wok-undigest annotate mplayerplug-in/receipt @ rev 326
Moved dia and nethack to wok.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Sun Jun 12 18:02:58 2011 +0000 (2011-06-12) |
parents | |
children | 235d315ed3fb |
rev | line source |
---|---|
pankso@247 | 1 # SliTaz package receipt. |
pankso@247 | 2 |
pankso@247 | 3 PACKAGE="mplayerplug-in" |
pankso@247 | 4 VERSION="3.55" |
pankso@247 | 5 CATEGORY="multimedia" |
pankso@247 | 6 SHORT_DESC="a browser plugin that uses mplayer to play videos from websites" |
pankso@247 | 7 MAINTAINER="jozee@slitaz.org" |
pankso@247 | 8 DEPENDS="mplayer xorg-libXpm gtk+ gcc-lib-base" |
pankso@247 | 9 BUILD_DEPENDS="mplayer gtk+-dev xorg-libXpm-dev firefox-dev libIDL gettext" |
pankso@247 | 10 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pankso@247 | 11 WEB_SITE="http://mplayerplug-in.sourceforge.net/" |
pankso@247 | 12 WGET_URL="http://downloads.sourceforge.net/mplayerplug-in/$TARBALL" |
pankso@247 | 13 TAGS="player audio video browser" |
pankso@247 | 14 |
pankso@247 | 15 get_firefox_version() |
pankso@247 | 16 { |
pankso@247 | 17 FIREFOX_VER=`cat $1/var/lib/tazpkg/installed/firefox/receipt | \ |
pankso@247 | 18 grep VERSION= | cut -d \" -f 2` |
pankso@247 | 19 } |
pankso@247 | 20 |
pankso@247 | 21 # Rules to configure and make the package. |
pankso@247 | 22 compile_rules() |
pankso@247 | 23 { |
pankso@247 | 24 cd $src |
pankso@247 | 25 sed -i 's/npupp\.h/npfunctions.h/' */np* |
pankso@247 | 26 cp ../stuff/slitaz-hack.h include |
pankso@247 | 27 grep -q slitaz-hack include/npplat.h || sed -i \ |
pankso@247 | 28 's/ne _NPPLAT_H_/ne _NPPLAT_H_\n#include "slitaz-hack.h"/' \ |
pankso@247 | 29 include/npplat.h |
pankso@247 | 30 while read file; do |
pankso@247 | 31 [ -f done.$file ] && continue |
pankso@247 | 32 echo "Apply $file..." |
pankso@247 | 33 patch -p1 < ../stuff/$PACKAGE-$VERSION-$file || return 1 |
pankso@247 | 34 touch done.$file |
pankso@247 | 35 done <<EOT |
pankso@247 | 36 glibc210.u |
pankso@247 | 37 static-iid-accessor.u |
pankso@247 | 38 EOT |
pankso@247 | 39 make distclean |
pankso@247 | 40 touch install.sh |
pankso@247 | 41 get_firefox_version |
pankso@247 | 42 ./configure --prefix=/usr --sysconfdir=/etc \ |
pankso@247 | 43 --enable-gtk2 \ |
pankso@247 | 44 --enable-wmp \ |
pankso@247 | 45 --enable-qt \ |
pankso@247 | 46 --enable-rm \ |
pankso@247 | 47 --enable-dvx \ |
pankso@247 | 48 MOZILLA_HOME="/usr/lib/firefox-$FIREFOX_VER" \ |
pankso@247 | 49 GECKO_IDLDIR="/usr/share/idl/firefox-$FIREFOX_VER" && |
pankso@247 | 50 make -j 4 && |
pankso@247 | 51 make DESTDIR=$PWD/_pkg install |
pankso@247 | 52 } |
pankso@247 | 53 |
pankso@247 | 54 genpkg_rules() |
pankso@247 | 55 { |
pankso@247 | 56 mkdir -p $fs/usr/lib |
pankso@247 | 57 cp -a $_pkg/etc $fs |
pankso@247 | 58 cp -a $_pkg/usr/lib/mozilla $fs/usr/lib |
pankso@247 | 59 # change the default video output to xv,x11 |
pankso@247 | 60 sed -i "s/#vo=xv,x11/vo=xv,x11/" $fs/etc/$PACKAGE.conf |
pankso@247 | 61 |
pankso@247 | 62 } |
pankso@247 | 63 |
pankso@247 | 64 post_install() |
pankso@247 | 65 { |
pankso@247 | 66 echo -n "Processing post install commands..." |
pankso@247 | 67 local root |
pankso@247 | 68 root=$1 |
pankso@247 | 69 get_firefox_version $1 |
pankso@247 | 70 for i in $root/usr/lib/mozilla/plugins/$PACKAGE*.so ; do |
pankso@247 | 71 ln -s $i $root/usr/lib/firefox-$FIREFOX_VER/plugins |
pankso@247 | 72 done |
pankso@247 | 73 status |
pankso@247 | 74 } |
pankso@247 | 75 |
pankso@247 | 76 post_remove() |
pankso@247 | 77 { |
pankso@247 | 78 echo -n "Processing post remove commands..." |
pankso@247 | 79 rm -f /usr/lib/firefox*/plugins/$PACKAGE*.so |
pankso@247 | 80 status |
pankso@247 | 81 } |
pankso@247 | 82 |