blob: 04a2ac77708e3b518fa578383a3e5cc8831ee254 [file] [log] [blame]
Brad Bishope42b3e32020-01-15 22:08:42 -05001SUMMARY = "Linux libcamera framework"
2SECTION = "libs"
3
Andrew Geisslerbffdb3e2020-08-21 16:13:29 -05004LICENSE = "GPL-2.0+ & LGPL-2.1+"
Brad Bishope42b3e32020-01-15 22:08:42 -05005
6LIC_FILES_CHKSUM = "\
Andrew Geisslerc87764f2020-06-27 00:16:32 -05007 file://LICENSES/GPL-2.0-or-later.txt;md5=fed54355545ffd980b814dab4a3b312c \
8 file://LICENSES/LGPL-2.1-or-later.txt;md5=2a4f4fd2128ea2f65047ee63fbca9f68 \
Brad Bishope42b3e32020-01-15 22:08:42 -05009"
10
11SRC_URI = " \
12 git://linuxtv.org/libcamera.git;protocol=git \
Brad Bishope42b3e32020-01-15 22:08:42 -050013"
14
William A. Kennington IIIb95905d2021-06-02 12:40:56 -070015SRCREV = "193ca8c353a42334f65ddfc988a105a47bca3547"
Brad Bishope42b3e32020-01-15 22:08:42 -050016
William A. Kennington IIIb95905d2021-06-02 12:40:56 -070017PV = "202105+git${SRCPV}"
Brad Bishope42b3e32020-01-15 22:08:42 -050018
19S = "${WORKDIR}/git"
20
Andrew Geissler97771a32021-03-05 15:23:11 -060021DEPENDS = "python3-pyyaml-native python3-jinja2-native python3-ply-native python3-jinja2-native udev gnutls boost chrpath-native"
Brad Bishope42b3e32020-01-15 22:08:42 -050022DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'qt', 'qtbase qtbase-native', '', d)}"
23
Andrew Geisslerd688a012020-09-18 13:36:00 -050024PACKAGES =+ "${PN}-gst"
25
26PACKAGECONFIG ??= ""
27PACKAGECONFIG[gst] = "-Dgstreamer=enabled,-Dgstreamer=disabled,gstreamer1.0 gstreamer1.0-plugins-base"
28
Patrick Williams213cb262021-08-07 19:21:33 -050029RDEPENDS:${PN} = "${@bb.utils.contains('DISTRO_FEATURES', 'wayland qt', 'qtwayland', '', d)}"
Brad Bishope42b3e32020-01-15 22:08:42 -050030
31inherit meson pkgconfig python3native
32
Patrick Williams213cb262021-08-07 19:21:33 -050033do_configure:prepend() {
William A. Kennington IIIb95905d2021-06-02 12:40:56 -070034 sed -i -e 's|py_compile=True,||' ${S}/utils/ipc/mojo/public/tools/mojom/mojom/generate/template_expander.py
35}
36
Patrick Williams213cb262021-08-07 19:21:33 -050037do_install:append() {
Andrew Geisslerbffdb3e2020-08-21 16:13:29 -050038 chrpath -d ${D}${libdir}/libcamera.so
39}
40
41addtask do_recalculate_ipa_signatures_package after do_package before do_packagedata
42do_recalculate_ipa_signatures_package() {
43 local modules
44 for module in $(find ${PKGD}/usr/lib/libcamera -name "*.so.sign"); do
45 module="${module%.sign}"
46 if [ -f "${module}" ] ; then
47 modules="${modules} ${module}"
48 fi
49 done
50
51 ${S}/src/ipa/ipa-sign-install.sh ${B}/src/ipa-priv-key.pem "${modules}"
52}
53
Patrick Williams213cb262021-08-07 19:21:33 -050054FILES:${PN}-dev = "${includedir} ${libdir}/pkgconfig"
55FILES:${PN} += " ${libdir}/libcamera.so"
56FILES:${PN}-gst = "${libdir}/gstreamer-1.0/libgstlibcamera.so"