| OLD | NEW |
| 1 # -*- python -*- | 1 # -*- python -*- |
| 2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 Import('env') | 6 Import('env') |
| 7 | 7 |
| 8 if 'TRUSTED_ENV' not in env: | 8 if 'TRUSTED_ENV' not in env: |
| 9 Return() | 9 Return() |
| 10 | 10 |
| 11 # Even if stubout mode is not supported sel_ldr still must run valid .nexes. | 11 # Even if stubout mode is not supported sel_ldr still must run valid .nexes. |
| 12 hello_world_nexe = env.File('${STAGING_DIR}/hello_world${PROGSUFFIX}') | 12 hello_world_nexe = env.File('${STAGING_DIR}/hello_world${PROGSUFFIX}') |
| 13 node = env.CommandSelLdrTestNacl( | 13 node = env.CommandSelLdrTestNacl( |
| 14 'hello_world_stub_out_run.out', hello_world_nexe, | 14 'hello_world_stub_out_run.out', hello_world_nexe, |
| 15 sel_ldr_flags=['-s']) | 15 sel_ldr_flags=['-s']) |
| 16 env.AddNodeToTestSuite( | 16 env.AddNodeToTestSuite( |
| 17 node, ['small_tests'], 'run_valid_nexe_with_stubout_test') | 17 node, ['small_tests'], 'run_valid_nexe_with_stubout_test') |
| 18 | 18 |
| 19 # Do not run these tests with pexes, assuming they are portable, since | 19 # Do not run these tests with pexes, assuming they are portable, since |
| 20 # they use inline assembler. | 20 # they use inline assembler. |
| 21 if env.Bit('bitcode') and env.Bit('pnacl_generate_pexe'): | 21 if env.Bit('bitcode') and env.Bit('pnacl_generate_pexe'): |
| 22 Return() | 22 Return() |
| 23 | 23 |
| 24 # nacl-clang currently has trouble with the top-level asm in this file: |
| 25 # https://code.google.com/p/nativeclient/issues/detail?id=3968 |
| 26 if env.Bit('nacl_clang'): |
| 27 Return() |
| 28 |
| 24 # The file partly_invalid.c contains inline assembler | 29 # The file partly_invalid.c contains inline assembler |
| 25 if env.Bit('bitcode'): | 30 if env.Bit('bitcode'): |
| 26 env.AddBiasForPNaCl() | 31 env.AddBiasForPNaCl() |
| 27 env.PNaClForceNative() | 32 env.PNaClForceNative() |
| 28 | 33 |
| 29 # Newlib + PIC doesn't provide native ___tls_get_addr, so gold complains. | 34 # Newlib + PIC doesn't provide native ___tls_get_addr, so gold complains. |
| 30 if env.Bit('bitcode') and env.Bit('nacl_pic'): | 35 if env.Bit('bitcode') and env.Bit('nacl_pic'): |
| 31 Return() | 36 Return() |
| 32 | 37 |
| 33 # TODO(mseaborn): Extend the ARM validator to support this. | 38 # TODO(mseaborn): Extend the ARM validator to support this. |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 # offline should be equivalent to using sel_ldr's "-s" option. | 113 # offline should be equivalent to using sel_ldr's "-s" option. |
| 109 # This tool exists only for x86. | 114 # This tool exists only for x86. |
| 110 node = env.CommandSelLdrTestNacl( | 115 node = env.CommandSelLdrTestNacl( |
| 111 'partly_invalid_stubout.out', | 116 'partly_invalid_stubout.out', |
| 112 partly_invalid_stubout_nexe, | 117 partly_invalid_stubout_nexe, |
| 113 stdout_golden=env.File('with_stubout.stdout'), | 118 stdout_golden=env.File('with_stubout.stdout'), |
| 114 exit_status='untrusted_sigsegv') | 119 exit_status='untrusted_sigsegv') |
| 115 env.AddNodeToTestSuite(node, test_suites, 'run_offline_stubout_test', | 120 env.AddNodeToTestSuite(node, test_suites, 'run_offline_stubout_test', |
| 116 is_broken=(env.Bit('target_mips32') or | 121 is_broken=(env.Bit('target_mips32') or |
| 117 testing_on_asan_or_valgrind)) | 122 testing_on_asan_or_valgrind)) |
| OLD | NEW |