summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx21
1 files changed, 21 insertions, 0 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index cd2fa9b..34d44e2 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -1232,6 +1232,27 @@ bool cmMakefile::IsOn(const char* name) const
return cmSystemTools::IsOn(value);
}
+bool cmMakefile::IsSet(const char* name) const
+{
+ const char* value = this->GetDefinition(name);
+ if ( !value )
+ {
+ return false;
+ }
+
+ if ( ! *value )
+ {
+ return false;
+ }
+
+ if ( cmSystemTools::IsNOTFOUND(value) )
+ {
+ return false;
+ }
+
+ return true;
+}
+
const char* cmMakefile::GetRequiredDefinition(const char* name) const
{
const char* ret = this->GetDefinition(name);