| 1 | # Copyright 2005 Gentoo Foundation |
1 | # Copyright 2005 Gentoo Foundation |
| 2 | # Distributed under the terms of the GNU General Public License, v2 or later |
2 | # Distributed under the terms of the GNU General Public License, v2 or later |
| 3 | # $Header: /var/cvsroot/gentoo-x86/eclass/twisted.eclass,v 1.3 2006/02/13 22:28:07 marienz Exp $ |
3 | # $Header: /var/cvsroot/gentoo-x86/eclass/twisted.eclass,v 1.4 2006/04/09 23:18:36 marienz Exp $ |
| 4 | # |
4 | # |
| 5 | # Author: Marien Zwart <marienz@gentoo.org> |
5 | # Author: Marien Zwart <marienz@gentoo.org> |
| 6 | # |
6 | # |
| 7 | # eclass to aid installing and testing twisted packages. |
7 | # eclass to aid installing and testing twisted packages. |
| 8 | # |
8 | # |
| … | |
… | |
| 28 | twisted_src_test() { |
28 | twisted_src_test() { |
| 29 | python_version |
29 | python_version |
| 30 | # This is a hack to make tests work without installing to the live |
30 | # This is a hack to make tests work without installing to the live |
| 31 | # filesystem. We copy the twisted site-packages to a temporary |
31 | # filesystem. We copy the twisted site-packages to a temporary |
| 32 | # dir, install there, and run from there. |
32 | # dir, install there, and run from there. |
| 33 | local spath="usr/$(get_libdir)/python${PYVER}/site-packages/" |
33 | local spath="usr/lib/python${PYVER}/site-packages/" |
| 34 | mkdir -p "${T}/${spath}" |
34 | mkdir -p "${T}/${spath}" |
| 35 | cp -R "${ROOT}${spath}/twisted" "${T}/${spath}" || die |
35 | cp -R "${ROOT}${spath}/twisted" "${T}/${spath}" || die |
| 36 | if has_version ">=dev-lang/python-2.3"; then |
36 | if has_version ">=dev-lang/python-2.3"; then |
| 37 | ${python} setup.py install --root="${T}" --no-compile --force || die |
37 | ${python} setup.py install --root="${T}" --no-compile --force || die |
| 38 | else |
38 | else |