[Cmake] CMAKE_SKIP_RPATH use

Amitha Perera perera at cs.rpi.edu
Mon Oct 14 11:35:46 EDT 2002


"David Mellor" <david at paracom.demon.co.uk> writes:
> Thanks for this. I've tried doing a SET(CMAKE_SKIP_RPATH) in the root
> CMakeLists.txt  and in the CMakeLists.txt that is compiling the application.
> They don't seem to make any difference though. strings -a application
> still shows the library paths embedded in my app.

I believe you need to edit the CMakeCache.txt directly, either via an
editor or the CMake GUI. You cannot do it from within your
CMakeLists.txt file. In general, values stored in the cache cannot be
overridden by CMakeLists.txt. (Otherwise, you'd lose your changes all
the time!)

Also, make sure you delete and re-link your libraries. (Not necessary
the .o files.) The CMAKE_SKIP_RPATH option changes the makefile
options, but does not cause the libraries to be re-linked.

Hope this helps.

Amitha.



More information about the CMake mailing list