vapier      15/03/20 18:22:05

  Modified:             eutils.eclass
  Log:
  epatch: include `patch --version` output in the failure log

Revision  Changes    Path
1.443                eclass/eutils.eclass

file : 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/eutils.eclass?rev=1.443&view=markup
plain: 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/eutils.eclass?rev=1.443&content-type=text/plain
diff : 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/eutils.eclass?r1=1.442&r2=1.443

Index: eutils.eclass
===================================================================
RCS file: /var/cvsroot/gentoo-x86/eclass/eutils.eclass,v
retrieving revision 1.442
retrieving revision 1.443
diff -u -r1.442 -r1.443
--- eutils.eclass       14 Jan 2015 22:50:02 -0000      1.442
+++ eutils.eclass       20 Mar 2015 18:22:05 -0000      1.443
@@ -1,6 +1,6 @@
 # Copyright 1999-2015 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/eutils.eclass,v 1.442 2015/01/14 
22:50:02 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/eutils.eclass,v 1.443 2015/03/20 
18:22:05 vapier Exp $
 
 # @ECLASS: eutils.eclass
 # @MAINTAINER:
@@ -523,6 +523,10 @@
                        einfo "  ${patchname} ..."
                fi
 
+               # Handle aliased patch command #404447 #461568
+               local patch="patch"
+               eval $(alias patch 2>/dev/null | sed 's:^alias ::')
+
                # most of the time, there will only be one run per unique name,
                # but if there are more, make sure we get unique log filenames
                local STDERR_TARGET="${T}/${patchname}.out"
@@ -530,7 +534,13 @@
                        STDERR_TARGET="${T}/${patchname}-$$.out"
                fi
 
-               printf "***** %s *****\nPWD: %s\n\n" "${patchname}" "${PWD}" > 
"${STDERR_TARGET}"
+               printf "***** %s *****\nPWD: %s\nPATCH TOOL: %s -> %s\nVERSION 
INFO:\n%s\n\n" \
+                       "${patchname}" \
+                       "${PWD}" \
+                       "${patch}" \
+                       "$(type -P "${patch}")" \
+                       "$(${patch} --version)" \
+                       > "${STDERR_TARGET}"
 
                # Decompress the patch if need be
                local count=0
@@ -574,9 +584,6 @@
 
                # Dynamically detect the correct -p# ... i'm lazy, so shoot me 
:/
                local patch_cmd
-               # Handle aliased patch command #404447 #461568
-               local patch="patch"
-               eval $(alias patch 2>/dev/null | sed 's:^alias ::')
                while [[ ${count} -lt 5 ]] ; do
                        patch_cmd="${patch} -p${count} ${EPATCH_OPTS}"
 




Reply via email to