BUG: There was no dependency for library targets on their required libraries.
(Hopefully there aren't any cyclic dependencies for libraries.) CMAKE_SHLIB_LINK is now used for executable targets.
This commit is contained in:
parent
ff529aa861
commit
46aa1cb9c4
|
@ -440,9 +440,9 @@ void cmUnixMakefileGenerator::OutputTargets(std::ostream& fout)
|
||||||
fout << std::endl;
|
fout << std::endl;
|
||||||
|
|
||||||
fout << "lib" << l->first << "$(SHLIB_SUFFIX): ${" <<
|
fout << "lib" << l->first << "$(SHLIB_SUFFIX): ${" <<
|
||||||
l->first << "_SRC_OBJS} \n";
|
l->first << "_SRC_OBJS} ${CMAKE_DEPEND_LIBS}\n";
|
||||||
fout << "\trm -f lib" << l->first << "$(SHLIB_SUFFIX)\n";
|
fout << "\trm -f lib" << l->first << "$(SHLIB_SUFFIX)\n";
|
||||||
fout << "\t$(CMAKE_CXX_COMPILER) ${CMAKE_SHLIB_LINK_FLAGS} ${CMAKE_CXX_FLAGS} ${CMAKE_SHLIB_BUILD_FLAGS} -o \\\n";
|
fout << "\t$(CMAKE_CXX_COMPILER) ${CMAKE_SHLIB_LINK_FLAGS} ${CMAKE_SHLIB_BUILD_FLAGS} ${CMAKE_CXX_FLAGS} -o \\\n";
|
||||||
fout << "\t lib" << l->first << "$(SHLIB_SUFFIX) \\\n";
|
fout << "\t lib" << l->first << "$(SHLIB_SUFFIX) \\\n";
|
||||||
fout << "\t ${" << l->first <<
|
fout << "\t ${" << l->first <<
|
||||||
"_SRC_OBJS} ";
|
"_SRC_OBJS} ";
|
||||||
|
@ -454,7 +454,7 @@ void cmUnixMakefileGenerator::OutputTargets(std::ostream& fout)
|
||||||
{
|
{
|
||||||
fout << l->first << ": ${" <<
|
fout << l->first << ": ${" <<
|
||||||
l->first << "_SRC_OBJS} ${CMAKE_DEPEND_LIBS}\n";
|
l->first << "_SRC_OBJS} ${CMAKE_DEPEND_LIBS}\n";
|
||||||
fout << "\t${CMAKE_CXX_COMPILER} ${CMAKE_CXXFLAGS} ${" <<
|
fout << "\t${CMAKE_CXX_COMPILER} ${CMAKE_SHLIB_LINK_FLAGS} ${CMAKE_CXXFLAGS} ${" <<
|
||||||
l->first << "_SRC_OBJS} ";
|
l->first << "_SRC_OBJS} ";
|
||||||
this->OutputLinkLibraries(fout, NULL,l->second);
|
this->OutputLinkLibraries(fout, NULL,l->second);
|
||||||
fout << " -o " << l->first << "\n\n";
|
fout << " -o " << l->first << "\n\n";
|
||||||
|
|
Loading…
Reference in New Issue