From 1270d5d34d71c97fe3e5be7dd6e6514448e20588 Mon Sep 17 00:00:00 2001 From: David Holdeman Date: Wed, 28 Feb 2024 21:46:19 -0600 Subject: [PATCH] use sentinel file with short board name to trigger rebuilds on target changes --- firmware/rusefi_config.mk | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/firmware/rusefi_config.mk b/firmware/rusefi_config.mk index 99eda46846..95ac1c377c 100644 --- a/firmware/rusefi_config.mk +++ b/firmware/rusefi_config.mk @@ -37,15 +37,19 @@ $(TCPPOBJS): $(RAMDISK) $(SIG_FILE): .FORCE bash $(PROJECT_DIR)/gen_signature.sh $(SHORT_BOARD_NAME) +.target-sentinel: .FORCE + if [ "$$(cat $@ 2>/dev/null)" != $(SHORT_BOARD_NAME) ]; then \ + echo $(SHORT_BOARD_NAME) >$@; fi + $(RAMDISK): .ramdisk-sentinel ; -.ramdisk-sentinel: $(INI_FILE) +.ramdisk-sentinel: $(INI_FILE) .target-sentinel bash $(PROJECT_DIR)/bin/gen_image_board.sh $(BOARD_DIR) $(SHORT_BOARD_NAME) @touch $@ $(CONFIG_FILES): .config-sentinel ; -.config-sentinel: $(CONFIG_INPUTS) $(CONFIG_DEFINITION) +.config-sentinel: $(CONFIG_INPUTS) $(CONFIG_DEFINITION) .target-sentinel ifneq (,$(CUSTOM_GEN_CONFIG)) bash $(BOARD_DIR)/$(CUSTOM_GEN_CONFIG) else