Bug 1060890 Port static linking of the CRT into the Thunderbird executable from bug 1023941. rs=port-by-build-system-peer,a=Standard8
authorMark Banner <standard8@mozilla.com>
Wed, 03 Sep 2014 13:20:58 +0100
changeset 18726 1d666c72afffd04a7dd13505ad1478834fec4126
parent 18725 c2b6c14a799fba778f9cd3071ea774a2fae3f5e4
child 18727 c11434d84ca899dcca383ef3b5a483a278e953fc
push id1285
push usermbanner@mozilla.com
push dateWed, 03 Sep 2014 19:03:01 +0000
treeherdercomm-aurora@1d666c72afff [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersport-by-build-system-peer, Standard8
bugs1060890, 1023941
Bug 1060890 Port static linking of the CRT into the Thunderbird executable from bug 1023941. rs=port-by-build-system-peer,a=Standard8
mail/app/moz.build
--- a/mail/app/moz.build
+++ b/mail/app/moz.build
@@ -13,19 +13,20 @@ if not CONFIG['LIBXUL_SDK']:
     PROGRAM = CONFIG['MOZ_APP_NAME']
     SOURCES += ['nsMailApp.cpp']
     LOCAL_INCLUDES += [
         '/mozilla/toolkit/xre',
         '/mozilla/xpcom/base',
         '/mozilla/xpcom/build',
     ]
 
-    USE_LIBS += [
-        'xpcomglue',
+    DELAYLOAD_DLLS += [
+        'mozglue.dll',
     ]
+    USE_STATIC_LIBS = True    
 
     if CONFIG['_MSC_VER']:
         # Always enter a Windows program through wmain, whether or not we're
         # a console application.
         WIN32_EXE_LDFLAGS += ['-ENTRY:wmainCRTStartup']
 
     # Control the default heap size.
     # This is the heap returned by GetProcessHeap().
@@ -33,12 +34,22 @@ if not CONFIG['LIBXUL_SDK']:
     #
     # The default heap size is 1MB on Win32.
     # The heap will grow if need be.
     #
     # Set it to 256k.  See bug 127069.
     if CONFIG['OS_ARCH'] == 'WINNT' and not CONFIG['GNU_CC']:
         LDFLAGS += ['/HEAP:0x40000']
 
+    if CONFIG['OS_ARCH'] == 'WINNT':
+        USE_LIBS += [
+            'mozglue',
+            'xpcomglue_staticruntime',
+        ]
+    else:
+        USE_LIBS += [
+            'xpcomglue',
+        ]
+
     if CONFIG['MOZ_LINKER']:
         OS_LIBS += CONFIG['MOZ_ZLIB_LIBS']
 
 DISABLE_STL_WRAPPING = True