mirror of
https://github.com/espressif/esp-idf.git
synced 2026-08-11 17:52:00 +03:00
fix(dns_over_https): declare main and protocol_examples_common deps
dns_over_https/main includes time_sync.h, nvs_flash.h, esp_event.h, esp_timer.h, and mbedtls headers. Declare nvs_flash, esp_event, esp_timer, mbedtls and time_sync in PRIV_REQUIRES so the build is self-describing under any build system. Also move esp_netif from PRIV_REQUIRES to REQUIRES in protocol_examples_common, since its public header exposes esp_netif.h. Also add the PRIVATE keyword to target_link_libraries in the dns_over_https component — CMake rejects mixed keyword/plain signatures on the same target.
This commit is contained in:
@@ -3,5 +3,5 @@ idf_component_register(SRCS "dns_over_https.c" "dns_utils.c"
|
||||
PRIV_REQUIRES nvs_flash lwip esp_event esp-tls esp_http_client)
|
||||
|
||||
if(CONFIG_LWIP_HOOK_NETCONN_EXT_RESOLVE_CUSTOM)
|
||||
target_link_libraries(${COMPONENT_LIB} "-u lwip_hook_netconn_external_resolve")
|
||||
target_link_libraries(${COMPONENT_LIB} PRIVATE "-u lwip_hook_netconn_external_resolve")
|
||||
endif()
|
||||
|
||||
@@ -7,4 +7,5 @@ endif()
|
||||
|
||||
idf_component_register(SRCS "example_dns_over_https.c"
|
||||
INCLUDE_DIRS "."
|
||||
PRIV_REQUIRES time_sync nvs_flash esp_event esp_timer mbedtls
|
||||
EMBED_TXTFILES ${cert_file})
|
||||
|
||||
Reference in New Issue
Block a user