Skip to content

Commit

Permalink
[ESP32] Append to chip_libraries list only if present in (project-chi…
Browse files Browse the repository at this point in the history
…p#29281)

BUILD_COMPONENTS and fix some indentation.
  • Loading branch information
shubhamdp authored Sep 18, 2023
1 parent 8bf4bdd commit 242a52b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions config/esp32/components/chip/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -486,12 +486,12 @@ endforeach()
set(components_to_link esp_event hal esp_system soc efuse vfs driver esp_coex freertos)
idf_build_get_property(build_components BUILD_COMPONENTS)
foreach(component ${components_to_link})
# Some of the components are not present in IDF v4.x
# So, Check if the component is in the list of build components
if("${component}" IN_LIST build_components)
# Some of the components are not present in IDF v4.x
# So, Check if the component is in the list of build components
if("${component}" IN_LIST build_components)
idf_component_get_property(lib_name ${component} COMPONENT_LIB)
list(APPEND chip_libraries $<TARGET_FILE:${lib_name}>)
endif()
list(APPEND chip_libraries $<TARGET_FILE:${lib_name}>)
endforeach()

target_link_libraries(${COMPONENT_LIB} INTERFACE -Wl,--start-group
Expand Down

0 comments on commit 242a52b

Please sign in to comment.