wok-4.x annotate slim/receipt @ rev 8615

Fix: replace exit 1 by return 1 in receipts (exit broke cook-list function)
author Antoine Bodin <gokhlayeh@slitaz.org>
date Mon Feb 14 19:09:46 2011 +0100 (2011-02-14)
parents cc070e9ce1b8
children 4a193c62c501
rev   line source
pankso@263 1 # SliTaz package receipt.
pankso@263 2
pankso@263 3 PACKAGE="slim"
rcx@6055 4 VERSION="1.3.2"
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@4052 8 DEPENDS="glibc-base gcc-lib-base expat fontconfig freetype util-linux-ng-uuid zlib \
rcx@3726 9 jpeg libpng xorg-libICE xorg-libSM xorg-libX11 xorg-libXau xorg-libXdmcp \
rcx@3726 10 xorg-libXext xorg-libXft xorg-libXmu xorg-libXrender xorg-libXt"
rcx@6055 11 BUILD_DEPENDS="xorg-dev jpeg-dev libpng-dev xorg-libXft-dev \
slaxemulator@5371 12 zlib-dev freetype-dev fontconfig-dev"
pankso@2838 13 SUGGESTED="slim-theme-default slitaz-configs"
pankso@263 14 TARBALL="$PACKAGE-$VERSION.tar.gz"
pankso@263 15 WEB_SITE="http://slim.berlios.de"
pankso@263 16 WGET_URL="http://download.berlios.de/slim/$TARBALL"
pascal@1212 17 CONFIG_FILES="/etc/slim.conf"
pascal@1778 18 BUGS="Sometime needs more than 10 seconds to start (since HAL/DCOP addition)."
pankso@263 19
pankso@263 20 # Rules to configure and make the package.
pankso@263 21 compile_rules()
pankso@263 22 {
pankso@263 23 cd $src
gokhlayeh@8615 24 patch -p1 < ../stuff/NoPwdForCmd.patch || return 1
rcx@6055 25 make &&
rcx@6055 26 make DESTDIR=$src/_pkg install
pankso@263 27 }
pankso@263 28
pankso@263 29 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@263 30 genpkg_rules()
pankso@263 31 {
rcx@6055 32 mkdir -p $fs/usr/share/slim
pankso@2862 33 cp -a stuff/themes $fs/usr/share/slim
rcx@6055 34 cp -a $_pkg/usr/bin $fs/usr
rcx@6055 35
pankso@2838 36 # Config file and rc script.
pankso@263 37 cp -a stuff/etc $fs
pankso@1090 38 chown -R root.root $fs
pankso@263 39 }
pankso@263 40
pankso@3000 41 pre_install()
pankso@2053 42 {
pankso@2053 43 local root
pankso@2053 44 root=$1
pankso@2053 45 # Backup config file.
pankso@2053 46 if [ -f $root/etc/slim.conf ]; then
pankso@2053 47 cp $root/etc/slim.conf $root/etc/slim.conf.bak
pankso@2053 48 fi
pankso@2053 49 }
pankso@2053 50
pascal@1062 51 post_install()
pascal@1062 52 {
pankso@2053 53 local root
pankso@2053 54 root=$1
pankso@2053 55 # Restore original config.
pankso@2053 56 if [ -f $root/etc/slim.conf.bak ]; then
pankso@2053 57 mv -f $root/etc/slim.conf.bak $root/etc/slim.conf
pankso@2053 58 fi
pascal@1784 59 local USER
pascal@1784 60 USER=$(awk -F: '/:1000:1000:/ { print $1 }' < $1/etc/passwd)
pascal@1784 61 [ -n "$USER" ] &&
pascal@1784 62 sed -i s/"default_user .*"/"default_user $USER"/ $1/etc/slim.conf
pascal@1062 63 }