Gentoo Archives: gentoo-commits

From: Lars Wendler <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-misc/dhcp/, net-misc/dhcp/files/
Date: Wed, 31 Jul 2019 22:04:04
Message-Id: 1564610631.be2f1e5f86171478cf4a9e24b2a414716cfa71fd.polynomial-c@gentoo
1 commit: be2f1e5f86171478cf4a9e24b2a414716cfa71fd
2 Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jul 31 22:00:35 2019 +0000
4 Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
5 CommitDate: Wed Jul 31 22:03:51 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=be2f1e5f
7
8 net-misc/dhcp: Removed old.
9
10 Package-Manager: Portage-2.3.69, Repoman-2.3.16
11 Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
12
13 net-misc/dhcp/Manifest | 1 -
14 net-misc/dhcp/dhcp-4.3.6_p1.ebuild | 263 ---------------------
15 .../files/dhcp-4.2.2-bind-parallel-build.patch | 14 --
16 .../dhcp/files/dhcp-4.2.4-always-accept-4.patch | 29 ---
17 net-misc/dhcp/files/dhcp-4.3.4-bind-disable.patch | 38 ---
18 5 files changed, 345 deletions(-)
19
20 diff --git a/net-misc/dhcp/Manifest b/net-misc/dhcp/Manifest
21 index 4197edbff03..4a8471be145 100644
22 --- a/net-misc/dhcp/Manifest
23 +++ b/net-misc/dhcp/Manifest
24 @@ -1,2 +1 @@
25 -DIST dhcp-4.3.6-P1.tar.gz 10189202 BLAKE2B 5dfbda82fa76d1011c552c9d9b5f15296834c2f380795e11fc6419010dd533fa45b9544fc10fc9da45095127f54ffe136b5fd7cc584589150b1b0a9a054e800c SHA512 cb04af2fb0fa8c5621e8b3dcb41e81422475218e1569b0eac6e13c876a21279928a3348f799253d7207517720466523b1cc28005c671542e37b1a391342b1e62
26 DIST dhcp-4.4.1.tar.gz 11164378 BLAKE2B fd3c65d8802c42cb936ff75ee19784e4f533c9b36aa08a61280aa8acae5cf581c67cd70222b46eb24b1f9a571e1c028cc853952feac4b6a12f9b7d7d3dbc2fc9 SHA512 684ae349f224918c9f8cec7bd6c55cd0b83ad2b5827375b2876ca088eb05b7ff1364e50f6dc24f2485c610d9be94d4ba3020f60a0fa0ef63962349d191b887e7
27
28 diff --git a/net-misc/dhcp/dhcp-4.3.6_p1.ebuild b/net-misc/dhcp/dhcp-4.3.6_p1.ebuild
29 deleted file mode 100644
30 index 934d0e56fbb..00000000000
31 --- a/net-misc/dhcp/dhcp-4.3.6_p1.ebuild
32 +++ /dev/null
33 @@ -1,263 +0,0 @@
34 -# Copyright 1999-2018 Gentoo Foundation
35 -# Distributed under the terms of the GNU General Public License v2
36 -
37 -EAPI=6
38 -
39 -inherit systemd toolchain-funcs user
40 -
41 -MY_PV="${PV//_alpha/a}"
42 -MY_PV="${MY_PV//_beta/b}"
43 -MY_PV="${MY_PV//_rc/rc}"
44 -MY_PV="${MY_PV//_p/-P}"
45 -MY_P="${PN}-${MY_PV}"
46 -DESCRIPTION="ISC Dynamic Host Configuration Protocol (DHCP) client/server"
47 -HOMEPAGE="http://www.isc.org/products/DHCP"
48 -SRC_URI="ftp://ftp.isc.org/isc/dhcp/${MY_P}.tar.gz
49 - ftp://ftp.isc.org/isc/dhcp/${MY_PV}/${MY_P}.tar.gz"
50 -
51 -LICENSE="ISC BSD SSLeay GPL-2" # GPL-2 only for init script
52 -SLOT="0"
53 -KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd"
54 -IUSE="+client ipv6 kernel_linux ldap libressl selinux +server ssl vim-syntax"
55 -
56 -DEPEND="
57 - client? (
58 - kernel_linux? (
59 - ipv6? ( sys-apps/iproute2 )
60 - sys-apps/net-tools
61 - )
62 - )
63 - ldap? (
64 - net-nds/openldap
65 - ssl? (
66 - !libressl? ( dev-libs/openssl:0= )
67 - libressl? ( dev-libs/libressl )
68 - )
69 - )"
70 -RDEPEND="${DEPEND}
71 - selinux? ( sec-policy/selinux-dhcp )
72 - vim-syntax? ( app-vim/dhcpd-syntax )"
73 -
74 -S="${WORKDIR}/${MY_P}"
75 -
76 -src_unpack() {
77 - unpack ${A}
78 - # handle local bind hell
79 - cd "${S}"/bind
80 - unpack ./bind.tar.gz
81 -}
82 -
83 -PATCHES=(
84 - # Gentoo patches - these will probably never be accepted upstream
85 - # Fix some permission issues
86 - "${FILESDIR}/${PN}-3.0-fix-perms.patch"
87 -
88 - # Enable dhclient to equery NTP servers
89 - "${FILESDIR}/${PN}-4.3.6-dhclient-ntp.patch"
90 - "${FILESDIR}/${PN}-4.3.6-dhclient-resolvconf.patch"
91 -
92 - # Enable dhclient to get extra configuration from stdin
93 - "${FILESDIR}/${PN}-4.2.2-dhclient-stdin-conf.patch"
94 - "${FILESDIR}/${PN}-4.3.6-nogateway.patch" #265531
95 - "${FILESDIR}/${PN}-4.3.6-quieter-ping.patch" #296921
96 - "${FILESDIR}/${PN}-4.2.4-always-accept-4.patch" #437108
97 - "${FILESDIR}/${PN}-4.3.6-iproute2-path.patch" #480636
98 - "${FILESDIR}/${PN}-4.2.5-bindtodevice-inet6.patch" #471142
99 - "${FILESDIR}/${PN}-4.3.3-ldap-ipv6-client-id.patch" #559832
100 - "${FILESDIR}/${PN}-4.3.6-lmdb-removal.patch" #628598
101 -)
102 -
103 -src_prepare() {
104 - default
105 -
106 - # Brand the version with Gentoo
107 - sed -i \
108 - -e "/VERSION=/s:'$: Gentoo-${PR}':" \
109 - configure || die
110 -
111 - # Change the hook script locations of the scripts
112 - sed -i \
113 - -e 's,/etc/dhclient-exit-hooks,/etc/dhcp/dhclient-exit-hooks,g' \
114 - -e 's,/etc/dhclient-enter-hooks,/etc/dhcp/dhclient-enter-hooks,g' \
115 - client/scripts/* || die
116 -
117 - # No need for the linux script to force bash #158540
118 - sed -i -e 's,#!/bin/bash,#!/bin/sh,' client/scripts/linux || die
119 -
120 - # Quiet the freebsd logger a little
121 - sed -i -e '/LOGGER=/ s/-s -p user.notice //g' client/scripts/freebsd || die
122 -
123 - # Remove these options from the sample config
124 - sed -i -r \
125 - -e "/(script|host-name|domain-name) /d" \
126 - client/dhclient.conf.example || die
127 -
128 - if use client && ! use server ; then
129 - sed -i -r \
130 - -e '/^SUBDIRS/s:\<(dhcpctl|relay|server)\>::g' \
131 - Makefile.in || die
132 - elif ! use client && use server ; then
133 - sed -i -r \
134 - -e '/^SUBDIRS/s:\<client\>::' \
135 - Makefile.in || die
136 - fi
137 -
138 - # Only install different man pages if we don't have en
139 - if [[ " ${LINGUAS} " != *" en "* ]]; then
140 - # Install Japanese man pages
141 - if [[ " ${LINGUAS} " == *" ja "* && -d doc/ja_JP.eucJP ]]; then
142 - einfo "Installing Japanese documention"
143 - cp doc/ja_JP.eucJP/dhclient* client || die
144 - cp doc/ja_JP.eucJP/dhcp* common || die
145 - fi
146 - fi
147 - # Now remove the non-english docs so there are no errors later
148 - rm -r doc/ja_JP.eucJP || die
149 -
150 - # make the bind build work
151 - binddir="${S}/bind"
152 - cd "${binddir}" || die
153 - cat <<-EOF > bindvar.tmp
154 - binddir=${binddir}
155 - GMAKE=${MAKE:-gmake}
156 - EOF
157 - eapply -p2 "${FILESDIR}"/${PN}-4.3.4-bind-disable.patch
158 - cd bind-*/ || die
159 - eapply -p2 "${FILESDIR}"/${PN}-4.2.2-bind-parallel-build.patch #380717
160 -}
161 -
162 -src_configure() {
163 - # bind defaults to stupid `/usr/bin/ar`
164 - tc-export AR BUILD_CC
165 - export ac_cv_path_AR=${AR}
166 -
167 - # this is tested for by the bind build system, and can cause trouble
168 - # when cross-building; since dhcp itself doesn't make use of libcap,
169 - # simply disable it.
170 - export ac_cv_lib_cap_cap_set_proc=no
171 -
172 - # Use FHS sane paths ... some of these have configure options,
173 - # but not all, so just do it all here.
174 - local e="/etc/dhcp" r="/var/run/dhcp" l="/var/lib/dhcp"
175 - cat <<-EOF >> includes/site.h
176 - #define _PATH_DHCPD_CONF "${e}/dhcpd.conf"
177 - #define _PATH_DHCLIENT_CONF "${e}/dhclient.conf"
178 - #define _PATH_DHCPD_DB "${l}/dhcpd.leases"
179 - #define _PATH_DHCPD6_DB "${l}/dhcpd6.leases"
180 - #define _PATH_DHCLIENT_DB "${l}/dhclient.leases"
181 - #define _PATH_DHCLIENT6_DB "${l}/dhclient6.leases"
182 - #define _PATH_DHCPD_PID "${r}/dhcpd.pid"
183 - #define _PATH_DHCPD6_PID "${r}/dhcpd6.pid"
184 - #define _PATH_DHCLIENT_PID "${r}/dhcpclient.pid"
185 - #define _PATH_DHCLIENT6_PID "${r}/dhcpclient6.pid"
186 - #define _PATH_DHCRELAY_PID "${r}/dhcrelay.pid"
187 - #define _PATH_DHCRELAY6_PID "${r}/dhcrelay6.pid"
188 - EOF
189 -
190 - local myeconfargs=(
191 - --enable-paranoia
192 - --enable-early-chroot
193 - --sysconfdir=${e}
194 - $(use_enable ipv6 dhcpv6)
195 - $(use_with ldap)
196 - $(use ldap && use_with ssl ldapcrypto || echo --without-ldapcrypto)
197 - )
198 - econf "${myeconfargs[@]}"
199 -
200 - # configure local bind cruft. symtable option requires
201 - # perl and we don't want to require that #383837.
202 - cd bind/bind-*/ || die
203 - eval econf \
204 - $(sed -n '/^bindconfig =/,/^$/{:a;N;$!ba;s,^[^-]*,,;s,\\\s*\n\s*--,--,g;s, @[[:upper:]]\+@,,g;P;D}' ../Makefile.in) \
205 - --disable-symtable \
206 - --without-make-clean
207 -}
208 -
209 -src_compile() {
210 - # build local bind cruft first
211 - emake -C bind/bind-*/lib/export install
212 - # then build standard dhcp code
213 - emake AR="$(tc-getAR)"
214 -}
215 -
216 -src_install() {
217 - default
218 -
219 - dodoc README RELNOTES doc/{api+protocol,IANA-arp-parameters}
220 - docinto html
221 - dodoc doc/References.html
222 -
223 - if [[ -e client/dhclient ]] ; then
224 - # move the client to /
225 - dodir /sbin
226 - mv "${D}"/usr/sbin/dhclient "${D}"/sbin/ || die
227 -
228 - exeinto /sbin
229 - if use kernel_linux ; then
230 - newexe "${S}"/client/scripts/linux dhclient-script
231 - else
232 - newexe "${S}"/client/scripts/freebsd dhclient-script
233 - fi
234 - fi
235 -
236 - if [[ -e server/dhcpd ]] ; then
237 - if use ldap ; then
238 - insinto /etc/openldap/schema
239 - doins contrib/ldap/dhcp.*
240 - dosbin contrib/ldap/dhcpd-conf-to-ldap
241 - fi
242 -
243 - newinitd "${FILESDIR}"/dhcpd.init5 dhcpd
244 - newconfd "${FILESDIR}"/dhcpd.conf2 dhcpd
245 - newinitd "${FILESDIR}"/dhcrelay.init3 dhcrelay
246 - newconfd "${FILESDIR}"/dhcrelay.conf dhcrelay
247 - newinitd "${FILESDIR}"/dhcrelay.init3 dhcrelay6
248 - newconfd "${FILESDIR}"/dhcrelay6.conf dhcrelay6
249 -
250 - systemd_newtmpfilesd "${FILESDIR}"/dhcpd.tmpfiles dhcpd.conf
251 - systemd_dounit "${FILESDIR}"/dhcpd4.service
252 - systemd_dounit "${FILESDIR}"/dhcpd6.service
253 - systemd_dounit "${FILESDIR}"/dhcrelay4.service
254 - systemd_dounit "${FILESDIR}"/dhcrelay6.service
255 - systemd_install_serviced "${FILESDIR}"/dhcrelay4.service.conf
256 - systemd_install_serviced "${FILESDIR}"/dhcrelay6.service.conf
257 -
258 - sed -i "s:#@slapd@:$(usex ldap slapd ''):" "${ED}"/etc/init.d/* || die #442560
259 - fi
260 -
261 - # the default config files aren't terribly useful #384087
262 - local f
263 - for f in "${ED}"/etc/dhcp/*.conf.example ; do
264 - mv "${f}" "${f%.example}" || die
265 - done
266 - sed -i '/^[^#]/s:^:#:' "${ED}"/etc/dhcp/*.conf || die
267 -}
268 -
269 -pkg_preinst() {
270 - enewgroup dhcp
271 - enewuser dhcp -1 -1 /var/lib/dhcp dhcp
272 -
273 - # Keep the user files over the sample ones. The
274 - # hashing is to ignore the crappy defaults #384087.
275 - local f h
276 - for f in dhclient:da7c8496a96452190aecf9afceef4510 dhcpd:10979e7b71134bd7f04d2a60bd58f070 ; do
277 - h=${f#*:}
278 - f="/etc/dhcp/${f%:*}.conf"
279 - if [ -e "${EROOT}"${f} ] ; then
280 - case $(md5sum "${EROOT}"${f}) in
281 - ${h}*) ;;
282 - *) cp -p "${EROOT}"${f} "${ED}"${f};;
283 - esac
284 - fi
285 - done
286 -}
287 -
288 -pkg_postinst() {
289 - if [[ -e "${ROOT}"/etc/init.d/dhcp ]] ; then
290 - ewarn
291 - ewarn "WARNING: The dhcp init script has been renamed to dhcpd"
292 - ewarn "/etc/init.d/dhcp and /etc/conf.d/dhcp need to be removed and"
293 - ewarn "and dhcp should be removed from the default runlevel"
294 - ewarn
295 - fi
296 -}
297
298 diff --git a/net-misc/dhcp/files/dhcp-4.2.2-bind-parallel-build.patch b/net-misc/dhcp/files/dhcp-4.2.2-bind-parallel-build.patch
299 deleted file mode 100644
300 index 6136154f65a..00000000000
301 --- a/net-misc/dhcp/files/dhcp-4.2.2-bind-parallel-build.patch
302 +++ /dev/null
303 @@ -1,14 +0,0 @@
304 -fix the bind subdir parallel builds
305 -
306 -https://bugs.gentoo.org/380717
307 -
308 ---- a/bind/lib/export/isc/Makefile.in
309 -+++ b/bind/lib/export/isc/Makefile.in
310 -@@ -114,6 +114,7 @@
311 - -DLIBAGE=${LIBAGE} \
312 - -c ${srcdir}/version.c
313 -
314 -+${OBJS}: | subdirs
315 - libisc.@SA@: ${OBJS}
316 - ${AR} ${ARFLAGS} $@ ${OBJS}
317 - ${RANLIB} $@
318
319 diff --git a/net-misc/dhcp/files/dhcp-4.2.4-always-accept-4.patch b/net-misc/dhcp/files/dhcp-4.2.4-always-accept-4.patch
320 deleted file mode 100644
321 index 6cec86c9d9c..00000000000
322 --- a/net-misc/dhcp/files/dhcp-4.2.4-always-accept-4.patch
323 +++ /dev/null
324 @@ -1,29 +0,0 @@
325 -https://bugs.gentoo.org/437108
326 -
327 -always accept the -4 option even if we don't have IPv6 support enabled.
328 -the relay code does this already.
329 -
330 ---- a/client/dhclient.c
331 -+++ b/client/dhclient.c
332 -@@ -170,8 +170,8 @@ main(int argc, char **argv) {
333 - if (!strcmp(argv[i], "-r")) {
334 - release_mode = 1;
335 - no_daemon = 1;
336 --#ifdef DHCPv6
337 - } else if (!strcmp(argv[i], "-4")) {
338 -+#ifdef DHCPv6
339 - if (local_family_set && local_family != AF_INET)
340 - log_fatal("Client can only do v4 or v6, not "
341 - "both.");
342 ---- a/server/dhcpd.c
343 -+++ b/server/dhcpd.c
344 -@@ -373,8 +373,8 @@ main(int argc, char **argv) {
345 - } else if (!strcmp (argv [i], "-q")) {
346 - quiet = 1;
347 - quiet_interface_discovery = 1;
348 --#ifdef DHCPv6
349 - } else if (!strcmp(argv[i], "-4")) {
350 -+#ifdef DHCPv6
351 - if (local_family_set && (local_family != AF_INET)) {
352 - log_fatal("Server cannot run in both IPv4 and "
353 - "IPv6 mode at the same time.");
354
355 diff --git a/net-misc/dhcp/files/dhcp-4.3.4-bind-disable.patch b/net-misc/dhcp/files/dhcp-4.3.4-bind-disable.patch
356 deleted file mode 100644
357 index be0c032ae76..00000000000
358 --- a/net-misc/dhcp/files/dhcp-4.3.4-bind-disable.patch
359 +++ /dev/null
360 @@ -1,38 +0,0 @@
361 ---- dhcp-4.3.4/bind/Makefile.in
362 -+++ dhcp-4.3.4/bind/Makefile.in
363 -@@ -40,6 +40,7 @@
364 - @BIND_ATF_TRUE@all: bind1 atf bind2
365 -
366 - bind1:
367 -+disable:
368 - # Extract the source from the tarball, if it hasn't been already.
369 - @if test -d ${bindsrcdir} ; then \
370 - echo ${bindsrcdir} already unpacked... ; \
371 -@@ -68,6 +69,7 @@
372 - fi
373 -
374 - atf:
375 -+disable:
376 - # Build and copy the ATF support if not yet installed.
377 - @if test -d ./atf ; then \
378 - echo ATF support already installed ; \
379 -@@ -82,6 +84,7 @@
380 - @CROSS_COMPILING_TRUE@bind2: bind2-hostgen
381 -
382 - bind2-noguest:
383 -+disable:
384 - # Build and install the export libraries
385 - # No need to do anything if we already have something installed.
386 - @if test -d ${binddir}/lib ; then \
387 -@@ -98,6 +101,7 @@
388 - fi
389 -
390 - bind2-hostgen:
391 -+disable:
392 - # Build and install the export libraries
393 - # No need to do anything if we already have something installed.
394 - @if test -d ${binddir}/lib ; then \
395 ---- dhcp-4.3.4/bind/test
396 -+++ dhcp-4.3.4/bind/test
397 -@@ -0,0 +1 @@
398 -+--disable-kqueue --disable-epoll --disable-devpoll --without-openssl --without-libxml2 --enable-exportlib --with-gssapi=no --enable-threads=no @BINDCONFIG@ --with-export-includedir=${binddir}/include --with-export-libdir=${binddir}/lib