- add sources.
[platform/framework/web/crosswalk.git] / src / chrome / test / data / nacl / nacl_test_data.gyp
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.
4
5 {
6   'includes': [
7     '../../../../ppapi/ppapi_nacl_test_common.gypi',
8   ],
9   'targets': [
10     {
11       'target_name': 'shared_test_files',
12       'type': 'none',
13       'variables': {
14         'build_newlib': 1,
15         'build_glibc': 1,
16         'build_pnacl_newlib': 1,
17         'nexe_destination_dir': 'nacl_test_data',
18         'test_files': [
19           # TODO(ncbray) move into chrome/test/data/nacl when all tests are
20           # converted.
21           '<(DEPTH)/ppapi/native_client/tests/ppapi_browser/progress_event_listener.js',
22           '<(DEPTH)/ppapi/native_client/tests/ppapi_browser/bad/ppapi_bad.js',
23           '<(DEPTH)/ppapi/native_client/tools/browser_tester/browserdata/nacltest.js',
24         ],
25       },
26     },
27     {
28       'target_name': 'simple_test',
29       'type': 'none',
30       'variables': {
31         'nexe_target': 'simple',
32         'build_newlib': 1,
33         'build_glibc': 1,
34         'build_pnacl_newlib': 1,
35         'nexe_destination_dir': 'nacl_test_data',
36         'sources': [
37           'simple.cc',
38         ],
39         'test_files': [
40           'nacl_load_test.html',
41         ],
42       },
43     },
44     {
45       'target_name': 'exit_status_test',
46       'type': 'none',
47       'variables': {
48         'nexe_target': 'pm_exit_status_test',
49         'build_newlib': 1,
50         'build_glibc': 1,
51         'build_pnacl_newlib': 1,
52         'nexe_destination_dir': 'nacl_test_data',
53         'sources': [
54           'exit_status/pm_exit_status_test.cc',
55         ],
56         'test_files': [
57           'exit_status/pm_exit_status_test.html',
58         ],
59       },
60     },
61     {
62       'target_name': 'sysconf_nprocessors_onln_test',
63       'type': 'none',
64       'variables': {
65         'nexe_target': 'sysconf_nprocessors_onln_test',
66         'build_newlib': 1,
67         'build_glibc': 1,
68         'build_pnacl_newlib': 1,
69         'nexe_destination_dir': 'nacl_test_data',
70         'sources': [
71           'sysconf_nprocessors_onln/sysconf_nprocessors_onln_test.cc',
72         ],
73         'test_files': [
74           'sysconf_nprocessors_onln/sysconf_nprocessors_onln_test.html',
75         ],
76       },
77     },
78     {
79       'target_name': 'ppapi_test_lib',
80       'type': 'none',
81       'variables': {
82         'nlib_target': 'libppapi_test_lib.a',
83         'nso_target': 'libppapi_test_lib.so',
84         'build_newlib': 1,
85         'build_glibc': 1,
86         'build_pnacl_newlib': 1,
87         'nexe_destination_dir': 'nacl_test_data',
88         'sources': [
89           # TODO(ncbray) move these files once SCons no longer depends on them.
90           '../../../../ppapi/native_client/tests/ppapi_test_lib/get_browser_interface.cc',
91           '../../../../ppapi/native_client/tests/ppapi_test_lib/internal_utils.cc',
92           '../../../../ppapi/native_client/tests/ppapi_test_lib/module_instance.cc',
93           '../../../../ppapi/native_client/tests/ppapi_test_lib/testable_callback.cc',
94           '../../../../ppapi/native_client/tests/ppapi_test_lib/test_interface.cc',
95         ]
96       },
97       'dependencies': [
98         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
99       ],
100     },
101     {
102       'target_name': 'ppapi_progress_events',
103       'type': 'none',
104       'variables': {
105         'nexe_target': 'ppapi_progress_events',
106         'build_newlib': 1,
107         'build_glibc': 1,
108         'build_pnacl_newlib': 1,
109         'nexe_destination_dir': 'nacl_test_data',
110         'link_flags': [
111           '-lppapi',
112           '-lppapi_test_lib',
113           '-lplatform',
114           '-lgio',
115         ],
116         'sources': [
117           'progress_events/ppapi_progress_events.cc',
118         ],
119         'test_files': [
120           'progress_events/ppapi_progress_events.html',
121         ],
122       },
123       'dependencies': [
124         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
125         '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib',
126         '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib',
127         '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib',
128         '<(DEPTH)/ppapi/ppapi_untrusted.gyp:ppapi_cpp_lib',
129         'ppapi_test_lib',
130       ],
131     },
132     {
133       'target_name': 'pnacl_error_handling_test',
134       'type': 'none',
135       'variables': {
136         'build_pnacl_newlib': 1,
137         'nexe_destination_dir': 'nacl_test_data',
138         # No need to translate AOT.
139         'enable_x86_32': 0,
140         'enable_x86_64': 0,
141         'enable_arm': 0,
142         # Use prebuilt NMF files.
143         'generate_nmf': 0,
144         'test_files': [
145           'pnacl_error_handling/pnacl_error_handling.html',
146           'pnacl_error_handling/bad.pexe',
147           'pnacl_error_handling/pnacl_bad_pexe.nmf',
148           'pnacl_error_handling/pnacl_bad_doesnotexist.nmf',
149           'pnacl_error_handling/pnacl_illformed_manifest.nmf',
150         ],
151       },
152       'dependencies': [
153         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
154       ]
155     },
156     {
157       'target_name': 'pnacl_mime_type_test',
158       'type': 'none',
159       'variables': {
160         'build_newlib': 1,
161         'build_glibc': 1,
162         'build_pnacl_newlib': 1,
163         'nexe_destination_dir': 'nacl_test_data',
164         # No need to translate AOT.
165         'enable_x86_32': 0,
166         'enable_x86_64': 0,
167         'enable_arm': 0,
168         'test_files': [
169           'pnacl_mime_type/pnacl_mime_type.html',
170         ],
171       },
172     },
173     {
174       'target_name': 'pnacl_options_test',
175       'type': 'none',
176       'variables': {
177         'nexe_target': 'pnacl_options',
178         'build_pnacl_newlib': 1,
179         'nexe_destination_dir': 'nacl_test_data',
180         # No need to translate these AOT, when we just need the pexe.
181         'enable_x86_32': 0,
182         'enable_x86_64': 0,
183         'enable_arm': 0,
184         'sources': [
185           'simple.cc',
186         ],
187         'test_files': [
188           'pnacl_nmf_options/pnacl_options.html',
189           'pnacl_nmf_options/pnacl_o_0.nmf',
190           'pnacl_nmf_options/pnacl_o_2.nmf',
191           'pnacl_nmf_options/pnacl_o_large.nmf',
192         ],
193       },
194       'dependencies': [
195         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
196       ]
197     },
198     {
199       'target_name': 'pnacl_dyncode_syscall_disabled_test',
200       'type': 'none',
201       'variables': {
202         # This tests that nexes produced by translation in the browser are not
203         # able to use the dyncode syscalls.  Pre-translated nexes are not
204         # subject to this constraint, so we do not test them.
205         'enable_x86_32': 0,
206         'enable_x86_64': 0,
207         'enable_arm': 0,
208         'nexe_target': 'pnacl_dyncode_syscall_disabled',
209         'build_pnacl_newlib': 1,
210         'nexe_destination_dir': 'nacl_test_data',
211         'link_flags': [
212           '-lppapi',
213           '-lppapi_test_lib',
214           '-lplatform',
215           '-lgio',
216           # The "_private" variant of the library calls the syscalls
217           # directly, which allows us to test the syscalls directly,
218           # even when the dyncode IRT interface is also disabled under
219           # PNaCl.
220           '-lnacl_dyncode_private',
221         ],
222         'sources': [
223           'pnacl_dyncode_syscall_disabled/pnacl_dyncode_syscall_disabled.cc',
224         ],
225         'test_files': [
226           'pnacl_dyncode_syscall_disabled/pnacl_dyncode_syscall_disabled.html',
227         ],
228       },
229       'dependencies': [
230         '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib',
231         '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib',
232         '<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_dyncode_private_lib',
233         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
234         '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib',
235         '<(DEPTH)/ppapi/ppapi_untrusted.gyp:ppapi_cpp_lib',
236         'ppapi_test_lib',
237       ],
238     },
239     {
240       'target_name': 'pnacl_exception_handling_disabled_test',
241       'type': 'none',
242       'variables': {
243         # This tests that nexes produced by translation in the browser are not
244         # able to use hardware exception handling.  Pre-translated nexes are
245         # not subject to this constraint, so we do not test them.
246         'enable_x86_32': 0,
247         'enable_x86_64': 0,
248         'enable_arm': 0,
249         'nexe_target': 'pnacl_exception_handling_disabled',
250         'build_pnacl_newlib': 1,
251         'nexe_destination_dir': 'nacl_test_data',
252         'link_flags': [
253           '-lppapi',
254           '-lppapi_test_lib',
255           '-lplatform',
256           '-lgio',
257           # The "_private" variant of the library calls the syscalls
258           # directly, which allows us to test the syscalls directly,
259           # even when the exception-handling IRT interface is also
260           # disabled under PNaCl.
261           '-lnacl_exception_private',
262         ],
263         'sources': [
264           'pnacl_exception_handling_disabled/pnacl_exception_handling_disabled.cc',
265         ],
266         'test_files': [
267           'pnacl_exception_handling_disabled/pnacl_exception_handling_disabled.html',
268         ],
269       },
270       'dependencies': [
271         '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib',
272         '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib',
273         '<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_exception_private_lib',
274         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
275         '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib',
276         '<(DEPTH)/ppapi/ppapi_untrusted.gyp:ppapi_cpp_lib',
277         'ppapi_test_lib',
278       ],
279     },
280     # Legacy NaCl PPAPI interface tests being here.
281     {
282       'target_name': 'ppapi_ppb_core',
283       'type': 'none',
284       'variables': {
285         'nexe_target': 'ppapi_ppb_core',
286         'build_newlib': 1,
287         'build_glibc': 1,
288         'build_pnacl_newlib': 1,
289         'nexe_destination_dir': 'nacl_test_data',
290         'link_flags': [
291           '-lppapi',
292           '-lppapi_test_lib',
293           '-lplatform',
294           '-lgio',
295         ],
296         'sources': [
297           'ppapi/ppb_core/ppapi_ppb_core.cc',
298         ],
299         'test_files': [
300           'ppapi/ppb_core/ppapi_ppb_core.html',
301         ],
302       },
303       'dependencies': [
304         '<(DEPTH)/native_client/tools.gyp:prep_toolchain',
305         '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib',
306         '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib',
307         '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib',
308         '<(DEPTH)/ppapi/ppapi_untrusted.gyp:ppapi_cpp_lib',
309         'ppapi_test_lib',
310       ],
311     },
312   ],
313 }