Browse Source

BUG: When building a C executable, we should add CMAKE_SHARED_LIBRARY_C_FLAGS, not CMAKE_SHARED_LIBRARY_LINK_FLAGS. The latter is already added by the link line procedure.

Brad King 22 years ago
parent
commit
1a1be82532
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Source/cmLocalUnixMakefileGenerator.cxx

+ 2 - 2
Source/cmLocalUnixMakefileGenerator.cxx

@@ -1061,11 +1061,11 @@ void cmLocalUnixMakefileGenerator::OutputExecutableRule(std::ostream& fout,
     }
   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 += " ";
+    flags += this->GetSafeDefinition("CMAKE_SHARED_LIBRARY_C_FLAGS");
+    flags += " ";
     }
   cmOStringStream linklibs;
   this->OutputLinkLibraries(linklibs, 0, t);