Skip to content

Commit c0a6686

Browse files
committed
ci: define explicitly rust toolchain on Windows
Change-Id: I45e804d523ca4f6c4d75267f7a3ecfa6f45becb6
1 parent f006c2c commit c0a6686

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

packages/cmk-agent-ctl/scripts/cargo_build_core.cmd

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,15 @@ if "%worker_cur_dir%" == "" powershell Write-Host "worker_cur_dir is not defined
2121
if "%worker_root_dir%" == "" powershell Write-Host "worker_root_dir is not defined" -Foreground Red && exit /b 79
2222
if "%worker_exe_name%" == "" powershell Write-Host "worker_exe_name is not defined" -Foreground Red && exit /b 79
2323
if "%worker_target%" == "" powershell Write-Host "worker_target is not defined" -Foreground Red && exit /b 79
24+
if "%worker_toolchain%" == "" powershell Write-Host "worker_target is not defined" -Foreground Red && exit /b 79
2425

2526

2627
:: Jenkins calls windows scripts in a quite strange manner, better to check is cargo available
2728
where cargo > nul
2829
if not %errorlevel% == 0 powershell Write-Host "Cargo not found, please install it and/or add to PATH" -Foreground Red && exit /b 7
2930
rustup update
30-
rustup target add %worker_target%
31+
echo rustup target add %worker_target% --toolchain %worker_toolchain%
32+
rustup target add %worker_target% --toolchain %worker_toolchain%
3133

3234
:: 64-bit
3335
::set target=x86_64-pc-windows-mscvc
@@ -41,6 +43,7 @@ echo worker_arg_build=%worker_arg_build%
4143
echo worker_arg_clippy=%worker_arg_clippy%
4244
echo worker_arg_test=%worker_arg_test%
4345
echo worker_target=%worker_target%
46+
echo worker_toolchain=%worker_toolchain%
4447

4548
:: Disable assert()s in C/C++ parts (e.g. wepoll-ffi), they map to _assert()/_wassert(),
4649
:: which is not provided by libucrt. The latter is needed for static linking.

packages/cmk-agent-ctl/setup_config.cmd

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ set worker_exe_name=cmk-agent-ctl.exe
99
set worker_root_dir=%cd%\..\..
1010
:: Rust
1111
set worker_target=i686-pc-windows-msvc
12+
set worker_toolchain=1.79
1213
:: Elevation
1314
set worker_need_elevation=1
1415

0 commit comments

Comments
 (0)