| 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('env') | 6 Import('env') |
| 7 env.Append(CCFLAGS=['-Wno-long-long']) | 7 env.Append(CCFLAGS=['-Wno-long-long']) |
| 8 | 8 |
| 9 # This library is linked into irt.nexe (see src/untrusted/irt/). | 9 # This library is linked into irt.nexe (see src/untrusted/irt/). |
| 10 # All IRT code must avoid direct use of the TLS ABI register, which | 10 # All IRT code must avoid direct use of the TLS ABI register, which |
| 11 # is reserved for user TLS. Instead, ensure all TLS accesses use a | 11 # is reserved for user TLS. Instead, ensure all TLS accesses use a |
| 12 # call to __nacl_read_tp, which the IRT code overrides to segregate | 12 # call to __nacl_read_tp, which the IRT code overrides to segregate |
| 13 # IRT-private TLS from user TLS. | 13 # IRT-private TLS from user TLS. |
| 14 if not env.Bit('bitcode') and not env.Bit('nacl_glibc'): | 14 if not env.Bit('bitcode') and not env.Bit('nacl_glibc'): |
| 15 env.Append(CCFLAGS=['-mtls-use-call']) | 15 env.Append(CCFLAGS=['-mtls-use-call']) |
| 16 | 16 |
| 17 platform_inputs = [ | 17 platform_inputs = [ |
| 18 'nacl_check.c', | 18 'nacl_check.c', |
| 19 'nacl_log.c', | 19 'nacl_log.c', |
| 20 'linux/condition_variable.cc', | 20 'linux/condition_variable.cc', |
| 21 'linux/lock.cc', | 21 'linux/lock.cc', |
| 22 'linux/nacl_exit.c', | 22 'linux/nacl_exit.c', |
| 23 'linux/nacl_threads.c', | 23 'linux/nacl_threads.c', |
| 24 'linux/nacl_timestamp.c', | 24 'linux/nacl_timestamp.c', |
| 25 'linux/time_linux.cc', | 25 'linux/time_linux.cc', |
| 26 'nacl_sync.cc', | 26 'nacl_sync.cc', |
| 27 'nacl_sync_checked.c', |
| 27 'time.cc', | 28 'time.cc', |
| 28 ] | 29 ] |
| 29 | 30 |
| 30 env.NaClSdkLibrary('platform', | 31 env.NaClSdkLibrary('platform', |
| 31 platform_inputs, | 32 platform_inputs, |
| 32 LIBS=['nacl', 'pthread', 'gio']) | 33 LIBS=['nacl', 'pthread', 'gio']) |
| 33 | 34 |
| 34 headers = [ | 35 headers = [ |
| 35 'nacl_check.h', | 36 'nacl_check.h', |
| 36 'nacl_log.h', | 37 'nacl_log.h', |
| 37 'nacl_threads.h', | 38 'nacl_threads.h', |
| 38 ] | 39 ] |
| 39 | 40 |
| 40 header_install = env.AddHeaderToSdk(headers) | 41 header_install = env.AddHeaderToSdk(headers) |
| 41 env.AddLibraryToSdk(['platform']) | 42 env.AddLibraryToSdk(['platform']) |
| 42 | 43 |
| 43 env.Requires('platform', header_install) | 44 env.Requires('platform', header_install) |
| OLD | NEW |