commit b5e330f3ce0030982e2b1f2c0bf4634cd3c79a18
Author: Jan Palus <[email protected]>
Date: Fri Feb 24 00:49:56 2023 +0100
up to 1.24.0
v4l-utils-bpf.patch | 118 ----------------------------------------------------
v4l-utils.spec | 17 ++++----
2 files changed, 10 insertions(+), 125 deletions(-)
---
diff --git a/v4l-utils.spec b/v4l-utils.spec
index ceea74c..e4bba79 100644
--- a/v4l-utils.spec
+++ b/v4l-utils.spec
@@ -6,13 +6,12 @@
Summary: Collection of Video4Linux utilities
Summary(pl.UTF-8): Zbiór narzędzi do urządzeń Video4Linux
Name: v4l-utils
-Version: 1.22.1
-Release: 2
+Version: 1.24.0
+Release: 1
License: GPL v2+ (utilities), LGPL v2.1+ (libraries)
Group: Applications/System
Source0:
https://linuxtv.org/downloads/v4l-utils/%{name}-%{version}.tar.bz2
-# Source0-md5: 8aa73287320a49e9170a8255d7b2c7e6
-Patch0: %{name}-bpf.patch
+# Source0-md5: a454d640c9eec26098f246d5f52ef438
URL: https://linuxtv.org/wiki/index.php/V4l-utils
BuildRequires: OpenGL-devel
BuildRequires: OpenGL-GLU-devel
@@ -32,7 +31,8 @@ BuildRequires: automake >= 1:1.9
BuildRequires: clang
BuildRequires: elfutils-devel
BuildRequires: gettext-tools >= 0.19.8
-BuildRequires: libbpf-devel >= 0.6
+BuildRequires: json-c-devel >= 0.15
+BuildRequires: libbpf-devel >= 0.7
BuildRequires: libjpeg-devel
BuildRequires: libstdc++-devel
BuildRequires: libtool
@@ -40,6 +40,7 @@ BuildRequires: pkgconfig
BuildRequires: systemd-devel
%{?with_udev:BuildRequires: udev-devel}
BuildRequires: xorg-lib-libX11-devel
+Requires: json-c >= 0.15
Requires: libv4l = %{version}-%{release}
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -143,7 +144,6 @@ Statyczne biblioteki libv4l.
%prep
%setup -q
-%patch0 -p1
%build
%{__libtoolize}
@@ -198,7 +198,7 @@ done
%files -f v4l-utils.lang
%defattr(644,root,root,755)
-%doc ChangeLog README TODO contrib
+%doc ChangeLog README.md TODO contrib
%attr(755,root,root) %{_bindir}/cec-compliance
%attr(755,root,root) %{_bindir}/cec-ctl
%attr(755,root,root) %{_bindir}/cec-follower
@@ -217,6 +217,7 @@ done
%attr(755,root,root) %{_bindir}/v4l2-compliance
%attr(755,root,root) %{_bindir}/v4l2-ctl
%attr(755,root,root) %{_bindir}/v4l2-sysfs-path
+%attr(755,root,root) %{_bindir}/v4l2-tracer
%attr(755,root,root) %{_bindir}/xc3028-firmware
%attr(755,root,root) %{_sbindir}/v4l2-dbg
%{_mandir}/man1/cec-compliance.1*
@@ -229,6 +230,7 @@ done
%{_mandir}/man1/ir-ctl.1*
%{_mandir}/man1/v4l2-compliance.1*
%{_mandir}/man1/v4l2-ctl.1*
+%{_mandir}/man1/v4l2-tracer.1*
%if %{with qt}
%files qt
@@ -266,6 +268,7 @@ done
%attr(755,root,root) %ghost %{_libdir}/libv4l2rds.so.0
%attr(755,root,root) %{_libdir}/libv4lconvert.so.*.*.*
%attr(755,root,root) %ghost %{_libdir}/libv4lconvert.so.0
+%attr(755,root,root) %{_libdir}/libv4l2tracer.so
%attr(755,root,root) %{_libdir}/v4l1compat.so
%attr(755,root,root) %{_libdir}/v4l2convert.so
%dir %{_libdir}/libv4l
diff --git a/v4l-utils-bpf.patch b/v4l-utils-bpf.patch
deleted file mode 100644
index 60fd42d..0000000
--- a/v4l-utils-bpf.patch
+++ /dev/null
@@ -1,118 +0,0 @@
---- v4l-utils-1.22.1/utils/keytable/bpf_load.c.orig 2022-10-25
21:46:09.072545347 +0200
-+++ v4l-utils-1.22.1/utils/keytable/bpf_load.c 2022-10-25 21:46:15.542510296
+0200
-@@ -63,19 +63,21 @@ struct bpf_file {
-
- static int load_and_attach(int lirc_fd, struct bpf_file *bpf_file, struct
bpf_insn *prog, int size)
- {
-- struct bpf_load_program_attr load_attr;
-+ struct bpf_prog_load_opts load_opts;
- int fd, err;
-
-- memset(&load_attr, 0, sizeof(struct bpf_load_program_attr));
-+ memset(&load_opts, 0, sizeof(struct bpf_prog_load_opts));
-
-- load_attr.prog_type = BPF_PROG_TYPE_LIRC_MODE2;
-- load_attr.expected_attach_type = BPF_LIRC_MODE2;
-- load_attr.name = bpf_file->name;
-- load_attr.insns = prog;
-- load_attr.insns_cnt = size / sizeof(struct bpf_insn);
-- load_attr.license = bpf_file->license;
--
-- fd = bpf_load_program_xattr(&load_attr, bpf_log_buf, LOG_BUF_SIZE);
-+ load_opts.sz = sizeof(struct bpf_prog_load_opts);
-+ load_opts.expected_attach_type = BPF_LIRC_MODE2;
-+ load_opts.log_size = LOG_BUF_SIZE;
-+ load_opts.log_buf = bpf_log_buf;
-+
-+ fd = bpf_prog_load(BPF_PROG_TYPE_LIRC_MODE2,
-+ bpf_file->name,
-+ bpf_file->license,
-+ prog, size / sizeof(struct bpf_insn),
-+ &load_opts);
- if (fd < 0) {
- printf("bpf_load_program() err=%m\n%s", bpf_log_buf);
- return -1;
-@@ -95,6 +97,7 @@ static int build_raw_map(struct bpf_map_
- int no_patterns, value_size, fd, key, i;
- struct raw_entry *e;
- struct raw_pattern *p;
-+ struct bpf_map_create_opts map_opts;
-
- no_patterns = 0;
-
-@@ -110,13 +113,17 @@ static int build_raw_map(struct bpf_map_
-
- value_size = sizeof(struct raw_pattern) + max_length * sizeof(short);
-
-- fd = bpf_create_map_node(map->def.type,
-- map->name,
-- map->def.key_size,
-- value_size,
-- no_patterns,
-- map->def.map_flags,
-- numa_node);
-+ memset(&map_opts, 0, sizeof(struct bpf_map_create_opts));
-+ map_opts.sz = sizeof(struct bpf_map_create_opts);
-+ map_opts.map_flags = map->def.map_flags;
-+ map_opts.numa_node = numa_node;
-+
-+ fd = bpf_map_create(map->def.type,
-+ map->name,
-+ map->def.key_size,
-+ value_size,
-+ no_patterns,
-+ &map_opts);
-
- if (fd < 0) {
- printf(_("failed to create a map: %d %s\n"),
-@@ -167,6 +174,10 @@ static int load_maps(struct bpf_file *bp
- {
- struct bpf_map_data *maps = bpf_file->map_data;
- int i, numa_node;
-+ struct bpf_map_create_opts map_opts;
-+
-+ memset(&map_opts, 0, sizeof(struct bpf_map_create_opts));
-+ map_opts.sz = sizeof(struct bpf_map_create_opts);
-
- for (i = 0; i < bpf_file->nr_maps; i++) {
- numa_node = maps[i].def.map_flags & BPF_F_NUMA_NODE ?
-@@ -174,27 +185,31 @@ static int load_maps(struct bpf_file *bp
-
- if (maps[i].def.type == BPF_MAP_TYPE_ARRAY_OF_MAPS ||
- maps[i].def.type == BPF_MAP_TYPE_HASH_OF_MAPS) {
-- int inner_map_fd =
bpf_file->map_fd[maps[i].def.inner_map_idx];
-+ map_opts.inner_map_fd =
bpf_file->map_fd[maps[i].def.inner_map_idx];
-+ map_opts.map_flags = maps[i].def.map_flags;
-+ map_opts.numa_node = numa_node;
-
-- bpf_file->map_fd[i] = bpf_create_map_in_map_node(
-+ bpf_file->map_fd[i] = bpf_map_create(
- maps[i].def.type,
- maps[i].name,
- maps[i].def.key_size,
-- inner_map_fd,
-+ 0,
- maps[i].def.max_entries,
-- maps[i].def.map_flags,
-- numa_node);
-+ &map_opts);
- } else if (!strcmp(maps[i].name, "raw_map")) {
- bpf_file->map_fd[i] = build_raw_map(&maps[i], raw,
numa_node);
- } else {
-- bpf_file->map_fd[i] = bpf_create_map_node(
-+ map_opts.inner_map_fd = 0;
-+ map_opts.map_flags = maps[i].def.map_flags;
-+ map_opts.numa_node = numa_node;
-+
-+ bpf_file->map_fd[i] = bpf_map_create(
- maps[i].def.type,
- maps[i].name,
- maps[i].def.key_size,
- maps[i].def.value_size,
- maps[i].def.max_entries,
-- maps[i].def.map_flags,
-- numa_node);
-+ &map_opts);
- }
-
- if (bpf_file->map_fd[i] < 0) {
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/v4l-utils.git/commitdiff/b5e330f3ce0030982e2b1f2c0bf4634cd3c79a18
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit