diff options
author | Thiago Macieira <thiago@macieira.org> | 2013-11-27 17:54:30 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2013-11-27 17:55:24 -0800 |
commit | 1080e5ca351a54275744100aa95a2f83217c1e9e (patch) | |
tree | 64b531b688220596d0cc976b1cf11e07efb8f2a8 /subsurface-install.pri | |
parent | 4b4e59a7e8a051c39d64fa3410f19ad0f94c2535 (diff) | |
download | subsurface-1080e5ca351a54275744100aa95a2f83217c1e9e.tar.gz |
Fix plugin deployment on Windows
And increase our list of plugins to be deployed to include the GIF and
SVG image plugins, the SVG icon engine and the CJK text codecs.
The install rules now iterate over the plugin list and deploy the
plugins in the right path in the staging area. The plugins must also
be scanned for dependencies (Fedora's qjpeg4.dll depends on
libjpeg-62.dll, which neds to be copied to the staging area).
Finally, fix qt.conf needed to be fixed.
Signed-off-by: Thiago Macieira <thiago@macieira.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface-install.pri')
-rw-r--r-- | subsurface-install.pri | 36 |
1 files changed, 29 insertions, 7 deletions
diff --git a/subsurface-install.pri b/subsurface-install.pri index 4b06e176d..89d1958a8 100644 --- a/subsurface-install.pri +++ b/subsurface-install.pri @@ -55,10 +55,37 @@ mac { qt_conf.commands = echo \'[Paths]\' > $@ qt_conf.commands += $${nltab}echo \'Prefix=.\' >> $@ - qt_conf.commands += $${nltab}echo \'Plugins=.\' >> $@ qt_conf.target = $$PWD/packaging/windows/qt.conf install.depends += qt_conf + # Plugin code + defineTest(deployPlugin) { + plugin = $$1 + plugintype = $$dirname(1) + CONFIG(debug, debug|release): plugin = $${plugin}d4.dll + else: plugin = $${plugin}4.dll + + abs_plugin = $$[QT_INSTALL_PLUGINS]/$$plugin + ABS_DEPLOYMENT_PLUGIN += $$abs_plugin + export(ABS_DEPLOYMENT_PLUGIN) + + safe_name = $$replace(1, /, _) + INSTALLS += $$safe_name + + # Work around qmake bug in Qt4 that it can't handle $${xx}.yy properly + eval(safe_name_files = $${safe_name}.files) + eval(safe_name_path = $${safe_name}.path) + $$safe_name_files = $$abs_plugin + $$safe_name_path = $$WINDOWSSTAGING/plugins/$$plugintype + export($$safe_name_files) + export($$safe_name_path) + export(INSTALLS) + } + # Convert plugin names to the relative DLL path + for(plugin, $$list($$DEPLOYMENT_PLUGIN)) { + deployPlugin($$plugin) + } + !win32-msvc* { #!equals($$QMAKE_HOST.os, "Windows"): dlls.commands += OBJDUMP=`$$QMAKE_CC -dumpmachine`-objdump dlls.commands += PATH=\$\$PATH:`$$QMAKE_CC -print-search-dirs | sed -nE \'/^libraries: =/{s///;s,/lib/?(:|\$\$),/bin\\1,g;p;q;}\'` @@ -68,12 +95,7 @@ mac { CONFIG(debug, debug|release): dlls.commands += $$OUT_PWD/debug/subsurface$$EXE_SUFFIX else: dlls.commands += $$OUT_PWD/release/$$TARGET$$EXE_SUFFIX - for(plugin, $$list($$DEPLOYMENT_PLUGIN)) { - CONFIG(debug, debug|release): dlls.depends += $$[QT_INSTALL_PLUGINS]/$${plugin}d4.dll - else: dlls.depends += $$[QT_INSTALL_PLUGINS]/$${plugin}4.dll - } - - dlls.commands += $$LIBS + dlls.commands += $$ABS_DEPLOYMENT_PLUGIN $$LIBS dlls.commands += | while read name; do $(INSTALL_FILE) \$\$name $$PWD/$$WINDOWSSTAGING; done dlls.depends += $(DESTDIR_TARGET) |