diff options
author | Christian Kandeler <christian.kandeler@theqtcompany.com> | 2016-06-20 14:23:17 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@theqtcompany.com> | 2016-06-20 14:18:29 +0000 |
commit | 646ae60164d61d85d5773309fe956dde7d4b2909 (patch) | |
tree | 306f558d629edc5f1ebef676860c77fc13eb3625 /tests/auto/blackbox/testdata/system-run-paths | |
parent | 532e8ea991cf0dede72d3f357619f49f4b36187b (diff) |
Add new cpp property "systemRunPaths".
The concrete use case is to prevent such paths from getting into the
list of rpaths, which can mess with the look-up of libraries in the case
where we linked against a different version than the one provided by the
system.
[ChangeLog] Introduced property cpp.systemRunPaths.
Task-number: QBS-921
Change-Id: I67a17bbebca22bfadf0932ecc6cc0cfcffea310a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'tests/auto/blackbox/testdata/system-run-paths')
3 files changed, 31 insertions, 0 deletions
diff --git a/tests/auto/blackbox/testdata/system-run-paths/lib.cpp b/tests/auto/blackbox/testdata/system-run-paths/lib.cpp new file mode 100644 index 000000000..3d1c8528d --- /dev/null +++ b/tests/auto/blackbox/testdata/system-run-paths/lib.cpp @@ -0,0 +1 @@ +void func() { } diff --git a/tests/auto/blackbox/testdata/system-run-paths/main.cpp b/tests/auto/blackbox/testdata/system-run-paths/main.cpp new file mode 100644 index 000000000..ddd165d39 --- /dev/null +++ b/tests/auto/blackbox/testdata/system-run-paths/main.cpp @@ -0,0 +1,6 @@ +void func(); + +int main() +{ + func(); +} diff --git a/tests/auto/blackbox/testdata/system-run-paths/system-run-paths.qbs b/tests/auto/blackbox/testdata/system-run-paths/system-run-paths.qbs new file mode 100644 index 000000000..81778d6f7 --- /dev/null +++ b/tests/auto/blackbox/testdata/system-run-paths/system-run-paths.qbs @@ -0,0 +1,24 @@ +import qbs + +Project { + property bool setRunPaths + Product { + name: "theLib" + type: ["dynamiclibrary"] + Depends { name: "cpp" } + Group { + fileTagsFilter: product.type + qbs.install: true + qbs.installDir: "lib" + } + files: ["lib.cpp"] + } + + CppApplication { + name: "app" + Depends { name: "theLib" } + files: ["main.cpp"] + cpp.rpaths: qbs.installRoot + "/lib" + cpp.systemRunPaths: project.setRunPaths ? [qbs.installRoot + "/lib"] : [] + } +} |