blob: 4ae1a18c9e78454dbd393b18d371091b478d572f [file] [log] [blame]
Patrick Williams8dd68482022-10-04 07:57:18 -05001SUMMARY = "v4l2 and IR applications"
2LICENSE = "GPL-2.0-only & LGPL-2.1-only"
3LIC_FILES_CHKSUM = "file://COPYING;md5=48da9957849056017dc568bbc43d8975 \
4 file://COPYING.libv4l;md5=d749e86a105281d7a44c2328acebc4b0"
5PROVIDES = "libv4l media-ctl"
6
7DEPENDS = "jpeg \
8 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/libx11', '', d)} \
9 ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)} \
10 ${@bb.utils.contains('DISTRO_FEATURES', 'alsa', 'alsa-lib', '', d)} \
11 ${@bb.utils.contains_any('PACKAGECONFIG', 'qv4l2 qvidcap', 'qtbase qtbase-native', '', d)}"
12
13DEPENDS:append:libc-musl = " argp-standalone"
14DEPENDS:append:class-target = " udev"
15LDFLAGS:append = " -pthread"
Andrew Geissler517393d2023-01-13 08:55:19 -060016# v4l2 explicitly sets _FILE_OFFSET_BITS=32 to get access to
17# both 32 and 64 bit file APIs. But it does not handle the time side?
18# Needs further investigation
19GLIBC_64BIT_TIME_FLAGS = ""
Patrick Williams8dd68482022-10-04 07:57:18 -050020
Patrick Williams56b44a92024-01-19 08:49:29 -060021inherit meson gettext pkgconfig
Patrick Williams8dd68482022-10-04 07:57:18 -050022
Patrick Williams56b44a92024-01-19 08:49:29 -060023PACKAGECONFIG ??= ""
24PACKAGECONFIG[qv4l2] = ",-Dqv4l2=disabled"
25PACKAGECONFIG[qvidcap] = ",-Dqvidcap=disabled"
26PACKAGECONFIG[v4l2-tracer] = ",-Dv4l2-tracer=disabled,json-c"
Patrick Williams8dd68482022-10-04 07:57:18 -050027
28SRC_URI = "\
Patrick Williams56b44a92024-01-19 08:49:29 -060029 git://git.linuxtv.org/v4l-utils.git;protocol=https;branch=stable-1.26 \
30 file://0001-keytable-meson-Restrict-the-installation-of-50-rc_ke.patch \
Patrick Williams8dd68482022-10-04 07:57:18 -050031 file://0004-Do-not-use-getsubopt.patch \
Patrick Williams8dd68482022-10-04 07:57:18 -050032"
33
Patrick Williams56b44a92024-01-19 08:49:29 -060034SRCREV = "4aee01a027923cab1e40969f56f8ba58d3e6c0d1"
Andrew Geissler6aa7eec2023-03-03 12:41:14 -060035
36PV .= "+git${SRCPV}"
Patrick Williams8dd68482022-10-04 07:57:18 -050037
38S = "${WORKDIR}/git"
Patrick Williams8dd68482022-10-04 07:57:18 -050039
Patrick Williams56b44a92024-01-19 08:49:29 -060040EXTRA_OEMESON = "-Dudevdir=${base_libdir}/udev -Dv4l2-compliance-32=false -Dv4l2-ctl-32=false"
Patrick Williams8dd68482022-10-04 07:57:18 -050041
Patrick Williams56b44a92024-01-19 08:49:29 -060042# Disable the erroneous installation of gconv-modules that would break glib
43# like it is done in Debian and ArchLinux.
44EXTRA_OEMESON += "-Dgconv=disabled"
Patrick Williams8dd68482022-10-04 07:57:18 -050045
46VIRTUAL-RUNTIME_ir-keytable-keymaps ?= "rc-keymaps"
47
48PACKAGES =+ "media-ctl ir-keytable rc-keymaps libv4l libv4l-dev qv4l2 qvidcap"
49
50RPROVIDES:${PN}-dbg += "libv4l-dbg"
51
52FILES:media-ctl = "${bindir}/media-ctl ${libdir}/libmediactl.so.*"
53FILES:qv4l2 = "\
54 ${bindir}/qv4l2 \
55 ${datadir}/applications/qv4l2.desktop \
56 ${datadir}/icons/hicolor/*/apps/qv4l2.* \
57"
58FILES:qvidcap = "\
59 ${bindir}/qvidcap \
60 ${datadir}/applications/qvidcap.desktop \
61 ${datadir}/icons/hicolor/*/apps/qvidcap.* \
62"
63
64FILES:ir-keytable = "${bindir}/ir-keytable ${base_libdir}/udev/rules.d/*-infrared.rules"
65RDEPENDS:ir-keytable += "${VIRTUAL-RUNTIME_ir-keytable-keymaps}"
66RDEPENDS:qv4l2 += "\
67 ${@bb.utils.contains('PACKAGECONFIG', 'qv4l2', 'qtbase', '', d)}"
68RDEPENDS:qvidcap += "\
69 ${@bb.utils.contains('PACKAGECONFIG', 'qvidcap', 'qtbase', '', d)}"
70
71FILES:rc-keymaps = "${sysconfdir}/rc* ${base_libdir}/udev/rc*"
72
73FILES:${PN} = "${bindir} ${sbindir}"
74
75FILES:libv4l += "${libdir}/libv4l*${SOLIBS} ${libdir}/libv4l/*.so ${libdir}/libv4l/plugins/*.so \
76 ${libdir}/libdvbv5*${SOLIBS} \
Patrick Williams705982a2024-01-12 09:51:57 -060077 ${libdir}/libv4l/*-decomp \
78 ${libdir}/libv4l2tracer.so \
79"
Patrick Williams8dd68482022-10-04 07:57:18 -050080
81FILES:libv4l-dev += "${includedir} ${libdir}/pkgconfig \
82 ${libdir}/libv4l*${SOLIBSDEV} ${libdir}/*.la \
83 ${libdir}/v4l*${SOLIBSDEV} ${libdir}/libv4l/*.la ${libdir}/libv4l/plugins/*.la"
84
85PARALLEL_MAKE:class-native = ""
86BBCLASSEXTEND = "native"