All of lore.kernel.org
 help / color / mirror / Atom feed
* [recipe]variable shared
@ 2012-09-12  8:29 Sophie Bonnouvrier
  2012-09-12 18:40 ` Khem Raj
  0 siblings, 1 reply; 2+ messages in thread
From: Sophie Bonnouvrier @ 2012-09-12  8:29 UTC (permalink / raw)
  To: openembedded-devel

hello,

I would like to set a variable in a recipe and used it in another one.
but when I get the variable in the second recipe the value is none.
How can I shared variable ?

Sophie


recipe 1:
export XENO_DIR = "${@get_xenomai_dir(bb, d)} "
export XENO_PV   = "${@get_xenomai_pv(bb, d)} "

recipe 2:
   xeno_dir = bb.data.getVar('XENO_DIR',d,1)
   xeno_pv  = bb.data.getVar('XENO_PV',d,1)



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

* Re: [recipe]variable shared
  2012-09-12  8:29 [recipe]variable shared Sophie Bonnouvrier
@ 2012-09-12 18:40 ` Khem Raj
  0 siblings, 0 replies; 2+ messages in thread
From: Khem Raj @ 2012-09-12 18:40 UTC (permalink / raw)
  To: openembedded-devel

On Wed, Sep 12, 2012 at 1:29 AM, Sophie Bonnouvrier
<sophie.bonnouvrier-ext@oneaccess-net.com> wrote:
>
>
> I would like to set a variable in a recipe and used it in another one.
> but when I get the variable in the second recipe the value is none.
> How can I shared variable ?

you have to define such variables in global metadata. any metadata
defined in recipe is recipe specific
may be add it to configuration metadata or some sort of abstracted out class.

>
> Sophie
>
>
> recipe 1:
> export XENO_DIR = "${@get_xenomai_dir(bb, d)} "
> export XENO_PV   = "${@get_xenomai_pv(bb, d)} "
>
> recipe 2:
>   xeno_dir = bb.data.getVar('XENO_DIR',d,1)
>   xeno_pv  = bb.data.getVar('XENO_PV',d,1)



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

end of thread, other threads:[~2012-09-12 18:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-12  8:29 [recipe]variable shared Sophie Bonnouvrier
2012-09-12 18:40 ` 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.