wok-6.x view slim-pam/receipt @ rev 16052
clamav: update genpkg_rules
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Mar 10 15:33:31 2014 +0000 (2014-03-10) |
parents | 77143f213b9b |
children | 9e01bc6321ea |
line source
1 # SliTaz package receipt.
3 PACKAGE="slim-pam"
4 VERSION="1.3.5"
5 CATEGORY="x-window"
6 SHORT_DESC="Desktop-independent graphical login manager for X11 (PAM enabled)."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="http://slim.berlios.de/"
10 SOURCE="slim"
11 TARBALL="$SOURCE-$VERSION.tar.gz"
12 WGET_URL="http://download.berlios.de/slim/$TARBALL"
13 CONFIG_FILES="/etc/slim.conf"
15 PROVIDE="slim:pam"
16 DEPENDS="gcc-lib-base libjpeg libpng pam xorg-libXft xorg-libXmu"
17 SUGGESTED="slim-theme-default slitaz-configs"
18 BUILD_DEPENDS="cmake freetype-dev jpeg-dev libpng-dev xorg-libXft-dev \
19 xorg-libXmu-dev pam-dev"
20 RELATED="slim slim-theme-default"
22 # Rules to configure and make the package.
23 compile_rules()
24 {
25 patch -p1 < $WOK/$SOURCE/stuff/$SOURCE-$VERSION.patch || return 1
26 mkdir build; cd build
27 cmake \
28 -DCMAKE_INSTALL_PREFIX=/usr \
29 -DX11_Xmu_LIB=-lXmu \
30 -DUSE_PAM=yes \
31 .. &&
32 make &&
33 make DESTDIR=$DESTDIR install
34 }
36 # Rules to gen a SliTaz package suitable for Tazpkg.
37 genpkg_rules()
38 {
39 mkdir -p $fs/usr/share/slim
40 cp -a $install/etc $fs
41 cp -a $install/usr/bin $fs/usr
42 cp -a $WOK/$SOURCE/stuff/themes $fs/usr/share/slim
44 # Config file and rc script.
45 cp -a $WOK/$SOURCE/stuff/etc $fs
46 chown -R root.root $fs
48 # slim-theme manager
49 install -m755 $WOK/$SOURCE/stuff/slim-theme $fs/usr/bin/slim-theme
50 }
52 post_install()
53 {
54 local USER
55 USER=$(awk -F: '/:1000:1000:/ { print $1 }' < $1/etc/passwd)
56 [ -n "$USER" ] &&
57 sed -i s/"default_user .*"/"default_user $USER"/ $1/etc/slim.conf
59 # In order to update the SLiM, we need to restart it.
60 # We can't just "/etc/init.d/slim restart" because it momentarily interrupts
61 # X session and the user will get a terrible console with strange letters.
62 printf '%40s\n' | tr ' ' '='
63 echo "In order to update the SLiM,"
64 echo "please, reboot your system!"
65 }
67 pre_remove()
68 {
69 tazpkg get-install ${PACKAGE%-pam}
70 }