]> git.decadent.org.uk Git - videolink.git/commitdiff
Added workaround for XULRunner 1.9's requirement of 16-bit wchar_t. Changing the... 1.2.5 1.2.5-1
authorBen Hutchings <ben@decadent.org.uk>
Wed, 11 Jun 2008 23:27:21 +0000 (23:27 +0000)
committerBen Hutchings <ben@decadent.org.uk>
Mon, 3 Nov 2008 00:20:04 +0000 (00:20 +0000)
The Makefile now removes -fshort-wchar from compiler options.  All files including Mozilla headers bracket them with #include "wchar_t_short.h" ... #include "wchar_t_default.h".  wchar_t_short.h defines wchar_t as a macro expanding to uint16_t and wchar_t_default.h undefines the macro.

15 files changed:
ChangeLog
Makefile
browser_widget.cpp
browser_widget.hpp
child_iterator.hpp
debian/changelog
event_state_manager.cpp
link_iterator.hpp
null_prompt_service.cpp
null_prompt_service.hpp
style_sheets.cpp
videolink.cpp
wchar_t_default.h [new file with mode: 0644]
wchar_t_short.h [new file with mode: 0644]
xpcom_support.hpp

index 5b73aebf731adc1ad60dcbc15149df2fb4419261..5cb546ddd8fae3920878747a92e4c4908735ebc6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+videolink (1.2.5) unstable; urgency=low
+
+  * Added workaround for XULRunner 1.9's requirement of 16-bit wchar_t
+
+ -- Ben Hutchings <ben@decadent.org.uk>  Thu, 12 Jun 2008 00:20:54 +0100
+
 videolink (1.2.4) unstable; urgency=low
 
   * Fixed warning messages from make when first compiled
index 9a62d7e2be49e66ebe55aaa3ecf06c2bfa37291e..d0bd9971c12474713a2fc3c1a9a15d40f753a541 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -99,7 +99,8 @@ $(sources_using_gtkmm:%.cpp=.objs/%.o) \
     : CPPFLAGS += $(shell pkg-config --cflags gtkmm-2.4)
 
 $(sources_using_moz:%.cpp=.objs/%.o) \
-    : CPPFLAGS += $(shell pkg-config --cflags $(moz_pc)) $(moz_cppflags_extra)
+    : CPPFLAGS += $(filter-out -fshort-wchar, \
+                   $(shell pkg-config --cflags $(moz_pc)) $(moz_cppflags_extra))
 # Non-virtual destructors are fine in XPCOM interface classes since
 # instances are only ever called by the Release function which is virtual.
 $(sources_using_moz:%.cpp=.objs/%.o) : CXXFLAGS += -Wno-non-virtual-dtor
index 3b7a2d442709ccd34fa37048c0cc33ae4f18e4c5..baa0748b36eafb9863cfceb7fda2ccbdbb506664 100644 (file)
@@ -8,10 +8,12 @@
 
 #include <limits.h>
 
+#include "wchar_t_short.h"
 #include <gtkmozembed_internal.h>
 #if MOZ_VERSION_MAJOR == 1 && MOZ_VERSION_MINOR == 9
 #include <gtkmozembed_glue.cpp>
 #endif
+#include "wchar_t_default.h"
 
 #include "xpcom_support.hpp"
 
index 456067bf39df4067182d84b12342ef7e48d8fa6e..fdf18ced710b10179f3e2f795efe9395f19fc786 100644 (file)
@@ -7,8 +7,10 @@
 #include <glibmm/signalproxy.h>
 #include <gtkmm/bin.h>
 
+#include "wchar_t_short.h"
 #include <gtkmozembed.h>
 #include <nsCOMPtr.h>
+#include "wchar_t_default.h"
 
 class browser_widget;
 class nsIWebBrowser;
index 53d88d319dfb63fb9241a2749023ed2c80b33d9d..9c58313966d0cc243224d7df0a9e7e10603040fc 100644 (file)
@@ -6,8 +6,10 @@
 
 #include <iterator>
 
+#include "wchar_t_short.h"
 #include <nsCOMPtr.h>
 #include <nsIDOMNode.h>
+#include "wchar_t_default.h"
 
 class child_iterator
     : public std::iterator<std::input_iterator_tag, nsCOMPtr<nsIDOMNode>,
index 50fbdb60de5d66bf404505e4cbf523edbda91b89..c2390d0d4e6bc27bad1d78070f67908009ff2b31 100644 (file)
@@ -1,3 +1,10 @@
+videolink (1.2.5-1) unstable; urgency=low
+
+  * New upstream version
+    - Adds workaround for bug #485876
+
+ -- Ben Hutchings <ben@decadent.org.uk>  Thu, 12 Jun 2008 00:22:20 +0100
+
 videolink (1.2.4-1) unstable; urgency=low
 
   * New upstream version
