wok-current view squirrelmail-quota/receipt @ rev 1860
Udpcast: fix genpkg
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Dec 15 21:38:53 2008 +0000 (2008-12-15) |
parents | |
children | bd6010223726 |
line source
1 # SliTaz package receipt.
3 PACKAGE="squirrelmail-quota"
4 VERSION="2.2-1.4.0"
5 CATEGORY="network"
6 SHORT_DESC="Quota plugin for Web mail."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 SOURCE="check_quota"
9 TARBALL="$SOURCE-$VERSION.tar.gz"
10 WEB_SITE="http://www.squirrelmail.org/"
11 DEPENDS="squirrelmail squirrelmail-compatibility-plugin"
12 WGET_URL="${WEB_SITE}plugins/$TARBALL"
13 CONFIG_FILES="/etc/squirrelmail/config-quota.php"
15 # Rules to gen a SliTaz package suitable for Tazpkg.
16 genpkg_rules()
17 {
18 mkdir -p $fs/usr/share/squirrelmail/plugins $fs/etc/squirrelmail
19 cp -a $SOURCE $fs/usr/share/squirrelmail/plugins
20 mv $fs/usr/share/squirrelmail/plugins/$SOURCE/config.sample.php \
21 $fs/etc/squirrelmail/config-quota.php
22 sed -i "s/settings\['quota_type'\] = 0/settings['quota_type'] = 1/" \
23 $fs/etc/squirrelmail/config-quota.php
24 ln -s /etc/squirrelmail/config-quota.php \
25 $fs/usr/share/squirrelmail/plugins/$SOURCE/config.php
26 }
28 post_install()
29 {
30 ( cd $1/ ; cpio -o -H newc | gzip -9 ) > \
31 $1/$INSTALLED/$PACKAGE/volatile.cpio.gz <<EOT
32 etc/squirrelmail/config-quota.php
33 EOT
34 echo "\$plugins[] = '$SOURCE';" >> $1/etc/squirrelmail/config_local.php
35 }
37 repack_cleanup()
38 {
39 zcat $INSTALLED/$PACKAGE/volatile.cpio.gz | ( cd $1 ; cpio -id )
40 }