Re: [cmake-developers] Why does this work - linking against a library before it has been defined ?
On 07/11/2013 03:52 PM, Alexander Neundorf wrote: target_link_libraries(kf5-config ${KDE4_KDECORE_LIBS} kde4support) add_subdirectory(lib) The thing is, the library kde4support is built inside the lib subdirectory, which is added after using kde4support in target_link_libraries(). I think in previous version of cmake the kde4support in the tll() call would have been recognized as the name of a library and added to the link command using -lkde4support. Now it seems to be recognized as the name of a target. This has always been the case. Link analysis has always been done at generate time. -Brad -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
Re: [cmake-developers] Why does this work - linking against a library before it has been defined ?
Alexander Neundorf wrote: Hi, I was surprised today, something worked which I expected to fail: Can you say which version of cmake this did fail with? Note that it is more likely to *compile* since 2.8.11 because includes and defines are part of the target interface, but linking should be unchanged. Thanks, Steve. -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers