diff options
author | Brad King <brad.king@kitware.com> | 2009-09-29 20:39:07 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2009-09-29 20:39:07 (GMT) |
commit | 024d05adada5b9deaac84f0f4df8beed273c972a (patch) | |
tree | 7e217bb3e29c8dd9f230dd5dc7f290e9e8b1dec6 /Source/cmVisualStudio10TargetGenerator.cxx | |
parent | caee3af3c5625d1a181c90efdff6fb599f21f699 (diff) | |
download | CMake-024d05adada5b9deaac84f0f4df8beed273c972a.zip CMake-024d05adada5b9deaac84f0f4df8beed273c972a.tar.gz CMake-024d05adada5b9deaac84f0f4df8beed273c972a.tar.bz2 |
Fix use of module .def files for MS tools
We recognize .def source files and map them to the /DEF:<file> option in
the MSVC tools. Previously this worked only for shared libraries. This
commit cleans up the implementation and makes it work for executables
too. See issue #9613.
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r-- | Source/cmVisualStudio10TargetGenerator.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index b7991b6..e7a8784 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -1125,6 +1125,11 @@ void cmVisualStudio10TargetGenerator::WriteLinkOptions(std::string const& linkOptions.AddFlag("ImportLibrary", imLib.c_str()); linkOptions.AddFlag("ProgramDataBaseFileName", pdb.c_str()); linkOptions.Parse(flags.c_str()); + if(!this->ModuleDefinitionFile.empty()) + { + linkOptions.AddFlag("ModuleDefinitionFile", + this->ModuleDefinitionFile.c_str()); + } linkOptions.OutputAdditionalOptions(*this->BuildFileStream, " ", ""); linkOptions.OutputFlagMap(*this->BuildFileStream, " "); |