Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-dns/getdns/
Date: Fri, 03 Jan 2020 21:32:10
Message-Id: 1578087118.06f3f121631f90bddbd09bef70f13140e03ac518.blueness@gentoo
1 commit: 06f3f121631f90bddbd09bef70f13140e03ac518
2 Author: Quentin Retornaz <gentoo <AT> retornaz <DOT> com>
3 AuthorDate: Sun Dec 29 20:27:15 2019 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Fri Jan 3 21:31:58 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=06f3f121
7
8 net-dns/getdns: fix forgot use_with replaced by usex and switch to cmake.eclass
9
10 Closes: https://bugs.gentoo.org/703886
11 Package-Manager: Portage-2.3.79, Repoman-2.3.16
12 Signed-off-by: Quentin Retornaz <gentoo <AT> retornaz.com>
13 Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org>
14
15 net-dns/getdns/getdns-1.6.0_beta1-r1.ebuild | 87 +++++++++++++++++++++++++++++
16 1 file changed, 87 insertions(+)
17
18 diff --git a/net-dns/getdns/getdns-1.6.0_beta1-r1.ebuild b/net-dns/getdns/getdns-1.6.0_beta1-r1.ebuild
19 new file mode 100644
20 index 00000000000..434509bab8d
21 --- /dev/null
22 +++ b/net-dns/getdns/getdns-1.6.0_beta1-r1.ebuild
23 @@ -0,0 +1,87 @@
24 +# Copyright 1999-2019 Gentoo Authors
25 +# Distributed under the terms of the GNU General Public License v2
26 +
27 +EAPI=7
28 +
29 +_SRCURI_P="${P/%_beta1/-beta.1}"
30 +
31 +inherit cmake fcaps systemd
32 +
33 +DESCRIPTION="Modern asynchronous DNS API"
34 +HOMEPAGE="https://getdnsapi.net/"
35 +SRC_URI="https://getdnsapi.net/releases/${_SRCURI_P//./-}/${_SRCURI_P}.tar.gz"
36 +
37 +LICENSE="BSD"
38 +SLOT="0"
39 +KEYWORDS="~amd64 ~x86"
40 +IUSE="doc examples +getdns-query +getdns-server-mon gnutls +idn libev libevent libuv static-libs stubby +unbound"
41 +
42 +S="${WORKDIR}/${_SRCURI_P}"
43 +
44 +# https://bugs.gentoo.org/661760
45 +# https://github.com/getdnsapi/getdns/issues/407
46 +RESTRICT="test"
47 +
48 +DEPEND="
49 + dev-libs/libbsd
50 + dev-libs/libyaml
51 + dev-libs/openssl:=
52 + idn? ( net-dns/libidn2:= )
53 + gnutls? (
54 + net-libs/gnutls:0=[dane,openssl]
55 + dev-libs/nettle:0=
56 + )
57 + libev? ( dev-libs/libev:= )
58 + libevent? ( dev-libs/libevent:= )
59 + libuv? ( dev-libs/libuv:= )
60 + unbound? ( >=net-dns/unbound-1.5.9:= )
61 +"
62 +RDEPEND="
63 + ${DEPEND}
64 + stubby? (
65 + acct-group/stubby
66 + acct-user/stubby
67 + sys-libs/libcap
68 + )
69 +"
70 +BDEPEND="
71 + doc? ( app-doc/doxygen )
72 +"
73 +
74 +PATCHES=( "${FILESDIR}/${PN}-1.4.2-stubby.service.patch" )
75 +
76 +src_configure() {
77 + local mycmakeargs=(
78 + -DCMAKE_INSTALL_RUNSTATEDIR=/var/run
79 + -DENABLE_STATIC=$(usex static-libs)
80 + -DBUILD_GETDNS_QUERY=$(usex getdns-query)
81 + -DBUILD_GETDNS_SERVER_MON=$(usex getdns-server-mon)
82 + -DUSE_GNUTLS=$(usex gnutls)
83 + -DUSE_LIBIDN2=$(usex idn)
84 + -DUSE_LIBEV=$(usex libev)
85 + -DUSE_LIBEVENT2=$(usex libevent)
86 + -DUSE_LIBUV=$(usex libuv)
87 + -DBUILD_STUBBY=$(usex stubby)
88 + -DENABLE_UNBOUND_EVENT_API=$(usex unbound)
89 + -DBUILD_DOXYGEN=$(usex doc)
90 + )
91 + cmake_src_configure
92 +}
93 +
94 +src_install() {
95 + cmake_src_install
96 + if use stubby; then
97 + newinitd "${FILESDIR}"/stubby.initd-r2 stubby
98 + newconfd "${FILESDIR}"/stubby.confd-r1 stubby
99 + insinto /etc/logrotate.d
100 + newins "${FILESDIR}"/stubby.logrotate stubby
101 + systemd_dounit "${S}"/stubby/systemd/stubby.service
102 + systemd_dotmpfilesd "${S}"/stubby/systemd/stubby.conf
103 + fi
104 +}
105 +
106 +pkg_postinst() {
107 + if use stubby; then
108 + fcaps cap_net_bind_service=ei /usr/bin/stubby
109 + fi
110 +}