wok-next view lighttpd/receipt @ rev 21665

updated freetype (2.9.1 -> 2.10.2)
author Hans-G?nter Theisgen
date Sat Jun 27 15:37:35 2020 +0100 (2020-06-27)
parents d5aab818505e
children
line source
1 # SliTaz package receipt v2.
3 PACKAGE="lighttpd"
4 VERSION="1.4.35"
5 CATEGORY="network"
6 SHORT_DESC="Fast and light HTTP Web server"
7 MAINTAINER="devel@slitaz.org"
8 LICENSE="BSD"
9 WEB_SITE="http://www.lighttpd.net/"
11 TARBALL="$PACKAGE-$VERSION.tar.xz"
12 WGET_URL="http://download.lighttpd.net/lighttpd/releases-${VERSION%.*}.x/$TARBALL"
14 BUILD_DEPENDS="pcre-dev bzip2-dev zlib-dev"
15 SPLIT="$PACKAGE-modules"
17 compile_rules() {
18 sed -i '/addrs_left/d' src/mod_extforward.c
20 ./configure \
21 --enable-shared \
22 --disable-ipv6 \
23 --libdir=/usr/lib/lighttpd \
24 $CONFIGURE_ARGS &&
25 fix libtool &&
26 make &&
27 make DESTDIR=$install install
28 }
30 # On SliTaz Lighttpd runs as user/group : www/www or 80/80.
31 genpkg_rules() {
32 case $PACKAGE in
33 lighttpd)
34 CONFIG_FILES="/etc/lighttpd/vhosts.conf /etc/lighttpd/lighttpd.conf"
35 SUGGESTED="lighttpd-modules php perl python"
36 DEPENDS="libpcre"
37 # Modules include in this package. Other modules are splited in
38 # the lighttpd-modules packages.
39 BASE_MODULES="
40 access
41 accesslog
42 alias
43 cgi
44 dirlisting
45 indexfile
46 staticfile
47 rewrite
48 status
49 userdir"
50 mkdir -p $fs/usr
51 #cp -a $install/usr/bin $fs/usr
52 cp -a $install/usr/sbin $fs/usr
54 # Modules.
55 mkdir -p $fs/usr/lib/lighttpd
56 for module in $BASE_MODULES; do
57 action "Copying: mod_$module.so"
58 cp $install/usr/lib/lighttpd/mod_$module.so $fs/usr/lib/lighttpd
59 status
60 done
62 # Config file.
63 cp -a $stuff/etc $fs
64 chown -R 0.0 $fs/etc
66 # Logs directory.
67 mkdir -p $fs/var/log/lighttpd
68 chown 80.80 $fs/var/log/lighttpd
69 ;;
70 lighttpd-modules)
71 CAT="network|complementary modules"
72 DEPENDS="libbzip2 libpcre zlib lighttpd"
73 BASE_MODULES="
74 access
75 accesslog
76 alias
77 cgi
78 dirlisting
79 indexfile
80 staticfile
81 rewrite
82 status
83 userdir"
84 # Modules.
85 mkdir -p $fs/usr/
86 cp -a $install/usr/lib $fs/usr
87 for module in $BASE_MODULES; do
88 rm -f $fs/usr/lib/lighttpd/mod_$module.so
89 done
90 rm -f $fs/usr/lib/lighttpd/*.la
91 ;;
92 esac
93 }
95 # Make sure it as cross compile properly
96 testsuite() {
97 readelf -h $install/usr/sbin/$PACKAGE
98 }
100 # We stop the server by default in case of upgarde.
101 pre_install_lighttpd() {
102 [ -z "$1" ] &&
103 for i in httpd ngnix apache cherokee lighttpd; do
104 [ -f /etc/init.d/$i ] && /etc/init.d/$i stop
105 done
106 # Backup config file.
107 if [ -d "$1/etc/lighttpd" ]; then
108 cp -a "$1/etc/lighttpd" "$1/etc/lighttpd.bak"
109 fi
110 }
112 post_install_lighttpd() {
113 # Restore original config.
114 if [ -d "$1/etc/lighttpd.bak" ]; then
115 rm -rf "$1/etc/lighttpd"
116 mv "$1/etc/lighttpd.bak" "$1/etc/lighttpd"
117 fi
119 # Just in case.
120 chown www.www "$1/var/log/$PACKAGE"
121 [ -n "$1" ] ||
122 netstat -ltn 2>/dev/null | grep -q :80 ||
123 /etc/init.d/$PACKAGE start
124 }