aboutsummaryrefslogtreecommitdiffstats
path: root/main/mplayer/APKBUILD
blob: 45aea5661c1698bb8f05947e1ea9cf1a8ca46c0b (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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=mplayer
pkgver=1.1.1
_ver=${pkgver/_/}
pkgrel=1
pkgdesc="A movie player for linux"
url="http://www.mplayerhq.hu/"
arch="all"
license="GPL"
depends=
subpackages="$pkgname-doc"
makedepends="libxxf86dga-dev libxv-dev libmad-dev lame-dev libao-dev
	libtheora-dev xvidcore-dev zlib-dev sdl-dev freetype-dev
	x264-dev faac-dev ttf-dejavu libxvmc-dev alsa-lib-dev live-media-dev
	mesa-dev yasm libpng-dev"

source="ftp://ftp1.mplayerhq.hu/MPlayer/releases/MPlayer-$pkgver.tar.xz
	x11-libs.patch
	"
_builddir="$srcdir"/MPlayer-$_ver
prepare() {
	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"

	export GCC_SPECS=hardenednopie.specs
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--disable-gui \
		--disable-gif \
		--disable-arts \
		--enable-x11 \
		--enable-runtime-cpudetection \
		--confdir=/etc/mplayer \
		--disable-nas \
		--enable-gl \
		--disable-tv-v4l1 \
		--enable-tv-v4l2 \
		--disable-liblzo \
		--disable-speex \
		--disable-openal \
		--disable-fribidi \
		--disable-libdv \
		--disable-musepack \
		--language=all \
		--disable-esd \
		--disable-mga \
		--disable-lirc \
		--enable-debug \
		--enable-radio \
		--enable-radio-capture \
		--extra-cflags="-I/usr/lib/live-media -O2" \
		--disable-nemesi \
		--enable-freetype \
		--enable-xvmc \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make -j1 DESTDIR="$pkgdir" install || return 1
	install -Dm644 etc/codecs.conf etc/input.conf etc/example.conf \
		"$pkgdir"/etc/mplayer/ || return 1
	install -dm755 "$pkgdir"/usr/share/mplayer/
	ln -s /usr/share/fonts/TTF/DejaVuSans.ttf \
		"$pkgdir"/usr/share/mplayer/subfont.ttf || return 1
	rm -rf "$pkgdir"/usr/share/mplayer/font
}
md5sums="39dd55f30eb5403f219a606e79a6648a  MPlayer-1.1.1.tar.xz
01bcc935a6b429347e8e77e1a70bf2b2  x11-libs.patch"
sha256sums="ce8fc7c3179e6a57eb3a58cb7d1604388756b8a61764cc93e095e7aff3798c76  MPlayer-1.1.1.tar.xz
924ae52abeaad41e4d14c0af82d52a6d65985f3b1c77fa432ed04a5ccbc4c24c  x11-libs.patch"
sha512sums="06371d47b02caec83c7662f6bb4a827eafb7f3309f6cda959a0f49b647df031166a6e7c5d530b57b580104289ee260aa96f3f43cbfffcef816cea776b0d5aed0  MPlayer-1.1.1.tar.xz
bba012c5a116cbc6715955a0a563c89a33a1d8ad3c44301a083ce65296ba9112a88a58e38c874d9347f9c3133054e62bd16d3b3367383f207ee40ddae105081c  x11-libs.patch"