Commit Graph

3303 Commits

Author SHA1 Message Date
Qt Forward Merge Bot
c3123c757a Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I8dbcf23835d52d3aa7d018ed250814d60c68aa83
2020-01-15 01:00:39 +01:00
Michal Klocek
7d7ba311e0 Fix isysroot for simulator only builds on ios
When not doing fat builds, QMAKE_MAC_SDK_PATH defaults
to iphoneos sysroot, which breaks compilation.

This fixes compilation when user sets also CONFIG-=device

Change-Id: I1d18269946cd2a5608e26d943159c824f31db09a
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2020-01-13 14:48:09 +00:00
Andy Shaw
06a7da3c3d yacc: Output the path for the move with the right directory separator
Change-Id: Ic075711062750dde3e3a6bc7a5ba8da25ddecfe9
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2020-01-13 11:50:02 +00:00
Qt Forward Merge Bot
cccc9d0b95 Merge remote-tracking branch 'origin/5.15' into dev
Conflicts:
	tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp

Change-Id: I4d3041fa291a918c774ffa5eb5c8792a0966451d
2020-01-13 10:13:01 +01:00
Liang Qi
a59c768489 Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	src/corelib/kernel/qobject.cpp

Change-Id: I4780b25665672692b086ee92092e506c814642f2
2020-01-09 20:30:39 +01:00
Jani Heikkinen
1e42c97cf0 Bump copyright year
Change-Id: I9468ef21a2cf03cf07c38f012a2aa9bae6d02a03
Reviewed-by: Johanna Äijälä <johanna.aijala@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2020-01-09 14:41:53 +02:00
BogDan Vatra
ce04fa345d Android: make sure we don't add _$${QT_ARCH} twice
Fixes: QTBUG-80582
Change-Id: I2b3790bb18754e146db611d61c48a3b7a532575c
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2020-01-09 08:25:42 +02:00
Qt Forward Merge Bot
6074ebf728 Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I7be168303fc4fec5892f20f8dcbdf1bdfcd4986f
2020-01-09 01:00:26 +01:00
Friedemann Kleint
75391511ff Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: Ia2ce994c42adc010c453edaeea57f672556958f6
2020-01-07 08:34:53 +01:00
Qt Forward Merge Bot
c75e8a6618 Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I6c81e3cb6272adc5c3de2513792bd48604ff4dd0
2020-01-07 01:01:16 +01:00
Kai Koehne
9b4ec1393f MinGW: Allow debug-and-release builds
Commit 4d289edb14 did disable debug-and-release
for MinGW completely. While it makes sense to change the
default, we should allow people to opt-in to old behavior
by explicitly setting '-debug-and-release'.

To allow differentiation between debug and release libraries
debug dll's (again) have a 'd' suffix.

Fixes: QTBUG-80792
Change-Id: I341b1a94788f490e975be6736159980cd9273f08
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2020-01-06 12:58:16 +01:00
Joerg Bornemann
cca279338c CMake: Fix usage requirements for static builds of Qt on macOS
When scanning the prl files to set up usage requirements for the Qt libraries
we omitted "-framework Foo" flags. Those were passed as linker flags, but not
as interface libraries. Consequently, the frameworks that are used by Qt
libraries were missing on the link line when building against a statically
built Qt.

Fix this issue by scanning the dependencies for "-framework Foo" just like we
do with "-lfoo" flags.

Fixes: QTBUG-80855
Change-Id: Ie7804304141c86207d143a6e1005e78bdc099113
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Kyle Edwards <kyle.edwards@kitware.com>
2020-01-06 12:48:40 +01:00
Qt Forward Merge Bot
3a010f72b8 Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	src/corelib/kernel/qvariant.h

Change-Id: I8f3873e74b9795ac889e7c7ec5de2619bca92160
2020-01-06 07:20:18 +00:00
Liang Qi
a503bf5470 Merge remote-tracking branch 'origin/5.15' into dev
Conflicts:
	src/corelib/tools/qvector.h
		Make QVector(DataPointer dd) public to be able to properly merge
		5b4b437b30 from 5.15 into dev.
	src/widgets/kernel/qapplication.cpp
	tests/auto/tools/moc/allmocs_baseline_in.json

Done-With: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Change-Id: I929ba7c036d570382d0454c2c75f6f0d96ddbc01
2020-01-04 15:32:34 +01:00
Andy Shaw
ef4448f129 Always add the extra Android apk and aab targets
The extra targets should be added to the project regardless so that
qmake can handle it appropriately. This enables make apk to work
correctly then from a SUBDIRS project.

Fixes: QTBUG-80351
Change-Id: If5903e0d2f543babfdb4ebbb13502e32ab97c6fc
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2020-01-02 14:27:05 +00:00
Andy Shaw
ee1b77e132 dumpcpp: Use tblCopy to ensure the path is detected correctly
This amends faf742b05d

Change-Id: Ia80a4274f61d895c297b2fae5df62c86db95c14c
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2020-01-02 14:26:26 +00:00
Qt Forward Merge Bot
4054c0d6ed Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	.qmake.conf
	src/plugins/platforms/xcb/qxcbscreen.cpp
	src/widgets/accessible/qaccessiblewidget.cpp

Change-Id: Ib3138e61ba7981610940509a7ff02ba2dd281bf0
2019-12-27 09:29:30 +01:00
Ulf Hermann
3ea7caed6f metatypes: Add no_check_exist to INSTALLS rule
Without this, the metatypes files are not installed if they don't exist
when qmake runs.

Change-Id: I014fcc1d1c41a7fab48870842f5e27f5b62dfed3
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-12-23 10:33:22 +01:00
Tor Arne Vestbø
fe784abc80 iOS: Silence GL deprecations until we can fix them
Change-Id: I1222708be5017a0dca381f365349fce5887a0bcb
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-12-20 12:23:37 +01:00
Tor Arne Vestbø
669a29f5e7 Xcode: Disable GPU frame capture and Metal API validation by default
The auto-detection Xcode has for whether GPU capture should be enabled
always enables it for our projects, which adds up to second to the
startup time when debugging. There's no need to pay this cost unless
you're actively debugging Metal code.

Change-Id: I4a76c4e7afedad4bb43395ae64bc0f8d62eca6be
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2019-12-18 19:16:09 +01:00
Lorn Potter
868ded6d87 wasm: do not use clamp mode for upstream LLVM
Emscripten version 1.39.0 and above are based upon upstream LLVM, which
does not contain BINARYEN_TRAP_MODE

Fixes: QTBUG-80691
Change-Id: I6129f84a31a607c202e13847b50705ef1c809630
Reviewed-by: jian liang <jianliang79@gmail.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-12-16 18:31:02 +10:00
Liang Qi
ee71a9ba81 Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	src/network/ssl/qsslsocket.cpp
	src/widgets/kernel/qapplication.cpp

Change-Id: Ib7421cc2df59d0969f89b3fbd65a17ea76ffef3b
2019-12-16 07:05:19 +01:00
James McDonnell
fc95ad8616 Add default location for the Wayland scanner tool on QNX
Change-Id: I0cfa823414a8f7866c594edb60b09b60f2b4d16b
Reviewed-by: Dan Cape <dcape@qnx.com>
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
2019-12-14 11:22:54 -05:00
Qt Forward Merge Bot
56b0dabf80 Merge remote-tracking branch 'origin/5.14.0' into 5.14
Change-Id: I03927d2ef75514e4f2633839387806125d8954f1
2019-12-13 12:46:12 +01:00
Andy Shaw
1dca7087e9 Account for when qtquickcompiler is used when getting the resources
When passing the resources used to the android deployment setting json
file it needs to check the variable generated by the qtquickcompiler
feature so that it can still find the qrc files originally populated in
the resources. This ensures that qmlimportscanner can still scan the
original qrc files when determining which QML import plugins are
needed.

Fixes: QTBUG-80713
Change-Id: I695b289eaaa78cc6c355fa8abd22a8a1031a9f6c
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2019-12-12 09:55:55 +01:00
Qt Forward Merge Bot
11d7788c18 Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I69238f23882deebeaad46e4fdcf899ab22cc2b8f
2019-12-12 01:01:04 +01:00
Qt Forward Merge Bot
a4a7c1bcf7 Merge remote-tracking branch 'origin/5.15' into dev
Conflicts:
	tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp

Change-Id: I6b82507bf9a80a374c40393e72f4843f1557de89
2019-12-11 14:50:53 +01:00
Lorn Potter
93d261b965 wasm: enforce emscripten version
This creates a define in the binary, as well as writing emscripten
version for qmake.

It also enforces app builder to use a certain known version.

Task-number: QTBUG-77745
Change-Id: I37691512171635cec66aa3ffa16258081f3f1e1b
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-12-11 06:06:45 +10:00
Joerg Bornemann
c5777ad81c Fix calls to qtFlattenResources from outside resources.prf
The xml_escape function must be part of resources_functions.prf, and the
qmake_immediate resource must not be created multiple times. Instead,
create another qmake_immediate resource with a number suffix.

This commit amends 577b6554.

Task-number: QTBUG-79672
Change-Id: Ibbe20c0fd1940f1fe7733cd1e5b0891f65689782
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-12-10 16:13:51 +01:00
Liang Qi
90210d5d9c Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	tests/auto/network/kernel/qnetworkinterface/BLACKLIST

Change-Id: I1e8866c63b54bcd95fc2a044276ee15b7f60e79a
2019-12-10 13:51:40 +02:00
Lorn Potter
73fada6d70 wasm: Fix clamp mode
Clamp mode was being obliterated by not appending to EMCC_COMMON_LFLAGS
This fixes crashes of integer overflow

