wok annotate pybootchartgui/receipt @ rev 5277
lzma: add --version support
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Apr 16 10:18:15 2010 +0200 (2010-04-16) |
parents | 255e56fcd6cf |
children | bf4a09ef1d2e |
rev | line source |
---|---|
jozee@3218 | 1 # SliTaz package receipt. |
jozee@3218 | 2 |
jozee@3218 | 3 PACKAGE="pybootchartgui" |
jozee@3218 | 4 VERSION="r124" |
jozee@3218 | 5 CATEGORY="misc" |
jozee@3218 | 6 SHORT_DESC="bootchart GUI in python" |
jozee@3218 | 7 MAINTAINER="jozee@slitaz.org" |
jozee@3218 | 8 DEPENDS="python pygtk bootchart" |
jozee@3218 | 9 TARBALL="$PACKAGE-$VERSION.tar.gz" |
jozee@3218 | 10 WEB_SITE="http://pybootchartgui.googlecode.com/" |
jozee@3218 | 11 WGET_URL="$WEB_SITE/files/$TARBALL" |
jozee@3218 | 12 |
jozee@3218 | 13 |
jozee@3218 | 14 |
jozee@3218 | 15 # Rules to gen a SliTaz package suitable for Tazpkg. |
jozee@3218 | 16 genpkg_rules() |
jozee@3218 | 17 { |
jozee@3218 | 18 PY_VERSION=`cat /var/lib/tazpkg/installed/python/receipt | grep "VERSION="|cut -d \" -f 2 | cut -d . -f 1,2` |
jozee@3218 | 19 mkdir -p $fs/usr/lib/python$PY_VERSION $fs/usr/bin |
jozee@3218 | 20 cp -a $src/pybootchartgui.py $fs/usr/lib/python$PY_VERSION |
jozee@3218 | 21 cp -a $src/pybootchartgui $fs/usr/lib/python$PY_VERSION |
jozee@3218 | 22 |
jozee@3218 | 23 |
jozee@3218 | 24 } |
jozee@3218 | 25 |
jozee@3218 | 26 post_install() |
jozee@3218 | 27 { |
jozee@3218 | 28 local root |
jozee@3218 | 29 root=$1 |
jozee@3218 | 30 PY_VERSION=`cat /var/lib/tazpkg/installed/python/receipt | grep "VERSION="|cut -d \" -f 2 | cut -d . -f 1,2` |
jozee@3218 | 31 if [ -f $root/usr/bin/pybootchartgui ] ; then rm $root/usr/bin/pybootchartgui ; fi |
jozee@3218 | 32 ln -s $root/usr/lib/python$PY_VERSION/pybootchartgui.py $root/usr/bin/pybootchartgui |
jozee@4964 | 33 if [ -f $root/etc/bootchartd.conf ] ; then |
jozee@4964 | 34 sed -i s/'AUTO_RENDER="no"'/'AUTO_RENDER="yes"'/ $root/etc/bootchartd.conf |
jozee@4964 | 35 fi |
jozee@3218 | 36 } |
jozee@3218 | 37 |
jozee@3218 | 38 post_remove() |
jozee@3218 | 39 { |
jozee@3218 | 40 local root |
jozee@3218 | 41 root=$1 |
jozee@3218 | 42 rm $root/usr/bin/pybootchartgui |
jozee@4964 | 43 if [ -f $root/etc/bootchartd.conf ] ; then |
jozee@4964 | 44 sed -i s/'AUTO_RENDER="yes"'/'AUTO_RENDER="no"'/ $root/etc/bootchartd.conf |
jozee@4964 | 45 fi |
jozee@3218 | 46 } |