Search code examples
cross-compilingzeromqyoctobitbake

bitbake can't build cppzmq when it's included in an image


I'm building a yocto project which uses cppzmq (http://layers.openembedded.org/layerindex/recipe/123508/)

The strange thing is that when I build it directly bitbake cppzmq it builds successfully.

But when I include it in my image IMAGE_INSTALL_append = " cppzmq" there is an error:

ERROR: Nothing RPROVIDES 'cppzmq' (but /home/ccccc/yocto-tegra/meta-eee/recipes-images/images/image-eee.bb RDEPENDS on or otherwise requires it)
NOTE: Runtime target 'cppzmq' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['cppzmq']
ERROR: Required build target 'image-eee' has no buildable providers.
Missing or unbuildable dependency chain was: ['image-eee', 'cppzmq']

If I run bitbake-layers show-recipes cppz*, it shows:

Parsing of 2234 .bb files complete (2233 cached, 1 parsed). 3398 targets, 141 skipped, 0 masked, 0 errors.
=== Matching recipes: ===
cppzmq:
  meta-oe              4.6.0

it's clearly included.

I don't know why cppzmq can't build when it's included in an image.

Thanks.


Solution

  • It is important to distinguish between the recipe name cppzmq and the provided packages of the recipe. A single recipe can provide several packages (<recipename>, <recipename>-dev, <recipename>-staticdev etc.).

    With IMAGE_INSTALL you define which packages are included in the image.

    Looking at the cppzmq recipe you can see that it only provides PACKAGES = "${PN}-dev".

    Hence you should use IMAGE_INSTALL_append = " cppzmq-dev"