Change-Id: Icae757a7189de25db5ed41df6d41d86304c39830
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-12-10 09:57:21 +10:00
Joerg Bornemann
485e4a8f0b WebAssembly: Do not use sed directly for wasm_shell.html deployment
Use $$QMAKE_STREAM_EDITOR, instead, which will on Windows expand
to "qmake -install sed" (triggering qmake's own sed implementation)
and otherwise expand to "sed".

Change-Id: I57da5fb3a4f6e5a09ae25c947caa0a10d279b480
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-12-09 17:49:19 +01:00
Qt Forward Merge Bot
0c29ebe374 Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I4134c0c6b6c9911950f58b3b5c86e789d28a185b
2019-12-04 01:00:23 +01:00
Ulf Hermann
e62d04b933 Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	src/corelib/serialization/qcborvalue.cpp

Change-Id: I675a3029955c96e81a33ed9d98b72b55b6784b52
2019-12-03 06:57:05 +01:00
BogDan Vatra
d463a63bb9 Set proper TARGET name for libs
When doing a multi ABI build in one go, if the TARGET is the same,
we'll endup with only one library which is not okay.

Task-number: QTBUG-80351
Change-Id: I0c5ff24480446d671e59dbd5a045f9889dff39e9
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-11-29 20:24:52 +02:00
Qt Forward Merge Bot
ad4ef9836c Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: Ib8357609b37b7cc22b51c27602ba60c69bf91da9
2019-11-29 01:01:08 +01:00
Aaron Linville
d60b71d635 Fix CONFIG += cmdline testcase creating app bundle paths in Makefiles
Fix an issue where qmake on macOS will generate a Makefile with a path
to a macOS bundle instead of a bundle-less executable in the Makefile's
check rule if cmdline is specified before testcase in the CONFIG
options.

Fixes: QTBUG-80280
Change-Id: Icc9ee1355b0641981ce79526b36f29957e1afb00
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-11-27 22:38:02 -05:00
Lorn Potter
20891777bb webassembly: enable opengl es3
Our WebGL 2 support is half finished, since we use surface format verion of 3
to map to webgl2, but do not enable Open GL ES3 needed for WebGL2 support.

This allows glDrawArrays and glDrawElements to be used

Change-Id: Ifbd434f4d25e49f671145a6727999a90920d6810
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-11-28 00:07:53 +00:00
Andy Shaw
84892e5e69 Get make docs working better on macOS
The system include paths need to be added to the include
paths passed to Clang so it can find the standard types.

Change-Id: I83e13e73a606130e3bc4762b01368bcd4a8bb0dc
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
2019-11-25 17:43:23 +01:00
Qt Forward Merge Bot
58c69df4d3 Merge remote-tracking branch 'origin/5.15' into dev
Conflicts:
	src/corelib/tools/qhash.h
	src/gui/kernel/qevent.h
	src/widgets/kernel/qshortcut.cpp
	src/widgets/kernel/qshortcut.h

Change-Id: If61c206ee43ad1d97f5b07f58ac93c4583ce5620
2019-11-25 11:30:04 +01:00
Alexandru Croitor
8c6824f2af CMake: Fix static build linkage with CMake version lower than 3.13
After appropriate link flags are determined, they are added to the
INTERFACE_LINK_OPTIONS property. Unfortunately this property was added
in 3.13, and thus static builds on Windows for instance failed with
missing symbols due to missing system libraries on the link command
line, when the CMake version was lower.

When detecting a lower version, add the flags instead to
INTERFACE_LINK_LIBRARIES, which is a property that is available in
older CMake versions. To do this we have to strip the SHELL: prefix,
which means that the added link flags might get deduplicated, and thus
it can happen that the linking phase might still fail.

Nevertheless, on Windows this improves the situation when using an older
CMake version.

Amends 44602224bf

Task-number: QTBUG-38913
Change-Id: Ib710b8ea691d4a9281dcd5f5b9700b11df0a5c10
Reviewed-by: Kyle Edwards <kyle.edwards@kitware.com>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-11-25 09:14:09 +01:00
Joerg Bornemann
e55a61a77f Fix passing FOO_LIBS variables to configure
This amends commit 9864d2c6. Some variables that are set in
qtConfLibrary_inline were not exported.

Fixes: QTBUG-78873
Change-Id: I10d766c1f41d2baa61967ee931a6631346cac2e9
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-11-19 18:35:49 +01:00
Qt Forward Merge Bot
adc7bbe910 Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts:
	src/gui/rhi/qshader.cpp
	tests/auto/corelib/time/qtimezone/tst_qtimezone.cpp

Change-Id: I1c4ae718eb3592a0a0a90af9d11553f3ab68cad5
2019-11-15 16:29:40 +01:00
Robert Loehning
6e42ed217c configure: Add sanitizer "fuzzer-no-link"
Adds instrumentation for fuzzing to the binaries but links to the usual
main function instead of a fuzzer's. The similar sanitizer "fuzzer"
should then be used only for building the test itself.

Requires clang 6 or higher.

Change-Id: I24ee1f018b0b97f2977dc86fbdc29a164d7c4e01
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-11-14 15:45:02 +01:00
Ulf Hermann
1e5d1a43dc Make sure the metatypes are installed in prefix builds
The JSON collection step has to be target_predeps in order to be
executed if the only place its output is referred to is INSTALLS.
Furthermore, some CONFIG options clear the INSTALLS variable.
Therefore, we need to add the metatypes CONFIG entries after
those.

Change-Id: I4694ab1d82c13cb4e3886c1722a03255d14b7f29
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-11-13 15:26:03 +00:00
Ulf Hermann
63dae62b7f In prefix builds, copy metatypes JSON to MODULE_BASE_OUTDIR
Otherwise we cannot find them when building further projects within the
same module. For example, qmlmodels needs the metatypes of qml in order
to build its plugins.qmltypes file, but the QML metatypes would only be
available after installing.

Change-Id: Ic2cdfa5b57fd3e5977eea16f2a9b192386737a1f
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-11-13 16:25:53 +01:00
Andy Shaw
2735c5bf06 Add support for passing qrc files to qmlimportscanner
With the qrcFiles entry in the deployment JSON for Android, it can now
pass this on to qmlimportscanner for scanning the qrc files for the
available imports. This enables qmake to populate the qrc files it has
referenced in the project, be it generated by qmake or added by the
user.

Task-number: QTBUG-55259
Change-Id: Ic512ce6f24508b3ea09ebdd07ac4446debfd9155
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-11-13 14:00:39 +01:00
Liang Qi
d140f2f614 Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	examples/widgets/widgets/scribble/mainwindow.cpp
		This amends cb54c16584.

Change-Id: Iaae60a893330524b2973917e23b31f9d51f8bd38
2019-11-13 07:21:33 +01:00
Ulf Hermann
e927d83407 Disambiguate do_install target in metatypes.prf
qmake matches those targets in a purely lexical way, disregarding any
scopes. do_install is much too generic and clashes with another
do_install target in the qmltypes installation code in qtdeclarative.

Change-Id: I8edab329eacc548cee880a9182a1e5ae4dd095fb
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2019-11-11 10:20:13 +01:00
Ulf Hermann
18753e5493 Don't create duplicate plugins.qmltypes rules
If the qmltypes are generated by qmltyperegistrar, we should not offer a
rule to generate them using qmlplugindump. Otherwise we get warnings
from make.

Change-Id: Ifb88cbff8e6c577f9889ff3f071bf31f48f634ad
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2019-11-11 10:20:13 +01:00
Joerg Bornemann
8ffb200153 Fix LTCG linker flags for macOS with separate debug info
The linker must not throw away the lto.o file. We now instruct the
linker to create a non-temporary lto.o, dependent on the target name.

In order to do that we introduce a new mkspec variable
QMAKE_LFLAGS_LTCG_SEPARATE_DEBUG_INFO. This variable can contain
single-$ variable references that get evaluated when loading ltcg.prf.

Fixes: QTBUG-72846
Change-Id: I0ea882628d63e5406ba0ee68c7435af597364b0f
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-11-08 17:00:17 +01:00
Qt Forward Merge Bot
78c687f98e Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I963b5f48b5d6f3500ca379fbd7f1a4290b570175
2019-11-08 09:11:02 +01:00
Qt Forward Merge Bot
75f791419c Merge "Merge remote-tracking branch 'origin/5.13' into 5.14" 2019-11-06 19:44:29 +01:00
Andy Shaw
b274f656b8 Be able to create a response file for other generators too
When building an application for Android on Windows it is possible that
the command line will be too long when doing the link step. So the code
for generating a response file is moved to MakefileGenerator so it can
be used by the other generators easily. The same variables used by
MinGW can be used elsewhere then.

Fixes: QTBUG-71940
Change-Id: I6c331d12e9541a90a4a95e0154d0ea1c056489bc
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-11-06 18:14:17 +01:00
Qt Forward Merge Bot
e3cc16e9fb Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	.qmake.conf
	mkspecs/features/mac/default_post.prf
	src/corelib/tools/qsimd_p.h
	src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
	util/qfloat16-tables/gen_qfloat16_tables.cpp

Change-Id: If48fa8a3bc3c983706b609a6d3822cb67c1352a4
2019-11-06 11:41:19 +01:00
Tor Arne Vestbø
2e63d12183 Update supported platforms and build requirements for Apple platforms
Per earlier discussions we bump the deployment target for LTS releases
and follow up by requiring the latest SDK available for building.

As layer backed views and dark mode is a lot more stable these days in
Qt and on macOS in general we no longer support the option to build with
the 10.13 SDK. A workaround in case this functionality is still needed
is to explicitly set the QMAKE_MAC_SDK_VERSION qmake variable, which
will tell the linker to write that version into the MachO header of
the executable, which will then be read by AppKit when determining
which features to opt in to.

Change-Id: Ied4f6d75b710505a5c440c990b82567bea780db6
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-11-05 19:49:14 +01:00
Joerg Bornemann
577b6554f0 Move RESOURCE flattening code to dedicated function
Introduce resources_functions.prf with the test function
qtFlattenResources which ensures that RESOURCES has a flat structure,
e.g. only contains *.qrc entries.

This can be called by other .prf files like qtquickcompiler.prf
without disturbing the ability to extend RESOURCES in other .prf files.

Task-number: QTBUG-79672
Change-Id: I43246e40f5ea52a9d9c917a1bd781aeeb1304acc
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-11-05 14:51:29 +01:00
Kai Koehne
99e43db7ce Fix regression in how "pkg-config --static" output is handled
Change a1ea498789 did replace different pkg-config calls for
-L, -l arguments to one. Anyhow, it also removed the eval() call that
ensured that the return string was split by whitespace, meaning that
paths couldn't resolve anymore properly if multiple arguments were
returned.

Fixes: QTBUG-79668
Change-Id: I4091fea6891ef79836e05f8e87ffa9d69863a8f5
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-11-04 09:31:56 +01:00
Joerg Bornemann
c0bde0da81 Fix cross-compilation to Linux
The CROSS_COMPILE variable wasn't picked up by the linux-g++ mkspec.
Now it's possible to cross-build Qt on FreeBSD to Linux, for example.

Fixes: QTBUG-79255
Change-Id: Ib1cd8ed3d5ef0af42f2d47af8f6d2c2ff5356adc
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-11-04 08:28:20 +00:00
Qt Forward Merge Bot
4b0af2cdbf Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I68a6ed3184e62fa89c47c564bb01002c0918d0fd
2019-11-01 01:01:02 +01:00
Qt Forward Merge Bot
c51ca1d1b2 Merge remote-tracking branch 'origin/5.13.2' into 5.13
Change-Id: Ieb5afc87086758119bcfc8efbe355f5c0a93fc04
2019-10-30 06:52:03 +01:00
Qt Forward Merge Bot
cd04181b2b Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I7f11733bda960196a96c6452bdabeb7072a8430d
2019-10-30 01:00:33 +01:00
Qt Forward Merge Bot
a317bff298 Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: Ib4df563fc7b1f7c40f425e0e71180d9517a672be
2019-10-30 01:00:14 +01:00
Qt Forward Merge Bot
08f90adffd Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	src/corelib/serialization/qjson_p.h

Change-Id: I83cea141a4de8b3998478bfded84ca9029f7a2a9
2019-10-28 10:50:03 +01:00
Francisco Boni
a9b34f5726 QRandom: add support for RDSEED on INTEL_ICL & MSVC
We set the macro for RDSEED because neither MSVC nor the Intel compiler
on Windows defines the macro. The implication is that when qRandomCpu()
calls qCpuHasFeature() in simd.cpp, qDetectCpuFeatures() correctly
receives the expected CPU features enabled in the build from
qCompilerCpuFeatures, namely CpuFeatureRDSEED (qsimd_x86_p.h)

Change-Id: I5741d4f956a93f21c358af8a4ee393c1741b85ee
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-10-27 15:53:58 -03:00
Qt Forward Merge Bot
8bcecd86fa Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I182a639748760393f9e6b0724259201588aeaae3
2019-10-27 01:00:50 +02:00
Qt Forward Merge Bot
7b3bdcbfe8 Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I379794a01cbf6fb39d94b24cc8c90b1971a212b9
2019-10-26 01:01:32 +02:00
Qt Forward Merge Bot
86e74d60d2 Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I208a36bf1c88c8291baaa5ca8fe8e838bc9d7aea
2019-10-26 01:01:14 +02:00
Christian Romberg
6acab25f97 Remove GCC-style PCH directives from android-clang mkspec
As described in QTBUG-72404, the android-clang mkspec has the gcc pch
style hardcoded for no reason. This change removes the respective lines.

[ChangeLog][qmake][Android] Remove gcc-style PCH directives from the
android-clang mkspec.

Fixes: QTBUG-72404
Change-Id: Iad42651e25ecce08eda7aa5fa8bbf531c9497896
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2019-10-25 07:04:57 +00:00
Qt Forward Merge Bot
375efdd0e1 Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: Iebedaa967a263854f18cd403ce007d7965f26d2b
2019-10-25 01:00:16 +02:00
BogDan Vatra
86a0f1cfd7 Add build-id flag
This flag is needed by LLDB & simple perf tools to locate the right binary.

Change-Id: Iffa1b0678663cfb9d1d699da5ad6fe672863918c
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-10-24 12:30:53 +03:00
Oliver Wolff
c686e885c0 qmake: Disallow building Qt examples inside the source tree
Building examples inside a Qt source tree is considered unsupported.
Instead of checking, whether the build is done "in source" inside the
source directory, we also have to check for "shadowed example builds" as
they are done by Creator. An example would be:
qtbase/examples/widgets/widgets/build-wiggly as a shadow build for
qtbase/examples/widgets/widgets/wiggly.

Fixes: QTBUG-76237
Change-Id: Iceb88af006fad249a4c13fa0b0345cf3f7086252
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-10-24 10:41:29 +02:00
Ulf Hermann
4514b67d7c moc: When generating metatypes, allow empty MOC_DIR
We don't want the metatypes to be generated into the file system root in
that case.

Change-Id: I91bab20fa498de0f2918d8ee5b2f230cc0610aae
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-10-24 09:27:00 +02:00
Christian Romberg
8409844bd6 Fix java mkspec for compatibility with JDK 12
Starting with JDK 12, javac no longer supports source and target
version 6. This commit changes the source and target version to 7.

[ChangeLog][General]

Fixes: QTBUG-79094
Change-Id: Ife8966db01c68251de2fe85307de30c31e658172
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-10-21 07:54:01 +02:00
Tor Arne Vestbø
a254472a49 Xcode: Ensure there's always a CFBundle[Short]Version[String] set
Leaving it empty resulted in errors from Xcode when compiling the app.

Task-number: QTBUG-25309
Task-number: QTBUG-74872
Change-Id: I61b0f47d754c5f5b181a6f918283d990458cc78d
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
(cherry picked from commit 1d1ed01711)
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-10-18 06:42:35 +02:00
Francisco Boni
da12c06b99 Fix build with ICC under IPO on Windows
qmake.conf(25) incorrectly sets QMAKE_CFLAGS_DISABLE_LTCG to -Qno-ipo.
The correct form to disable IPO on Windows with ICC 18.x and 19.x should
be: -Qipo-. The implication is that the CONFIG feature in simd.prf (31)
modulating the compilation of specific ISA optimized sources now
successfully disables IPO on intel_icl when needed.

Fixes: QTBUG-78976
Change-Id: Id691f69b909d2bbba77402ff4f0b17b3b07ad6f3
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2019-10-13 15:08:43 -03:00
Qt Forward Merge Bot
8d8140dffa Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I9953c1ca16862184c2373027e946c482ce8e6f0e
2019-10-13 01:00:43 +02:00
Joerg Bornemann
a90899df43 Default to #!/bin/bash in wrapper scripts on macOS
This gives the user the opportunity to employ BASH_ENV to circumvent
macOS System Integrity Protection and set variables like
DYLD_FRAMEWORK_PATH.

Fixes: QTBUG-57204
Change-Id: Icd99d903a3be76fabd509e204ea61a254a96609c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-10-12 09:57:28 +02:00
Liang Qi
9c84b7786c Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	src/plugins/platforms/xcb/qxcbscreen.h
	src/src.pro

Change-Id: I4e1981e69a1ddcbe4078ec6ab2a64b0da6a445de
2019-10-10 09:13:49 +02:00
Thiago Macieira
780137d585 QRandom: add support for RDSEED
The Intel whitepaer[1] recommends using the RDSEED over RDRAND whenever
present. libstdc++ from GCC 10 will also use it in std::random_device.

[ChangeLog][QtCore][QRandomGenerator] The system() random generator will
now use the RDSEED instruction on x86 processors whenever available as
the first source of random data. It will fall back to RDRAND and then to
the system functions, in that order.

[1] https://software.intel.com/en-us/articles/intel-digital-random-number-generator-drng-software-implementation-guide

Change-Id: I907a43cd9a714da288a2fffd15bab176e54e1975
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-10-09 07:31:28 -07:00
Milian Wolff
63a3b26b6b Fix QMake build system to support trace points in a cross-compiled build
CONFIG(cross_compile) implies CONFIG(force_bootstrap). The latter is
errorneously used within qt_tracepoints.prf and to decide when
tracegen is to be build.

For the tracepoints, we just need to check if etw/lttng trace points
are enabled.

For tracegen, we don't need to check anything - it doesn't depend
on etw or lttng, it is just a code generator similar to moc or rcc
and should be handled like these tools.

Change-Id: I3784b37db10680efd0ed7ee7860059bdf62b4118
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-10-09 16:20:08 +02:00
Kai Koehne
a1ea498789 configure: Do use pkg-config --libs for static libs
This ensures that also linker commands like -pthread are returned.

Fixes: QTBUG-77159
Change-Id: If9ab3797ccfb52c6b96a4ab120c59fd8896d5466
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
(cherry picked from commit 4ddc50c0cd16ddd146ea9ea21d6565c8f4a5e2bc)
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-10-09 07:27:14 +00:00
Joerg Bornemann
53ac8094b1 Fix PRE_TARGETDEPS for iOS projects
This variable was ignored for iOS projects, because the generated
Makefile includes xcodebuild.mk that defines its own default target.

Export PRE_TARGETDEPS to the Makefile before including xcodebuild.mk
and use it there for the dependencies of the generic build targets.

Fixes: QTBUG-41325
Change-Id: I5faa82e05570974b5a844ae95b0a012c3badc64a
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-10-08 17:24:57 +02:00
Qt Forward Merge Bot
327b305e95 Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: I554a2762890391b3b6013c8b82211a8386a4ced8
2019-10-05 01:01:06 +02:00
Simon Hausmann
da284ef10e Add support for machine-readable JSON output to the MOC
The --output-json parameter will make moc produce a .json file next to
the regular output file. With --collect-json the .json files for a
module can be merged into a single one.

Task-number: QTBUG-68796
Change-Id: I0e8fb802d47bd22da219701a8df947973d4bd7b5
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2019-10-04 18:35:29 +02:00
Tor Arne Vestbø
0768a28fbf Remove CFBundleGetInfoString from Info.plist templates
Is't been deprecated since Mac OS X 10.5.

Task-number: QTBUG-74872
Change-Id: I8b1ad7aca6448883cb164fd0c4b329592ca60548
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-10-04 13:09:34 +00:00
BogDan Vatra
fcb78b5000 Android: Fix plugins naming
Android 5 doesn't extract the files from libs folder unless they are prefixed with "lib".
This patch sets a proper name for the plugin which will make gdb happy and it will also
avoid any name clashes.
If we rename the plugins when we copy them, gdb won't find them, therefore it can't load their
symbols.
On Android all the libs are in a single folder, so to make sure we don't have any name clashes,
we are prefixing the plugin name with it's relative path to qt folder (we replace / with _).

Fixes: QTBUG-78616
Change-Id: I7e0e67d65448532769d69f46b1856c029e2cf5cb
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-10-01 11:36:24 +03:00
Laszlo Agocs
d83995caab Add an i.MX8 (aarch64) device spec
Not much different from i.MX6, apart from switching to aarch64 and the
appropriate tune flags.

[ChangeLog][Platform Specific Changes][Linux] Added a device spec for
64-bit i.MX8 systems (Vivante graphics stack)

Change-Id: I1fe939fca87d5f3031cefbf43fa359aeeaf44752
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2019-09-28 08:36:12 +02:00
Tor Arne Vestbø
fc4a6b0b97 Fix rpath on UIKit systems
Change-Id: I0b35c32f3730dc15d868b10489abeda909bbe926
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-09-25 15:39:10 +02:00
Tor Arne Vestbø
9a1eb86f3d macOS: Prevent warnings about object files without any symbols
Change-Id: Iafe976bdd27da0476b2e6bb6d84db8ca34aa0a62
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-09-25 15:39:02 +02:00
Tor Arne Vestbø
1d1ed01711 Xcode: Ensure there's always a CFBundle[Short]Version[String] set
Leaving it empty resulted in errors from Xcode when compiling the app.

Task-number: QTBUG-25309
Task-number: QTBUG-74872
Change-Id: I61b0f47d754c5f5b181a6f918283d990458cc78d
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-09-23 16:02:59 +00:00
Laszlo Agocs
60e20abf19 Add a RPi4 device spec
[ChangeLog][Platform Specific Changes][Linux] Added a device spec for
Raspberry Pi 4 (32-bit, V3D)

Change-Id: Idea889842a89dcc74705f1bb9559953dadc07251
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2019-09-22 15:49:40 +00:00
Joerg Bornemann
73f880d393 Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	qmake/generators/makefile.cpp
	qmake/generators/makefile.h

Change-Id: I4c2deac4f6376c85f5e4fe7fb0ccc9ab9a013cd7
2019-09-20 08:20:47 +02:00
Simon Hausmann
4d289edb14 Disable debug-and-release builds for MinGW
The requirement to separate debug and release DLLs on Windows stems from
the Visual Studio C run-time library appearing in two different variants
(debug and release) and not mixing well. It's possible to perform builds
without optimzations and with debug symbols while linking against the
release version of the C run-time, but at the same time the debug
version of the run-time brings other developer visible advantages.

MinGW on the other hand does not have this distinction, does not ship
with separate DLLS and does also not require the VS C runtime library.
Therefore we do not need this separation for MinGW, which means that our
packages can be reduced in size and application developers wishing to
debug their applications do not have to use debug builds of the Qt
libraries or run into Qt internal debug code.

Task-number: QTBUG-78445
Change-Id: Idf588606091298dc44262c4c89e689df18d34747
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-09-18 06:28:16 +00:00
Joerg Bornemann
90779d96ad Ignore non-existent .ui file dependencies
Commit 80dea664 broke .ui files with global includes that are not part
of the project, because we blindly added every file path that falls
out of 'uic -d' as dependency.

Introduce the extra compiler CONFIG flag dep_existing_only to bring
back the old behavior that ignores non-existent dependencies and set
it for uic.

Change-Id: I6eaa82817c932a98ebac6d08115a9815d4b9dd21
Fixes: QTBUG-78144
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-09-18 08:24:46 +02:00
Joerg Bornemann
1456b8091a Make it possible to undefine NDEBUG for nmake and VS projects
For nmake and VS projects we added the NDEBUG define for the release
configuration unconditionally within the qmake generators. To undefine
it, users had to use a nasty work-around.

Now, define NDEBUG within the MSVC mkspecs. In order to do that we
introduce the DEFINES_RELEASE and DEFINES_DEBUG variables that are
merged into DEFINES in default_pre.prf.

Users can unset NDEBUG by writing
    DEFINES -= NDEBUG
in their .pro file.

Note that DEFINES_RELEASE and DEFINES_DEBUG are merged in
default_pre.prf in order to give extra compilers (like moc) the chance
to see the fully resolved DEFINES variable. This is different from the
QMAKE_CFLAGS_(DEBUG|RELEASE) variables that get merged in default_post.prf.

Fixes: QTBUG-78071
Change-Id: I381770a1d2f974fbae9b09a2254e3f2fc7842b68
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-09-18 08:24:38 +02:00
Joerg Bornemann
983cfc773d Fix Vulkan SDK detection for MinGW cross-compilation
We must not set QMAKE_INCDIR_VULKAN if the Vulkan SDK is installed in
some default include directory. MinGW's std headers rely on
#include_next, which will break if we mess with the order of default
include paths.

Fixes: QTBUG-76660
Change-Id: I5ee0fc4c328ff88b979a8c1c010472b3883dff8d
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-09-18 08:24:26 +02:00
Joerg Bornemann
9864d2c6f3 Revert "configure: actually resolve libraries into full filepaths"
This reverts commit 521a85395d.

Having libraries resolved to absolute file paths by configure has
annoying consequences:
1. The Qt installer needs to unabsolutify paths in all kinds of files.
This is error-prone and fragile.
2. It hurts Qt's relocatabilty. The absolute paths are unlikely to be
right on different systems.
3. Qt's configure must imitate linker behavior correctly to do the
resolution right on every platform, which is hard to get right.

Consequently, the disadvantages of 521a8539 outweigh the advantages.

Task-number: QTBUG-72903
Change-Id: I3e159c46a1348963615b95614e56f026ecb2aefd
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-09-13 10:47:38 +02:00
Qt Forward Merge Bot
104f0535a1 Merge remote-tracking branch 'origin/5.13' into 5.14
Change-Id: Idcf8fc1d79bcd84b494d7f43308e6fe82d60e1a4
2019-09-13 01:00:15 +02:00
Alexandru Croitor
be21ff11b7 CMake: Fix usage of debug frameworks on macOS
If an app wants use a debug framework of Qt, it is still expected that
the app should link against the release version, and just set
DYLD_IMAGE_SUFFIX=_debug when running the app.

This was not the case before, where the CMake Config files told CMake
to link explicitly against the debug libraries. This caused crashes
due to the Qt plugin loader mechanism still trying to find a release
platform plugin, which in turn would load release libraries, and thus
the application would end up loading both debug and release plugins.

Make sure the Config files in a framework case always reference the
release libraries (even though this might be counter intuitive).
Otherwise users of the Debug Config files would always get
crashes.

Fixes: QTBUG-78131
Change-Id: I88b1dc421477ad186012ca67b328a891128eb568
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-09-10 16:48:47 +02:00
Friedemann Kleint
1d53b6d9f2 Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	tests/auto/gui/text/qtextlayout/tst_qtextlayout.cpp

Change-Id: Idd3ca5cb9a2b95a4c3513b2a4c8966e6f56193f1
2019-09-09 07:51:49 +00:00
Qt Forward Merge Bot
1f35c8caa0 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I371c5ae1af6f58e32e579671f485b92b586e0b76
2019-09-08 11:33:28 +02:00
Qt Forward Merge Bot
a9db729095 Merge remote-tracking branch 'origin/5.12.5' into 5.12
Change-Id: I41a252fdbf22551aadb0b1a6e9ecf3f95f99fbd4
2019-09-07 13:08:26 +02:00
BogDan Vatra
891b1f51b9 Android: Fix cmake generator
Fixes: QTBUG-29859
Change-Id: Id0b5f9ab8b4866483361ba9f15cf51dc0d2627d0
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-09-07 06:53:19 +03:00
Joerg Bornemann
cc32a69193 Fix CMake config files for -libdir different from "lib"
When Qt was configured with -libdir different from "lib", one could not
build with CMake whenever a static lib was pulled in (e.g. uitools).

Do not hard-code "/lib" but use the correct variable also for static
libraries.

Fixes: QTBUG-76255
Change-Id: I28c6861752e29e461247628d2b1f8a9ec32f0790
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Fabian Vogt <fabian@ritter-vogt.de>
2019-09-06 13:13:32 +02:00
Liang Qi
6a36fe904c Merge remote-tracking branch 'origin/5.13' into 5.14
Conflicts:
	src/corelib/codecs/qicucodec.cpp
	src/dbus/qdbusserver.cpp
	src/gui/painting/qbezier.cpp
	src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp
	src/plugins/printsupport/cups/qppdprintdevice.cpp

Change-Id: I2703128bb64baf5580fbc2c2061b55b0f0611d2a
2019-09-04 07:03:54 +02:00
BogDan Vatra
162e23d838 Android: Add aab target
Move aab, apk, apk_install_target to !build_pass, otherwise these targets
will be executed for each android abi.

Change-Id: I18f6c8946f503f2c08338f24758bf9059987fe0f
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-09-02 18:32:29 +03:00
Qt Forward Merge Bot
3176c821bf Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I9823da32168e99bbece2f8337d0bd4d33e6d634c
2019-08-31 01:00:48 +02:00
BogDan Vatra
65dfc485ad Android: clean configure params for android
-android-toolchain-version is not needed anymore as we are using exclusively the llvm toolchain.

Change-Id: Ia033297a6a2c968352c364758eb1436380a5f96e
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-30 22:29:14 +03:00
BogDan Vatra
c28b881c98 Android: Use LLVM tools where possible
Properly set CROSS_COMPILE qmake variable

Fixes: QTBUG-77890
Change-Id: I73e22d0f936d35c373c064d30ea8d92005d79b2c
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-29 09:45:37 +03:00
BogDan Vatra
8e54fc0880 Android: AUX template doesn't require a multi arch build
Change-Id: I7b7abe7f016b4b85546986354653fc4ddf320dcc
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-29 09:45:34 +03:00
Tor Arne Vestbø
0844be34ba iOS: Skip explicit dead code stripping when generating Xcode projects
Fixes: QTBUG-73680
Change-Id: I5d17ef6321bb1f800c39c3f80dca9527ad343d12
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-28 13:58:39 +02:00
BogDan Vatra
0315e1945e Android: install qmlfiles only for first ABI
qmlfiles are the same for all ABIs, and installing them for all leads to race condition

Change-Id: I69fe062f59f1d7c028dff5212e2f2fac7e71398d
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-28 13:50:31 +03:00
BogDan Vatra
3db14b5bd3 Say hello to -android-abis configure param
This configure parameter is useful to compile Qt only for a selected ABIs.

The old parameter, -android-arch, does the same thing, it's kept for compatibility.

[ChangeLog][Android] -android-abis configure script parameter useful to compile Qt
only for a selected Android ABIs.

Change-Id: I1f418c7e0914dd83b98d763e8cd8c09841e20fdf
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-08-28 12:36:34 +03:00
Liang Qi
0f1f7fb97f Merge remote-tracking branch 'origin/dev' into 5.14
Conflicts:
	src/widgets/kernel/qwidget.cpp
	src/widgets/kernel/qwidget_p.h
	src/widgets/kernel/qwidgetrepaintmanager.cpp
	src/widgets/kernel/qwidgetwindow.cpp
	tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp

Change-Id: Ifae457d0427be8e2465e474b055722e11b3b1e5c
2019-08-27 09:45:52 +02:00
BogDan Vatra
5bb178c479 Say hello to Android multi arch build in one go
Multi arch build in one go is need to support the new .aab packaging format.

By default the users apps are built for all Android ABIs: arm64-v8a armeabi-v7a x86_64 x86
The user can pass ANDROID_ABIS to qmake to filter the ABIs during development,
e.g. qmake ANDROID_ABIS="arm64-v8a armeabi-v7a" will build only for arm ABIs.

[ChangeLog][Android] Android multi arch build in one go,
needed to support the new .aab packaging format.

Change-Id: I3a64caf9621c2a195863976a62a57cdf47e6e3b5
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-08-26 12:59:15 +03:00
Alexandru Croitor
6a859f8112 CMake: Fix usage of non debug and release static builds on Windows
As was recently discovered, the debug_and_release CONFIG value is
always true on Windows, even if the feaure is disabled when specifying
-debug or -release when configuring Qt.

In order for the generated CMake Config files to be correct, we need
to use the true feature value.

Amends 44602224bf.

Change-Id: I42be684e8ad2a5ce72cb2e9d36f81de7589112c6
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-25 16:47:25 +02:00
Joerg Bornemann
7cbe1ca33d CMake: Fix detection of debug_and_release for Windows builds
If Qt is configured with -release or -debug we must set CMAKE_DEBUG_TYPE
or CMAKE_RELEASE_TYPE, but not both.

This was broken by 82a2c7df which fixed the issue for iOS
simulator_and_device builds.

We have the following situation for both relevant CONFIG values:

                           debug_and_release  build_all
iOS simulator_and_device   unset              set
Windows -release           set                unset
Windows -debug-and-release set                set

Trivia: On Windows, when configuring with -release (or -debug) then
the *feature* debug_and_release is not set.
The *CONFIG* *value* however, is unconditionally set in
msvc-desktop.conf.

Fixes: QTBUG-77754
Change-Id: I326ecb024056bc189be5fa03ec6f59bc71226544
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-08-25 14:47:22 +00:00
Paul Wicking
304587e3db Merge 5.12 into 5.12.5
Change-Id: I188926022fa4afc0db2dadc6dc214ea5173b17ea
2019-08-23 08:42:17 +02:00
BogDan Vatra
9b14950ff6 Android: Update clang mkspecs
Follow Google's BuildSystemMaintainers doc to simplify (a lot) the clang support
It is needed to support future NDK releases painlessly.
Also remove old workarounds.

[ChangeLog][Android] Android depends on NDK r20+

Change-Id: Ib4c07fc71e0f5a264d804b0b3baa18ff79d07630
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-08-22 16:32:47 +03:00
Qt Forward Merge Bot
0c9f8ff2a8 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Ia4bcd81eff948e56a5eda9519cdbee59b7da54d9
2019-08-22 01:00:35 +02:00
Alexandru Croitor
6743b174c0 CMake: Fix invalid setting of QT_PLUGIN_TYPES on interface libraries
It is forbidden to set upper case named properties on CMake
interface libraries which do not start with the "INTERFACE_"
prefix. Rename QT_PLUGIN_TYPES to INTERFACE_QT_PLUGIN_TYPES.

There does not seem to be any usage of the property, so it's just for
informational purposes, so it's a one line change.

Fixes: QTBUG-77754
Change-Id: I3621f2b6188c3c72c4c2446f93ba1e078b755f72
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-21 22:18:42 +02:00
Lorn Potter
987cca7bca wasm: allow setting total memory for non thread builds
Using WASM_OBJECT_FILES does not allow memory growth, so we need to just
explicitly check for QMAKE_WASM_TOTAL_MEMORY

Change-Id: I447113972dfc3df4ee4073e8cc25481646d1507b
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-08-22 04:41:04 +10:00
Joerg Bornemann
3b5f9678d7 Remove dead QMakeSourceFileInfo caching feature from QMake
Since its introduction in commit
65bb1a25419210e6097cad973fb847aa3719c09b (old internal history, 2005)
with the commit message "optimizations I've been sitting on here"
we're dragging along this dead code. It is time for removal.

Change-Id: Ic7902ebb8c402734974ad6651a1371d1e5bf93c5
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-08-20 20:27:52 +02:00
Tor Arne Vestbø
28ba681eb6 macOS: Whitelist the 10.15 SDK for building Qt and applications
Change-Id: I63689e79d08429e7760bb85a1f2b3f5825178428
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-08-20 15:07:43 +02:00
Tor Arne Vestbø
fe2aaf1b90 qmake: Quote path to project file in Xcode project Makefile rule
Change-Id: I40aba757486548ef9f319d3176e89eb7129a007e
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-20 11:31:37 +02:00
Alexandru Croitor
5d7e9c9667 CMake: Fix prl and library names on macOS for debug configurations
The paths to the libraries and prl files should have the "_debug"
suffix for the debug configuration. This prefix is added to the TARGET
when by qt_module.prf when doing a debug build, but not during a
debug_and_release build.
Make sure to strip the _debug suffix if it's there, and re-add it later
always, to be consistent in both debug_and_release builds and in
debug builds.

Amends a12b6e7bf6.

Task-number: QTBUG-38913
Task-number: QTBUG-75520
Task-number: QTBUG-77092
Change-Id: I29e88f2b991e2be06b23652d64edc768fa35a5ae
(cherry picked from qt/78d67d17a6c108a419816b8bd47f78864ddbb07f)
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-08-18 21:06:11 +02:00
Tasuku Suzuki
99749d3b05 Fix build without features.poll_{ppoll,pollts,poll,select}
Change-Id: Idc87521cdf713682ed07eb28b3d3f2f3ca0675ce
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2019-08-18 13:22:35 +09:00
Alexandru Croitor
82a2c7df30 CMake: Fix detection of debug_and_release for iOS simulator_and_device
create_cmake.prf populates the values of CMAKE_RELEASE_TYPE and
CMAKE_DEBUG_TYPE depending on if Qt was configured with debug, or
release, or the build_all feature was set (which implies
debug_and_release).

simulator_and_device also implies build_all. This
is a problem when configuring a Qt simulator_and_device build with
only a "debug" configuration, or only a "release" configuration.

In that case we would try to parse prl files for both configurations,
even though only one configuration exists.

Switch to checking for debug_and_release scope explicitly instead of
build_all. This allows configuring and building a Qt iOS
device_and_simulator debug configuration which is usable from CMake.

Task-number: QTBUG-38913
Change-Id: Ife6d5d34d2b6bb1ac787d901a166e41c6e0c844b
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-17 12:03:41 +02:00
Qt Forward Merge Bot
425d34b70e Merge remote-tracking branch 'origin/5.13' into dev
Change-Id: Icc80dacbca8613f2996be75553ff15d0ad242b7e
2019-08-15 01:00:51 +02:00
Lorn Potter
7a67a78d05 wasm: remove clamp mode for WASM_OBJECT_FILES builds
Change-Id: I2ddda7423c6546ab287111485da9c145ce7d31ea
Fixes: QTBUG-76771
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-08-14 14:38:26 +10:00
Yuhang Zhao
afb5746e62 Enable /OPT:REF explicitly for MSVC
/OPT:REF is enabled for release builds for MSVC by default,
however, clang-cl may not enable it without this flag,
add it to MSVC's mkspec so that all compilers based on MSVC
can benefit from it as well.

Change-Id: Ia80c20a8510cfa1e4687e39104ce99b37a2aa13f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-08-14 07:22:28 +08:00
Liang Qi
1dade1bd8a Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	mkspecs/win32-clang-msvc/qmake.conf
	src/corelib/tools/qlist.h
	src/gui/painting/qcompositionfunctions.cpp
	src/gui/painting/qtriangulator_p.h
	src/gui/text/qfontengine_p.h
	src/network/kernel/qhostinfo_p.h
	src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp

Done-With: Allan Sandfeld Jensen <allan.jensen@qt.io>
Change-Id: Ib8a0308cf77224c4fbdcf56778fdac4a43e37798
2019-08-13 09:46:17 +02:00
Kyle Edwards
63d9cd17d0 CMake: Add support for auto-importing plugins in CMake
This commit adds transitive dependencies to the plugins, so that a
sane set of default plugins get auto-imported when linking against a
module. It also provides a new function, qt5_import_plugins(), which
allows you to override the set of plugins that get imported. The decision
of whether or not to import a specific plugin is based on several custom
target properties and a very clever generator expression.

Note that this change only imports plugins on static Qt builds. It
does nothing on shared Qt builds, as the shared libraries already have
their own plugin import mechanism.

[ChangeLog][CMake] Added ability to auto-import non-qml plugins on
CMake builds

Task-number: QTBUG-38913
Task-number: QTBUG-76562
Change-Id: I2d6c8908b521cf6ba1ebbbc33a87cb7ddd9935cf
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-08-12 18:23:58 +02:00
Alexandru Croitor
ef74730a59 CMake: Prevent creation of library target when it already exists
When doing plugin auto-importing as part of a Qt static build, it can
happen that the same module FooConfig.cmake file is loaded twice.
Make sure not to create the same target twice if it was already
created previously.

Task-number: QTBUG-38913
Change-Id: I734c83ff3c0bb9e3ee9bff37971209c57abaa2b9
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-12 18:23:54 +02:00
Liang Qi
44c393f9b6 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	config.tests/arch/write_info.pri
		Repair architecture config test for the WASM_OBJECT_FILES=1 build mode
	configure.pri
	tests/auto/gui/text/qtextdocument/tst_qtextdocument.cpp

Done-With: Jörg Bornemann <joerg.bornemann@qt.io>
Change-Id: I9e12088356eb5bc65b53211cd7a8e330cccd1bb4
2019-08-12 13:23:11 +02:00
Yuhang Zhao
d502b19b28 Fix std detection for win32-clang-msvc
clang-cl will never support C++ standards newer than
C++14 without these flags.
I didn't add them to msvc-based-version.conf because
on Windows, only clang-cl use the same flags with MSVC,
both ICC and MinGW have their own flags. So they are
clang-cl specific flags.

Change-Id: Ia44a5ea4237c77ea5e897fffded32cbc008a4729
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-08-09 15:16:18 +08:00
Tor Arne Vestbø
6ac610c79b Allow specifying explicit SDK version on Apple platforms
This enables building against the latest SDK, while still opting out
of features that this SDK normally enables, by lowering the SDK version
set in the BUILD_VERSION/VERSION_MIN_MACOSX load command.

Change-Id: Id5f13524740bfbf5eda10a5d0c2e3fda04bf3f52
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2019-08-08 10:27:28 +02:00
Marc Mutz
213f7d1b1f Require opt-out for using QLinkedList
Now that all QLinkedList uses are removed from Qt, make sure
QT_NO_LINKED_LIST is set by default for Qt modules, so new
modules don't need to explicitly specify it in their
.qmake.conf.

Modules can still opt out of the QLinkedList ban by adding
   DEFINES -= QT_NO_LINKED_LIST
to their .qmake.conf.

Change-Id: I34b7ab1c009795649bb7b4f1e7493556eafadd5a
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2019-08-07 20:09:10 +00:00
Liang Qi
f3b28e8021 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	qmake/generators/unix/unixmake2.cpp
	src/plugins/platforms/cocoa/qcocoawindow.mm

Change-Id: Iba7aa7324f35543e0297a3680956420058cd3630
2019-08-05 09:28:48 +02:00
Tor Arne Vestbø
89e97e9937 Pass qmake arguments when creating Xcode project from Makefile
Change-Id: I0020273b200465f44a135848b4fd505793e85c30
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-08-01 15:24:25 +02:00
Qt Forward Merge Bot
5ee1c86d10 Merge remote-tracking branch 'origin/5.13' into dev
Change-Id: I4505ec6fe17a1aa2c8d1e6576234d06a34eb9f99
2019-08-01 01:00:10 +02:00
Simon Hausmann
2dddc1c9f4 Fix erroneous missing-cmake-tests errors
After commit 9c7ebd191b, qmake would
complain about missing cmake tests even for internal modules that have
no application side C++ linkage that needs testing.

Change-Id: I23b23c81dbe6be2b6da5672cbd7b8f8454ec2f66
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-07-31 16:37:28 +02:00
Paul Wicking
23841083e3 Doc build: overcome command-line length limitation on Windows
On Windows, create a file containing include paths for QDoc in
cases where number of include paths exceed 30. Based on how moc
does this.

Task-number: QTBUG-68259
Change-Id: I0d03fab4b809174cb6b48c36ee9f8880ff294ff4
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Martin Smith <martin.smith@qt.io>
2019-07-30 07:54:17 +00:00
Qt Forward Merge Bot
f9b8c544e6 Merge remote-tracking branch 'origin/5.13' into dev
Change-Id: Ic6cfe08dbda1dc92b969e67063f805df63ba0fcf
2019-07-27 01:00:37 +02:00
Liang Qi
bf08e0bbb2 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/network/access/qhttpthreaddelegate.cpp

Change-Id: Id47b977587e2d713c16ac17e63c5ec80c2f05ee9
2019-07-26 10:13:06 +02:00
Mike Krus
b202d45026 Make simulator detection work with Xcode 11
Beta version of Xcode 11 changes the format of the json object
returned by simctl and used to detect running simulators.

While multiple versions of Xcode can coexist on the same system,
they share the same simulator infrastructure so installing
Xcode 11 Beta affects projects using previous versions.

Change-Id: Icf06a794aa5ba3624163ace2ce827c0ecf97c38c
Reviewed-by: Frank Osterfeld <frank.osterfeld@kdab.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-07-21 14:05:15 +01:00
Qt Forward Merge Bot
64df0eda36 Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	src/corelib/global/qlogging.cpp
	src/gui/painting/qtextureglyphcache_p.h
	src/gui/text/qfontengine.cpp
	src/widgets/widgets/qlineedit.cpp

Change-Id: Ic8798538df466b7141caa8bbf1fb7605eb56be37
2019-07-17 10:44:21 +02:00
Qt Forward Merge Bot
77d126ccb5 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	configure.pri

Also required s/solid\.color/solidColor/ in a couple of places in:
	src/gui/painting/qpaintengine_raster.cpp

Change-Id: I29937f63e9779deb6dac7ae77e2948d06ebc0319
2019-07-12 12:23:29 +02:00
Qt Forward Merge Bot
fd2d9de51e Merge remote-tracking branch 'origin/5.13' into dev
Change-Id: Icaabf08f9af539ddf844d96bc9c3a2d09408ba8a
2019-07-12 01:00:42 +02:00
Kai Koehne
3f8e754f07 CMake: Properly escape '.lib' in regex
In a CMake regex, you need two backslashes to escape a character. The
.in file therefore needs four backslashes ...

This amends ba4fdd99ff

Fixes:  QTBUG-76698
Change-Id: Ic757354ba596bf020c3ee5e90ee6d2d0fe3ba352
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-07-11 14:13:19 +00:00
Qt Forward Merge Bot
85d3061c1c Merge "Merge remote-tracking branch 'origin/5.13' into dev" 2019-07-10 17:01:22 +02:00
Joerg Bornemann
3052e621a4 Fix duplicates in QMAKE_DIR_REPLACE
When building Qt, qt_build_config.prf adds all directory variables but
DESTDIR to QMAKE_DIR_REPLACE_SANE. We must not add the content of
QMAKE_DIR_REPLACE_SANE unconditionally to QMAKE_DIR_REPLACE in order
to avoid duplicate entries.

Duplicate entries result in an interesting build folder structure like

.obj
├───debug
│   └───debug
└───release
    └───release

This commit amends 274882a5.

Change-Id: Ifa8178410d82f58635babc46d43774bab522fbf8
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-07-10 12:35:52 +02:00
Qt Forward Merge Bot
6fd20defb9 Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	src/corelib/time/qdatetime.cpp
	src/widgets/widgets/qcombobox.h

Change-Id: Ib84352e8fe34aed2986a1c94e7346a46a71c803b
2019-07-10 10:39:33 +02:00
Ryan Chu
17ac9f8ced Revert "Disable Docker-based test servers on Windows temporarily"
This reverts commit 17512d497d.

Reason for revert: force vmx instructions to Coin level B virtual

Relates to qt/qt5 84ff024609e4eca003c604294b4102e73deba8c3

Change-Id: Id87a5629a5cd6ebc18c676eae390466e280fc600
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-07-09 13:49:18 +02:00
Alexandru Croitor
9c7ebd191b CMake: Create Config.cmake files for internal modules in static builds
This change will create Config.cmake files for internal modules like
AccessibilitySupport when doing static builds. They need to be
find_package()'ed and linked in when linking in certain qt plugins.

Task-number: QTBUG-38913
Task-number: QTBUG-76562
Change-Id: Ia2e446025c87df48f20bb65cfd9da6c6a4354bb1
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-07-08 11:04:35 +02:00
Alexandru Croitor
44602224bf CMake: Put the static dependencies into the relevant configuration
When adding the static dependencies for a module, they should be
added to the debug|release configuration as appropriate, otherwise
it ends up adding the debug version of the libraries to the release
configuration as well as the release version of the libraries.

Implementation wise, that means we have to use generator expressions
of the form $<$<CONFIG:Configuration>:${dependencies}>, because
INTERFACE_LINK_LIBRARIES does not have a
INTERFACE_LINK_LIBRARIES_<CONFIG> equivalent that can be set per
configuration.

Note that the condition part of the generator expression can not
explicitly check for Debug or for Release, because a user can
configure their application without specifying CMAKE_BUILD_TYPE,
which means that both Debug and Relase conditions would fail.
So the actual condition has to be isDebug or isNotDebug.

The same approach is used for INTERFACE_LINK_OPTIONS.

For debug_and_release builds we use the isDebug and isNotDebug
conditions for the generator expressions.

For singular builds (only release or only debug), we set the
generator expression condition to "1" aka always true.
This means that the Qt libraries and link options will always be used
regardless of the configuration with which the CMake application
is configured with.

Fixes: QTBUG-76337
Task-number: QTBUG-38913
Change-Id: I5369d8ba083359a4a92253dbd1dabe9d1efa34db
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2019-07-05 15:59:13 +02:00
Liang Qi
deee7b7ece Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	.qmake.conf
	qmake/generators/makefile.cpp

Change-Id: Ifb2633a69d0bf8cdf12d799c6259beefc279c49e
2019-07-05 15:37:50 +02:00
Alexandru Croitor
6ad08b9cad CMake: Fix handling of static dependencies that have spaces in path
The absolute paths of certain static dependencies can have spaces in
them. The _qt5_$${CMAKE_MODULE_NAME}_process_prl_file fails to handle
this, and simply replaces all spaces with semicolons, which obviously
breaks the list of dependencies, and a consuming application fails to
link with a message like:

LINK : fatal error LNK1181: cannot open input file 'C:\Program.obj'

This change partially restores the functionality that was added in
102e1822ff specifically the part
that changes qmake to export an additional variable
QMAKE_PRL_LIBS_FOR_CMAKE. This variable has the same content as
QMAKE_PRL_LIBS except it uses a semicolon as a separator, so that
CMake can correctly parse the separate lib entries.

This is much cleaner than trying to parse the original QMAKE_PRL_LIBS
variable with a complicated regular expression.

Amends eda28621f6.

Task-number: QTBUG-38913
Change-Id: I1d18fb779606505bc92320d8ce13232c7022e212
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-07-05 10:18:56 +02:00
Alexandru Croitor
78d67d17a6 CMake: Fix prl and library names on macOS for debug configurations
The paths to the libraries and prl files should have the "_debug"
suffix for the debug configuration. This prefix is added to the TARGET
when by qt_module.prf when doing a debug build, but not during a
debug_and_release build.
Make sure to strip the _debug suffix if it's there, and re-add it later
always, to be consistent in both debug_and_release builds and in
debug builds.

Amends a12b6e7bf6.

Task-number: QTBUG-38913
Task-number: QTBUG-75520
Change-Id: I29e88f2b991e2be06b23652d64edc768fa35a5ae
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-07-05 10:18:47 +02:00
Joerg Bornemann
11d9af5d95 Unbreak the -silent build
The header clean command must not be prefixed by "@echo ...", because it
now starts with "$(CXX)" which already is prefixed.

This amends commit 6fa5dfdd.

Change-Id: I5c2e0d2c2ed91c7232fce0a4a49db0fccfdc005d
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-07-04 13:16:52 +02:00
Andy Shaw
faf742b05d dumpcpp: Run dumpcpp if the generated files do not exist at qmake time
By running dumpcpp if the files do not exist at qmake time we enable
the dependency finder to find these files and set up the dependencies
as appropriate. Since other changes ensure that dumpcpp will be called
at the right time when building if the typelib changes, we no longer
need to have the generated files dependent on the objects. As a
result, we are able to prevent it from unnecessarily rebuilding
everything if certain files are updated.

Change-Id: I334f48c7a980aa8b893c14cb2a4687d3b2b7a4b9
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-07-03 22:15:44 +01:00
Qt Forward Merge Bot
a2b221e595 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	.qmake.conf

Change-Id: I936be3c0df2b9845ff6a85eb3d4442cdabe63d37
2019-07-03 15:19:26 +02:00
Joerg Bornemann
cee5a11bdb Fix directory separator of QMAKE_INCDIR_VULKAN
Like in Qt code itself we should use forward slashes consistently.

This enables the vulkan test to run on Linux for MinGW
cross-compilation.

Task-number: QTBUG-76660
Change-Id: Ifc6dec11bac3c3769d5d06e49da529f66f7b5843
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-07-02 08:02:53 +02:00
Liang Qi
d25c322729 Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	src/network/ssl/qsslsocket_openssl.cpp
	src/platformsupport/vkconvenience/qvkconvenience.cpp

Change-Id: I97ce6ed185f7fdad8102cc58d3cfec0119fd7bb4
2019-07-01 10:21:37 +02:00
Mikhail Svetkin
222b81f5da rtems: Fix missing some ernno defines
By default RTEMS does not support linux extensions for errno.
Enable it for build.

Change-Id: I43b346794b99ac0ed339bfbe6e39684071615503
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Ryan Chu <ryan.chu@qt.io>
2019-07-01 02:04:19 +02:00
Ryan Chu
57055ffafd Share the common configurations among different modules
This change is used to generalize a template docker-compose file for all
modules. Ideally, the leaf module only need to keep a docker compose
file for all platforms (docker-compose.yml).

NOTE:
The version of docker-compose file downgrades from 3.4 to 2.1 because
the 'extends' keyword is not supported in Compose version 3.x.

Change-Id: I2e36fd9236eda86cb5fcf940d787ccefe9200696
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
2019-07-01 01:09:42 +02:00
Qt Forward Merge Bot
134ee9d548 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I4cb91777e7ae9f462fa219d5b9ebeb277fde49c3
2019-06-29 01:00:34 +02:00
Joerg Bornemann
57eed823e4 Fix build with Android NDK's make on Windows
The make executable that comes with Android's NDK tries to execute the
shell-builtin "move" as a stand-alone executable unless you trick it
to execute "move" through the shell by surrounding one argument with
double quotes or such.

Force the execution of "move" through shell by altering QMAKE_MOVE for
Android on Windows.

Change-Id: I5b1490ad0606960dbd06a4cafb0b0b983e265159
Fixes: QTBUG-35713
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2019-06-28 15:13:34 +02:00
Qt Forward Merge Bot
7265fb0597 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I912bd8851c390302414d3dfb3c8220df5a0d5630
2019-06-28 01:00:23 +02:00
Liang Qi
25eb97d2d4 Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	.qmake.conf
	src/network/ssl/qsslsocket_openssl.cpp

Done-With: Timur Pocheptsov <timur.pocheptsov@qt.io>
Change-Id: Ibb57a0548b4977797b400637487a56245ac1c024
2019-06-27 14:38:03 +02:00
Joerg Bornemann
18a6c5ebe2 Fix QMAKE_LIBDIR_BCM_HOST for linux-rasp-pi3-g++
The directory must be prepended by = to denote the sysroot.
This amends commit 797f686e.

Change-Id: Ib85c0abc58fce3504ecccef0e223b2618ac9149a
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-06-25 09:42:09 +02:00
Joerg Bornemann
c450e8bd20 Fix .la/.pc replacements if libdir is in QMAKE_DEFAULT_LIBDIRS
We must use the same two-level replacements like for .prl files.
This amends commit d5071a40.

Change-Id: Iea065d01dee61cf2d1ff78640d045c3c76db9ac8
Fixes: QTBUG-76625
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-06-25 09:17:07 +02:00
Thiago Macieira
859eb2467d Add qmake config for controlling LTCG behavior for static libs
Static libraries may get installed and used by other builds, which may
be done with a different version or build of the compiler. So this
commit introduces two new flags:
 - no-static-ltcg: disables LTCG completely for static libraries
 - fat-static-lto: forces static libraries to produce fat LTO objects

fat-static-lto is useful for Linux distributions, since installed static
libraries should not carry LTO information, but that information is
useful during Qt's own build. This feature should be used alongside some
compiler-specific method of removing the LTO information from the
static libraries prior to installation, so only the regular part
remains.

For current GCC versions, this command suffices:
  strip -R '.gnu.lto*' -R '.gnu.debuglto*' libname.a

Otherwise, distributions can use "no-static-ltcg" to disable it
completely.

Change-Id: I495bc19409f348069f5bfffd155237ade9f4b42f
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-06-17 15:27:51 +00:00
Liang Qi
bd9959bde2 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	.qmake.conf
	src/gui/painting/qdrawhelper.cpp
	src/network/ssl/qsslsocket_openssl.cpp
	src/widgets/styles/qstylesheetstyle.cpp

Change-Id: Ibe1cd40f46a823c9e5edbe0a3cd16be1e1686b17
2019-06-20 07:50:44 +02:00
Liang Qi
ef37ab9970 Merge remote-tracking branch 'origin/5.12' into dev
Conflicts:
	.qmake.conf
	src/gui/painting/qdrawhelper.cpp
	src/gui/text/qdistancefield.cpp
	src/gui/text/qdistancefield_p.h
	src/network/ssl/qsslsocket_openssl.cpp
	src/plugins/platforms/android/qandroidinputcontext.cpp
	src/widgets/styles/qstylesheetstyle.cpp

Done-With: Timur Pocheptsov <timur.pocheptsov@qt.io>
Change-Id: Ia7daad21f077ea889898f17734ec46303e71fe6b
2019-06-25 13:04:27 +02:00
Tor Arne Vestbø
6fa5dfddf8 Don't hardcode compiler when building headers
Normal sources are built using $(CXX), which is defined in the makefile,
but can be overridden. We should do the same lazy evaluation of the
compiler for headers.

Change-Id: Ic548786bd18ed8fb7eb0b58a527615ab19000323
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-06-13 14:11:50 +02:00
BogDan Vatra
e428cdc32c Android: Fix sanitize_address
Starting with Android 8.1.0 wrap.sh can be used to enable ASAN on Android.

Change-Id: I6ef6e5989475b9b7981d05e78a03f9680c1acb1b
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-05-29 15:03:47 +03:00
Thiago Macieira
36c6b7ee4d Append LTCG arguments properly
If the QMAKE_CXXFLAGS already had -ffat-lto-objects, the *= wouldn't add
it it again, after our "-flto -fno-fat-lto-objects", which meant the
last one would stand.

Change-Id: Ic9cfa6256b5045caa6e6fffd15a7f6cda7aaa837
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-06-13 23:02:22 -07:00
Liang Qi
98813ead02 Merge remote-tracking branch 'origin/5.13.0' into 5.13
Change-Id: I39248f6c561c6274ab5ead64238dd2f80e167eee
2019-06-17 10:17:56 +02:00
Qt Forward Merge Bot
2a9cf3aeab Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I53a50669face6f68ddc046fd2102de8c1f888b4b
2019-06-14 01:00:09 +02:00
BogDan Vatra
0676645318 Android: Fix build with NDKr20
In NDK r20 clang adds -lc++ library automatically which leads to link fails.

[ChangeLog][Android] Fix NDK r20 linking.

Task-number: QTBUG-76293
Change-Id: I6675180a3555d1ad9047d7a9ce1c03333cf0ab35
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-06-13 07:14:54 +00:00
Fredrik Orderud
90aefe0843 Add quoting to deal with empty ${CMAKE_CXX_STANDARD_LIBRARIES}
Done to fix broken CMake WebAssembly support, where CMAKE_CXX_STANDARD_LIBRARIES
appear to be empty. The regression was introduced by
ba4fdd99ff.

This fixes the following CMake error on find_package(Qt ...):
string sub-command REGEX, mode REPLACE needs at least 6 arguments total to command.

Fixes: QTBUG-73475
Fixes: QTBUG-76244
Change-Id: Ieebe8cd1d49bb302dc37d8f118cc0b9376d6cdd7
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-06-11 12:44:49 +02:00
Joerg Bornemann
015d7f16cb Fix QMAKE_PRL_INSTALL_REPLACE for macOS
The regular expression with the alternative is not portable.
Use a separate QMAKE_PRL_INSTALL_REPLACE item.

This amends commit f00de33.

Fixes: QTBUG-75950
Change-Id: I78e172053f8b05be7d595a1c9e1695ea658b0547
Reviewed-by: Iikka Eklund <iikka.eklund@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-22 10:40:36 +02:00
Joerg Bornemann
f00de3322e Replace absolute Qt lib dir in .prl files
In the case of building a Qt module repository against an installed
qtbase the .prl files contain absolute paths to Qt dependencies e.g.
'/install-prefix/lib/libQt5Core.so'.

Those must be replaced with $$[QT_INSTALL_PREFIX]. The .prl
replacement code however only takes $$MODULE_BASE_OUTDIR/lib into
account.

Fixes: QTBUG-75804
Change-Id: I5ea5623ca7396b672fded3f1b9434b9ad5ed12ec
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-20 13:06:57 +00:00
Kai Koehne
9dbbccf7a2 Fix emar invocation on Windows for MinGW
If qmake is called without sh.exe in PATH, the relative paths
in OBJECTS will contain backslashes as separator.

Anyhow, emar needs forward slashes. Use GNU make's subst command
to fix this.

This amends  22c1e10e19.

Task-number: QTBUG-75257
Change-Id: Iacc6fe69cf470f35c6ddd829be7a80944346452d
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-05-13 04:37:47 +00:00
BogDan Vatra
c996d13126 Android: Fix x86_64 linking
x86_64 libs are located in ANDROID_PLATFORM_ROOT_PATH/usr/lib64
not in ANDROID_PLATFORM_ROOT_PATH/usr/lib .

Fixes: QTBUG-47672
Change-Id: Ia1f74f7c2a30b276b95fd0e7dcf8370d739e3c41
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
(cherry picked from commit 43763e2796)
Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
2019-05-08 08:40:44 +00:00
Frederik Gladhorn
4f5b2733b6 Merge 5.13 into 5.13.0
Change-Id: I98e2b93d78dba1cbf746c39a0b5877d5e72c91fc
2019-05-07 14:51:25 +02:00
BogDan Vatra
854156dd07 Android: Nuke mips architectures
Mips archs were removed from Android NDK long time ago.

Change-Id: Icf64a1e2cfbe3fe7307c7898b14fd199d9eeaad3
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-05-06 08:01:04 +00:00
Qt Forward Merge Bot
e4e5a1f0b7 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Iaad9509712c848ed42ada2c25065162a6fc5a930
2019-05-06 01:00:13 +02:00
Joerg Bornemann
6288c12bb4 Resolve QMAKE_INCDIR_VULKAN on every qmake call
Do not store this variable locally, because
a) it might change if the SDK location changes
b) does not play well with Qt installer packages which would provide the
include path of the build machine.

