All of lore.kernel.org
 help / color / mirror / Atom feed
* Samba server?
@ 2013-03-06 23:31 Paul D. DeRocco
  2013-03-07 10:40 ` Martin Jansa
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-06 23:31 UTC (permalink / raw)
  To: yocto

The poky-danny-8.0 tree doesn't seem to have any Samba stuff in it. However,
openembedded does. My untutored, fumbling efforts to include the relevant
part of the latter in the former haven't succeeded. Is there an easy way to
do this? I just need the server, not the client.

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 
 



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

* Re: Samba server?
  2013-03-06 23:31 Samba server? Paul D. DeRocco
@ 2013-03-07 10:40 ` Martin Jansa
  2013-03-07 18:22   ` Paul D. DeRocco
  0 siblings, 1 reply; 20+ messages in thread
From: Martin Jansa @ 2013-03-07 10:40 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

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

On Wed, Mar 06, 2013 at 03:31:03PM -0800, Paul D. DeRocco wrote:
> The poky-danny-8.0 tree doesn't seem to have any Samba stuff in it. However,
> openembedded does. My untutored, fumbling efforts to include the relevant
> part of the latter in the former haven't succeeded. Is there an easy way to
> do this? I just need the server, not the client.

Are you talking about openembedded as openembedded-classic or
meta-openembedded?

Use samba from meta-openembedded.

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

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

* Re: Samba server?
  2013-03-07 10:40 ` Martin Jansa
@ 2013-03-07 18:22   ` Paul D. DeRocco
  2013-03-07 18:29     ` Martin Jansa
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-07 18:22 UTC (permalink / raw)
  To: 'Martin Jansa'; +Cc: yocto

> From: Martin Jansa
> 
> Are you talking about openembedded as openembedded-classic or
> meta-openembedded?
> 
> Use samba from meta-openembedded.

That's what I tried first. It's not a layer, but a collection of layers, and
the layer that contains samba is called meta-oe. So I tried to include
meta-openembedded/meta-oe, and it barfed due to the absence of
fontcache.bbclass. But fontcache.bbclass is nowhere to be found in
meta-openembedded; it's contained in openembedded-core/meta. So I included
openembedded-core/meta, and got some other error message containing about a
dozen lines of Python script that had raised an exception. I tried including
openembedded instead/too, and got other error messages.

To someone who understands the shape of the universe, this is probably easy
to figure out. I might feel the trunk, or the tail, but I don't know it's an
elephant yet.

Since samba is a fairly common, standard module, I was hoping someone here
had already done this, and could tell me what buttons to push. I've read the
scant docs on bitbake, and pretty much the entire Yocto docs and
Openembedded docs, and my head is spinning. I don't mind learning some
stuff, but if I have to spend six months becoming an expert on something
just to get it to work, then this is an economically unviable project for
me.

Or maybe I should just build the system without samba, run it, manually
install samba just like any other user, and then use dd to save the modified
image for production use. Does that sound like a good idea?

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-07 18:22   ` Paul D. DeRocco
@ 2013-03-07 18:29     ` Martin Jansa
  2013-03-07 22:29       ` Paul D. DeRocco
  0 siblings, 1 reply; 20+ messages in thread
From: Martin Jansa @ 2013-03-07 18:29 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

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

On Thu, Mar 07, 2013 at 10:22:54AM -0800, Paul D. DeRocco wrote:
> Or maybe I should just build the system without samba, run it, manually
> install samba just like any other user, and then use dd to save the modified
> image for production use. Does that sound like a good idea?

No, adding extra layer is pretty basic operation and should be properly
documented. Can you send some pointers what have you read about adding a
layer and what wasn't easy to understand?

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

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

* Re: Samba server?
  2013-03-07 18:29     ` Martin Jansa
@ 2013-03-07 22:29       ` Paul D. DeRocco
  2013-03-07 22:42         ` Martin Jansa
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-07 22:29 UTC (permalink / raw)
  To: 'Martin Jansa'; +Cc: yocto

> From: Martin Jansa [mailto:martin.jansa@gmail.com] 
> 
> No, adding extra layer is pretty basic operation and should 
> be properly
> documented. Can you send some pointers what have you read 
> about adding a
> layer and what wasn't easy to understand?

How to theoretically add a layer was easy enough to understand, but when it
failed to work, I came to a dead end.

I'm trying to make a basic non-GUI image based on the Atom cedartrail-nopvr
machine, plus Samba, so I began with the following items in BBLAYERS:

  meta
  meta-yocto
  meta-yocto-bsp
  meta-intel
  meta-intel/meta-cedartrail

