wok-current view postfixadmin/receipt @ rev 20973
updated glew again (1.5.8 -> 2.1.0)
author | Hans-G?nter Theisgen |
---|---|
date | Tue Mar 05 16:37:40 2019 +0100 (2019-03-05) |
parents | 51a1ebbda768 |
children | 9560550c6164 |
line source
1 # SliTaz package receipt.
3 PACKAGE="postfixadmin"
4 VERSION="2.3.5"
5 CATEGORY="network"
6 SHORT_DESC="Postfix web administration."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://postfixadmin.sourceforge.net/"
11 WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL"
12 DEPENDS="php php-mysqli php-imap postfix mysql_or_postgresql"
14 # Rules to configure and make the package.
15 compile_rules()
16 {
17 cd $src
18 }
20 # Rules to gen a SliTaz package suitable for Tazpkg.
21 genpkg_rules()
22 {
23 mkdir -p $fs/usr/share/postfixadmin \
24 $fs/etc/postfixadmin \
25 $fs/usr/share/doc/postfixadmin \
26 $fs/usr/lib/postfixadmin
28 cp -a $src/* $fs/usr/share/postfixadmin/
29 mv $fs/usr/share/postfixadmin/config.inc.php $fs/etc/postfixadmin
30 ln -s /etc/postfixadmin/config.inc.php $fs/usr/share/postfixadmin/config.inc.php
31 sed -i 's/false/true/' $fs/etc/postfixadmin/config.inc.php
33 # Remove unwanted files
34 rm -rf $fs/usr/share/postfixadmin/debian
36 # Move docs
37 mv $fs/usr/share/postfixadmin/*.TXT $fs/usr/share/doc/postfixadmin
38 mv $fs/usr/share/postfixadmin/DOCUMENTS $fs/usr/share/doc/postfixadmin
39 mv $fs/usr/share/postfixadmin/ADDITIONS/* $fs/usr/lib/postfixadmin
40 mv $fs/usr/share/postfixadmin/VIRTUAL_VACATION/*.pl $fs/usr/lib/postfixadmin
41 mv $fs/usr/share/postfixadmin/VIRTUAL_VACATION/ $fs/usr/share/doc/postfixadmin
43 rm -rf $fs/usr/share/postfixadmin/ADDITIONS
45 # Fix group
46 chown -R root.root $fs/usr/share/postfixadmin/
47 }
49 post_install()
50 {
51 # Configure lighttpd server
52 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then
53 if ! grep -q /usr/share/postfixadmin/ "$1/etc/lighttpd/lighttpd.conf"; then
54 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/postfixadmin/" => "/usr/share/postfixadmin/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
55 if [ -z "$1" ]; then
56 # Start Web server.
57 /etc/init.d/lighttpd stop
58 /etc/init.d/lighttpd start
59 fi
60 fi
61 fi
62 # Configure apache server
63 if [ -f "$1/etc/apache/httpd.conf" ]; then
64 if [ ! -f "$1/etc/apache/conf.d/postfixadmin" ]; then
65 cat > "$1/etc/apache/conf.d/postfixadmin" <<EOT
66 <IfModule mod_alias.c>
67 Alias /postfixadmin /usr/share/postfixadmin
68 </IfModule>
69 <DirectoryMatch /usr/share/postfixadmin/>
70 DirectoryIndex index.php
71 Options +FollowSymLinks
72 AllowOverride None
73 Order allow,deny
74 Allow from all
75 </DirectoryMatch>
76 EOT
77 if [ -z "$1" ]; then
78 # Start Web server.
79 /etc/init.d/apache stop
80 /etc/init.d/apache start
81 fi
82 fi
83 fi
84 }