| OLD | NEW |
| 1 #!/usr/bin/python2.4 | 1 #!/usr/bin/python2.4 |
| 2 # Copyright 2009, Google Inc. | 2 # Copyright 2009, Google Inc. |
| 3 # All rights reserved. | 3 # All rights reserved. |
| 4 # | 4 # |
| 5 # Redistribution and use in source and binary forms, with or without | 5 # Redistribution and use in source and binary forms, with or without |
| 6 # modification, are permitted provided that the following conditions are | 6 # modification, are permitted provided that the following conditions are |
| 7 # met: | 7 # met: |
| 8 # | 8 # |
| 9 # * Redistributions of source code must retain the above copyright | 9 # * Redistributions of source code must retain the above copyright |
| 10 # notice, this list of conditions and the following disclaimer. | 10 # notice, this list of conditions and the following disclaimer. |
| (...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 172 CC=os.path.join(bin_path, '%s-gcc%s' % (arch, cc_mode_flag)), | 172 CC=os.path.join(bin_path, '%s-gcc%s' % (arch, cc_mode_flag)), |
| 173 CXX=os.path.join(bin_path, '%s-g++%s' % (arch, cc_mode_flag)), | 173 CXX=os.path.join(bin_path, '%s-g++%s' % (arch, cc_mode_flag)), |
| 174 AR=os.path.join(bin_path, '%s-ar' % arch), | 174 AR=os.path.join(bin_path, '%s-ar' % arch), |
| 175 AS=os.path.join(bin_path, '%s-as%s' % (arch, as_mode_flag)), | 175 AS=os.path.join(bin_path, '%s-as%s' % (arch, as_mode_flag)), |
| 176 GDB=os.path.join(bin_path, 'nacl-gdb'), | 176 GDB=os.path.join(bin_path, 'nacl-gdb'), |
| 177 # NOTE: use g++ for linking so we can handle C AND C++. | 177 # NOTE: use g++ for linking so we can handle C AND C++. |
| 178 LINK=os.path.join(bin_path, '%s-g++%s' % (arch, cc_mode_flag)), | 178 LINK=os.path.join(bin_path, '%s-g++%s' % (arch, cc_mode_flag)), |
| 179 # Grrr... and sometimes we really need ld. | 179 # Grrr... and sometimes we really need ld. |
| 180 LD=os.path.join(bin_path, '%s-ld%s' % (arch, ld_mode_flag)), | 180 LD=os.path.join(bin_path, '%s-ld%s' % (arch, ld_mode_flag)), |
| 181 RANLIB=os.path.join(bin_path, '%s-ranlib' % arch), | 181 RANLIB=os.path.join(bin_path, '%s-ranlib' % arch), |
| 182 OBJDUMP=os.path.join(bin_path, '%s-objdump' % arch), |
| 182 CFLAGS = ['-std=gnu99'], | 183 CFLAGS = ['-std=gnu99'], |
| 183 CCFLAGS=['-O3', | 184 CCFLAGS=['-O3', |
| 184 '-Werror', | 185 '-Werror', |
| 185 '-Wall', | 186 '-Wall', |
| 186 '-Wswitch-enum', | 187 '-Wswitch-enum', |
| 187 '-g', | 188 '-g', |
| 188 '-fno-builtin', | 189 '-fno-builtin', |
| 189 '-fno-stack-protector', | 190 '-fno-stack-protector', |
| 190 '-fdiagnostics-show-option', | 191 '-fdiagnostics-show-option', |
| 191 '-pedantic', | 192 '-pedantic', |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 372 # if bitcode=1 use pnacl toolchain | 373 # if bitcode=1 use pnacl toolchain |
| 373 if env.Bit('bitcode'): | 374 if env.Bit('bitcode'): |
| 374 _SetEnvForPnacl(env, root) | 375 _SetEnvForPnacl(env, root) |
| 375 elif env.Bit('target_x86'): | 376 elif env.Bit('target_x86'): |
| 376 _SetEnvForX86Sdk(env, root) | 377 _SetEnvForX86Sdk(env, root) |
| 377 else: | 378 else: |
| 378 print "ERROR: unknown TARGET_ARCHITECTURE: ", env['TARGET_ARCHITECTURE'] | 379 print "ERROR: unknown TARGET_ARCHITECTURE: ", env['TARGET_ARCHITECTURE'] |
| 379 assert 0 | 380 assert 0 |
| 380 | 381 |
| 381 env.Prepend(LIBPATH='${NACL_SDK_LIB}') | 382 env.Prepend(LIBPATH='${NACL_SDK_LIB}') |
| OLD | NEW |