wok-current view phproxy/receipt @ rev 21537

updated neon and neon-dev (0.29.3 -> 0.30.2)
author Hans-G?nter Theisgen
date Sun May 05 14:32:35 2019 +0100 (2019-05-05)
parents 775714eeb4c8
children 15650f5d595b
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="https://sebsauvage.net/wiki/doku.php?id=phproxy"
11 TARBALL="$SOURCE%20$VERSION%20mod%20SSE+ARKA%2020100825.7z"
12 WGET_URL="https://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 dos2unix *
22 mkdir -p $DESTDIR/usr/share/$PACKAGE
23 cp *.php *.css $DESTDIR/usr/share/$PACKAGE
24 }
26 # Rules to gen a SliTaz package suitable for Tazpkg.
27 genpkg_rules()
28 {
29 cp -a $install/* $fs
30 }
32 post_install()
33 {
34 # Configure lighttpd server
35 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then
36 if ! grep -q /usr/share/phproxy/ "$1/etc/lighttpd/lighttpd.conf"; then
37 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/phproxy/" => "/usr/share/phproxy/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
38 if [ -z "$1" ]; then
39 # Start Web server.
40 /etc/init.d/lighttpd stop
41 /etc/init.d/lighttpd start
42 fi
43 fi
44 fi
45 # Configure apache server
46 if [ -f "$1/etc/apache/httpd.conf" ]; then
47 if [ ! -f "$1/etc/apache/conf.d/phproxy" ]; then
48 cat > "$1/etc/apache/conf.d/phproxy" <<EOT
49 <IfModule mod_alias.c>
50 Alias /phproxy /usr/share/phproxy
51 </IfModule>
52 <Directory /usr/share/phproxy/>
53 DirectoryIndex index.php
54 Options +FollowSymLinks
55 AllowOverride None
56 Order allow,deny
57 Allow from all
58 </Directory>
59 EOT
60 if [ -z "$1" ]; then
61 # Start Web server.
62 /etc/init.d/apache stop
63 /etc/init.d/apache start
64 fi
65 fi
66 fi
67 }