Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # -*- python -*- | 1 # -*- python -*- |
| 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 import platform | 6 import platform |
| 7 import os | 7 import os |
| 8 | 8 |
| 9 Import('env') | 9 Import('env') |
| 10 | 10 |
| 11 # TODO(robertm): consider adding this to the top level scons files | 11 # TODO(robertm): consider adding this to the top level scons files |
| 12 env.Append(CPPPATH=['${TARGET_ROOT}']) | 12 env.Append(CPPPATH=['${TARGET_ROOT}']) |
| 13 # this is needed for including gen/... files, see GENERATED below | 13 # this is needed for including gen/... files, see GENERATED below |
| 14 | 14 |
| 15 # this is needed for including gdb_utils files | 15 # this is needed for including gdb_utils files |
| 16 env.Append(CPPPATH=['${SOURCE_ROOT}/gdb_utils/src']) | 16 env.Append(CPPPATH=['${SOURCE_ROOT}/gdb_utils/src']) |
| 17 | 17 |
| 18 DEBUG_LIBS = ['debug_stub_init', 'gdb_rsp', 'debug_stub'] | 18 DEBUG_LIBS = ['debug_stub_init', 'gdb_rsp', 'debug_stub'] |
| 19 if env.Bit('windows'): | 19 if env.Bit('windows'): |
| 20 env.Append(CPPDEFINES=['WIN32']) | 20 env.Append(CPPDEFINES=['WIN32']) |
| 21 if env.Bit('target_x86_64'): | 21 if env.Bit('target_x86_64'): |
| 22 env.Append(CPPDEFINES=['WIN64']) | 22 env.Append(CPPDEFINES=['WIN64']) |
| 23 | 23 |
| 24 # Thumb2 mode sets a variety of different defines. | |
| 25 if env.Bit('target_arm_thumb2'): | |
| 26 env.Append(CPPDEFINES=['NACL_TARGET_IS_THUMB2=1']) | |
| 27 | |
| 24 # normally comment out -- uncomment out to test the pedantic removal | 28 # normally comment out -- uncomment out to test the pedantic removal |
| 25 # check below. | 29 # check below. |
| 26 #if env.Bit('linux') or env.Bit('mac'): | 30 #if env.Bit('linux') or env.Bit('mac'): |
| 27 # env.FilterOut(CCFLAGS=['-pedantic']) | 31 # env.FilterOut(CCFLAGS=['-pedantic']) |
| 28 # env.FilterOut(CCFLAGS=['-Wall']) | 32 # env.FilterOut(CCFLAGS=['-Wall']) |
| 29 | 33 |
| 30 # Make a copy of debug CRT for now. | 34 # Make a copy of debug CRT for now. |
| 31 # TODO(bradnelson): there should be a better way to generalize this requirement. | 35 # TODO(bradnelson): there should be a better way to generalize this requirement. |
| 32 crt = [] | 36 crt = [] |
| 33 if env.AllBits('windows', 'debug'): | 37 if env.AllBits('windows', 'debug'): |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 121 elif env.Bit('build_arm'): | 125 elif env.Bit('build_arm'): |
| 122 ldr_inputs += [ | 126 ldr_inputs += [ |
| 123 'arch/arm/nacl_app.c', | 127 'arch/arm/nacl_app.c', |
| 124 'arch/arm/nacl_switch_to_app_arm.c', | 128 'arch/arm/nacl_switch_to_app_arm.c', |
| 125 'arch/arm/sel_rt.c', | 129 'arch/arm/sel_rt.c', |
| 126 'arch/arm/nacl_tls.c', | 130 'arch/arm/nacl_tls.c', |
| 127 'arch/arm/sel_ldr_arm.c', | 131 'arch/arm/sel_ldr_arm.c', |
| 128 'arch/arm/sel_addrspace_arm.c', | 132 'arch/arm/sel_addrspace_arm.c', |
| 129 'arch/arm/nacl_switch.S', | 133 'arch/arm/nacl_switch.S', |
| 130 'arch/arm/nacl_syscall.S', | 134 'arch/arm/nacl_syscall.S', |
| 131 'arch/arm/springboard.S', | |
| 132 'arch/arm/tramp_arm.S', | |
| 133 ] | 135 ] |
| 134 if env.Bit('target_arm_thumb2'): | 136 if env.Bit('build_arm_thumb2') or env.Bit('target_arm_thumb2'): |
|
Karl
2011/08/30 19:53:52
Why is this needed for the build environment? I un
jasonwkim
2011/09/16 20:09:16
It was just to keep the prior bifurcation bet. BUI
| |
| 135 thumb2_env = env.Clone() | 137 thumb2_env = env.Clone() |
| 136 thumb2_env.Append(ASFLAGS=['-mthumb']) | 138 thumb2_env.Replace(ASFLAGS=['-mthumb']) |
|
bsy
2011/09/01 00:30:00
could env already have other ASFLAGS already set?
jasonwkim
2011/09/16 20:09:16
Don't know. I'll have to check
| |
| 137 ldr_inputs += [ | 139 ldr_inputs += [ |
| 138 thumb2_env.DualObject('arch/arm/springboard_thumb2.S'), | 140 thumb2_env.DualObject('arch/arm/springboard_thumb2.S'), |
| 139 thumb2_env.DualObject('arch/arm/tramp_arm_thumb2.S'), | 141 thumb2_env.DualObject('arch/arm/tramp_arm_thumb2.S'), |
| 140 ] | 142 ] |
| 141 else: | 143 else: |
| 142 ldr_inputs += [ | 144 ldr_inputs += [ |
| 143 'arch/arm/springboard.S', | 145 'arch/arm/springboard.S', |
| 144 'arch/arm/tramp_arm.S', | 146 'arch/arm/tramp_arm.S', |
| 145 ] | 147 ] |
| 146 | 148 |
| (...skipping 681 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 828 expected_exit_status = 'sigabrt' | 830 expected_exit_status = 'sigabrt' |
| 829 node = env.CommandTest( | 831 node = env.CommandTest( |
| 830 'sel_ldr_thread_death_test.out', | 832 'sel_ldr_thread_death_test.out', |
| 831 command=[sel_ldr_thread_death_test_exe], | 833 command=[sel_ldr_thread_death_test_exe], |
| 832 exit_status=expected_exit_status) | 834 exit_status=expected_exit_status) |
| 833 | 835 |
| 834 # TODO(tuduce): Make it work on windows. | 836 # TODO(tuduce): Make it work on windows. |
| 835 env.AddNodeToTestSuite(node, ['medium_tests'], | 837 env.AddNodeToTestSuite(node, ['medium_tests'], |
| 836 'run_sel_ldr_thread_death_test', | 838 'run_sel_ldr_thread_death_test', |
| 837 is_broken=env.Bit('windows')) | 839 is_broken=env.Bit('windows')) |
| OLD | NEW |