Sie sind auf Seite 1von 7

Universal C Runtime KB2999226 installer

Current version: 1.0.129077


---------------------------

Captain's log:

Change 129080 by gleadaa@SHFF8C9F02 on 2016/01/08 07:01:53

Updating my UCRT installer to use the later version where Microsoft fix the
bug "_sntscanf_s does not stop parsing after it encounters a \0 char" (!!!)

2c2
< !define VERSION "1.0.1287.47"
---
> !define VERSION "1.0.1290.77"
100,101c100,101
< IntCmp $R4 10240 +1 need_to_install already_installed
< IntCmp $R5 16390 already_installed need_to_install already_installed
---
> IntCmp $R4 10586 +1 need_to_install already_installed
> IntCmp $R5 9 already_installed need_to_install already_installed
117c117
< StrCpy $1 "Windows6.0-KB2999226-$8"
---
> StrCpy $1 "Windows6.0-KB3118401-$8"
121c121
< StrCpy $1 "Windows6.1-KB2999226-$8"
---
> StrCpy $1 "Windows6.1-KB3118401-$8"
125c125
< StrCpy $1 "Windows8-RT-KB2999226-$8"
---
> StrCpy $1 "Windows8-RT-KB3118401-$8"

Change 128747 by gleadaa@SHFF8C9F02 on 2015/11/27 01:55:20

Fixing tragic typo in the KB number making that whole message useless

2c2
< !define VERSION "1.0.1287.23"
---
> !define VERSION "1.0.1287.47"
194c194
< StrCpy $products_installed "$products_installed$\r$\nNothing installed --
Windows 8.1 requires KB2913955 to be installed first"
---
> StrCpy $products_installed "$products_installed$\r$\nNothing installed --
Windows 8.1 requires KB2919355 to be installed first"

Change 128723 by gleadaa@SHFF8C9F02 on 2015/11/26 02:58:13

NW-52474. Changing the behaviour for Windows 8.1 to not attempt to install
the UCRT because on Windows 8.1 there is a dependency on KB2913955, a massive 800MB
security update. We're not going to install that so we can't really do anything
clever for Windows 8.1. We'll just have to let the VC Redist attempt to sort it
out in its own turgidly slow way.
Renamed the output to match the name that it has in the IF.

2c2
< !define VERSION "1.0.1283.72"
---
> !define VERSION "1.0.1287.23"
5c5
< OutFile Installer.exe
---
> OutFile AdUcrtInstaller.exe
134a135
>
136,137c137,142
< StrCpy $1 "Windows8.1-KB2999226-$8"
< goto do_install
---
> ; NW-52474. Since Microsoft have inserted a bogus dependency on KB2913955,
> ; a monster (800MB) update, installation fails (sliently) on windows 8.1 if
> ; that update is missing. Don't want to ship KB2913955 as well. Ultimately,
> ; users on Windows 8.1 will need that update so just let the VC2015 redist and
> ; WUSA.exe try to sort that out. It will look like a hang (see NW-52403)...
> goto nothing_to_do_on_windows_8_1
184a190,195
> goto end_of_section
>
> nothing_to_do_on_windows_8_1:
> IntCmp $num_products_installed 0 0 end_of_section end_of_section
> StrCpy $products_installed "$products_installed$\r$\nNothing installed --
Windows 8.1 requires KB2913955 to be installed first"
> goto end_of_section

Change 128372 by gleadaa@SHFF8C9F02 on 2015/10/30 04:53:21

Set the reboot flag in the hope the IF will notice

2c2
< !define VERSION "1.0.1283.71"
---
> !define VERSION "1.0.1283.72"
188,189c188,192
< IntCmp $2 3010 success ; ERROR_SUCCESS_REBOOT_REQUIRED
< IntCmp $2 0 success ; ERROR_SUCCESS
---
> IntCmp $2 3010 0 check_error_success check_error_success ; 3010 is
ERROR_SUCCESS_REBOOT_REQUIRED
> SetRebootFlag true
> goto success
> check_error_success:
> IntCmp $2 0 success ; 0 is ERROR_SUCCESS
Change 128371 by gleadaa@SHFF8C9F02 on 2015/10/30 03:55:55

Don't abort if we get ERROR_SUCCESS_REBOOT_REQUIRED back from installing the


CAB

2c2
< !define VERSION "1.0.1283.66"
---
> !define VERSION "1.0.1283.71"
188c188,189
< IntCmp $2 0 +2
---
> IntCmp $2 3010 success ; ERROR_SUCCESS_REBOOT_REQUIRED
> IntCmp $2 0 success ; ERROR_SUCCESS
190a192
> success:

