blob: a4c1c1d45fdd9c5a1733027ce55ba6ff76a9e83b [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)',
Bjorn Terelius36411852015-07-30 12:45:18 +020035 'rtc_event_log',
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 {
48 'target_name': 'rtc_event_log',
49 'type': 'static_library',
50 'sources': [
Peter Boström5c389d32015-09-25 13:58:30 +020051 'call/rtc_event_log.cc',
52 'call/rtc_event_log.h',
terelius4311ba52016-04-22 12:40:37 -070053 'call/rtc_event_log_helper_thread.cc',
54 'call/rtc_event_log_helper_thread.h',
Bjorn Terelius36411852015-07-30 12:45:18 +020055 ],
56 'conditions': [
57 # If enable_protobuf is defined, we want to compile the protobuf
58 # and add rtc_event_log.pb.h and rtc_event_log.pb.cc to the sources.
59 ['enable_protobuf==1', {
60 'dependencies': [
61 'rtc_event_log_proto',
62 ],
63 'defines': [
64 'ENABLE_RTC_EVENT_LOG',
65 ],
66 }],
67 ],
68 },
kjellander86600242016-06-14 02:09:19 -070069 ], # targets
70 'conditions': [
71 ['include_tests==1', {
72 'includes': [
73 'webrtc_tests.gypi',
74 ],
75 }],
76 ['enable_protobuf==1', {
77 'targets': [
78 {
79 # This target should only be built if enable_protobuf is defined
80 'target_name': 'rtc_event_log_proto',
81 'type': 'static_library',
82 'sources': ['call/rtc_event_log.proto',],
83 'variables': {
84 'proto_in_dir': 'call',
85 'proto_out_dir': 'webrtc/call',
86 },
87 'includes': ['build/protoc.gypi'],
88 },
89 {
90 'target_name': 'rtc_event_log_parser',
91 'type': 'static_library',
92 'sources': [
93 'call/rtc_event_log_parser.cc',
94 'call/rtc_event_log_parser.h',
95 ],
96 'dependencies': [
97 'rtc_event_log_proto',
98 ],
99 'export_dependent_settings': [
100 'rtc_event_log_proto',
101 ],
102 },
103 ],
104 }],
105 ['include_tests==1 and enable_protobuf==1', {
106 'targets': [
107 {
108 'target_name': 'rtc_event_log2rtp_dump',
109 'type': 'executable',
110 'sources': ['call/rtc_event_log2rtp_dump.cc',],
111 'dependencies': [
112 '<(DEPTH)/third_party/gflags/gflags.gyp:gflags',
113 'rtc_event_log_parser',
114 'rtc_event_log_proto',
115 'test/test.gyp:rtp_test_utils'
116 ],
117 },
118 ],
119 }],
120 ], # conditions
henrike@webrtc.org8d27a1c2013-07-23 18:15:11 +0000121}