wok-current annotate privoxy/receipt @ rev 14151
syslinux/isohybrid.exe: lseek fix
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Mar 04 10:03:54 2013 +0100 (2013-03-04) |
parents | 7b13b3b4b836 |
children | 51a1ebbda768 |
rev | line source |
---|---|
paul@2275 | 1 # SliTaz package receipt. |
paul@2275 | 2 |
paul@2275 | 3 PACKAGE="privoxy" |
paul@11618 | 4 VERSION="3.0.19-stable" |
paul@2275 | 5 CATEGORY="network" |
paul@2275 | 6 SHORT_DESC="Non-caching web privacy proxy." |
paul@2275 | 7 MAINTAINER="paul@slitaz.org" |
pascal@2456 | 8 DEPENDS="zlib pcre" |
paul@2275 | 9 BUILD_DEPENDS="zlib-dev autoconf perl m4 coreutils" |
paul@2275 | 10 TARBALL="$PACKAGE-$VERSION-src.tar.gz" |
paul@2275 | 11 WEB_SITE="http://www.privoxy.org/" |
paul@2275 | 12 WGET_URL="http://downloads.sourceforge.net/ijbswa/$TARBALL" |
paul@2275 | 13 |
paul@2275 | 14 # Rules to configure and make the package. |
paul@2275 | 15 compile_rules() |
paul@2275 | 16 { |
paul@2275 | 17 # Have to create privoxy user/group to be able to compile |
slaxemulator@8011 | 18 adduser -s /bin/false -H -D -u 42 privoxy |
slaxemulator@9383 | 19 addgroup -g 42 privoxy |
erjo@5885 | 20 |
paul@2275 | 21 cd $src |
paul@2275 | 22 |
paul@2275 | 23 # Needs autoconf |
paul@2275 | 24 autoheader |
paul@2275 | 25 autoconf |
paul@2275 | 26 |
paul@2275 | 27 ./configure \ |
paul@2275 | 28 --prefix=/usr \ |
paul@2275 | 29 --sysconfdir=/etc/privoxy \ |
paul@2275 | 30 --infodir=/usr/share/info \ |
paul@2275 | 31 --mandir=/usr/share/man \ |
pascal@4211 | 32 --localstatedir=/var \ |
pascal@2456 | 33 $CONFIGURE_ARGS && |
paul@7247 | 34 make && make DESTDIR=$PWD/_pkg install |
paul@2275 | 35 } |
paul@2275 | 36 |
paul@2275 | 37 # Rules to gen a SliTaz package suitable for Tazpkg. |
paul@2275 | 38 genpkg_rules() |
paul@2275 | 39 { |
paul@4836 | 40 mkdir -p $fs/etc/init.d $fs/usr |
paul@4373 | 41 cp -a $_pkg/usr/sbin $fs/usr |
paul@4836 | 42 cp -a $_pkg/var $fs |
paul@4836 | 43 cp -a $_pkg/etc $fs |
paul@2275 | 44 |
slaxemulator@9701 | 45 # Copy daemon from stuff |
slaxemulator@9701 | 46 cp $stuff/daemon-privoxy $fs/etc/init.d/privoxy |
paul@2275 | 47 } |
paul@2275 | 48 |
paul@7279 | 49 post_install() |
paul@2275 | 50 { |
paul@7247 | 51 # adduser privoxy if needed |
paul@7247 | 52 if ! grep -q privoxy $1/etc/passwd; then |
paul@7247 | 53 echo -n "Adding user privoxy..." |
slaxemulator@8011 | 54 chroot $1/ adduser -s /bin/false -H -D -u 42 privoxy |
paul@7247 | 55 status |
paul@7247 | 56 fi |
paul@7279 | 57 |
slaxemulator@9383 | 58 if ! grep -q privoxy $1/etc/group; then |
slaxemulator@9383 | 59 echo -n "Adding group privoxy..." |
slaxemulator@9383 | 60 chroot $1/ addgroup -g 42 privoxy |
slaxemulator@9383 | 61 status |
slaxemulator@9383 | 62 fi |
slaxemulator@9383 | 63 |
paul@7279 | 64 # and change file permissions |
paul@7279 | 65 echo -n "Changing file permissions..." |
slaxemulator@9383 | 66 chown -R privoxy.privoxy $1/etc/privoxy |
paul@7279 | 67 chown -R root.root $1/etc/privoxy/templates |
paul@7279 | 68 chown root.root $1/etc/privoxy |
slaxemulator@9383 | 69 chown privoxy.privoxy $1/var/log/privoxy/logfile |
paul@7279 | 70 status |
paul@2275 | 71 } |
paul@7247 | 72 |
paul@7247 | 73 # Del user privoxy when pkg is removed. |
paul@7247 | 74 post_remove() |
paul@7247 | 75 { |
paul@7247 | 76 deluser privoxy |
slaxemulator@9383 | 77 delgroup privoxy |
paul@7247 | 78 } |