2013-08-12 19:58:35 +00:00
|
|
|
# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
|
|
|
|
# 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/.
|
|
|
|
|
2015-03-10 08:03:12 +00:00
|
|
|
with Files('**'):
|
|
|
|
BUG_COMPONENT = ('Core', 'Security: Process Sandboxing')
|
|
|
|
|
2013-10-28 21:54:36 +00:00
|
|
|
if CONFIG['OS_ARCH'] == 'Linux':
|
|
|
|
DIRS += ['linux']
|
2014-08-08 16:55:22 +00:00
|
|
|
elif CONFIG['OS_ARCH'] == 'Darwin':
|
|
|
|
DIRS += ['mac']
|
2013-10-28 21:54:36 +00:00
|
|
|
elif CONFIG['OS_ARCH'] == 'WINNT':
|
2014-09-03 05:10:54 +00:00
|
|
|
Library('sandbox_s')
|
2013-10-30 23:58:45 +00:00
|
|
|
FORCE_STATIC_LIB = True
|
|
|
|
|
2014-02-14 16:07:16 +00:00
|
|
|
DIRS += [
|
2014-08-28 02:50:10 +00:00
|
|
|
'staticruntime',
|
2014-02-14 16:07:16 +00:00
|
|
|
'win/src/sandboxbroker',
|
|
|
|
'win/src/sandboxtarget',
|
|
|
|
]
|
2013-08-12 19:58:35 +00:00
|
|
|
|
2014-12-24 08:13:42 +00:00
|
|
|
if (CONFIG['CPU_ARCH'] == 'x86' and CONFIG['_MSC_VER'] and not
|
|
|
|
CONFIG['CLANG_CL']):
|
|
|
|
DIRS += ['win/wow_helper']
|
|
|
|
|
2014-11-29 17:12:18 +00:00
|
|
|
EXPORTS.mozilla.sandboxing += [
|
2015-01-22 08:37:30 +00:00
|
|
|
'chromium-shim/sandbox/win/loggingCallbacks.h',
|
|
|
|
'chromium-shim/sandbox/win/loggingTypes.h',
|
|
|
|
'chromium-shim/sandbox/win/sandboxLogging.h',
|
2014-11-29 17:12:18 +00:00
|
|
|
]
|
2014-06-11 14:32:37 +00:00
|
|
|
|
2014-08-28 02:50:10 +00:00
|
|
|
include('objs.mozbuild')
|
|
|
|
SOURCES += security_sandbox_cppsrcs
|
2014-03-28 04:59:16 +00:00
|
|
|
|
2014-11-18 13:48:21 +00:00
|
|
|
# Bug 1102853 tracks looking at removing this.
|
|
|
|
if CONFIG['CPU_ARCH'] == 'x86_64':
|
2015-05-15 00:49:20 +00:00
|
|
|
SOURCES['/security/sandbox/chromium/sandbox/win/src/sharedmem_ipc_client.cc'].no_pgo = True
|
2014-11-18 13:48:21 +00:00
|
|
|
|
2013-11-27 13:55:07 +00:00
|
|
|
for var in ('UNICODE', '_UNICODE', 'NS_NO_XPCOM', 'SANDBOX_EXPORTS',
|
2014-02-28 13:17:22 +00:00
|
|
|
'NOMINMAX', '_CRT_RAND_S', 'CHROMIUM_SANDBOX_BUILD'):
|
2013-11-27 13:55:07 +00:00
|
|
|
DEFINES[var] = True
|
2014-02-18 13:49:12 +00:00
|
|
|
|
2015-01-22 08:37:30 +00:00
|
|
|
LOCAL_INCLUDES += ['/security/sandbox/chromium-shim']
|
2014-02-18 13:49:12 +00:00
|
|
|
LOCAL_INCLUDES += ['/security/sandbox/chromium']
|
|
|
|
LOCAL_INCLUDES += ['/nsprpub']
|
2014-03-05 00:39:06 +00:00
|
|
|
|
|
|
|
DISABLE_STL_WRAPPING = True
|
2014-08-09 21:25:24 +00:00
|
|
|
|
|
|
|
# Suppress warnings in third-party code.
|
|
|
|
if CONFIG['_MSC_VER']:
|
|
|
|
CXXFLAGS += [
|
|
|
|
'-wd4275', # non dll-interface class exception used as base for dll-interface class
|
|
|
|
'-wd4717', # recursive on all control paths, function will cause runtime stack overflow
|
2014-08-19 19:09:03 +00:00
|
|
|
'-wd4996', # 'GetVersionExW': was declared deprecated
|
2014-08-09 21:25:24 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
FAIL_ON_WARNINGS = True
|