To achieve this we introduce the (usual) magic value - for
QMAKE_EXPORT_INCDIR_VULKAN to denote "do not export this value".

Fixes: QTBUG-73796
Change-Id: Ied26ee12cbcdf7f5f6e1caef5d29dadf6309c5d6
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-05-05 13:15:37 +00:00
Liang Qi
b5c2535eb0 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/3rdparty/pcre2/qt_attribution.json

Change-Id: Ibae941cb12662f27bd6962ee02bc235971c59a15
2019-05-03 10:44:24 +02:00
Joerg Bornemann
d5071a4016 Fix prl replacements if libdir is in QMAKE_DEFAULT_LIBDIRS
QMAKE_PRL_LIBS contains absolute paths to libraries, e.g. libqtpcre2.a.
On "make install" the libdir is replaced with the installation target
libdir. If the libdir is in QMAKE_DEFAULT_LIBDIRS (e.g. /usr) then the
replacement was empty. That worked fine for include paths but not for
paths referencing files in that libdir:
/my/build/lib/qtbase/lib/libqtpcre2.a would become /libqtpcre2.a.

Add another replacement that takes care of file paths and inserts
$$[QT_INSTALL_LIBS].

Fixes: QTBUG-75460
Change-Id: I4e84478a50c24d4143ad5695493cad2992735cf2
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Samuli Piippo <samuli.piippo@qt.io>
2019-05-02 13:04:22 +00:00
Joerg Bornemann
22c1e10e19 Fix emar invocation on Windows
On Windows we hit the command line length limit when building the wasm
port of Qt. We must not pass the list of object files directly to emar,
but write a response file which is then passed via the @ parameter.

