automatically create a tarball of all config.log files when we fail, and tell the...
authorMike Frysinger <vapier@gentoo.org>
Tue, 13 Dec 2011 00:21:54 +0000 (00:21 +0000)
committerMike Frysinger <vapier@gentoo.org>
Tue, 13 Dec 2011 00:21:54 +0000 (00:21 +0000)
eclass/toolchain.eclass

index 7a44ae84b9986820b9bfce171f72a41d304ae02f..33649d1bdf92ff4b9df567a2cc7673bdcc6131b7 100644 (file)
@@ -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/toolchain.eclass,v 1.510 2011/12/10 08:55:37 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.511 2011/12/13 00:21:54 vapier Exp $
 #
 # Maintainer: Toolchain Ninjas <toolchain@gentoo.org>
 
@@ -1216,6 +1216,16 @@ gcc_do_configure() {
        popd > /dev/null
 }
 
+has toolchain_death_notice ${EBUILD_DEATH_HOOKS} || EBUILD_DEATH_HOOKS+=" toolchain_death_notice"
+toolchain_death_notice() {
+       pushd "${WORKDIR}"/build >/dev/null
+       tar jcf gcc-build-logs.tar.bz2 $(find -name config.log)
+       eerror
+       eerror "Please include ${PWD}/gcc-build-logs.tar.bz2 in your bug report"
+       eerror
+       popd >/dev/null
+}
+
 # This function accepts one optional argument, the make target to be used.
 # If ommitted, gcc_do_make will try to guess whether it should use all,
 # profiledbootstrap, or bootstrap-lean depending on CTARGET and arch. An