Skip to content

Commit

Permalink
🐧 CI: Upgrade manylinux_2_28
Browse files Browse the repository at this point in the history
  • Loading branch information
Isotr0py committed Feb 4, 2024
1 parent 97d4984 commit f56950e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 19 deletions.
24 changes: 11 additions & 13 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,36 +26,33 @@ jobs:
timeout-minutes: 60
strategy:
matrix:
target: [x86_64, x86, aarch64, armv7, s390x, ppc64le]
target: [x86_64, aarch64, armv7, s390x, ppc64le]
include:
- target: x86_64
docker_image: quay.io/pypa/manylinux2014_x86_64:latest
- target: x86
docker_image: quay.io/pypa/manylinux2014_i686:latest
docker_image: quay.io/pypa/manylinux_2_28_x86_64:latest
- target: aarch64
distro: ubuntu_latest
docker_image: ghcr.io/rust-cross/manylinux_2_28-cross:aarch64
- target: armv7
distro: ubuntu_latest
docker_image: ghcr.io/rust-cross/manylinux_2_28-cross:armv7
- target: s390x
distro: ubuntu_latest
docker_image: ghcr.io/rust-cross/manylinux_2_28-cross:s390x
- target: ppc64le
distro: ubuntu_latest
docker_image: ghcr.io/rust-cross/manylinux_2_28-cross:ppc64le

steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.10'

- name: Build libjxl (x86/x64)
- name: Build libjxl (x86_64)
if: ${{ contains(matrix.target, 'x86')}}
uses: kohlerdominik/docker-run-action@v1
with:
image: ${{ matrix.docker_image }}
volumes: ${{ github.workspace }}:/workspace
workdir: /workspace
run: |
yum install -y cmake clang gcc-c++
git clone --recurse-submodules --depth 1 -b v0.9.1 https://github.com/libjxl/libjxl.git
cd libjxl
cmake -B build -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=OFF -DBUILD_TESTING=OFF \
Expand All @@ -70,7 +67,7 @@ jobs:
uses: uraimo/[email protected]
with:
arch: ${{ matrix.target }}
distro: ${{ matrix.distro }}
distro: ubuntu_latest

# Not required, but speeds up builds
githubToken: ${{ github.token }}
Expand All @@ -89,7 +86,7 @@ jobs:
# publicly in your project's package repository, so it is vital that
# no secrets are present in the container state or logs.
install: |
case "${{ matrix.distro }}" in
case "ubuntu_latest" in
ubuntu*|jessie|stretch|buster|bullseye)
apt-get update -q -y
apt-get install -q -y git build-essential
Expand All @@ -110,7 +107,7 @@ jobs:
apt-get install -y cmake ninja-build
git clone --recurse-submodules --depth 1 -b v0.9.1 https://github.com/libjxl/libjxl.git
cd libjxl
cmake -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF \
cmake -B build -G Ninja -DBUILD_SHARED_LIBS=OFF -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF \
-DJPEGXL_ENABLE_TOOLS=OFF -DJPEGXL_ENABLE_DOXYGEN=OFF -DJPEGXL_ENABLE_MANPAGES=OFF \
-DJPEGXL_ENABLE_BENCHMARKS=OFF -DJPEGXL_ENABLE_EXAMPLES=OFF -DJPEGXL_ENABLE_JNI=OFF \
-DJPEGXL_ENABLE_SJPEG=OFF -DJPEGXL_ENABLE_OPENEXR=OFF
Expand All @@ -121,6 +118,7 @@ jobs:
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
container: ${{ matrix.docker_image }}
args: --release --out dist --find-interpreter
manylinux: auto
docker-options: |
Expand Down
9 changes: 3 additions & 6 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,9 @@ fn static_link() {
println!("cargo:rustc-link-search=native={}", path);
}

// println!("cargo:rustc-link-lib=static:+whole-archive=brotlidec-static");
// println!("cargo:rustc-link-lib=static=brotlienc-static");
// println!("cargo:rustc-link-lib=static=brotlicommon-static");
println!("cargo:rustc-link-lib:+whole-archive=brotlidec");
println!("cargo:rustc-link-lib=brotlienc");
println!("cargo:rustc-link-lib=brotlicommon");
println!("cargo:rustc-link-lib=static:+whole-archive=brotlidec-static");
println!("cargo:rustc-link-lib=static=brotlienc-static");
println!("cargo:rustc-link-lib=static=brotlicommon-static");
if let Ok(path) = env::var("DEP_BROTLI_LIB") {
println!("cargo:rustc-link-search=native={}", path);
}
Expand Down

0 comments on commit f56950e

Please sign in to comment.