wok-next view webalizer/receipt @ rev 21020

Cleaning is almost finished... I should proceed to upgrades.
author Aleksej Bobylev <al.bobylev@gmail.com>
date Fri Nov 02 14:15:08 2018 +0200 (2018-11-02)
parents 757d032c55c7
children
line source
1 # SliTaz package receipt v2.
3 PACKAGE="webalizer"
4 VERSION="2.23-08"
5 CATEGORY="network"
6 SHORT_DESC="Web server log file analysis program"
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="http://www.webalizer.org/"
11 TARBALL="$PACKAGE-$VERSION-src.tar.bz2"
12 WGET_URL="ftp://ftp.mrunix.net/pub/$PACKAGE/$TARBALL"
14 BUILD_DEPENDS="libgd libgd-dev zlib-dev db db-dev libjpeg-turbo"
16 compile_rules() {
17 ./configure &&
18 make &&
19 make DESTDIR=$install install || return 1
21 mv $install/etc/webalizer.conf.sample $install/etc/webalizer.conf
22 install -Dm755 $stuff/webalizer $install/etc/initcron.d/webalizer
23 install -Dd -o80 -g80 $install/var/www/webalizer/
24 }
26 genpkg_rules() {
27 copy @std
28 DEPENDS="libgd zlib db apache"
29 TAGS="logs"
30 }
32 post_install() {
33 grep -q webalizer "$1/etc/init.d/local.sh" || \
34 cat >> "$1/etc/init.d/local.sh" <<EOT
35 [ -f /var/www/webalizer/index.html ] || /usr/bin/webalizer -o /var/www/webalizer /var/log/apache/access_log
36 EOT
38 if [ -z "$1" ]; then
39 webalizer -o /var/www/webalizer /var/log/apache/access_log
40 crontab -l 2>/dev/null | grep -q webalizer || crontab - << EOT
41 $(crontab -l 2>/dev/null)
42 $(cat /etc/initcron.d/webalizer)
43 EOT
44 fi
45 }