diff options
author | Alon Zakai <alonzakai@gmail.com> | 2011-12-14 17:01:16 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2011-12-14 17:01:16 -0800 |
commit | df41a405914e60d21262b3fb9ab81a5832bb4405 (patch) | |
tree | da6c6aa4f3682cbbb7d0675fd48ac6510dbeeba3 /emar | |
parent | 8e7d56453f584c3be3b1aca0f642a94278afc466 (diff) |
generate .o by default, not .bc. fixes test_zlib
Diffstat (limited to 'emar')
-rwxr-xr-x | emar | 16 |
1 files changed, 12 insertions, 4 deletions
@@ -1,13 +1,21 @@ #!/usr/bin/env python ''' -emcc - ar helper script +emar - ar helper script ======================= This script acts as a frontend replacement for ar. See emcc. ''' -if set(sys.argv[1]).issubset(set('-cruqs')): # ar - sys.argv = sys.argv[:1] + sys.argv[3:] + ['-o='+sys.argv[2]] - assert use_linker, 'Linker should be used in this case' +import os, sys +from tools import shared + +DEBUG = os.environ.get('EMCC_DEBUG') + +newargs = [shared.EMLD] + sys.argv[3:] + ['-o='+sys.argv[2]] + +if DEBUG: + print >> sys.stderr, 'emar:', sys.argv, ' ==> ', newargs + +os.execvp(shared.EMLD, newargs) |