diff --git a/Makefile b/Makefile index 9030b158..6f0db24f 100644 --- a/Makefile +++ b/Makefile @@ -144,7 +144,7 @@ ifdef ARCH_WIN cd dist && zip -5 -r Rack-$(VERSION)-$(ARCH).zip Rack # Make NSIS installer # pacman -S mingw-w64-x86_64-nsis - makensis installer.nsi + makensis -DVERSION=$(VERSION) installer.nsi mv installer.exe dist/Rack-$(VERSION)-$(ARCH).exe endif diff --git a/installer.nsi b/installer.nsi index e03eaf86..b6179079 100644 --- a/installer.nsi +++ b/installer.nsi @@ -1,6 +1,6 @@ !include "MUI2.nsh" -Name "VCV Rack" +Name "VCV Rack ${VERSION}" OutFile "installer.exe" SetCompressor /solid "lzma" CRCCheck On @@ -55,12 +55,15 @@ Section "VCV Rack" VCV_RACK_SECTION ; Write uninstaller info WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "DisplayName" "VCV Rack" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "DisplayIcon" '"$INSTDIR\Rack.exe"' + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "DisplayVersion" "${VERSION}" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "UninstallString" '"$INSTDIR\Uninstall.exe"' WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "QuietUninstallString" '"$INSTDIR\Uninstall.exe" /S' WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "InstallLocation" '"$INSTDIR"' WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "Publisher" "VCV" SectionGetSize ${VCV_RACK_SECTION} $0 WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "EstimatedSize" $0 + WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "NoModify" 1 + WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\VCV Rack" "NoRepair" 1 ; Create uninstaller WriteUninstaller "$INSTDIR\Uninstall.exe"