diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-11-17 11:26:58 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-11-21 20:47:01 +0100 |
commit | f199880bb1474e8b2e3a3e4a3e5bf215c8a2b694 (patch) | |
tree | 95e04687526857908d9f56813891efd4d8a78481 /emscripten.py | |
parent | b074f4241b87a097bf25e09cda7766b55a88a81b (diff) |
set up parameter passing for jcache
Diffstat (limited to 'emscripten.py')
-rwxr-xr-x | emscripten.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/emscripten.py b/emscripten.py index 1f6ae2fc..d33c16e7 100755 --- a/emscripten.py +++ b/emscripten.py @@ -32,6 +32,7 @@ def path_from_root(*pathelems): temp_files = shared.TempFiles() compiler_engine = None +jcache = False def scan(ll, settings): # blockaddress(@main, %23) @@ -335,6 +336,10 @@ if __name__ == '__main__': metavar='FOO=BAR', help=('Overrides for settings defined in settings.js. ' 'May occur multiple times.')) + parser.add_option('-j', '--jcache', + action='store_true', + default=False, + help=('Enable jcache (ccache-like caching of compilation results, for faster incremental builds).')) # Convert to the same format that argparse would have produced. keywords, positional = parser.parse_args() @@ -344,6 +349,7 @@ if __name__ == '__main__': if isinstance(keywords.outfile, basestring): keywords.outfile = open(keywords.outfile, 'w') compiler_engine = keywords.compiler + jcache = keywords.jcache temp_files.run_and_clean(lambda: main(keywords)) |