2016-07-14 19:16:42 +03:00
|
|
|
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
|
2013-02-26 00:47:22 +04: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/.
|
|
|
|
|
2013-12-12 18:41:05 +04:00
|
|
|
include('/build/gyp.mozbuild')
|
|
|
|
|
|
|
|
GYP_DIRS += [
|
|
|
|
'nICEr',
|
|
|
|
'nrappkit',
|
|
|
|
]
|
|
|
|
|
2017-05-30 19:37:29 +03:00
|
|
|
# Set gyp vars that webrtc needs when building under various analysis tools.
|
|
|
|
# Primarily this prevents webrtc from setting NVALGRIND and breaking builds.
|
|
|
|
gyp_vars_copy = gyp_vars.copy()
|
|
|
|
if CONFIG['MOZ_VALGRIND']:
|
|
|
|
gyp_vars_copy.update(build_for_tool="memcheck")
|
|
|
|
elif CONFIG['MOZ_ASAN']:
|
|
|
|
gyp_vars_copy.update(build_for_tool="asan")
|
|
|
|
elif CONFIG['MOZ_TSAN']:
|
|
|
|
gyp_vars_copy.update(build_for_tool="tsan")
|
|
|
|
|
2013-12-19 21:08:31 +04:00
|
|
|
# These files cannot be built in unified mode because of name clashes on RCSSTRING
|
|
|
|
nICEr_non_unified_sources = [
|
|
|
|
'nICEr/src/crypto/nr_crypto.c',
|
|
|
|
'nICEr/src/ice/ice_candidate.c',
|
|
|
|
'nICEr/src/ice/ice_candidate_pair.c',
|
|
|
|
'nICEr/src/ice/ice_component.c',
|
|
|
|
'nICEr/src/ice/ice_ctx.c',
|
|
|
|
'nICEr/src/ice/ice_media_stream.c',
|
|
|
|
'nICEr/src/ice/ice_parser.c',
|
|
|
|
'nICEr/src/ice/ice_peer_ctx.c',
|
|
|
|
'nICEr/src/ice/ice_socket.c',
|
|
|
|
'nICEr/src/net/nr_socket.c',
|
|
|
|
'nICEr/src/net/transport_addr.c',
|
|
|
|
'nICEr/src/net/transport_addr_reg.c',
|
|
|
|
'nICEr/src/stun/addrs.c',
|
|
|
|
'nICEr/src/stun/nr_socket_turn.c',
|
|
|
|
'nICEr/src/stun/stun_build.c',
|
|
|
|
'nICEr/src/stun/stun_client_ctx.c',
|
|
|
|
'nICEr/src/stun/stun_codec.c',
|
|
|
|
'nICEr/src/stun/stun_hint.c',
|
|
|
|
'nICEr/src/stun/stun_msg.c',
|
|
|
|
'nICEr/src/stun/stun_proc.c',
|
|
|
|
'nICEr/src/stun/stun_server_ctx.c',
|
|
|
|
'nICEr/src/stun/stun_util.c',
|
|
|
|
'nICEr/src/stun/turn_client_ctx.c',
|
|
|
|
'nICEr/src/util/cb_args.c',
|
|
|
|
'nICEr/src/util/ice_util.c',
|
|
|
|
]
|
2013-12-20 22:27:50 +04:00
|
|
|
|
|
|
|
# This file cannot be built in unified mode because it breaks Linux ASAN builds
|
|
|
|
nICEr_non_unified_sources += [
|
|
|
|
'nICEr/src/util/mbslen.c',
|
|
|
|
]
|
2013-12-19 21:08:31 +04:00
|
|
|
nrappkit_non_unified_sources = [
|
|
|
|
'nrappkit/src/log/r_log.c',
|
|
|
|
'nrappkit/src/util/byteorder.c',
|
|
|
|
'nrappkit/src/util/hex.c',
|
|
|
|
'nrappkit/src/util/libekr/debug.c',
|
|
|
|
'nrappkit/src/util/libekr/r_assoc.c',
|
|
|
|
'nrappkit/src/util/libekr/r_crc32.c',
|
|
|
|
'nrappkit/src/util/libekr/r_data.c',
|
|
|
|
'nrappkit/src/util/libekr/r_errors.c',
|
|
|
|
'nrappkit/src/util/libekr/r_list.c',
|
|
|
|
'nrappkit/src/util/libekr/r_memory.c',
|
|
|
|
'nrappkit/src/util/libekr/r_replace.c',
|
|
|
|
'nrappkit/src/util/libekr/r_time.c',
|
|
|
|
'nrappkit/src/util/p_buf.c',
|
|
|
|
'nrappkit/src/util/util.c',
|
|
|
|
]
|
|
|
|
|
2013-12-12 18:41:05 +04:00
|
|
|
GYP_DIRS['nICEr'].input = 'nICEr/nicer.gyp'
|
2017-05-30 19:37:29 +03:00
|
|
|
GYP_DIRS['nICEr'].variables = gyp_vars_copy
|
2015-10-20 04:05:20 +03:00
|
|
|
# We allow warnings for third-party code that can be updated from upstream.
|
2015-08-28 06:44:53 +03:00
|
|
|
GYP_DIRS['nICEr'].sandbox_vars['ALLOW_COMPILER_WARNINGS'] = True
|
2017-01-13 17:28:43 +03:00
|
|
|
GYP_DIRS['nICEr'].sandbox_vars['FINAL_LIBRARY'] = 'xul'
|
2013-12-19 21:08:31 +04:00
|
|
|
GYP_DIRS['nICEr'].non_unified_sources += nICEr_non_unified_sources
|
2013-12-12 18:41:05 +04:00
|
|
|
|
|
|
|
GYP_DIRS['nrappkit'].input = 'nrappkit/nrappkit.gyp'
|
2017-05-30 19:37:29 +03:00
|
|
|
GYP_DIRS['nrappkit'].variables = gyp_vars_copy
|
2015-10-20 04:05:20 +03:00
|
|
|
# We allow warnings for third-party code that can be updated from upstream.
|
2015-08-28 06:44:53 +03:00
|
|
|
GYP_DIRS['nrappkit'].sandbox_vars['ALLOW_COMPILER_WARNINGS'] = True
|
2017-01-13 17:28:43 +03:00
|
|
|
GYP_DIRS['nrappkit'].sandbox_vars['FINAL_LIBRARY'] = 'xul'
|
2013-12-19 21:08:31 +04:00
|
|
|
GYP_DIRS['nrappkit'].non_unified_sources += nrappkit_non_unified_sources
|