configure: Document that -sdk only applies to the target mkspec

Change-Id: Ie4a9e7c9d2888f92aa891ba8fcc034ea49b22de2
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
iOS: Flesh out device-pixel-ratio handling in QIOSWindow

We don't need to cache the device-pixel-ratio, as we can ask the UIView
directly. We do need to set it though, as the default behavior of
matching the screen scale does not apply for EAGL-backed views,
but the ratio needs to match the current screen the view is on.

Change-Id: I29e4a4fa4f4b767d86265ec899fb43a355b5c3a3
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Handle key window as part of QWindow activation

The default UIWindow may not be the only UIWindow around in a multi
screen setup.

Change-Id: Ia7243190321a1416e577634bf5e010dd67d482e6
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Tie QIOSContext FBOs to corresponding QPlatformWindow, not QWindow

A QWindow may be created() and destroyed() multiple times in the lifetime
of the window, each time resulting in a new platform window (QIOSWindow)
being created. This QIOSWindow is backed by a new UIView each time, hence
it needs a new FBO and renderbuffer-mapping, since the previous
renderbuffer was mapped to the old UIView.

This fixes a bug where a QWindow would not render after a destroy()
unless it was resized (which triggered new FBO/renderbuffers).

We need to inherit QObject so that we can watch the destroyed() signal.

Change-Id: I93172dd6280b86b49755bf7abddf061d7e6b66f1
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Get rid of separate release pool for QIOSScreen

We don't use separate pools anwyhere else, and this was copied straight
from the UIKit plugin. Unless there's a good reason for having it in this
particular place we should keep things consistent.

Change-Id: I9a3f83bcc5894a2cdfd9af7818b46d6c0f8448da
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Remove background color for UIWindow and UIViewController's root view

They were handy while debugging the iOS platform plugin, but should not
affect users who link against debug libraries, so let's just remove them.

Change-Id: I61b157e81130e5d951c22892e00f71e593082b1d
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Enable clipping of subviews when QWindow has child windows

QWindow::setParent() is documented to imply that the geometry of the
window is in the parent's coordinate system and that the window is
clipped to the parent.

Instead of always enabling clipping of subviews for our UIView subclass
we dynamically detect if we have QWindow children and enable/disable it
on the fly.

Change-Id: If83de94c55cbd19de401ab835e86bb7be5999d71
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
Android: fix crash on exit

Let's not try to dereference the null pointer.

Task-number: QTBUG-34746
Change-Id: Iee79b711bd81614e36af4ab3612f9a87053a39f2
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
QOpenGLPixelTransferOptions: declare as shared, add move assignment operator

A move constructor cannot be added because the class uses
a smart pointer to hold its pImpl, so the move ctor would
have to be out-of-line, destroying BC between C++11 and C++98
versions of Qt.

Member-swap is required for Q_DECLARED_SHARED, which in turn
enables efficient use of the class in Qt containers by marking
it movable.

Change-Id: I1aaa5bf3343a92e621d9464d8e4352f4e5ceff1f
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
QOpenGLTexture: mark (Target) ctor explicit

Disables implicit conversions from Target to QOpenGLTexture.

Change-Id: I2edd2dc4528a311577f0b7df4f6ce22696336a88
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
QOpenGLTexture: mark (QImage) ctor explicit

Disables implicit conversions from QImage to QOpenGLTexture.

Change-Id: I09b4d236dde8eae5258e6a954f4e02b4451990bd
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Detect architecture before auto detection

Some compile checks may depend on the architecture,
e.g., NEON is only available for ARM, so it makes no
sense to check it for this architecture. Therefore
we need to run the architecture check before we
auto detect settings.

Task-number: QTBUG-34743
Change-Id: I53208d25b0ae0fd93cccc7394307b8ee286576a2
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Autodetect Neon support under Windows

This is done to autodetect Neon support for QNX.
It might make sense for other platforms as well,
so enable the compile check for all target platforms.

Task-number: QTBUG-34743
Change-Id: I1d149d1942ce0caa288cb56491e4a0ba455dda7d
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Autodetect Fontconfig for QNX

Task-number: QTBUG-34743
Change-Id: Ib9bba874137b1ef081cb7e8450746abbe983ebc9
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Use compile check instead of searching header for ICU

The findFile would need to look though all include
paths the compiler is supporting, which can be very hard
to support for multiply compilers. It is way easier to
use a compile check to catch all include paths the
compiler supports. This fix is needed to find correctly
ICU under QNX.

Task-number: QTBUG-34743
Change-Id: I4f755042a76882b304b058355cf54e37b25df61d
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
clean superfile and cachefile paths upon creation

otherwise, if the output dir is the root, the path would be denormalized.

the code for finding existing files already does that.

Change-Id: I56d70477e9c9ffcd936325068624a84df10ffd87
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
support a cache that is really just a cache

unlike .qmake.cache & co., the presence of this file has no magic
effects on where mkspecs, modules and other things are searched.

as the obvious name "cache" is of course already taken, we call it
"stash".

the file is searched up to the super cache (if present), otherwise up to
the normal cache/conf (if present), otherwise up to the root.
if it's not found, it is created next to the super cache (if present),
otherwise next to the cache/conf (if present), otherwise in the current
output directory.

note that the cache really should be created and populated by the
top-level project if there are subprojects: otherwise, if there is an
"anchor" (super/cache/conf), subprojects would race for updating the
cache and make a mess. without an "anchor", each subproject would just
create its own cache, kind of defeating its purpose. this is no
different from the existing "cache", but it's worth mentioning that
removing the "anchoring" function does not remove the "nesting order"
constraint.

Task-number: QTBUG-31340
Change-Id: I786d40cef40d14582a0dd4a9407863001bec4c98
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
use the new "stash" instead of the (anything but) "regular" cache

as this new cache category comes without side effects, we can
unconditionally create a cache whereever we are. this allows us to be
performant without explicit user action.

Task-number: QTBUG-31340
Change-Id: I6b88b20b61e8351aa8cbf94ad3eec65adac6e1d6
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>