PKGBUILDs/extra/libyuv/PKGBUILD
2023-05-29 21:48:20 +00:00

39 lines
990 B
Bash

# Maintainer: Bruno Pagani <archange@archlinux.org>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - disable NEON, broken assembly
pkgname=libyuv
pkgver=r2322+3aebf69d
pkgrel=1.1
pkgdesc="Library for YUV scaling"
arch=(x86_64)
url="https://chromium.googlesource.com/libyuv/libyuv/"
license=(custom)
depends=(gcc-libs libjpeg)
makedepends=(cmake git)
# Version required by libavif
_commit=3aebf69d668177e7ee6dbbe0025e5c3dbb525ff2
source=(git+${url}#commit=${_commit})
sha512sums=(SKIP)
pkgver() {
cd ${pkgname}
printf "r%s+%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
prepare() {
sed -i 's|yuvconvert ${JPEG_LIBRARY}|${ly_lib_shared} ${JPEG_LIBRARY}|' ${pkgname}/CMakeLists.txt
}
build() {
CXXFLAGS+=" -DLIBYUV_DISABLE_NEON"
cmake -B build -S ${pkgname} \
-DCMAKE_INSTALL_PREFIX=/usr
make -C build
}
package() {
make -C build DESTDIR="${pkgdir}" install
install -Dm644 ${pkgname}/LICENSE -t "${pkgdir}"/usr/share/licenses/${pkgname}/
}