summaryrefslogtreecommitdiffstats
path: root/Source/cmake.cxx
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2010-09-01 15:24:20 (GMT)
committerBen Boeckel <ben.boeckel@kitware.com>2010-09-01 17:09:08 (GMT)
commit74997000c89ee3a82d68e4107d4a4264e7e57229 (patch)
tree2551f29fd89495df47cec7bbded5efaa6e074239 /Source/cmake.cxx
parentfff9f6d6f74aa92d0bc4adf3a80a25b1b662458d (diff)
downloadCMake-74997000c89ee3a82d68e4107d4a4264e7e57229.zip
CMake-74997000c89ee3a82d68e4107d4a4264e7e57229.tar.gz
CMake-74997000c89ee3a82d68e4107d4a4264e7e57229.tar.bz2
Add a flag to warn about system files
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r--Source/cmake.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 93ca9e3..27bfbee 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -150,6 +150,7 @@ cmake::cmake()
this->WarnUninitialized = false;
this->WarnUnused = false;
this->WarnUnusedCli = true;
+ this->CheckSystemVars = false;
this->SuppressDevWarnings = false;
this->DoSuppressDevWarnings = false;
this->DebugOutput = false;
@@ -656,6 +657,11 @@ void cmake::SetArgs(const std::vector<std::string>& args)
std::cout << "Finding unused variables given on the command line.\n";
this->SetWarnUnusedCli(true);
}
+ else if(arg.find("--check-system-vars",0) == 0)
+ {
+ std::cout << "Also check system files when warning about unused and uninitialized variables.\n";
+ this->SetCheckSystemVars(true);
+ }
else if(arg.find("-G",0) == 0)
{
std::string value = arg.substr(2);