[bitbake-devel] can i get a list of only bbappend'ed recipes that were *used* in a build?

Aaron Cohen aaron at assonance.org
Fri Feb 28 20:40:01 UTC 2020


On Fri, Feb 28, 2020 at 3:32 PM Peter Kjellerstedt <
peter.kjellerstedt at axis.com> wrote:

> > -----Original Message-----
> > From: bitbake-devel-bounces at lists.openembedded.org <bitbake-devel-
> > bounces at lists.openembedded.org> On Behalf Of Robert P. J. Day
> > Sent: den 28 februari 2020 20:38
> > To: Mikko.Rapeli at bmw.de
> > Cc: bitbake-devel at lists.openembedded.org
> > Subject: Re: [bitbake-devel] can i get a list of only bbappend'ed recipes
> > that were *used* in a build?
> >
> > On Fri, 28 Feb 2020, Mikko.Rapeli at bmw.de wrote:
> >
> > > Hi,
> > >
> > > On Fri, Feb 28, 2020 at 08:33:36AM -0500, rpjday at crashcourse.ca wrote:
> > > > looked around and i don't see an immediately obvious way to do
> > > > this ... is there a way to generate a list of *only* those recipes
> > > > that were used in the current build that had associated .bbappend
> > > > files?
> > > >
> > > > "bitbake-layers show-appends" will show all recipes with .bbappend
> > > > files, including those that are not included and processed for the
> > > > current build/image. here's the rationale, in case i'm missing
> > > > something.
> > >
> > > I'm doing "find meta* -name \*recipe\*bb\*" and reviewing every one
> > > of them. More visibility to this including parsing order would be
> > > nice to store in e.g. buildhistory.
> >
> >   thanks for clarifying that there wasn't a massively trivial way to
> > do this that i just didn't see.
>
> For each image you build, you should find a manifest in
> "tmp/deploy/image/<machine>/<image>-<machine>.manifest". It contains the
> names, architectures and versions of all packages that were installed in
> the image.
>
> To convert the package names from the manifest to recipes, you can use
> oe-pkgdata-util:
>
>   oe-pkgdata-util -p tmp/pkgdata/<machine> package-info -f <path to the
> manifest file>
>
> (the -p tmp/pkgdata/<machine> option isn't necessary, but you avoid
> starting tinfoil if you use it). This will give you one line per package
> that also includes the recipe name. Pass the output to `cut -f3 -d' ' |
> sort -u' and you should have the list of recipes that were used to build
> the packages in your image.
>
> Then all you have to do is take the intersection of recipes from that
> list and from `bitbake-layers show-appends` and you should have the
> list of recipes that have bbappends applied and are used to build your
> image.
>
>
pipe the package list through 'xargs bitbake-layers show-appends' and it
seems exactly what's asked for.

oe-pkgdata-util -p tmp/pkgdata/<machine> package-info -f
tmp/deploy/images/<machine>/<image>.manifest | cut -f3 -d' ' | sort -u |
xargs bitbake-layers show-appends
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/bitbake-devel/attachments/20200228/90137a49/attachment-0001.html>


More information about the bitbake-devel mailing list