# Pull in limit macros from stdint.h, even in C++:
CPPFLAGS += -D__STDC_LIMIT_MACROS
-CompileWarnings := -Wall -W -Wwrite-strings -Wno-unused
-CompileCommonOpts := $(CompileWarnings) -fshort-enums
+CompileCommonOpts := -Wall -W -Wwrite-strings -Wno-unused
CompileOptimizeOpts := -O3 -DNDEBUG -finline-functions
#
#---------------------------------------------------------
ifdef DIRS
-all install clean test bytecode ::
+all install clean test bytecode stripped-bytecode::
$(VERB) for dir in ${DIRS}; do \
if [ ! -f $$dir/Makefile ]; \
then \
clean :: $(addsuffix /.makeclean , $(PARALLEL_DIRS))
test :: $(addsuffix /.maketest , $(PARALLEL_DIRS))
bytecode :: $(addsuffix /.makebytecode, $(PARALLEL_DIRS))
+stripped-bytecode :: $(addsuffix /.makestripped-bytecode, $(PARALLEL_DIRS))
-%/.makeall %/.makeinstall %/.makeclean %/.maketest %/.makebytecode:
+%/.makeall %/.makeinstall %/.makeclean %/.maketest %/.makebytecode %/.makestripped-bytecode:
$(VERB) if [ ! -f $(@D)/Makefile ]; \
then \
$(MKDIR) $(@D); \
# Handle directories that may or may not exist
ifdef OPTIONAL_DIRS
-all install clean test bytecode ::
+all install clean test bytecode stripped-bytecode::
$(VERB) for dir in ${OPTIONAL_DIRS}; do \
if [ -d $(SourceDir)/$$dir ]; \
then\
$(BUILD_OBJ_DIR)/BytecodeObj/%.bc: %.cpp $(BUILD_OBJ_DIR)/BytecodeObj/.dir $(LCC1XX)
@${ECHO} "Compiling `basename $<` to bytecode"
- $(VERB) $(LLVMGXX) $(CompileWarnings) $(CPPFLAGS) -c $< -o $@
+ $(VERB) $(LLVMGXX) $(CompileCommonOpts) $(CPPFLAGS) -c $< -o $@
$(BUILD_OBJ_DIR)/BytecodeObj/%.bc: %.c $(BUILD_OBJ_DIR)/BytecodeObj/.dir $(LCC1)
@${ECHO} "Compiling `basename $<` to bytecode"
- $(VERB) $(LLVMGCC) $(CompileWarnings) $(CPPFLAGS) -c $< -o $@
+ $(VERB) $(LLVMGCC) $(CompileCommonOpts) $(CPPFLAGS) -c $< -o $@
$(BUILD_OBJ_DIR)/BytecodeObj/%.bc: %.ll $(BUILD_OBJ_DIR)/BytecodeObj/.dir $(LLVMAS)
@${ECHO} "Compiling `basename $<` to bytecode"