CI Linux: download rav1e build instead of building own

Building rav1e requires nasm 2.15 (if asm is not disabled) while U20
has just 2.14.02, so that the build in CI currently fails, anyways.

Pick sse4 for now but expect using avx2 version later, depending on
UG_ARCH value.

\+ populate PKG_CONFIG_PATH immediately
This commit is contained in:
Martin Pulec
2024-03-20 10:08:08 +01:00
parent a88e99bdc4
commit f5467237ae
4 changed files with 18 additions and 26 deletions

View File

@@ -78,6 +78,21 @@ install_pipewire() {(
fi
)}
install_rav1e() {(
# TODO: use avx2 later
if expr "${UG_ARCH-}" : '.*avx' >/dev/null; then
avx2=avx2
fi
fpattern="librav1e.*linux-${avx2-sse4}.tar.gz"
"${GITHUB_WORKSPACE-.}"/.github/scripts/download-gh-asset.sh xiph/rav1e \
"$fpattern" librav1e.tar.gz
sudo tar xaf librav1e.tar.gz -C /usr/local
sudo rm -rf /usr/local/lib/librav1e.so*
sudo sed -i -e 's-prefix=dist-prefix=/usr/local-' \
-e 's/-lrav1e/-lrav1e -lm -pthread/' \
/usr/local/lib/pkgconfig/rav1e.pc
)}
# FFmpeg master needs at least v1.3.238 as for 23th Aug '23
install_vulkan() {(
# TOREMOVE: FFmpeg doesn't currently build with main (2024-02-09)
@@ -101,7 +116,7 @@ if [ $# -eq 1 ] && { [ "$1" = -h ] || [ "$1" = --help ] || [ "$1" = help ]; }; t
fi
if [ $# -eq 0 ] || [ $show_help ]; then
set -- aja gpujpeg live555 ndi pipewire vulkan ximea
set -- aja gpujpeg live555 ndi pipewire rav1e vulkan ximea
fi
if [ $show_help ]; then

View File

@@ -1,9 +1,10 @@
#!/bin/bash -eux
export PKG_CONFIG_PATH=/usr/local/qt/lib/pkgconfig:/usr/local/lib/pkgconfig
printf "%b" "AJA_DIRECTORY=/var/tmp/ntv2\n\
CPATH=/usr/local/qt/include\n\
LIBRARY_PATH=/usr/local/qt/lib\n\
PKG_CONFIG_PATH=/usr/local/qt/lib/pkgconfig\n" >> "$GITHUB_ENV"
PKG_CONFIG_PATH=$PKG_CONFIG_PATH\n" >> "$GITHUB_ENV"
printf "/usr/local/qt/bin\n" >> "$GITHUB_PATH"
git config --global user.name "UltraGrid Builder"

View File

@@ -1,11 +0,0 @@
#!/bin/sh -eux
#
# Builds rav1e but doesn't install it
rustup update
cargo install cargo-c
git clone --depth 1 https://github.com/xiph/rav1e.git
cd rav1e
cargo build --release
cargo cinstall --release --destdir=install