diff options
Diffstat (limited to 'meta-multimedia/recipes-multimedia/libcamera/libcamera_0.2.0.bb')
| -rw-r--r-- | meta-multimedia/recipes-multimedia/libcamera/libcamera_0.2.0.bb | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/meta-multimedia/recipes-multimedia/libcamera/libcamera_0.2.0.bb b/meta-multimedia/recipes-multimedia/libcamera/libcamera_0.2.0.bb new file mode 100644 index 0000000000..3fd17f0a85 --- /dev/null +++ b/meta-multimedia/recipes-multimedia/libcamera/libcamera_0.2.0.bb | |||
| @@ -0,0 +1,74 @@ | |||
| 1 | SUMMARY = "Linux libcamera framework" | ||
| 2 | SECTION = "libs" | ||
| 3 | |||
| 4 | LICENSE = "GPL-2.0-or-later & LGPL-2.1-or-later" | ||
| 5 | |||
| 6 | LIC_FILES_CHKSUM = "\ | ||
| 7 | file://LICENSES/GPL-2.0-or-later.txt;md5=fed54355545ffd980b814dab4a3b312c \ | ||
| 8 | file://LICENSES/LGPL-2.1-or-later.txt;md5=2a4f4fd2128ea2f65047ee63fbca9f68 \ | ||
| 9 | " | ||
| 10 | |||
| 11 | SRC_URI = " \ | ||
| 12 | git://git.libcamera.org/libcamera/libcamera.git;protocol=https;branch=master \ | ||
| 13 | " | ||
| 14 | |||
| 15 | SRCREV = "89227a428a82e724548399d35c98ea89566f9045" | ||
| 16 | |||
| 17 | PE = "1" | ||
| 18 | |||
| 19 | S = "${WORKDIR}/git" | ||
| 20 | |||
| 21 | DEPENDS = "python3-pyyaml-native python3-jinja2-native python3-ply-native python3-jinja2-native udev gnutls chrpath-native libevent libyaml" | ||
| 22 | DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'qt', 'qtbase qtbase-native', '', d)}" | ||
| 23 | |||
| 24 | PACKAGES =+ "${PN}-gst" | ||
| 25 | |||
| 26 | PACKAGECONFIG ??= "" | ||
| 27 | PACKAGECONFIG[gst] = "-Dgstreamer=enabled,-Dgstreamer=disabled,gstreamer1.0 gstreamer1.0-plugins-base" | ||
| 28 | |||
| 29 | LIBCAMERA_PIPELINES ??= "auto" | ||
| 30 | |||
| 31 | EXTRA_OEMESON = " \ | ||
| 32 | -Dpipelines=${LIBCAMERA_PIPELINES} \ | ||
| 33 | -Dv4l2=true \ | ||
| 34 | -Dcam=enabled \ | ||
| 35 | -Dlc-compliance=disabled \ | ||
| 36 | -Dtest=false \ | ||
| 37 | -Ddocumentation=disabled \ | ||
| 38 | " | ||
| 39 | |||
| 40 | RDEPENDS:${PN} = "${@bb.utils.contains('DISTRO_FEATURES', 'wayland qt', 'qtwayland', '', d)}" | ||
| 41 | |||
| 42 | inherit meson pkgconfig python3native | ||
| 43 | |||
| 44 | do_configure:prepend() { | ||
| 45 | sed -i -e 's|py_compile=True,||' ${S}/utils/ipc/mojo/public/tools/mojom/mojom/generate/template_expander.py | ||
| 46 | } | ||
| 47 | |||
| 48 | do_install:append() { | ||
| 49 | chrpath -d ${D}${libdir}/libcamera.so | ||
| 50 | chrpath -d ${D}${libexecdir}/libcamera/v4l2-compat.so | ||
| 51 | } | ||
| 52 | |||
| 53 | do_package:append() { | ||
| 54 | bb.build.exec_func("do_package_recalculate_ipa_signatures", d) | ||
| 55 | } | ||
| 56 | |||
| 57 | do_package_recalculate_ipa_signatures() { | ||
| 58 | local modules | ||
| 59 | for module in $(find ${PKGD}/usr/lib/libcamera -name "*.so.sign"); do | ||
| 60 | module="${module%.sign}" | ||
| 61 | if [ -f "${module}" ] ; then | ||
| 62 | modules="${modules} ${module}" | ||
| 63 | fi | ||
| 64 | done | ||
| 65 | |||
| 66 | ${S}/src/ipa/ipa-sign-install.sh ${B}/src/ipa-priv-key.pem "${modules}" | ||
| 67 | } | ||
| 68 | |||
| 69 | FILES:${PN} += " ${libexecdir}/libcamera/v4l2-compat.so" | ||
| 70 | FILES:${PN}-gst = "${libdir}/gstreamer-1.0" | ||
| 71 | |||
| 72 | # libcamera-v4l2 explicitly sets _FILE_OFFSET_BITS=32 to get access to | ||
| 73 | # both 32 and 64 bit file APIs. | ||
| 74 | GLIBC_64BIT_TIME_FLAGS = "" | ||
