endif
ifneq ($(shell git describe --always 2>/dev/null),)
- CFLAGS += -DGMQCC_GITINFO="\"$(shell git describe --always)\""
+ CFLAGS += -DGMQCC_GITINFO="\"$(shell git describe --always)\""
+endif
+
+ifeq ($(shell valgrind --version 2>/dev/null),)
+ CFLAGS += -DNVALGRIND
endif
# do this last otherwise there is whitespace in the command output and
GMQCC = gmqcc.exe
TESTSUITE = testsuite.exe
PAK = gmqpak.exe
+ CFLAGS += -DNVALGRIND
else
ifneq ("$(MINGW)", "")
#nullify the common variables that
GMQCC = gmqcc.exe
TESTSUITE = testsuite.exe
PAK = gmqpak.exe
+ CFLAGS += -DNVALGRIND
else
QCVM = qcvm
GMQCC = gmqcc
endif
#standard rules
-%.o: %.c
- $(CC) -c $< -o $@ $(CFLAGS) $(CPPFLAGS)
+c.o:
+ $(CC) -c $< -o $@ $(CFLAGS) $(CPPFLAGS)
exec-standalone.o: exec.c
$(CC) -c $< -o $@ $(CFLAGS) $(CPPFLAGS) -DQCVM_EXECUTOR=1
utf8.o: gmqcc.h opts.def
correct.o: gmqcc.h opts.def
fold.o: ast.h ir.h gmqcc.h opts.def parser.h lexer.h
+intrin.o: parser.h gmqcc.h opts.def lexer.h ast.h ir.h