forked from auracaster/pyalsaaudio
ci: auto-detect package manager to use
This commit is contained in:
22
ci/setup_cibuildwheel.sh
Executable file
22
ci/setup_cibuildwheel.sh
Executable file
@@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
|
||||
# NOTE: ensure to use the correct package manager depending on the manylinux
|
||||
# image used.
|
||||
|
||||
if which yum; then
|
||||
yum install -y alsa-lib-devel
|
||||
exit
|
||||
fi
|
||||
|
||||
if which apk; then
|
||||
apk add alsa-lib-dev
|
||||
exit
|
||||
fi
|
||||
|
||||
if which apt-get; then
|
||||
apt-get install -y libasound2-dev
|
||||
exit
|
||||
fi
|
||||
|
||||
echo "Cannot install ALSA headers! No package manager detected"
|
||||
exit 1
|
||||
@@ -56,15 +56,10 @@ ext-modules = [
|
||||
]
|
||||
|
||||
|
||||
[tool.cibuildwheel.linux]
|
||||
# Use uv and build
|
||||
[tool.cibuildwheel]
|
||||
platform = "linux"
|
||||
build-frontend = "build[uv]"
|
||||
|
||||
# NOTE: ensure to use the correct package manager depending on the manylinux
|
||||
# image used. For AlmaLinux based images, use `yum`, for Debian based images
|
||||
# use `apt`. `cibuildwheel` v3.1.4 defaults to manylinux_2_28, which is
|
||||
# based on AlmaLinux 8.
|
||||
before-all = "yum install -y alsa-lib-devel"
|
||||
before-all = "ci/setup_cibuildwheel.sh"
|
||||
|
||||
|
||||
[dependency-groups]
|
||||
|
||||
Reference in New Issue
Block a user