Reorder library arguments so component libraries come first
This allows components to override weak linked symbols in the core or the SDK libraries, without needing to force symbol discovery. Will help with #24, for instance.
This commit is contained in:
parent
5bb832b7a6
commit
c19bb63286
1 changed files with 2 additions and 2 deletions
|
@ -80,7 +80,7 @@ OBJDUMP = $(CROSS)objdump
|
|||
|
||||
# Source components to compile and link. Each of these are subdirectories
|
||||
# of the root, with a 'component.mk' file.
|
||||
COMPONENTS ?= core FreeRTOS lwip axtls $(EXTRA_COMPONENTS)
|
||||
COMPONENTS ?= $(EXTRA_COMPONENTS) FreeRTOS lwip axtls core
|
||||
|
||||
# binary esp-iot-rtos SDK libraries to link. These are pre-processed prior to linking.
|
||||
SDK_LIBS ?= main net80211 phy pp wpa
|
||||
|
@ -318,7 +318,7 @@ $(LD_DIR)%.ld: $(ROOT)ld/%.ld | $(LD_DIR)
|
|||
# final linking step to produce .elf
|
||||
$(PROGRAM_OUT): $(COMPONENT_ARS) $(SDK_PROCESSED_LIBS) $(LINKER_SCRIPTS_PROCESSED)
|
||||
$(vecho) "LD $@"
|
||||
$(Q) $(LD) $(LDFLAGS) -Wl,--start-group $(LIB_ARGS) $(SDK_LIB_ARGS) $(COMPONENT_ARS) -Wl,--end-group -o $@
|
||||
$(Q) $(LD) $(LDFLAGS) -Wl,--start-group $(COMPONENT_ARS) $(LIB_ARGS) $(SDK_LIB_ARGS) -Wl,--end-group -o $@
|
||||
|
||||
$(BUILD_DIR) $(FW_BASE) $(BUILD_DIR)sdklib $(LD_DIR):
|
||||
$(Q) mkdir -p $@
|
||||
|
|
Loading…
Reference in a new issue