summaryrefslogtreecommitdiff
path: root/qbs-resources/imports
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@qt.io>2018-03-06 10:47:29 +0100
committerChristian Kandeler <christian.kandeler@qt.io>2018-06-04 13:03:13 +0000
commitb3e1e3e3b307e60924dcf3cf308488a362de88f0 (patch)
treecd0ee0824eba2693198681ee587b691ee5e28e50 /qbs-resources/imports
parent400d9e1d66aacb2760b2190a5f10cfc3d5d359d2 (diff)
downloadqbs-b3e1e3e3b307e60924dcf3cf308488a362de88f0.tar.gz
Add module Exporter.pkgconfig
This module generates .pc files for products, optionally attempting to derive some of the entries from the contents of the Export item. [ChangeLog] Added new module "Exporter.pkgconfig" for creating pkg- config metadata files. Task-number: QBS-1232 Change-Id: Ic41e645e4462e8f85ad6c2025fb967e88d3438f9 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'qbs-resources/imports')
-rw-r--r--qbs-resources/imports/QbsLibrary.qbs9
1 files changed, 9 insertions, 0 deletions
diff --git a/qbs-resources/imports/QbsLibrary.qbs b/qbs-resources/imports/QbsLibrary.qbs
index f8bc70580..69e107871 100644
--- a/qbs-resources/imports/QbsLibrary.qbs
+++ b/qbs-resources/imports/QbsLibrary.qbs
@@ -19,10 +19,14 @@ QbsProduct {
property string visibilityType: staticBuild ? "static" : "dynamic"
property string headerInstallPrefix: "/include/qbs"
property bool hasExporter: Utilities.versionCompare(qbs.version, "1.12") >= 0
+ property bool generatePkgConfigFile: qbsbuildconfig.generatePkgConfigFiles && hasExporter
property bool generateQbsModule: install && qbsbuildconfig.generateQbsModules && hasExporter
property bool staticBuild: Qt.core.staticBuild || qbsbuildconfig.staticBuild
property stringList libType: [staticBuild ? "staticlibrary" : "dynamiclibrary"]
+
+ Depends { name: "Exporter.pkgconfig"; condition: generatePkgConfigFile }
Depends { name: "Exporter.qbs"; condition: generateQbsModule }
+
Group {
fileTagsFilter: libType.concat("dynamiclibrary_symlink")
.concat(qbs.buildVariant === "debug" ? ["debuginfo_dll"] : [])
@@ -37,6 +41,11 @@ QbsProduct {
qbs.installDir: qbsbuildconfig.importLibInstallDir
}
Group {
+ fileTagsFilter: "Exporter.pkgconfig.pc"
+ qbs.install: install
+ qbs.installDir: qbsbuildconfig.pkgConfigInstallDir
+ }
+ Group {
fileTagsFilter: "Exporter.qbs.module"
qbs.install: install
qbs.installDir: FileInfo.joinPaths(qbsbuildconfig.qbsModulesBaseDir, product.name)