aboutsummaryrefslogtreecommitdiffstats
path: root/main/x265/APKBUILD
blob: 8ecb316542bfc91de90301ae9709154ce25bf091 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=x265
pkgver=2.4
pkgrel=0
pkgdesc="Open Source H265/HEVC video encoder"
url="https://bitbucket.org/multicoreware/x265"
arch="all"
license="GPL"
makedepends="$depends_dev cmake yasm"
subpackages="$pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://bitbucket.org/multicoreware/$pkgname/downloads/${pkgname}_${pkgver}.tar.gz"
builddir="$srcdir"/x265_$pkgver

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
}

sha512sums="40d0e57104839454226cdba928806c12e533eade391a89e9587e1f9c11b8fd70cc54d20136a09a1127784fe7799c80425617280076b29e1a1ffff7ce44f07dbe  x265-2.4.tar.gz"