commit:     1bf781b83fdfd96e662ec76a54ff5ca0b9aad5f6
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Wed Nov  6 11:18:47 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Nov  6 11:18:47 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1bf781b8

toolchain.eclass: further death hook fixes

Fixes: d82f81cd65b9a668bd7940151e3fa876d4b0ce92
Signed-off-by: Sam James <sam <AT> gentoo.org>

 eclass/toolchain.eclass | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index aa7134b23e8e..b25c5dcf0929 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -2980,10 +2980,10 @@ toolchain_death_notice() {
        for dir in "${WORKDIR}"/build-jit "${WORKDIR}"/build ; do
                if [[ -e "${dir}" ]] ; then
                        pushd "${WORKDIR}" >/dev/null
-                       (echo '' | $(tc-getCC ${CTARGET}) ${CFLAGS} -v -E - 
2>&1) > gccinfo.log
-                       [[ -e "${T}"/build.log ]] && cp "${T}"/build.log .
+                       (echo '' | $(tc-getCC ${CTARGET}) ${CFLAGS} -v -E - 
2>&1) > "${dir}"/gccinfo.log
+                       [[ -e "${T}"/build.log ]] && cp "${T}"/build.log 
"${dir}"
                        tar -arf "${WORKDIR}"/gcc-build-logs.tar.xz \
-                               "${dir}"/gccinfo.log "${dir}"/build.log $(find 
-name "${dir}"/config.log)
+                               "${dir#${WORKDIR}/}"/gccinfo.log 
"${dir#${WORKDIR}/}"/build.log $(find -name "${dir}"/config.log)
                        rm "${dir}"/gccinfo.log "${dir}"/build.log
                        eerror
                        eerror "Please include ${WORKDIR}/gcc-build-logs.tar.xz 
in your bug report."

Reply via email to