Pass linker search paths with -L not -Wl,-L, so they take priority over sysroot

This fixes link-time errors where the toolchain used was esp-open-sdk
built with the default STANDALONE=y (meaning there are Espressif SDK
libs in the sysroot).

Closes #74
This commit is contained in:
Angus Gratton 2015-12-01 09:44:50 +11:00
parent 812c2fef21
commit e264d63e35

View file

@ -106,7 +106,7 @@ CFLAGS = $(C_CXX_FLAGS) -std=gnu99
# Flags for C++ only # Flags for C++ only
CXXFLAGS = $(C_CXX_FLAGS) -fno-exceptions -fno-rtti CXXFLAGS = $(C_CXX_FLAGS) -fno-exceptions -fno-rtti
LDFLAGS = -nostdlib -Wl,--no-check-sections -Wl,-L$(BUILD_DIR)sdklib -Wl,-L$(ROOT)lib -u $(ENTRY_SYMBOL) -Wl,-static -Wl,-Map=build/${PROGRAM}.map $(EXTRA_LDFLAGS) LDFLAGS = -nostdlib -Wl,--no-check-sections -L$(BUILD_DIR)sdklib -L$(ROOT)lib -u $(ENTRY_SYMBOL) -Wl,-static -Wl,-Map=build/${PROGRAM}.map $(EXTRA_LDFLAGS)
ifeq ($(SPLIT_SECTIONS),1) ifeq ($(SPLIT_SECTIONS),1)
C_CXX_FLAGS += -ffunction-sections -fdata-sections C_CXX_FLAGS += -ffunction-sections -fdata-sections