diff options
author | Christian Kandeler <christian.kandeler@qt.io> | 2017-07-13 12:00:18 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@qt.io> | 2018-03-14 08:52:50 +0000 |
commit | 149e20aca1e401ba18bbae602df2caa7dc68c493 (patch) | |
tree | 29b0b5a270696040b5b8c668834c2e6929ec621f /doc/reference | |
parent | d0f29502e0d4f3e21fbe0f0b7b56c62b4f85fde3 (diff) |
Provide rules with information about the content of Export items
The product variable gets a new property "exports" that provides
a "dependencies" array as well as property values the same way
that the product variable itself does, but for exported dependencies
and properties, respectively. In addition, meta data about these
properties is provided via a "properties" array, and structural
information can be retrieved via "childItems".
This data is intended to be used by modules creating interface
files from products.
Task-number: QBS-268
Change-Id: I2bb106e1ca1b18abbd6fe60411bc81bda9ee35e7
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'doc/reference')
-rw-r--r-- | doc/reference/items/language/export.qdoc | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/doc/reference/items/language/export.qdoc b/doc/reference/items/language/export.qdoc index b4b31ad1b..3c89117e9 100644 --- a/doc/reference/items/language/export.qdoc +++ b/doc/reference/items/language/export.qdoc @@ -67,3 +67,29 @@ the Export item. Use the \c{importingProduct} variable to refer to the product that pulls in the resulting module. */ + +/*! + \qmlproperty var Export::prefixMapping + + This property allows to provide a translation of exported values between non-deployed and + deployed contexts. It is an array of objects with properties \c prefix and \c replacement. + The array's elements get applied to all other properties set in this item such that if the + property's value start with \c prefix, that prefix gets replaced with \c replacement. + It is typically used for C/C++ include paths. For instance, in a library that provides + header files for inclusion both directly from its source directory (when building it + as part of a bigger project) and from some installed location (when building an unrelated + project against it), you would write something like the following: + \code + Export { + Depends { name: cpp" } + cpp.includePaths: [product.sourceDirectory] + prefixMapping: [{ + prefix: product.sourceDirectory, + replacement: FileInfo.joinPaths(qbs.installPrefix, "include") + }] + } + \endcode + + \defaultvalue \c undefined + \since 1.12 +*/ |