Skip to content

Instantly share code, notes, and snippets.

@GENiEBEN
Last active January 4, 2016 01:38
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save GENiEBEN/8549239 to your computer and use it in GitHub Desktop.
PortableBenchmarks2D
!include "x64.nsh"
; Installer settings
SetCompressor /SOLID lzma
SetDatablockOptimize on
VIProductVersion "1.6.000.0"
VIAddVersionKey "ProductName" "Portable 2D Benchmarks LITE"
VIAddVersionKey "Comments" "This setup will install a collection of 2D Benchmarks"
VIAddVersionKey "CompanyName" "The Hardware Database"
VIAddVersionKey "FileVersion" "1.6"
XPStyle on
; The name of the installer
Name "Portable 2D Benchmarks LITE"
BrandingText "(c) 2013-2014 www.hw-db.com"
; The file to write
OutFile "Portable 2D Benchmarks LITE.exe"
; The default installation directory
InstallDir "$PROGRAMFILES\GENiEBEN\PortableBenchmarks"
; Request application privileges for Windows Vista
RequestExecutionLevel admin
;--------------------------------
; Pages
Page components
Page directory
Page instfiles
UninstPage uninstConfirm
UninstPage instfiles
;--------------------------------
; The stuff to install
Section "Uninstaller"
SectionIn RO
; Set output path to the installation directory.-
SetOutPath $INSTDIR
; Create directories
CreateDirectory "$DESKTOP\PortableBenchmarks"
CreateDirectory "$SMPROGRAMS\PortableBenchmarks"
; Write the uninstall keys for Windows
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "DisplayName" "Portable 2D Benchmarks LITE v1.6"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "DisplayVersion" "1.6"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "UninstallString" "$INSTDIR\Uninstall.exe"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "URLInfoAbout" "http://hw-db.com"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "URLUpdateInfo" "http://hw-db.com"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "Publisher" "hw-db.com"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "HelpLink" "http://hw-db.com"
;WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "NoModify" 1
;WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D" "NoRepair" 1
WriteUninstaller "Uninstall.exe"
SectionEnd
SubSection "Tools"
;http://www.cpuid.com/softwares/cpu-z.html
Section "CPU-Z v1.71.0"
CreateDirectory "$INSTDIR\cpuz"
SetOutPath "$INSTDIR\cpuz"
File "cpuz\cpuz_x32.exe"
CreateShortCut "$DESKTOP\PortableBenchmarks\CPU-Z (32bit).lnk" "$INSTDIR\cpuz\cpuz_x32.exe" "" "$INSTDIR\cpuz\cpuz_x32.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\CPU-Z (32bit).lnk" "$INSTDIR\cpuz\cpuz_x32.exe" "" "$INSTDIR\cpuz\cpuz_x32.exe" 0
${if} ${RunningX64}
File "cpuz\cpuz_x64.exe"
CreateShortCut "$DESKTOP\PortableBenchmarks\CPU-Z (64bit).lnk" "$INSTDIR\cpuz\cpuz_x64.exe" "" "$INSTDIR\cpuz\cpuz_x64.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\CPU-Z (64bit).lnk" "$INSTDIR\cpuz\cpuz_x64.exe" "" "$INSTDIR\cpuz\cpuz_x64.exe" 0
${endif}
SectionEnd
;http://www.techpowerup.com/downloads/SysInfo/GPU-Z/
SubSection "GPU-Z v0.8.0"
Section "Regular"
CreateDirectory "$INSTDIR\gpuz"
SetOutPath "$INSTDIR\gpuz"
File "gpuz\gpuz.exe"
CreateShortCut "$DESKTOP\PortableBenchmarks\GPU-Z.lnk" "$INSTDIR\gpuz\gpuz.exe" "" "$INSTDIR\gpuz\gpuz.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\GPU-Z.lnk" "$INSTDIR\gpuz\gpuz.exe" "" "$INSTDIR\gpuz\gpuz.exe" 0
SectionEnd
Section /o "ASUS ROG"
CreateDirectory "$INSTDIR\gpuz"
SetOutPath "$INSTDIR\gpuz"
File "gpuz\gpuz_rog.exe"
CreateShortCut "$DESKTOP\PortableBenchmarks\GPU-Z ROG.lnk" "$INSTDIR\gpuz\gpuz_rog.exe" "" "$INSTDIR\gpuz\gpuz_rog.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\GPU-Z ROG.lnk" "$INSTDIR\gpuz\gpuz_rog.exe" "" "$INSTDIR\gpuz\gpuz_rog.exe" 0
SectionEnd
SubSectionEnd
SubSectionEnd
SubSection "With HWBOT points"
Section "CINEBENCH R11.529"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\cinebench115"
File /r "cinebench115"
SetOutPath "$INSTDIR\cinebench115"
CreateShortCut "$DESKTOP\PortableBenchmarks\Cinebench R11.5 (32bit).lnk" "$INSTDIR\cinebench115\CINEBENCH Windows 32 Bit.exe" "" "$INSTDIR\cinebench115\CINEBENCH Windows 32 Bit.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\Cinebench R11.5 (32bit).lnk" "$INSTDIR\cinebench115\CINEBENCH Windows 32 Bit.exe" "" "$INSTDIR\cinebench115\CINEBENCH Windows 32 Bit.exe" 0
${if} ${RunningX64}
CreateShortCut "$DESKTOP\PortableBenchmarks\Cinebench R11.5 (64bit).lnk" "$INSTDIR\cinebench115\CINEBENCH Windows 64 Bit.exe" "" "$INSTDIR\cinebench115\CINEBENCH Windows 64 Bit.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\Cinebench R11.5 (64bit).lnk" "$INSTDIR\cinebench115\CINEBENCH Windows 64 Bit.exe" "" "$INSTDIR\cinebench115\CINEBENCH Windows 64 Bit.exe" 0
${endif}
SectionEnd
Section "CINEBENCH R15"
${if} ${RunningX64}
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\cinebench15"
File /r "cinebench15"
SetOutPath "$INSTDIR\cinebench15"
CreateShortCut "$DESKTOP\PortableBenchmarks\Cinebench R15 (64bit).lnk" "$INSTDIR\cinebench15\CINEBENCH Windows 64 Bit.exe" "" "$INSTDIR\cinebench15\CINEBENCH Windows 64 Bit.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\Cinebench R15 (64bit).lnk" "$INSTDIR\cinebench15\CINEBENCH Windows 64 Bit.exe" "" "$INSTDIR\cinebench15\CINEBENCH Windows 64 Bit.exe" 0
${endif}
SectionEnd
SubSection "HWBOT Prime v0.8.3"
Section "Main Files"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\hwbotprime"
SetOutPath "$INSTDIR\hwbotprime"
File "hwbotprime\hwbotprime.exe"
File "hwbotprime\hwbotprime.jar"
SetOutPath "$INSTDIR\hwbotprime"
CreateShortCut "$DESKTOP\PortableBenchmarks\HWBOT Prime.lnk" "$INSTDIR\hwbotprime\hwbotprime.exe" "" "$INSTDIR\hwbotprime\hwbotprime.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\HWBOT Prime.lnk" "$INSTDIR\hwbotprime\hwbotprime.exe" "" "$INSTDIR\hwbotprime\hwbotprime.exe" 0
SectionEnd
;http://www.java.com/en/download/manual.jsp
Section "Java v1.7.0.18"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\hwbotprime_"
SetOutPath "$INSTDIR\hwbotprime_"
File "hwbotprime\jre-x86.exe"
ExecWait "$INSTDIR\hwbotprime_\jre-x86.exe /s"
${if} ${RunningX64}
SetOutPath "$INSTDIR\hwbotprime_"
File "hwbotprime\jre-x64.exe"
ExecWait "$INSTDIR\hwbotprime_\jre-x64.exe /s"
${endif}
RMDir /r "$INSTDIR\hwbotprime_"
SectionEnd
SubSectionEnd
;https://downloadcenter.intel.com/SearchResult.aspx?lang=eng&ProdId=3483
Section /o "Intel XTU v5.1.1.25"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\xtu"
File /r "xtu"
ExecWait "$INSTDIR\xtu\xtu-setup.exe /quiet /norestart"
Rename "$DESKTOP\Intel(R) Extreme Tuning Utility.lnk" "$DESKTOP\PortableBenchmarks\XTU.lnk"
SectionEnd
SubSection "PCMark04 v1.0.0"
Section /o "Windows Media Encoder 9"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\pcmark_"
File /r "pcmark_"
SetOutPath "$INSTDIR\pcmark_"
ExecWait "$INSTDIR\pcmark_\WMEncoder.exe /Q"
RMDir /r "$INSTDIR\pcmark_"
SectionEnd
Section /o "Main Files"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\pcmark04"
CreateDirectory "C:\Program Files\Futuremark\PCMark04"
File /r "pcmark04"
SetOutPath "$INSTDIR\pcmark04"
ExecWait "$INSTDIR\pcmark04\PCMark04.exe"
RMDir /r "$INSTDIR\pcmark04"
Rename "$DESKTOP\PCMark04.lnk" "$DESKTOP\PortableBenchmarks\PCMark04.lnk"
SectionEnd
;https://www.futuremark.com/support/systeminfo
Section /o "FM SystemInfo v4.30"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\fmsi"
File /r "fmsi"
SetOutPath "$INSTDIR\fmsi"
ExecWait "$INSTDIR\fmsi\fmsi.msi /quiet /n /norestart"
RMDir /r "$INSTDIR\fmsi"
SectionEnd
SubSectionEnd
SubSection "PCMark05 v1.2.2.1901"
Section /o "Main Files"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\pcmark05"
CreateDirectory "C:\Program Files\Futuremark\PCMark05"
File /r "pcmark05"
SetOutPath "$INSTDIR\pcmark05"
ExecWait "$INSTDIR\pcmark05\PCMark05.exe"
RMDir /r "$INSTDIR\pcmark05"
Rename "$DESKTOP\PCMark05.lnk" "$DESKTOP\PortableBenchmarks\PCMark05.lnk"
SectionEnd
;https://www.futuremark.com/support/systeminfo
Section /o "FM SystemInfo v4.29"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\fmsi"
File /r "fmsi"
SetOutPath "$INSTDIR\fmsi"
ExecWait "$INSTDIR\fmsi\fmsi.msi /quiet /n /norestart"
RMDir /r "$INSTDIR\fmsi"
SectionEnd
SubSectionEnd
Section "PiFast v4.1 HEXUS"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\pifast"
File /r "pifast"
SetOutPath "$INSTDIR\pifast"
CreateShortCut "$DESKTOP\PortableBenchmarks\PiFast.lnk" "$INSTDIR\pifast\hexus_pifast.exe" "" "$INSTDIR\pifast\hexus_pifast.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\PiFast.lnk" "$INSTDIR\pifast\hexus_pifast.exe" "" "$INSTDIR\pifast\hexus_pifast.exe" 0
SectionEnd
Section "SuperPI v1.5 XS"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\superpi"
File /r "superpi"
SetOutPath "$INSTDIR\superpi"
CreateShortCut "$DESKTOP\PortableBenchmarks\SuperPi.lnk" "$INSTDIR\superpi\super_pi_mod.exe" "" "$INSTDIR\superpi\super_pi_mod.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\SuperPi.lnk" "$INSTDIR\superpi\super_pi_mod.exe" "" "$INSTDIR\superpi\super_pi_mod.exe" 0
SectionEnd
;http://anrieff.net/ucbench/download.php
Section "UCBench 2011 r178"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\ucbench"
File /r "ucbench"
SetOutPath "$INSTDIR\ucbench"
CreateShortCut "$DESKTOP\PortableBenchmarks\UCBench.lnk" "$INSTDIR\ucbench\launcher_admin.exe" "" "$INSTDIR\ucbench\launcher.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\UCBench.lnk" "$INSTDIR\ucbench\launcher_admin.exe" "" "$INSTDIR\ucbench\launcher.exe" 0
SectionEnd
Section "WPrime v1.55 HWBOT"
SetOutPath $INSTDIR
CreateDirectory "$INSTDIR\wprime"
File /r "wprime"
SetOutPath "$INSTDIR\wprime"
CreateShortCut "$DESKTOP\PortableBenchmarks\WPrime.lnk" "$INSTDIR\wprime\wPrime_Admin.exe" "" "$INSTDIR\wprime\wPrime.exe" 0
CreateShortCut "$SMPROGRAMS\PortableBenchmarks\WPrime.lnk" "$INSTDIR\wprime\wPrime_Admin.exe" "" "$INSTDIR\wprime\wPrime.exe" 0
SectionEnd
SubSectionEnd
; Uninstaller
Section "Uninstall"
; Remove registry keys
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PortableBenchmarks2D"
ExecWait "$INSTDIR\passmark\unins000.exe /VERYSILENT"
ExecWait "$INSTDIR\xtu\xtu-setup.exe /uninstall /quiet"
; Remove files and uninstaller
Delete "$INSTDIR\*.*"
; Remove shortcuts, if any
Delete "$DESKTOP\PortableBenchmarks\*.*"
Delete "$SMPROGRAMS\PortableBenchmarks\*.*"
RMDir /r "$DESKTOP\PortableBenchmarks"
RMDir /r "$SMPROGRAMS\PortableBenchmarks"
RMDir /r "$INSTDIR"
SectionEnd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment