aports/community/libvpx/APKBUILD
2025-05-31 18:52:15 +02:00

79 lines
2 KiB
Text

# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libvpx
pkgver=1.15.1
pkgrel=1
pkgdesc="Library for the vp8/vp9 codecs"
url="https://www.webmproject.org/"
arch="all"
license="BSD-3-Clause"
makedepends="coreutils nasm bash perl diffutils linux-headers" # linux-headers is needed on ppc64le
subpackages="$pkgname-dev $pkgname-utils"
source="https://github.com/webmproject/libvpx/archive/v$pkgver/libvpx-v$pkgver.tar.gz
fix-arm-float-abi.patch
fix-double-free.patch
"
# net required for tests
# tests disabled due to failing to find symbols
options="!check"
# secfixes:
# 1.14.1-r0:
# - CVE-2024-5197
# 1.13.0-r3:
# - CVE-2023-5217
# 1.8.2-r0:
# - CVE-2020-0034
# 1.8.1-r0:
# - CVE-2019-9371
# - CVE-2019-9433
# - CVE-2019-9325
# - CVE-2019-9232
# GCC13 unrecognized '-mlsx' '-mlasx' on loongarch64
[ "$CARCH" = "loongarch64" ] && _target="--target=generic-gnu"
build() {
# build fix for arm
export CROSS=" "
export CFLAGS="$CFLAGS -O2 -flto=auto -ffat-lto-objects"
export CXXFLAGS="$CXXFLAGS -O2 -flto=auto -ffat-lto-objects"
./configure \
--prefix=/usr \
--disable-install-srcs \
--disable-static \
--enable-libs \
--enable-multithread \
--enable-pic \
--enable-postproc \
--enable-runtime-cpu-detect \
--enable-shared \
--enable-temporal-denoising \
--enable-unit-tests \
--enable-vp8 \
--enable-vp9 \
--enable-vp9-highbitdepth \
--enable-vp9-postproc \
--enable-vp9-temporal-denoising \
$_target
make
}
check() {
make test
}
package() {
make DESTDIR="$pkgdir" install
}
utils() {
pkgdesc="$pkgdesc (tools)"
amove usr/bin
}
sha512sums="
4cf5c3d7735ed75be1984b826dd6706e46e21ef9f0e9c7c52001d0c71ab10e79633ae292132d49db11ca2251a77573473b911400b1e4cf2383a74e59c540b640 libvpx-v1.15.1.tar.gz
4eadbc2f4eb68eaff35cf85515aef271d6fd47293a53cba7b7a6e9e0fb71106dfb5ded45b9e9ba83264a91846e4a5fa4db42e39fc3eaff6ac37769e622f90f6c fix-arm-float-abi.patch
b81ebf05967050f0617c7333e923ca9f59de241f0c2e6cddc8fef92986942f131f38a3b5d6e356b576585b1039a0951c4cbce246e2e3f7d68e65df37d2b76e56 fix-double-free.patch
"