include config makefile for bootloader

This commit is contained in:
David Holdeman 2024-02-26 21:18:56 -06:00 committed by rusefillc
parent ab9c55225e
commit 8399af96ab
6 changed files with 21 additions and 12 deletions

View File

@ -35,7 +35,7 @@ jobs:
- name: Install required software (macos)
if: ${{ matrix.os == 'macos-latest' }}
run: |
brew install mtools zip dosfstools flock
brew install mtools zip dosfstools flock coreutils
- name: Print bash version
working-directory: .

View File

@ -356,6 +356,11 @@ ULIBS = -lm --specs=nano.specs
##############################################################################
include $(RULESFILE)
ifneq (yes,$(SUBMAKE))
include $(PROJECT_DIR)/rusefi_config.mk
endif
include $(PROJECT_DIR)/rusefi_pch.mk
.PHONY: CLEAN_RULE_HOOK CLEAN_PCH_HOOK

View File

@ -108,8 +108,8 @@ $(SIMULATOR_OUT):
$(BOOTLOADER_HEX) $(BOOTLOADER_BIN): .bootloader-sentinel ;
.bootloader-sentinel:
BOARD_DIR=../$(BOARD_DIR) BOARD_META_PATH=../$(BOARD_META_PATH) $(MAKE) -C bootloader -r
.bootloader-sentinel: $(CONFIG_FILES)
BOARD_DIR=../$(BOARD_DIR) BOARD_META_PATH=../$(BOARD_META_PATH) $(MAKE) -C bootloader -r SUBMAKE=yes
@touch $@
$(BUILDDIR)/$(PROJECT).map: $(BUILDDIR)/$(PROJECT).elf

View File

@ -12,10 +12,6 @@
set -e
cd ../java_tools
flock /tmp/java.lock ./gradlew :config_definition:shadowJar
cd ../firmware
echo "This script reads rusefi_config.txt and produces firmware persistent configuration headers"
echo "the storage section of rusefiXXX.ini is updated as well"
@ -24,17 +20,25 @@ SHORT_BOARD_NAME=${2:-$SHORT_BOARD_NAME}
INI=${3:-"rusefi_$SHORT_BOARD_NAME.ini"}
if [ -z "$BOARD_DIR" ]; then
echo "Board name parameter expected"
echo "Board dir parameter expected"
exit 1
fi
if [ -z "$SHORT_BOARD_NAME" ]; then
echo "ShortBoard name parameter expected"
echo "Short board name parameter expected"
exit 1
fi
echo "BOARD_DIR=${BOARD_DIR} SHORT_BOARD_NAME=${SHORT_BOARD_NAME}"
which realpath >/dev/null 2>&1 || (which grealpath >/dev/null 2>&1 && alias realpath='grealpath')
FDIR=$(realpath $(dirname "$0"))
BOARD_DIR=$(realpath --relative-to "$FDIR" "$BOARD_DIR")
cd "$FDIR/../java_tools"
flock /tmp/java.lock ./gradlew :config_definition:shadowJar
cd ../firmware
bash gen_signature.sh ${SHORT_BOARD_NAME}
PREPEND_FILE=${BOARD_DIR}/prepend.txt

View File

@ -1,4 +1,4 @@
include ../java_tools/java_tools.mk
include $(PROJECT_DIR)/../java_tools/java_tools.mk
INI_FILE = $(META_OUTPUT_ROOT_FOLDER)tunerstudio/generated/rusefi_$(SHORT_BOARD_NAME).ini
SIG_FILE = $(PROJECT_DIR)/tunerstudio/generated/signature_$(SHORT_BOARD_NAME).txt
@ -24,7 +24,7 @@ $(CONFIG_FILES): .config-sentinel ;
.config-sentinel: $(SIG_FILE) .FORCE
ifneq (,$(CUSTOM_GEN_CONFIG))
bash $(PROJECT_DIR)/$(BOARD_DIR)/$(CUSTOM_GEN_CONFIG)
bash $(BOARD_DIR)/$(CUSTOM_GEN_CONFIG)
else
bash $(PROJECT_DIR)/gen_config_board.sh $(BOARD_DIR) $(SHORT_BOARD_NAME)
endif

View File

@ -1,4 +1,4 @@
JAVA_TOOLS = ../java_tools
JAVA_TOOLS = $(PROJECT_DIR)/../java_tools
#
# problem statement: 'make -j4' could easily attempt to run parallel gradle processes. gradle does not seem to like it