]> de.git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - Makefile
added --nocolor and fixed bug
[xonotic/gmqcc.git] / Makefile
index 75d4921ea0c2067ed9260b06d50ff7de7c69c417..b2d65805d0a3ca7c0b67877b8fca386d90fc3f9d 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,5 @@
 CC     ?= clang
-CFLAGS += -Wall -I. -pedantic-errors -std=c90
-
+CFLAGS += -Wall -I. -fomit-frame-pointer -fno-stack-protector
 #turn on tons of warnings if clang is present
 ifeq ($(CC), clang)
        CFLAGS +=                  \
@@ -16,19 +15,20 @@ ifeq ($(CC), clang)
                -Wno-format-nonliteral
 
 endif
-OBJ     = lex.o       \
-          error.o     \
-          parse.o     \
-          typedef.o   \
+ifeq ($(track), no)
+    CFLAGS += -DNOTRACK
+endif
+
+OBJ     = \
           util.o      \
           code.o      \
-          asm.o       \
           ast.o       \
-          ir.o 
+          ir.o        \
+          con.o
 OBJ_A = test/ast-test.o
 OBJ_I = test/ir-test.o
-OBJ_C = main.o
-OBJ_X = exec-standalone.o util.o
+OBJ_C = main.o lexer.o parser.o
+OBJ_X = exec-standalone.o util.o con.o
 
 #default is compiler only
 default: gmqcc
@@ -44,9 +44,7 @@ test_ast: $(OBJ_A) $(OBJ)
 test_ir:  $(OBJ_I) $(OBJ)
        $(CC) -o $@ $^ $(CFLAGS)
 qcvm:     $(OBJ_X)
-       $(CC) -o $@ $^ $(CFLAGS)
-exec.o: execloop.h
-exec-standalone.o: execloop.h
+       $(CC) -o $@ $^ $(CFLAGS) -lm
 test: test_ast test_ir
 
 # compiler target