1*43c1707eStholo# aclocal.m4 generated automatically by aclocal 1.4e 2*43c1707eStholo 3*43c1707eStholo# Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000 4*43c1707eStholo# Free Software Foundation, Inc. 5*43c1707eStholo# This file is free software; the Free Software Foundation 6*43c1707eStholo# gives unlimited permission to copy and/or distribute it, 7*43c1707eStholo# with or without modifications, as long as this notice is preserved. 8*43c1707eStholo 9*43c1707eStholo# This program is distributed in the hope that it will be useful, 10*43c1707eStholo# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11*43c1707eStholo# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12*43c1707eStholo# PARTICULAR PURPOSE. 13*43c1707eStholo 14*43c1707eStholo/* This program is free software; you can redistribute it and/or modify 15*43c1707eStholo it under the terms of the GNU General Public License as published by 16*43c1707eStholo the Free Software Foundation; either version 2, or (at your option) 17*43c1707eStholo any later version. 18*43c1707eStholo 19*43c1707eStholo This program is distributed in the hope that it will be useful, 20*43c1707eStholo but WITHOUT ANY WARRANTY; without even the implied warranty of 21*43c1707eStholo MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22*43c1707eStholo GNU General Public License for more details. */ 23*43c1707eStholo 24*43c1707eStholoAC_DEFUN(ACX_WITH_GSSAPI,[ 25*43c1707eStholo# 26*43c1707eStholo# Use --with-gssapi[=DIR] to enable GSSAPI support. 27*43c1707eStholo# 28*43c1707eStholo# defaults to enabled with DIR in default list below 29*43c1707eStholo# 30*43c1707eStholo# Search for /SUNHEA/ and read the comments about this default below. 31*43c1707eStholo# 32*43c1707eStholoAC_ARG_WITH([gssapi], 33*43c1707eStholo [ --with-gssapi=value GSSAPI directory], 34*43c1707eStholo [acx_gssapi_withgssapi=$withval], [acx_gssapi_withgssapi=yes])dnl 35*43c1707eStholo 36*43c1707eStholodnl 37*43c1707eStholodnl FIXME - cache withval and obliterate later cache values when options change 38*43c1707eStholodnl 39*43c1707eStholo# 40*43c1707eStholo# Try to locate a GSSAPI installation if no location was specified, assuming 41*43c1707eStholo# GSSAPI was enabled (the default). 42*43c1707eStholo# 43*43c1707eStholoif test -n "$acx_gssapi_cv_gssapi"; then 44*43c1707eStholo # Granted, this is a slightly ugly way to print this info, but the 45*43c1707eStholo # AC_CHECK_HEADER used in the search for a GSSAPI installation makes using 46*43c1707eStholo # AC_CACHE_CHECK worse 47*43c1707eStholo AC_MSG_CHECKING([for GSSAPI]) 48*43c1707eStholoelse :; fi 49*43c1707eStholoAC_CACHE_VAL([acx_gssapi_cv_gssapi], [ 50*43c1707eStholoif test x$acx_gssapi_withgssapi = xyes; then 51*43c1707eStholo # --with but no location specified 52*43c1707eStholo # assume a gssapi.h or gssapi/gssapi.h locates our install. 53*43c1707eStholo # 54*43c1707eStholo # This isn't always strictly true. For instance Solaris 7's SUNHEA (header) 55*43c1707eStholo # package installs gssapi.h whether or not the necessary libraries are 56*43c1707eStholo # installed. I'm still not sure whether to consider this a bug. The long 57*43c1707eStholo # way around is to not consider GSSPAI installed unless gss_import_name is 58*43c1707eStholo # found, but that brings up a lot of other hassles, like continuing to let 59*43c1707eStholo # gcc & ld generate the error messages when the user uses --with-gssapi=dir 60*43c1707eStholo # as a debugging aid. The short way around is to disable GSSAPI by default, 61*43c1707eStholo # but I think Sun users have been faced with this for awhile and I haven't 62*43c1707eStholo # heard many complaints. 63*43c1707eStholo acx_gssapi_save_CPPFLAGS=$CPPFLAGS 64*43c1707eStholo for acx_gssapi_cv_gssapi in yes /usr/kerberos /usr/cygnus/kerbnet no; do 65*43c1707eStholo if test x$acx_gssapi_cv_gssapi = xno; then 66*43c1707eStholo break 67*43c1707eStholo fi 68*43c1707eStholo if test x$acx_gssapi_cv_gssapi = xyes; then 69*43c1707eStholo AC_CHECKING([for GSSAPI]) 70*43c1707eStholo else 71*43c1707eStholo CPPFLAGS="$acx_gssapi_save_CPPFLAGS -I$acx_gssapi_cv_gssapi/include" 72*43c1707eStholo AC_CHECKING([for GSSAPI in $acx_gssapi_cv_gssapi]) 73*43c1707eStholo fi 74*43c1707eStholo unset ac_cv_header_gssapi_h 75*43c1707eStholo unset ac_cv_header_gssapi_gssapi_h 76*43c1707eStholo AC_CHECK_HEADERS([gssapi.h gssapi/gssapi.h]) 77*43c1707eStholo if test "$ac_cv_header_gssapi_h" = "yes" || 78*43c1707eStholo test "$ac_cv_header_gssapi_gssapi_h" = "yes"; then 79*43c1707eStholo break 80*43c1707eStholo fi 81*43c1707eStholo done 82*43c1707eStholo CPPFLAGS=$acx_gssapi_save_CPPFLAGS 83*43c1707eStholoelse 84*43c1707eStholo acx_gssapi_cv_gssapi=$acx_gssapi_withgssapi 85*43c1707eStholofi 86*43c1707eStholoAC_MSG_CHECKING([for GSSAPI]) 87*43c1707eStholo])dnl 88*43c1707eStholoAC_MSG_RESULT([$acx_gssapi_cv_gssapi]) 89*43c1707eStholo 90*43c1707eStholo# 91*43c1707eStholo# Set up GSSAPI includes for later use. We don't bother to check for 92*43c1707eStholo# $acx_gssapi_cv_gssapi=no here since that will be caught later. 93*43c1707eStholo# 94*43c1707eStholoif test x$acx_gssapi_cv_gssapi = yes; then 95*43c1707eStholo # no special includes necessary 96*43c1707eStholo GSSAPI_INCLUDES="" 97*43c1707eStholoelse 98*43c1707eStholo # GSSAPI at $acx_gssapi_cv_gssapi (could be 'no') 99*43c1707eStholo GSSAPI_INCLUDES=" -I$acx_gssapi_cv_gssapi/include" 100*43c1707eStholofi 101*43c1707eStholo 102*43c1707eStholo# 103*43c1707eStholo# Get the rest of the information CVS needs to compile with GSSAPI support 104*43c1707eStholo# 105*43c1707eStholoif test x$acx_gssapi_cv_gssapi != xno; then 106*43c1707eStholo # define HAVE_GSSAPI and set up the includes 107*43c1707eStholo AC_DEFINE([HAVE_GSSAPI],, [Define if you have GSSAPI with Kerberos version 5 available.]) 108*43c1707eStholo includeopt=$includeopt$GSSAPI_INCLUDES 109*43c1707eStholo 110*43c1707eStholo # locate any other headers 111*43c1707eStholo acx_gssapi_save_CPPFLAGS=$CPPFLAGS 112*43c1707eStholo CPPFLAGS=$CPPFLAGS$GSSAPI_INCLUDES 113*43c1707eStholo dnl We don't use HAVE_KRB5_H anywhere, but including it here might make it 114*43c1707eStholo dnl easier to spot errors by reading configure output 115*43c1707eStholo AC_CHECK_HEADERS([gssapi.h gssapi/gssapi.h gssapi/gssapi_generic.h krb5.h]) 116*43c1707eStholo # And look through them for GSS_C_NT_HOSTBASED_SERVICE or its alternatives 117*43c1707eStholo AC_CACHE_CHECK([for GSS_C_NT_HOSTBASED_SERVICE], [acx_gssapi_cv_gss_c_nt_hostbased_service], 118*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service=no 119*43c1707eStholo if test "$ac_cv_header_gssapi_h" = "yes"; then 120*43c1707eStholo AC_EGREP_HEADER([GSS_C_NT_HOSTBASED_SERVICE], [gssapi.h], 121*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service=yes], 122*43c1707eStholo AC_EGREP_HEADER([gss_nt_service_name], [gssapi.h], 123*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service=gss_nt_service_name])) 124*43c1707eStholo fi 125*43c1707eStholo if test $acx_gssapi_cv_gss_c_nt_hostbased_service = no && 126*43c1707eStholo test "$ac_cv_header_gssapi_gssapi_h" = "yes"; then 127*43c1707eStholo AC_EGREP_HEADER([GSS_C_NT_HOSTBASED_SERVICE], [gssapi/gssapi.h], 128*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service], 129*43c1707eStholo AC_EGREP_HEADER([gss_nt_service_name], [gssapi/gssapi.h], 130*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service=gss_nt_service_name])) 131*43c1707eStholo fi 132*43c1707eStholo if test $acx_gssapi_cv_gss_c_nt_hostbased_service = no && 133*43c1707eStholo test "$ac_cv_header_gssapi_gssapi_generic_h" = "yes"; then 134*43c1707eStholo AC_EGREP_HEADER([GSS_C_NT_HOSTBASED_SERVICE], [gssapi/gssapi_generic.h], 135*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service], 136*43c1707eStholo AC_EGREP_HEADER([gss_nt_service_name], [gssapi/gssapi_generic.h], 137*43c1707eStholo [acx_gssapi_cv_gss_c_nt_hostbased_service=gss_nt_service_name])) 138*43c1707eStholo fi]) 139*43c1707eStholo if test $acx_gssapi_cv_gss_c_nt_hostbased_service != yes && 140*43c1707eStholo test $acx_gssapi_cv_gss_c_nt_hostbased_service != no; then 141*43c1707eStholo # don't define for yes since that means it already means something and 142*43c1707eStholo # don't define for no since we'd rather the compiler catch the error 143*43c1707eStholo AC_DEFINE_UNQUOTED([GSS_C_NT_HOSTBASED_SERVICE], [$acx_gssapi_cv_gss_c_nt_hostbased_service], 144*43c1707eStholo[Define to an alternative value if GSS_C_NT_HOSTBASED_SERVICE isn't defined 145*43c1707eStholoin the gssapi.h header file. MIT Kerberos 1.2.1 requires this. Only relevant 146*43c1707eStholowhen using GSSAPI.]) 147*43c1707eStholo fi 148*43c1707eStholo CPPFLAGS=$acx_gssapi_save_CPPFLAGS 149*43c1707eStholo 150*43c1707eStholo # Expect the libs to be installed parallel to the headers 151*43c1707eStholo # 152*43c1707eStholo # We could try once with and once without, but I'm not sure it's worth the 153*43c1707eStholo # trouble. 154*43c1707eStholo if test x$acx_gssapi_cv_gssapi != xyes; then 155*43c1707eStholo if test -z "$LIBS"; then 156*43c1707eStholo LIBS="-L$acx_gssapi_cv_gssapi/lib" 157*43c1707eStholo else 158*43c1707eStholo LIBS="-L$acx_gssapi_cv_gssapi/lib $LIBS" 159*43c1707eStholo fi 160*43c1707eStholo else :; fi 161*43c1707eStholo 162*43c1707eStholo dnl What happens if we want to enable, say, krb5 and some other GSSAPI 163*43c1707eStholo dnl authentication method at the same time? 164*43c1707eStholo # 165*43c1707eStholo # Some of the order below is particular due to library dependencies 166*43c1707eStholo # 167*43c1707eStholo 168*43c1707eStholo # 169*43c1707eStholo # des Heimdal K 0.3d, but Heimdal seems to be set up such 170*43c1707eStholo # that it could have been installed from elsewhere. 171*43c1707eStholo # 172*43c1707eStholo AC_SEARCH_LIBS([des_set_odd_parity], [des]) 173*43c1707eStholo 174*43c1707eStholo # 175*43c1707eStholo # com_err Heimdal K 0.3d 176*43c1707eStholo # 177*43c1707eStholo # com_err MIT K5 v1.2.2-beta1 178*43c1707eStholo # 179*43c1707eStholo AC_SEARCH_LIBS([com_err], [com_err]) 180*43c1707eStholo 181*43c1707eStholo # 182*43c1707eStholo # asn1 Heimdal K 0.3d -lcom_err 183*43c1707eStholo # 184*43c1707eStholo AC_SEARCH_LIBS([initialize_asn1_error_table_r], [asn1]) 185*43c1707eStholo 186*43c1707eStholo # 187*43c1707eStholo # resolv required, but not installed by Heimdal K 0.3d 188*43c1707eStholo # 189*43c1707eStholo # resolv MIT K5 1.2.2-beta1 190*43c1707eStholo # Linux 2.2.17 191*43c1707eStholo # 192*43c1707eStholo AC_SEARCH_LIBS([__dn_expand], [resolv]) 193*43c1707eStholo 194*43c1707eStholo # 195*43c1707eStholo # roken Heimdal K 0.3d -lresolv 196*43c1707eStholo # 197*43c1707eStholo AC_SEARCH_LIBS([roken_gethostbyaddr], [roken]) 198*43c1707eStholo 199*43c1707eStholo # 200*43c1707eStholo # k5crypto MIT K5 v1.2.2-beta1 201*43c1707eStholo # 202*43c1707eStholo AC_SEARCH_LIBS([valid_enctype], [k5crypto]) 203*43c1707eStholo 204*43c1707eStholo # 205*43c1707eStholo # gen ? ? ? Needed on Irix 5.3 with some 206*43c1707eStholo # Irix 5.3 version of Kerberos. I'm not 207*43c1707eStholo # sure which since Irix didn't 208*43c1707eStholo # get any testing this time 209*43c1707eStholo # around. Original comment: 210*43c1707eStholo # 211*43c1707eStholo # This is necessary on Irix 5.3, in order to link against libkrb5 -- 212*43c1707eStholo # there, an_to_ln.o refers to things defined only in -lgen. 213*43c1707eStholo # 214*43c1707eStholo AC_SEARCH_LIBS([compile], [gen]) 215*43c1707eStholo 216*43c1707eStholo # 217*43c1707eStholo # krb5 ? ? ? -lgen -l??? 218*43c1707eStholo # Irix 5.3 219*43c1707eStholo # 220*43c1707eStholo # krb5 MIT K5 v1.1.1 221*43c1707eStholo # 222*43c1707eStholo # krb5 MIT K5 v1.2.2-beta1 -lcrypto -lcom_err 223*43c1707eStholo # Linux 2.2.17 224*43c1707eStholo # 225*43c1707eStholo # krb5 MIT K5 v1.2.2-beta1 -lcrypto -lcom_err -lresolv 226*43c1707eStholo # 227*43c1707eStholo # krb5 Heimdal K 0.3d -lasn1 -lroken -ldes 228*43c1707eStholo # 229*43c1707eStholo AC_SEARCH_LIBS([krb5_free_context], [krb5]) 230*43c1707eStholo 231*43c1707eStholo # 232*43c1707eStholo # gssapi_krb5 Only lib needed with MIT K5 v1.2.1, so find it first in 233*43c1707eStholo # order to prefer MIT Kerberos. If both MIT & Heimdal 234*43c1707eStholo # Kerberos are installed and in the path, this will leave 235*43c1707eStholo # some of the libraries above in LIBS unnecessarily, but 236*43c1707eStholo # noone would ever do that, right? 237*43c1707eStholo # 238*43c1707eStholo # gssapi_krb5 MIT K5 v1.2.2-beta1 -lkrb5 239*43c1707eStholo # 240*43c1707eStholo # gssapi Heimdal K 0.3d -lkrb5 241*43c1707eStholo # 242*43c1707eStholo AC_SEARCH_LIBS([gss_import_name], [gssapi_krb5 gssapi]) 243*43c1707eStholofi 244*43c1707eStholo])dnl 245*43c1707eStholo 246*43c1707eStholo# Do all the work for Automake. This macro actually does too much -- 247*43c1707eStholo# some checks are only needed if your package does certain things. 248*43c1707eStholo# But this isn't really a big deal. 249*43c1707eStholo 250*43c1707eStholo# serial 5 251*43c1707eStholo 252*43c1707eStholo# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 253*43c1707eStholo# written in clear, in which case automake, when reading aclocal.m4, 254*43c1707eStholo# will think it sees a *use*, and therefore will trigger all it's 255*43c1707eStholo# C support machinery. Also note that it means that autoscan, seeing 256*43c1707eStholo# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 257*43c1707eStholo 258*43c1707eStholo 259*43c1707eStholo# We require 2.13 because we rely on SHELL being computed by configure. 260*43c1707eStholoAC_PREREQ([2.13]) 261*43c1707eStholo 262*43c1707eStholo# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) 263*43c1707eStholo# ----------------------------------------------------------- 264*43c1707eStholo# If MACRO-NAME is provided do IF-PROVIDED, else IF-NOT-PROVIDED. 265*43c1707eStholo# The purpose of this macro is to provide the user with a means to 266*43c1707eStholo# check macros which are provided without letting her know how the 267*43c1707eStholo# information is coded. 268*43c1707eStholo# If this macro is not defined by Autoconf, define it here. 269*43c1707eStholoifdef([AC_PROVIDE_IFELSE], 270*43c1707eStholo [], 271*43c1707eStholo [define([AC_PROVIDE_IFELSE], 272*43c1707eStholo [ifdef([AC_PROVIDE_$1], 273*43c1707eStholo [$2], [$3])])]) 274*43c1707eStholo 275*43c1707eStholo 276*43c1707eStholo# AM_INIT_AUTOMAKE(PACKAGE,VERSION, [NO-DEFINE]) 277*43c1707eStholo# ---------------------------------------------- 278*43c1707eStholoAC_DEFUN([AM_INIT_AUTOMAKE], 279*43c1707eStholo[AC_REQUIRE([AC_PROG_INSTALL])dnl 280*43c1707eStholo# test to see if srcdir already configured 281*43c1707eStholoif test "`CDPATH=:; cd $srcdir && pwd`" != "`pwd`" && 282*43c1707eStholo test -f $srcdir/config.status; then 283*43c1707eStholo AC_MSG_ERROR([source directory already configured; run \"make distclean\" there first]) 284*43c1707eStholofi 285*43c1707eStholo 286*43c1707eStholo# Define the identity of the package. 287*43c1707eStholoPACKAGE=$1 288*43c1707eStholoAC_SUBST(PACKAGE)dnl 289*43c1707eStholoVERSION=$2 290*43c1707eStholoAC_SUBST(VERSION)dnl 291*43c1707eStholoifelse([$3],, 292*43c1707eStholo[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 293*43c1707eStholoAC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])]) 294*43c1707eStholo 295*43c1707eStholo# Autoconf 2.50 wants to disallow AM_ names. We explicitly allow 296*43c1707eStholo# the ones we care about. 297*43c1707eStholoifdef([m4_pattern_allow], 298*43c1707eStholo [m4_pattern_allow([^AM_(C|CPP|CXX|OBJC|F|R|GCJ)FLAGS])])dnl 299*43c1707eStholo 300*43c1707eStholo# Some tools Automake needs. 301*43c1707eStholoAC_REQUIRE([AM_SANITY_CHECK])dnl 302*43c1707eStholoAC_REQUIRE([AC_ARG_PROGRAM])dnl 303*43c1707eStholoAM_MISSING_PROG(ACLOCAL, aclocal) 304*43c1707eStholoAM_MISSING_PROG(AUTOCONF, autoconf) 305*43c1707eStholoAM_MISSING_PROG(AUTOMAKE, automake) 306*43c1707eStholoAM_MISSING_PROG(AUTOHEADER, autoheader) 307*43c1707eStholoAM_MISSING_PROG(MAKEINFO, makeinfo) 308*43c1707eStholoAM_MISSING_PROG(AMTAR, tar) 309*43c1707eStholoAM_MISSING_INSTALL_SH 310*43c1707eStholoAM_PROG_INSTALL_STRIP 311*43c1707eStholo# We need awk for the "check" target. The system "awk" is bad on 312*43c1707eStholo# some platforms. 313*43c1707eStholoAC_REQUIRE([AC_PROG_AWK])dnl 314*43c1707eStholoAC_REQUIRE([AC_PROG_MAKE_SET])dnl 315*43c1707eStholoAC_REQUIRE([AM_PROG_ETAGS])dnl 316*43c1707eStholoAC_REQUIRE([AM_DEP_TRACK])dnl 317*43c1707eStholoAC_REQUIRE([AM_SET_DEPDIR])dnl 318*43c1707eStholoAC_PROVIDE_IFELSE([AC_PROG_][CC], 319*43c1707eStholo [AM_DEPENDENCIES(CC)], 320*43c1707eStholo [define([AC_PROG_][CC], 321*43c1707eStholo defn([AC_PROG_][CC])[AM_DEPENDENCIES(CC)])])dnl 322*43c1707eStholoAC_PROVIDE_IFELSE([AC_PROG_][CXX], 323*43c1707eStholo [AM_DEPENDENCIES(CXX)], 324*43c1707eStholo [define([AC_PROG_][CXX], 325*43c1707eStholo defn([AC_PROG_][CXX])[AM_DEPENDENCIES(CXX)])])dnl 326*43c1707eStholo]) 327*43c1707eStholo 328*43c1707eStholo# 329*43c1707eStholo# Check to make sure that the build environment is sane. 330*43c1707eStholo# 331*43c1707eStholo 332*43c1707eStholo# serial 3 333*43c1707eStholo 334*43c1707eStholo# AM_SANITY_CHECK 335*43c1707eStholo# --------------- 336*43c1707eStholoAC_DEFUN([AM_SANITY_CHECK], 337*43c1707eStholo[AC_MSG_CHECKING([whether build environment is sane]) 338*43c1707eStholo# Just in case 339*43c1707eStholosleep 1 340*43c1707eStholoecho timestamp > conftest.file 341*43c1707eStholo# Do `set' in a subshell so we don't clobber the current shell's 342*43c1707eStholo# arguments. Must try -L first in case configure is actually a 343*43c1707eStholo# symlink; some systems play weird games with the mod time of symlinks 344*43c1707eStholo# (eg FreeBSD returns the mod time of the symlink's containing 345*43c1707eStholo# directory). 346*43c1707eStholoif ( 347*43c1707eStholo set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` 348*43c1707eStholo if test "$[*]" = "X"; then 349*43c1707eStholo # -L didn't work. 350*43c1707eStholo set X `ls -t $srcdir/configure conftest.file` 351*43c1707eStholo fi 352*43c1707eStholo if test "$[*]" != "X $srcdir/configure conftest.file" \ 353*43c1707eStholo && test "$[*]" != "X conftest.file $srcdir/configure"; then 354*43c1707eStholo 355*43c1707eStholo # If neither matched, then we have a broken ls. This can happen 356*43c1707eStholo # if, for instance, CONFIG_SHELL is bash and it inherits a 357*43c1707eStholo # broken ls alias from the environment. This has actually 358*43c1707eStholo # happened. Such a system could not be considered "sane". 359*43c1707eStholo AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 360*43c1707eStholoalias in your environment]) 361*43c1707eStholo fi 362*43c1707eStholo 363*43c1707eStholo test "$[2]" = conftest.file 364*43c1707eStholo ) 365*43c1707eStholothen 366*43c1707eStholo # Ok. 367*43c1707eStholo : 368*43c1707eStholoelse 369*43c1707eStholo AC_MSG_ERROR([newly created file is older than distributed files! 370*43c1707eStholoCheck your system clock]) 371*43c1707eStholofi 372*43c1707eStholorm -f conftest* 373*43c1707eStholoAC_MSG_RESULT(yes)]) 374*43c1707eStholo 375*43c1707eStholo 376*43c1707eStholo# serial 2 377*43c1707eStholo 378*43c1707eStholo# AM_MISSING_PROG(NAME, PROGRAM) 379*43c1707eStholo# ------------------------------ 380*43c1707eStholoAC_DEFUN([AM_MISSING_PROG], 381*43c1707eStholo[AC_REQUIRE([AM_MISSING_HAS_RUN]) 382*43c1707eStholo$1=${$1-"${am_missing_run}$2"} 383*43c1707eStholoAC_SUBST($1)]) 384*43c1707eStholo 385*43c1707eStholo 386*43c1707eStholo# AM_MISSING_INSTALL_SH 387*43c1707eStholo# --------------------- 388*43c1707eStholo# Like AM_MISSING_PROG, but only looks for install-sh. 389*43c1707eStholoAC_DEFUN([AM_MISSING_INSTALL_SH], 390*43c1707eStholo[AC_REQUIRE([AM_MISSING_HAS_RUN]) 391*43c1707eStholoif test -z "$install_sh"; then 392*43c1707eStholo for install_sh in "$ac_aux_dir/install-sh" \ 393*43c1707eStholo "$ac_aux_dir/install.sh" \ 394*43c1707eStholo "${am_missing_run}${ac_auxdir}/install-sh"; 395*43c1707eStholo do 396*43c1707eStholo test -f "$install_sh" && break 397*43c1707eStholo done 398*43c1707eStholo # FIXME: an evil hack: we remove the SHELL invocation from 399*43c1707eStholo # install_sh because automake adds it back in. Sigh. 400*43c1707eStholo install_sh=`echo $install_sh | sed -e 's/\${SHELL}//'` 401*43c1707eStholofi 402*43c1707eStholoAC_SUBST(install_sh)]) 403*43c1707eStholo 404*43c1707eStholo 405*43c1707eStholo# AM_MISSING_HAS_RUN 406*43c1707eStholo# ------------------ 407*43c1707eStholo# Define MISSING if not defined so far and test if it supports --run. 408*43c1707eStholo# If it does, set am_missing_run to use it, otherwise, to nothing. 409*43c1707eStholoAC_DEFUN([AM_MISSING_HAS_RUN], 410*43c1707eStholo[test x"${MISSING+set}" = xset || 411*43c1707eStholo MISSING="\${SHELL} `CDPATH=:; cd $ac_aux_dir && pwd`/missing" 412*43c1707eStholo# Use eval to expand $SHELL 413*43c1707eStholoif eval "$MISSING --run true"; then 414*43c1707eStholo am_missing_run="$MISSING --run " 415*43c1707eStholoelse 416*43c1707eStholo am_missing_run= 417*43c1707eStholo am_backtick='`' 418*43c1707eStholo AC_MSG_WARN([${am_backtick}missing' script is too old or missing]) 419*43c1707eStholofi 420*43c1707eStholo]) 421*43c1707eStholo 422*43c1707eStholo# AM_AUX_DIR_EXPAND 423*43c1707eStholo 424*43c1707eStholo# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 425*43c1707eStholo# $ac_aux_dir to ${srcdir}/foo. In other projects, it is set to `.'. 426*43c1707eStholo# Of course, Automake must honor this variable whenever it call a tool 427*43c1707eStholo# from the auxiliary directory. The problem is that $srcdir (hence 428*43c1707eStholo# $ac_aux_dir) can be either an absolute path or a path relative to 429*43c1707eStholo# $top_srcdir or absolute, this depends on how configure is run. This 430*43c1707eStholo# is pretty anoying since it makes $ac_aux_dir quite unusable in 431*43c1707eStholo# subdirectories: on the top source directory, any form will work 432*43c1707eStholo# fine, but in subdirectories relative pat needs to be adapted. 433*43c1707eStholo# - calling $top_srcidr/$ac_aux_dir/missing would success if $srcdir is 434*43c1707eStholo# relative, but fail if $srcdir is absolute 435*43c1707eStholo# - conversly, calling $ax_aux_dir/missing would fail if $srcdir is 436*43c1707eStholo# absolute, and success on relative paths. 437*43c1707eStholo# 438*43c1707eStholo# Consequently, we define and use $am_aux_dir, the "always absolute" 439*43c1707eStholo# version of $ac_aux_dir. 440*43c1707eStholo 441*43c1707eStholoAC_DEFUN([AM_AUX_DIR_EXPAND], [ 442*43c1707eStholo# expand $ac_aux_dir to an absolute path 443*43c1707eStholoam_aux_dir=`CDPATH=:; cd $ac_aux_dir && pwd` 444*43c1707eStholo]) 445*43c1707eStholo 446*43c1707eStholo# One issue with vendor `install' (even GNU) is that you can't 447*43c1707eStholo# specify the program used to strip binaries. This is especially 448*43c1707eStholo# annoying in cross=compiling environments, where the build's strip 449*43c1707eStholo# is unlikely to handle the host's binaries. 450*43c1707eStholo# Fortunately install-sh will honor a STRIPPROG variable, so if we ever 451*43c1707eStholo# need to use a non standard strip, we just have to make sure we use 452*43c1707eStholo# install-sh with the STRIPPROG variable set. 453*43c1707eStholoAC_DEFUN([AM_PROG_INSTALL_STRIP], 454*43c1707eStholo[AC_REQUIRE([AM_MISSING_INSTALL_SH]) 455*43c1707eStholodnl Don't test for $cross_compiling = yes, it might be `maybe'... 456*43c1707eStholo# We'd like to do this but we can't because it will unconditionally 457*43c1707eStholo# require config.guess. One way would be if autoconf had the capability 458*43c1707eStholo# to let us compile in this code only when config.guess was already 459*43c1707eStholo# a possibility. 460*43c1707eStholo#if test "$cross_compiling" != no; then 461*43c1707eStholo# # since we are cross-compiling, we need to check for a suitable `strip' 462*43c1707eStholo# AM_PROG_STRIP 463*43c1707eStholo# if test -z "$STRIP"; then 464*43c1707eStholo# AC_MSG_WARN([strip missing, install-strip will not strip binaries]) 465*43c1707eStholo# fi 466*43c1707eStholo#fi 467*43c1707eStholo 468*43c1707eStholo# If $STRIP is defined (either by the user, or by AM_PROG_STRIP), 469*43c1707eStholo# instruct install-strip to use install-sh and the given $STRIP program. 470*43c1707eStholo# Otherwise, just use ${INSTALL}: the idea is to use the vendor install 471*43c1707eStholo# as much as possible, because it's faster. 472*43c1707eStholoif test -z "$STRIP"; then 473*43c1707eStholo # The top level make will set INSTALL_PROGRAM=$(INSTALL_STRIP_PROGRAM) 474*43c1707eStholo # and the double dolard below is there to make sure that ${INSTALL} 475*43c1707eStholo # is substitued in the sub-makes, not at the top-level; this is 476*43c1707eStholo # needed if ${INSTALL} is a relative path (ajusted in each subdirectory 477*43c1707eStholo # by config.status). 478*43c1707eStholo INSTALL_STRIP_PROGRAM='$${INSTALL} -s' 479*43c1707eStholo INSTALL_STRIP_PROGRAM_ENV='' 480*43c1707eStholoelse 481*43c1707eStholo _am_dirpart="`echo $install_sh | sed -e 's,//*[[^/]]*$,,'`" 482*43c1707eStholo INSTALL_STRIP_PROGRAM="\${SHELL} \`CDPATH=: && cd $_am_dirpart && pwd\`/install-sh -c -s" 483*43c1707eStholo INSTALL_STRIP_PROGRAM_ENV="STRIPPROG='\$(STRIP)'" 484*43c1707eStholofi 485*43c1707eStholoAC_SUBST([STRIP]) 486*43c1707eStholoAC_SUBST([INSTALL_STRIP_PROGRAM]) 487*43c1707eStholoAC_SUBST([INSTALL_STRIP_PROGRAM_ENV])]) 488*43c1707eStholo 489*43c1707eStholo#AC_DEFUN([AM_PROG_STRIP], 490*43c1707eStholo#[# Check for `strip', unless the installer 491*43c1707eStholo# has set the STRIP environment variable. 492*43c1707eStholo# Note: don't explicitly check for -z "$STRIP" here because 493*43c1707eStholo# that will cause problems if AC_CANONICAL_* is AC_REQUIREd after 494*43c1707eStholo# this macro, and anyway it doesn't have an effect anyway. 495*43c1707eStholo#AC_CHECK_TOOL([STRIP],[strip]) 496*43c1707eStholo#]) 497*43c1707eStholo 498*43c1707eStholo# 499*43c1707eStholo# Find some information about the etags program 500*43c1707eStholo# 501*43c1707eStholo# Sets 502*43c1707eStholo# ETAGS = path to etags 503*43c1707eStholo# ETAGS_INCLUDE_OPTION = option to pass to etags with arg for includes 504*43c1707eStholo# 505*43c1707eStholo 506*43c1707eStholoAC_DEFUN([AM_PROG_ETAGS], 507*43c1707eStholo[AC_BEFORE([$0], [AM_PROG_ETAGS_WORKS])dnl 508*43c1707eStholoAC_CHECK_PROG(ETAGS, etags, etags) 509*43c1707eStholoif test -z "$ETAGS"; then 510*43c1707eStholo AC_CHECK_PROG(ETAGS, ctags, ctags -e) 511*43c1707eStholofi 512*43c1707eStholoif test -n "$ETAGS"; then 513*43c1707eStholo AM_PROG_ETAGS_WORKS 514*43c1707eStholo if test "$am_cv_prog_etags_works" = yes ; then 515*43c1707eStholo AM_PROG_ETAGS_INCLUDE_OPTION 516*43c1707eStholo else 517*43c1707eStholo AM_MISSING_PROG(ETAGS, etags) 518*43c1707eStholo fi 519*43c1707eStholoelse 520*43c1707eStholo AM_MISSING_PROG(ETAGS, etags) 521*43c1707eStholofi]) 522*43c1707eStholo 523*43c1707eStholo 524*43c1707eStholoAC_DEFUN([AM_PROG_ETAGS_WORKS], 525*43c1707eStholo[AC_CACHE_CHECK([whether ${ETAGS-etags} works], [am_cv_prog_etags_works], 526*43c1707eStholo[cat >conftest.c <<EOF 527*43c1707eStholoint globalvar; 528*43c1707eStholoEOF 529*43c1707eStholoif AC_TRY_COMMAND([${ETAGS-etags} -f - conftest.c |egrep ^int\ globalvar\; >&2]); then 530*43c1707eStholo am_cv_prog_etags_works=yes 531*43c1707eStholoelse 532*43c1707eStholo am_cv_prog_etags_works=no 533*43c1707eStholofi 534*43c1707eStholorm -f conftest.c])]) 535*43c1707eStholo 536*43c1707eStholoAC_DEFUN([AM_PROG_ETAGS_INCLUDE_OPTION], 537*43c1707eStholo[AC_REQUIRE([AM_PROG_ETAGS_WORKS])dnl 538*43c1707eStholoif test "$am_cv_prog_etags_works" = yes ; then 539*43c1707eStholo AC_CACHE_CHECK([for etags include option], 540*43c1707eStholo [am_cv_prog_etags_include_option], 541*43c1707eStholo [cat >conftest.c <<EOF 542*43c1707eStholoint globalvar; 543*43c1707eStholoEOF 544*43c1707eStholo if AC_TRY_COMMAND([${ETAGS-etags} --etags-include=TAGS.inc -f - conftest.c |egrep ^TAGS.inc,include\$ >&2]); then 545*43c1707eStholo am_cv_prog_etags_include_option=--etags-include= 546*43c1707eStholo elif AC_TRY_COMMAND([${ETAGS-etags} -i TAGS.inc -f - conftest.c |egrep ^TAGS.inc,include\$ >&2]); then 547*43c1707eStholo am_cv_prog_etags_include_option='"-i "' 548*43c1707eStholo else : 549*43c1707eStholo # AC_MSG_ERROR(unfamiliar etags implementation) 550*43c1707eStholo fi 551*43c1707eStholo rm -f conftest.c]) 552*43c1707eStholoelse 553*43c1707eStholo : 554*43c1707eStholofi 555*43c1707eStholoETAGS_INCLUDE_OPTION="$am_cv_prog_etags_include_option" 556*43c1707eStholoAC_SUBST(ETAGS_INCLUDE_OPTION)]) 557*43c1707eStholo 558*43c1707eStholo# serial 3 559*43c1707eStholo 560*43c1707eStholo# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 561*43c1707eStholo# written in clear, in which case automake, when reading aclocal.m4, 562*43c1707eStholo# will think it sees a *use*, and therefore will trigger all it's 563*43c1707eStholo# C support machinery. Also note that it means that autoscan, seeing 564*43c1707eStholo# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 565*43c1707eStholo 566*43c1707eStholo# AM_DEPENDENCIES(NAME) 567*43c1707eStholo# --------------------- 568*43c1707eStholo# See how the compiler implements dependency checking. 569*43c1707eStholo# NAME is "CC", "CXX" or "OBJC". 570*43c1707eStholo# We try a few techniques and use that to set a single cache variable. 571*43c1707eStholoAC_DEFUN([AM_DEPENDENCIES], 572*43c1707eStholo[AC_REQUIRE([AM_SET_DEPDIR])dnl 573*43c1707eStholoAC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 574*43c1707eStholoifelse([$1], CC, 575*43c1707eStholo [AC_REQUIRE([AC_PROG_][CC])dnl 576*43c1707eStholoAC_REQUIRE([AC_PROG_][CPP]) 577*43c1707eStholodepcc="$CC" 578*43c1707eStholodepcpp="$CPP"], 579*43c1707eStholo [$1], CXX, [AC_REQUIRE([AC_PROG_][CXX])dnl 580*43c1707eStholoAC_REQUIRE([AC_PROG_][CXXCPP]) 581*43c1707eStholodepcc="$CXX" 582*43c1707eStholodepcpp="$CXXCPP"], 583*43c1707eStholo [$1], OBJC, [am_cv_OBJC_dependencies_compiler_type=gcc], 584*43c1707eStholo [AC_REQUIRE([AC_PROG_][$1])dnl 585*43c1707eStholodepcc="$$1" 586*43c1707eStholodepcpp=""]) 587*43c1707eStholo 588*43c1707eStholoAC_REQUIRE([AM_MAKE_INCLUDE]) 589*43c1707eStholo 590*43c1707eStholoAC_CACHE_CHECK([dependency style of $depcc], 591*43c1707eStholo [am_cv_$1_dependencies_compiler_type], 592*43c1707eStholo[if test -z "$AMDEP"; then 593*43c1707eStholo # We make a subdir and do the tests there. Otherwise we can end up 594*43c1707eStholo # making bogus files that we don't know about and never remove. For 595*43c1707eStholo # instance it was reported that on HP-UX the gcc test will end up 596*43c1707eStholo # making a dummy file named `D' -- because `-MD' means `put the output 597*43c1707eStholo # in D'. 598*43c1707eStholo mkdir confdir 599*43c1707eStholo # Copy depcomp to subdir because otherwise we won't find it if we're 600*43c1707eStholo # using a relative directory. 601*43c1707eStholo cp "$am_depcomp" confdir 602*43c1707eStholo cd confdir 603*43c1707eStholo 604*43c1707eStholo am_cv_$1_dependencies_compiler_type=none 605*43c1707eStholo for depmode in `sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < "./depcomp"`; do 606*43c1707eStholo # We need to recreate these files for each test, as the compiler may 607*43c1707eStholo # overwrite some of them when testing with obscure command lines. 608*43c1707eStholo # This happens at least with the AIX C compiler. 609*43c1707eStholo echo '#include "conftest.h"' > conftest.c 610*43c1707eStholo echo 'int i;' > conftest.h 611*43c1707eStholo 612*43c1707eStholo case "$depmode" in 613*43c1707eStholo nosideeffect) 614*43c1707eStholo # after this tag, mechanisms are not by side-effect, so they'll 615*43c1707eStholo # only be used when explicitly requested 616*43c1707eStholo if test "x$enable_dependency_tracking" = xyes; then 617*43c1707eStholo continue 618*43c1707eStholo else 619*43c1707eStholo break 620*43c1707eStholo fi 621*43c1707eStholo ;; 622*43c1707eStholo none) break ;; 623*43c1707eStholo esac 624*43c1707eStholo # We check with `-c' and `-o' for the sake of the "dashmstdout" 625*43c1707eStholo # mode. It turns out that the SunPro C++ compiler does not properly 626*43c1707eStholo # handle `-M -o', and we need to detect this. 627*43c1707eStholo if depmode="$depmode" \ 628*43c1707eStholo source=conftest.c object=conftest.o \ 629*43c1707eStholo depfile=conftest.Po tmpdepfile=conftest.TPo \ 630*43c1707eStholo $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 && 631*43c1707eStholo grep conftest.h conftest.Po > /dev/null 2>&1; then 632*43c1707eStholo am_cv_$1_dependencies_compiler_type="$depmode" 633*43c1707eStholo break 634*43c1707eStholo fi 635*43c1707eStholo done 636*43c1707eStholo 637*43c1707eStholo cd .. 638*43c1707eStholo rm -rf confdir 639*43c1707eStholoelse 640*43c1707eStholo am_cv_$1_dependencies_compiler_type=none 641*43c1707eStholofi 642*43c1707eStholo]) 643*43c1707eStholo$1DEPMODE="depmode=$am_cv_$1_dependencies_compiler_type" 644*43c1707eStholoAC_SUBST([$1DEPMODE]) 645*43c1707eStholo]) 646*43c1707eStholo 647*43c1707eStholo 648*43c1707eStholo# AM_SET_DEPDIR 649*43c1707eStholo# ------------- 650*43c1707eStholo# Choose a directory name for dependency files. 651*43c1707eStholo# This macro is AC_REQUIREd in AM_DEPENDENCIES 652*43c1707eStholoAC_DEFUN([AM_SET_DEPDIR], 653*43c1707eStholo[if test -d .deps || mkdir .deps 2> /dev/null || test -d .deps; then 654*43c1707eStholo DEPDIR=.deps 655*43c1707eStholo # We redirect because .deps might already exist and be populated. 656*43c1707eStholo # In this situation we don't want to see an error. 657*43c1707eStholo rmdir .deps > /dev/null 2>&1 658*43c1707eStholoelse 659*43c1707eStholo DEPDIR=_deps 660*43c1707eStholofi 661*43c1707eStholoAC_SUBST(DEPDIR) 662*43c1707eStholo]) 663*43c1707eStholo 664*43c1707eStholo 665*43c1707eStholo# AM_DEP_TRACK 666*43c1707eStholo# ------------ 667*43c1707eStholoAC_DEFUN([AM_DEP_TRACK], 668*43c1707eStholo[AC_ARG_ENABLE(dependency-tracking, 669*43c1707eStholo[ --disable-dependency-tracking Speeds up one-time builds 670*43c1707eStholo --enable-dependency-tracking Do not reject slow dependency extractors]) 671*43c1707eStholoif test "x$enable_dependency_tracking" != xno; then 672*43c1707eStholo am_depcomp="$ac_aux_dir/depcomp" 673*43c1707eStholo AMDEPBACKSLASH='\' 674*43c1707eStholofi 675*43c1707eStholoAM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 676*43c1707eStholopushdef([subst], defn([AC_SUBST])) 677*43c1707eStholosubst(AMDEPBACKSLASH) 678*43c1707eStholopopdef([subst]) 679*43c1707eStholo]) 680*43c1707eStholo 681*43c1707eStholo# Generate code to set up dependency tracking. 682*43c1707eStholo# This macro should only be invoked once -- use via AC_REQUIRE. 683*43c1707eStholo# Usage: 684*43c1707eStholo# AM_OUTPUT_DEPENDENCY_COMMANDS 685*43c1707eStholo 686*43c1707eStholo# 687*43c1707eStholo# This code is only required when automatic dependency tracking 688*43c1707eStholo# is enabled. FIXME. This creates each `.P' file that we will 689*43c1707eStholo# need in order to bootstrap the dependency handling code. 690*43c1707eStholoAC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],[ 691*43c1707eStholoAC_OUTPUT_COMMANDS([ 692*43c1707eStholotest x"$AMDEP" != x"" || 693*43c1707eStholofor mf in $CONFIG_FILES; do 694*43c1707eStholo case "$mf" in 695*43c1707eStholo Makefile) dirpart=.;; 696*43c1707eStholo */Makefile) dirpart=`echo "$mf" | sed -e 's|/[^/]*$||'`;; 697*43c1707eStholo *) continue;; 698*43c1707eStholo esac 699*43c1707eStholo grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue 700*43c1707eStholo # Extract the definition of DEP_FILES from the Makefile without 701*43c1707eStholo # running `make'. 702*43c1707eStholo DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"` 703*43c1707eStholo test -z "$DEPDIR" && continue 704*43c1707eStholo # When using ansi2knr, U may be empty or an underscore; expand it 705*43c1707eStholo U=`sed -n -e '/^U = / s///p' < "$mf"` 706*43c1707eStholo test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR" 707*43c1707eStholo # We invoke sed twice because it is the simplest approach to 708*43c1707eStholo # changing $(DEPDIR) to its actual value in the expansion. 709*43c1707eStholo for file in `sed -n -e ' 710*43c1707eStholo /^DEP_FILES = .*\\\\$/ { 711*43c1707eStholo s/^DEP_FILES = // 712*43c1707eStholo :loop 713*43c1707eStholo s/\\\\$// 714*43c1707eStholo p 715*43c1707eStholo n 716*43c1707eStholo /\\\\$/ b loop 717*43c1707eStholo p 718*43c1707eStholo } 719*43c1707eStholo /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \ 720*43c1707eStholo sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 721*43c1707eStholo # Make sure the directory exists. 722*43c1707eStholo test -f "$dirpart/$file" && continue 723*43c1707eStholo fdir=`echo "$file" | sed -e 's|/[^/]*$||'` 724*43c1707eStholo $ac_aux_dir/mkinstalldirs "$dirpart/$fdir" > /dev/null 2>&1 725*43c1707eStholo # echo "creating $dirpart/$file" 726*43c1707eStholo echo '# dummy' > "$dirpart/$file" 727*43c1707eStholo done 728*43c1707eStholodone 729*43c1707eStholo], [AMDEP="$AMDEP" 730*43c1707eStholoac_aux_dir="$ac_aux_dir"])]) 731*43c1707eStholo 732*43c1707eStholo# AM_MAKE_INCLUDE() 733*43c1707eStholo# ----------------- 734*43c1707eStholo# Check to see how make treats includes. 735*43c1707eStholoAC_DEFUN([AM_MAKE_INCLUDE], 736*43c1707eStholo[am_make=${MAKE-make} 737*43c1707eStholocat > confinc << 'END' 738*43c1707eStholodoit: 739*43c1707eStholo @echo done 740*43c1707eStholoEND 741*43c1707eStholo# If we don't find an include directive, just comment out the code. 742*43c1707eStholoAC_MSG_CHECKING([for style of include used by $am_make]) 743*43c1707eStholo_am_include='#' 744*43c1707eStholo_am_quote= 745*43c1707eStholo_am_result=none 746*43c1707eStholo# First try GNU make style include. 747*43c1707eStholoecho "include confinc" > confmf 748*43c1707eStholoif test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then 749*43c1707eStholo _am_include=include 750*43c1707eStholo _am_quote= 751*43c1707eStholo _am_result=GNU 752*43c1707eStholofi 753*43c1707eStholo# Now try BSD make style include. 754*43c1707eStholoif test "$_am_include" = "#"; then 755*43c1707eStholo echo '.include "confinc"' > confmf 756*43c1707eStholo if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then 757*43c1707eStholo _am_include=.include 758*43c1707eStholo _am_quote='"' 759*43c1707eStholo _am_result=BSD 760*43c1707eStholo fi 761*43c1707eStholofi 762*43c1707eStholoAC_SUBST(_am_include) 763*43c1707eStholoAC_SUBST(_am_quote) 764*43c1707eStholoAC_MSG_RESULT($_am_result) 765*43c1707eStholorm -f confinc confmf 766*43c1707eStholo]) 767*43c1707eStholo 768*43c1707eStholo# serial 3 769*43c1707eStholo 770*43c1707eStholo# AM_CONDITIONAL(NAME, SHELL-CONDITION) 771*43c1707eStholo# ------------------------------------- 772*43c1707eStholo# Define a conditional. 773*43c1707eStholo# 774*43c1707eStholo# FIXME: Once using 2.50, use this: 775*43c1707eStholo# m4_match([$1], [^TRUE\|FALSE$], [AC_FATAL([$0: invalid condition: $1])])dnl 776*43c1707eStholoAC_DEFUN([AM_CONDITIONAL], 777*43c1707eStholo[ifelse([$1], [TRUE], 778*43c1707eStholo [errprint(__file__:__line__: [$0: invalid condition: $1 779*43c1707eStholo])dnl 780*43c1707eStholom4exit(1)])dnl 781*43c1707eStholoifelse([$1], [FALSE], 782*43c1707eStholo [errprint(__file__:__line__: [$0: invalid condition: $1 783*43c1707eStholo])dnl 784*43c1707eStholom4exit(1)])dnl 785*43c1707eStholoAC_SUBST([$1_TRUE]) 786*43c1707eStholoAC_SUBST([$1_FALSE]) 787*43c1707eStholoif $2; then 788*43c1707eStholo $1_TRUE= 789*43c1707eStholo $1_FALSE='#' 790*43c1707eStholoelse 791*43c1707eStholo $1_TRUE='#' 792*43c1707eStholo $1_FALSE= 793*43c1707eStholofi]) 794*43c1707eStholo 795*43c1707eStholo# Like AC_CONFIG_HEADER, but automatically create stamp file. 796*43c1707eStholo 797*43c1707eStholo# serial 3 798*43c1707eStholo 799*43c1707eStholo# When config.status generates a header, we must update the stamp-h file. 800*43c1707eStholo# This file resides in the same directory as the config header 801*43c1707eStholo# that is generated. We must strip everything past the first ":", 802*43c1707eStholo# and everything past the last "/". 803*43c1707eStholo 804*43c1707eStholoAC_PREREQ([2.12]) 805*43c1707eStholo 806*43c1707eStholoAC_DEFUN([AM_CONFIG_HEADER], 807*43c1707eStholo[ifdef([AC_FOREACH],dnl 808*43c1707eStholo [dnl init our file count if it isn't already 809*43c1707eStholo m4_ifndef([_AM_Config_Header_Index], m4_define([_AM_Config_Header_Index], [0])) 810*43c1707eStholo dnl prepare to store our destination file list for use in config.status 811*43c1707eStholo AC_FOREACH([_AM_File], [$1], 812*43c1707eStholo [m4_pushdef([_AM_Dest], m4_patsubst(_AM_File, [:.*])) 813*43c1707eStholo m4_define([_AM_Config_Header_Index], m4_incr(_AM_Config_Header_Index)) 814*43c1707eStholo dnl and add it to the list of files AC keeps track of, along 815*43c1707eStholo dnl with our hook 816*43c1707eStholo AC_CONFIG_HEADERS(_AM_File, 817*43c1707eStholodnl COMMANDS, [, INIT-CMDS] 818*43c1707eStholo[# update the timestamp 819*43c1707eStholoecho timestamp >"AS_ESCAPE(_AM_DIRNAME(]_AM_Dest[))/stamp-h]_AM_Config_Header_Index[" 820*43c1707eStholo][$2]m4_ifval([$3], [, [$3]]))dnl AC_CONFIG_HEADERS 821*43c1707eStholo m4_popdef([_AM_Dest])])],dnl 822*43c1707eStholo[AC_CONFIG_HEADER([$1]) 823*43c1707eStholo AC_OUTPUT_COMMANDS( 824*43c1707eStholo ifelse(patsubst([$1], [[^ ]], []), 825*43c1707eStholo [], 826*43c1707eStholo [test -z "$CONFIG_HEADERS" || echo timestamp >dnl 827*43c1707eStholo patsubst([$1], [^\([^:]*/\)?.*], [\1])stamp-h]),dnl 828*43c1707eStholo[am_indx=1 829*43c1707eStholofor am_file in $1; do 830*43c1707eStholo case " \$CONFIG_HEADERS " in 831*43c1707eStholo *" \$am_file "*) 832*43c1707eStholo am_dir=\`echo \$am_file |sed 's%:.*%%;s%[^/]*\$%%'\` 833*43c1707eStholo if test -n "\$am_dir"; then 834*43c1707eStholo am_tmpdir=\`echo \$am_dir |sed 's%^\(/*\).*\$%\1%'\` 835*43c1707eStholo for am_subdir in \`echo \$am_dir |sed 's%/% %'\`; do 836*43c1707eStholo am_tmpdir=\$am_tmpdir\$am_subdir/ 837*43c1707eStholo if test ! -d \$am_tmpdir; then 838*43c1707eStholo mkdir \$am_tmpdir 839*43c1707eStholo fi 840*43c1707eStholo done 841*43c1707eStholo fi 842*43c1707eStholo echo timestamp > "\$am_dir"stamp-h\$am_indx 843*43c1707eStholo ;; 844*43c1707eStholo esac 845*43c1707eStholo am_indx=\`expr \$am_indx + 1\` 846*43c1707eStholodone]) 847*43c1707eStholo])]) # AM_CONFIG_HEADER 848*43c1707eStholo 849*43c1707eStholo# _AM_DIRNAME(PATH) 850*43c1707eStholo# ----------------- 851*43c1707eStholo# Like AS_DIRNAME, only do it during macro expansion 852*43c1707eStholoAC_DEFUN([_AM_DIRNAME], 853*43c1707eStholo [m4_if(m4_regexp([$1], [^.*[^/]//*[^/][^/]*/*$]), -1, 854*43c1707eStholo m4_if(m4_regexp([$1], [^//\([^/]\|$\)]), -1, 855*43c1707eStholo m4_if(m4_regexp([$1], [^/.*]), -1, 856*43c1707eStholo [.], 857*43c1707eStholo m4_patsubst([$1], [^\(/\).*], [\1])), 858*43c1707eStholo m4_patsubst([$1], [^\(//\)\([^/].*\|$\)], [\1])), 859*43c1707eStholo m4_patsubst([$1], [^\(.*[^/]\)//*[^/][^/]*/*$], [\1]))[]dnl 860*43c1707eStholo]) # _AM_DIRNAME 861*43c1707eStholo 862