wok-current view squirrelmail-ldapuser/receipt @ rev 11308

Fix: remove some unneeded xfburn depends
author Alexander Medvedev <devl547@gmail.com>
date Sun Nov 13 11:09:54 2011 +0000 (2011-11-13)
parents f81e47267992
children b13ed9740841
line source
1 # SliTaz package receipt.
3 PACKAGE="squirrelmail-ldapuser"
4 VERSION="0.4"
5 CATEGORY="network"
6 SHORT_DESC="LDAP backend for Web mail users' profile/preferences."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 SOURCE="ldapuserdata"
9 TARBALL="$SOURCE-$VERSION.tar.gz"
10 WEB_SITE="http://www.squirrelmail.org/"
11 DEPENDS="squirrelmail openldap"
12 WGET_URL="${WEB_SITE}plugins/$TARBALL"
13 CONFIG_FILES="/etc/squirrelmail/config-$SOURCE.php"
15 # Rules to configure and make the package.
16 compile_rules()
17 {
18 mkdir -p $DESTDIR
19 cp -a $src $DESTDIR/$SOURCE
20 }
22 # Rules to gen a SliTaz package suitable for Tazpkg.
23 genpkg_rules()
24 {
25 mkdir -p $fs/usr/share/squirrelmail/plugins $fs/etc/squirrelmail
26 cp -a $_pkg/$SOURCE $fs/usr/share/squirrelmail/plugins
27 mv $fs/usr/share/squirrelmail/plugins/$SOURCE/config_sample.php \
28 $fs/etc/squirrelmail/config-$SOURCE.php
29 ln -s /etc/squirrelmail/config-$SOURCE.php \
30 $fs/usr/share/squirrelmail/plugins/$SOURCE/config.php
31 }
33 post_install()
34 {
35 echo "\$plugins[] = '$SOURCE';" >> $1/etc/squirrelmail/config_local.php
36 mv $1/usr/share/squirrelmail/functions/file_prefs.php \
37 $1/usr/share/squirrelmail/functions/file_prefs.php.original
38 ln -s ../plugins/ldapuserdata/file_prefs.php \
39 $1/usr/share/squirrelmail/functions/file_prefs.php
40 cat >> $1/etc/openldap/slapd.conf <<EOT
41 include /usr/share/squirrelmail/plugins/$SOURCE/doc/squirrelmail.schema
42 EOT
43 }
45 pre_remove()
46 {
47 sed -i "/\$plugins.. = '$SOURCE';/d" /etc/squirrelmail/config_local.php
48 sed -i "/plugins.$SOURCE.doc/d" /etc/openldap/slapd.conf
49 rm -f /usr/share/squirrelmail/functions/file_prefs.php
50 mv /usr/share/squirrelmail/functions/file_prefs.php.original \
51 /usr/share/squirrelmail/functions/file_prefs.php
52 }