Skip to content

Commit

Permalink
ci: before-script openssl install
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdoret committed Sep 20, 2024
1 parent bd2dad5 commit eb9b518
Showing 1 changed file with 49 additions and 35 deletions.
84 changes: 49 additions & 35 deletions .github/workflows/maturin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,41 +19,53 @@ permissions:
contents: read

jobs:
# linux:
# runs-on: ${{ matrix.platform.runner }}
# strategy:
# matrix:
# platform:
# - runner: ubuntu-latest
# target: x86_64
# - runner: ubuntu-latest
# target: x86
# - runner: ubuntu-latest
# target: aarch64
# - runner: ubuntu-latest
# target: armv7
# - runner: ubuntu-latest
# target: s390x
# - runner: ubuntu-latest
# target: ppc64le
# steps:
# - uses: actions/checkout@v4
# - uses: actions/setup-python@v5
# with:
# python-version: 3.x
# - name: Build wheels
# uses: PyO3/maturin-action@v1
# with:
# target: ${{ matrix.platform.target }}
# args: --release --out dist --manifest-path pyfuzon/Cargo.toml
# sccache: 'true'
# docker-options: -e "OPENSSL_DIR=/usr/lib64/openssl"
# manylinux: auto
# - name: Upload wheels
# uses: actions/upload-artifact@v4
# with:
# name: wheels-linux-${{ matrix.platform.target }}
# path: dist
linux:
runs-on: ${{ matrix.platform.runner }}
strategy:
matrix:
platform:
- runner: ubuntu-latest
target: x86_64
- runner: ubuntu-latest
target: x86
- runner: ubuntu-latest
target: aarch64
- runner: ubuntu-latest
target: armv7
- runner: ubuntu-latest
target: s390x
- runner: ubuntu-latest
target: ppc64le
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
manylinux: auto
#sccache: 'true'
before-script-linux: |
# If we're running on rhel centos, install needed packages.
if command -v yum &> /dev/null; then
yum update -y && yum install -y perl-core openssl openssl-devel pkgconfig libatomic
# If we're running on i686 we need to symlink libatomic
# in order to build openssl with -latomic flag.
if [[ ! -d "/usr/lib64" ]]; then
ln -s /usr/lib/libatomic.so.1 /usr/lib/libatomic.so
fi
else
# If we're running on debian-based system.
apt update -y && apt-get install -y libssl-dev openssl pkg-config
fi args: --release --out dist --manifest-path pyfuzon/Cargo.toml
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-linux-${{ matrix.platform.target }}
path: dist

musllinux:
runs-on: ${{ matrix.platform.runner }}
Expand All @@ -73,6 +85,8 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Instal OpenSSL
run: sudo apt-get update && sudo apt-get install libssl-dev openssl
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
Expand Down

0 comments on commit eb9b518

Please sign in to comment.