Fixes: QTBUG-75257
Change-Id: Id518fd81325716b8efaba29f495568a9a3e34be4
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
2019-05-02 05:35:09 +00:00
Allan Sandfeld Jensen
ef05c48898 Fix -Wdeprecated-copy warnings
Implicit copy constructors or methods are considered deprecated for
classes that has one of the two or a destructor.

The warning is enabled with -Wextra in gcc 9

Change-Id: Ic9be654f2a142fb186a4d5a7d6b4f7d6f4e611d8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-05-01 07:39:55 +00:00
Kai Koehne
ba4fdd99ff CMake: Ignore CMAKE_CXX_STANDARD_LIBRARIES in .prl files
Do not call find_library() on libs that are part of CMAKE_CXX_STANDARD_LIBRARIES:
At CMake call time they might not be found.

Fixes: QTBUG-73475
Change-Id: I350b3280744883e82d83c46e70f6a7cfc8aeed2e
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-04-30 11:50:07 +00:00
Qt Forward Merge Bot
9f1a1e320c Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Ibce9bfef928ce39070183c488ce86ae32e5ea705
2019-04-28 01:00:26 +02:00
Joerg Bornemann
bbfc95914f Fix determination of OpenGL include paths on macOS, take 3
The sysrootification of QMAKE_INCDIR_OPENGL on macOS must happen only
once. Commit 49ef3773 addressed this but stored the sysrootified
QMAKE_INCDIR_OPENGL in qt_lib_gui_private.pri. For installer packages,
these paths are the paths of the build machine and most likely wrong
on the user's machine.

