Commit ef2377a9 authored by Rafaël Carré's avatar Rafaël Carré

nsis: refuse to run on Windows < XP SP2

parent 9c0864bf
...@@ -49,6 +49,7 @@ RequestExecutionLevel user ...@@ -49,6 +49,7 @@ RequestExecutionLevel user
!addincludedir NSIS !addincludedir NSIS
!addplugindir NSIS !addplugindir NSIS
!include UAC.nsh !include UAC.nsh
!include WinVer.nsh
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; NSIS Modern User Interface configuration ; ; NSIS Modern User Interface configuration ;
...@@ -430,6 +431,14 @@ Function .onInit ...@@ -430,6 +431,14 @@ Function .onInit
@HAVE_WIN64_TRUE@ MessageBox MB_OK|MB_ICONSTOP "This version of VLC only runs on 64bits operating systems.$\nYour operating system is 32bits.$\n$\nPlease get the 32 BITS version." @HAVE_WIN64_TRUE@ MessageBox MB_OK|MB_ICONSTOP "This version of VLC only runs on 64bits operating systems.$\nYour operating system is 32bits.$\n$\nPlease get the 32 BITS version."
@HAVE_WIN64_TRUE@ Quit @HAVE_WIN64_TRUE@ Quit
@HAVE_WIN64_TRUE@ ${Endif} @HAVE_WIN64_TRUE@ ${Endif}
${If} ${AtLeastWinXP}
${If} ${IsWinXP}
${AndIf} ${AtMostServicePack} 1
Goto WinTooOld
${Endif}
${Else}
Goto WinTooOld
${Endif}
@HAVE_WIN64_TRUE@ SetRegView 64 @HAVE_WIN64_TRUE@ SetRegView 64
ReadRegStr $INSTDIR HKLM "${PRODUCT_DIR_REGKEY}" "InstallDir" ReadRegStr $INSTDIR HKLM "${PRODUCT_DIR_REGKEY}" "InstallDir"
...@@ -451,6 +460,10 @@ UAC_ElevationAborted: ...@@ -451,6 +460,10 @@ UAC_ElevationAborted:
MessageBox mb_iconstop "This installer requires admin access, aborting!" MessageBox mb_iconstop "This installer requires admin access, aborting!"
Abort Abort
WinTooOld:
MessageBox MB_OK|MB_ICONSTOP "This version of VLC only runs on Windows XP SP2 and newer."
Quit
UAC_Success: UAC_Success:
StrCmp 1 $3 +4 StrCmp 1 $3 +4
StrCmp 3 $1 0 UAC_ElevationAborted StrCmp 3 $1 0 UAC_ElevationAborted
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment