summaryrefslogtreecommitdiffstats
path: root/Source/cmVisualStudioGeneratorOptions.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-02-15 15:36:56 (GMT)
committerBrad King <brad.king@kitware.com>2017-02-15 15:37:35 (GMT)
commitbd5ea6993c8376cd3612100019e15ee256a758d8 (patch)
tree795225931be425048c759a78f5b6e4eaf1fb7d9e /Source/cmVisualStudioGeneratorOptions.cxx
parent3936a2886efc1fd46560352f3a48d6a656f95367 (diff)
downloadCMake-bd5ea6993c8376cd3612100019e15ee256a758d8.zip
CMake-bd5ea6993c8376cd3612100019e15ee256a758d8.tar.gz
CMake-bd5ea6993c8376cd3612100019e15ee256a758d8.tar.bz2
cmVisualStudioGeneratorOptions: Add PrependInerhitedString method
Diffstat (limited to 'Source/cmVisualStudioGeneratorOptions.cxx')
-rw-r--r--Source/cmVisualStudioGeneratorOptions.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/cmVisualStudioGeneratorOptions.cxx b/Source/cmVisualStudioGeneratorOptions.cxx
index 6bacfa1..f8de3f8 100644
--- a/Source/cmVisualStudioGeneratorOptions.cxx
+++ b/Source/cmVisualStudioGeneratorOptions.cxx
@@ -211,6 +211,17 @@ void cmVisualStudioGeneratorOptions::ParseFinish()
}
}
+void cmVisualStudioGeneratorOptions::PrependInheritedString(
+ std::string const& key)
+{
+ std::map<std::string, FlagValue>::iterator i = this->FlagMap.find(key);
+ if (i == this->FlagMap.end() || i->second.size() != 1) {
+ return;
+ }
+ std::string& value = i->second[0];
+ value = "%(" + key + ") " + value;
+}
+
void cmVisualStudioGeneratorOptions::StoreUnknownFlag(const char* flag)
{
// Look for Intel Fortran flags that do not map well in the flag table.