configure.ac revision 1ae1b5e8
176888252Smrg# Copyright 2005 Adam Jackson. 276888252Smrg# 376888252Smrg# Permission is hereby granted, free of charge, to any person obtaining a 476888252Smrg# copy of this software and associated documentation files (the "Software"), 576888252Smrg# to deal in the Software without restriction, including without limitation 676888252Smrg# on the rights to use, copy, modify, merge, publish, distribute, sub 776888252Smrg# license, and/or sell copies of the Software, and to permit persons to whom 876888252Smrg# the Software is furnished to do so, subject to the following conditions: 976888252Smrg# 1076888252Smrg# The above copyright notice and this permission notice (including the next 1176888252Smrg# paragraph) shall be included in all copies or substantial portions of the 1276888252Smrg# Software. 1376888252Smrg# 1476888252Smrg# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 1576888252Smrg# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 1676888252Smrg# FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL 1776888252Smrg# ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 1876888252Smrg# IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 1976888252Smrg# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 2076888252Smrg# 2176888252Smrg# Process this file with autoconf to produce a configure script 2276888252Smrg 2376888252SmrgAC_PREREQ(2.57) 2476888252SmrgAC_INIT([xf86-video-cirrus], 251ae1b5e8Smrg 1.3.0, 2676888252Smrg [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], 2776888252Smrg xf86-video-cirrus) 2876888252Smrg 2976888252SmrgAC_CONFIG_SRCDIR([Makefile.am]) 3076888252SmrgAM_CONFIG_HEADER([config.h]) 3176888252SmrgAC_CONFIG_AUX_DIR(.) 3276888252Smrg 3376888252SmrgAM_INIT_AUTOMAKE([dist-bzip2]) 3476888252Smrg 3576888252SmrgAM_MAINTAINER_MODE 3676888252Smrg 371ae1b5e8Smrg# Require xorg-macros: XORG_CWARNFLAGS, XORG_CHANGELOG 381ae1b5e8Smrgm4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.2 or later before running autoconf/autogen])]) 391ae1b5e8SmrgXORG_MACROS_VERSION(1.2) 401ae1b5e8Smrg 4176888252Smrg# Checks for programs. 4276888252SmrgAC_DISABLE_STATIC 4376888252SmrgAC_PROG_LIBTOOL 4476888252SmrgAC_PROG_CC 451ae1b5e8SmrgXORG_CWARNFLAGS 4676888252Smrg 4776888252SmrgAH_TOP([#include "xorg-server.h"]) 4876888252Smrg 4976888252SmrgAC_ARG_WITH(xorg-module-dir, 5076888252Smrg AC_HELP_STRING([--with-xorg-module-dir=DIR], 5176888252Smrg [Default xorg module directory [[default=$libdir/xorg/modules]]]), 5276888252Smrg [moduledir="$withval"], 5376888252Smrg [moduledir="$libdir/xorg/modules"]) 5476888252Smrg 5576888252Smrg# Checks for extensions 5676888252SmrgXORG_DRIVER_CHECK_EXT(RANDR, randrproto) 5776888252SmrgXORG_DRIVER_CHECK_EXT(RENDER, renderproto) 5876888252SmrgXORG_DRIVER_CHECK_EXT(XV, videoproto) 5976888252SmrgXORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto) 6076888252Smrg 6176888252Smrg# Checks for pkg-config packages 621ae1b5e8SmrgPKG_CHECK_MODULES(XORG, [xorg-server >= 1.4 xproto fontsproto $REQUIRED_MODULES]) 6376888252Smrgsdkdir=$(pkg-config --variable=sdkdir xorg-server) 6476888252Smrg 6576888252Smrg# Checks for libraries. 661ae1b5e8SmrgSAVE_CPPFLAGS="$CPPFLAGS" 671ae1b5e8SmrgCPPFLAGS="$CPPFLAGS $XORG_CFLAGS" 681ae1b5e8SmrgAC_CHECK_DECL(XSERVER_LIBPCIACCESS, 691ae1b5e8Smrg [XSERVER_LIBPCIACCESS=yes],[XSERVER_LIBPCIACCESS=no], 701ae1b5e8Smrg [#include "xorg-server.h"]) 711ae1b5e8SmrgAC_CHECK_HEADER(xf1bpp.h,[AC_DEFINE(HAVE_XF1BPP, 1, [Have 1bpp support])],[]) 721ae1b5e8SmrgAC_CHECK_HEADER(xf4bpp.h,[AC_DEFINE(HAVE_XF4BPP, 1, [Have 4bpp support])],[]) 731ae1b5e8SmrgCPPFLAGS="$SAVE_CPPFLAGS" 741ae1b5e8Smrg 751ae1b5e8Smrgif test "x$XSERVER_LIBPCIACCESS" = xyes; then 761ae1b5e8Smrg PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0]) 771ae1b5e8Smrg XORG_CFLAGS="$XORG_CFLAGS $PCIACCESS_CFLAGS" 781ae1b5e8Smrgfi 791ae1b5e8SmrgAM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes) 8076888252Smrg 8176888252Smrg# Checks for header files. 8276888252SmrgAC_HEADER_STDC 8376888252Smrg 8476888252SmrgAC_SUBST([XORG_CFLAGS]) 8576888252SmrgAC_SUBST([moduledir]) 8676888252Smrg 8776888252SmrgDRIVER_NAME=cirrus 8876888252SmrgAC_SUBST([DRIVER_NAME]) 8976888252Smrg 9076888252SmrgXORG_MANPAGE_SECTIONS 9176888252SmrgXORG_RELEASE_VERSION 921ae1b5e8SmrgXORG_CHANGELOG 9376888252Smrg 9476888252SmrgAC_OUTPUT([ 9576888252Smrg Makefile 9676888252Smrg src/Makefile 9776888252Smrg man/Makefile 9876888252Smrg]) 99