Only handle QTPLUGIN when linking against static Qt
authorMiikka Heikkinen <miikka.heikkinen@digia.com>
Fri, 7 Dec 2012 07:54:43 +0000 (09:54 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Fri, 7 Dec 2012 18:55:19 +0000 (19:55 +0100)
Usage of QTPLUGIN implies static Qt, so only handle it when that is
true so user projects do not need to scope it if they support linking
against both static and shared Qt.

Change-Id: I011b4672bac122d7d64d8f2fc0e41ca7e5251dfc
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
mkspecs/features/qt.prf

index 586dae3..443914e 100644 (file)
@@ -35,7 +35,8 @@ plugin { #Qt plugins
    }
 }
 
-QT_PLUGIN_VERIFY = QTPLUGIN DEPLOYMENT_PLUGIN
+QT_PLUGIN_VERIFY = DEPLOYMENT_PLUGIN
+contains(QT_CONFIG, static): QT_PLUGIN_VERIFY += QTPLUGIN
 for(QT_CURRENT_VERIFY, $$list($$QT_PLUGIN_VERIFY)) {
     for(QTPLUG, $$list($$lower($$unique($$QT_CURRENT_VERIFY)))) {
        # Check if the plugin is known to Qt. We can use this to determine