mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
60 lines
1.5 KiB
Bash
60 lines
1.5 KiB
Bash
# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
|
|
# Contributor: Chocobo1 <chocobo1 AT archlinux DOT net>
|
|
|
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
# - cmake with -DAOM_TARGET_CPU=generic for !AArch64
|
|
|
|
pkgbase=aom
|
|
pkgname=(aom aom-docs)
|
|
pkgver=3.1.2
|
|
pkgrel=2
|
|
pkgdesc="Alliance for Open Media video codec"
|
|
url="https://aomedia.org/"
|
|
arch=(x86_64)
|
|
license=(BSD custom:PATENTS)
|
|
depends=(gcc-libs)
|
|
makedepends=(git cmake ninja doxygen yasm)
|
|
_commit=ae2be8030200925895fa6e98bd274ffdb595cbf6 # tags/v3.1.2^0
|
|
source=("git+https://aomedia.googlesource.com/aom#commit=$_commit")
|
|
b2sums=('SKIP')
|
|
|
|
pkgver() {
|
|
cd $pkgbase
|
|
git describe --tags | sed 's/^v//;s/-errata/.errata/;s/-/+/g'
|
|
}
|
|
|
|
prepare() {
|
|
cd $pkgbase
|
|
|
|
# https://bugs.archlinux.org/task/71800
|
|
git cherry-pick -n 31257f59a1df72cbbd1399efb780d13a0e433b16
|
|
}
|
|
|
|
build() {
|
|
[[ $CARCH != "aarch64" ]] && CONFIG="-DAOM_TARGET_CPU=generic"
|
|
cmake -S $pkgbase -B build -G Ninja \
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
-DBUILD_SHARED_LIBS=1 \
|
|
-DENABLE_TESTS=0 $CONFIG
|
|
cmake --build build
|
|
}
|
|
|
|
package_aom() {
|
|
provides=(libaom.so)
|
|
|
|
DESTDIR="$pkgdir" cmake --install build
|
|
|
|
install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 $pkgbase/{LICENSE,PATENTS}
|
|
}
|
|
|
|
package_aom-docs() {
|
|
pkgdesc+=" (documentation)"
|
|
depends=()
|
|
|
|
mkdir -p "$pkgdir/usr/share/doc"
|
|
cp -r build/docs/html "$pkgdir/usr/share/doc/$pkgbase"
|
|
|
|
install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 $pkgbase/{LICENSE,PATENTS}
|
|
}
|
|
|
|
# vim:set et sw=2:
|