We don't have a -relocatable configure switch. Move the documentation to
the right place (configure -list-features).
The correct configure switches to turn the feature on/off are
-feature-relocatable and -no-feature-relocatable.
Task-number: QTBUG-80928
Change-Id: I96df0f44f12b2efe5a64132e9006d4b73de41255
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Tasuku Suzuki <tasuku.suzuki@kdab.com>
Reviewed-by: Yuhang Zhao <2546789017@qq.com>
Our copy function for qtloader.js does not handle quoting when a
directory has '+' in the path, and this makes the copy method fail.
This is fixed the same way the cxx_future test works
Fixes: QTBUG-79552
Change-Id: Iad8331800aa73eea948e7d2650568645a4c0640c
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This adds instrumentation to the binaries. At the end of their
execution, these will then write a file containing information which code
was executed. This can be used for code coverage analysis.
[ChangeLog][QtCore][configure] Add switch "-coverage source-based" to
enable clang's "source-based" code coverage feature. This can be used
for code coverage analysis.
Change-Id: If31c6849aa797ff8820e041e85a492a14e2f1a6b
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Doing only debug build is not supported at the moment.
Add error to configure.
Task-number: QTBUG-71990
Change-Id: If35d00c3f09d733efe63d5ea66d07e4a3ec922cc
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
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>
Qt 5.14.0 switched the default from -debug-and-release
to -debug only. Change this to -release, like on the
other platforms.
[ChangeLog][MinGW] Qt will by default be built in release
mode. Use -debug-or-release to force the pre 5.14.0
default.
Change-Id: I020268d0672c80cdc0259068c6dc2c743a794237
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
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>
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>
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>
The c++1z feature can stay for now
Change-Id: I899c7b6de822a4533d589c05aaa0066dfddfb977
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
One of our compilers for emscripten coerces all signaling NaNs to
quiet ones, so won't do any actual signaling. Anyone relying on them
to do so shall be disappointed, so it's better that they know about it
at compile-time - or, at least, have the ability to find it out.
Put the signaling NaN producers (and remaining (test) code using them)
under the control of a feature that's disabled when numeric_limits
claims double has no signaling NaN. Assume the bootstrap library
doesn't need signaling NaNs. Sadly, until C++20 <bit>, there's no
contexpr way to test that alleged signalling and quiet NaNs are
actually distinct.
Added some auto-tests for signaling NaN, including that it's distinct
from quiet NaN. Any platform on which the last fails should disable
this feature.
Task-number: QTBUG-77967
Change-Id: I57e9d14bfe276732cd313887adc9acc354d88f08
Reviewed-by: Joerg Bornemann <joerg.bornemann@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>
[ChangeLog][QtCore] Qt installations on the host system can now be
relocated, i.e. moved to other directories.
Add a new feature 'relocatable' that's by default enabled for
non-static builds
- on platforms where libdl is available,
- on macOS when configured with -framework,
- on Windows.
If the feature is enabled, the directory where plugins, translations
and other assets are loaded from is determined by the location of
libQt5Core.so and the lib dir (bin dir on Windows) relative to the
prefix.
For static builds, the feature 'relocatable' is off by default. It can
be turned on manually by passing -feature-relocatable to configure. In
that case, QLibraryInfo::location(QLibraryInfo::TranslationsPaths) and
friends will return paths rooted in the user application's directory.
The installed and relocated qmake determines properties like
QT_INSTALL_PREFIX and QT_HOST_PREFIX from the location of the qmake
executable and the host bin dir relative to the host prefix. This is
now always done, independent of the 'relocatable' feature.
Note that qmake is currently only relocatable within an environment
that has the same layout as the original build machine due to absolute
paths to the original prefix in .prl, .pc and .la files.
This will be addressed in a separate patch.
Task-number: QTBUG-15234
Change-Id: I7319e2856d8fe17f277082d71216442f52580633
Reviewed-by: Alexandru Croitor <alexandru.croitor@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>
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>
Conflicts:
configure.pri
Also required s/solid\.color/solidColor/ in a couple of places in:
src/gui/painting/qpaintengine_raster.cpp
Change-Id: I29937f63e9779deb6dac7ae77e2948d06ebc0319
Android is also unix, so can pick up the host 'arch' binary when
rerunning configure. This patch splits the names so we don't end up
confusing target and host binaries.
Task-number: QTBUG-76445
Change-Id: Ib65251a514e45ad8873f523d71c17e13e56ea58a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Remove the config.unix condition from the ccache feature. This enables
us to use ccache for non-Unix cross-builds like MinGW on Linux.
Change-Id: I3b108c2288754ad5dd05834e3d5a487c2da4ac00
Fixes: QTBUG-76681
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Backtraces with optimize-debug are less useful due to scoped variables
no longer alive, and some gcc bugs with inlining.
Fixes: QTBUG-75514
Change-Id: I6d62441047daee8f7079d1538dfc92015dd7ea63
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
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>
It is 2019, so the name c++17 is more than fixed by now.
At the same time remove an old restriction on using -c++std= with MSVC,
since VS2017 (15.7), we have been able to request c++14 and c++17.
Change-Id: I7129799a2e46301b7ec1322251a3805f4d6b20a8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
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>
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>
Also blacklist tst_QRawFont::unsupportedWritingSystem() and
tst_QGlyphRun::mixedScripts() on windows for now.
Conflicts:
qmake/generators/makefile.cpp
src/corelib/itemmodels/qstringlistmodel.cpp
src/platformsupport/fontdatabases/windows/qwindowsfontengine_p.h
tests/auto/corelib/itemmodels/qstringlistmodel/tst_qstringlistmodel.cpp
tests/auto/gui/text/qglyphrun/BLACKLIST
tests/auto/gui/text/qrawfont/BLACKLIST
Task-number: QTBUG-72836
Change-Id: I10fea1493f0ae1a5708e1e48d0a4d7d6b76258b9
in addition to the actual library resolution, also resolve the headers
belonging to the library, to validate the include path, and possibly
ensure that the right version of the library is present.
the "include" entries were moved out of the "test" objects, and renamed
to "headers". this cleanly permits libraries without compile tests.
the headers were not put into the sources, because the variance among
the includes is generally orthogonal to the variance among the
libraries.
note that this - like the library resolution - provides no support for
darwin frameworks. consequently, the opengl libraries are excluded from
the conversion on darwin.
similarly, wasm is excluded (centrally), because emcc is magic and would
need advanced wizardry to be dealt with.
Change-Id: Ib390c75371efa2badcfec9b74274047ce67c3e5a
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
See next commit for details on why this is a good idea.
[ChangeLog][Important Behavior Changes] The Qt resource system now
supports compressing content using the Zstandard (https://zstd.net)
algorithm. Compared to zlib, it compresses better for the same CPU time,
so this algorithm is the default. QResource::isCompressed() returns true
for either compression algorithm. Use QResource::compressionAlgorithm()
to find out which algorithm to decompress. QFile will automatically
decompress using the correct algorithm.
Change-Id: I343f2beed55440a7ac0bfffd1562e9a8f94933a7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
this considerably speeds up failures, as no doomed build is attempted,
and produces more reliable results, as no second lookup (which would be
subject to environment changes) is done any more during the build.
in principle, this also opens up possibilities like selecting specific
variants of dependencies, automatically extracting rpaths, etc.
qt_helper_lib.prf also needs to create fully resolved library names now.
Change-Id: I65f13564b635433030e40fa017427bbc72d1c130
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This removes the need for specifying "-nomake examples"
on the configure line.
We are using static builds; building all of the examples
is too space and time consuming (especially time).
Change-Id: Iff23239ca7304b1d1cf734c8bf69ad3f8ef31844
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
This removes the need for “-no-feature thread”.
Thread support will be added at later point in time,
see QTBUG-64625.
Change-Id: I4d1dedd527aa83d6033bf108f5f34e759517b954
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
This removes the need for specifying "-static" on the
configure line.
Shared builds are on the roadmap (QTBUG-63925), but
not currently supported.
Change-Id: I7f72ac702bc77304abfa6a962cb1139c25fb5e35
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
and fix handling of incoming binary data
Change-Id: I31e97505ad4ff64cf8e380df5d0d6b70c3cd60b0
Reviewed-by: Ryan Chu <ryan.chu@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Do not unconditionally enable precompiled headers
for MSVC since clang-cl does not support it.
Task-number: QTBUG-63512
Change-Id: I95df7d3bb51647ecee8ddc3161421768313ab4a1
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>