and I built core-image-base. That worked fine, but of course it had no Samba
in it, nor is Samba anywhere to be found within the Yocto stuff. So I
downloaded meta-openembedded from their GIT server, which I know from my
Gumstix experience contains Samba in its meta-oe layer, added
meta-openembedded/meta-oe to the end of BBLAYERS, and tried bitbaking both
core-image-base and samba. I quickly got the following error:


ERROR: ParseError at
/home/pauld/yocto-atom/poky-danny-8.0/meta-openembedded/meta-oe/recipes-grap
hics/ttf-fonts/ttf.inc:12: Could not inherit file classes/fontcache.bbclass


There is no fontcache.bbclass anywhere within meta-openembedded, or the
Yocto stuff, but looking through their GIT repository I found it exists
within openembedded-core, in the meta layer. So I downloaded that, and added
openembedded-core/meta to BBLAYERS before meta-openembedded/meta-oe and
tried again. It got past the above error, but this time I got the following
shell script error:


ERROR: ExpansionError during parsing
/home/pauld/yocto-atom/poky-danny-8.0/meta-openembedded/meta-oe/recipes-supp
ort/maliit/maliit-framework_git.bb: Failure expanding variable
gtk_immodule_cache_postinst: ExpansionError: Failure expanding variable
gtk_immodule_cache_postinst, expression was if [ "x$D" != "x" ]; then
    for maj_ver in 2 3; do
        if [ -x $D/usr/bin/gtk-query-immodules-$maj_ver.0 ]; then
            IMFILES=$(ls $D/usr/lib/gtk-$maj_ver.0/*/immodules/*.so)
            ${@qemu_run_binary(d, '$D',
'/usr/bin/gtk-query-immodules-$maj_ver.0')} \
                $IMFILES > $D/etc/gtk-$maj_ver.0/gtk.immodules 2>/dev/null
&&
                sed -i -e "s:$D::" $D/etc/gtk-$maj_ver.0/gtk.immodules

            [ $? -ne 0 ] && exit 1
        fi
    done

    exit 0
fi
if [ ! -z `which gtk-query-immodules-2.0` ]; then
    gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules
fi
if [ ! -z `which gtk-query-immodules-3.0` ]; then
    gtk-query-immodules-3.0 > /etc/gtk-3.0/gtk.immodules
fi
 which triggered exception NameError: name 'qemu_run_binary' is not defined


I'm sure this e-mail mangled the above due to line wrapping, but I doubt
anyone really needs to know what's going on in that shell script, and the
final line is the only meaningful one. I suspect that the meta-oe layer is
dependent on yet another layer that defines this 'qemu_run_binary' function,
and that even though I've got all of openmbedded-core and meta-openembedded
under my poky-danny-8.0 directory, bitbake only parses those parts that are
mentioned in BBLAYERS, relying upon the user to deal with inter-layer
dependencies.

Perhaps I could grep a bazillion files looking for qemu_run_binary, but I'm
worried that I'm wasting my time down a blind alley. Is pulling in somebody
else's layer (in this case an OpenEmbedded layer into a Yocto system)
something that's supposed to work, or does it only work if it's been tried
and debugged by the experts who create these things in the first place?

(And why doesn't Yocto include Samba anyway? It seems more of a common
standard package than a lot of the stuff I see included.)

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-07 22:29       ` Paul D. DeRocco
@ 2013-03-07 22:42         ` Martin Jansa
  2013-03-27  8:09           ` Paul D. DeRocco
  0 siblings, 1 reply; 20+ messages in thread
From: Martin Jansa @ 2013-03-07 22:42 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

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

On Thu, Mar 07, 2013 at 02:29:08PM -0800, Paul D. DeRocco wrote:
> > From: Martin Jansa [mailto:martin.jansa@gmail.com] 
> > 
> > No, adding extra layer is pretty basic operation and should 
> > be properly
> > documented. Can you send some pointers what have you read 
> > about adding a
> > layer and what wasn't easy to understand?
> 
> How to theoretically add a layer was easy enough to understand, but when it
> failed to work, I came to a dead end.
> 
> I'm trying to make a basic non-GUI image based on the Atom cedartrail-nopvr
> machine, plus Samba, so I began with the following items in BBLAYERS:
> 
>   meta
>   meta-yocto
>   meta-yocto-bsp
>   meta-intel
>   meta-intel/meta-cedartrail
> 
> and I built core-image-base. That worked fine, but of course it had no Samba
> in it, nor is Samba anywhere to be found within the Yocto stuff. So I
> downloaded meta-openembedded from their GIT server, which I know from my
> Gumstix experience contains Samba in its meta-oe layer, added
> meta-openembedded/meta-oe to the end of BBLAYERS, and tried bitbaking both
> core-image-base and samba. I quickly got the following error:
> 
> 
> ERROR: ParseError at
> /home/pauld/yocto-atom/poky-danny-8.0/meta-openembedded/meta-oe/recipes-grap
> hics/ttf-fonts/ttf.inc:12: Could not inherit file classes/fontcache.bbclass

From those errors I guess you're trying to add meta-oe from master
branch which indeed is not compatible with danny release, use meta-oe
from danny branch.

> (And why doesn't Yocto include Samba anyway? It seems more of a common
> standard package than a lot of the stuff I see included.)

That's why it's called oe-core. uncommon stuff should be moved to more
specific layers.

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

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

* Re: Samba server?
  2013-03-07 22:42         ` Martin Jansa
@ 2013-03-27  8:09           ` Paul D. DeRocco
  2013-03-27  9:03             ` Anders Darander
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-27  8:09 UTC (permalink / raw)
  To: yocto

A couple weeks ago, several people here were kind enough to help me through
the process of adding the OpenEmbedded layer called
meta-openembedded/meta-oe to my core-image-base-cedartrail-nopvr build,
which I wanted because it contains Samba. I eventually got it to build
without errors. But still no Samba.

The log file shows that the layer.conf file for that layer is being read,
and there is indeed some recipes for Samba. The bitbake -s option lists
samba as one of the packages. But the logs only show a few of recipes being
processed from this layer, none having to do with Samba. I was under the
impression that adding a layer added the recipes in the layer, and caused
them to be built. Apparently not. What am I missing?

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-27  8:09           ` Paul D. DeRocco
@ 2013-03-27  9:03             ` Anders Darander
  2013-03-27 22:12               ` Paul D. DeRocco
  0 siblings, 1 reply; 20+ messages in thread
From: Anders Darander @ 2013-03-27  9:03 UTC (permalink / raw)
  To: yocto

* Paul D. DeRocco <pderocco@ix.netcom.com> [130327 09:09]:
> The log file shows that the layer.conf file for that layer is being read,
> and there is indeed some recipes for Samba. The bitbake -s option lists
> samba as one of the packages. But the logs only show a few of recipes being
> processed from this layer, none having to do with Samba. I was under the
> impression that adding a layer added the recipes in the layer, and caused
> them to be built. Apparently not. What am I missing?

Maybe a dumb question...

Have you added samba to the image that you're building?
Just adding a layer won't cause the added recipes to be built and
deployed.

If you have added samba to the image, could you share the image recipe
and build logs?
Can you build samba manually? (Calling bitbake samba, (though I don't
know if that's the correct name, as I haven't check the meta-oe-layer
for that)).

Cheers,
Anders

-- 
Anders Darander
ChargeStorm AB / eStorm AB


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

* Re: Samba server?
  2013-03-27  9:03             ` Anders Darander
@ 2013-03-27 22:12               ` Paul D. DeRocco
  2013-03-28  2:10                 ` ChenQi
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-27 22:12 UTC (permalink / raw)
  To: 'Anders Darander', yocto

> From: Anders Darander
> 
> Maybe a dumb question...
> 
> Have you added samba to the image that you're building?
> Just adding a layer won't cause the added recipes to be built and
> deployed.

It's not a dumb question. No, I haven't added samba to the image that I'm
building. I've read the Yocto Project Reference Manual (except certain
sections that are obviously irrelevant to a user), and the wretched Bitbake
manual, and I don't see any mention of doing anything other than adding
layers to bblayers.conf and tweaking local.conf.

I'm under the impression that, unless one is making metadata changes that
will ultimately be contributed back to the community, one treats the
poky-danny-8.0 tree as essentially readonly, and limits ones adjustments to
perhaps adding more metadata (as I've done by downloading
meta-openembedded), and editing bblayers.conf (as I've done by adding the
meta-openembedded/meta-oe layer) and a few settings in local.conf.

I don't see anything in those files that causes anything to be "added to the
image" other than the mentioning of various layers in bblayers.conf. Yet it
still manages to build a substantial system containing lots of stuff from
poky-danny-8.0, but only a few things from meta-openembedded/meta-oe, and
that doesn't include samba.

So where in the documentation does it explain this? If, as I suspect, the
answer is "nowhere", then somebody's going to have to hold my hand and tell
me how to "add samba to the image that I'm building", because I have no idea
how to do that.

Pardon my exasperation. I really do appreciate the help people have given me
here. I just wish it was possible to deduce this stuff by reading a decent
manual.

And if anyone who is part of the Yocto development team is looking for bugs
to fix, they should consider regarding the state of the documentation as a
great big fat "bug", and maybe devote 10% of the time to fixing that.

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-27 22:12               ` Paul D. DeRocco
@ 2013-03-28  2:10                 ` ChenQi
  2013-03-28  3:10                   ` Paul D. DeRocco
  2013-03-28 20:33                   ` Trevor Woerner
  0 siblings, 2 replies; 20+ messages in thread
From: ChenQi @ 2013-03-28  2:10 UTC (permalink / raw)
  To: yocto

On 03/28/2013 06:12 AM, Paul D. DeRocco wrote:
>> From: Anders Darander
>>
>> Maybe a dumb question...
>>
>> Have you added samba to the image that you're building?
>> Just adding a layer won't cause the added recipes to be built and
>> deployed.
> It's not a dumb question. No, I haven't added samba to the image that I'm
> building. I've read the Yocto Project Reference Manual (except certain
> sections that are obviously irrelevant to a user), and the wretched Bitbake
> manual, and I don't see any mention of doing anything other than adding
> layers to bblayers.conf and tweaking local.conf.
>
> I'm under the impression that, unless one is making metadata changes that
> will ultimately be contributed back to the community, one treats the
> poky-danny-8.0 tree as essentially readonly, and limits ones adjustments to
> perhaps adding more metadata (as I've done by downloading
> meta-openembedded), and editing bblayers.conf (as I've done by adding the
> meta-openembedded/meta-oe layer) and a few settings in local.conf.
>
> I don't see anything in those files that causes anything to be "added to the
> image" other than the mentioning of various layers in bblayers.conf. Yet it
> still manages to build a substantial system containing lots of stuff from
> poky-danny-8.0, but only a few things from meta-openembedded/meta-oe, and
> that doesn't include samba.
>
> So where in the documentation does it explain this? If, as I suspect, the
> answer is "nowhere", then somebody's going to have to hold my hand and tell
> me how to "add samba to the image that I'm building", because I have no idea
> how to do that.
>
> Pardon my exasperation. I really do appreciate the help people have given me
> here. I just wish it was possible to deduce this stuff by reading a decent
> manual.
>
> And if anyone who is part of the Yocto development team is looking for bugs
> to fix, they should consider regarding the state of the documentation as a
> great big fat "bug", and maybe devote 10% of the time to fixing that.
>
http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html
section 5.2 Customizing Images

In your case, you could add the following line to local.conf.
IMAGE_INSTALL_append += "samba"

And you can use 'bitbake -g <image_recipe_name>' to see whether samba is 
pulled in.

For all docs, see https://www.yoctoproject.org/documentation/current.

Best Regards,
Chen Qi


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

* Re: Samba server?
  2013-03-28  2:10                 ` ChenQi
@ 2013-03-28  3:10                   ` Paul D. DeRocco
  2013-03-28  3:24                     ` ChenQi
                                       ` (2 more replies)
  2013-03-28 20:33                   ` Trevor Woerner
  1 sibling, 3 replies; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-28  3:10 UTC (permalink / raw)
  To: 'ChenQi', yocto

> From: ChenQi
> 
> http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html
> section 5.2 Customizing Images
> 
> In your case, you could add the following line to local.conf.
> IMAGE_INSTALL_append += "samba"
> 
> And you can use 'bitbake -g <image_recipe_name>' to see 
> whether samba is pulled in.
> 
> For all docs, see https://www.yoctoproject.org/documentation/current.

Thanks for that pointer. I'll try that out.

So is there a general way to peruse the collection of recipes? Does one have
to do "ls -R *.bb" to get the list of recipes, then read the comments inside
the files to see how to use them?

And how does one know in advance which ones get included by default? Is
there some construct one looks for in the .bb file that indicates it gets
included? Or is there some master recipe that says "this depends upon this
big long list of standard recipes"?

And are any of the recipes that are included by default not actually
required, and if so, how do you un-include them if you want to pare down the
system to a bare minimum?

Or is there some master documentation that I just haven't found that lists
all the recipes in the Yocto project and gives some guidance on their use?

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-28  3:10                   ` Paul D. DeRocco
@ 2013-03-28  3:24                     ` ChenQi
  2013-03-28  5:55                     ` Anders Darander
  2013-04-01  9:32                     ` Paul Eggleton
  2 siblings, 0 replies; 20+ messages in thread
From: ChenQi @ 2013-03-28  3:24 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

On 03/28/2013 11:10 AM, Paul D. DeRocco wrote:
>> From: ChenQi
>>
>> http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html
>> section 5.2 Customizing Images
>>
>> In your case, you could add the following line to local.conf.
>> IMAGE_INSTALL_append += "samba"
>>
>> And you can use 'bitbake -g <image_recipe_name>' to see
>> whether samba is pulled in.
>>
>> For all docs, see https://www.yoctoproject.org/documentation/current.
> Thanks for that pointer. I'll try that out.
>
> So is there a general way to peruse the collection of recipes? Does one have
> to do "ls -R *.bb" to get the list of recipes, then read the comments inside
> the files to see how to use them?
>
> And how does one know in advance which ones get included by default? Is
> there some construct one looks for in the .bb file that indicates it gets
> included? Or is there some master recipe that says "this depends upon this
> big long list of standard recipes"?
>
> And are any of the recipes that are included by default not actually
> required, and if so, how do you un-include them if you want to pare down the
> system to a bare minimum?
>
> Or is there some master documentation that I just haven't found that lists
> all the recipes in the Yocto project and gives some guidance on their use?
>
http://docs.openembedded.org/bitbake/html/
http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html
The above two manuals might be sufficient for understanding the recipes 
and performing common tasks.

//Chen Qi


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

* Re: Samba server?
  2013-03-28  3:10                   ` Paul D. DeRocco
  2013-03-28  3:24                     ` ChenQi
@ 2013-03-28  5:55                     ` Anders Darander
  2013-03-28  6:05                       ` Paul D. DeRocco
  2013-04-01  9:32                     ` Paul Eggleton
  2 siblings, 1 reply; 20+ messages in thread
From: Anders Darander @ 2013-03-28  5:55 UTC (permalink / raw)
  To: yocto

* Paul D. DeRocco <pderocco@ix.netcom.com> [130328 04:11]:
> > From: ChenQi

> > http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html
> > section 5.2 Customizing Images

> > In your case, you could add the following line to local.conf.
> > IMAGE_INSTALL_append += "samba"

> > And you can use 'bitbake -g <image_recipe_name>' to see 
> > whether samba is pulled in.

> > For all docs, see https://www.yoctoproject.org/documentation/current.

> Thanks for that pointer. I'll try that out.

Chen Qi has already given you pointers to the documentation. Though,
I'll just add a few remarks that hopefully will kickstart your
understadning when reading the docs.

> So is there a general way to peruse the collection of recipes? Does one have
> to do "ls -R *.bb" to get the list of recipes, then read the comments inside
> the files to see how to use them?

No, the recipes themselves do not enforce their own inclusions into your
image. (That wouldn't really make sense, especially not when including
such a large layer as meta-oe).

> And how does one know in advance which ones get included by default? Is
> there some construct one looks for in the .bb file that indicates it gets
> included? Or is there some master recipe that says "this depends upon this
> big long list of standard recipes"?

Which image are you building? 

Say that you're building core-image-sato, then you'll have to look at
that recipe meta/recipes-sato/images/core-image-sato.bb. 

There you might find IMAGE_INSTALL, which defines what packages (and
package groupds) this recipe wants to install. 

The recipes can also define IMAGE_FEATURES, which are used by the
core-image.bbclass (which is inherited in the .bb-file), to add a number
of packages.

> And are any of the recipes that are included by default not actually
> required, and if so, how do you un-include them if you want to pare down the
> system to a bare minimum?

Sure, there's likely some stuff in most images that you're not
interested in. All the supplied images are there for some use-case, be
it demoing stuff, test, etc.

If you want to customize an image more, I'd recommend you to create your
own image. A first step might be to just copy one of the image recipes
to a layer of your own, and then modify it according to your taste.

Cheers,
Anders

-- 
Anders Darander
ChargeStorm AB / eStorm AB


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

* Re: Samba server?
  2013-03-28  5:55                     ` Anders Darander
@ 2013-03-28  6:05                       ` Paul D. DeRocco
  0 siblings, 0 replies; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-28  6:05 UTC (permalink / raw)
  To: 'Anders Darander', yocto

> From: Anders Darander
> 
> > So is there a general way to peruse the collection of 
> recipes? Does one have
> > to do "ls -R *.bb" to get the list of recipes, then read 
> the comments inside
> > the files to see how to use them?
> 
> No, the recipes themselves do not enforce their own 
> inclusions into your
> image. (That wouldn't really make sense, especially not when including
> such a large layer as meta-oe).
> 
> > And how does one know in advance which ones get included by 
> default? Is
> > there some construct one looks for in the .bb file that 
> indicates it gets
> > included? Or is there some master recipe that says "this 
> depends upon this
> > big long list of standard recipes"?
> 
> Which image are you building? 
> 
> Say that you're building core-image-sato, then you'll have to look at
> that recipe meta/recipes-sato/images/core-image-sato.bb. 
> 
> There you might find IMAGE_INSTALL, which defines what packages (and
> package groupds) this recipe wants to install. 
> 
> The recipes can also define IMAGE_FEATURES, which are used by the
> core-image.bbclass (which is inherited in the .bb-file), to 
> add a number
> of packages.
> 
> > And are any of the recipes that are included by default not actually
> > required, and if so, how do you un-include them if you want 
> to pare down the
> > system to a bare minimum?
> 
> Sure, there's likely some stuff in most images that you're not
> interested in. All the supplied images are there for some use-case, be
> it demoing stuff, test, etc.
> 
> If you want to customize an image more, I'd recommend you to 
> create your
> own image. A first step might be to just copy one of the image recipes
> to a layer of your own, and then modify it according to your taste.

Thanks. With everyone's help, the fog is gradually lifting.

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-28  2:10                 ` ChenQi
  2013-03-28  3:10                   ` Paul D. DeRocco
@ 2013-03-28 20:33                   ` Trevor Woerner
  2013-03-28 21:35                     ` Paul D. DeRocco
  1 sibling, 1 reply; 20+ messages in thread
From: Trevor Woerner @ 2013-03-28 20:33 UTC (permalink / raw)
  To: Robert P. J. Day, Paul D. DeRocco; +Cc: yocto

I'm kinda surprised Robert Day hasn't jumped in, I know he's got all
this straightened out :-)

On Wed, Mar 27, 2013 at 10:10 PM, ChenQi <Qi.Chen@windriver.com> wrote:
> In your case, you could add the following line to local.conf.
> IMAGE_INSTALL_append += "samba"

I thought this was not the generally accepted notation. I thought

    IMAGE_INSTALL_append = " samba"

(note the space before 'samba') was better. Having an _append bitbake
option and using += seems a bit redundant.

Sorry, Paul, for only noticing this thread now. I wrote a very quick
bunch of notes when I was going through this as well. Some of these
notes are probably out of date (they were "correct" at the time, but
trying to keep pace with Yocto is isn't easy!) but hopefully there's
something there that might help.

My notes are at:
https://github.com/twoerner/meta-trevor/blob/master/misc/notes

Specifically item #8 might be useful.

Robert Day wrote lots of notes which you can find starting here:
http://www.crashcourse.ca/wiki/index.php/Yocto_Project

Tim Bird too has written some good stuff:
http://elinux.org/Yocto_Project_Introduction

I'm sure there are others as well.


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

* Re: Samba server?
  2013-03-28 20:33                   ` Trevor Woerner
@ 2013-03-28 21:35                     ` Paul D. DeRocco
  2013-03-28 21:44                       ` Trevor Woerner
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-03-28 21:35 UTC (permalink / raw)
  To: 'Trevor Woerner', yocto

> From: Trevor Woerner
> 
> I'm kinda surprised Robert Day hasn't jumped in, I know he's got all
> this straightened out :-)
> 
> On Wed, Mar 27, 2013 at 10:10 PM, ChenQi 
> <Qi.Chen@windriver.com> wrote:
> > In your case, you could add the following line to local.conf.
> > IMAGE_INSTALL_append += "samba"
> 
> I thought this was not the generally accepted notation. I thought
> 
>     IMAGE_INSTALL_append = " samba"
> 
> (note the space before 'samba') was better. Having an _append bitbake
> option and using += seems a bit redundant.

That's what I thought, too, but what do I know? I tried it with += and no
space, and it does indeed work. I have no idea how this stuff is parsed
internally. Somehow, it grates on me that underscore is used almost like an
operator in BitBake.

> Sorry, Paul, for only noticing this thread now. I wrote a very quick
> bunch of notes when I was going through this as well. Some of these
> notes are probably out of date (they were "correct" at the time, but
> trying to keep pace with Yocto is isn't easy!) but hopefully there's
> something there that might help.
> 
> My notes are at:
> https://github.com/twoerner/meta-trevor/blob/master/misc/notes
> 
> Specifically item #8 might be useful.

Thanks. The distinction between recipes and packages is very useful to know.
So is some of the other stuff.

> Robert Day wrote lots of notes which you can find starting here:
> http://www.crashcourse.ca/wiki/index.php/Yocto_Project
> 
> Tim Bird too has written some good stuff:
> http://elinux.org/Yocto_Project_Introduction

I'll read those, too.

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-03-28 21:35                     ` Paul D. DeRocco
@ 2013-03-28 21:44                       ` Trevor Woerner
  0 siblings, 0 replies; 20+ messages in thread
From: Trevor Woerner @ 2013-03-28 21:44 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

On Thu, Mar 28, 2013 at 5:35 PM, Paul D. DeRocco <pderocco@ix.netcom.com> wrote:
> Somehow, it grates on me that underscore is used almost like an
> operator in BitBake.

You're not alone!

Because the people who did this are reading this list ;-) I'll be
polite, it is clever, but even after a year of trying to get
comfortable with it, I still think it is a poor paradigm.

A variable name is a variable name and should be only a variable name.
One shouldn't have to parse a variable name to try to determine what
operations should be performed on the value of a variable in addition
to whatever external operations are requested :-)

VARIABLE_append -= "feature"

??


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

* Re: Samba server?
  2013-03-28  3:10                   ` Paul D. DeRocco
  2013-03-28  3:24                     ` ChenQi
  2013-03-28  5:55                     ` Anders Darander
@ 2013-04-01  9:32                     ` Paul Eggleton
  2013-04-01 23:42                       ` Paul D. DeRocco
  2 siblings, 1 reply; 20+ messages in thread
From: Paul Eggleton @ 2013-04-01  9:32 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

On Wednesday 27 March 2013 20:10:40 Paul D. DeRocco wrote:
> So is there a general way to peruse the collection of recipes? Does one have
> to do "ls -R *.bb" to get the list of recipes, then read the comments
> inside the files to see how to use them?

There are a few useful tools here. Firstly, "bitbake-layers show-recipes" will 
list all recipes available in your current configuration, the versions 
available and which layers they are provided by. You can also specify a search 
keyword on the command line.

Additionally, "bitbake -s" will list all available "targets" (recipes, plus 
any BBCLASSEXTENDed variants, e.g. zlib-native) and the latest and current 
preferred versions.

Lastly, if you want to search all available recipes in community layers, there 
is now an online metadata index available:

  http://layers.openembedded.org/

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre


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

* Re: Samba server?
  2013-04-01  9:32                     ` Paul Eggleton
@ 2013-04-01 23:42                       ` Paul D. DeRocco
  2013-04-02  7:13                         ` Paul Eggleton
  0 siblings, 1 reply; 20+ messages in thread
From: Paul D. DeRocco @ 2013-04-01 23:42 UTC (permalink / raw)
  To: 'Paul Eggleton', yocto

> From: Paul Eggleton
> 
> There are a few useful tools here. Firstly, "bitbake-layers 
> show-recipes" will 
> list all recipes available in your current configuration, the 
> versions 
> available and which layers they are provided by. You can also 
> specify a search keyword on the command line.
> 
> Additionally, "bitbake -s" will list all available "targets" 
> (recipes, plus 
> any BBCLASSEXTENDed variants, e.g. zlib-native) and the 
> latest and current preferred versions.
> 
> Lastly, if you want to search all available recipes in 
> community layers, there 
> is now an online metadata index available:
> 
>   http://layers.openembedded.org/

I found the first one, and the second seems to show mostly the same info in
a different form.

What I don't see is any info on the recipes, beyond name and version number.
I don't see a list of packages they produce. For instance, doing "bitbake -e
samba", and then looking at the PACKAGES variable, shows the following list:

    libwbclient
    libwinbind
    libwinbind-dbg
    winbind
    winbind-dbg
    libnetapi
    libtdb
    libsmbsharemodes
    libsmbclient
    libsmbclient-dev
    cifs
    cifs-doc
    swat
    samba-dbg
    samba-staticdev
    samba-dev
    samba-doc
    samba-locale
    samba

I'm not sure what got included when I added "samba" to my IMAGE_INSTALL
variable, but I assume samba and winbind are required, but the other things?
To an end user like me (someone who just wants to build a distro with
certain capabilities, and then get back to the real work of application
development), the following sorts of questions occur:

    What choices are provided by each package?
    If something is included in the build, can I do without it?
    If something isn't included in the build, should I add it?

To be a real turn-key system, each recipe needs a page, or two, or three, of
human-written (not script-produced) explanation of what options the recipe
has, what they correspond to in user terms, and how they can be selected or
deselected. Without that, the recipe really isn't "documented" in the
conventional sense.

When I added samba to core-image-base-cedartrail-nopvr, the image got vastly
bigger. I wouldn't think the ability to do Windows file sharing would be
comparable in size to the rest of the system. Did it add tons of man pages
which no one will read, because it's an embedded system? Did it add a client
which I don't need, or just the server which I do need? Did it add libraries
to the target that will never be used? Eventually, I'll figure this out, but
I'm spending weeks and weeks on this, which is making this a very expensive
project. Perhaps I should have just hired someone else to do it for me.

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 



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

* Re: Samba server?
  2013-04-01 23:42                       ` Paul D. DeRocco
@ 2013-04-02  7:13                         ` Paul Eggleton
  0 siblings, 0 replies; 20+ messages in thread
From: Paul Eggleton @ 2013-04-02  7:13 UTC (permalink / raw)
  To: Paul D. DeRocco; +Cc: yocto

On Monday 01 April 2013 16:42:46 Paul D. DeRocco wrote:
>  What I don't see is any info on the recipes, beyond name and version
>  number.
> I don't see a list of packages they produce. For instance, doing "bitbake
> -e samba", and then looking at the PACKAGES variable, shows the following
> list:
> 
>     libwbclient
>     libwinbind
>     libwinbind-dbg
>     winbind
>     winbind-dbg
>     libnetapi
>     libtdb
>     libsmbsharemodes
>     libsmbclient
>     libsmbclient-dev
>     cifs
>     cifs-doc
>     swat
>     samba-dbg
>     samba-staticdev
>     samba-dev
>     samba-doc
>     samba-locale
>     samba
> 
> I'm not sure what got included when I added "samba" to my IMAGE_INSTALL
> variable, but I assume samba and winbind are required, but the other things?
> To an end user like me (someone who just wants to build a distro with
> certain capabilities, and then get back to the real work of application
> development), the following sorts of questions occur:
> 
>     What choices are provided by each package?
>     If something is included in the build, can I do without it?
>     If something isn't included in the build, should I add it?
> 
> To be a real turn-key system, each recipe needs a page, or two, or three, of
> human-written (not script-produced) explanation of what options the recipe
> has, what they correspond to in user terms, and how they can be selected or
> deselected. Without that, the recipe really isn't "documented" in the
> conventional sense.

I guess that would be helpful, but I don't know if we have the resources to
document that for every recipe. Usually that information is already available
upstream. It could be that we can get to this point later on.

> When I added samba to core-image-base-cedartrail-nopvr, the image got vastly
> bigger. I wouldn't think the ability to do Windows file sharing would be
> comparable in size to the rest of the system. 

As I understand it Samba 3 itself (upstream) is an special case in this regard
- it has a deficiency where it includes a substantial portion of its library
code in every executable, of which Samba provides quite a few, making
it quite large indeed. If you look at these executables on your standard
Linux distribution you'll probably find they are similarly sized. Last time
I searched about the problem it was acknowledged by the developers but
they didn't seem overly interested in solving it at the time, which is
unfortunate. Hopefully Samba 4 is better in this regard. Here is the
thread:

http://lists.samba.org/archive/samba/2009-October/151096.html

> Did it add tons of man pages which no one will read, because it's an
> embedded system?

In the absence of bugs, we do package documentation separately (*-doc
packages) so that is unlikely to be the case.

> Did it add a
> client which I don't need, or just the server which I do need? Did it add
> libraries to the target that will never be used? Eventually, I'll figure
> this out, but I'm spending weeks and weeks on this, which is making this a
> very expensive project. Perhaps I should have just hired someone else to do
> it for me.

FWIW, we do strive to make things as minimal as we can; that's why we split
things up into so many packages. You've done the right thing in just adding
the main "samba" package to the image, it's just that Samba itself is quite
large and beyond patching the source or splitting packages further there's not
a lot that can be done about it.

FYI if you're interested in some analysis of the contents of final images you
may find buildhistory useful. There is a section of the manual about it here:

http://www.yoctoproject.org/docs/latest/poky-ref-manual/poky-ref-manual.html#maintaining-build-output-quality

Also, I know this doesn't help you much right now, but FYI we plan to
build more powerful image contents analysis tools into Web Hob, which
will be a web-based frontend to the build system.

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre


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

end of thread, other threads:[~2013-04-02  7:13 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-06 23:31 Samba server? Paul D. DeRocco
2013-03-07 10:40 ` Martin Jansa
2013-03-07 18:22   ` Paul D. DeRocco
2013-03-07 18:29     ` Martin Jansa
2013-03-07 22:29       ` Paul D. DeRocco
2013-03-07 22:42         ` Martin Jansa
2013-03-27  8:09           ` Paul D. DeRocco
2013-03-27  9:03             ` Anders Darander
2013-03-27 22:12               ` Paul D. DeRocco
2013-03-28  2:10                 ` ChenQi
2013-03-28  3:10                   ` Paul D. DeRocco
2013-03-28  3:24                     ` ChenQi
2013-03-28  5:55                     ` Anders Darander
2013-03-28  6:05                       ` Paul D. DeRocco
2013-04-01  9:32                     ` Paul Eggleton
2013-04-01 23:42                       ` Paul D. DeRocco
2013-04-02  7:13                         ` Paul Eggleton
2013-03-28 20:33                   ` Trevor Woerner
2013-03-28 21:35                     ` Paul D. DeRocco
2013-03-28 21:44                       ` Trevor Woerner

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.