[692] | 1 | ; Script generated by the HM NIS Edit Script Wizard. |
---|
| 2 | |
---|
| 3 | ; HM NIS Edit Wizard helper defines |
---|
| 4 | !define PRODUCT_NAME "STLport Prebuilt For OGRE" |
---|
| 5 | !define PRODUCT_VERSION "4.6.2" |
---|
| 6 | !define PRODUCT_PUBLISHER "The OGRE Team" |
---|
| 7 | !define PRODUCT_WEB_SITE "http://www.ogre3d.org" |
---|
| 8 | !define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}" |
---|
| 9 | !define PRODUCT_UNINST_ROOT_KEY "HKLM" |
---|
| 10 | |
---|
| 11 | SetCompressor lzma |
---|
| 12 | |
---|
| 13 | ; MUI 1.67 compatible ------ |
---|
| 14 | !include "MUI.nsh" |
---|
| 15 | |
---|
| 16 | ; MUI Settings |
---|
| 17 | !define MUI_ABORTWARNING |
---|
| 18 | !define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico" |
---|
| 19 | !define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico" |
---|
| 20 | |
---|
| 21 | ; Welcome page |
---|
| 22 | !insertmacro MUI_PAGE_WELCOME |
---|
| 23 | ; License page |
---|
| 24 | !insertmacro MUI_PAGE_LICENSE "README" |
---|
| 25 | ; Directory page |
---|
| 26 | !insertmacro MUI_PAGE_DIRECTORY |
---|
| 27 | ; Instfiles page |
---|
| 28 | !insertmacro MUI_PAGE_INSTFILES |
---|
| 29 | ; Finish page |
---|
| 30 | !insertmacro MUI_PAGE_FINISH |
---|
| 31 | |
---|
| 32 | ; Uninstaller pages |
---|
| 33 | !insertmacro MUI_UNPAGE_INSTFILES |
---|
| 34 | |
---|
| 35 | ; Language files |
---|
| 36 | !insertmacro MUI_LANGUAGE "English" |
---|
| 37 | |
---|
| 38 | ; Reserve files |
---|
| 39 | !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS |
---|
| 40 | |
---|
| 41 | ; MUI end ------ |
---|
| 42 | |
---|
| 43 | Name "${PRODUCT_NAME} ${PRODUCT_VERSION}" |
---|
| 44 | OutFile "OGRESTLport-4.6.2.exe" |
---|
| 45 | InstallDir "c:\STLport-4.6.2" |
---|
| 46 | ShowInstDetails show |
---|
| 47 | ShowUnInstDetails show |
---|
| 48 | |
---|
| 49 | Section -Main |
---|
| 50 | SetOutPath "$INSTDIR\stlport" |
---|
| 51 | SetOverwrite try |
---|
| 52 | File /r ".\stlport\*.*" |
---|
| 53 | |
---|
| 54 | SetOutPath "$SYSDIR" |
---|
| 55 | SetOverwrite try |
---|
| 56 | File ".\lib\stlport_vc646.dll" |
---|
| 57 | File ".\lib\stlport_vc6_stldebug46.dll" |
---|
| 58 | File ".\lib\stlport_vc746.dll" |
---|
| 59 | File ".\lib\stlport_vc7_stldebug46.dll" |
---|
| 60 | |
---|
| 61 | SetOutPath "$INSTDIR\lib" |
---|
| 62 | SetOverwrite try |
---|
| 63 | File ".\lib\stlport_vc6.lib" |
---|
| 64 | File ".\lib\stlport_vc6_stldebug.lib" |
---|
| 65 | File ".\lib\stlport_vc7.lib" |
---|
| 66 | File ".\lib\stlport_vc7_stldebug.lib" |
---|
| 67 | |
---|
| 68 | |
---|
| 69 | SectionEnd |
---|
| 70 | |
---|
| 71 | Section -AdditionalIcons |
---|
| 72 | SetOutPath $INSTDIR |
---|
| 73 | CreateDirectory "$SMPROGRAMS\STLport Prebuilt For OGRE" |
---|
| 74 | CreateShortCut "$SMPROGRAMS\STLport Prebuilt For OGRE\Uninstall.lnk" "$INSTDIR\uninst.exe" |
---|
| 75 | SectionEnd |
---|
| 76 | |
---|
| 77 | Section -Post |
---|
| 78 | WriteUninstaller "$INSTDIR\uninst.exe" |
---|
| 79 | WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)" |
---|
| 80 | WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$INSTDIR\uninst.exe" |
---|
| 81 | WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayVersion" "${PRODUCT_VERSION}" |
---|
| 82 | WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}" |
---|
| 83 | WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}" |
---|
| 84 | SectionEnd |
---|
| 85 | |
---|
| 86 | |
---|
| 87 | Function un.onUninstSuccess |
---|
| 88 | HideWindow |
---|
| 89 | MessageBox MB_ICONINFORMATION|MB_OK "$(^Name) was successfully removed from your computer." |
---|
| 90 | FunctionEnd |
---|
| 91 | |
---|
| 92 | Function un.onInit |
---|
| 93 | MessageBox MB_ICONQUESTION|MB_YESNO|MB_DEFBUTTON2 "Are you sure you want to completely remove $(^Name) and all of its components?" IDYES +2 |
---|
| 94 | Abort |
---|
| 95 | FunctionEnd |
---|
| 96 | |
---|
| 97 | Section Uninstall |
---|
| 98 | Delete "$INSTDIR\uninst.exe" |
---|
| 99 | |
---|
| 100 | Delete "$SMPROGRAMS\STLport Prebuilt For OGRE\Uninstall.lnk" |
---|
| 101 | |
---|
| 102 | RMDir "$SMPROGRAMS\STLport Prebuilt For OGRE" |
---|
| 103 | |
---|
| 104 | RMDir /r "$INSTDIR" |
---|
| 105 | |
---|
| 106 | DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" |
---|
| 107 | SetAutoClose true |
---|
| 108 | SectionEnd |
---|