Emerging subversion with USE=-python and PYTHON_TARGETS=python3_2 fails. Installing/updating subversion should complete without requiring anything about python as was the case before introduction of PYTHON_TARGETS. [ebuild U ] dev-vcs/subversion-1.7.9 [1.7.7] USE="dso webdav-neon -apache2 -berkdb -ctypes-python -debug -doc -extras -gnome-keyring -java -kde -nls -perl -python -ruby -sasl -vim-syntax -webdav-serf" PYTHON_TARGETS="-python2_5% -python2_6% -python2_7%" 0 kB >>> Verifying ebuild manifests >>> Emerging (1 of 1) dev-vcs/subversion-1.7.9 * subversion-1.7.9.tar.bz2 SHA256 SHA512 WHIRLPOOL size ;-) ... [ ok ] >>> Unpacking source... >>> Unpacking subversion-1.7.9.tar.bz2 to /var/tmp/portage/dev-vcs/subversion-1.7.9/work >>> Source unpacked in /var/tmp/portage/dev-vcs/subversion-1.7.9/work >>> Preparing source in /var/tmp/portage/dev-vcs/subversion-1.7.9/work/subversion-1.7.9 ... * Applying subversion-1.5.4-interix.patch ... [ ok ] * Applying subversion-1.5.6-aix-dso.patch ... [ ok ] * Applying subversion-1.6.3-hpux-dso.patch ... [ ok ] * Applying subversion-fix-parallel-build-support-for-perl-bindings.patch ... [ ok ] * Running autoconf ... [ ok ] * Running elibtoolize in: subversion-1.7.9/build/ * Applying portage/1.2.0 patch ... * Applying sed/1.5.6 patch ... * Applying as-needed/2.2.6 patch ... cp: cannot stat ‘/var/tmp/portage/dev-vcs/subversion-1.7.9/work/subversion-1.7.9/build/configure’: No such file or directory chmod: failed to get attributes of ‘/var/tmp/portage/dev-vcs/subversion-1.7.9/work/subversion-1.7.9/build/configure.gentoo.elt’: No such file or directory >>> Source prepared. >>> Configuring source in /var/tmp/portage/dev-vcs/subversion-1.7.9/work/subversion-1.7.9 ... * No Python implementation selected for the build. Please add one * of the following values to your PYTHON_TARGETS (in make.conf): * * python2_5 python2_6 python2_7 * ERROR: dev-vcs/subversion-1.7.9 failed (configure phase): * No supported Python implementation in PYTHON_TARGETS. * * Call stack: * ebuild.sh, line 93: Called src_configure * environment, line 6939: Called python_export_best * environment, line 6438: Called _python_obtain_impls * environment, line 915: Called _python_validate_useflags * environment, line 1011: Called die * The specific snippet of code: * die "No supported Python implementation in PYTHON_TARGETS." * * If you need support, post the output of `emerge --info '=dev-vcs/subversion-1.7.9'`, * the complete build log and the output of `emerge -pqv '=dev-vcs/subversion-1.7.9'`. !!! When you file a bug report, please include the following information: GENTOO_VM= CLASSPATH="" JAVA_HOME="" JAVACFLAGS="" COMPILER="" and of course, the output of emerge --info =subversion-1.7.9 * The complete build log is located at '/var/tmp/portage/dev-vcs/subversion-1.7.9/temp/build.log'. * The ebuild environment file is located at '/var/tmp/portage/dev-vcs/subversion-1.7.9/temp/environment'. * Working directory: '/var/tmp/portage/dev-vcs/subversion-1.7.9/work/subversion-1.7.9' * S: '/var/tmp/portage/dev-vcs/subversion-1.7.9/work/subversion-1.7.9' >>> Failed to emerge dev-vcs/subversion-1.7.9, Log file: Reproducible: Always
Created attachment 347516 [details] emerge --info
"me too" The change from 1.7.7 to 1.7.9 ebuild is that PYTHON_DEPS is now included in DEPEND. I don't really get it if subversion could live without python in 1.7.7, why does it need in 1.7.9.
Just tested, it works correctly without python, the ebuild needs only a few modifications: 1) Remove the PYTHON_DEPS line from DEPEND (line 47). COMMON_DEPEND already has that with the python USE flag (which should control the dependency anyway). 2) The python_export_best line (line 187) and the ac_cv_python_includes line (line 192) needs a conditional (i'm not sure if the second one is needed, as ruby lacks the conditional too, and i don't have ruby isntalled), eg: if use python; then python_export_best fi [...] if use python; then ac_cv_python_includes='-I$(PYTHON_INCLUDEDIR)' fi ac_cv_path_RUBY="${EPREFIX}"/usr/bin/ruby18 ac_cv_path_RDOC="${EPREFIX}"/usr/bin/rdoc18 \ econf --libdir="${EPREFIX}/usr/$(get_libdir)" \ [...] This should nail it.
Created attachment 349810 [details, diff] proposed fix I've prepared Zoltán Halassy's suggestions in comment 3 as a patch. After applying the patch, subversion successfully builds on my machine with USE="-python" PYTHON_TARGETS="python3_2".
Just checked the patch from attachment 349810 [details, diff] with USE="python" PYTHON_TARGETS=python2_7 and it works fine too.
fixed: 20 Jul 2013; Michał Górny <mgorny@gentoo.org> subversion-1.7.9.ebuild: Lower the build-time requirement of Python to Python bindings or USE=test. Add REQUIRED_USE for Python.