wok annotate slim/receipt @ rev 2838
slim: Avoid dep on slitaz-configs/GTK and add slim-theme-default
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Thu Apr 30 20:44:27 2009 +0200 (2009-04-30) |
parents | 73f6b06abab1 |
children | 348ab55e5d94 |
rev | line source |
---|---|
pankso@263 | 1 # SliTaz package receipt. |
pankso@263 | 2 |
pankso@263 | 3 PACKAGE="slim" |
pascal@1424 | 4 VERSION="1.3.1" |
pankso@263 | 5 CATEGORY="x-window" |
pankso@263 | 6 SHORT_DESC="Desktop-independent graphical login manager for X11." |
pankso@263 | 7 MAINTAINER="pankso@slitaz.org" |
pankso@2838 | 8 DEPENDS="xorg jpeg libpng" |
pascal@1477 | 9 BUILD_DEPENDS="xorg-dev jpeg-dev libpng-dev xorg-libXft-dev" |
pankso@2838 | 10 SUGGESTED="slim-theme-default slitaz-configs" |
pankso@263 | 11 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pankso@263 | 12 WEB_SITE="http://slim.berlios.de" |
pankso@263 | 13 WGET_URL="http://download.berlios.de/slim/$TARBALL" |
pascal@1212 | 14 CONFIG_FILES="/etc/slim.conf" |
pascal@1778 | 15 BUGS="Sometime needs more than 10 seconds to start (since HAL/DCOP addition)." |
pankso@263 | 16 |
pankso@263 | 17 # Rules to configure and make the package. |
pankso@263 | 18 compile_rules() |
pankso@263 | 19 { |
pankso@263 | 20 cd $src |
pankso@263 | 21 sed -i "s|/usr/X11R6/include|/usr/include/xorg|g" Makefile |
pankso@263 | 22 sed -i "s|/usr/X11R6/|/usr/|g" Makefile |
pankso@263 | 23 make |
pankso@263 | 24 } |
pankso@263 | 25 |
pankso@263 | 26 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@263 | 27 genpkg_rules() |
pankso@263 | 28 { |
pankso@263 | 29 mkdir -p $fs/usr/bin $fs/usr/share/slim |
pankso@263 | 30 cp -a $src/slim $fs/usr/bin |
pankso@2838 | 31 cp -a stuff/themes/base $fs/usr/share/slim |
pankso@2838 | 32 # Config file and rc script. |
pankso@263 | 33 cp -a stuff/etc $fs |
pankso@1090 | 34 chown -R root.root $fs |
pankso@263 | 35 } |
pankso@263 | 36 |
pankso@2053 | 37 pre_instal() |
pankso@2053 | 38 { |
pankso@2053 | 39 local root |
pankso@2053 | 40 root=$1 |
pankso@2053 | 41 # Backup config file. |
pankso@2053 | 42 if [ -f $root/etc/slim.conf ]; then |
pankso@2053 | 43 cp $root/etc/slim.conf $root/etc/slim.conf.bak |
pankso@2053 | 44 fi |
pankso@2053 | 45 } |
pankso@2053 | 46 |
pascal@1062 | 47 post_install() |
pascal@1062 | 48 { |
pankso@2053 | 49 local root |
pankso@2053 | 50 root=$1 |
pankso@2053 | 51 # Restore original config. |
pankso@2053 | 52 if [ -f $root/etc/slim.conf.bak ]; then |
pankso@2053 | 53 mv -f $root/etc/slim.conf.bak $root/etc/slim.conf |
pankso@2053 | 54 fi |
pascal@1784 | 55 local USER |
pascal@1784 | 56 USER=$(awk -F: '/:1000:1000:/ { print $1 }' < $1/etc/passwd) |
pascal@1784 | 57 [ -n "$USER" ] && |
pascal@1784 | 58 sed -i s/"default_user .*"/"default_user $USER"/ $1/etc/slim.conf |
pascal@1062 | 59 } |