[CMake] cmake end user vs. developer rpath handling

Hendrik Sattler post at hendrik-sattler.de
Wed Oct 9 15:36:21 EDT 2019



Am 9. Oktober 2019 08:09:19 MESZ schrieb "Zakrzewski, Jakub" 
>That "something" seems to be line 257:
>set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/${LIB_INSTALL_DIR}")

IMHO setting this to something based on CMAKE_INSTALL_PREFIX is rarely a good idea if it can be relative to the runtime path of the executable. The above makes the program not relocatable even though that's easily possible on many systems.

HS



More information about the CMake mailing list