From 0f88f6ff92e5913064252af3336d959edacba7ed Mon Sep 17 00:00:00 2001 From: Yu-Ping Wu Date: Tue, 20 Jul 2021 14:32:40 +0800 Subject: tests/Makefile.inc: Correct dependency file suffix The dependency file, generated by $(HOSTCC) ... -MMD -MT $@ -c $< -o $@.orig is determined by replacing the suffix of "$@.orig" with ".d", resulting in "$@.d" (which is *.o.d). The file name was accidentally changed in CB:55360. Now explicitly specify the path by the "-MF" option. BUG=none TEST=make unit-tests; find build/tests/ -name "*.d" BRANCH=none Change-Id: I01f77ebaaae78dd9e69394a49e524f1013857195 Signed-off-by: Yu-Ping Wu Reviewed-on: https://review.coreboot.org/c/coreboot/+/56444 Tested-by: build bot (Jenkins) Reviewed-by: Jakub Czapiga --- tests/Makefile.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/Makefile.inc b/tests/Makefile.inc index b4b8cda5ee..056ad7df85 100644 --- a/tests/Makefile.inc +++ b/tests/Makefile.inc @@ -118,8 +118,8 @@ $($(1)-objs): TEST_CFLAGS += -I$$(dir $$($(1)-config-file)) \ $($(1)-srcobjs): OBJCOPY_FLAGS += $$(foreach mock,$$($(1)-mocks),--globalize-symbol=$$(mock) --weaken-symbol=$$(mock)) $($(1)-objs): $(testobj)/$(1)/%.o: $$$$*.c $$($(1)-config-file) mkdir -p $$(dir $$@) - $(HOSTCC) $(HOSTCFLAGS) $$(TEST_CFLAGS) $($(1)-cflags) -MMD \ - -MT $$@ -c $$< -o $$@.orig + $(HOSTCC) $(HOSTCFLAGS) $$(TEST_CFLAGS) $($(1)-cflags) -MMD \ + -MF $$(basename $$@).d -MT $$@ -c $$< -o $$@.orig $(OBJCOPY) $$@.orig $$(OBJCOPY_FLAGS) $$@ $($(1)-bin): $($(1)-objs) $(CMOCKA_LIB) -- cgit v1.2.3