summaryrefslogtreecommitdiff
path: root/check.py
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2016-01-15 19:47:45 -0800
committerAlon Zakai <alonzakai@gmail.com>2016-01-17 11:57:09 -0800
commit4de7679d71fe4ed87bff14eebf5b1dcc9b0f76ec (patch)
treec84bca7764e4804fbeb81ccacbecd69ecab62520 /check.py
parent19fa7c8e14844f7a25c2ef143cb89464d639c8a9 (diff)
downloadbinaryen-4de7679d71fe4ed87bff14eebf5b1dcc9b0f76ec.tar.gz
binaryen-4de7679d71fe4ed87bff14eebf5b1dcc9b0f76ec.tar.bz2
binaryen-4de7679d71fe4ed87bff14eebf5b1dcc9b0f76ec.zip
run vanilla emcc to make sure it's set up properly, if it was never run before
Diffstat (limited to 'check.py')
-rwxr-xr-xcheck.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/check.py b/check.py
index eb75b4585..f0bd6cf61 100755
--- a/check.py
+++ b/check.py
@@ -362,12 +362,18 @@ print '\n[ checking emcc WASM_BACKEND testcases... ]\n'
os.environ['WASM_BACKEND'] = '1'
try:
+ VANILLA_EMCC = os.path.join('test', 'emscripten', 'emcc')
+ # run emcc to make sure it sets itself up properly, if it was never run before
+ command = [VANILLA_EMCC, '-v']
+ print '____' + ' '.join(command)
+ subprocess.check_call(command)
+
for c in sorted(os.listdir(os.path.join('test', 'wasm_backend'))):
if not c.endswith('cpp'): continue
print '..', c
base = c.replace('.cpp', '').replace('.c', '')
expected = open(os.path.join('test', 'wasm_backend', base + '.txt')).read()
- command = [os.path.join('test', 'emscripten', 'emcc'), '-o', 'a.wasm.js', '-s', 'BINARYEN="' + os.getcwd() + '"', os.path.join('test', 'wasm_backend', c), '-O1', '-s', 'ONLY_MY_CODE=1']
+ command = [VANILLA_EMCC, '-o', 'a.wasm.js', '-s', 'BINARYEN="' + os.getcwd() + '"', os.path.join('test', 'wasm_backend', c), '-O1', '-s', 'ONLY_MY_CODE=1']
print '....' + ' '.join(command)
if os.path.exists('a.wasm.js'): os.unlink('a.wasm.js')
subprocess.check_call(command)