diff options
| author | Vonsek <45567075+Vonsek@users.noreply.github.com> | 2026-11-22 15:51:40 +0100 |
|---|---|---|
| committer | Vonsek <45567075+Vonsek@users.noreply.github.com> | 2026-11-22 15:51:40 +0100 |
| commit | df91c6624b69ee4e6c6eeca20ed68d331ed0e728 (patch) | |
| tree | 323c88b9df89bf8abaa2b98d10808474ab675dc2 /scripts/build_runtime.ps1 | |
| parent | b40d8039a98f57b26bd05860febbabbe59b97873 (diff) | |
| parent | 6a6704df1592e1dc4a3215ddf1423a78adb52045 (diff) | |
Merge main into test/valu-int-misc (#1492)
Conflicted files: runtime/test/shaders/check.py, scripts/run_gpu_tests.py
AI-assisted.
Diffstat (limited to 'scripts/build_runtime.ps1')
| -rw-r--r-- | scripts/build_runtime.ps1 | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/build_runtime.ps1 b/scripts/build_runtime.ps1 index e71bcfe27..b251a281c 100644 --- a/scripts/build_runtime.ps1 +++ b/scripts/build_runtime.ps1 | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | # Builds runtime\build\gta6rt.exe with MSVC at BelowNormal priority, on half the cores. | 1 | # Builds runtime\build\gta6rt.exe with MSVC at BelowNormal priority, on half the cores. |
| 2 | # Uses VS's CMake + Ninja when the "C++ CMake tools" component is installed, otherwise calls cl.exe directly. | 2 | # Uses VS's CMake + Ninja when the "C++ CMake tools" component is installed, otherwise calls cl.exe directly. |
| 3 | # The GameInput controller shim (SDL3, docs/gameinput.md) is built only on the CMake path: with an installed SDL3, or | 3 | # The GameInput controller shim (SDL3, docs/gameinput.md) is built only on the CMake path: with an installed SDL3, or |
| 4 | # with -FetchSdl3, which lets CMake download the pinned SDL3 release. The cl.exe fallback never builds it. | 4 | # with -FetchSdl3, which lets CMake download the pinned SDL3 release. The cl.exe fallback never builds it. |
| @@ -58,8 +58,10 @@ if defined VULKAN_SDK cl /nologo /std:c++20 /EHsc /O2 /DWIN32_LEAN_AND_MEAN /DNO | |||
| 58 | } | 58 | } |
| 59 | 59 | ||
| 60 | # A .cmd file avoids cmd.exe's quote stripping on paths with spaces. | 60 | # A .cmd file avoids cmd.exe's quote stripping on paths with spaces. |
| 61 | # Switch to UTF-8 (CP 65001) before invoking CMake/Ninja/cl.exe so non-English MSVC /showIncludes prefixes | ||
| 62 | # (e.g. Spanish "Nota: inclusión del archivo:") match Ninja's msvc_deps_prefix instead of being mojibaked in OEM CP. | ||
| 61 | $bat = Join-Path $out "_build.cmd" | 63 | $bat = Join-Path $out "_build.cmd" |
| 62 | "@echo off`r`nset `"PATH=$installer;%PATH%`"`r`ncall `"$vcvars`" >nul || exit /b 1`r`n$body" | Set-Content -Encoding ascii $bat | 64 | "@echo off`r`nchcp 65001 >nul`r`nset `"PATH=$installer;%PATH%`"`r`ncall `"$vcvars`" >nul || exit /b 1`r`n$body" | Set-Content -Encoding ascii $bat |
| 63 | 65 | ||
| 64 | $p = Start-Process cmd.exe -ArgumentList "/c", "`"$bat`"" -NoNewWindow -PassThru | 66 | $p = Start-Process cmd.exe -ArgumentList "/c", "`"$bat`"" -NoNewWindow -PassThru |
| 65 | $null = $p.Handle # keeps the exit code readable after WaitForExit | 67 | $null = $p.Handle # keeps the exit code readable after WaitForExit |