wok-next annotate lighttpd/receipt @ rev 1516

Update some BUILD_DEPENDS
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Oct 07 11:12:02 2008 +0000 (2008-10-07)
parents e53076a6ce3f
children 3a574003f9dd
rev   line source
pankso@24 1 # SliTaz package receipt.
pankso@24 2
pankso@24 3 PACKAGE="lighttpd"
pankso@1095 4 VERSION="1.4.19-1"
pankso@211 5 CATEGORY="network"
pankso@24 6 SHORT_DESC="Fast and light HTTP Web server."
pankso@24 7 MAINTAINER="pankso@slitaz.org"
pankso@639 8 DEPENDS="pcre"
pankso@667 9 BUILD_DEPENDS="pcre-dev bzip2-dev"
pankso@639 10 SUGGESTED="lighttpd-modules php perl python"
pankso@24 11 TARBALL="$PACKAGE-$VERSION.tar.gz"
pankso@24 12 WEB_SITE="http://www.lighttpd.net/"
pankso@1095 13 #WGET_URL="http://www.lighttpd.net/download/$TARBALL"
pankso@1095 14 WGET_URL="http://mirror.slitaz.org/sources/packages/l/$TARBALL"
pascal@1272 15 CONFIG_FILES="/etc/lighttpd/lighttpd.conf /etc/lighttpd/vhosts.conf"
pankso@24 16 BASE_MODULES="
pankso@24 17 access
pankso@24 18 accesslog
pankso@24 19 alias
pankso@24 20 cgi
pankso@24 21 dirlisting
pankso@24 22 indexfile
pankso@24 23 staticfile
pankso@24 24 rewrite
pankso@24 25 status
pankso@24 26 userdir"
pankso@24 27
pankso@24 28 # Rules to configure and make the package.
pankso@24 29 compile_rules()
pankso@24 30 {
pankso@24 31 cd $src
pascal@1516 32 if [ ! done.fastcgi_detach.patch ]; then
pascal@1516 33 patch -i ../stuff/fastcgi_detach.patch || exit 1
pascal@1516 34 touch done.fastcgi_detach.patch
pascal@1516 35 fi
pankso@639 36 ./configure \
pankso@639 37 --enable-shared \
pankso@639 38 --disable-ipv6 \
pankso@639 39 --prefix=/usr \
pankso@639 40 --libdir=/usr/lib/lighttpd \
pankso@639 41 --mandir=/usr/share/man \
pascal@1516 42 $CONFIGURE_ARGS &&
pascal@1516 43 make &&
pankso@24 44 make DESTDIR=$PWD/_pkg install
pankso@24 45 }
pankso@24 46
pankso@24 47 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@24 48 # On SliTaz Lighttpd runs as user/group : www/www or 80/80.
pankso@24 49 genpkg_rules()
pankso@24 50 {
pankso@24 51 mkdir -p $fs/usr
pankso@24 52 cp -a $_pkg/usr/bin $fs/usr
pankso@24 53 cp -a $_pkg/usr/sbin $fs/usr
pankso@24 54
pankso@24 55 # Modules.
pankso@24 56 mkdir -p $fs/usr/lib/lighttpd
pankso@24 57 for module in $BASE_MODULES
pankso@24 58 do
pankso@24 59 cp $_pkg/usr/lib/lighttpd/mod_${module}.so $fs/usr/lib/lighttpd
pankso@24 60 echo -n "Copying : mod_${module}.so" && status
pankso@24 61 done
pankso@24 62 strip -s $fs/usr/bin/*
pankso@24 63 strip -s $fs/usr/sbin/*
pankso@24 64 strip -s $fs/usr/lib/lighttpd/*
pankso@24 65
pankso@24 66 # Server root and config file.
pankso@24 67 cp -a stuff/var $fs
pankso@24 68 cp -a stuff/etc $fs
pankso@119 69 chown -R 0.0 $fs/var/www
pankso@119 70 chown -R 0.0 $fs/etc
pankso@24 71
pankso@24 72 # Logs directory.
pankso@24 73 mkdir -p $fs/var/log/lighttpd
pankso@24 74 chown 80.80 $fs/var/log/lighttpd
pankso@24 75 }
pankso@24 76
pankso@24 77 # Pre and post install commands for Tazpkg.
pankso@24 78 # We stop the server by default in case of upgarde.
pankso@24 79 pre_install()
pankso@24 80 {
pankso@24 81 echo "Processing pre-install commands..."
pascal@1204 82 [ -f /etc/init.d/$PACKAGE ] && /etc/init.d/$PACKAGE stop
pankso@24 83 }
pankso@24 84 post_install()
pankso@24 85 {
pankso@127 86 local root
pankso@127 87 root=$1
pankso@24 88 echo "Processing post-install commands..."
pankso@24 89 # Just in case.
pankso@24 90 chown www.www $root/var/log/$PACKAGE
pankso@24 91 /etc/init.d/$PACKAGE start
pankso@24 92 }