diff options
author | Mike Frysinger <vapier@gentoo.org> | 2007-12-30 18:39:13 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2007-12-30 18:39:13 +0000 |
commit | 55c11b5fbaa4025f523efe50271eb28c1d9c3cf0 (patch) | |
tree | 2ec5f5b688297b771bc3ec88b5ffceb663f953ab /net-print/hplip | |
parent | Fix incompatibilities with iptables-1.4.0 (#203744). (diff) | |
download | gentoo-2-55c11b5fbaa4025f523efe50271eb28c1d9c3cf0.tar.gz gentoo-2-55c11b5fbaa4025f523efe50271eb28c1d9c3cf0.tar.bz2 gentoo-2-55c11b5fbaa4025f523efe50271eb28c1d9c3cf0.zip |
rewrite the pkg_preinst hack so that it screws around with dll.conf much less often ... break my setup once, fine ... screw me twice, i stab you: *stab*
(Portage version: 2.1.4_rc12)
Diffstat (limited to 'net-print/hplip')
-rw-r--r-- | net-print/hplip/hplip-2.7.10.ebuild | 19 | ||||
-rw-r--r-- | net-print/hplip/hplip-2.7.12.ebuild | 19 |
2 files changed, 22 insertions, 16 deletions
diff --git a/net-print/hplip/hplip-2.7.10.ebuild b/net-print/hplip/hplip-2.7.10.ebuild index c56c3e4ee156..0a463151087f 100644 --- a/net-print/hplip/hplip-2.7.10.ebuild +++ b/net-print/hplip/hplip-2.7.10.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-print/hplip/hplip-2.7.10.ebuild,v 1.5 2007/12/26 09:46:05 drac Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-print/hplip/hplip-2.7.10.ebuild,v 1.6 2007/12/30 18:39:13 vapier Exp $ inherit eutils linux-info @@ -110,13 +110,16 @@ src_install() { } pkg_preinst() { - if ! use minimal && use scanner ; then - insinto /etc/sane.d - [ -e /etc/sane.d/dll.conf ] && cp /etc/sane.d/dll.conf . - [ -e "${ROOT}"/etc/sane.d/dll.conf ] && cp "${ROOT}"/etc/sane.d/dll.conf . - grep -q hpaio dll.conf || echo hpaio >> "${T}"/dll.conf - doins "${T}"/dll.conf - fi + # try to be very conservative as to when we screw around with config files + use minimal && return 0 + use scanner || return 0 + [[ ! -e ${ROOT}/etc/sane.d/dll.conf ]] && return 0 + grep -qs '\<hpaio\>' "${ROOT}"/etc/sane.d/dll.conf && return 0 + + cp "${ROOT}"/etc/sane.d/dll.conf "${T}"/dll.conf || return 1 + echo hpaio >> "${T}"/dll.conf + insinto /etc/sane.d + doins "${T}"/dll.conf } pkg_postinst() { diff --git a/net-print/hplip/hplip-2.7.12.ebuild b/net-print/hplip/hplip-2.7.12.ebuild index caa97d8a2beb..388ee7df270e 100644 --- a/net-print/hplip/hplip-2.7.12.ebuild +++ b/net-print/hplip/hplip-2.7.12.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-print/hplip/hplip-2.7.12.ebuild,v 1.1 2007/12/23 10:29:11 calchan Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-print/hplip/hplip-2.7.12.ebuild,v 1.2 2007/12/30 18:39:13 vapier Exp $ inherit eutils linux-info @@ -110,13 +110,16 @@ src_install() { } pkg_preinst() { - if ! use minimal && use scanner ; then - insinto /etc/sane.d - [ -e /etc/sane.d/dll.conf ] && cp /etc/sane.d/dll.conf . - [ -e "${ROOT}"/etc/sane.d/dll.conf ] && cp "${ROOT}"/etc/sane.d/dll.conf . - grep -q hpaio dll.conf || echo hpaio >> "${T}"/dll.conf - doins "${T}"/dll.conf - fi + # try to be very conservative as to when we screw around with config files + use minimal && return 0 + use scanner || return 0 + [[ ! -e ${ROOT}/etc/sane.d/dll.conf ]] && return 0 + grep -qs '\<hpaio\>' "${ROOT}"/etc/sane.d/dll.conf && return 0 + + cp "${ROOT}"/etc/sane.d/dll.conf "${T}"/dll.conf || return 1 + echo hpaio >> "${T}"/dll.conf + insinto /etc/sane.d + doins "${T}"/dll.conf } pkg_postinst() { |