Blame SOURCES/0001-major-and-minor-functions-moved-to-sysmacros.h.patch

290f8b
From fb98a845d155fdfbd45c22a6b062c3cfbe692a0a Mon Sep 17 00:00:00 2001
290f8b
From: Sebastian Kisela <skisela@redhat.com>
290f8b
Date: Wed, 25 Jul 2018 09:18:33 +0200
290f8b
Subject: [PATCH] major and minor functions moved to sysmacros.h
290f8b
290f8b
According to https://sourceware.org/git/?p=glibc.git;a=blob_plain;f=NEWS;hb=HEAD
290f8b
(glibc changelog) the below happened, therefore explicitly include
290f8b
<sys/sysmacros.h>
290f8b
290f8b
"
290f8b
...
290f8b
The macros 'major', 'minor', and 'makedev' are now only available from
290f8b
the header <sys/sysmacros.h>; not from <sys/types.h> or various other
290f8b
headers that happen to include <sys/types.h>.  These macros are rarely
290f8b
used, not part of POSIX nor XSI, and their names frequently collide with
290f8b
user code; see https://sourceware.org/bugzilla/show_bug.cgi?id=19239 for
290f8b
further explanation.
290f8b
290f8b
<sys/sysmacros.h> is a GNU extension.  Portable programs that require
290f8b
these macros should first include <sys/types.h>, and then include
290f8b
<sys/sysmacros.h> if __GNU_LIBRARY__ is defined.
290f8b
...
290f8b
"
290f8b
290f8b
Signed-off-by: Sebastian Kisela <skisela@redhat.com>
290f8b
---
290f8b
 src/lockdev.c        | 1 +
290f8b
 src/lockdev.c.access | 1 +
290f8b
 2 files changed, 2 insertions(+)
290f8b
290f8b
diff --git a/src/lockdev.c b/src/lockdev.c
290f8b
index 6e69894..ec86f65 100644
290f8b
--- a/src/lockdev.c
290f8b
+++ b/src/lockdev.c
290f8b
@@ -121,6 +121,7 @@
290f8b
 #include <sys/stat.h>
290f8b
 #include <sys/file.h>
290f8b
 #include <sys/types.h>
290f8b
+#include <sys/sysmacros.h>
290f8b
 #include <sys/wait.h>
290f8b
 #include "lockdev.h"
290f8b
 #include "ttylock.h"
290f8b
diff --git a/src/lockdev.c.access b/src/lockdev.c.access
290f8b
index 9a0fca5..3581938 100644
290f8b
--- a/src/lockdev.c.access
290f8b
+++ b/src/lockdev.c.access
290f8b
@@ -117,6 +117,7 @@
290f8b
 #include <sys/stat.h>
290f8b
 #include <sys/file.h>
290f8b
 #include <sys/types.h>
290f8b
+#include <sys/sysmacros.h>
290f8b
 #include <sys/wait.h>
290f8b
 #include "lockdev.h"
290f8b
 #include "ttylock.h"
290f8b
-- 
290f8b
2.14.4
290f8b