Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / native_client / src / trusted / debug_stub / build.scons
1 # -*- python -*-
2 # Copyright 2010 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 debug_sources = [
9   'abi.cc',
10   'debug_stub.cc',
11   'nacl_debug.cc',
12   'packet.cc',
13   'session.cc',
14   'target.cc',
15   'thread_common.cc',
16   'transport_common.cc',
17   'util.cc',
18   ]
19
20 if env.Bit('windows'):
21   debug_sources += [
22     'win/debug_stub_win.cc',
23     'win/platform_impl.cc',
24     'win/thread_impl.cc',
25   ]
26 else:
27   debug_sources += [
28     'posix/debug_stub_posix.cc',
29     'posix/platform_impl.cc',
30     'posix/thread_impl.cc',
31   ]
32
33 rsp_test_sources = [
34   'abi_test.cc',
35   'packet_test.cc',
36   'session_test.cc',
37   'util_test.cc',
38   'test.cc'
39   ]
40
41
42 env.DualLibrary('debug_stub', debug_sources)
43
44 gdb_rsp_test_exe = env.ComponentProgram(
45     'gdb_rsp_unittest', rsp_test_sources, EXTRA_LIBS=['debug_stub'])
46
47 node = env.CommandTest('gdb_rsp_unittest.out', command=[gdb_rsp_test_exe])
48 env.AddNodeToTestSuite(node, ['small_tests'], 'run_gdb_rsp_tests')