diff options
author | Michał Górny <mgorny@gentoo.org> | 2013-03-20 19:00:55 +0000 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2013-03-20 19:00:55 +0000 |
commit | e8e678434b749967202fb972f91260580173c66f (patch) | |
tree | c778c04012f13976614662ca72e46e6675593582 /eclass/python-r1.eclass | |
parent | Remove dodoc INSTALL from 9999 ebuild to reflect upstream change. (diff) | |
download | historical-e8e678434b749967202fb972f91260580173c66f.tar.gz historical-e8e678434b749967202fb972f91260580173c66f.tar.bz2 historical-e8e678434b749967202fb972f91260580173c66f.zip |
Reuse multibuild.eclass in python_export_best.
Diffstat (limited to 'eclass/python-r1.eclass')
-rw-r--r-- | eclass/python-r1.eclass | 24 |
1 files changed, 9 insertions, 15 deletions
diff --git a/eclass/python-r1.eclass b/eclass/python-r1.eclass index 12e3baa60960..b743473522e4 100644 --- a/eclass/python-r1.eclass +++ b/eclass/python-r1.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.49 2013/03/09 13:52:55 mgorny Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/python-r1.eclass,v 1.50 2013/03/20 19:00:55 mgorny Exp $ # @ECLASS: python-r1 # @MAINTAINER: @@ -661,24 +661,18 @@ python_parallel_foreach_impl() { python_export_best() { debug-print-function ${FUNCNAME} "${@}" - _python_validate_useflags - [[ ${#} -gt 0 ]] || set -- EPYTHON PYTHON - local impl best - for impl in "${_PYTHON_ALL_IMPLS[@]}"; do - if has "${impl}" "${PYTHON_COMPAT[@]}" \ - && _python_impl_supported "${impl}" \ - && use "python_targets_${impl}" - then - best=${impl} - fi - done + local best MULTIBUILD_VARIANTS + _python_obtain_impls - [[ ${best+1} ]] || die "python_export_best(): no implementation found!" + _python_set_best() { + best=${MULTIBUILD_VARIANT} + } + multibuild_for_best_variant _python_set_best - debug-print "${FUNCNAME}: Best implementation is: ${impl}" - python_export "${impl}" "${@}" + debug-print "${FUNCNAME}: Best implementation is: ${best}" + python_export "${best}" "${@}" } # @FUNCTION: python_replicate_script |