Skip to content

Commit 01f2d9d

Browse files
committed
First pass Win CI building
Signed-off-by: Rob Suderman <rob.suderman@gmail.com>
1 parent 0aa85dc commit 01f2d9d

1 file changed

Lines changed: 78 additions & 0 deletions

File tree

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
# Copyright 2026 Advanced Micro Devices, Inc.
2+
#
3+
# Licensed under the Apache License v2.0 with LLVM Exceptions.
4+
# See https://llvm.org/LICENSE.txt for license information.
5+
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+
7+
name: CI - Windows x64 MSVC
8+
9+
on:
10+
workflow_dispatch:
11+
pull_request:
12+
push:
13+
branches:
14+
- main
15+
16+
jobs:
17+
windows_x64_msvc:
18+
runs-on: azure-windows-scale
19+
env:
20+
BASE_BUILD_DIR_POWERSHELL: B:\tmpbuild
21+
steps:
22+
- name: "Checking out repository"
23+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
24+
with:
25+
submodules: true
26+
# TODO(#18813): Remove this. Environment setup needs to happen on runners, not in workflows.
27+
- name: "Create build dir"
28+
run: |
29+
$buildDir = "$env:BASE_BUILD_DIR_POWERSHELL\"
30+
echo "BUILD_DIR_POWERSHELL=$buildDir" >> $env:GITHUB_ENV
31+
mkdir "$buildDir"
32+
Write-Host "Generated Build Directory: $buildDir"
33+
$bashBuildDir = $buildDir -replace '\\', '/' -replace '^B:', '/b'
34+
echo "BUILD_DIR_BASH=$bashBuildDir" >> $env:GITHUB_ENV
35+
Write-Host "Converted Build Directory For Bash: $bashBuildDir"
36+
- name: "Setting up Python"
37+
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
38+
with:
39+
python-version: "3.11"
40+
- name: "Installing Python packages"
41+
run: |
42+
python3 -m venv .venv
43+
.venv/Scripts/activate.bat
44+
45+
python3 -m pip install --upgrade pip
46+
- name: "Configuring MSVC"
47+
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
48+
- name: "Installing Fusilli requirements"
49+
run: |
50+
choco install cmake
51+
choco install ninja
52+
choco install lit
53+
- name: "Building Fusilli"
54+
run: |
55+
cmake -S . -B ${{ env.BUILD_DIR_BASH }} -G Ninja -DCMAKE_BUILD_TYPE=Release
56+
cmake --build ${{ env.BUILD_DIR_BASH }} --config Release --target all
57+
- name: "Clean up build dir"
58+
if: always()
59+
run: if (Test-Path -Path "$Env:BUILD_DIR_POWERSHELL") {Remove-Item -Path "$Env:BUILD_DIR_POWERSHELL" -Recurse -Force}
60+
61+
# Depends on all other jobs to provide an aggregate job status.
62+
ci_fusilli_summary:
63+
if: always()
64+
runs-on: ubuntu-24.04
65+
needs:
66+
- windows_x64_msvc
67+
steps:
68+
- name: Getting failed jobs
69+
run: |
70+
echo '${{ toJson(needs) }}'
71+
FAILED_JOBS="$(echo '${{ toJson(needs) }}' \
72+
| jq --raw-output \
73+
'map_values(select(.result!="success" and .result!="skipped")) | keys | join(",")' \
74+
)"
75+
if [[ "${FAILED_JOBS}" != "" ]]; then
76+
echo "The following jobs failed: ${FAILED_JOBS}"
77+
exit 1
78+
fi

0 commit comments

Comments
 (0)