Gentoo Archives: gentoo-commits

From: Sven Wegener <swegener@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-dns/pdns-recursor/files/, net-dns/pdns-recursor/
Date: Tue, 03 Nov 2015 19:31:05
Message-Id: 1446579013.88153f4d34a0719cee3960acb6423d7a6a7845cb.swegener@gentoo
1 commit: 88153f4d34a0719cee3960acb6423d7a6a7845cb
2 Author: Sven Wegener <swegener <AT> gentoo <DOT> org>
3 AuthorDate: Tue Nov 3 19:30:13 2015 +0000
4 Commit: Sven Wegener <swegener <AT> gentoo <DOT> org>
5 CommitDate: Tue Nov 3 19:30:13 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=88153f4d
7
8 net-dns/pdns-recursor: cleanup
9
10 Signed-off-by: Sven Wegener <swegener <AT> gentoo.org>
11
12 .../pdns-recursor-3.1.7.2-error-message.patch | 11 ----
13 .../files/pdns-recursor-3.5.3-fdlimit.patch | 67 ----------------------
14 .../files/pdns-recursor-3.6.1-CVE-2014-8601.patch | 52 -----------------
15 .../pdns-recursor/pdns-recursor-3.6.1-r1.ebuild | 59 -------------------
16 net-dns/pdns-recursor/pdns-recursor-3.6.2.ebuild | 55 ------------------
17 net-dns/pdns-recursor/pdns-recursor-3.6.3.ebuild | 55 ------------------
18 net-dns/pdns-recursor/pdns-recursor-3.7.1.ebuild | 61 --------------------
19 net-dns/pdns-recursor/pdns-recursor-3.7.2.ebuild | 61 --------------------
20 8 files changed, 421 deletions(-)
21
22 diff --git a/net-dns/pdns-recursor/files/pdns-recursor-3.1.7.2-error-message.patch b/net-dns/pdns-recursor/files/pdns-recursor-3.1.7.2-error-message.patch
23 deleted file mode 100644
24 index 7fdf208..0000000
25 --- a/net-dns/pdns-recursor/files/pdns-recursor-3.1.7.2-error-message.patch
26 +++ /dev/null
27 @@ -1,11 +0,0 @@
28 ---- pdns-recursor-3.1.7.2/rec_channel.cc
29 -+++ pdns-recursor-3.1.7.2/rec_channel.cc
30 -@@ -100,7 +100,7 @@
31 - strcpy(remote.sun_path,(path+"/"+fname).c_str());
32 - if(::connect(d_fd, (sockaddr*)&remote, sizeof(remote)) < 0) {
33 - unlink(d_local.sun_path);
34 -- throw AhuException("Unable to connect to remote '"+path+fname+"': "+string(strerror(errno)));
35 -+ throw AhuException("Unable to connect to remote '"+path+"/"+fname+"': "+string(strerror(errno)));
36 - }
37 - }
38 -
39
40 diff --git a/net-dns/pdns-recursor/files/pdns-recursor-3.5.3-fdlimit.patch b/net-dns/pdns-recursor/files/pdns-recursor-3.5.3-fdlimit.patch
41 deleted file mode 100644
42 index 3b6e8e2..0000000
43 --- a/net-dns/pdns-recursor/files/pdns-recursor-3.5.3-fdlimit.patch
44 +++ /dev/null
45 @@ -1,67 +0,0 @@
46 ---- pdns-recursor-3.5.3/misc.cc
47 -+++ pdns-recursor-3.5.3/misc.cc
48 -@@ -22,6 +22,7 @@
49 - #include <netdb.h>
50 - #include <sys/time.h>
51 - #include <time.h>
52 -+#include <sys/resource.h>
53 - #include <netinet/in.h>
54 - #include <unistd.h>
55 - #endif // WIN32
56 -@@ -697,3 +698,22 @@
57 - } while(!strchr(buffer, '\n'));
58 - return true;
59 - }
60 -+
61 -+unsigned int getFilenumLimit(bool hardOrSoft)
62 -+{
63 -+ struct rlimit rlim;
64 -+ if(getrlimit(RLIMIT_NOFILE, &rlim) < 0)
65 -+ unixDie("Requesting number of available file descriptors");
66 -+ return hardOrSoft ? rlim.rlim_max : rlim.rlim_cur;
67 -+}
68 -+
69 -+void setFilenumLimit(unsigned int lim)
70 -+{
71 -+ struct rlimit rlim;
72 -+
73 -+ if(getrlimit(RLIMIT_NOFILE, &rlim) < 0)
74 -+ unixDie("Requesting number of available file descriptors");
75 -+ rlim.rlim_cur=lim;
76 -+ if(setrlimit(RLIMIT_NOFILE, &rlim) < 0)
77 -+ unixDie("Setting number of available file descriptors");
78 -+}
79 ---- pdns-recursor-3.5.3/misc.hh
80 -+++ pdns-recursor-3.5.3/misc.hh
81 -@@ -445,4 +445,6 @@
82 - regex_t d_preg;
83 - };
84 -
85 -+unsigned int getFilenumLimit(bool hardOrSoft=0);
86 -+void setFilenumLimit(unsigned int lim);
87 - #endif
88 ---- pdns-recursor-3.5.3/pdns_recursor.cc
89 -+++ pdns-recursor-3.5.3/pdns_recursor.cc
90 -@@ -1740,7 +1740,21 @@
91 -
92 - g_tcpTimeout=::arg().asNum("client-tcp-timeout");
93 - g_maxTCPPerClient=::arg().asNum("max-tcp-per-client");
94 -- g_maxMThreads=::arg().asNum("max-mthreads");
95 -+ g_maxMThreads=::arg().asNum("max-mthreads");
96 -+ unsigned int availFDs=getFilenumLimit();
97 -+ if(g_maxMThreads * g_numThreads > availFDs) {
98 -+ if(getFilenumLimit(true) >= g_maxMThreads * g_numThreads) {
99 -+ setFilenumLimit(g_maxMThreads * g_numThreads);
100 -+ L<<Logger::Warning<<"Raised soft limit on number of filedescriptors to "<<g_maxMThreads * g_numThreads<<" to match max-mthreads and threads settings"<<endl;
101 -+ }
102 -+ else {
103 -+ int newval = getFilenumLimit(true) / g_numThreads;
104 -+ L<<Logger::Warning<<"Insufficient number of filedescriptors available for max-mthreads*threads setting! ("<<availFDs<<" < "<<g_maxMThreads*g_numThreads<<"), reducing max-mthreads to "<<newval<<endl;
105 -+ g_maxMThreads = newval;
106 -+ }
107 -+
108 -+
109 -+ }
110 -
111 - if(g_numThreads == 1) {
112 - L<<Logger::Warning<<"Operating unthreaded"<<endl;
113
114 diff --git a/net-dns/pdns-recursor/files/pdns-recursor-3.6.1-CVE-2014-8601.patch b/net-dns/pdns-recursor/files/pdns-recursor-3.6.1-CVE-2014-8601.patch
115 deleted file mode 100644
116 index 44ccc28..0000000
117 --- a/net-dns/pdns-recursor/files/pdns-recursor-3.6.1-CVE-2014-8601.patch
118 +++ /dev/null
119 @@ -1,52 +0,0 @@
120 -https://downloads.powerdns.com/patches/2014-02/3.6.1.patch
121 -
122 -diff --git a/pdns_recursor.cc b/pdns_recursor.cc
123 -index f1ef93c..8e43d6e 100644
124 ---- a/pdns_recursor.cc
125 -+++ b/pdns_recursor.cc
126 -@@ -550,7 +550,14 @@ void startDoResolve(void *p)
127 -
128 - // if there is a RecursorLua active, and it 'took' the query in preResolve, we don't launch beginResolve
129 - if(!t_pdl->get() || !(*t_pdl)->preresolve(dc->d_remote, g_listenSocketsAddresses[dc->d_socket], dc->d_mdp.d_qname, QType(dc->d_mdp.d_qtype), ret, res, &variableAnswer)) {
130 -- res = sr.beginResolve(dc->d_mdp.d_qname, QType(dc->d_mdp.d_qtype), dc->d_mdp.d_qclass, ret);
131 -+ try {
132 -+ res = sr.beginResolve(dc->d_mdp.d_qname, QType(dc->d_mdp.d_qtype), dc->d_mdp.d_qclass, ret);
133 -+ }
134 -+ catch(ImmediateServFailException &e) {
135 -+ L<<Logger::Error<<"Sending SERVFAIL during resolve of '"<<dc->d_mdp.d_qname<<"' because: "<<e.reason<<endl;
136 -+
137 -+ res = RCode::ServFail;
138 -+ }
139 -
140 - if(t_pdl->get()) {
141 - if(res == RCode::NoError) {
142 -diff --git a/syncres.cc b/syncres.cc
143 -index 4dc78b4..d09e44b 100644
144 ---- a/syncres.cc
145 -+++ b/syncres.cc
146 -@@ -923,6 +923,7 @@ int SyncRes::doResolveAt(set<string, CIStringCompare> nameservers, string auth,
147 - }
148 - else {
149 - s_outqueries++; d_outqueries++;
150 -+ if(d_outqueries > 50) throw ImmediateServFailException("more than 50 queries sent while resolving "+qname);
151 - TryTCP:
152 - if(doTCP) {
153 - LOG(prefix<<qname<<": using TCP with "<< remoteIP->toStringWithPort() <<endl);
154 -diff --git a/syncres.hh b/syncres.hh
155 -index 5182527..b22de89 100644
156 ---- a/syncres.hh
157 -+++ b/syncres.hh
158 -@@ -593,6 +593,13 @@ private:
159 - static AtomicCounter s_currentConnections; //!< total number of current TCP connections
160 - };
161 -
162 -+class ImmediateServFailException
163 -+{
164 -+public:
165 -+ ImmediateServFailException(string r){reason=r;};
166 -+
167 -+ string reason; //! Print this to tell the user what went wrong
168 -+};
169 -
170 - struct RemoteKeeper
171 - {
172
173 diff --git a/net-dns/pdns-recursor/pdns-recursor-3.6.1-r1.ebuild b/net-dns/pdns-recursor/pdns-recursor-3.6.1-r1.ebuild
174 deleted file mode 100644
175 index c90dfa2..0000000
176 --- a/net-dns/pdns-recursor/pdns-recursor-3.6.1-r1.ebuild
177 +++ /dev/null
178 @@ -1,59 +0,0 @@
179 -# Copyright 1999-2014 Gentoo Foundation
180 -# Distributed under the terms of the GNU General Public License v2
181 -# $Id$
182 -
183 -EAPI="4"
184 -
185 -inherit toolchain-funcs flag-o-matic eutils
186 -
187 -DESCRIPTION="The PowerDNS Recursor"
188 -HOMEPAGE="http://www.powerdns.com/"
189 -SRC_URI="http://downloads.powerdns.com/releases/${P}.tar.bz2"
190 -
191 -LICENSE="GPL-2"
192 -SLOT="0"
193 -KEYWORDS="amd64 x86"
194 -IUSE="lua"
195 -
196 -DEPEND="lua? ( >=dev-lang/lua-5.1 )"
197 -RDEPEND="${DEPEND}
198 - !<net-dns/pdns-2.9.20-r1"
199 -DEPEND="${DEPEND}
200 - >=dev-libs/boost-1.33.1"
201 -
202 -pkg_setup() {
203 - filter-flags -ftree-vectorize
204 -}
205 -
206 -src_prepare() {
207 - epatch "${FILESDIR}"/${P}-CVE-2014-8601.patch
208 -}
209 -
210 -src_configure() {
211 - true
212 -}
213 -
214 -src_compile() {
215 - emake \
216 - LOCALSTATEDIR=/var/lib/powerdns \
217 - CC="$(tc-getCC)" \
218 - CXX="$(tc-getCXX)" \
219 - OPTFLAGS="" \
220 - LUA_LIBS_CONFIG="-llua" \
221 - LUA_CPPFLAGS_CONFIG="" \
222 - LUA="$(use lua && echo 1)"
223 -}
224 -
225 -src_install() {
226 - dosbin pdns_recursor rec_control
227 - doman pdns_recursor.1 rec_control.1
228 -
229 - insinto /etc/powerdns
230 - doins "${FILESDIR}"/recursor.conf
231 -
232 - doinitd "${FILESDIR}"/precursor
233 -
234 - # Pretty ugly, uh?
235 - dodir /var/lib/powerdns/var/lib
236 - dosym ../.. /var/lib/powerdns/var/lib/powerdns
237 -}
238
239 diff --git a/net-dns/pdns-recursor/pdns-recursor-3.6.2.ebuild b/net-dns/pdns-recursor/pdns-recursor-3.6.2.ebuild
240 deleted file mode 100644
241 index cb321f4..0000000
242 --- a/net-dns/pdns-recursor/pdns-recursor-3.6.2.ebuild
243 +++ /dev/null
244 @@ -1,55 +0,0 @@
245 -# Copyright 1999-2014 Gentoo Foundation
246 -# Distributed under the terms of the GNU General Public License v2
247 -# $Id$
248 -
249 -EAPI="4"
250 -
251 -inherit toolchain-funcs flag-o-matic eutils
252 -
253 -DESCRIPTION="The PowerDNS Recursor"
254 -HOMEPAGE="http://www.powerdns.com/"
255 -SRC_URI="http://downloads.powerdns.com/releases/${P}.tar.bz2"
256 -
257 -LICENSE="GPL-2"
258 -SLOT="0"
259 -KEYWORDS="~amd64 ~x86"
260 -IUSE="lua"
261 -
262 -DEPEND="lua? ( >=dev-lang/lua-5.1 )"
263 -RDEPEND="${DEPEND}
264 - !<net-dns/pdns-2.9.20-r1"
265 -DEPEND="${DEPEND}
266 - >=dev-libs/boost-1.33.1"
267 -
268 -pkg_setup() {
269 - filter-flags -ftree-vectorize
270 -}
271 -
272 -src_configure() {
273 - true
274 -}
275 -
276 -src_compile() {
277 - emake \
278 - LOCALSTATEDIR=/var/lib/powerdns \
279 - CC="$(tc-getCC)" \
280 - CXX="$(tc-getCXX)" \
281 - OPTFLAGS="" \
282 - LUA_LIBS_CONFIG="-llua" \
283 - LUA_CPPFLAGS_CONFIG="" \
284 - LUA="$(use lua && echo 1)"
285 -}
286 -
287 -src_install() {
288 - dosbin pdns_recursor rec_control
289 - doman pdns_recursor.1 rec_control.1
290 -
291 - insinto /etc/powerdns
292 - doins "${FILESDIR}"/recursor.conf
293 -
294 - doinitd "${FILESDIR}"/precursor
295 -
296 - # Pretty ugly, uh?
297 - dodir /var/lib/powerdns/var/lib
298 - dosym ../.. /var/lib/powerdns/var/lib/powerdns
299 -}
300
301 diff --git a/net-dns/pdns-recursor/pdns-recursor-3.6.3.ebuild b/net-dns/pdns-recursor/pdns-recursor-3.6.3.ebuild
302 deleted file mode 100644
303 index bb2f19e..0000000
304 --- a/net-dns/pdns-recursor/pdns-recursor-3.6.3.ebuild
305 +++ /dev/null
306 @@ -1,55 +0,0 @@
307 -# Copyright 1999-2015 Gentoo Foundation
308 -# Distributed under the terms of the GNU General Public License v2
309 -# $Id$
310 -
311 -EAPI="4"
312 -
313 -inherit toolchain-funcs flag-o-matic eutils
314 -
315 -DESCRIPTION="The PowerDNS Recursor"
316 -HOMEPAGE="http://www.powerdns.com/"
317 -SRC_URI="http://downloads.powerdns.com/releases/${P}.tar.bz2"
318 -
319 -LICENSE="GPL-2"
320 -SLOT="0"
321 -KEYWORDS="~amd64 ~x86"
322 -IUSE="lua"
323 -
324 -DEPEND="lua? ( >=dev-lang/lua-5.1 )"
325 -RDEPEND="${DEPEND}
326 - !<net-dns/pdns-2.9.20-r1"
327 -DEPEND="${DEPEND}
328 - >=dev-libs/boost-1.33.1"
329 -
330 -pkg_setup() {
331 - filter-flags -ftree-vectorize
332 -}
333 -
334 -src_configure() {
335 - true
336 -}
337 -
338 -src_compile() {
339 - emake \
340 - LOCALSTATEDIR=/var/lib/powerdns \
341 - CC="$(tc-getCC)" \
342 - CXX="$(tc-getCXX)" \
343 - OPTFLAGS="" \
344 - LUA_LIBS_CONFIG="-llua" \
345 - LUA_CPPFLAGS_CONFIG="" \
346 - LUA="$(use lua && echo 1)"
347 -}
348 -
349 -src_install() {
350 - dosbin pdns_recursor rec_control
351 - doman pdns_recursor.1 rec_control.1
352 -
353 - insinto /etc/powerdns
354 - doins "${FILESDIR}"/recursor.conf
355 -
356 - doinitd "${FILESDIR}"/precursor
357 -
358 - # Pretty ugly, uh?
359 - dodir /var/lib/powerdns/var/lib
360 - dosym ../.. /var/lib/powerdns/var/lib/powerdns
361 -}
362
363 diff --git a/net-dns/pdns-recursor/pdns-recursor-3.7.1.ebuild b/net-dns/pdns-recursor/pdns-recursor-3.7.1.ebuild
364 deleted file mode 100644
365 index 5b5d2c8..0000000
366 --- a/net-dns/pdns-recursor/pdns-recursor-3.7.1.ebuild
367 +++ /dev/null
368 @@ -1,61 +0,0 @@
369 -# Copyright 1999-2015 Gentoo Foundation
370 -# Distributed under the terms of the GNU General Public License v2
371 -# $Id$
372 -
373 -EAPI="4"
374 -
375 -inherit toolchain-funcs flag-o-matic eutils
376 -
377 -DESCRIPTION="The PowerDNS Recursor"
378 -HOMEPAGE="http://www.powerdns.com/"
379 -SRC_URI="http://downloads.powerdns.com/releases/${P}.tar.bz2"
380 -
381 -LICENSE="GPL-2"
382 -SLOT="0"
383 -KEYWORDS="~amd64 ~x86"
384 -IUSE="lua"
385 -
386 -DEPEND="lua? ( >=dev-lang/lua-5.1 )"
387 -RDEPEND="${DEPEND}
388 - !<net-dns/pdns-2.9.20-r1"
389 -DEPEND="${DEPEND}
390 - >=dev-libs/boost-1.33.1"
391 -
392 -pkg_setup() {
393 - filter-flags -ftree-vectorize
394 -}
395 -
396 -src_configure() {
397 - CC="$(tc-getCC)" \
398 - CXX="$(tc-getCXX)" \
399 - OPTFLAGS="" \
400 - LUA_LIBS_CONFIG="-llua" \
401 - LUA_CPPFLAGS_CONFIG="" \
402 - LUA="$(use lua && echo 1)" \
403 - ./configure
404 -}
405 -
406 -src_compile() {
407 - emake \
408 - LOCALSTATEDIR=/var/lib/powerdns \
409 - CC="$(tc-getCC)" \
410 - CXX="$(tc-getCXX)" \
411 - OPTFLAGS="" \
412 - LUA_LIBS_CONFIG="-llua" \
413 - LUA_CPPFLAGS_CONFIG="" \
414 - LUA="$(use lua && echo 1)"
415 -}
416 -
417 -src_install() {
418 - dosbin pdns_recursor rec_control
419 - doman pdns_recursor.1 rec_control.1
420 -
421 - insinto /etc/powerdns
422 - doins "${FILESDIR}"/recursor.conf
423 -
424 - doinitd "${FILESDIR}"/precursor
425 -
426 - # Pretty ugly, uh?
427 - dodir /var/lib/powerdns/var/lib
428 - dosym ../.. /var/lib/powerdns/var/lib/powerdns
429 -}
430
431 diff --git a/net-dns/pdns-recursor/pdns-recursor-3.7.2.ebuild b/net-dns/pdns-recursor/pdns-recursor-3.7.2.ebuild
432 deleted file mode 100644
433 index 5b5d2c8..0000000
434 --- a/net-dns/pdns-recursor/pdns-recursor-3.7.2.ebuild
435 +++ /dev/null
436 @@ -1,61 +0,0 @@
437 -# Copyright 1999-2015 Gentoo Foundation
438 -# Distributed under the terms of the GNU General Public License v2
439 -# $Id$
440 -
441 -EAPI="4"
442 -
443 -inherit toolchain-funcs flag-o-matic eutils
444 -
445 -DESCRIPTION="The PowerDNS Recursor"
446 -HOMEPAGE="http://www.powerdns.com/"
447 -SRC_URI="http://downloads.powerdns.com/releases/${P}.tar.bz2"
448 -
449 -LICENSE="GPL-2"
450 -SLOT="0"
451 -KEYWORDS="~amd64 ~x86"
452 -IUSE="lua"
453 -
454 -DEPEND="lua? ( >=dev-lang/lua-5.1 )"
455 -RDEPEND="${DEPEND}
456 - !<net-dns/pdns-2.9.20-r1"
457 -DEPEND="${DEPEND}
458 - >=dev-libs/boost-1.33.1"
459 -
460 -pkg_setup() {
461 - filter-flags -ftree-vectorize
462 -}
463 -
464 -src_configure() {
465 - CC="$(tc-getCC)" \
466 - CXX="$(tc-getCXX)" \
467 - OPTFLAGS="" \
468 - LUA_LIBS_CONFIG="-llua" \
469 - LUA_CPPFLAGS_CONFIG="" \
470 - LUA="$(use lua && echo 1)" \
471 - ./configure
472 -}
473 -
474 -src_compile() {
475 - emake \
476 - LOCALSTATEDIR=/var/lib/powerdns \
477 - CC="$(tc-getCC)" \
478 - CXX="$(tc-getCXX)" \
479 - OPTFLAGS="" \
480 - LUA_LIBS_CONFIG="-llua" \
481 - LUA_CPPFLAGS_CONFIG="" \
482 - LUA="$(use lua && echo 1)"
483 -}
484 -
485 -src_install() {
486 - dosbin pdns_recursor rec_control
487 - doman pdns_recursor.1 rec_control.1
488 -
489 - insinto /etc/powerdns
490 - doins "${FILESDIR}"/recursor.conf
491 -
492 - doinitd "${FILESDIR}"/precursor
493 -
494 - # Pretty ugly, uh?
495 - dodir /var/lib/powerdns/var/lib
496 - dosym ../.. /var/lib/powerdns/var/lib/powerdns
497 -}