Moving on from include() to add_subdirectory() is the mayor change in this PR. add_subdirectory() mirrors the directory structure from the source-tree to the build-tree which isolates targets and their properties in a hierarchical structure. This is idiomatic usage in CMake.
On the way, I added two more fixes. Please find more details in the individual commit messages.
I completely agree with these changes. Back in the days, I read that include(...) would have been better than add_subdirectory(...) but I guess it was wrong.
Moving on from
include()
toadd_subdirectory()
is the mayor change in this PR.add_subdirectory()
mirrors the directory structure from the source-tree to the build-tree which isolates targets and their properties in a hierarchical structure. This is idiomatic usage in CMake.On the way, I added two more fixes. Please find more details in the individual commit messages.