diff options
Diffstat (limited to 'doc/reference')
-rw-r--r-- | doc/reference/cli/cli-options.qdocinc | 1 | ||||
-rw-r--r-- | doc/reference/items/probe/sdcc-probe.qdoc | 93 | ||||
-rw-r--r-- | doc/reference/modules/android-ndk-module.qdoc | 15 | ||||
-rw-r--r-- | doc/reference/modules/android-sdk-module.qdoc | 40 | ||||
-rw-r--r-- | doc/reference/modules/protobufcpp-module.qdoc | 19 | ||||
-rw-r--r-- | doc/reference/modules/qbs-module.qdoc | 139 | ||||
-rw-r--r-- | doc/reference/modules/qt-android_support-module.qdoc | 9 |
7 files changed, 275 insertions, 41 deletions
diff --git a/doc/reference/cli/cli-options.qdocinc b/doc/reference/cli/cli-options.qdocinc index 2d35bea61..d4c3280a2 100644 --- a/doc/reference/cli/cli-options.qdocinc +++ b/doc/reference/cli/cli-options.qdocinc @@ -496,6 +496,7 @@ \li \c msvc \li \c iar \li \c keil + \li \c sdcc \endlist //! [type] diff --git a/doc/reference/items/probe/sdcc-probe.qdoc b/doc/reference/items/probe/sdcc-probe.qdoc new file mode 100644 index 000000000..1353eb736 --- /dev/null +++ b/doc/reference/items/probe/sdcc-probe.qdoc @@ -0,0 +1,93 @@ +/**************************************************************************** +** +** Copyright (C) 2019 Denis Shienkov <denis.shienkov@gmail.com> +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qbs. +** +** $QT_BEGIN_LICENSE:FDL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU Free Documentation License Usage +** Alternatively, this file may be used under the terms of the GNU Free +** Documentation License version 1.3 as published by the Free Software +** Foundation and appearing in the file included in the packaging of +** this file. Please review the following information to ensure +** the GNU Free Documentation License version 1.3 requirements +** will be met: https://www.gnu.org/licenses/fdl-1.3.html. +** $QT_END_LICENSE$ +** +****************************************************************************/ +/*! + \contentspage list-of-probes.html + \qmltype SdccProbe + \ingroup list-of-probes + \ingroup list-of-items + \keyword QML.SdccProbe + \inherits PathProbe + \brief Collects SDCC toolchain compiler information. + \since Qbs 1.14 + \internal + + Detects the version, supported architecture and the platform + endianness of the specified compiler executable file from the + \l{http://sdcc.sourceforge.net/}{SDCC} toolchain. +*/ + +/*! + \qmlproperty string SdccProbe::compilerFilePath + + An input property which is a full path to the SDCC compiler executable file. + + \nodefaultvalue +*/ + +/*! + \qmlproperty string SdccProbe::architecture + + Detected architecture of the target platform's processor. + + The possible values are \c "mcs51". + + \nodefaultvalue +*/ + +/*! + \qmlproperty string SdccProbe::endianness + + Detected endianness of the target platform's processor architecture. + + The possible values are \c "little". + + \nodefaultvalue +*/ + +/*! + \qmlproperty int SdccProbe::versionMajor + + Detected major compiler version. + + \nodefaultvalue +*/ + +/*! + \qmlproperty int SdccProbe::versionMinor + + Detected minor compiler version. + + \nodefaultvalue +*/ + +/*! + \qmlproperty int SdccProbe::versionPatch + + Detected patch compiler version. + + \nodefaultvalue +*/ diff --git a/doc/reference/modules/android-ndk-module.qdoc b/doc/reference/modules/android-ndk-module.qdoc index 8113a7c68..e3a7ca22d 100644 --- a/doc/reference/modules/android-ndk-module.qdoc +++ b/doc/reference/modules/android-ndk-module.qdoc @@ -47,7 +47,7 @@ CppApplication { name: "HelloJni" Android.sdk.packageName: "com.example.hellojni" - qbs.architectures: ["mips", "x86"] + qbs.architectures: ["arm", "x86"] files: "app/src/main/jni/hello-jni.c" } \endcode @@ -86,16 +86,9 @@ \list \li \c "c++_shared" \li \c "c++_static" - \li \c "gabi++_shared" (until r17) - \li \c "gabi++_static" (until r17) - \li \c "gnustl_shared" (until r17) - \li \c "gnustl_static" (until r17) - \li \c "stlport_shared" (until r17) - \li \c "stlport_static" (until r17) - \li \c "system" \endlist - \defaultvalue \c{"system"} + \defaultvalue \c{"c++_shared"} */ /*! @@ -111,5 +104,7 @@ The versioned platform name. - \defaultvalue \c{"android-9"} + \defaultvalue \c{"android-16"} for 32 bit arm ABIs + and \c{"android-21"} for all 64 bit ABIs and x86. + x86 ABI has broken wstring support in android-16 to android-19. */ diff --git a/doc/reference/modules/android-sdk-module.qdoc b/doc/reference/modules/android-sdk-module.qdoc index a9e06ae17..7733ae75d 100644 --- a/doc/reference/modules/android-sdk-module.qdoc +++ b/doc/reference/modules/android-sdk-module.qdoc @@ -161,6 +161,46 @@ */ /*! + \qmlproperty string Android.sdk::versionCode + + The Android Manifest version code of the respective product. The \c android:versionCode + attribute in the manifest file will be set to this value if not undefined. + + In the following example we provide an architecture-specific value + for \c android:versionCode: + + \code + // ... + property int _version: 1 + property int _patchVersion: 0 + Android.sdk.versionCode: { + switch (Android.ndk.abi) { + case "armeabi-v7a": + return 132000000 | _version * 10 + _patchVersion; + case "arm64-v8a": + return 164000000 | _version * 10 + _patchVersion; + case "x86": + return 232000000 | _version * 10 + _patchVersion; + case "x86_64": + return 264000000 | _version * 10 + _patchVersion; + } + throw "Unknown architecture"; + } + \endcode + + \defaultvalue \c undefined +*/ + +/*! + \qmlproperty string Android.sdk::versionName + + The Android Manifest version name of the respective product. The \c android:versionName + attribute in the manifest file will be set to this value if not undefined. + + \defaultvalue \c undefined +*/ + +/*! \qmlproperty string Android.sdk::resourcesDir The base directory for Android resources in the respective product. diff --git a/doc/reference/modules/protobufcpp-module.qdoc b/doc/reference/modules/protobufcpp-module.qdoc index 688f1d9e2..63c56c6ca 100644 --- a/doc/reference/modules/protobufcpp-module.qdoc +++ b/doc/reference/modules/protobufcpp-module.qdoc @@ -36,6 +36,25 @@ The \c protobuf.cpp module provides support for generating C++ headers and sources from proto definition files using the \l protoc tool. + A simple qbs file that uses protobuf can be written as follows: + \code + CppApplication { + Depends { name: "protobuf.cpp" } + files: ["foo.proto", "main.cpp"] + } + \endcode + A generated header now can be included in the C++ sources: + \code + #include <foo.pb.h> + + int main(int argc, char* argv[]) { + Foo bar; + bar.set_answer(42); + google::protobuf::ShutdownProtobufLibrary(); + return 0; + } + \endcode + \section2 Relevant File Tags \table diff --git a/doc/reference/modules/qbs-module.qdoc b/doc/reference/modules/qbs-module.qdoc index eea67688b..5d93aff4a 100644 --- a/doc/reference/modules/qbs-module.qdoc +++ b/doc/reference/modules/qbs-module.qdoc @@ -182,59 +182,93 @@ where the target OS is always known (such as an Apple Watch app written in native code). - You should generally treat this property as \e{write-only} and avoid using - it to test for the current target OS. Instead, use the \l{qbs::}{targetOS} - property for conditionals. For example, instead of: - + For example, a profile used for building for the iOS Simulator platform will have this + property set to the \c ios-simulator value: \code - qbs.targetPlatform === "macos" || qbs.targetPlatform === "ios" || qbs.targetPlatform === "tvos" || qbs.targetPlatform === "watchos" + profiles.xcode-iphonesimulator.qbs.targetPlatform: "ios-simulator" \endcode - use - - \code - qbs.targetOS.contains("darwin") - - \endcode - - However, in some cases using \c targetPlatform would be acceptable, such as - when the resulting condition would be simpler while still being correct: - - \code - qbs.targetPlatform === "linux" - \endcode - - versus - \code - qbs.targetOS.contains("linux") && !qbs.targetOS.contains("android") - \endcode + You should generally treat this property as \e{write-only} and avoid using + it to test for the current target OS. Instead, use the \l{qbs::}{targetOS} + property for conditionals. - The possible values include one or more of the following: + \section2 Relation between targetPlatform and targetOS - \list + This table describes the possible values and matching between the \c targetPlatform + and the \l{qbs::}{targetOS} properties: + \table + \header + \li Target Platform + \li Target OS + \row \li \c{"aix"} + \li \c{["aix", "unix"]} + \row \li \c{"android"} + \li \c{["android", "linux", "unix"]} + \row \li \c{"freebsd"} + \li \c{["freebsd", "bsd", "unix"]} + \row \li \c{"haiku"} + \li \c{["haiku"]} + \row \li \c{"hpux"} + \li \c{["hpux", "unix"]} + \row \li \c{"hurd"} + \li \c{["hurd", "unix"]} + \row \li \c{"integrity"} + \li \c{["integrity", "unix"]} + \row \li \c{"ios"} + \li \c{["ios", "darwin", "bsd", "unix"]} + \row \li \c{"ios-simulator"} + \li \c{["ios-simulator", "ios", "darwin", "bsd", "unix"]} + \row \li \c{"linux"} + \li \c{["linux", "unix"]} + \row \li \c{"lynx"} + \li \c{["lynx"]} + \row \li \c{"macos"} + \li \c{["macos", "darwin", "bsd", "unix"]} + \row \li \c{"netbsd"} + \li \c{["netbsd", "bsd", "unix"]} + \row \li \c{"openbsd"} + \li \c{["openbsd", "bsd", "unix"]} + \row \li \c{"qnx"} + \li \c{["qnx", "unix"]} + \row \li \c{"solaris"} + \li \c{["solaris", "unix"]} + \row \li \c{"tvos"} + \li \c{["tvos", "darwin", "bsd", "unix"]} + \row \li \c{"tvos-simulator"} + \li \c{["tvos-simulator", "tvos", "darwin", "bsd", "unix"]} + \row \li \c{"vxworks"} + \li \c{["vxworks"]} + \row \li \c{"watchos"} + \li \c{["watchos", "darwin", "bsd", "unix"]} + \row \li \c{"watchos-simulator"} + \li \c{["watchos-simulator", "watchos", "darwin", "bsd", "unix"]} + \row \li \c{"windows"} - \endlist + \li \c{["windows"]} + \endtable + + \sa {Target Platforms} \nodefaultvalue */ @@ -433,14 +467,57 @@ /*! \qmlproperty stringList qbs::targetOS + \readonly + + Contains the list of string values describing the OS and OS family that is + used to build a project. - Specifies the OS you want to build the project for. + This property is calculated based on the \l{qbs::}{targetPlatform} property and is typically + used to test for a particular OS or OS family in conditionals: + \code + Group { + // Includes all Unix-like platforms, such as: Linux, BSD, Apple platforms and others. + condition: qbs.targetOS.contains("unix") + files: ... + } + Group { + // Includes all Apple platforms, such as macOS, iOS, and iOS Simulator. + condition: qbs.targetOS.contains("darwin") + files: ... + } + Group { + // Includes only macOS + condition: qbs.targetOS.contains("macos") + files: ... + } + \endcode + Avoid using \l{qbs::}{targetPlatform} for this purpose. For example, instead of: - Use this property to test for a particular OS or OS family in conditionals. - Do not use \l{qbs::}{targetPlatform} for this purpose. + \code + qbs.targetPlatform === "macos" || qbs.targetPlatform === "ios" || qbs.targetPlatform === "tvos" || qbs.targetPlatform === "watchos" + \endcode + + use + + \code + qbs.targetOS.contains("darwin") + + \endcode + + However, in some cases using \l{qbs::}{targetPlatform} would be acceptable, such as + when the resulting condition would be simpler while still being correct: + + \code + qbs.targetPlatform === "linux" + \endcode + + versus + \code + qbs.targetOS.contains("linux") && !qbs.targetOS.contains("android") + \endcode - Possible values include one or more of \c{"bsd"}, \c{"darwin"}, and - \c{"unix"}, in addition to the possible values of \l{qbs::}{targetPlatform}. + For the complete list of possible values, see + \l{Relation between targetPlatform and targetOS}. \nodefaultvalue */ diff --git a/doc/reference/modules/qt-android_support-module.qdoc b/doc/reference/modules/qt-android_support-module.qdoc index f7ec595e3..995f73ba5 100644 --- a/doc/reference/modules/qt-android_support-module.qdoc +++ b/doc/reference/modules/qt-android_support-module.qdoc @@ -77,6 +77,15 @@ */ /*! + \qmlproperty stringList Qt.android_support::extraLibs + + Additional libs to be packaged and loaded on start-up (mind the order). + Corresponds to qmake's ANDROID_EXTRA_LIBS. + + \defaultvalue \c undefined +*/ + +/*! \qmlproperty bool Qt.android_support::verboseAndroidDeployQt Enable this property if you want verbose output from the |