From 3ab32dc7752cbcdbfb13183486f7238b4a89363b Mon Sep 17 00:00:00 2001 From: Nico Weber Date: Tue, 2 Aug 2016 09:53:25 -0400 Subject: [PATCH] gn: Do not include "webrtc" in Chromium/iOS builds. It's not part of the gyp build either, and `ninja -C out/gnios webrtc` causes several build errors, at least in Chromium builds (which means gn/ios bots building 'all' are broken). BUG=chromium:633316 R=kjellander@webrtc.org Review URL: https://codereview.webrtc.org/2205533003 . Cr-Commit-Position: refs/heads/master@{#13609} --- webrtc/BUILD.gn | 80 +++++++++++++++++++++++++------------------------ 1 file changed, 41 insertions(+), 39 deletions(-) diff --git a/webrtc/BUILD.gn b/webrtc/BUILD.gn index 61fc48cc8f..13bac8f3ff 100644 --- a/webrtc/BUILD.gn +++ b/webrtc/BUILD.gn @@ -240,47 +240,49 @@ config("common_objc") { precompiled_source = "sdk/objc/WebRTC-Prefix.pch" } -source_set("webrtc") { - sources = [ - "call.h", - "config.h", - "transport.h", - ] - - defines = [] - configs += [ ":common_config" ] - public_configs = [ ":common_inherited_config" ] - - deps = [ - ":webrtc_common", - "audio", - "base:rtc_base", - "call", - "common_audio", - "common_video", - "modules", - "system_wrappers", - "tools", - "video", - "voice_engine", - ] - - if (build_with_chromium) { - deps += [ "modules/video_capture" ] - } else { - # TODO(kjellander): Enable for Chromium as well when bugs.webrtc.org/4256 is - # fixed. Right now it's not possible due to circular dependencies. - deps += [ - "api", - "media", - "p2p", - "pc", +if (!is_ios || !build_with_chromium) { + source_set("webrtc") { + sources = [ + "call.h", + "config.h", + "transport.h", ] - } - if (rtc_enable_protobuf) { - defines += [ "ENABLE_RTC_EVENT_LOG" ] - deps += [ ":rtc_event_log_proto" ] + defines = [] + configs += [ ":common_config" ] + public_configs = [ ":common_inherited_config" ] + + deps = [ + ":webrtc_common", + "audio", + "base:rtc_base", + "call", + "common_audio", + "common_video", + "modules", + "system_wrappers", + "tools", + "video", + "voice_engine", + ] + + if (build_with_chromium) { + deps += [ "modules/video_capture" ] + } else { + # TODO(kjellander): Enable for Chromium as well when bugs.webrtc.org/4256 + # is fixed. Right now it's not possible due to circular dependencies. + deps += [ + "api", + "media", + "p2p", + "pc", + ] + } + + if (rtc_enable_protobuf) { + defines += [ "ENABLE_RTC_EVENT_LOG" ] + deps += [ ":rtc_event_log_proto" ] + } } }