diff --git a/recipes-support/opencv/opencv_4.6.0.imx.bb b/recipes-support/opencv/opencv_4.6.0.imx.bb index 6d13d107..3b455534 100644 --- a/recipes-support/opencv/opencv_4.6.0.imx.bb +++ b/recipes-support/opencv/opencv_4.6.0.imx.bb @@ -302,10 +302,12 @@ EXTRA_OECMAKE:append = " -DBUILD_opencv_cvv=OFF" do_install:append() { ln -sf opencv4/opencv2 ${D}${includedir}/opencv2 - install -d ${D}${datadir}/OpenCV/samples/data - cp -r ${S}/samples/data/* ${D}${datadir}/OpenCV/samples/data - install -d ${D}${datadir}/OpenCV/samples/bin/ - cp -f bin/example_* ${D}${datadir}/OpenCV/samples/bin/ + if ${@bb.utils.contains('PACKAGECONFIG', 'samples', 'true', 'false', d)}; then + install -d ${D}${datadir}/OpenCV/samples/data + cp -r ${S}/samples/data/* ${D}${datadir}/OpenCV/samples/data + install -d ${D}${datadir}/OpenCV/samples/bin/ + cp -f bin/example_* ${D}${datadir}/OpenCV/samples/bin/ + fi if ${@bb.utils.contains('PACKAGECONFIG', 'tests-imx', 'true', 'false', d)}; then cp -r share/opencv4/testdata/cv/face/* ${D}${datadir}/opencv4/testdata/cv/face/ fi