| OLD | NEW |
| (Empty) |
| 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 # TODO bug 512902 this needs to be ported to GN. | |
| 12 'target_name': 'shared_test_files', | |
| 13 'type': 'none', | |
| 14 'variables': { | |
| 15 'build_newlib': 1, | |
| 16 'build_glibc': 1, | |
| 17 'build_pnacl_newlib': 1, | |
| 18 'nexe_destination_dir': 'nacl_test_data', | |
| 19 'test_files': [ | |
| 20 # TODO(ncbray) move into chrome/test/data/nacl when all tests are | |
| 21 # converted. | |
| 22 '<(DEPTH)/ppapi/native_client/tools/browser_tester/browserdata/nacltes
t.js', | |
| 23 | |
| 24 # Files that aren't assosiated with any particular executable. | |
| 25 'bad/ppapi_bad.html', | |
| 26 'bad/ppapi_bad.js', | |
| 27 'bad/ppapi_bad_native.html', | |
| 28 'bad/ppapi_bad_doesnotexist.nmf', | |
| 29 'bad/ppapi_bad_magic.nmf', | |
| 30 'bad/ppapi_bad_manifest_uses_nexes.nmf', | |
| 31 'bad/ppapi_bad_manifest_bad_files.nmf', | |
| 32 'bad/ppapi_bad_manifest_nexe_arch.nmf', | |
| 33 'crash/ppapi_crash.js', | |
| 34 'crash/ppapi_crash_via_check_failure.html', | |
| 35 'crash/ppapi_crash_via_exit_call.html', | |
| 36 'crash/ppapi_crash_in_callback.html', | |
| 37 'crash/ppapi_crash_ppapi_off_main_thread.html', | |
| 38 'crash/ppapi_crash_off_main_thread.html', | |
| 39 'load_util.js', | |
| 40 'manifest_file/test_file.txt', | |
| 41 'progress_event_listener.js', | |
| 42 'simple_cc.js', | |
| 43 ], | |
| 44 }, | |
| 45 'conditions': [ | |
| 46 ['(target_arch=="ia32" or target_arch=="x64") and OS=="linux"', { | |
| 47 # Enable nonsfi testing on ia32-linux environment. | |
| 48 # This flag causes test_files to be copied into nonsfi directory, | |
| 49 # too. | |
| 50 'variables': { | |
| 51 'enable_x86_32_nonsfi': 1, | |
| 52 }, | |
| 53 }], | |
| 54 ['target_arch=="arm" and OS=="linux"', { | |
| 55 # Enable nonsfi testing on arm-linux environment. | |
| 56 # This flag causes test_files to be copied into nonsfi directory, | |
| 57 # too. | |
| 58 'variables': { | |
| 59 'enable_arm_nonsfi': 1, | |
| 60 }, | |
| 61 }], | |
| 62 ], | |
| 63 }, | |
| 64 { | |
| 65 'target_name': 'simple_test', | |
| 66 'type': 'none', | |
| 67 'variables': { | |
| 68 'nexe_target': 'simple', | |
| 69 'build_newlib': 1, | |
| 70 'build_glibc': 1, | |
| 71 'build_pnacl_newlib': 1, | |
| 72 'nexe_destination_dir': 'nacl_test_data', | |
| 73 'sources': [ | |
| 74 'simple.cc', | |
| 75 ], | |
| 76 'test_files': [ | |
| 77 'nacl_load_test.html', | |
| 78 ], | |
| 79 }, | |
| 80 }, | |
| 81 { | |
| 82 'target_name': 'exit_status_test', | |
| 83 'type': 'none', | |
| 84 'variables': { | |
| 85 'nexe_target': 'pm_exit_status_test', | |
| 86 'build_newlib': 1, | |
| 87 'build_glibc': 1, | |
| 88 'build_pnacl_newlib': 1, | |
| 89 'nexe_destination_dir': 'nacl_test_data', | |
| 90 'sources': [ | |
| 91 'exit_status/pm_exit_status_test.cc', | |
| 92 ], | |
| 93 'test_files': [ | |
| 94 'exit_status/pm_exit_status_test.html', | |
| 95 ], | |
| 96 }, | |
| 97 }, | |
| 98 { | |
| 99 'target_name': 'extension_validation_cache', | |
| 100 'type': 'none', | |
| 101 'variables': { | |
| 102 'nexe_target': 'extension_validation_cache', | |
| 103 # The test currently only has the test expectations for the | |
| 104 # newlib and glibc cases (# validation queries/settings), and has also | |
| 105 # hardcoded the newlib and glibc variants' directory path for the | |
| 106 # unpacked ext. | |
| 107 'build_newlib': 1, | |
| 108 'build_glibc': 1, | |
| 109 'build_pnacl_newlib': 0, | |
| 110 # Need a new directory to not clash with with other extension | |
| 111 # tests's files (e.g., manifest.json). | |
| 112 'nexe_destination_dir': 'nacl_test_data/extension_vcache_test', | |
| 113 'sources': [ | |
| 114 'simple.cc', | |
| 115 ], | |
| 116 'test_files': [ | |
| 117 # TODO(ncbray) move into chrome/test/data/nacl when all tests are | |
| 118 # converted. | |
| 119 '<(DEPTH)/ppapi/native_client/tools/browser_tester/browserdata/nacltes
t.js', | |
| 120 'extension_validation_cache/extension_validation_cache.html', | |
| 121 'extension_validation_cache/extension_validation_cache.js', | |
| 122 # Turns the test data directory into an extension. | |
| 123 # Use a different nexe_destination_dir to isolate the files. | |
| 124 # Note that the .nexe names are embedded in this file. | |
| 125 'extension_validation_cache/manifest.json', | |
| 126 'load_util.js', | |
| 127 'simple_cc.js', | |
| 128 ], | |
| 129 }, | |
| 130 }, | |
| 131 { | |
| 132 'target_name': 'sysconf_nprocessors_onln_test', | |
| 133 'type': 'none', | |
| 134 'variables': { | |
| 135 'nexe_target': 'sysconf_nprocessors_onln_test', | |
| 136 'build_newlib': 1, | |
| 137 'build_glibc': 1, | |
| 138 'build_pnacl_newlib': 1, | |
| 139 'nexe_destination_dir': 'nacl_test_data', | |
| 140 'sources': [ | |
| 141 'sysconf_nprocessors_onln/sysconf_nprocessors_onln_test.cc', | |
| 142 ], | |
| 143 'test_files': [ | |
| 144 'sysconf_nprocessors_onln/sysconf_nprocessors_onln_test.html', | |
| 145 ], | |
| 146 }, | |
| 147 }, | |
| 148 { | |
| 149 'target_name': 'ppapi_test_lib', | |
| 150 'type': 'none', | |
| 151 'variables': { | |
| 152 'nlib_target': 'libppapi_test_lib.a', | |
| 153 'nso_target': 'libppapi_test_lib.so', | |
| 154 'build_newlib': 1, | |
| 155 'build_glibc': 1, | |
| 156 'build_pnacl_newlib': 1, | |
| 157 'nexe_destination_dir': 'nacl_test_data', | |
| 158 'sources': [ | |
| 159 'ppapi_test_lib/get_browser_interface.cc', | |
| 160 'ppapi_test_lib/internal_utils.cc', | |
| 161 'ppapi_test_lib/module_instance.cc', | |
| 162 'ppapi_test_lib/test_interface.cc', | |
| 163 'ppapi_test_lib/testable_callback.cc', | |
| 164 ] | |
| 165 }, | |
| 166 }, | |
| 167 { | |
| 168 'target_name': 'ppapi_progress_events', | |
| 169 'type': 'none', | |
| 170 'variables': { | |
| 171 'nexe_target': 'ppapi_progress_events', | |
| 172 'build_newlib': 1, | |
| 173 'build_glibc': 1, | |
| 174 'build_pnacl_newlib': 1, | |
| 175 'nexe_destination_dir': 'nacl_test_data', | |
| 176 'link_flags': [ | |
| 177 '-lppapi', | |
| 178 '-lppapi_test_lib', | |
| 179 '-lplatform', | |
| 180 '-lgio', | |
| 181 ], | |
| 182 'sources': [ | |
| 183 'progress_events/ppapi_progress_events.cc', | |
| 184 ], | |
| 185 'test_files': [ | |
| 186 'progress_events/ppapi_progress_events.html', | |
| 187 ], | |
| 188 }, | |
| 189 'dependencies': [ | |
| 190 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 191 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 192 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 193 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 194 'ppapi_test_lib', | |
| 195 ], | |
| 196 }, | |
| 197 { | |
| 198 'target_name': 'ppapi_bad_ppp_initialize', | |
| 199 'type': 'none', | |
| 200 'variables': { | |
| 201 'nexe_target': 'ppapi_bad_ppp_initialize', | |
| 202 'build_newlib': 1, | |
| 203 'build_glibc': 0, | |
| 204 'build_pnacl_newlib': 0, | |
| 205 'nexe_destination_dir': 'nacl_test_data', | |
| 206 'link_flags': [ | |
| 207 '-lppapi', | |
| 208 '-lplatform', | |
| 209 '-lgio', | |
| 210 ], | |
| 211 'sources': [ | |
| 212 'bad/ppapi_bad_ppp_initialize.cc', | |
| 213 ], | |
| 214 }, | |
| 215 'dependencies': [ | |
| 216 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 217 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 218 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 219 ], | |
| 220 }, | |
| 221 { | |
| 222 'target_name': 'ppapi_bad_ppp_initialize_crash', | |
| 223 'type': 'none', | |
| 224 'variables': { | |
| 225 'nexe_target': 'ppapi_bad_ppp_initialize_crash', | |
| 226 'build_newlib': 1, | |
| 227 'build_glibc': 0, | |
| 228 'build_pnacl_newlib': 0, | |
| 229 'nexe_destination_dir': 'nacl_test_data', | |
| 230 'link_flags': [ | |
| 231 '-lppapi', | |
| 232 '-lplatform', | |
| 233 '-lgio', | |
| 234 ], | |
| 235 'sources': [ | |
| 236 'bad/ppapi_bad_ppp_initialize_crash.cc', | |
| 237 ], | |
| 238 }, | |
| 239 'dependencies': [ | |
| 240 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 241 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 242 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 243 ], | |
| 244 }, | |
| 245 { | |
| 246 'target_name': 'ppapi_bad_no_ppp_instance', | |
| 247 'type': 'none', | |
| 248 'variables': { | |
| 249 'nexe_target': 'ppapi_bad_no_ppp_instance', | |
| 250 'build_newlib': 1, | |
| 251 'build_glibc': 0, | |
| 252 'build_pnacl_newlib': 0, | |
| 253 'nexe_destination_dir': 'nacl_test_data', | |
| 254 'link_flags': [ | |
| 255 '-lppapi', | |
| 256 '-lplatform', | |
| 257 '-lgio', | |
| 258 ], | |
| 259 'sources': [ | |
| 260 'bad/ppapi_bad_no_ppp_instance.cc', | |
| 261 ], | |
| 262 }, | |
| 263 'dependencies': [ | |
| 264 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 265 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 266 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 267 ], | |
| 268 }, | |
| 269 { | |
| 270 'target_name': 'ppapi_bad_get_ppp_instance_crash', | |
| 271 'type': 'none', | |
| 272 'variables': { | |
| 273 'nexe_target': 'ppapi_bad_get_ppp_instance_crash', | |
| 274 'build_newlib': 1, | |
| 275 'build_glibc': 0, | |
| 276 'build_pnacl_newlib': 0, | |
| 277 'nexe_destination_dir': 'nacl_test_data', | |
| 278 'link_flags': [ | |
| 279 '-lppapi', | |
| 280 '-lplatform', | |
| 281 '-lgio', | |
| 282 ], | |
| 283 'sources': [ | |
| 284 'bad/ppapi_bad_get_ppp_instance_crash.cc', | |
| 285 ], | |
| 286 }, | |
| 287 'dependencies': [ | |
| 288 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 289 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 290 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 291 ], | |
| 292 }, | |
| 293 { | |
| 294 'target_name': 'ppapi_bad_ppp_instance_didcreate', | |
| 295 'type': 'none', | |
| 296 'variables': { | |
| 297 'nexe_target': 'ppapi_bad_ppp_instance_didcreate', | |
| 298 'build_newlib': 1, | |
| 299 'build_glibc': 0, | |
| 300 'build_pnacl_newlib': 0, | |
| 301 'nexe_destination_dir': 'nacl_test_data', | |
| 302 'link_flags': [ | |
| 303 '-lppapi', | |
| 304 '-lplatform', | |
| 305 '-lgio', | |
| 306 ], | |
| 307 'sources': [ | |
| 308 'bad/ppapi_bad_ppp_instance_didcreate.cc', | |
| 309 ], | |
| 310 }, | |
| 311 'dependencies': [ | |
| 312 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 313 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 314 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 315 ], | |
| 316 }, | |
| 317 { | |
| 318 'target_name': 'ppapi_bad_ppp_instance_didcreate_crash', | |
| 319 'type': 'none', | |
| 320 'variables': { | |
| 321 'nexe_target': 'ppapi_bad_ppp_instance_didcreate_crash', | |
| 322 'build_newlib': 1, | |
| 323 'build_glibc': 0, | |
| 324 'build_pnacl_newlib': 0, | |
| 325 'nexe_destination_dir': 'nacl_test_data', | |
| 326 'link_flags': [ | |
| 327 '-lppapi', | |
| 328 '-lplatform', | |
| 329 '-lgio', | |
| 330 ], | |
| 331 'sources': [ | |
| 332 'bad/ppapi_bad_ppp_instance_didcreate_crash.cc', | |
| 333 ], | |
| 334 }, | |
| 335 'dependencies': [ | |
| 336 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 337 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 338 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 339 ], | |
| 340 }, | |
| 341 { | |
| 342 'target_name': 'ppapi_crash_via_check_failure', | |
| 343 'type': 'none', | |
| 344 'variables': { | |
| 345 'nexe_target': 'ppapi_crash_via_check_failure', | |
| 346 'build_newlib': 1, | |
| 347 'build_glibc': 1, | |
| 348 'build_pnacl_newlib': 1, | |
| 349 'nexe_destination_dir': 'nacl_test_data', | |
| 350 'link_flags': [ | |
| 351 '-lppapi', | |
| 352 '-lppapi_test_lib', | |
| 353 '-lplatform', | |
| 354 '-lgio', | |
| 355 ], | |
| 356 'sources': [ | |
| 357 'crash/ppapi_crash_via_check_failure.cc', | |
| 358 ], | |
| 359 }, | |
| 360 'dependencies': [ | |
| 361 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 362 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 363 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 364 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 365 'ppapi_test_lib', | |
| 366 ], | |
| 367 }, | |
| 368 { | |
| 369 'target_name': 'ppapi_crash_via_exit_call', | |
| 370 'type': 'none', | |
| 371 'variables': { | |
| 372 'nexe_target': 'ppapi_crash_via_exit_call', | |
| 373 'build_newlib': 1, | |
| 374 'build_glibc': 1, | |
| 375 'build_pnacl_newlib': 1, | |
| 376 'nexe_destination_dir': 'nacl_test_data', | |
| 377 'link_flags': [ | |
| 378 '-lppapi', | |
| 379 '-lppapi_test_lib', | |
| 380 '-lplatform', | |
| 381 '-lgio', | |
| 382 ], | |
| 383 'sources': [ | |
| 384 'crash/ppapi_crash_via_exit_call.cc', | |
| 385 ], | |
| 386 }, | |
| 387 'dependencies': [ | |
| 388 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 389 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 390 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 391 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 392 'ppapi_test_lib', | |
| 393 ], | |
| 394 }, | |
| 395 { | |
| 396 'target_name': 'ppapi_crash_in_callback', | |
| 397 'type': 'none', | |
| 398 'variables': { | |
| 399 'nexe_target': 'ppapi_crash_in_callback', | |
| 400 'build_newlib': 1, | |
| 401 'build_glibc': 1, | |
| 402 'build_pnacl_newlib': 1, | |
| 403 'nexe_destination_dir': 'nacl_test_data', | |
| 404 'link_flags': [ | |
| 405 '-lppapi', | |
| 406 '-lppapi_test_lib', | |
| 407 '-lplatform', | |
| 408 '-lgio', | |
| 409 ], | |
| 410 'sources': [ | |
| 411 'crash/ppapi_crash_in_callback.cc', | |
| 412 ], | |
| 413 }, | |
| 414 'dependencies': [ | |
| 415 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 416 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 417 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 418 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 419 'ppapi_test_lib', | |
| 420 ], | |
| 421 }, | |
| 422 { | |
| 423 'target_name': 'ppapi_crash_off_main_thread', | |
| 424 'type': 'none', | |
| 425 'variables': { | |
| 426 'nexe_target': 'ppapi_crash_off_main_thread', | |
| 427 'build_newlib': 1, | |
| 428 'build_glibc': 1, | |
| 429 'build_pnacl_newlib': 1, | |
| 430 'nexe_destination_dir': 'nacl_test_data', | |
| 431 'link_flags': [ | |
| 432 '-lppapi', | |
| 433 '-lppapi_test_lib', | |
| 434 '-lplatform', | |
| 435 '-lgio', | |
| 436 ], | |
| 437 'sources': [ | |
| 438 'crash/ppapi_crash_off_main_thread.cc', | |
| 439 ], | |
| 440 }, | |
| 441 'dependencies': [ | |
| 442 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 443 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 444 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 445 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 446 'ppapi_test_lib', | |
| 447 ], | |
| 448 }, | |
| 449 { | |
| 450 'target_name': 'ppapi_crash_ppapi_off_main_thread', | |
| 451 'type': 'none', | |
| 452 'variables': { | |
| 453 'nexe_target': 'ppapi_crash_ppapi_off_main_thread', | |
| 454 'build_newlib': 1, | |
| 455 'build_glibc': 1, | |
| 456 'build_pnacl_newlib': 1, | |
| 457 'nexe_destination_dir': 'nacl_test_data', | |
| 458 'link_flags': [ | |
| 459 '-lppapi', | |
| 460 '-lppapi_test_lib', | |
| 461 '-lplatform', | |
| 462 '-lgio', | |
| 463 ], | |
| 464 'sources': [ | |
| 465 'crash/ppapi_crash_ppapi_off_main_thread.cc', | |
| 466 ], | |
| 467 }, | |
| 468 'dependencies': [ | |
| 469 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 470 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 471 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 472 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 473 'ppapi_test_lib', | |
| 474 ], | |
| 475 }, | |
| 476 { | |
| 477 'target_name': 'irt_manifest_file', | |
| 478 'type': 'none', | |
| 479 'variables': { | |
| 480 'nexe_target': 'irt_manifest_file', | |
| 481 'build_newlib': 1, | |
| 482 # Linking problems - can't find __nacl_irt_query. | |
| 483 'build_glibc': 0, | |
| 484 # TODO(ncbray) support file injection into PNaCl manifest. | |
| 485 'build_pnacl_newlib': 0, | |
| 486 'nexe_destination_dir': 'nacl_test_data', | |
| 487 'link_flags': [ | |
| 488 '-lppapi_cpp', | |
| 489 '-lppapi', | |
| 490 '-lplatform', | |
| 491 '-lgio', | |
| 492 '-lnacl', | |
| 493 ], | |
| 494 'sources': [ | |
| 495 'manifest_file/irt_manifest_file_test.cc', | |
| 496 ], | |
| 497 'create_nmf_args_portable': [ | |
| 498 '-xtest_file:test_file.txt', | |
| 499 '-xnmf says hello world:test_file.txt', | |
| 500 # There is no dummy_test_file.txt file intentionally. This is just for | |
| 501 # a test case where there is a manifest entry, but no actual file. | |
| 502 '-xdummy_test_file:dummy_test_file.txt', | |
| 503 ], | |
| 504 'test_files': [ | |
| 505 'manifest_file/irt_manifest_file_test.html', | |
| 506 ], | |
| 507 }, | |
| 508 'dependencies': [ | |
| 509 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 510 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 511 '<(DEPTH)/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_irt_shi
m.gyp:aot', | |
| 512 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 513 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 514 '<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_lib', | |
| 515 ], | |
| 516 'conditions': [ | |
| 517 # These are needed to build a non-SFI nexe binary. | |
| 518 # Note that these trigger building nexe files for other | |
| 519 # architectures, such as x86-32 (based on enable_XXX variables). | |
| 520 # As described above, although the tests for pnacl are currently | |
| 521 # disabled, but building the binary should work. | |
| 522 # We cannot disable building, as enable_XXX variables are also used | |
| 523 # to build newlib linked nexes. | |
| 524 ['(target_arch=="ia32" or target_arch=="x64") and OS=="linux"', { | |
| 525 # Enable nonsfi testing on ia32-linux environment. | |
| 526 'variables': { | |
| 527 'build_pnacl_newlib': 1, | |
| 528 'translate_pexe_with_build': 1, | |
| 529 'enable_x86_32_nonsfi': 1, | |
| 530 }, | |
| 531 }], | |
| 532 ['target_arch=="arm" and OS=="linux"', { | |
| 533 # Enable nonsfi testing on arm-linux environment. | |
| 534 'variables': { | |
| 535 'build_pnacl_newlib': 1, | |
| 536 'translate_pexe_with_build': 1, | |
| 537 'enable_arm_nonsfi': 1, | |
| 538 }, | |
| 539 }], | |
| 540 ], | |
| 541 }, | |
| 542 { | |
| 543 'target_name': 'irt_exception_test', | |
| 544 'type': 'none', | |
| 545 'variables': { | |
| 546 'nexe_target': 'irt_exception_test', | |
| 547 'build_newlib': 1, | |
| 548 'generate_nmf': 1, | |
| 549 'nexe_destination_dir': 'nacl_test_data', | |
| 550 'build_pnacl_newlib': 1, | |
| 551 'link_flags': [ | |
| 552 '-lppapi', | |
| 553 '-lppapi_test_lib', | |
| 554 '-lplatform', | |
| 555 '-lgio', | |
| 556 '-lnacl_exception', | |
| 557 ], | |
| 558 'sources': [ | |
| 559 'irt_exception/irt_exception_test.cc', | |
| 560 ], | |
| 561 'test_files': [ | |
| 562 # TODO(ncbray) move into chrome/test/data/nacl when all tests are | |
| 563 # converted. | |
| 564 'irt_exception/irt_exception_test.html', | |
| 565 ], | |
| 566 }, | |
| 567 'dependencies': [ | |
| 568 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 569 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 570 '<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_exception_lib', | |
| 571 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 572 '<(DEPTH)/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_irt_shi
m.gyp:aot', | |
| 573 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 574 'ppapi_test_lib', | |
| 575 ], | |
| 576 'conditions': [ | |
| 577 ['(target_arch=="ia32" or target_arch=="x64") and OS=="linux"', { | |
| 578 # Enable nonsfi testing on ia32-linux environment. | |
| 579 'variables': { | |
| 580 'enable_x86_32_nonsfi': 1, | |
| 581 'translate_pexe_with_build': 1, | |
| 582 }, | |
| 583 }], | |
| 584 ['target_arch=="arm" and OS=="linux"', { | |
| 585 # Enable nonsfi testing on arm-linux environment. | |
| 586 'variables': { | |
| 587 'enable_arm_nonsfi': 1, | |
| 588 'translate_pexe_with_build': 1, | |
| 589 }, | |
| 590 }], | |
| 591 ], | |
| 592 }, | |
| 593 { | |
| 594 'target_name': 'ppapi_extension_mime_handler', | |
| 595 'type': 'none', | |
| 596 'variables': { | |
| 597 'nexe_target': 'ppapi_extension_mime_handler', | |
| 598 'build_newlib': 1, | |
| 599 'build_glibc': 0, | |
| 600 'build_pnacl_newlib': 0, | |
| 601 'nexe_destination_dir': 'nacl_test_data', | |
| 602 'link_flags': [ | |
| 603 '-lppapi', | |
| 604 '-lppapi_test_lib', | |
| 605 '-lplatform', | |
| 606 '-lgio', | |
| 607 ], | |
| 608 'sources': [ | |
| 609 'extension_mime_handler/ppapi_extension_mime_handler.cc', | |
| 610 ], | |
| 611 'test_files': [ | |
| 612 'extension_mime_handler/ppapi_extension_mime_handler.html', | |
| 613 'extension_mime_handler/mime_test_data.dat', | |
| 614 # For faking the file's MIME type. | |
| 615 'extension_mime_handler/mime_test_data.dat.mock-http-headers', | |
| 616 # Turns the test data directory into an extension. Hackish. | |
| 617 # Note that the .nexe names are embedded in this file. | |
| 618 'extension_mime_handler/manifest.json', | |
| 619 ], | |
| 620 }, | |
| 621 'dependencies': [ | |
| 622 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 623 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 624 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 625 'ppapi_test_lib', | |
| 626 ], | |
| 627 }, | |
| 628 { | |
| 629 'target_name': 'pnacl_debug_url_test', | |
| 630 'type': 'none', | |
| 631 'variables': { | |
| 632 'nexe_target': 'pnacl_debug_url', | |
| 633 'build_pnacl_newlib': 1, | |
| 634 'nexe_destination_dir': 'nacl_test_data', | |
| 635 'generate_nmf': 0, | |
| 636 'sources': [ | |
| 637 'simple.cc', | |
| 638 ], | |
| 639 'test_files': [ | |
| 640 'pnacl_debug_url/pnacl_debug_url.html', | |
| 641 'pnacl_debug_url/pnacl_has_debug.nmf', | |
| 642 'pnacl_debug_url/pnacl_has_debug_flag_off.nmf', | |
| 643 'pnacl_debug_url/pnacl_no_debug.nmf', | |
| 644 ], | |
| 645 }, | |
| 646 }, | |
| 647 { | |
| 648 'target_name': 'pnacl_error_handling_test', | |
| 649 'type': 'none', | |
| 650 'variables': { | |
| 651 'nexe_target': 'pnacl_errors', | |
| 652 'extra_args': ['--nonstable-pnacl'], | |
| 653 'build_pnacl_newlib': 1, | |
| 654 'nexe_destination_dir': 'nacl_test_data', | |
| 655 'sources': [ | |
| 656 'simple.cc', | |
| 657 ], | |
| 658 'generate_nmf': 0, | |
| 659 'test_files': [ | |
| 660 'pnacl_error_handling/pnacl_error_handling.html', | |
| 661 'pnacl_error_handling/bad.pexe', | |
| 662 'pnacl_error_handling/pnacl_bad_pexe.nmf', | |
| 663 'pnacl_error_handling/pnacl_bad_pexe_O0.nmf', | |
| 664 'pnacl_error_handling/pnacl_bad_doesnotexist.nmf', | |
| 665 'pnacl_error_handling/pnacl_illformed_manifest.nmf', | |
| 666 'pnacl_error_handling/pnacl_nonfinal_pexe_O0.nmf', | |
| 667 ], | |
| 668 }, | |
| 669 }, | |
| 670 { | |
| 671 'target_name': 'pnacl_mime_type_test', | |
| 672 'type': 'none', | |
| 673 'variables': { | |
| 674 'build_newlib': 1, | |
| 675 'build_glibc': 1, | |
| 676 'build_pnacl_newlib': 1, | |
| 677 'nexe_destination_dir': 'nacl_test_data', | |
| 678 'test_files': [ | |
| 679 'pnacl_mime_type/pnacl_mime_type.html', | |
| 680 ], | |
| 681 }, | |
| 682 }, | |
| 683 { | |
| 684 'target_name': 'pnacl_options_test', | |
| 685 'type': 'none', | |
| 686 'variables': { | |
| 687 'nexe_target': 'pnacl_options', | |
| 688 'build_pnacl_newlib': 1, | |
| 689 'nexe_destination_dir': 'nacl_test_data', | |
| 690 'generate_nmf': 0, | |
| 691 'sources': [ | |
| 692 'simple.cc', | |
| 693 ], | |
| 694 'test_files': [ | |
| 695 'pnacl_nmf_options/pnacl_options.html', | |
| 696 'pnacl_nmf_options/pnacl_o_0.nmf', | |
| 697 'pnacl_nmf_options/pnacl_o_2.nmf', | |
| 698 'pnacl_nmf_options/pnacl_o_large.nmf', | |
| 699 ], | |
| 700 }, | |
| 701 }, | |
| 702 { | |
| 703 'target_name': 'pnacl_url_loader_test', | |
| 704 'type': 'none', | |
| 705 'variables': { | |
| 706 'nexe_target': 'pnacl_url_loader', | |
| 707 'build_pnacl_newlib': 1, | |
| 708 'nexe_destination_dir': 'nacl_test_data', | |
| 709 'generate_nmf': 1, | |
| 710 'link_flags': [ | |
| 711 '-lppapi', | |
| 712 ], | |
| 713 'sources': [ | |
| 714 'pnacl_url_loader/pnacl_url_loader.cc', | |
| 715 ], | |
| 716 'test_files': [ | |
| 717 'pnacl_url_loader/pnacl_url_loader.html', | |
| 718 ], | |
| 719 }, | |
| 720 }, | |
| 721 { | |
| 722 'target_name': 'pnacl_dyncode_syscall_disabled_test', | |
| 723 'type': 'none', | |
| 724 'variables': { | |
| 725 'nexe_target': 'pnacl_dyncode_syscall_disabled', | |
| 726 'build_pnacl_newlib': 1, | |
| 727 'nexe_destination_dir': 'nacl_test_data', | |
| 728 'link_flags': [ | |
| 729 '-lppapi', | |
| 730 '-lppapi_test_lib', | |
| 731 '-lplatform', | |
| 732 '-lgio', | |
| 733 # The "_private" variant of the library calls the syscalls | |
| 734 # directly, which allows us to test the syscalls directly, | |
| 735 # even when the dyncode IRT interface is also disabled under | |
| 736 # PNaCl. | |
| 737 '-lnacl_dyncode_private', | |
| 738 ], | |
| 739 'sources': [ | |
| 740 'pnacl_dyncode_syscall_disabled/pnacl_dyncode_syscall_disabled.cc', | |
| 741 ], | |
| 742 'test_files': [ | |
| 743 'pnacl_dyncode_syscall_disabled/pnacl_dyncode_syscall_disabled.html', | |
| 744 ], | |
| 745 }, | |
| 746 'dependencies': [ | |
| 747 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 748 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 749 '<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_dyncode_private
_lib', | |
| 750 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 751 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 752 'ppapi_test_lib', | |
| 753 ], | |
| 754 }, | |
| 755 { | |
| 756 'target_name': 'pnacl_hw_eh_disabled_test', | |
| 757 'type': 'none', | |
| 758 'variables': { | |
| 759 'nexe_target': 'pnacl_hw_eh_disabled', | |
| 760 'build_pnacl_newlib': 1, | |
| 761 'nexe_destination_dir': 'nacl_test_data', | |
| 762 'link_flags': [ | |
| 763 '-lppapi', | |
| 764 '-lppapi_test_lib', | |
| 765 '-lplatform', | |
| 766 '-lgio', | |
| 767 # The "_private" variant of the library calls the syscalls | |
| 768 # directly, which allows us to test the syscalls directly, | |
| 769 # even when the exception-handling IRT interface is also | |
| 770 # disabled under PNaCl. | |
| 771 '-lnacl_exception_private', | |
| 772 ], | |
| 773 'sources': [ | |
| 774 'pnacl_hw_eh_disabled/pnacl_hw_eh_disabled.cc', | |
| 775 ], | |
| 776 'test_files': [ | |
| 777 'pnacl_hw_eh_disabled/pnacl_hw_eh_disabled.html', | |
| 778 ], | |
| 779 }, | |
| 780 'dependencies': [ | |
| 781 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 782 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 783 '<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_exception_priva
te_lib', | |
| 784 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 785 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 786 'ppapi_test_lib', | |
| 787 ], | |
| 788 }, | |
| 789 # Legacy NaCl PPAPI interface tests being here. | |
| 790 { | |
| 791 'target_name': 'ppapi_ppb_core', | |
| 792 'type': 'none', | |
| 793 'variables': { | |
| 794 'nexe_target': 'ppapi_ppb_core', | |
| 795 'build_newlib': 1, | |
| 796 'build_glibc': 1, | |
| 797 'build_pnacl_newlib': 1, | |
| 798 'nexe_destination_dir': 'nacl_test_data', | |
| 799 'link_flags': [ | |
| 800 '-lppapi', | |
| 801 '-lppapi_test_lib', | |
| 802 '-lplatform', | |
| 803 '-lgio', | |
| 804 ], | |
| 805 'sources': [ | |
| 806 'ppapi/ppb_core/ppapi_ppb_core.cc', | |
| 807 ], | |
| 808 'test_files': [ | |
| 809 'ppapi/ppb_core/ppapi_ppb_core.html', | |
| 810 ], | |
| 811 }, | |
| 812 'dependencies': [ | |
| 813 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 814 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 815 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 816 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 817 'ppapi_test_lib', | |
| 818 ], | |
| 819 }, | |
| 820 { | |
| 821 'target_name': 'ppapi_ppb_instance', | |
| 822 'type': 'none', | |
| 823 'variables': { | |
| 824 'nexe_target': 'ppapi_ppb_instance', | |
| 825 'build_newlib': 1, | |
| 826 'build_glibc': 1, | |
| 827 'build_pnacl_newlib': 1, | |
| 828 'nexe_destination_dir': 'nacl_test_data', | |
| 829 'link_flags': [ | |
| 830 '-lppapi', | |
| 831 '-lppapi_test_lib', | |
| 832 '-lplatform', | |
| 833 '-lgio', | |
| 834 ], | |
| 835 'sources': [ | |
| 836 'ppapi/ppb_instance/ppapi_ppb_instance.cc', | |
| 837 ], | |
| 838 'test_files': [ | |
| 839 'ppapi/ppb_instance/ppapi_ppb_instance.html', | |
| 840 ], | |
| 841 }, | |
| 842 'dependencies': [ | |
| 843 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 844 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 845 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 846 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 847 'ppapi_test_lib', | |
| 848 ], | |
| 849 }, | |
| 850 { | |
| 851 'target_name': 'ppapi_ppp_instance', | |
| 852 'type': 'none', | |
| 853 'variables': { | |
| 854 'nexe_target': 'ppapi_ppp_instance', | |
| 855 'build_newlib': 1, | |
| 856 'build_glibc': 1, | |
| 857 'build_pnacl_newlib': 1, | |
| 858 'nexe_destination_dir': 'nacl_test_data', | |
| 859 'link_flags': [ | |
| 860 '-lppapi', | |
| 861 '-lppapi_test_lib', | |
| 862 '-lplatform', | |
| 863 '-lgio', | |
| 864 ], | |
| 865 'sources': [ | |
| 866 'ppapi/ppp_instance/ppapi_ppp_instance.cc', | |
| 867 ], | |
| 868 'test_files': [ | |
| 869 'ppapi/ppp_instance/ppapi_ppp_instance.html', | |
| 870 'ppapi/ppp_instance/ppapi_ppp_instance.js', | |
| 871 ], | |
| 872 }, | |
| 873 'dependencies': [ | |
| 874 '<(DEPTH)/native_client/src/shared/platform/platform.gyp:platform_lib', | |
| 875 '<(DEPTH)/native_client/src/shared/gio/gio.gyp:gio_lib', | |
| 876 '<(DEPTH)/ppapi/native_client/native_client.gyp:ppapi_lib', | |
| 877 '<(DEPTH)/ppapi/ppapi_nacl.gyp:ppapi_cpp_lib', | |
| 878 'ppapi_test_lib', | |
| 879 ], | |
| 880 }, | |
| 881 ], | |
| 882 'conditions': [ | |
| 883 ['target_arch!="arm" and disable_newlib==0', { | |
| 884 # Source file does not have asm for ARM. | |
| 885 'targets': [ | |
| 886 { | |
| 887 'target_name': 'partly_invalid', | |
| 888 'type': 'none', | |
| 889 'variables': { | |
| 890 'nexe_target': 'partly_invalid', | |
| 891 'build_newlib': 1, | |
| 892 'build_glibc': 0, | |
| 893 'build_pnacl_newlib': 0, | |
| 894 'nexe_destination_dir': 'nacl_test_data', | |
| 895 'sources': [ | |
| 896 '<(DEPTH)/native_client/tests/stubout_mode/partly_invalid.c', | |
| 897 ], | |
| 898 }, | |
| 899 }, | |
| 900 ], | |
| 901 }], | |
| 902 | |
| 903 # Tests for non-SFI mode. | |
| 904 ['OS=="linux"', { | |
| 905 'targets': [ | |
| 906 { | |
| 907 'target_name': 'nonsfi_libc_free_nexe', | |
| 908 'type': 'executable', | |
| 909 'product_name': '>(nexe_destination_dir)/libc_free_>(arch_suffix)', | |
| 910 'product_extension': 'nexe', | |
| 911 'variables': { | |
| 912 'arch_suffix': '<(target_arch)', | |
| 913 # This is needed, because NaCl's target_default rule is | |
| 914 # automatically applied to all the targets in this file, and it | |
| 915 # requires nexe_destination_dir, even if it is not important. | |
| 916 'nexe_destination_dir': 'nacl_test_data/libc-free', | |
| 917 }, | |
| 918 'sources': [ | |
| 919 'nonsfi/libc_free.c', | |
| 920 ], | |
| 921 # Here, we would like to link a relocatable, libc-free executable. | |
| 922 # -shared/-fPIC make this binary relocatable. -nostdlib ensures | |
| 923 # this is libc-free. | |
| 924 # The program does not apply any dynamic relocations at start up, | |
| 925 # so it cannot rely on relocations having been applied. | |
| 926 # In addition, -fvisibility=hidden avoids creating some types | |
| 927 # of relocation. | |
| 928 'cflags': [ | |
| 929 '-fPIC', | |
| 930 '-fvisibility=hidden', | |
| 931 | |
| 932 # Stack-Smashing protector does not work with libc-free context. | |
| 933 '-fno-stack-protector', | |
| 934 # Optimizers may translate the original code to code which | |
| 935 # requires builtin functions and/or relocations. Specifically, | |
| 936 # the LLVM's optimizer translates for-loop based zero | |
| 937 # clear to memset. | |
| 938 '-O0', | |
| 939 ], | |
| 940 'cflags!': [ | |
| 941 # We filter these out because release_extra_cflags or another | |
| 942 # such thing might be adding them in, and those options wind up | |
| 943 # coming after the -fno-stack-protector we added above. | |
| 944 '-fstack-protector', | |
| 945 '-fstack-protector-all', | |
| 946 '-fprofile-generate', | |
| 947 '-finstrument-functions', | |
| 948 # ARM GCC emits symbols like __aeabi_unwind_cpp_pr0 in | |
| 949 # .exidx sections with this flag. | |
| 950 '-funwind-tables', | |
| 951 ], | |
| 952 'ldflags': [ | |
| 953 '-nostdlib', | |
| 954 '-shared', | |
| 955 # This binary cannot relocate itself, so we should have no | |
| 956 # undefined references left. | |
| 957 '-Wl,--no-undefined', | |
| 958 ], | |
| 959 'ldflags!': [ | |
| 960 # Explicitly remove the -pthread flag to avoid a link time warning. | |
| 961 '-pthread', | |
| 962 ], | |
| 963 # Do not use any sanitizers tools, which require a few symbols. | |
| 964 'cflags/': [ | |
| 965 ['exclude', '-fsanitize'], | |
| 966 ['exclude', '^-O'], # Strip -O2, -Os etc. | |
| 967 ], | |
| 968 'ldflags/': [ | |
| 969 ['exclude', '-fsanitize'], | |
| 970 ], | |
| 971 'defines': [ | |
| 972 # The code depends on NaCl's headers. This is a macro for them. | |
| 973 'NACL_LINUX=1', | |
| 974 ], | |
| 975 # For native_client/src/include/... | |
| 976 'include_dirs': [ | |
| 977 '../../../..', | |
| 978 ], | |
| 979 'conditions': [ | |
| 980 # Overwrite suffix for x64 and ia32 to align NaCl's naming | |
| 981 # convention. | |
| 982 ['target_arch=="x64"', { | |
| 983 'variables': { | |
| 984 'arch_suffix': 'x86_64', | |
| 985 } | |
| 986 }], | |
| 987 ['target_arch=="ia32"', { | |
| 988 'variables': { | |
| 989 'arch_suffix': 'x86_32', | |
| 990 } | |
| 991 }], | |
| 992 ], | |
| 993 }, | |
| 994 { | |
| 995 'target_name': 'nonsfi_libc_free', | |
| 996 'type': 'none', | |
| 997 'variables': { | |
| 998 'nexe_destination_dir': 'nacl_test_data', | |
| 999 'destination_dir': '<(PRODUCT_DIR)/>(nexe_destination_dir)/libc-free
', | |
| 1000 'test_files': [ | |
| 1001 # TODO(ncbray) move into chrome/test/data/nacl when all tests are | |
| 1002 # converted. | |
| 1003 '<(DEPTH)/ppapi/native_client/tools/browser_tester/browserdata/nac
ltest.js', | |
| 1004 'nonsfi/libc_free.html', | |
| 1005 'nonsfi/libc_free.nmf', | |
| 1006 'nonsfi/irt_test.html', | |
| 1007 ], | |
| 1008 }, | |
| 1009 'dependencies': [ | |
| 1010 'nonsfi_libc_free_nexe', | |
| 1011 ], | |
| 1012 # Because we are still under development for non-SFI mode, the | |
| 1013 # toolchain is not yet ready, which means ppapi_nacl_common does not | |
| 1014 # work well for non-SFI mode yet. Instead, we manually set up the | |
| 1015 # testing environment here. | |
| 1016 'copies': [ | |
| 1017 { | |
| 1018 'destination': '>(destination_dir)', | |
| 1019 'files': [ | |
| 1020 '>@(test_files)', | |
| 1021 ], | |
| 1022 }, | |
| 1023 ], | |
| 1024 }, | |
| 1025 ], | |
| 1026 }], | |
| 1027 ], | |
| 1028 } | |
| OLD | NEW |