summaryrefslogtreecommitdiffstats
path: root/examples/designer/customwidgetplugin/customwidgetplugin.pro
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@digia.com>2012-10-25 17:34:15 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-05 14:03:02 +0100
commit6e524bb082d8098ba6be5e47aaf9c9df8b575359 (patch)
tree3d0dc17ea3c40af582311dfb525cecc2c111ee75 /examples/designer/customwidgetplugin/customwidgetplugin.pro
parentd10d182d0cba2635cfbf85eecb3af4fedcd29c42 (diff)
adjust to qt_plugin.prf changes
DESTDIR and INSTALLS+=target are set up automatically now, but PLUGIN_TYPE needs to be defined. TEMPLATE, some CONFIG flags and TARGET munging are unnecessary, too. this contains a nasty hack for examples, as we don't want users to use the internal prf files. Change-Id: I9af75f3040fd45d87ec9daea27e00588796ebe81 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Diffstat (limited to 'examples/designer/customwidgetplugin/customwidgetplugin.pro')
-rw-r--r--examples/designer/customwidgetplugin/customwidgetplugin.pro26
1 files changed, 19 insertions, 7 deletions
diff --git a/examples/designer/customwidgetplugin/customwidgetplugin.pro b/examples/designer/customwidgetplugin/customwidgetplugin.pro
index 1ff6aa7e1..db6538664 100644
--- a/examples/designer/customwidgetplugin/customwidgetplugin.pro
+++ b/examples/designer/customwidgetplugin/customwidgetplugin.pro
@@ -1,12 +1,25 @@
-#! [0] #! [1]
-CONFIG += plugin
+#! [0]
QT += widgets designer
#! [0]
-TARGET = $$qtLibraryTarget($$TARGET)
+
+QTDIR_build {
+# This is only for the Qt build. Do not use externally. We mean it.
+PLUGIN_TYPE = designer
+load(qt_plugin)
+} else {
+# Public example:
+
#! [2]
+CONFIG += plugin
TEMPLATE = lib
-#! [1] #! [2]
-DESTDIR = $$QT.designer.plugins/designer
+#! [2]
+
+TARGET = $$qtLibraryTarget($$TARGET)
+
+target.path = $$[QT_INSTALL_PLUGINS]/designer
+INSTALLS += target
+
+}
#! [3]
HEADERS = analogclock.h \
@@ -17,7 +30,6 @@ OTHER_FILES += analogclock.json
#! [3]
# install
-target.path = $$[QT_INSTALL_PLUGINS]/designer
sources.files = $$SOURCES $$HEADERS *.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/qttools/designer/customwidgetplugin
-INSTALLS += target sources
+INSTALLS += sources