Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 339366 Details for
Bug 458192
dev-vcs/subversion: please review python-r1 conversion
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
2) python-r1 conversion, -r1
0002-Convert-to-distutils-r1.patch (text/plain), 9.24 KB, created by
Michał Górny
on 2013-02-19 14:38:54 UTC
(
hide
)
Description:
2) python-r1 conversion, -r1
Filename:
MIME Type:
Creator:
Michał Górny
Created:
2013-02-19 14:38:54 UTC
Size:
9.24 KB
patch
obsolete
>From dfbcb88128080d3745d820a99017d7c7d99dc2bd Mon Sep 17 00:00:00 2001 >From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> >Date: Mon, 18 Feb 2013 23:22:55 +0100 >Subject: [PATCH 2/2] Convert to distutils-r1. > >--- > gx86/dev-vcs/subversion/subversion-1.7.7-r1.ebuild | 151 +++++++++++---------- > 1 file changed, 77 insertions(+), 74 deletions(-) > >diff --git a/gx86/dev-vcs/subversion/subversion-1.7.7-r1.ebuild b/gx86/dev-vcs/subversion/subversion-1.7.7-r1.ebuild >index eeac3e0..7913fc2 100644 >--- a/gx86/dev-vcs/subversion/subversion-1.7.7-r1.ebuild >+++ b/gx86/dev-vcs/subversion/subversion-1.7.7-r1.ebuild >@@ -3,12 +3,12 @@ > # $Header: /var/cvsroot/gentoo-x86/dev-vcs/subversion/subversion-1.7.7.ebuild,v 1.12 2013/01/26 17:44:46 grobian Exp $ > > EAPI=5 >-SUPPORT_PYTHON_ABIS="1" >-RESTRICT_PYTHON_ABIS="3.* *-jython *-pypy-*" >+PYTHON_COMPAT=( python{2_5,2_6,2_7} ) >+DISTUTILS_OPTIONAL=1 > WANT_AUTOMAKE="none" > MY_P="${P/_/-}" > >-inherit autotools bash-completion-r1 db-use depend.apache elisp-common flag-o-matic java-pkg-opt-2 libtool multilib perl-module python eutils >+inherit autotools bash-completion-r1 db-use depend.apache distutils-r1 elisp-common flag-o-matic java-pkg-opt-2 libtool multilib perl-module eutils > > DESCRIPTION="Advanced version control system" > HOMEPAGE="http://subversion.apache.org/" >@@ -26,11 +26,11 @@ COMMON_DEPEND=">=dev-db/sqlite-3.4 > dev-libs/expat > sys-libs/zlib > berkdb? ( >=sys-libs/db-4.0.14 ) >- ctypes-python? ( =dev-lang/python-2* ) >+ ctypes-python? ( ${PYTHON_DEPS} ) > gnome-keyring? ( dev-libs/glib:2 sys-apps/dbus gnome-base/gnome-keyring ) > kde? ( sys-apps/dbus x11-libs/qt-core:4 x11-libs/qt-dbus:4 x11-libs/qt-gui:4 >=kde-base/kdelibs-4:4 ) > perl? ( dev-lang/perl ) >- python? ( =dev-lang/python-2* ) >+ python? ( ${PYTHON_DEPS} ) > ruby? ( >=dev-lang/ruby-1.8.2:1.8 ) > sasl? ( dev-libs/cyrus-sasl ) > webdav-neon? ( >=net-libs/neon-0.28 ) >@@ -41,7 +41,9 @@ RDEPEND="${COMMON_DEPEND} > kde? ( kde-base/kwalletd ) > nls? ( virtual/libintl ) > perl? ( dev-perl/URI )" >+# Note: ctypesgen doesn't need PYTHON_USEDEP, it's used once > DEPEND="${COMMON_DEPEND} >+ ${PYTHON_DEPS} > !!<sys-apps/sandbox-1.6 > ctypes-python? ( dev-python/ctypesgen ) > doc? ( app-doc/doxygen ) >@@ -85,7 +87,8 @@ pkg_setup() { > java-pkg-opt-2_pkg_setup > > if use ctypes-python || use python; then >- python_pkg_setup >+ # for build-time scripts >+ python_export_best > fi > > if ! use webdav-neon && ! use webdav-serf; then >@@ -118,8 +121,6 @@ src_prepare() { > -e "s/\(BUILD_RULES=.*\) bdb-test\(.*\)/\1\2/g" \ > -e "s/\(BUILD_RULES=.*\) test\(.*\)/\1\2/g" configure.ac > >- sed -e "/SWIG_PY_INCLUDES=/s/\$ac_cv_python_includes/\\\\\$(PYTHON_INCLUDES)/" -i build/ac-macros/swig.m4 || die "sed failed" >- > # this bites us in particular on Solaris > sed -i -e '1c\#!/usr/bin/env sh' build/transform_libtool_scripts.sh || \ > die "/bin/sh is not POSIX shell!" >@@ -127,7 +128,14 @@ src_prepare() { > eautoconf > elibtoolize > >- sed -e "s/libsvn_swig_py-1\.la/libsvn_swig_py-\$(PYTHON_VERSION)-1.la/" -i build-outputs.mk || die "sed failed" >+ sed -e 's/\(libsvn_swig_py\)-\(1\.la\)/\1-$(EPYTHON)-\2/g' \ >+ -i build-outputs.mk || die "sed failed" >+ >+ if use python; then >+ # XXX: make python_copy_sources accept path >+ S=${S}/subversion/bindings/swig/python python_copy_sources >+ rm -r "${S}"/subversion/bindings/swig/python || die >+ fi > } > > src_configure() { >@@ -182,7 +190,9 @@ src_configure() { > myconf+=" --disable-disallowing-of-undefined-references" > > #force ruby-1.8 for bug 399105 >+ #allow overriding Python include directory > ac_cv_path_RUBY="${EPREFIX}"/usr/bin/ruby18 ac_cv_path_RDOC="${EPREFIX}"/usr/bin/rdoc18 \ >+ ac_cv_python_includes='-I$(PYTHON_INCLUDEDIR)' \ > econf --libdir="${EPREFIX}/usr/$(get_libdir)" \ > $(use_with apache2 apxs "${APXS}") \ > $(use_with berkdb berkeley-db "db.h:${EPREFIX}/usr/include/db${SVN_BDB_VERSION}::db-${SVN_BDB_VERSION}") \ >@@ -209,36 +219,30 @@ src_compile() { > emake local-all > > if use ctypes-python; then >- python_copy_sources subversion/bindings/ctypes-python >- rm -fr subversion/bindings/ctypes-python >- ctypes_python_bindings_building() { >- rm -f subversion/bindings/ctypes-python >- ln -s ctypes-python-${PYTHON_ABI} subversion/bindings/ctypes-python >- emake ctypes-python >- } >- python_execute_function \ >- --action-message 'Building of Subversion Ctypes Python bindings with $(python_get_implementation) $(python_get_version)' \ >- --failure-message 'Building of Subversion Ctypes Python bindings failed with $(python_get_implementation) $(python_get_version)' \ >- ctypes_python_bindings_building >+ # pre-generate .py files >+ use ctypes-python && emake ctypes-python >+ >+ pushd subversion/bindings/ctypes-python >/dev/null || die >+ distutils-r1_src_compile >+ popd >/dev/null || die > fi > > if use python; then >- python_copy_sources subversion/bindings/swig/python >- rm -fr subversion/bindings/swig/python >- swig_python_bindings_building() { >- rm -f subversion/bindings/swig/python >- ln -s python-${PYTHON_ABI} subversion/bindings/swig/python >- emake \ >- PYTHON_INCLUDES="-I${EPREFIX}$(python_get_includedir)" \ >- PYTHON_VERSION="$(python_get_version)" \ >- swig_pydir="${EPREFIX}$(python_get_sitedir)/libsvn" \ >- swig_pydir_extra="${EPREFIX}$(python_get_sitedir)/svn" \ >- swig-py >+ swig_py_compile() { >+ local p=subversion/bindings/swig/python >+ ln -fs "${BUILD_DIR}" ${p} || die >+ >+ python_export PYTHON_INCLUDEDIR >+ emake swig-py \ >+ swig_pydir="$(python_get_sitedir)/libsvn" \ >+ swig_pydir_extra="$(python_get_sitedir)/svn" >+ >+ rm ${p} || die > } >- python_execute_function \ >- --action-message 'Building of Subversion SWIG Python bindings with $(python_get_implementation) $(python_get_version)' \ >- --failure-message 'Building of Subversion SWIG Python bindings failed with $(python_get_implementation) $(python_get_version)' \ >- swig_python_bindings_building >+ >+ # this will give us proper BUILD_DIR for symlinking >+ BUILD_DIR=python \ >+ python_foreach_impl swig_py_compile > fi > > if use perl; then >@@ -266,40 +270,55 @@ src_compile() { > fi > } > >+src_test() { >+ default >+ >+ if use ctypes-python; then >+ python_test() { >+ "${PYTHON}" subversion/bindings/ctypes-python/test/run_all.py \ >+ || die "ctypes-python tests fail with ${EPYTHON}" >+ } >+ >+ distutils-r1_src_test >+ fi >+ >+ if use python; then >+ swig_py_test() { >+ pushd "${BUILD_DIR}" >/dev/null || die >+ "${PYTHON}" tests/run_all.py || die "swig-py tests fail with ${EPYTHON}" >+ popd >/dev/null || die >+ } >+ >+ BUILD_DIR=subversion/bindings/swig/python \ >+ python_foreach_impl swig_py_test >+ fi >+} >+ > src_install() { > emake -j1 DESTDIR="${D}" local-install > > if use ctypes-python; then >- ctypes_python_bindings_installation() { >- rm -f subversion/bindings/ctypes-python >- ln -s ctypes-python-${PYTHON_ABI} subversion/bindings/ctypes-python >- emake DESTDIR="${D}" install-ctypes-python >- } >- python_execute_function \ >- --action-message 'Installation of Subversion Ctypes Python bindings with $(python_get_implementation) $(python_get_version)' \ >- --failure-message 'Installation of Subversion Ctypes Python bindings failed with $(python_get_implementation) $(python_get_version)' \ >- ctypes_python_bindings_installation >+ pushd subversion/bindings/ctypes-python >/dev/null || die >+ distutils-r1_src_install >+ popd >/dev/null || die > fi > > if use python; then >- swig_python_bindings_installation() { >- rm -f subversion/bindings/swig/python >- ln -s python-${PYTHON_ABI} subversion/bindings/swig/python >+ swig_py_install() { >+ local p=subversion/bindings/swig/python >+ ln -s "${BUILD_DIR}" ${p} || die >+ > emake \ > DESTDIR="${D}" \ >- PYTHON_VERSION="$(python_get_version)" \ >- swig_pydir="${EPREFIX}$(python_get_sitedir)/libsvn" \ >- swig_pydir_extra="${EPREFIX}$(python_get_sitedir)/svn" \ >+ swig_pydir="$(python_get_sitedir)/libsvn" \ >+ swig_pydir_extra="$(python_get_sitedir)/svn" \ > install-swig-py >+ >+ rm ${p} || die > } >- python_execute_function \ >- --action-message 'Installation of Subversion SWIG Python bindings with $(python_get_implementation) $(python_get_version)' \ >- --failure-message 'Installation of Subversion SWIG Python bindings failed with $(python_get_implementation) $(python_get_version)' \ >- swig_python_bindings_installation >- fi > >- if use ctypes-python || use python; then >- python_clean_installation_image -q >+ BUILD_DIR=python \ >+ python_foreach_impl swig_py_install > fi > > if use perl; then >@@ -369,7 +388,7 @@ EOF > rm -fr tools/{buildbot,dev,diff,po} > > insinto /usr/share/${PN} >- python_convert_shebangs -r 2 tools >+ find tools -name '*.py' -exec sed -i -e '1s:python:&2:' {} + || die > doins -r tools > fi > >@@ -403,14 +422,6 @@ pkg_preinst() { > pkg_postinst() { > use perl && perl-module_pkg_postinst > >- if use ctypes-python; then >- python_mod_optimize csvn >- fi >- >- if use python; then >- python_mod_optimize libsvn svn >- fi >- > if [[ -n "${CHANGED_BDB_VERSION}" ]]; then > ewarn "You upgraded from an older version of Berkeley DB and may experience" > ewarn "problems with your repository. Run the following commands as root to fix it:" >@@ -423,14 +434,6 @@ pkg_postinst() { > > pkg_postrm() { > use perl && perl-module_pkg_postrm >- >- if use ctypes-python; then >- python_mod_cleanup csvn >- fi >- >- if use python; then >- python_mod_cleanup libsvn svn >- fi > } > > pkg_config() { >-- >1.8.1.2 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 458192
:
339312
|
339314
| 339366