This reverts commit 4949ef377349ba4dae840c2d5caa36e2d516707baa and
restores the sysrootification in sdk.prf. The original include paths
are assigned to QMAKE_EXPORT_INCDIR_OPENGL and stored as
QMAKE_INCDIR_OPENGL in qt_lib_gui_private.pri.

Fixes: QTBUG-75374
Task-number: QTBUG-73736
Change-Id: I4c0f65866d60660c632363dba3adc7ea2e344bfc
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-04-27 07:32:53 +00:00
Qt Forward Merge Bot
0dff40adf8 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I6ecf7074eda57ef4954fb3fdc7a6d1e8cd229340
2019-04-26 01:00:13 +02:00
Martin Storsjö
65a33d73ea qmake: Always split QMAKE_DEFAULT_LIBDIRS using ; with clang on windows
When building in a unix style build system (i.e. msys), QMAKE_DIRLIST_SEP
is a colon, not a semicolon. Thus, always split the incoming string
(after the fixup regex) using semicolons on windows.

This matches the code for gcc, further up, which does:

    equals(QMAKE_HOST.os, Windows): \
        paths = $$split(line, ;)
    else: \
        paths = $$split(line, $$QMAKE_DIRLIST_SEP)

Change-Id: I6a0175f9d14ae9ca188553483b7868f0549c784a
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-04-25 09:29:23 +00:00
Qt Forward Merge Bot
cb10ec56f7 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I26da00aa71b0f0b91c9bfb4a9e8550345ee62875
2019-04-24 01:00:13 +02:00
Joerg Bornemann
f36a306563 configure: Support the = prefix for -I and -L
For gcc's -I and -L arguments a = prefix is replaced by the sysroot.
Since we're resolving include paths and library paths, we have to
support this feature.