Change 128366 by gleadaa@SHFF8C9F02 on 2015/10/30 03:07:27

Wow, Microsoft have made the detection of Windows 10 somewhat tricky...

2c2
< !define VERSION "1.0.1283.37"
---
> !define VERSION "1.0.1283.66"
77a78,79
> ;have to access the 64bit registry...
> SetRegView 64
126a129,135
> ; Microsoft have made this hard because they have stopped incrementing
CurrentVersion value
> ; Therefore I need to look at CurrentMajorVersionNumber as well.
> ClearErrors
> ReadRegDWORD $R6 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion"
CurrentMajorVersionNumber
> IfErrors really_windows_8_1 windows_10
> IntCmp $6 10 windows_10 really_windows_8_1 unknown_or_post_windows_10_version
> really_windows_8_1:

Change 128339 by gleadaa@SHFF8C9F02 on 2015/10/29 08:45:57

Swapped using CABs for MSUs which clears up the legal grey area with
distributing the CABs from the inside of MSUs. Slows things down and adds
complexity however. Adding detail messages. Tried to ensure we get an exit code
of 2 if something didn't work that the IF can use.

2c2
< !define VERSION "1.0.1283.21"
---
> !define VERSION "1.0.1283.37"
86c86
< ; check vs 10.0.10240.16390
---
> DetailPrint "Checking installed versions of $9\api-ms-win-crt-runtime-l1-1-0.dll
against 10.0.10240.16390..."
104a105
> DetailPrint "Chosing MSU for current OS..."
114c115
< StrCpy $1 "Windows6.0-KB2999226-$8.cab"
---
> StrCpy $1 "Windows6.0-KB2999226-$8"
118c119
< StrCpy $1 "Windows6.1-KB2999226-$8.cab"
---
> StrCpy $1 "Windows6.1-KB2999226-$8"
122c123
< StrCpy $1 "Windows8-RT-KB2999226-$8.cab"
---
> StrCpy $1 "Windows8-RT-KB2999226-$8"
126c127
< StrCpy $1 "Windows8.1-KB2999226-$8.cab"
---
> StrCpy $1 "Windows8.1-KB2999226-$8"
139c140,154
< ${GetFileName} $1 $3
---
> DetailPrint "Checking that $EXEDIR\$1.msu is present..."
> IfFileExists $EXEDIR\$1.msu 0 skip_install
>
> DetailPrint "Unpacking the CAB from the MSU..."
> SetOutPath $TEMP\UCRT ; SetOutPath creates the directory as a side effect
> SetOutPath $EXEDIR
> ClearErrors
> DetailPrint 'expand $1.msu -F:$1.cab "$TEMP\UCRT"'
> nsExec::Exec 'expand $1.msu -F:$1.cab "$TEMP\UCRT"'
> Pop $2
> IntCmp $2 0 0 skip_install skip_install
> IfErrors skip_install
>
> DetailPrint "Installing the CAB with DISM.exe..."
> SetOutPath $TEMP\UCRT
141,143c156,157
< IfFileExists $EXEDIR\$1 0 skip_install
< SetOutPath $EXEDIR
< nsExec::Exec '"$9\DISM.exe" /Online /Add-Package /PackagePath:$1 /LogPath:%TEMP%\
$3.log /LogLevel:4 /Quiet /Norestart'
---
> DetailPrint '"$9\DISM.exe" /Online /Add-Package /PackagePath:$1.cab /LogPath:..\
$1.cab.log /LogLevel:4 /Quiet /Norestart'
> nsExec::Exec '"$9\DISM.exe" /Online /Add-Package /PackagePath:$1.cab /LogPath:..\
$1.cab.log /LogLevel:4 /Quiet /Norestart'
146c160,161
< StrCpy $products_installed "$products_installed$\r$\n- $1 (Exit code: $2, Log
File:%TEMP%\$3.log)"
---
> DetailPrint "$1.cab (Exit code: $2, Log File:%TEMP%\$1.cab.log)"
> StrCpy $products_installed "$products_installed$\r$\n- $1.cab (Exit code: $2, Log
File:%TEMP%\$1.cab.log)"
148a164,168
> DetailPrint "Cleaning up..."
> Delete /REBOOTOK $TEMP\UCRT\$1.cab
> SetOutPath $TEMP ; Can't delete $TEMP\CRT if it is the current working dir
> RMDir /REBOOTOK $TEMP\UCRT
>
150c170
< IntCmp $num_products_installed 0 0 +2 +2
---
> IntCmp $num_products_installed 0 0 end_of_section end_of_section
154c174
< IntCmp $num_products_installed 0 0 +2 +2
---
> IntCmp $num_products_installed 0 0 end_of_section end_of_section
155a176,180
>
> ; Check we didn't see an error code from installing the CAB
> end_of_section:
> IntCmp $2 0 +2
> Abort

