cmake: revert using EXCLUDE_FROM_ALL when adding component subdirectories

Reverting (for now) the change in !4452 to use EXCLUDE_FROM_ALL.
Apparently this also affects custom targets with ALL option specified,
not causing them to be built with the project.

This is apparently a bug which has a merged fix:
https://gitlab.kitware.com/cmake/cmake/merge_requests/2816
This commit is contained in:
Renz Christian Bagaporo 2019-05-31 15:27:11 +08:00
parent f0f861ccd9
commit 6365658d3f

View File

@ -74,9 +74,9 @@ foreach(component_target ${build_component_targets})
idf_build_get_property(build_prefix __PREFIX)
set(__idf_component_context 1)
if(NOT prefix STREQUAL build_prefix)
add_subdirectory(${dir} ${prefix}_${_name} EXCLUDE_FROM_ALL)
add_subdirectory(${dir} ${prefix}_${_name})
else()
add_subdirectory(${dir} ${_name} EXCLUDE_FROM_ALL)
add_subdirectory(${dir} ${_name})
endif()
set(__idf_component_context 0)
endforeach()