From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by nuthatch.gentoo.org with esmtp (Exim 4.50) id 1ENElH-0006IN-TT for garchives@archives.gentoo.org; Wed, 05 Oct 2005 19:17:08 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.13.5/8.13.5) with SMTP id j95J829C020641; Wed, 5 Oct 2005 19:08:02 GMT Received: from smtp.gentoo.org (smtp.gentoo.org [134.68.220.30]) by robin.gentoo.org (8.13.5/8.13.5) with ESMTP id j95J6Ia5021634 for ; Wed, 5 Oct 2005 19:06:18 GMT Received: from cpe-65-26-255-237.wi.res.rr.com ([65.26.255.237] helo=nightcrawler) by smtp.gentoo.org with esmtpa (Exim 4.43) id 1ENEiz-0003u7-Vc for gentoo-dev@lists.gentoo.org; Wed, 05 Oct 2005 19:14:46 +0000 Date: Wed, 5 Oct 2005 14:14:57 -0500 From: Brian Harring To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] Re: [gentoo-portage-dev] allow extra info to be echod on die Message-ID: <20051005191457.GA10159@nightcrawler> References: <20051005163317.GA6783@toucan.gentoo.org> <20051005164801.GC7855@nightcrawler> <20051005184709.GD7855@nightcrawler> <20051005190423.GG28593@olive.flatmonk> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Reply-to: gentoo-dev@lists.gentoo.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="vkogqOf2sHV7VnPd" Content-Disposition: inline In-Reply-To: <20051005190423.GG28593@olive.flatmonk> User-Agent: Mutt/1.5.8i X-Archives-Salt: e5eb217d-0abc-4210-86f7-e29fe830fd1c X-Archives-Hash: 44d5f2a4b58ce6e787da6459b9ea1a26 --vkogqOf2sHV7VnPd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Oct 05, 2005 at 03:04:23PM -0400, Aron Griffis wrote: > Brian Harring wrote: [Wed Oct 05 2005, 02:47:09PM EDT] > >> diefunc() { > >> local funcname=3D"$1" lineno=3D"$2" exitcode=3D"$3" > >> shift 3 > >> @@ -289,6 +291,7 @@ > >> echo "!!! ${*:-(no error message)}" >&2 > >> echo "!!! If you need support, post the topmost build error, N= OT=20 > >this status message." >&2 > >> echo >&2 > >> + for x in $EBUILD_DEATH_HOOKS; do > >> + ${x} "$1" "$2" "$3" > >> + done > >> exit 1 > >> } >=20 > Is this exactly what went in? It looks like you're trying to use > positional params that were shifted earlier. No, the hooks are called with "$@" actually, plus some checks to=20 ensure that A) the output goes to stderr, which is the norm for die B) the hooks aren't engaged during depends phase. if people are after the func/line/exit code being handed to the hook,=20 it can be changed, the intention was for this to allow dumping extra=20 debug info. ~harring --vkogqOf2sHV7VnPd Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFDRCYxvdBxRoA3VU0RAh7SAJ0R9xk+JPKrBM4Qarkll42eXEbeKgCfdwEo OkkvpnZUNVBnPnF5IIe6KRI= =fHRy -----END PGP SIGNATURE----- --vkogqOf2sHV7VnPd-- -- gentoo-dev@gentoo.org mailing list