diff options
author | Dirkjan Ochtman <djc@gentoo.org> | 2011-07-04 10:59:25 +0000 |
---|---|---|
committer | Dirkjan Ochtman <djc@gentoo.org> | 2011-07-04 10:59:25 +0000 |
commit | f1439e8a833fe1a60042952ba9e5c9267cd0e3ba (patch) | |
tree | 55f826dbb8c7a0a661aa3d3a1788066da1931c39 /eclass/python.eclass | |
parent | Fix warning about skipped tests being shown even when tests are disabled by t... (diff) | |
download | gentoo-2-f1439e8a833fe1a60042952ba9e5c9267cd0e3ba.tar.gz gentoo-2-f1439e8a833fe1a60042952ba9e5c9267cd0e3ba.tar.bz2 gentoo-2-f1439e8a833fe1a60042952ba9e5c9267cd0e3ba.zip |
Support EAPI >=4 in python_src_install().
(Patch by Arfrever. Backported from python overlay.)
Diffstat (limited to 'eclass/python.eclass')
-rw-r--r-- | eclass/python.eclass | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/eclass/python.eclass b/eclass/python.eclass index 92ca7694183b..326069b53168 100644 --- a/eclass/python.eclass +++ b/eclass/python.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/python.eclass,v 1.112 2011/07/04 10:50:28 djc Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/python.eclass,v 1.113 2011/07/04 10:59:25 djc Exp $ # @ECLASS: python.eclass # @MAINTAINER: @@ -602,7 +602,7 @@ if ! has "${EAPI:-0}" 0 1; then python_copy_sources } - for python_default_function in src_configure src_compile src_test src_install; do + for python_default_function in src_configure src_compile src_test; do eval "python_${python_default_function}() { _python_check_python_pkg_setup_execution @@ -615,6 +615,26 @@ if ! has "${EAPI:-0}" 0 1; then done unset python_default_function + python_src_install() { + if ! _python_package_supporting_installation_for_multiple_python_abis; then + die "${FUNCNAME}() cannot be used in ebuilds of packages not supporting installation for multiple Python ABIs" + fi + + _python_check_python_pkg_setup_execution + + if has "${EAPI:-0}" 0 1 2 3; then + python_execute_function -d -s -- "$@" + else + python_installation() { + emake DESTDIR="${T}/images/${PYTHON_ABI}" install "$@" + } + python_execute_function -s python_installation "$@" + unset python_installation + + python_merge_intermediate_installation_images "${T}/images" + fi + } + if [[ -n "${PYTHON_EXPORT_PHASE_FUNCTIONS}" ]]; then EXPORT_FUNCTIONS src_prepare src_configure src_compile src_test src_install fi |