kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 1 | # Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. |
| 2 | # |
| 3 | # Use of this source code is governed by a BSD-style license |
| 4 | # that can be found in the LICENSE file in the root of the source |
| 5 | # tree. An additional intellectual property rights grant can be found |
| 6 | # in the file PATENTS. All contributing project authors may |
| 7 | # be found in the AUTHORS file in the root of the source tree. |
| 8 | |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 9 | import("//build/config/arm.gni") |
hbos | 62756ee | 2016-02-08 02:57:00 -0800 | [diff] [blame] | 10 | import("//build/config/features.gni") |
kjellander@webrtc.org | acb8085 | 2015-01-25 19:17:56 +0000 | [diff] [blame] | 11 | import("//build/config/mips.gni") |
ehmaldonado | 1dd2335 | 2016-09-02 07:03:15 -0700 | [diff] [blame] | 12 | import("//build/config/sanitizers/sanitizers.gni") |
ehmaldonado | 4016a0b | 2016-09-07 06:50:19 -0700 | [diff] [blame^] | 13 | import("//build_overrides/build.gni") |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 14 | import("//testing/test.gni") |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 15 | |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 16 | declare_args() { |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 17 | # Disable this to avoid building the Opus audio codec. |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 18 | rtc_include_opus = true |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 19 | |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 20 | # Disable to use absolute header paths for some libraries. |
| 21 | rtc_relative_path = true |
| 22 | |
kjellander@webrtc.org | e281f7f | 2014-09-02 11:22:06 +0000 | [diff] [blame] | 23 | # Used to specify an external Jsoncpp include path when not compiling the |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 24 | # library that comes with WebRTC (i.e. rtc_build_json == 0). |
| 25 | rtc_jsoncpp_root = "//third_party/jsoncpp/source/include" |
kjellander@webrtc.org | e281f7f | 2014-09-02 11:22:06 +0000 | [diff] [blame] | 26 | |
| 27 | # Used to specify an external OpenSSL include path when not compiling the |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 28 | # library that comes with WebRTC (i.e. rtc_build_ssl == 0). |
| 29 | rtc_ssl_root = "" |
kjellander@webrtc.org | e281f7f | 2014-09-02 11:22:06 +0000 | [diff] [blame] | 30 | |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 31 | # Selects fixed-point code where possible. |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 32 | rtc_prefer_fixed_point = false |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 33 | |
kjellander@webrtc.org | 78f440c | 2014-06-21 14:25:16 +0000 | [diff] [blame] | 34 | # Enable data logging. Produces text files with data logged within engines |
| 35 | # which can be easily parsed for offline processing. |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 36 | rtc_enable_data_logging = false |
kjellander@webrtc.org | 78f440c | 2014-06-21 14:25:16 +0000 | [diff] [blame] | 37 | |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 38 | # Enables the use of protocol buffers for debug recordings. |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 39 | rtc_enable_protobuf = true |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 40 | |
peah | 1bcfce5 | 2016-08-26 07:16:04 -0700 | [diff] [blame] | 41 | # Disable the code for the intelligibility enhancer by default. |
| 42 | rtc_enable_intelligibility_enhancer = false |
| 43 | |
peah | f28a389 | 2016-09-01 08:58:21 -0700 | [diff] [blame] | 44 | # Selects whether debug dumps for the audio processing module |
| 45 | # should be generated. |
| 46 | apm_debug_dump = false |
| 47 | |
kjellander@webrtc.org | 11bea89 | 2014-07-03 17:04:12 +0000 | [diff] [blame] | 48 | # Disable these to not build components which can be externally provided. |
Henrik Kjellander | e6cefb6 | 2015-04-27 14:39:04 +0200 | [diff] [blame] | 49 | rtc_build_expat = true |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 50 | rtc_build_json = true |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 51 | rtc_build_libjpeg = true |
| 52 | rtc_build_libsrtp = true |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 53 | rtc_build_libvpx = true |
kjellander | fb11424 | 2016-06-13 00:19:48 -0700 | [diff] [blame] | 54 | rtc_libvpx_build_vp9 = true |
Henrik Kjellander | e6cefb6 | 2015-04-27 14:39:04 +0200 | [diff] [blame] | 55 | rtc_build_libyuv = true |
Andrew MacDonald | 23dc68e | 2015-04-24 08:46:51 -0700 | [diff] [blame] | 56 | rtc_build_openmax_dl = true |
Henrik Kjellander | e6cefb6 | 2015-04-27 14:39:04 +0200 | [diff] [blame] | 57 | rtc_build_opus = true |
| 58 | rtc_build_ssl = true |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 59 | rtc_build_usrsctp = true |
kjellander@webrtc.org | 11bea89 | 2014-07-03 17:04:12 +0000 | [diff] [blame] | 60 | |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 61 | # Disable by default. |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 62 | rtc_have_dbus_glib = false |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 63 | |
| 64 | # Enable to use the Mozilla internal settings. |
| 65 | build_with_mozilla = false |
| 66 | |
henrika@webrtc.org | 45db7ee | 2015-01-12 14:27:23 +0000 | [diff] [blame] | 67 | rtc_enable_android_opensl = false |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 68 | |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 69 | # Link-Time Optimizations. |
| 70 | # Executes code generation at link-time instead of compile-time. |
| 71 | # https://gcc.gnu.org/wiki/LinkTimeOptimization |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 72 | rtc_use_lto = false |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 73 | |
Johan Ahlers | 9ddac18 | 2016-07-22 08:57:23 +0200 | [diff] [blame] | 74 | # Set to "func", "block", "edge" for coverage generation. |
| 75 | # At unit test runtime set UBSAN_OPTIONS="coverage=1". |
| 76 | # It is recommend to set include_examples=0. |
| 77 | # Use llvm's sancov -html-report for human readable reports. |
| 78 | # See http://clang.llvm.org/docs/SanitizerCoverage.html . |
| 79 | rtc_sanitize_coverage = "" |
| 80 | |
phoglund | ff27439 | 2016-05-17 03:44:28 -0700 | [diff] [blame] | 81 | # Enable libevent task queues on platforms that support it. |
| 82 | if (is_win || is_mac || is_ios || is_nacl) { |
| 83 | rtc_enable_libevent = false |
| 84 | rtc_build_libevent = false |
| 85 | } else { |
| 86 | rtc_enable_libevent = true |
| 87 | rtc_build_libevent = true |
| 88 | } |
| 89 | |
pkotwicz | a75339c | 2016-02-10 10:21:07 -0800 | [diff] [blame] | 90 | if (current_cpu == "arm" || current_cpu == "arm64") { |
kjellander@webrtc.org | 6d08ca6 | 2014-09-07 17:36:10 +0000 | [diff] [blame] | 91 | rtc_prefer_fixed_point = true |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 92 | } |
kjellander@webrtc.org | 524b8f7 | 2014-08-31 20:32:53 +0000 | [diff] [blame] | 93 | |
Gordana.Cmiljanovic | caea17a | 2016-06-01 00:53:36 -0700 | [diff] [blame] | 94 | if (!is_ios && (current_cpu != "arm" || arm_version >= 7) && |
| 95 | current_cpu != "mips64el") { |
andrew@webrtc.org | 4165f7a | 2014-10-08 18:01:27 +0000 | [diff] [blame] | 96 | rtc_use_openmax_dl = true |
| 97 | } else { |
| 98 | rtc_use_openmax_dl = false |
| 99 | } |
| 100 | |
Andrew MacDonald | ac4234c | 2015-06-24 18:25:54 -0700 | [diff] [blame] | 101 | # Determines whether NEON code will be built. |
petermayo | 50cf10d | 2015-07-09 09:45:04 -0700 | [diff] [blame] | 102 | rtc_build_with_neon = |
pasko | e305d95 | 2016-05-17 10:56:40 -0700 | [diff] [blame] | 103 | (current_cpu == "arm" && arm_use_neon) || current_cpu == "arm64" |
Zeke Chin | 71f6f44 | 2015-06-29 14:34:58 -0700 | [diff] [blame] | 104 | |
| 105 | # Enable this to use HW H.264 encoder/decoder on iOS PeerConnections. |
| 106 | # Enabling this may break interop with Android clients that support H264. |
| 107 | rtc_use_objc_h264 = false |
hbos | a9a1d2a | 2016-01-11 10:19:02 -0800 | [diff] [blame] | 108 | |
hbos | 902c03e | 2016-01-21 03:34:40 -0800 | [diff] [blame] | 109 | # Enable this to build OpenH264 encoder/FFmpeg decoder. This is supported on |
hbos | 62756ee | 2016-02-08 02:57:00 -0800 | [diff] [blame] | 110 | # all platforms except Android and iOS. Because FFmpeg can be built |
| 111 | # with/without H.264 support, |ffmpeg_branding| has to separately be set to a |
| 112 | # value that includes H.264, for example "Chrome". If FFmpeg is built without |
| 113 | # H.264, compilation succeeds but |H264DecoderImpl| fails to initialize. See |
| 114 | # also: |rtc_initialize_ffmpeg|. |
hbos | a9a1d2a | 2016-01-11 10:19:02 -0800 | [diff] [blame] | 115 | # CHECK THE OPENH264, FFMPEG AND H.264 LICENSES/PATENTS BEFORE BUILDING. |
| 116 | # http://www.openh264.org, https://www.ffmpeg.org/ |
hbos | 62756ee | 2016-02-08 02:57:00 -0800 | [diff] [blame] | 117 | rtc_use_h264 = proprietary_codecs && !is_android && !is_ios |
hbos | c5a39c2 | 2016-02-02 02:26:05 -0800 | [diff] [blame] | 118 | |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 119 | # Determines whether QUIC code will be built. |
| 120 | rtc_use_quic = false |
| 121 | |
noahric | c594aa61 | 2016-08-16 18:21:18 -0700 | [diff] [blame] | 122 | # By default, use normal platform audio support or dummy audio, but don't |
| 123 | # use file-based audio playout and record. |
| 124 | rtc_use_dummy_audio_file_devices = false |
| 125 | |
hbos | c5a39c2 | 2016-02-02 02:26:05 -0800 | [diff] [blame] | 126 | # FFmpeg must be initialized for |H264DecoderImpl| to work. This can be done |
| 127 | # by WebRTC during |H264DecoderImpl::InitDecode| or externally. FFmpeg must |
| 128 | # only be initialized once. Projects that initialize FFmpeg externally, such |
| 129 | # as Chromium, must turn this flag off so that WebRTC does not also |
| 130 | # initialize. |
| 131 | rtc_initialize_ffmpeg = !build_with_chromium |
kjellander | c76dc95 | 2016-06-03 03:09:32 -0700 | [diff] [blame] | 132 | |
| 133 | # Build sources requiring GTK. NOTICE: This is not present in Chrome OS |
| 134 | # build environments, even if available for Chromium builds. |
| 135 | rtc_use_gtk = !build_with_chromium |
kjellander@webrtc.org | 851a09e | 2014-06-17 08:54:03 +0000 | [diff] [blame] | 136 | } |
kjellander@webrtc.org | ce22f13 | 2015-02-16 12:47:20 +0000 | [diff] [blame] | 137 | |
kwiberg | f8c2bac | 2016-01-18 06:38:32 -0800 | [diff] [blame] | 138 | # A second declare_args block, so that declarations within it can |
| 139 | # depend on the possibly overridden variables in the first |
| 140 | # declare_args block. |
| 141 | declare_args() { |
| 142 | # Include the iLBC audio codec? |
| 143 | rtc_include_ilbc = !(build_with_chromium || build_with_mozilla) |
ehmaldonado | edaa4a4 | 2016-09-06 02:27:47 -0700 | [diff] [blame] | 144 | |
| 145 | rtc_restrict_logging = build_with_chromium |
ehmaldonado | 4016a0b | 2016-09-07 06:50:19 -0700 | [diff] [blame^] | 146 | |
| 147 | # Excluded in Chromium since its prerequisites don't require Pulse Audio. |
| 148 | rtc_include_pulse_audio = !build_with_chromium |
| 149 | |
| 150 | # Chromium uses its own IO handling, so the internal ADM is only built for |
| 151 | # standalone WebRTC. |
| 152 | rtc_include_internal_audio_device = !build_with_chromium |
| 153 | |
| 154 | # Include tests in standalone checkout. |
| 155 | rtc_include_tests = !build_with_chromium |
kwiberg | f8c2bac | 2016-01-18 06:38:32 -0800 | [diff] [blame] | 156 | } |
| 157 | |
kjellander@webrtc.org | ce22f13 | 2015-02-16 12:47:20 +0000 | [diff] [blame] | 158 | # Make it possible to provide custom locations for some libraries (move these |
| 159 | # up into declare_args should we need to actually use them for the GN build). |
kjellander | e26e787 | 2016-03-04 14:39:28 -0800 | [diff] [blame] | 160 | rtc_libvpx_dir = "//third_party/libvpx" |
kjellander@webrtc.org | ce22f13 | 2015-02-16 12:47:20 +0000 | [diff] [blame] | 161 | rtc_libyuv_dir = "//third_party/libyuv" |
| 162 | rtc_opus_dir = "//third_party/opus" |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 163 | |
| 164 | ############################################################################### |
| 165 | # Templates |
| 166 | # |
| 167 | |
| 168 | # Points to //webrtc/ in webrtc stand-alone or to //third_party/webrtc/ in |
| 169 | # chromium. |
| 170 | # We need absolute paths for all configs in templates as they are shared in |
| 171 | # different subdirectories. |
| 172 | webrtc_root = get_path_info("../", "abspath") |
| 173 | |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 174 | # Global configuration that should be applied to all WebRTC targets. |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 175 | # You normally shouldn't need to include this in your target as it's |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 176 | # automatically included when using the rtc_* templates. |
| 177 | # It sets defines, include paths and compilation warnings accordingly, |
| 178 | # both for WebRTC stand-alone builds and for the scenario when WebRTC |
| 179 | # native code is built as part of Chromium. |
| 180 | rtc_common_config = webrtc_root + ":common_config" |
| 181 | |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 182 | # Global public configuration that should be applied to all WebRTC targets. You |
| 183 | # normally shouldn't need to include this in your target as it's automatically |
| 184 | # included when using the rtc_* templates. It set the defines, include paths and |
| 185 | # compilation warnings that should be propagated to dependents of the targets |
| 186 | # depending on the target having this config. |
| 187 | rtc_common_inherited_config = webrtc_root + ":common_inherited_config" |
| 188 | |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 189 | # Common configs to remove or add in all rtc targets. |
| 190 | rtc_remove_configs = [] |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 191 | rtc_add_configs = [ rtc_common_config ] |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 192 | |
ehmaldonado | f71d298 | 2016-09-05 10:03:57 -0700 | [diff] [blame] | 193 | if (!is_debug && is_win) { |
ehmaldonado | 59af8b7 | 2016-09-05 02:48:54 -0700 | [diff] [blame] | 194 | rtc_remove_configs += [ "//build/config/compiler:default_optimization" ] |
| 195 | rtc_add_configs += [ "//build/config/compiler:optimize_max" ] |
| 196 | } |
| 197 | |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 198 | set_defaults("rtc_test") { |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 199 | configs = rtc_add_configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 200 | suppressed_configs = [] |
| 201 | } |
| 202 | |
| 203 | set_defaults("rtc_source_set") { |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 204 | configs = rtc_add_configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 205 | suppressed_configs = [] |
| 206 | } |
| 207 | |
| 208 | set_defaults("rtc_executable") { |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 209 | configs = rtc_add_configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 210 | suppressed_configs = [] |
| 211 | } |
| 212 | |
| 213 | set_defaults("rtc_static_library") { |
ehmaldonado | 7a2ce0b | 2016-09-05 01:35:44 -0700 | [diff] [blame] | 214 | configs = rtc_add_configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 215 | suppressed_configs = [] |
| 216 | } |
| 217 | |
| 218 | template("rtc_test") { |
| 219 | test(target_name) { |
| 220 | forward_variables_from(invoker, |
| 221 | "*", |
| 222 | [ |
| 223 | "configs", |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 224 | "public_configs", |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 225 | "suppressed_configs", |
| 226 | ]) |
| 227 | configs += invoker.configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 228 | configs -= rtc_remove_configs |
| 229 | configs -= invoker.suppressed_configs |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 230 | public_configs = [ rtc_common_inherited_config ] |
| 231 | if (defined(invoker.public_configs)) { |
| 232 | public_configs += invoker.public_configs |
| 233 | } |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 234 | } |
| 235 | } |
| 236 | |
| 237 | template("rtc_source_set") { |
| 238 | source_set(target_name) { |
| 239 | forward_variables_from(invoker, |
| 240 | "*", |
| 241 | [ |
| 242 | "configs", |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 243 | "public_configs", |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 244 | "suppressed_configs", |
| 245 | ]) |
| 246 | configs += invoker.configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 247 | configs -= rtc_remove_configs |
| 248 | configs -= invoker.suppressed_configs |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 249 | public_configs = [ rtc_common_inherited_config ] |
| 250 | if (defined(invoker.public_configs)) { |
| 251 | public_configs += invoker.public_configs |
| 252 | } |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 253 | } |
| 254 | } |
| 255 | |
| 256 | template("rtc_executable") { |
| 257 | executable(target_name) { |
| 258 | forward_variables_from(invoker, |
| 259 | "*", |
| 260 | [ |
ehmaldonado | 1dd2335 | 2016-09-02 07:03:15 -0700 | [diff] [blame] | 261 | "deps", |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 262 | "configs", |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 263 | "public_configs", |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 264 | "suppressed_configs", |
| 265 | ]) |
| 266 | configs += invoker.configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 267 | configs -= rtc_remove_configs |
| 268 | configs -= invoker.suppressed_configs |
ehmaldonado | 1dd2335 | 2016-09-02 07:03:15 -0700 | [diff] [blame] | 269 | deps = [ |
| 270 | "//build/config/sanitizers:deps", |
| 271 | ] |
| 272 | deps += invoker.deps |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 273 | public_configs = [ rtc_common_inherited_config ] |
| 274 | if (defined(invoker.public_configs)) { |
| 275 | public_configs += invoker.public_configs |
| 276 | } |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 277 | } |
| 278 | } |
| 279 | |
| 280 | template("rtc_static_library") { |
| 281 | static_library(target_name) { |
| 282 | forward_variables_from(invoker, |
| 283 | "*", |
| 284 | [ |
| 285 | "configs", |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 286 | "public_configs", |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 287 | "suppressed_configs", |
| 288 | ]) |
| 289 | configs += invoker.configs |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 290 | configs -= rtc_remove_configs |
| 291 | configs -= invoker.suppressed_configs |
ehmaldonado | e9cc686 | 2016-09-05 06:10:18 -0700 | [diff] [blame] | 292 | public_configs = [ rtc_common_inherited_config ] |
| 293 | if (defined(invoker.public_configs)) { |
| 294 | public_configs += invoker.public_configs |
| 295 | } |
ehmaldonado | 38a2132 | 2016-09-02 04:10:34 -0700 | [diff] [blame] | 296 | } |
| 297 | } |