wok-6.x view mplayerplug-in/receipt @ rev 25174

updated python-flask (1.1.2 -> 1.1.4)
author Hans-G?nter Theisgen
date Fri Jul 01 17:16:59 2022 +0100 (2022-07-01)
parents d6ca18366f41
children 7dd01dedad38
line source
1 # SliTaz package receipt.
3 PACKAGE="mplayerplug-in"
4 VERSION="3.55"
5 CATEGORY="multimedia"
6 SHORT_DESC="a browser plugin that uses mplayer to play videos from websites"
7 MAINTAINER="jozee@slitaz.org"
8 LICENSE="GPL"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://mplayerplug-in.sourceforge.net/"
11 WGET_URL="http://downloads.sourceforge.net/mplayerplug-in/$TARBALL"
12 TAGS="player audio video browser"
14 DEPENDS="mplayer xorg-libXpm gtk+ gcc-lib-base"
15 BUILD_DEPENDS="mplayer gtk+-dev xorg-libXpm-dev firefox-dev libIDL gettext \
16 nspr-dev"
18 # What is the latest version available today?
19 current_version()
20 {
21 wget -O - https://sourceforge.net/projects/mplayerplug-in/files/mplayerplug-in/ 2>/dev/null | \
22 sed '/scope="row/!d;s|.*href="|"https://sourceforge.net|;q' | xargs wget -O - 2>/dev/null | \
23 sed '/scope="row/!d;s|.*/mplayerplug-in/v||;s|/.*||;q'
24 }
26 get_firefox_version()
27 {
28 FIREFOX_VER=$(cat "$1/var/lib/tazpkg/installed/firefox/receipt" | \
29 grep VERSION= | cut -d \" -f 2)
30 }
32 # Rules to configure and make the package.
33 compile_rules()
34 {
35 sed -i 's/npupp\.h/npfunctions.h/' */np*
36 sed -i 's|char [\* ]*NP*_GetMIMEDescription(|const &|' \
37 plugingate/np_entry.cpp Source/plugin.cpp
38 cp $stuff/slitaz-hack.h include
39 grep -q slitaz-hack include/npplat.h || sed -i \
40 's/ne _NPPLAT_H_/ne _NPPLAT_H_\n#include "slitaz-hack.h"/' \
41 include/npplat.h
42 while read file; do
43 [ -f done.$file ] && continue
44 echo "Apply $file..."
45 patch -p1 < $stuff/$PACKAGE-$VERSION-$file || return 1
46 touch done.$file
47 done <<EOT
48 glibc210.u
49 static-iid-accessor.u
50 EOT
51 make distclean
52 touch install.sh
53 get_firefox_version
54 ./configure --prefix=/usr --sysconfdir=/etc \
55 --enable-x \
56 --enable-wmp \
57 --enable-qt \
58 --enable-rm \
59 --enable-dvx \
60 CFLAGS="$CFLAGS -I/usr/include/nspr" \
61 GECKO_XPIDL="$stuff/xpidl" \
62 MOZILLA_HOME="/usr/lib/firefox-$FIREFOX_VER" \
63 GECKO_IDLDIR="/usr/share/idl/firefox-$FIREFOX_VER" &&
64 make $MAKEFLAGS &&
65 make DESTDIR=$DESTDIR install
66 }
68 genpkg_rules()
69 {
70 mkdir -p $fs/usr/lib
71 cp -a $install/etc $fs
72 cp -a $install/usr/lib/mozilla $fs/usr/lib
73 # change the default video output to xv,x11
74 sed -i "s/#vo=xv,x11/vo=xv,x11/" $fs/etc/$PACKAGE.conf
75 }
77 post_install()
78 {
79 get_firefox_version "$1"
80 cd "$1/"
81 for i in usr/lib/mozilla/plugins/$PACKAGE*.so ; do
82 ln -s "/$i" "$1/usr/lib/firefox-$FIREFOX_VER/plugins"
83 done
84 }
86 post_remove()
87 {
88 rm -f /usr/lib/firefox*/plugins/$PACKAGE*.so
89 }