I would like to use the -rpath linker option to set the .so search path. I'd like it to search [app_path]/../lib
. I've tried add this to my qmake .pro
file:
QMAKE_LFLAGS += -Wl,-rpath=$ORIGIN/../lib/
But qmake links my project this way:
g++ -Wl,-rpath=RIGIN/../lib/ -Wl,-O1 -o myoutput main.o [...]
How can I escape the $ORIGIN
?