2016-07-14 16:16:42 +00:00
|
|
|
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
|
2013-12-12 14:41:05 +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/.
|
|
|
|
|
2016-11-15 17:37:09 +00:00
|
|
|
include('gyp_base.mozbuild')
|
|
|
|
|
|
|
|
gyp_vars.update({
|
2015-11-18 20:03:25 +00:00
|
|
|
'lsan': 0,
|
|
|
|
'asan': 0,
|
2020-12-10 18:29:11 +00:00
|
|
|
'tsan': 1 if CONFIG['MOZ_TSAN'] else 0,
|
2017-04-09 10:59:26 +00:00
|
|
|
'ubsan' : 0,
|
2017-07-07 18:43:59 +00:00
|
|
|
'fuzzing' : 1 if CONFIG['FUZZING'] else 0,
|
|
|
|
'libfuzzer' : 1 if CONFIG['LIBFUZZER'] else 0,
|
2018-05-24 19:11:46 +00:00
|
|
|
'libfuzzer_fuzzer_no_link_flag' : 1 if CONFIG['HAVE_LIBFUZZER_FLAG_FUZZER_NO_LINK'] else 0,
|
2013-12-12 14:41:05 +00:00
|
|
|
'build_with_mozilla': 1,
|
|
|
|
'build_with_chromium': 0,
|
2017-06-13 05:54:13 +00:00
|
|
|
# 10.9 once we move to TC cross-compiles - bug 1270217
|
2018-05-10 09:41:13 +00:00
|
|
|
'mac_sdk_min': '10.9',
|
|
|
|
'mac_deployment_target': '10.9',
|
2014-05-09 18:40:32 +00:00
|
|
|
'use_official_google_api_keys': 0,
|
2013-12-12 14:41:05 +00:00
|
|
|
'have_clock_monotonic': 1 if CONFIG['HAVE_CLOCK_MONOTONIC'] else 0,
|
|
|
|
'have_ethtool_cmd_speed_hi': 1 if CONFIG['MOZ_WEBRTC_HAVE_ETHTOOL_SPEED_HI'] else 0,
|
2017-08-08 07:50:07 +00:00
|
|
|
'include_alsa_audio': 1 if CONFIG['MOZ_ALSA'] else 0,
|
2013-12-12 14:41:05 +00:00
|
|
|
'include_pulse_audio': 1 if CONFIG['MOZ_PULSEAUDIO'] else 0,
|
|
|
|
# basic stuff for everything
|
|
|
|
'include_internal_video_render': 0,
|
2017-12-07 21:09:38 +00:00
|
|
|
'clang': 1 if CONFIG['CC_TYPE'] == 'clang' else 0,
|
2018-07-25 18:02:02 +00:00
|
|
|
'clang_cl': 1 if CONFIG['CC_TYPE'] == 'clang-cl' else 0,
|
2013-12-12 14:41:05 +00:00
|
|
|
'clang_use_chrome_plugins': 0,
|
|
|
|
'enable_protobuf': 0,
|
|
|
|
'include_tests': 0,
|
|
|
|
'enable_android_opensl': 1,
|
2014-02-26 18:55:07 +00:00
|
|
|
'enable_android_opensl_output': 0,
|
2013-12-12 14:41:05 +00:00
|
|
|
# use_system_lib* still seems to be in use in trunk/build
|
|
|
|
'use_system_libjpeg': 0,
|
|
|
|
'use_system_libvpx': 0,
|
2015-01-29 23:33:36 +00:00
|
|
|
'build_json': 0,
|
2013-12-12 14:41:05 +00:00
|
|
|
'build_libjpeg': 0,
|
2014-01-31 00:55:04 +00:00
|
|
|
'build_libyuv': 0,
|
2015-01-29 23:33:36 +00:00
|
|
|
'build_libvpx': 0,
|
2017-06-13 05:54:13 +00:00
|
|
|
'build_libevent': 0,
|
2015-01-29 23:33:36 +00:00
|
|
|
'build_ssl': 0,
|
2015-11-18 20:03:25 +00:00
|
|
|
'build_json': 0,
|
|
|
|
'build_icu': 0,
|
|
|
|
'build_opus': 0,
|
2017-02-24 19:01:56 +00:00
|
|
|
'libyuv_dir': '/media/libyuv/libyuv',
|
2014-05-29 21:05:14 +00:00
|
|
|
# don't use openssl
|
|
|
|
'use_openssl': 0,
|
2017-06-13 05:54:13 +00:00
|
|
|
# Must match build/gyp.mozbuild WEBRTC_BUILD_LIBEVENT
|
|
|
|
#'enable_libevent': 0, default according to OS
|
2014-01-31 00:55:04 +00:00
|
|
|
|
2016-12-28 00:41:02 +00:00
|
|
|
'debug': 1 if CONFIG['DEBUG'] else 0,
|
|
|
|
|
2014-08-01 09:42:00 +00:00
|
|
|
'use_x11': 1 if CONFIG['MOZ_X11'] else 0,
|
|
|
|
'use_glib': 1 if CONFIG['GLIB_LIBS'] else 0,
|
2017-06-22 05:12:20 +00:00
|
|
|
# bug 1373485 - avoid pkg-config for gtk2 in webrtc
|
|
|
|
'use_gtk': 0,
|
2014-08-01 09:42:00 +00:00
|
|
|
|
2013-12-12 14:41:05 +00:00
|
|
|
# turn off mandatory use of NEON and instead use NEON detection
|
|
|
|
'arm_neon': 0,
|
2014-02-04 21:08:43 +00:00
|
|
|
'arm_neon_optional': 1,
|
2013-12-12 14:41:05 +00:00
|
|
|
|
|
|
|
# (for vp8) chromium sets to 0 also
|
|
|
|
'use_temporal_layers': 0,
|
2014-09-24 17:11:58 +00:00
|
|
|
|
2013-12-12 14:41:05 +00:00
|
|
|
# Creates AEC internal sample dump files in current directory
|
2015-02-12 12:46:59 +00:00
|
|
|
'aec_debug_dump': 1,
|
2013-12-12 14:41:05 +00:00
|
|
|
|
|
|
|
# codec enable/disables:
|
|
|
|
'include_g711': 1,
|
|
|
|
'include_opus': 1,
|
2014-08-03 04:10:09 +00:00
|
|
|
'include_g722': 1,
|
2013-12-12 14:41:05 +00:00
|
|
|
'include_ilbc': 0,
|
2015-11-18 20:03:25 +00:00
|
|
|
# We turn on ISAC because the AGC uses parts of it, and depend on the
|
|
|
|
# linker to throw away uneeded bits.
|
|
|
|
'include_isac': 1,
|
2013-12-12 14:41:05 +00:00
|
|
|
'include_pcm16b': 1,
|
2017-06-13 05:54:13 +00:00
|
|
|
|
|
|
|
#'rtc_opus_variable_complexity': 1,
|
2017-07-12 20:49:15 +00:00
|
|
|
|
|
|
|
'apm_debug_dump': 1,
|
2016-11-15 17:37:09 +00:00
|
|
|
})
|
2013-12-12 14:41:05 +00:00
|
|
|
|
2016-11-15 17:37:09 +00:00
|
|
|
if os == 'Android':
|
2023-03-08 20:23:41 +00:00
|
|
|
gyp_vars.update(gtest_target_type='executable')
|
2013-12-12 14:41:05 +00:00
|
|
|
|
|
|
|
if CONFIG['ARM_ARCH']:
|
2013-12-17 02:12:15 +00:00
|
|
|
if int(CONFIG['ARM_ARCH']) < 7:
|
2013-12-12 14:41:05 +00:00
|
|
|
gyp_vars['armv7'] = 0
|
2014-02-04 21:08:43 +00:00
|
|
|
gyp_vars['arm_neon_optional'] = 0
|
2013-12-12 14:41:05 +00:00
|
|
|
elif os == 'Android':
|
|
|
|
gyp_vars['armv7'] = 1
|
2017-06-13 05:54:13 +00:00
|
|
|
gyp_vars['arm_neon'] = 1
|
|
|
|
gyp_vars['build_with_neon'] = 1
|
2013-12-12 14:41:05 +00:00
|
|
|
else:
|
|
|
|
# CPU detection for ARM works on Android only. armv7 always uses CPU
|
|
|
|
# detection, so we have to set armv7=0 for non-Android target
|
|
|
|
gyp_vars['armv7'] = 0
|
2014-01-16 22:08:01 +00:00
|
|
|
# For libyuv
|
2014-08-25 19:39:04 +00:00
|
|
|
gyp_vars['arm_version'] = int(CONFIG['ARM_ARCH'])
|
2013-12-12 14:41:05 +00:00
|
|
|
|
|
|
|
if CONFIG['MACOS_SDK_DIR']:
|
|
|
|
gyp_vars['mac_sdk_path'] = CONFIG['MACOS_SDK_DIR']
|
2017-01-20 15:42:32 +00:00
|
|
|
|
|
|
|
if not CONFIG['MOZ_SYSTEM_LIBVPX']:
|
|
|
|
gyp_vars['libvpx_dir'] = '/media/libvpx/libvpx'
|
2017-08-03 04:28:25 +00:00
|
|
|
|
|
|
|
if not CONFIG['MOZ_SYSTEM_LIBEVENT']:
|
2017-10-19 14:51:04 +00:00
|
|
|
gyp_vars['libevent_dir'] = '/ipc/chromium/src/third_party/libevent'
|