v4l-utils: fix build with glibc >= 2.27
This commit is contained in:
parent
79dde8f6a8
commit
cf7057079e
76
srcpkgs/v4l-utils/patches/fix-glibc-2.27.patch
Normal file
76
srcpkgs/v4l-utils/patches/fix-glibc-2.27.patch
Normal file
|
@ -0,0 +1,76 @@
|
|||
From 12e262176478f832856bc7d3ebe6637152c6982a Mon Sep 17 00:00:00 2001
|
||||
From: maxice8 <thinkabit.ukim@gmail.com>
|
||||
Date: Sat, 22 Sep 2018 23:51:34 -0300
|
||||
Subject: [PATCH] libv4lcontrol.c: unconditionally include sys/sysmacros.h
|
||||
|
||||
Fixes build with glibc >= 2.27
|
||||
|
||||
CC processing/libv4lconvert_la-libv4lprocessing.lo
|
||||
control/libv4lcontrol.c: In function 'v4lcontrol_get_usb_info':
|
||||
control/libv4lcontrol.c:391:33: warning: implicit declaration of function 'minor'; did you mean 'mknod'? [-Wimplicit-function-declaration]
|
||||
c == '\n' && minor_dev == minor(st.st_rdev))
|
||||
^~~~~
|
||||
mknod
|
||||
|
||||
/builddir/v4l-utils-1.14.2/lib/libv4lconvert/.libs/libv4lconvert.so: undefined reference to `minor'
|
||||
---
|
||||
lib/libv4lconvert/control/libv4lcontrol.c | 2 --
|
||||
1 file changed, 2 deletions(-)
|
||||
|
||||
diff --git a/lib/libv4lconvert/control/libv4lcontrol.c b/lib/libv4lconvert/control/libv4lcontrol.c
|
||||
index 1e784ed..59f28b1 100644
|
||||
--- lib/libv4lconvert/control/libv4lcontrol.c
|
||||
+++ lib/libv4lconvert/control/libv4lcontrol.c
|
||||
@@ -20,9 +20,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
-#if defined(MAJOR_IN_SYSMACROS)
|
||||
#include <sys/sysmacros.h>
|
||||
-#endif
|
||||
#include <sys/mman.h>
|
||||
#include <fcntl.h>
|
||||
#include <sys/stat.h>
|
||||
--
|
||||
2.19.0
|
||||
|
||||
From c402d46b1a34ee1703a22622b6fc056b8971fbcc Mon Sep 17 00:00:00 2001
|
||||
From: maxice8 <thinkabit.ukim@gmail.com>
|
||||
Date: Sat, 22 Sep 2018 23:54:56 -0300
|
||||
Subject: [PATCH] v4l2-ctl.cpp: add sys/sysmacros.h include
|
||||
|
||||
Fixes build with glibc >= 2.27
|
||||
|
||||
v4l2-ctl.cpp: In function 'bool is_subdevice(int)':
|
||||
v4l2-ctl.cpp:1156:8: error: 'major' was not declared in this scope
|
||||
major(sb.st_rdev), minor(sb.st_rdev)) == -1) {
|
||||
^~~~~
|
||||
v4l2-ctl.cpp:1156:27: error: 'minor' was not declared in this scope
|
||||
major(sb.st_rdev), minor(sb.st_rdev)) == -1) {
|
||||
^~~~~
|
||||
v4l2-ctl.cpp:1156:27: note: suggested alternative: 'mknod'
|
||||
major(sb.st_rdev), minor(sb.st_rdev)) == -1) {
|
||||
^~~~~
|
||||
mknod
|
||||
make[3]: *** [Makefile:712: v4l2_ctl-v4l2-ctl.o] Error 1
|
||||
make[3]: *** Waiting for unfinished jobs....
|
||||
---
|
||||
utils/v4l2-ctl/v4l2-ctl.cpp | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/utils/v4l2-ctl/v4l2-ctl.cpp b/utils/v4l2-ctl/v4l2-ctl.cpp
|
||||
index e02dc75..83512d9 100644
|
||||
--- utils/v4l2-ctl/v4l2-ctl.cpp
|
||||
+++ utils/v4l2-ctl/v4l2-ctl.cpp
|
||||
@@ -35,6 +35,7 @@
|
||||
#include <sys/time.h>
|
||||
#include <dirent.h>
|
||||
#include <math.h>
|
||||
+#include <sys/sysmacros.h>
|
||||
|
||||
#include "v4l2-ctl.h"
|
||||
|
||||
--
|
||||
2.19.0
|
||||
|
||||
|
|
@ -3,7 +3,7 @@ pkgname=v4l-utils
|
|||
version=1.14.2
|
||||
revision=1
|
||||
build_style=gnu-configure
|
||||
configure_args="--sbindir=/usr/bin --disable-qv4l2 --with-udevdir=/usr/lib/udev"
|
||||
configure_args="--disable-qv4l2 --with-udevdir=/usr/lib/udev"
|
||||
hostmakedepends="automake libtool pkg-config gettext-devel"
|
||||
makedepends="libjpeg-turbo-devel libsysfs-devel eudev-libudev-devel alsa-lib-devel"
|
||||
conf_files="/etc/rc_maps.cfg"
|
||||
|
@ -11,7 +11,7 @@ short_desc="Userspace tools and libraries for Video 4 Linux"
|
|||
maintainer="Juan RP <xtraeme@voidlinux.eu>"
|
||||
homepage="http://freshmeat.net/projects/libv4l"
|
||||
license="GPL-2.0-or-later, LGPL-2.1-or-later"
|
||||
distfiles="http://linuxtv.org/downloads/$pkgname/$pkgname-$version.tar.bz2"
|
||||
distfiles="http://linuxtv.org/downloads/${pkgname}/${pkgname}-${version}.tar.bz2"
|
||||
checksum=e6b962c4b1253cf852c31da13fd6b5bb7cbe5aa9e182881aec55123bae680692
|
||||
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
|
|
Loading…
Reference in New Issue
Block a user