mgorny 15/07/27 16:32:46 Modified: ChangeLog python-utils-r1.eclass Log: python_wrapper_setup(): replace symlinks with shell wrappers to avoid triggering Python 3.4+ magical prefix support.
Revision Changes Path 1.1729 eclass/ChangeLog file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.1729&view=markup plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.1729&content-type=text/plain diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.1728&r2=1.1729 Index: ChangeLog =================================================================== RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v retrieving revision 1.1728 retrieving revision 1.1729 diff -u -r1.1728 -r1.1729 --- ChangeLog 27 Jul 2015 16:31:01 -0000 1.1728 +++ ChangeLog 27 Jul 2015 16:32:46 -0000 1.1729 @@ -1,6 +1,10 @@ # ChangeLog for eclass directory # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1728 2015/07/27 16:31:01 floppym Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1729 2015/07/27 16:32:46 mgorny Exp $ + + 27 Jul 2015; Michał Górny <mgo...@gentoo.org> python-utils-r1.eclass: + python_wrapper_setup(): replace symlinks with shell wrappers to avoid + triggering Python 3.4+ magical prefix support. 27 Jul 2015; Mike Gilbert <flop...@gentoo.org> python-r1.eclass: Drop the USE_PYTHON warning. 1.85 eclass/python-utils-r1.eclass file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.85&view=markup plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?rev=1.85&content-type=text/plain diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/python-utils-r1.eclass?r1=1.84&r2=1.85 Index: python-utils-r1.eclass =================================================================== RCS file: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v retrieving revision 1.84 retrieving revision 1.85 diff -u -r1.84 -r1.85 --- python-utils-r1.eclass 25 Jul 2015 10:07:36 -0000 1.84 +++ python-utils-r1.eclass 27 Jul 2015 16:32:46 -0000 1.85 @@ -1,6 +1,6 @@ # Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.84 2015/07/25 10:07:36 mgorny Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/python-utils-r1.eclass,v 1.85 2015/07/27 16:32:46 mgorny Exp $ # @ECLASS: python-utils-r1 # @MAINTAINER: @@ -855,14 +855,25 @@ fi # Python interpreter - ln -s "${PYTHON}" "${workdir}"/bin/python || die - ln -s python "${workdir}"/bin/python${pyver} || die + # note: we don't use symlinks because python likes to do some + # symlink reading magic that breaks stuff + # https://bugs.gentoo.org/show_bug.cgi?id=555752 + cat > "${workdir}/bin/python" <<-_EOF_ + #!/bin/sh + exec "${PYTHON}" "\${@}" + _EOF_ + cp "${workdir}/bin/python" "${workdir}/bin/python${pyver}" || die + chmod +x "${workdir}/bin/python" "${workdir}/bin/python${pyver}" || die local nonsupp=() # CPython-specific if [[ ${EPYTHON} == python* ]]; then - ln -s "${PYTHON}-config" "${workdir}"/bin/python-config || die + cat > "${workdir}/bin/python-config" <<-_EOF_ + #!/bin/sh + exec "${PYTHON}-config" "\${@}" + _EOF_ + chmod +x "${workdir}/bin/python-config" || die # Python 2.6+. ln -s "${PYTHON/python/2to3-}" "${workdir}"/bin/2to3 || die