This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM62A3: Support for the including the opencv packages in the build.

Part Number: AM62A3

Tool/software:

Hello ti,

I am trying to add the below opencv packages in the build : 

- opencv_dnn_objdetect 
-opencv_dnn_superres - opencv_freetype - opencv_hdf - opencv_text - opencv_viz

 Please suggest me how do I add it my build, do I need to include any specific layer or the recipe for the same.
I am using am62ax processor SDK - build version 9.02

  • When you review the OpenCV recipe at meta-openembedded/meta-oe/recipes-support/opencv/opencv_* you'll see that at least some of the packages you want are referenced in the PACKAGECONFIG[] object. To activate those features you need to add what's needed to the PACKAGECONFIG variable, see https://docs.yoctoproject.org/ref-manual/variables.html#term-PACKAGECONFIG

    Regards, Andreas

  • Hello Andreas,
    Thanks for the support, got most of the packages included but now I am getting the below error : 

    "Rebuild the library with Windows, GTK+ 2.x or Cocoa support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function 'cvShowImage'"

    How do I add support for libgtk2.0 in the build.

     
  • Hi Monica,

    "Rebuild the library with Windows, GTK+ 2.x or Cocoa support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function 'cvShowImage'"

    I suppose this error the result of adding one of the OpenCV packages?

    How do I add support for libgtk2.0 in the build.

    Looks like there's a recipe that can provide this library, located at meta-openembedded/meta-oe/recipes-gnome/gtk+/gtk+_2.24.33.bb.

    You could experiment with adding...

    DEPENDS = "gtk+"

    or

    RDEPENDS:${PN} = "gtk+"

    To your OpenCV recipe.

    Regards, Andreas

  • Getting the below error after adding gtk+2 support in the build

    .

  • The recipe is there but it can't be build during missing distro features, as the error message states. This is caused by this line here:

    oe-core/meta/conf/distro/include/default-distrovars.inc:GTK2DISTROFEATURES = "directfb x11"

    I'm not sure which package you are adding that requires `libgtk2.0` in the first place? You need to experiment with your setup and unroll and understand if you really need gtk for the package you are trying to use and if there's a way to remove/simplify dependencies. Also, note that do we do not support `x11` with our offering.

    Regards, Andreas