From bf7de7d48d6b8cddd89fc376d3c505bcf265631a Mon Sep 17 00:00:00 2001 From: Robert Hargreaves Date: Mon, 9 Sep 2024 00:20:18 +0100 Subject: [PATCH] Simplify Makefile --- tests/Makefile | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/tests/Makefile b/tests/Makefile index 1f46df7..8666ecb 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -237,24 +237,17 @@ system: $(SYSTEM_TESTS_TARGET) $(GDB) ./$(SYSTEM_TESTS_TARGET) .PHONY: system -$(OBJ_DIR): - mkdir -p $(dir $@) - -$(OBJ_DIR)/%.o: %.c - mkdir -p $(dir $@) - $(CC) $(CFLAGS) -MMD -c $< -o $@ - $(OBJ_DIR)/%.o: %.c mkdir -p $(dir $@) $(CC) $(CFLAGS) -MMD -c $< -o $@ $(UNIT_TESTS_TARGET): $(SRC_OBJ) $(UNIT_TEST_OBJ) $(COMMON_TEST_OBJ) mkdir -p $(dir $@) - $(CC) -MMD -o $@ $^ $(UNIT_TEST_LDFLAGS) + $(CC) -o $@ $^ $(UNIT_TEST_LDFLAGS) $(SYSTEM_TESTS_TARGET): $(SRC_OBJ) $(SYSTEM_TEST_OBJ) $(COMMON_TEST_OBJ) mkdir -p $(dir $@) - $(CC) -MMD -o $@ $^ $(SYSTEM_TEST_LDFLAGS) + $(CC) -o $@ $^ $(SYSTEM_TEST_LDFLAGS) $(CMOCKA_DIR): mkdir -p $@