diff options
author | Patrik Nyblom <[email protected]> | 2012-11-27 16:26:24 +0100 |
---|---|---|
committer | Patrik Nyblom <[email protected]> | 2012-11-27 16:38:16 +0100 |
commit | a175f808c69f2ad944e92d0006c66c258fc10fc7 (patch) | |
tree | 9570f76810c2dde61e25c76ddc302daec5afb3e9 /erts/etc/win32/nsis/erlang20.nsi | |
parent | d5de2e1ffd6403f5d7ec62e6ce8da508e1cb1239 (diff) | |
download | otp-a175f808c69f2ad944e92d0006c66c258fc10fc7.tar.gz otp-a175f808c69f2ad944e92d0006c66c258fc10fc7.tar.bz2 otp-a175f808c69f2ad944e92d0006c66c258fc10fc7.zip |
Teach Win installer to handle redist on w2012/w8
Also made check for DLL version against redistributables
instead of towards installed system, as some builds
required redistributables everytime (installed dll on build
machine had higher version than the redist)...
Diffstat (limited to 'erts/etc/win32/nsis/erlang20.nsi')
-rw-r--r-- | erts/etc/win32/nsis/erlang20.nsi | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/erts/etc/win32/nsis/erlang20.nsi b/erts/etc/win32/nsis/erlang20.nsi index c5ada9e3b3..3333c4a9aa 100644 --- a/erts/etc/win32/nsis/erlang20.nsi +++ b/erts/etc/win32/nsis/erlang20.nsi @@ -35,6 +35,7 @@ !include "MUI.nsh"
!include "WordFunc.nsh"
+ !include "WinVer.nsh"
;--------------------------------
;Configuration
@@ -341,6 +342,9 @@ FunctionEnd Function .onInit
Var /GLOBAL archprefix
Var /GLOBAL sysnativedir
+ Var /GLOBAL winvermajor
+ Var /GLOBAL winverminor
+
SectionGetFlags 0 $MYTEMP
StrCmpS ${WINTYPE} "win64" +1 +4
StrCpy $archprefix "amd64"
@@ -348,9 +352,16 @@ Function .onInit Goto +3
StrCpy $archprefix "x86"
StrCpy $sysnativedir $SYSDIR
- ;MessageBox MB_YESNO "Found $sysnativedir\${REDIST_DLL_NAME}" IDYES FoundLbl
+ ${WinVerGetMajor} $0
+ ${WinVerGetMinor} $1
+ StrCpy $winvermajor $0
+ StrCpy $winverminor $1
IfFileExists $sysnativedir\${REDIST_DLL_NAME} MaybeFoundInSystemLbl
SearchSxSLbl:
+ IntCmp $winvermajor 6 WVCheckMinorLbl WVCheckDoneLbl NotFoundLbl
+ WVCheckMinorLbl:
+ IntCmp $winverminor 1 WVCheckDoneLbl WVCheckDoneLbl NotFoundLbl
+ WVCheckDoneLbl:
FindFirst $0 $1 $WINDIR\WinSxS\$archprefix*
LoopLbl:
StrCmp $1 "" NotFoundLbl
|