Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-dev
Navigation:
Lists: gentoo-dev: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-dev@g.o
From: Michael Orlitzky <michael@...>
Subject: Re: RFD: EAPI specification in ebuilds
Date: Fri, 09 Mar 2012 10:21:37 -0500
On 03/09/12 10:05, Zac Medico wrote:
>>
>> Surely we can source one or two lines of the ebuild safely, like the
>> example shows?
> 
> Why would we though, when sourcing is a relatively costly operation, and
> there are much more efficient ways to get the EAPI?

There do not seem to be any that people agree on =)

I mean, it's /easy/ to get the EAPI. There's a list of ways on the GLEP,
but all of them have trade-offs.

The header comment seems to be the preference in this thread. The
advantage that the eapi function has over a comment is that it's not
magic -- it's just normal bash syntax. So we've addressed that issue at
a small performance cost (we're really only sourcing the ebuild up to
'exit').

Whether or not that trade-off is worth it, who knows. I would prefer to
make it work before we make it fast; but new ideas can't hurt
considering nobody has agreed on an old one.


> Also, you've got a chicken and egg problem, since you're assuming that
> your eapi() function is going to be available in the global environment
> when the ebuild is sourced. The whole point of knowing the EAPI in
> advance is so that we will be able to make changes to the global
> environment, such as add, remove, or change the behavior of _any_ function.

Nah, at the top of the ebuild, you would have,

 EAPI=5
 eapi 5

until package managers catch up, just like we would have to do with the
comment. Once they've caught up, we can drop the EAPI= assignment, and
begin using new features after the call to 'eapi'.


Replies:
Re: RFD: EAPI specification in ebuilds
-- Zac Medico
References:
RFD: EAPI specification in ebuilds
-- Ulrich Mueller
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Re: RFD: EAPI specification in ebuilds
-- Michał Górny
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Re: RFD: EAPI specification in ebuilds
-- Michał Górny
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Re: RFD: EAPI specification in ebuilds
-- Ciaran McCreesh
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Re: RFD: EAPI specification in ebuilds
-- Ciaran McCreesh
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Re: RFD: EAPI specification in ebuilds
-- Michał Górny
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Re: RFD: EAPI specification in ebuilds
-- Zac Medico
Re: RFD: EAPI specification in ebuilds
-- Michael Orlitzky
Navigation:
Lists: gentoo-dev: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
Re: RFD: EAPI specification in ebuilds
Next by thread:
Re: RFD: EAPI specification in ebuilds
Previous by date:
Re: RFD: EAPI specification in ebuilds
Next by date:
Re: RFD: EAPI specification in ebuilds


Updated Jun 29, 2012

Summary: Archive of the gentoo-dev mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.