mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
feat(esp_wifi): Add dependency on wifi_remote for chips with no wifi
This commit is contained in:
parent
bb1bc2afac
commit
07d60b1c04
@ -38,11 +38,18 @@ if(CONFIG_ESP_WIFI_ENABLED)
|
||||
if(CONFIG_ESP_WIFI_NAN_ENABLE)
|
||||
list(APPEND srcs "wifi_apps/src/nan_app.c")
|
||||
endif()
|
||||
set(local_include_dirs include/local)
|
||||
else()
|
||||
# No local wifi: provide only netif bindings
|
||||
set(srcs
|
||||
"src/wifi_default.c"
|
||||
"src/wifi_netif.c")
|
||||
set(local_include_dirs)
|
||||
|
||||
endif()
|
||||
|
||||
idf_component_register(SRCS "${srcs}"
|
||||
INCLUDE_DIRS "include" "wifi_apps/include"
|
||||
INCLUDE_DIRS "include" "wifi_apps/include" ${local_include_dirs}
|
||||
REQUIRES esp_event esp_phy esp_netif
|
||||
PRIV_REQUIRES driver esptool_py esp_pm esp_timer nvs_flash
|
||||
wpa_supplicant hal lwip esp_coex ${extra_priv_requires}
|
||||
@ -70,6 +77,13 @@ if(CONFIG_ESP_WIFI_ENABLED)
|
||||
target_link_libraries(${COMPONENT_LIB} PUBLIC ${blob})
|
||||
endforeach()
|
||||
endif()
|
||||
else()
|
||||
# No local wifi: use esp_wifi_remote if it's available within our components
|
||||
idf_build_get_property(build_components BUILD_COMPONENTS)
|
||||
if(esp_wifi_remote IN_LIST build_components)
|
||||
idf_component_get_property(esp_wifi_remote esp_wifi_remote COMPONENT_LIB)
|
||||
target_link_libraries(${COMPONENT_LIB} PUBLIC ${esp_wifi_remote})
|
||||
endif()
|
||||
|
||||
if(CONFIG_SPIRAM)
|
||||
idf_component_optional_requires(PRIVATE esp_psram)
|
||||
|
@ -4,6 +4,7 @@
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
#include "sdkconfig.h"
|
||||
#include "esp_system.h"
|
||||
#include "esp_wifi.h"
|
||||
#include "esp_netif.h"
|
||||
#include "esp_log.h"
|
||||
|
Loading…
Reference in New Issue
Block a user