index 50b068a013117863b1839859760b8e304efe3404..3fde68df6ef87b97eef1fdd2c52cb7ebfceb1353 100644 (file)
@@ -4,8 +4,10 @@
 #ifndef MOZILLA_INTERNAL_API
 #define MOZILLA_INTERNAL_API
 #endif
+#include "wchar_t_short.h"
 #include <nsIDocShell.h>
 #include <nsPresContext.h>
+#include "wchar_t_default.h"
 
 #include "event_state_manager.hpp"
 #include "xpcom_support.hpp"
index ceadc6d5363275a373ed1032196f83ba0364eccb..b56e69b7f3995dc12ad434f0b354baf522a30f02 100644 (file)
@@ -6,9 +6,11 @@
 
 #include <iterator>
 
+#include "wchar_t_short.h"
 #include <nsCOMPtr.h>
 #include <nsIDOMHTMLCollection.h>
 #include <nsIDOMNode.h>
+#include "wchar_t_default.h"
 
 class nsIDOMDocument;
 
index 2548512af320127dd51bee9d00bc8b6e331eee1a..68d6d9010a287cb6189cd93137afb4d54273afe7 100644 (file)
@@ -6,6 +6,7 @@
 
 #include <langinfo.h>
 
+#include "wchar_t_short.h"
 #include <nsCOMPtr.h>
 #include <nsICharsetConverterManager.h>
 #include <nsIComponentManager.h>
@@ -13,6 +14,7 @@
 #include <nsIComponentRegistrar.h>
 #include <nsServiceManagerUtils.h>
 #include <nsIUnicodeEncoder.h>
+#include "wchar_t_default.h"
 
 #include "null_prompt_service.hpp"
 #include "videolink.hpp"
index c3b69515bd730792275473aa730e2faf816978c6..464b809c980a49389b53c43d1cb1dc52ae2aaf5a 100644 (file)
@@ -1,7 +1,9 @@
 #ifndef INC_NULL_PROMPT_SERVICE_HPP
 #define INC_NULL_PROMPT_SERVICE_HPP
 
+#include "wchar_t_short.h"
 #include <nsIPromptService.h>
+#include "wchar_t_default.h"
 
 class null_prompt_service : public nsIPromptService
 {
index 9cd6273cff80110d059a23bc8bed9f58a9ccd39b..6093585f527c29114391b59028c1e8cdffb105ea 100644 (file)
@@ -3,12 +3,14 @@
 
 #include "style_sheets.hpp"
 
+#include "wchar_t_short.h"
 #include <nsCOMPtr.h>
 #include <nsContentCID.h>
 #include <nsIStyleSheetService.h>
 #include <nsServiceManagerUtils.h>
 #include <nsIURI.h>
 #include <nsNetUtil.h>
+#include "wchar_t_default.h"
 
 #include "xpcom_support.hpp"
 
index 1d473fac03fd102630ac1ff289c8dd58a4e83f1f..9ed174675f2a85d45f58737ded4d62a1d802677c 100644 (file)
@@ -22,6 +22,7 @@
 #include <gtkmm/main.h>
 #include <gtkmm/window.h>
 
+#include "wchar_t_short.h"
 #include <ImageErrors.h>
 #if MOZ_VERSION_MAJOR == 1 && MOZ_VERSION_MINOR == 9
 #include <nsWeakPtr.h>
@@ -56,6 +57,7 @@ typedef nsCOMPtr<nsIWeakReference> nsWeakPtr;
 #else
 #include <nsStringAPI.h>
 #endif
+#include "wchar_t_default.h"
 
 #include "browser_widget.hpp"
 #include "child_iterator.hpp"
diff --git a/wchar_t_default.h b/wchar_t_default.h
new file mode 100644 (file)
index 0000000..59028f6
--- /dev/null
@@ -0,0 +1 @@
+#undef wchar_t
diff --git a/wchar_t_short.h b/wchar_t_short.h
new file mode 100644 (file)
index 0000000..7377c36
--- /dev/null
@@ -0,0 +1,3 @@
+#include <stdint.h>
+#undef wchar_t
+#define wchar_t uint16_t
index 4fc983f12b26dbad52d8a5cd1f17e90068a4b00c..b3a6fd182de756597ccc838fd4489250ad65f9f7 100644 (file)
@@ -6,7 +6,9 @@
 
 #include <stdexcept>
 
+#include "wchar_t_short.h"
 #include <nsError.h>
+#include "wchar_t_default.h"
 
 namespace xpcom_support
 {