From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 5759D13829C for ; Fri, 10 Jun 2016 03:30:02 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2DC5B141F9; Fri, 10 Jun 2016 03:29:56 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 0CEF514229 for ; Fri, 10 Jun 2016 03:29:55 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 4A54D340C6F for ; Fri, 10 Jun 2016 03:29:54 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 821DD2331 for ; Fri, 10 Jun 2016 03:29:50 +0000 (UTC) From: "Benda XU" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Benda XU" Message-ID: <1465523249.10f6517e6c32eb8777a51ae08492692fcd540dfc.heroxbd@gentoo> Subject: [gentoo-commits] repo/proj/prefix:rap0 commit in: scripts/ X-VCS-Repository: repo/proj/prefix X-VCS-Files: scripts/bootstrap-prefix.sh X-VCS-Directories: scripts/ X-VCS-Committer: heroxbd X-VCS-Committer-Name: Benda XU X-VCS-Revision: 10f6517e6c32eb8777a51ae08492692fcd540dfc X-VCS-Branch: rap0 Date: Fri, 10 Jun 2016 03:29:50 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 9ea9ad20-f2c3-460f-b413-1e496644ca3c X-Archives-Hash: 6f8b397a49c63acc6737db6c62297a01 commit: 10f6517e6c32eb8777a51ae08492692fcd540dfc Author: Benda Xu gentoo org> AuthorDate: Thu May 26 09:41:35 2016 +0000 Commit: Benda XU gentoo org> CommitDate: Fri Jun 10 01:47:29 2016 +0000 URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=10f6517e bootstrap-prefix.sh: get_libdir for multilib support on RAP. scripts/bootstrap-prefix.sh | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/scripts/bootstrap-prefix.sh b/scripts/bootstrap-prefix.sh index 4fba6df..cb649dc 100755 --- a/scripts/bootstrap-prefix.sh +++ b/scripts/bootstrap-prefix.sh @@ -9,6 +9,7 @@ eerror() { echo "!!! $*" 1>&2; } einfo() { echo "* $*"; } is-rap() { [[ ${BASH_SOURCE} = *rap.sh ]]; } rapx() { is-rap && echo $1 || echo $2; } +get_libdir() { portageq envvar LIBDIR_$(portageq envvar ABI) || echo lib; } # prefer gtar over tar [[ x$(type -t gtar) == "xfile" ]] \ @@ -407,7 +408,7 @@ EOF do_tree() { local x - for x in etc{,/portage} usr/{{,s}bin,lib} var/tmp var/lib/portage var/log/portage var/db; + for x in etc{,/portage} usr/{{,s}bin,$(rapx "" lib)} var/tmp var/lib/portage var/log/portage var/db; do [[ -d ${ROOT}/${x} ]] || mkdir -p "${ROOT}/${x}" done @@ -423,7 +424,7 @@ do_tree() { [[ -e ${ROOT}/${x} ]] || ( cd "${ROOT}" && ln -s usr/${x} ) done else - for x in lib sbin ; do + for x in $(rapx "" lib) sbin ; do [[ -d ${ROOT}/${x} ]] || mkdir -p "${ROOT}/${x}" done fi @@ -531,7 +532,8 @@ bootstrap_portage() { [[ -x ${ROOT}/tmp/bin/bash ]] || [[ ! -x ${ROOT}/tmp/usr/bin/bash ]] || ln -s ../usr/bin/bash "${ROOT}"/tmp/bin/bash || return 1 [[ -x ${ROOT}/tmp/bin/bash ]] || ln -s "${BASH}" "${ROOT}"/tmp/bin/bash || return 1 [[ -x ${ROOT}/tmp/bin/sh ]] || ln -s bash "${ROOT}"/tmp/bin/sh || return 1 - [[ -x ${ROOT}/bin/sh ]] || ln -s ../tmp/bin/sh "${ROOT}"/bin/sh || return 1 + [[ -x ${ROOT}/bin/bash ]] || ln -s ../tmp/bin/bash "${ROOT}"/bin/bash || return 1 + [[ -x ${ROOT}/bin/sh ]] || ln -s bash "${ROOT}"/bin/sh || return 1 export PORTAGE_BASH="${ROOT}"/tmp/bin/bash einfo "Compiling ${A%-*}" @@ -1333,7 +1335,7 @@ bootstrap_stage3() { configure_toolchain || return 1 export CONFIG_SHELL="${ROOT}"/tmp/bin/bash export CPPFLAGS="-I${ROOT}/usr/include" - export LDFLAGS="-L${ROOT}/usr/lib" + export LDFLAGS="-L${ROOT}/usr/$(get_libdir)" unset CC CXX emerge_pkgs() {