[oe] Finding out the IMAGE_BASENAME of the image beeing built

Ulf Samuelsson openembedded at emagii.com
Sat Mar 30 14:36:18 UTC 2013


On 2013-03-30 14:04, Takeshi Hamasaki wrote:
> Hi Ulf,
>
> $ MACHINE=beagleboard  bitbake -e some-image
>
> shows all variables including $IMAGE_BASENAME without actually
> building the image.
> Using grep you can take the value of IMAGE_BASENAME, like as:

Thanks,

bitbake is already running to build my recipe.
Not sure that running "bitbake -e" is OK while bitbake is already running.

IMAGE_BASENAME is set to my recipe, so I cannot use this directly.

> $ MACHINE=beagleboard  bitbake -e some-image | grep ^IMAGE_BASENAME
>
> Does it help you?
>
> If possible, consider to use hooks, for example, IMAGE_POSTPROCESS_COMMAND .
> Refer image.bbclass for details. It might make things straiter.
>
> Regards,

I know I can do it inside the "some-image.bb" recipe, but I would like
to do it inside my recipe. Otherwise all images must be customized
for my recipe, which is not a good idea.

If I could do an IMAGE_POSTPROCESS_COMMAND in my recipe, then
that would be OK, but I then still need to find out what the image name is.

BR
Ulf Samuelsson





More information about the Openembedded-devel mailing list