Skip to content

Update glib, libpng, zlib #91

Update glib, libpng, zlib

Update glib, libpng, zlib #91

Workflow file for this run

# Temporary workflow to build Linux and macOS binaries directly with Meson
name: Direct
on:
pull_request:
branches: [main]
push:
branches: [main]
permissions:
contents: read
jobs:
linux:
name: Linux
runs-on: ubuntu-latest
container: ghcr.io/openslide/linux-builder:latest
steps:
- name: Check out repo
uses: actions/checkout@v4
- name: Cache sources
uses: actions/cache@v3
with:
key: direct-cache
path: subprojects/packagecache
- name: Build
id: build
run: |
meson setup build --native-file machines/native-linux-x86_64.ini \
-Dopenslide:werror=true -Dopenslide-java:werror=true
meson compile -C build
artifact=$(cd build/artifacts && echo openslide-bin-*-linux-x86_64.tar.xz)
mv "build/artifacts/$artifact" .
echo "artifact=$artifact" >> $GITHUB_OUTPUT
- name: Smoke test
run: |
tar xf "${{ steps.build.outputs.artifact }}"
OPENSLIDE_DEBUG=synthetic \
openslide-bin-*-linux-x86_64/bin/slidetool prop list ''
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ${{ steps.build.outputs.artifact }}
path: ${{ steps.build.outputs.artifact }}
compression-level: 0
macos:
name: macOS
runs-on: macos-latest
steps:
- name: Install dependencies
run: |
# https://github.com/actions/setup-python/issues/577
# https://github.com/q3aiml/ledger/commit/f53b35ae
brew list -1 | grep python@ | while read formula; do
brew unlink $formula
brew link --overwrite $formula
done
brew update
brew install meson
- name: Check out repo
uses: actions/checkout@v4
- name: Cache sources
uses: actions/cache@v3
with:
key: direct-cache
path: subprojects/packagecache
- name: Build
id: build
run: |
export OPENSLIDE_BIN_SUFFIX="$(date +%Y%m%d).local"
version=$(MESON_SOURCE_ROOT=$(pwd) python3 utils/get-version.py)
for arch in x86_64 arm64; do
meson setup $arch --cross-file machines/cross-macos-${arch}.ini \
-Dopenslide:werror=true -Dopenslide-java:werror=true
meson compile -C $arch
done
artifact="openslide-bin-${version}-macos-arm64-x86_64.tar.xz"
PYTHONPATH=. python3 utils/write-universal-bdist.py \
-o "$artifact" \
*/artifacts/openslide-bin-"${version}"-macos-*.tar.xz
echo "artifact=$artifact" >> $GITHUB_OUTPUT
- name: Smoke test
run: |
tar xf "${{ steps.build.outputs.artifact }}"
OPENSLIDE_DEBUG=synthetic \
openslide-bin-*-macos-arm64-x86_64/bin/slidetool prop list ''
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ${{ steps.build.outputs.artifact }}
path: ${{ steps.build.outputs.artifact }}
compression-level: 0