Skip to content

Bump version to 0.7.2 #668

Bump version to 0.7.2

Bump version to 0.7.2 #668

# Copyright (c) the JPEG XL Project Authors. All rights reserved.
#
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
# Workflow for building and running tests.
name: Build/Test Cross
on:
push:
branches:
- main
- v*.*.x
pull_request:
types: [opened, reopened, labeled, synchronize]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs:
cross_compile_ubuntu:
name: Cross-compiling ${{ matrix.build_target }} ${{ matrix.variant }}
runs-on: [ubuntu-22.04]
container:
image: debian:bullseye
strategy:
fail-fast: false
matrix:
include:
- arch: arm64
build_target: aarch64-linux-gnu
cmake_args:
- -DCMAKE_CROSSCOMPILING_EMULATOR=/usr/bin/qemu-aarch64-static
- arch: arm64
variant: SVE
build_target: aarch64-linux-gnu
cmake_args:
- -DCMAKE_CROSSCOMPILING_EMULATOR=/usr/bin/qemu-aarch64-static
- -DJPEGXL_ENABLE_OPENEXR=off
- -DJPEGXL_ENABLE_SIZELESS_VECTORS=on
cmake_flags: -march=armv8-a+sve
c_compiler: aarch64-linux-gnu-gcc
cxx_compiler: aarch64-linux-gnu-g++
disable_tests: true
- arch: arm64
variant: lowprecision
build_target: aarch64-linux-gnu
cmake_args:
- -DCMAKE_CROSSCOMPILING_EMULATOR=/usr/bin/qemu-aarch64-static
- -DCMAKE_CXX_FLAGS=-DJXL_HIGH_PRECISION=0
- arch: armhf
build_target: arm-linux-gnueabihf
cmake_args: [-DCMAKE_CROSSCOMPILING_EMULATOR=/usr/bin/qemu-arm-static]
- arch: i386
test_in_pr: true
build_target: i686-linux-gnu
env:
BUILD_DIR: build
WILL_RUN_TESTS: ${{ (github.event_name == 'push' || (github.event_name == 'pull_request' && (matrix.test_in_pr || contains(github.event.pull_request.labels.*.name, 'CI:full')))) && !matrix.disable_tests }}
steps:
- name: Setup apt
shell: bash
run: |
set -x
apt-get update -y
apt-get install -y ca-certificates debian-ports-archive-keyring
dpkg --add-architecture "${{ matrix.arch }}"
# Update the sources.list with the split of supported architectures.
bkplist="/etc/apt/sources.list.bkp"
mv /etc/apt/sources.list "${bkplist}"
newlist="/etc/apt/sources.list"
rm -f "${newlist}"
main_list="amd64,${{ matrix.arch }}"
port_list=""
if [[ "${{ matrix.arch }}" == "i386" ]]; then
main_list="amd64,i386"
else
port_list="${{ matrix.arch }}"
fi
grep -v -E '^#' "${bkplist}" |
sed -E "s;^deb (http[^ ]+) (.*)\$;deb [arch=${main_list}] \\1 \\2\ndeb-src [arch=${main_list}] \\1 \\2;" \
| tee -a "${newlist}"
- name: Install build deps
shell: bash
run: |
set -x
apt update
pkgs=(
# Build dependencies
cmake
doxygen
git
graphviz
ninja-build
pkg-config
qemu-user-static
xdg-utils
xvfb
# Toolchain for cross-compiling.
clang-11
g++-aarch64-linux-gnu
libc6-dev-${{ matrix.arch }}-cross
libstdc++-10-dev-${{ matrix.arch }}-cross
libstdc++-10-dev:${{ matrix.arch }}
# Dependencies
libbrotli-dev:${{ matrix.arch }}
libgif-dev:${{ matrix.arch }}
libjpeg-dev:${{ matrix.arch }}
libpng-dev:${{ matrix.arch }}
libwebp-dev:${{ matrix.arch }}
# For OpenEXR:
libilmbase-dev:${{ matrix.arch }}
libopenexr-dev:${{ matrix.arch }}
# GTK plugins
libgdk-pixbuf2.0-dev:${{ matrix.arch }}
libgtk2.0-dev:${{ matrix.arch }}
# QT
libqt5x11extras5-dev:${{ matrix.arch }}
qtbase5-dev:${{ matrix.arch }}
)
if [[ "${{ matrix.build_target }}" != "x86_64-linux-gnu" ]]; then
pkgs+=(
binutils-${{ matrix.build_target }}
gcc-${{ matrix.build_target }}
)
fi
if [[ "${{ matrix.arch }}" != "i386" ]]; then
pkgs+=(
# TCMalloc
libgoogle-perftools-dev:${{ matrix.arch }}
libgoogle-perftools4:${{ matrix.arch }}
libtcmalloc-minimal4:${{ matrix.arch }}
libunwind-dev:${{ matrix.arch }}
)
fi
DEBIAN_FRONTEND=noninteractive apt install -y "${pkgs[@]}"
echo "CC=${{ matrix.c_compiler || 'clang-11' }}" >> $GITHUB_ENV
echo "CXX=${{ matrix.cxx_compiler || 'clang++-11' }}" >> $GITHUB_ENV
- name: Checkout the source
uses: actions/checkout@v2
with:
submodules: true
fetch-depth: 1
- name: Build
run: |
CMAKE_FLAGS="${{ matrix.cmake_flags }}" ./ci.sh release \
-DJPEGXL_FORCE_SYSTEM_BROTLI=ON \
-DJPEGXL_ENABLE_JNI=OFF \
${{ join(matrix.cmake_args, ' ') }}
env:
SKIP_TEST: 1
BUILD_TARGET: ${{ matrix.build_target }}
- name: Build stats ${{ matrix.build_target }}
run: |
tools/build_stats.py --save build/stats.json \
--binutils ${{ matrix.build_target }}- \
--max-stack ${{ matrix.max_stack || '0' }} \
cjxl djxl libjxl.so libjxl_dec.so
# Run the tests on push and when requested in pull_request.
- name: Test
if: env.WILL_RUN_TESTS == 'true'
run: |
./ci.sh test
env:
BUILD_TARGET: ${{ matrix.build_target }}