<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jun 2, 2017 at 6:26 AM, Mark Hatle <span dir="ltr"><<a href="mailto:mark.hatle@windriver.com" target="_blank">mark.hatle@windriver.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb adM"><div class="">On 6/2/17 7:58 AM, Richard Purdie wrote:<br>
> On Mon, 2017-05-22 at 12:50 +0200, Patrick Ohly wrote:<br>
>> Having a .bbappend without corresponding .bb file triggers an error<br>
>> or<br>
>> at least warning, depending on the global<br>
>> BB_DANGLINGAPPENDS_WARNONLY.<br>
>><br>
>> Some layers (for example, meta-freescale) avoid that message by only<br>
>> adding .bbappends to the BBFILES when the layers they apply to are<br>
>> present. Others (like intel-iot-refkit) avoid such .bbappends by<br>
>> falling back to global assignments with _pn-<recipe> as override.<br>
>> Both<br>
>> is complicated.<br>
>><br>
>> Now the warning code checks BBAPPENDS_DANGLING_WHITELIST and ignores<br>
>> all bbappends which match a file pattern in that list. This is an<br>
>> easier way to have bbappends which may or may not apply to an<br>
>> existing recipe.<br>
>><br>
>> Example usage:<br>
>><br>
>> # We have recipes-* directories, add to BBFILES<br>
>> BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \<br>
>> ${LAYERDIR}/optional-<wbr>bbappends/recipes-*/*/*.<wbr>bbappend \<br>
>> ${LAYERDIR}/recipes-*/*/*.<wbr>bbappend"<br>
>><br>
>> # Several of our *.bbappends might be for layers that are not<br>
>> # guaranteed to be present. Don't warn or even error out because<br>
>> # of those.<br>
>> BBAPPENDS_DANGLING_WHITELIST += "${LAYERDIR}/optional-<br>
>> bbappends/recipes-*/*/*.<wbr>bbappend"<br>
><br>
> I've been giving this some thought. The freescale layer approach does<br>
> have ordering issues which I don't like. Equally, Chris' comment about<br>
> this is also a valid concern. Experience suggests saying the layer<br>
> maintainer needs to be careful doesn't work in practise.<br>
><br>
> I'm wondering if there is a hybrid solution if we extend this syntax a<br>
> little, e.g.:<br>
><br>
> BBFILES_DYNAMIC += "\<br>
> XXXX:${LAYERDIR}/optional-<wbr>bbappends-XXX/recipes-*/*/*.<wbr>bbappend<br>
> YYYY:${LAYERDIR}/optional-<wbr>bbappends-YYY/recipes-*/*/*.<wbr>bbappend<br>
> "<br>
><br>
> so that the code only applies these BBFILES entries if the layer named<br>
> in the first parameter is present?<br>
><br>
> This would happen at the end of parsing so ordering becomes a moot<br>
> point. The direction you stack BBFILES_DYANMIC in would determin<br>
> bbappend application order.<br>
><br>
> How does that sound to people?<br>
<br>
</div></div>That sounds reasonable to me, and has a precedent in the package_dynamic as well.</blockquote></div><br>Agreed.<br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr">Christopher Larson<br>kergoth at gmail dot com<br>Founder - BitBake, OpenEmbedded, OpenZaurus<br>Senior Software Engineer, Mentor Graphics</div></div></div></div>
</div></div>