Displaying CMake variables - Stack Overflow
stackoverflow.com › questions › 31343813Jul 10, 2015 · I can give you a yes answer to (2) but it does require that you (re)run cmake. But since you can re-run your cmake configure step by simply executing cmake . in the build directory, re-running cmake should not keep you from trying this approach. My answer is given in this SO answer and uses the get_cmake_property command.
message — CMake 3.23.0-rc2 Documentation
cmake.org › cmake › helpBy default, message context is not shown, it has to be explicitly enabled by giving the cmake --log-context command-line option or by setting the CMAKE_MESSAGE_CONTEXT_SHOW variable to true. See the CMAKE_MESSAGE_CONTEXT documentation for usage examples. CMake Warning and Error message text displays using a simple markup language.