diff --git a/components/bootloader/Makefile.projbuild b/components/bootloader/Makefile.projbuild index 7876635c..734e3092 100644 --- a/components/bootloader/Makefile.projbuild +++ b/components/bootloader/Makefile.projbuild @@ -18,7 +18,7 @@ SECURE_BOOT_SIGNING_KEY=$(abspath $(call dequote,$(CONFIG_SECURE_BOOT_SIGNING_KE export SECURE_BOOT_SIGNING_KEY # used by bootloader_support component # Has a matching value in bootloader_support esp_flash_partitions.h -BOOTLOADER_OFFSET := 0x1000 +BOOTLOADER_OFFSET := 0x0000 # Custom recursive make for bootloader sub-project # @@ -56,7 +56,7 @@ bootloader: $(BOOTLOADER_BIN) ESPTOOL_ALL_FLASH_ARGS += $(BOOTLOADER_OFFSET) $(BOOTLOADER_BIN) bootloader-flash: $(BOOTLOADER_BIN) $(call prereq_if_explicit,erase_flash) - $(ESPTOOLPY_WRITE_FLASH) 0x1000 $^ + $(ESPTOOLPY_WRITE_FLASH) 0x0000 $^ else ifdef CONFIG_SECURE_BOOTLOADER_ONE_TIME_FLASH diff --git a/components/bootloader/subproject/Makefile b/components/bootloader/subproject/Makefile index e01dc3c8..f4c66276 100644 --- a/components/bootloader/subproject/Makefile +++ b/components/bootloader/subproject/Makefile @@ -8,14 +8,14 @@ endif PROJECT_NAME := bootloader -COMPONENTS := esptool_py bootloader_support log spi_flash micro-ecc soc main +COMPONENTS := esptool_py main # Clear C and CXX from top level project CFLAGS = CXXFLAGS = -#We cannot include the esp32 component directly but we need its includes. -CFLAGS += -I $(IDF_PATH)/components/esp32/include +#We cannot include the esp8266 component directly but we need its includes. +CFLAGS += -I $(IDF_PATH)/components/esp8266/include # The bootloader pseudo-component is also included in this build, for its Kconfig.projbuild to be included. # diff --git a/components/bootloader/subproject/main/Makefile.projbuild b/components/bootloader/subproject/main/Makefile.projbuild deleted file mode 100644 index c368c684..00000000 --- a/components/bootloader/subproject/main/Makefile.projbuild +++ /dev/null @@ -1,4 +0,0 @@ -# Submodules normally added in component.mk, but fully qualified -# paths can be added at this level (we need binary librtc to be -# available to link bootloader). -COMPONENT_SUBMODULES += $(IDF_PATH)/components/esp32/lib diff --git a/components/bootloader/subproject/main/component.mk b/components/bootloader/subproject/main/component.mk index a54fe30a..fd4cc90c 100644 --- a/components/bootloader/subproject/main/component.mk +++ b/components/bootloader/subproject/main/component.mk @@ -6,15 +6,9 @@ # LINKER_SCRIPTS := \ - esp32.bootloader.ld \ - $(IDF_PATH)/components/esp32/ld/esp32.rom.ld \ - $(IDF_PATH)/components/esp32/ld/esp32.rom.spiram_incompatible_fns.ld \ - $(IDF_PATH)/components/esp32/ld/esp32.peripherals.ld \ - esp32.bootloader.rom.ld - -ifndef CONFIG_SPI_FLASH_ROM_DRIVER_PATCH -LINKER_SCRIPTS += $(IDF_PATH)/components/esp32/ld/esp32.rom.spiflash.ld -endif + esp8266.bootloader.ld \ + $(IDF_PATH)/components/esp8266/ld/esp8266.rom.ld \ + esp8266.bootloader.rom.ld COMPONENT_ADD_LDFLAGS += -L $(COMPONENT_PATH) $(addprefix -T ,$(LINKER_SCRIPTS))