mirror of
https://github.com/espressif/esp-idf
synced 2025-03-10 01:29:21 -04:00
cmake: add hidden option to link components as group
Adds a hidden option to link components in projects as one big group for debugging purposes. Makes it easy to single out if symbols are not really defined or some requirements are missing for components leading to undefined link errors.
This commit is contained in:
parent
2c4e2825ad
commit
7b9ab1e597
@ -440,6 +440,10 @@ macro(project project_name)
|
||||
add_executable(${project_elf} "${project_elf_src}")
|
||||
add_dependencies(${project_elf} _project_elf_src)
|
||||
|
||||
if(__PROJECT_GROUP_LINK_COMPONENTS)
|
||||
target_link_libraries(${project_elf} "-Wl,--start-group")
|
||||
endif()
|
||||
|
||||
if(test_components)
|
||||
target_link_libraries(${project_elf} "-Wl,--whole-archive")
|
||||
foreach(test_component ${test_components})
|
||||
|
Loading…
x
Reference in New Issue
Block a user