summaryrefslogtreecommitdiff
path: root/extra/libmpeg2/PKGBUILD
blob: 60a0499b249482c21899789f5e82a39b822956a0 (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
# $Id: PKGBUILD 177015 2013-02-04 08:35:17Z jgc $
# Contributor: Sarah Hay <sarah@archlinux.org>
# Maintainer: Andreas Radke <andyrtr@archlinux.org>

pkgname=libmpeg2
pkgver=0.5.1
pkgrel=4
pkgdesc="Library for decoding MPEG-1 and MPEG-2 video streams."
arch=('i686' 'x86_64')
url="http://libmpeg2.sourceforge.net/"
depends=('glibc')
makedepends=('sdl' 'libxv')
optdepends=('sdl: required for mpeg2dec'
            'libxv: required for mpeg2dec')
source=(http://libmpeg2.sourceforge.net/files/${pkgname}-${pkgver}.tar.gz
        libmpeg2-0.5.1-gcc4.6.patch)
license=('GPL2')
options=(!libtool)
provides=('mpeg2dec')
md5sums=('0f92c7454e58379b4a5a378485bbd8ef'
         '8b36660297e6ffde6aa9733136bff405')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  patch -Np1 -i "${srcdir}/libmpeg2-0.5.1-gcc4.6.patch"

  sed '/AC_PATH_XTRA/d' -i configure.ac
  autoreconf --force --install

  ./configure --prefix=/usr --enable-shared --disable-static
  make	OPT_CFLAGS="${CFLAGS}" \
	MPEG2DEC_CFLAGS="${CFLAGS}" \
	LIBMPEG2_CFLAGS=""
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
}