# HG changeset patch # User Rohit Joshi # Date 1243514930 0 # Node ID a60208fea30c89343b943b5f499c73ef684323bd # Parent 9743505c66accb3e7a8aea60b300d29fb00445ed Add bootgraph diff -r 9743505c66ac -r a60208fea30c bootchart/receipt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/bootchart/receipt Thu May 28 12:48:50 2009 +0000 @@ -0,0 +1,54 @@ +# SliTaz package receipt. + +PACKAGE="bootchart" +VERSION="0.9" +CATEGORY="misc" +SHORT_DESC="boot process performance analyzer (add init=/sbin/bootchartd to boot options)" +MAINTAINER="jozee@slitaz.org" +SUGGESTED="pybootchartgui" +TARBALL="$PACKAGE-$VERSION.tar.bz2" +WEB_SITE="http://www.bootchart.org/" +WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL" + + + +# Rules to gen a SliTaz package suitable for Tazpkg. +genpkg_rules() +{ + mkdir -p $fs/sbin $fs/etc + cp -a $src/script/bootchartd $fs/sbin/bootchartd + cp -a $src/script/bootchartd.conf $fs/etc + sed -i "s/SAMPLE_PERIOD=0.2/SAMPLE_PERIOD=1/" $fs/etc/bootchartd.conf + sed -i "s/kdm_greet/kdm_greet slim /" $fs/sbin/bootchartd + sed -i "s|\/usr\/bin\/bootchart|\/usr\/bin\/pybootchartgui|g" $fs/sbin/bootchartd + +} + +post_install() +{ + if [ -f "$1/boot/grub/menu.lst" ]; then + if ! grep -q "vmlinuz-$VERSION-slitaz" $1/boot/grub/menu.lst; then + root_dev=`cat $1/boot/grub/menu.lst | grep root= | sed 's/.*root=\([^ ]*\).*/\1/' | head -n 1` + grub_dev=`cat $1/boot/grub/menu.lst | grep "root.* (" | head -n 1` + # Add new kernel entry in case of upgrade for installed system. + cat >> $1/boot/grub/menu.lst << EOT + +title SliTaz GNU/Linux (Kernel $VERSION-slitaz) with bootchart +$grub_dev + kernel /boot/vmlinuz-$VERSION-slitaz root=$root_dev init=/sbin/bootchartd +EOT + # Display information message. + cat <