Gentoo Archives: gentoo-commits

From: Andreas Sturmlechner <asturm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/kde-sunset:master commit in: net-dns/avahi/
Date: Mon, 01 Feb 2021 20:22:42
Message-Id: 1612210914.81618f5dd4d4f04e95c48cdae33fc08e9be34122.asturm@gentoo
1 commit: 81618f5dd4d4f04e95c48cdae33fc08e9be34122
2 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
3 AuthorDate: Mon Feb 1 20:15:12 2021 +0000
4 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
5 CommitDate: Mon Feb 1 20:21:54 2021 +0000
6 URL: https://gitweb.gentoo.org/proj/kde-sunset.git/commit/?id=81618f5d
7
8 net-dns/avahi: 0.8-r2 version bump re-enabled with IUSE=qt4
9
10 Package-Manager: Portage-3.0.14, Repoman-3.0.2
11 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
12
13 net-dns/avahi/avahi-0.6.31-r6.ebuild | 234 -----------------------------------
14 net-dns/avahi/avahi-0.8-r2.ebuild | 216 ++++++++++++++++++++++++++++++++
15 net-dns/avahi/metadata.xml | 20 ++-
16 3 files changed, 223 insertions(+), 247 deletions(-)
17
18 diff --git a/net-dns/avahi/avahi-0.6.31-r6.ebuild b/net-dns/avahi/avahi-0.6.31-r6.ebuild
19 deleted file mode 100644
20 index 9ed29766..00000000
21 --- a/net-dns/avahi/avahi-0.6.31-r6.ebuild
22 +++ /dev/null
23 @@ -1,234 +0,0 @@
24 -# Copyright 1999-2020 Gentoo Authors
25 -# Distributed under the terms of the GNU General Public License v2
26 -
27 -EAPI="5"
28 -
29 -PYTHON_COMPAT=( python2_7 )
30 -PYTHON_REQ_USE="gdbm"
31 -WANT_AUTOMAKE=1.11
32 -inherit autotools eutils flag-o-matic multilib multilib-minimal mono-env python-r1 systemd user
33 -
34 -DESCRIPTION="System which facilitates service discovery on a local network"
35 -HOMEPAGE="http://avahi.org/"
36 -SRC_URI="http://avahi.org/download/${P}.tar.gz"
37 -
38 -LICENSE="LGPL-2.1"
39 -SLOT="0"
40 -KEYWORDS="amd64 ~arm ~hppa m68k ~mips ~ppc ~ppc64 s390 ~sparc x86 ~x86-linux"
41 -IUSE="autoipd bookmarks dbus doc gdbm gtk howl-compat +introspection ipv6 kernel_linux mdnsresponder-compat mono nls python qt4 selinux test utils"
42 -
43 -REQUIRED_USE="
44 - utils? ( gtk )
45 - python? ( ${PYTHON_REQUIRED_USE} dbus gdbm )
46 - mono? ( dbus )
47 - howl-compat? ( dbus )
48 - mdnsresponder-compat? ( dbus )
49 -"
50 -
51 -RESTRICT="!test? ( test )"
52 -
53 -COMMON_DEPEND="
54 - dev-libs/libdaemon
55 - dev-libs/expat
56 - >=dev-libs/glib-2.34.3:2[${MULTILIB_USEDEP}]
57 - gdbm? ( >=sys-libs/gdbm-1.10-r1[${MULTILIB_USEDEP}] )
58 - qt4? ( dev-qt/qtcore:4 )
59 - gtk? ( x11-libs/gtk+:3 )
60 - dbus? ( >=sys-apps/dbus-1.6.18-r1[${MULTILIB_USEDEP}] )
61 - kernel_linux? ( sys-libs/libcap )
62 - introspection? ( dev-libs/gobject-introspection )
63 - mono? ( dev-lang/mono )
64 - python? (
65 - ${PYTHON_DEPS}
66 - dbus? ( dev-python/dbus-python )
67 - )
68 - bookmarks? ( dev-python/twisted )
69 -"
70 -
71 -DEPEND="${COMMON_DEPEND}
72 - dev-util/intltool
73 - >=virtual/pkgconfig-0-r1
74 - doc? ( app-doc/doxygen )
75 -"
76 -
77 -RDEPEND="${COMMON_DEPEND}
78 - howl-compat? ( !net-misc/howl )
79 - mdnsresponder-compat? ( !net-misc/mDNSResponder )
80 - selinux? ( sec-policy/selinux-avahi )
81 -"
82 -
83 -MULTILIB_WRAPPED_HEADERS=(
84 - # necessary until the UI libraries are ported
85 - /usr/include/avahi-qt4/qt-watch.h
86 - /usr/include/avahi-ui/avahi-ui.h
87 -)
88 -
89 -pkg_preinst() {
90 - enewgroup netdev
91 - enewgroup avahi
92 - enewuser avahi -1 -1 -1 avahi
93 -
94 - if use autoipd; then
95 - enewgroup avahi-autoipd
96 - enewuser avahi-autoipd -1 -1 -1 avahi-autoipd
97 - fi
98 -}
99 -
100 -pkg_setup() {
101 - use mono && mono-env_pkg_setup
102 -}
103 -
104 -src_prepare() {
105 - if use ipv6; then
106 - sed -i \
107 - -e s/use-ipv6=no/use-ipv6=yes/ \
108 - avahi-daemon/avahi-daemon.conf || die
109 - fi
110 -
111 - sed -i\
112 - -e "s:\\.\\./\\.\\./\\.\\./doc/avahi-docs/html/:../../../doc/${PF}/html/:" \
113 - doxygen_to_devhelp.xsl || die
114 -
115 - # Make gtk utils optional
116 - epatch "${FILESDIR}"/${PN}-0.6.30-optional-gtk-utils.patch
117 -
118 - # Fix init scripts for >=openrc-0.9.0, bug #383641
119 - epatch "${FILESDIR}"/${PN}-0.6.x-openrc-0.9.x-init-scripts-fixes.patch
120 -
121 - # install-exec-local -> install-exec-hook
122 - epatch "${FILESDIR}"/${P}-install-exec-hook.patch
123 -
124 - # Backport host-name-from-machine-id patch, bug #466134
125 - epatch "${FILESDIR}"/${P}-host-name-from-machine-id.patch
126 -
127 - # Don't install avahi-discover unless ENABLE_GTK_UTILS, bug #359575
128 - epatch "${FILESDIR}"/${P}-fix-install-avahi-discover.patch
129 -
130 - epatch "${FILESDIR}"/${P}-so_reuseport-may-not-exist-in-running-kernel.patch
131 -
132 - # allow building client without the daemon
133 - epatch "${FILESDIR}"/${P}-build-client-without-daemon.patch
134 -
135 - # Fix build under various locales, bug #501664
136 - epatch "${FILESDIR}"/${P}-fix-locale-build.patch
137 -
138 - # Drop DEPRECATED flags, bug #384743
139 - sed -i -e 's:-D[A-Z_]*DISABLE_DEPRECATED=1::g' avahi-ui/Makefile.am || die
140 -
141 - # Fix references to Lennart's home directory, bug #466210
142 - sed -i -e 's/\/home\/lennart\/tmp\/avahi//g' man/* || die
143 -
144 - # Prevent .pyc files in DESTDIR
145 - >py-compile
146 -
147 - eautoreconf
148 -
149 - # bundled manpages
150 - multilib_copy_sources
151 -}
152 -
153 -src_configure() {
154 - # those steps should be done once-per-ebuild rather than per-ABI
155 - use sh && replace-flags -O? -O0
156 - use python && python_export_best
157 -
158 - # We need to unset DISPLAY, else the configure script might have problems detecting the pygtk module
159 - unset DISPLAY
160 -
161 - multilib-minimal_src_configure
162 -}
163 -
164 -multilib_src_configure() {
165 - local myconf=( --disable-static )
166 -
167 - if use python; then
168 - myconf+=(
169 - $(multilib_native_use_enable dbus python-dbus)
170 - --disable-pygtk
171 - )
172 - fi
173 -
174 - if use mono; then
175 - myconf+=( $(multilib_native_use_enable doc monodoc) )
176 - fi
177 -
178 - if ! multilib_is_native_abi; then
179 - myconf+=(
180 - # used by daemons only
181 - --disable-libdaemon
182 - --with-xml=none
183 - )
184 - fi
185 -
186 - econf \
187 - --localstatedir="${EPREFIX}/var" \
188 - --with-distro=gentoo \
189 - --disable-python-dbus \
190 - --disable-pygtk \
191 - --disable-xmltoman \
192 - --disable-monodoc \
193 - --enable-glib \
194 - --enable-gobject \
195 - $(multilib_native_use_enable test tests) \
196 - $(multilib_native_use_enable autoipd) \
197 - $(use_enable mdnsresponder-compat compat-libdns_sd) \
198 - $(use_enable howl-compat compat-howl) \
199 - $(multilib_native_use_enable doc doxygen-doc) \
200 - $(multilib_native_use_enable mono) \
201 - $(use_enable dbus) \
202 - $(multilib_native_use_enable python) \
203 - --disable-gtk \
204 - $(multilib_native_use_enable gtk gtk3) \
205 - $(use_enable nls) \
206 - $(multilib_native_use_enable introspection) \
207 - $(multilib_native_use_enable utils gtk-utils) \
208 - --disable-qt3 \
209 - $(multilib_native_use_enable qt4) \
210 - $(use_enable gdbm) \
211 - $(systemd_with_unitdir) \
212 - "${myconf[@]}"
213 -}
214 -
215 -multilib_src_compile() {
216 - emake
217 -
218 - multilib_is_native_abi && use doc && emake avahi.devhelp
219 -}
220 -
221 -multilib_src_install() {
222 - emake install DESTDIR="${D}"
223 - use bookmarks && use python && use dbus || \
224 - rm -f "${ED}"/usr/bin/avahi-bookmarks
225 -
226 - use howl-compat && dosym avahi-compat-howl.pc /usr/$(get_libdir)/pkgconfig/howl.pc
227 - use mdnsresponder-compat && dosym avahi-compat-libdns_sd/dns_sd.h /usr/include/dns_sd.h
228 -
229 - if multilib_is_native_abi && use doc; then
230 - dohtml -r doxygen/html/. || die
231 - insinto /usr/share/devhelp/books/avahi
232 - doins avahi.devhelp || die
233 - fi
234 -}
235 -
236 -multilib_src_install_all() {
237 - if use autoipd; then
238 - insinto /$(get_libdir)/rcscripts/net
239 - doins "${FILESDIR}"/autoipd.sh
240 -
241 - insinto /$(get_libdir)/netifrc/net
242 - newins "${FILESDIR}"/autoipd-openrc.sh autoipd.sh
243 - fi
244 -
245 - dodoc docs/{AUTHORS,NEWS,README,TODO}
246 -
247 - prune_libtool_files --all
248 -}
249 -
250 -pkg_postinst() {
251 - if use autoipd; then
252 - elog
253 - elog "To use avahi-autoipd to configure your interfaces with IPv4LL (RFC3927)"
254 - elog "addresses, just set config_<interface>=( autoipd ) in /etc/conf.d/net!"
255 - elog
256 - fi
257 -}
258
259 diff --git a/net-dns/avahi/avahi-0.8-r2.ebuild b/net-dns/avahi/avahi-0.8-r2.ebuild
260 new file mode 100644
261 index 00000000..71213619
262 --- /dev/null
263 +++ b/net-dns/avahi/avahi-0.8-r2.ebuild
264 @@ -0,0 +1,216 @@
265 +# Copyright 1999-2021 Gentoo Authors
266 +# Distributed under the terms of the GNU General Public License v2
267 +
268 +EAPI="7"
269 +
270 +PYTHON_COMPAT=( python3_{7,8} )
271 +PYTHON_REQ_USE="gdbm"
272 +inherit autotools flag-o-matic multilib-minimal mono-env python-r1 systemd
273 +
274 +DESCRIPTION="System which facilitates service discovery on a local network"
275 +HOMEPAGE="http://avahi.org/"
276 +SRC_URI="https://github.com/lathiat/avahi/archive/v${PV}.tar.gz -> ${P}.tar.gz"
277 +
278 +LICENSE="LGPL-2.1"
279 +SLOT="0"
280 +KEYWORDS="amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc x86 ~x86-linux"
281 +IUSE="autoipd bookmarks +dbus doc gdbm gtk gtk2 howl-compat +introspection ipv6 kernel_linux mdnsresponder-compat mono nls python qt4 qt5 selinux systemd test"
282 +
283 +REQUIRED_USE="
284 + python? ( dbus gdbm ${PYTHON_REQUIRED_USE} )
285 + mono? ( dbus )
286 + howl-compat? ( dbus )
287 + mdnsresponder-compat? ( dbus )
288 + systemd? ( dbus )
289 +"
290 +
291 +RESTRICT="!test? ( test )"
292 +
293 +DEPEND="
294 + dev-libs/libdaemon
295 + dev-libs/libevent:=[${MULTILIB_USEDEP}]
296 + dev-libs/expat
297 + dev-libs/glib:2[${MULTILIB_USEDEP}]
298 + gdbm? ( sys-libs/gdbm:=[${MULTILIB_USEDEP}] )
299 + qt4? ( dev-qt/qtcore:4 )
300 + qt5? ( dev-qt/qtcore:5 )
301 + gtk2? ( x11-libs/gtk+:2[${MULTILIB_USEDEP}] )
302 + gtk? ( x11-libs/gtk+:3[${MULTILIB_USEDEP}] )
303 + dbus? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
304 + kernel_linux? ( sys-libs/libcap )
305 + introspection? ( dev-libs/gobject-introspection:= )
306 + mono? (
307 + dev-lang/mono
308 + gtk2? ( dev-dotnet/gtk-sharp:2 )
309 + )
310 + python? (
311 + ${PYTHON_DEPS}
312 + dbus? ( dev-python/dbus-python[${PYTHON_USEDEP}] )
313 + introspection? ( dev-python/pygobject:3[${PYTHON_USEDEP}] )
314 + )
315 + bookmarks? (
316 + ${PYTHON_DEPS}
317 + >=dev-python/twisted-16.0.0[${PYTHON_USEDEP}]
318 + )
319 +"
320 +RDEPEND="
321 + acct-user/avahi
322 + acct-group/avahi
323 + acct-group/netdev
324 + autoipd? (
325 + acct-user/avahi-autoipd
326 + acct-group/avahi-autoipd
327 + )
328 + ${DEPEND}
329 + selinux? ( sec-policy/selinux-avahi )
330 +"
331 +BDEPEND="
332 + dev-util/glib-utils
333 + doc? ( app-doc/doxygen )
334 + app-doc/xmltoman
335 + dev-util/intltool
336 + virtual/pkgconfig
337 +"
338 +
339 +MULTILIB_WRAPPED_HEADERS=(
340 + /usr/include/avahi-qt4/qt-watch.h
341 + /usr/include/avahi-qt5/qt-watch.h
342 +)
343 +
344 +# These patches do not apply cleanly but may need to be re-instated.
345 +# I'll leave them commented out for now.
346 +#PATCHES=(
347 +# "${FILESDIR}/${PN}-0.7-qt5.patch"
348 +# "${FILESDIR}/${PN}-0.7-CVE-2017-6519.patch"
349 +# "${FILESDIR}/${PN}-0.7-remove-empty-avahi_discover.patch"
350 +# "${FILESDIR}/${PN}-0.7-python3.patch"
351 +# "${FILESDIR}/${PN}-0.7-python3-unittest.patch"
352 +# "${FILESDIR}/${PN}-0.7-python3-gdbm.patch"
353 +#)
354 +
355 +pkg_setup() {
356 + use mono && mono-env_pkg_setup
357 + use python || use bookmarks && python_setup
358 +}
359 +
360 +src_prepare() {
361 + default
362 +
363 + if ! use ipv6; then
364 + sed -i \
365 + -e "s/use-ipv6=yes/use-ipv6=no/" \
366 + avahi-daemon/avahi-daemon.conf || die
367 + fi
368 +
369 + sed -i \
370 + -e "s:\\.\\./\\.\\./\\.\\./doc/avahi-docs/html/:../../../doc/${PF}/html/:" \
371 + doxygen_to_devhelp.xsl || die
372 +
373 + eautoreconf
374 +
375 + # bundled manpages
376 + multilib_copy_sources
377 +}
378 +
379 +multilib_src_configure() {
380 + local myconf=(
381 + --disable-monodoc
382 + --disable-python-dbus
383 + --disable-qt3
384 + --disable-static
385 + --enable-manpages
386 + --enable-glib
387 + --enable-gobject
388 + --enable-xmltoman
389 + --localstatedir="${EPREFIX}/var"
390 + --with-distro=gentoo
391 + --with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
392 + $(use_enable dbus)
393 + $(use_enable gdbm)
394 + $(use_enable gtk2 gtk)
395 + $(use_enable gtk gtk3)
396 + $(use_enable howl-compat compat-howl)
397 + $(use_enable mdnsresponder-compat compat-libdns_sd)
398 + $(use_enable nls)
399 + $(multilib_native_use_enable autoipd)
400 + $(multilib_native_use_enable doc doxygen-doc)
401 + $(multilib_native_use_enable introspection)
402 + $(multilib_native_use_enable mono)
403 + $(multilib_native_use_enable python)
404 + $(multilib_native_use_enable qt4)
405 + $(multilib_native_use_enable qt5)
406 + $(multilib_native_use_enable test tests)
407 + )
408 +
409 + if use python; then
410 + myconf+=(
411 + $(multilib_native_use_enable dbus python-dbus)
412 + $(multilib_native_use_enable introspection pygobject)
413 + )
414 + fi
415 +
416 + if use mono; then
417 + myconf+=( $(multilib_native_use_enable doc monodoc) )
418 + fi
419 +
420 + if ! multilib_is_native_abi; then
421 + myconf+=(
422 + # used by daemons only
423 + --disable-libdaemon
424 + --with-xml=none
425 + )
426 + fi
427 +
428 + econf "${myconf[@]}"
429 +}
430 +
431 +multilib_src_compile() {
432 + emake
433 +
434 + multilib_is_native_abi && use doc && emake avahi.devhelp
435 +}
436 +
437 +multilib_src_install() {
438 + emake install DESTDIR="${D}"
439 + use bookmarks && use python && use dbus && use gtk2 || \
440 + rm -f "${ED}"/usr/bin/avahi-bookmarks
441 +
442 + # https://github.com/lathiat/avahi/issues/28
443 + use howl-compat && dosym avahi-compat-howl.pc /usr/$(get_libdir)/pkgconfig/howl.pc
444 + use mdnsresponder-compat && dosym avahi-compat-libdns_sd/dns_sd.h /usr/include/dns_sd.h
445 +
446 + if multilib_is_native_abi && use doc; then
447 + docinto html
448 + dodoc -r doxygen/html/.
449 + insinto /usr/share/devhelp/books/avahi
450 + doins avahi.devhelp
451 + fi
452 +
453 + # The build system creates an empty "/run" directory, so we clean it up here
454 + rmdir "${ED}"/run || die
455 +}
456 +
457 +multilib_src_install_all() {
458 + if use autoipd; then
459 + insinto /lib/rcscripts/net
460 + doins "${FILESDIR}"/autoipd.sh
461 +
462 + insinto /lib/netifrc/net
463 + newins "${FILESDIR}"/autoipd-openrc.sh autoipd.sh
464 + fi
465 +
466 + dodoc docs/{AUTHORS,NEWS,README,TODO}
467 +
468 + find "${ED}" -name '*.la' -type f -delete || die
469 +}
470 +
471 +pkg_postinst() {
472 + if use autoipd; then
473 + elog
474 + elog "To use avahi-autoipd to configure your interfaces with IPv4LL (RFC3927)"
475 + elog "addresses, just set config_<interface>=( autoipd ) in /etc/conf.d/net!"
476 + elog
477 + fi
478 +
479 + systemd_reenable avahi-daemon.service
480 +}
481
482 diff --git a/net-dns/avahi/metadata.xml b/net-dns/avahi/metadata.xml
483 index 626558ea..14001602 100644
484 --- a/net-dns/avahi/metadata.xml
485 +++ b/net-dns/avahi/metadata.xml
486 @@ -3,18 +3,12 @@
487 <pkgmetadata>
488 <!-- maintainer-needed -->
489 <use>
490 - <flag name='autoipd'>Build and install the IPv4LL (RFC3927) network address
491 - configuration daemon</flag>
492 - <flag name='bookmarks'>Install the avahi-bookmarks application (requires
493 - <pkg>dev-python/twisted</pkg>)</flag>
494 - <flag name='howl-compat'>Enable compat libraries for howl</flag>
495 - <flag name="gtk">Build the avahi-ui-gtk3 library, and use gtk3 for the
496 - avahi utilities under USE=utils</flag>
497 - <flag name="introspection">Use <pkg>dev-libs/gobject-introspection</pkg>
498 - for introspection</flag>
499 - <flag name='mdnsresponder-compat'>Enable compat libraries for
500 - mDNSResponder</flag>
501 - <flag name="utils">Install the avahi gtk+ utils avahi-discover, bssh, and
502 - bvnc</flag>
503 + <flag name="autoipd">Build and install the IPv4LL (RFC3927) network address configuration daemon</flag>
504 + <flag name="bookmarks">Install the avahi-bookmarks application (requires <pkg>dev-python/twisted</pkg>)</flag>
505 + <flag name="gtk2">Use gtk2 for the avahi utilities (overridden by USE=gtk) and build the avahi-ui library</flag>
506 + <flag name="gtk">Use gtk3 for the avahi utilities (overrides USE=gtk2) and build the avahi-ui-gtk3 library</flag>
507 + <flag name="howl-compat">Enable compat libraries for howl</flag>
508 + <flag name="introspection">Use <pkg>dev-libs/gobject-introspection</pkg> for introspection</flag>
509 + <flag name="mdnsresponder-compat">Enable compat libraries for mDNSResponder</flag>
510 </use>
511 </pkgmetadata>