Skip to contentSkip to conversation

opencv: Only rename ${bindir}/shape if it exists

PATCH New Zoltán Böszörményi 1 participant 1 message Sep 9, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 opencv: Only rename ${bindir}/shape if it exists

Its creation depends on PACKAGECONFIG = "samples", which may be removed in a bbappend.

---
 meta-oe/recipes-support/opencv/opencv_4.12.0.bb | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
meta-oe/recipes-support/opencv/opencv_4.12.0.bb +5 -3
index 539190553d..86af1ebc43 100644
@@ -214,7 +214,9 @@ do_install:append() {
         fi
     done
 
-    # rename shape dir to avoid rootfs conflict with
-    # mesa-demos /usr/bin/shape file.
-    mv ${D}/${bindir}/shape ${D}/${bindir}/opencv_shape
+    if [ -d ${D}/${bindir}/shape ]; then
+        # rename shape dir to avoid rootfs conflict with
+        # mesa-demos /usr/bin/shape file.
+        mv ${D}/${bindir}/shape ${D}/${bindir}/opencv_shape
+    fi
 }
Signature · 1 line
2.51.0