wok-next annotate slim-pam/receipt @ rev 3192

Add: imlib
author Matthew Sheets <rcx@zoominternet.net>
date Tue May 26 13:24:34 2009 +0000 (2009-05-26)
parents
children 996a788dda09
rev   line source
pascal@2223 1 # SliTaz package receipt.
pascal@2223 2
pascal@2223 3 PACKAGE="slim-pam"
pascal@2223 4 VERSION="1.3.1"
pascal@2223 5 CATEGORY="x-window"
pascal@2223 6 SHORT_DESC="Desktop-independent graphical login manager for X11."
pascal@2223 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@2223 8 DEPENDS="xorg jpeg libpng slitaz-configs pam"
pascal@2223 9 BUILD_DEPENDS="xorg-dev jpeg-dev libpng-dev xorg-libXft-dev pam pam-dev"
pascal@2223 10 SOURCE="slim"
pascal@2223 11 TARBALL="$SOURCE-$VERSION.tar.gz"
pascal@2223 12 WEB_SITE="http://slim.berlios.de"
pascal@2223 13 WGET_URL="http://download.berlios.de/slim/$TARBALL"
pascal@2223 14 CONFIG_FILES="/etc/slim.conf"
pascal@2223 15 PROVIDE="slim:pam"
pascal@2223 16 BUGS="Sometime needs more than 10 seconds to start (since HAL/DCOP addition)."
pascal@2223 17
pascal@2223 18 # Rules to configure and make the package.
pascal@2223 19 compile_rules()
pascal@2223 20 {
pascal@2223 21 cd $src
pascal@2223 22 sed -i "s|/usr/X11R6/include|/usr/include/xorg|g" Makefile
pascal@2223 23 sed -i "s|/usr/X11R6/|/usr/|g" Makefile
pascal@2223 24 make USE_PAM=1
pascal@2223 25 }
pascal@2223 26
pascal@2223 27 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@2223 28 genpkg_rules()
pascal@2223 29 {
pascal@2223 30 mkdir -p $fs/usr/bin $fs/usr/share/slim
pascal@2223 31 cp -a $src/slim $fs/usr/bin
pascal@2223 32
pascal@2223 33 # Config file and rc script (theme is in slitaz-configs).
pascal@2223 34 cp -a ../$SOURCE/stuff/etc $fs
pascal@2223 35 chown -R root.root $fs
pascal@2223 36 }
pascal@2223 37
pascal@2223 38 pre_instal()
pascal@2223 39 {
pascal@2223 40 local root
pascal@2223 41 root=$1
pascal@2223 42 # Backup config file.
pascal@2223 43 if [ -f $root/etc/slim.conf ]; then
pascal@2223 44 cp $root/etc/slim.conf $root/etc/slim.conf.bak
pascal@2223 45 fi
pascal@2223 46 }
pascal@2223 47
pascal@2223 48 post_install()
pascal@2223 49 {
pascal@2223 50 local root
pascal@2223 51 root=$1
pascal@2223 52 # Restore original config.
pascal@2223 53 if [ -f $root/etc/slim.conf.bak ]; then
pascal@2223 54 mv -f $root/etc/slim.conf.bak $root/etc/slim.conf
pascal@2223 55 fi
pascal@2223 56 local USER
pascal@2223 57 USER=$(awk -F: '/:1000:1000:/ { print $1 }' < $1/etc/passwd)
pascal@2223 58 [ -n "$USER" ] &&
pascal@2223 59 sed -i s/"default_user .*"/"default_user $USER"/ $1/etc/slim.conf
pascal@2223 60 }