Skip to contentSkip to conversation

makedev.3: glibc has deprecated exposing the definitions via <sys/types.h>

PATCH In review Adrian Bunk 2 participants 2 messages Nov 25, 2017 – Nov 26, 2017 1 message not in the archive Man-pages: manual pages for Linux -- Sections 2, 3, 4, 5, and 7

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 makedev.3: glibc has deprecated exposing the definitions via <sys/types.h>

Compile warning with glibc 2.25:

warning: In the GNU C Library, "makedev" is defined
by <sys/sysmacros.h>. For historical compatibility, it is currently defined by <sys/types.h> as well, but we plan to remove this soon. To use "makedev", include <sys/sysmacros.h> directly. If you did not intend to use a system-defined macro "makedev", you should undefine it after including <sys/types.h>.

Background:
https://sourceware.org/git/?p=glibc.git;a=commit;h=dbab6577c6684c62bd2521c1c29dc25c3cac966f

---
 man3/makedev.3 | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
man3/makedev.3 +4 -3
index 3398bbb0b..75c191be7 100644
@@ -94,9 +94,10 @@ and
 The latter names are exported, but the traditional names are more portable.
 .PP
 The BSDs expose the definitions for these macros via
-.IR <sys/types.h> ,
-and glibc also exposes definitions for these macros from that
-header file if suitable feature test macros are defined.
+.IR <sys/types.h> .
+glibc also exposes definitions for these macros from that
+header file if suitable feature test macros are defined,
+but this is deprecated and will be removed in the future.
 .SH SEE ALSO
 .BR mknod (2),
 .BR stat (2)
Signature · 6 lines
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
#2 lore raw
In reply to a message not in the archive
Quoted 8 lines · Adrian Bunk

Compile warning with glibc 2.25:

warning: In the GNU C Library, "makedev" is defined
by <sys/sysmacros.h>. For historical compatibility, it is currently defined by <sys/types.h> as well, but we plan to remove this soon. To use "makedev", include <sys/sysmacros.h> directly. If you did not intend to use a system-defined macro "makedev", you should undefine it after including <sys/types.h>.

Thanks, Adrian. Patch applied.

Cheers,

Michael

Quoted 25 lines

Background:
https://sourceware.org/git/?p=glibc.git;a=commit;h=dbab6577c6684c62bd2521c1c29dc25c3cac966f

---
 man3/makedev.3 | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
man3/makedev.3 +4 -3
index 3398bbb0b..75c191be7 100644
@@ -94,9 +94,10 @@ and
 The latter names are exported, but the traditional names are more portable.
 .PP
 The BSDs expose the definitions for these macros via
-.IR <sys/types.h> ,
-and glibc also exposes definitions for these macros from that
-header file if suitable feature test macros are defined.
+.IR <sys/types.h> .
+glibc also exposes definitions for these macros from that
+header file if suitable feature test macros are defined,
+but this is deprecated and will be removed in the future.
 .SH SEE ALSO
 .BR mknod (2),
 .BR stat (2)
Signature · 7 lines
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html