public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in eclass: distutils.eclass
       [not found] <E1JHnw1-0006f5-3X@stork.gentoo.org>
@ 2008-01-24  1:13 ` Donnie Berkholz
  2008-01-31 14:51   ` [gentoo-dev] " Ali Polatel
  0 siblings, 1 reply; 2+ messages in thread
From: Donnie Berkholz @ 2008-01-24  1:13 UTC (permalink / raw
  To: gentoo-dev, hawking

On 22:19 Wed 23 Jan     , Ali Polatel (hawking) wrote:
> hawking     08/01/23 22:19:05
> 
>   Modified:             distutils.eclass
>   Log:
>   Fixed ROOT usage for distutils_pkg_postinst failing when ROOT ends with slash

> @@ -99,11 +99,14 @@
>  distutils_pkg_postinst() {
>  	PYTHON_MODNAME=${PYTHON_MODNAME:-${PN}}
>  
> +	# strip trailing slash
> +	myroot="${ROOT%/}"
> +
>  	if has_version ">=dev-lang/python-2.3"; then
>  		python_version
>  		for pymod in ${PYTHON_MODNAME}; do
> -			if [ -d "${ROOT}usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}" ]; then
> -				python_mod_optimize ${ROOT}usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}
> +			if [ -d "${myroot}/usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}" ]; then
> +				python_mod_optimize ${myroot}/usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}
>  			fi
>  		done
>  	fi

Seems like this might be better fixed by properly handling ROOT in 
python.eclass instead of hacking around it.

Thanks,
Donnie
-- 
gentoo-dev@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 2+ messages in thread

* [gentoo-dev] Re: gentoo-x86 commit in eclass: distutils.eclass
  2008-01-24  1:13 ` [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in eclass: distutils.eclass Donnie Berkholz
@ 2008-01-31 14:51   ` Ali Polatel
  0 siblings, 0 replies; 2+ messages in thread
From: Ali Polatel @ 2008-01-31 14:51 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1326 bytes --]

Donnie Berkholz yazmış:
> On 22:19 Wed 23 Jan     , Ali Polatel (hawking) wrote:
> > hawking     08/01/23 22:19:05
> > 
> >   Modified:             distutils.eclass
> >   Log:
> >   Fixed ROOT usage for distutils_pkg_postinst failing when ROOT ends with slash
> 
> > @@ -99,11 +99,14 @@
> >  distutils_pkg_postinst() {
> >  	PYTHON_MODNAME=${PYTHON_MODNAME:-${PN}}
> >  
> > +	# strip trailing slash
> > +	myroot="${ROOT%/}"
> > +
> >  	if has_version ">=dev-lang/python-2.3"; then
> >  		python_version
> >  		for pymod in ${PYTHON_MODNAME}; do
> > -			if [ -d "${ROOT}usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}" ]; then
> > -				python_mod_optimize ${ROOT}usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}
> > +			if [ -d "${myroot}/usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}" ]; then
> > +				python_mod_optimize ${myroot}/usr/$(get_libdir)/python${PYVER}/site-packages/${pymod}
> >  			fi
> >  		done
> >  	fi
> 
> Seems like this might be better fixed by properly handling ROOT in 
> python.eclass instead of hacking around it.
> 

You're right. dev-zero has made some changes to these eclasses in python
overlay[1] which I'll merge to the tree after some more testing.

[1]: http://overlays.gentoo.org/proj/python/browser/overlays/testing/eclass

-ali

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-01-31 14:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <E1JHnw1-0006f5-3X@stork.gentoo.org>
2008-01-24  1:13 ` [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in eclass: distutils.eclass Donnie Berkholz
2008-01-31 14:51   ` [gentoo-dev] " Ali Polatel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox