wok-6.x annotate slim-pam/receipt @ rev 4193
openmotif: update BUILD_DEPENDS
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Sep 23 16:16:08 2009 +0200 (2009-09-23) |
parents | 0088f0af4413 |
children | 09d47b216378 |
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 |
pankso@3815 | 22 patch -p0 < ../../slim/stuff/gcc44.patch || exit 1 |
pascal@2223 | 23 sed -i "s|/usr/X11R6/include|/usr/include/xorg|g" Makefile |
pascal@2223 | 24 sed -i "s|/usr/X11R6/|/usr/|g" Makefile |
pascal@2223 | 25 make USE_PAM=1 |
pascal@2223 | 26 } |
pascal@2223 | 27 |
pascal@2223 | 28 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@2223 | 29 genpkg_rules() |
pascal@2223 | 30 { |
pascal@2223 | 31 mkdir -p $fs/usr/bin $fs/usr/share/slim |
pascal@2223 | 32 cp -a $src/slim $fs/usr/bin |
pankso@3815 | 33 |
pascal@2223 | 34 # Config file and rc script (theme is in slitaz-configs). |
pascal@2223 | 35 cp -a ../$SOURCE/stuff/etc $fs |
pascal@2223 | 36 chown -R root.root $fs |
pascal@2223 | 37 } |
pascal@2223 | 38 |
pascal@2223 | 39 pre_instal() |
pascal@2223 | 40 { |
pascal@2223 | 41 local root |
pascal@2223 | 42 root=$1 |
pascal@2223 | 43 # Backup config file. |
pascal@2223 | 44 if [ -f $root/etc/slim.conf ]; then |
pascal@2223 | 45 cp $root/etc/slim.conf $root/etc/slim.conf.bak |
pascal@2223 | 46 fi |
pascal@2223 | 47 } |
pascal@2223 | 48 |
pascal@2223 | 49 post_install() |
pascal@2223 | 50 { |
pascal@2223 | 51 local root |
pascal@2223 | 52 root=$1 |
pascal@2223 | 53 # Restore original config. |
pascal@2223 | 54 if [ -f $root/etc/slim.conf.bak ]; then |
pascal@2223 | 55 mv -f $root/etc/slim.conf.bak $root/etc/slim.conf |
pascal@2223 | 56 fi |
pascal@2223 | 57 local USER |
pascal@2223 | 58 USER=$(awk -F: '/:1000:1000:/ { print $1 }' < $1/etc/passwd) |
pascal@2223 | 59 [ -n "$USER" ] && |
pascal@2223 | 60 sed -i s/"default_user .*"/"default_user $USER"/ $1/etc/slim.conf |
pascal@2223 | 61 } |