On Mon, 04 Mar 2013 23:21:36 +0100
Thomas Sachau <to...@gentoo.org> wrote:

> Michał Górny schrieb:
> > On Mon, 4 Mar 2013 11:02:40 +0100
> > Alexis Ballier <aball...@gentoo.org> wrote:
> > 
> >> you are called with ABI=sth argv[0] = your name
> > 
> > I'm afraid that's the first potential point of failure. Relying
> > on argv[0] is a poor idea and means that any application calling exec()
> > with changed argv[0] on a wrapped binary will fail terribly.
> 
> Nobody said, that one cannot create situations, where such a wrapper
> does fail, the point is more an easy and general solution for wrapping
> binaries without implementing different solutions for the same issue in
> every ebuild.

There's no such thing as 'easy and general solution'. You always
sacrifice something.

And in this case, you're creating a point of failure which is
completely custom to Gentoo and actually quite hard to track. Just to
support a specific package manager feature specific to Gentoo.

> If you have a better, yet still easy and general solution not requiring
> every ebuild to create something on its own, please write it instead of
> just complaining how bad the wrapper solution actually is.

The solution is called eclasses.

> > Yep, I intended to just have the additional variant of glxinfo directly
> > callable, with a name chosen specifically by the X11 team. Wrapper
> > would be more confusing than beneficial here IMO.
> 
> Ah, you actually want each ebuild to have its own custom hack instead of
> one global solution usable everywhere?

Yes.

> >> To some extent that's what happened to python too :) As a python
> >> maintainer, you could share your thoughts on the topic. python slotting
> >> was intended to make switching between python versions easy but has
> >> been needing wrappers for the python binary.
> > 
> > I'm doing just that. Any kind of wrapping is an increasing mess. I'm
> > still trying to find out good solutions for Python wrapping but there's
> > no such thing. It's always about choosing one evil over the other.
> 
> So you are wrapping python, have not yet found anything better and still
> dont want to wrap abi-specific binaries, while you dont have a better
> solution at hand? Saying no to everything is easy, providing something
> better if you dont like a suggestion is the challenge.

Yes, it is easy and mess-free. Using a cheap hack is mess-full, and is
just asking for trouble which will eventually rise.

-- 
Best regards,
Michał Górny

Attachment: signature.asc
Description: PGP signature

Reply via email to