Prevent the following compile-time error due to a missing system
header file (see --enable-config-udev which defaults to "auto"):

  CCLD     Xorg
/usr/bin/ld: common/.libs/libcommon.a(udev.o): in function `device_added':
udev.c:(.text+0x2bb): undefined reference to `major'
/usr/bin/ld: udev.c:(.text+0x2fe): undefined reference to `minor'
/usr/bin/ld: udev.c:(.text+0x666): undefined reference to `minor'
/usr/bin/ld: udev.c:(.text+0x672): undefined reference to `major'
/usr/bin/ld: udev.c:(.text+0x69e): undefined reference to `minor'
/usr/bin/ld: udev.c:(.text+0x6ab): undefined reference to `major'
/usr/bin/ld: common/.libs/libcommon.a(udev.o): in function `device_removed':
udev.c:(.text+0xb6a): undefined reference to `minor'
/usr/bin/ld: udev.c:(.text+0xb77): undefined reference to `major'
/usr/bin/ld: common/.libs/libcommon.a(udev.o): in function 
`config_udev_odev_probe':
udev.c:(.text+0x10ee): undefined reference to `minor'
/usr/bin/ld: udev.c:(.text+0x10fc): undefined reference to `major'

Fixes: https://gitlab.freedesktop.org/xorg/xserver/issues/879

Signed-off-by: Guido Trentalancia <gu...@trentalancia.com>

--- xorg-server-orig/config/udev.c      2019-08-29 17:07:08.472745416 +0200
+++ xorg-server/config/udev.c   2019-08-29 17:06:06.150742444 +0200
@@ -30,6 +30,7 @@
 #include <libudev.h>
 #include <ctype.h>
 #include <unistd.h>
+#include <sys/sysmacros.h>
 
 #include "input.h"
 #include "inputstr.h"
_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to