; * +------------------------------------+; * | Inspire Internet Relay Chat Daemon |; * +------------------------------------+; *; * InspIRCd: (C) 2002-2007 InspIRCd Development Team; * See: http://www.inspircd.org/wiki/index.php/Credits; *; * This program is free but copyrighted software; see; * the file COPYING for details.; *; * ---------------------------------------------------;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; SET THE BUILD TO BE PACKAGED HERE ;;;;!defineBUILD"release";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; HM NIS Edit Wizard helper defines!definePRODUCT_NAME"InspIRCd"!definePRODUCT_VERSION"1.1"!definePRODUCT_PUBLISHER"InspIRCd Development Team"!definePRODUCT_WEB_SITE"http://www.inspircd.org/"!definePRODUCT_DIR_REGKEY"Software\Microsoft\Windows\CurrentVersion\App Paths\inspircd.exe"!definePRODUCT_UNINST_KEY"Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"!definePRODUCT_UNINST_ROOT_KEY"HKLM"!defineDOT_MAJOR"2"!defineDOT_MINOR"0"SetCompressorbzip2; MUI 1.67 compatible ------!include"MUI.nsh"; MUI Settings!defineMUI_ABORTWARNING!defineMUI_ICON"inspircd.ico"!defineMUI_UNICON"inspircd.ico"; Welcome page!insertmacroMUI_PAGE_WELCOME; License page!defineMUI_LICENSEPAGE_CHECKBOX!insertmacroMUI_PAGE_LICENSE"..\docs\COPYING"; directory pagePagedirectory; Components page!insertmacroMUI_PAGE_COMPONENTS; Instfiles page!insertmacroMUI_PAGE_INSTFILES; Finish page!defineMUI_FINISHPAGE_RUN"$INSTDIR\InspGUI.exe"!insertmacroMUI_PAGE_FINISH; Uninstaller pages!insertmacroMUI_UNPAGE_INSTFILES; Language files!insertmacroMUI_LANGUAGE"English"; Reserve files!insertmacroMUI_RESERVEFILE_INSTALLOPTIONS; MUI end ------Name"${PRODUCT_NAME} ${PRODUCT_VERSION}"OutFile"Setup.exe"InstallDir"$PROGRAMFILES\InspIRCd"InstallDirRegKeyHKLM"${PRODUCT_DIR_REGKEY}"""ShowInstDetailsshowShowUnInstDetailsshowFunctionIsDotNetInstalledStrCpy$0"0"StrCpy$1"SOFTWARE\Microsoft\.NETFramework";registry entry to look in.StrCpy$20StartEnum:;Enumerate the versions installed.EnumRegKey$3HKLM"$1\policy"$2;If we don't find any versions installed, it's not here.StrCmp$3""noDotNetnotEmpty;We found something.notEmpty:;Find out if the RegKey starts with 'v'. ;If it doesn't, goto the next key.StrCpy$4$310StrCmp$4"v"+1goNextStrCpy$4$311;It starts with 'v'. Now check to see how the installed major version;relates to our required major version.;If it's equal check the minor version, if it's greater, ;we found a good RegKey.IntCmp$4${DOT_MAJOR}+1goNextyesDotNetReg;Check the minor version. If it's equal or greater to our requested ;version then we're good.StrCpy$4$313IntCmp$4${DOT_MINOR}yesDotNetReggoNextyesDotNetReggoNext:;Go to the next RegKey.IntOp$2$2+1gotoStartEnumyesDotNetReg:;Now that we've found a good RegKey, let's make sure it's actually;installed by getting the install path and checking to see if the ;mscorlib.dll exists.EnumRegValue$2HKLM"$1\policy\$3"0;$2 should equal whatever comes after the major and minor versions ;(ie, v1.1.4322)StrCmp$2""noDotNetReadRegStr$4HKLM$1"InstallRoot";Hopefully the install root isn't empty.StrCmp$4""noDotNet;build the actuall directory path to mscorlib.dll.StrCpy$4"$4$3.$2\mscorlib.dll"IfFileExists$4yesDotNetnoDotNetnoDotNet:MessageBoxMB_OK"You do not have have v${DOT_MAJOR}.${DOT_MINOR} or greater of the .NET framework installed. This is required for the InspIRCd Monitor, however you can still launch the IRCd manually."yesDotNet:;Everything checks out. Go on w