blob: 98d9498366543e10e791782ca7a7a6cd1018c37d [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{
pbos@webrtc.org16e03b72013-10-28 16:32:01 +00009 'includes': [
10 'build/common.gypi',
Peter Boström5c389d32015-09-25 13:58:30 +020011 'audio/webrtc_audio.gypi',
12 'call/webrtc_call.gypi',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000013 'video/webrtc_video.gypi',
14 ],
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +000015 'targets': [
16 {
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000017 'target_name': 'webrtc',
18 'type': 'static_library',
19 'sources': [
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000020 'call.h',
kjellander84f8df72016-05-18 05:00:50 -070021 'config.h',
kjellander7324eb92016-02-25 08:36:42 -080022 'transport.h',
23 'video_receive_stream.h',
kjellander7324eb92016-02-25 08:36:42 -080024 'video_send_stream.h',
25
Peter Boström5c389d32015-09-25 13:58:30 +020026 '<@(webrtc_audio_sources)',
27 '<@(webrtc_call_sources)',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000028 '<@(webrtc_video_sources)',
29 ],
30 'dependencies': [
pbos@webrtc.org1e92b0a2014-05-15 09:35:06 +000031 'common.gyp:*',
Peter Boström5c389d32015-09-25 13:58:30 +020032 '<@(webrtc_audio_dependencies)',
33 '<@(webrtc_call_dependencies)',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000034 '<@(webrtc_video_dependencies)',
skvladcc91d282016-10-03 18:31:22 -070035 'rtc_event_log_impl',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000036 ],
andresp@webrtc.orgab071da2014-09-18 08:58:15 +000037 'conditions': [
Henrik Kjellander6ffc3302015-10-08 14:40:51 +020038 # TODO(andresp): Chromium should link directly with this and no if
39 # conditions should be needed on webrtc build files.
andresp@webrtc.orgab071da2014-09-18 08:58:15 +000040 ['build_with_chromium==1', {
pbos@webrtc.orga7f77722014-12-15 16:33:16 +000041 'dependencies': [
kjellander@webrtc.orgf58fe0a2015-02-11 07:47:00 +000042 '<(webrtc_root)/modules/modules.gyp:video_capture',
pbos@webrtc.orga7f77722014-12-15 16:33:16 +000043 ],
44 }],
andresp@webrtc.orgab071da2014-09-18 08:58:15 +000045 ],
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000046 },
Bjorn Terelius36411852015-07-30 12:45:18 +020047 {
skvladcc91d282016-10-03 18:31:22 -070048 'target_name': 'rtc_event_log_api',
Bjorn Terelius36411852015-07-30 12:45:18 +020049 'type': 'static_library',
50 'sources': [
skvladcc91d282016-10-03 18:31:22 -070051 'logging/rtc_event_log/rtc_event_log.h',
52 ],
53 },
54 {
55 'target_name': 'rtc_event_log_impl',
56 'type': 'static_library',
57 'sources': [
58 'logging/rtc_event_log/ringbuffer.h',
59 'logging/rtc_event_log/rtc_event_log.cc',
60 'logging/rtc_event_log/rtc_event_log_helper_thread.cc',
61 'logging/rtc_event_log/rtc_event_log_helper_thread.h',
Bjorn Terelius36411852015-07-30 12:45:18 +020062 ],
63 'conditions': [
64 # If enable_protobuf is defined, we want to compile the protobuf
65 # and add rtc_event_log.pb.h and rtc_event_log.pb.cc to the sources.
66 ['enable_protobuf==1', {
67 'dependencies': [
skvladcc91d282016-10-03 18:31:22 -070068 'rtc_event_log_api',
Bjorn Terelius36411852015-07-30 12:45:18 +020069 'rtc_event_log_proto',
70 ],
71 'defines': [
72 'ENABLE_RTC_EVENT_LOG',
73 ],
74 }],
75 ],
76 },
kjellander86600242016-06-14 02:09:19 -070077 ], # targets
78 'conditions': [
79 ['include_tests==1', {
80 'includes': [
81 'webrtc_tests.gypi',
82 ],
83 }],
84 ['enable_protobuf==1', {
85 'targets': [
86 {
87 # This target should only be built if enable_protobuf is defined
88 'target_name': 'rtc_event_log_proto',
89 'type': 'static_library',
skvladcc91d282016-10-03 18:31:22 -070090 'sources': ['logging/rtc_event_log/rtc_event_log.proto',],
kjellander86600242016-06-14 02:09:19 -070091 'variables': {
skvladcc91d282016-10-03 18:31:22 -070092 'proto_in_dir': 'logging/rtc_event_log',
93 'proto_out_dir': 'webrtc/logging/rtc_event_log',
kjellander86600242016-06-14 02:09:19 -070094 },
95 'includes': ['build/protoc.gypi'],
96 },
97 {
98 'target_name': 'rtc_event_log_parser',
99 'type': 'static_library',
100 'sources': [
skvladcc91d282016-10-03 18:31:22 -0700101 'logging/rtc_event_log/rtc_event_log_parser.cc',
102 'logging/rtc_event_log/rtc_event_log_parser.h',
kjellander86600242016-06-14 02:09:19 -0700103 ],
104 'dependencies': [
105 'rtc_event_log_proto',
106 ],
107 'export_dependent_settings': [
108 'rtc_event_log_proto',
109 ],
110 },
111 ],
112 }],
113 ['include_tests==1 and enable_protobuf==1', {
114 'targets': [
115 {
116 'target_name': 'rtc_event_log2rtp_dump',
117 'type': 'executable',
skvladcc91d282016-10-03 18:31:22 -0700118 'sources': ['logging/rtc_event_log2rtp_dump.cc',],
kjellander86600242016-06-14 02:09:19 -0700119 'dependencies': [
120 '<(DEPTH)/third_party/gflags/gflags.gyp:gflags',
121 'rtc_event_log_parser',
122 'rtc_event_log_proto',
123 'test/test.gyp:rtp_test_utils'
124 ],
125 },
126 ],
127 }],
128 ], # conditions
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +0000129}