configure.ac revision de78e416
115fb4814Smrg#  Copyright 2005 Adam Jackson.
215fb4814Smrg#
315fb4814Smrg#  Permission is hereby granted, free of charge, to any person obtaining a
415fb4814Smrg#  copy of this software and associated documentation files (the "Software"),
515fb4814Smrg#  to deal in the Software without restriction, including without limitation
615fb4814Smrg#  on the rights to use, copy, modify, merge, publish, distribute, sub
715fb4814Smrg#  license, and/or sell copies of the Software, and to permit persons to whom
815fb4814Smrg#  the Software is furnished to do so, subject to the following conditions:
915fb4814Smrg#
1015fb4814Smrg#  The above copyright notice and this permission notice (including the next
1115fb4814Smrg#  paragraph) shall be included in all copies or substantial portions of the
1215fb4814Smrg#  Software.
1315fb4814Smrg#
1415fb4814Smrg#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
1515fb4814Smrg#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
1615fb4814Smrg#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
1715fb4814Smrg#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
1815fb4814Smrg#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
1915fb4814Smrg#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2015fb4814Smrg#
2115fb4814Smrg# Process this file with autoconf to produce a configure script
2215fb4814Smrg
2315fb4814SmrgAC_PREREQ(2.57)
2415fb4814SmrgAC_INIT([xf86-video-ast],
25de78e416Smrg        0.89.8,
2615fb4814Smrg        [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
2715fb4814Smrg        xf86-video-ast)
2815fb4814Smrg
2915fb4814SmrgAC_CONFIG_SRCDIR([Makefile.am])
3015fb4814SmrgAM_CONFIG_HEADER([config.h])
3115fb4814SmrgAC_CONFIG_AUX_DIR(.)
3215fb4814Smrg
3315fb4814SmrgAM_INIT_AUTOMAKE([dist-bzip2])
3415fb4814Smrg
3515fb4814SmrgAM_MAINTAINER_MODE
3615fb4814Smrg
3715fb4814Smrg# Checks for programs.
3815fb4814SmrgAC_DISABLE_STATIC
3915fb4814SmrgAC_PROG_LIBTOOL
4015fb4814SmrgAC_PROG_CC
4115fb4814Smrg
4215fb4814SmrgAH_TOP([#include "xorg-server.h"])
4315fb4814Smrg
4415fb4814SmrgAC_ARG_WITH(xorg-module-dir,
4515fb4814Smrg            AC_HELP_STRING([--with-xorg-module-dir=DIR],
4615fb4814Smrg                           [Default xorg module directory [[default=$libdir/xorg/modules]]]),
4715fb4814Smrg            [moduledir="$withval"],
4815fb4814Smrg            [moduledir="$libdir/xorg/modules"])
4915fb4814Smrg
5015fb4814Smrg# Checks for extensions
5115fb4814SmrgXORG_DRIVER_CHECK_EXT(RANDR, randrproto)
5215fb4814SmrgXORG_DRIVER_CHECK_EXT(RENDER, renderproto)
5315fb4814SmrgXORG_DRIVER_CHECK_EXT(XV, videoproto)
5415fb4814SmrgXORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
5515fb4814Smrg
5615fb4814Smrg# Checks for pkg-config packages
5715fb4814SmrgPKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
5815fb4814Smrgsdkdir=$(pkg-config --variable=sdkdir xorg-server)
5915fb4814Smrg
6015fb4814Smrg# Checks for libraries.
61de78e416SmrgSAVE_CPPFLAGS="$CPPFLAGS"
62de78e416SmrgCPPFLAGS="$CPPFLAGS $XORG_CFLAGS"
63de78e416SmrgAC_CHECK_DECL(XSERVER_LIBPCIACCESS,
64de78e416Smrg              [XSERVER_LIBPCIACCESS=yes],[XSERVER_LIBPCIACCESS=no],
65de78e416Smrg              [#include "xorg-server.h"])
66de78e416SmrgCPPFLAGS="$SAVE_CPPFLAGS"
6715fb4814Smrg
6815fb4814Smrg# Checks for header files.
6915fb4814SmrgAC_HEADER_STDC
7015fb4814Smrg
71de78e416Smrgif test "x$XSERVER_LIBPCIACCESS" = xyes; then
72de78e416Smrg    PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
73de78e416Smrg    XORG_CFLAGS="$XORG_CFLAGS $PCIACCESS_CFLAGS"
74de78e416Smrgfi
75de78e416SmrgAM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
76de78e416Smrg
7715fb4814SmrgAC_SUBST([XORG_CFLAGS])
7815fb4814SmrgAC_SUBST([moduledir])
7915fb4814Smrg
8015fb4814SmrgDRIVER_NAME=nv
8115fb4814SmrgAC_SUBST([DRIVER_NAME])
8215fb4814Smrg
8315fb4814SmrgXORG_MANPAGE_SECTIONS
8415fb4814SmrgXORG_RELEASE_VERSION
8515fb4814Smrg
8615fb4814SmrgAC_OUTPUT([
8715fb4814Smrg	Makefile
8815fb4814Smrg	src/Makefile
8915fb4814Smrg])
90