Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(109)

Side by Side Diff: tools/scons_to_gn/test.scons

Issue 758223003: Cleanup: Use Bit('build_ARCH') instead of Bit('target_ARCH') (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Fix + simplify Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tests/gdb/nacl.scons ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2014 The Native Client Authors. All rights reserved. 1 # Copyright (c) 2014 The Native Client Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file 3 # found in the LICENSE file
4 4
5 # Test file for scons_to_gn 5 # Test file for scons_to_gn
6 6
7 sources = ['A.c', 'B.c', 'C.c'] 7 sources = ['A.c', 'B.c', 'C.c']
8 defines = [] 8 defines = []
9 9
10 if env.Bit('win'): 10 if env.Bit('win'):
11 sources += ['win'] 11 sources += ['win']
12 if env.Bit('target_x86_32'): 12 if env.Bit('build_x86_32'):
13 defines += ['_x86'] 13 defines += ['_x86']
14 if env.Bit('target_x86_64'): 14 if env.Bit('build_x86_64'):
15 defines += ['_x64'] 15 defines += ['_x64']
16 16
17 if True: 17 if True:
18 sources += ['FOOBAR.c'] 18 sources += ['FOOBAR.c']
19 19
20 env.ComponentLibrary('all', sources, CFLAGS=['-D' + x for x in defines]) 20 env.ComponentLibrary('all', sources, CFLAGS=['-D' + x for x in defines])
21 21
22 nacl_env = env.Clone() 22 nacl_env = env.Clone()
23 nacl_env.Append(CFLAGS=['-DNACL']) 23 nacl_env.Append(CFLAGS=['-DNACL'])
24 24
25 if nacl_env.Bit('win'): 25 if nacl_env.Bit('win'):
26 nacl_env.ComponentLibrary('win', sources) 26 nacl_env.ComponentLibrary('win', sources)
27 27
28 if env.Bit('linux'): 28 if env.Bit('linux'):
29 env.ComponentLibrary('linux', sources) 29 env.ComponentLibrary('linux', sources)
30 30
31 if env.Bit('linux'): 31 if env.Bit('linux'):
32 cpu_test = nacl_env.ComponentProgram('my_test', ['testing/test.c'], 32 cpu_test = nacl_env.ComponentProgram('my_test', ['testing/test.c'],
33 EXTRA_LIBS=['cpu_features','platform']) 33 EXTRA_LIBS=['cpu_features','platform'])
34 34
35 node = nacl_env.CommandTest( 35 node = nacl_env.CommandTest(
36 'cpu_x86_test.out', 36 'cpu_x86_test.out',
37 [cpu_test]) 37 [cpu_test])
38 nacl_env.AddNodeToTestSuite(node, ['small_tests'], 'run_cpu_x86_test') 38 nacl_env.AddNodeToTestSuite(node, ['small_tests'], 'run_cpu_x86_test')
OLDNEW
« no previous file with comments | « tests/gdb/nacl.scons ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698