aboutsummaryrefslogtreecommitdiffstats
path: root/qbs/imports
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@theqtcompany.com>2016-06-10 17:51:22 +0200
committerChristian Kandeler <christian.kandeler@theqtcompany.com>2016-06-15 12:35:55 +0000
commite1e203598dd876337e7c91e1d4da87f7dab7acf0 (patch)
treebb56bb035a00d0943ccbf28920bda7ac5597c77f /qbs/imports
parent96a3d49b07fa0119d11ed4f76d9f1fd5e86686ef (diff)
qbs build: Final steps to support building plugins "out of source".
- Use the entire Export block when creating a module, not just the Depends items. Adapt references to the product source directory and the "share" directory so that they point to the respective locations in the install tree. - Install dev headers for some more plugins. - Bug fixes & polishing. Create a "dev installation" like this: $ qbs qtc.make_dev_package:true qbs.installRoot:<install root> Then build your plugin against it like this: $ qbs qtc.make_dev_package:true qbs.installRoot:<install root> project.qbsSearchPaths:<install root>/qbs-resources (Using qbs from 1.5 branch; 1.5.1 requires a trivial wrapper project.) That's all. Successfully tested with all commercial plugins on Linux. Change-Id: Ie39c4717dafcd431c533421a15f2f898783d8521 Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Diffstat (limited to 'qbs/imports')
-rw-r--r--qbs/imports/QtcDevHeaders.qbs4
-rw-r--r--qbs/imports/QtcProduct.qbs2
2 files changed, 5 insertions, 1 deletions
diff --git a/qbs/imports/QtcDevHeaders.qbs b/qbs/imports/QtcDevHeaders.qbs
index 3ca4730834..819983f27d 100644
--- a/qbs/imports/QtcDevHeaders.qbs
+++ b/qbs/imports/QtcDevHeaders.qbs
@@ -3,13 +3,15 @@ import qbs.FileInfo
Product {
property string productName: project.name
+ property string baseDir: sourceDirectory
name: productName + " dev headers"
condition: qtc.make_dev_package
Depends { name: "qtc" }
Group {
+ prefix: baseDir + '/'
files: ["**/*.h"]
qbs.install: true
qbs.installDir: qtc.ide_include_path + '/' + FileInfo.fileName(product.sourceDirectory)
- qbs.installSourceBase: product.sourceDirectory
+ qbs.installSourceBase: baseDir
}
}
diff --git a/qbs/imports/QtcProduct.qbs b/qbs/imports/QtcProduct.qbs
index 0e17a4145f..3c789ed3de 100644
--- a/qbs/imports/QtcProduct.qbs
+++ b/qbs/imports/QtcProduct.qbs
@@ -1,4 +1,5 @@
import qbs 1.0
+import qbs.FileInfo
import QtcFunctions
Product {
@@ -7,6 +8,7 @@ Product {
property bool install: true
property string installDir
property stringList installTags: type
+ property string fileName: FileInfo.fileName(sourceDirectory) + ".qbs"
Depends { name: "cpp" }
Depends { name: "qtc" }