mirror of
https://github.com/eclipse-mosquitto/mosquitto.git
synced 2026-09-22 16:15:05 +08:00
Windows: Installer quality of life improvements
This commit is contained in:
@@ -19,6 +19,11 @@ Broker:
|
||||
Clients:
|
||||
- Fix mosquitto_rr not honouring `-R`. Closes #2893.
|
||||
|
||||
Windows:
|
||||
- Installer will start/stop the mosquitto service when installing and
|
||||
uninstalling, to prevent problems with not being able to overwrite or remove
|
||||
mosquitto.exe.
|
||||
|
||||
|
||||
2.0.17 - 2023-08-22
|
||||
===================
|
||||
|
||||
@@ -40,7 +40,12 @@ InstallDir "$PROGRAMFILES\mosquitto"
|
||||
|
||||
Section "Files" SecInstall
|
||||
SectionIn RO
|
||||
|
||||
ExecWait 'sc stop mosquitto'
|
||||
Sleep 1000
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
File "..\logo\mosquitto.ico"
|
||||
File "..\build\src\Release\mosquitto.exe"
|
||||
File "..\build\apps\mosquitto_passwd\Release\mosquitto_passwd.exe"
|
||||
File "..\build\apps\mosquitto_ctrl\Release\mosquitto_ctrl.exe"
|
||||
@@ -75,6 +80,7 @@ Section "Files" SecInstall
|
||||
|
||||
WriteUninstaller "$INSTDIR\Uninstall.exe"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto" "DisplayName" "Eclipse Mosquitto MQTT broker"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto" "DisplayIcon" "$INSTDIR\mosquitto.ico"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto" "UninstallString" "$\"$INSTDIR\Uninstall.exe$\""
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto" "QuietUninstallString" "$\"$INSTDIR\Uninstall.exe$\" /S"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto" "HelpLink" "https://mosquitto.org/"
|
||||
@@ -89,10 +95,15 @@ SectionEnd
|
||||
|
||||
Section "Service" SecService
|
||||
ExecWait '"$INSTDIR\mosquitto.exe" install'
|
||||
ExecWait 'sc start mosquitto'
|
||||
SectionEnd
|
||||
|
||||
Section "Uninstall"
|
||||
ExecWait 'sc stop mosquitto'
|
||||
Sleep 1000
|
||||
ExecWait '"$INSTDIR\mosquitto.exe" uninstall'
|
||||
Sleep 1000
|
||||
|
||||
Delete "$INSTDIR\mosquitto.exe"
|
||||
Delete "$INSTDIR\mosquitto_ctrl.exe"
|
||||
Delete "$INSTDIR\mosquitto_passwd.exe"
|
||||
@@ -114,6 +125,7 @@ Section "Uninstall"
|
||||
Delete "$INSTDIR\libcrypto-1_1.dll"
|
||||
Delete "$INSTDIR\edl-v10"
|
||||
Delete "$INSTDIR\epl-v20"
|
||||
Delete "$INSTDIR\mosquitto.ico"
|
||||
|
||||
Delete "$INSTDIR\devel\mosquitto.h"
|
||||
Delete "$INSTDIR\devel\mosquitto.lib"
|
||||
|
||||
@@ -41,7 +41,12 @@ InstallDir "$PROGRAMFILES64\mosquitto"
|
||||
|
||||
Section "Files" SecInstall
|
||||
SectionIn RO
|
||||
|
||||
ExecWait 'sc stop mosquitto'
|
||||
Sleep 1000
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
File "..\logo\mosquitto.ico"
|
||||
File "..\build64\src\Release\mosquitto.exe"
|
||||
File "..\build64\apps\mosquitto_ctrl\Release\mosquitto_ctrl.exe"
|
||||
File "..\build64\apps\mosquitto_passwd\Release\mosquitto_passwd.exe"
|
||||
@@ -81,6 +86,7 @@ Section "Files" SecInstall
|
||||
|
||||
WriteUninstaller "$INSTDIR\Uninstall.exe"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto64" "DisplayName" "Eclipse Mosquitto MQTT broker (64 bit)"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto64" "DisplayIcon" "$INSTDIR\mosquitto.ico"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto64" "UninstallString" "$\"$INSTDIR\Uninstall.exe$\""
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto64" "QuietUninstallString" "$\"$INSTDIR\Uninstall.exe$\" /S"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Mosquitto64" "HelpLink" "https://mosquitto.org/"
|
||||
@@ -102,10 +108,15 @@ SectionEnd
|
||||
|
||||
Section "Service" SecService
|
||||
ExecWait '"$INSTDIR\mosquitto.exe" install'
|
||||
ExecWait 'sc start mosquitto'
|
||||
SectionEnd
|
||||
|
||||
Section "Uninstall"
|
||||
ExecWait 'sc stop mosquitto'
|
||||
Sleep 1000
|
||||
ExecWait '"$INSTDIR\mosquitto.exe" uninstall'
|
||||
Sleep 1000
|
||||
|
||||
Delete "$INSTDIR\mosquitto.dll"
|
||||
Delete "$INSTDIR\mosquitto.exe"
|
||||
Delete "$INSTDIR\mosquitto_ctrl.exe"
|
||||
@@ -126,6 +137,7 @@ Section "Uninstall"
|
||||
Delete "$INSTDIR\SECURITY.md"
|
||||
Delete "$INSTDIR\edl-v10"
|
||||
Delete "$INSTDIR\epl-v20"
|
||||
Delete "$INSTDIR\mosquitto.ico"
|
||||
|
||||
Delete "$INSTDIR\cjson.dll"
|
||||
Delete "$INSTDIR\libcrypto-3-x64.dll"
|
||||
|
||||
Reference in New Issue
Block a user