URL: https://bugs.gentoo.org/487478 --- bin/phase-helpers.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh index ec48c94..59c053a 100644 --- a/bin/phase-helpers.sh +++ b/bin/phase-helpers.sh @@ -512,7 +512,9 @@ econf() { -name config.guess -o -name config.sub ')' -print0 | \ while read -r -d $'\0' x ; do __vecho " * econf: updating ${x/${WORKDIR}\/} with ${EPREFIX}/usr/share/gnuconfig/${x##*/}" - cp -f "${EPREFIX}"/usr/share/gnuconfig/"${x##*/}" "${x}" + # Make sure we do this atomically incase we're run in parallel. #487478 + cp -f "${EPREFIX}"/usr/share/gnuconfig/"${x##*/}" "${x}.$$" + mv -f "${x}.$$" "${x}" done fi -- 1.8.4.3