wok view phproxy/receipt @ rev 16849

netsurf: partially undo prev.commit: add perl parser due to log
author Xander Ziiryanoff <psychomaniak@xakep.ru>
date Sun Jul 13 02:17:24 2014 +0300 (2014-07-13)
parents d51b2411e55e
children 9e01bc6321ea
line source
1 # SliTaz package receipt.
3 PACKAGE="phproxy"
4 SOURCE="PHProxy"
5 VERSION="0.5b2"
6 CATEGORY="network"
7 SHORT_DESC="A proxy HTTP."
8 MAINTAINER="pascal.bellard@slitaz.org"
9 LICENSE="GPL2"
10 WEB_SITE="http://sebsauvage.net/wiki/doku.php?id=phproxy"
11 TARBALL="$SOURCE%20$VERSION%20mod%20SSE+ARKA%2020100825.7z"
12 WGET_URL="http://sebsauvage.net/temp/$TARBALL"
13 #HOST_ARCH="any"
15 DEPENDS="php"
16 BUILD_DEPENDS="p7zip"
18 # Rules to configure and make the package.
19 compile_rules()
20 {
21 cd $src
22 7zr x $TARBALL
23 cd $SOURCE\ *
24 dos2unix *
25 mkdir -p $DESTDIR/usr/share/$PACKAGE
26 cp *.php *.css $DESTDIR/usr/share/$PACKAGE
27 }
29 # Rules to gen a SliTaz package suitable for Tazpkg.
30 genpkg_rules()
31 {
32 cp -a $install/* $fs
33 }
35 post_install()
36 {
37 # Configure lighttpd server
38 if [ -f $1/etc/lighttpd/lighttpd.conf ]; then
39 if ! grep -q /usr/share/phproxy/ $1/etc/lighttpd/lighttpd.conf; then
40 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/phproxy/" => "/usr/share/phproxy/",|g' -i $1/etc/lighttpd/lighttpd.conf
41 if [ -z "$1" ]; then
42 # Start Web server.
43 /etc/init.d/lighttpd stop
44 /etc/init.d/lighttpd start
45 fi
46 fi
47 fi
48 # Configure apache server
49 if [ -f $1/etc/apache/httpd.conf ]; then
50 if [ ! -f $1/etc/apache/conf.d/phproxy ]; then
51 cat > $1/etc/apache/conf.d/phproxy <<EOT
52 <IfModule mod_alias.c>
53 Alias /phproxy /usr/share/phproxy
54 </IfModule>
55 <Directory /usr/share/phproxy/>
56 DirectoryIndex index.php
57 Options +FollowSymLinks
58 AllowOverride None
59 Order allow,deny
60 Allow from all
61 </Directory>
62 EOT
63 if [ -z "$1" ]; then
64 # Start Web server.
65 /etc/init.d/apache stop
66 /etc/init.d/apache start
67 fi
68 fi
69 fi
70 }