components/desktop/firefox/patches/firefox-41-static-xul-components.patch
author Rich Burridge <rich.burridge@oracle.com>
Tue, 02 May 2017 17:33:26 -0700
changeset 7964 d9801318ed3d
parent 5527 611b2d6efdfe
permissions -rw-r--r--
25981468 Build ilmbase and openexr with the GNU compilers

Define variables differently for Solaris. 
Do not plan to send upstream.

diff --git a/toolkit/library/StaticXULComponentsEnd/StaticXULComponentsEnd.cpp b/toolkit/library/StaticXULComponentsEnd/StaticXULComponentsEnd.cpp
--- a/toolkit/library/StaticXULComponentsEnd/StaticXULComponentsEnd.cpp
+++ b/toolkit/library/StaticXULComponentsEnd/StaticXULComponentsEnd.cpp
@@ -5,9 +5,10 @@
 #ifdef _MSC_VER
 /* Sections on Windows are in two parts, separated with $. When linking,
  * sections with the same first part are all grouped, and ordered
  * alphabetically with the second part as sort key. */
 #  pragma section(".kPStaticModules$Z", read)
 #  undef NSMODULE_SECTION
 #  define NSMODULE_SECTION __declspec(allocate(".kPStaticModules$Z"), dllexport)
 #endif
-NSMODULE_DEFN(end_kPStaticModules) = nullptr;
+static const mozilla::Module kEndModule = { 0 };
+NSMODULE_DEFN(end_kPStaticModules) = &kEndModule;
diff --git a/toolkit/library/StaticXULComponentsStart.cpp b/toolkit/library/StaticXULComponentsStart.cpp
--- a/toolkit/library/StaticXULComponentsStart.cpp
+++ b/toolkit/library/StaticXULComponentsStart.cpp
@@ -1,3 +1,4 @@
 #include "mozilla/Module.h"
 
-NSMODULE_DEFN(start_kPStaticModules) = nullptr;
+static const mozilla::Module kStartModule = { 0 };
+NSMODULE_DEFN(start_kPStaticModules) = &kStartModule;