diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index 4084d0e44..85a0ccc90 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -1735,6 +1735,11 @@ void cmMakefile::AddDefinition(const char* name, bool value) #endif } +void cmMakefile::MarkVariableAsUsed(const char* var) +{ + this->Internal->VarUsageStack.top().insert(var); +} + bool cmMakefile::VariableInitialized(const char* var) const { if(this->Internal->VarInitStack.top().find(var) != this->Internal->VarInitStack.top().end()) diff --git a/Source/cmMakefile.h b/Source/cmMakefile.h index 89979d6a3..6b0bfa26a 100644 --- a/Source/cmMakefile.h +++ b/Source/cmMakefile.h @@ -61,6 +61,8 @@ public: unsigned int GetCacheMajorVersion(); unsigned int GetCacheMinorVersion(); + /* Mark a variable as used */ + void MarkVariableAsUsed(const char* var); /* return true if a variable has been initialized */ bool VariableInitialized(const char* ) const; /* return true if a variable has been used */