tracks/c/exercises/queen-attack/makefile in trackler-2.2.1.69 vs tracks/c/exercises/queen-attack/makefile in trackler-2.2.1.70
- old
+ new
@@ -1,12 +1,22 @@
CFLAGS = -std=c99
+CFLAGS += -g
CFLAGS += -Wall
CFLAGS += -Wextra
CFLAGS += -pedantic
CFLAGS += -Werror
+VFLAGS = --quiet
+VFLAGS += --tool=memcheck
+VFLAGS += --leak-check=full
+VFLAGS += --error-exitcode=1
+
test: tests.out
@./tests.out
+
+memcheck: tests.out
+ @valgrind $(VFLAGS) ./tests.out
+ @echo "Memory check passed"
clean:
rm -f *.o *.out
tests.out: test/test_queen_attack.c src/queen_attack.c src/queen_attack.h