All of lore.kernel.org
 help / color / mirror / Atom feed
* Yocto Top Level Files
@ 2020-02-26 12:00 Mehran Memarnejad
  2020-02-26 12:05 ` [yocto] " Paul Barker
  0 siblings, 1 reply; 4+ messages in thread
From: Mehran Memarnejad @ 2020-02-26 12:00 UTC (permalink / raw)
  To: yocto

[-- Attachment #1: Type: text/plain, Size: 1587 bytes --]

Hi,

Working with Yocto Project, Now I am a little confused about which files
are the top level ones i.e. files that bitbake starts by, and then all
other recipes are used *if and only if* they are included by some means
such as DEPENDS, RDEPENDS, IMAGE_INSTALL and so on...

As I understood:

   - *meta*/recipes*/images/myImage.bb* which is "*hardware independent*"
   and includes packages to install and etc
   - *conf/machine/myMachine.conf* which is "*hardware specific*" and
   includes appropriate Bootloader, kernel, device tree and etc ... i.e.
   selecting appropriate bootloader, kernel recipes among all others by
   PREFERRED_PROVIDER mechanism
   - *conf/distro/myDistro.conf* which I don't know its usage

Then by setting MACHINE and DISTRO variables in *conf/local.conf* and
calling bitbake with *$ bitbake myImage*, finally *conf/local.conf* is read
and "*myMahcine.conf and myDistro.conf*" will be selected to be used for
image creation, and the myImage recipe's tasks will be executed by
bitbake... all other recipes, include file and bbclass files are come into
play *if and only if* they have been used by some means such as *IMAGE_INSATLL,
DEPENDS, RDEPENDS, inc, inherit and so on* in myImage.bb, myMahchine.conf
and myDistro.conf

Question: Is this procedure Right??

Question: So in summary, I guess that top level files are: *myImage.bb*,
*myMahchine.conf* and *myDistro.conf*

NOTE: Some other files such as conf/bblayer.conf, bitbake.conf and etc are
read but those are not in my focus for this question

Thanks in advance

[-- Attachment #2: Type: text/html, Size: 1913 bytes --]

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

* Re: [yocto] Yocto Top Level Files
  2020-02-26 12:00 Yocto Top Level Files Mehran Memarnejad
@ 2020-02-26 12:05 ` Paul Barker
       [not found]   ` <CAER1B8K56hz4dxTjbeC1a3KpAg9TYQ4PL=L5tAqtA30eWnkeyw@mail.gmail.com>
  0 siblings, 1 reply; 4+ messages in thread
From: Paul Barker @ 2020-02-26 12:05 UTC (permalink / raw)
  To: Mehran Memarnejad; +Cc: yocto

On Wed, 26 Feb 2020 at 12:00, Mehran Memarnejad <memarnejadm74@gmail.com> wrote:
>
> Hi,
>
> Working with Yocto Project, Now I am a little confused about which files are the top level ones i.e. files that bitbake starts by, and then all other recipes are used if and only if they are included by some means such as DEPENDS, RDEPENDS, IMAGE_INSTALL and so on...
>
> As I understood:
>
> meta*/recipes*/images/myImage.bb which is "hardware independent" and includes packages to install and etc
> conf/machine/myMachine.conf which is "hardware specific" and includes appropriate Bootloader, kernel, device tree and etc ... i.e. selecting appropriate bootloader, kernel recipes among all others by PREFERRED_PROVIDER mechanism
> conf/distro/myDistro.conf which I don't know its usage
>
> Then by setting MACHINE and DISTRO variables in conf/local.conf and calling bitbake with $ bitbake myImage, finally conf/local.conf is read and "myMahcine.conf and myDistro.conf" will be selected to be used for image creation, and the myImage recipe's tasks will be executed by bitbake... all other recipes, include file and bbclass files are come into play if and only if they have been used by some means such as IMAGE_INSATLL, DEPENDS, RDEPENDS, inc, inherit and so on in myImage.bb, myMahchine.conf and myDistro.conf
>
> Question: Is this procedure Right??
>
> Question: So in summary, I guess that top level files are: myImage.bb, myMahchine.conf and myDistro.conf
>
> NOTE: Some other files such as conf/bblayer.conf, bitbake.conf and etc are read but those are not in my focus for this question

If I've understood the bitbake sources correctly, the parsing looks like this:
1) bblayers.conf
2) bitbake.conf (this pulls in local.conf, your distro conf, your
machine conf, etc)
3) All recipes (even the ones you're not building)

Then the targets given on the command line are resolved to recipes and
those are built.

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

* Re: [yocto] Yocto Top Level Files
       [not found]   ` <CAER1B8K56hz4dxTjbeC1a3KpAg9TYQ4PL=L5tAqtA30eWnkeyw@mail.gmail.com>
@ 2020-02-26 13:17     ` Mehran Memarnejad
  2020-02-26 13:20       ` Paul Barker
  0 siblings, 1 reply; 4+ messages in thread
From: Mehran Memarnejad @ 2020-02-26 13:17 UTC (permalink / raw)
  To: Paul Barker; +Cc: yocto

