diff --git a/.yamato/build_classlibs_win.yml b/.yamato/build_classlibs_win.yml new file mode 100644 index 00000000000000..e9981dbe0e6481 --- /dev/null +++ b/.yamato/build_classlibs_win.yml @@ -0,0 +1,20 @@ +name: Build Classlibs Windows + +agent: + type: Unity::VM + image: platform-foundation/windows-vs2019-il2cpp-bokken:stable + flavor: b1.xlarge + +commands: + - .yamato/scripts/build_classlibs.bat + +triggers: + pull_requests: + - targets: + only: + - "unity-main" + +artifacts: + win64: + paths: + - incomingbuilds\** \ No newline at end of file diff --git a/.yamato/build_windows_x64.yml b/.yamato/build_windows_x64.yml index 2f230462b05917..e7679a0efab9d5 100644 --- a/.yamato/build_windows_x64.yml +++ b/.yamato/build_windows_x64.yml @@ -8,6 +8,12 @@ agent: commands: - .yamato/scripts/build_win.bat +triggers: + pull_requests: + - targets: + only: + - "unity-main" + artifacts: win64: paths: diff --git a/.yamato/scripts/build_classlibs.bat b/.yamato/scripts/build_classlibs.bat new file mode 100644 index 00000000000000..3f6e0dfc0dc569 --- /dev/null +++ b/.yamato/scripts/build_classlibs.bat @@ -0,0 +1,22 @@ +@echo OFF + +if not exist "incomingbuilds" mkdir "incomingbuilds" + +for %%x IN ("windows", "OSX", "Linux") do ( + CALL :EchoAndExecute build.cmd libs -os %%x -c release + if NOT %errorlevel% == 0 ( + echo "build failed" + EXIT /B %errorlevel% + ) + if not exist "incomingbuilds/coreclrjit-%%x" mkdir "incomingbuilds/coreclrjit-%%x" + + CALL :EchoAndExecute xcopy /s /e /h /y "artifacts/bin/runtime/net7.0-%%x-Release-x64" "incomingbuilds/coreclrjit-%%x" + CALL :EchoAndExecute taskkill /IM "dotnet.exe" /F + CALL :EchoAndExecute build.cmd -clean +) +EXIT /B %ERRORLEVEL% + +:EchoAndExecute +ECHO %* +CALL %* +GOTO :EOF diff --git a/.yamato/scripts/build_win.bat b/.yamato/scripts/build_win.bat index 7cb15792509d51..79ebdc83e32d3f 100644 --- a/.yamato/scripts/build_win.bat +++ b/.yamato/scripts/build_win.bat @@ -1,5 +1,8 @@ @echo off -build.cmd -subset clr -a x64 -c release +setlocal + + +powershell -ExecutionPolicy ByPass -NoProfile -Command "& 'eng\build.ps1'" -subset clr -a x64 -c release if NOT %errorlevel% == 0 ( echo "build failed"