From 9ee7ec2068523bebbb6a084299a2ed1ba6c87541 Mon Sep 17 00:00:00 2001 From: George King <98261225+GeorgeK1ng@users.noreply.github.com> Date: Sat, 4 Jan 2025 10:11:40 +0100 Subject: [PATCH] Add files via upload --- CI/wininstaller/build_installer.cmd | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/CI/wininstaller/build_installer.cmd b/CI/wininstaller/build_installer.cmd index ecf798f50..d4d66a118 100644 --- a/CI/wininstaller/build_installer.cmd +++ b/CI/wininstaller/build_installer.cmd @@ -12,7 +12,7 @@ set "VCMIFolder=VCMI" REM Define Inno Setup version set InnoSetupVer=6 -REM Uncomment this line and set custom UCRT source path, otherwise it will be detected automatically from installed Windows 10 SDK +REM Uncomment this line and set custom UCRT source path, otherwise latest installed Windows 10 SDK will be used REM set "UCRTFilesPath=%ProgFiles%\Windows Kits\10\Redist\10.0.22621.0\ucrt\DLLs" REM Normally, there is no need to modify anything below this line. @@ -44,11 +44,11 @@ REM Dynamically locate the UCRT path if not defined if not defined UCRTFilesPath ( set "UCRTBasePath=!ProgFiles!\Windows Kits\10\Redist" set "UCRTFilesPath=" - for /d %%d in ("!UCRTBasePath!\*") do ( - if exist "%%d\ucrt\DLLs" ( - set "UCRTFilesPath=%%d\ucrt\DLLs" - ) - ) + for /f "delims=" %%d in ('dir /b /ad /on "!UCRTBasePath!"') do ( + if exist "!UCRTBasePath!\%%d\ucrt\DLLs" ( + set "UCRTFilesPath=!UCRTBasePath!\%%d\ucrt\DLLs" + ) + ) ) REM Verify Inno Setup is installed