wok view squidguard/receipt @ rev 1651
Add scim
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Nov 08 13:39:01 2008 +0000 (2008-11-08) |
parents | |
children | bd6010223726 |
line source
1 # SliTaz package receipt.
3 PACKAGE="squidguard"
4 VERSION="1.3"
5 CATEGORY="network"
6 SHORT_DESC="Web filter."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 SOURCE="squidGuard"
9 TARBALL="$SOURCE-$VERSION.tar.gz"
10 WEB_SITE="http://www.squidguard.org/"
11 WGET_URL="${WEB_SITE}Downloads/$TARBALL"
12 DEPENDS="squid libdb"
13 BUILD_DEPENDS="db-dev"
15 # Rules to configure and make the package.
16 compile_rules()
17 {
18 cd $src
19 ./configure --prefix=/usr --infodir=/usr/share/info \
20 --sysconfdir=/etc --with-sg-config=/etc/squid/squidGuard.conf \
21 --with-sg-logdir=/var/lib/squidGuard/log \
22 --with-sg-dbhome=/var/lib/squidGuard/db \
23 --mandir=/usr/share/man $CONFIGURE_ARGS
24 make
25 sed -e 's|^prefix =.*|prefix = _pkg/usr|' \
26 -e 's|^logdir =.*|logdir = _pkg/var/lib/squidGuard/log|' \
27 -e 's|^configfile =.*|configfile = _pkg/etc/squid/squidGuard.conf|' \
28 -e 's|^dbhomedir =.*|dbhomedir = _pkg/var/lib/squidGuard/db|' \
29 -e 's|^SQUIDUSER =.*|SQUIDUSER = root|' \
30 < Makefile > Makefile.slitaz-install
31 mkdir -p _pkg/etc/squid
32 make -f Makefile.slitaz-install install
33 }
35 # Rules to gen a SliTaz package suitable for Tazpkg.
36 genpkg_rules()
37 {
38 cp -a $_pkg/* $fs/
39 }
41 # Pre and post install commands for Tazpkg.
42 post_install()
43 {
44 ( cd $1/ ; cpio -o -H newc | gzip -9 ) > \
45 $1/$INSTALLED/$PACKAGE/volatile.cpio.gz <<EOF
46 etc/squid/squidGuard.conf
47 EOF
48 chown -R nobody /var/lib/squidGuard/* /usr/squidGuard
49 if ! grep ^redirect_program $1/etc/squid/squid.conf ; then
50 echo "Updating /etc/squid/squid.conf"
51 cat >> $1/etc/squid/squid.conf <<EOF
52 redirect_program /usr/bin/squidGuard -c /etc/squid/squidGuard.conf
53 EOF
54 fi
55 }
57 repack_cleanup()
58 {
59 zcat $INSTALLED/$PACKAGE/volatile.cpio.gz | ( cd $1 ; cpio -id )
60 }