Skip to content

Commit

Permalink
media-tv/v4l-utils: fix build w/newer glibc #580910
Browse files Browse the repository at this point in the history
  • Loading branch information
vapier committed Apr 23, 2016
1 parent 792a619 commit cc2e3e5
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 0 deletions.
59 changes: 59 additions & 0 deletions media-tv/v4l-utils/files/v4l-utils-1.6.2-sysmacros.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
https://bugs.gentoo.org/580910

From 8edd80d3654843d9441fb5e43dfbf2b3e81f84b5 Mon Sep 17 00:00:00 2001
From: Mike Frysinger <[email protected]>
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 <[email protected]>
---
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

4 changes: 4 additions & 0 deletions media-tv/v4l-utils/v4l-utils-1.6.2.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ DEPEND="${RDEPEND}
sys-devel/gettext
virtual/pkgconfig"

src_prepare() {
epatch "${FILESDIR}"/${PN}-1.6.2-sysmacros.patch #580910
}

src_configure() {
# Hard disable the flags that apply only to the libs.
econf \
Expand Down

0 comments on commit cc2e3e5

Please sign in to comment.