summaryrefslogtreecommitdiffstats
path: root/qmake/doc/src/qmake-manual.qdoc
diff options
context:
space:
mode:
Diffstat (limited to 'qmake/doc/src/qmake-manual.qdoc')
-rw-r--r--qmake/doc/src/qmake-manual.qdoc390
1 files changed, 158 insertions, 232 deletions
diff --git a/qmake/doc/src/qmake-manual.qdoc b/qmake/doc/src/qmake-manual.qdoc
index 9d3d15b9c1..31d3f824e7 100644
--- a/qmake/doc/src/qmake-manual.qdoc
+++ b/qmake/doc/src/qmake-manual.qdoc
@@ -1,29 +1,5 @@
-/****************************************************************************
-**
-** Copyright (C) 2019 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of the documentation of the Qt Toolkit.
-**
-** $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$
-**
-****************************************************************************/
+// Copyright (C) 2019 The Qt Company Ltd.
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\page qmake-manual.html
@@ -142,6 +118,9 @@
For more information about the environment variables that qmake uses when
configuring the build process, see \l{Configuring qmake}.
+ \note Add your project build directory to the list of excluded directories
+ of any anti-virus application that runs on your system.
+
\section1 Using Third Party Libraries
The guide to \l{Third Party Libraries} shows you how to use simple third
@@ -178,7 +157,6 @@
The following sections describe the different types of elements used
in project files.
- \target ProjectFileElementsVariables
\section2 Variables
In a project file, variables are used to hold lists of strings. In the
@@ -296,9 +274,10 @@
line as the condition.
More complex operations on variables that would usually require loops
- are provided by built-in functions such as \l{findfunction}{find()},
- \l{unique}{unique()}, and \l{countfunction}{count()}. These functions, and
- many others are provided to manipulate
+ are provided by built-in functions such as \l{find(variablename, substr)}
+ {find()}, \l{unique(variablename)}{unique()}, and
+ \l{count(variablename, number)}{count()}.
+ These functions, and many others are provided to manipulate
strings and paths, support user input, and call external tools. For more
information about using the functions, see \l{qmake Language}. For lists
of all functions and their descriptions, see \l{Replace Functions} and
@@ -345,7 +324,6 @@
The \c SUBDIRS variable is used to
contain a list of all the subdirectories to be processed.
- \target GeneralConfiguration
\section1 General Configuration
The \l{CONFIG} variable specifies the options and features that the project
@@ -512,9 +490,9 @@
You can use the \c options to specify both general and mode-specific
settings. Options that only apply to the Makefile mode are described in the
- \l{#MakefileMode}{Makefile Mode Options} section, whereas options that influence the
+ \l{Makefile Mode Options} section, whereas options that influence the
creation of project files are described in the
- \l{#ProjectMode}{Project Mode Options} section.
+ \l{Project Mode Options} section.
\section1 Files
@@ -575,7 +553,6 @@
files.
\endlist
- \target MakefileMode
\section1 Makefile Mode Options
\snippet code/doc_src_qmake-manual.pro 9
@@ -617,7 +594,6 @@
is specified, all assignments on the command line after the \c -after
option will be postponed until after the specified files are parsed.
- \target ProjectMode
\section1 Project Mode Options
\snippet code/doc_src_qmake-manual.pro 12
@@ -908,7 +884,6 @@
to specify a list of libraries that each project needs to link against,
and \c QMAKE_LIBS_X11 would be used to extend this list.
- \target ANDROID_ABIS
\section1 ANDROID_ABIS
\note This variable applies only to Android targets.
@@ -926,7 +901,6 @@
it is not recommended since it will override any ABIs specified on the
\c qmake command line.
- \target ANDROID_API_VERSION
\section1 ANDROID_API_VERSION
\note This variable applies only to Android targets.
@@ -934,7 +908,6 @@
Specifies the Android API level number. For more information, see
\l{Android: Build Numbers}{Android Build Numbers}.
- \target ANDROID_APPLICATION_ARGUMENTS
\section1 ANDROID_APPLICATION_ARGUMENTS
\note This variable applies only to Android targets.
@@ -947,7 +920,6 @@
ANDROID_APPLICATION_ARGUMENTS = "arg1 arg2 arg3"
\endcode
- \target ANDROID_BUNDLED_JAR_DEPENDENCIES
\section1 ANDROID_BUNDLED_JAR_DEPENDENCIES
\note This variable applies only to Android modules.
@@ -959,7 +931,6 @@
ANDROID_BUNDLED_JAR_DEPENDENCIES += jar/Qt6Android.jar
\endcode
- \target ANDROID_DEPLOYMENT_DEPENDENCIES
\section1 ANDROID_DEPLOYMENT_DEPENDENCIES
\note This variable applies only to Android targets.
@@ -978,7 +949,6 @@
provides a way to override the automatic detection entirely, so if a library
is listed before its dependencies, it will fail to load on some devices.
- \target ANDROID_DEPLOYMENT_SETTINGS_FILE
\section1 ANDROID_DEPLOYMENT_SETTINGS_FILE
\note This variable applies only to Android targets.
@@ -988,7 +958,6 @@
the settings file generated by qmake, thus you have to make sure to provide
a valid settings file.
- \target ANDROID_EXTRA_LIBS
\section1 ANDROID_EXTRA_LIBS
\note This variable applies only to Android targets.
@@ -1011,7 +980,6 @@
for (abi, ANDROID_ABIS): ANDROID_EXTRA_LIBS += $$PWD/library_name_$${abi}.so
\endcode
- \target ANDROID_EXTRA_PLUGINS
\section1 ANDROID_EXTRA_PLUGINS
\note This variable applies only to Android targets.
@@ -1052,7 +1020,6 @@
ANDROID_EXTRA_PLUGINS += $$top_builddir/plugins
\endcode
- \target ANDROID_FEATURES
\section1 ANDROID_FEATURES
\note This variable applies only to Android modules.
@@ -1065,7 +1032,6 @@
For more information, see \l{Android: <uses-feature>}{Android <uses-feature> Docs}.
- \target ANDROID_LIB_DEPENDENCIES
\section1 ANDROID_LIB_DEPENDENCIES
\note This variable applies only to Android modules.
@@ -1078,7 +1044,6 @@
plugins/libplugins_platforms_qtforandroid.so
\endcode
- \target ANDROID_MIN_SDK_VERSION
\section1 ANDROID_MIN_SDK_VERSION
\note This variable applies only to Android targets.
@@ -1086,7 +1051,6 @@
Specifies the minimum Android API level for the project. By default, this
variable is set to API level 23.
- \target ANDROID_PACKAGE_SOURCE_DIR
\section1 ANDROID_PACKAGE_SOURCE_DIR
\note This variable applies only to Android targets.
@@ -1107,7 +1071,6 @@
instance, you can make a custom \c {AndroidManifest.xml} for your application,
then place this directly into the directory specified by this variable.
- \target ANDROID_PERMISSIONS
\section1 ANDROID_PERMISSIONS
\note This variable applies only to Android modules.
@@ -1120,15 +1083,13 @@
For more information, see \l{Android: <uses-permission>}{Android <uses-permission> Docs}.
- \target ANDROID_TARGET_SDK_VERSION
\section1 ANDROID_TARGET_SDK_VERSION
\note This variable applies only to Android targets.
Specifies the target Android API level for the project. By default, this
- variable is set to API level 30.
+ variable is set to API level 34.
- \target ANDROID_VERSION_CODE
\section1 ANDROID_VERSION_CODE
\note This variable applies only to Android targets.
@@ -1136,7 +1097,6 @@
Specifies the application's version number. For more information, see
\l{Android: App Versioning}{Android App Versioning}.
- \target ANDROID_VERSION_NAME
\section1 ANDROID_VERSION_NAME
\note This variable applies only to Android targets.
@@ -1144,7 +1104,6 @@
Specifies the application's version in as a human readable string. For more
information, see \l{Android: App Versioning}{Android App Versioning}.
- \target CONFIG
\section1 CONFIG
Specifies project configuration and compiler options. The values are
@@ -1227,8 +1186,10 @@
By default, support is disabled.
\row \li c++2a \li Obsolete alias for c++20.
\row \li c++latest \li Support for the latest C++ language standard is
- enabled that is supported by the compiler. By default, this option is
- disabled.
+ enabled. This option is mostly useful for MSVC that supports a
+ \c{/std:c++latest} compiler argument. For other toolchains, this
+ option enables the latest C++ standard that is known to Qt. By
+ default, this option is disabled.
\row \li strict_c++ \li Disables support for C++ compiler extensions.
By default, they are enabled.
\row \li depend_includepath \li Appending the value of INCLUDEPATH to
@@ -1302,11 +1263,11 @@
qmake to track these dependencies. When this
option is enabled, qmake will create a file
with the extension \c .prl which will save meta-information about the library
- (see \l{LibDepend}{Library Dependencies} for more info).
+ (see \l{Library Dependencies} for more info).
\row \li link_prl \li When this option is enabled,
qmake will process all libraries linked to
by the application and find their meta-information (see
- \l{LibDepend}{Library Dependencies} for more info).
+ \l{Library Dependencies} for more info).
\row \li no_install_prl \li This option disables the generation of
installation rules for generated .prl files.
\endtable
@@ -1322,7 +1283,7 @@
\row \li qt \li The target is a Qt application or library and requires the Qt
library and header files. The proper include and library paths for the
Qt library will automatically be added to the project. This is defined
- by default, and can be fine-tuned with the \c{\l{#qt}{QT}} variable.
+ by default, and can be fine-tuned with the \l{#qt}{QT} variable.
\row \li x11 \li The target is an X11 application or library. The proper
include paths and libraries will automatically be added to the
project.
@@ -1413,7 +1374,6 @@
\snippet code/doc_src_qmake-manual.pro 26
- \target DEFINES
\section1 DEFINES
qmake adds the values of this variable as
@@ -1423,7 +1383,6 @@
\snippet code/doc_src_qmake-manual.pro 27
- \target DEFINES_DEBUG
\section1 DEFINES_DEBUG
Specifies preprocessor defines for the debug configuration. The values of
@@ -1433,7 +1392,6 @@
This variable was introduced in Qt 5.13.2.
- \target DEFINES_RELEASE
\section1 DEFINES_RELEASE
Specifies preprocessor defines for the release configuration. The values of
@@ -1446,21 +1404,18 @@
This variable was introduced in Qt 5.13.2.
- \target DEF_FILE
\section1 DEF_FILE
\note This variable is used only on Windows when using the \c app template.
Specifies a \c .def file to be included in the project.
- \target DEPENDPATH
\section1 DEPENDPATH
Specifies a list of directories for qmake to scan, to resolve dependencies.
This variable is used when qmake crawls through the header files that you
\c{#include} in your source code.
- \target DESTDIR
\section1 DESTDIR
Specifies where to put the \l{#TARGET}{target} file.
@@ -1473,7 +1428,6 @@
the used build tool. In particular, parentheses do not
work with \c{make}.
- \target DISTFILES
\section1 DISTFILES
Specifies a list of files to be included in the dist
@@ -1483,14 +1437,12 @@
\snippet code/doc_src_qmake-manual.pro 31
- \target DLLDESTDIR
\section1 DLLDESTDIR
\note This variable applies only to Windows targets.
Specifies where to copy the \l{#TARGET}{target} dll.
- \target EXTRA_TRANSLATIONS
\section1 EXTRA_TRANSLATIONS
Specifies a list of translation (.ts) files that contain
@@ -1508,18 +1460,17 @@
See the \l{Qt Linguist Manual} for more information about
internationalization (i18n) and localization (l10n) with Qt.
- \target FORMS
\section1 FORMS
- Specifies the UI files (see \l{Qt Designer Manual}) to be processed by \c uic
- before compiling. All dependencies, headers and source files required
- to build these UI files will automatically be added to the project.
+ Specifies the UI files (see \l{Qt Widgets Designer Manual}) to be processed
+ by \c uic before compiling. All dependencies, headers and source files
+ required to build these UI files will automatically be added to the
+ project.
For example:
\snippet code/doc_src_qmake-manual.pro 32
- \target GUID
\section1 GUID
Specifies the GUID that is set inside a \c{.vcproj} file. The GUID is
@@ -1529,7 +1480,6 @@
This variable is specific to \c{.vcproj} files only; it is ignored
otherwise.
- \target HEADERS
\section1 HEADERS
Defines the header files for the project.
@@ -1544,20 +1494,17 @@
See also \l{#SOURCES}{SOURCES}.
- \target ICON
\section1 ICON
This variable is used only on Mac OS to set the application icon.
Please see \l{Setting the Application Icon}{the application icon documentation}
for more information.
- \target IDLSOURCES
\section1 IDLSOURCES
This variable is used only on Windows for the Visual Studio project generation to
put the specified files in the Generated Files folder.
- \target INCLUDEPATH
\section1 INCLUDEPATH
Specifies the #include directories which should be
@@ -1572,7 +1519,6 @@
\snippet qmake/spaces.pro quoting include paths with spaces
- \target INSTALLS
\section1 INSTALLS
Specifies a list of resources that will be installed when
@@ -1626,28 +1572,24 @@
This variable is also used to specify which additional files will be
deployed to embedded devices.
- \target JAVA_HOME
\section1 JAVA_HOME
\note This variable is useful only to Android targets.
Specifies the JDK/OpenJDK installation path used for building the project.
- \target LEXIMPLS
\section1 LEXIMPLS
Specifies a list of Lex implementation files. The value
of this variable is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target LEXOBJECTS
\section1 LEXOBJECTS
Specifies the names of intermediate Lex object
files. The value of this variable is typically handled by
qmake and rarely needs to be modified.
- \target LEXSOURCES
\section1 LEXSOURCES
Specifies a list of Lex source files. All
@@ -1658,7 +1600,6 @@
\snippet code/doc_src_qmake-manual.pro 37
- \target LIBS
\section1 LIBS
Specifies a list of libraries to be linked into the project.
@@ -1682,7 +1623,6 @@
\snippet code/doc_src_qmake-manual.pro 39
- \target LIBS_PRIVATE
\section1 LIBS_PRIVATE
Specifies a list of libraries to be linked privately into the project.
@@ -1695,7 +1635,6 @@
directly, it needs to link to A explicitly. Put differently, libraries
linked privately are not exposed transitively at build time.
- \target LITERAL_HASH
\section1 LITERAL_HASH
This variable is used whenever a literal hash character (\c{#}) is needed in
@@ -1709,14 +1648,12 @@
By using \c LITERAL_HASH in this way, the \c # character can be used
to construct a URL for the \c message() function to print to the console.
- \target MAKEFILE
\section1 MAKEFILE
Specifies the name of the generated Makefile. The value of this variable is
typically handled by qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to
be modified.
- \target MAKEFILE_GENERATOR
\section1 MAKEFILE_GENERATOR
Specifies the name of the Makefile generator to use
@@ -1724,13 +1661,11 @@
handled internally by qmake and rarely needs to
be modified.
- \target MSVCPROJ_*
\section1 MSVCPROJ_*
These variables are handled internally by qmake and should not be modified
or utilized.
- \target MOC_DIR
\section1 MOC_DIR
Specifies the directory where all intermediate moc
@@ -1740,7 +1675,6 @@
\snippet code/doc_src_qmake-manual.pro 40
- \target OBJECTIVE_HEADERS
\section1 OBJECTIVE_HEADERS
Defines the Objective-C++ header files for the project.
@@ -1754,7 +1688,6 @@
See also \l{#OBJECTIVE_SOURCES}{OBJECTIVE_SOURCES}.
- \target OBJECTIVE_SOURCES
\section1 OBJECTIVE_SOURCES
Specifies the names of all Objective-C/C++ source files in the project.
@@ -1764,14 +1697,12 @@
See also \l{#OBJECTIVE_HEADERS}{OBJECTIVE_HEADERS}.
- \target OBJECTS
\section1 OBJECTS
This variable is automatically populated from the \l{SOURCES} variable.
The extension of each source file is replaced by .o (Unix) or .obj (Win32).
You can add objects to the list.
- \target OBJECTS_DIR
\section1 OBJECTS_DIR
Specifies the directory where all intermediate
@@ -1781,7 +1712,6 @@
\snippet code/doc_src_qmake-manual.pro 41
- \target POST_TARGETDEPS
\section1 POST_TARGETDEPS
Lists the libraries that the \l{#TARGET}{target} depends on. Some backends,
@@ -1793,7 +1723,6 @@
This list is placed after all builtin (and \link #PRE_TARGETDEPS
$$PRE_TARGETDEPS \endlink) dependencies.
- \target PRE_TARGETDEPS
\section1 PRE_TARGETDEPS
Lists libraries that the \l{#TARGET}{target} depends on. Some backends,
@@ -1804,7 +1733,6 @@
This list is placed before all builtin dependencies.
- \target PRECOMPILED_HEADER
\section1 PRECOMPILED_HEADER
Indicates the header file for creating a precompiled
@@ -1813,7 +1741,6 @@
(Windows - all MSVC project types, Apple - Xcode, Makefile,
Unix - gcc 3.3 and up).
- \target PWD
\section1 PWD
Specifies the full path leading to the directory
@@ -1825,7 +1752,6 @@
\note Do not attempt to overwrite the value of this variable.
- \target OUT_PWD
\section1 OUT_PWD
Specifies the full path leading to the directory where qmake places the
@@ -1833,7 +1759,6 @@
\note Do not attempt to overwrite the value of this variable.
- \target QM_FILES_RESOURCE_PREFIX
\section1 QM_FILES_RESOURCE_PREFIX
Specifies the directory in the resource system where \c .qm files will
@@ -1841,27 +1766,46 @@
The default is \c{:/i18n/}.
- \target QM_FILES_INSTALL_PATH
\section1 QM_FILES_INSTALL_PATH
Specifies the target directory \c .qm files generated by
\l{CONFIG}{CONFIG += lrelease} will be installed to. Does not have any
effect if \l{CONFIG}{CONFIG += embed_translations} is set.
- \target QML_IMPORT_PATH
\section1 QML_IMPORT_PATH
- This variable is only used by \l{Qt Creator Manual}{Qt Creator}.
+ This variable is only used by \l{Qt Creator Manual}{Qt Creator}. If you have
+ an extra module that is kept outside of your Qt installation, you can
+ specify its path here.
+
See \l{Qt Creator: Using QML Modules with Plugins} for details.
- \target QMAKE_systemvariable
+ \section1 QMLPATHS
+
+ Expects a list of import paths that point to root directories of trees of
+ QML modules. For example, if you have a custom location for your QML
+ modules, you can specify it here.
+
+ \note The path entries for QMLPATHS point to root directories of trees of
+ QML modules. This is the concept of import paths the QML engine understands.
+ You can pass the same paths via the \c QML_IMPORT_PATH \e environment variable
+ to your QML application, but they are \e different from the expected contents
+ of the \l QML_IMPORT_PATH \e qmake variable. The latter expects paths to
+ \e individual modules to be processed by Qt Creator only.
+
+ \note The contents of QMLPATHS are \e not automatically passed to your
+ application. Rather, they are only used at build time. In particular,
+ qmlimportscanner uses them to find any QML modules it may need to mark as
+ imported by your application.
+
+ \sa QQmlEngine::addImportPath()
+
\section1 QMAKE
Specifies the name of the qmake program itself and is placed in generated
Makefiles. The value of this variable is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKESPEC_systemvariable
\section1 QMAKESPEC
A system variable that contains the full path of the qmake configuration that is used
@@ -1869,7 +1813,20 @@
\note Do not attempt to overwrite the value of this variable.
- \target QMAKE_AR_CMD
+ \section1 QMAKE_APPLE_DEVICE_ARCHS
+
+ \note This variable is used on \macos only.
+
+ Specifies a list of architectures to build for. By default, a project is
+ built for the development machine's architecture. This variable allows to
+ override the default and build for a different architecture or to create
+ multi-architecture binaries.
+
+ This variable is usually specified on the command line or in the project
+ file.
+
+ See \l{Qt for macOS} for more information.
+
\section1 QMAKE_AR_CMD
\note This variable is used on Unix platforms only.
@@ -1877,7 +1834,6 @@
Specifies the command to execute when creating a shared library. The value of this variable
is typically handled by qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_BUNDLE_DATA
\section1 QMAKE_BUNDLE_DATA
\note This variable is used on \macos, iOS, tvOS, and watchOS only.
@@ -1900,6 +1856,33 @@
See \l{Platform Notes#Creating Frameworks}{Platform Notes} for
more information about creating library bundles.
+ A project can also use this variable to bundle application translation
+ files. The exact syntax depends on whether the project is using Xcode's
+ legacy build system or its new build system.
+
+ For example when the following project snippet is built using the
+ legacy build system:
+
+ \snippet code/doc_src_qmake-manual.pro 188
+
+ Xcode will ignore the original location of \c InfoPlist.strings
+ and the file will placed into the bundle \c Resources directory
+ under the provided \c translations_en.path path, so
+ \c Resources/en.lproj/InfoPlist.strings
+
+ With the new build system, the relative location of the file is
+ preserved, which means the file will incorrectly be placed under
+ \c Resources/en.lproj/en.lproj/InfoPlist.strings
+
+ To ensure correct file placement, the project can either move
+ the original file not to be in a sub-directory or it can choose
+ not to specify the \c translations_en.path variable.
+
+ \snippet code/doc_src_qmake-manual.pro 189
+
+ See \qtbug QTBUG-98417 for more details on how the Xcode build
+ system changed its behavior in bundling translation files.
+
\section1 QMAKE_BUNDLE_EXTENSION
\note This variable is used on \macos, iOS, tvOS, and watchOS only.
@@ -1929,21 +1912,18 @@
adjusted by modifying the \c QMAKE_CFLAGS_DEBUG and
\c QMAKE_CFLAGS_RELEASE variables, respectively.
- \target QMAKE_CFLAGS_DEBUG
\section1 QMAKE_CFLAGS_DEBUG
Specifies the C compiler flags for debug builds.
The value of this variable is typically handled by qmake or \l{#QMAKESPEC}{qmake.conf} and
rarely needs to be modified.
- \target QMAKE_CFLAGS_RELEASE
\section1 QMAKE_CFLAGS_RELEASE
Specifies the C compiler flags for release builds.
The value of this variable is typically handled by qmake or \l{#QMAKESPEC}{qmake.conf}
and rarely needs to be modified.
- \target QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO
\section1 QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO
Specifies the C compiler flags for release builds where
@@ -1951,7 +1931,6 @@
The value of this variable is typically handled by
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CFLAGS_SHLIB
\section1 QMAKE_CFLAGS_SHLIB
\note This variable is used on Unix platforms only.
@@ -1961,7 +1940,6 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target QMAKE_CFLAGS_THREAD
\section1 QMAKE_CFLAGS_THREAD
Specifies the compiler flags for creating a multi-threaded
@@ -1969,21 +1947,18 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target QMAKE_CFLAGS_WARN_OFF
\section1 QMAKE_CFLAGS_WARN_OFF
This variable is used only when the \c {warn_off} \l{#CONFIG}{CONFIG} option
is set. The value of this variable is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CFLAGS_WARN_ON
\section1 QMAKE_CFLAGS_WARN_ON
This variable is used only when the \c {warn_on} \l{#CONFIG}{CONFIG} option
is set. The value of this variable is typically handled by
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CLEAN
\section1 QMAKE_CLEAN
Specifies a list of generated files (by \l{moc} and \l{uic}, for example) and
@@ -2005,21 +1980,18 @@
adjusted by modifying the \c QMAKE_CXXFLAGS_DEBUG and
\c QMAKE_CXXFLAGS_RELEASE variables, respectively.
- \target QMAKE_CXXFLAGS_DEBUG
\section1 QMAKE_CXXFLAGS_DEBUG
Specifies the C++ compiler flags for debug builds.
The value of this variable is typically handled by
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CXXFLAGS_RELEASE
\section1 QMAKE_CXXFLAGS_RELEASE
Specifies the C++ compiler flags for release builds.
The value of this variable is typically handled by
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO
\section1 QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO
Specifies the C++ compiler flags for release builds where
@@ -2027,7 +1999,6 @@
The value of this variable is typically handled by
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CXXFLAGS_SHLIB
\section1 QMAKE_CXXFLAGS_SHLIB
Specifies the C++ compiler flags for creating a shared library.
@@ -2035,14 +2006,12 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target QMAKE_CXXFLAGS_THREAD
\section1 QMAKE_CXXFLAGS_THREAD
Specifies the C++ compiler flags for creating a multi-threaded application.
The value of this variable is typically handled by qmake or \l{#QMAKESPEC}
{qmake.conf} and rarely needs to be modified.
- \target QMAKE_CXXFLAGS_WARN_OFF
\section1 QMAKE_CXXFLAGS_WARN_OFF
Specifies the C++ compiler flags for suppressing compiler
@@ -2050,7 +2019,6 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target QMAKE_CXXFLAGS_WARN_ON
\section1 QMAKE_CXXFLAGS_WARN_ON
Specifies C++ compiler flags for generating compiler warnings.
@@ -2058,7 +2026,6 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target QMAKE_DEVELOPMENT_TEAM
\section1 QMAKE_DEVELOPMENT_TEAM
\note This variable is used on \macos, iOS, tvOS, and watchOS only.
@@ -2066,12 +2033,10 @@
The identifier of a development team to use for signing certificates
and provisioning profiles.
- \target QMAKE_DISTCLEAN
\section1 QMAKE_DISTCLEAN
Specifies a list of files to be removed by \c{make distclean}.
- \target QMAKE_EXTENSION_SHLIB
\section1 QMAKE_EXTENSION_SHLIB
Contains the extension for shared libraries. The value of
@@ -2081,7 +2046,6 @@
\note Platform-specific variables that change the extension override
the contents of this variable.
- \target QMAKE_EXTENSION_STATICLIB
\section1 QMAKE_EXTENSION_STATICLIB
Contains the extension for shared static libraries. The value of
@@ -2092,51 +2056,51 @@
Contains the extension used on included moc files.
- See also \l{Configuring qmake#Extensions}{File Extensions}.
+ See also \l{Configuring qmake#File Extensions}{File Extensions}.
\section1 QMAKE_EXT_UI
Contains the extension used on \QD UI files.
- See also \l{Configuring qmake#Extensions}{File Extensions}.
+ See also \l{Configuring qmake#File Extensions}{File Extensions}.
\section1 QMAKE_EXT_PRL
Contains the extension used on created PRL files.
- See also \l{Configuring qmake#Extensions}{File Extensions},
- \l{LibDepend}{Library Dependencies}.
+ See also \l{Configuring qmake#File Extensions}{File Extensions},
+ \l{Library Dependencies}.
\section1 QMAKE_EXT_LEX
Contains the extension used on files given to Lex.
- See also \l{Configuring qmake#Extensions}{File Extensions},
+ See also \l{Configuring qmake#File Extensions}{File Extensions},
\l{#LEXSOURCES}{LEXSOURCES}.
\section1 QMAKE_EXT_YACC
Contains the extension used on files given to Yacc.
- See also \l{Configuring qmake#Extensions}{File Extensions},
+ See also \l{Configuring qmake#File Extensions}{File Extensions},
\l{#YACCSOURCES}{YACCSOURCES}.
\section1 QMAKE_EXT_OBJ
Contains the extension used on generated object files.
- See also \l{Configuring qmake#Extensions}{File Extensions}.
+ See also \l{Configuring qmake#File Extensions}{File Extensions}.
\section1 QMAKE_EXT_CPP
Contains suffixes for files that should be interpreted as C++ source code.
- See also \l{Configuring qmake#Extensions}{File Extensions}.
+ See also \l{Configuring qmake#File Extensions}{File Extensions}.
\section1 QMAKE_EXT_H
Contains suffixes for files which should be interpreted as C header files.
- See also \l{Configuring qmake#Extensions}{File Extensions}.
+ See also \l{Configuring qmake#File Extensions}{File Extensions}.
\section1 QMAKE_EXTRA_COMPILERS
@@ -2150,7 +2114,6 @@
See also \l{Adding Custom Targets}.
- \target QMAKE_FAILED_REQUIREMENTS
\section1 QMAKE_FAILED_REQUIREMENTS
Contains the list of failed requirements.
@@ -2171,7 +2134,6 @@
See \l{Creating Frameworks} for
more information about creating frameworks and library bundles.
- \target QMAKE_FRAMEWORK_VERSION
\section1 QMAKE_FRAMEWORK_VERSION
\note This variable is used on \macos, iOS, tvOS, and watchOS only.
@@ -2185,7 +2147,6 @@
See \l{Creating Frameworks} for more information about creating frameworks.
- \target QMAKE_HOST
\section1 QMAKE_HOST
Provides information about the host machine running qmake.
@@ -2204,14 +2165,12 @@
\snippet code/doc_src_qmake-manual.pro 187
- \target QMAKE_INCDIR
\section1 QMAKE_INCDIR
Specifies the list of system header paths that are appended to \l{INCLUDEPATH}.
The value of this variable is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_INCDIR_EGL
\section1 QMAKE_INCDIR_EGL
Specifies the location of EGL header files to be added to
@@ -2220,7 +2179,6 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target QMAKE_INCDIR_OPENGL
\section1 QMAKE_INCDIR_OPENGL
Specifies the location of OpenGL header files to be added
@@ -2244,7 +2202,6 @@
If the OpenGL implementation uses EGL (most OpenGL/ES systems),
then QMAKE_INCDIR_EGL may also need to be set.
- \target QMAKE_INCDIR_OPENVG
\section1 QMAKE_INCDIR_OPENVG
Specifies the location of OpenVG header files to be added
@@ -2256,7 +2213,6 @@
If the OpenVG implementation uses EGL then QMAKE_INCDIR_EGL may also
need to be set.
- \target QMAKE_INCDIR_X11
\section1 QMAKE_INCDIR_X11
\note This variable is used on Unix platforms only.
@@ -2266,7 +2222,6 @@
is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_INFO_PLIST
\section1 QMAKE_INFO_PLIST
\note This variable is used on \macos, iOS, tvOS, and watchOS platforms only.
@@ -2285,8 +2240,11 @@
\li \c ${PRODUCT_BUNDLE_IDENTIFIER}, \c @BUNDLEIDENTIFIER@
\li Expands to the target bundle's bundle identifier string,
for example: \c{com.example.myapp}. Determined by concatenating the
- values of QMAKE_TARGET_BUNDLE_PREFIX and QMAKE_BUNDLE, separated
- by a full stop (\c{.}).
+ values of \c QMAKE_TARGET_BUNDLE_PREFIX and \c QMAKE_BUNDLE, separated
+ by a full stop (\c{.}). The value of \c QMAKE_BUNDLE is derived from
+ \c QMAKE_APPLICATION_BUNDLE_NAME, \c QMAKE_PLUGIN_BUNDLE_NAME, or
+ \c QMAKE_FRAMEWORK_BUNDLE_NAME. It should not be set directly by the
+ project.
\row
\li \c ${EXECUTABLE_NAME}, \c @EXECUTABLE@, \c @LIBRARY@
\li Equivalent to the value of QMAKE_APPLICATION_BUNDLE_NAME,
@@ -2357,7 +2315,6 @@
platform or type of project, use one of the specialized variables
for that purpose instead of this variable.
- \target QMAKE_LFLAGS_CONSOLE
\section1 QMAKE_LFLAGS_CONSOLE
\note This variable is used on Windows only.
@@ -2625,7 +2582,6 @@
value of this variable is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_LRELEASE_FLAGS
\section1 QMAKE_LRELEASE_FLAGS
List of additional options passed to \l{Using lrelease}{lrelease} when
@@ -2651,7 +2607,8 @@
together. This variable is normally empty and therefore nothing is
executed.
- \note This variable takes no effect on Xcode projects.
+ \warning This variable is not supported when using the Xcode
+ generator and the new Xcode build system.
\section1 QMAKE_PROJECT_NAME
@@ -2661,7 +2618,6 @@
files for IDEs. The default value is the target name. The value of this
variable is typically handled by qmake and rarely needs to be modified.
- \target QMAKE_PROVISIONING_PROFILE
\section1 QMAKE_PROVISIONING_PROFILE
\note This variable is used on \macos, iOS, tvOS, and watchOS only.
@@ -2794,7 +2750,6 @@
variable is typically handled by qmake or
\l{#QMAKESPEC}{qmake.conf} and rarely needs to be modified.
- \target QMAKE_TARGET_COMPANY
\section1 QMAKE_TARGET_COMPANY
Windows only. Specifies the company for the project target; this is
@@ -2802,7 +2757,6 @@
properties. This is only utilized if the \l{VERSION} or \l{RC_ICONS}
variable is set and the \l{RC_FILE} and \l{RES_FILE} variables are not set.
- \target QMAKE_TARGET_DESCRIPTION
\section1 QMAKE_TARGET_DESCRIPTION
Windows only. Specifies the description for the project target; this is
@@ -2810,7 +2764,6 @@
properties. This is only utilized if the \l{VERSION} or \l{RC_ICONS}
variable is set and the \l{RC_FILE} and \l{RES_FILE} variables are not set.
- \target QMAKE_TARGET_COPYRIGHT
\section1 QMAKE_TARGET_COPYRIGHT
Windows only. Specifies the copyright information for the project target;
@@ -2819,7 +2772,6 @@
\l{RC_ICONS} variable is set and the \l{RC_FILE} and \l{RES_FILE} variables
are not set.
- \target QMAKE_TARGET_PRODUCT
\section1 QMAKE_TARGET_PRODUCT
Windows only. Specifies the product for the project target; this is used
@@ -2827,7 +2779,6 @@
This is only utilized if the \l{VERSION} or \l{RC_ICONS} variable is set
and the \l{RC_FILE} and \l{RES_FILE} variables are not set.
- \target QMAKE_TARGET_ORIGINAL_FILENAME
\section1 QMAKE_TARGET_ORIGINAL_FILENAME
Windows only. Specifies the original file name for the project target;
@@ -2836,7 +2787,6 @@
\l{RC_ICONS} variable is set and the \l{RC_FILE} and \l{RES_FILE}
variables are not set.
- \target QMAKE_TARGET_INTERNALNAME
\section1 QMAKE_TARGET_INTERNALNAME
Windows only. Specifies the internal name for the project target; this is
@@ -2844,7 +2794,6 @@
properties. This is only utilized if the \l{VERSION} or \l{RC_ICONS}
variable is set and the \l{RC_FILE} and \l{RES_FILE} variables are not set.
- \target QMAKE_TARGET_COMMENTS
\section1 QMAKE_TARGET_COMMENTS
Windows only. Specifies the comments for the project target; this is
@@ -2852,7 +2801,6 @@
properties. This is only utilized if the \l{VERSION} or \l{RC_ICONS}
variable is set and the \l{RC_FILE} and \l{RES_FILE} variables are not set.
- \target QMAKE_TARGET_TRADEMARKS
\section1 QMAKE_TARGET_TRADEMARKS
Windows only. Specifies the trademark information for the project target;
@@ -2861,7 +2809,6 @@
\l{RC_ICONS} variable is set and the \l{RC_FILE} and \l{RES_FILE} variables
are not set.
- \target QMAKE_MANIFEST
\section1 QMAKE_MANIFEST
Windows only. Specifies the manifest file for the project target.
@@ -2962,22 +2909,18 @@
shared/dynamic build of Qt, or when linking libraries.
It may be used for deployment of dynamic plugins at a later time.
- \target QT_VERSION_variable
\section1 QT_VERSION
Contains the current version of Qt.
- \target QT_MAJOR_VERSION
\section1 QT_MAJOR_VERSION
Contains the current major version of Qt.
- \target QT_MINOR_VERSION
\section1 QT_MINOR_VERSION
Contains the current minor version of Qt.
- \target QT_PATCH_VERSION
\section1 QT_PATCH_VERSION
Contains the current patch version of Qt.
@@ -2987,14 +2930,12 @@
Windows only. Specifies the name of the Windows resource file (.rc) for the
target. See \l{Adding Windows Resource Files}.
- \target RC_CODEPAGE
\section1 RC_CODEPAGE
Windows only. Specifies the codepage that should be specified in a generated
.rc file. This is only utilized if the \l{VERSION} or \l{RC_ICONS} variable
is set and the \l{RC_FILE} and \l{RES_FILE} variables are not set.
- \target RC_DEFINES
\section1 RC_DEFINES
Windows only. qmake adds the values of this variable as RC preprocessor macros
@@ -3002,7 +2943,6 @@
\snippet code/doc_src_qmake-manual.pro 186
- \target RC_ICONS
\section1 RC_ICONS
Windows only. Specifies the icons that should be included into a generated
@@ -3010,7 +2950,6 @@
are not set. More details about the generation of .rc files can be found in
the \l{Platform Notes}.
- \target RC_LANG
\section1 RC_LANG
Windows only. Specifies the language that should be specified in a generated
@@ -3021,7 +2960,6 @@
Specifies include paths that are passed to the Windows Resource Compiler.
- \target RCC_DIR
\section1 RCC_DIR
Specifies the directory for Qt Resource Compiler output files.
@@ -3030,7 +2968,6 @@
\snippet code/doc_src_qmake-manual.pro 48
- \target REQUIRES
\section1 REQUIRES
Specifies a list of values that are evaluated as conditions. If any of the conditions is false,
@@ -3039,7 +2976,6 @@
\note We recommend using the \l{requires(condition)}{requires()} function
instead if you want to skip projects or subprojects when building.
- \target RESOURCES
\section1 RESOURCES
Specifies the name of the resource collection files (qrc)
@@ -3055,7 +2991,6 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target SOURCES
\section1 SOURCES
Specifies the names of all source files in the project.
@@ -3066,7 +3001,6 @@
See also \l{#HEADERS}{HEADERS}.
- \target SUBDIRS
\section1 SUBDIRS
This variable, when used with the \c subdirs \l{#TEMPLATE}{template}
@@ -3128,7 +3062,6 @@
\snippet code/doc_src_qmake-manual.pro 149
- \target TARGET
\section1 TARGET
Specifies the name of the target file. Contains the base name of the project
@@ -3161,7 +3094,6 @@
qmake or \l{#QMAKESPEC}{qmake.conf} and rarely
needs to be modified.
- \target TEMPLATE
\section1 TEMPLATE
Specifies the name of the template to use when generating the project. The
@@ -3198,7 +3130,6 @@
determine how the project is built, it is necessary to declare TEMPLATE on
the command line rather than use the \c -t option.
- \target TRANSLATIONS
\section1 TRANSLATIONS
Specifies a list of translation (.ts) files that contain
@@ -3216,7 +3147,25 @@
See the \l{Qt Linguist Manual} for more information about
internationalization (i18n) and localization (l10n) with Qt.
- \target UI_DIR
+ \section1 TR_EXCLUDE
+
+ Specifies a list of paths (source files, subdirectories, and C++ include
+ paths) to be excluded from handling in \c{lupdate}. The paths may contain
+ wildcards. Relative paths are considered to be relative to
+ \l{_PRO_FILE_PWD_}.
+
+ For example, to exclude source files:
+
+ \snippet code/doc_src_qmake-manual.pro TR_EXCLUDE sources
+
+ To exclude subdirectories of a \c SUBDIRS project:
+
+ \snippet code/doc_src_qmake-manual.pro TR_EXCLUDE SUBDIRS
+
+ To speed up lupdate's C++ parser, exclude include paths:
+
+ \snippet code/doc_src_qmake-manual.pro TR_EXCLUDE include paths
+
\section1 UI_DIR
Specifies the directory where all intermediate files from uic
@@ -3226,7 +3175,6 @@
\snippet code/doc_src_qmake-manual.pro 54
- \target VERSION
\section1 VERSION
Specifies the version number of the application if the \c app
@@ -3277,7 +3225,6 @@
See also \l{#DEPENDPATH}{DEPENDPATH}.
- \target WINDOWS_TARGET_PLATFORM_VERSION
\section1 WINDOWS_TARGET_PLATFORM_VERSION
Specifies the targeted Windows version; this corresponds to the tag
@@ -3286,7 +3233,6 @@
On desktop Windows, the default value is the value of the environment
variable \c{WindowsSDKVersion}.
- \target WINDOWS_TARGET_PLATFORM_MIN_VERSION
\section1 WINDOWS_TARGET_PLATFORM_MIN_VERSION
Specifies the minimum version of the Windows target platform; this
@@ -3294,7 +3240,6 @@
Defaults to \c{WINDOWS_TARGET_PLATFORM_VERSION}.
- \target YACCSOURCES
\section1 YACCSOURCES
Specifies a list of Yacc source files to be included
@@ -3374,7 +3319,6 @@
\snippet code/doc_src_qmake-manual.pro 59
- \target qmake-cat
\section2 cat(filename[, mode])
Returns the contents of \c filename. You can specify the following options
@@ -3426,7 +3370,6 @@
\snippet code/doc_src_qmake-manual.pro 173
- \target findfunction
\section2 find(variablename, substr)
Returns all the values in \c variablename that match the regular expression
@@ -3442,7 +3385,6 @@
Expands the specified wildcard pattern and returns a list of filenames.
If \c recursive is true, this function descends into subdirectories.
- \target fn_first
\section2 first(variablename)
Returns the first value of \c variablename.
@@ -3451,9 +3393,9 @@
\snippet code/doc_src_qmake-manual.pro 161
- See also \l{take_first()}, \l{fn_last}{last()}.
+ See also \l{take_first(variablename)}{take_first()},
+ \l{last(variablename)}{last()}.
- \target format_number()
\section2 format_number(number[, options...])
Returns \c number in the format specified by \c options. You can specify the
@@ -3504,7 +3446,6 @@
to empty strings. If you need to encode spaces in \c glue, \c before, or \c
after, you must quote them.
- \target fn_last
\section2 last(variablename)
Returns the last value of \c variablename.
@@ -3513,7 +3454,8 @@
\snippet code/doc_src_qmake-manual.pro 162
- See also \l{take_last()}, \l{fn_first}{first()}.
+ See also \l{take_last(variablename)}{take_last()},
+ \l{first(variablename)}{first()}.
\section2 list(arg1 [, arg2 ..., argn])
@@ -3534,7 +3476,6 @@
See also \l{upper(arg1 [, arg2 ..., argn])}{upper()}.
- \target member()
\section2 member(variablename [, start [, end]])
Returns the slice of the list value of \c variablename with the
@@ -3561,9 +3502,8 @@
that an empty list will be returned only when an index is invalid
(which is implied by the input variable being empty).
- See also \l{str_member()}.
+ See also \l{str_member(arg [, start [, end]])}{str_member()}.
- \target num_add()
\section2 num_add(arg1 [, arg2 ..., argn])
Takes an arbitrary number of numeric arguments and adds them up,
@@ -3695,12 +3635,11 @@
See also \l{system_quote(arg)}{system_quote()}.
- \target fn_size
\section2 size(variablename)
Returns the number of values of \c variablename.
- See also \l{str_size()}.
+ See also \l{str_size(arg)}{str_size()}.
\section2 sort_depends(variablename, prefix)
@@ -3714,7 +3653,8 @@
in ascending ASCII order.
Numerical sorting can be accomplished by zero-padding the values to
- a fixed length with the help of the \l{format_number()} function.
+ a fixed length with the help of the
+ \l{format_number(number[, options...])}{format_number()} function.
This function was introduced in Qt 5.8.
@@ -3732,12 +3672,11 @@
Replaces %1-%9 in \c string with the arguments passed in the comma-separated
list of function \c arguments and returns the processed string.
- \target str_member()
\section2 str_member(arg [, start [, end]])
- This function is identical to \l{member()}, except that it operates
- on a string value instead of a list variable, and consequently the
- indices refer to character positions.
+ This function is identical to \l{member(variablename [, start [, end]])}
+ {member()}, except that it operates on a string value instead of a list
+ variable, and consequently the indices refer to character positions.
This function can be used to implement many common string slicing
operations:
@@ -3762,20 +3701,19 @@
\note In these implementations, a zero \c len argument needs to be
handled separately.
- See also \l{member()}, \l{num_add()}.
+ See also \l{member(variablename [, start [, end]])}{member()},
+ \l{num_add(arg1 [, arg2 ..., argn])}{num_add()}.
This function was introduced in Qt 5.8.
- \target str_size()
\section2 str_size(arg)
Returns the number of characters in the argument.
- See also \l{fn_size}{size()}.
+ See also \l{size(variablename)}{size()}.
This function was introduced in Qt 5.8.
- \target system_replace
\section2 system(command[, mode[, stsvar]])
You can use this variant of the \c system function to obtain stdout from the
@@ -3785,9 +3723,10 @@
\snippet code/doc_src_qmake-manual.pro 72
- Like \l {qmake-cat}{$$cat()}, the \a mode argument takes \c blob, \c lines,
- \c true, and \c false as value. However, the legacy word splitting rules
- (i.e. empty or \c true, and \c false) differ subtly.
+ Like \l {cat(filename[, mode])}{$$cat()}, the \a mode argument takes
+ \c blob, \c lines, \c true, and \c false as value. However, the legacy
+ word splitting rules (i.e. empty or \c true, and \c false) differ
+ subtly.
If you pass \c stsvar, the command's exit status will be stored in that
variable. If the command crashes, the status will be -1, otherwise a
@@ -3816,7 +3755,6 @@
See also \l{shell_quote(arg)}{shell_quote()}.
- \target take_first()
\section2 take_first(variablename)
Returns the first value of \c variablename and removes it from the
@@ -3826,9 +3764,9 @@
This function was introduced in Qt 5.8.
- See also \l{take_last()}, \l{fn_first}{first()}.
+ See also \l{take_last(variablename)}{take_last()},
+ \l{first(variablename)}{first()}.
- \target take_last()
\section2 take_last(variablename)
Returns the last value of \c variablename and removes it from the
@@ -3838,9 +3776,9 @@
This function was introduced in Qt 5.8.
- See also \l{take_first()}, \l{fn_last}{last()}.
+ See also \l{take_first(variablename)}{take_first()},
+ \l{last(variablename)}{last()}.
- \target unique
\section2 unique(variablename)
Returns the list of values in \c variablename with duplicate entries removed.
@@ -3918,7 +3856,6 @@
appropriate files are added to the \l{SOURCES} and \l{HEADERS}
variables.
- \target countfunction
\section2 count(variablename, number)
Succeeds if the variable \c variablename contains a list with the
@@ -3997,7 +3934,6 @@
Exports the current value of \c variablename from the local context of a
function to the global context.
- \target forfunction
\section2 for(iterate, list)
Starts a loop that iterates over all values in \c list, setting \c iterate to each
@@ -4008,6 +3944,10 @@
\snippet code/doc_src_qmake-manual.pro 65
+ Loops can be interrupted with \c{break()}. The \c{next()} statement skips
+ the remainder of the loop's body and continues execution with the next
+ iteration.
+
\section2 greaterThan(variablename, value)
Tests that the value of \c variablename is greater than \c value. First,
@@ -4138,9 +4078,9 @@
\snippet code/doc_src_qmake-manual.pro 71
- See also the replace variant of \l{system_replace}{system()}.
+ See also the replace variant of \l{system(command[, mode[, stsvar]])}
+ {system()}.
- \target touchfunction
\section2 touch(filename, reference_filename)
Updates the time stamp of \c filename to match the time stamp of
@@ -4359,7 +4299,6 @@
\snippet code/doc_src_qmake-manual.pro 78
- \target QMAKESPEC
\section1 QMAKESPEC
qmake requires a platform and compiler
@@ -4383,7 +4322,6 @@
\note The \c QMAKESPEC path will be automatically added to the generated
Makefile after the contents of the \l{INCLUDEPATH} system variable.
- \target cache
\section1 Cache File
The cache file is a special file qmake reads to
@@ -4396,7 +4334,6 @@
If qmake finds a \c{.qmake.cache} file then it will process this file first before
it processes the project file.
- \target Extensions
\section1 File Extensions
Under normal circumstances qmake will try to
@@ -4417,7 +4354,7 @@
\li \l{QMAKE_EXT_UI} modifies the extension used for \QD UI files
(usually in \l{FORMS}).
\li \l{QMAKE_EXT_PRL} modifies the extension placed on
- \l{LibDepend}{library dependency files}.
+ \l{Library Dependencies}{library dependency files}.
\li \l{QMAKE_EXT_LEX} changes the suffix used in Lex files (usually in
\l{LEXSOURCES}).
\li \l{QMAKE_EXT_YACC} changes the suffix used in Yacc files (usually in
@@ -4498,8 +4435,8 @@
\snippet code/doc_src_qmake-manual.pro 92
In the above line, \c USE_MY_STUFF will only be added to the list of pre-processor
- defines if it is not already defined. Note that the \l{unique}{unique()}
- function can also be used to ensure that a variable only contains one
+ defines if it is not already defined. Note that the \l{unique(variablename)}
+ {unique()} function can also be used to ensure that a variable only contains one
instance of each value.
\section2 Replacing Values
@@ -4558,7 +4495,6 @@
\snippet code/doc_src_qmake-manual.pro 101
- \target Scopes
\section1 Scopes
Scopes are similar to \c if statements in procedural programming languages.
@@ -4685,7 +4621,6 @@
You can test for any other platform-compiler combination as long as a
specification exists for it in the \c mkspecs directory.
- \target UsingVariables
\section1 Variables
Many of the variables used in project files are special variables that
@@ -4718,7 +4653,6 @@
\snippet code/doc_src_qmake-manual.pro 100
- \target UsingReplaceFunctions
\section1 Replace Functions
qmake provides a selection of built-in
@@ -4744,7 +4678,6 @@
\snippet qmake/replacefunction.pro 0
- \target UsingTestFunctions
\section1 Test Functions
qmake provides built-in functions that can be
@@ -5063,7 +4996,6 @@
to be linked in.
\endtable
- \target LibDepend
\section1 Library Dependencies
Often when linking against a library, qmake
@@ -5117,7 +5049,6 @@
\previouspage Advanced Usage
\nextpage Configuring qmake
- \target Introduction
Precompiled headers (PCH) are a performance feature supported by some
compilers to compile a stable body of code, and store the compiled
@@ -5146,7 +5077,6 @@
\endlist
\endlist
- \target ADD_PCH
\section1 Adding Precompiled Headers to Your Project
The precompiled header must contain code which is \e stable
@@ -5159,7 +5089,6 @@
C++ includes, since the precompiled header file for C files may not
contain C++ code.
- \target PROJECT_OPTIONS
\section2 Project Options
To make your project use precompiled headers, you only need to define the
@@ -5199,7 +5128,6 @@
To avoid potential conflicts like these, give distinctive names to header
files that will be precompiled.
- \target EXAMPLE_PROJECT
\section1 Example Project
You can find the following source code in the
@@ -5513,7 +5441,6 @@
Platform-specific variables are not described here. For more information,
see \l{Qt for Windows - Deployment} and \l{Qt for macOS}.
- \target Application
\section1 Building an Application
The \c app template tells qmake to generate a
@@ -5539,7 +5466,7 @@
\li \l{HEADERS} - A list of header files for the application.
\li \l{SOURCES} - A list of C++ source files for the application.
\li \l{FORMS} - A list of UI files for the application (created using
- Qt Designer).
+ \QD).
\li \l{LEXSOURCES} - A list of Lex source files for the application.
\li \l{YACCSOURCES} - A list of Yacc source files for the
application.
@@ -5633,7 +5560,6 @@
The only primary requirement is that the test program exit with a zero exit code
on success, and a non-zero exit code on failure.
- \target Library
\section1 Building a Library
The \c lib template tells qmake to generate a Makefile that will build a
@@ -5662,7 +5588,6 @@
X11, \macos, and iOS, the library name will be prefixed by \c lib. On Windows,
no prefix is added to the file name.
- \target Plugin
\section1 Building a Plugin
Plugins are built using the \c lib template, as described in the previous
@@ -5676,7 +5601,7 @@
\li VERSION - The version number of the target library. For example, 2.3.1.
\endlist
- \section2 Building a Qt Designer Plugin
+ \section2 Building a Qt Widgets Designer Plugin
\QD plugins are built using a specific set of configuration settings that
depend on the way Qt was configured for your system. For convenience, these
@@ -5687,7 +5612,8 @@
QT += widgets designer
\endcode
- See the \l{Qt Designer Examples} for more examples of plugin-based projects.
+ See the \l{Qt Widgets Designer Examples} for more examples of plugin-based
+ projects.
\section1 Building and Installing in Debug and Release Modes