<div class="gmail_extra">On Thu, Nov 22, 2012 at 1:43 PM, Robert P. J. Day <span dir="ltr"><<a href="mailto:rpjday@crashcourse.ca" target="_blank">rpjday@crashcourse.ca</a>></span> wrote:<br><div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="im">On Thu, 22 Nov 2012, Chris Larson wrote:<br>
<br>
</div><div class="im">> I would personally like to see something like:<br>
><br>
> bitbake -E MACHINE,DISTRO,TMPDIR<br>
><br>
> Rather than having to define additional 'grouping' metadata.<br>
><br>
> For now, something like this might be convenient:<br>
><br>
> $ cat ~/bin/bitbake-env<br>
> #!/bin/sh<br>
> #<br>
> # bitbake-env VARIABLE [VARIBLE...]<br>
> #<br>
> # Filter out particular variables from bitbake -e, including the commented out<br>
> # unexpanded form, and both exported and unexported.<br>
><br>
> args_pattern () {<br>
> for arg; do<br>
> printf "$arg|"<br>
> done | sed 's,|$,,'<br>
> }<br>
><br>
> bitbake -e | grep -E "^((export )?|(# )?)($(args_pattern "$@"))="<br>
<br>
</div> ok, but there's still something i'm missing. from<br>
<a href="http://linux-yocto_3.4.bb" target="_blank">linux-yocto_3.4.bb</a>, i might want to see the final value of<br>
LINUX_VERSION, but that's not printed as part of the normal<br>
environment, so i'm assuming i'd need to export it first, right?<br>
because there's a lot of content i'd be interested in seeing that is<br>
currently not printed by "bitbake -e".</blockquote></div><br>Yeah, that quick script just ran bitbake -e, not bitbake -e <provider>. You could modify it easily enough to support that, though.</div><div class="gmail_extra">
<br></div><div class="gmail_extra">You could also try out <a href="https://gist.github.com/4133101">https://gist.github.com/4133101</a>. It's just a quick prototype. Drop it next to bitbake in bitbake/bin/. It fixes a couple minor annoyances with bitbake -e and it sends all the bitbake log output from stdout to stderr, so you can redirect that independently of the emitted variables and values.</div>
<div class="gmail_extra"><br></div><div class="gmail_extra">Usage examples:</div><div class="gmail_extra"><br></div><div class="gmail_extra"> bitbake-env DISTRO MACHINE do_configure</div><div class="gmail_extra"> bitbake-env -r virtual/kernel FILE</div>
<div class="gmail_extra"> eval $(bitbake-env TMPDIR | grep -v '^#')</div><div class="gmail_extra">-- <br>Christopher Larson<br>
</div>