blob: eac8b97ec6220451da986bdd581931d31933cf0c [file] [log] [blame]
pbos@webrtc.org16e03b72013-10-28 16:32:01 +00001# Copyright (c) 2013 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.
8{
9 'includes': [
10 '../build/common.gypi',
11 ],
12 'targets': [
13 {
14 'target_name': 'webrtc_test_common',
15 'type': 'static_library',
16 'sources': [
sprang@webrtc.org8b881922013-12-10 10:05:17 +000017 'configurable_frame_size_encoder.cc',
18 'configurable_frame_size_encoder.h',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000019 'direct_transport.cc',
20 'direct_transport.h',
stefan@webrtc.orgb082ade2013-11-18 11:45:11 +000021 'fake_audio_device.cc',
22 'fake_audio_device.h',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000023 'fake_decoder.cc',
24 'fake_decoder.h',
25 'fake_encoder.cc',
26 'fake_encoder.h',
stefan@webrtc.orgfaada6e2013-12-18 20:28:25 +000027 'fake_network_pipe.cc',
28 'fake_network_pipe.h',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000029 'flags.cc',
30 'flags.h',
31 'frame_generator_capturer.cc',
32 'frame_generator_capturer.h',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000033 'gl/gl_renderer.cc',
34 'gl/gl_renderer.h',
35 'linux/glx_renderer.cc',
36 'linux/glx_renderer.h',
37 'linux/video_renderer_linux.cc',
38 'mac/run_tests.mm',
39 'mac/video_renderer_mac.h',
40 'mac/video_renderer_mac.mm',
stefan@webrtc.org7e9315b2013-12-04 10:24:26 +000041 'mock_transport.h',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000042 'null_platform_renderer.cc',
43 'null_transport.cc',
44 'null_transport.h',
45 'rtp_rtcp_observer.h',
46 'run_tests.cc',
47 'run_tests.h',
48 'run_loop.cc',
49 'run_loop.h',
50 'statistics.cc',
51 'statistics.h',
52 'vcm_capturer.cc',
53 'vcm_capturer.h',
54 'video_capturer.cc',
55 'video_capturer.h',
56 'video_renderer.cc',
57 'video_renderer.h',
58 'win/d3d_renderer.cc',
59 'win/d3d_renderer.h',
60 'win/run_loop_win.cc',
61 ],
62 'conditions': [
63 ['OS=="linux"', {
64 'sources!': [
65 'null_platform_renderer.cc',
66 ],
67 }],
68 ['OS=="mac"', {
69 'sources!': [
70 'null_platform_renderer.cc',
71 'run_tests.cc',
72 ],
73 }],
74 ['OS!="linux" and OS!="mac"', {
75 'sources!' : [
76 'gl/gl_renderer.cc',
77 'gl/gl_renderer.h',
78 ],
79 }],
80 ['OS=="win"', {
81 'sources!': [
82 'null_platform_renderer.cc',
83 'run_loop.cc',
84 ],
85 }],
86 ],
87 'direct_dependent_settings': {
88 'conditions': [
89 ['OS=="linux"', {
90 'libraries': [
91 '-lXext',
92 '-lX11',
93 '-lGL',
94 ],
95 }],
96 #TODO(pbos) : These dependencies should not have to be here, they
97 # aren't used by test code directly, only by components
98 # used by the tests.
99 ['OS=="android"', {
100 'libraries' : [
101 '-lGLESv2', '-llog',
102 ],
103 }],
104 ['OS=="mac"', {
105 'xcode_settings' : {
106 'OTHER_LDFLAGS' : [
107 '-framework Foundation',
108 '-framework AppKit',
109 '-framework Cocoa',
110 '-framework OpenGL',
111 '-framework CoreVideo',
112 '-framework CoreAudio',
113 '-framework AudioToolbox',
114 ],
115 },
116 }],
117 ],
118 },
119 'dependencies': [
120 '<(DEPTH)/testing/gtest.gyp:gtest',
121 '<(DEPTH)/third_party/gflags/gflags.gyp:gflags',
122 '<(webrtc_root)/modules/modules.gyp:video_capture_module',
stefan@webrtc.orgb082ade2013-11-18 11:45:11 +0000123 '<(webrtc_root)/modules/modules.gyp:media_file',
pbos@webrtc.org724947b2013-12-11 16:26:16 +0000124 '<(webrtc_root)/test/test.gyp:frame_generator',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000125 '<(webrtc_root)/test/test.gyp:test_support',
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000126 ],
127 },
128 ],
stefan@webrtc.orgfaada6e2013-12-18 20:28:25 +0000129 'conditions': [
130 ['include_tests==1', {
131 'targets': [
132 {
133 'target_name': 'webrtc_test_common_unittests',
134 'type': '<(gtest_target_type)',
135 'dependencies': [
136 'webrtc_test_common',
137 '<(DEPTH)/testing/gtest.gyp:gtest',
138 '<(DEPTH)/testing/gmock.gyp:gmock',
139 '<(webrtc_root)/test/test.gyp:test_support_main',
140 ],
141 'sources': [
142 'fake_network_pipe_unittest.cc',
143 ],
144 },
145 ], #targets
146 }], # include_tests
147 ], # conditions
pbos@webrtc.org16e03b72013-10-28 16:32:01 +0000148}