/[gentoo-x86]/eclass/python-distutils-ng.eclass
Gentoo

Diff of /eclass/python-distutils-ng.eclass

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

Revision 1.27 Revision 1.31
1# Copyright 1999-2012 Gentoo Foundation 1# Copyright 1999-2013 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/Attic/python-distutils-ng.eclass,v 1.27 2012/09/26 12:07:45 hasufell Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/Attic/python-distutils-ng.eclass,v 1.31 2013/09/29 15:04:51 mgorny Exp $
4
5# @DEAD
6# Michał Górny <mgorny@gentoo.org> (29 Sep 2013)
7# This eclass has been superseded by distutils-r1 and python-r1 eclasses
8# and will be removed on 2013-10-29. Please modify your ebuilds to use
9# the new eclasses instead. Bug #450770.
4 10
5# @ECLASS: python-distutils-ng 11# @ECLASS: python-distutils-ng
6# @MAINTAINER: 12# @MAINTAINER:
7# Python herd <python@gentoo.org> 13# Python herd <python@gentoo.org>
8# @AUTHOR: 14# @AUTHOR:
74EXPORT_FUNCTIONS src_prepare src_configure src_compile src_test src_install 80EXPORT_FUNCTIONS src_prepare src_configure src_compile src_test src_install
75 81
76case "${EAPI}" in 82case "${EAPI}" in
77 0|1|2|3) 83 0|1|2|3)
78 die "Unsupported EAPI=${EAPI} (too old) for python-distutils-ng.eclass" ;; 84 die "Unsupported EAPI=${EAPI} (too old) for python-distutils-ng.eclass" ;;
79 4) 85 4|5)
80 # EAPI=4 needed for REQUIRED_USE 86 # EAPI=4 needed for REQUIRED_USE
81 S="${S:-${WORKDIR}/${P}}" 87 S="${S:-${WORKDIR}/${P}}"
82 ;; 88 ;;
83 *) 89 *)
84 die "Unsupported EAPI=${EAPI} (unknown) for python-distutils-ng.eclass" ;; 90 die "Unsupported EAPI=${EAPI} (unknown) for python-distutils-ng.eclass" ;;
96# `python'. 102# `python'.
97_python-distutils-ng_get_binary_for_implementation() { 103_python-distutils-ng_get_binary_for_implementation() {
98 local impl="${1/_/.}" 104 local impl="${1/_/.}"
99 case "${impl}" in 105 case "${impl}" in
100 python?.?|jython?.?) 106 python?.?|jython?.?)
101 echo "/usr/bin/${impl}" ;; 107 echo "${EPREFIX}/usr/bin/${impl}" ;;
102 pypy?.?) 108 pypy?.?)
103 echo "/usr/bin/pypy-c${impl: -3}" ;; 109 echo "${EPREFIX}/usr/bin/pypy-c${impl: -3}" ;;
104 *) 110 *)
105 die "Unsupported implementation: ${1}" ;; 111 die "Unsupported implementation: ${1}" ;;
106 esac 112 esac
107} 113}
108 114
130 python?.?) 136 python?.?)
131 dep_str="dev-lang/python:${dep_str: -3}${_PYTHON_USE}" ;; 137 dep_str="dev-lang/python:${dep_str: -3}${_PYTHON_USE}" ;;
132 jython?.?) 138 jython?.?)
133 dep_str="dev-java/jython:${dep_str: -3}${_PYTHON_USE}" ;; 139 dep_str="dev-java/jython:${dep_str: -3}${_PYTHON_USE}" ;;
134 pypy?.?) 140 pypy?.?)
135 dep_str="dev-python/pypy:${dep_str: -3}${_PYTHON_USE}" ;; 141 dep_str="virtual/pypy:${dep_str: -3}${_PYTHON_USE}" ;;
136 *) 142 *)
137 die "Unsupported implementation: ${impl}" ;; 143 die "Unsupported implementation: ${impl}" ;;
138 esac 144 esac
139 dep_str="python_targets_${impl}? ( ${dep_str} )" 145 dep_str="python_targets_${impl}? ( ${dep_str} )"
140 146
398 python_install_all 404 python_install_all
399 popd &> /dev/null 405 popd &> /dev/null
400 fi 406 fi
401 407
402 if [[ -z "${PYTHON_DISABLE_SCRIPT_REDOS}" ]]; then 408 if [[ -z "${PYTHON_DISABLE_SCRIPT_REDOS}" ]]; then
403 for script_file in $(find "${D}"{,usr/}{,s}bin/ -type f -executable 2> /dev/null); do 409 for script_file in $(find "${ED}"{,usr/}{,s}bin/ -type f -executable 2> /dev/null); do
404 python-distutils-ng_redoscript "/${script_file#${D}}" 410 python-distutils-ng_redoscript "/${script_file#${D}}"
405 done 411 done
406 fi 412 fi
407} 413}

Legend:
Removed from v.1.27  
changed lines
  Added in v.1.31

  ViewVC Help
Powered by ViewVC 1.1.20