diff --git a/Makefile b/Makefile index 6d681ba63..933888647 100644 --- a/Makefile +++ b/Makefile @@ -135,7 +135,7 @@ $(TEST_OBJ): tests/%.o: tests/%.c $(patsubst %.exe,%_main.o,$(TEST_EXE)): tests/%_main.o: $(HDRS) $(patsubst %.exe,%_main.o,$(TEST_EXE)): tests/%_main.o: $(T_MAIN_C) $(patsubst %.exe,%_main.o,$(TEST_EXE)): tests/%_main.o: tests/%.toc - $(CC) -Isrc -I. '-DTEST_TOC="$<"' \ + $(CC) $(CFLAGS) -Isrc -I. '-DTEST_TOC="$<"' \ -c $(T_MAIN_C) \ -o $@ diff --git a/tests/test_main.c b/tests/test_main.c index 0be51ee21..43bb43402 100644 --- a/tests/test_main.c +++ b/tests/test_main.c @@ -24,6 +24,7 @@ */ #include "test_lib.h" +#include #undef BEGIN_TEST #define BEGIN_TEST(name) extern void testfunc__##name(void);