Skip to content

example where *main* CMakeLists.txt calls add_subdirectory(../../common/utils

Notifications You must be signed in to change notification settings

user706/cmake_add_outOfTree_dirs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

It is a MISTAKE to assume that the main CMakeLists.txt is always located in a toplevel directory, with all files BELOW that directory. This mistaken assuption leads to a severe "BUG" in "cmake for visual studio".

Example: Here the main CMakeList.txt is located here: target_device/full_variant/CMakeLists.txt
And from there we call:

add_subdirectory(../../common/utils    # code which is NOT in a subdirectory, but "out-of-tree"
                 utils_binary_dir      # build dir
                 ) 

This means that we go to out-of-tree builds such as common/utils/CMakeLists.txt
which ARE NOT DISPLAYED PROPERLY in the new "cmake for visual studio".

This is a bug. It must be possible for me to see all the code.
Thus: In the case where the main CMakeLists.txt pulls in stuff, which does not lie in a subdirectory BELOW the main CMakeLists.txt-directory, we must still be able to see that code.

About

example where *main* CMakeLists.txt calls add_subdirectory(../../common/utils

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published