diff options
author | Ting-Wei Lan <lantw@src.gnome.org> | 2018-06-03 02:17:51 +0800 |
---|---|---|
committer | Ting-Wei Lan <lantw@src.gnome.org> | 2018-06-07 23:05:50 +0800 |
commit | c61f01f0ff9889c393304e8ffa7ee099ba5ed8f6 (patch) | |
tree | db2ee396395b06f9f55246200f398a8a698367e0 /gio | |
parent | f752515925f532916c392ca4043805dab06006c7 (diff) | |
download | glib-c61f01f0ff9889c393304e8ffa7ee099ba5ed8f6.tar.gz |
build: Define MAJOR_IN_TYPES when major is defined in sys/types.h
Autoconf macro AC_HEADER_MAJOR doesn't define a macro in config.h when
major is defined in sys/types.h. This was not a problem because major
is assumed to be always available. However, commit aefffa3fbc3901
changes this assumption in order to fix build on systems without major,
which causes code using major to be disabled on systems putting major
in sys/types.h.
This commit defines a new macro MAJOR_IN_TYPES for both autotools and
meson builds to make major useful on these systems again.
Diffstat (limited to 'gio')
-rw-r--r-- | gio/gdbusmessage.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c index be001ae55..68122387b 100644 --- a/gio/gdbusmessage.c +++ b/gio/gdbusmessage.c @@ -32,6 +32,8 @@ #include <sys/mkdev.h> #elif MAJOR_IN_SYSMACROS #include <sys/sysmacros.h> +#elif MAJOR_IN_TYPES +#include <sys/types.h> #else #define MAJOR_MINOR_NOT_FOUND 1 #endif |