From: Alex J Lennon <ajlennon@dynamicdevices.co.uk>
To: Paul Eggleton <paul.eggleton@linux.intel.com>
Cc: yocto@yoctoproject.org, Otavio Salvador <otavio@ossystems.com.br>
Subject: Re: Undefining a variable in a recipe?
Date: Thu, 01 May 2014 18:34:52 +0100 [thread overview]
Message-ID: <536285BC.8010200@dynamicdevices.co.uk> (raw)
In-Reply-To: <5577559.2gRHFt1x94@peggleto-mobl5.ger.corp.intel.com>
On 01/05/2014 14:54, Paul Eggleton wrote:
> Hi Alex,
>
> On Thursday 01 May 2014 10:42:51 Alex J Lennon wrote:
>> I have an issue with the build of an old u-boot (2009.08) which is
>> failing a check in poky as both UBOOT_CONFIG and UBOOT_MACHINE are being
>> defined for some reason.
>>
>> poky/meta/classes/uboot-config.bbclass
>>
>> ubootmachine = d.getVar("UBOOT_MACHINE", True)
>> ubootconfigflags = d.getVarFlags('UBOOT_CONFIG')
>>
>> ..
>>
>> if ubootmachine and ubootconfigflags:
>> raise bb.parse.SkipPackage("You cannot use UBOOT_MACHINE and
>> UBOOT_CONFIG at the same time.")
>>
>>
>> I have a .bbappend on the original u-boot recipe and could solve the
>> problem by undefining UBOOT_MACHINE if I could work out how to do this
>> in the .bbappend
>>
>> I've tried setting it to None or an empty string, and I tried an
>> anonymous python function but those approaches didn't help,
>>
>> e.g. (in the .bbappend
>>
>> UBOOT_MACHINE = ""
> This should work - the python code above is checking if the value evaluates to
> True, and that shouldn't be the case for an empty string. I suspect something
> else is at work here - either the check is running before your value gets set,
> or the value is being set using an override somewhere and therefore your value
> isn't being used.
>
> (adding Otavio on CC since these are his checks and his layer)
Thanks for coming back to me on this Paul. OK, I must be
misunderstanding something.
I was outputting the UBOOT_MACHINE to test and it's not a True value at
any point as you
might expect as it's set to the machine type if set, but my build was
still failing to pick up
my preferred recipe version unless I commented out the if/raise, in
which case all worked
as expected.
Caught up with something at the minute but I will go through this again
first thing tomorrow.
Thanks again,
Alex
> Cheers,
> Paul
>
next prev parent reply other threads:[~2014-05-01 17:35 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-01 9:42 Undefining a variable in a recipe? Alex J Lennon
2014-05-01 13:54 ` Paul Eggleton
2014-05-01 17:34 ` Alex J Lennon [this message]
2014-05-01 17:54 ` Otavio Salvador
2014-05-01 18:34 ` Alex J Lennon
2014-05-02 5:24 ` Alex J Lennon
2014-05-02 12:56 ` Otavio Salvador
2014-05-02 13:01 ` Alex J Lennon
2014-05-02 13:07 ` Otavio Salvador
2014-05-02 13:11 ` Alex J Lennon
2014-05-02 13:23 ` Otavio Salvador
2014-05-02 13:25 ` Otavio Salvador
2014-05-02 14:08 ` Alex J Lennon
2014-05-02 15:24 ` Otavio Salvador
2014-05-02 15:46 ` Alex J Lennon
2014-05-02 16:55 ` Otavio Salvador
2014-05-02 17:18 ` Alex J Lennon
2014-05-02 13:28 ` Paul Eggleton
2014-05-02 13:35 ` Alex J Lennon
2014-05-02 13:45 ` Otavio Salvador
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=536285BC.8010200@dynamicdevices.co.uk \
--to=ajlennon@dynamicdevices.co.uk \
--cc=otavio@ossystems.com.br \
--cc=paul.eggleton@linux.intel.com \
--cc=yocto@yoctoproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.