According to
http://blogs.msdn.com/b/astebner/archive/2010/10/20/10078468.aspx and bug 7507 the Visual C++ 2010 redistributable installer might want to reboot the system. Tell it not to do that and request a reboot at the end of the installation process if needed. svn path=/trunk/; revision=43864
This commit is contained in:
parent
40e08c936d
commit
6b04299ae4
|
@ -92,7 +92,9 @@ NSIS_FLAGS=\
|
||||||
/DMAKEDIR=$(MAKEDIR) \
|
/DMAKEDIR=$(MAKEDIR) \
|
||||||
/DSTAGING_DIR=$(STAGING_DIR) \
|
/DSTAGING_DIR=$(STAGING_DIR) \
|
||||||
/DWIRESHARK_TARGET_PLATFORM=$(WIRESHARK_TARGET_PLATFORM) \
|
/DWIRESHARK_TARGET_PLATFORM=$(WIRESHARK_TARGET_PLATFORM) \
|
||||||
|
/DTARGET_MACHINE=$(TARGET_MACHINE) \
|
||||||
/DMSVC_VARIANT=$(MSVC_VARIANT) \
|
/DMSVC_VARIANT=$(MSVC_VARIANT) \
|
||||||
|
/DMSC_VER_REQUIRED=$(MSC_VER_REQUIRED) \
|
||||||
/DWIRESHARK_LIB_DIR=$(WIRESHARK_LIB_DIR) \
|
/DWIRESHARK_LIB_DIR=$(WIRESHARK_LIB_DIR) \
|
||||||
!IFDEF MSVCR_DLL
|
!IFDEF MSVCR_DLL
|
||||||
/DMSVCR_DLL="$(MSVCR_DLL)" \
|
/DMSVCR_DLL="$(MSVCR_DLL)" \
|
||||||
|
|
|
@ -275,6 +275,8 @@ FunctionEnd
|
||||||
Var WINPCAP_UNINSTALL ;declare variable for holding the value of a registry key
|
Var WINPCAP_UNINSTALL ;declare variable for holding the value of a registry key
|
||||||
;Var WIRESHARK_UNINSTALL ;declare variable for holding the value of a registry key
|
;Var WIRESHARK_UNINSTALL ;declare variable for holding the value of a registry key
|
||||||
|
|
||||||
|
Var VCREDIST_FLAGS ; silent vs passive, norestart
|
||||||
|
|
||||||
Section "-Required"
|
Section "-Required"
|
||||||
;-------------------------------------------
|
;-------------------------------------------
|
||||||
|
|
||||||
|
@ -354,16 +356,26 @@ File "..\..\ipmap.html"
|
||||||
!ifdef VCREDIST_EXE
|
!ifdef VCREDIST_EXE
|
||||||
; vcredist_x86.exe (MSVC V8) - copy and execute the redistributable installer
|
; vcredist_x86.exe (MSVC V8) - copy and execute the redistributable installer
|
||||||
File "${VCREDIST_EXE}"
|
File "${VCREDIST_EXE}"
|
||||||
!if ${WIRESHARK_TARGET_PLATFORM} == "win32"
|
|
||||||
; If the user already has the redistributable installed they will see a
|
; If the user already has the redistributable installed they will see a
|
||||||
; Big Ugly Dialog by default, asking if they want to uninstall or repair.
|
; Big Ugly Dialog by default, asking if they want to uninstall or repair.
|
||||||
; Ideally we should add a checkbox for this somewhere. In the meantime,
|
; Ideally we should add a checkbox for this somewhere. In the meantime,
|
||||||
; just do a silent install.
|
; just do a "passive+norestart" install for MSVC 2010 and later and a
|
||||||
ExecWait '"$INSTDIR\vcredist_x86.exe" /q' $0
|
; "silent" install otherwise.
|
||||||
!else
|
|
||||||
ExecWait '"$INSTDIR\vcredist_x64.exe" /q' $0
|
; http://blogs.msdn.com/b/astebner/archive/2010/10/20/10078468.aspx
|
||||||
!endif ; WIRESHARK_TARGET_PLATFORM
|
!searchparse /noerrors ${MSVC_VER_REQUIRED} "1400" VCREDIST_OLD_FLAGS "1500" VCREDIST_OLD_FLAGS
|
||||||
DetailPrint "vcredist_x86 returned $0"
|
!ifdef VCREDIST_OLD_FLAGS
|
||||||
|
StrCpy $VCREDIST_FLAGS "/q"
|
||||||
|
!else ; VCREDIST_OLD_FLAGS
|
||||||
|
StrCpy $VCREDIST_FLAGS "/q /norestart"
|
||||||
|
!endif ; VCREDIST_OLD_FLAGS
|
||||||
|
|
||||||
|
ExecWait '"$INSTDIR\vcredist_${TARGET_MACHINE}.exe" $VCREDIST_FLAGS' $0
|
||||||
|
DetailPrint "vcredist_${TARGET_MACHINE} returned $0"
|
||||||
|
IntCmp $0 3010 redistReboot redistNoReboot
|
||||||
|
redistReboot:
|
||||||
|
SetRebootFlag true
|
||||||
|
redistNoReboot:
|
||||||
!else
|
!else
|
||||||
!ifdef MSVCR_DLL
|
!ifdef MSVCR_DLL
|
||||||
; msvcr*.dll (MSVC V7 or V7.1) - simply copy the dll file
|
; msvcr*.dll (MSVC V7 or V7.1) - simply copy the dll file
|
||||||
|
|
Loading…
Reference in New Issue