aboutsummaryrefslogtreecommitdiffstats
path: root/main/x264/APKBUILD
blob: 4230e3cb318252484f2d0dca16d6cd95b46fe2e8 (plain) (blame)
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
34
35
36
37
38
39
40
41
42
43
44
45
46
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=x264
pkgver=20140625
pkgrel=1
pkgdesc="free library for encoding H264/AVC video streams"
url="http://www.videolan.org/developers/x264.html"
arch="all"
license="GPL"
depends=
makedepends="libx11-dev bash yasm coreutils perl"
subpackages="$pkgname-dev $pkgname-libs"
source="ftp://ftp.videolan.org/pub/x264/snapshots/x264-snapshot-$pkgver-2245-stable.tar.bz2"

_builddir="$srcdir/$pkgname-snapshot-$pkgver-2245-stable"
build() {
	cd "$_builddir"
	local _asmopts=

	case "$CARCH" in
		# x86 assembly contains TEXTRELs
		# arm neon assembly contains TEXTRELs
		x86 | arm*) _asmopts="--disable-asm"
	esac

	# note: not autotools
	./configure \
		--host=$CHOST \
		--prefix=/usr \
		--enable-shared \
		$_asmopts \
		--enable-pic \
		--extra-cflags=-fno-aggressive-loop-optimizations \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make -C "$_builddir" DESTDIR="$pkgdir" \
		bindir=/usr/bin libdir=/usr/lib includedir=/usr/include \
		install || return 1
}

md5sums="9921a42b9c5f75929fd47c3b3751d573  x264-snapshot-20140625-2245-stable.tar.bz2"
sha256sums="2b8e83482560a77873ffef70a96a3b324815450a96223128a619db71ff9abdb4  x264-snapshot-20140625-2245-stable.tar.bz2"
sha512sums="36ee67fb15fb541bec0ea7d38a44a5cf618b6b5a7426581a6039bdb5c1444a47cae8b346d66e4b6856d053138e79132636c1c83234014517296f779bda672cf5  x264-snapshot-20140625-2245-stable.tar.bz2"