diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-05-01 11:11:19 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-05-01 11:11:19 -0700 |
commit | 94e097a1fd9b3691796356a9df3402710e0c9018 (patch) | |
tree | dca1ca06d64350c4415ab5993e70a7e33fed7f54 | |
parent | 18c03af5f0ee66eb0d75ba3892cd31c72ea6d5c2 (diff) |
require -g with jcache, fixes test_jcache
-rwxr-xr-x | emcc | 7 | ||||
-rwxr-xr-x | tests/runner.py | 2 |
2 files changed, 8 insertions, 1 deletions
@@ -441,6 +441,10 @@ Options that are modified or new in %s include: (also a global property) does not invalidate everything. + Note that you must add -g during the linking + stage (bitcode to JS), for jcache to work + (otherwise, JS minification can confuse it). + --clear-cache Manually clears the cache of compiled emscripten system libraries (libc++, libc++abi, libc). This is normally @@ -1030,6 +1034,9 @@ try: print >> sys.stderr, 'emcc: warning: disabling closure because debug info was requested' closure = False + if jcache: + assert keep_js_debug, 'must run jcache with -g during link stage' # js minification can confuse jcache + if minify_whitespace is None: minify_whitespace = opt_level >= 2 and not keep_js_debug diff --git a/tests/runner.py b/tests/runner.py index 60f19af2..570bfbf2 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -13348,7 +13348,7 @@ fi print >> sys.stderr, args, input_file, expect_pre_save, expect_pre_load, expect_funcs_save, expect_funcs_load, expect_jsfuncs_save, expect_jsfuncs_load, expected - out, err = Popen([PYTHON, EMCC, '-O2', path_from_root('tests', input_file)] + args, stdout=PIPE, stderr=PIPE).communicate() + out, err = Popen([PYTHON, EMCC, '-O2', '-g', path_from_root('tests', input_file)] + args, stdout=PIPE, stderr=PIPE).communicate() errtail = err.split('emcc invocation')[-1] self.assertContained('hello, world!', run_js('a.out.js'), errtail) assert (PRE_SAVE_MSG in err) == expect_pre_save, errtail |