All of lore.kernel.org
 help / color / mirror / Atom feed
* trying to clarify PREFERRED_VERSION processing
@ 2014-06-18 14:16 Robert P. J. Day
  0 siblings, 0 replies; only message in thread
From: Robert P. J. Day @ 2014-06-18 14:16 UTC (permalink / raw)
  To: BitBake developer list


  still working my way through the bitbake user manual, currently in
section 2.3, "Preferences and Providers", and i think this section is
unnecessarily confusing as it tries to discuss both preferences and
providers at the same time, which i think are two separate concepts
that should be covered independently, so let me ask some questions
about just PREFERRED_VERSION processing using an actual example ripped
from the oe/poky codebase.

  (side note: i'm writing up a bunch of examples of bitbake processing
for my courses and, rather than use generic labels like "foo" and
"bar", i want to use actual examples from the codebase so i can show
the results with things like "bitbake -s".)

  consider (from my poky checkout) the two possibilities for the
busybox recipe:

  busybox_1.22.1.bb
  busybox_git.bb

obviously, there are two versions available to me and, if i examine
the respective .bb files, i can see in the git version:

  DEFAULT_PREFERENCE = "-1"

making that the *unpreferred* version. let's verify that with "bitbake
-s" (using my build for beaglebone/core-image-minimal):

$ bitbake -s
...
busybox                                           :1.22.1-r32
...
$

  good, that's what i expected -- the fixed version recipe is the one
that would be selected. now say i wanted to use the other (git)
version, what would be the appropriate line i would add to local.conf?
it seems i can just use wildcarding, as in:

  PREFERRED_VERSION_busybox = "1.22.1+git%"

at which point i can see:

$ bitbake -s
...
busybox                                           :1.22.1-r32 :1.22.1+gitAUTOINC+d9e0c438e1-r0
...
$

  from what i read from "bitbake -h", what is being printed is the
"current" version, followed by the "preferred" version, so i'm
interpreting that as the first value would be the version selected if
i didn't override it, and the second value is the version that will
actually be used given that i've explicitly preferred a version for
that recipe. is that the proper way to describe that?

  also, what would be the proper PREFERRED_VERSION line in my
local.conf if i wanted to prefer *precisely* that git version of
busybox? i know wildcarding works, as in:

  PREFERRED_VERSION_busybox = "1.22.1+git%"

but what value would i use to match *precisely* that git-based
version? something involving SRCREV or SRCPV or something like that?

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-06-18 14:19 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-18 14:16 trying to clarify PREFERRED_VERSION processing Robert P. J. Day

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.