Avoid race condition in QQmlEngine on shutdown.

The QQmlTypeLoader was deleted (and its thread shut down) when
the QQmlEnginePrivate was destroyed. However, the QQmlTypeLoader
runs a thread which would happiliy make calls on the engine and
its managed data. Fix this by stopping the QQmlTypeLoader's
thread right away in QQmlEngine.

Task-number: QTBUG-39905
Change-Id: Ida8e95d083f79237c74b036fd3521133a9fa4ac7
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
Enable QSG_RUNTIME_DESCRIPTION by default for debug builds.

This can be quite helpful when doing scene graph debugging
with QSG_RENDERER_DEBUG=dump or using qDebug() on nodes
in general.

Change-Id: I6328d3f2a0fad87161c386bed14408598c986dcb
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Verbose fatal instead of crash when the scene graph state is invalid.

Change-Id: I9a55bcbf9e94084c0cadac561e4707d47f5f8744
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>

Conflicts:
	src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp
Merge pull request #34 from sletta/mer-stable

[qtdeclarative] cherry-pick relevant changes from upstream