提交 aca4d72b 编写于 作者: M Martin Kletzander

Include sysmacros.h where needed

So in glibc-2.23 sys/sysmacros.h is no longer included from sys/types.h
and we don't build because of the usage of major/minor/makedev macros.
Autoconf already has AC_HEADER_MAJOR macro that check where exactly
these functions/macros are defined, so let's use that.
Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
上级 32f3f083
......@@ -144,6 +144,8 @@ AC_TYPE_UID_T
dnl Support building Win32 DLLs (must appear *before* AM_PROG_LIBTOOL)
AC_LIBTOOL_WIN32_DLL
AC_HEADER_MAJOR
m4_ifndef([LT_INIT], [
AM_PROG_LIBTOOL
], [
......
......@@ -26,6 +26,12 @@
#include <sys/stat.h>
#include <sys/types.h>
#ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
#elif MAJOR_IN_SYSMACROS
# include <sys/sysmacros.h>
#endif
#include "domain_audit.h"
#include "viraudit.h"
#include "viruuid.h"
......
......@@ -28,6 +28,13 @@
#include <sys/wait.h>
#include <sys/socket.h>
#include <sys/types.h>
#ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
#elif MAJOR_IN_SYSMACROS
# include <sys/sysmacros.h>
#endif
#include <sys/un.h>
#include <sys/personality.h>
#include <unistd.h>
......
......@@ -29,6 +29,13 @@
#include <sys/utsname.h>
#include <string.h>
#include <sys/types.h>
#ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
#elif MAJOR_IN_SYSMACROS
# include <sys/sysmacros.h>
#endif
#include <sys/socket.h>
#include <sys/stat.h>
#include <sys/un.h>
......
......@@ -35,6 +35,13 @@
#include <stdlib.h>
#include <sys/stat.h>
#include <sys/types.h>
#ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
#elif MAJOR_IN_SYSMACROS
# include <sys/sysmacros.h>
#endif
#include <signal.h>
#include <dirent.h>
#include <unistd.h>
......
......@@ -36,6 +36,13 @@
#include <poll.h>
#include <sys/stat.h>
#include <sys/types.h>
#ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
#elif MAJOR_IN_SYSMACROS
# include <sys/sysmacros.h>
#endif
#include <sys/ioctl.h>
#include <string.h>
#include <termios.h>
......
......@@ -29,6 +29,13 @@
# include <unistd.h>
# include <fcntl.h>
# include <sys/stat.h>
# ifdef MAJOR_IN_MKDEV
# include <sys/mkdev.h>
# elif MAJOR_IN_SYSMACROS
# include <sys/sysmacros.h>
# endif
# include <stdarg.h>
# include "testutilslxc.h"
# include "virstring.h"
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册