Name "MV3D Server" OutFile "..\mv3d-windows-server.exe" InstallDir $PROGRAMFILES32\MV3D\Server InstallDirRegKey HKLM "Software\MV3D\Server" "Install_Dir" RequestExecutionLevel admin Page license Page components Page directory Page instfiles UninstPage uninstConfirm UninstPage instfiles LicenseText "MV3D is released under the MIT License:" LicenseData "..\LICENSE" Section "MV3D Server (required)" SectionIn RO ; Set output path to the installation directory. SetOutPath $INSTDIR ; Put file there File /r "..\dist-server\*.*" ; Write the installation path into the registry WriteRegStr HKLM SOFTWARE\MV3D\Server "Install_Dir" "$INSTDIR" ; Write the uninstall keys for Windows WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\MV3D_Server" "DisplayName" "MV3D Server" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\MV3D_Server" "UninstallString" '"$INSTDIR\uninstall.exe"' WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\MV3D_Server" "NoModify" 1 WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\MV3D_Server" "NoRepair" 1 WriteUninstaller "uninstall.exe" SectionEnd Section "Start Menu Shortcuts" CreateDirectory "$SMPROGRAMS\MV3D\Server" CreateShortCut "$SMPROGRAMS\MV3D\Server\Uninstall.lnk" "$INSTDIR\uninstall.exe" "" "$INSTDIR\uninstall.exe" 0 CreateShortCut "$SMPROGRAMS\MV3D\Server\Overseer.lnk" "$INSTDIR\overseer.exe" "" "$INSTDIR\overseer.exe" 0 SectionEnd ;-------------------------------- ; Uninstaller Section "Uninstall" ; Remove registry keys DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\MV3D_Server" DeleteRegKey HKLM SOFTWARE\MV3D\Server ; Remove files and uninstaller Delete $INSTDIR\*.* ; Remove shortcuts, if any Delete "$SMPROGRAMS\MV3D\Server\*.*" ; Remove directories used RMDir "$SMPROGRAMS\MV3D\Server" RMDir "$INSTDIR" SectionEnd