aboutsummaryrefslogtreecommitdiff
path: root/emcc
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2013-06-24 16:00:24 -0700
committerAlon Zakai <alonzakai@gmail.com>2013-07-03 15:31:02 -0700
commitfac77c3ff04c2f228389fd3697239db263f62ab6 (patch)
treebd3529623087330da0ac84914c8601c8cd034198 /emcc
parentfc397a94391958b13c06762957961f73447dabc9 (diff)
initial setup
Diffstat (limited to 'emcc')
-rwxr-xr-xemcc10
1 files changed, 10 insertions, 0 deletions
diff --git a/emcc b/emcc
index 75750e1e..c6b0893b 100755
--- a/emcc
+++ b/emcc
@@ -1066,6 +1066,16 @@ try:
logging.warning('disabling LLVM optimizations, need typed arrays mode 2 for them')
llvm_opts = 0
+ if shared.Settings.MAIN_MODULE:
+ assert not shared.Settings.SIDE_MODULE
+ shared.Settings.INCLUDE_FULL_LIBRARY = 1
+ shared.Settings.LINKABLE = 1 # TODO: add FORCE_DCE option for the brave people that do want to dce here and in side modules
+ debug_level = max(debug_level, 2) # preserve function names
+ elif shared.Settings.SIDE_MODULE:
+ assert not shared.Settings.MAIN_MODULE
+ shared.Settings.LINKABLE = 1
+ debug_level = max(debug_level, 2)
+
## Compile source code to bitcode
logging.debug('compiling to bitcode')