From b4e1218cd232d930e7702a6c0e6aa66c9e000a2b Mon Sep 17 00:00:00 2001 From: Peter Alfredsen Date: Wed, 14 Jan 2009 17:17:17 +0000 Subject: Update multilib_comply to allow for different mv_commands. Also complyize bin dirs. --- eclass/mono.eclass | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'eclass/mono.eclass') diff --git a/eclass/mono.eclass b/eclass/mono.eclass index 966785d04d6e..0fe28ee1bc5f 100644 --- a/eclass/mono.eclass +++ b/eclass/mono.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/mono.eclass,v 1.11 2009/01/05 17:12:34 loki_val Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/mono.eclass,v 1.12 2009/01/14 17:17:17 loki_val Exp $ # @ECLASS: mono.eclass # @MAINTAINER: @@ -43,14 +43,14 @@ egacinstall() { } mono_multilib_comply() { - local dir finddirs=() + local dir finddirs=() mv_command=${mv_command:-mv} if [[ -d "${D}/usr/lib" && "$(get_libdir)" != "lib" ]] then if ! [[ -d "${D}"/usr/"$(get_libdir)" ]] then mkdir "${D}"/usr/"$(get_libdir)" || die "Couldn't mkdir ${D}/usr/$(get_libdir)" fi - cp -ar "${D}"/usr/lib/* "${D}"/usr/"$(get_libdir)"/ || die "Moving files into correct libdir failed" + ${mv_command} "${D}"/usr/lib/* "${D}"/usr/"$(get_libdir)"/ || die "Moving files into correct libdir failed" rm -rf "${D}"/usr/lib for dir in "${D}"/usr/"$(get_libdir)"/pkgconfig "${D}"/usr/share/pkgconfig do @@ -62,6 +62,17 @@ mono_multilib_comply() { $(find "${finddirs[@]}" -name '*.pc') \ || die "Sedding some sense into pkgconfig files failed." fi + if [[ -d "${D}/usr/bin" ]] + then + for exe in "${D}/usr/bin"/* + do + if [[ "$(file "${exe}")" == *"shell script text"* ]] + then + sed -r -i -e ":/lib(/|$): s:/lib(/|$):/$(get_libdir)\1:" \ + "${exe}" || die "Sedding some sense into ${exe} failed" + fi + done + fi fi } -- cgit v1.2.3-65-gdbad