All of lore.kernel.org
 help / color / mirror / Atom feed
* Best way to remove DISTRO_FEATURES?
@ 2014-05-14 13:04 Neuer User
  2014-05-14 13:36 ` Vaduva alexandru
  2014-05-14 13:56 ` Burton, Ross
  0 siblings, 2 replies; 17+ messages in thread
From: Neuer User @ 2014-05-14 13:04 UTC (permalink / raw)
  To: yocto

Hi

I have a small custom image based on the core-image-minimal.

Due to some DISTRO features (3g, nfc, a.o.) I get useless packages
included (ofono, neard). What is the best way to remove them?

Can the distro content be changed? Or would I need to build my own
distro? (Which would be not so easy looking at the complex poky.conf
configuration files...)

Thanks

Michael



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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:04 Best way to remove DISTRO_FEATURES? Neuer User
@ 2014-05-14 13:36 ` Vaduva alexandru
  2014-05-14 13:54   ` Neuer User
  2014-05-14 13:56 ` Burton, Ross
  1 sibling, 1 reply; 17+ messages in thread
From: Vaduva alexandru @ 2014-05-14 13:36 UTC (permalink / raw)
  To: Neuer User, yocto@yoctoproject.org

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


Depending on your situation.
If it is a one time yob you can do:
DISTRO_FEATURES_remove = " xxxxx" in your local.conf

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

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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:36 ` Vaduva alexandru
@ 2014-05-14 13:54   ` Neuer User
  2014-05-14 13:58     ` Burton, Ross
  2014-05-14 14:01     ` Anders Darander
  0 siblings, 2 replies; 17+ messages in thread
From: Neuer User @ 2014-05-14 13:54 UTC (permalink / raw)
  To: yocto

Well, no, not a one-time job. So I rather added

DISTRO_FEATURES_remove = " 3g bluetooth irda nfc zeroconf x11 wayland"

to my image.bb file. Guess, this is then the recommended way to go?

Thanks,

Michael

Am 14.05.2014 15:36, schrieb Vaduva alexandru:
> 
> Depending on your situation.
> If it is a one time yob you can do:
> DISTRO_FEATURES_remove = " xxxxx" in your local.conf
> 
> 
> -- 
> 




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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:04 Best way to remove DISTRO_FEATURES? Neuer User
  2014-05-14 13:36 ` Vaduva alexandru
@ 2014-05-14 13:56 ` Burton, Ross
  1 sibling, 0 replies; 17+ messages in thread
From: Burton, Ross @ 2014-05-14 13:56 UTC (permalink / raw)
  To: Neuer User; +Cc: yocto@yoctoproject.org

On 14 May 2014 14:04, Neuer User <auslands-kv@gmx.de> wrote:
> Can the distro content be changed? Or would I need to build my own
> distro? (Which would be not so easy looking at the complex poky.conf
> configuration files...)

The "quick" solution is DISTRO_FEATURES_remove="nfc 3g" in local.conf.
 For most non-trivial uses of Yocto you'll want your own distro
anyway, but you can either copy poky.conf or include poky.conf from
your own distro.conf and then use DISTRO_FEATURES_remove.

Ross


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:54   ` Neuer User
@ 2014-05-14 13:58     ` Burton, Ross
  2014-05-14 14:02       ` Philip Balister
  2014-05-14 14:03       ` Neuer User
  2014-05-14 14:01     ` Anders Darander
  1 sibling, 2 replies; 17+ messages in thread
From: Burton, Ross @ 2014-05-14 13:58 UTC (permalink / raw)
  To: Neuer User; +Cc: yocto@yoctoproject.org

On 14 May 2014 14:54, Neuer User <auslands-kv@gmx.de> wrote:
> to my image.bb file. Guess, this is then the recommended way to go?

Not in your image recipe, no, as then e.g. connman will still think
that you need 3g and nfc.

Ross


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:54   ` Neuer User
  2014-05-14 13:58     ` Burton, Ross
