* How to log inside a recipe #yocto
@ 2021-12-07 7:04 mousavy.system2005
2021-12-07 7:10 ` tomzy
0 siblings, 1 reply; 4+ messages in thread
From: mousavy.system2005 @ 2021-12-07 7:04 UTC (permalink / raw)
To: yocto
[-- Attachment #1: Type: text/plain, Size: 179 bytes --]
Hi
There is a variable (or what ever it's called) inside a recipe. I want to know its value.
I've used `bbnote "something"` but this gives a parse error.
How to properly log?
[-- Attachment #2: Type: text/html, Size: 191 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: How to log inside a recipe #yocto
2021-12-07 7:04 How to log inside a recipe #yocto mousavy.system2005
@ 2021-12-07 7:10 ` tomzy
2021-12-07 7:53 ` mousavy.system2005
0 siblings, 1 reply; 4+ messages in thread
From: tomzy @ 2021-12-07 7:10 UTC (permalink / raw)
To: yocto
[-- Attachment #1: Type: text/plain, Size: 463 bytes --]
Hi
To get a value of some variable added in recipe it is best to use bitbake
with `-e` flag which should print the whole environment, then one can just
use `grep` to search for given variable. Let say we have recipe `example.bb`
and need to know the value of `A_VAR` - with bitbake you can find it with
`bitbake -e example | grep ^A_VAR`
Regards
--
Tomasz Żyjewski
Embedded Systems Engineer
GPG: 5C495EA3EBEECA59
https://3mdeb.com | @3mdeb_com
[-- Attachment #2: Type: text/html, Size: 588 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: How to log inside a recipe #yocto
2021-12-07 7:10 ` tomzy
@ 2021-12-07 7:53 ` mousavy.system2005
2021-12-07 8:49 ` tomzy
0 siblings, 1 reply; 4+ messages in thread
From: mousavy.system2005 @ 2021-12-07 7:53 UTC (permalink / raw)
To: yocto
[-- Attachment #1: Type: text/plain, Size: 161 bytes --]
Thanks a lot. That works perfectly, but do you know how to use the log commands inside the recipe? It seems they work inside functions only (`do_install` e.g.)
[-- Attachment #2: Type: text/html, Size: 161 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: How to log inside a recipe #yocto
2021-12-07 7:53 ` mousavy.system2005
@ 2021-12-07 8:49 ` tomzy
0 siblings, 0 replies; 4+ messages in thread
From: tomzy @ 2021-12-07 8:49 UTC (permalink / raw)
To: yocto
[-- Attachment #1: Type: text/plain, Size: 411 bytes --]
This is not something I do a lot but from what I know, you should be able
to use `bbnote` expresions etc inside the functions like `do_install` or
`do_compile` only if you inherit the `logging` bbclass
https://git.yoctoproject.org/poky/tree/meta/classes/logging.bbclass within
your recipes.
Regards
--
Tomasz Żyjewski
Embedded Systems Engineer
GPG: 5C495EA3EBEECA59
https://3mdeb.com | @3mdeb_com
[-- Attachment #2: Type: text/html, Size: 680 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-12-07 8:49 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-07 7:04 How to log inside a recipe #yocto mousavy.system2005
2021-12-07 7:10 ` tomzy
2021-12-07 7:53 ` mousavy.system2005
2021-12-07 8:49 ` tomzy
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.