summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalVisualStudio6Generator.cxx
diff options
context:
space:
mode:
authorKen Martin <ken.martin@kitware.com>2005-06-16 15:48:43 (GMT)
committerKen Martin <ken.martin@kitware.com>2005-06-16 15:48:43 (GMT)
commitfbf40e202a86c22868ce5394014606de331356c5 (patch)
tree60b862f32489ccc7b54beb4a9ed5f9467d77be29 /Source/cmLocalVisualStudio6Generator.cxx
parent0fa75654078f81b19ab7bcee9ecc6642a13dcabb (diff)
downloadCMake-fbf40e202a86c22868ce5394014606de331356c5.zip
CMake-fbf40e202a86c22868ce5394014606de331356c5.tar.gz
CMake-fbf40e202a86c22868ce5394014606de331356c5.tar.bz2
ENH: add first cut at support for exe with same name as lib
Diffstat (limited to 'Source/cmLocalVisualStudio6Generator.cxx')
-rw-r--r--Source/cmLocalVisualStudio6Generator.cxx19
1 files changed, 15 insertions, 4 deletions
diff --git a/Source/cmLocalVisualStudio6Generator.cxx b/Source/cmLocalVisualStudio6Generator.cxx
index f463717..dfb1ca5 100644
--- a/Source/cmLocalVisualStudio6Generator.cxx
+++ b/Source/cmLocalVisualStudio6Generator.cxx
@@ -739,9 +739,11 @@ inline std::string removeQuotes(const std::string& s)
}
-void cmLocalVisualStudio6Generator::WriteDSPHeader(std::ostream& fout, const char *libName,
- const cmTarget &target,
- std::vector<cmSourceGroup> &)
+void cmLocalVisualStudio6Generator
+::WriteDSPHeader(std::ostream& fout,
+ const char *libName,
+ const cmTarget &target,
+ std::vector<cmSourceGroup> &)
{
std::set<std::string> pathEmitted;
@@ -948,7 +950,16 @@ void cmLocalVisualStudio6Generator::WriteDSPHeader(std::ostream& fout, const cha
std::string extraLinkOptions;
if(target.GetType() == cmTarget::EXECUTABLE)
{
- extraLinkOptions = m_Makefile->GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS");
+ extraLinkOptions =
+ m_Makefile->GetRequiredDefinition("CMAKE_EXE_LINKER_FLAGS");
+
+ // if the executable has an output name then add the appropriate flag
+ if (target.GetProperty("OUTPUT_NAME"))
+ {
+ libMultiLineOptions += "# ADD LINK32 /out:";
+ libMultiLineOptions += target.GetProperty("OUTPUT_NAME");
+ libMultiLineOptions += " \n";
+ }
}
if(target.GetType() == cmTarget::SHARED_LIBRARY)
{