@ 2014-05-14 14:01     ` Anders Darander
  1 sibling, 0 replies; 17+ messages in thread
From: Anders Darander @ 2014-05-14 14:01 UTC (permalink / raw)
  To: yocto

* Neuer User <auslands-kv@gmx.de> [140514 15:56]:
> Well, no, not a one-time job. So I rather added
> DISTRO_FEATURES_remove = " 3g bluetooth irda nfc zeroconf x11 wayland"
> to my image.bb file. Guess, this is then the recommended way to go?

Well, the quick solution is to add that line to local.conf.

The image.bb file is far to late to change the distro configuration.

The better, long term solution would be to define your own distro. Which
really isn't that hard.

Cheers,
Anders

-- 
Anders Darander
ChargeStorm AB / eStorm AB


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:58     ` Burton, Ross
@ 2014-05-14 14:02       ` Philip Balister
  2014-05-14 14:03       ` Neuer User
  1 sibling, 0 replies; 17+ messages in thread
From: Philip Balister @ 2014-05-14 14:02 UTC (permalink / raw)
  To: Burton, Ross, Neuer User; +Cc: yocto@yoctoproject.org

On 05/14/2014 09:58 AM, Burton, Ross wrote:
> On 14 May 2014 14:54, Neuer User <auslands-kv@gmx.de> wrote:
>> to my image.bb file. Guess, this is then the recommended way to go?
> 
> Not in your image recipe, no, as then e.g. connman will still think
> that you need 3g and nfc.

What Ross said. DISTRO features should only be changed in distro conf
file (or local conf files for testing/local changes).

Philip

> 
> Ross
> 


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 13:58     ` Burton, Ross
  2014-05-14 14:02       ` Philip Balister
@ 2014-05-14 14:03       ` Neuer User
  2014-05-14 14:13         ` Burton, Ross
  1 sibling, 1 reply; 17+ messages in thread
From: Neuer User @ 2014-05-14 14:03 UTC (permalink / raw)
  To: yocto

Am 14.05.2014 15:58, schrieb Burton, Ross:
> On 14 May 2014 14:54, Neuer User <auslands-kv@gmx.de> wrote:
>> to my image.bb file. Guess, this is then the recommended way to go?
> 
> Not in your image recipe, no, as then e.g. connman will still think
> that you need 3g and nfc.
> 
> Ross
> 
Right. It doesn't work.

Hmm, so I need my own distro?

Actually, it is not 100% clear to me what the difference and the
interaction of "distro" and "image" is.

What I need is several (slightly to strongly) different images for my
system. Some are for testing only (include some debug apps), some are
for production purposes, some are used as initramfs (very minimal).

So, I should build my own distro, include poky.conf and add the
DISTRO_FEATURES_remove there?

Thanks

