diff options
Diffstat (limited to 'tests/makefile')
| -rw-r--r-- | tests/makefile | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/makefile b/tests/makefile index e69de29..2300a19 100644 --- a/tests/makefile +++ b/tests/makefile | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | include config.mk | ||
| 2 | |||
| 3 | TEST_RUNNER=$(BUILD_DIR)/tester | ||
| 4 | OBJS=$(BUILD_DIR)/csv-test.o | ||
| 5 | |||
| 6 | $(TEST_RUNNER): $(OBJS) | libcsv | ||
| 7 | cc -o $@ $(LDFLAGS) $(OBJS) | ||
| 8 | |||
| 9 | $(BUILD_DIR)/%.o: src/%.c | $(BUILD_DIR) | ||
| 10 | cc $(CFLAGS) -c $< -o $@ | ||
| 11 | |||
| 12 | $(BUILD_DIR): | ||
| 13 | mkdir -p $@ | ||
| 14 | |||
| 15 | .PHONY: libcsv | ||
| 16 | libcsv: | ||
| 17 | $(MAKE) -C ../lib | ||
| 18 | |||
| 19 | compile_flags.txt: | ||
| 20 | echo "$(CFLAGS)" | tr ' ' '\n' > $@ | ||
| 21 | |||
| 22 | .PHONY: clean | ||
| 23 | clean: | ||
| 24 | rm -f $(TEST_RUNNER) $(OBJS) | ||
