SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "slim-pam"

# SliTaz package receipt.

PACKAGE="slim-pam"
VERSION="1.3.2"
CATEGORY="x-window"
SHORT_DESC="Desktop-independent graphical login manager for X11."
MAINTAINER="pascal.bellard@slitaz.org"
SUGGESTED="slim-theme-default slitaz-configs"
SOURCE="slim"
TARBALL="$SOURCE-$VERSION.tar.gz"
WEB_SITE="http://slim.berlios.de"
WGET_URL="http://download.berlios.de/slim/$TARBALL"
CONFIG_FILES="/etc/slim.conf"
PROVIDE="slim:pam"
BUGS="Sometime needs more than 10 seconds to start (since HAL/DCOP addition)."

DEPENDS="glibc-base gcc-lib-base expat fontconfig freetype util-linux-ng-uuid zlib \
jpeg libpng xorg-libICE xorg-libSM xorg-libX11 xorg-libXau xorg-libXdmcp \
xorg-libXext xorg-libXft xorg-libXmu xorg-libXrender xorg-libXt \
pam"
BUILD_DEPENDS="pam-dev"

# Rules to configure and make the package.
compile_rules()
{
    cd $src
    make USE_PAM=1 &&
    make install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    mkdir -p $fs/usr/share/slim
    cp -a ../$SOURCE/stuff/themes $fs/usr/share/slim
    cp -a $_pkg/usr/bin $fs/usr
    
    # Config file and rc script.
    cp -a ../$SOURCE/stuff/etc $fs
    chown -R root.root $fs
}

pre_install()
{
    local root
    root=$1
    # Backup config file.
    if [ -f $root/etc/slim.conf ]; then
        cp $root/etc/slim.conf $root/etc/slim.conf.bak
    fi
}

post_install()
{
    local root
    root=$1
    # Restore original config.
    if [ -f $root/etc/slim.conf.bak ]; then
        mv -f $root/etc/slim.conf.bak $root/etc/slim.conf
    fi
    local USER
    USER=$(awk -F: '/:1000:1000:/ { print $1 }' < $1/etc/passwd)
    [ -n "$USER" ] &&
    sed -i s/"default_user .*"/"default_user        $USER"/ $1/etc/slim.conf
}

pre_remove()
{
    tazpkg get-install  ${PACKAGE%-pam}
}
3382 packages and 430813 files in stable database (Mon Mar 4 17:53:49 2019)