On 01/20/2015 12:57 PM, Tom Kacvinsky wrote: > there are some static archives we build that depend on a third party > static archive (one we don't build - it comes with the Ada compiler > we are using), yet the third part archive is on the link line (as > given by the link.txt file) *before* the static archives we build.
If you have a library add_library(mylib STATIC mylib.c) and it depends on a third-party library then tell CMake so: target_link_libraries(mylib otherlib) Then CMake will guarantee that an occurrence of otherlib appears on the link line after mylib. > duplicated shared libraries These generally don't hurt anything. CMake 3.1 will de-duplicate shared libraries that come from logical targets (created via add_library either as a build target or as an imported library). > Can anyone point me in the right direction? FYI, the ordering algorithm is documented in source comments here: http://www.cmake.org/gitweb?p=cmake.git;a=blob;f=Source/cmComputeLinkDepends.cxx;hb=v3.1.0#l25 -Brad -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
