-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
help wantedExtra attention is neededExtra attention is needed
Description
If we have a library foo
that is built as a static library, then if you try to install it with install(EXPORT)
then it fails unless all its dependencies are also installed, even when the target_link_libraries
is PRIVATE
. The same does not occur if foo
is a shared library or an executable.
- Why does this occur?
Posibility:the symbols inlibfoo.a
contain only the ones that it built for itself and not that of the dependencies, so in order to consumelibfoo.a
you would need it to consume its dependencies as well?
(Confirmed in: https://github.com/LecrisUT/cmake_install_static_issue)
- Should installation of static libraries be supported? How to install the dependencies as well?
- How to limit the installation of
PRIVATE
linked dependencies to not install header files, Config.cmake, etc. - Investigate
BUILD_LOCAL_INTERFACE
:
Metadata
Metadata
Assignees
Labels
help wantedExtra attention is neededExtra attention is needed