Skip to content

Commit 1742dec

Browse files
authored
Merge pull request #5375 from lowkeyrossi/CI_for_WoA
Add CI support for building and validating OpenBLAS on WoA
2 parents 08df0f0 + cb2c726 commit 1742dec

File tree

1 file changed

+82
-0
lines changed

1 file changed

+82
-0
lines changed

.github/workflows/windows_arm64.yml

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
name: Windows ARM64 CI
2+
3+
on:
4+
push:
5+
branches:
6+
- develop
7+
- release-**
8+
pull_request:
9+
branches:
10+
- develop
11+
- release-**
12+
13+
concurrency:
14+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
15+
cancel-in-progress: true
16+
17+
permissions:
18+
contents: read # to fetch code (actions/checkout)
19+
20+
jobs:
21+
build:
22+
if: "github.repository == 'OpenMathLib/OpenBLAS'"
23+
runs-on: windows-11-arm
24+
steps:
25+
- name: Checkout repository
26+
uses: actions/checkout@v3
27+
28+
- name: Install LLVM for Win-ARM64
29+
shell: pwsh
30+
run: |
31+
Invoke-WebRequest https://github.com/llvm/llvm-project/releases/download/llvmorg-20.1.6/LLVM-20.1.6-woa64.exe -UseBasicParsing -OutFile LLVM-woa64.exe
32+
Start-Process -FilePath ".\LLVM-woa64.exe" -ArgumentList "/S" -Wait
33+
echo "C:\Program Files\LLVM\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
34+
35+
- name: Install CMake and Ninja for Win-ARM64
36+
shell: pwsh
37+
run: |
38+
Invoke-WebRequest https://github.com/Kitware/CMake/releases/download/v3.29.4/cmake-3.29.4-windows-arm64.msi -OutFile cmake-arm64.msi
39+
Start-Process msiexec.exe -ArgumentList "/i cmake-arm64.msi /quiet /norestart" -Wait
40+
echo "C:\Program Files\CMake\bin" >> $env:GITHUB_PATH
41+
42+
Invoke-WebRequest https://github.com/ninja-build/ninja/releases/download/v1.13.1/ninja-winarm64.zip -OutFile ninja-winarm64.zip
43+
Expand-Archive ninja-winarm64.zip -DestinationPath ninja
44+
Copy-Item ninja\ninja.exe -Destination "C:\Windows\System32"
45+
46+
- name: Configure OpenBLAS
47+
shell: cmd
48+
run: |
49+
CALL "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsarm64.bat"
50+
mkdir build
51+
cd build
52+
cmake .. -G Ninja ^
53+
-DCMAKE_BUILD_TYPE=Release ^
54+
-DTARGET=ARMV8 ^
55+
-DBINARY=64 ^
56+
-DCMAKE_C_COMPILER=clang-cl ^
57+
-DCMAKE_Fortran_COMPILER=flang-new ^
58+
-DBUILD_SHARED_LIBS=ON ^
59+
-DCMAKE_SYSTEM_PROCESSOR=arm64 ^
60+
-DCMAKE_SYSTEM_NAME=Windows ^
61+
-DCMAKE_INSTALL_PREFIX=C:/opt
62+
63+
- name: Build OpenBLAS
64+
shell: cmd
65+
run: |
66+
cd build
67+
ninja -j16
68+
69+
- name: Install OpenBLAS
70+
shell: cmd
71+
run: |
72+
cd build
73+
cmake --install .
74+
75+
- name: Run ctests
76+
shell: pwsh
77+
run: |
78+
$env:PATH = "C:\opt\bin;$env:PATH"
79+
cd build
80+
ctest
81+
82+

0 commit comments

Comments
 (0)