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 be
4 # found in the LICENSE file.
8 # suspend_test_guest.nexe fails to link when Valgrind is enabled
9 # because of a problem with the TLS ".tbss" section.
10 if env.IsRunningUnderValgrind():
13 if 'TRUSTED_ENV' not in env:
15 trusted_env = env['TRUSTED_ENV']
17 if not env.AllowInlineAssembly():
20 test_guest = env.ComponentProgram(
21 'suspend_test_guest', ['suspend_test_guest.c'],
22 EXTRA_LIBS=['${NONIRT_LIBS}', 'test_common'])
24 test_host = trusted_env.ComponentProgram(
25 'suspend_test_host', ['suspend_test_host.c'],
26 EXTRA_LIBS=['sel', 'test_common'])
28 node = env.CommandTest('thread_suspension_test.out',
29 env.AddBootstrap(test_host, [test_guest]),
31 env.AddNodeToTestSuite(node, ['small_tests', 'nonpexe_tests'],
32 'run_thread_suspension_test',
33 is_broken=not env.Bit('nacl_static_link') or
34 # This test is flaky on mac10.7-newlib-dbg-asan.
35 # See https://code.google.com/p/nativeclient/issues/detail?id=3906
36 (env.Bit('asan') and env.Bit('host_mac')))