wok view pdnsd/receipt @ rev 25194
updated python-html2text (2017.10.4 -> 2019.8.11)
author | Hans-G?nter Theisgen |
---|---|
date | Wed Jul 13 10:52:13 2022 +0100 (2022-07-13) |
parents | b9659e3c2111 |
children |
line source
1 # SliTaz package receipt.
3 PACKAGE="pdnsd"
4 VERSION="1.2.9a"
5 CATEGORY="network"
6 SHORT_DESC="A proxy DNS server with permanent caching."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL3"
9 WEB_SITE="https://web.archive.org/web/20201203080556/members.home.nl/p.a.rombouts/pdnsd/"
10 TARBALL="$PACKAGE-$VERSION-par.tar.gz"
11 WGET_URL="$WEB_SITE/releases/$TARBALL"
12 CONFIG_FILES="/etc/pdnsd.conf"
14 DEPENDS=""
15 BUILD_DEPENDS=""
17 # What is the latest version available today?
18 current_version()
19 {
20 wget -O - https://github.com/kwarunek/pdnsd/tags 2>/dev/null | \
21 sed '/archive.*tar/!d;s|.*/v*\(.*\).tar.*|\1|;q'
22 }
24 # Rules to configure and make the package.
25 compile_rules()
26 {
27 cd $src
28 ./configure --prefix=/usr --sysconfdir=/etc $CONFIGURE_ARGS &&
29 make && make DESTDIR=$DESTDIR install
30 }
32 # Rules to gen a SliTaz package suitable for Tazpkg.
33 genpkg_rules()
34 {
35 cp -a $install/* $fs
36 rm -rf $fs/usr/share
37 mv $fs/etc/pdnsd.conf.sample $fs/etc/pdnsd.conf
38 }
40 # Pre and post install commands for Tazpkg.
41 pre_remove()
42 {
43 sed -i 's/pdnsd//' "$1/etc/rcS.conf"
44 rm -f "$1/etc/init.d/pdnsd"
45 }
47 post_install()
48 {
49 local tmp
50 tmp=$(route -n | awk '/^0.0.0.0/ { print $8; }')
51 [ -n "$tmp" ] && sed -i "s/eth0/$tmp/" "$1/etc/pdnsd.conf"
52 tmp=$(sed '/nameserver/!d;s/nameserver //;q' < /etc/resolv.conf)
53 [ -n "$tmp" ] && sed -i "s/192\.168\.0\.1/$tmp/" "$1/etc/pdnsd.conf"
54 tmp=
55 [ -s "$1/etc/init.d/daemon" ] && ln -s daemon "$1/etc/init.d/pdnsd" &&
56 tmp=" and add pdnsd to RUN_DAEMONS in /etc/rcS.conf"
57 cat <<EOT
58 Now you can check /etc/pdnsd.conf$tmp.
59 EOT
60 }