Skip to content

Commit 7bfd207

Browse files
authored
Merge pull request #478 from Harishmcw/arm64
Add Windows ARM64 support in CI
2 parents 232d0ef + 3b70975 commit 7bfd207

2 files changed

Lines changed: 22 additions & 7 deletions

File tree

.github/workflows/python-package.yml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
strategy:
99
fail-fast: false
1010
matrix:
11-
os: [ubuntu-latest, windows-latest, macos-latest]
11+
os: [ubuntu-latest, windows-latest, windows-11-arm, macos-latest]
1212
python-version:
1313
- "3.10"
1414
- "3.11"
@@ -17,7 +17,7 @@ jobs:
1717
- "3.14"
1818
- "pypy-3.10"
1919
- "pypy-3.11"
20-
architecture: ["x86", "x64"]
20+
architecture: ["x86", "x64", "arm64"]
2121
exclude:
2222
- os: macos-latest
2323
python-version: "3.10"
@@ -27,6 +27,22 @@ jobs:
2727
architecture: "x86"
2828
- os: windows-latest
2929
python-version: "pypy-3.10"
30+
- os: windows-11-arm
31+
python-version: "3.10"
32+
- os: windows-latest
33+
architecture: "arm64"
34+
- os: ubuntu-latest
35+
architecture: "arm64"
36+
- os: macos-latest
37+
architecture: "arm64"
38+
- os: windows-11-arm
39+
architecture: "x86"
40+
- os: windows-11-arm
41+
architecture: "x64"
42+
- os: windows-11-arm
43+
python-version: "pypy-3.10"
44+
- os: windows-11-arm
45+
python-version: "pypy-3.11"
3046

3147
steps:
3248
- uses: actions/checkout@v2

soundfile.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -170,11 +170,10 @@
170170
elif _sys.platform == 'win32':
171171
from platform import architecture as _architecture
172172
from platform import machine as _machine
173-
# this check can not be completed correctly: for x64 binaries running on
174-
# arm64 Windows report the same values as arm64 binaries. For now, neither
175-
# numpy nor cffi are available for arm64, so we can safely assume we're
176-
# in x86 land:
177-
if _architecture()[0] == '64bit':
173+
_win_machine = _machine().lower()
174+
if _win_machine in ('arm64', 'aarch64'):
175+
_packaged_libname = 'libsndfile_arm64.dll'
176+
elif _architecture()[0] == '64bit':
178177
_packaged_libname = 'libsndfile_x64.dll'
179178
elif _architecture()[0] == '32bit':
180179
_packaged_libname = 'libsndfile_x86.dll'

0 commit comments

Comments
 (0)