summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/recipes-devtools/autoconf/autoconf/AC_HEADER_MAJOR-port-to-glibc-2.25.patch89
1 files changed, 14 insertions, 75 deletions
diff --git a/meta/recipes-devtools/autoconf/autoconf/AC_HEADER_MAJOR-port-to-glibc-2.25.patch b/meta/recipes-devtools/autoconf/autoconf/AC_HEADER_MAJOR-port-to-glibc-2.25.patch
index fc37236bf8..b2d7dc0e24 100644
--- a/meta/recipes-devtools/autoconf/autoconf/AC_HEADER_MAJOR-port-to-glibc-2.25.patch
+++ b/meta/recipes-devtools/autoconf/autoconf/AC_HEADER_MAJOR-port-to-glibc-2.25.patch
@@ -1,4 +1,4 @@
1From e17a30e987d7ee695fb4294a82d987ec3dc9b974 Mon Sep 17 00:00:00 2001 1From b859ab1b211d348b46eca9158b7742f050c8115e Mon Sep 17 00:00:00 2001
2From: Eric Blake <eblake@redhat.com> 2From: Eric Blake <eblake@redhat.com>
3Date: Wed, 14 Sep 2016 08:17:06 -0500 3Date: Wed, 14 Sep 2016 08:17:06 -0500
4Subject: [PATCH] AC_HEADER_MAJOR: port to glibc 2.25 4Subject: [PATCH] AC_HEADER_MAJOR: port to glibc 2.25
@@ -35,85 +35,21 @@ this patch.
35* lib/autoconf/headers.m4 (AC_HEADER_MAJOR): Drop check for 35* lib/autoconf/headers.m4 (AC_HEADER_MAJOR): Drop check for
36major within sys/types.h; it interferes with the need to check 36major within sys/types.h; it interferes with the need to check
37sysmacros.h first. 37sysmacros.h first.
38* doc/autoconf.texi (Particular Headers) <AC_HEADER_MAJOR>: Expand
39details on usage, and on workarounds for non-updated projects.
40 38
41Signed-off-by: Eric Blake <eblake@redhat.com> 39Signed-off-by: Eric Blake <eblake@redhat.com>
42--- 40
41Remove the documentation change from the patch
43Upstream-Status: Backport 42Upstream-Status: Backport
44 43
45 doc/autoconf.texi | 35 +++++++++++++++++++++++++++++++---- 44Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
46 lib/autoconf/headers.m4 | 30 ++++++++++++++---------------- 45---
47 2 files changed, 45 insertions(+), 20 deletions(-) 46 lib/autoconf/headers.m4 | 30 ++++++++++++++----------------
47 1 file changed, 14 insertions(+), 16 deletions(-)
48 48
49Index: autoconf-2.69/doc/autoconf.texi 49diff --git a/lib/autoconf/headers.m4 b/lib/autoconf/headers.m4
50=================================================================== 50index 81a7fa2..a57d0d3 100644
51--- autoconf-2.69.orig/doc/autoconf.texi 51--- a/lib/autoconf/headers.m4
52+++ autoconf-2.69/doc/autoconf.texi 52+++ b/lib/autoconf/headers.m4
53@@ -15,7 +15,7 @@
54 @c The ARG is an optional argument. To be used for macro arguments in
55 @c their documentation (@defmac).
56 @macro ovar{varname}
57-@r{[}@var{\varname\}@r{]}@c
58+@r{[}@var{\varname\}@r{]}
59 @end macro
60
61 @c @dvar(ARG, DEFAULT)
62@@ -23,7 +23,7 @@
63 @c The ARG is an optional argument, defaulting to DEFAULT. To be used
64 @c for macro arguments in their documentation (@defmac).
65 @macro dvar{varname, default}
66-@r{[}@var{\varname\} = @samp{\default\}@r{]}@c
67+@r{[}@var{\varname\} = @samp{\default\}@r{]}
68 @end macro
69
70 @c Handling the indexes with Texinfo yields several different problems.
71@@ -5926,10 +5926,37 @@ Also see @code{AC_STRUCT_DIRENT_D_INO} a
72 @cvindex MAJOR_IN_SYSMACROS
73 @hdrindex{sys/mkdev.h}
74 @hdrindex{sys/sysmacros.h}
75-If @file{sys/types.h} does not define @code{major}, @code{minor}, and
76-@code{makedev}, but @file{sys/mkdev.h} does, define
77-@code{MAJOR_IN_MKDEV}; otherwise, if @file{sys/sysmacros.h} does, define
78-@code{MAJOR_IN_SYSMACROS}.
79+Detect the headers required to use @code{makedev}, @code{major}, and
80+@code{minor}. These functions may be defined by @file{sys/mkdev.h},
81+@code{sys/sysmacros.h}, or @file{sys/types.h}.
82+
83+@code{AC_HEADER_MAJOR} defines @code{MAJOR_IN_MKDEV} if they are in
84+@file{sys/mkdev.h}, or @code{MAJOR_IN_SYSMACROS} if they are in
85+@file{sys/sysmacros.h}. If neither macro is defined, they are either in
86+@file{sys/types.h} or unavailable.
87+
88+To properly use these functions, your code should contain something
89+like:
90+
91+@verbatim
92+#include <sys/types.h>
93+#ifdef MAJOR_IN_MKDEV
94+# include <sys/mkdev.h>
95+#elif defined MAJOR_IN_SYSMACROS
96+# include <sys/sysmacros.h>
97+#endif
98+@end verbatim
99+
100+Note: Configure scripts built with Autoconf 2.69 or earlier will not
101+detect a problem if @file{sys/types.h} contains definitions of
102+@code{major}, @code{minor}, and/or @code{makedev} that trigger compiler
103+warnings upon use. This is known to occur with GNU libc 2.25, where
104+those definitions are being deprecated to reduce namespace pollution.
105+If it is not practical to use Autoconf 2.70 to regenerate the configure
106+script of affected software, you can work around the problem by setting
107+@samp{ac_cv_header_sys_types_h_makedev=no}, as an argument to
108+@command{configure} or as part of a @file{config.site} site default file
109+(@pxref{Site Defaults}).
110 @end defmac
111
112 @defmac AC_HEADER_RESOLV
113Index: autoconf-2.69/lib/autoconf/headers.m4
114===================================================================
115--- autoconf-2.69.orig/lib/autoconf/headers.m4
116+++ autoconf-2.69/lib/autoconf/headers.m4
117@@ -502,31 +502,29 @@ fi 53@@ -502,31 +502,29 @@ fi
118 54
119 # AC_HEADER_MAJOR 55 # AC_HEADER_MAJOR
@@ -160,3 +96,6 @@ Index: autoconf-2.69/lib/autoconf/headers.m4
160 fi 96 fi
161 ])# AC_HEADER_MAJOR 97 ])# AC_HEADER_MAJOR
162 98
99--
1002.7.4
101