aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore1
-rw-r--r--packaging/nsis/Makefile.nmake12
-rwxr-xr-xpackaging/nsis/uninstall.nsi34
-rw-r--r--packaging/nsis/windeployqt-to-nsis.ps140
-rw-r--r--packaging/nsis/wireshark.nsi3
5 files changed, 68 insertions, 22 deletions
diff --git a/.gitignore b/.gitignore
index 5259f23bd8..4e76fd501a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -207,6 +207,7 @@ packaging/macosx/COPYING.txt
packaging/macosx/Info.plist
packaging/macosx/osx-dmg.sh
packaging/macosx/Wireshark_package.pmdoc/index.xml
+packaging/nsis/qt-dll-manifest.nsh
packaging/portableapps/win32/Files/
packaging/portableapps/win32/WiresharkPortable.ini
packaging/portableapps/win32/appinfo.ini
diff --git a/packaging/nsis/Makefile.nmake b/packaging/nsis/Makefile.nmake
index 7d9c19ae2b..95ee895636 100644
--- a/packaging/nsis/Makefile.nmake
+++ b/packaging/nsis/Makefile.nmake
@@ -230,15 +230,13 @@ NSIS_FLAGS=\
/DQT_DIR="..\..\wireshark-qt-release" \
!ENDIF
-wireshark.nsi: qt-dll-manifest.txt
-qt-dll-manifest.txt:
+wireshark.nsi: qt-dll-manifest.nsh
+qt-dll-manifest.nsh: windeployqt-to-nsis.ps1
!IF EXIST("$(QT5_BASE_DIR)\bin\windeployqt.exe")
+ powershell -executionpolicy bypass -File windeployqt-to-nsis.ps1 \
"$(QT5_BASE_DIR)\bin\windeployqt.exe" \
- --release \
- --no-compiler-runtime \
- --list source ..\..\wireshark-qt-release\qtshark.exe \
+ ..\..\wireshark-qt-release\qtshark.exe \
> $@
- sed -i -e 's/^/File "/' -e 's/$$/"/' $@
!ELSE IF EXIST("..\..\wireshark-qt-release\Qt5Core.dll")
type << > $@
File "..\..\wireshark-qt-release\Qt5Core.dll"
@@ -272,7 +270,7 @@ clean:
rm -f $(UNINSTALL_INSTALLER)
rm -f NEWS.txt
rm -f user-guide.chm
- rm -f qt-dll-manifest.txt
+ rm -f qt-dll-manifest.nsh
distclean: clean
rm -f wireshark-$(WIRESHARK_TARGET_PLATFORM)-*.exe
diff --git a/packaging/nsis/uninstall.nsi b/packaging/nsis/uninstall.nsi
index 3b9086f25e..751367570a 100755
--- a/packaging/nsis/uninstall.nsi
+++ b/packaging/nsis/uninstall.nsi
@@ -134,37 +134,43 @@ DeleteRegKey HKCR ${WIRESHARK_ASSOC}
DeleteRegKey HKCR "${WIRESHARK_ASSOC}\Shell\open\command"
DeleteRegKey HKCR "${WIRESHARK_ASSOC}\DefaultIcon"
+Delete "$INSTDIR\*.dll"
+Delete "$INSTDIR\*.exe"
+Delete "$INSTDIR\*.html"
+Delete "$INSTDIR\*.qm"
+Delete "$INSTDIR\accessible\*.*"
+Delete "$INSTDIR\AUTHORS-SHORT"
+Delete "$INSTDIR\COPYING*"
+Delete "$INSTDIR\diameter\*.*"
Delete "$INSTDIR\etc\gtk-2.0\*.*"
Delete "$INSTDIR\etc\gtk-3.0\*.*"
Delete "$INSTDIR\etc\pango\*.*"
+Delete "$INSTDIR\help\*.*"
+Delete "$INSTDIR\iconengines\*.*"
+Delete "$INSTDIR\imageformats\*.*"
+Delete "$INSTDIR\lib\gtk-2.0\2.10.0\engines\*.*"
+Delete "$INSTDIR\lib\gtk-2.0\2.10.0\immodules\*.*"
+Delete "$INSTDIR\lib\gtk-2.0\2.10.0\loaders\*.*"
Delete "$INSTDIR\lib\gtk-2.0\2.2.0\engines\*.*"
-Delete "$INSTDIR\lib\gtk-2.0\2.2.0\loaders\*.*"
Delete "$INSTDIR\lib\gtk-2.0\2.2.0\immodules\*.*"
+Delete "$INSTDIR\lib\gtk-2.0\2.2.0\loaders\*.*"
Delete "$INSTDIR\lib\gtk-2.0\2.4.0\engines\*.*"
-Delete "$INSTDIR\lib\gtk-2.0\2.4.0\loaders\*.*"
Delete "$INSTDIR\lib\gtk-2.0\2.4.0\immodules\*.*"
-Delete "$INSTDIR\lib\gtk-2.0\2.10.0\engines\*.*"
-Delete "$INSTDIR\lib\gtk-2.0\2.10.0\loaders\*.*"
-Delete "$INSTDIR\lib\gtk-2.0\2.10.0\immodules\*.*"
+Delete "$INSTDIR\lib\gtk-2.0\2.4.0\loaders\*.*"
Delete "$INSTDIR\lib\gtk-2.0\modules\*.*"
Delete "$INSTDIR\lib\pango\1.2.0\modules\*.*"
Delete "$INSTDIR\lib\pango\1.4.0\modules\*.*"
Delete "$INSTDIR\lib\pango\1.5.0\modules\*.*"
-Delete "$INSTDIR\share\themes\Default\gtk-2.0\*.*"
+Delete "$INSTDIR\platforms\*.*"
+Delete "$INSTDIR\printsupport\*.*"
Delete "$INSTDIR\share\glib-2.0\schemas\*.*"
-Delete "$INSTDIR\help\*.*"
-Delete "$INSTDIR\diameter\*.*"
-Delete "$INSTDIR\snmp\mibs\*.*"
+Delete "$INSTDIR\share\themes\Default\gtk-2.0\*.*"
Delete "$INSTDIR\snmp\*.*"
+Delete "$INSTDIR\snmp\mibs\*.*"
Delete "$INSTDIR\tpncp\*.*"
Delete "$INSTDIR\ui\*.*"
Delete "$INSTDIR\wimaxasncp\*.*"
-Delete "$INSTDIR\*.exe"
-Delete "$INSTDIR\*.dll"
-Delete "$INSTDIR\*.html"
Delete "$INSTDIR\ws.css"
-Delete "$INSTDIR\COPYING*"
-Delete "$INSTDIR\AUTHORS-SHORT"
; previous versions installed these files
Delete "$INSTDIR\*.manifest"
; previous versions installed this file
diff --git a/packaging/nsis/windeployqt-to-nsis.ps1 b/packaging/nsis/windeployqt-to-nsis.ps1
new file mode 100644
index 0000000000..a47d00e363
--- /dev/null
+++ b/packaging/nsis/windeployqt-to-nsis.ps1
@@ -0,0 +1,40 @@
+# windeployqt-to-nsh
+#
+# Convert the output of windeployqt to an equivalent set of NSIS "File"
+# function calls.
+
+Param(
+ [string[]] $Windeployqt,
+ [string[]] $Executable
+)
+
+$wdqtList = & $Windeployqt `
+ --release `
+ --no-compiler-runtime `
+ --list relative `
+ $Executable
+
+$dllPath = Split-Path -Parent $Executable
+
+$dllList = @()
+$dirList = @()
+
+foreach ($entry in $wdqtList) {
+ $dir = Split-Path -Parent $entry
+ if ($dir) {
+ $dirList += $dir
+ } else {
+ $dllList += $entry
+ }
+}
+
+$dirList = $dirList | Sort-Object | Get-Unique
+
+foreach ($entry in $dllList) {
+ write-output "File `"$dllPath\$entry`""
+}
+
+foreach ($entry in $dirList) {
+ write-output "File /r `"$dllPath\$entry`""
+}
+
diff --git a/packaging/nsis/wireshark.nsi b/packaging/nsis/wireshark.nsi
index fe3665dc87..8f9b5f0ec4 100644
--- a/packaging/nsis/wireshark.nsi
+++ b/packaging/nsis/wireshark.nsi
@@ -880,7 +880,8 @@ Section "${PROGRAM_NAME} 2 Preview" SecWiresharkQt
; by default, QtShark is installed but file is always associate with Wireshark GTK+
SetOutPath $INSTDIR
File "${QT_DIR}\${PROGRAM_NAME_PATH_QT}"
-!include qt-dll-manifest.txt
+!include qt-dll-manifest.nsh
+File "${QT_DIR}\*.qm"
Push $0
;SectionGetFlags ${SecWiresharkQt} $0