[oe] Use AUTOREV and have revision/commit number in package name?

Graeme Gregory dp at xora.org.uk
Thu Aug 20 09:13:05 UTC 2009


Holger Hans Peter Freyther wrote:
> On Thursday 20 August 2009 05:28:02 Denys Dmytriyenko wrote:
>   
>> All,
>>
>> I've been playing with AUTOREV for some time now and also asked this
>> question before on the IRC, but so far there seems to be no easy solution
>> to the problem in subject.
>>
>> Usually, when a package is built from an SCM repository, SRCREV is set to a
>> specific commit#/tag etc. And SRCREV is also usually referenced from PV
>> (like PV = "X.Y.Z-scmr${SRCREV}") to have the revision/commit number in the
>> package name, to easily track different builds.
>>
>> Now, when SRCREV = "${AUTOREV}", AUTOREV gets resolved into a Python
>> function, which does the magic of fetching the latest snapshot from a
>> repository. But now if PV contains references to SRCREV, it breaks
>> (undesrandably), since SRCREV gets resolved in do_fetch and PV needs to be
>> resolved early on.
>>
>> Are there any standard ways to work around this limitation?
>>     
>
> Check the mailinglist archives... Openmoko has deployed a solution that has 
> fixed that about 1 1/2 years ago.
>
> Short answer:
> 	- Do not put SRCREV into PV, e.g. create a new var called SRCPV
> 	- Populate SRCPV with something based on the SRCREV..
>
>
>   
Holger, I have been trying to maintain a branch with your SRCPV work in 
it, xora/angstrom-srcpv in git. Unfortuneately as I only get to do it in 
spare time I never seem to be able to quite keep up with OE mainline.

But it would be good to start merging this into mainline, probably 
package by package.

Graeme





More information about the Openembedded-devel mailing list