OLD | NEW |
1 # -*- python -*- | 1 # -*- python -*- |
2 # Copyright 2012 The Native Client Authors. All rights reserved. | 2 # Copyright 2012 The Native Client Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can | 3 # Use of this source code is governed by a BSD-style license that can |
4 # be found in the LICENSE file. | 4 # be 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 trusted_env = env['TRUSTED_ENV'] | 10 trusted_env = env['TRUSTED_ENV'] |
11 | 11 |
12 # This duplicates the library list in src/trusted/service_runtime/build.scons. | |
13 # We would not have to do this if we could get Scons to track dependencies | |
14 # between libraries. | |
15 test_host = trusted_env.ComponentProgram( | 12 test_host = trusted_env.ComponentProgram( |
16 'desc_test_host', ['desc_test_host.c'], | 13 'desc_test_host', ['desc_test_host.c'], |
17 EXTRA_LIBS=['sel', | 14 EXTRA_LIBS=['sel', 'sel_debug_dummy']) |
18 'nacl_interval', | |
19 'sel_debug_dummy', | |
20 'manifest_proxy', | |
21 'simple_service', | |
22 'thread_interface', | |
23 'gio_wrapped_desc', | |
24 'nonnacl_srpc', | |
25 'nrd_xfer', | |
26 'nacl_perf_counter', | |
27 'nacl_base', | |
28 'imc', | |
29 'container', | |
30 'nacl_fault_inject', | |
31 'platform', | |
32 'platform_qual_lib', | |
33 'gio', | |
34 ]) | |
35 | 15 |
36 test_guest = env.ComponentProgram( | 16 test_guest = env.ComponentProgram( |
37 'desc_test_guest', ['desc_test_guest.c'], | 17 'desc_test_guest', ['desc_test_guest.c'], |
38 EXTRA_LIBS=['imc_syscalls', '${NONIRT_LIBS}']) | 18 EXTRA_LIBS=['imc_syscalls', '${NONIRT_LIBS}']) |
39 | 19 |
40 if env.Bit('pnacl_generate_pexe'): | 20 if env.Bit('pnacl_generate_pexe'): |
41 test_guest = env.GetTranslatedNexe(test_guest) | 21 test_guest = env.GetTranslatedNexe(test_guest) |
42 | 22 |
43 test_command = [test_host, test_guest] | 23 test_command = [test_host, test_guest] |
44 bootstrap, _ = env.GetBootstrap() | 24 bootstrap, _ = env.GetBootstrap() |
45 if bootstrap is not None: | 25 if bootstrap is not None: |
46 test_command = [bootstrap] + test_command | 26 test_command = [bootstrap] + test_command |
47 | 27 |
48 node = env.CommandTest('custom_desc_test.out', test_command) | 28 node = env.CommandTest('custom_desc_test.out', test_command) |
49 env.AddNodeToTestSuite(node, ['small_tests'], 'run_custom_desc_test', | 29 env.AddNodeToTestSuite(node, ['small_tests'], 'run_custom_desc_test', |
50 is_broken=not env.Bit('nacl_static_link')) | 30 is_broken=not env.Bit('nacl_static_link')) |
OLD | NEW |