All of lore.kernel.org
 help / color / mirror / Atom feed
* image inheritance problem
@ 2018-01-26 18:52 Martin Townsend
  2018-01-26 18:57 ` Khem Raj
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Townsend @ 2018-01-26 18:52 UTC (permalink / raw)
  To: yocto

Hi,

I have an image say

my-image-minimal.bb in one layer and and append this
(my-image-minimal.bbappend) in another layer.  In this append I'm adding
IMAGE_INSTALL += "kernel-modules"
for example.

Now if I run
bitbake my-image-minimal -e | grep ^IMAGE_INSTALL
I see kernel-modules

So bbappend is working, now I have another image

my-image which has
requires /core/images/my-image-minimal.bb
...

But kernel-modules is not appearing in this image and
bitbake my-image -e | grep ^IMAGE_INSTALL

confirms this.

Any ideas as to what I'm doing wrong, I assume bitbake supports this.

I'm using the Krogoth release.

Many Thanks in advance,
Martin.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: image inheritance problem
  2018-01-26 18:52 image inheritance problem Martin Townsend
@ 2018-01-26 18:57 ` Khem Raj
  2018-01-26 19:17   ` Martin Townsend
  0 siblings, 1 reply; 5+ messages in thread
From: Khem Raj @ 2018-01-26 18:57 UTC (permalink / raw)
  To: yocto

On 1/26/18 10:52 AM, Martin Townsend wrote:
> Hi,
> 
> I have an image say
> 
> my-image-minimal.bb in one layer and and append this
> (my-image-minimal.bbappend) in another layer.  In this append I'm adding
> IMAGE_INSTALL += "kernel-modules"
> for example.
> 
> Now if I run
> bitbake my-image-minimal -e | grep ^IMAGE_INSTALL
> I see kernel-modules
> 
> So bbappend is working, now I have another image
> 
> my-image which has
> requires /core/images/my-image-minimal.bb
> ...
> 
> But kernel-modules is not appearing in this image and
> bitbake my-image -e | grep ^IMAGE_INSTALL
> 
> confirms this.
> 
> Any ideas as to what I'm doing wrong, I assume bitbake supports this.
> 

in second case you are including the .bb file so its behaving as an
include file.
bbappend only applies to parsed recipes not include files.

> I'm using the Krogoth release.
> 
> Many Thanks in advance,
> Martin.
> 



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: image inheritance problem
  2018-01-26 18:57 ` Khem Raj
@ 2018-01-26 19:17   ` Martin Townsend
  2018-01-26 19:49     ` Martin Townsend
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Townsend @ 2018-01-26 19:17 UTC (permalink / raw)
  To: Khem Raj; +Cc: yocto

Hi Khem,

On Fri, Jan 26, 2018 at 6:57 PM, Khem Raj <raj.khem@gmail.com> wrote:
> On 1/26/18 10:52 AM, Martin Townsend wrote:
>> Hi,
>>
>> I have an image say
>>
>> my-image-minimal.bb in one layer and and append this
>> (my-image-minimal.bbappend) in another layer.  In this append I'm adding
>> IMAGE_INSTALL += "kernel-modules"
>> for example.
>>
>> Now if I run
>> bitbake my-image-minimal -e | grep ^IMAGE_INSTALL
>> I see kernel-modules
>>
>> So bbappend is working, now I have another image
>>
>> my-image which has
>> requires /core/images/my-image-minimal.bb
>> ...
>>
>> But kernel-modules is not appearing in this image and
>> bitbake my-image -e | grep ^IMAGE_INSTALL
>>
>> confirms this.
>>
>> Any ideas as to what I'm doing wrong, I assume bitbake supports this.
>>
>
> in second case you are including the .bb file so its behaving as an
> include file.
> bbappend only applies to parsed recipes not include files.
>

Thanks for the swift reply and clarifications on how requires/include works.

Don't suppose you know of the best way of handling this situation?

