-
Notifications
You must be signed in to change notification settings - Fork 25
98 lines (81 loc) · 3.29 KB
/
windows-arm.yml
File metadata and controls
98 lines (81 loc) · 3.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: Windows-on-ARM
on:
push:
branches: [ main ]
pull_request:
branches:
- main
- maintenance/**
env:
OPENBLAS_ROOT: "c:\\opt"
# Preserve working directory for calls into bash
# Without this, invoking bash will cd to the home directory
CHERE_INVOKING: "yes"
BASH_PATH: "C:\\Program Files\\Git\\bin\\bash.exe"
PLAT: arm64
jobs:
build:
runs-on: windows-11-arm
timeout-minutes: 90
strategy:
matrix:
INTERFACE64: ['1', '0']
env:
INTERFACE64: ${{ matrix.INTERFACE64 }}
steps:
- uses: actions/checkout@v4.1.1
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.12
architecture: arm64
- name: Download and install LLVM installer
run: |
Invoke-WebRequest https://github.com/llvm/llvm-project/releases/download/llvmorg-20.1.8/LLVM-20.1.8-woa64.exe -UseBasicParsing -OutFile LLVM-woa64.exe
Start-Process -FilePath ".\LLVM-woa64.exe" -ArgumentList "/S" -Wait
echo "C:\Program Files\LLVM\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
- name: Install CMake and Ninja for Win-ARM64
shell: pwsh
run: |
Invoke-WebRequest https://github.com/Kitware/CMake/releases/download/v3.29.4/cmake-3.29.4-windows-arm64.msi -OutFile cmake-arm64.msi
Start-Process msiexec.exe -ArgumentList "/i cmake-arm64.msi /quiet /norestart" -Wait
echo "C:\Program Files\CMake\bin" >> $env:GITHUB_PATH
Invoke-WebRequest https://github.com/ninja-build/ninja/releases/download/v1.13.1/ninja-winarm64.zip -OutFile ninja-winarm64.zip
Expand-Archive ninja-winarm64.zip -DestinationPath ninja
Copy-Item ninja\ninja.exe -Destination "C:\Windows\System32"
- name: Set env variables
run: |
if ( ${{ matrix.INTERFACE64 }} -eq "1" ) {
echo "INTERFACE_BITS=64" >> $env:GITHUB_ENV
} else {
echo "INTERFACE_BITS=32" >> $env:GITHUB_ENV
}
- name: Build
run: |
git submodule update --init --recursive
.\tools\build_steps_win_arm64.bat 64 ${env:INTERFACE_BITS}
- name: Test ${{ matrix.INTERFACE_BITS }}-bit interface wheel
run: |
python -m pip install --no-index --find-links dist scipy_openblas${env:INTERFACE_BITS}
python -m scipy_openblas${env:INTERFACE_BITS}
python -c "import scipy_openblas${env:INTERFACE_BITS}; print(scipy_openblas${env:INTERFACE_BITS}.get_pkg_config())"
- uses: actions/upload-artifact@v4.3.0
with:
name: wheels-${{ env.PLAT }}-${{ env.INTERFACE64 }}
path: dist/scipy_openblas*.whl
- name: Install Anaconda client
run: |
# Rust installation needed for rpds-py.
Invoke-WebRequest https://static.rust-lang.org/rustup/dist/aarch64-pc-windows-msvc/rustup-init.exe -UseBasicParsing -Outfile rustup-init.exe
.\rustup-init.exe -y
$env:PATH="$env:PATH;$env:USERPROFILE\.cargo\bin"
pip install anaconda-client
- name: Upload
# see https://github.com/marketplace/actions/setup-miniconda for why
# `-el {0}` is required.
shell: bash -el {0}
env:
ANACONDA_SCIENTIFIC_PYTHON_UPLOAD: ${{ secrets.ANACONDA_SCIENTIFIC_PYTHON_UPLOAD }}
run: |
source tools/upload_to_anaconda_staging.sh
upload_wheels