From: Mike Frysinger Date: Wed, 4 Jan 2012 06:22:12 +0000 (+0000) Subject: check EBUILD_PHASE all the time in restore_config to catch mis-use even when USE... X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=11b58c3a4af43168333d788e2a9f364227c7071e;p=gentoo.git check EBUILD_PHASE all the time in restore_config to catch mis-use even when USE=-savedconfig --- diff --git a/eclass/savedconfig.eclass b/eclass/savedconfig.eclass index f07ac8658562..89f9eebfe4c2 100644 --- a/eclass/savedconfig.eclass +++ b/eclass/savedconfig.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/savedconfig.eclass,v 1.17 2012/01/04 06:19:09 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/savedconfig.eclass,v 1.18 2012/01/04 06:22:12 vapier Exp $ # @ECLASS: savedconfig.eclass # @MAINTAINER: @@ -76,12 +76,13 @@ save_config() { # ${PORTAGE_CONFIGROOT}/etc/portage/savedconfig/${CATEGORY}/${PN} # @CODE restore_config() { - use savedconfig || return - case ${EBUILD_PHASE} in unpack|compile|configure|prepare) ;; *) die "Bad package! restore_config only for use in src_{unpack,compile,configure,prepare} functions!" ;; esac + + use savedconfig || return + local found check configfile local base=${PORTAGE_CONFIGROOT}/etc/portage/savedconfig for check in {${CATEGORY}/${PF},${CATEGORY}/${P},${CATEGORY}/${PN}}; do