Created
April 19, 2019 18:12
-
-
Save deysumitkr/2eda28479aa5068e50cbd3c58ade37eb to your computer and use it in GitHub Desktop.
List all variables available in cmake
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# List all variables and values in cmake | |
get_cmake_property(_variableNames VARIABLES) | |
list (SORT _variableNames) | |
foreach (_variableName ${_variableNames}) | |
message(STATUS "${_variableName}=${${_variableName}}") | |
endforeach() | |
# To print environment variables, use CMake's command mode: | |
execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "environment") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment