# Contributor: Leonardo Arena # Maintainer: Natanael Copa pkgname=vlc pkgver=1.1.7 pkgrel=3 pkgdesc="A multi-platform MPEG, VCD/DVD, and DivX player" url="http://www.videolan.org/vlc/" arch="all" license="GPL-2" triggers="$pkgname.trigger:/usr/lib/vlc/plugins" subpackages="$pkgname-dev $pkgname-doc $pkgname-xorg" #depends="libnotify a52dec fluidsynth zvbi libdvbpsi lirc-utils libdca hal # libproxy sdl_image libdvdnav>=4.1.3 lua libxv libv4l libcddb smbclient # libmatroska taglib sysfsutils libmpcdec ffmpeg>=0.5 libshout libmad # qt fribidi libmpeg2 libmodplug avahi ttf-dejavu" depends="ttf-dejavu" makedepends=" a52dec-dev alsa-lib-dev automake autoconf libtool dbus-dev faad2-dev ffmpeg-dev flac-dev fribidi-dev gtk+-dev libdvbpsi-dev libgcrypt-dev libice-dev libiconv-dev libmad-dev libmpeg2-dev libnotify-dev libogg-dev libsm-dev libtheora-dev libvorbis-dev libx11-dev libxext-dev libxv-dev live-media-dev lua-dev ncurses-dev mesa-dev pkgconfig sdl-dev sysfsutils-dev taglib-dev v4l-utils-dev x264-dev " source="http://download.videolan.org/pub/videolan/$pkgname/$pkgver/$pkgname-$pkgver.tar.bz2 uclibc3.patch uclibc-libcompat.patch uclibc-inhibit-spawn.patch vlc.trigger vlc-1.1.7-disable-cache-gen.patch " _builddir="$srcdir"/$pkgname-$pkgver prepare() { cd "$_builddir" for i in $source; do case $i in *.patch) msg "Applying $i" patch -p1 -i "$srcdir"/$i || return 1 ;; esac; done sed -i -e "/^SOURCES_xscreensaver/s/^/#/" modules/misc/Modules.am ./bootstrap } build () { cd "$_builddir" sed -i -e 's:/usr/share/fonts/truetype/freefont/FreeSerifBold.ttf:/usr/share/fonts/TTF/DejaVuSerif-Bold.ttf:' modules/misc/freetype.c export CFLAGS="$CFLAGS -D_GNU_SOURCE" ./configure --prefix=/usr \ --disable-mmx \ --disable-nls \ --disable-optimizations \ --disable-qt4 --disable-skins2 \ --disable-rpath \ --enable-a52 \ --enable-avcodec \ --enable-avformat \ --enable-dbus \ --enable-dbus-control \ --enable-dvbpsi \ --enable-faad \ --enable-flac \ --enable-httpd \ --enable-live555 \ --enable-merge-ffmpeg \ --enable-ncurses \ --enable-realrtsp \ --enable-sdl \ --enable-sout \ --enable-taglib \ --enable-theora \ --enable-v4l \ --enable-v4l2 \ --enable-vlm \ --enable-vorbis \ --enable-xvideo \ || return 1 # --enable-dvdread \ # --enable-dvdnav \ # --enable-qt4 \ # --enable-skins2 \ # --enable-dvb \ # --enable-snapshot \ # --enable-hal \ # --enable-lirc \ # --enable-shout \ # --enable-pvr \ make || return 1 } package() { cd "$_builddir" make DESTDIR="$pkgdir"/ install || return 1 # for res in 16 32 48 128; do # install -D -m644 share/vlc${res}x${res}.png \ # "$pkgdir"/usr/share/icons/hicolor/${res}x${res}/apps/vlc.png || return 1 # done rm -rf "$pkgdir"/usr/lib/mozilla # FIXME: for some reason libavcodec_plugin does not get installed install -m644 $_builddir/modules/codec/avcodec/.libs/libavcodec_plugin.so \ $pkgdir/usr/lib/vlc/plugins/codec/libavcodec_plugin.so } _mv() { local dir=${1%/*} mkdir -p "$subpkgdir"/$dir mv "$1" "$subpkgdir"/$dir/ } xorg() { pkgdesc="Video LAN X.org support" triggers= # scan for elf files that directly or indirectly depends on # libX* libraries cd "$pkgdir" for i in $(find -type f ); do if ldd $i 2>/dev/null | grep -q libX; then _mv "$i" || return 1 fi done mkdir -p "$subpkgdir"/usr/share/ mv "$pkgdir"/usr/share/applications \ "$pkgdir"/usr/share/kde4 \ "$pkgdir"/usr/share/icons \ "$subpkgdir"/usr/share/ } md5sums="932ce1fa4afa54b56ac0ccc0655667b6 vlc-1.1.7.tar.bz2 4f74dcde9ce51c15d80c3876b85c05f2 uclibc3.patch d718e22a7de9f38579f276f720b2f36a uclibc-libcompat.patch 43bea31edd02de2b53075e5e883706db uclibc-inhibit-spawn.patch ddbd40bd72fedc1449be45588aea5d66 vlc.trigger e1ef2dec8e25f7ea6ba40e646c63e061 vlc-1.1.7-disable-cache-gen.patch"