Don't consider a Bluetooth adapter present until it has an address.
[chromium-blink-merge.git] / ppapi / ppapi_tests.gypi
blobe9aa4da00001eba6330afdd0f8d00ee3aad5ff05
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6   'targets': [
7     {
8       'target_name': 'ppapi_tests',
9       'type': 'loadable_module',
10       'include_dirs': [
11         'lib/gl/include',
12       ],
13       'defines': [
14         'GL_GLEXT_PROTOTYPES',
15       ],
16       'sources': [
17         '<@(test_common_source_files)',
18         '<@(test_trusted_source_files)',
19       ],
20       'dependencies': [
21         'ppapi.gyp:ppapi_cpp',
22         'ppapi_internal.gyp:ppapi_shared',
23       ],
24       'copies': [
25         {
26           'destination': '<(PRODUCT_DIR)',
27           'files': [
28             # Keep 'test_case.html.mock-http-headers' with 'test_case.html'.
29             'tests/test_case.html',
30             'tests/test_case.html.mock-http-headers',
31             'tests/test_page.css',
32             'native_client/tests/ppapi_tests/ppapi_nacl_tests_newlib.nmf',
33           ],
34         },
35         {
36           'destination': '<(PRODUCT_DIR)/test_url_loader_data',
37           'files': [
38             'tests/test_url_loader_data/hello.txt',
39           ],
40         },
41       ],
42       'run_as': {
43         'action': [
44           '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)chrome<(EXECUTABLE_SUFFIX)',
45           '--enable-pepper-testing',
46           '--enable-accelerated-plugins',
47           '--register-pepper-plugins=$(TargetPath);application/x-ppapi-tests',
48           'file://$(ProjectDir)/tests/test_case.html?testcase=',
49         ],
50       },
51       'conditions': [
52         ['OS=="win"', {
53           'defines': [
54             '_CRT_SECURE_NO_DEPRECATE',
55             '_CRT_NONSTDC_NO_WARNINGS',
56             '_CRT_NONSTDC_NO_DEPRECATE',
57             '_SCL_SECURE_NO_DEPRECATE',
58           ],
59         }],
60         ['OS=="mac"', {
61           'mac_bundle': 1,
62           'product_name': 'ppapi_tests',
63           'product_extension': 'plugin',
64         }],
65       ],
66 # TODO(dmichael):  Figure out what is wrong with the script on Windows and add
67 #                  it as an automated action.
68 #      'actions': [
69 #        {
70 #          'action_name': 'generate_ppapi_include_tests',
71 #          'inputs': [],
72 #          'outputs': [
73 #            'tests/test_c_includes.c',
74 #            'tests/test_cc_includes.cc',
75 #          ],
76 #          'action': [
77 #            '<!@(python generate_ppapi_include_tests.py)',
78 #          ],
79 #        },
80 #      ],
81     },
82     {
83       'target_name': 'ppapi_unittest_shared',
84       'type': 'static_library',
85       'dependencies': [
86         'ppapi_proxy',
87         'ppapi_shared',
88         '../base/base.gyp:test_support_base',
89         '../ipc/ipc.gyp:ipc',
90         '../ipc/ipc.gyp:test_support_ipc',
91         '../testing/gmock.gyp:gmock',
92         '../testing/gtest.gyp:gtest',
93       ],
94       'sources': [
95         'proxy/ppapi_proxy_test.cc',
96         'proxy/ppapi_proxy_test.h',
97         'proxy/resource_message_test_sink.cc',
98         'proxy/resource_message_test_sink.h',
99         'shared_impl/test_globals.cc',
100         'shared_impl/test_globals.h',
101       ],
102     },
104     {
105       'target_name': 'ppapi_perftests',
106       'type': 'executable',
107       'variables': {
108         'chromium_code': 1,
109       },
110       'dependencies': [
111         'ppapi_proxy',
112         'ppapi_shared',
113         'ppapi_unittest_shared',
114         '../base/base.gyp:test_support_base',
115         '../testing/gtest.gyp:gtest',
116       ],
117       'sources': [
118         'proxy/ppapi_perftests.cc',
119         'proxy/ppp_messaging_proxy_perftest.cc',
120       ],
121     },
122     {
123       'target_name': 'ppapi_unittests',
124       'type': 'executable',
125       'variables': {
126         'chromium_code': 1,
127       },
128       'dependencies': [
129         'ppapi_proxy',
130         'ppapi_shared',
131         'ppapi_unittest_shared',
132         '../base/base.gyp:test_support_base',
133         '../gpu/gpu.gyp:gpu_ipc',
134         '../ipc/ipc.gyp:ipc',
135         '../ipc/ipc.gyp:test_support_ipc',
136         '../media/media.gyp:shared_memory_support',
137         '../testing/gmock.gyp:gmock',
138         '../testing/gtest.gyp:gtest',
139         '../ui/surface/surface.gyp:surface',
140       ],
141       'sources': [
142         'proxy/run_all_unittests.cc',
144         'proxy/file_chooser_resource_unittest.cc',
145         'proxy/mock_resource.cc',
146         'proxy/mock_resource.h',
147         'proxy/plugin_dispatcher_unittest.cc',
148         'proxy/plugin_resource_tracker_unittest.cc',
149         'proxy/plugin_var_tracker_unittest.cc',
150         'proxy/ppb_var_unittest.cc',
151         'proxy/ppp_instance_private_proxy_unittest.cc',
152         'proxy/ppp_instance_proxy_unittest.cc',
153         'proxy/ppp_messaging_proxy_unittest.cc',
154         'proxy/printing_resource_unittest.cc',
155         'proxy/serialized_var_unittest.cc',
156         'shared_impl/resource_tracker_unittest.cc',
157         'shared_impl/tracked_callback_unittest.cc',
158         'shared_impl/var_tracker_unittest.cc',
159       ],
160     },
161     {
162       'target_name': 'ppapi_example_skeleton',
163       'suppress_wildcard': 1,
164       'type': 'none',
165       'direct_dependent_settings': {
166         'product_name': '>(_target_name)',
167         'conditions': [
168           ['os_posix==1 and OS!="mac"', {
169             'cflags': ['-fvisibility=hidden'],
170             'type': 'shared_library',
171             # -gstabs, used in the official builds, causes an ICE. Simply remove
172             # it.
173             'cflags!': ['-gstabs'],
174           }],
175           ['OS=="win"', {
176             'type': 'shared_library',
177           }],
178           ['OS=="mac"', {
179             'type': 'loadable_module',
180             'mac_bundle': 1,
181             'product_extension': 'plugin',
182             'xcode_settings': {
183               'OTHER_LDFLAGS': [
184                 # Not to strip important symbols by -Wl,-dead_strip.
185                 '-Wl,-exported_symbol,_PPP_GetInterface',
186                 '-Wl,-exported_symbol,_PPP_InitializeModule',
187                 '-Wl,-exported_symbol,_PPP_ShutdownModule'
188               ]},
189           }],
190         ],
191       },
192     },
193     {
194       'target_name': 'ppapi_example_mouse_cursor',
195       'dependencies': [
196         'ppapi_example_skeleton',
197         'ppapi.gyp:ppapi_cpp',
198       ],
199       'sources': [
200         'examples/mouse_cursor/mouse_cursor.cc',
201       ],
202     },
203     {
204       'target_name': 'ppapi_example_mouse_lock',
205       'dependencies': [
206         'ppapi_example_skeleton',
207         'ppapi.gyp:ppapi_cpp',
208       ],
209       'sources': [
210         'examples/mouse_lock/mouse_lock.cc',
211       ],
212     },
214     {
215       'target_name': 'ppapi_example_gamepad',
216       'dependencies': [
217         'ppapi_example_skeleton',
218         'ppapi.gyp:ppapi_cpp',
219       ],
220       'sources': [
221         'examples/gamepad/gamepad.cc',
222       ],
223     },
225     {
226       'target_name': 'ppapi_example_c_stub',
227       'dependencies': [
228         'ppapi_example_skeleton',
229         'ppapi.gyp:ppapi_c',
230       ],
231       'sources': [
232         'examples/stub/stub.c',
233       ],
234     },
235     {
236       'target_name': 'ppapi_example_cc_stub',
237       'dependencies': [
238         'ppapi_example_skeleton',
239         'ppapi.gyp:ppapi_cpp',
240       ],
241       'sources': [
242         'examples/stub/stub.cc',
243       ],
244     },
245     {
246       'target_name': 'ppapi_example_audio',
247       'dependencies': [
248         'ppapi_example_skeleton',
249         'ppapi.gyp:ppapi_cpp',
250       ],
251       'sources': [
252         'examples/audio/audio.cc',
253       ],
254     },
255     {
256       'target_name': 'ppapi_example_audio_input',
257       'dependencies': [
258         'ppapi_example_skeleton',
259         'ppapi.gyp:ppapi_cpp',
260       ],
261       'sources': [
262         'examples/audio_input/audio_input.cc',
263       ],
264     },
265     {
266       'target_name': 'ppapi_example_file_chooser',
267       'dependencies': [
268         'ppapi_example_skeleton',
269         'ppapi.gyp:ppapi_cpp',
270       ],
271       'sources': [
272         'examples/file_chooser/file_chooser.cc',
273       ],
274     },
275     {
276       'target_name': 'ppapi_example_graphics_2d',
277       'dependencies': [
278         'ppapi_example_skeleton',
279         'ppapi.gyp:ppapi_c',
280       ],
281       'sources': [
282         'examples/2d/graphics_2d_example.c',
283       ],
284     },
285     {
286       'target_name': 'ppapi_example_ime',
287       'dependencies': [
288         'ppapi_example_skeleton',
289         'ppapi.gyp:ppapi_cpp',
290       ],
291       'sources': [
292         'examples/ime/ime.cc',
293       ],
294     },
295     {
296       'target_name': 'ppapi_example_paint_manager',
297       'dependencies': [
298         'ppapi_example_skeleton',
299         'ppapi.gyp:ppapi_cpp',
300       ],
301       'sources': [
302         'examples/2d/paint_manager_example.cc',
303       ],
304     },
305     {
306       'target_name': 'ppapi_example_input',
307       'dependencies': [
308         'ppapi_example_skeleton',
309         'ppapi.gyp:ppapi_cpp',
310       ],
311       'sources': [
312         'examples/input/pointer_event_input.cc',
313       ],
314     },
315     {
316       'target_name': 'ppapi_example_post_message',
317       'dependencies': [
318         'ppapi_example_skeleton',
319         'ppapi.gyp:ppapi_cpp',
320       ],
321       'sources': [
322         'examples/scripting/post_message.cc',
323       ],
324     },
325     {
326       'target_name': 'ppapi_example_scroll',
327       'dependencies': [
328         'ppapi_example_skeleton',
329         'ppapi.gyp:ppapi_cpp',
330       ],
331       'sources': [
332         'examples/2d/scroll.cc',
333       ],
334     },
335     {
336       'target_name': 'ppapi_example_simple_font',
337       'dependencies': [
338         'ppapi_example_skeleton',
339         'ppapi.gyp:ppapi_cpp',
340       ],
341       'sources': [
342         'examples/font/simple_font.cc',
343       ],
344     },
345     {
346       'target_name': 'ppapi_example_url_loader',
347       'dependencies': [
348         'ppapi_example_skeleton',
349         'ppapi.gyp:ppapi_cpp',
350       ],
351       'sources': [
352         'examples/url_loader/streaming.cc',
353       ],
354     },
355     {
356       'target_name': 'ppapi_example_gles2',
357       'dependencies': [
358         'ppapi_example_skeleton',
359         'ppapi.gyp:ppapi_cpp',
360         'ppapi.gyp:ppapi_gles2',
361         'ppapi.gyp:ppapi_egl',
362       ],
363       'include_dirs': [
364         'lib/gl/include',
365       ],
366       'sources': [
367         'examples/gles2/gles2.cc',
368       ],
369     },
370     {
371       'target_name': 'ppapi_example_video_decode',
372       'dependencies': [
373         'ppapi_example_skeleton',
374         'ppapi.gyp:ppapi_cpp',
375         'ppapi.gyp:ppapi_gles2',
376         'ppapi.gyp:ppapi_egl',
377       ],
378       'include_dirs': [
379         'lib/gl/include',
380       ],
381       'sources': [
382         'examples/video_decode/video_decode.cc',
383         'examples/video_decode/testdata.h',
384       ],
385     },
386     {
387       'target_name': 'ppapi_example_vc',
388       'dependencies': [
389         'ppapi_example_skeleton',
390         'ppapi.gyp:ppapi_cpp',
391         'ppapi.gyp:ppapi_gles2',
392         'ppapi.gyp:ppapi_egl',
393       ],
394       'include_dirs': [
395         'lib/gl/include',
396       ],
397       'sources': [
398         'examples/video_capture/video_capture.cc',
399       ],
400     },
401     {
402       'target_name': 'ppapi_example_flash_topmost',
403       'dependencies': [
404         'ppapi_example_skeleton',
405         'ppapi.gyp:ppapi_cpp',
406       ],
407       'sources': [
408         'examples/flash_topmost/flash_topmost.cc',
409       ],
410     },
411     {
412       'target_name': 'ppapi_example_printing',
413       'dependencies': [
414         'ppapi_example_skeleton',
415         'ppapi.gyp:ppapi_cpp',
416       ],
417       'sources': [
418         'examples/printing/printing.cc',
419       ],
420     },
421   ],