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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
Change-Id: I0b35c32f3730dc15d868b10489abeda909bbe926
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
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>
[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>
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>
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>
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>
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>
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>
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>
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>
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>
-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>
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>
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>
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>
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>
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>
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>