diff --git a/make_helpers/build_macros.mk b/make_helpers/build_macros.mk index 24d5924..2312d2c 100644 --- a/make_helpers/build_macros.mk +++ b/make_helpers/build_macros.mk @@ -300,9 +300,8 @@ # ordering is not relevant but sort removes duplicates. $(eval TEMP_OBJ_DIRS := $(sort $(BUILD_DIR)/ $(dir ${OBJS} ${LINKERFILE}))) # The $(dir ) function leaves a trailing / on the directory names - # We append a . then strip /. from each, to remove the trailing / characters - # This gives names suitable for use as make rule targets. - $(eval OBJ_DIRS := $(subst /.,,$(addsuffix .,$(TEMP_OBJ_DIRS)))) + # Rip off the / to match directory names with make rule targets. + $(eval OBJ_DIRS := $(patsubst %/,%,$(TEMP_OBJ_DIRS))) # Create generators for object directory structure