2016-07-14 16:16:42 +00:00
|
|
|
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
|
2013-02-25 20:47:18 +00:00
|
|
|
# vim: set filetype=python:
|
|
|
|
# This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
|
2017-08-25 17:08:45 +00:00
|
|
|
with Files("**"):
|
|
|
|
BUG_COMPONENT = ("Firefox", "General")
|
|
|
|
|
|
|
|
with Files("firefox.exe.manifest"):
|
|
|
|
BUG_COMPONENT = ("Core", "Widget: Win32")
|
|
|
|
with Files("module.ver"):
|
|
|
|
BUG_COMPONENT = ("Core", "Widget: Win32")
|
|
|
|
with Files("splash.rc"):
|
|
|
|
BUG_COMPONENT = ("Core", "Widget: Win32")
|
|
|
|
|
|
|
|
with Files("macversion.py"):
|
|
|
|
BUG_COMPONENT = ("Core", "Widget: Cocoa")
|
|
|
|
with Files("macbuild/**"):
|
|
|
|
BUG_COMPONENT = ("Core", "Widget: Cocoa")
|
|
|
|
|
|
|
|
with Files("moz.build"):
|
|
|
|
BUG_COMPONENT = ("Core", "Build Config")
|
|
|
|
with Files("Makefile.in"):
|
|
|
|
BUG_COMPONENT = ("Core", "Build Config")
|
|
|
|
|
|
|
|
with Files("profile/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}/**"):
|
|
|
|
BUG_COMPONENT = ("Firefox", "Theme")
|
|
|
|
with Files("profile/channel-prefs.js"):
|
|
|
|
BUG_COMPONENT = ("Firefox", "Installer")
|
|
|
|
with Files("profile/firefox.js"):
|
|
|
|
BUG_COMPONENT = ("Firefox", "General")
|
|
|
|
|
|
|
|
|
2013-02-25 20:47:18 +00:00
|
|
|
DIRS += ['profile/extensions']
|
2013-05-01 18:05:40 +00:00
|
|
|
|
2016-05-15 15:23:57 +00:00
|
|
|
GeckoProgram(CONFIG['MOZ_APP_NAME'])
|
2013-05-01 18:05:40 +00:00
|
|
|
|
2013-10-24 23:23:05 +00:00
|
|
|
SOURCES += [
|
2013-04-23 21:54:15 +00:00
|
|
|
'nsBrowserApp.cpp',
|
|
|
|
]
|
2013-11-27 13:55:07 +00:00
|
|
|
|
2017-11-09 19:39:27 +00:00
|
|
|
# Neither channel-prefs.js nor firefox.exe want to end up in dist/bin/browser.
|
|
|
|
DIST_SUBDIR = ""
|
2014-07-23 17:56:25 +00:00
|
|
|
|
2014-02-10 18:41:02 +00:00
|
|
|
LOCAL_INCLUDES += [
|
2015-11-04 05:20:20 +00:00
|
|
|
'!/build',
|
2014-02-10 18:41:02 +00:00
|
|
|
'/toolkit/xre',
|
|
|
|
'/xpcom/base',
|
|
|
|
'/xpcom/build',
|
|
|
|
]
|
2014-02-24 13:30:25 +00:00
|
|
|
|
2016-09-01 13:07:01 +00:00
|
|
|
if CONFIG['LIBFUZZER']:
|
2017-01-12 05:44:18 +00:00
|
|
|
USE_LIBS += [ 'fuzzer' ]
|
|
|
|
LOCAL_INCLUDES += [
|
|
|
|
'/tools/fuzzing/libfuzzer',
|
|
|
|
]
|
2016-09-01 13:07:01 +00:00
|
|
|
|
2017-10-09 20:09:09 +00:00
|
|
|
if CONFIG['ENABLE_GECKODRIVER']:
|
|
|
|
DEFINES['MOZ_GECKODRIVER'] = True
|
|
|
|
|
2017-12-08 12:46:13 +00:00
|
|
|
if CONFIG['CC_TYPE'] in ('msvc', 'clang-cl'):
|
2014-02-24 13:30:25 +00:00
|
|
|
# Always enter a Windows program through wmain, whether or not we're
|
|
|
|
# a console application.
|
|
|
|
WIN32_EXE_LDFLAGS += ['-ENTRY:wmainCRTStartup']
|
2014-02-26 14:12:49 +00:00
|
|
|
|
|
|
|
if CONFIG['OS_ARCH'] == 'WINNT':
|
2014-03-04 22:19:24 +00:00
|
|
|
RCINCLUDE = 'splash.rc'
|
2014-02-26 14:12:49 +00:00
|
|
|
DEFINES['MOZ_PHOENIX'] = True
|
2014-02-27 02:38:29 +00:00
|
|
|
|
2016-05-15 15:41:40 +00:00
|
|
|
if CONFIG['MOZ_SANDBOX'] and CONFIG['OS_ARCH'] == 'WINNT':
|
|
|
|
# For sandbox includes and the include dependencies those have
|
|
|
|
LOCAL_INCLUDES += [
|
|
|
|
'/security/sandbox/chromium',
|
|
|
|
'/security/sandbox/chromium-shim',
|
|
|
|
]
|
|
|
|
|
|
|
|
USE_LIBS += [
|
|
|
|
'sandbox_s',
|
|
|
|
]
|
|
|
|
|
2016-07-07 23:00:23 +00:00
|
|
|
DELAYLOAD_DLLS += [
|
|
|
|
'winmm.dll',
|
|
|
|
'user32.dll',
|
|
|
|
]
|
|
|
|
|
2018-01-25 18:15:40 +00:00
|
|
|
if CONFIG['CC_TYPE'] == "msvc":
|
|
|
|
CFLAGS += ['-guard:cf']
|
|
|
|
CXXFLAGS += ['-guard:cf']
|
|
|
|
LDFLAGS += ['-guard:cf']
|
|
|
|
|
2014-02-27 02:38:29 +00:00
|
|
|
# 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.
|
2017-12-07 21:09:15 +00:00
|
|
|
if CONFIG['OS_ARCH'] == 'WINNT' and CONFIG['CC_TYPE'] not in ('clang', 'gcc'):
|
2014-02-27 02:38:29 +00:00
|
|
|
LDFLAGS += ['/HEAP:0x40000']
|
2014-03-05 00:39:06 +00:00
|
|
|
|
2017-04-28 23:35:19 +00:00
|
|
|
DisableStlWrapping()
|
2014-08-05 22:25:33 +00:00
|
|
|
|
|
|
|
if CONFIG['MOZ_LINKER']:
|
|
|
|
OS_LIBS += CONFIG['MOZ_ZLIB_LIBS']
|
|
|
|
|
|
|
|
if CONFIG['HAVE_CLOCK_MONOTONIC']:
|
|
|
|
OS_LIBS += CONFIG['REALTIME_LIBS']
|
2014-09-12 03:24:10 +00:00
|
|
|
|
2016-09-14 09:40:53 +00:00
|
|
|
if CONFIG['MOZ_LINUX_32_SSE2_STARTUP_ERROR']:
|
|
|
|
DEFINES['MOZ_LINUX_32_SSE2_STARTUP_ERROR'] = True
|
2017-10-25 22:12:10 +00:00
|
|
|
COMPILE_FLAGS['OS_CXXFLAGS'] = [
|
|
|
|
f for f in COMPILE_FLAGS.get('OS_CXXFLAGS', [])
|
|
|
|
if not f.startswith('-march=') and f not in ('-msse', '-msse2', '-mfpmath=sse')
|
|
|
|
] + [
|
|
|
|
'-mno-sse', '-mno-sse2', '-mfpmath=387',
|
|
|
|
]
|
2016-09-14 09:40:53 +00:00
|
|
|
|
2016-02-02 05:21:12 +00:00
|
|
|
for icon in ('firefox', 'document', 'newwindow', 'newtab', 'pbmode'):
|
2016-11-22 07:59:43 +00:00
|
|
|
DEFINES[icon.upper() + '_ICO'] = '"%s/%s/%s.ico"' % (
|
2016-11-22 22:58:20 +00:00
|
|
|
TOPSRCDIR, CONFIG['MOZ_BRANDING_DIRECTORY'], icon)
|