Skip to content

Commit

Permalink
esp_wifi: merge esp32s2beta WiFi library to master branch
Browse files Browse the repository at this point in the history
  • Loading branch information
TimXia committed Oct 29, 2019
1 parent a45e998 commit 9afba2a
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 19 deletions.
11 changes: 3 additions & 8 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -67,14 +67,6 @@
path = examples/build_system/cmake/import_lib/main/lib/tinyxml2
url = ../../leethomason/tinyxml2.git

[submodule "components/esp_wifi/lib_esp32"]
path = components/esp_wifi/lib_esp32
url = ../../espressif/esp32-wifi-lib.git

[submodule "components/esp_wifi/lib_esp32s2beta"]
path = components/esp_wifi/lib_esp32s2beta
url = ../../espressif/esp32-wifi-lib.git

[submodule "components/bt/host/nimble/nimble"]
path = components/bt/host/nimble/nimble
url = ../../espressif/esp-nimble.git
Expand All @@ -83,3 +75,6 @@
path = components/cbor/tinycbor
url = ../../intel/tinycbor.git

[submodule "components/esp_wifi/lib"]
path = components/esp_wifi/lib
url = ../../espressif/esp32-wifi-lib.git
2 changes: 1 addition & 1 deletion components/bootloader/subproject/main/Makefile.projbuild
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 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/esp_wifi/lib_esp32
COMPONENT_SUBMODULES += $(IDF_PATH)/components/esp_wifi/lib
4 changes: 2 additions & 2 deletions components/esp_wifi/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ idf_component_register(SRCS "src/coexist.c"
LDFRAGMENTS "${ldfragments}")

idf_build_get_property(build_dir BUILD_DIR)
target_link_libraries(${COMPONENT_LIB} PUBLIC "-L ${CMAKE_CURRENT_SOURCE_DIR}/lib_${idf_target}")
target_link_libraries(${COMPONENT_LIB} PUBLIC "-L ${CMAKE_CURRENT_SOURCE_DIR}/lib/${idf_target}")

if(link_binary_libs)
if(CONFIG_IDF_TARGET_ESP32)
Expand All @@ -39,7 +39,7 @@ if(link_binary_libs)

foreach(blob ${blobs})
add_library(${blob} STATIC IMPORTED)
set_property(TARGET ${blob} PROPERTY IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/lib_${idf_target}/lib${blob}.a)
set_property(TARGET ${blob} PROPERTY IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/lib/${idf_target}/lib${blob}.a)
target_link_libraries(${COMPONENT_LIB} PUBLIC ${blob})

foreach(_blob ${blobs})
Expand Down
6 changes: 3 additions & 3 deletions components/esp_wifi/component.mk
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ COMPONENT_SRCDIRS := src

ifndef CONFIG_ESP32_NO_BLOBS
LIBS := core rtc net80211 pp smartconfig coexist espnow phy mesh
COMPONENT_ADD_LDFLAGS += -L$(COMPONENT_PATH)/lib_$(IDF_TARGET) \
COMPONENT_ADD_LDFLAGS += -L$(COMPONENT_PATH)/lib/$(IDF_TARGET) \
$(addprefix -l,$(LIBS))

COMPONENT_ADD_LDFRAGMENTS += linker.lf

COMPONENT_SUBMODULES += lib_$(IDF_TARGET)
COMPONENT_SUBMODULES += lib

ALL_LIB_FILES := $(patsubst %,$(COMPONENT_PATH)/lib_$(IDF_TARGET)/lib%.a,$(LIBS))
ALL_LIB_FILES := $(patsubst %,$(COMPONENT_PATH)/lib/$(IDF_TARGET)/lib%.a,$(LIBS))
COMPONENT_ADD_LINKER_DEPS += $(ALL_LIB_FILES)
endif

1 change: 1 addition & 0 deletions components/esp_wifi/lib
Submodule lib added at 4a7e54
1 change: 0 additions & 1 deletion components/esp_wifi/lib_esp32
Submodule lib_esp32 deleted from 1d830b
1 change: 0 additions & 1 deletion components/esp_wifi/lib_esp32s2beta
Submodule lib_esp32s2beta deleted from 8ea1c6
6 changes: 3 additions & 3 deletions tools/ci/config/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ build_template_app:
- export EXTRA_CXXFLAGS=${PEDANTIC_CXXFLAGS}

# Check if there are any stray printf/ets_printf references in WiFi libs
- pushd ../components/esp_wifi/lib_esp32
- test $(xtensa-esp32-elf-nm *.a | grep -w printf | wc -l) -eq 0
- test $(xtensa-esp32-elf-nm *.a | grep -w ets_printf | wc -l) -eq 0
- pushd ../components/esp_wifi/lib
- for dir in esp32 esp32s2beta; do test $(xtensa-esp32-elf-nm $dir/*.a | grep -w printf | wc -l) -eq 0; done;
- for dir in esp32 esp32s2beta; do test $(xtensa-esp32-elf-nm $dir/*.a | grep -w ets_printf | wc -l) -eq 0; done;
- popd

build_ssc:
Expand Down

0 comments on commit 9afba2a

Please sign in to comment.