aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Zakai <azakai@mozilla.com>2011-03-12 13:37:42 -0800
committerAlon Zakai <azakai@mozilla.com>2011-03-12 13:37:42 -0800
commit443107fc61b83caa49fbfc57a6b2b5adf09581e2 (patch)
treec50952b177c433ef4c18b678f629e88ad4bd67d1
parentc06b543a3ed8a7f05a320d7ec9f43e9175457ef8 (diff)
use proper constant in emscripten.py
-rwxr-xr-xemscripten.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/emscripten.py b/emscripten.py
index 8b4d5e60..d61d84ab 100755
--- a/emscripten.py
+++ b/emscripten.py
@@ -2,7 +2,7 @@
import os, sys, subprocess
-JS_ENGINE = None
+COMPILER_ENGINE = None
abspath = os.path.abspath(os.path.dirname(__file__))
def path_from_root(*pathelems):
@@ -18,7 +18,7 @@ def emscripten(filename, settings):
except:
cwd = None
os.chdir(os.path.dirname(COMPILER))
- subprocess.Popen(JS_ENGINE + [COMPILER], stdin=subprocess.PIPE).communicate(settings+'\n'+data)[0]
+ subprocess.Popen(COMPILER_ENGINE + [COMPILER], stdin=subprocess.PIPE).communicate(settings+'\n'+data)[0]
if cwd is not None:
os.chdir(cwd)
@@ -33,11 +33,11 @@ Emscripten usage: emscripten.py INFILE [PATH-TO-JS-ENGINE] [SETTINGS]
run the compiler (which is in JavaScript itself). You can later use
the same engine to run the code, or another one, that is a separate
issue. If you do not provide this parameter, you should define
- JS_ENGINE = ... in a file at ~/.emscripten.
+ COMPILER_ENGINE = ... in a file at ~/.emscripten.
SETTINGS is an optional set of compiler settings, overriding the defaults.
'''
else:
if len(sys.argv) >= 3:
- JS_ENGINE = [sys.argv[2]]
+ COMPILER_ENGINE = [sys.argv[2]]
emscripten(sys.argv[1], sys.argv[3] if len(sys.argv) == 4 else "{}")