summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2016-03-14 17:10:18 -0400
committerMike Frysinger <vapier@gentoo.org>2016-03-14 22:31:59 -0400
commitfa4684ca43726c66e8107ed45fa62ff070e8abd5 (patch)
tree1e928fad7068faa9f039c4ce3788dd42bd68d285 /media-libs/libv4l
parentsys-libs/gpm: fix build w/newer glibc (diff)
downloadgentoo-fa4684ca43726c66e8107ed45fa62ff070e8abd5.tar.gz
gentoo-fa4684ca43726c66e8107ed45fa62ff070e8abd5.tar.bz2
gentoo-fa4684ca43726c66e8107ed45fa62ff070e8abd5.zip
media-libs/libv4l: fix build w/newer glibc
Diffstat (limited to 'media-libs/libv4l')
-rw-r--r--media-libs/libv4l/files/libv4l-1.6.2-sysmacros.patch57
-rw-r--r--media-libs/libv4l/libv4l-1.6.2.ebuild4
2 files changed, 61 insertions, 0 deletions
diff --git a/media-libs/libv4l/files/libv4l-1.6.2-sysmacros.patch b/media-libs/libv4l/files/libv4l-1.6.2-sysmacros.patch
new file mode 100644
index 000000000000..db497409d417
--- /dev/null
+++ b/media-libs/libv4l/files/libv4l-1.6.2-sysmacros.patch
@@ -0,0 +1,57 @@
+From 8edd80d3654843d9441fb5e43dfbf2b3e81f84b5 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Mon, 14 Mar 2016 16:56:40 -0400
+Subject: [PATCH] include sys/sysmacros.h for major() & minor()
+
+Linux C libraries are looking to disentangle sysmacros.h from the
+sys/types.h header to clean up namespace pollution. Since these
+macros are provided in glibc/etc... today, switch to pulling in
+this header directly.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ contrib/test/mc_nextgen_test.c | 1 +
+ lib/libv4lconvert/control/libv4lcontrol.c | 1 +
+ utils/libmedia_dev/get_media_devices.c | 1 +
+ utils/media-ctl/libmediactl.c | 1 +
+ 4 files changed, 4 insertions(+)
+
+diff --git a/lib/libv4lconvert/control/libv4lcontrol.c b/lib/libv4lconvert/control/libv4lcontrol.c
+index 3c8335c..59f28b1 100644
+--- a/lib/libv4lconvert/control/libv4lcontrol.c
++++ b/lib/libv4lconvert/control/libv4lcontrol.c
+@@ -20,6 +20,7 @@
+ */
+
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/mman.h>
+ #include <fcntl.h>
+ #include <sys/stat.h>
+diff --git a/utils/libmedia_dev/get_media_devices.c b/utils/libmedia_dev/get_media_devices.c
+index e3a2200..edfeb41 100644
+--- a/utils/libmedia_dev/get_media_devices.c
++++ b/utils/libmedia_dev/get_media_devices.c
+@@ -20,6 +20,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/stat.h>
+ #include <string.h>
+ #include <stdlib.h>
+diff --git a/utils/media-ctl/libmediactl.c b/utils/media-ctl/libmediactl.c
+index 4a82d24..16dddbe 100644
+--- a/utils/media-ctl/libmediactl.c
++++ b/utils/media-ctl/libmediactl.c
+@@ -24,6 +24,7 @@
+ #include <sys/ioctl.h>
+ #include <sys/stat.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+
+ #include <ctype.h>
+ #include <errno.h>
+--
+2.6.2
+
diff --git a/media-libs/libv4l/libv4l-1.6.2.ebuild b/media-libs/libv4l/libv4l-1.6.2.ebuild
index fa076f2302c7..5ac86938280a 100644
--- a/media-libs/libv4l/libv4l-1.6.2.ebuild
+++ b/media-libs/libv4l/libv4l-1.6.2.ebuild
@@ -36,6 +36,10 @@ pkg_setup() {
linux-info_pkg_setup
}
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-sysmacros.patch
+}
+
multilib_src_configure() {
# Hard disable the flags that apply only to the utils.
ECONF_SOURCE=${S} \