1 # Contributor: Jason <jason52lh # gmail com>
5 pkgdesc="Complete and free Internet live audio and video broadcasting solution for Linux/Unix (Multithread build, git version, needed by mplayer-mt)"
7 url="http://ffmpeg.mplayerhq.hu/"
10 # set 1 to force not to use alsa libs
13 # depend on only what you already have
14 [ "x$_noalsa" == "x0" ] && _alsa=$(pacman -Q alsa-lib 2>/dev/null | awk '{print $1}')
15 _xvidcore=$(pacman -Q xvidcore 2>/dev/null | awk '{print $1}')
16 _faac=$(pacman -Q faac 2>/dev/null | awk '{print $1}')
17 _libvpx=$(pacman -Q libvpx 2>/dev/null | awk '{print $1}')
18 _lame=$(pacman -Q lame 2>/dev/null | awk '{print $1}')
19 _libvdpau=$(pacman -Q libvdpau 2>/dev/null | awk '{print $1}')
20 _x264=$(pacman -Q x264 2>/dev/null | awk '{print $1}')
22 depends=('zlib' 'libxext' 'libxfixes' 'libvorbis' 'libtheora' $_x264 $_xvidcore $_libvpx $_faac $_lame $_alsa)
23 makedepends=('git' 'yasm')
29 _gitroot="git://repo.or.cz/FFMpeg-mirror/mplayer-patches.git"
34 msg "Connecting to GIT server...."
36 if [ -d "$srcdir/$_gitname" ] ; then
37 cd $_gitname && git pull origin
38 msg "The local files are updated."
40 git clone $_gitroot $_gitname
42 git checkout --track -b mt origin/mt
45 msg "GIT checkout done or server timeout"
46 msg "Starting make..."
48 cd "$srcdir/$_gitname"
54 [ ! -z $_xvidcore ] && _options="$_options --enable-libxvid"
55 [ ! -z $_x264 ] && _options="$_options --enable-libx264"
56 [ ! -z $_faac ] && _options="$_options --enable-libfaac"
57 [ ! -z $_lame ] && _options="$_options --enable-libmp3lame"
58 [ ! -z $_libvpx ] && _options="$_options --enable-libvpx"
59 [ "x$_noalsa" == "x1" ] && _options="$_options --disable-outdev=alsa"
62 --prefix=/usr --enable-shared --enable-pthreads --arch=`uname -m` \
63 --enable-gpl --enable-version3 --enable-nonfree --enable-postproc \
64 --enable-libvorbis --enable-libtheora --enable-x11grab $_options
67 make doc/ff{mpeg,server}.1 || return 1
70 cd ${srcdir}/$_gitname
71 make DESTDIR="$pkgdir" install || return 1
72 make DESTDIR="$pkgdir" install-man || return 1
73 rm `find $pkgdir -name "*.a"`