aboutsummaryrefslogtreecommitdiff
path: root/tools/nativize_llvm.py
diff options
context:
space:
mode:
authorNick Bray <ncbray@chromium.org>2013-08-05 20:08:12 -0700
committerAlon Zakai <alonzakai@gmail.com>2013-08-08 16:32:32 -0700
commit34229a78e51a3f59818cd1c38c01794d4afe4676 (patch)
treeb83c714f4ce87f6425c3876c529fa7acc6c6e087 /tools/nativize_llvm.py
parent30a929e104a5874620a8b048e9e5fd935006fb5b (diff)
Allow the PNaCl toolchain to be used in place of a standard version of Clang.
The main differences between PNaCl and standard Clang are that the tools are prefixed with "pnacl-" instead of "llvm-" and PNaCl does not accept "-o=file" style arguments, and requires them to be specified as "-o file".
Diffstat (limited to 'tools/nativize_llvm.py')
-rwxr-xr-xtools/nativize_llvm.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/nativize_llvm.py b/tools/nativize_llvm.py
index d9558c32..413c8d14 100755
--- a/tools/nativize_llvm.py
+++ b/tools/nativize_llvm.py
@@ -21,11 +21,11 @@ filename = sys.argv[1]
libs = sys.argv[2:] # e.g.: dl for dlopen/dlclose, util for openpty/forkpty
print 'bc => clean bc'
-Popen([LLVM_OPT, filename, '-strip-debug', '-o=' + filename + '.clean.bc']).communicate()[0]
+Popen([LLVM_OPT, filename, '-strip-debug', '-o', filename + '.clean.bc']).communicate()[0]
print 'bc => s'
for params in [[], ['-march=x86-64']]: # try x86, then x86-64 FIXME
print 'params', params
- Popen([LLVM_COMPILER] + params + [filename + '.clean.bc', '-o=' + filename + '.s']).communicate()[0]
+ Popen([LLVM_COMPILER] + params + [filename + '.clean.bc', '-o', filename + '.s']).communicate()[0]
print 's => o'
Popen(['as', filename + '.s', '-o', filename + '.o']).communicate()[0]
if os.path.exists(filename + '.o'): break