[OE-core] [PATCHv2] bitbake.conf: add default PRINC 0 to be able to increment it

Chris Larson clarson at kergoth.com
Fri Dec 2 19:29:45 UTC 2011


On Fri, Dec 2, 2011 at 11:39 AM, Martin Jansa <martin.jansa at gmail.com> wrote:
> Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
> ---
>  meta/classes/base.bbclass |    2 +-
>  meta/conf/bitbake.conf    |    1 +
>  2 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
> index ea53498..fbcaefb 100644
> --- a/meta/classes/base.bbclass
> +++ b/meta/classes/base.bbclass
> @@ -335,7 +335,7 @@ python () {
>
>     # If PRINC is set, try and increase the PR value by the amount specified
>     princ = d.getVar('PRINC', True)
> -    if princ:
> +    if princ and princ != "0":

Could also do:

  if int(princ):

Or:

  PRINC[type] = "integer" # and:

  if oe.data.typed_value('PRINC', d):
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics




More information about the Openembedded-core mailing list