Consider a debug_and_release build of a static library.
Set DESTDIR to different values for debug/release.
Let TARGET be the same for debug/release.
Now qmake would generate code in Unix Makefiles like this:
rm mylib.a
ar mylib.a ...objects...
rm debug/mylib.a
mv mylib.a debug/mylib.a
and for release analogous. This clashes when building in parallel.
This patch resolves this conflict by reducing the commands to:
rm debug/mylib.a
ar debug/mylib.a ...objects...
We believe that every ar implementation that's in use for Qt
is able to operate on files in subdirectories.
[ChangeLog][Important Behavior Changes][qmake][Unix] QMAKE_POST_LINK
steps of static libraries are now required to operate on $(TARGET) in
$(DESTDIR) instead of $$OUT_PWD. This matches the Windows backends.
Task-number: QTBUG-48287
Change-Id: I192f488ed74c56bc32862426d9e9d4237d9b8135
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The test is moved from tst_qtreeview to tst_qtreewidget as it tests
qtreewidget class.
C++ usage is fixed, there was an illegal C cast that was causing crashes
Change-Id: I80e90a9b531e87f9b133186b6f48be42f54901b5
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Add an option to skip a generic bearer engine if needed (by testing
environment variable QT_EXCLUDE_GENERIC_BEARER).
Task-number: QTBUG-41866
Change-Id: I1b53ed1d22a7b34de5c6f6d0386ed242b2ca5e00
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Detection for most of them is free because we're loading the entire
registers anyway. The only exception is AVX512VBMI, which is in a new
register we hadn't yet read from.
I've also added the new GCC names so they can be used with
QT_FUNCTION_TARGET. The only two exceptions are "movbe" and "popcnt",
which are extremely restricted in use and we are not likely to have code
dedicated to using them.
Change-Id: Ib306f8f647014b399b87ffff13f1d8fd29e58be0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Instead of trying to detect one bit and set another, let's just use the
bits from the x86 CPUID instruction on x86. This makes use of the full
64-bit space now.
Since MSVC doesn't like enums bigger than 32-bit, we have to store the
bit number instead of the actual bit value in the constant. For that
reason, I also renamed the constants, to catch anyone who was using them
directly, instead of through qCpuHasFeature.
Change-Id: Ib306f8f647014b399b87ffff13f1d587692d827a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
I've tested with Clang 3.7 and ICC 16 on Linux, XCode 6.4 on OS X for OS
X (not iOS).
Change-Id: Ib306f8f647014b399b87ffff13f1f4291d801a20
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Qt needs to return false in case it does not handle the "extra"
buttons (like WM_XBUTTONDOWN) which causes Windows to send the
corresponding WM_APPCOMMAND message (like APPCOMMAND_BROWSER_FORWARD).
Task-number: QTBUG-48117
Change-Id: Id2c8005ee992b0abd8af2aacbcb97c4eedcfa32f
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
On Windows, Qt needs to return false in case it does not handle the "extra"
buttons (like WM_XBUTTONDOWN) which causes Windows to send the
corresponding WM_APPCOMMAND message (like APPCOMMAND_BROWSER_FORWARD).
Task-number: QTBUG-48117
Change-Id: I093cd2d8205a39c3a042dd8a0d19c7229003761f
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
Replace deprecated File Manager APIs with modern equivalents.
Change some Q_OS_MACX to Q_OS_DARWIN in file system related code.
All of these apply to iOS as well as OS X, and were ifdef'ed for OS X
only primarily due to legacy reasons - carryovers from Qt 4 or Carbon
APIs which have since been refactored into using CoreFoundation.
This also makes the code consistent with the documentation.
Change-Id: I414e9bdfffff731413ddf16171b1317027d87caf
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
The naturalTextWidth() of the QTextLayout already includes the left
and right bearing of the actual text in the line edit, there's no need
to shift the text based on the minimum left and right bearings as well.
This may result in text that is closer to the edges of the line edit
on platforms that relied on this flawed logic, but that should be
adjusted back using the corresponding style hints.
Change-Id: I1d5edbeda7afe3e69b972841d280eb9e573675f5
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
If a mouse event from the window system changes both position and buttons
at the same time, then it's split by QGuiApplication into a mouse move
event followed by a mouse button event. Propagate the source of the
original mouse event to the mouse button event.
Change-Id: I075fb4ad9e4338bf8ec170630ce270b38d8682d9
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Virtual roots are windows, so we should request XCB_ATOM_WINDOW
instead of XCB_ATOM_ATOM.
Change-Id: I59558b1a3c37cb9bcad42bc0695d420f59088eb9
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Add note mentioning it to QTcpSocket::incomingConnection() and
update SSL socket server code snippet accordingly.
Change-Id: I9d228dabde76f9e9cd5140edf08be09a588066c8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
On Windows, some messages occur before a QPlatformWindow is actually
created, for example WM_WINDOWPOSCHANGING, which is handled in
QWindowsWindow::handleGeometryChangingMessage().
Extract a static function QPlatformWindow::closestAcceptableGeometry()
from QPlatformWindow::windowClosestAcceptableGeometry() and use
that in QWindowsWindow::handleGeometryChangingMessage().
This fixes a regression crash occurring in Qt 5.6 when running
the example from QTBUG-48201.
Task-number: QTBUG-36220
Task-number: QTBUG-48201
Task-number: QTBUG-46615
Change-Id: I86b8f923447c8e447382427cf5795628ef1c9717
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
I added this sometime in the past to work around some ICC bug in
position-independent code. Modern versions don't have the bug.
Change-Id: I42e7ef1a481840699a8dffff140049ce927cdff2
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
See https://software.intel.com/node/522852. There are options to turn
off LTCG and, on Linux, to enable/disable fat objects.
Change-Id: I42e7ef1a481840699a8dffff14003db5a9c95b83
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This is probably emitted in error in ICC 16.
warning #809: exception specification for virtual function
"QQmlEnginePrivate::~QQmlEnginePrivate" is incompatible with that of
overridden function "QObjectData::~QObjectData"
Change-Id: I7a21ba10770ba008bdc18f535502376e1d92520f
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This is a repeat of acf80b9a2b, but this
time it appears ICC 15 works and ICC 16 doesn't. ICC doesn't like
polymorphic, exported classes with inline constructors.
qsvgiconengine.obj : error LNK2001: unresolved external symbol "const QIconEngine::`vftable'" (??_7QIconEngine@@6B@)
Task-number: QTBUG-48062
Change-Id: I82493c0f52084e0588352cd0c26e1293b0727242
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This is for compatibility with old Qt versions that had this.
Task-number: QTBUG-48360
Change-Id: I42e7ef1a481840699a8dffff1405c0a348e32e27
Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
The .altmacro is not supported with Clang's integrated assembly.
The worst part is that I had this fixed, but apparently I never pushed
the update to Gerrit and then we staged the old version. This commit
brings back the fixes.
Incidentally, it also makes things work with freebsd-clang.
Change-Id: Id2a5d90d07d7ee470fcb9ad9696a9a0f9ced7ea7
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
there is no particular reason to have them in qt_functions.prf any more,
while the separation made the code harder to follow.
Change-Id: Ie44c9784358f382f7bc863b421ff5b440211d66f
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
there is no particular reason to have it in qt_functions.prf.
Change-Id: I88ed1ea937a9a88a4625a6de7bcd3a29957560da
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
the addition of qt's rpath belongs into qt.prf - even on mac.
so consolidate the two implementations.
as a nice "side effect", we get relative rpaths also on linux.
another "side effect" is that we don't unnecessarily add the qt rpath to
qt modules also on linux.
the qt rpath addition mechanism should not be responsible for setting
the policy who gets a relative rpath, so move the logic to higher-level
callers.
Change-Id: I52e8fe2e8279e7b1ac25fae758867a5cb1cafcf8
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
the rpath applies only to the installed on-device location and is
consequently always the same for all modules, so there is no point in
indirections.
Change-Id: Ia0590552aa317d799a2d3879fd0c0768344b9645
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
this variable is not referenced anywhere else.
Change-Id: Ib4d0a47a08d029f65542e752fa2a47c992e061fa
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
the old plugin loader which test-loaded plugins (without their
dependencies) is gone, so the hack is obsolete.
Change-Id: I68077cb58174dfbcb0b5372e2574de41f48d35c9
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
$ORIGIN (or $LIB) needs to be escaped to survive the trip through
make and the shell.
this shouldn't break anything, as there was simply no way to get it
right so far.
Change-Id: I86337c5994d10dae2e80dd2f858f74874b14bca7
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
ppc/ppc64 and 32-bit x86 have been dead for a while.
consequently, the legacy macx-g++-64 spec was most probably not used.
which in turn meant that NATIVE_64_ARCH was never set (in particular on
windows hosts ...), which means that the android ndk host auto-detection
was effectively broken.
the arch code in mac/default_post.prf was also never triggered, so nuke
it as well.
Change-Id: Ic0775e40b273a22e0a15808cac328e0df33c2155
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
According to MSDN, the zero value of ICONDIRENTRY bHeight and bWidth
fields mean a maximum icon size 256 pixels. So QtIcoHandler::option()
should return 256 instead of 0 pixels for such icons. Also there is
fixed wrong seek offset at the second call on this method.
http://blogs.msdn.com/b/oldnewthing/archive/2010/10/18/10077133.aspx
Task-number: QTBUG-48103
Change-Id: I99f0c9720fd58889045b0c73c51498f2065b0b91
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
By serializing the capitalization value of QFont, it ensures that it is
correctly preserved when QPicture streams it and later plays it back.
Subsequently the QDataStream version has been bumped up to account for the
change of the data format for serializing QFont.
[ChangeLog][QtGui][QFont] QFont now serializes the capitalization setting.
[ChangeLog][Important Behavior Changes] QDataStream version bumped up to
17 to account for changes in the serialization of QFont.
Task-number: QTBUG-15214
Change-Id: I042680760e5a69d18d41e786b7500a3eebbe562f
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
Calling runOnUiThread() only queues calls that comes from a different
thread then the UI thread. The problem with the current solution is that
we can't promise or rely on the calls being delivered in the same order
they were called. Another consequence of the old behavior is that we
potentially cause long lasting synchronization points, which can cause
the application to become unresponsive or in worst case result in a
deadlock. With this change all calls to runAction() will be queued on
Android's main message queue (aka the UI thread) and return immediately.
Change-Id: I50a4273ae9ba8ad17fb2c50ccd57449e4fbc12f9
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
It was just documented as a method and signal so far, even though it
already was a property. This patch merges both documentations into one.
Change-Id: I3fb4090b773ba8762ad9e830303812887b75add3
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
The correct macros can be easily checked by running:
.../arm-linux-androideabi-gcc -E -dM - < /dev/null | grep -i ANDR
Otherwise we're just relying on the user to set up explicitly the
toolchain to target Android
Change-Id: I7b68521f43031c13da99b07626360d0702bff4ca
Reviewed-by: BogDan Vatra <bogdan@kde.org>
According to the SCXML specification, the state-machine can exit the
interpreter loop when a final state has been reached. This happens after
finishing a macro-step or when it ends up in a final state right after
startup (e.g. when the only state is a final state). This patch adds a
virtual method which can be used to detect this reliably.
Change-Id: I594e952a4972dd70d4089a2c4ce1c86880568eb9
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
It sends a shortcut override event directly, which should go
though QPA anyways.
Change-Id: Ie2c6f45cd44222cd9be8846099573dcd2968a77c
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
QDBusConnectionPrivate can only be a client or a server, not both, so
the DBusServer and DBusConnection pointers can be shared, like the
QDBusConnectionInterface and QDBusServer pointers in the other anonymous
union.
Change-Id: I9a75ad8521ae4e5cbbe5ffff13d1baa8ab83c42f
Reviewed-by: Albert Astals Cid <aacid@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
P2P connections don't have senders and receivers, so asking
QDBusConnection to connect to a signal with a sender was a mistake
(added in 5368e44a86). Due to an internal
bug, this never presented itself -- double fault.
Fix the connection so that we don't get unit test failures when the bug
is solved.
Change-Id: I9a75ad8521ae4e5cbbe5ffff13d1a78b7dea6d07
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
This commit moves the code that finishes the signal-slot connection into
the QtDBus auxiliary thread. That is necessary because we're holding the
lock for writing while making blocking calls. The auxiliary thread might
be waiting for us to release that lock while processing some previous
message.
Change-Id: Iee8cbc07c4434ce9b560ffff13d0521b94a51833
Reviewed-by: Albert Astals Cid <aacid@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
This is an optimization but is required. Instead of going through the
entire (dis)connectSignal() stack to add/remove matching rules for the
NameOwnerChanged bus signal and call into our serviceOwnerChangedNoLock
slot, create a static hook that will match the signal and simply add/
remove the rules as needed.
The required part is that this avoids a recursion into connectSignal().
The next commit will move this code to the QtDBus manager thread and we
won't be able to call connectSignal() from there (it would create a
deadlock).
Change-Id: Iee8cbc07c4434ce9b560ffff13d074ce90ad02d4
Reviewed-by: Albert Astals Cid <aacid@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
In two commits, we will attempt to call this function from the manager
thread, so we need to be sure this function works from there. Right now,
it would deadlock in QDBusPendingCallPrivate::waitForFinished(), inside
QDBusConnectionPrivate::sendWithReply().
The solution is simple: expand sendWithReply to the sendWithReplyAsync
function it calls anyway, but tell the internal DBusPendingCall to
finish before we call waitForFinished().
Change-Id: Iee8cbc07c4434ce9b560ffff13d0749013d771ab
Reviewed-by: Albert Astals Cid <aacid@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
That function was added in the previous commit, so deduplicate the code
from QDBusAbstractInterfacePrivate::initOwnerTracking().
Change-Id: Iee8cbc07c4434ce9b560ffff13d06f1d9fb0cde5
Reviewed-by: Albert Astals Cid <aacid@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
With kdbus, we won't have a regular signal, but instead a special
message. So keep the logic of what to do in QDBusConnectionPrivate.
The #ifdef is to make sure the bootstrapped qdbuscpp2xml continues to
build in cross-compilation environments.
Change-Id: Iee8cbc07c4434ce9b560ffff13d06f0d9904cb6d
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>