[CMake] What is a good way to exclude default library locations from install-tree rpaths?
Alexander Neundorf
a.neundorf-work at gmx.net
Wed Feb 3 15:47:34 EST 2010
On Tuesday 02 February 2010, Alan W. Irwin wrote:
...
> So to summarize this, I plan to filter all the many INSTALL_RPATH target
> properties I set in various parts of our build system for our applications
> and libraries using the CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES variable,
> but a much cleaner way to do this would be if CMake itself automatically
> filtered INSTALL_RPATH. Therefore, I hope that CMake fix is implemented.
> (I assume here you always want to filter out the standard locations from
> rpath for the installed applications and libraries. This is the assumption
> CMake appears to make for the build-tree versions of those applications and
> libraries.)
>
> Is that a trivial fix or do you want me to make a wish-list bug so the idea
> doesn't get lost?
Wish-list bug.
But before you do that, I would suggest that you try to use
INSTALL_RPATH_USE_LINK_PATH. This will add all RPATHs which are in the build
tree RPATH. If you know which directories you need additionally to that, you
can add those using the INSTALL_RPATH property.
That's what we use in KDE (adding ${LIB_INSTALL_DIR} via INSTALL_RPATH) and I
didn't hear any issues with this since a long time.
Alex
More information about the CMake
mailing list