blob: 7591f22071b493ace9adf97c6e47e359210d123c [file] [log] [blame]
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +00001# Copyright (c) 2012 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.
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +00008{
Henrik Kjellander15583c12016-02-10 10:53:12 +01009 'variables': {
10 'webrtc_all_dependencies': [
11 'base/base.gyp:*',
Henrik Kjellander15583c12016-02-10 10:53:12 +010012 'common.gyp:*',
13 'common_audio/common_audio.gyp:*',
14 'common_video/common_video.gyp:*',
15 'media/media.gyp:*',
16 'modules/modules.gyp:*',
17 'p2p/p2p.gyp:*',
18 'system_wrappers/system_wrappers.gyp:*',
19 'tools/tools.gyp:*',
20 'voice_engine/voice_engine.gyp:*',
21 '<(webrtc_vp8_dir)/vp8.gyp:*',
22 '<(webrtc_vp9_dir)/vp9.gyp:*',
23 ],
24 },
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000025 'conditions': [
Henrik Kjellander15583c12016-02-10 10:53:12 +010026 ['build_with_chromium==0', {
27 # TODO(kjellander): Move this to webrtc_all_dependencies once all of talk/
28 # has been moved to webrtc/. It can't be processed by Chromium since the
29 # reference to buid/java.gypi is using an absolute path (and includes
30 # entries cannot contain variables).
31 'variables': {
32 'webrtc_all_dependencies': [
33 'api/api.gyp:*',
34 ],
35 },
36 }],
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000037 ['include_tests==1', {
38 'includes': [
39 'webrtc_tests.gypi',
40 ],
41 }],
Bjorn Terelius36411852015-07-30 12:45:18 +020042 ['enable_protobuf==1', {
43 'targets': [
44 {
45 # This target should only be built if enable_protobuf is defined
46 'target_name': 'rtc_event_log_proto',
47 'type': 'static_library',
Peter Boström5c389d32015-09-25 13:58:30 +020048 'sources': ['call/rtc_event_log.proto',],
Bjorn Terelius36411852015-07-30 12:45:18 +020049 'variables': {
Peter Boström5c389d32015-09-25 13:58:30 +020050 'proto_in_dir': 'call',
51 'proto_out_dir': 'webrtc/call',
Bjorn Terelius36411852015-07-30 12:45:18 +020052 },
53 'includes': ['build/protoc.gypi'],
54 },
55 ],
56 }],
Ivo Creusene1aa5b52015-09-18 15:41:07 +020057 ['include_tests==1 and enable_protobuf==1', {
58 'targets': [
59 {
60 'target_name': 'rtc_event_log2rtp_dump',
61 'type': 'executable',
Peter Boström5c389d32015-09-25 13:58:30 +020062 'sources': ['call/rtc_event_log2rtp_dump.cc',],
Ivo Creusene1aa5b52015-09-18 15:41:07 +020063 'dependencies': [
64 '<(DEPTH)/third_party/gflags/gflags.gyp:gflags',
65 'rtc_event_log',
66 'rtc_event_log_proto',
67 'test/test.gyp:rtp_test_utils'
68 ],
69 },
70 ],
71 }],
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000072 ],
73 'includes': [
74 'build/common.gypi',
Peter Boström5c389d32015-09-25 13:58:30 +020075 'audio/webrtc_audio.gypi',
76 'call/webrtc_call.gypi',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000077 'video/webrtc_video.gypi',
78 ],
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000079 'targets': [
80 {
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000081 'target_name': 'webrtc_all',
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000082 'type': 'none',
83 'dependencies': [
84 '<@(webrtc_all_dependencies)',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000085 'webrtc',
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000086 ],
87 'conditions': [
88 ['include_tests==1', {
89 'dependencies': [
Henrik Kjellander15583c12016-02-10 10:53:12 +010090 'api/api_tests.gyp:*',
pbos@webrtc.org724947b2013-12-11 16:26:16 +000091 'common_video/common_video_unittests.gyp:*',
Peter Boström2ee24392015-06-22 07:57:16 +020092 'rtc_unittests',
andresp@webrtc.org86e1e482015-01-14 09:30:52 +000093 'system_wrappers/system_wrappers_tests.gyp:*',
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000094 'test/metrics.gyp:*',
95 'test/test.gyp:*',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000096 'webrtc_tests',
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000097 ],
98 }],
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000099 ],
100 },
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000101 {
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000102 'target_name': 'webrtc',
103 'type': 'static_library',
104 'sources': [
kjellander7324eb92016-02-25 08:36:42 -0800105 'audio_receive_stream.h',
Jelena Marusiccd670222015-07-16 09:30:09 +0200106 'audio_send_stream.h',
solenberg566ef242015-11-06 15:34:49 -0800107 'audio_state.h',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000108 'call.h',
kjellander7324eb92016-02-25 08:36:42 -0800109 'config.h',
110 'frame_callback.h',
111 'stream.h',
112 'transport.h',
113 'video_receive_stream.h',
kjellander7324eb92016-02-25 08:36:42 -0800114 'video_send_stream.h',
115
Peter Boström5c389d32015-09-25 13:58:30 +0200116 '<@(webrtc_audio_sources)',
117 '<@(webrtc_call_sources)',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000118 '<@(webrtc_video_sources)',
119 ],
120 'dependencies': [
pbos@webrtc.org1e92b0a2014-05-15 09:35:06 +0000121 'common.gyp:*',
Peter Boström5c389d32015-09-25 13:58:30 +0200122 '<@(webrtc_audio_dependencies)',
123 '<@(webrtc_call_dependencies)',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000124 '<@(webrtc_video_dependencies)',
Bjorn Terelius36411852015-07-30 12:45:18 +0200125 'rtc_event_log',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000126 ],
andresp@webrtc.orgab071da2014-09-18 08:58:15 +0000127 'conditions': [
Henrik Kjellander6ffc3302015-10-08 14:40:51 +0200128 # TODO(andresp): Chromium should link directly with this and no if
129 # conditions should be needed on webrtc build files.
andresp@webrtc.orgab071da2014-09-18 08:58:15 +0000130 ['build_with_chromium==1', {
pbos@webrtc.orga7f77722014-12-15 16:33:16 +0000131 'dependencies': [
kjellander@webrtc.orgf58fe0a2015-02-11 07:47:00 +0000132 '<(webrtc_root)/modules/modules.gyp:video_capture',
133 '<(webrtc_root)/modules/modules.gyp:video_render',
pbos@webrtc.orga7f77722014-12-15 16:33:16 +0000134 ],
135 }],
andresp@webrtc.orgab071da2014-09-18 08:58:15 +0000136 ],
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000137 },
Bjorn Terelius36411852015-07-30 12:45:18 +0200138 {
139 'target_name': 'rtc_event_log',
140 'type': 'static_library',
141 'sources': [
Peter Boström5c389d32015-09-25 13:58:30 +0200142 'call/rtc_event_log.cc',
143 'call/rtc_event_log.h',
Bjorn Terelius36411852015-07-30 12:45:18 +0200144 ],
145 'conditions': [
146 # If enable_protobuf is defined, we want to compile the protobuf
147 # and add rtc_event_log.pb.h and rtc_event_log.pb.cc to the sources.
148 ['enable_protobuf==1', {
149 'dependencies': [
150 'rtc_event_log_proto',
151 ],
152 'defines': [
153 'ENABLE_RTC_EVENT_LOG',
154 ],
155 }],
156 ],
157 },
158
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +0000159 ],
160}