Parse C++ bool, false and true.
[cparser] / Makefile
index 017f797..f7f50ca 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -29,20 +29,20 @@ SOURCES := \
        adt/obstack_printf.c \
        adt/xmalloc.c \
        ast.c \
-       ast2firm.c \
-       config.h \
        diagnostic.c \
        entitymap.c \
        format_check.c \
        lexer.c \
        main.c \
-       parser.c \
+       walk_statements.c \
        symbol_table.c \
        token.c \
        type.c \
        types.c \
        type_hash.c \
        warning.c \
+       parser.c \
+       ast2firm.c \
        write_fluffy.c \
        write_caml.c \
        driver/firm_cmdline.c \
@@ -50,6 +50,7 @@ SOURCES := \
        driver/firm_codegen.c \
        driver/firm_opt.c \
        driver/gen_firm_asm.c \
+       preprocessor.c
 
 OBJECTS = $(SOURCES:%.c=build/%.o)
 
@@ -75,8 +76,10 @@ config.h:
 %.h:
        @true
 
-.depend: $(SOURCES)
-       @echo "#define cparser_REVISION \"`svnversion -n .`\"" > .revision.h
+REVISION ?= $(shell svnversion -n .)
+
+.depend: config.h $(SOURCES)
+       @echo "#define cparser_REVISION \"$(REVISION)\"" > .revision.h
        $(Q)if diff -Nq .revision.h revision.h > /dev/null; then \
              rm .revision.h;                                    \
            else                                                 \
@@ -89,7 +92,7 @@ config.h:
 DIRS = build build/adt build/driver build/cpb build/cpb/adt build/cpb/driver build/cpb2 build/cpb2/adt build/cpb2/driver build/cpbe build/cpbe/adt build/cpbe/driver
 UNUSED := $(shell mkdir -p $(DIRS))
 
-$(GOAL): $(OBJECTS)
+$(GOAL): $(OBJECTS) $(LIBFIRM_FILE)
        @echo "===> LD $@"
        $(Q)$(CC) $(OBJECTS) $(LFLAGS) -o $(GOAL)
 
@@ -115,7 +118,7 @@ $(DIRS):
        @echo "===> MKDIR $@"
        $(Q)mkdir -p $@
 
-builtins.h: builtins/builtins.c
+builtins.h: builtins/builtins.c create_builtins_h.sh
        @echo '===> CREATE_BUILTINS $<'
        $(Q)./create_builtins_h.sh > $@
 
@@ -147,8 +150,8 @@ cparser.bootstrap2: $(CPARSEROS2)
 
 build/%.o: %.c
        @echo '===> CC $<'
-       $(Q)$(ICC) $(CPPFLAGS) $(ICC_CFLAGS) -c $< -o $@
-       $(Q)$(GCCO1) $(CPPFLAGS) $(CFLAGS) -O1 -c $< -o $@
+#$(Q)$(ICC) $(CPPFLAGS) $(ICC_CFLAGS) -c $< -o $@
+#$(Q)$(GCCO1) $(CPPFLAGS) $(CFLAGS) -O1 -c $< -o $@
        $(Q)$(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $@
 
 clean: