boostorg / boost_install

8 stars 32 forks source link

Some CMake options are not marked as advanced #48

Closed DenizThatMenace closed 2 years ago

DenizThatMenace commented 3 years ago

When building a CMake project which depends on Boost and one uses find_package(Boost CONFIG) to find the installed Boost libraries, the CMake cache variables for Boost which are listed in cmake-gui are mostly marked as advanced (using the mark_as_advanced CMake command), however, not all of them are.

These CMake cache variables have the form boost_<library-name>_DIR and point to the directories which contains the CMake config scripts for importing the associated Boost library.
However, these variables exist for all such installed config scripts, even if the associated library is not provided for the build platform (and therefore not installed). Examples for such variables on a Linux platform are:

In that case these variables are not marked as advanced and are therefore always shown, even if cmake-gui shall only display non-advanced options.

I recommend, these variables should still be marked as advanced.

pdimov commented 3 years ago

Should be fixed with https://github.com/boostorg/boost_install/commit/c1878b042c43188184a49ac1e0ea9ddd84d1460e.