OLD | NEW |
1 # Copyright 2016 The WebRTC project authors. All Rights Reserved. | 1 # Copyright 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("../webrtc.gni") | 9 import("../webrtc.gni") |
10 if (is_ios) { | 10 if (is_ios) { |
11 import("//build/config/ios/rules.gni") | 11 import("//build/config/ios/rules.gni") |
12 } | 12 } |
13 | 13 |
14 declare_args() { | 14 declare_args() { |
15 # Determine whether or not to include metal rendering | 15 # Determine whether or not to include metal rendering |
16 rtc_use_metal_rendering = is_mac || (is_ios && current_cpu == "arm64") | 16 rtc_use_metal_rendering = is_mac || (is_ios && current_cpu == "arm64") |
17 } | 17 } |
18 | 18 |
19 group("sdk") { | 19 group("sdk") { |
20 if (is_ios) { | 20 if (!build_with_chromium && is_ios) { |
21 public_deps = [ | 21 public_deps = [ |
22 ":objc_framework", | 22 ":objc_framework", |
23 ] | 23 ] |
24 } | 24 } |
25 } | 25 } |
26 | 26 |
27 if (is_ios || is_mac) { | 27 if (is_ios || is_mac) { |
28 config("objc_common_config") { | 28 config("objc_common_config") { |
29 include_dirs = [ | 29 include_dirs = [ |
30 "objc/Framework/Classes", | 30 "objc/Framework/Classes", |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 } | 72 } |
73 | 73 |
74 if (!build_with_chromium) { | 74 if (!build_with_chromium) { |
75 sources += [ | 75 sources += [ |
76 "objc/Framework/Classes/Common/RTCFileLogger.mm", | 76 "objc/Framework/Classes/Common/RTCFileLogger.mm", |
77 "objc/Framework/Headers/WebRTC/RTCFileLogger.h", | 77 "objc/Framework/Headers/WebRTC/RTCFileLogger.h", |
78 ] | 78 ] |
79 } | 79 } |
80 } | 80 } |
81 | 81 |
82 rtc_static_library("objc_video") { | 82 if (!build_with_chromium) { |
83 sources = [ | 83 rtc_static_library("objc_video") { |
84 "objc/Framework/Classes/Video/RTCAVFoundationVideoCapturerInternal.h", | 84 sources = [ |
85 "objc/Framework/Classes/Video/RTCAVFoundationVideoCapturerInternal.mm", | 85 "objc/Framework/Classes/Video/RTCAVFoundationVideoCapturerInternal.h", |
86 "objc/Framework/Classes/Video/RTCDefaultShader.h", | 86 "objc/Framework/Classes/Video/RTCAVFoundationVideoCapturerInternal.mm", |
87 "objc/Framework/Classes/Video/RTCDefaultShader.mm", | 87 "objc/Framework/Classes/Video/RTCDefaultShader.h", |
88 "objc/Framework/Classes/Video/RTCI420TextureCache.h", | 88 "objc/Framework/Classes/Video/RTCDefaultShader.mm", |
89 "objc/Framework/Classes/Video/RTCI420TextureCache.mm", | 89 "objc/Framework/Classes/Video/RTCI420TextureCache.h", |
90 "objc/Framework/Classes/Video/RTCOpenGLDefines.h", | 90 "objc/Framework/Classes/Video/RTCI420TextureCache.mm", |
91 "objc/Framework/Classes/Video/RTCShader.h", | 91 "objc/Framework/Classes/Video/RTCOpenGLDefines.h", |
92 "objc/Framework/Classes/Video/RTCShader.mm", | 92 "objc/Framework/Classes/Video/RTCShader.h", |
93 "objc/Framework/Classes/Video/avfoundationformatmapper.h", | 93 "objc/Framework/Classes/Video/RTCShader.mm", |
94 "objc/Framework/Classes/Video/avfoundationformatmapper.mm", | 94 "objc/Framework/Classes/Video/avfoundationformatmapper.h", |
95 "objc/Framework/Classes/Video/avfoundationvideocapturer.h", | 95 "objc/Framework/Classes/Video/avfoundationformatmapper.mm", |
96 "objc/Framework/Classes/Video/avfoundationvideocapturer.mm", | 96 "objc/Framework/Classes/Video/avfoundationvideocapturer.h", |
97 "objc/Framework/Classes/Video/objcvideotracksource.h", | 97 "objc/Framework/Classes/Video/avfoundationvideocapturer.mm", |
98 "objc/Framework/Classes/Video/objcvideotracksource.mm", | 98 "objc/Framework/Classes/Video/objcvideotracksource.h", |
99 ] | 99 "objc/Framework/Classes/Video/objcvideotracksource.mm", |
100 libs = [] | |
101 if (is_ios) { | |
102 sources += [ | |
103 "objc/Framework/Classes/Video/RTCNV12TextureCache.h", | |
104 "objc/Framework/Classes/Video/RTCNV12TextureCache.m", | |
105 ] | 100 ] |
106 libs += [ | 101 libs = [] |
107 "GLKit.framework", | |
108 "OpenGLES.framework", | |
109 "QuartzCore.framework", | |
110 ] | |
111 } else if (is_mac) { | |
112 sources += [] | |
113 | |
114 libs += [ | |
115 "CoreMedia.framework", | |
116 "CoreVideo.framework", | |
117 "OpenGL.framework", | |
118 ] | |
119 } | |
120 | |
121 deps = [ | |
122 ":objc_common", | |
123 ":objc_corevideoframebuffer", | |
124 ":objc_videotoolbox", | |
125 "../api:libjingle_peerconnection_api", | |
126 "../base:rtc_base", | |
127 "../common_video", | |
128 "../media:rtc_media_base", | |
129 ] | |
130 | |
131 configs += [ "..:common_objc" ] | |
132 if (!build_with_chromium && is_clang) { | |
133 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). | |
134 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | |
135 } | |
136 } | |
137 | |
138 rtc_static_library("objc_ui") { | |
139 if (is_ios) { | |
140 sources = [ | |
141 "objc/Framework/Classes/UI/RTCCameraPreviewView.m", | |
142 "objc/Framework/Classes/UI/RTCEAGLVideoView.m", | |
143 "objc/Framework/Headers/WebRTC/RTCCameraPreviewView.h", | |
144 "objc/Framework/Headers/WebRTC/RTCEAGLVideoView.h", | |
145 ] | |
146 } | |
147 if (is_mac) { | |
148 sources = [ | |
149 "objc/Framework/Classes/UI/RTCNSGLVideoView.m", | |
150 "objc/Framework/Headers/WebRTC/RTCNSGLVideoView.h", | |
151 ] | |
152 } | |
153 configs += [ "..:common_objc" ] | |
154 deps = [ | |
155 ":objc_common", | |
156 ":objc_peerconnection", | |
157 ] | |
158 } | |
159 | |
160 if (rtc_use_metal_rendering) { | |
161 rtc_static_library("objc_metal") { | |
162 sources = [ | |
163 "objc/Framework/Classes/Metal/RTCMTLI420Renderer.h", | |
164 "objc/Framework/Classes/Metal/RTCMTLI420Renderer.mm", | |
165 "objc/Framework/Classes/Metal/RTCMTLRenderer+Private.h", | |
166 "objc/Framework/Classes/Metal/RTCMTLRenderer.h", | |
167 "objc/Framework/Classes/Metal/RTCMTLRenderer.mm", | |
168 ] | |
169 if (is_ios) { | 102 if (is_ios) { |
170 sources += [ | 103 sources += [ |
171 "objc/Framework/Classes/Metal/RTCMTLNV12Renderer.h", | 104 "objc/Framework/Classes/Video/RTCNV12TextureCache.h", |
172 "objc/Framework/Classes/Metal/RTCMTLNV12Renderer.mm", | 105 "objc/Framework/Classes/Video/RTCNV12TextureCache.m", |
173 "objc/Framework/Classes/Metal/RTCMTLVideoView.m", | 106 ] |
174 "objc/Framework/Headers/WebRTC/RTCMTLVideoView.h", | 107 libs += [ |
| 108 "GLKit.framework", |
| 109 "OpenGLES.framework", |
| 110 "QuartzCore.framework", |
| 111 ] |
| 112 } else if (is_mac) { |
| 113 sources += [] |
| 114 |
| 115 libs += [ |
| 116 "CoreMedia.framework", |
| 117 "CoreVideo.framework", |
| 118 "OpenGL.framework", |
175 ] | 119 ] |
176 } | 120 } |
177 if (is_mac) { | 121 |
178 sources += [ | |
179 "objc/Framework/Classes/Metal/RTCMTLNSVideoView.m", | |
180 "objc/Framework/Headers/WebRTC/RTCMTLNSVideoView.h", | |
181 ] | |
182 } | |
183 libs = [ | |
184 "CoreVideo.framework", | |
185 "Metal.framework", | |
186 "MetalKit.framework", | |
187 ] | |
188 deps = [ | 122 deps = [ |
189 ":objc_video", | 123 ":objc_common", |
190 "../api:video_frame_api", | 124 ":objc_corevideoframebuffer", |
191 "../base:rtc_base_approved", | 125 ":objc_videotoolbox", |
192 ] | 126 "../api:libjingle_peerconnection_api", |
193 configs += [ "..:common_objc" ] | 127 "../base:rtc_base", |
194 public_configs = [ ":objc_common_config" ] | 128 "../common_video", |
195 } | 129 "../media:rtc_media_base", |
196 } | |
197 | |
198 rtc_static_library("objc_peerconnection") { | |
199 sources = [ | |
200 "objc/Framework/Classes/PeerConnection/RTCAVFoundationVideoSource+Private.
h", | |
201 "objc/Framework/Classes/PeerConnection/RTCAVFoundationVideoSource.mm", | |
202 "objc/Framework/Classes/PeerConnection/RTCAudioSource+Private.h", | |
203 "objc/Framework/Classes/PeerConnection/RTCAudioSource.mm", | |
204 "objc/Framework/Classes/PeerConnection/RTCAudioTrack+Private.h", | |
205 "objc/Framework/Classes/PeerConnection/RTCAudioTrack.mm", | |
206 "objc/Framework/Classes/PeerConnection/RTCCameraVideoCapturer.m", | |
207 "objc/Framework/Classes/PeerConnection/RTCConfiguration+Private.h", | |
208 "objc/Framework/Classes/PeerConnection/RTCConfiguration.mm", | |
209 "objc/Framework/Classes/PeerConnection/RTCDataChannel+Private.h", | |
210 "objc/Framework/Classes/PeerConnection/RTCDataChannel.mm", | |
211 "objc/Framework/Classes/PeerConnection/RTCDataChannelConfiguration+Private
.h", | |
212 "objc/Framework/Classes/PeerConnection/RTCDataChannelConfiguration.mm", | |
213 "objc/Framework/Classes/PeerConnection/RTCIceCandidate+Private.h", | |
214 "objc/Framework/Classes/PeerConnection/RTCIceCandidate.mm", | |
215 "objc/Framework/Classes/PeerConnection/RTCIceServer+Private.h", | |
216 "objc/Framework/Classes/PeerConnection/RTCIceServer.mm", | |
217 "objc/Framework/Classes/PeerConnection/RTCLegacyStatsReport+Private.h", | |
218 "objc/Framework/Classes/PeerConnection/RTCLegacyStatsReport.mm", | |
219 "objc/Framework/Classes/PeerConnection/RTCMediaConstraints+Private.h", | |
220 "objc/Framework/Classes/PeerConnection/RTCMediaConstraints.mm", | |
221 "objc/Framework/Classes/PeerConnection/RTCMediaSource+Private.h", | |
222 "objc/Framework/Classes/PeerConnection/RTCMediaSource.mm", | |
223 "objc/Framework/Classes/PeerConnection/RTCMediaStream+Private.h", | |
224 "objc/Framework/Classes/PeerConnection/RTCMediaStream.mm", | |
225 "objc/Framework/Classes/PeerConnection/RTCMediaStreamTrack+Private.h", | |
226 "objc/Framework/Classes/PeerConnection/RTCMediaStreamTrack.mm", | |
227 "objc/Framework/Classes/PeerConnection/RTCMetrics.mm", | |
228 "objc/Framework/Classes/PeerConnection/RTCMetricsSampleInfo+Private.h", | |
229 "objc/Framework/Classes/PeerConnection/RTCMetricsSampleInfo.mm", | |
230 "objc/Framework/Classes/PeerConnection/RTCPeerConnection+DataChannel.mm", | |
231 "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Private.h", | |
232 "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Stats.mm", | |
233 "objc/Framework/Classes/PeerConnection/RTCPeerConnection.mm", | |
234 "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory+Private.h"
, | |
235 "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory.mm", | |
236 "objc/Framework/Classes/PeerConnection/RTCRtpCodecParameters+Private.h", | |
237 "objc/Framework/Classes/PeerConnection/RTCRtpCodecParameters.mm", | |
238 "objc/Framework/Classes/PeerConnection/RTCRtpEncodingParameters+Private.h"
, | |
239 "objc/Framework/Classes/PeerConnection/RTCRtpEncodingParameters.mm", | |
240 "objc/Framework/Classes/PeerConnection/RTCRtpParameters+Private.h", | |
241 "objc/Framework/Classes/PeerConnection/RTCRtpParameters.mm", | |
242 "objc/Framework/Classes/PeerConnection/RTCRtpReceiver+Private.h", | |
243 "objc/Framework/Classes/PeerConnection/RTCRtpReceiver.mm", | |
244 "objc/Framework/Classes/PeerConnection/RTCRtpSender+Private.h", | |
245 "objc/Framework/Classes/PeerConnection/RTCRtpSender.mm", | |
246 "objc/Framework/Classes/PeerConnection/RTCSSLAdapter.mm", | |
247 "objc/Framework/Classes/PeerConnection/RTCSessionDescription+Private.h", | |
248 "objc/Framework/Classes/PeerConnection/RTCSessionDescription.mm", | |
249 "objc/Framework/Classes/PeerConnection/RTCTracing.mm", | |
250 "objc/Framework/Classes/PeerConnection/RTCVideoCapturer.m", | |
251 "objc/Framework/Classes/PeerConnection/RTCVideoFrame+Private.h", | |
252 "objc/Framework/Classes/PeerConnection/RTCVideoFrame.mm", | |
253 "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter+Private.h", | |
254 "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter.h", | |
255 "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter.mm", | |
256 "objc/Framework/Classes/PeerConnection/RTCVideoSource+Private.h", | |
257 "objc/Framework/Classes/PeerConnection/RTCVideoSource.mm", | |
258 "objc/Framework/Classes/PeerConnection/RTCVideoTrack+Private.h", | |
259 "objc/Framework/Classes/PeerConnection/RTCVideoTrack.mm", | |
260 "objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h", | |
261 "objc/Framework/Headers/WebRTC/RTCAudioSource.h", | |
262 "objc/Framework/Headers/WebRTC/RTCAudioTrack.h", | |
263 "objc/Framework/Headers/WebRTC/RTCCameraVideoCapturer.h", | |
264 "objc/Framework/Headers/WebRTC/RTCConfiguration.h", | |
265 "objc/Framework/Headers/WebRTC/RTCDataChannel.h", | |
266 "objc/Framework/Headers/WebRTC/RTCDataChannelConfiguration.h", | |
267 "objc/Framework/Headers/WebRTC/RTCIceCandidate.h", | |
268 "objc/Framework/Headers/WebRTC/RTCIceServer.h", | |
269 "objc/Framework/Headers/WebRTC/RTCLegacyStatsReport.h", | |
270 "objc/Framework/Headers/WebRTC/RTCMediaConstraints.h", | |
271 "objc/Framework/Headers/WebRTC/RTCMediaSource.h", | |
272 "objc/Framework/Headers/WebRTC/RTCMediaStream.h", | |
273 "objc/Framework/Headers/WebRTC/RTCMediaStreamTrack.h", | |
274 "objc/Framework/Headers/WebRTC/RTCMetrics.h", | |
275 "objc/Framework/Headers/WebRTC/RTCMetricsSampleInfo.h", | |
276 "objc/Framework/Headers/WebRTC/RTCPeerConnection.h", | |
277 "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactory.h", | |
278 "objc/Framework/Headers/WebRTC/RTCRtpCodecParameters.h", | |
279 "objc/Framework/Headers/WebRTC/RTCRtpEncodingParameters.h", | |
280 "objc/Framework/Headers/WebRTC/RTCRtpParameters.h", | |
281 "objc/Framework/Headers/WebRTC/RTCRtpReceiver.h", | |
282 "objc/Framework/Headers/WebRTC/RTCRtpSender.h", | |
283 "objc/Framework/Headers/WebRTC/RTCSSLAdapter.h", | |
284 "objc/Framework/Headers/WebRTC/RTCSessionDescription.h", | |
285 "objc/Framework/Headers/WebRTC/RTCTracing.h", | |
286 "objc/Framework/Headers/WebRTC/RTCVideoCapturer.h", | |
287 "objc/Framework/Headers/WebRTC/RTCVideoFrame.h", | |
288 "objc/Framework/Headers/WebRTC/RTCVideoRenderer.h", | |
289 "objc/Framework/Headers/WebRTC/RTCVideoSource.h", | |
290 "objc/Framework/Headers/WebRTC/RTCVideoTrack.h", | |
291 "objc/Framework/Headers/WebRTC/RTCVideoViewShading.h", | |
292 ] | |
293 | |
294 libs = [ "AVFoundation.framework" ] | |
295 | |
296 if (is_ios) { | |
297 libs += [ "CoreGraphics.framework" ] | |
298 } | |
299 | |
300 configs += [ "..:common_objc" ] | |
301 | |
302 public_configs = [ ":objc_common_config" ] | |
303 | |
304 if (!build_with_chromium && is_clang) { | |
305 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). | |
306 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | |
307 } | |
308 | |
309 deps = [ | |
310 ":objc_common", | |
311 ":objc_corevideoframebuffer", | |
312 ":objc_video", | |
313 "../api:video_frame_api", | |
314 "../base:rtc_base", | |
315 "../media:rtc_media_base", | |
316 "../pc:libjingle_peerconnection", | |
317 ] | |
318 | |
319 if (rtc_use_metal_rendering) { | |
320 deps += [ ":objc_metal" ] | |
321 } | |
322 | |
323 if (rtc_build_libyuv) { | |
324 deps += [ "$rtc_libyuv_dir" ] | |
325 public_deps = [ | |
326 "$rtc_libyuv_dir", | |
327 ] | |
328 } | |
329 } | |
330 | |
331 if (rtc_include_tests) { | |
332 rtc_source_set("objc_sdk_unittests") { | |
333 testonly = true | |
334 | |
335 # Skip restricting visibility on mobile platforms since the tests on those | |
336 # gets additional generated targets which would require many lines here to | |
337 # cover (which would be confusing to read and hard to maintain). | |
338 if (!is_android && !is_ios) { | |
339 visibility = [ "..:rtc_unittests" ] | |
340 } | |
341 sources = [ | |
342 "objc/Framework/UnitTests/RTCCameraVideoCapturerTests.mm", | |
343 "objc/Framework/UnitTests/RTCConfigurationTest.mm", | |
344 "objc/Framework/UnitTests/RTCDataChannelConfigurationTest.mm", | |
345 "objc/Framework/UnitTests/RTCIceCandidateTest.mm", | |
346 "objc/Framework/UnitTests/RTCIceServerTest.mm", | |
347 "objc/Framework/UnitTests/RTCMediaConstraintsTest.mm", | |
348 "objc/Framework/UnitTests/RTCPeerConnectionTest.mm", | |
349 "objc/Framework/UnitTests/RTCSessionDescriptionTest.mm", | |
350 "objc/Framework/UnitTests/avformatmappertests.mm", | |
351 ] | 130 ] |
352 | 131 |
353 # |-ObjC| flag needed to make sure category method implementations | 132 configs += [ "..:common_objc" ] |
354 # are included: | |
355 # https://developer.apple.com/library/mac/qa/qa1490/_index.html | |
356 ldflags = [ "-ObjC" ] | |
357 | |
358 defines = [ "GTEST_RELATIVE_PATH" ] | |
359 deps = [ | |
360 ":objc_peerconnection", | |
361 "..//system_wrappers:system_wrappers_default", | |
362 "../base:rtc_base_tests_utils", | |
363 "../system_wrappers:system_wrappers_default", | |
364 "//third_party/ocmock", | |
365 ] | |
366 | |
367 # RTCMTLVideoView not supported on 32-bit arm | |
368 if (is_ios && current_cpu != "arm") { | |
369 sources += [ "objc/Framework/UnitTests/RTCMTLVideoViewTests.mm" ] | |
370 if (current_cpu != "arm64") { | |
371 # Only include this file on simulator, as it's already | |
372 # included in device builds. | |
373 sources += [ "objc/Framework/Classes/Metal/RTCMTLVideoView.m" ] | |
374 libs = [ "CoreVideo.framework" ] | |
375 } | |
376 } | |
377 | |
378 if (!build_with_chromium && is_clang) { | 133 if (!build_with_chromium && is_clang) { |
379 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163)
. | 134 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163)
. |
380 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | 135 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
381 } | 136 } |
382 } | 137 } |
383 } | |
384 | 138 |
385 if (is_ios) { | 139 rtc_static_library("objc_ui") { |
386 ios_framework_bundle("objc_framework") { | 140 if (is_ios) { |
387 info_plist = "objc/Framework/Info.plist" | 141 sources = [ |
388 output_name = "WebRTC" | 142 "objc/Framework/Classes/UI/RTCCameraPreviewView.m", |
| 143 "objc/Framework/Classes/UI/RTCEAGLVideoView.m", |
| 144 "objc/Framework/Headers/WebRTC/RTCCameraPreviewView.h", |
| 145 "objc/Framework/Headers/WebRTC/RTCEAGLVideoView.h", |
| 146 ] |
| 147 } |
| 148 if (is_mac) { |
| 149 sources = [ |
| 150 "objc/Framework/Classes/UI/RTCNSGLVideoView.m", |
| 151 "objc/Framework/Headers/WebRTC/RTCNSGLVideoView.h", |
| 152 ] |
| 153 } |
| 154 configs += [ "..:common_objc" ] |
| 155 deps = [ |
| 156 ":objc_common", |
| 157 ":objc_peerconnection", |
| 158 ] |
| 159 } |
389 | 160 |
390 common_objc_headers = [ | 161 if (rtc_use_metal_rendering) { |
| 162 rtc_static_library("objc_metal") { |
| 163 sources = [ |
| 164 "objc/Framework/Classes/Metal/RTCMTLI420Renderer.h", |
| 165 "objc/Framework/Classes/Metal/RTCMTLI420Renderer.mm", |
| 166 "objc/Framework/Classes/Metal/RTCMTLRenderer+Private.h", |
| 167 "objc/Framework/Classes/Metal/RTCMTLRenderer.h", |
| 168 "objc/Framework/Classes/Metal/RTCMTLRenderer.mm", |
| 169 ] |
| 170 if (is_ios) { |
| 171 sources += [ |
| 172 "objc/Framework/Classes/Metal/RTCMTLNV12Renderer.h", |
| 173 "objc/Framework/Classes/Metal/RTCMTLNV12Renderer.mm", |
| 174 "objc/Framework/Classes/Metal/RTCMTLVideoView.m", |
| 175 "objc/Framework/Headers/WebRTC/RTCMTLVideoView.h", |
| 176 ] |
| 177 } |
| 178 if (is_mac) { |
| 179 sources += [ |
| 180 "objc/Framework/Classes/Metal/RTCMTLNSVideoView.m", |
| 181 "objc/Framework/Headers/WebRTC/RTCMTLNSVideoView.h", |
| 182 ] |
| 183 } |
| 184 libs = [ |
| 185 "CoreVideo.framework", |
| 186 "Metal.framework", |
| 187 "MetalKit.framework", |
| 188 ] |
| 189 deps = [ |
| 190 ":objc_video", |
| 191 "../api:video_frame_api", |
| 192 "../base:rtc_base_approved", |
| 193 ] |
| 194 configs += [ "..:common_objc" ] |
| 195 public_configs = [ ":objc_common_config" ] |
| 196 } |
| 197 } |
| 198 |
| 199 rtc_static_library("objc_peerconnection") { |
| 200 sources = [ |
| 201 "objc/Framework/Classes/PeerConnection/RTCAVFoundationVideoSource+Privat
e.h", |
| 202 "objc/Framework/Classes/PeerConnection/RTCAVFoundationVideoSource.mm", |
| 203 "objc/Framework/Classes/PeerConnection/RTCAudioSource+Private.h", |
| 204 "objc/Framework/Classes/PeerConnection/RTCAudioSource.mm", |
| 205 "objc/Framework/Classes/PeerConnection/RTCAudioTrack+Private.h", |
| 206 "objc/Framework/Classes/PeerConnection/RTCAudioTrack.mm", |
| 207 "objc/Framework/Classes/PeerConnection/RTCCameraVideoCapturer.m", |
| 208 "objc/Framework/Classes/PeerConnection/RTCConfiguration+Private.h", |
| 209 "objc/Framework/Classes/PeerConnection/RTCConfiguration.mm", |
| 210 "objc/Framework/Classes/PeerConnection/RTCDataChannel+Private.h", |
| 211 "objc/Framework/Classes/PeerConnection/RTCDataChannel.mm", |
| 212 "objc/Framework/Classes/PeerConnection/RTCDataChannelConfiguration+Priva
te.h", |
| 213 "objc/Framework/Classes/PeerConnection/RTCDataChannelConfiguration.mm", |
| 214 "objc/Framework/Classes/PeerConnection/RTCIceCandidate+Private.h", |
| 215 "objc/Framework/Classes/PeerConnection/RTCIceCandidate.mm", |
| 216 "objc/Framework/Classes/PeerConnection/RTCIceServer+Private.h", |
| 217 "objc/Framework/Classes/PeerConnection/RTCIceServer.mm", |
| 218 "objc/Framework/Classes/PeerConnection/RTCLegacyStatsReport+Private.h", |
| 219 "objc/Framework/Classes/PeerConnection/RTCLegacyStatsReport.mm", |
| 220 "objc/Framework/Classes/PeerConnection/RTCMediaConstraints+Private.h", |
| 221 "objc/Framework/Classes/PeerConnection/RTCMediaConstraints.mm", |
| 222 "objc/Framework/Classes/PeerConnection/RTCMediaSource+Private.h", |
| 223 "objc/Framework/Classes/PeerConnection/RTCMediaSource.mm", |
| 224 "objc/Framework/Classes/PeerConnection/RTCMediaStream+Private.h", |
| 225 "objc/Framework/Classes/PeerConnection/RTCMediaStream.mm", |
| 226 "objc/Framework/Classes/PeerConnection/RTCMediaStreamTrack+Private.h", |
| 227 "objc/Framework/Classes/PeerConnection/RTCMediaStreamTrack.mm", |
| 228 "objc/Framework/Classes/PeerConnection/RTCMetrics.mm", |
| 229 "objc/Framework/Classes/PeerConnection/RTCMetricsSampleInfo+Private.h", |
| 230 "objc/Framework/Classes/PeerConnection/RTCMetricsSampleInfo.mm", |
| 231 "objc/Framework/Classes/PeerConnection/RTCPeerConnection+DataChannel.mm"
, |
| 232 "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Private.h", |
| 233 "objc/Framework/Classes/PeerConnection/RTCPeerConnection+Stats.mm", |
| 234 "objc/Framework/Classes/PeerConnection/RTCPeerConnection.mm", |
| 235 "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory+Private.
h", |
| 236 "objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory.mm", |
| 237 "objc/Framework/Classes/PeerConnection/RTCRtpCodecParameters+Private.h", |
| 238 "objc/Framework/Classes/PeerConnection/RTCRtpCodecParameters.mm", |
| 239 "objc/Framework/Classes/PeerConnection/RTCRtpEncodingParameters+Private.
h", |
| 240 "objc/Framework/Classes/PeerConnection/RTCRtpEncodingParameters.mm", |
| 241 "objc/Framework/Classes/PeerConnection/RTCRtpParameters+Private.h", |
| 242 "objc/Framework/Classes/PeerConnection/RTCRtpParameters.mm", |
| 243 "objc/Framework/Classes/PeerConnection/RTCRtpReceiver+Private.h", |
| 244 "objc/Framework/Classes/PeerConnection/RTCRtpReceiver.mm", |
| 245 "objc/Framework/Classes/PeerConnection/RTCRtpSender+Private.h", |
| 246 "objc/Framework/Classes/PeerConnection/RTCRtpSender.mm", |
| 247 "objc/Framework/Classes/PeerConnection/RTCSSLAdapter.mm", |
| 248 "objc/Framework/Classes/PeerConnection/RTCSessionDescription+Private.h", |
| 249 "objc/Framework/Classes/PeerConnection/RTCSessionDescription.mm", |
| 250 "objc/Framework/Classes/PeerConnection/RTCTracing.mm", |
| 251 "objc/Framework/Classes/PeerConnection/RTCVideoCapturer.m", |
| 252 "objc/Framework/Classes/PeerConnection/RTCVideoFrame+Private.h", |
| 253 "objc/Framework/Classes/PeerConnection/RTCVideoFrame.mm", |
| 254 "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter+Private.h
", |
| 255 "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter.h", |
| 256 "objc/Framework/Classes/PeerConnection/RTCVideoRendererAdapter.mm", |
| 257 "objc/Framework/Classes/PeerConnection/RTCVideoSource+Private.h", |
| 258 "objc/Framework/Classes/PeerConnection/RTCVideoSource.mm", |
| 259 "objc/Framework/Classes/PeerConnection/RTCVideoTrack+Private.h", |
| 260 "objc/Framework/Classes/PeerConnection/RTCVideoTrack.mm", |
391 "objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h", | 261 "objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h", |
392 "objc/Framework/Headers/WebRTC/RTCAudioSource.h", | 262 "objc/Framework/Headers/WebRTC/RTCAudioSource.h", |
393 "objc/Framework/Headers/WebRTC/RTCAudioTrack.h", | 263 "objc/Framework/Headers/WebRTC/RTCAudioTrack.h", |
394 "objc/Framework/Headers/WebRTC/RTCCameraVideoCapturer.h", | 264 "objc/Framework/Headers/WebRTC/RTCCameraVideoCapturer.h", |
395 "objc/Framework/Headers/WebRTC/RTCCameraPreviewView.h", | |
396 "objc/Framework/Headers/WebRTC/RTCConfiguration.h", | 265 "objc/Framework/Headers/WebRTC/RTCConfiguration.h", |
397 "objc/Framework/Headers/WebRTC/RTCDataChannel.h", | 266 "objc/Framework/Headers/WebRTC/RTCDataChannel.h", |
398 "objc/Framework/Headers/WebRTC/RTCDataChannelConfiguration.h", | 267 "objc/Framework/Headers/WebRTC/RTCDataChannelConfiguration.h", |
399 "objc/Framework/Headers/WebRTC/RTCDispatcher.h", | |
400 "objc/Framework/Headers/WebRTC/RTCEAGLVideoView.h", | |
401 "objc/Framework/Headers/WebRTC/RTCFieldTrials.h", | |
402 "objc/Framework/Headers/WebRTC/RTCIceCandidate.h", | 268 "objc/Framework/Headers/WebRTC/RTCIceCandidate.h", |
403 "objc/Framework/Headers/WebRTC/RTCIceServer.h", | 269 "objc/Framework/Headers/WebRTC/RTCIceServer.h", |
404 "objc/Framework/Headers/WebRTC/RTCLegacyStatsReport.h", | 270 "objc/Framework/Headers/WebRTC/RTCLegacyStatsReport.h", |
405 "objc/Framework/Headers/WebRTC/RTCLogging.h", | |
406 "objc/Framework/Headers/WebRTC/RTCMacros.h", | |
407 "objc/Framework/Headers/WebRTC/RTCMediaConstraints.h", | 271 "objc/Framework/Headers/WebRTC/RTCMediaConstraints.h", |
408 "objc/Framework/Headers/WebRTC/RTCMediaSource.h", | 272 "objc/Framework/Headers/WebRTC/RTCMediaSource.h", |
409 "objc/Framework/Headers/WebRTC/RTCMediaStream.h", | 273 "objc/Framework/Headers/WebRTC/RTCMediaStream.h", |
410 "objc/Framework/Headers/WebRTC/RTCMediaStreamTrack.h", | 274 "objc/Framework/Headers/WebRTC/RTCMediaStreamTrack.h", |
411 "objc/Framework/Headers/WebRTC/RTCMetrics.h", | 275 "objc/Framework/Headers/WebRTC/RTCMetrics.h", |
412 "objc/Framework/Headers/WebRTC/RTCMetricsSampleInfo.h", | 276 "objc/Framework/Headers/WebRTC/RTCMetricsSampleInfo.h", |
413 "objc/Framework/Headers/WebRTC/RTCPeerConnection.h", | 277 "objc/Framework/Headers/WebRTC/RTCPeerConnection.h", |
414 "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactory.h", | 278 "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactory.h", |
415 "objc/Framework/Headers/WebRTC/RTCRtpCodecParameters.h", | 279 "objc/Framework/Headers/WebRTC/RTCRtpCodecParameters.h", |
416 "objc/Framework/Headers/WebRTC/RTCRtpEncodingParameters.h", | 280 "objc/Framework/Headers/WebRTC/RTCRtpEncodingParameters.h", |
417 "objc/Framework/Headers/WebRTC/RTCRtpParameters.h", | 281 "objc/Framework/Headers/WebRTC/RTCRtpParameters.h", |
418 "objc/Framework/Headers/WebRTC/RTCRtpReceiver.h", | 282 "objc/Framework/Headers/WebRTC/RTCRtpReceiver.h", |
419 "objc/Framework/Headers/WebRTC/RTCRtpSender.h", | 283 "objc/Framework/Headers/WebRTC/RTCRtpSender.h", |
420 "objc/Framework/Headers/WebRTC/RTCSSLAdapter.h", | 284 "objc/Framework/Headers/WebRTC/RTCSSLAdapter.h", |
421 "objc/Framework/Headers/WebRTC/RTCSessionDescription.h", | 285 "objc/Framework/Headers/WebRTC/RTCSessionDescription.h", |
422 "objc/Framework/Headers/WebRTC/RTCTracing.h", | 286 "objc/Framework/Headers/WebRTC/RTCTracing.h", |
423 "objc/Framework/Headers/WebRTC/RTCVideoCapturer.h", | 287 "objc/Framework/Headers/WebRTC/RTCVideoCapturer.h", |
424 "objc/Framework/Headers/WebRTC/RTCVideoFrame.h", | 288 "objc/Framework/Headers/WebRTC/RTCVideoFrame.h", |
425 "objc/Framework/Headers/WebRTC/RTCVideoRenderer.h", | 289 "objc/Framework/Headers/WebRTC/RTCVideoRenderer.h", |
426 "objc/Framework/Headers/WebRTC/RTCVideoSource.h", | 290 "objc/Framework/Headers/WebRTC/RTCVideoSource.h", |
427 "objc/Framework/Headers/WebRTC/RTCVideoTrack.h", | 291 "objc/Framework/Headers/WebRTC/RTCVideoTrack.h", |
428 "objc/Framework/Headers/WebRTC/RTCVideoViewShading.h", | 292 "objc/Framework/Headers/WebRTC/RTCVideoViewShading.h", |
429 "objc/Framework/Headers/WebRTC/UIDevice+RTCDevice.h", | 293 ] |
430 "objc/Framework/Headers/WebRTC/WebRTC.h", | 294 |
431 ] | 295 libs = [ "AVFoundation.framework" ] |
| 296 |
| 297 if (is_ios) { |
| 298 libs += [ "CoreGraphics.framework" ] |
| 299 } |
| 300 |
| 301 configs += [ "..:common_objc" ] |
| 302 |
| 303 public_configs = [ ":objc_common_config" ] |
| 304 |
| 305 if (!build_with_chromium && is_clang) { |
| 306 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163)
. |
| 307 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 308 } |
| 309 |
| 310 deps = [ |
| 311 ":objc_common", |
| 312 ":objc_corevideoframebuffer", |
| 313 ":objc_video", |
| 314 "../api:video_frame_api", |
| 315 "../base:rtc_base", |
| 316 "../media:rtc_media_base", |
| 317 "../pc:libjingle_peerconnection", |
| 318 ] |
| 319 |
432 if (rtc_use_metal_rendering) { | 320 if (rtc_use_metal_rendering) { |
433 common_objc_headers += | 321 deps += [ ":objc_metal" ] |
434 [ "objc/Framework/Headers/WebRTC/RTCMTLVideoView.h" ] | 322 } |
435 } | 323 |
436 sources = common_objc_headers | 324 if (rtc_build_libyuv) { |
437 public_headers = common_objc_headers | 325 deps += [ "$rtc_libyuv_dir" ] |
438 | 326 public_deps = [ |
439 if (!build_with_chromium) { | 327 "$rtc_libyuv_dir", |
440 sources += [ "objc/Framework/Headers/WebRTC/RTCFileLogger.h" ] | 328 ] |
441 public_headers += [ "objc/Framework/Headers/WebRTC/RTCFileLogger.h" ] | 329 } |
442 } | 330 } |
443 | 331 |
444 ldflags = [ | 332 if (rtc_include_tests) { |
445 "-all_load", | 333 rtc_source_set("objc_sdk_unittests") { |
446 "-install_name", | 334 testonly = true |
447 "@rpath/$output_name.framework/$output_name", | 335 |
448 ] | 336 # Skip restricting visibility on mobile platforms since the tests on tho
se |
449 | 337 # gets additional generated targets which would require many lines here
to |
| 338 # cover (which would be confusing to read and hard to maintain). |
| 339 if (!is_android && !is_ios) { |
| 340 visibility = [ "..:rtc_unittests" ] |
| 341 } |
| 342 sources = [ |
| 343 "objc/Framework/UnitTests/RTCCameraVideoCapturerTests.mm", |
| 344 "objc/Framework/UnitTests/RTCConfigurationTest.mm", |
| 345 "objc/Framework/UnitTests/RTCDataChannelConfigurationTest.mm", |
| 346 "objc/Framework/UnitTests/RTCIceCandidateTest.mm", |
| 347 "objc/Framework/UnitTests/RTCIceServerTest.mm", |
| 348 "objc/Framework/UnitTests/RTCMediaConstraintsTest.mm", |
| 349 "objc/Framework/UnitTests/RTCPeerConnectionTest.mm", |
| 350 "objc/Framework/UnitTests/RTCSessionDescriptionTest.mm", |
| 351 "objc/Framework/UnitTests/avformatmappertests.mm", |
| 352 ] |
| 353 |
| 354 # |-ObjC| flag needed to make sure category method implementations |
| 355 # are included: |
| 356 # https://developer.apple.com/library/mac/qa/qa1490/_index.html |
| 357 ldflags = [ "-ObjC" ] |
| 358 |
| 359 defines = [ "GTEST_RELATIVE_PATH" ] |
| 360 deps = [ |
| 361 ":objc_peerconnection", |
| 362 "..//system_wrappers:system_wrappers_default", |
| 363 "../base:rtc_base_tests_utils", |
| 364 "../system_wrappers:system_wrappers_default", |
| 365 "//third_party/ocmock", |
| 366 ] |
| 367 |
| 368 # RTCMTLVideoView not supported on 32-bit arm |
| 369 if (is_ios && current_cpu != "arm") { |
| 370 sources += [ "objc/Framework/UnitTests/RTCMTLVideoViewTests.mm" ] |
| 371 if (current_cpu != "arm64") { |
| 372 # Only include this file on simulator, as it's already |
| 373 # included in device builds. |
| 374 sources += [ "objc/Framework/Classes/Metal/RTCMTLVideoView.m" ] |
| 375 libs = [ "CoreVideo.framework" ] |
| 376 } |
| 377 } |
| 378 |
| 379 if (!build_with_chromium && is_clang) { |
| 380 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/16
3). |
| 381 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 382 } |
| 383 } |
| 384 } |
| 385 |
| 386 if (is_ios) { |
| 387 ios_framework_bundle("objc_framework") { |
| 388 info_plist = "objc/Framework/Info.plist" |
| 389 output_name = "WebRTC" |
| 390 |
| 391 common_objc_headers = [ |
| 392 "objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h", |
| 393 "objc/Framework/Headers/WebRTC/RTCAudioSource.h", |
| 394 "objc/Framework/Headers/WebRTC/RTCAudioTrack.h", |
| 395 "objc/Framework/Headers/WebRTC/RTCCameraVideoCapturer.h", |
| 396 "objc/Framework/Headers/WebRTC/RTCCameraPreviewView.h", |
| 397 "objc/Framework/Headers/WebRTC/RTCConfiguration.h", |
| 398 "objc/Framework/Headers/WebRTC/RTCDataChannel.h", |
| 399 "objc/Framework/Headers/WebRTC/RTCDataChannelConfiguration.h", |
| 400 "objc/Framework/Headers/WebRTC/RTCDispatcher.h", |
| 401 "objc/Framework/Headers/WebRTC/RTCEAGLVideoView.h", |
| 402 "objc/Framework/Headers/WebRTC/RTCFieldTrials.h", |
| 403 "objc/Framework/Headers/WebRTC/RTCIceCandidate.h", |
| 404 "objc/Framework/Headers/WebRTC/RTCIceServer.h", |
| 405 "objc/Framework/Headers/WebRTC/RTCLegacyStatsReport.h", |
| 406 "objc/Framework/Headers/WebRTC/RTCLogging.h", |
| 407 "objc/Framework/Headers/WebRTC/RTCMacros.h", |
| 408 "objc/Framework/Headers/WebRTC/RTCMediaConstraints.h", |
| 409 "objc/Framework/Headers/WebRTC/RTCMediaSource.h", |
| 410 "objc/Framework/Headers/WebRTC/RTCMediaStream.h", |
| 411 "objc/Framework/Headers/WebRTC/RTCMediaStreamTrack.h", |
| 412 "objc/Framework/Headers/WebRTC/RTCMetrics.h", |
| 413 "objc/Framework/Headers/WebRTC/RTCMetricsSampleInfo.h", |
| 414 "objc/Framework/Headers/WebRTC/RTCPeerConnection.h", |
| 415 "objc/Framework/Headers/WebRTC/RTCPeerConnectionFactory.h", |
| 416 "objc/Framework/Headers/WebRTC/RTCRtpCodecParameters.h", |
| 417 "objc/Framework/Headers/WebRTC/RTCRtpEncodingParameters.h", |
| 418 "objc/Framework/Headers/WebRTC/RTCRtpParameters.h", |
| 419 "objc/Framework/Headers/WebRTC/RTCRtpReceiver.h", |
| 420 "objc/Framework/Headers/WebRTC/RTCRtpSender.h", |
| 421 "objc/Framework/Headers/WebRTC/RTCSSLAdapter.h", |
| 422 "objc/Framework/Headers/WebRTC/RTCSessionDescription.h", |
| 423 "objc/Framework/Headers/WebRTC/RTCTracing.h", |
| 424 "objc/Framework/Headers/WebRTC/RTCVideoCapturer.h", |
| 425 "objc/Framework/Headers/WebRTC/RTCVideoFrame.h", |
| 426 "objc/Framework/Headers/WebRTC/RTCVideoRenderer.h", |
| 427 "objc/Framework/Headers/WebRTC/RTCVideoSource.h", |
| 428 "objc/Framework/Headers/WebRTC/RTCVideoTrack.h", |
| 429 "objc/Framework/Headers/WebRTC/RTCVideoViewShading.h", |
| 430 "objc/Framework/Headers/WebRTC/UIDevice+RTCDevice.h", |
| 431 "objc/Framework/Headers/WebRTC/WebRTC.h", |
| 432 ] |
| 433 if (rtc_use_metal_rendering) { |
| 434 common_objc_headers += |
| 435 [ "objc/Framework/Headers/WebRTC/RTCMTLVideoView.h" ] |
| 436 } |
| 437 sources = common_objc_headers |
| 438 public_headers = common_objc_headers |
| 439 |
| 440 if (!build_with_chromium) { |
| 441 sources += [ "objc/Framework/Headers/WebRTC/RTCFileLogger.h" ] |
| 442 public_headers += [ "objc/Framework/Headers/WebRTC/RTCFileLogger.h" ] |
| 443 } |
| 444 |
| 445 ldflags = [ |
| 446 "-all_load", |
| 447 "-install_name", |
| 448 "@rpath/$output_name.framework/$output_name", |
| 449 ] |
| 450 |
| 451 deps = [ |
| 452 ":objc_peerconnection", |
| 453 ":objc_ui", |
| 454 "../base:rtc_base_approved", |
| 455 "../system_wrappers:field_trial_default", |
| 456 "../system_wrappers:metrics_default", |
| 457 ] |
| 458 |
| 459 libs = [ |
| 460 "AVFoundation.framework", |
| 461 "CoreGraphics.framework", |
| 462 "CoreMedia.framework", |
| 463 "GLKit.framework", |
| 464 ] |
| 465 |
| 466 configs += [ "..:common_objc" ] |
| 467 |
| 468 public_configs = [ ":objc_common_config" ] |
| 469 |
| 470 if (!build_with_chromium && is_clang) { |
| 471 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/16
3) |
| 472 configs -= [ "//build/config/clang:find_bad_constructs" ] |
| 473 } |
| 474 } |
| 475 } |
| 476 |
| 477 rtc_static_library("rtc_sdk_objc") { |
| 478 complete_static_lib = true |
450 deps = [ | 479 deps = [ |
451 ":objc_peerconnection", | 480 ":objc_peerconnection", |
452 ":objc_ui", | 481 ":objc_ui", |
453 "../base:rtc_base_approved", | |
454 "../system_wrappers:field_trial_default", | 482 "../system_wrappers:field_trial_default", |
455 "../system_wrappers:metrics_default", | 483 "../system_wrappers:metrics_default", |
456 ] | 484 ] |
| 485 } |
| 486 |
| 487 rtc_static_library("objc_corevideoframebuffer") { |
| 488 sources = [ |
| 489 "objc/Framework/Classes/Video/corevideo_frame_buffer.cc", |
| 490 "objc/Framework/Classes/Video/corevideo_frame_buffer.h", |
| 491 |
| 492 # TODO(mbonadei): remove this backward compatibility header |
| 493 "objc/Framework/Classes/corevideo_frame_buffer.h", |
| 494 ] |
| 495 |
| 496 deps = [ |
| 497 "../base:rtc_base_approved", |
| 498 "../common_video", |
| 499 ] |
| 500 |
| 501 if (!build_with_chromium && is_clang) { |
| 502 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163)
. |
| 503 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
| 504 } |
| 505 |
| 506 libs = [ "CoreVideo.framework" ] |
| 507 } |
| 508 |
| 509 rtc_static_library("objc_videotoolbox") { |
| 510 sources = [ |
| 511 "objc/Framework/Classes/VideoToolbox/decoder.cc", |
| 512 "objc/Framework/Classes/VideoToolbox/decoder.h", |
| 513 "objc/Framework/Classes/VideoToolbox/encoder.h", |
| 514 "objc/Framework/Classes/VideoToolbox/encoder.mm", |
| 515 "objc/Framework/Classes/VideoToolbox/nalu_rewriter.cc", |
| 516 "objc/Framework/Classes/VideoToolbox/nalu_rewriter.h", |
| 517 "objc/Framework/Classes/VideoToolbox/videocodecfactory.cc", |
| 518 "objc/Framework/Classes/VideoToolbox/videocodecfactory.h", |
| 519 ] |
| 520 |
| 521 configs += [ "..:common_objc" ] |
| 522 |
| 523 deps = [ |
| 524 ":objc_common", |
| 525 ":objc_corevideoframebuffer", |
| 526 "../base:rtc_base_approved", |
| 527 "../common_video", |
| 528 "../media:rtc_media", |
| 529 "../media:rtc_media_base", |
| 530 "../modules:module_api", |
| 531 "../modules/video_coding:video_coding_utility", |
| 532 "../modules/video_coding:webrtc_h264", |
| 533 "../system_wrappers", |
| 534 ] |
457 | 535 |
458 libs = [ | 536 libs = [ |
459 "AVFoundation.framework", | 537 "CoreFoundation.framework", |
460 "CoreGraphics.framework", | |
461 "CoreMedia.framework", | 538 "CoreMedia.framework", |
462 "GLKit.framework", | 539 "CoreVideo.framework", |
463 ] | 540 "VideoToolbox.framework", |
464 | 541 ] |
465 configs += [ "..:common_objc" ] | |
466 | |
467 public_configs = [ ":objc_common_config" ] | |
468 | 542 |
469 if (!build_with_chromium && is_clang) { | 543 if (!build_with_chromium && is_clang) { |
470 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163) | 544 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163)
. |
471 configs -= [ "//build/config/clang:find_bad_constructs" ] | 545 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] |
472 } | 546 } |
473 } | 547 |
474 } | 548 if (rtc_build_libyuv) { |
475 | 549 deps += [ "$rtc_libyuv_dir" ] |
476 rtc_static_library("rtc_sdk_objc") { | 550 public_deps = [ |
477 complete_static_lib = true | 551 "$rtc_libyuv_dir", |
478 deps = [ | 552 ] |
479 ":objc_peerconnection", | 553 } else { |
480 ":objc_ui", | 554 # Need to add a directory normally exported by libyuv. |
481 "../system_wrappers:field_trial_default", | 555 include_dirs = [ "$rtc_libyuv_dir/include" ] |
482 "../system_wrappers:metrics_default", | 556 } |
483 ] | |
484 } | |
485 | |
486 rtc_static_library("objc_corevideoframebuffer") { | |
487 sources = [ | |
488 "objc/Framework/Classes/Video/corevideo_frame_buffer.cc", | |
489 "objc/Framework/Classes/Video/corevideo_frame_buffer.h", | |
490 | |
491 # TODO(mbonadei): remove this backward compatibility header | |
492 "objc/Framework/Classes/corevideo_frame_buffer.h", | |
493 ] | |
494 | |
495 deps = [ | |
496 "../base:rtc_base_approved", | |
497 "../common_video", | |
498 ] | |
499 | |
500 if (!build_with_chromium && is_clang) { | |
501 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). | |
502 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | |
503 } | |
504 | |
505 libs = [ "CoreVideo.framework" ] | |
506 } | |
507 | |
508 rtc_static_library("objc_videotoolbox") { | |
509 sources = [ | |
510 "objc/Framework/Classes/VideoToolbox/decoder.cc", | |
511 "objc/Framework/Classes/VideoToolbox/decoder.h", | |
512 "objc/Framework/Classes/VideoToolbox/encoder.h", | |
513 "objc/Framework/Classes/VideoToolbox/encoder.mm", | |
514 "objc/Framework/Classes/VideoToolbox/nalu_rewriter.cc", | |
515 "objc/Framework/Classes/VideoToolbox/nalu_rewriter.h", | |
516 "objc/Framework/Classes/VideoToolbox/videocodecfactory.cc", | |
517 "objc/Framework/Classes/VideoToolbox/videocodecfactory.h", | |
518 ] | |
519 | |
520 configs += [ "..:common_objc" ] | |
521 | |
522 deps = [ | |
523 ":objc_common", | |
524 ":objc_corevideoframebuffer", | |
525 "../base:rtc_base_approved", | |
526 "../common_video", | |
527 "../media:rtc_media", | |
528 "../media:rtc_media_base", | |
529 "../modules:module_api", | |
530 "../modules/video_coding:video_coding_utility", | |
531 "../modules/video_coding:webrtc_h264", | |
532 "../system_wrappers", | |
533 ] | |
534 | |
535 libs = [ | |
536 "CoreFoundation.framework", | |
537 "CoreMedia.framework", | |
538 "CoreVideo.framework", | |
539 "VideoToolbox.framework", | |
540 ] | |
541 | |
542 if (!build_with_chromium && is_clang) { | |
543 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163). | |
544 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] | |
545 } | |
546 | |
547 if (rtc_build_libyuv) { | |
548 deps += [ "$rtc_libyuv_dir" ] | |
549 public_deps = [ | |
550 "$rtc_libyuv_dir", | |
551 ] | |
552 } else { | |
553 # Need to add a directory normally exported by libyuv. | |
554 include_dirs = [ "$rtc_libyuv_dir/include" ] | |
555 } | 557 } |
556 } | 558 } |
557 } | 559 } |
OLD | NEW |