blob: 1447a99183aeee054c53b8019a09f28499b0fde7 [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',
solenberg940b6d62016-10-25 11:19:07 -070070 '<(webrtc_root)/api/api.gyp:call_api',
Bjorn Terelius36411852015-07-30 12:45:18 +020071 ],
72 'defines': [
73 'ENABLE_RTC_EVENT_LOG',
74 ],
75 }],
76 ],
77 },
kjellander86600242016-06-14 02:09:19 -070078 ], # targets
79 'conditions': [
80 ['include_tests==1', {
81 'includes': [
82 'webrtc_tests.gypi',
83 ],
84 }],
85 ['enable_protobuf==1', {
86 'targets': [
87 {
88 # This target should only be built if enable_protobuf is defined
89 'target_name': 'rtc_event_log_proto',
90 'type': 'static_library',
skvladcc91d282016-10-03 18:31:22 -070091 'sources': ['logging/rtc_event_log/rtc_event_log.proto',],
kjellander86600242016-06-14 02:09:19 -070092 'variables': {
skvladcc91d282016-10-03 18:31:22 -070093 'proto_in_dir': 'logging/rtc_event_log',
94 'proto_out_dir': 'webrtc/logging/rtc_event_log',
kjellander86600242016-06-14 02:09:19 -070095 },
96 'includes': ['build/protoc.gypi'],
97 },
98 {
99 'target_name': 'rtc_event_log_parser',
100 'type': 'static_library',
101 'sources': [
skvladcc91d282016-10-03 18:31:22 -0700102 'logging/rtc_event_log/rtc_event_log_parser.cc',
103 'logging/rtc_event_log/rtc_event_log_parser.h',
kjellander86600242016-06-14 02:09:19 -0700104 ],
105 'dependencies': [
106 'rtc_event_log_proto',
107 ],
108 'export_dependent_settings': [
109 'rtc_event_log_proto',
110 ],
111 },
112 ],
113 }],
114 ['include_tests==1 and enable_protobuf==1', {
115 'targets': [
116 {
117 'target_name': 'rtc_event_log2rtp_dump',
118 'type': 'executable',
skvladcc91d282016-10-03 18:31:22 -0700119 'sources': ['logging/rtc_event_log2rtp_dump.cc',],
kjellander86600242016-06-14 02:09:19 -0700120 'dependencies': [
121 '<(DEPTH)/third_party/gflags/gflags.gyp:gflags',
122 'rtc_event_log_parser',
123 'rtc_event_log_proto',
124 'test/test.gyp:rtp_test_utils'
125 ],
126 },
127 ],
128 }],
129 ], # conditions
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +0000130}