mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-20 00:21:35 +00:00
multimedia/libv4l: Update v4l_compat, libv4l and v4l-utils to 1.23.0
NOTE: This version tag currently only exists for FreeBSD and has not yet been made upstream and is based on the latest available v4l-utils. Approved by: pi (implicit)
This commit is contained in:
parent
495e663374
commit
ca63a16f5c
@ -2,8 +2,7 @@
|
||||
# Check v4l_compat and v4l-utils slave ports
|
||||
|
||||
PORTNAME?= libv4l
|
||||
PORTVERSION= 1.20.0
|
||||
PORTREVISION= 2
|
||||
PORTVERSION= 1.23.0
|
||||
DISTVERSIONPREFIX= v4l-utils-
|
||||
CATEGORIES= multimedia
|
||||
|
||||
@ -19,10 +18,10 @@ USE_GITHUB= yes
|
||||
GH_ACCOUNT= hselasky
|
||||
GH_PROJECT= v4l-utils
|
||||
|
||||
GH_TUPLE= hselasky:webcamd:v5.13.2.2:webcamd \
|
||||
torvalds:linux:v5.13-rc2:linux
|
||||
GH_TUPLE= hselasky:webcamd:v5.17.1.0:webcamd \
|
||||
torvalds:linux:v5.17-rc1:linux
|
||||
|
||||
WEBCAMDDIR= ${WRKDIR}/webcamd-5.13.2.2
|
||||
WEBCAMDDIR= ${WRKDIR}/webcamd-5.17.1.0
|
||||
LINUXDIR= ${WRKDIR}/linux-*
|
||||
|
||||
.if ${PORTNAME} == v4l-utils || ${PORTNAME} == libv4l
|
||||
@ -70,6 +69,15 @@ CONFIGURE_ARGS+= \
|
||||
.endif
|
||||
|
||||
post-patch:
|
||||
.if ${PORTNAME} == v4l-utils || ${PORTNAME} == libv4l
|
||||
# Create some files and folders needed by autoreconf
|
||||
@${MKDIR} ${WRKSRC}/build-aux
|
||||
@${TOUCH} ${WRKSRC}/build-aux/config.rpath \
|
||||
${WRKSRC}/v4l-utils-po/Makefile.in.in \
|
||||
${WRKSRC}/libdvbv5-po/Makefile.in.in
|
||||
# Don't build translation files for now
|
||||
@${REINPLACE_CMD} -e 's|v4l-utils-po libdvbv5-po||g' ${WRKSRC}/Makefile.am
|
||||
.endif
|
||||
# Remove old FreeBSD include files (to be removed upstream)
|
||||
@${RM} -r ${WRKSRC}/contrib/freebsd/include/*
|
||||
# Create symbolic link for Linux sources
|
||||
@ -108,6 +116,7 @@ post-patch:
|
||||
-e 's|_IOC_NONE|IOC_VOID|g' \
|
||||
-e 's|<endian.h>|<sys/endian.h>|g' \
|
||||
-e 's|<linux/compiler.h>|<sys/cdefs.h>|g' \
|
||||
-e 's|<v4l-getsubopt.h>|<include/v4l-getsubopt.h>|g' \
|
||||
-e 's|"compiler.h"|<sys/cdefs.h>|g' \
|
||||
-e 's|fallthrough;|;|g' \
|
||||
-e 's|<linux/errno.h>|<errno.h>|g' \
|
||||
|
@ -1,7 +1,7 @@
|
||||
TIMESTAMP = 1621686769
|
||||
SHA256 (hselasky-v4l-utils-v4l-utils-1.20.0_GH0.tar.gz) = 1a2bcc1fa5182f718c982c6ee58d0756dca602639ab6b9a9caff021272b33646
|
||||
SIZE (hselasky-v4l-utils-v4l-utils-1.20.0_GH0.tar.gz) = 1620489
|
||||
SHA256 (hselasky-webcamd-v5.13.2.2_GH0.tar.gz) = a9164a5731be35c5f79aecf8ccbd0e11d3ea7e1a29f81b356def5b08954bacb1
|
||||
SIZE (hselasky-webcamd-v5.13.2.2_GH0.tar.gz) = 272186
|
||||
SHA256 (torvalds-linux-v5.13-rc2_GH0.tar.gz) = 34673cea88f7e5399b704bcacc088b3f14f5800dadf04af6a90b19c35ad3777f
|
||||
SIZE (torvalds-linux-v5.13-rc2_GH0.tar.gz) = 192612873
|
||||
TIMESTAMP = 1643121787
|
||||
SHA256 (hselasky-v4l-utils-v4l-utils-1.23.0_GH0.tar.gz) = 38a56997126e2585913a7b8896b9d9ade078634b62a96ba018c0d4de5f818054
|
||||
SIZE (hselasky-v4l-utils-v4l-utils-1.23.0_GH0.tar.gz) = 1704848
|
||||
SHA256 (hselasky-webcamd-v5.17.1.0_GH0.tar.gz) = 33a34f90f583a1829d1b7b00e03e5ea123e188e2560fcfb01ca1714fb6010565
|
||||
SIZE (hselasky-webcamd-v5.17.1.0_GH0.tar.gz) = 272952
|
||||
SHA256 (torvalds-linux-v5.17-rc1_GH0.tar.gz) = 9269b46a87c16941871f81057c8b82c913869eb86037b92c0bd4d5b9aa69dece
|
||||
SIZE (torvalds-linux-v5.17-rc1_GH0.tar.gz) = 201780465
|
||||
|
@ -1,24 +0,0 @@
|
||||
--- utils/common/fwht-ctrls.h.orig 2021-05-22 12:52:28 UTC
|
||||
+++ utils/common/fwht-ctrls.h
|
||||
@@ -11,21 +11,6 @@
|
||||
#ifndef _FWHT_CTRLS_H_
|
||||
#define _FWHT_CTRLS_H_
|
||||
|
||||
-#define V4L2_CTRL_TYPE_FWHT_PARAMS 0x0105
|
||||
-
|
||||
#define V4L2_CID_MPEG_VIDEO_FWHT_PARAMS (V4L2_CID_MPEG_BASE + 292)
|
||||
-
|
||||
-struct v4l2_ctrl_fwht_params {
|
||||
- __u64 backward_ref_ts;
|
||||
- __u32 version;
|
||||
- __u32 width;
|
||||
- __u32 height;
|
||||
- __u32 flags;
|
||||
- __u32 colorspace;
|
||||
- __u32 xfer_func;
|
||||
- __u32 ycbcr_enc;
|
||||
- __u32 quantization;
|
||||
-};
|
||||
-
|
||||
|
||||
#endif
|
@ -1,46 +0,0 @@
|
||||
--- utils/common/media-info.cpp.orig 2020-05-21 11:22:05 UTC
|
||||
+++ utils/common/media-info.cpp
|
||||
@@ -24,6 +24,10 @@
|
||||
#include <iostream>
|
||||
#include <fstream>
|
||||
#include <media-info.h>
|
||||
+#ifndef __linux__
|
||||
+#include <linux/videodev2.h>
|
||||
+#include <fcntl.h>
|
||||
+#endif
|
||||
|
||||
static std::string num2s(unsigned num, bool is_hex = true)
|
||||
{
|
||||
@@ -61,7 +65,7 @@ media_type mi_media_detect_type(const char *device)
|
||||
|
||||
if (stat(device, &sb) == -1)
|
||||
return MEDIA_TYPE_CANT_STAT;
|
||||
-
|
||||
+#ifdef __linux__
|
||||
std::string uevent_path("/sys/dev/char/");
|
||||
|
||||
uevent_path += num2s(major(sb.st_rdev), false) + ":" +
|
||||
@@ -97,6 +101,23 @@ media_type mi_media_detect_type(const char *device)
|
||||
}
|
||||
|
||||
uevent_file.close();
|
||||
+#else // Not Linux
|
||||
+ int fd = open(device, O_RDONLY);
|
||||
+ if (fd >= 0) {
|
||||
+ struct v4l2_capability caps;
|
||||
+ int error = ioctl(fd, VIDIOC_QUERYCAP, &caps);
|
||||
+ close(fd);
|
||||
+ if (error == 0) {
|
||||
+ if (caps.device_caps & V4L2_CAP_VIDEO_CAPTURE) {
|
||||
+ return MEDIA_TYPE_VIDEO;
|
||||
+ } else if (caps.device_caps & V4L2_CAP_VBI_CAPTURE) {
|
||||
+ return MEDIA_TYPE_VBI;
|
||||
+ } else if (caps.device_caps & V4L2_CAP_RADIO) {
|
||||
+ return MEDIA_TYPE_RADIO;
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
return MEDIA_TYPE_UNKNOWN;
|
||||
}
|
||||
|
@ -1,10 +0,0 @@
|
||||
--- utils/v4l2-compliance/v4l2-test-buffers.cpp.orig 2020-12-02 20:09:09 UTC
|
||||
+++ utils/v4l2-compliance/v4l2-test-buffers.cpp
|
||||
@@ -32,6 +32,7 @@
|
||||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
#include <poll.h>
|
||||
+#include <signal.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <netinet/in.h>
|
||||
#include <map>
|
@ -1,12 +1,13 @@
|
||||
--- utils/v4l2-ctl/v4l2-ctl-overlay.cpp.orig 2020-05-21 11:22:05 UTC
|
||||
diff --git utils/v4l2-ctl/v4l2-ctl-overlay.cpp utils/v4l2-ctl/v4l2-ctl-overlay.cpp
|
||||
index 5493222dd..1f0a6f47f 100644
|
||||
--- utils/v4l2-ctl/v4l2-ctl-overlay.cpp
|
||||
+++ utils/v4l2-ctl/v4l2-ctl-overlay.cpp
|
||||
@@ -14,11 +14,13 @@
|
||||
#include <dirent.h>
|
||||
#include <math.h>
|
||||
|
||||
-#include <linux/fb.h>
|
||||
@@ -1,10 +1,11 @@
|
||||
#include <array>
|
||||
#include <vector>
|
||||
|
||||
-#include <linux/fb.h>
|
||||
-
|
||||
#include "v4l2-ctl.h"
|
||||
|
||||
+#ifndef __FreeBSD__
|
||||
@ -15,7 +16,7 @@
|
||||
static unsigned int set_fbuf;
|
||||
static unsigned int set_overlay_fmt;
|
||||
static struct v4l2_format overlay_fmt; /* set_format/get_format video overlay */
|
||||
@@ -546,3 +548,24 @@ void overlay_list(cv4l_fd &fd)
|
||||
@@ -527,3 +528,24 @@ void overlay_list(cv4l_fd &fd)
|
||||
if (options[OptFindFb])
|
||||
find_fb(fd.g_fd());
|
||||
}
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- utils/v4l2-ctl/v4l2-ctl-streaming.cpp.orig 2022-01-25 16:28:52 UTC
|
||||
+++ utils/v4l2-ctl/v4l2-ctl-streaming.cpp
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
#include <netdb.h>
|
||||
#include <sys/types.h>
|
||||
+#include <sys/socket.h>
|
||||
+#include <netinet/in.h>
|
||||
|
||||
#include <linux/media.h>
|
||||
|
@ -1,10 +0,0 @@
|
||||
--- utils/v4l2-ctl/v4l2-ctl-vidcap.cpp.orig 2020-12-30 21:13:40 UTC
|
||||
+++ utils/v4l2-ctl/v4l2-ctl-vidcap.cpp
|
||||
@@ -14,6 +14,7 @@
|
||||
#include <dirent.h>
|
||||
#include <math.h>
|
||||
#include <cstdlib>
|
||||
+#include <sys/endian.h>
|
||||
|
||||
#include "v4l2-ctl.h"
|
||||
|
@ -17,6 +17,7 @@ include/libdvbv5/desc_language.h
|
||||
include/libdvbv5/desc_logical_channel.h
|
||||
include/libdvbv5/desc_network_name.h
|
||||
include/libdvbv5/desc_partial_reception.h
|
||||
include/libdvbv5/desc_registration_id.h
|
||||
include/libdvbv5/desc_sat.h
|
||||
include/libdvbv5/desc_service.h
|
||||
include/libdvbv5/desc_t2_delivery.h
|
||||
|
@ -12,6 +12,7 @@ PLIST= ${.CURDIR}/pkg-plist
|
||||
BASE_HEADERS= \
|
||||
linux/cec.h \
|
||||
linux/cec-funcs.h \
|
||||
linux/const.h \
|
||||
linux/dvb/audio.h \
|
||||
linux/dvb/ca.h \
|
||||
linux/dvb/dmx.h \
|
||||
|
@ -1,5 +1,6 @@
|
||||
include/linux/cec.h
|
||||
include/linux/cec-funcs.h
|
||||
include/linux/const.h
|
||||
include/linux/dvb/audio.h
|
||||
include/linux/dvb/ca.h
|
||||
include/linux/dvb/dmx.h
|
||||
|
Loading…
Reference in New Issue
Block a user