diff options
author | Michał Górny <mgorny@gentoo.org> | 2012-12-01 10:53:40 +0000 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2012-12-01 10:53:40 +0000 |
commit | cd6bd98ae7d7c48a2ff0e388f47ee1074ba2dbc5 (patch) | |
tree | 96380a44404b4b3da2af220479ec8f0a56f4e13e | |
parent | Use intermediate-root install. (diff) | |
download | gentoo-2-cd6bd98ae7d7c48a2ff0e388f47ee1074ba2dbc5.tar.gz gentoo-2-cd6bd98ae7d7c48a2ff0e388f47ee1074ba2dbc5.tar.bz2 gentoo-2-cd6bd98ae7d7c48a2ff0e388f47ee1074ba2dbc5.zip |
Create the wrapper symlinks directly in _distutils-r1_rename_scripts rather than postponing it to distutils-r1_install_all.
-rw-r--r-- | eclass/ChangeLog | 6 | ||||
-rw-r--r-- | eclass/distutils-r1.eclass | 25 |
2 files changed, 11 insertions, 20 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog index f0c2874e3650..3f4da04c5408 100644 --- a/eclass/ChangeLog +++ b/eclass/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for eclass directory # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.535 2012/12/01 10:52:40 mgorny Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.536 2012/12/01 10:53:40 mgorny Exp $ + + 01 Dec 2012; Michał Górny <mgorny@gentoo.org> distutils-r1.eclass: + Create the wrapper symlinks directly in _distutils-r1_rename_scripts rather + than postponing it to distutils-r1_install_all. 01 Dec 2012; Michał Górny <mgorny@gentoo.org> distutils-r1.eclass: Use intermediate-root install. diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass index f0b250284313..34542b5c1f43 100644 --- a/eclass/distutils-r1.eclass +++ b/eclass/distutils-r1.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/distutils-r1.eclass,v 1.22 2012/12/01 10:52:40 mgorny Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/distutils-r1.eclass,v 1.23 2012/12/01 10:53:40 mgorny Exp $ # @ECLASS: distutils-r1 # @MAINTAINER: @@ -268,8 +268,11 @@ _distutils-r1_rename_scripts() { debug-print "${FUNCNAME}: matching shebang: $(head -n 1 "${f}")" local newf=${f}-${EPYTHON} - debug-print "${FUNCNAME}: renamed to ${newf#${D}/}" + debug-print "${FUNCNAME}: renaming to ${newf#${D}/}" mv "${f}" "${newf}" || die + + debug-print "${FUNCNAME}: installing wrapper at ${f#${D}/}" + _python_ln_rel "${path}"/usr/bin/python-exec "${f}" || die fi done < <(find "${path}" -type f -executable -print0) } @@ -309,9 +312,7 @@ distutils-r1_python_install() { # @FUNCTION: distutils-r1_python_install_all # @DESCRIPTION: -# The default python_install_all(). It symlinks wrappers -# for the implementation-suffixed executables and installs -# documentation. +# The default python_install_all(). It installs the documentation. distutils-r1_python_install_all() { debug-print-function ${FUNCNAME} "${@}" @@ -331,20 +332,6 @@ distutils-r1_python_install_all() { if declare -p HTML_DOCS &>/dev/null; then dohtml -r "${HTML_DOCS[@]}" || die "dohtml failed" fi - - # note: keep in sync with ...rename_scripts() - # also, we assume that each script is installed for all impls - local EPYTHON - python_export_best EPYTHON - - local f - while IFS= read -r -d '' f; do - debug-print "${FUNCNAME}: found executable at ${f#${D}/}" - - local wrapf=${f%-${EPYTHON}} - - _python_ln_rel "${ED}"/usr/bin/python-exec "${wrapf}" || die - done < <(find "${D}" -type f -executable -name "*-${EPYTHON}" -print0) } # @FUNCTION: distutils-r1_run_phase |