Michael



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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:03       ` Neuer User
@ 2014-05-14 14:13         ` Burton, Ross
  2014-05-14 14:22           ` Neuer User
  0 siblings, 1 reply; 17+ messages in thread
From: Burton, Ross @ 2014-05-14 14:13 UTC (permalink / raw)
  To: Neuer User; +Cc: yocto@yoctoproject.org

On 14 May 2014 15:03, Neuer User <auslands-kv@gmx.de> wrote:
> Hmm, so I need my own distro?

You don't need to as local.conf is sufficient, but changes to
local.conf are specific to *your current* builds.

Defining a distro is trivial, just make your own distro.conf and
either include poky.conf or actually look at it and see how little
that conf file is actually doing.  The default values (which is not
Poky) are a good starting point.

> Actually, it is not 100% clear to me what the difference and the
> interaction of "distro" and "image" is.

Distro affects everything you build, an image is simply instructions
on how to put some packages together into a disk image.

Ross


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:13         ` Burton, Ross
@ 2014-05-14 14:22           ` Neuer User
  2014-05-14 14:27             ` Burton, Ross
  2014-05-14 14:27             ` Vaduva alexandru
  0 siblings, 2 replies; 17+ messages in thread
From: Neuer User @ 2014-05-14 14:22 UTC (permalink / raw)
  To: yocto

Ok, thanks, did this:

made new file "meta-mylayer/conf/distro/mydistro.conf":

include poky.conf

DISTRO_FEATURES_remove = " 3g bluetooth irda nfc zeroconf x11 wayland"

Then changed conf/local.conf:

DISTRO ?= "mydistro"


Then started a bitbake. Got a strange error "LCONF_VERSION is 6, should
be 5 in bblayers.conf". So I changed it to 5.

Then bitbake works, but it seems to recompile ALL packages?! Is this
correct. (I stopped it as it will take half a day to finish).

Thanks again for your help!

Michael

Am 14.05.2014 16:13, schrieb Burton, Ross:
> On 14 May 2014 15:03, Neuer User <auslands-kv@gmx.de> wrote:
>> Hmm, so I need my own distro?
> 
> You don't need to as local.conf is sufficient, but changes to
> local.conf are specific to *your current* builds.
> 
> Defining a distro is trivial, just make your own distro.conf and
> either include poky.conf or actually look at it and see how little
> that conf file is actually doing.  The default values (which is not
> Poky) are a good starting point.
> 
>> Actually, it is not 100% clear to me what the difference and the
>> interaction of "distro" and "image" is.
> 
> Distro affects everything you build, an image is simply instructions
> on how to put some packages together into a disk image.
> 
> Ross
> 




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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:22           ` Neuer User
@ 2014-05-14 14:27             ` Burton, Ross
  2014-05-14 14:35               ` Neuer User
  2014-05-14 14:27             ` Vaduva alexandru
  1 sibling, 1 reply; 17+ messages in thread
From: Burton, Ross @ 2014-05-14 14:27 UTC (permalink / raw)
  To: Neuer User; +Cc: yocto@yoctoproject.org

On 14 May 2014 15:22, Neuer User <auslands-kv@gmx.de> wrote:
> Then started a bitbake. Got a strange error "LCONF_VERSION is 6, should
> be 5 in bblayers.conf". So I changed it to 5.

So that's because the Poky layers are a version higher than the
oe-core layers.  Once you stop using Poky the version drops.  Annoying
but you won't have to do it again.

> Then bitbake works, but it seems to recompile ALL packages?! Is this
> correct. (I stopped it as it will take half a day to finish).

Yes.  bitbake doesn't know that "nfc" only actually impacts a few
recipes, so a changed DISTRO_FEATURES means a new toolchain which
means everything else rebuilds.

Half a day for a build suggests you're building in a VM or a slow
laptop: I recommend using a desktop machine with plenty of RAM.

Ross


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:22           ` Neuer User
  2014-05-14 14:27             ` Burton, Ross
@ 2014-05-14 14:27             ` Vaduva alexandru
  1 sibling, 0 replies; 17+ messages in thread
From: Vaduva alexandru @ 2014-05-14 14:27 UTC (permalink / raw)
  To: Neuer User, yocto@yoctoproject.org

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

Read this for more information and to understand the difference between distro, machine or image features.


Yocto Project Reference Manual
 
 Yocto Project Reference Manual
Chapter7.Classes Table of Contents 7.1. allarch.bbclass 7.2. archiver.bbclass 7.3. autotools.bbclass 7.4. autotools-brokensep.bbclass 7.5. base.bbclass 7.6. bin_package.bbclass 7.7. binconfig.bbclass   
View on www.yoctoproject.org Preview by Yahoo  

On Wednesday, May 14, 2014 5:23 PM, Neuer User <auslands-kv@gmx.de> wrote:
 
Ok, thanks, did this:

made new file "meta-mylayer/conf/distro/mydistro.conf":

include poky.conf

DISTRO_FEATURES_remove = " 3g bluetooth irda nfc zeroconf x11 wayland"

Then changed conf/local.conf:

DISTRO ?= "mydistro"


Then started a bitbake. Got a strange error "LCONF_VERSION is 6, should
be 5 in bblayers.conf". So I changed it to 5.

Then bitbake works, but it seems to recompile ALL packages?! Is this
correct. (I stopped it as it will take half a day to finish).

Thanks again for your help!

Michael


Am 14.05.2014 16:13, schrieb Burton, Ross:
> On 14 May 2014 15:03, Neuer User <auslands-kv@gmx.de> wrote:
>> Hmm, so I need my own distro?
> 
> You don't need to as local.conf is sufficient, but changes to
> local.conf are specific to *your current* builds.
> 
> Defining a distro is trivial, just make your own distro.conf and
> either include poky.conf or actually look at it and see how little
> that conf file is actually doing.  The default values (which is not
> Poky) are a good starting point.
> 
>> Actually, it is not 100% clear to me what the difference and the
>> interaction of "distro" and "image" is.
> 
> Distro affects everything you build, an image is simply instructions
> on how to put some packages together into a disk image.
> 
> Ross
> 