>> I'm using the Krogoth release.
>>
>> Many Thanks in advance,
>> Martin.
>>
>
> --
> _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: image inheritance problem
  2018-01-26 19:17   ` Martin Townsend
@ 2018-01-26 19:49     ` Martin Townsend
  2018-01-26 20:46       ` Khem Raj
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Townsend @ 2018-01-26 19:49 UTC (permalink / raw)
  To: Khem Raj; +Cc: yocto

On Fri, Jan 26, 2018 at 7:17 PM, Martin Townsend
<mtownsend1973@gmail.com> wrote:
> Hi Khem,
>
> On Fri, Jan 26, 2018 at 6:57 PM, Khem Raj <raj.khem@gmail.com> wrote:
>> On 1/26/18 10:52 AM, Martin Townsend wrote:
>>> Hi,
>>>
>>> I have an image say
>>>
>>> my-image-minimal.bb in one layer and and append this
>>> (my-image-minimal.bbappend) in another layer.  In this append I'm adding
>>> IMAGE_INSTALL += "kernel-modules"
>>> for example.
>>>
>>> Now if I run
>>> bitbake my-image-minimal -e | grep ^IMAGE_INSTALL
>>> I see kernel-modules
>>>
>>> So bbappend is working, now I have another image
>>>
>>> my-image which has
>>> requires /core/images/my-image-minimal.bb
>>> ...
>>>
>>> But kernel-modules is not appearing in this image and
>>> bitbake my-image -e | grep ^IMAGE_INSTALL
>>>
>>> confirms this.
>>>
>>> Any ideas as to what I'm doing wrong, I assume bitbake supports this.
>>>
>>
>> in second case you are including the .bb file so its behaving as an
>> include file.
>> bbappend only applies to parsed recipes not include files.
>>
>
> Thanks for the swift reply and clarifications on how requires/include works.
>
> Don't suppose you know of the best way of handling this situation?

Not sure if it's the best way but I converted the bbappend to an image
recipe my-minimal-image-xxx.bb
and then include this as well as include will ignore it if the layer
doesn't exist. Seems to work :)

>
>>> I'm using the Krogoth release.
>>>
>>> Many Thanks in advance,
>>> Martin.
>>>
>>
>> --
>> _______________________________________________
>> yocto mailing list
>> yocto@yoctoproject.org
>> https://lists.yoctoproject.org/listinfo/yocto


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: image inheritance problem
  2018-01-26 19:49     ` Martin Townsend
@ 2018-01-26 20:46       ` Khem Raj
  0 siblings, 0 replies; 5+ messages in thread
From: Khem Raj @ 2018-01-26 20:46 UTC (permalink / raw)
  To: Martin Townsend; +Cc: yocto

On Fri, Jan 26, 2018 at 11:49 AM, Martin Townsend
<mtownsend1973@gmail.com> wrote:
> On Fri, Jan 26, 2018 at 7:17 PM, Martin Townsend
> <mtownsend1973@gmail.com> wrote:
>> Hi Khem,
>>
>> On Fri, Jan 26, 2018 at 6:57 PM, Khem Raj <raj.khem@gmail.com> wrote:
>>> On 1/26/18 10:52 AM, Martin Townsend wrote:
>>>> Hi,
>>>>
>>>> I have an image say
>>>>
>>>> my-image-minimal.bb in one layer and and append this
>>>> (my-image-minimal.bbappend) in another layer.  In this append I'm adding
>>>> IMAGE_INSTALL += "kernel-modules"
>>>> for example.
>>>>
>>>> Now if I run
>>>> bitbake my-image-minimal -e | grep ^IMAGE_INSTALL
>>>> I see kernel-modules
>>>>
>>>> So bbappend is working, now I have another image
>>>>
>>>> my-image which has
>>>> requires /core/images/my-image-minimal.bb
>>>> ...
>>>>
>>>> But kernel-modules is not appearing in this image and
>>>> bitbake my-image -e | grep ^IMAGE_INSTALL
>>>>
>>>> confirms this.
>>>>
>>>> Any ideas as to what I'm doing wrong, I assume bitbake supports this.
>>>>
>>>
>>> in second case you are including the .bb file so its behaving as an
>>> include file.
>>> bbappend only applies to parsed recipes not include files.
>>>
>>
>> Thanks for the swift reply and clarifications on how requires/include works.
>>
>> Don't suppose you know of the best way of handling this situation?
>
> Not sure if it's the best way but I converted the bbappend to an image
> recipe my-minimal-image-xxx.bb
> and then include this as well as include will ignore it if the layer
> doesn't exist. Seems to work :)

thats probably ok. you can call it a .inc file and use include instead
of require to include it
that way you can include it in multiple image recipes or bbappends in
your own layers.


>
>>
>>>> I'm using the Krogoth release.
>>>>
>>>> Many Thanks in advance,
>>>> Martin.
>>>>
>>>
>>> --
>>> _______________________________________________
>>> yocto mailing list
>>> yocto@yoctoproject.org
>>> https://lists.yoctoproject.org/listinfo/yocto


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-01-26 20:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-26 18:52 image inheritance problem Martin Townsend
2018-01-26 18:57 ` Khem Raj
2018-01-26 19:17   ` Martin Townsend
2018-01-26 19:49     ` Martin Townsend
2018-01-26 20:46       ` Khem Raj

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.