diff options
author | Morten Johan Sørvig <morten.sorvig@nokia.com> | 2011-01-06 09:30:18 (GMT) |
---|---|---|
committer | Morten Johan Sørvig <morten.sorvig@nokia.com> | 2011-01-07 07:58:37 (GMT) |
commit | e24d7c9cab4a50fe682478d43ac74e867666d48b (patch) | |
tree | c6f8d0213631db68178d6115a9c7cd7df833e958 /src/plugins/platforms | |
parent | cc8877068dc6ae8f3142ffec0b85f6fbac4a0d81 (diff) | |
download | Qt-e24d7c9cab4a50fe682478d43ac74e867666d48b.zip Qt-e24d7c9cab4a50fe682478d43ac74e867666d48b.tar.gz Qt-e24d7c9cab4a50fe682478d43ac74e867666d48b.tar.bz2 |
Lighthouse: Support external plugins.
Add -platformpluginpath command line option that
spesifies an additional directory to scan for
plugins. Also read QT_QPA_PLATFORM_PLUGIN_PATH.
QlatformIntegrationFacgtory::create() now tries
to load the plugin from the external path first.
Similarly, keys() returns the keys from the
extra path in addition to the "internal" keys
API changes:
QPlatformIntegration::create() and keys() now take
an optional const QString &platformPluginPath.
New file:
externalplugin.pri, contains instructions and a
base setup for building external plugins.
Diffstat (limited to 'src/plugins/platforms')
-rw-r--r-- | src/plugins/platforms/externalplugin.pri | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/plugins/platforms/externalplugin.pri b/src/plugins/platforms/externalplugin.pri new file mode 100644 index 0000000..54da4d9 --- /dev/null +++ b/src/plugins/platforms/externalplugin.pri @@ -0,0 +1,29 @@ +# +# Lighthouse now has preliminarily support for building and +# loading platform plugins from outside the Qt source/build +# tree. +# +# 1) Building external plugins: +# Set QTDIR to the Qt build directory, copy this file to +# the plugin source repository and include it at the top +# of the plugin's pro file. Use QT_SOURCE_TREE if you +# want to pull in source code from Qt: +# +# include($$QT_SOURCE_TREE/src/plugins/platforms/fontdatabases/genericunix/genericunix.pri) +# +# 2) Loading external plugins: +# Specify the path to the directory containing the +# plugin on the command line, in addition to the +# platform name. +# +# ./wiggly -platformPluginPath /path/to/myPlugin -platform gullfaksA +# + +!exists($$(QTDIR)/.qmake.cache) { + error("Please set QTDIR to the Qt build directory") +} + +QT_SOURCE_TREE = $$fromfile($$(QTDIR)/.qmake.cache,QT_SOURCE_TREE) +QT_BUILD_TREE = $$fromfile($$(QTDIR)/.qmake.cache,QT_BUILD_TREE) + +include($$QT_SOURCE_TREE/src/plugins/qpluginbase.pri) |