qbs: dylib - library not loaded, image not found
Unsolved
General and Desktop
-
I'm trying to build a qbs project using the leap motion library but on running the project am given the following error:
dyld: Library not loaded: @loader_path/libLeap.dylib Referenced from: /Users/pball/Work/Code/Qt/build-LeapTest-Desktop-Debug/qtc_Desktop_95cbad6a-debug/install-root/LeapTest Reason: image not found
My qbs file:
import qbs CppApplication { consoleApplication: true files: "main.cpp" Group { // Properties for the produced executable fileTagsFilter: product.type qbs.install: true } cpp.includePaths: [".","/Users/pball/LeapSDK/include"] cpp.libraryPaths: ["/Users/pball/LeapSDK/lib"] cpp.dynamicLibraries: "Leap" }
libLeap.dylib is in that location and I am able to work with the library when linking with qmake.
Using Qt 5.6.0
New to using qbs so any help / pointers greatly appreciated.
-
Hi and welcome to devnet,
You likely have to add
/Users/pball/LeapSDK/include
toQMAKE_RPATHDIR
.however I don't know how to do it with QBS, I haven't used it yet.