Gentoo Archives: gentoo-commits

From: Marek Szuba <marecki@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: profiles/, net-dns/dnsdist/
Date: Tue, 22 Dec 2020 21:53:11
Message-Id: 1608673979.5391bc26d8e7602fe492f5d839d56541e4a0478e.marecki@gentoo
1 commit: 5391bc26d8e7602fe492f5d839d56541e4a0478e
2 Author: Marek Szuba <marecki <AT> gentoo <DOT> org>
3 AuthorDate: Tue Dec 22 21:50:48 2020 +0000
4 Commit: Marek Szuba <marecki <AT> gentoo <DOT> org>
5 CommitDate: Tue Dec 22 21:52:59 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5391bc26
7
8 net-dns/dnsdist: migrate to lua-single.eclass
9
10 Nice and easy. Builds, tests and installs fine against all implementations
11 currently in the tree.
12
13 Closes: https://bugs.gentoo.org/752795
14 Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>
15
16 net-dns/dnsdist/dnsdist-1.5.1-r100.ebuild | 85 +++++++++++++++++++++++++++++++
17 profiles/package.mask | 1 +
18 2 files changed, 86 insertions(+)
19
20 diff --git a/net-dns/dnsdist/dnsdist-1.5.1-r100.ebuild b/net-dns/dnsdist/dnsdist-1.5.1-r100.ebuild
21 new file mode 100644
22 index 00000000000..4e2054c07cc
23 --- /dev/null
24 +++ b/net-dns/dnsdist/dnsdist-1.5.1-r100.ebuild
25 @@ -0,0 +1,85 @@
26 +# Copyright 1999-2020 Gentoo Authors
27 +# Distributed under the terms of the GNU General Public License v2
28 +
29 +EAPI=7
30 +
31 +LUA_COMPAT=( lua5-{1..4} luajit )
32 +
33 +inherit flag-o-matic lua-single
34 +
35 +DESCRIPTION="A highly DNS-, DoS- and abuse-aware loadbalancer"
36 +HOMEPAGE="https://dnsdist.org"
37 +
38 +SRC_URI="https://downloads.powerdns.com/releases/${P}.tar.bz2"
39 +KEYWORDS="~amd64 ~x86"
40 +
41 +LICENSE="GPL-2"
42 +SLOT="0"
43 +IUSE="dnscrypt dnstap doh gnutls +lmdb regex remote-logging snmp +ssl systemd test"
44 +RESTRICT="!test? ( test )"
45 +REQUIRED_USE="${LUA_REQUIRED_USE}
46 + dnscrypt? ( ssl )
47 + gnutls? ( ssl )
48 + doh? ( ssl !gnutls )"
49 +
50 +RDEPEND="acct-group/dnsdist
51 + acct-user/dnsdist
52 + >=dev-libs/boost-1.35:=
53 + dev-libs/libedit:=
54 + dnscrypt? ( dev-libs/libsodium:= )
55 + dnstap? ( dev-libs/fstrm:= )
56 + doh? ( www-servers/h2o:=[libh2o] )
57 + lmdb? ( dev-db/lmdb:= )
58 + regex? ( dev-libs/re2:= )
59 + remote-logging? ( >=dev-libs/protobuf-3:= )
60 + snmp? ( net-analyzer/net-snmp:= )
61 + ssl? (
62 + gnutls? ( net-libs/gnutls:= )
63 + !gnutls? ( dev-libs/openssl:= )
64 + )
65 + systemd? ( sys-apps/systemd:0= )
66 + ${LUA_DEPS}
67 +"
68 +
69 +DEPEND="${RDEPEND}"
70 +BDEPEND="virtual/pkgconfig"
71 +
72 +src_prepare() {
73 + default
74 +}
75 +
76 +src_configure() {
77 + econf \
78 + --sysconfdir=/etc/dnsdist \
79 + --with-lua="${ELUA}" \
80 + $(use_enable doh dns-over-https) \
81 + $(use_enable dnscrypt) \
82 + $(use_enable dnstap) \
83 + $(use_with lmdb ) \
84 + $(use_with regex re2) \
85 + $(use_with remote-logging protobuf) \
86 + $(use_with snmp net-snmp) \
87 + $(use ssl && { echo "--enable-dns-over-tls" && use_with gnutls && use_with !gnutls libssl;} || echo "--without-gnutls --without-libssl") \
88 + $(use_enable systemd) \
89 + $(use_enable test unit-tests)
90 + sed 's/hardcode_libdir_flag_spec_CXX='\''$wl-rpath $wl$libdir'\''/hardcode_libdir_flag_spec_CXX='\''$wl-rpath $wl\/$libdir'\''/g' \
91 + -i "${S}/configure"
92 +}
93 +
94 +src_install() {
95 + default
96 +
97 + insinto /etc/dnsdist
98 + doins "${FILESDIR}"/dnsdist.conf.example
99 +
100 + newconfd "${FILESDIR}"/dnsdist.confd ${PN}
101 + newinitd "${FILESDIR}"/dnsdist.initd ${PN}
102 +}
103 +
104 +pkg_postinst() {
105 + elog "dnsdist provides multiple instances support. You can create more instances"
106 + elog "by symlinking the dnsdist init script to another name."
107 + elog
108 + elog "The name must be in the format dnsdist.<suffix> and dnsdist will use the"
109 + elog "/etc/dnsdist/dnsdist-<suffix>.conf configuration file instead of the default."
110 +}
111
112 diff --git a/profiles/package.mask b/profiles/package.mask
113 index fa5530ecdee..8dc2c8267c6 100644
114 --- a/profiles/package.mask
115 +++ b/profiles/package.mask
116 @@ -559,6 +559,7 @@ kde-apps/kdebase-meta:5
117 >=net-analyzer/tracebox-0.4.4-r100
118 >=net-analyzer/wireshark-3.4.2-r100
119 >=net-dialup/accel-ppp-1.12.0_p20200913-r100
120 +>=net-dns/dnsdist-1.5.1-r100
121 >=net-dns/dnsmasq-2.82-r100
122 >=net-im/prosody-0.11.7-r100
123 >=net-im/swift-4.0.2-r100