| 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 # Do not run these tests with pexes, assuming they are portable, since | 8 # Do not run these tests with pexes, assuming they are portable, since |
| 9 # they use inline assembler. | 9 # they use inline assembler. |
| 10 if env.Bit('bitcode') and env.Bit('pnacl_generate_pexe'): | 10 if env.Bit('bitcode') and env.Bit('pnacl_generate_pexe'): |
| 11 Return() | 11 Return() |
| 12 | 12 |
| 13 # The file partly_invalid.c contains inline assembler | 13 # The file partly_invalid.c contains inline assembler |
| 14 if env.Bit('bitcode'): | 14 if env.Bit('bitcode'): |
| 15 env.AddBiasForPNaCl() | 15 env.AddBiasForPNaCl() |
| 16 env.PNaClForceNative() | 16 env.PNaClForceNative() |
| 17 | 17 |
| 18 # Newlib + PIC doesn't provide native ___tls_get_addr, so gold complains. | 18 # Newlib + PIC doesn't provide native ___tls_get_addr, so gold complains. |
| 19 if env.Bit('bitcode') and env.Bit('nacl_pic'): | 19 if env.Bit('bitcode') and env.Bit('nacl_pic'): |
| 20 Return() | 20 Return() |
| 21 | 21 |
| 22 # TODO(mseaborn): Extend the ARM validator to support this. | 22 # TODO(mseaborn): Extend the ARM validator to support this. |
| 23 # BUG= http://code.google.com/p/nativeclient/issues/detail?id=2369 | 23 # BUG= http://code.google.com/p/nativeclient/issues/detail?id=2369 |
| 24 if env.Bit('build_arm'): | 24 if env.Bit('build_arm'): |
| 25 Return() | 25 Return() |
| 26 | 26 |
| 27 # Curiously, on the nacl-win64_glibc_opt trybot, small_tests_irt is | |
| 28 # producing a version of partly_invalid.nexe that contains an empty | |
| 29 # ".iplt" section, and ncval_stubout currently fails on empty sections | |
| 30 # (see http://code.google.com/p/nativeclient/issues/detail?id=2795). | |
| 31 # I cannot reproduce this locally. It might be a result of | |
| 32 # non-determinism in the order in which Scons targets are built. | |
| 33 # TODO(mseaborn): Fix ncval_stubout and investigate why we get an | |
| 34 # empty ".iplt" section. | |
| 35 if env.Bit('tests_use_irt') and env.Bit('nacl_glibc'): | |
| 36 Return() | |
| 37 | |
| 38 # R-DFA does not support stubout mode | 27 # R-DFA does not support stubout mode |
| 39 if env.Bit('validator_ragel'): | 28 if env.Bit('validator_ragel'): |
| 40 Return() | 29 Return() |
| 41 | 30 |
| 42 if 'TRUSTED_ENV' not in env: | 31 if 'TRUSTED_ENV' not in env: |
| 43 Return() | 32 Return() |
| 44 | 33 |
| 45 stubout_tool = env['TRUSTED_ENV'].File( | 34 stubout_tool = env['TRUSTED_ENV'].File( |
| 46 '${STAGING_DIR}/${PROGPREFIX}ncval_stubout${PROGSUFFIX}') | 35 '${STAGING_DIR}/${PROGPREFIX}ncval_stubout${PROGSUFFIX}') |
| 47 | 36 |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 env.AddNodeToTestSuite(node, test_suites, 'run_stubout_mode_test') | 83 env.AddNodeToTestSuite(node, test_suites, 'run_stubout_mode_test') |
| 95 | 84 |
| 96 # Using the standalone ncval_stubout tool to rewrite the executable | 85 # Using the standalone ncval_stubout tool to rewrite the executable |
| 97 # offline should be equivalent to using sel_ldr's "-s" option. | 86 # offline should be equivalent to using sel_ldr's "-s" option. |
| 98 node = env.CommandSelLdrTestNacl( | 87 node = env.CommandSelLdrTestNacl( |
| 99 'partly_invalid_stubout.out', | 88 'partly_invalid_stubout.out', |
| 100 partly_invalid_stubout_nexe, | 89 partly_invalid_stubout_nexe, |
| 101 stdout_golden=env.File('with_stubout.stdout'), | 90 stdout_golden=env.File('with_stubout.stdout'), |
| 102 exit_status='untrusted_sigill') | 91 exit_status='untrusted_sigill') |
| 103 env.AddNodeToTestSuite(node, test_suites, 'run_offline_stubout_test') | 92 env.AddNodeToTestSuite(node, test_suites, 'run_offline_stubout_test') |
| OLD | NEW |