Rolf Eike Beer wrote: >> >> Hi, >> >> In KDE we set the LINK_INTERFACE_LIBRARIES to empty in a wrapper around >> add_library. The reason is to reduce the number of libraries which are >> linked to by default - developers have to be explicit about what is in >> the LINK_INTERFACE. >> >> I was considering patching CMake to do that by setting an option. >> >> http://thread.gmane.org/gmane.comp.kde.devel.buildsystem/6622/focus=72030 >> >> Would such a feature of making >> >> set(CMAKE_SET_LINK_INTERFACE_EMPTY ON) >> >> cause the LINK_INTERFACE to be empty for all shared library targets be >> accepted into CMake? > > I personally am all into this, as this basically makes the same as the > linker does when it gets passed --no-copy-dt-needed-entries --as-needed. > > I would call it a bit different to make more clear what this is all about, > something like CMAKE_NO_LINK_IMPLICIT_DEPENDENCIES. > > The "tricky" part of this is to tell CMake to not enforce the implicit > dependencies to be exported when creating an export file for targets > created with this property enabled. Or better: to not enforce _any_ > dependencies of a shared library to be exported then.
I don't think I understand your description of the tricky part or your suggested solution. Can you expand on it? > > Eike > -- > > 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 -- 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