For example, the linux-rasp-pi3-g++ makes use of this and is broken
without this patch.

Change-Id: Ie39e63322bd35e2a93aa8e55d52260164b8c6a6b
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-04-23 09:09:37 +00:00
Joerg Bornemann
c2917243a9 syncqt: Fix resolution of injected headers for external modules
Injected headers were made relative to MODULE_BASE_OUTDIR by syncqt
and made absolute by resolving against REAL_MODULE_BASE_OUTDIR.
This breaks for modules that reside outside the original Qt source
tree (if the directory depth doesn't coincidentally match).

Now, we resolve injected headers against build_basedir, which is
REAL_MODULE_BASE_OUTDIR. To emphasize the equivalence of
REAL_MODULE_BASE_OUTDIR and syncqt's build_basedir, use the former for
syncqt's -output argument.

This commit amends 2aa779e8.

Fixes: QTBUG-70587
Change-Id: I2935d87d7ee681fa4aa795a270b94ab7a43abe59
Reviewed-by: Dominik Holland <dominik.holland@pelagicore.com>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-04-23 09:09:33 +00:00
Allan Sandfeld Jensen
51bae0331c Add qmake support for c++2a
Makes it possible to build user projects and Qt with C++2a. It is not
automatically upgraded to yet though.

Change-Id: I949ce94871ddc53f21b7265a52b9c0e1370456c8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-04-19 08:14:25 +00:00
Liang Qi
9d67bf6e96 Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/corelib/tools/qlocale.qdoc
	tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp

Done-with: Edward Welbourne <edward.welbourne@qt.io>
Done-with: Volker Hilsheimer <volker.hilsheimer@qt.io>
Change-Id: I88e0757b2d020f0a244714c87844631df4b3fd13
2019-04-16 09:34:50 +02:00
Oswald Buddenhagen
5b3dfa470e qmake: link qt libraries by full path
this avoids the scenario where the linker would pick up the wrong qt
libraries for LIBS_PRIVATE because LIBS added the "wrong" path first.
this is also consistent with configure-supplied dependencies as of
recently.

as a side effect, this also removes pretenses of lsb linker handling, as
it makes no sense after the change and is certainly obsolete anyway.

Fixes: QTBUG-50921
Change-Id: I84398c9143f393c2eefb3c69a31bd9f633669924
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-04-15 05:41:08 +00:00
Jean-Michaël Celerier
bb8a3dfc95 CMake: fix generation of config files for external Qt modules on macOS
This is a follow-up to f5850cb0da, which
did not take into account some special-casing for macOS framework build,
thus causing CMake to look for QtFoo.framework instead of Foo.framework.

Change-Id: I261b14e75fde66fb57486bde43fc936f796a6f96
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
2019-04-12 09:31:35 +00:00
Liang Qi
3c662bf13c Merge remote-tracking branch 'origin/5.13.0' into 5.13
Conflicts:
	src/plugins/platforms/wasm/qwasmintegration.cpp
	src/plugins/platforms/wasm/qwasmintegration.h

Change-Id: Idf4c7936513fb1f21daa8f6105b8545f13447bb8
2019-06-11 10:30:48 +02:00
Liang Qi
9967a011ea Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	qmake/generators/makefile.cpp
	src/plugins/platforms/cocoa/qcocoaintegration.h
	src/plugins/platforms/cocoa/qcocoaintegration.mm

Done-With: Jörg Bornemann <joerg.bornemann@qt.io>
Change-Id: I5a61e161784cc6f947abe370aab8f2971a9cbe78
2019-06-07 13:19:27 +02:00
Joerg Bornemann
99636127d1 Fix prefix_build check for top-level builds
The checks whether we have a Qt prefix build were broken for
top-level builds. Non-prefix top-level builds were incorrectly
detected as prefix builds.

For top-level non-prefix builds QT_HOST_DATA/QT_INSTALL_PREFIX becomes
something like "~/my/build/dir/qtbase" but .qmake.cache (and
.qmake.super) is/are created in "~/my/build/dir".

This patch extends the prefix_build check by probing for the existence
of .qmake.super, which only exists for top-level builds. Also, we add
qt_prefix_build_check.prf as central place for determining whether we
have a prefix build to make sure that qt_configure.prf and
qt_build_config.prf use the same logic.

Fixes: QTBUG-76185
Change-Id: I2b76fe26013496aaf2dac96ea711b06a69550a29
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-06-05 13:02:22 +02:00
Tasuku Suzuki
9d9b944b44 Fix configure comment in/for -device linux-rasp-pi3-vc4-g++
The name was renamed in 8e445f8434

Change-Id: I5a74b65309cf5dc64621db281fad3a62a2f026b1
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
2019-06-04 17:22:35 +09:00
Joerg Bornemann
4da47d0fba Make sure .pc, .prl and .la files are created for header_only modules
Those modules are TEMPLATE=aux, so they weren't triggering the file creation
here.

To make this work properly we have to:
  - check for TEMPLATE aux in the right places
  - add a dummy target to INSTALLS to actually trigger the creation
  - initialize PRL_TARGET for aux templates

Fixes: QTBUG-75901
Started-by: Thiago Macieira <thiago.macieira@intel.com>
Change-Id: Idce141629dd34287808bfffd159f92ac28c6c8b1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-06-03 15:06:29 +02:00
Fredrik Orderud
2a2f04205c WASM: Make wasm_shell.html compatible with CMake configure_file
The CMake configure_file command is commonly used copy & modify template files
during the build process. One limitation, thought, is that configure_file
expect the variables to be replaced to be encoded using either a @APPNAME@ or
${APPNAME} convention.

This commit therefore changes "APPNAME" to "@APPNAME@" in wasm_shell.html to
make the HTML template file compatible with CMake configure_file.

With this commit, it becomes possible to write the following CMake function
that mimics what QMake is already doing:
function(copy_html_js_launch_files target)
  set(APPNAME ${target})
  configure_file("${_qt5Core_install_prefix}/plugins/platforms/wasm_shell.html"
                 "${target}.html")
  configure_file("${_qt5Core_install_prefix}/plugins/platforms/qtloader.js"
                 qtloader.js COPYONLY)
endfunction()

Change-Id: Ic38abdc498ba03b8d21f1b9b70aa1d480ae7f362
Reference: https://cmake.org/cmake/help/latest/command/configure_file.html
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-05-21 09:12:07 +02:00
Qt Forward Merge Bot
264e66afb2 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I1bdc28a3ae825ea35e83f20fe16d2409515e5a3d
2019-05-16 01:00:11 +02:00
Kai Koehne
16eb2b7e32 Copy plugins.qmltypes files to build dir (again)
Since change c808a6978b plugins.qmltypes and designer/*  didn't
get copied anymore for a non-prefixed build. Fix this, and clean up surrounding
code.

Fixes: QTBUG-75682
Change-Id: Ic6de94a5b01dae08929a67cbaedde60d120a4807
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-05-15 11:01:50 +00:00
Joerg Bornemann
871b65ab10 Add the c++latest CONFIG value to select the latest C++ standard
[ChangeLog][qmake] The CONFIG value c++latest was added to select the
latest C++ standard the currently used toolchain supports.

Task-number: QTBUG-75653
Change-Id: I22ddc9d293109d99e652b7ccb19d7226fca4716d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-05-14 08:01:40 +00:00
Qt Forward Merge Bot
f8212b87d9 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I0c00ffe0eabebc919f22d6faa4bf958b288e8fd9
2019-05-12 01:00:08 +02:00
Qt Forward Merge Bot
e56d3b03ed Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/corelib/tools/qlocale_data_p.h
        (Regenerated by running the scripts in util/local_database/)
	src/gui/opengl/qopengltextureuploader.cpp

Done-With: Edward Welbourne <edward.welbourne@qt.io>
Done-With: Allan Sandfeld Jensen <allan.jensen@qt.io>
Change-Id: I12df7f066ed0a25eb109f61c4b8d8dea63b683e2
2019-05-09 13:06:11 +00:00
Joerg Bornemann
a12b6e7bf6 Fix CMake file generation for debug libs on macOS
CMAKE_QT_STEM already contains the _debug suffix.
Do not add it again.

This amends commit bb8a3dfc.

Fixes: QTBUG-75520
Change-Id: I6c311f0913ea83fcf299a21a0ee1f28c3861371f
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-05-09 07:50:32 +00:00
BogDan Vatra
43763e2796 Android: Fix x86_64 linking
x86_64 libs are located in ANDROID_PLATFORM_ROOT_PATH/usr/lib64
not in ANDROID_PLATFORM_ROOT_PATH/usr/lib .

Fixes: QTBUG-47672
Change-Id: Ia1f74f7c2a30b276b95fd0e7dcf8370d739e3c41
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-05-06 06:42:23 +00:00
Allan Sandfeld Jensen
eaf20420f8 Fix precompiled headers with clang-cl
Clang-cl couldn't find the header given to it by -FI when it isn't in
any of the included directories.

Additionally clang-cl 8 has a bug with exported templated classes with
inline methods that causes it to have missing symbols at link time. We
work around this.

Fixes: QTBUG-74563
Change-Id: I7becf05fa8edb07bd4cefe12bee3737e5e1dfa14
Reviewed-by: Yuhang Zhao <2546789017@qq.com>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-04-09 21:58:54 +00:00
Qt Forward Merge Bot
ffe9c395dc Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Ia5d893e57deb78bc32e2053a5a79543ff847fe32
2019-04-02 01:00:26 +02:00
Yuhang Zhao
387f120bf9 Fix cross compile on Ubuntu
When cross compiling on Ubuntu with LTO enabled, the linker will complain about the "-fno-fat-objects" parameter even if the "-fuse-linker-plugin" is passed it.
But if the "-fno-fat-objects" parameter is removed, the linker will complain about "don't support linker plugin in this mode".
Remove both parameters can fix this.

Change-Id: I2d792ca70737f2e82a360bfc597f2b110513b954
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-03-30 07:34:30 +00:00
Qt Forward Merge Bot
0a7302abbc Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I9935bacae0d6ba532418fc3d28adbc7ca1463604
2019-03-30 01:00:07 +01:00
Allan Sandfeld Jensen
ff8d9ad5bc Speculative fix for building on INTEGRITY with ARM NEON
Avoid using inline assembler

Task-number: QTBUG-72716
Change-Id: I696efb5a787416eb4fc5ba3a250461aaa9a4afc2
Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io>
2019-03-29 13:06:12 +00:00
Qt Forward Merge Bot
3b27126440 Merge remote-tracking branch 'origin/5.12.4' into 5.12
Change-Id: I61c92717cf82cfe2b14a4d7cbe17f03c3634e827
2019-06-17 12:29:53 +02:00
Joerg Bornemann
b4f83596ca Fix QMAKE_PRL_INSTALL_REPLACE for macOS
The regular expression with the alternative is not portable.
Use a separate QMAKE_PRL_INSTALL_REPLACE item.

This amends commit f00de33.

(cherry picked from commit 015d7f16cb)

Fixes: QTBUG-75950
Change-Id: I78e172053f8b05be7d595a1c9e1695ea658b0547
Reviewed-by: Iikka Eklund <iikka.eklund@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-23 07:31:26 +00:00
Joerg Bornemann
b5bb4f762c Replace absolute Qt lib dir in .prl files
In the case of building a Qt module repository against an installed
qtbase the .prl files contain absolute paths to Qt dependencies e.g.
'/install-prefix/lib/libQt5Core.so'.

Those must be replaced with $$[QT_INSTALL_PREFIX]. The .prl
replacement code however only takes $$MODULE_BASE_OUTDIR/lib into
account.

(cherry picked from commit f00de3322e)

Fixes: QTBUG-75804
Change-Id: Ibf0f90a860d5089f416f903c1d18483d3dcc2ee6
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-05-23 07:29:53 +00:00
Kai Koehne
1d5f9fcc8a Handle quotes in .prl files
Do remove quotes around libraries before trying to parse them.
This patch is a follow-up to eda28621f6, and fixes
an issue on Windows where e.g. Qt5AxServer.prl contains entries
like

   "-lole32"

Fixes: QTBUG-73475
Change-Id: I3d1353de618328a0d44bacd4dbd6aba8fc66b1b7
Reviewed-by: Kyle Edwards <kyle.edwards@kitware.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-03-21 08:46:31 +00:00
Qt Forward Merge Bot
19510477b4 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Ie7f68dcd5650e0037b6c3313cc9ffdcd7c494fbe
2019-03-21 01:00:07 +01:00
Qt Forward Merge Bot
6893919b0c Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/gui/kernel/qplatformintegration.cpp
	src/gui/kernel/qplatformintegration.h
	src/plugins/platforms/wasm/qwasmintegration.cpp
	src/plugins/platforms/xcb/qxcbconnection_screens.cpp

Change-Id: I15063d42e9a1e226d9d2d2d372f75141b84c5c1b
2019-03-20 14:09:30 +01:00
Andy Shaw
c808a6978b Add a means to handle dynamically created qmldir files
This will enable modules like QtWebView which needs to generate its
qmldir at qmake time since it changes depending on whether QtWebEngine
is available or not. This ensures that it is not created in the sources
directory and in the build directory and correctly picked up.

Task-number: QTBUG-65092
Change-Id: Iac628b97145d29778f554510e8e07102d588df64
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-03-20 08:37:59 +00:00
Timo Aarnipuro
b4b8ea6181 configure: Allow libraries to be defined with exact filename
INTEGRITY compiler searches for exact filename if the -l argument already
contains .a suffix. GNU linker uses exact filename if -l argument begins
with a colon.

Change-Id: I62be8f1e6b9c7dc7eaa5ab3d4bfc55460d729737
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2019-03-20 07:09:27 +00:00
Yuhang Zhao
75b3c471b3 win32-clang-msvc: qmake.conf: Fix alignment
Change-Id: I62bff5e10c0dfb45078a9ff5a2378f251c6596aa
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2019-03-20 04:04:51 +00:00
Eskil Abrahamsen Blomfeldt
3ca05b2a2e Wasm: Build with Qt's freetype, png and zlib
Compilation breaks on Windows and macOS hosts with USE_ZLIB=1.

In addition, it turns out that the versions of the libraries in
Emscripten Ports are outdated. Since we have newer versions
of these libraries in Qt already, we will just use those.

This is a revert of 70b558ad5b.

Task-number: QTQAINFRA-2835
Change-Id: Ic2642b7d319a3447fd08843657eb0535255e0449
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
2019-03-19 20:38:28 +00:00
Andy Shaw
d2dff76a4f Replace instances of - with _ when generating the function name
As - cannot be used in a function name but can still be used as part of
the TARGET, then we need to make sure that it is replaced to avoid a
compile problem.

Change-Id: I0b2e465310206e2522ce59235b1592517817d3e2
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-03-19 13:35:15 +00:00
BogDan Vatra
079dafc42f Run prebuilt android test APKs
androidtestrunner now checks is the apk is build and if it is, it will skip the build phase.
Now we can build the apks in parallel (which takes most of the time) and run them sequentially.
This way running tests on Android is much faster.

Change-Id: I82f34723ac08f7728cc0daab3366e03821335eed
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-06-13 07:26:20 +00:00
BogDan Vatra
9dec965248 Say hello to $ make apk
Now creating an .apk it's easier than ever.
"$ make apk" is all you need to run to create an apk for your application.

[ChangeLog][Android] Introduce "make apk" target, an easy way to create an apk.

Change-Id: I12565e7ed32beb42da40d8ce42a52339038be950
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-06-06 15:31:29 +03:00
BogDan Vatra
a5e03f59f4 Say hello to androidtestrunner
androidtestrunner is a tool needed to run qt tests on Android.
Now you can run tests as simple as you run them on Linux, macOS,
Windows.
"$ make check" it's all you need to run tests on the default android
device.

ANDROID_DEVICE_SERIAL env variable can be used to use a specific android
serial.

Use cases:
$ make -j1 check
-j1 is needed to make sure we don't run multiple tests in parallel.

$ ANDROID_DEVICE_SERIAL="emulator-5554" make check
Run the test on "emulator-5554"

$ make TESTARGS="-- -xml" check
Switch to xml output. All params after -- are passed to test
application.

$ make TESTARGS="-- -o out.xml,xml -o out.txt,txt -o -,tap -vs" check
Create two files out.xml and out.txt in the current folder and print
"tap" format to stdout and enable logging of every signal emission.

[ChangeLog][Android] Make it easy to run Qt tests on Android.
"$ make check" is all it's needed to run a test on an Android device.

Change-Id: I1a7f64b62608f7367b5a6aabf5d6c6e7e50242e6
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
2019-06-06 15:25:07 +03:00
Liang Qi
b1a216649e Merge remote-tracking branch 'origin/5.13' into dev
Conflicts:
	qmake/generators/makefile.cpp
	qmake/generators/unix/unixmake2.cpp
	src/corelib/thread/qthread_unix.cpp
	tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp

Change-Id: I1df0d4ba20685de7f9300bf07458c13376493408
2019-06-14 13:45:18 +02:00
Joerg Bornemann
29fa59d244 Fix parallel lex/yacc invocation for debug_and_release builds
[ChangeLog][qmake] Introduced the variables LEX_DIR and YACC_DIR which
determine the location of lex/yacc output. Fixed parallel execution of
lex/yacc for debug_and_release builds.

Fixes: QTBUG-65730
Change-Id: I68c8260a95609e11bb5205a91aff2c098ed7009c
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
 
 
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-06-06 15:21:37 +02:00
Joerg Bornemann
274882a58c De-duplicate elements of QMAKE_DIR_REPLACE[_SANE]
Elements that appear in QMAKE_DIR_REPLACE_SANE must appear in
QMAKE_DIR_REPLACE to be considered due to the algorithm used in
exclusive_builds_post.prf.

Change-Id: Ibce7e6c988b3e8a141075890a2f547eb34090b3a
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-06-06 15:21:37 +02:00
Allan Sandfeld Jensen
327bfdb671 Enable warnings_are_errors builds for MSVC 2017
Also remove it from versions no longer supported.

Change-Id: I03a911a349527a81846e1820f95d775fe3943450
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-06-07 17:23:57 +02:00
Qt Forward Merge Bot
a1808c5dbe Merge remote-tracking branch 'origin/5.12.2' into 5.12
Change-Id: I5f9d8090a07056411fb65d7de60eb679d00e99a3
2019-03-15 11:10:10 +01:00
Morten Johan Sørvig
9ab25792b5 wasm: Add WASM_OBJECT_FILES=1 build mode
This mode significantly improves build (link) time.
Opt-in by passing “-device-option WASM_OBJECT_FILES=1”
to configure.

This requires a custom emsdk build which uses upstream
llvm.

Task-number: QTBUG-72537
Change-Id: I47bab2b58ae7e49ca104233ec14fff7b93516d36
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
2019-03-06 09:28:53 +00:00
Qt Forward Merge Bot
607338f98f Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I83f6ed9480bf21020ce7a9431010d87a88df84a1
2019-03-02 01:00:08 +01:00
Jean-Michaël Celerier
f5850cb0da CMake: fix generation of config files for external Qt modules
When such modules aren't following the libQt5Foo.so naming convention,
the generated CMake files would be incorrect.

Change-Id: I57908f7466bff7a05f19271ccd495849476bdf38
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
2019-03-01 14:15:12 +00:00
Joerg Bornemann
20063cf999 Actively discard return value of qtConfGetNextCommandlineArg
Calling a qmake replace function without assignment is undefined
behavior.

This amends 11ae0e77.

Change-Id: Ie716f295275d1ba79a217745b332a8eca04b355d
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-03-01 10:35:46 +00:00
Qt Forward Merge Bot
043f99954f Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Icc9b061c56e969756f0351c936cdeb8063c86079
2019-02-28 01:00:15 +01:00
Joerg Bornemann
49ef377349 Fix determination of OpenGL include paths on macOS, take 2
The sysrootification of OpenGL include paths must be done only once: at
configure time. The resolved paths are stored since 521a8539 and must not be
resolved again.

Turn the makeSpec-type opengl library into a custom-type one, and do
the sysrootification in the handler function.

Fixes: QTBUG-73736
Change-Id: I2933144057d6f01d8bfc7bda2c2df56c57303459
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-02-27 09:53:52 +00:00
Kai Koehne
bc107d8100 Allow QML plugin to specify import name explicitly
For creating the qmlplugindump rule we need the name of the import. So
far we're trying to derive this from the directory name, but that
becomes complicated if versions are included, like

  QtQuick/Controls.2/Fusion

Instead of trying to tweak the regexp even more to capture this, we
now allow a plugin to set it's name explicitly via IMPORT_NAME.

Change-Id: Ie75dae7d41398b3ac19ccb6910002b6fad009891
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-02-26 07:32:22 +00:00
Christian Kandeler
d6d80ff2e9 Automatic resources: Fix tooling support
The files to be put into an auto-generated qrc file must not simply
disappear, because IDE users still need to have them in the project tree.
So we add them to OTHER_FILES now.

Task-number: QTCREATORBUG-20103
Task-number: QTCREATORBUG-20104
Change-Id: I8a9136491f975def7c33385e375c407815ad269a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-02-25 09:39:13 +00:00
Qt Forward Merge Bot
64085d9b2f Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I9e7cb1b131b7b216aad8ed1b1536669fd1557c21
2019-02-22 01:00:27 +01:00
Oliver Wolff
7227e54445 qmake: Fix COPIES for Visual Studio projects
QINSTALLS is not set when Visual Studio projects are used. Use its
resolved value in case that Visual Studio projects are generated.

Change-Id: I8c21d4335971f45e56b3549086cb803c2d464158
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-02-21 06:43:56 +00:00
Qt Forward Merge Bot
2e8987b7ec Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" into refs/staging/5.13 2019-02-21 01:34:52 +00:00
Qt Forward Merge Bot
0c0c4a23bc Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I830beea26863323ab78a5d4b093f7763d77ad3da
2019-02-21 01:00:08 +01:00
Lorn Potter
70b558ad5b wasm: fix system lib detection and use
This is a revert of eea08d376a.
We need these flags to be added to the compiler in order to find the
emscripten ports to be able to use them.

Task-number: QTBUG-73127
Change-Id: Icf70f456947aef04dc79b2328f2e95fb1e94fcf8
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-02-20 23:03:09 +00:00
Oliver Wolff
ba58776a79 winrt: Add support for Visual Studio 2019
Change-Id: I5a07a3d20425a8c7ce2b2477792c379afeff5680
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
2019-02-20 13:32:29 +00:00
Qt Forward Merge Bot
67c70b22f6 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Ifa143cc462301aaa305c9c85360e543553a751f0
2019-02-19 01:00:08 +01:00
Joerg Bornemann
8fe3680193 Add cmdline feature to qmake
[ChangeLog][qmake] A new feature "cmdline" was added that implies
"CONFIG += console" and "CONFIG -= app_bundle".

Task-number: QTBUG-27079
Change-Id: I6e52b07c9341c904bb1424fc717057432f9360e1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
2019-02-18 07:12:14 +00:00
Joerg Bornemann
0c03316ec9 Revert "Fix determination of OpenGL include paths on macOS"
This reverts commit 37970d7b3e.

That commit broke the build on macOS, because the OpenGL headers aren't
resolved anymore at configure time.

Change-Id: Iec6ef009c9ea7e28b12eeca6b5eb06918bf49d98
Fixes: QTBUG-73827
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2019-02-16 16:25:24 +00:00
Qt Forward Merge Bot
ef2ddcf551 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I8cad26f17834dbc9f7151edc0f17786f9e32025d
2019-02-15 01:00:51 +01:00
Samuel Thibault
501cca2c4b Add <features.h> include to hurd-g++ mkspec
Without this include, __REDIRECT does not get defined, and then
open gets #defined to open64, leading to bogus MOC output.

See https://bugs.debian.org/920613.

Change-Id: I629d9dc6af05b9480c0c81a61d8890ab8bbefaae
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-02-14 14:24:56 +00:00
Joerg Bornemann
797f686ea4 Turn bcm_host library into makeSpec source
The bcm_host library couldn't be detected anymore. Let the makespec
provide LIBDIR, INCDIR and LIBS for bcm_host to fix this.

Change-Id: I4bc268504dc48edaf2884f1c14b745260fd9112c
Fixes: QTBUG-73727
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-02-14 07:27:34 +00:00
Oliver Wolff
896b307679 Add support for Visual Studio 2019
Change-Id: I963fc1c159edc644f081675c3dee248c25d7c9dc
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
2019-02-13 14:04:54 +00:00
Liang Qi
93bcd488af Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" into refs/staging/5.13 2019-02-12 18:13:34 +00:00
Jean-Michaël Celerier
cbbf7ddd3d Fix detection of libraries when linking against static builds with CMake
This patch is a follow-up to eda28621f6.
It adds a translation of the $$[QT_INSTALL_LIBS] variable into
a path that CMake understands.
Without this, CMake finds the system libraries if there are any
instead.
It also handles the case where the .prl file contains absolute paths to
libraries, as it happens for instance on Debian systems.

Task-number: QTBUG-38913
Change-Id: If68373efee22bc00172e8fead3e2c12ea440787f
Reviewed-by: Kyle Edwards <kyle.edwards@kitware.com>
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
2019-02-12 13:09:38 +00:00
Joerg Bornemann
37970d7b3e Fix determination of OpenGL include paths on macOS
Since include paths are fully resolved, we must remove the code that prepends
the SDK path to the OpenGL include paths.

Change-Id: I80d74629c7fc989a89c3f1d95d6de43b4c1de17a
Fixes: QTBUG-73736
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-02-12 12:58:44 +00:00
Qt Forward Merge Bot
d3b3be6865 Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: Iad53d4f21263718b8ecf15fd2d1170d24c7b675d
2019-02-12 13:53:22 +01:00
Eric Lemanissier
fd88c152db configure: use proper separator for mingw libraries
Change-Id: Ic328691fe2f08e918c1bb67910521d85b274a8fd
Fixes: QTBUG-73466
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-02-12 05:48:58 +00:00
Liang Qi
fbfacd33be Merge remote-tracking branch 'origin/5.12' into 5.13
Conflicts:
	src/android/templates/AndroidManifest.xml
	src/network/ssl/qsslsocket_mac.cpp
	src/widgets/styles/qstylesheetstyle.cpp
	tests/auto/corelib/kernel/qtimer/BLACKLIST
	tests/auto/testlib/selftests/blacklisted/tst_blacklisted.cpp
	tests/auto/testlib/selftests/expected_blacklisted.lightxml
	tests/auto/testlib/selftests/expected_blacklisted.tap
	tests/auto/testlib/selftests/expected_blacklisted.teamcity
	tests/auto/testlib/selftests/expected_blacklisted.txt
	tests/auto/testlib/selftests/expected_blacklisted.xml
	tests/auto/testlib/selftests/expected_blacklisted.xunitxml
	tests/auto/testlib/selftests/expected_float.tap
	tests/auto/testlib/selftests/expected_float.teamcity
	tests/auto/testlib/selftests/expected_float.txt
	tests/auto/testlib/selftests/expected_float.xunitxml

Done-With: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Done-With: Edward Welbourne <edward.welbourne@qt.io>
Done-With: Timur Pocheptsov <timur.pocheptsov@qt.io>
Change-Id: If93cc432a56ae3ac1b6533d0028e4dc497415a52
2019-02-08 12:31:02 +01:00
Morten Johan Sørvig
de4f256d48 Wasm: enable thread support
configure.json: Make the “thread” feature be allowed
for wasm but disabled by default.

Change qmake.conf and wasm.prf to enable Emscripten
pthreads mode:
- Add USE_PTHREADS=1 linker flag
- Add PTHREAD_POOL_SIZE linker flag with a default pool size (4).
- Add TOTAL_MEMORY linker flag to set available memory (1GB)

It is possible to override options such as PTHREAD_POOL_SIZE
from the application .pro file using QMAKE_WASM_PTHREAD_POOL_SIZE
To change TOTAL_MEMORY, use QMAKE_WASM_TOTAL_MEMORY

Make qtloader.js work in pthreads mode:
- The Module.instantiateWasm callback must provide the module
  in addition to the instance to Emscripten.
- Set Module.mainScriptUrlOrBlob so that the pthreads web workers
  can access the main script

Task-number: QTBUG-64625
Change-Id: I1ab5a559ec97c27c5fc24500ba5f863bcd275141
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
2019-02-07 16:13:26 +00:00
Morten Johan Sørvig
6e7a7d5fb9 Wasm: enable source map support for debug builds
The source map location can be configured by setting
QMAKE_WASM_SOURCE_MAP_BASE in the .pro file. Fall back
to “http://localhost:8000” if not set.

Task-number: QTBUG-72002
Change-Id: I9da80dacdefc272f267e5db4caac274d93ba4479
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
2019-02-07 16:11:23 +00:00
BogDan Vatra
74e04d6ace Android: follow official android flags for cmake
Update our cflags and lflags with the ones found in android.toolchain.cmake

Fixes: QTBUG-73274
Change-Id: Id9fd9bf04df959239abd3100090a1485e872b2f0
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2019-02-07 09:02:17 +00:00
Michal Klocek
7910dd0a54 Add llvm linker detection to configure
https://gcc.gnu.org/ml/gcc-patches/2018-10/msg01240.html

This is currently only used for webengine, where link time really matters.

New configure options:
* force 'lld'  '-linker lld' or' --linker=lld'
* force 'gold' '-linker gold' or '--linker=gold'
* force 'bfd' '-linker bfd' or '--linker=bfd'

Note before by default gold was always forced (if supported) now default linker
is system default one.

[ChangeLog][Tools][configure & build system] Added --linker=[bfg,lld,gold] configure flag.

Change-Id: Idaa13510da70243c6176b96db846d629cd65c7af
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-02-06 22:11:22 +00:00
Qt Forward Merge Bot
670b843369 Merge "Merge remote-tracking branch 'origin/5.12.1' into 5.12" into refs/staging/5.12 2019-02-06 10:52:13 +00:00
Qt Forward Merge Bot
e4c29088c8 Merge remote-tracking branch 'origin/5.12.1' into 5.12
Change-Id: I486f3c51df4b60fe60b75ba642636a835a75f731
2019-02-06 10:28:01 +01:00
Joerg Bornemann
8e6231f4eb Fix install targets for generated private headers
Header files of modules that specify generated_privates are usually
not yet available at qmake-time. Thus, the installation rule must not
check for the file's existence.

Change-Id: Ifc7ff95422912d255744c9006382ff181176ae77
Fixes: QTBUG-71340
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-02-06 07:17:46 +00:00
Andy Shaw
9435526d50 qmake: Add variables for setting the version number and name in Android
This makes it much easier to have the version information set for an
Android APK without having to manually modify the AndroidManifest.xml
each time.

[ChangeLog][Android][qmake] Can now set the version name and code for
Android using ANDROID_VERSION_NAME and ANDROID_VERSION_CODE respectively
in the pro file.

Change-Id: Ie6813bc3a7444f7baa5e772b93bc2695d9b81e57
Done-with: Markus Maier <markus.maier@rosenberger.de>
Reviewed-by: Markus Maier <markus.maier@rosenberger.de>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2019-02-04 16:57:07 +00:00
Tor Arne Vestbø
5d181961ea macOS: Don't check for stale SDK unless target needs to be remade
Also catches some more variants of SDK mismatch, such as Xcode not
being installed at all, or the SDK missing.

Change-Id: I184aaa571ef0ea722ca64c54f665462dabc17533
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-01-29 11:08:31 +00:00
Joerg Bornemann
c2b0bca984 configure: Respect -continue in qtConfParseCommandLine
If configure is called with -continue, it should not stop processing
command line arguments after encountering an invalid one.

Example:
  configure ... -continue -quack -no-feature-gui
would ignore everything after -quack.

Change-Id: Ia5f0cb13414c9c0c7246ff0c72f8e935fe6dca3c
Fixes: QTBUG-72912
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2019-01-29 10:51:19 +00:00
Joerg Bornemann
11ae0e772c Consume the -skip option in qtbase/configure
...and yield a warning that -skip has no effect in a qtbase build.

This is consistent with configure's help output and enables us to
always pass "-skip qtwhatnot", whether we're calling top-level or
qtbase configure.

Change-Id: Ie5b0791a6000d1d78b1367658ad86a92b2ec6a6a
Fixes: QTBUG-71253
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2019-01-29 10:51:10 +00:00
Morten Johan Sørvig
3a9240428c Wasm: disable resources_big
Errors out with “No data signature found”.

Change-Id: Ia9a38e8c71aef4e090494ed4754f4c14e913b092
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Reviewed-by: hjk <hjk@qt.io>
2019-01-28 16:06:39 +00:00
Liang Qi
980567b3a3 Merge remote-tracking branch 'origin/5.12' into dev
Conflicts:
	src/android/templates/AndroidManifest.xml
	tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp

Change-Id: I4c9679e3a8ebba118fbf4772301ff8fde60455b9
2019-01-26 08:35:40 +01:00
Janne Koskinen
63891267c1 Disable NEON flags from Integrity compiler
Integrity assembler doesn't understand NEON assembly statements.
Compiler enables _ARM_NEON_ and _ARM_NEON to indicate that NEON
intrinsics are available. _ARM_NEON_ and _ARM_NEON needs to be
disabled to skip handwritten assembly code paths in Qt.Auto-
vectorization is enabled without the flags enabled.

Task-number: QTBUG-72716
Change-Id: I84cfbf98bd2af47740a79f4b300c1801017ee22c
Reviewed-by: Tuukka Turunen <tuukka.turunen@qt.io>
Reviewed-by: Kimmo Ollila <kimmo.ollila@qt.io>
Reviewed-by: Timo Aarnipuro <timo.aarnipuro@qt.io>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2019-01-25 11:15:04 +00:00
Kimmo Ollila
f8f96d0fa1 Fix OpenGL library paths on INTEGRITY QC Snapdragon 820
After 521a85395d configure doesn't find
OpenGL libraries from QMAKE_LIBDIR, hence we use QMAKE_LIBDIR_OPENGL_ES2
and QMAKE_LIBDIR_EGL instead.

Task-number: QTBUG-73136
Change-Id: Iaeac46000c5d684f601741cbef91ce745ceb4ea2
Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io>
2019-01-25 11:14:55 +00:00
Thomas Miller
036247e777 Add arm64 winrt target
Change-Id: I45170216be3a0ffe28a9759ffc12aebca342efd2
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2019-01-24 21:04:20 +00:00
Eskil Abrahamsen Blomfeldt
e0dc6dce22 Android: Set minimum supported version to android-21
With the current distribution, this is 90% of active devices, and
it was released in 2014. Qt 5.12 is LTS and will continue to support
older Android versions for a long time to come.

This is to reduce the testing needed on outdated platforms and
allow ourselves to use some newer APIs unconditionally in Qt.
Android 21 was chosen because it is the minimum version that supports
64 bit builds.

[ChangeLog][Android] Increased the minimum supported Android version
to Android 5.0 (API level 21).

Fixes: QTBUG-70508
Change-Id: Ia7b4345e42ca05a25a292f11ccbb8cbd692cf8f0
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2019-01-23 15:21:56 +00:00
Qt Forward Merge Bot
e3da05f39a Merge remote-tracking branch 'origin/5.12.1' into 5.12
Change-Id: Icebd151eae0cf9d400319a42573290d1a911ce26
2019-01-23 10:13:29 +01:00
Lorn Potter
df65087192 wasm: remove BINARYEN_METHOD from link line
This has been removed in emscripten compler version 1.38.23 and will
cause building apps to fail.

Change-Id: I7e58053ce06053f6f1d577377b503cabb035bb58
Fixes: QTBUG-73143
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2019-01-23 01:53:36 +00:00
Qt Forward Merge Bot
f94ca82e0f Merge remote-tracking branch 'origin/5.12' into dev
Conflicts:
	.qmake.conf

Change-Id: Ibfcb30053f3aacb8ec2ec480e146538c9bf440ea
2019-01-21 13:03:09 +01:00
Mårten Nordheim
61af5abb33 clang-cl: use GCC -m CPU feature flag option
To enable non-default options

Change-Id: I2d2f5dc8368a8235fd91e7f9986df4402612a823
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-01-16 14:23:50 +00:00
Joerg Bornemann
af821f79ca Remove duplicate windeployqt_clean target
That target is added unconditionally at the end of windeployqt.prf.

Fixes: QTBUG-73018
Change-Id: I8d29691c30df64bf5383daa10e169985d47592f2
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2019-01-16 11:26:46 +00:00
Tor Arne Vestbø
1b47e7154a Fix default rpath dirs on Apple platforms
The @executable_path relative framework directory is one step below
the executable, as in:

   Foo.app/Contents/Frameworks

not:

  Foo.app/Contents/MacOS/Frameworks

The former is what Xcode defaults to for new projects.

Change-Id: Id08f3f1d80f1c84d76fb71676c5df4a3a6b3da36
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-01-15 14:26:29 +00:00
Joerg Bornemann
69bd238ad8 Fix resolving of libraries on Apple platforms
Qt couldn't be configured with -system-zlib on macOS, because qmake
failed to find "/usr/lib/libz.dylib".
  The library path is something along the lines of
"/Applications/Xcode.app/.../MacOSX10.14.sdk/usr/lib" which doesn't
contain "libz.dylib". But it contains "libz.tbd", which is a YAML-file
pointing to "/usr/lib/libz.dylib". One can pass the absolute path to
this tbd file to the linker, which will then pick up
"/usr/lib/libz.dylib".

Introduce a new variable QMAKE_EXTENSIONS_AUX_SHLIB, which is a list
of auxiliary extensions for shared libs, and add the "tbd" extension
to it on macOS.

Change-Id: I083b79a69d00232e35f9d6164ffa86cb473f1742
Fixes: QTBUG-72745
Fixes: QTBUG-72964
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2019-01-13 18:17:43 +00:00
Tor Arne Vestbø
7044409c87 macOS: Use tool environment to ensure tests load matching Qt libraries
Linking with a framework suffix to pick up the debug version of
libraries doesn't work as long as the dependencies picked up from prl
files are not rewritten to also include the suffix. The result is that
we end up loading both release and debug versions of the Qt libraries.

Use the target environment (target_wrapper.sh) to set the image suffix
instead, which means 'make check' will automatically work.

Change-Id: I60b0840760f68e579c270245d394e1dd609a0ebb
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2019-01-12 12:18:36 +00:00
Oliver Wolff
911da982df qmltestcase: Fix generation of Visual Studio project files
Mimicking the approach from testlib_defines.prf, DEFINES containing a path
surrounded by quotation marks have to be handled differently for Visual
Studio projects.

Change-Id: I26f6a45d4df154f599e8be15b3aa3905cf703a1f
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2019-01-11 12:56:14 +00:00
Liang Qi
0e96b5fe48 Merge remote-tracking branch 'origin/5.12' into 5.12.1
Conflicts:
	src/widgets/kernel/qtooltip.cpp

Change-Id: Ic2f9a425359050eb56b3a4e5162cf5e3447058c8
2019-01-08 09:34:24 +01:00
Oswald Buddenhagen
5733dfbd90 qmake: make CONFIG+=egl work again
while it's legacy and should not be used (use QMAKE_USE+=egl instead),
it shouldn't be broken nonetheless.

amends 310bf3f57c.

Fixes: QTBUG-72564
Change-Id: Id6a070a4653dc1182a6b4d75af027a6ee6cbacae
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Rolf Eike Beer <eb@emlix.com>
2019-01-07 19:07:02 +00:00
Qt Forward Merge Bot
c497f79ad4 Merge remote-tracking branch 'origin/5.12' into dev
Change-Id: Ieb57137ee2b7d0c505e3531d5aa1bcb66978847e
2019-01-07 01:00:08 +01:00