wok view privoxy/receipt @ rev 24017

tuxpaint: no parallel make
author Hans-G?nter Theisgen
date Sat Feb 27 15:07:25 2021 +0100 (2021-02-27)
parents 970c5ec9a60a
children 080c1dff8494
line source
1 # SliTaz package receipt.
3 PACKAGE="privoxy"
4 VERSION="3.0.28"
5 CATEGORY="network"
6 SHORT_DESC="Non-caching web privacy proxy."
7 MAINTAINER="paul@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="https://www.privoxy.org/"
11 TARBALL="$PACKAGE-$VERSION-stable-src.tar.gz"
12 WGET_URL="$SF_MIRROR/ijbswa/$TARBALL"
14 DEPENDS="pcre zlib"
15 BUILD_DEPENDS="autoconf coreutils m4 perl zlib-dev"
16 CONFIG_FILES="/etc/privoxy/config"
18 # Rules to configure and make the package.
19 compile_rules()
20 {
21 # Have to create privoxy user/group to be able to compile
22 adduser -s /bin/false -H -D -u 42 privoxy
23 addgroup -g 42 privoxy
25 # Needs autoconf
26 autoheader
27 autoconf
29 ./configure \
30 --prefix=/usr \
31 --sysconfdir=/etc/privoxy \
32 --infodir=/usr/share/info \
33 --mandir=/usr/share/man \
34 --localstatedir=/var \
35 $CONFIGURE_ARGS &&
36 make &&
37 make DESTDIR=$DESTDIR install
38 }
40 # Rules to gen a SliTaz package suitable for Tazpkg.
41 genpkg_rules()
42 {
43 mkdir -p $fs/etc/init.d
44 mkdir -p $fs/usr
46 cp -a $install/usr/sbin $fs/usr
47 cp -a $install/var $fs
48 cp -a $install/etc $fs
50 # Copy daemon from stuff
51 cp $stuff/daemon-privoxy $fs/etc/init.d/privoxy
52 }
54 post_install()
55 {
56 # adduser privoxy if needed
57 if ! grep -q privoxy "$1/etc/passwd"; then
58 echo
59 echo -n "Adding user privoxy..."
60 chroot "$1/" adduser -s /bin/false -H -D -u 42 privoxy
61 status
62 fi
64 if ! grep -q privoxy "$1/etc/group"; then
65 echo
66 echo -n "Adding group privoxy..."
67 chroot "$1/" addgroup -g 42 privoxy
68 status
69 fi
71 # and change file permissions
72 echo
73 echo -n "Changing file permissions..."
74 chroot "$1/" chown -R privoxy.privoxy /etc/privoxy
75 chown -R root.root "$1/etc/privoxy/templates"
76 chown root.root "$1/etc/privoxy"
77 chroot "$1/" chown privoxy.privoxy /var/log/privoxy/logfile
78 status
79 }
81 # Del user privoxy when pkg is removed.
82 post_remove()
83 {
84 deluser privoxy
85 delgroup privoxy
86 }