[-- Attachment #1: Type: text/plain, Size: 3258 bytes --]

Hi Paul,
As I know, bitbake parses all recipes to make its database so that it knows
each recipe PROVIDEs what... base on top level files (I guess they are
myImage.bb,
myMahchine.conf and myDistro.conf), other files are pulled in if they are
necessary... For the machine.conf and distro.conf, the files named in
MACHINE and DISTRO variables in local.conf are pulled in and the myImage.bb
is pulled in by the user when entering a command like $bitbake myImage

Am I right?

On Wed, Feb 26, 2020 at 4:47 PM Mehran Memarnejad <memarnejadm74@gmail.com>
wrote:

> Hi Paul,
> As I know, bitbake parses all recipes to make its database so that it
> knows each recipe PROVIDEs what... base on top level files (I guess they
> are myImage.bb, myMahchine.conf and myDistro.conf), other files are
> pulled in if they are necessary... For the machine.conf and distro.conf,
> the files named in MACHINE and DISTRO variables in local.conf are pulled in
> and the myImage.bb is pulled in by the user when entering a command like
> $bitbake myImage
>
> Am I right?
>
>
>
> On Wed, Feb 26, 2020 at 3:36 PM Paul Barker <pbarker@konsulko.com> wrote:
>
>> On Wed, 26 Feb 2020 at 12:00, Mehran Memarnejad <memarnejadm74@gmail.com>
>> wrote:
>> >
>> > Hi,
>> >
>> > Working with Yocto Project, Now I am a little confused about which
>> files are the top level ones i.e. files that bitbake starts by, and then
>> all other recipes are used if and only if they are included by some means
>> such as DEPENDS, RDEPENDS, IMAGE_INSTALL and so on...
>> >
>> > As I understood:
>> >
>> > meta*/recipes*/images/myImage.bb which is "hardware independent" and
>> includes packages to install and etc
>> > conf/machine/myMachine.conf which is "hardware specific" and includes
>> appropriate Bootloader, kernel, device tree and etc ... i.e. selecting
>> appropriate bootloader, kernel recipes among all others by
>> PREFERRED_PROVIDER mechanism
>> > conf/distro/myDistro.conf which I don't know its usage
>> >
>> > Then by setting MACHINE and DISTRO variables in conf/local.conf and
>> calling bitbake with $ bitbake myImage, finally conf/local.conf is read and
>> "myMahcine.conf and myDistro.conf" will be selected to be used for image
>> creation, and the myImage recipe's tasks will be executed by bitbake... all
>> other recipes, include file and bbclass files are come into play if and
>> only if they have been used by some means such as IMAGE_INSATLL, DEPENDS,
>> RDEPENDS, inc, inherit and so on in myImage.bb, myMahchine.conf and
>> myDistro.conf
>> >
>> > Question: Is this procedure Right??
>> >
>> > Question: So in summary, I guess that top level files are: myImage.bb,
>> myMahchine.conf and myDistro.conf
>> >
>> > NOTE: Some other files such as conf/bblayer.conf, bitbake.conf and etc
>> are read but those are not in my focus for this question
>>
>> If I've understood the bitbake sources correctly, the parsing looks like
>> this:
>> 1) bblayers.conf
>> 2) bitbake.conf (this pulls in local.conf, your distro conf, your
>> machine conf, etc)
>> 3) All recipes (even the ones you're not building)
>>
>> Then the targets given on the command line are resolved to recipes and
>> those are built.
>>
>

[-- Attachment #2: Type: text/html, Size: 4061 bytes --]

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

* Re: [yocto] Yocto Top Level Files
  2020-02-26 13:17     ` Mehran Memarnejad
@ 2020-02-26 13:20       ` Paul Barker
  0 siblings, 0 replies; 4+ messages in thread
From: Paul Barker @ 2020-02-26 13:20 UTC (permalink / raw)
  To: Mehran Memarnejad; +Cc: yocto

On Wed, 26 Feb 2020 at 13:17, Mehran Memarnejad <memarnejadm74@gmail.com> wrote:
>
> Hi Paul,
> As I know, bitbake parses all recipes to make its database so that it knows each recipe PROVIDEs what... base on top level files (I guess they are myImage.bb, myMahchine.conf and myDistro.conf), other files are pulled in if they are necessary... For the machine.conf and distro.conf, the files named in MACHINE and DISTRO variables in local.conf are pulled in and the myImage.bb is pulled in by the user when entering a command like $bitbake myImage
>
> Am I right?

What do you mean by "top level files"?

I'd recommend you look at bitbake.conf so you can see how MACHINE,
DISTRO, etc are handled.

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

end of thread, other threads:[~2020-02-26 13:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-26 12:00 Yocto Top Level Files Mehran Memarnejad
2020-02-26 12:05 ` [yocto] " Paul Barker
     [not found]   ` <CAER1B8K56hz4dxTjbeC1a3KpAg9TYQ4PL=L5tAqtA30eWnkeyw@mail.gmail.com>
2020-02-26 13:17     ` Mehran Memarnejad
2020-02-26 13:20       ` Paul Barker

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.