On glibc, include sysmacros.h directly
On glibc, major, minor, and makedev are all defined in sys/sysmacros.h with types.h only including this for historical reasons. A future release of glibc will remove this behaviour, meaning that major, minor, and makedev will no longer be defined for us without including sysmacros.h.
This commit is contained in:
parent
48d04ae446
commit
99c7876310
3
ls.c
3
ls.c
@ -1,6 +1,9 @@
|
|||||||
/* See LICENSE file for copyright and license details. */
|
/* See LICENSE file for copyright and license details. */
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
#ifdef __GLIBC__
|
||||||
|
#include <sys/sysmacros.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <dirent.h>
|
#include <dirent.h>
|
||||||
#include <grp.h>
|
#include <grp.h>
|
||||||
|
4
tar.c
4
tar.c
@ -1,6 +1,10 @@
|
|||||||
/* See LICENSE file for copyright and license details. */
|
/* See LICENSE file for copyright and license details. */
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
|
#include <sys/types.h>
|
||||||
|
#ifdef __GLIBC__
|
||||||
|
#include <sys/sysmacros.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
|
Loading…
Reference in New Issue
Block a user