Change 128321 by gleadaa@SHFF8C9F02 on 2015/10/29 03:10:47

Fixed behaviour for a theoretical Windows 11 and beyond. Fixed bug where we
ended up using overly long commands (280 characters for FormIt) -- now using a
command line that is essentially fixed in length and much less than 260 characters.

2c2
< !define VERSION "1.0.1282.98"
---
> !define VERSION "1.0.1283.21"
111c111
< goto skip_install
---
> goto unknown_or_post_windows_10_version
129a130
> unknown_or_post_windows_10_version:
141c142,143
< nsExec::Exec '"$9\DISM.exe" /Online /Add-Package /PackagePath:$EXEDIR\$1
/LogPath:%TEMP%\$3.log /LogLevel:4 /Quiet /Norestart'
---
> SetOutPath $EXEDIR
> nsExec::Exec '"$9\DISM.exe" /Online /Add-Package /PackagePath:$1 /LogPath:%TEMP%\
$3.log /LogLevel:4 /Quiet /Norestart'

Change 128298 by gleadaa@SHFF8C9F02 on 2015/10/28 04:25:38

Fixed behaviour for Windows 10


2c2
< !define VERSION "1.0.1282.97"
---
> !define VERSION "1.0.1282.98"
132c132
< goto skip_install
---
> goto already_installed
Change 128297 by gleadaa@SHFF8C9F02 on 2015/10/28 03:06:21

Fixed a couple of bugs. Not checking in the correct 32/64 bit system dir for
existing installation versions, and aborting if things are already installed when
really that is a successful completion.

2c2
< !define VERSION "1.0.1282.64"
---
> !define VERSION "1.0.1282.97"
88c88
< GetDllVersion $SYSDIR\api-ms-win-crt-runtime-l1-1-0.dll $R0 $R1
---
> GetDllVersion $9\api-ms-win-crt-runtime-l1-1-0.dll $R0 $R1
95,99c95,99
< ; IntOp jumps are = < >
< IntCmp $R2 10 +1 need_to_install skip_install
< IntCmp $R3 0 +1 need_to_install skip_install
< IntCmp $R4 10240 +1 need_to_install skip_install
< IntCmp $R5 16390 skip_install need_to_install skip_install
---
> ; IntOp jumps are = < >
> IntCmp $R2 10 +1 need_to_install already_installed
> IntCmp $R3 0 +1 need_to_install already_installed
> IntCmp $R4 10240 +1 need_to_install already_installed
> IntCmp $R5 16390 already_installed need_to_install already_installed
150a151,154
> already_installed:
> IntCmp $num_products_installed 0 0 +2 +2
> StrCpy $products_installed "$products_installed$\r$\nNothing installed -- C
Runtimes already present"
>

Change 128264 by gleadaa@SHFF8C9F02 on 2015/10/26 14:39:35

Try to find the CABs in the same directory as the installer.exe file -- when
launched by setup.exe the current directory is setup.exe's temp dir.

2c2
< !define VERSION "1.0.1282.57"
---
> !define VERSION "1.0.1282.64"
140,142c140,141
< IfFileExists $1 0 skip_install
< ;ExecWait "$9\DISM.exe /Online /Add-Package /PackagePath:$1 /LogPath:%TEMP%\
$3.log /LogLevel:4 /Quiet /Norestart" $2
< nsExec::Exec '"$9\DISM.exe" /Online /Add-Package /PackagePath:$1 /LogPath:%TEMP%\
$3.log /LogLevel:4 /Quiet /Norestart'
---
> IfFileExists $EXEDIR\$1 0 skip_install
> nsExec::Exec '"$9\DISM.exe" /Online /Add-Package /PackagePath:$EXEDIR\$1
/LogPath:%TEMP%\$3.log /LogLevel:4 /Quiet /Norestart'
Change 128257 by gleadaa@SHFF8C9F02 on 2015/10/26 06:25:18

Added NSIS script to install the Universal C Runtime with DISM.exe, a version
of WUSA.exe without the slowness and bureaurocracy of Windows Update. This means
the UCRT update goes on smoothly wihtout hanging if your windows updates are
hopelessly out of date.

Das könnte Ihnen auch gefallen