From 83562bf402e6b2cfca5dfc5aef655d3507ee5da1 Mon Sep 17 00:00:00 2001 From: skyjake Date: Fri, 30 Mar 2012 11:17:19 +0300 Subject: [PATCH] Unix|qmake: Tell linker where to find shared libraries When installing with a non-standard prefix, tell the dynamic linker where the Doomsday shared libraries can be found. Currently any library path that doesn't start with "/usr/" is considered non-standard. --- doomsday/config_unix.pri | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/doomsday/config_unix.pri b/doomsday/config_unix.pri index 398722fabd..2b1a74b621 100644 --- a/doomsday/config_unix.pri +++ b/doomsday/config_unix.pri @@ -40,6 +40,12 @@ contains(QMAKE_HOST.arch, x86_64) { } } +# When installing libraries to a non-standard location, instruct +# the linker where to find them. +!contains(DENG_LIB_DIR, ^/usr/.*) { + QMAKE_LFLAGS += -Wl,-rpath,$$DENG_LIB_DIR +} + DENG_BASE_DIR = $$PREFIX/share/doomsday DENG_DATA_DIR = $$DENG_BASE_DIR/data