From e71a595cf8a8e37d5bf1f4181ef78672054f6006 Mon Sep 17 00:00:00 2001 From: Frantisek Hrbata Date: Tue, 24 Sep 2024 14:22:10 +0200 Subject: [PATCH] change(examples): explicitly specify component dependencies for examples Currently, several examples do not explicitly state their component dependencies, relying instead on the default behavior that includes all registered components and commonly required ones in the build. Explicitly adding component dependencies can reduce build time when set(COMPONENTS main) is used. Signed-off-by: Frantisek Hrbata --- examples/protocols/mqtt/custom_outbox/main/CMakeLists.txt | 1 + examples/protocols/mqtt/ssl/main/CMakeLists.txt | 1 + examples/protocols/mqtt/ssl_ds/main/CMakeLists.txt | 1 + examples/protocols/mqtt/ssl_mutual_auth/main/CMakeLists.txt | 1 + examples/protocols/mqtt/ssl_psk/main/CMakeLists.txt | 1 + examples/protocols/mqtt/tcp/main/CMakeLists.txt | 1 + examples/protocols/mqtt/ws/main/CMakeLists.txt | 1 + examples/protocols/mqtt/wss/main/CMakeLists.txt | 1 + examples/protocols/mqtt5/main/CMakeLists.txt | 1 + 9 files changed, 9 insertions(+) diff --git a/examples/protocols/mqtt/custom_outbox/main/CMakeLists.txt b/examples/protocols/mqtt/custom_outbox/main/CMakeLists.txt index cb970c8..7423b60 100644 --- a/examples/protocols/mqtt/custom_outbox/main/CMakeLists.txt +++ b/examples/protocols/mqtt/custom_outbox/main/CMakeLists.txt @@ -1,3 +1,4 @@ idf_component_register(SRCS "app_main.c" INCLUDE_DIRS "." + PRIV_REQUIRES mqtt nvs_flash esp_netif ) diff --git a/examples/protocols/mqtt/ssl/main/CMakeLists.txt b/examples/protocols/mqtt/ssl/main/CMakeLists.txt index 61fac40..d6ca62d 100644 --- a/examples/protocols/mqtt/ssl/main/CMakeLists.txt +++ b/examples/protocols/mqtt/ssl/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt esp_partition nvs_flash esp_netif app_update INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt/ssl_ds/main/CMakeLists.txt b/examples/protocols/mqtt/ssl_ds/main/CMakeLists.txt index 61fac40..055d4c5 100644 --- a/examples/protocols/mqtt/ssl_ds/main/CMakeLists.txt +++ b/examples/protocols/mqtt/ssl_ds/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt esp_netif INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt/ssl_mutual_auth/main/CMakeLists.txt b/examples/protocols/mqtt/ssl_mutual_auth/main/CMakeLists.txt index 61fac40..31650f3 100644 --- a/examples/protocols/mqtt/ssl_mutual_auth/main/CMakeLists.txt +++ b/examples/protocols/mqtt/ssl_mutual_auth/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt esp_wifi nvs_flash INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt/ssl_psk/main/CMakeLists.txt b/examples/protocols/mqtt/ssl_psk/main/CMakeLists.txt index 61fac40..31650f3 100644 --- a/examples/protocols/mqtt/ssl_psk/main/CMakeLists.txt +++ b/examples/protocols/mqtt/ssl_psk/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt esp_wifi nvs_flash INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt/tcp/main/CMakeLists.txt b/examples/protocols/mqtt/tcp/main/CMakeLists.txt index 61fac40..3bf739c 100644 --- a/examples/protocols/mqtt/tcp/main/CMakeLists.txt +++ b/examples/protocols/mqtt/tcp/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt nvs_flash esp_netif INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt/ws/main/CMakeLists.txt b/examples/protocols/mqtt/ws/main/CMakeLists.txt index 61fac40..31650f3 100644 --- a/examples/protocols/mqtt/ws/main/CMakeLists.txt +++ b/examples/protocols/mqtt/ws/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt esp_wifi nvs_flash INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt/wss/main/CMakeLists.txt b/examples/protocols/mqtt/wss/main/CMakeLists.txt index 61fac40..31650f3 100644 --- a/examples/protocols/mqtt/wss/main/CMakeLists.txt +++ b/examples/protocols/mqtt/wss/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt esp_wifi nvs_flash INCLUDE_DIRS ".") diff --git a/examples/protocols/mqtt5/main/CMakeLists.txt b/examples/protocols/mqtt5/main/CMakeLists.txt index 61fac40..3bf739c 100644 --- a/examples/protocols/mqtt5/main/CMakeLists.txt +++ b/examples/protocols/mqtt5/main/CMakeLists.txt @@ -1,2 +1,3 @@ idf_component_register(SRCS "app_main.c" + PRIV_REQUIRES mqtt nvs_flash esp_netif INCLUDE_DIRS ".")