Windows on Arm devices have been becoming more common, and some libraries have already started shipping win_arm64 wheels for it, e.g. numpy, which pyworld already depends on. Would pyworld be able to support it too? Building it via GitHub Actions looks achievable without too much difficulty, thanks to a free windows-11-arm hosted runner.
The Windows wheels here are built on AppVeyor (appveyor.yml), and AppVeyor's list of Windows build worker images only has Windows Server 2012 R2 / 2016 / 2019, all x64. There's no ARM64 Windows image offered at all, so this isn't something that could be added to the current appveyor.yml — a separate piece of CI is needed just for this one platform.
(I haven't actually tried building pyworld this way myself, so what follows below is more of a starting point than a tested solution.)
Option A: just add a Windows ARM64 leg
Leaves appveyor.yml and .travis.yml untouched, adds one new workflow file:
# .github/workflows/build_win_arm64.yml
name: Build wheel (Windows ARM64)
on:
workflow_dispatch:
push:
tags:
- "*"
jobs:
build_wheel_win_arm64:
runs-on: windows-11-arm
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-python@v5
with:
python-version: "3.12"
architecture: "arm64"
- run: pip wheel --wheel-dir=dist --no-deps .
- uses: actions/upload-artifact@v4
with:
name: wheel-win-arm64
path: dist/*.whl
This mirrors what appveyor.yml already does (pip wheel --wheel-dir=.\dist --no-deps .), just on a native ARM64 runner instead of through Miniconda (Miniconda itself has no Windows ARM64 installer, which is another reason this couldn't just be bolted onto the existing AppVeyor config).
Option B: move Windows builds to GitHub Actions entirely
Since windows-11-arm and windows-2022 are both free standard GitHub-hosted runners, it might also be worth considering replacing the AppVeyor leg altogether, covering the same Python versions it does today plus ARM64:
# .github/workflows/build_windows_wheels.yml
name: Build Windows wheels
on:
workflow_dispatch:
push:
tags:
- "*"
jobs:
build_wheel:
strategy:
fail-fast: false
matrix:
include:
- { os: windows-2022, python: "3.6", arch: x86 }
- { os: windows-2022, python: "3.6", arch: x64 }
- { os: windows-2022, python: "3.7", arch: x86 }
- { os: windows-2022, python: "3.7", arch: x64 }
- { os: windows-2022, python: "3.8", arch: x64 }
- { os: windows-2022, python: "3.9", arch: x64 }
- { os: windows-2022, python: "3.10", arch: x64 }
- { os: windows-2022, python: "3.11", arch: x64 }
- { os: windows-11-arm, python: "3.11", arch: arm64 }
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
architecture: ${{ matrix.arch }}
- run: pip wheel --wheel-dir=dist --no-deps .
- uses: actions/upload-artifact@v4
with:
name: wheel-${{ matrix.os }}-${{ matrix.python }}-${{ matrix.arch }}
path: dist/*.whl
(Side note: I ran into this while packaging VOICEVOX, a Python-based speech synthesis engine, for Windows on ARM64, and pyworld was one of the pieces missing a wheel for it.)
Thanks for maintaining this project!
Windows on Arm devices have been becoming more common, and some libraries have already started shipping
win_arm64wheels for it, e.g. numpy, whichpyworldalready depends on. Wouldpyworldbe able to support it too? Building it via GitHub Actions looks achievable without too much difficulty, thanks to a freewindows-11-armhosted runner.The Windows wheels here are built on AppVeyor (
appveyor.yml), and AppVeyor's list of Windows build worker images only has Windows Server 2012 R2 / 2016 / 2019, all x64. There's no ARM64 Windows image offered at all, so this isn't something that could be added to the currentappveyor.yml— a separate piece of CI is needed just for this one platform.(I haven't actually tried building
pyworldthis way myself, so what follows below is more of a starting point than a tested solution.)Option A: just add a Windows ARM64 leg
Leaves
appveyor.ymland.travis.ymluntouched, adds one new workflow file:This mirrors what
appveyor.ymlalready does (pip wheel --wheel-dir=.\dist --no-deps .), just on a native ARM64 runner instead of through Miniconda (Miniconda itself has no Windows ARM64 installer, which is another reason this couldn't just be bolted onto the existing AppVeyor config).Option B: move Windows builds to GitHub Actions entirely
Since
windows-11-armandwindows-2022are both free standard GitHub-hosted runners, it might also be worth considering replacing the AppVeyor leg altogether, covering the same Python versions it does today plus ARM64:(Side note: I ran into this while packaging VOICEVOX, a Python-based speech synthesis engine, for Windows on ARM64, and
pyworldwas one of the pieces missing a wheel for it.)Thanks for maintaining this project!