Bug 975733 - Move some LDFLAGS for building executables on Windows to moz.build; r=mshal

This commit is contained in:
Ehsan Akhgari 2014-02-26 21:38:29 -05:00
parent 6a3df0012c
commit 2bb7d82af6
10 changed files with 58 additions and 77 deletions

View File

@ -67,22 +67,6 @@ PROGRAMS_DEST = $(DIST)/bin
include $(topsrcdir)/config/rules.mk
ifeq ($(OS_ARCH),WINNT) #{
#
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
#
ifndef GNU_CC #{
LDFLAGS += /HEAP:0x40000
endif #}
endif #}
ifneq (,$(filter-out WINNT,$(OS_ARCH)))
ifdef COMPILE_ENVIRONMENT

View File

@ -40,3 +40,14 @@ if CONFIG['_MSC_VER']:
if CONFIG['OS_ARCH'] == 'WINNT':
DEFINES['MOZ_PHOENIX'] = True
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# 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']

View File

@ -37,22 +37,3 @@ STL_FLAGS=
OS_LIBS += $(call EXPAND_LIBNAME,ole32 comdlg32 shell32 version)
include $(topsrcdir)/config/rules.mk
#
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
#
ifndef GNU_CC
LDFLAGS += /HEAP:0x40000
endif
# Get rid of console window
ifdef GNU_CC
LDFLAGS += -mwindows
endif

View File

@ -17,3 +17,17 @@ XPI_NAME = 'winembed'
DEFINES['XPCOM_GLUE'] = True
RESFILE = 'winEmbed.res'
if CONFIG['GNU_CC']:
# Get rid of console window
LDFLAGS += ['-mwindows']
else:
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
LDFLAGS += ['/HEAP:0x40000']

View File

@ -50,19 +50,6 @@ endif
# Note the manifest file exists in the tree, so we use the explicit filename
# here.
EXTRA_DEPS += plugin-container.exe.manifest
#
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
#
ifndef GNU_CC #{
LDFLAGS += /HEAP:0x40000
endif #}
endif #}
ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT)) #{

View File

@ -34,3 +34,14 @@ 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().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# 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']

View File

@ -69,16 +69,3 @@ GRE_BUILDID := $(shell cat $(DEPTH)/config/buildid)
DEFINES += -DGRE_BUILDID=$(GRE_BUILDID)
webapprt.$(OBJ_SUFFIX): $(DEPTH)/config/buildid
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
#
ifndef GNU_CC
LDFLAGS += /HEAP:0x40000
endif

View File

@ -28,3 +28,14 @@ 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().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
if not CONFIG['GNU_CC']:
LDFLAGS += ['/HEAP:0x40000']

View File

@ -41,22 +41,6 @@ include $(topsrcdir)/config/rules.mk
DEFINES += -DXULRUNNER_ICO='"$(DIST)/branding/xulrunner.ico"' -DDOCUMENT_ICO='"$(DIST)/branding/document.ico"'
ifeq ($(OS_ARCH),WINNT)
#
# Control the default heap size.
# This is the heap returned by GetProcessHeap().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# The default heap size is 1MB on Win32.
# The heap will grow if need be.
#
# Set it to 256k. See bug 127069.
#
ifndef GNU_CC
LDFLAGS += /HEAP:0x40000
endif
endif
ifdef MOZ_WIDGET_GTK
libs::
$(INSTALL) $(IFLAGS1) $(DIST)/branding/default16.png $(DIST)/bin/chrome/icons/default

View File

@ -31,3 +31,14 @@ 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().
# As we use the CRT heap, the default size is too large and wastes VM.
#
# 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']