aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2017-12-16 00:32:54 +0100
committerAndreas K. Hüttel <dilfridge@gentoo.org>2017-12-16 00:32:54 +0100
commit7bbb548b4c5e695fe5cfc439f64c75d07169bd1c (patch)
tree9f459bef1e8b3c47679956d0aa02738360b8302a
parentVersion 1.1 (diff)
downloadbinutils-config-7bbb548b4c5e695fe5cfc439f64c75d07169bd1c.tar.gz
binutils-config-7bbb548b4c5e695fe5cfc439f64c75d07169bd1c.tar.bz2
binutils-config-7bbb548b4c5e695fe5cfc439f64c75d07169bd1c.zip
Version 1.2
https://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/sys-devel/binutils-config/files/binutils-config-1.2?revision=1.1
-rw-r--r--binutils-config9
1 files changed, 7 insertions, 2 deletions
diff --git a/binutils-config b/binutils-config
index e0a31f7..e9ab57b 100644
--- a/binutils-config
+++ b/binutils-config
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/binutils-config/files/Attic/binutils-config-1.1,v 1.1 2004/12/09 02:23:22 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/binutils-config/files/Attic/binutils-config-1.2,v 1.1 2004/12/15 17:00:30 vapier Exp $
# Format of /etc/env.d/binutils/:
# config-TARGET: CURRENT=version for TARGET
@@ -57,7 +57,12 @@ switch_profile() {
LIBPATH="/usr/lib/binutils/${TARGET}/${VER}"
cd "${ROOT}/${LIBPATH}" || exit 1
mkdir -p "${ROOT}"/usr/${TARGET}/lib
- rm -f "${ROOT}"/usr/${TARGET}/lib/ldscripts
+ if [[ -d ${ROOT}/usr/${TARGET}/lib/ldscripts ]] ; then
+ # When upgrading, we need to clean up ldscripts
+ rm -r "${ROOT}"/usr/${TARGET}/lib/ldscripts
+ else
+ rm -f "${ROOT}"/usr/${TARGET}/lib/ldscripts
+ fi
ln -sf "${LIBPATH}/ldscripts" "${ROOT}"/usr/${TARGET}/lib/ldscripts
if [[ ${TARGET} = ${HOST} ]] ; then
dstlib="${ROOT}"/usr/${HOST}/lib