mirror of
https://github.com/X11Libre/xf86-video-r128.git
synced 2026-03-24 01:24:26 +00:00
configure.ac: formatting cleanup
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
122
configure.ac
122
configure.ac
@@ -58,7 +58,7 @@ AC_ARG_ENABLE(dri, AS_HELP_STRING([--disable-dri],
|
||||
[DRI=auto])
|
||||
|
||||
AC_ARG_ENABLE(exa, AS_HELP_STRING([--disable-exa],
|
||||
[Disable EXA support [[default=enabled]]]),
|
||||
[Disable EXA support [[default=enabled]]]),
|
||||
[EXA="$enableval"],
|
||||
[EXA=yes])
|
||||
|
||||
@@ -78,43 +78,43 @@ sdkdir=`$PKG_CONFIG --variable=sdkdir xorg-server`
|
||||
# Checks for libraries.
|
||||
|
||||
if test "$DRI" != no; then
|
||||
if test -f "${sdkdir}/dri.h"; then
|
||||
have_dri_h="yes"
|
||||
else
|
||||
have_dri_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/sarea.h"; then
|
||||
have_sarea_h="yes"
|
||||
else
|
||||
have_sarea_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/dristruct.h"; then
|
||||
have_dristruct_h="yes"
|
||||
else
|
||||
have_dristruct_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/damage.h"; then
|
||||
have_damage_h="yes"
|
||||
else
|
||||
have_damage_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/dri.h"; then
|
||||
have_dri_h="yes"
|
||||
else
|
||||
have_dri_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/sarea.h"; then
|
||||
have_sarea_h="yes"
|
||||
else
|
||||
have_sarea_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/dristruct.h"; then
|
||||
have_dristruct_h="yes"
|
||||
else
|
||||
have_dristruct_h="no"
|
||||
fi
|
||||
if test -f "${sdkdir}/damage.h"; then
|
||||
have_damage_h="yes"
|
||||
else
|
||||
have_damage_h="no"
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING([whether to include DRI support])
|
||||
if test x$DRI = xauto; then
|
||||
if test "$have_dri_h" = yes -a \
|
||||
if test "$have_dri_h" = yes -a \
|
||||
"$have_sarea_h" = yes -a \
|
||||
"$have_dristruct_h" = yes; then
|
||||
DRI="yes"
|
||||
else
|
||||
DRI="no"
|
||||
fi
|
||||
DRI="yes"
|
||||
else
|
||||
DRI="no"
|
||||
fi
|
||||
fi
|
||||
AC_MSG_RESULT([$DRI])
|
||||
|
||||
AM_CONDITIONAL(DRI, test x$DRI = xyes)
|
||||
if test "$DRI" = yes; then
|
||||
PKG_CHECK_MODULES(DRI, [libdrm >= 2.2 xf86driproto])
|
||||
PKG_CHECK_MODULES(DRI, [libdrm >= 2.2 xf86driproto])
|
||||
AC_DEFINE(R128DRI,1,[Enable DRI driver support])
|
||||
AC_DEFINE(R128DRI_DEVEL,1,[Enable developmental DRI driver support])
|
||||
fi
|
||||
@@ -159,10 +159,10 @@ AC_CHECK_HEADERS([dev/wscons/wsconsio.h])
|
||||
|
||||
# Checks for headers/macros for byte swapping
|
||||
# Known variants:
|
||||
# <byteswap.h> bswap_16, bswap_32, bswap_64 (glibc)
|
||||
# <sys/endian.h> __swap16, __swap32, __swap64 (OpenBSD)
|
||||
# <sys/endian.h> bswap16, bswap32, bswap64 (other BSD's)
|
||||
# and a fallback to local macros if none of the above are found
|
||||
# <byteswap.h> bswap_16, bswap_32, bswap_64 (glibc)
|
||||
# <sys/endian.h> __swap16, __swap32, __swap64 (OpenBSD)
|
||||
# <sys/endian.h> bswap16, bswap32, bswap64 (other BSD's)
|
||||
# and a fallback to local macros if none of the above are found
|
||||
|
||||
# if <byteswap.h> is found, assume it's the correct version
|
||||
AC_CHECK_HEADERS([byteswap.h])
|
||||
@@ -171,8 +171,8 @@ AC_CHECK_HEADERS([byteswap.h])
|
||||
AC_CHECK_HEADER([sys/endian.h], [HAVE_SYS_ENDIAN_H="yes"], [HAVE_SYS_ENDIAN_H="no"])
|
||||
|
||||
if test "x$HAVE_SYS_ENDIAN_H" = "xyes" ; then
|
||||
AC_MSG_CHECKING([for __swap16 variant of <sys/endian.h> byteswapping macros])
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([
|
||||
AC_MSG_CHECKING([for __swap16 variant of <sys/endian.h> byteswapping macros])
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([
|
||||
#include <sys/types.h>
|
||||
#include <sys/endian.h>
|
||||
], [
|
||||
@@ -180,10 +180,10 @@ int a = 1, b;
|
||||
b = __swap16(a);
|
||||
])
|
||||
], [SYS_ENDIAN__SWAP='yes'], [SYS_ENDIAN__SWAP='no'])
|
||||
AC_MSG_RESULT([$SYS_ENDIAN__SWAP])
|
||||
AC_MSG_RESULT([$SYS_ENDIAN__SWAP])
|
||||
|
||||
AC_MSG_CHECKING([for bswap16 variant of <sys/endian.h> byteswapping macros])
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([
|
||||
AC_MSG_CHECKING([for bswap16 variant of <sys/endian.h> byteswapping macros])
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([
|
||||
#include <sys/types.h>
|
||||
#include <sys/endian.h>
|
||||
], [
|
||||
@@ -191,39 +191,33 @@ int a = 1, b;
|
||||
b = bswap16(a);
|
||||
])
|
||||
], [SYS_ENDIAN_BSWAP='yes'], [SYS_ENDIAN_BSWAP='no'])
|
||||
AC_MSG_RESULT([$SYS_ENDIAN_BSWAP])
|
||||
AC_MSG_RESULT([$SYS_ENDIAN_BSWAP])
|
||||
|
||||
if test "$SYS_ENDIAN_BSWAP" = "yes" ; then
|
||||
USE_SYS_ENDIAN_H=yes
|
||||
BSWAP=bswap
|
||||
else
|
||||
if test "$SYS_ENDIAN__SWAP" = "yes" ; then
|
||||
USE_SYS_ENDIAN_H=yes
|
||||
BSWAP=__swap
|
||||
else
|
||||
USE_SYS_ENDIAN_H=no
|
||||
fi
|
||||
fi
|
||||
if test "$SYS_ENDIAN_BSWAP" = "yes" ; then
|
||||
USE_SYS_ENDIAN_H=yes
|
||||
BSWAP=bswap
|
||||
else
|
||||
if test "$SYS_ENDIAN__SWAP" = "yes" ; then
|
||||
USE_SYS_ENDIAN_H=yes
|
||||
BSWAP=__swap
|
||||
else
|
||||
USE_SYS_ENDIAN_H=no
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$USE_SYS_ENDIAN_H" = "yes" ; then
|
||||
AC_DEFINE([USE_SYS_ENDIAN_H], 1,
|
||||
[Define to use byteswap macros from <sys/endian.h>])
|
||||
AC_DEFINE_UNQUOTED([bswap_16], ${BSWAP}16,
|
||||
[Define to 16-bit byteswap macro])
|
||||
AC_DEFINE_UNQUOTED([bswap_32], ${BSWAP}32,
|
||||
[Define to 32-bit byteswap macro])
|
||||
AC_DEFINE_UNQUOTED([bswap_64], ${BSWAP}64,
|
||||
[Define to 64-bit byteswap macro])
|
||||
fi
|
||||
if test "$USE_SYS_ENDIAN_H" = "yes" ; then
|
||||
AC_DEFINE([USE_SYS_ENDIAN_H], 1,
|
||||
[Define to use byteswap macros from <sys/endian.h>])
|
||||
AC_DEFINE_UNQUOTED([bswap_16], ${BSWAP}16,
|
||||
[Define to 16-bit byteswap macro])
|
||||
AC_DEFINE_UNQUOTED([bswap_32], ${BSWAP}32,
|
||||
[Define to 32-bit byteswap macro])
|
||||
AC_DEFINE_UNQUOTED([bswap_64], ${BSWAP}64,
|
||||
[Define to 64-bit byteswap macro])
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_SUBST([moduledir])
|
||||
|
||||
AC_MSG_NOTICE(
|
||||
[Please change the Driver line in xorg.conf from "ati" to "r128" or install]
|
||||
[the ati wrapper as well:]
|
||||
[ https://gitlab.freedesktop.org/xorg/driver/xf86-video-ati]
|
||||
)
|
||||
|
||||
AC_CONFIG_FILES([Makefile src/Makefile man/Makefile])
|
||||
AC_OUTPUT
|
||||
|
||||
Reference in New Issue
Block a user