mirror of
https://github.com/apache/nuttx.git
synced 2026-08-19 04:28:21 +00:00
espressif: Add variable to override MCUboot version and URL
The version and the git repository of Espressif's MCUboot port can be changed by setting the `MCUBOOT_VERSION` and `MCUBOOT_URL` environment variables before running the `make bootloader` command. Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
This commit is contained in:
parent
6eba7ad35b
commit
c22df41ca6
4 changed files with 32 additions and 8 deletions
|
|
@ -35,8 +35,14 @@ BOOTLOADER_CONFIG = $(BOOTLOADER_SRCDIR)/bootloader.conf
|
|||
|
||||
MCUBOOT_SRCDIR = $(BOOTLOADER_SRCDIR)/mcuboot
|
||||
MCUBOOT_ESPDIR = $(MCUBOOT_SRCDIR)/boot/espressif
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
MCUBOOT_TOOLCHAIN = $(TOOLSDIR)/mcuboot_toolchain_espressif.cmake
|
||||
ifndef MCUBOOT_VERSION
|
||||
MCUBOOT_VERSION = $(CONFIG_ESPRESSIF_MCUBOOT_VERSION)
|
||||
endif
|
||||
|
||||
ifndef MCUBOOT_URL
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
endif
|
||||
|
||||
# Helpers for creating the configuration file
|
||||
|
||||
|
|
@ -92,7 +98,7 @@ BOOTLOADER_BIN = $(TOPDIR)/mcuboot-$(CHIP_SERIES).bin
|
|||
$(MCUBOOT_SRCDIR): $(BOOTLOADER_SRCDIR)
|
||||
$(Q) echo "Cloning MCUboot"
|
||||
$(Q) git clone --quiet $(MCUBOOT_URL) $(MCUBOOT_SRCDIR)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(CONFIG_ESPRESSIF_MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" submodule --quiet update --init --recursive ext/mbedtls
|
||||
|
||||
$(BOOTLOADER_BIN): chip/$(ESP_HAL_3RDPARTY_REPO) $(MCUBOOT_SRCDIR) $(BOOTLOADER_CONFIG)
|
||||
|
|
|
|||
|
|
@ -35,8 +35,14 @@ BOOTLOADER_CONFIG = $(BOOTLOADER_DIR)/bootloader.conf
|
|||
|
||||
MCUBOOT_SRCDIR = $(BOOTLOADER_DIR)/mcuboot
|
||||
MCUBOOT_ESPDIR = $(MCUBOOT_SRCDIR)/boot/espressif
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
MCUBOOT_TOOLCHAIN = $(TOPDIR)/tools/esp32/mcuboot_toolchain_esp32.cmake
|
||||
ifndef MCUBOOT_VERSION
|
||||
MCUBOOT_VERSION = $(CONFIG_ESP32_MCUBOOT_VERSION)
|
||||
endif
|
||||
|
||||
ifndef MCUBOOT_URL
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
endif
|
||||
|
||||
# Helpers for creating the configuration file
|
||||
|
||||
|
|
@ -128,7 +134,7 @@ BOOTLOADER_SIGNED_BIN = $(TOPDIR)/mcuboot-esp32.signed.bin
|
|||
$(MCUBOOT_SRCDIR):
|
||||
$(Q) echo "Cloning MCUboot"
|
||||
$(Q) git clone --quiet $(MCUBOOT_URL) $(MCUBOOT_SRCDIR)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(CONFIG_ESP32_MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" submodule --quiet update --init --recursive ext/mbedtls
|
||||
|
||||
$(BOOTLOADER_BIN): chip/$(ESP_HAL_3RDPARTY_REPO) $(MCUBOOT_SRCDIR) $(BOOTLOADER_CONFIG)
|
||||
|
|
|
|||
|
|
@ -35,8 +35,14 @@ BOOTLOADER_CONFIG = $(BOOTLOADER_DIR)/bootloader.conf
|
|||
|
||||
MCUBOOT_SRCDIR = $(BOOTLOADER_DIR)/mcuboot
|
||||
MCUBOOT_ESPDIR = $(MCUBOOT_SRCDIR)/boot/espressif
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
MCUBOOT_TOOLCHAIN = $(TOPDIR)/tools/esp32s2/mcuboot_toolchain_esp32s2.cmake
|
||||
ifndef MCUBOOT_VERSION
|
||||
MCUBOOT_VERSION = $(CONFIG_ESP32S2_MCUBOOT_VERSION)
|
||||
endif
|
||||
|
||||
ifndef MCUBOOT_URL
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
endif
|
||||
|
||||
$(BOOTLOADER_DIR):
|
||||
$(Q) mkdir -p $(BOOTLOADER_DIR) &>/dev/null
|
||||
|
|
@ -121,7 +127,7 @@ BOOTLOADER_SIGNED_BIN = $(TOPDIR)/mcuboot-esp32s2.signed.bin
|
|||
$(MCUBOOT_SRCDIR): $(BOOTLOADER_DIR)
|
||||
$(Q) echo "Cloning MCUboot"
|
||||
$(Q) git clone --quiet $(MCUBOOT_URL) $(MCUBOOT_SRCDIR)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(CONFIG_ESP32S2_MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" submodule --quiet update --init --recursive ext/mbedtls
|
||||
|
||||
$(BOOTLOADER_BIN): chip/$(ESP_HAL_3RDPARTY_REPO) $(MCUBOOT_SRCDIR) $(BOOTLOADER_CONFIG)
|
||||
|
|
|
|||
|
|
@ -35,8 +35,14 @@ BOOTLOADER_CONFIG = $(BOOTLOADER_DIR)/bootloader.conf
|
|||
|
||||
MCUBOOT_SRCDIR = $(BOOTLOADER_DIR)/mcuboot
|
||||
MCUBOOT_ESPDIR = $(MCUBOOT_SRCDIR)/boot/espressif
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
MCUBOOT_TOOLCHAIN = $(TOPDIR)/tools/esp32s3/mcuboot_toolchain_esp32s3.cmake
|
||||
ifndef MCUBOOT_VERSION
|
||||
MCUBOOT_VERSION = $(CONFIG_ESP32S3_MCUBOOT_VERSION)
|
||||
endif
|
||||
|
||||
ifndef MCUBOOT_URL
|
||||
MCUBOOT_URL = https://github.com/mcu-tools/mcuboot
|
||||
endif
|
||||
|
||||
$(BOOTLOADER_DIR):
|
||||
$(Q) mkdir -p $(BOOTLOADER_DIR) &>/dev/null
|
||||
|
|
@ -98,7 +104,7 @@ BOOTLOADER_BIN = $(TOPDIR)/mcuboot-esp32s3.bin
|
|||
$(MCUBOOT_SRCDIR): $(BOOTLOADER_DIR)
|
||||
$(Q) echo "Cloning MCUboot"
|
||||
$(Q) git clone --quiet $(MCUBOOT_URL) $(MCUBOOT_SRCDIR)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(CONFIG_ESP32S3_MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" checkout --quiet $(MCUBOOT_VERSION)
|
||||
$(Q) git -C "$(MCUBOOT_SRCDIR)" submodule --quiet update --init --recursive ext/mbedtls
|
||||
|
||||
$(BOOTLOADER_BIN): chip/$(ESP_HAL_3RDPARTY_REPO) $(MCUBOOT_SRCDIR) $(BOOTLOADER_CONFIG)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue