Skip to content

Commit

Permalink
Fix deployment of dynamically-built binaries on Linux
Browse files Browse the repository at this point in the history
Set the rpath.
  • Loading branch information
mitchcurtis committed Apr 4, 2019
1 parent ab3112e commit 4bede2b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions app/app.qbs
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,12 @@ QtGuiApplication {
// Additional import path used to resolve QML modules in Qt Creator's code model
property pathList qmlImportPaths: []

cpp.useRPaths: qbs.targetOS.contains("darwin")
cpp.rpaths: ["@loader_path/../Frameworks"]
readonly property bool darwin: qbs.targetOS.contains("darwin")
readonly property bool unix: qbs.targetOS.contains("unix")

cpp.useRPaths: darwin || (unix && !Qt.core.staticBuild)
// Ensure that e.g. libslate is found.
cpp.rpaths: darwin ? ["@loader_path/../Frameworks"] : ["$ORIGIN/lib"]

cpp.cxxLanguageVersion: "c++11"

Expand Down

0 comments on commit 4bede2b

Please sign in to comment.