# Contributor: Carlo Landmeter # Maintainer: Natanael Copa pkgname=x265 pkgver=2.3 pkgrel=0 pkgdesc="Open Source H265/HEVC video encoder" url="https://bitbucket.org/multicoreware/x265" arch="all" license="GPL" depends="" depends_dev="" makedepends="$depends_dev cmake yasm" install="" subpackages="$pkgname-dev" source="$pkgname-$pkgver.tar.gz::https://bitbucket.org/multicoreware/$pkgname/downloads/${pkgname}_${pkgver}.tar.gz" _builddir="$srcdir"/x265_$pkgver prepare() { local i cd "$_builddir" for i in $source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done } build() { cd "$_builddir"/build/linux local CMAKE_OPS="-DCMAKE_INSTALL_PREFIX=/usr" # has textrel on x86 so we disable asm if [ "$CARCH" = x86 ] ; then CMAKE_OPS="$CMAKE_OPS -DENABLE_ASSEMBLY=OFF" fi if [ "$CARCH" = ppc64le ] ; then CMAKE_OPS="$CMAKE_OPS -DENABLE_ALTIVEC=OFF" fi cmake -G "Unix Makefiles" $CMAKE_OPS ../../source } package() { cd "$_builddir"/build/linux make DESTDIR="$pkgdir" install || return 1 } sha512sums="c863e4bd95323baf5c1ee388c2d9e460749940b947a795e0bce7bffab620258fb7aafbbf2956225491f4532f715392df3d40f19301964e00c3ac2971cd7d8809 x265-2.3.tar.gz"