From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-555201-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id A41AC138878 for <garchives@archives.gentoo.org>; Tue, 5 Feb 2013 08:39:50 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 5047CE04C1; Tue, 5 Feb 2013 08:39:49 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DD528E04C1 for <gentoo-commits@lists.gentoo.org>; Tue, 5 Feb 2013 08:39:48 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 02B5B33DEBC for <gentoo-commits@lists.gentoo.org>; Tue, 5 Feb 2013 08:39:48 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 9653EE4073 for <gentoo-commits@lists.gentoo.org>; Tue, 5 Feb 2013 08:39:46 +0000 (UTC) From: "Zac Medico" <zmedico@gentoo.org> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" <zmedico@gentoo.org> Message-ID: <1360053570.75b469eace9a0dbd5187cb78531ed064ec29a461.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: bin/ X-VCS-Repository: proj/portage X-VCS-Files: bin/phase-helpers.sh X-VCS-Directories: bin/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 75b469eace9a0dbd5187cb78531ed064ec29a461 X-VCS-Branch: master Date: Tue, 5 Feb 2013 08:39:46 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 7a8db690-01d8-4633-a8e6-84cfc172a758 X-Archives-Hash: 55067fe04ea2769df448bcba6cfe376c commit: 75b469eace9a0dbd5187cb78531ed064ec29a461 Author: Zac Medico <zmedico <AT> gentoo <DOT> org> AuthorDate: Tue Feb 5 08:39:30 2013 +0000 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> CommitDate: Tue Feb 5 08:39:30 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=75b469ea econf: teak timestamp preservation Use the sed -i so we can keep the same inode, avoiding potential issues with loss of file metadata. --- bin/phase-helpers.sh | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh index 7426229..d278dd6 100644 --- a/bin/phase-helpers.sh +++ b/bin/phase-helpers.sh @@ -439,13 +439,12 @@ econf() { if [ -x "${ECONF_SOURCE}/configure" ]; then if [[ -n $CONFIG_SHELL && \ "$(head -n1 "$ECONF_SOURCE/configure")" =~ ^'#!'[[:space:]]*/bin/sh([[:space:]]|$) ]] ; then - sed -e "1s:^#![[:space:]]*/bin/sh:#!$CONFIG_SHELL:" "$ECONF_SOURCE/configure" > \ - "$ECONF_SOURCE/configure._portage_tmp_.$$" || \ - die "Substition of shebang in '$ECONF_SOURCE/configure' failed" # preserve timestamp, see bug #440304 touch -r "$ECONF_SOURCE/configure" "$ECONF_SOURCE/configure._portage_tmp_.$$" || die - mv "$ECONF_SOURCE/configure._portage_tmp_.$$" "$ECONF_SOURCE/configure" || die - chmod +x "$ECONF_SOURCE/configure" || die + sed -e "1s:^#![[:space:]]*/bin/sh:#!$CONFIG_SHELL:" -i "$ECONF_SOURCE/configure" || \ + die "Substition of shebang in '$ECONF_SOURCE/configure' failed" + touch -r "$ECONF_SOURCE/configure._portage_tmp_.$$" "$ECONF_SOURCE/configure" || die + rm -f "$ECONF_SOURCE/configure._portage_tmp_.$$" fi if [ -e "${EPREFIX}"/usr/share/gnuconfig/ ]; then find "${WORKDIR}" -type f '(' \