I am currently playing around with the C++ source-code of CMake, trying to implement a new feature.
For that I need to retrieve some defined variable, but I want to distinguish if its value comes from a CMake cache variable or from a local CMake variable.
Source/cmMakefile.[h|cxx]I found the following methods which retrieve/access the values of variables:
Sadly, none of these allows to retrieve just the locally defined variable. They always fall back to returning the Cache variable if no local one was found.
Is there really no other way than to modify the signature of these functions and provide an optional (defaulted) parameter which determines if the Cache should be accessed as fallback or not?
Thanks for any information.