OLD | NEW |
---|---|
(Empty) | |
1 # -*- python -*- | |
Mark Seaborn
2012/02/09 22:24:55
The in-browser version isn't going to work for NaC
bradn
2012/02/11 01:04:14
I've disabled when disable_dynamic_plugin_loading
| |
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 | |
4 # found in the LICENSE file. | |
5 | |
6 Import('env') | |
7 | |
8 # Exception handling support is not implemented everywhere yet. | |
9 is_broken = (not (env.Bit('host_windows') or env.Bit('host_mac')) or | |
10 not env.Bit('build_x86_32')) | |
11 | |
12 # Don't build on anything other than x86-32 for now. | |
13 if not env.Bit('build_x86_32'): | |
14 Return() | |
15 | |
16 env.Append(CCFLAGS=['-O0', '-fno-omit-frame-pointer', '-g']) | |
17 env.Append(CPPDEFINES=['IN_BROWER=1']) | |
18 | |
19 untrusted_crash_dump_lib = env.ComponentLibrary( | |
20 'inbrowser_untrusted_crash_dump_lib', | |
21 '${MAIN_DIR}/tests/untrusted_crash_dump/untrusted_crash_dump_lib.c', | |
22 EXTRA_LIBS=['srpc', 'platform', 'gio', 'imc', 'imc_syscalls', | |
23 '${PTHREAD_LIBS}', '${NON_PPAPI_BROWSER_LIBS}'], | |
24 COMPONENT_STATIC=not env.Bit('nacl_glibc')) | |
25 | |
26 untrusted_crash_dump_test = env.ComponentProgram( | |
27 'inbrowser_untrusted_crash_dump_test', | |
28 [env.ComponentObject( | |
29 'untrusted_crash_dump', | |
30 '${MAIN_DIR}/tests/untrusted_crash_dump/untrusted_crash_dump.c'), | |
31 env.ComponentObject( | |
32 'untrusted_crash_dump_test', | |
33 '${MAIN_DIR}/tests/untrusted_crash_dump/untrusted_crash_dump_test.c')], | |
34 EXTRA_LIBS=['untrusted_crash_dump_lib', | |
35 'srpc', 'platform', 'gio', 'imc', 'imc_syscalls', | |
36 '${PTHREAD_LIBS}', '${NON_PPAPI_BROWSER_LIBS}']) | |
37 | |
38 # Make sure .so is in place for decoding. | |
39 if env.Bit('nacl_glibc'): | |
40 env.Depends(untrusted_crash_dump_test, | |
41 '$STAGING_DIR/libuntrusted_crash_dump_lib.so') | |
42 | |
43 if env.Bit('nacl_glibc'): | |
44 golden = 'untrusted_crash_dump_test_glibc.golden' | |
45 else: | |
46 golden = 'untrusted_crash_dump_test_newlib.golden' | |
47 golden = '$MAIN_DIR/tests/untrusted_crash_dump/' + golden | |
48 | |
49 env['ENV']['NACL_UNTRUSTED_EXCEPTION_HANDLING'] = '1' | |
50 node = env.PPAPIBrowserTester( | |
51 'inbrowser_untrusted_crash_dump_test.out', | |
52 url='untrusted_crash_dump.html', | |
53 nmfs=['inbrowser_untrusted_crash_dump_test.nmf'], | |
54 nacl_exe_stdout={ | |
55 'file': ('${TARGET_ROOT}/test_results/' | |
56 'inbrowser_untrusted_crash_dump_test.stdout'), | |
57 'golden': golden, | |
58 'decode_crash_dump': True, | |
59 }, | |
60 files=[untrusted_crash_dump_test, | |
61 env.File('untrusted_crash_dump.html')]) | |
62 env.AddNodeToTestSuite( | |
63 node, ['chrome_browser_tests', 'exception_tests'], | |
64 'run_inbrowser_untrusted_crash_dump_test', | |
65 is_broken=env.PPAPIBrowserTesterIsBroken() or | |
66 env.Bit('running_on_valgrind') or is_broken) | |
OLD | NEW |