diff --git a/Docker/Dockerfile b/Docker/Dockerfile index 3720c77..e1e71dd 100644 --- a/Docker/Dockerfile +++ b/Docker/Dockerfile @@ -2,7 +2,7 @@ FROM eclipse-temurin:11-jdk-jammy AS builder RUN set -ex && \ apt-get update && \ - apt-get install -y git python3 pip make && \ + apt-get install -y git python3 pip make python3-venv && \ pip install --upgrade platformio && \ pip install --upgrade esptool diff --git a/Docker/build_with_docker_pio.sh b/Docker/build_with_docker_pio.sh index bdad679..ba4673f 100755 --- a/Docker/build_with_docker_pio.sh +++ b/Docker/build_with_docker_pio.sh @@ -1,4 +1,4 @@ set -ex IMAGE_NAME=nuki_hub_build docker build -f ./Dockerfile -t ${IMAGE_NAME} .. -docker run --rm -it -v $PWD/..:/src -w /src ${IMAGE_NAME} make release +docker run --rm -it -v $PWD/..:/src -w /src ${IMAGE_NAME} /bin/bash -c "make deps && make updater && make release" diff --git a/Docker/build_with_docker_pio_debug.sh b/Docker/build_with_docker_pio_debug.sh index 5b33ae4..18ab19e 100755 --- a/Docker/build_with_docker_pio_debug.sh +++ b/Docker/build_with_docker_pio_debug.sh @@ -1,4 +1,4 @@ set -ex IMAGE_NAME=nuki_hub_build docker build -f ./Dockerfile -t ${IMAGE_NAME} .. -docker run --rm -it -v $PWD/..:/src -w /src ${IMAGE_NAME} make debug +docker run --rm -it -v $PWD/..:/src -w /src ${IMAGE_NAME} /bin/bash -c "make deps && make updater && make debug" \ No newline at end of file diff --git a/Makefile b/Makefile index 4ac1b21..6b3070f 100644 --- a/Makefile +++ b/Makefile @@ -2,6 +2,7 @@ PLATFORMIO_INI := platformio.ini BOARDS := $(shell grep -oP '(?<=\[env:)[^\]]+' $(PLATFORMIO_INI) | grep -v '_dbg') DEBUG_BOARDS := $(shell grep -oP '(?<=\[env:)[^\]]+' $(PLATFORMIO_INI) | grep '_dbg') +UPDATER_BOARDS := $(shell grep -oP '(?<=\[env:)[^\]]+' $(PLATFORMIO_INI) | grep -v '_dbg' | sed 's/^/updater_/') # Default target .PHONY: default @@ -11,7 +12,7 @@ default: esp32 release: $(BOARDS) .PHONY: updater -release: updater_$(BOARDS) +updater: $(UPDATER_BOARDS) .PHONY: debug debug: $(DEBUG_BOARDS) @@ -40,6 +41,7 @@ help: @echo " make deps - Install software dependencies (PlatformIO)" @echo " make all - Build all boards in both release and debug modes" @$(foreach board,$(BOARDS),echo " make $(board) - Build $(board) in release mode";) + @$(foreach board,$(UPDATER_BOARDS),echo " make $(board) - Build updater for $(board) in release mode";) @$(foreach board,$(DEBUG_BOARDS),echo " make $(board) - Build $(board) in debug mode";) @echo "Available boards:" @echo " $(BOARDS)"