Use IDF_PATH instead of SDK_PATH for the environment variable pointing to esp-idf

This will require a matching change in all projects using ESP-IDF.
This commit is contained in:
Angus Gratton
2016-08-19 14:32:35 +08:00
parent 9ec0e1545d
commit f853f94335
19 changed files with 43 additions and 43 deletions

View File

@@ -1,23 +1,23 @@
#
# Component Makefile
#
# This Makefile should, at the very least, just include $(SDK_PATH)/make/component.mk. By default,
# This Makefile should, at the very least, just include $(IDF_PATH)/make/component.mk. By default,
# this will take the sources in this directory, compile them and link them into
# lib(subdirectory_name).a in the build directory. This behaviour is entirely configurable,
# please read the SDK documents if you need to do this.
# please read the esp-idf build system document if you need to do this.
#
LIBS := crypto core net80211 phy rtc pp wpa wps
COMPONENT_ADD_LDFLAGS := -lesp32 \
$(abspath libhal.a) \
-L$(abspath lib) \
$(addprefix -l,$(LIBS)) \
-L $(abspath ld) \
-T eagle.fpga32.v7.ld \
-T eagle.fpga32.rom.addr.v7.ld
-T eagle.fpga32.rom.addr.v7.ld
include $(SDK_PATH)/make/component.mk
include $(IDF_PATH)/make/component.mk
ALL_LIB_FILES := $(patsubst %,$(COMPONENT_PATH)/lib/lib%.a,$(LIBS))
@@ -25,10 +25,10 @@ ALL_LIB_FILES := $(patsubst %,$(COMPONENT_PATH)/lib/lib%.a,$(LIBS))
# be invoked if any modules are missing (probably because
# git submodule update --init needs to be run).
$(ALL_LIB_FILES):
$(Q) [ -d ${SDK_PATH}/.git ] || ( @echo "ERROR: Missing libraries in esp32 component. esp-idf must be cloned from git to work."; exit 1 )
$(Q) [ -d ${IDF_PATH}/.git ] || ( @echo "ERROR: Missing libraries in esp32 component. esp-idf must be cloned from git to work."; exit 1 )
$(Q) [ -x $(which git) ] || ( @echo "ERROR: Missing libraries in esp32 component. Need to run 'git submodule update --init' in esp-idf root directory."; exit 1 )
@echo "Warning: Missing libraries in components/esp32/lib/ submodule. Going to try running 'git submodule update --init' in esp-idf root directory..."
cd ${SDK_PATH} && git submodule update --init
cd ${IDF_PATH} && git submodule update --init
# adding $(ALL_LIB_FILES) as a build dependency here is a hack to make
# sure they get evaluated. Once TW6630 lands and we have library file