SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "tiptop"

# SliTaz package receipt.

PACKAGE="tiptop"
VERSION="2.3.1"
CATEGORY="utilities"
SHORT_DESC="A performance monitoring tool for Linux."
MAINTAINER="paul@slitaz.org"
LICENSE="GPL2"
WEB_SITE="https://github.com/FeCastle/tiptop"

TARBALL="$PACKAGE-$VERSION.tar.gz"
WGET_URL="https://files.inria.fr/pacap/tiptop/$TARBALL"

DEPENDS="libxml2 ncurses"
BUILD_DEPENDS="bison flex libxml2-dev m4 ncurses-dev"

# What is the latest version available today?
current_version()
{
    wget -O - https://raw.githubusercontent.com/FeCastle/tiptop/master/configure.ac 2>/dev/null | \
    sed '/AC_INIT/!d;s|.*.tiptop., .||;s|].*||;q'
}

# Rules to configure and make the package.
compile_rules()
{
    ./configure --prefix=/usr &&
    make &&
    make install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    mkdir -p $fs/usr
    mkdir -p $fs/etc/skel

    cp -a $install/usr/bin    $fs/usr
    cp -a $src/tiptoprc    $fs/etc/skel/.tiptoprc
}

post_install()
{
    for i in $(ls "$1/home" 2> /dev/null)
      do
        [ -f "$1/home/$i/.tiptoprc" ] && continue
        cp "$1/etc/skel/.tiptoprc" "$1/home/$i"
        chroot "$1/" chown $(stat -c "%u.%g" "$1/home/$i") "/home/$i/.tiptoprc"
      done
}

post_remove()
{
    rm -f "$1"/home/*/.tiptoprc
}
6025 packages and 203154 files in current database (Thu Apr 25 06:17:47 2024)