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

Side by Side Diff: SConstruct

Issue 11691004: [MIPS] Do not use pnacl-irt-link for MIPS target. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Created 7 years, 12 months 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 | « no previous file | 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 #! -*- python -*- 1 #! -*- python -*-
2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. 2 # Copyright (c) 2012 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 atexit 6 import atexit
7 import os 7 import os
8 import platform 8 import platform
9 import re 9 import re
10 import subprocess 10 import subprocess
(...skipping 3061 matching lines...) Expand 10 before | Expand all | Expand 10 after
3072 # ignore the --nacl_glibc, nacl_pic=1 and bitcode=1 switches. 3072 # ignore the --nacl_glibc, nacl_pic=1 and bitcode=1 switches.
3073 # We have to reinstantiate the naclsdk.py magic after clearing those flags, 3073 # We have to reinstantiate the naclsdk.py magic after clearing those flags,
3074 # so it regenerates the tool paths right. 3074 # so it regenerates the tool paths right.
3075 # TODO(mcgrathr,bradnelson): could get cleaner if naclsdk.py got folded back in. 3075 # TODO(mcgrathr,bradnelson): could get cleaner if naclsdk.py got folded back in.
3076 nacl_irt_env.ClearBits('nacl_glibc') 3076 nacl_irt_env.ClearBits('nacl_glibc')
3077 nacl_irt_env.ClearBits('nacl_pic') 3077 nacl_irt_env.ClearBits('nacl_pic')
3078 nacl_irt_env.ClearBits('pnacl_shared_newlib') 3078 nacl_irt_env.ClearBits('pnacl_shared_newlib')
3079 # For x86 systems we build the IRT using the nnacl TC even when 3079 # For x86 systems we build the IRT using the nnacl TC even when
3080 # the pnacl TC is used otherwise 3080 # the pnacl TC is used otherwise
3081 if nacl_irt_env.Bit('target_x86_64') or nacl_irt_env.Bit('target_x86_32'): 3081 if nacl_irt_env.Bit('target_x86_64') or nacl_irt_env.Bit('target_x86_32'):
3082 nacl_irt_env.ClearBits('bitcode') 3082 nacl_irt_env.ClearBits('bitcode')
jvoung (off chromium) 2012/12/28 17:21:15 yeah -- also, arm and mips are the only ones that
3083 nacl_irt_env.SetBits('native_code') 3083 nacl_irt_env.SetBits('native_code')
3084 # The irt is not subject to the pexe constraint! 3084 # The irt is not subject to the pexe constraint!
3085 if nacl_irt_env.Bit('pnacl_generate_pexe'): 3085 if nacl_irt_env.Bit('pnacl_generate_pexe'):
3086 # do not build the irt using the the pexe step 3086 # do not build the irt using the the pexe step
3087 nacl_irt_env.ClearBits('pnacl_generate_pexe') 3087 nacl_irt_env.ClearBits('pnacl_generate_pexe')
3088 # do not build the irt using the sandboxed translator 3088 # do not build the irt using the sandboxed translator
3089 nacl_irt_env.ClearBits('use_sandboxed_translator') 3089 nacl_irt_env.ClearBits('use_sandboxed_translator')
3090 nacl_irt_env.Tool('naclsdk') 3090 nacl_irt_env.Tool('naclsdk')
3091 # These are unfortunately clobbered by running Tool, which 3091 # These are unfortunately clobbered by running Tool, which
3092 # we needed to do to get the destination directory reset. 3092 # we needed to do to get the destination directory reset.
(...skipping 22 matching lines...) Expand all
3115 nacl_irt_env.Append(CCFLAGS=['--pnacl-frontend-triple=i686-unknown-nacl']) 3115 nacl_irt_env.Append(CCFLAGS=['--pnacl-frontend-triple=i686-unknown-nacl'])
3116 elif nacl_irt_env.Bit('target_x86_64'): 3116 elif nacl_irt_env.Bit('target_x86_64'):
3117 nacl_irt_env.Append(CCFLAGS=['--pnacl-frontend-triple=x86_64-unknown-nacl']) 3117 nacl_irt_env.Append(CCFLAGS=['--pnacl-frontend-triple=x86_64-unknown-nacl'])
3118 3118
3119 3119
3120 # All IRT code must avoid direct use of the TLS ABI register, which 3120 # All IRT code must avoid direct use of the TLS ABI register, which
3121 # is reserved for user TLS. Instead, ensure all TLS accesses use a 3121 # is reserved for user TLS. Instead, ensure all TLS accesses use a
3122 # call to __nacl_read_tp, which the IRT code overrides to segregate 3122 # call to __nacl_read_tp, which the IRT code overrides to segregate
3123 # IRT-private TLS from user TLS. 3123 # IRT-private TLS from user TLS.
3124 if nacl_irt_env.Bit('bitcode'): 3124 if nacl_irt_env.Bit('bitcode'):
3125 nacl_irt_env.Append(LINKFLAGS=['--pnacl-allow-native', 3125 nacl_irt_env.Append(LINKFLAGS=['--pnacl-allow-native', '-Wt,-mtls-use-call'])
3126 '-Wt,-mtls-use-call', 3126 if nacl_irt_env.Bit('target_arm'):
3127 '-Wl,--pnacl-irt-link']) 3127 nacl_irt_env.Append(LINKFLAGS=['-Wl,--pnacl-irt-link'])
jvoung (off chromium) 2012/12/28 17:21:15 The reason we have --pnacl-irt-link, is that the I
Mark Seaborn 2012/12/28 18:06:39 Fix indentation here, then LGTM. petarj wrote:
3128 elif nacl_irt_env.Bit('target_arm'): 3128 elif nacl_irt_env.Bit('target_arm'):
3129 nacl_irt_env.Append(CCFLAGS=['-mtp=soft']) 3129 nacl_irt_env.Append(CCFLAGS=['-mtp=soft'])
3130 else: 3130 else:
3131 nacl_irt_env.Append(CCFLAGS=['-mtls-use-call']) 3131 nacl_irt_env.Append(CCFLAGS=['-mtls-use-call'])
3132 # A debugger should be able to unwind IRT call frames. As the IRT is compiled 3132 # A debugger should be able to unwind IRT call frames. As the IRT is compiled
3133 # with high level of optimizations and without debug info, compiler is requested 3133 # with high level of optimizations and without debug info, compiler is requested
3134 # to generate unwind tables explicitly. This is the default behavior on x86-64 3134 # to generate unwind tables explicitly. This is the default behavior on x86-64
3135 # and when compiling C++ with exceptions enabled, the change is for the benefit 3135 # and when compiling C++ with exceptions enabled, the change is for the benefit
3136 # of x86-32 C. 3136 # of x86-32 C.
3137 # TODO(eaeltsin): enable unwind tables for ARM 3137 # TODO(eaeltsin): enable unwind tables for ARM
(...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after
3518 nacl_env.ValidateSdk() 3518 nacl_env.ValidateSdk()
3519 3519
3520 if BROKEN_TEST_COUNT > 0: 3520 if BROKEN_TEST_COUNT > 0:
3521 msg = "There are %d broken tests." % BROKEN_TEST_COUNT 3521 msg = "There are %d broken tests." % BROKEN_TEST_COUNT
3522 if GetOption('brief_comstr'): 3522 if GetOption('brief_comstr'):
3523 msg += " Add --verbose to the command line for more information." 3523 msg += " Add --verbose to the command line for more information."
3524 print msg 3524 print msg
3525 3525
3526 # separate warnings from actual build output 3526 # separate warnings from actual build output
3527 Banner('B U I L D - O U T P U T:') 3527 Banner('B U I L D - O U T P U T:')
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698