this was introduced in 60e5a1c8 for no apparent reason.
Change-Id: Idcbc6df3df4e4846c76b3e4215d753a1c97e2eec
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
the arguments after '--' are by definition meant only for the top-level
project, as that's where configure is invoked from. passing them to
sub-projects just adds noise to the make output and misleads users.
note that this specifically does not support qmake -r, which will break
if the subprojects rely on the arguments being absent. this isn't a
problem, because the qt build doesn't support qmake -r anyway.
Change-Id: I7ecff6212ce3137526005fc324a4a7ae45e3345e
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
turns out that just appending builtin-qt.conf isn't a good idea:
executable-editing tools (objcopy, prelink, etc.) will happily drop the
"attachment".
a safe method would be adding a proper section to the executable, but
there doesn't appear to be an objcopy equivalent in msvc, and using
entirely different methods of embedding the file with different
toolchains seems like a rather bad idea.
so instead go back to the old method of building qmake with a generated
qconfig.cpp. of course, as said file is now created by qmake itself, we
have to compile qlibraryinfo.cpp a second time, and link a second qmake
executable.
Task-number: QTBUG-57803
Change-Id: I9e232693550aa870cec154e49cc06add13017cc2
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
it makes the call more noisy for no particular reason.
and the new code is even easier to read ...
Change-Id: Ib4dfd373f351eeaca99e6bfc42b631f931ec987d
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
now qmake is the last command called by the unix configure script.
as it happens, this was already the case in the windows script, but only
because it didn't print these messages at all, which it implicitly does
now.
another effect of this is that repositories outside qtbase will now also
get the installation note in modular builds, which makes sense.
Change-Id: I567146936b216185a8e0f61e445222215608bf13
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
... so that we can turn it off if we don't want to build it.
Change-Id: Ia330dfa1477bcd2dc8e24eb55400e100fca156b5
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
... so that we can turn it off if we don't want to build it.
Change-Id: Ib27386da4754d843d4e4cbb05f9542852efefb88
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
This way we can disable it by passing -no-feature-sql to configure.
Change-Id: Ia47d72101de0788478997fa1854cedcd1742f6fd
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
This way you can disable support for QtNetwork by specifying
-no-feature-network on the configure line.
Change-Id: I46217ccc525a9e2c85394ed4eb6db0e2b60b6d86
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
The expression 'maximum - minimum' has undefined behavior when
'qint64(maximum) - minimum > INT_MAX'. Use 64-bit arithmetic
instead.
Also fix calculation of the progress when minimum != 0.
Rename QStyleOptionProgressBar* variable to avoid line wraps.
Change-Id: I1d48a7930e7f6d69798c2e878bb0045d55c2f057
Reviewed-by: David Faure <david.faure@kdab.com>
The expression 'minimum - 1' invokes UB when 'minimum == INT_MIN'.
Likewise, the expression 'maximum - minimum' invokes UB when
'qint64(maximum) - minimum > INT_MAX'.
Fix by restructuring the code or else by using 64-bit arithmetic.
Change-Id: I352eafa72f28ae907f41c8f88abcf0a81705c718
Task-number: QTBUG-57857
Reviewed-by: David Faure <david.faure@kdab.com>
Since the destructor is not virtual we need to
cast to the proper class when deleting otherwise the wrong
destructor is called and the object memory is not entirely freed.
Change-Id: Ie4e0e91bfa6e802c7d72fd1f137f5c7f3f31c8a0
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
There are a few places that did not check if the returned interface is valid.
Task-number: QTBUG-52536
Change-Id: I56ca0952fec0b44dfd4b3991aa94554e9c829642
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
Try to return the immediate parent first, nothing else makes sense. The
original code relied on the window pointer usually being nullptr, which
is not reliable.
Make sure to check the validity of the handle returned, since it's
possible to have the platform window being nullptr. It's not quite clear
to me how to end up with a null window though.
Task-number: QTBUG-52304
Change-Id: Id3e70cdab980fb0a86cebbb7c10d824d8a7dd80b
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
Commit 88e043a8 introduced two bugs:
1. When constructing the WHERE clause, the closing ' around the owner
name was dropped.
2. When constructing QLatin1Strings for comparison with system owners,
a size of -1 was passed, with the comment "force strlen call". But,
unlike QString, QLatin1String does not invoke strlen(), but stores
the negative length unchanged, making the comparisons always fail.
Change-Id: Ie2835b76877c31ee32c900f67eb0853df7110dbb
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
We have to enable qt_safe_ftok with either sharedmemory or
systemsemaphore. In order to make the resulting QT_CONFIG work with the
bootstrap library we switch the features off for bootstrapping. Some
tests and examples have to be excluded when sharedmemory is not
available.
Change-Id: I3fc3926d160202b378be2293fba40201a4bf50c5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QFileSystemModel inherits from QAbstractItemModel, so it has to be
disabled if the latter is not available.
Change-Id: Ifc56f7e311d84bd15e8b4ed95d67bf9ad9aba888
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
getMaximum() and getMinimum(), called during parsing, create new
QDateTime instances, which on Linux end up calling mktime().
Making these static (for the common case of LocalTime spec)
improves performance dramatically, when parsing several date/times.
tests/benchmarks/corelib/tools/qdatetime/ (after fixing it to
actually parse a valid date/time) says:
RESULT : tst_QDateTime::fromString():
- 36,742,060 instruction reads per iteration (total: 36,742,060, iterations: 1)
+ 24,230,060 instruction reads per iteration (total: 24,230,060, iterations: 1)
Change-Id: I0c3931285475bf19a5be8cba1486ed07cbf5e134
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This pertially reverts commit 3ec57107ce
and brings back the hack to prevent the DLL from being unloaded. It
should have been enough, but we've got reports that it's still causing
trouble. Since it causes not much harm to keep the DLL loaded (worst
case scenario is that QtDBus and QtCore remain loaded after a plugin
gets unloaded), we'll keep it.
Note: Microsoft is aware that their way of killing threads on process
exit is a flaw. See https://blogs.msdn.microsoft.com/oldnewthing/20070502-00/?p=27023/
Task-number: QTBUG-53031
Change-Id: I2962773739e34633b033fffd1493dce695b008c0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
May of the tests initiate a scan / update of the network configuration
and expect the API to deliver exactly one update. This turns out to be a
race condition as the update may be emitted multiple times, as
QNetworkConfigurationManagerPrivate::updateConfigurations() is called
via posted events (queued signal emissions) from the bearer thread, and
so after creating the spy we may receive an update from _before_ and end
up emitting the signal multiple times.
Task-number: QTQAINFRA-1040
Change-Id: I931e2907f0cb86d48b4ab1a8795d75206035ea11
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
this is rather hacky. a proper solution would auto-generate help from
the command line argument definitions, at the cost of needing to
bootstrap qmake first.
Change-Id: Iada6e25d5b31d7db0595309887f2d13295bbc1e3
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
we don't want to do the (possibly interactive) license check when the
command line is not valid.
Task-number: QTBUG-18459
Change-Id: I68c3b7ed4646e49865922ab5612f971930698356
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
log a message in all unsuccessful exit paths.
Task-number: QTBUG-57217
Change-Id: I8b0f2685d327da583c3e42c8149327e05b2a66cc
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
beyond this point, simulator_archs is only used to determine from which
one of the lists the remaining arch came from (and device_archs is
actually never used again). the lists are assumed to be mutually
exclusive, so truncating them won't affect in which of them the first
element of their concatenation is found.
Change-Id: I4736ed7e51f6623efa6bd37892ab1fcf8c83ae8b
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
there appears to be no particular reason why this ended up in sdk.prf,
and it has become an actual problem now that the sdk is resolved from
default_pre.prf already, making it impossible for projects to override
the deployment target.
Task-number: QTBUG-56965
Change-Id: I8e319d10cdfb95acc1da1f431c8b8d4f76d1168e
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
uikit already implies !host_build, as host builds are executed with the
host spec. and the only darwin alternative to uikit is macos.
Change-Id: I6b47d68bad5d4427640901ff1e32dacf9a4e352b
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
this is mostly for appearances (as evidenced by everything working
despite it being missing from some specs), as the variable is just a
fallback for moc.prf's automatic detection.
Change-Id: Ie4af24c02ec03aaa1810281d1bb6876ea38cedf8
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
When saving state for a 3-columns headerview and then restoring that
state onto a 5-column headerview, the headerview shouldn't suddenly think
it has 3 columns.
Rather than making restoreState() fail, we adjust for the additional
columns, so that we can still apply the customizations from the user to
all other columns (hiding, moving, etc.).
Change-Id: I3f220aa322ea8b629d2fe345f8cde13e0ea615d6
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
157ee01a8d was trying to
minimize some side effects of the bug in the evdev driver
(https://bugs.freedesktop.org/show_bug.cgi?id=98188) by
not changing mouse button state on motion.
Unfortunately it resurrected bugs that were fixed by
76de1ac0a4.
Filter out mouse events from touch screens instead.
This change reverts 157ee01a8d.
Task-number: QTBUG-32609
Task-number: QTBUG-35065
Task-number: QTBUG-43776
Task-number: QTBUG-44166
Task-number: QTBUG-44231
Task-number: QTBUG-56156
Change-Id: Ie17710d94beabeb08681d669a9d8309be9b44e73
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
The article does answer the questions asked in the bug.
Task-number: QTBUG-56629
Change-Id: Ib8bac0acf45bc10598fc47feb6dd73005b5ad040
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Two sentences that read like author notes likely added by accident.
Task-number: QTBUG-56630
Change-Id: I7a0b114e128f95e54e9e8f26b43493f67747d650
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
MinGW's headers are lowercase, and MSVC is generally run on a case-
insensitive file system. Including in the lowercase is the more
compatible option.
Change-Id: I288cecb77ddd8029bb3925e613a830dd9ce96a6c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
src/widgets/styles/qwindowsvistastyle.cpp: In member function 'virtual QSize QWindowsVistaStyle::sizeFromContents(QStyle::ContentsType, const QStyleOption*, const QSize&, const QWidget*) const':
src/widgets/styles/qwindowsvistastyle.cpp:1872:9: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
if (!sz.isEmpty())
^~
src/widgets/styles/qwindowsvistastyle.cpp:1874:13: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if'
return sz;
Change-Id: Ifd3faef8c93f12d5fadaf4edf875fbe0fc6fb785
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This code always intended to follow the recommended checking order from
the spec, which says "if multiple globs match, use file contents".
But if the globs had different weights, it would discard globs with
lower weights, and then wrongly conclude, if there is only one glob
left, that there was no ambiguity.
The correct way is rather: remember that multiple globs matched,
do determination from contents, and if that didn't work, *then* use
(one of) the highest-weight glob(s).
This fixes PGP-encrypted *.asc files being detected as text/plain rather
than application/pgp-encrypted.
(https://bugs.kde.org/show_bug.cgi?id=346754)
Change-Id: I734459daf9f502baa95ebb89432819964e0ce304
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* apply endianness to the mask as well
* do not apply endianness to "host" entries, they were wrongly behaving
exactly like "big endian" entries.
The issue with the mask was detected by the audio/aac magic
<match type="big16" value="0xFFF0" mask="0xFFF6" offset="0"/>
which failed to identify the test file ct_faac-adts.aac since it was
applying the mask 0xFFF6 instead of 0xF6FF (on a little-endian machine).
Not yet detected by tst_qmimedatabase which is based on shared-mime-info 1.0,
will be covered by the upgrade to 1.8 in dev.
Change-Id: I4fb7af2d367099817e712b14f2a031066d0ac432
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Since the loop says p <= e, no +1 should be added to e.
Testcase:
The magic for application/x-gameboy-rom says
<match type="byte" value="0x0" mask="0x80" offset="323"/>
and this code was checking both byte 323 and byte 324, finding a match
at pos 324, returning application/x-gameboy-rom erroneously.
Given the magic for application/x-gameboy-color-rom:
<match type="byte" value="0x80" mask="0x80" offset="323"/>
the expected result for game-boy-color-test.gbc is application/x-gameboy-color-rom
Not yet detected by tst_qmimedatabase which is based on shared-mime-info 1.0,
will be covered by the upgrade to 1.8.
Change-Id: I2396cb1ccfb26db5a24d5551fef493cc0b98a247
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Disables escalating the implicit fallthough warning to an error, since
Qt is not yet free of unmarked implicit fallthroughs.
With this we can clean the code in the dev branch instead of in 5.6 and
5.8, and only backport bug fixes.
Change-Id: Id30ee21b77de6defcb7d5bb1e05e86c0db098481
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>