Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. | 1 # Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. |
| 2 # | 2 # |
| 3 # Use of this source code is governed by a BSD-style license | 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 | 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 | 5 # tree. An additional intellectual property rights grant can be found |
| 6 # in the file PATENTS. All contributing project authors may | 6 # in the file PATENTS. All contributing project authors may |
| 7 # be found in the AUTHORS file in the root of the source tree. | 7 # be found in the AUTHORS file in the root of the source tree. |
| 8 | 8 |
| 9 import("//build/config/linux/pkg_config.gni") | 9 import("//build/config/linux/pkg_config.gni") |
| 10 import("../webrtc.gni") | 10 import("../webrtc.gni") |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 25 | 25 |
| 26 config("rtc_media_warnings_config") { | 26 config("rtc_media_warnings_config") { |
| 27 # GN orders flags on a target before flags from configs. The default config | 27 # GN orders flags on a target before flags from configs. The default config |
| 28 # adds these flags so to cancel them out they need to come from a config and | 28 # adds these flags so to cancel them out they need to come from a config and |
| 29 # cannot be on the target directly. | 29 # cannot be on the target directly. |
| 30 if (!is_win) { | 30 if (!is_win) { |
| 31 cflags = [ "-Wno-deprecated-declarations" ] | 31 cflags = [ "-Wno-deprecated-declarations" ] |
| 32 } | 32 } |
| 33 } | 33 } |
| 34 | 34 |
| 35 rtc_static_library("rtc_media_base") { | 35 rtc_static_library("rtc_media_base_datachannel_only") { |
| 36 # TODO(kjellander): Remove (bugs.webrtc.org/6828) | 36 # TODO(kjellander): Remove (bugs.webrtc.org/6828) |
| 37 # Enabling GN check triggers cyclic dependency error: | 37 # Enabling GN check triggers cyclic dependency error: |
| 38 # //webrtc/media:rtc_media_base -> | 38 # //webrtc/media:rtc_media_base -> |
| 39 # //webrtc/pc:rtc_pc -> | 39 # //webrtc/pc:rtc_pc -> |
| 40 # //webrtc/media:media -> | 40 # //webrtc/media:media -> |
| 41 # //webrtc/media:rtc_media_base | 41 # //webrtc/media:rtc_media_base |
| 42 check_includes = false | 42 check_includes = false |
| 43 defines = [] | 43 defines = [] |
| 44 libs = [] | 44 libs = [] |
| 45 deps = [] | 45 deps = [] |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 92 "$rtc_libyuv_dir", | 92 "$rtc_libyuv_dir", |
| 93 ] | 93 ] |
| 94 } else { | 94 } else { |
| 95 # Need to add a directory normally exported by libyuv. | 95 # Need to add a directory normally exported by libyuv. |
| 96 include_dirs += [ "$rtc_libyuv_dir/include" ] | 96 include_dirs += [ "$rtc_libyuv_dir/include" ] |
| 97 } | 97 } |
| 98 | 98 |
| 99 deps += [ | 99 deps += [ |
| 100 "..:webrtc_common", | 100 "..:webrtc_common", |
| 101 "../api:libjingle_peerconnection_api", | 101 "../api:libjingle_peerconnection_api", |
| 102 "../api/audio_codecs:audio_codecs_api", | |
| 103 "../base:rtc_base", | |
| 104 "../base:rtc_base_approved", | |
| 105 "../call:call_interfaces", | |
| 106 "../p2p", | |
| 107 ] | |
| 108 | |
| 109 if (is_nacl) { | |
| 110 deps += [ "//native_client_sdk/src/libraries/nacl_io" ] | |
| 111 } | |
| 112 } | |
| 113 | |
| 114 rtc_static_library("rtc_media_base") { | |
|
kjellander_webrtc
2017/05/10 14:20:37
Can we avoid the duplication here and split out th
Zhi Huang
2017/05/10 21:00:35
Yeah, I can do it here but I need "check_includes
| |
| 115 # TODO(kjellander): Remove (bugs.webrtc.org/6828) | |
| 116 # Enabling GN check triggers cyclic dependency error: | |
| 117 # //webrtc/media:rtc_media_base -> | |
| 118 # //webrtc/pc:rtc_pc -> | |
| 119 # //webrtc/media:media -> | |
| 120 # //webrtc/media:rtc_media_base | |
| 121 check_includes = false | |
| 122 defines = [ | |
| 123 "HAVE_WEBRTC_VOICE", | |
| 124 "HAVE_WEBRTC_VIDEO", | |
| 125 ] | |
| 126 libs = [] | |
| 127 deps = [] | |
| 128 sources = [ | |
| 129 "base/adaptedvideotracksource.cc", | |
|
kjellander_webrtc
2017/05/10 14:20:37
I thought duplicating the same sources in multiple
Zhi Huang
2017/05/10 21:00:35
Yes, this is very fortunate.
But we probably wan
| |
| 130 "base/adaptedvideotracksource.h", | |
| 131 "base/audiosource.h", | |
| 132 "base/codec.cc", | |
| 133 "base/codec.h", | |
| 134 "base/cryptoparams.h", | |
| 135 "base/device.h", | |
| 136 "base/mediachannel.h", | |
| 137 "base/mediaconstants.cc", | |
| 138 "base/mediaconstants.h", | |
| 139 "base/mediaengine.cc", | |
| 140 "base/mediaengine.h", | |
| 141 "base/rtpdataengine.cc", | |
| 142 "base/rtpdataengine.h", | |
| 143 "base/rtputils.cc", | |
| 144 "base/rtputils.h", | |
| 145 "base/streamparams.cc", | |
| 146 "base/streamparams.h", | |
| 147 "base/turnutils.cc", | |
| 148 "base/turnutils.h", | |
| 149 "base/videoadapter.cc", | |
| 150 "base/videoadapter.h", | |
| 151 "base/videobroadcaster.cc", | |
| 152 "base/videobroadcaster.h", | |
| 153 "base/videocapturer.cc", | |
| 154 "base/videocapturer.h", | |
| 155 "base/videocapturerfactory.h", | |
| 156 "base/videocommon.cc", | |
| 157 "base/videocommon.h", | |
| 158 "base/videoframe.h", | |
| 159 "base/videosourcebase.cc", | |
| 160 "base/videosourcebase.h", | |
| 161 ] | |
| 162 | |
| 163 configs += [ ":rtc_media_warnings_config" ] | |
| 164 | |
| 165 if (!build_with_chromium && is_clang) { | |
| 166 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). | |
| 167 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | |
| 168 } | |
| 169 | |
| 170 include_dirs = [] | |
| 171 if (rtc_build_libyuv) { | |
| 172 deps += [ "$rtc_libyuv_dir" ] | |
| 173 public_deps = [ | |
| 174 "$rtc_libyuv_dir", | |
| 175 ] | |
| 176 } else { | |
| 177 # Need to add a directory normally exported by libyuv. | |
| 178 include_dirs += [ "$rtc_libyuv_dir/include" ] | |
| 179 } | |
| 180 | |
| 181 deps += [ | |
| 182 "..:webrtc_common", | |
| 183 "../api:libjingle_peerconnection_api", | |
| 102 "../api:video_frame_api", | 184 "../api:video_frame_api", |
| 103 "../api/audio_codecs:audio_codecs_api", | 185 "../api/audio_codecs:audio_codecs_api", |
| 104 "../api/audio_codecs:builtin_audio_encoder_factory", | 186 "../api/audio_codecs:builtin_audio_encoder_factory", |
| 105 "../base:rtc_base", | 187 "../base:rtc_base", |
| 106 "../base:rtc_base_approved", | 188 "../base:rtc_base_approved", |
| 107 "../call:call_interfaces", | 189 "../call:call_interfaces", |
| 108 "../common_video:common_video", | 190 "../common_video:common_video", |
| 109 "../p2p", | 191 "../p2p", |
| 110 ] | 192 ] |
| 111 | 193 |
| 112 if (is_nacl) { | 194 if (is_nacl) { |
| 113 deps += [ "//native_client_sdk/src/libraries/nacl_io" ] | 195 deps += [ "//native_client_sdk/src/libraries/nacl_io" ] |
| 114 } | 196 } |
| 115 } | 197 } |
| 116 | 198 |
| 199 rtc_static_library("rtc_media_datachannel_only") { | |
| 200 # TODO(kjellander): Remove (bugs.webrtc.org/6828) | |
| 201 # Enabling GN check triggers cyclic dependency error: | |
| 202 # //webrtc/media:media -> | |
| 203 # //webrtc/media:rtc_media -> | |
| 204 # //webrtc/pc:rtc_pc -> | |
| 205 # //webrtc/media:media | |
| 206 check_includes = false | |
| 207 defines = [] | |
| 208 deps = [] | |
| 209 sources = [ | |
| 210 "sctp/sctptransport.cc", | |
| 211 "sctp/sctptransport.h", | |
| 212 "sctp/sctptransportinternal.h", | |
| 213 ] | |
| 214 | |
| 215 configs += [ ":rtc_media_warnings_config" ] | |
| 216 | |
| 217 if (!build_with_chromium && is_clang) { | |
| 218 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). | |
| 219 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | |
| 220 } | |
| 221 | |
| 222 if (is_win) { | |
| 223 cflags = [ | |
| 224 "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch. | |
| 225 "/wd4267", # conversion from "size_t" to "int", possible loss of data. | |
| 226 "/wd4389", # signed/unsigned mismatch. | |
| 227 ] | |
| 228 } | |
| 229 | |
| 230 if (rtc_enable_sctp && rtc_build_usrsctp) { | |
| 231 include_dirs = [ | |
| 232 # TODO(jiayl): move this into the public_configs of | |
| 233 # //third_party/usrsctp/BUILD.gn. | |
| 234 "//third_party/usrsctp/usrsctplib", | |
| 235 ] | |
| 236 deps += [ "//third_party/usrsctp" ] | |
| 237 } | |
| 238 | |
| 239 deps += [ | |
| 240 ":rtc_media_base_datachannel_only", | |
| 241 "..:webrtc_common", | |
| 242 "../api:call_api", | |
| 243 "../api:transport_api", | |
| 244 "../base:rtc_base", | |
| 245 "../base:rtc_base_approved", | |
| 246 "../p2p:rtc_p2p", | |
| 247 "../system_wrappers", | |
| 248 ] | |
| 249 } | |
| 250 | |
| 117 rtc_static_library("rtc_media") { | 251 rtc_static_library("rtc_media") { |
| 118 # TODO(kjellander): Remove (bugs.webrtc.org/6828) | 252 # TODO(kjellander): Remove (bugs.webrtc.org/6828) |
| 119 # Enabling GN check triggers cyclic dependency error: | 253 # Enabling GN check triggers cyclic dependency error: |
| 120 # //webrtc/media:media -> | 254 # //webrtc/media:media -> |
| 121 # //webrtc/media:rtc_media -> | 255 # //webrtc/media:rtc_media -> |
| 122 # //webrtc/pc:rtc_pc -> | 256 # //webrtc/pc:rtc_pc -> |
| 123 # //webrtc/media:media | 257 # //webrtc/media:media |
| 124 check_includes = false | 258 check_includes = false |
| 125 defines = [] | 259 defines = [] |
| 126 libs = [] | 260 libs = [] |
| (...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 460 "../modules/video_coding:video_coding_utility", | 594 "../modules/video_coding:video_coding_utility", |
| 461 "../modules/video_coding:webrtc_vp8", | 595 "../modules/video_coding:webrtc_vp8", |
| 462 "../p2p:p2p_test_utils", | 596 "../p2p:p2p_test_utils", |
| 463 "../system_wrappers:metrics_default", | 597 "../system_wrappers:metrics_default", |
| 464 "../test:audio_codec_mocks", | 598 "../test:audio_codec_mocks", |
| 465 "../test:test_support", | 599 "../test:test_support", |
| 466 "../voice_engine:voice_engine", | 600 "../voice_engine:voice_engine", |
| 467 ] | 601 ] |
| 468 } | 602 } |
| 469 } | 603 } |
| OLD | NEW |