wok-next annotate 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 |
rev | line source |
---|---|
al@20534 | 1 # SliTaz package receipt v2. |
pascal@1676 | 2 |
pascal@1676 | 3 PACKAGE="webalizer" |
pascal@20261 | 4 VERSION="2.23-08" |
pascal@1676 | 5 CATEGORY="network" |
al@20534 | 6 SHORT_DESC="Web server log file analysis program" |
pascal@1676 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@15002 | 8 LICENSE="GPL2" |
al@21020 | 9 WEB_SITE="http://www.webalizer.org/" |
al@20534 | 10 |
pascal@1676 | 11 TARBALL="$PACKAGE-$VERSION-src.tar.bz2" |
pascal@1676 | 12 WGET_URL="ftp://ftp.mrunix.net/pub/$PACKAGE/$TARBALL" |
erjo@9923 | 13 |
pascal@20261 | 14 BUILD_DEPENDS="libgd libgd-dev zlib-dev db db-dev libjpeg-turbo" |
erjo@9923 | 15 |
al@20534 | 16 compile_rules() { |
al@20534 | 17 ./configure && |
al@20534 | 18 make && |
al@21020 | 19 make DESTDIR=$install install || return 1 |
pascal@1676 | 20 |
al@20534 | 21 mv $install/etc/webalizer.conf.sample $install/etc/webalizer.conf |
al@20534 | 22 install -Dm755 $stuff/webalizer $install/etc/initcron.d/webalizer |
al@20534 | 23 install -Dd -o80 -g80 $install/var/www/webalizer/ |
pascal@1676 | 24 } |
pascal@1676 | 25 |
al@20534 | 26 genpkg_rules() { |
al@20534 | 27 copy @std |
al@20534 | 28 DEPENDS="libgd zlib db apache" |
al@20534 | 29 TAGS="logs" |
pascal@1676 | 30 } |
pascal@1676 | 31 |
al@20534 | 32 post_install() { |
pascal@18730 | 33 grep -q webalizer "$1/etc/init.d/local.sh" || \ |
pascal@18730 | 34 cat >> "$1/etc/init.d/local.sh" <<EOT |
pascal@1979 | 35 [ -f /var/www/webalizer/index.html ] || /usr/bin/webalizer -o /var/www/webalizer /var/log/apache/access_log |
pascal@1978 | 36 EOT |
al@20534 | 37 |
pascal@1843 | 38 if [ -z "$1" ]; then |
al@20534 | 39 webalizer -o /var/www/webalizer /var/log/apache/access_log |
al@20534 | 40 crontab -l 2>/dev/null | grep -q webalizer || crontab - << EOT |
al@20534 | 41 $(crontab -l 2>/dev/null) |
pascal@1978 | 42 $(cat /etc/initcron.d/webalizer) |
pascal@1843 | 43 EOT |
pascal@1843 | 44 fi |
pascal@1843 | 45 } |