mirror of
https://gitlab.freedesktop.org/mesa/drm.git
synced 2025-12-20 15:10:10 +01:00
Fix headers inclusion in xf86drmMode.c
Add sys/sysctl.h to get sysctlbyname declaration on kFreeBSD Updated by Thorsten “mirabilos” Glaser <t.glaser@tarent.de> to add autoconf check and only include <sys/sysctl.h> if it is detected by configure as it’s unusable on Linux/x32 (and others, e.g. other new architectures). Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
This commit is contained in:
parent
5ba34e1aee
commit
fc8c3e23fb
2 changed files with 4 additions and 1 deletions
|
|
@ -53,7 +53,7 @@ AC_USE_SYSTEM_EXTENSIONS
|
||||||
AC_SYS_LARGEFILE
|
AC_SYS_LARGEFILE
|
||||||
AC_FUNC_ALLOCA
|
AC_FUNC_ALLOCA
|
||||||
|
|
||||||
AC_CHECK_HEADERS([sys/mkdev.h])
|
AC_CHECK_HEADERS([sys/mkdev.h sys/sysctl.h])
|
||||||
|
|
||||||
# Initialize libtool
|
# Initialize libtool
|
||||||
LT_PREREQ([2.2])
|
LT_PREREQ([2.2])
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,9 @@
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
|
#ifdef HAVE_SYS_SYSCTL_H
|
||||||
|
#include <sys/sysctl.h>
|
||||||
|
#endif
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue