summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalUnixMakefileGenerator.cxx
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2002-11-14 01:14:05 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2002-11-14 01:14:05 (GMT)
commitb7b32566d21aab567d9e53c72c9f705fa553059d (patch)
tree74eb78fa91a85b9336f92d86571b123d72acff4a /Source/cmLocalUnixMakefileGenerator.cxx
parent26e05fc060810bd6dbf65e4a34992409244a2f8a (diff)
downloadCMake-b7b32566d21aab567d9e53c72c9f705fa553059d.zip
CMake-b7b32566d21aab567d9e53c72c9f705fa553059d.tar.gz
CMake-b7b32566d21aab567d9e53c72c9f705fa553059d.tar.bz2
add support for borland run time flag for shared builds
Diffstat (limited to 'Source/cmLocalUnixMakefileGenerator.cxx')
-rw-r--r--Source/cmLocalUnixMakefileGenerator.cxx18
1 files changed, 17 insertions, 1 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator.cxx b/Source/cmLocalUnixMakefileGenerator.cxx
index bb244f1..3c7eca1 100644
--- a/Source/cmLocalUnixMakefileGenerator.cxx
+++ b/Source/cmLocalUnixMakefileGenerator.cxx
@@ -939,14 +939,19 @@ void cmLocalUnixMakefileGenerator::OutputExecutableRule(std::ostream& fout,
linkFlags += this->GetSafeDefinition(build.c_str());
linkFlags += " ";
}
+
if(t.HasCxx())
{
rules.push_back(m_Makefile->GetDefinition("CMAKE_CXX_LINK_EXECUTABLE"));
flags += this->GetSafeDefinition("CMAKE_CXX_FLAGS");
flags += " ";
+ flags += this->GetSafeDefinition("CMAKE_SHARED_LIBRARY_CXX_FLAGS");
+ flags += " ";
}
else
{
+ flags += this->GetSafeDefinition("CMAKE_SHARED_LIBRARY_LINK_FLAGS");
+ flags += " ";
rules.push_back(m_Makefile->GetDefinition("CMAKE_C_LINK_EXECUTABLE"));
flags += this->GetSafeDefinition("CMAKE_C_FLAGS");
flags += " ";
@@ -962,6 +967,12 @@ void cmLocalUnixMakefileGenerator::OutputExecutableRule(std::ostream& fout,
{
commands.push_back(customCommands.c_str());
}
+ if(cmSystemTools::IsOn(m_Makefile->GetDefinition("BUILD_SHARED_LIBS")))
+ {
+ linkFlags += this->GetSafeDefinition("CMAKE_SHARED_BUILD_CXX_FLAGS");
+ linkFlags += " ";
+ }
+
if(t.GetType() == cmTarget::WIN32_EXECUTABLE)
{
linkFlags += this->GetSafeDefinition("CMAKE_CREATE_WIN32_EXE");
@@ -973,7 +984,7 @@ void cmLocalUnixMakefileGenerator::OutputExecutableRule(std::ostream& fout,
linkFlags += " ";
}
-
+
for(std::vector<std::string>::iterator i = commands.begin();
i != commands.end(); ++i)
{
@@ -2212,6 +2223,11 @@ OutputBuildObjectFromSource(std::ostream& fout,
}
case cmSystemTools::CXX_FILE_FORMAT:
{
+ if(cmSystemTools::IsOn(m_Makefile->GetDefinition("BUILD_SHARED_LIBS")))
+ {
+ flags += this->GetSafeDefinition("CMAKE_SHARED_BUILD_CXX_FLAGS");
+ flags += " ";
+ }
rules.push_back(m_Makefile->GetDefinition("CMAKE_CXX_COMPILE_OBJECT"));
flags += this->GetSafeDefinition("CMAKE_CXX_FLAGS");
flags += " ";