/[gentoo-x86]/eclass/multilib-build.eclass
Gentoo

Diff of /eclass/multilib-build.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.53 Revision 1.54
1# Copyright 1999-2014 Gentoo Foundation 1# Copyright 1999-2014 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/multilib-build.eclass,v 1.53 2014/05/23 07:53:22 mgorny Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/multilib-build.eclass,v 1.54 2014/05/23 17:11:10 mgorny Exp $
4 4
5# @ECLASS: multilib-build.eclass 5# @ECLASS: multilib-build.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# gx86-multilib team <multilib@gentoo.org> 7# gx86-multilib team <multilib@gentoo.org>
8# @AUTHOR: 8# @AUTHOR:
128 echo "${pairs[@]#*:}" 128 echo "${pairs[@]#*:}"
129} 129}
130 130
131# @FUNCTION: multilib_get_enabled_abi_pairs 131# @FUNCTION: multilib_get_enabled_abi_pairs
132# @DESCRIPTION: 132# @DESCRIPTION:
133# Return the ordered list of enabled <use-flag>:<ABI> pairs 133# Return the ordered list of enabled <use-flag>.<ABI> pairs
134# if multilib builds are enabled. The best (most preferred) 134# if multilib builds are enabled. The best (most preferred)
135# ABI will come last. 135# ABI will come last.
136# 136#
137# If multilib is disabled, the default ABI will be returned 137# If multilib is disabled, the default ABI will be returned
138# along with empty <use-flag>. 138# along with empty <use-flag>.
150 # split on ,; we can't switch IFS for function scope because 150 # split on ,; we can't switch IFS for function scope because
151 # paludis is broken (bug #486592), and switching it locally 151 # paludis is broken (bug #486592), and switching it locally
152 # for the split is more complex than cheating like this 152 # for the split is more complex than cheating like this
153 for m_abi in ${m_abis//,/ }; do 153 for m_abi in ${m_abis//,/ }; do
154 if [[ ${m_abi} == ${abi} ]] && use "${m_flag}"; then 154 if [[ ${m_abi} == ${abi} ]] && use "${m_flag}"; then
155 echo "${m_flag}:${abi}" 155 echo "${m_flag}.${abi}"
156 found=1 156 found=1
157 break 2 157 break 2
158 fi 158 fi
159 done 159 done
160 done 160 done
165 # ${DEFAULT_ABI} is the safe fallback. 165 # ${DEFAULT_ABI} is the safe fallback.
166 local abi=${ABI:-${DEFAULT_ABI}} 166 local abi=${ABI:-${DEFAULT_ABI}}
167 167
168 debug-print "${FUNCNAME}: no ABIs enabled, fallback to ${abi}" 168 debug-print "${FUNCNAME}: no ABIs enabled, fallback to ${abi}"
169 debug-print "${FUNCNAME}: ABI=${ABI}, DEFAULT_ABI=${DEFAULT_ABI}" 169 debug-print "${FUNCNAME}: ABI=${ABI}, DEFAULT_ABI=${DEFAULT_ABI}"
170 echo ":${abi}" 170 echo ".${abi}"
171 fi 171 fi
172} 172}
173 173
174# @FUNCTION: _multilib_multibuild_wrapper 174# @FUNCTION: _multilib_multibuild_wrapper
175# @USAGE: <argv>... 175# @USAGE: <argv>...
177# @DESCRIPTION: 177# @DESCRIPTION:
178# Initialize the environment for ABI selected for multibuild. 178# Initialize the environment for ABI selected for multibuild.
179_multilib_multibuild_wrapper() { 179_multilib_multibuild_wrapper() {
180 debug-print-function ${FUNCNAME} "${@}" 180 debug-print-function ${FUNCNAME} "${@}"
181 181
182 local ABI=${MULTIBUILD_VARIANT#*:} 182 local ABI=${MULTIBUILD_VARIANT#*.}
183 local MULTILIB_ABI_FLAG=${MULTIBUILD_VARIANT%:*} 183 local MULTILIB_ABI_FLAG=${MULTIBUILD_VARIANT%.*}
184 184
185 multilib_toolchain_setup "${ABI}" 185 multilib_toolchain_setup "${ABI}"
186 "${@}" 186 "${@}"
187} 187}
188 188

Legend:
Removed from v.1.53  
changed lines
  Added in v.1.54

  ViewVC Help
Powered by ViewVC 1.1.20