summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Hubbs <williamh@gentoo.org>2012-11-02 13:58:00 +0000
committerWilliam Hubbs <williamh@gentoo.org>2012-11-02 13:58:00 +0000
commit05f76a8decd75074148c3a928f6e54d0771caa96 (patch)
tree927217a7a6baba50bede6ccd7760a72fc7dbbcd1 /net-misc/dhcpcd
parentSign manifest. (diff)
downloadgentoo-2-05f76a8decd75074148c3a928f6e54d0771caa96.tar.gz
gentoo-2-05f76a8decd75074148c3a928f6e54d0771caa96.tar.bz2
gentoo-2-05f76a8decd75074148c3a928f6e54d0771caa96.zip
Only display messages about zeroconf if the status of the use flag changed for bug #440410.
(Portage version: 2.2.0_alpha142/cvs/Linux i686, signed Manifest commit with key 0x30C46538)
Diffstat (limited to 'net-misc/dhcpcd')
-rw-r--r--net-misc/dhcpcd/dhcpcd-5.6.2.ebuild8
1 files changed, 6 insertions, 2 deletions
diff --git a/net-misc/dhcpcd/dhcpcd-5.6.2.ebuild b/net-misc/dhcpcd/dhcpcd-5.6.2.ebuild
index b716fd9f0f07..e58fe99f5c08 100644
--- a/net-misc/dhcpcd/dhcpcd-5.6.2.ebuild
+++ b/net-misc/dhcpcd/dhcpcd-5.6.2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcpcd/dhcpcd-5.6.2.ebuild,v 1.5 2012/10/29 20:55:54 jdhore Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcpcd/dhcpcd-5.6.2.ebuild,v 1.6 2012/11/02 13:58:00 williamh Exp $
EAPI=4
@@ -53,6 +53,10 @@ src_install() {
systemd_dounit "${FILESDIR}"/${PN}.service
}
+pkg_preinst() {
+ has_version 'net-misc/dhcpcd[zeroconf]' && prev_zero=true || prev_zero=false
+}
+
pkg_postinst() {
# Upgrade the duid file to the new format if needed
local old_duid="${ROOT}"/var/lib/dhcpcd/dhcpcd.duid
@@ -66,7 +70,7 @@ pkg_postinst() {
cp -p "${old_duid}" "${new_duid}"
fi
- if use zeroconf; then
+ if use zeroconf && ! $prev_zero; then
elog "You have installed dhcpcd with zeroconf support."
elog "This means that it will always obtain an IP address even if no"
elog "DHCP server can be contacted, which will break any existing"