summaryrefslogtreecommitdiff
path: root/driver/xf86-video-apm/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'driver/xf86-video-apm/configure.ac')
-rw-r--r--driver/xf86-video-apm/configure.ac78
1 files changed, 23 insertions, 55 deletions
diff --git a/driver/xf86-video-apm/configure.ac b/driver/xf86-video-apm/configure.ac
index d08204060..780b0a51b 100644
--- a/driver/xf86-video-apm/configure.ac
+++ b/driver/xf86-video-apm/configure.ac
@@ -20,93 +20,61 @@
#
# Process this file with autoconf to produce a configure script
-AC_PREREQ(2.57)
+# Initialize Autoconf
+AC_PREREQ([2.60])
AC_INIT([xf86-video-apm],
- 1.2.2,
+ [1.2.3],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
- xf86-video-apm)
-
+ [xf86-video-apm])
AC_CONFIG_SRCDIR([Makefile.am])
-AM_CONFIG_HEADER([config.h])
+AC_CONFIG_HEADERS([config.h])
AC_CONFIG_AUX_DIR(.)
-AM_INIT_AUTOMAKE([dist-bzip2])
-
+# Initialize Automake
+AM_INIT_AUTOMAKE([foreign dist-bzip2])
AM_MAINTAINER_MODE
-# Checks for programs.
+# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
+m4_ifndef([XORG_MACROS_VERSION],
+ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
+XORG_MACROS_VERSION(1.8)
+XORG_DEFAULT_OPTIONS
+
+# Initialize libtool
AC_DISABLE_STATIC
AC_PROG_LIBTOOL
-AC_PROG_CC
AH_TOP([#include "xorg-server.h"])
+# Define a configure option for an alternate module directory
AC_ARG_WITH(xorg-module-dir, [ --with-xorg-module-dir=DIR ],
[ moduledir="$withval" ],
[ moduledir="$libdir/xorg/modules" ])
AC_SUBST(moduledir)
-# Checks for extensions
+# Store the list of server defined optional extensions in REQUIRED_MODULES
XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
XORG_DRIVER_CHECK_EXT(XV, videoproto)
XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
-# Checks for pkg-config packages
+# Obtain compiler/linker options for the driver dependencies
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901] xproto fontsproto $REQUIRED_MODULES)
PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
HAVE_XEXTPROTO_71="yes"; AC_DEFINE(HAVE_XEXTPROTO_71, 1, [xextproto 7.1 available]),
HAVE_XEXTPROTO_71="no")
AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
-sdkdir=$(pkg-config --variable=sdkdir xorg-server)
-
-PKG_CHECK_MODULES(XF86RUSH, xxf86rush, have_xf86rush=yes, have_xf86rush=no)
-AM_CONDITIONAL(XF86RUSH, test "x$have_xf86rush" = xyes)
-AC_SUBST([XF86RUSH_LIBS])
-AC_SUBST([XF86RUSH_CFLAGS])
-
-CFLAGS="$CFLAGS $XORG_CFLAGS $XF86RUSH_CFLAGS"' -I$(top_srcdir)/src'
-INCLUDES="$XORG_INCS -I${sdkdir} $XF86RUSH_INCS "'-I$(top_srcdir)/src -I$(prefix)/include'
-AC_SUBST([CFLAGS])
-AC_SUBST([INCLUDES])
-save_CFLAGS="$CFLAGS"
-CFLAGS="$XORG_CFLAGS"
-AC_CHECK_DECL(xf86ConfigIsaEntity,
- [AC_DEFINE(HAVE_ISA, 1, [Have ISA support])],
- [],
- [#include "xf86.h"])
-CFLAGS="$save_CFLAGS"
-# Checks for libraries.
-SAVE_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $XORG_CFLAGS"
-AC_CHECK_DECL(XSERVER_LIBPCIACCESS,
- [XSERVER_LIBPCIACCESS=yes],[XSERVER_LIBPCIACCESS=no],
- [#include "xorg-server.h"])
-AC_CHECK_HEADER(xf1bpp.h,[AC_DEFINE(HAVE_XF1BPP, 1, [Have 1bpp support])],[])
-AC_CHECK_HEADER(xf4bpp.h,[AC_DEFINE(HAVE_XF4BPP, 1, [Have 4bpp support])],[])
-CPPFLAGS="$SAVE_CPPFLAGS"
-
-# Checks for header files.
-AC_HEADER_STDC
-
-if test "x$XSERVER_LIBPCIACCESS" = xyes; then
- PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
- XORG_CFLAGS="$XORG_CFLAGS $PCIACCESS_CFLAGS"
-fi
+PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
DRIVER_NAME=apm
AC_SUBST([DRIVER_NAME])
-XORG_MANPAGE_SECTIONS
-XORG_RELEASE_VERSION
-
-XORG_CHECK_LINUXDOC
-
-AC_OUTPUT([
- Makefile
- src/Makefile
- man/Makefile
+AC_CONFIG_FILES([
+ Makefile
+ src/Makefile
+ man/Makefile
])
+AC_OUTPUT