-- 
_______________________________________________
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto

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

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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:27             ` Burton, Ross
@ 2014-05-14 14:35               ` Neuer User
  2014-05-14 14:42                 ` Neuer User
  2014-05-14 14:43                 ` Burton, Ross
  0 siblings, 2 replies; 17+ messages in thread
From: Neuer User @ 2014-05-14 14:35 UTC (permalink / raw)
  To: yocto

Am 14.05.2014 16:27, schrieb Burton, Ross:
> On 14 May 2014 15:22, Neuer User <auslands-kv@gmx.de> wrote:
>> Then started a bitbake. Got a strange error "LCONF_VERSION is 6, should
>> be 5 in bblayers.conf". So I changed it to 5.
> 
> So that's because the Poky layers are a version higher than the
> oe-core layers.  Once you stop using Poky the version drops.  Annoying
> but you won't have to do it again.
> 
Hmm, even if I include poky.conf? Or should I rather use "inherit"?
Would it make a difference? I will make a fast test.

>> Then bitbake works, but it seems to recompile ALL packages?! Is this
>> correct. (I stopped it as it will take half a day to finish).
> 
> Yes.  bitbake doesn't know that "nfc" only actually impacts a few
> recipes, so a changed DISTRO_FEATURES means a new toolchain which
> means everything else rebuilds.
> 
Strangely, when adding the "DISTRO_FEATURES_remove" to local.conf
instead of making a new distro, bitbake does not recompile everything?!

> Half a day for a build suggests you're building in a VM or a slow
> laptop: I recommend using a desktop machine with plenty of RAM.
> 
It's a VM, but just for management purposes. The host is a core-i7
desktop machine. However, I do have Qt5 and this alone takes app 1-2
hours to build. (Actually, only Qt5webkit alone takes more than half an
hour). :-/

> Ross
> 




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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:35               ` Neuer User
@ 2014-05-14 14:42                 ` Neuer User
  2014-05-15 20:43                   ` Richard Purdie
  2014-05-14 14:43                 ` Burton, Ross
  1 sibling, 1 reply; 17+ messages in thread
From: Neuer User @ 2014-05-14 14:42 UTC (permalink / raw)
  To: yocto

Probably solved. It should be

include conf/distro/poky.conf

instead of

include poky.conf.

(Stupid newbie error).

Now bblayers.conf has been automatically updated to "6" again and the
system only recompiles a few packages. Should be finished in 10 min or
so. :-)

Am 14.05.2014 16:35, schrieb Neuer User:
> Am 14.05.2014 16:27, schrieb Burton, Ross:
>> On 14 May 2014 15:22, Neuer User <auslands-kv@gmx.de> wrote:
>>> Then started a bitbake. Got a strange error "LCONF_VERSION is 6, should
>>> be 5 in bblayers.conf". So I changed it to 5.
>>
>> So that's because the Poky layers are a version higher than the
>> oe-core layers.  Once you stop using Poky the version drops.  Annoying
>> but you won't have to do it again.
>>
> Hmm, even if I include poky.conf? Or should I rather use "inherit"?
> Would it make a difference? I will make a fast test.
> 
>>> Then bitbake works, but it seems to recompile ALL packages?! Is this
>>> correct. (I stopped it as it will take half a day to finish).
>>
>> Yes.  bitbake doesn't know that "nfc" only actually impacts a few
>> recipes, so a changed DISTRO_FEATURES means a new toolchain which
>> means everything else rebuilds.
>>
> Strangely, when adding the "DISTRO_FEATURES_remove" to local.conf
> instead of making a new distro, bitbake does not recompile everything?!
> 
>> Half a day for a build suggests you're building in a VM or a slow
>> laptop: I recommend using a desktop machine with plenty of RAM.
>>
> It's a VM, but just for management purposes. The host is a core-i7
> desktop machine. However, I do have Qt5 and this alone takes app 1-2
> hours to build. (Actually, only Qt5webkit alone takes more than half an
> hour). :-/
> 
>> Ross
>>
> 
> 




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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:35               ` Neuer User
  2014-05-14 14:42                 ` Neuer User
