tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 1 | # Copyright 2016 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 | |
mbonadei | 9aa3f0a | 2017-01-24 06:58:22 -0800 | [diff] [blame] | 9 | import("../webrtc.gni") |
kthelgason | ebc34e7 | 2016-09-15 04:30:18 -0700 | [diff] [blame] | 10 | if (is_ios) { |
| 11 | import("//build/config/ios/rules.gni") |
oprypin | 4519752 | 2017-06-22 01:47:20 -0700 | [diff] [blame] | 12 | import("//build/config/ios/ios_sdk.gni") |
kthelgason | ebc34e7 | 2016-09-15 04:30:18 -0700 | [diff] [blame] | 13 | } |
tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 14 | |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 15 | declare_args() { |
| 16 | # Determine whether or not to include metal rendering |
| 17 | rtc_use_metal_rendering = is_mac || (is_ios && current_cpu == "arm64") |
| 18 | } |
| 19 | |
kjellander | 6ceab08 | 2016-10-28 05:44:03 -0700 | [diff] [blame] | 20 | group("sdk") { |
Henrik Kjellander | a7d0df7 | 2017-06-27 08:56:46 +0200 | [diff] [blame] | 21 | public_deps = [] |
| 22 | if (!build_with_chromium) { |
| 23 | if (is_android) { |
| 24 | public_deps += [ "android" ] |
| 25 | } |
| 26 | if (is_ios) { |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 27 | public_deps += [ ":framework_objc" ] |
Henrik Kjellander | a7d0df7 | 2017-06-27 08:56:46 +0200 | [diff] [blame] | 28 | } |
kjellander | 6ceab08 | 2016-10-28 05:44:03 -0700 | [diff] [blame] | 29 | } |
| 30 | } |
| 31 | |
kthelgason | cc2d1c6 | 2016-11-09 07:44:27 -0800 | [diff] [blame] | 32 | if (is_ios || is_mac) { |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 33 | config("common_config_objc") { |
kjellander | 080a1e3 | 2016-05-25 11:37:11 -0700 | [diff] [blame] | 34 | include_dirs = [ |
| 35 | "objc/Framework/Classes", |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 36 | "objc/Framework/Classes/Audio", |
| 37 | "objc/Framework/Classes/Common", |
| 38 | "objc/Framework/Classes/Metal", |
| 39 | "objc/Framework/Classes/PeerConnection", |
| 40 | "objc/Framework/Classes/UI", |
| 41 | "objc/Framework/Classes/Video", |
| 42 | "objc/Framework/Classes/VideoToolbox", |
kjellander | 080a1e3 | 2016-05-25 11:37:11 -0700 | [diff] [blame] | 43 | "objc/Framework/Headers", |
| 44 | ] |
Kári Tristan Helgason | 47d3a01 | 2017-10-24 15:28:51 +0200 | [diff] [blame] | 45 | cflags = [ |
| 46 | "-Wstrict-overflow", |
| 47 | "-Wmissing-field-initializers", |
| 48 | ] |
kjellander | 080a1e3 | 2016-05-25 11:37:11 -0700 | [diff] [blame] | 49 | } |
| 50 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 51 | rtc_static_library("common_objc") { |
tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 52 | sources = [ |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 53 | "objc/Framework/Classes/Common/NSString+StdString.h", |
| 54 | "objc/Framework/Classes/Common/NSString+StdString.mm", |
| 55 | "objc/Framework/Classes/Common/RTCDispatcher+Private.h", |
| 56 | "objc/Framework/Classes/Common/RTCDispatcher.m", |
| 57 | "objc/Framework/Classes/Common/RTCFieldTrials.mm", |
| 58 | "objc/Framework/Classes/Common/RTCLogging.mm", |
Anders Carlsson | fc30975 | 2017-06-12 14:16:20 +0200 | [diff] [blame] | 59 | "objc/Framework/Classes/Common/RTCUIApplicationStatusObserver.h", |
| 60 | "objc/Framework/Classes/Common/RTCUIApplicationStatusObserver.m", |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 61 | "objc/Framework/Classes/Common/helpers.h", |
| 62 | "objc/Framework/Classes/Common/helpers.mm", |
Kári Tristan Helgason | a17ddcd | 2017-09-28 19:28:52 +0200 | [diff] [blame] | 63 | "objc/Framework/Classes/Common/scoped_cftyperef.h", |
tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 64 | "objc/Framework/Headers/WebRTC/RTCDispatcher.h", |
| 65 | "objc/Framework/Headers/WebRTC/RTCFieldTrials.h", |
| 66 | "objc/Framework/Headers/WebRTC/RTCLogging.h", |
| 67 | "objc/Framework/Headers/WebRTC/RTCMacros.h", |
tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 68 | ] |
denicija | d208815 | 2017-04-28 02:14:54 -0700 | [diff] [blame] | 69 | |
mbonadei | 1e060c6 | 2017-04-21 00:02:02 -0700 | [diff] [blame] | 70 | deps = [ |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 71 | "../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 72 | "../rtc_base:rtc_base", |
mbonadei | 1e060c6 | 2017-04-21 00:02:02 -0700 | [diff] [blame] | 73 | ] |
kthelgason | c097710 | 2017-04-24 00:57:16 -0700 | [diff] [blame] | 74 | configs += [ "..:common_objc" ] |
| 75 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 76 | public_configs = [ ":common_config_objc" ] |
denicija | d208815 | 2017-04-28 02:14:54 -0700 | [diff] [blame] | 77 | |
kjellander | 3bcedd3 | 2016-06-08 01:14:15 -0700 | [diff] [blame] | 78 | if (is_ios) { |
| 79 | sources += [ |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 80 | "objc/Framework/Classes/Common/UIDevice+RTCDevice.mm", |
tkchin | d762910 | 2016-07-28 14:52:55 -0700 | [diff] [blame] | 81 | "objc/Framework/Headers/WebRTC/UIDevice+RTCDevice.h", |
kjellander | 3bcedd3 | 2016-06-08 01:14:15 -0700 | [diff] [blame] | 82 | ] |
denicija | d208815 | 2017-04-28 02:14:54 -0700 | [diff] [blame] | 83 | } |
| 84 | |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 85 | if (!build_with_chromium) { |
denicija | d208815 | 2017-04-28 02:14:54 -0700 | [diff] [blame] | 86 | sources += [ |
Anders Carlsson | 3b3364e | 2018-01-30 15:46:13 +0100 | [diff] [blame] | 87 | "objc/Framework/Classes/Common/RTCCallbackLogger.mm", |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 88 | "objc/Framework/Classes/Common/RTCFileLogger.mm", |
Anders Carlsson | 3b3364e | 2018-01-30 15:46:13 +0100 | [diff] [blame] | 89 | "objc/Framework/Headers/WebRTC/RTCCallbackLogger.h", |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 90 | "objc/Framework/Headers/WebRTC/RTCFileLogger.h", |
| 91 | ] |
| 92 | } |
| 93 | } |
| 94 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 95 | if (!build_with_chromium) { |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 96 | if (is_ios) { |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 97 | rtc_static_library("native_api_audio_device_module") { |
| 98 | visibility = [ "*" ] |
| 99 | |
| 100 | sources = [ |
| 101 | "objc/Framework/Native/api/audio_device_module.h", |
| 102 | "objc/Framework/Native/api/audio_device_module.mm", |
| 103 | ] |
| 104 | |
| 105 | deps = [ |
| 106 | ":audio_device", |
| 107 | "../modules/audio_device:audio_device_api", |
| 108 | "../modules/audio_device:audio_device_generic", |
| 109 | "../rtc_base:checks", |
| 110 | "../rtc_base:rtc_base_approved", |
| 111 | "../system_wrappers", |
| 112 | "../system_wrappers:metrics_api", |
| 113 | ] |
| 114 | |
| 115 | if (is_clang) { |
| 116 | # Suppress warnings from the Chromium Clang plugin |
| 117 | # (bugs.webrtc.org/163). |
| 118 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 119 | } |
| 120 | } |
| 121 | |
| 122 | rtc_source_set("audio_session_observer") { |
| 123 | visibility = [ ":*" ] |
| 124 | |
| 125 | sources = [ |
| 126 | "objc/Framework/Native/src/audio/audio_session_observer.h", |
| 127 | ] |
| 128 | |
| 129 | deps = [ |
| 130 | "../rtc_base:rtc_base", |
| 131 | ] |
| 132 | } |
| 133 | |
| 134 | rtc_static_library("audio_device") { |
| 135 | visibility = [ "*" ] |
| 136 | |
| 137 | sources = [ |
| 138 | "objc/Framework/Native/src/audio/audio_device_ios.h", |
| 139 | "objc/Framework/Native/src/audio/audio_device_ios.mm", |
| 140 | "objc/Framework/Native/src/audio/audio_device_module_ios.h", |
| 141 | "objc/Framework/Native/src/audio/audio_device_module_ios.mm", |
| 142 | "objc/Framework/Native/src/audio/voice_processing_audio_unit.h", |
| 143 | "objc/Framework/Native/src/audio/voice_processing_audio_unit.mm", |
| 144 | ] |
| 145 | |
| 146 | deps = [ |
| 147 | ":audio_objc", |
| 148 | ":audio_session_observer", |
| 149 | ":common_objc", |
| 150 | "../api:array_view", |
| 151 | "../modules/audio_device:audio_device_api", |
| 152 | "../modules/audio_device:audio_device_buffer", |
| 153 | "../modules/audio_device:audio_device_generic", |
| 154 | "../rtc_base:checks", |
| 155 | "../rtc_base:rtc_base", |
| 156 | "../rtc_base/system:fallthrough", |
| 157 | "../sdk:common_objc", |
| 158 | "../system_wrappers:metrics_api", |
| 159 | ] |
| 160 | |
| 161 | if (is_clang) { |
| 162 | # Suppress warnings from the Chromium Clang plugin |
| 163 | # (bugs.webrtc.org/163). |
| 164 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 165 | } |
| 166 | } |
| 167 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 168 | rtc_static_library("audio_objc") { |
| 169 | sources = [ |
| 170 | "objc/Framework/Classes/Audio/RTCAudioSession+Configuration.mm", |
| 171 | "objc/Framework/Classes/Audio/RTCAudioSession+Private.h", |
| 172 | "objc/Framework/Classes/Audio/RTCAudioSession.mm", |
| 173 | "objc/Framework/Classes/Audio/RTCAudioSessionConfiguration.m", |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 174 | "objc/Framework/Classes/Audio/RTCNativeAudioSessionDelegateAdapter.h", |
| 175 | "objc/Framework/Classes/Audio/RTCNativeAudioSessionDelegateAdapter.mm", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 176 | "objc/Framework/Headers/WebRTC/RTCAudioSession.h", |
| 177 | "objc/Framework/Headers/WebRTC/RTCAudioSessionConfiguration.h", |
| 178 | ] |
| 179 | configs += [ "..:common_objc" ] |
denicija | 59ee91b | 2017-06-05 05:48:47 -0700 | [diff] [blame] | 180 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 181 | public_configs = [ ":common_config_objc" ] |
Anders Carlsson | 8ecfd80 | 2017-09-15 14:07:30 +0200 | [diff] [blame] | 182 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 183 | deps = [ |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 184 | ":audio_session_observer", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 185 | ":common_objc", |
| 186 | "../rtc_base:checks", |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 187 | "../rtc_base:rtc_base", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 188 | "../rtc_base:rtc_base_approved", |
| 189 | ] |
denicija | 59ee91b | 2017-06-05 05:48:47 -0700 | [diff] [blame] | 190 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 191 | if (is_clang) { |
| 192 | # Suppress warnings from the Chromium Clang plugin |
| 193 | # (bugs.webrtc.org/163). |
| 194 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 195 | } |
denicija | 59ee91b | 2017-06-05 05:48:47 -0700 | [diff] [blame] | 196 | } |
| 197 | } |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 198 | |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 199 | rtc_static_library("videosource_objc") { |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 200 | sources = [ |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 201 | "objc/Framework/Classes/PeerConnection/RTCVideoSource+Private.h", |
| 202 | "objc/Framework/Classes/PeerConnection/RTCVideoSource.mm", |
| 203 | "objc/Framework/Headers/WebRTC/RTCVideoSource.h", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 204 | ] |
| 205 | |
| 206 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 207 | ":common_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 208 | ":mediasource_objc", |
| 209 | ":native_video", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 210 | ":videoframebuffer_objc", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 211 | "../api:libjingle_peerconnection_api", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 212 | "../api/video:video_frame", |
| 213 | "../api/video:video_frame_i420", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 214 | "../common_video", |
| 215 | "../media:rtc_media_base", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 216 | "../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 217 | "../rtc_base:rtc_base", |
Mirko Bonadei | 401d056 | 2017-12-14 11:24:00 +0100 | [diff] [blame] | 218 | "//third_party/libyuv", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 219 | ] |
| 220 | |
| 221 | configs += [ "..:common_objc" ] |
| 222 | if (!build_with_chromium && is_clang) { |
| 223 | # Suppress warnings from the Chromium Clang plugin |
| 224 | # (bugs.webrtc.org/163). |
| 225 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 226 | } |
| 227 | } |
| 228 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 229 | rtc_static_library("videoframebuffer_objc") { |
| 230 | sources = [ |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 231 | "objc/Framework/Classes/PeerConnection/RTCVideoFrame.mm", |
| 232 | "objc/Framework/Classes/Video/RTCCVPixelBuffer.mm", |
| 233 | "objc/Framework/Classes/Video/RTCI420Buffer+Private.h", |
| 234 | "objc/Framework/Classes/Video/RTCI420Buffer.mm", |
| 235 | "objc/Framework/Headers/WebRTC/RTCVideoFrame.h", |
| 236 | "objc/Framework/Headers/WebRTC/RTCVideoFrameBuffer.h", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 237 | ] |
| 238 | deps = [ |
| 239 | ":common_objc", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 240 | "//api/video:video_frame", |
| 241 | "//api/video:video_frame_i420", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 242 | "//common_video", |
| 243 | "//rtc_base:checks", |
| 244 | "//rtc_base:rtc_base_approved", |
| 245 | "//third_party/libyuv", |
| 246 | ] |
| 247 | configs += [ "..:common_objc" ] |
| 248 | } |
| 249 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 250 | rtc_static_library("video_objc") { |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 251 | sources = [ |
jtteh | 3b673c6 | 2017-07-25 15:48:39 -0700 | [diff] [blame] | 252 | "objc/Framework/Classes/Video/AVCaptureSession+DevicePosition.h", |
| 253 | "objc/Framework/Classes/Video/AVCaptureSession+DevicePosition.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 254 | "objc/Framework/Classes/Video/RTCDefaultShader.h", |
| 255 | "objc/Framework/Classes/Video/RTCDefaultShader.mm", |
| 256 | "objc/Framework/Classes/Video/RTCI420TextureCache.h", |
| 257 | "objc/Framework/Classes/Video/RTCI420TextureCache.mm", |
| 258 | "objc/Framework/Classes/Video/RTCOpenGLDefines.h", |
| 259 | "objc/Framework/Classes/Video/RTCShader.h", |
| 260 | "objc/Framework/Classes/Video/RTCShader.mm", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 261 | "objc/Framework/Headers/WebRTC/RTCVideoViewShading.h", |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 262 | ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 263 | libs = [] |
denicija | d208815 | 2017-04-28 02:14:54 -0700 | [diff] [blame] | 264 | if (is_ios) { |
denicija | 070d5e3 | 2017-02-26 11:44:13 -0800 | [diff] [blame] | 265 | sources += [ |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 266 | "objc/Framework/Classes/Video/RTCNV12TextureCache.h", |
| 267 | "objc/Framework/Classes/Video/RTCNV12TextureCache.m", |
| 268 | ] |
| 269 | libs += [ |
| 270 | "GLKit.framework", |
| 271 | "OpenGLES.framework", |
| 272 | "QuartzCore.framework", |
| 273 | ] |
| 274 | } else if (is_mac) { |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 275 | libs += [ |
| 276 | "CoreMedia.framework", |
| 277 | "CoreVideo.framework", |
| 278 | "OpenGL.framework", |
denicija | 070d5e3 | 2017-02-26 11:44:13 -0800 | [diff] [blame] | 279 | ] |
| 280 | } |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 281 | |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 282 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 283 | ":common_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 284 | ":mediaconstraints_objc", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 285 | ":native_video", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 286 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 287 | ":videosource_objc", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 288 | "../api:libjingle_peerconnection_api", |
kwiberg | 84f6a3f | 2017-09-05 08:43:13 -0700 | [diff] [blame] | 289 | "../api:optional", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 290 | "../api/video:video_frame", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 291 | "../common_video", |
| 292 | "../media:rtc_media_base", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 293 | "../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 294 | "../rtc_base:rtc_base", |
tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 295 | ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 296 | |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 297 | configs += [ "..:common_objc" ] |
ehmaldonado | da8dcfb | 2017-01-04 07:11:23 -0800 | [diff] [blame] | 298 | if (!build_with_chromium && is_clang) { |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 299 | # Suppress warnings from the Chromium Clang plugin |
| 300 | # (bugs.webrtc.org/163). |
ehmaldonado | da8dcfb | 2017-01-04 07:11:23 -0800 | [diff] [blame] | 301 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 302 | } |
| 303 | } |
ehmaldonado | da8dcfb | 2017-01-04 07:11:23 -0800 | [diff] [blame] | 304 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 305 | rtc_static_library("ui_objc") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 306 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 307 | allow_poison = [ |
| 308 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 309 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 310 | ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 311 | if (is_ios) { |
| 312 | sources = [ |
| 313 | "objc/Framework/Classes/UI/RTCCameraPreviewView.m", |
| 314 | "objc/Framework/Classes/UI/RTCEAGLVideoView.m", |
| 315 | "objc/Framework/Headers/WebRTC/RTCCameraPreviewView.h", |
| 316 | "objc/Framework/Headers/WebRTC/RTCEAGLVideoView.h", |
| 317 | ] |
| 318 | } |
| 319 | if (is_mac) { |
| 320 | sources = [ |
| 321 | "objc/Framework/Classes/UI/RTCNSGLVideoView.m", |
| 322 | "objc/Framework/Headers/WebRTC/RTCNSGLVideoView.h", |
| 323 | ] |
| 324 | } |
| 325 | configs += [ "..:common_objc" ] |
| 326 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 327 | ":common_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 328 | ":video_objc", |
| 329 | ":videocapture_objc", |
| 330 | ":videoframebuffer_objc", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 331 | ] |
| 332 | } |
kthelgason | ebc34e7 | 2016-09-15 04:30:18 -0700 | [diff] [blame] | 333 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 334 | if (rtc_use_metal_rendering) { |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 335 | rtc_static_library("metal_objc") { |
Mirko Bonadei | d68956d | 2018-02-16 17:55:36 +0100 | [diff] [blame] | 336 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 337 | allow_poison = [ |
| 338 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 339 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 340 | ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 341 | sources = [ |
| 342 | "objc/Framework/Classes/Metal/RTCMTLI420Renderer.h", |
| 343 | "objc/Framework/Classes/Metal/RTCMTLI420Renderer.mm", |
| 344 | "objc/Framework/Classes/Metal/RTCMTLRenderer+Private.h", |
| 345 | "objc/Framework/Classes/Metal/RTCMTLRenderer.h", |
| 346 | "objc/Framework/Classes/Metal/RTCMTLRenderer.mm", |
| 347 | ] |
| 348 | if (is_ios) { |
| 349 | sources += [ |
| 350 | "objc/Framework/Classes/Metal/RTCMTLNV12Renderer.h", |
| 351 | "objc/Framework/Classes/Metal/RTCMTLNV12Renderer.mm", |
Peter Hanspers | 1c62b98 | 2018-05-03 14:06:04 +0200 | [diff] [blame] | 352 | "objc/Framework/Classes/Metal/RTCMTLRGBRenderer.h", |
| 353 | "objc/Framework/Classes/Metal/RTCMTLRGBRenderer.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 354 | "objc/Framework/Classes/Metal/RTCMTLVideoView.m", |
| 355 | "objc/Framework/Headers/WebRTC/RTCMTLVideoView.h", |
| 356 | ] |
| 357 | } |
| 358 | if (is_mac) { |
| 359 | sources += [ |
| 360 | "objc/Framework/Classes/Metal/RTCMTLNSVideoView.m", |
| 361 | "objc/Framework/Headers/WebRTC/RTCMTLNSVideoView.h", |
| 362 | ] |
| 363 | } |
| 364 | libs = [ |
| 365 | "CoreVideo.framework", |
| 366 | "Metal.framework", |
| 367 | "MetalKit.framework", |
| 368 | ] |
| 369 | deps = [ |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 370 | ":common_objc", |
| 371 | ":peerconnectionfactory_base_objc", |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 372 | ":video_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 373 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 374 | ":videorenderer_objc", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 375 | "../api/video:video_frame", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 376 | "../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 377 | "../rtc_base:rtc_base_approved", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 378 | ] |
| 379 | configs += [ "..:common_objc" ] |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 380 | public_configs = [ ":common_config_objc" ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 381 | } |
| 382 | } |
| 383 | |
Anders Carlsson | 7311918 | 2018-03-15 09:41:03 +0100 | [diff] [blame] | 384 | rtc_static_library("videocapturebase_objc") { |
| 385 | visibility = [ "*" ] |
| 386 | sources = [ |
| 387 | "objc/Framework/Classes/PeerConnection/RTCVideoCapturer.m", |
| 388 | "objc/Framework/Headers/WebRTC/RTCVideoCapturer.h", |
| 389 | ] |
| 390 | libs = [ "AVFoundation.framework" ] |
| 391 | |
| 392 | configs += [ "..:common_objc" ] |
| 393 | |
| 394 | public_configs = [ ":common_config_objc" ] |
| 395 | |
| 396 | deps = [ |
| 397 | ":common_objc", |
| 398 | ":videoframebuffer_objc", |
| 399 | ] |
| 400 | } |
| 401 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 402 | rtc_static_library("videocapture_objc") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 403 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 404 | allow_poison = [ |
| 405 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 406 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 407 | ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 408 | sources = [ |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 409 | "objc/Framework/Classes/PeerConnection/RTCCameraVideoCapturer.m", |
| 410 | "objc/Framework/Headers/WebRTC/RTCCameraVideoCapturer.h", |
| 411 | ] |
| 412 | if (is_ios) { |
| 413 | sources += [ |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 414 | "objc/Framework/Classes/PeerConnection/RTCFileVideoCapturer.m", |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 415 | "objc/Framework/Headers/WebRTC/RTCFileVideoCapturer.h", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 416 | ] |
| 417 | } |
| 418 | libs = [ "AVFoundation.framework" ] |
| 419 | |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 420 | configs += [ "..:common_objc" ] |
| 421 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 422 | public_configs = [ ":common_config_objc" ] |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 423 | |
| 424 | if (!build_with_chromium && is_clang) { |
| 425 | # Suppress warnings from the Chromium Clang plugin |
| 426 | # (bugs.webrtc.org/163). |
| 427 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 428 | } |
| 429 | |
| 430 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 431 | ":common_objc", |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 432 | ":video_objc", |
Anders Carlsson | 7311918 | 2018-03-15 09:41:03 +0100 | [diff] [blame] | 433 | ":videocapturebase_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 434 | ":videoframebuffer_objc", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 435 | ] |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 436 | } |
| 437 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 438 | rtc_static_library("videocodec_objc") { |
Karl Wiberg | bb23c83 | 2018-04-22 19:55:00 +0200 | [diff] [blame] | 439 | visibility = [ "*" ] |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 440 | sources = [ |
| 441 | "objc/Framework/Classes/PeerConnection/RTCEncodedImage.mm", |
| 442 | "objc/Framework/Classes/PeerConnection/RTCRtpFragmentationHeader.mm", |
| 443 | "objc/Framework/Classes/PeerConnection/RTCVideoCodec+Private.h", |
| 444 | "objc/Framework/Classes/PeerConnection/RTCVideoCodec.mm", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 445 | "objc/Framework/Classes/PeerConnection/RTCVideoCodecH264.mm", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 446 | "objc/Framework/Classes/PeerConnection/RTCVideoEncoderSettings.mm", |
| 447 | "objc/Framework/Headers/WebRTC/RTCVideoCodec.h", |
| 448 | "objc/Framework/Headers/WebRTC/RTCVideoCodecFactory.h", |
| 449 | "objc/Framework/Headers/WebRTC/RTCVideoCodecH264.h", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 450 | ] |
Yura Yaroshevich | 0f77fea | 2018-04-26 15:41:01 +0300 | [diff] [blame] | 451 | if (is_ios) { |
| 452 | sources += [ |
| 453 | "objc/Framework/Classes/Video/UIDevice+H264Profile.h", |
| 454 | "objc/Framework/Classes/Video/UIDevice+H264Profile.mm", |
| 455 | ] |
| 456 | } |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 457 | if (!build_with_chromium && is_clang) { |
| 458 | # Suppress warnings from the Chromium Clang plugin |
| 459 | # (bugs.webrtc.org/163). |
| 460 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 461 | } |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 462 | public_configs = [ ":common_config_objc" ] |
| 463 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 464 | ":common_objc", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 465 | "../api/video_codecs:video_codecs_api", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 466 | "../common_video", |
Yura Yaroshevich | 0f77fea | 2018-04-26 15:41:01 +0300 | [diff] [blame] | 467 | "../media:rtc_h264_profile_id", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 468 | "../media:rtc_media_base", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 469 | "../modules:module_api", |
| 470 | "../modules/video_coding:video_codec_interface", |
| 471 | "../rtc_base:rtc_base_approved", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 472 | "../system_wrappers:field_trial_api", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 473 | ] |
| 474 | } |
| 475 | |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 476 | rtc_static_library("default_codec_factory_objc") { |
| 477 | sources = [ |
| 478 | "objc/Framework/Classes/PeerConnection/RTCDefaultVideoDecoderFactory.m", |
| 479 | "objc/Framework/Classes/PeerConnection/RTCDefaultVideoEncoderFactory.m", |
| 480 | ] |
| 481 | |
| 482 | deps = [ |
| 483 | ":common_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 484 | ":native_video", |
| 485 | ":videocodec_objc", |
Magnus Jedvert | 8b4e92d | 2018-04-13 15:36:43 +0200 | [diff] [blame] | 486 | ":vp8", |
| 487 | ":vp9", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 488 | ] |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 489 | } |
| 490 | |
| 491 | rtc_static_library("vp8") { |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 492 | visibility = [ "*" ] |
Karl Wiberg | 7ba22b8 | 2018-04-27 04:31:53 +0200 | [diff] [blame] | 493 | allow_poison = [ "software_video_codecs" ] |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 494 | sources = [ |
| 495 | "objc/Framework/Classes/PeerConnection/RTCVideoCodecVP8.mm", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 496 | "objc/Framework/Headers/WebRTC/RTCVideoDecoderVP8.h", |
| 497 | "objc/Framework/Headers/WebRTC/RTCVideoEncoderVP8.h", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 498 | ] |
| 499 | |
| 500 | if (!build_with_chromium && is_clang) { |
| 501 | # Suppress warnings from the Chromium Clang plugin |
| 502 | # (bugs.webrtc.org/163). |
| 503 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 504 | } |
| 505 | |
| 506 | deps = [ |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 507 | ":wrapped_native_codec_objc", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 508 | "../modules/video_coding:webrtc_vp8", |
| 509 | "../system_wrappers:metrics_default", |
| 510 | ] |
| 511 | } |
| 512 | |
| 513 | rtc_static_library("vp9") { |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 514 | visibility = [ "*" ] |
Karl Wiberg | 7ba22b8 | 2018-04-27 04:31:53 +0200 | [diff] [blame] | 515 | allow_poison = [ "software_video_codecs" ] |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 516 | sources = [ |
| 517 | "objc/Framework/Classes/PeerConnection/RTCVideoCodecVP9.mm", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 518 | "objc/Framework/Headers/WebRTC/RTCVideoDecoderVP9.h", |
| 519 | "objc/Framework/Headers/WebRTC/RTCVideoEncoderVP9.h", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 520 | ] |
| 521 | |
| 522 | if (!build_with_chromium && is_clang) { |
| 523 | # Suppress warnings from the Chromium Clang plugin |
| 524 | # (bugs.webrtc.org/163). |
| 525 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 526 | } |
| 527 | |
| 528 | deps = [ |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 529 | ":wrapped_native_codec_objc", |
Anders Carlsson | dd8c165 | 2018-01-30 10:32:13 +0100 | [diff] [blame] | 530 | "../modules/video_coding:webrtc_vp9", |
| 531 | "../system_wrappers:metrics_default", |
| 532 | ] |
| 533 | } |
| 534 | |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 535 | # Build the PeerConnectionFactory without audio/video support. |
| 536 | # This target depends on the objc_peeerconnectionfactory_base which still |
| 537 | # includes some audio/video related objects such as RTCAudioSource because |
| 538 | # these objects are just thin wrappers of native C++ interfaces required |
| 539 | # when implementing webrtc::PeerConnectionFactoryInterface and |
| 540 | # webrtc::PeerConnectionInterface. |
Kári Tristan Helgason | a2d89fc | 2018-03-06 10:18:43 +0100 | [diff] [blame] | 541 | # The applications which only use WebRTC DataChannel can depend on this. |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 542 | rtc_static_library("peerconnectionfactory_no_media_objc") { |
Per Kjellander | a7f2d84 | 2018-01-10 15:54:53 +0000 | [diff] [blame] | 543 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 544 | allow_poison = [ |
| 545 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 546 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 547 | ] |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 548 | defines = [ "HAVE_NO_MEDIA" ] |
| 549 | |
| 550 | sources = [ |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 551 | "objc/Framework/Classes/Common/noop.mm", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 552 | ] |
| 553 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 554 | public_configs = [ ":common_config_objc" ] |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 555 | |
| 556 | if (!build_with_chromium && is_clang) { |
| 557 | # Suppress warnings from the Chromium Clang plugin |
| 558 | # (bugs.webrtc.org/163). |
| 559 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 560 | } |
| 561 | |
| 562 | deps = [ |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 563 | ":native_api", |
| 564 | ":native_video", |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 565 | ":peerconnectionfactory_base_objc", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 566 | "../api:libjingle_peerconnection_api", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 567 | "../rtc_base:rtc_base", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 568 | ] |
| 569 | } |
| 570 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 571 | rtc_static_library("mediaconstraints_objc") { |
| 572 | sources = [ |
| 573 | "objc/Framework/Classes/PeerConnection/RTCMediaConstraints+Private.h", |
| 574 | "objc/Framework/Classes/PeerConnection/RTCMediaConstraints.mm", |
| 575 | "objc/Framework/Headers/WebRTC/RTCMediaConstraints.h", |
| 576 | ] |
| 577 | if (!build_with_chromium && is_clang) { |
| 578 | # Suppress warnings from the Chromium Clang plugin |
| 579 | # (bugs.webrtc.org/163). |
| 580 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 581 | } |
| 582 | |
| 583 | public_configs = [ ":common_config_objc" ] |
| 584 | deps = [ |
| 585 | ":common_objc", |
| 586 | "../api:libjingle_peerconnection_api", |
| 587 | ] |
| 588 | } |
| 589 | |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 590 | rtc_source_set("videorenderer_objc") { |
| 591 | sources = [ |
| 592 | "objc/Framework/Headers/WebRTC/RTCVideoRenderer.h", |
| 593 | ] |
| 594 | |
| 595 | configs += [ "..:common_objc" ] |
| 596 | visibility = [ "*" ] |
| 597 | public_configs = [ ":common_config_objc" ] |
| 598 | } |
| 599 | |
| 600 | rtc_static_library("videorendereradapter_objc") { |
Karl Wiberg | bb23c83 | 2018-04-22 19:55:00 +0200 | [diff] [blame] | 601 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 602 | allow_poison = [ |
| 603 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 604 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 605 | ] |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 606 | sources = [ |
| 607 | "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter+Private.h", |
| 608 | "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter.h", |
| 609 | "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter.mm", |
| 610 | ] |
| 611 | |
| 612 | configs += [ "..:common_objc" ] |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 613 | public_configs = [ ":common_config_objc" ] |
| 614 | |
| 615 | deps = [ |
| 616 | ":common_objc", |
| 617 | ":native_api", |
| 618 | ":videoframebuffer_objc", |
| 619 | ":videorenderer_objc", |
| 620 | "../api:libjingle_peerconnection_api", |
| 621 | ] |
| 622 | } |
| 623 | |
| 624 | rtc_static_library("mediasource_objc") { |
| 625 | sources = [ |
| 626 | "objc/Framework/Classes/PeerConnection/RTCMediaSource+Private.h", |
| 627 | "objc/Framework/Classes/PeerConnection/RTCMediaSource.mm", |
| 628 | "objc/Framework/Headers/WebRTC/RTCMediaSource.h", |
| 629 | ] |
| 630 | |
| 631 | configs += [ "..:common_objc" ] |
| 632 | public_configs = [ ":common_config_objc" ] |
| 633 | |
| 634 | deps = [ |
| 635 | ":common_objc", |
| 636 | "../api:libjingle_peerconnection_api", |
| 637 | "../rtc_base:checks", |
| 638 | ] |
| 639 | } |
| 640 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 641 | rtc_static_library("peerconnectionfactory_base_objc") { |
Karl Wiberg | bb23c83 | 2018-04-22 19:55:00 +0200 | [diff] [blame] | 642 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 643 | allow_poison = [ |
| 644 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 645 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 646 | ] |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 647 | sources = [ |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 648 | "objc/Framework/Classes/PeerConnection/RTCAudioSource+Private.h", |
| 649 | "objc/Framework/Classes/PeerConnection/RTCAudioSource.mm", |
| 650 | "objc/Framework/Classes/PeerConnection/RTCAudioTrack+Private.h", |
| 651 | "objc/Framework/Classes/PeerConnection/RTCAudioTrack.mm", |
Zeke Chin | ef1140e | 2017-10-27 15:42:08 -0700 | [diff] [blame] | 652 | "objc/Framework/Classes/PeerConnection/RTCConfiguration+Native.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 653 | "objc/Framework/Classes/PeerConnection/RTCConfiguration+Private.h", |
| 654 | "objc/Framework/Classes/PeerConnection/RTCConfiguration.mm", |
| 655 | "objc/Framework/Classes/PeerConnection/RTCDataChannel+Private.h", |
| 656 | "objc/Framework/Classes/PeerConnection/RTCDataChannel.mm", |
| 657 | "objc/Framework/Classes/PeerConnection/RTCDataChannelConfiguration+Private.h", |
| 658 | "objc/Framework/Classes/PeerConnection/RTCDataChannelConfiguration.mm", |
Yura Yaroshevich | 2767632 | 2018-01-02 14:44:35 +0300 | [diff] [blame] | 659 | "objc/Framework/Classes/PeerConnection/RTCDtmfSender+Private.h", |
| 660 | "objc/Framework/Classes/PeerConnection/RTCDtmfSender.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 661 | "objc/Framework/Classes/PeerConnection/RTCIceCandidate+Private.h", |
| 662 | "objc/Framework/Classes/PeerConnection/RTCIceCandidate.mm", |
| 663 | "objc/Framework/Classes/PeerConnection/RTCIceServer+Private.h", |
| 664 | "objc/Framework/Classes/PeerConnection/RTCIceServer.mm", |
Steve Anton | d295e40 | 2017-07-14 16:06:41 -0700 | [diff] [blame] | 665 | "objc/Framework/Classes/PeerConnection/RTCIntervalRange+Private.h", |
| 666 | "objc/Framework/Classes/PeerConnection/RTCIntervalRange.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 667 | "objc/Framework/Classes/PeerConnection/RTCLegacyStatsReport+Private.h", |
| 668 | "objc/Framework/Classes/PeerConnection/RTCLegacyStatsReport.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 669 | "objc/Framework/Classes/PeerConnection/RTCMediaStream+Private.h", |
| 670 | "objc/Framework/Classes/PeerConnection/RTCMediaStream.mm", |
| 671 | "objc/Framework/Classes/PeerConnection/RTCMediaStreamTrack+Private.h", |
| 672 | "objc/Framework/Classes/PeerConnection/RTCMediaStreamTrack.mm", |
| 673 | "objc/Framework/Classes/PeerConnection/RTCMetrics.mm", |
| 674 | "objc/Framework/Classes/PeerConnection/RTCMetricsSampleInfo+Private.h", |
| 675 | "objc/Framework/Classes/PeerConnection/RTCMetricsSampleInfo.mm", |
| 676 | "objc/Framework/Classes/PeerConnection/RTCPeerConnection+DataChannel.mm", |
Magnus Jedvert | 0af86d1 | 2017-10-28 16:26:55 +0200 | [diff] [blame] | 677 | "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Native.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 678 | "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Private.h", |
| 679 | "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Stats.mm", |
| 680 | "objc/Framework/Classes/PeerConnection/RTCPeerConnection.mm", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 681 | "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory+Native.h", |
| 682 | "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory+Private.h", |
| 683 | "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory.mm", |
Yura Yaroshevich | bf56712 | 2018-01-02 13:33:16 +0300 | [diff] [blame] | 684 | "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactoryOptions+Private.h", |
| 685 | "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactoryOptions.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 686 | "objc/Framework/Classes/PeerConnection/RTCRtpCodecParameters+Private.h", |
| 687 | "objc/Framework/Classes/PeerConnection/RTCRtpCodecParameters.mm", |
| 688 | "objc/Framework/Classes/PeerConnection/RTCRtpEncodingParameters+Private.h", |
| 689 | "objc/Framework/Classes/PeerConnection/RTCRtpEncodingParameters.mm", |
| 690 | "objc/Framework/Classes/PeerConnection/RTCRtpParameters+Private.h", |
| 691 | "objc/Framework/Classes/PeerConnection/RTCRtpParameters.mm", |
| 692 | "objc/Framework/Classes/PeerConnection/RTCRtpReceiver+Private.h", |
| 693 | "objc/Framework/Classes/PeerConnection/RTCRtpReceiver.mm", |
| 694 | "objc/Framework/Classes/PeerConnection/RTCRtpSender+Private.h", |
| 695 | "objc/Framework/Classes/PeerConnection/RTCRtpSender.mm", |
Steve Anton | 8cb344a | 2018-02-27 15:34:53 -0800 | [diff] [blame] | 696 | "objc/Framework/Classes/PeerConnection/RTCRtpTransceiver+Private.h", |
| 697 | "objc/Framework/Classes/PeerConnection/RTCRtpTransceiver.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 698 | "objc/Framework/Classes/PeerConnection/RTCSSLAdapter.mm", |
| 699 | "objc/Framework/Classes/PeerConnection/RTCSessionDescription+Private.h", |
| 700 | "objc/Framework/Classes/PeerConnection/RTCSessionDescription.mm", |
| 701 | "objc/Framework/Classes/PeerConnection/RTCTracing.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 702 | "objc/Framework/Classes/PeerConnection/RTCVideoTrack+Private.h", |
| 703 | "objc/Framework/Classes/PeerConnection/RTCVideoTrack.mm", |
Kári Tristan Helgason | f93f5a4 | 2017-05-31 10:04:55 +0200 | [diff] [blame] | 704 | "objc/Framework/Headers/WebRTC/RTCAudioSource.h", |
| 705 | "objc/Framework/Headers/WebRTC/RTCAudioTrack.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 706 | "objc/Framework/Headers/WebRTC/RTCConfiguration.h", |
| 707 | "objc/Framework/Headers/WebRTC/RTCDataChannel.h", |
| 708 | "objc/Framework/Headers/WebRTC/RTCDataChannelConfiguration.h", |
Yura Yaroshevich | 2767632 | 2018-01-02 14:44:35 +0300 | [diff] [blame] | 709 | "objc/Framework/Headers/WebRTC/RTCDtmfSender.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 710 | "objc/Framework/Headers/WebRTC/RTCIceCandidate.h", |
| 711 | "objc/Framework/Headers/WebRTC/RTCIceServer.h", |
Steve Anton | d295e40 | 2017-07-14 16:06:41 -0700 | [diff] [blame] | 712 | "objc/Framework/Headers/WebRTC/RTCIntervalRange.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 713 | "objc/Framework/Headers/WebRTC/RTCLegacyStatsReport.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 714 | "objc/Framework/Headers/WebRTC/RTCMediaStream.h", |
| 715 | "objc/Framework/Headers/WebRTC/RTCMediaStreamTrack.h", |
| 716 | "objc/Framework/Headers/WebRTC/RTCMetrics.h", |
| 717 | "objc/Framework/Headers/WebRTC/RTCMetricsSampleInfo.h", |
| 718 | "objc/Framework/Headers/WebRTC/RTCPeerConnection.h", |
| 719 | "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactory.h", |
Yura Yaroshevich | bf56712 | 2018-01-02 13:33:16 +0300 | [diff] [blame] | 720 | "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactoryOptions.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 721 | "objc/Framework/Headers/WebRTC/RTCRtpCodecParameters.h", |
| 722 | "objc/Framework/Headers/WebRTC/RTCRtpEncodingParameters.h", |
| 723 | "objc/Framework/Headers/WebRTC/RTCRtpParameters.h", |
| 724 | "objc/Framework/Headers/WebRTC/RTCRtpReceiver.h", |
| 725 | "objc/Framework/Headers/WebRTC/RTCRtpSender.h", |
Steve Anton | 8cb344a | 2018-02-27 15:34:53 -0800 | [diff] [blame] | 726 | "objc/Framework/Headers/WebRTC/RTCRtpTransceiver.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 727 | "objc/Framework/Headers/WebRTC/RTCSSLAdapter.h", |
| 728 | "objc/Framework/Headers/WebRTC/RTCSessionDescription.h", |
| 729 | "objc/Framework/Headers/WebRTC/RTCTracing.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 730 | "objc/Framework/Headers/WebRTC/RTCVideoTrack.h", |
kthelgason | 5fe4d49 | 2016-12-05 11:27:30 -0800 | [diff] [blame] | 731 | ] |
kthelgason | ebc34e7 | 2016-09-15 04:30:18 -0700 | [diff] [blame] | 732 | |
kthelgason | c097710 | 2017-04-24 00:57:16 -0700 | [diff] [blame] | 733 | configs += [ "..:common_objc" ] |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 734 | public_configs = [ ":common_config_objc" ] |
kthelgason | c097710 | 2017-04-24 00:57:16 -0700 | [diff] [blame] | 735 | |
kjellander | e40a7ee | 2016-10-16 23:56:12 -0700 | [diff] [blame] | 736 | if (!build_with_chromium && is_clang) { |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 737 | # Suppress warnings from the Chromium Clang plugin |
| 738 | # (bugs.webrtc.org/163). |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 739 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 740 | } |
| 741 | |
| 742 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 743 | ":common_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 744 | ":mediaconstraints_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 745 | ":mediasource_objc", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 746 | ":native_api", |
| 747 | ":native_video", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 748 | ":video_objc", |
| 749 | ":videocodec_objc", |
| 750 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 751 | ":videorenderer_objc", |
| 752 | ":videorendereradapter_objc", |
| 753 | ":videosource_objc", |
Mirko Bonadei | e51f785 | 2017-12-06 11:23:19 +0100 | [diff] [blame] | 754 | "../api:libjingle_peerconnection_api", |
Karl Wiberg | 5817d3d | 2018-04-06 10:06:42 +0200 | [diff] [blame] | 755 | "../api/audio_codecs:builtin_audio_decoder_factory", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 756 | "../api/video:video_frame", |
Anders Carlsson | 7e04281 | 2017-10-05 16:55:38 +0200 | [diff] [blame] | 757 | "../api/video_codecs:video_codecs_api", |
Anders Carlsson | e5960ce | 2017-06-22 15:26:30 +0200 | [diff] [blame] | 758 | "../common_video", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 759 | "../media:rtc_media_base", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 760 | "../modules:module_api", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 761 | "../modules/video_coding:video_codec_interface", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 762 | "../pc:create_pc_factory", |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 763 | "../pc:peerconnection", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 764 | "../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 765 | "../rtc_base:rtc_base", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 766 | ] |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 767 | |
| 768 | if (is_ios) { |
| 769 | deps += [ ":native_api_audio_device_module" ] |
| 770 | } |
kthelgason | ebc34e7 | 2016-09-15 04:30:18 -0700 | [diff] [blame] | 771 | } |
Zeke Chin | dd0e1e0 | 2016-10-11 13:27:26 -0700 | [diff] [blame] | 772 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 773 | if (rtc_include_tests) { |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 774 | if (is_ios) { |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 775 | rtc_source_set("sdk_unittests_sources") { |
| 776 | testonly = true |
| 777 | include_dirs = [ |
| 778 | "objc/Framework/Headers", |
| 779 | "objc/Framework/Classes", |
| 780 | ] |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 781 | |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 782 | sources = [ |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 783 | "objc/Framework/UnitTests/ObjCVideoTrackSource_xctest.mm", |
| 784 | "objc/Framework/UnitTests/RTCCVPixelBuffer_xctest.mm", |
Anders Carlsson | 3b3364e | 2018-01-30 15:46:13 +0100 | [diff] [blame] | 785 | "objc/Framework/UnitTests/RTCCallbackLogger_xctest.m", |
Peter Hanspers | 8020ae8 | 2018-01-09 14:26:41 +0100 | [diff] [blame] | 786 | "objc/Framework/UnitTests/RTCDoNotPutCPlusPlusInFrameworkHeaders_xctest.m", |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 787 | "objc/Framework/UnitTests/RTCFileVideoCapturer_xctest.mm", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 788 | "objc/Framework/UnitTests/frame_buffer_helpers.h", |
| 789 | "objc/Framework/UnitTests/frame_buffer_helpers.mm", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 790 | ] |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 791 | |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 792 | # TODO(peterhanspers): Reenable these tests on simulator. |
| 793 | # See bugs.webrtc.org/7812 |
| 794 | if (!use_ios_simulator) { |
| 795 | sources += [ |
| 796 | "objc/Framework/UnitTests/RTCAudioDeviceModule_xctest.mm", |
| 797 | "objc/Framework/UnitTests/RTCAudioDevice_xctest.mm", |
| 798 | ] |
| 799 | } |
| 800 | |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 801 | deps = [ |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 802 | ":audio_device", |
| 803 | ":audio_objc", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 804 | ":common_objc", |
Anders Carlsson | dc6b477 | 2018-01-15 13:31:03 +0100 | [diff] [blame] | 805 | ":framework_objc", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 806 | ":native_api", |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 807 | ":native_api_audio_device_module", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 808 | ":native_video", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 809 | ":videocapture_objc", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 810 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 811 | ":videosource_objc", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 812 | ":videotoolbox_objc", |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 813 | "../../system_wrappers:system_wrappers", |
Mirko Bonadei | a498ae8 | 2017-12-06 09:17:14 +0100 | [diff] [blame] | 814 | "../../system_wrappers:system_wrappers_default", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 815 | "../api/video:video_frame_i420", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 816 | "../common_video:common_video", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 817 | "../media:rtc_media_base", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 818 | "../media:rtc_media_tests_utils", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 819 | "../modules:module_api", |
| 820 | "../rtc_base:rtc_base", |
| 821 | "../rtc_base:rtc_base_tests_utils", |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 822 | "//third_party/libyuv", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 823 | ] |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 824 | |
| 825 | if (rtc_use_metal_rendering) { |
Kári Tristan Helgason | 06d094f | 2018-04-19 17:38:05 +0200 | [diff] [blame] | 826 | sources += [ "objc/Framework/UnitTests/RTCMTLVideoView_xctest.m" ] |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 827 | deps += [ ":metal_objc" ] |
| 828 | } |
| 829 | |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 830 | public_deps = [ |
| 831 | "//build/config/ios:xctest", |
| 832 | "//third_party/ocmock", |
| 833 | ] |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 834 | |
Anders Carlsson | dc6b477 | 2018-01-15 13:31:03 +0100 | [diff] [blame] | 835 | include_dirs += [ "$root_out_dir/WebRTC.framework/Headers/" ] |
Anders Carlsson | fe9d817 | 2018-04-03 11:40:39 +0200 | [diff] [blame] | 836 | |
| 837 | if (!build_with_chromium && is_clang) { |
| 838 | # Suppress warnings from the Chromium Clang plugin |
| 839 | # (bugs.webrtc.org/163). |
| 840 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 841 | } |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 842 | } |
| 843 | |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 844 | bundle_data("sdk_unittests_bundle_data") { |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 845 | sources = [ |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 846 | "objc/Framework/UnitTests/audio_short16.pcm", |
| 847 | "objc/Framework/UnitTests/audio_short44.pcm", |
| 848 | "objc/Framework/UnitTests/audio_short48.pcm", |
| 849 | |
| 850 | # Sample video taken from https://media.xiph.org/video/derf/ |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 851 | "objc/Framework/UnitTests/foreman.mp4", |
| 852 | ] |
| 853 | outputs = [ |
| 854 | "{{bundle_resources_dir}}/{{source_file_part}}", |
| 855 | ] |
| 856 | } |
| 857 | |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 858 | rtc_ios_xctest_test("sdk_unittests") { |
| 859 | info_plist = "//test/ios/Info.plist" |
| 860 | sources = [ |
| 861 | "objc/Framework/UnitTests/main.m", |
| 862 | ] |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 863 | |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 864 | _bundle_id_suffix = ios_generic_test_bundle_id_suffix |
| 865 | extra_substitutions = [ "GTEST_BUNDLE_ID_SUFFIX=$_bundle_id_suffix" ] |
| 866 | deps = [ |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 867 | ":sdk_unittests_bundle_data", |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 868 | ":sdk_unittests_sources", |
| 869 | ] |
| 870 | ldflags = [ "-all_load" ] |
Peter Hanspers | 8d95e3b | 2018-05-15 10:22:36 +0200 | [diff] [blame] | 871 | |
| 872 | if (is_clang) { |
| 873 | # Suppress warnings from the Chromium Clang plugin |
| 874 | # (bugs.webrtc.org/163). |
| 875 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 876 | } |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 877 | } |
| 878 | } |
| 879 | |
| 880 | # TODO(denicija): once all tests are migrated to xctest remove this source set. |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 881 | rtc_source_set("sdk_unittests_objc") { |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 882 | testonly = true |
Kári Tristan Helgason | cbe7435 | 2016-11-09 10:43:26 +0100 | [diff] [blame] | 883 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 884 | sources = [ |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 885 | "objc/Framework/UnitTests/RTCConfigurationTest.mm", |
| 886 | "objc/Framework/UnitTests/RTCDataChannelConfigurationTest.mm", |
| 887 | "objc/Framework/UnitTests/RTCIceCandidateTest.mm", |
| 888 | "objc/Framework/UnitTests/RTCIceServerTest.mm", |
Steve Anton | d295e40 | 2017-07-14 16:06:41 -0700 | [diff] [blame] | 889 | "objc/Framework/UnitTests/RTCIntervalRangeTests.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 890 | "objc/Framework/UnitTests/RTCMediaConstraintsTest.mm", |
| 891 | "objc/Framework/UnitTests/RTCPeerConnectionTest.mm", |
| 892 | "objc/Framework/UnitTests/RTCSessionDescriptionTest.mm", |
jtteh | 7480da4 | 2017-07-07 11:02:15 -0700 | [diff] [blame] | 893 | "objc/Framework/UnitTests/RTCTracingTest.mm", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 894 | "objc/Framework/UnitTests/objc_video_decoder_factory_tests.mm", |
| 895 | "objc/Framework/UnitTests/objc_video_encoder_factory_tests.mm", |
Kári Tristan Helgason | ca95748 | 2017-10-05 14:06:52 +0200 | [diff] [blame] | 896 | "objc/Framework/UnitTests/scoped_cftyperef_tests.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 897 | ] |
Anders Carlsson | e7dd83f | 2018-01-19 11:28:44 +0100 | [diff] [blame] | 898 | if (is_ios) { |
oprypin | 4519752 | 2017-06-22 01:47:20 -0700 | [diff] [blame] | 899 | sources += |
| 900 | [ "objc/Framework/UnitTests/RTCCameraVideoCapturerTests.mm" ] |
| 901 | } |
mbonadei | d762058 | 2017-05-30 01:50:35 -0700 | [diff] [blame] | 902 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 903 | # |-ObjC| flag needed to make sure category method implementations |
| 904 | # are included: |
| 905 | # https://developer.apple.com/library/mac/qa/qa1490/_index.html |
| 906 | ldflags = [ "-ObjC" ] |
magjed | 3149e09 | 2017-05-08 05:32:05 -0700 | [diff] [blame] | 907 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 908 | defines = [ "GTEST_RELATIVE_PATH" ] |
| 909 | deps = [ |
Kári Tristan Helgason | ca95748 | 2017-10-05 14:06:52 +0200 | [diff] [blame] | 910 | ":common_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 911 | ":mediaconstraints_objc", |
| 912 | ":native_api", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 913 | ":native_video", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 914 | ":peerconnectionfactory_base_objc", |
| 915 | ":video_objc", |
| 916 | ":videocapture_objc", |
| 917 | ":videocodec_objc", |
| 918 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 919 | ":videosource_objc", |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 920 | ":videotoolbox_objc", |
Mirko Bonadei | a498ae8 | 2017-12-06 09:17:14 +0100 | [diff] [blame] | 921 | "../../system_wrappers:system_wrappers_default", |
Magnus Jedvert | 8b4e92d | 2018-04-13 15:36:43 +0200 | [diff] [blame] | 922 | "../api/video_codecs:video_codecs_api", |
kthelgason | ebd4f79 | 2017-09-04 04:36:21 -0700 | [diff] [blame] | 923 | "../media:rtc_media_base", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 924 | "../modules:module_api", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 925 | "../modules/video_coding:video_codec_interface", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 926 | "../rtc_base:rtc_base_tests_utils", |
Kári Tristan Helgason | ca95748 | 2017-10-05 14:06:52 +0200 | [diff] [blame] | 927 | "//test:test_support", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 928 | "//third_party/ocmock", |
| 929 | ] |
magjed | 3149e09 | 2017-05-08 05:32:05 -0700 | [diff] [blame] | 930 | |
denicija | 59ee91b | 2017-06-05 05:48:47 -0700 | [diff] [blame] | 931 | if (is_ios) { |
| 932 | sources += [ "objc/Framework/UnitTests/RTCAudioSessionTest.mm" ] |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 933 | deps += [ ":audio_objc" ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 934 | } |
Daniela | ae012cf | 2017-10-12 13:46:00 +0200 | [diff] [blame] | 935 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 936 | if (!build_with_chromium && is_clang) { |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 937 | # Suppress warnings from the Chromium Clang plugin |
| 938 | # (bugs.webrtc.org/163). |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 939 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 940 | } |
| 941 | } |
kthelgason | 2f08879 | 2017-05-30 01:48:47 -0700 | [diff] [blame] | 942 | } |
| 943 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 944 | if (is_ios) { |
Anders Carlsson | dc6b477 | 2018-01-15 13:31:03 +0100 | [diff] [blame] | 945 | ios_framework_bundle_with_umbrella_header("framework_objc") { |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 946 | info_plist = "objc/Framework/Info.plist" |
| 947 | output_name = "WebRTC" |
Magnus Jedvert | f83dc8b | 2017-08-29 09:49:43 +0000 | [diff] [blame] | 948 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 949 | common_objc_headers = [ |
Jeremy Newton-Smith | 96de428 | 2017-08-23 10:02:23 -0700 | [diff] [blame] | 950 | "objc/Framework/Headers/WebRTC/RTCAudioSession.h", |
Magnus Jedvert | f83dc8b | 2017-08-29 09:49:43 +0000 | [diff] [blame] | 951 | "objc/Framework/Headers/WebRTC/RTCVideoCodec.h", |
| 952 | "objc/Framework/Headers/WebRTC/RTCVideoCodecFactory.h", |
Jeremy Newton-Smith | 96de428 | 2017-08-23 10:02:23 -0700 | [diff] [blame] | 953 | "objc/Framework/Headers/WebRTC/RTCAudioSessionConfiguration.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 954 | "objc/Framework/Headers/WebRTC/RTCAudioSource.h", |
| 955 | "objc/Framework/Headers/WebRTC/RTCAudioTrack.h", |
| 956 | "objc/Framework/Headers/WebRTC/RTCCameraVideoCapturer.h", |
| 957 | "objc/Framework/Headers/WebRTC/RTCCameraPreviewView.h", |
| 958 | "objc/Framework/Headers/WebRTC/RTCConfiguration.h", |
| 959 | "objc/Framework/Headers/WebRTC/RTCDataChannel.h", |
| 960 | "objc/Framework/Headers/WebRTC/RTCDataChannelConfiguration.h", |
| 961 | "objc/Framework/Headers/WebRTC/RTCDispatcher.h", |
| 962 | "objc/Framework/Headers/WebRTC/RTCEAGLVideoView.h", |
| 963 | "objc/Framework/Headers/WebRTC/RTCFieldTrials.h", |
Daniela | 012b56b | 2017-11-15 13:15:24 +0100 | [diff] [blame] | 964 | "objc/Framework/Headers/WebRTC/RTCFileVideoCapturer.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 965 | "objc/Framework/Headers/WebRTC/RTCIceCandidate.h", |
| 966 | "objc/Framework/Headers/WebRTC/RTCIceServer.h", |
Steve Anton | d295e40 | 2017-07-14 16:06:41 -0700 | [diff] [blame] | 967 | "objc/Framework/Headers/WebRTC/RTCIntervalRange.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 968 | "objc/Framework/Headers/WebRTC/RTCLegacyStatsReport.h", |
| 969 | "objc/Framework/Headers/WebRTC/RTCLogging.h", |
| 970 | "objc/Framework/Headers/WebRTC/RTCMacros.h", |
| 971 | "objc/Framework/Headers/WebRTC/RTCMediaConstraints.h", |
| 972 | "objc/Framework/Headers/WebRTC/RTCMediaSource.h", |
| 973 | "objc/Framework/Headers/WebRTC/RTCMediaStream.h", |
| 974 | "objc/Framework/Headers/WebRTC/RTCMediaStreamTrack.h", |
| 975 | "objc/Framework/Headers/WebRTC/RTCMetrics.h", |
| 976 | "objc/Framework/Headers/WebRTC/RTCMetricsSampleInfo.h", |
| 977 | "objc/Framework/Headers/WebRTC/RTCPeerConnection.h", |
| 978 | "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactory.h", |
Yura Yaroshevich | bf56712 | 2018-01-02 13:33:16 +0300 | [diff] [blame] | 979 | "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactoryOptions.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 980 | "objc/Framework/Headers/WebRTC/RTCRtpCodecParameters.h", |
| 981 | "objc/Framework/Headers/WebRTC/RTCRtpEncodingParameters.h", |
| 982 | "objc/Framework/Headers/WebRTC/RTCRtpParameters.h", |
| 983 | "objc/Framework/Headers/WebRTC/RTCRtpReceiver.h", |
| 984 | "objc/Framework/Headers/WebRTC/RTCRtpSender.h", |
Steve Anton | 8cb344a | 2018-02-27 15:34:53 -0800 | [diff] [blame] | 985 | "objc/Framework/Headers/WebRTC/RTCRtpTransceiver.h", |
Yura Yaroshevich | 2767632 | 2018-01-02 14:44:35 +0300 | [diff] [blame] | 986 | "objc/Framework/Headers/WebRTC/RTCDtmfSender.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 987 | "objc/Framework/Headers/WebRTC/RTCSSLAdapter.h", |
| 988 | "objc/Framework/Headers/WebRTC/RTCSessionDescription.h", |
| 989 | "objc/Framework/Headers/WebRTC/RTCTracing.h", |
| 990 | "objc/Framework/Headers/WebRTC/RTCVideoCapturer.h", |
Anders Carlsson | 7e04281 | 2017-10-05 16:55:38 +0200 | [diff] [blame] | 991 | "objc/Framework/Headers/WebRTC/RTCVideoCodecH264.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 992 | "objc/Framework/Headers/WebRTC/RTCVideoFrame.h", |
Anders Carlsson | e5960ce | 2017-06-22 15:26:30 +0200 | [diff] [blame] | 993 | "objc/Framework/Headers/WebRTC/RTCVideoFrameBuffer.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 994 | "objc/Framework/Headers/WebRTC/RTCVideoRenderer.h", |
| 995 | "objc/Framework/Headers/WebRTC/RTCVideoSource.h", |
| 996 | "objc/Framework/Headers/WebRTC/RTCVideoTrack.h", |
| 997 | "objc/Framework/Headers/WebRTC/RTCVideoViewShading.h", |
| 998 | "objc/Framework/Headers/WebRTC/UIDevice+RTCDevice.h", |
Magnus Jedvert | 8b4e92d | 2018-04-13 15:36:43 +0200 | [diff] [blame] | 999 | "objc/Framework/Headers/WebRTC/RTCVideoDecoderVP8.h", |
| 1000 | "objc/Framework/Headers/WebRTC/RTCVideoDecoderVP9.h", |
| 1001 | "objc/Framework/Headers/WebRTC/RTCVideoEncoderVP8.h", |
| 1002 | "objc/Framework/Headers/WebRTC/RTCVideoEncoderVP9.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1003 | ] |
Magnus Jedvert | 8b4e92d | 2018-04-13 15:36:43 +0200 | [diff] [blame] | 1004 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1005 | if (!build_with_chromium) { |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1006 | common_objc_headers += [ |
Anders Carlsson | 3b3364e | 2018-01-30 15:46:13 +0100 | [diff] [blame] | 1007 | "objc/Framework/Headers/WebRTC/RTCCallbackLogger.h", |
| 1008 | "objc/Framework/Headers/WebRTC/RTCFileLogger.h", |
| 1009 | ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1010 | } |
Anders Carlsson | c3d1e09 | 2018-03-21 12:38:37 +0100 | [diff] [blame] | 1011 | if (rtc_use_metal_rendering) { |
| 1012 | common_objc_headers += |
| 1013 | [ "objc/Framework/Headers/WebRTC/RTCMTLVideoView.h" ] |
| 1014 | } |
Kári Tristan Helgason | cbe7435 | 2016-11-09 10:43:26 +0100 | [diff] [blame] | 1015 | |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1016 | sources = common_objc_headers |
| 1017 | public_headers = common_objc_headers |
| 1018 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1019 | ldflags = [ |
| 1020 | "-all_load", |
| 1021 | "-install_name", |
| 1022 | "@rpath/$output_name.framework/$output_name", |
| 1023 | ] |
Kári Tristan Helgason | cbe7435 | 2016-11-09 10:43:26 +0100 | [diff] [blame] | 1024 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1025 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 1026 | ":audio_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1027 | ":common_objc", |
| 1028 | ":default_codec_factory_objc", |
| 1029 | ":native_api", |
| 1030 | ":native_video", |
| 1031 | ":peerconnectionfactory_base_objc", |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 1032 | ":ui_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1033 | ":videocapture_objc", |
| 1034 | ":videocodec_objc", |
| 1035 | ":videotoolbox_objc", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 1036 | "../rtc_base:rtc_base_approved", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1037 | "../system_wrappers:field_trial_default", |
| 1038 | "../system_wrappers:metrics_default", |
Ilya Nikolaevskiy | 2ffe3e8 | 2018-01-17 19:57:24 +0000 | [diff] [blame] | 1039 | "../system_wrappers:runtime_enabled_features_default", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1040 | ] |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1041 | if (rtc_use_metal_rendering) { |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1042 | deps += [ ":metal_objc" ] |
| 1043 | } |
Kári Tristan Helgason | cbe7435 | 2016-11-09 10:43:26 +0100 | [diff] [blame] | 1044 | |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1045 | libs = [ |
| 1046 | "AVFoundation.framework", |
| 1047 | "CoreGraphics.framework", |
| 1048 | "CoreMedia.framework", |
| 1049 | "GLKit.framework", |
| 1050 | ] |
| 1051 | |
| 1052 | configs += [ "..:common_objc" ] |
| 1053 | |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 1054 | public_configs = [ ":common_config_objc" ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1055 | |
| 1056 | if (!build_with_chromium && is_clang) { |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 1057 | # Suppress warnings from the Chromium Clang plugin |
| 1058 | # (bugs.webrtc.org/163). |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1059 | configs -= [ "//build/config/clang:find_bad_constructs" ] |
| 1060 | } |
| 1061 | } |
Kári Tristan Helgason | cbe7435 | 2016-11-09 10:43:26 +0100 | [diff] [blame] | 1062 | } |
| 1063 | |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1064 | rtc_static_library("wrapped_native_codec_objc") { |
| 1065 | sources = [ |
| 1066 | "objc/Framework/Classes/PeerConnection/RTCWrappedNativeVideoDecoder.h", |
| 1067 | "objc/Framework/Classes/PeerConnection/RTCWrappedNativeVideoDecoder.mm", |
| 1068 | "objc/Framework/Classes/PeerConnection/RTCWrappedNativeVideoEncoder.h", |
| 1069 | "objc/Framework/Classes/PeerConnection/RTCWrappedNativeVideoEncoder.mm", |
| 1070 | ] |
| 1071 | |
| 1072 | configs += [ "..:common_objc" ] |
| 1073 | public_configs = [ ":common_config_objc" ] |
| 1074 | |
| 1075 | if (!build_with_chromium && is_clang) { |
| 1076 | # Suppress warnings from the Chromium Clang plugin |
| 1077 | # (bugs.webrtc.org/163). |
| 1078 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 1079 | } |
| 1080 | |
| 1081 | deps = [ |
| 1082 | ":common_objc", |
| 1083 | ":videocodec_objc", |
| 1084 | "../api/video_codecs:video_codecs_api", |
| 1085 | "../media:rtc_media_base", |
| 1086 | ] |
| 1087 | } |
| 1088 | |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1089 | # The native API is currently experimental and may change without notice. |
| 1090 | rtc_static_library("native_api") { |
| 1091 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 1092 | allow_poison = [ |
| 1093 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 1094 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 1095 | ] |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1096 | sources = [ |
Anders Carlsson | 7311918 | 2018-03-15 09:41:03 +0100 | [diff] [blame] | 1097 | "objc/Framework/Native/api/video_capturer.h", |
| 1098 | "objc/Framework/Native/api/video_capturer.mm", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1099 | "objc/Framework/Native/api/video_decoder_factory.h", |
| 1100 | "objc/Framework/Native/api/video_decoder_factory.mm", |
| 1101 | "objc/Framework/Native/api/video_encoder_factory.h", |
| 1102 | "objc/Framework/Native/api/video_encoder_factory.mm", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1103 | "objc/Framework/Native/api/video_frame.h", |
| 1104 | "objc/Framework/Native/api/video_frame.mm", |
| 1105 | "objc/Framework/Native/api/video_frame_buffer.h", |
| 1106 | "objc/Framework/Native/api/video_frame_buffer.mm", |
| 1107 | "objc/Framework/Native/api/video_renderer.h", |
| 1108 | "objc/Framework/Native/api/video_renderer.mm", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1109 | ] |
| 1110 | |
| 1111 | configs += [ "..:common_objc" ] |
| 1112 | |
| 1113 | public_configs = [ ":common_config_objc" ] |
| 1114 | |
| 1115 | if (!build_with_chromium && is_clang) { |
| 1116 | # Suppress warnings from the Chromium Clang plugin |
| 1117 | # (bugs.webrtc.org/163). |
| 1118 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 1119 | } |
| 1120 | |
| 1121 | deps = [ |
| 1122 | ":native_video", |
Anders Carlsson | 7311918 | 2018-03-15 09:41:03 +0100 | [diff] [blame] | 1123 | ":videocapturebase_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1124 | ":videocodec_objc", |
| 1125 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1126 | ":videorenderer_objc", |
Anders Carlsson | 7311918 | 2018-03-15 09:41:03 +0100 | [diff] [blame] | 1127 | "../api:libjingle_peerconnection_api", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 1128 | "../api/video:video_frame", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1129 | "../api/video_codecs:video_codecs_api", |
| 1130 | "../common_video", |
| 1131 | "../rtc_base:rtc_base", |
| 1132 | ] |
| 1133 | } |
| 1134 | |
| 1135 | rtc_static_library("native_video") { |
| 1136 | sources = [ |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1137 | "objc/Framework/Native/src/objc_frame_buffer.h", |
| 1138 | "objc/Framework/Native/src/objc_frame_buffer.mm", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1139 | "objc/Framework/Native/src/objc_video_decoder_factory.h", |
| 1140 | "objc/Framework/Native/src/objc_video_decoder_factory.mm", |
| 1141 | "objc/Framework/Native/src/objc_video_encoder_factory.h", |
| 1142 | "objc/Framework/Native/src/objc_video_encoder_factory.mm", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1143 | "objc/Framework/Native/src/objc_video_frame.h", |
| 1144 | "objc/Framework/Native/src/objc_video_frame.mm", |
| 1145 | "objc/Framework/Native/src/objc_video_renderer.h", |
| 1146 | "objc/Framework/Native/src/objc_video_renderer.mm", |
| 1147 | "objc/Framework/Native/src/objc_video_track_source.h", |
| 1148 | "objc/Framework/Native/src/objc_video_track_source.mm", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1149 | ] |
| 1150 | |
| 1151 | configs += [ "..:common_objc" ] |
| 1152 | |
| 1153 | public_configs = [ ":common_config_objc" ] |
| 1154 | |
| 1155 | if (!build_with_chromium && is_clang) { |
| 1156 | # Suppress warnings from the Chromium Clang plugin |
| 1157 | # (bugs.webrtc.org/163). |
| 1158 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 1159 | } |
| 1160 | |
| 1161 | deps = [ |
| 1162 | ":common_objc", |
Anders Carlsson | 7311918 | 2018-03-15 09:41:03 +0100 | [diff] [blame] | 1163 | ":videocapturebase_objc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1164 | ":videocodec_objc", |
| 1165 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1166 | ":videorenderer_objc", |
| 1167 | ":wrapped_native_codec_objc", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 1168 | "../api/video:video_frame", |
| 1169 | "../api/video:video_frame_i420", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1170 | "../api/video_codecs:video_codecs_api", |
| 1171 | "../common_video", |
| 1172 | "../media:rtc_audio_video", |
| 1173 | "../media:rtc_media_base", |
| 1174 | "../modules:module_api", |
| 1175 | "../modules/video_coding:video_codec_interface", |
| 1176 | "../rtc_base:checks", |
| 1177 | "../rtc_base:rtc_base", |
| 1178 | ] |
| 1179 | } |
| 1180 | |
mbonadei | c0af5ac | 2017-08-24 12:26:05 -0700 | [diff] [blame] | 1181 | rtc_static_library("video_toolbox_cc") { |
mbonadei | 6ff8f96 | 2017-09-04 05:51:34 -0700 | [diff] [blame] | 1182 | visibility = [ ":videotoolbox_objc" ] |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1183 | sources = [ |
magjed | 73c0eb5 | 2017-08-07 06:55:28 -0700 | [diff] [blame] | 1184 | "objc/Framework/Classes/VideoToolbox/helpers.cc", |
| 1185 | "objc/Framework/Classes/VideoToolbox/helpers.h", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1186 | "objc/Framework/Classes/VideoToolbox/nalu_rewriter.cc", |
| 1187 | "objc/Framework/Classes/VideoToolbox/nalu_rewriter.h", |
mbonadei | c0af5ac | 2017-08-24 12:26:05 -0700 | [diff] [blame] | 1188 | ] |
| 1189 | deps = [ |
| 1190 | "../common_video", |
| 1191 | "../modules:module_api", |
| 1192 | "../modules/video_coding:webrtc_h264", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 1193 | "../rtc_base:checks", |
mbonadei | c0af5ac | 2017-08-24 12:26:05 -0700 | [diff] [blame] | 1194 | "../rtc_base:rtc_base_approved", |
| 1195 | ] |
| 1196 | if (!build_with_chromium && is_clang) { |
| 1197 | # Suppress warnings from the Chromium Clang plugin |
| 1198 | # (bugs.webrtc.org/163). |
| 1199 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 1200 | } |
| 1201 | } |
| 1202 | |
| 1203 | rtc_static_library("videotoolbox_objc") { |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1204 | visibility = [ "*" ] |
Anders Carlsson | 1f433e4 | 2018-04-24 16:39:05 +0200 | [diff] [blame] | 1205 | allow_poison = [ |
| 1206 | "audio_codecs", # TODO(bugs.webrtc.org/8396): Remove. |
| 1207 | "software_video_codecs", # TODO(bugs.webrtc.org/7925): Remove. |
| 1208 | ] |
mbonadei | c0af5ac | 2017-08-24 12:26:05 -0700 | [diff] [blame] | 1209 | sources = [ |
| 1210 | "objc/Framework/Classes/VideoToolbox/RTCVideoDecoderH264.mm", |
| 1211 | "objc/Framework/Classes/VideoToolbox/RTCVideoEncoderH264.mm", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1212 | ] |
| 1213 | |
| 1214 | configs += [ "..:common_objc" ] |
| 1215 | |
| 1216 | deps = [ |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 1217 | ":common_objc", |
Anders Carlsson | 3ff50fb | 2018-02-01 15:47:05 +0100 | [diff] [blame] | 1218 | ":native_api", |
kthelgason | 36d658d | 2017-08-24 05:43:45 -0700 | [diff] [blame] | 1219 | ":video_objc", |
mbonadei | c0af5ac | 2017-08-24 12:26:05 -0700 | [diff] [blame] | 1220 | ":video_toolbox_cc", |
Kári Tristan Helgason | 99bf77c | 2018-02-16 10:49:22 +0100 | [diff] [blame] | 1221 | ":videocodec_objc", |
| 1222 | ":videoframebuffer_objc", |
Anders Carlsson | 9823ee4 | 2018-03-07 10:32:03 +0100 | [diff] [blame] | 1223 | ":videosource_objc", |
Niels Möller | c6ce9c5 | 2018-05-11 11:15:30 +0200 | [diff] [blame] | 1224 | "../api/video:video_frame", |
kthelgason | fb14312 | 2017-07-25 07:55:58 -0700 | [diff] [blame] | 1225 | "../api/video_codecs:video_codecs_api", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1226 | "../common_video", |
Mirko Bonadei | 75baa49 | 2018-01-11 17:07:30 +0100 | [diff] [blame] | 1227 | "../media:rtc_audio_video", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1228 | "../media:rtc_media", |
| 1229 | "../media:rtc_media_base", |
| 1230 | "../modules:module_api", |
Patrik Höglund | 99175c6 | 2018-01-08 11:05:10 +0100 | [diff] [blame] | 1231 | "../modules/video_coding:video_codec_interface", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1232 | "../modules/video_coding:video_coding_utility", |
Patrik Höglund | a8005cf | 2017-12-13 16:05:42 +0100 | [diff] [blame] | 1233 | "../rtc_base:checks", |
ehmaldonado | f6a861a | 2017-07-19 10:40:47 -0700 | [diff] [blame] | 1234 | "../rtc_base:rtc_base_approved", |
Mirko Bonadei | 401d056 | 2017-12-14 11:24:00 +0100 | [diff] [blame] | 1235 | "//third_party/libyuv", |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1236 | ] |
| 1237 | |
| 1238 | libs = [ |
| 1239 | "CoreFoundation.framework", |
| 1240 | "CoreMedia.framework", |
| 1241 | "CoreVideo.framework", |
| 1242 | "VideoToolbox.framework", |
| 1243 | ] |
| 1244 | |
| 1245 | if (!build_with_chromium && is_clang) { |
zhihuang | a4c113a | 2017-06-28 14:05:44 -0700 | [diff] [blame] | 1246 | # Suppress warnings from the Chromium Clang plugin |
| 1247 | # (bugs.webrtc.org/163). |
mbonadei | 2c8ac1b | 2017-05-31 05:14:26 -0700 | [diff] [blame] | 1248 | suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 1249 | } |
Kári Tristan Helgason | cbe7435 | 2016-11-09 10:43:26 +0100 | [diff] [blame] | 1250 | } |
| 1251 | } |
tkchin | 9eeb624 | 2016-04-27 01:54:20 -0700 | [diff] [blame] | 1252 | } |