From dd74a7cb87ec63baf45d002eecbe0d46d8b71c71 Mon Sep 17 00:00:00 2001 From: Rosen Penev Date: Wed, 3 Jun 2020 21:31:37 -0700 Subject: [PATCH] libv4l: update to 1.20.0 Removed upstreamed patches. Signed-off-by: Rosen Penev --- libs/libv4l/Makefile | 4 +- .../patches/020-add-missing-includes.patch | 67 +++---------------- libs/libv4l/patches/030-getsubopt.patch | 34 ---------- libs/libv4l/patches/040-musl.patch | 11 --- libs/libv4l/patches/050-4.14.patch | 13 ---- 5 files changed, 10 insertions(+), 119 deletions(-) delete mode 100644 libs/libv4l/patches/030-getsubopt.patch delete mode 100644 libs/libv4l/patches/040-musl.patch delete mode 100644 libs/libv4l/patches/050-4.14.patch diff --git a/libs/libv4l/Makefile b/libs/libv4l/Makefile index ed82da052..54dfb4368 100644 --- a/libs/libv4l/Makefile +++ b/libs/libv4l/Makefile @@ -6,12 +6,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=v4l-utils -PKG_VERSION:=1.16.8 +PKG_VERSION:=1.20.0 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=https://www.linuxtv.org/downloads/v4l-utils -PKG_HASH:=84346bf200bd30efb8a80a65ded1b81d39ae7e0ff2272e98f478b4eee8f40d13 +PKG_HASH:=956118713f7ccb405c55c7088a6a2490c32d54300dd9a30d8d5008c28d3726f7 PKG_MAINTAINER:=Ted Hess diff --git a/libs/libv4l/patches/020-add-missing-includes.patch b/libs/libv4l/patches/020-add-missing-includes.patch index 695f8e3e0..c5a83a97a 100644 --- a/libs/libv4l/patches/020-add-missing-includes.patch +++ b/libs/libv4l/patches/020-add-missing-includes.patch @@ -1,61 +1,10 @@ ---- a/utils/cec-ctl/cec-ctl.cpp -+++ b/utils/cec-ctl/cec-ctl.cpp -@@ -18,6 +18,7 @@ - #include - #include - #include -+#include - #include - #include - #include ---- a/utils/cec-follower/cec-follower.h -+++ b/utils/cec-follower/cec-follower.h -@@ -9,6 +9,7 @@ - #define _CEC_FOLLOWER_H_ - - #include -+#include - #include - #include - #include ---- a/utils/common/media-info.cpp -+++ b/utils/common/media-info.cpp -@@ -21,6 +21,7 @@ - #include - - #include -+#include - #include - - static std::string num2s(unsigned num, bool is_hex = true) ---- a/utils/rds-ctl/rds-ctl.cpp -+++ b/utils/rds-ctl/rds-ctl.cpp -@@ -27,6 +27,8 @@ - #include - #include +--- a/utils/libcecutil/cec-info.cpp ++++ b/utils/libcecutil/cec-info.cpp +@@ -5,6 +5,7 @@ + * Copyright 2017 Cisco Systems, Inc. and/or its affiliates. All rights reserved. + */ +#include -+#include - #include - #include - #include ---- a/utils/v4l2-compliance/media-info.cpp -+++ b/utils/v4l2-compliance/media-info.cpp -@@ -21,6 +21,7 @@ - #include - - #include -+#include - #include - - static std::string num2s(unsigned num, bool is_hex = true) ---- a/utils/v4l2-ctl/media-info.cpp -+++ b/utils/v4l2-ctl/media-info.cpp -@@ -21,6 +21,7 @@ - #include - - #include -+#include - #include - - static std::string num2s(unsigned num, bool is_hex = true) + #include + #include + #include diff --git a/libs/libv4l/patches/030-getsubopt.patch b/libs/libv4l/patches/030-getsubopt.patch deleted file mode 100644 index 5fbb60422..000000000 --- a/libs/libv4l/patches/030-getsubopt.patch +++ /dev/null @@ -1,34 +0,0 @@ -POSIX says that behavior when subopts list is empty is undefined. -musl libs will set value to NULL which leads to crash. - -Simply avoid getsubopt, since we cannot rely on it. - ---- a/utils/v4l2-ctl/v4l2-ctl-common.cpp -+++ b/utils/v4l2-ctl/v4l2-ctl-common.cpp -@@ -679,16 +679,17 @@ static bool parse_subset(char *optarg) - - static bool parse_next_subopt(char **subs, char **value) - { -- static char *const subopts[] = { -- NULL -- }; -- int opt = getsubopt(subs, subopts, value); -+ char *p = *subs; -+ *value = *subs; - -- if (opt < 0 || *value) -- return false; -- fprintf(stderr, "No value given to suboption <%s>\n", -- subopts[opt]); -- return true; -+ while (*p && *p != ',') -+ p++; -+ -+ if (*p) -+ *p++ = '\0'; -+ -+ *subs = p; -+ return false; - } - - void common_cmd(int ch, char *optarg) diff --git a/libs/libv4l/patches/040-musl.patch b/libs/libv4l/patches/040-musl.patch deleted file mode 100644 index 79dc5d212..000000000 --- a/libs/libv4l/patches/040-musl.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/utils/keytable/keytable.c -+++ b/utils/keytable/keytable.c -@@ -1686,7 +1686,7 @@ static void test_event(struct rc_device *rc_dev, int fd) - - for (i = 0; i < rd / sizeof(struct input_event); i++) { - printf(_("%ld.%06ld: event type %s(0x%02x)"), -- ev[i].time.tv_sec, ev[i].time.tv_usec, -+ ev[i].input_event_sec, ev[i].input_event_usec, - get_event_name(events_type, ev[i].type), ev[i].type); - - switch (ev[i].type) { diff --git a/libs/libv4l/patches/050-4.14.patch b/libs/libv4l/patches/050-4.14.patch deleted file mode 100644 index 7cad8ecf5..000000000 --- a/libs/libv4l/patches/050-4.14.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- a/utils/keytable/keytable.c -+++ b/utils/keytable/keytable.c -@@ -61,6 +61,10 @@ struct input_keymap_entry_v2 { - u_int8_t scancode[32]; - }; - -+#ifndef input_event_sec -+#define input_event_sec time.tv_sec -+#define input_event_usec time.tv_usec -+#endif - - #define IR_PROTOCOLS_USER_DIR IR_KEYTABLE_USER_DIR "/protocols" - #define IR_PROTOCOLS_SYSTEM_DIR IR_KEYTABLE_SYSTEM_DIR "/protocols"