@ 2014-05-14 14:43                 ` Burton, Ross
  1 sibling, 0 replies; 17+ messages in thread
From: Burton, Ross @ 2014-05-14 14:43 UTC (permalink / raw)
  To: Neuer User; +Cc: yocto@yoctoproject.org

On 14 May 2014 15:35, Neuer User <auslands-kv@gmx.de> wrote:
> Strangely, when adding the "DISTRO_FEATURES_remove" to local.conf
> instead of making a new distro, bitbake does not recompile everything?!

Well, there's some logic to avoid rebuilds if the distro features
change in a way that the recipe *can't* change, but changing the
distro name impacts *everything*.

>> Half a day for a build suggests you're building in a VM or a slow
>> laptop: I recommend using a desktop machine with plenty of RAM.
>>
> It's a VM, but just for management purposes. The host is a core-i7
> desktop machine. However, I do have Qt5 and this alone takes app 1-2
> hours to build. (Actually, only Qt5webkit alone takes more than half an
> hour). :-/

Oh, WebKit, fair enough.  :)  Doing it outside of the VM is advisable,
but try giving the VM more memory: pretty sure my average i7 can build
webkit quicker than that.

Ross


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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-14 14:42                 ` Neuer User
@ 2014-05-15 20:43                   ` Richard Purdie
  2014-05-16  7:04                     ` Neuer User
  0 siblings, 1 reply; 17+ messages in thread
From: Richard Purdie @ 2014-05-15 20:43 UTC (permalink / raw)
  To: Neuer User; +Cc: yocto

On Wed, 2014-05-14 at 16:42 +0200, Neuer User wrote:
> Probably solved. It should be
> 
> include conf/distro/poky.conf
> 
> instead of
> 
> include poky.conf.
> 
> (Stupid newbie error).

FWIW if you said "require" instead of "include" you'd have got a useful
error saying it couldn't find the file.

Cheers,

Richard



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

* Re: Best way to remove DISTRO_FEATURES?
  2014-05-15 20:43                   ` Richard Purdie
@ 2014-05-16  7:04                     ` Neuer User
  0 siblings, 0 replies; 17+ messages in thread
From: Neuer User @ 2014-05-16  7:04 UTC (permalink / raw)
  To: yocto

Am 15.05.2014 22:43, schrieb Richard Purdie:
> On Wed, 2014-05-14 at 16:42 +0200, Neuer User wrote:
>> Probably solved. It should be
>>
>> include conf/distro/poky.conf
>>
>> instead of
>>
>> include poky.conf.
>>
>> (Stupid newbie error).
> 
> FWIW if you said "require" instead of "include" you'd have got a useful
> error saying it couldn't find the file.
> 
> Cheers,
> 
> Richard
> 

Ah, really? So, "include" means, "if you find it then include it -  if
not, then doesn't matter"?

Good to know :-)

Thanks to everybody. I have it working now :-)

Michael



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

end of thread, other threads:[~2014-05-16  7:04 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-14 13:04 Best way to remove DISTRO_FEATURES? Neuer User
2014-05-14 13:36 ` Vaduva alexandru
2014-05-14 13:54   ` Neuer User
2014-05-14 13:58     ` Burton, Ross
2014-05-14 14:02       ` Philip Balister
2014-05-14 14:03       ` Neuer User
2014-05-14 14:13         ` Burton, Ross
2014-05-14 14:22           ` Neuer User
2014-05-14 14:27             ` Burton, Ross
2014-05-14 14:35               ` Neuer User
2014-05-14 14:42                 ` Neuer User
2014-05-15 20:43                   ` Richard Purdie
2014-05-16  7:04                     ` Neuer User
2014-05-14 14:43                 ` Burton, Ross
2014-05-14 14:27             ` Vaduva alexandru
2014-05-14 14:01     ` Anders Darander
2014-05-14 13:56 ` Burton, Ross

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.