diff --git a/dist/tools/insufficient_memory/Makefile.for_sh b/dist/tools/insufficient_memory/Makefile.for_sh index 3c1ed8071daa..6b2e1a920bb5 100644 --- a/dist/tools/insufficient_memory/Makefile.for_sh +++ b/dist/tools/insufficient_memory/Makefile.for_sh @@ -6,7 +6,8 @@ define create_Makefile.ci @echo " #" >> $(1) endef -BOARD_INSUFFICIENT_MEMORY += $(BOARD) +BOARD_INSUFFICIENT_MEMORY += $(ADD_BOARDS) +BOARD_INSUFFICIENT_MEMORY := $(filter-out $(REMOVE_BOARDS),$(BOARD_INSUFFICIENT_MEMORY)) .PHONY: Makefile.ci ifeq ($(BOARD_INSUFFICIENT_MEMORY),) diff --git a/dist/tools/insufficient_memory/create_makefile.ci.sh b/dist/tools/insufficient_memory/create_makefile.ci.sh index 4f58861338c5..54bf3b204009 100755 --- a/dist/tools/insufficient_memory/create_makefile.ci.sh +++ b/dist/tools/insufficient_memory/create_makefile.ci.sh @@ -80,4 +80,4 @@ for BOARD in $(EXTERNAL_BOARD_DIRS="" make --no-print-directory info-boards-sup done rm "${APP_DIR}/Makefile.ci" -make -f "$(dirname "$0")"/Makefile.for_sh DIR="${APP_DIR}" BOARD="${BOARDS}" Makefile.ci > /dev/null +make -f "$(dirname "$0")"/Makefile.for_sh DIR="${APP_DIR}" ADD_BOARDS="${BOARDS}" Makefile.ci > /dev/null diff --git a/dist/tools/insufficient_memory/add_insufficient_memory_board.sh b/dist/tools/insufficient_memory/update_insufficient_memory_board.sh similarity index 87% rename from dist/tools/insufficient_memory/add_insufficient_memory_board.sh rename to dist/tools/insufficient_memory/update_insufficient_memory_board.sh index f18e5c5a3912..66f8644bd2a7 100755 --- a/dist/tools/insufficient_memory/add_insufficient_memory_board.sh +++ b/dist/tools/insufficient_memory/update_insufficient_memory_board.sh @@ -53,6 +53,10 @@ APPLICATIONS="${APPLICATIONS} $(make -sC "${RIOTBASE}" info-applications)" for application in ${APPLICATIONS}; do printf "${CNORMAL}%-40s${CRESET}" "${application}" + + # First, remove the board from Makefile.ci; otherwise linking step will be + # skipped with RIOT_CI_BUILD=1 when the board is already in the list. + make -f "$(dirname "$0")"/Makefile.for_sh DIR="${RIOTBASE}/${application}" REMOVE_BOARDS="${BOARD}" Makefile.ci > /dev/null # disable warning about globbing and word splitting for ${LOCAL_MAKE_ARGS} # as this is exactly what we want here # shellcheck disable=SC2086 @@ -62,7 +66,7 @@ for application in ${APPLICATIONS}; do -e "wraps around address space" \ "$TMPFILE" > /dev/null; then printf "${CBIG}%s${CRESET}\n" "too big" - make -f "$(dirname "$0")"/Makefile.for_sh DIR="${RIOTBASE}/${application}" BOARD="${BOARD}" Makefile.ci > /dev/null + make -f "$(dirname "$0")"/Makefile.for_sh DIR="${RIOTBASE}/${application}" ADD_BOARDS="${BOARD}" Makefile.ci > /dev/null elif grep -e "not whitelisted" \ -e "unsatisfied feature requirements" \ -e "Some feature requirements are blacklisted:" \