summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalVisualStudio7Generator.cxx
diff options
context:
space:
mode:
authorDavid Cole <david.cole@kitware.com>2011-01-25 23:54:36 (GMT)
committerDavid Cole <david.cole@kitware.com>2011-01-26 00:01:13 (GMT)
commit662756036e4f4983b00ab7740773a55bef808c64 (patch)
tree187ec92cf99e4c04efa440539b4aa316b7180153 /Source/cmLocalVisualStudio7Generator.cxx
parent0cde56dda4b93a8a51196dbd8c26fdf530a70968 (diff)
downloadCMake-662756036e4f4983b00ab7740773a55bef808c64.zip
CMake-662756036e4f4983b00ab7740773a55bef808c64.tar.gz
CMake-662756036e4f4983b00ab7740773a55bef808c64.tar.bz2
VS10: Escape double quote chars in defines for rc files (#11695)
To get rc defines to work in the VS10 IDE requires \" when constructing PreprocessorDefinitions strings. This is different than defines for cl. Also, per-file rc defines were not being generated. Fix that, too.
Diffstat (limited to 'Source/cmLocalVisualStudio7Generator.cxx')
-rw-r--r--Source/cmLocalVisualStudio7Generator.cxx8
1 files changed, 5 insertions, 3 deletions
diff --git a/Source/cmLocalVisualStudio7Generator.cxx b/Source/cmLocalVisualStudio7Generator.cxx
index 21f6460..7d36153 100644
--- a/Source/cmLocalVisualStudio7Generator.cxx
+++ b/Source/cmLocalVisualStudio7Generator.cxx
@@ -755,7 +755,7 @@ void cmLocalVisualStudio7Generator::WriteConfiguration(std::ostream& fout,
}
fout << "\"\n";
targetOptions.OutputFlagMap(fout, "\t\t\t\t");
- targetOptions.OutputPreprocessorDefinitions(fout, "\t\t\t\t", "\n");
+ targetOptions.OutputPreprocessorDefinitions(fout, "\t\t\t\t", "\n", "CXX");
fout << "\t\t\t\tAssemblerListingLocation=\"" << configName << "\"\n";
fout << "\t\t\t\tObjectFile=\"$(IntDir)\\\"\n";
if(targetBuilds)
@@ -789,7 +789,7 @@ void cmLocalVisualStudio7Generator::WriteConfiguration(std::ostream& fout,
}
// add the -D flags to the RC tool
fout << "\"";
- targetOptions.OutputPreprocessorDefinitions(fout, "\n\t\t\t\t", "");
+ targetOptions.OutputPreprocessorDefinitions(fout, "\n\t\t\t\t", "", "RC");
fout << "/>\n";
tool = "VCMIDLTool";
if(this->FortranProject)
@@ -1462,6 +1462,7 @@ void cmLocalVisualStudio7Generator
else if(!fcinfo.FileConfigMap.empty())
{
const char* aCompilerTool = "VCCLCompilerTool";
+ const char* lang = "CXX";
if(this->FortranProject)
{
aCompilerTool = "VFFortranCompilerTool";
@@ -1479,6 +1480,7 @@ void cmLocalVisualStudio7Generator
if(ext == "rc")
{
aCompilerTool = "VCResourceCompilerTool";
+ lang = "RC";
if(this->FortranProject)
{
aCompilerTool = "VFResourceCompilerTool";
@@ -1520,7 +1522,7 @@ void cmLocalVisualStudio7Generator
fileOptions.OutputAdditionalOptions(fout, "\t\t\t\t\t", "\n");
fileOptions.OutputFlagMap(fout, "\t\t\t\t\t");
fileOptions.OutputPreprocessorDefinitions(fout,
- "\t\t\t\t\t", "\n");
+ "\t\t\t\t\t", "\n", lang);
}
if(!fc.AdditionalDeps.empty())
{