1# generated automatically by aclocal 1.7.3 -*- Autoconf -*-
2
3# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002
4# Free Software Foundation, Inc.
5# This file is free software; the Free Software Foundation
6# gives unlimited permission to copy and/or distribute it,
7# with or without modifications, as long as this notice is preserved.
8
9# This program is distributed in the hope that it will be useful,
10# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12# PARTICULAR PURPOSE.
13
14# Do all the work for Automake.                            -*- Autoconf -*-
15
16# This macro actually does too much some checks are only needed if
17# your package does certain things.  But this isn't really a big deal.
18
19# Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
20# Free Software Foundation, Inc.
21
22# This program is free software; you can redistribute it and/or modify
23# it under the terms of the GNU General Public License as published by
24# the Free Software Foundation; either version 2, or (at your option)
25# any later version.
26
27# This program is distributed in the hope that it will be useful,
28# but WITHOUT ANY WARRANTY; without even the implied warranty of
29# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
30# GNU General Public License for more details.
31
32# You should have received a copy of the GNU General Public License
33# along with this program; if not, write to the Free Software
34# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
35# 02111-1307, USA.
36
37# serial 9
38
39# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
40# written in clear, in which case automake, when reading aclocal.m4,
41# will think it sees a *use*, and therefore will trigger all it's
42# C support machinery.  Also note that it means that autoscan, seeing
43# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
44
45
46AC_PREREQ([2.54])
47
48# Autoconf 2.50 wants to disallow AM_ names.  We explicitly allow
49# the ones we care about.
50m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
51
52# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
53# AM_INIT_AUTOMAKE([OPTIONS])
54# -----------------------------------------------
55# The call with PACKAGE and VERSION arguments is the old style
56# call (pre autoconf-2.50), which is being phased out.  PACKAGE
57# and VERSION should now be passed to AC_INIT and removed from
58# the call to AM_INIT_AUTOMAKE.
59# We support both call styles for the transition.  After
60# the next Automake release, Autoconf can make the AC_INIT
61# arguments mandatory, and then we can depend on a new Autoconf
62# release and drop the old call support.
63AC_DEFUN([AM_INIT_AUTOMAKE],
64[AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
65 AC_REQUIRE([AC_PROG_INSTALL])dnl
66# test to see if srcdir already configured
67if test "`cd $srcdir && pwd`" != "`pwd`" &&
68   test -f $srcdir/config.status; then
69  AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
70fi
71
72# test whether we have cygpath
73if test -z "$CYGPATH_W"; then
74  if (cygpath --version) >/dev/null 2>/dev/null; then
75    CYGPATH_W='cygpath -w'
76  else
77    CYGPATH_W=echo
78  fi
79fi
80AC_SUBST([CYGPATH_W])
81
82# Define the identity of the package.
83dnl Distinguish between old-style and new-style calls.
84m4_ifval([$2],
85[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
86 AC_SUBST([PACKAGE], [$1])dnl
87 AC_SUBST([VERSION], [$2])],
88[_AM_SET_OPTIONS([$1])dnl
89 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
90 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
91
92_AM_IF_OPTION([no-define],,
93[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
94 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
95
96# Some tools Automake needs.
97AC_REQUIRE([AM_SANITY_CHECK])dnl
98AC_REQUIRE([AC_ARG_PROGRAM])dnl
99AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
100AM_MISSING_PROG(AUTOCONF, autoconf)
101AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
102AM_MISSING_PROG(AUTOHEADER, autoheader)
103AM_MISSING_PROG(MAKEINFO, makeinfo)
104AM_MISSING_PROG(AMTAR, tar)
105AM_PROG_INSTALL_SH
106AM_PROG_INSTALL_STRIP
107# We need awk for the "check" target.  The system "awk" is bad on
108# some platforms.
109AC_REQUIRE([AC_PROG_AWK])dnl
110AC_REQUIRE([AC_PROG_MAKE_SET])dnl
111AC_REQUIRE([AM_SET_LEADING_DOT])dnl
112
113_AM_IF_OPTION([no-dependencies],,
114[AC_PROVIDE_IFELSE([AC_PROG_CC],
115                  [_AM_DEPENDENCIES(CC)],
116                  [define([AC_PROG_CC],
117                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
118AC_PROVIDE_IFELSE([AC_PROG_CXX],
119                  [_AM_DEPENDENCIES(CXX)],
120                  [define([AC_PROG_CXX],
121                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
122])
123])
124
125
126# When config.status generates a header, we must update the stamp-h file.
127# This file resides in the same directory as the config header
128# that is generated.  The stamp files are numbered to have different names.
129
130# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
131# loop where config.status creates the headers, so we can generate
132# our stamp files there.
133AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
134[# Compute $1's index in $config_headers.
135_am_stamp_count=1
136for _am_header in $config_headers :; do
137  case $_am_header in
138    $1 | $1:* )
139      break ;;
140    * )
141      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
142  esac
143done
144echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
145
146# Copyright 2002  Free Software Foundation, Inc.
147
148# This program is free software; you can redistribute it and/or modify
149# it under the terms of the GNU General Public License as published by
150# the Free Software Foundation; either version 2, or (at your option)
151# any later version.
152
153# This program is distributed in the hope that it will be useful,
154# but WITHOUT ANY WARRANTY; without even the implied warranty of
155# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
156# GNU General Public License for more details.
157
158# You should have received a copy of the GNU General Public License
159# along with this program; if not, write to the Free Software
160# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
161
162# AM_AUTOMAKE_VERSION(VERSION)
163# ----------------------------
164# Automake X.Y traces this macro to ensure aclocal.m4 has been
165# generated from the m4 files accompanying Automake X.Y.
166AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.7"])
167
168# AM_SET_CURRENT_AUTOMAKE_VERSION
169# -------------------------------
170# Call AM_AUTOMAKE_VERSION so it can be traced.
171# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
172AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
173	 [AM_AUTOMAKE_VERSION([1.7.3])])
174
175# Helper functions for option handling.                    -*- Autoconf -*-
176
177# Copyright 2001, 2002  Free Software Foundation, Inc.
178
179# This program is free software; you can redistribute it and/or modify
180# it under the terms of the GNU General Public License as published by
181# the Free Software Foundation; either version 2, or (at your option)
182# any later version.
183
184# This program is distributed in the hope that it will be useful,
185# but WITHOUT ANY WARRANTY; without even the implied warranty of
186# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
187# GNU General Public License for more details.
188
189# You should have received a copy of the GNU General Public License
190# along with this program; if not, write to the Free Software
191# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
192# 02111-1307, USA.
193
194# serial 2
195
196# _AM_MANGLE_OPTION(NAME)
197# -----------------------
198AC_DEFUN([_AM_MANGLE_OPTION],
199[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
200
201# _AM_SET_OPTION(NAME)
202# ------------------------------
203# Set option NAME.  Presently that only means defining a flag for this option.
204AC_DEFUN([_AM_SET_OPTION],
205[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
206
207# _AM_SET_OPTIONS(OPTIONS)
208# ----------------------------------
209# OPTIONS is a space-separated list of Automake options.
210AC_DEFUN([_AM_SET_OPTIONS],
211[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
212
213# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
214# -------------------------------------------
215# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
216AC_DEFUN([_AM_IF_OPTION],
217[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
218
219#
220# Check to make sure that the build environment is sane.
221#
222
223# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
224
225# This program is free software; you can redistribute it and/or modify
226# it under the terms of the GNU General Public License as published by
227# the Free Software Foundation; either version 2, or (at your option)
228# any later version.
229
230# This program is distributed in the hope that it will be useful,
231# but WITHOUT ANY WARRANTY; without even the implied warranty of
232# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
233# GNU General Public License for more details.
234
235# You should have received a copy of the GNU General Public License
236# along with this program; if not, write to the Free Software
237# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
238# 02111-1307, USA.
239
240# serial 3
241
242# AM_SANITY_CHECK
243# ---------------
244AC_DEFUN([AM_SANITY_CHECK],
245[AC_MSG_CHECKING([whether build environment is sane])
246# Just in case
247sleep 1
248echo timestamp > conftest.file
249# Do `set' in a subshell so we don't clobber the current shell's
250# arguments.  Must try -L first in case configure is actually a
251# symlink; some systems play weird games with the mod time of symlinks
252# (eg FreeBSD returns the mod time of the symlink's containing
253# directory).
254if (
255   set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
256   if test "$[*]" = "X"; then
257      # -L didn't work.
258      set X `ls -t $srcdir/configure conftest.file`
259   fi
260   rm -f conftest.file
261   if test "$[*]" != "X $srcdir/configure conftest.file" \
262      && test "$[*]" != "X conftest.file $srcdir/configure"; then
263
264      # If neither matched, then we have a broken ls.  This can happen
265      # if, for instance, CONFIG_SHELL is bash and it inherits a
266      # broken ls alias from the environment.  This has actually
267      # happened.  Such a system could not be considered "sane".
268      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
269alias in your environment])
270   fi
271
272   test "$[2]" = conftest.file
273   )
274then
275   # Ok.
276   :
277else
278   AC_MSG_ERROR([newly created file is older than distributed files!
279Check your system clock])
280fi
281AC_MSG_RESULT(yes)])
282
283#  -*- Autoconf -*-
284
285
286# Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
287
288# This program is free software; you can redistribute it and/or modify
289# it under the terms of the GNU General Public License as published by
290# the Free Software Foundation; either version 2, or (at your option)
291# any later version.
292
293# This program is distributed in the hope that it will be useful,
294# but WITHOUT ANY WARRANTY; without even the implied warranty of
295# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
296# GNU General Public License for more details.
297
298# You should have received a copy of the GNU General Public License
299# along with this program; if not, write to the Free Software
300# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
301# 02111-1307, USA.
302
303# serial 3
304
305# AM_MISSING_PROG(NAME, PROGRAM)
306# ------------------------------
307AC_DEFUN([AM_MISSING_PROG],
308[AC_REQUIRE([AM_MISSING_HAS_RUN])
309$1=${$1-"${am_missing_run}$2"}
310AC_SUBST($1)])
311
312
313# AM_MISSING_HAS_RUN
314# ------------------
315# Define MISSING if not defined so far and test if it supports --run.
316# If it does, set am_missing_run to use it, otherwise, to nothing.
317AC_DEFUN([AM_MISSING_HAS_RUN],
318[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
319test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
320# Use eval to expand $SHELL
321if eval "$MISSING --run true"; then
322  am_missing_run="$MISSING --run "
323else
324  am_missing_run=
325  AC_MSG_WARN([`missing' script is too old or missing])
326fi
327])
328
329# AM_AUX_DIR_EXPAND
330
331# Copyright 2001 Free Software Foundation, Inc.
332
333# This program is free software; you can redistribute it and/or modify
334# it under the terms of the GNU General Public License as published by
335# the Free Software Foundation; either version 2, or (at your option)
336# any later version.
337
338# This program is distributed in the hope that it will be useful,
339# but WITHOUT ANY WARRANTY; without even the implied warranty of
340# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
341# GNU General Public License for more details.
342
343# You should have received a copy of the GNU General Public License
344# along with this program; if not, write to the Free Software
345# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
346# 02111-1307, USA.
347
348# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
349# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
350# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
351#
352# Of course, Automake must honor this variable whenever it calls a
353# tool from the auxiliary directory.  The problem is that $srcdir (and
354# therefore $ac_aux_dir as well) can be either absolute or relative,
355# depending on how configure is run.  This is pretty annoying, since
356# it makes $ac_aux_dir quite unusable in subdirectories: in the top
357# source directory, any form will work fine, but in subdirectories a
358# relative path needs to be adjusted first.
359#
360# $ac_aux_dir/missing
361#    fails when called from a subdirectory if $ac_aux_dir is relative
362# $top_srcdir/$ac_aux_dir/missing
363#    fails if $ac_aux_dir is absolute,
364#    fails when called from a subdirectory in a VPATH build with
365#          a relative $ac_aux_dir
366#
367# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
368# are both prefixed by $srcdir.  In an in-source build this is usually
369# harmless because $srcdir is `.', but things will broke when you
370# start a VPATH build or use an absolute $srcdir.
371#
372# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
373# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
374#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
375# and then we would define $MISSING as
376#   MISSING="\${SHELL} $am_aux_dir/missing"
377# This will work as long as MISSING is not called from configure, because
378# unfortunately $(top_srcdir) has no meaning in configure.
379# However there are other variables, like CC, which are often used in
380# configure, and could therefore not use this "fixed" $ac_aux_dir.
381#
382# Another solution, used here, is to always expand $ac_aux_dir to an
383# absolute PATH.  The drawback is that using absolute paths prevent a
384# configured tree to be moved without reconfiguration.
385
386# Rely on autoconf to set up CDPATH properly.
387AC_PREREQ([2.50])
388
389AC_DEFUN([AM_AUX_DIR_EXPAND], [
390# expand $ac_aux_dir to an absolute path
391am_aux_dir=`cd $ac_aux_dir && pwd`
392])
393
394# AM_PROG_INSTALL_SH
395# ------------------
396# Define $install_sh.
397
398# Copyright 2001 Free Software Foundation, Inc.
399
400# This program is free software; you can redistribute it and/or modify
401# it under the terms of the GNU General Public License as published by
402# the Free Software Foundation; either version 2, or (at your option)
403# any later version.
404
405# This program is distributed in the hope that it will be useful,
406# but WITHOUT ANY WARRANTY; without even the implied warranty of
407# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
408# GNU General Public License for more details.
409
410# You should have received a copy of the GNU General Public License
411# along with this program; if not, write to the Free Software
412# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
413# 02111-1307, USA.
414
415AC_DEFUN([AM_PROG_INSTALL_SH],
416[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
417install_sh=${install_sh-"$am_aux_dir/install-sh"}
418AC_SUBST(install_sh)])
419
420# AM_PROG_INSTALL_STRIP
421
422# Copyright 2001 Free Software Foundation, Inc.
423
424# This program is free software; you can redistribute it and/or modify
425# it under the terms of the GNU General Public License as published by
426# the Free Software Foundation; either version 2, or (at your option)
427# any later version.
428
429# This program is distributed in the hope that it will be useful,
430# but WITHOUT ANY WARRANTY; without even the implied warranty of
431# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
432# GNU General Public License for more details.
433
434# You should have received a copy of the GNU General Public License
435# along with this program; if not, write to the Free Software
436# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
437# 02111-1307, USA.
438
439# One issue with vendor `install' (even GNU) is that you can't
440# specify the program used to strip binaries.  This is especially
441# annoying in cross-compiling environments, where the build's strip
442# is unlikely to handle the host's binaries.
443# Fortunately install-sh will honor a STRIPPROG variable, so we
444# always use install-sh in `make install-strip', and initialize
445# STRIPPROG with the value of the STRIP variable (set by the user).
446AC_DEFUN([AM_PROG_INSTALL_STRIP],
447[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
448# Installed binaries are usually stripped using `strip' when the user
449# run `make install-strip'.  However `strip' might not be the right
450# tool to use in cross-compilation environments, therefore Automake
451# will honor the `STRIP' environment variable to overrule this program.
452dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
453if test "$cross_compiling" != no; then
454  AC_CHECK_TOOL([STRIP], [strip], :)
455fi
456INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
457AC_SUBST([INSTALL_STRIP_PROGRAM])])
458
459#                                                          -*- Autoconf -*-
460# Copyright (C) 2003  Free Software Foundation, Inc.
461
462# This program is free software; you can redistribute it and/or modify
463# it under the terms of the GNU General Public License as published by
464# the Free Software Foundation; either version 2, or (at your option)
465# any later version.
466
467# This program is distributed in the hope that it will be useful,
468# but WITHOUT ANY WARRANTY; without even the implied warranty of
469# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
470# GNU General Public License for more details.
471
472# You should have received a copy of the GNU General Public License
473# along with this program; if not, write to the Free Software
474# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
475# 02111-1307, USA.
476
477# serial 1
478
479# Check whether the underlying file-system supports filenames
480# with a leading dot.  For instance MS-DOS doesn't.
481AC_DEFUN([AM_SET_LEADING_DOT],
482[rm -rf .tst 2>/dev/null
483mkdir .tst 2>/dev/null
484if test -d .tst; then
485  am__leading_dot=.
486else
487  am__leading_dot=_
488fi
489rmdir .tst 2>/dev/null
490AC_SUBST([am__leading_dot])])
491
492# serial 5						-*- Autoconf -*-
493
494# Copyright (C) 1999, 2000, 2001, 2002, 2003  Free Software Foundation, Inc.
495
496# This program is free software; you can redistribute it and/or modify
497# it under the terms of the GNU General Public License as published by
498# the Free Software Foundation; either version 2, or (at your option)
499# any later version.
500
501# This program is distributed in the hope that it will be useful,
502# but WITHOUT ANY WARRANTY; without even the implied warranty of
503# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
504# GNU General Public License for more details.
505
506# You should have received a copy of the GNU General Public License
507# along with this program; if not, write to the Free Software
508# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
509# 02111-1307, USA.
510
511
512# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
513# written in clear, in which case automake, when reading aclocal.m4,
514# will think it sees a *use*, and therefore will trigger all it's
515# C support machinery.  Also note that it means that autoscan, seeing
516# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
517
518
519
520# _AM_DEPENDENCIES(NAME)
521# ----------------------
522# See how the compiler implements dependency checking.
523# NAME is "CC", "CXX", "GCJ", or "OBJC".
524# We try a few techniques and use that to set a single cache variable.
525#
526# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
527# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
528# dependency, and given that the user is not expected to run this macro,
529# just rely on AC_PROG_CC.
530AC_DEFUN([_AM_DEPENDENCIES],
531[AC_REQUIRE([AM_SET_DEPDIR])dnl
532AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
533AC_REQUIRE([AM_MAKE_INCLUDE])dnl
534AC_REQUIRE([AM_DEP_TRACK])dnl
535
536ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
537       [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
538       [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
539       [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
540                   [depcc="$$1"   am_compiler_list=])
541
542AC_CACHE_CHECK([dependency style of $depcc],
543               [am_cv_$1_dependencies_compiler_type],
544[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
545  # We make a subdir and do the tests there.  Otherwise we can end up
546  # making bogus files that we don't know about and never remove.  For
547  # instance it was reported that on HP-UX the gcc test will end up
548  # making a dummy file named `D' -- because `-MD' means `put the output
549  # in D'.
550  mkdir conftest.dir
551  # Copy depcomp to subdir because otherwise we won't find it if we're
552  # using a relative directory.
553  cp "$am_depcomp" conftest.dir
554  cd conftest.dir
555
556  am_cv_$1_dependencies_compiler_type=none
557  if test "$am_compiler_list" = ""; then
558     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
559  fi
560  for depmode in $am_compiler_list; do
561    # We need to recreate these files for each test, as the compiler may
562    # overwrite some of them when testing with obscure command lines.
563    # This happens at least with the AIX C compiler.
564    echo '#include "conftest.h"' > conftest.c
565    echo 'int i;' > conftest.h
566    echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf
567
568    case $depmode in
569    nosideeffect)
570      # after this tag, mechanisms are not by side-effect, so they'll
571      # only be used when explicitly requested
572      if test "x$enable_dependency_tracking" = xyes; then
573	continue
574      else
575	break
576      fi
577      ;;
578    none) break ;;
579    esac
580    # We check with `-c' and `-o' for the sake of the "dashmstdout"
581    # mode.  It turns out that the SunPro C++ compiler does not properly
582    # handle `-M -o', and we need to detect this.
583    if depmode=$depmode \
584       source=conftest.c object=conftest.o \
585       depfile=conftest.Po tmpdepfile=conftest.TPo \
586       $SHELL ./depcomp $depcc -c -o conftest.o conftest.c \
587         >/dev/null 2>conftest.err &&
588       grep conftest.h conftest.Po > /dev/null 2>&1 &&
589       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
590      # icc doesn't choke on unknown options, it will just issue warnings
591      # (even with -Werror).  So we grep stderr for any message
592      # that says an option was ignored.
593      if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
594        am_cv_$1_dependencies_compiler_type=$depmode
595        break
596      fi
597    fi
598  done
599
600  cd ..
601  rm -rf conftest.dir
602else
603  am_cv_$1_dependencies_compiler_type=none
604fi
605])
606AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
607AM_CONDITIONAL([am__fastdep$1], [
608  test "x$enable_dependency_tracking" != xno \
609  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
610])
611
612
613# AM_SET_DEPDIR
614# -------------
615# Choose a directory name for dependency files.
616# This macro is AC_REQUIREd in _AM_DEPENDENCIES
617AC_DEFUN([AM_SET_DEPDIR],
618[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
619AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
620])
621
622
623# AM_DEP_TRACK
624# ------------
625AC_DEFUN([AM_DEP_TRACK],
626[AC_ARG_ENABLE(dependency-tracking,
627[  --disable-dependency-tracking Speeds up one-time builds
628  --enable-dependency-tracking  Do not reject slow dependency extractors])
629if test "x$enable_dependency_tracking" != xno; then
630  am_depcomp="$ac_aux_dir/depcomp"
631  AMDEPBACKSLASH='\'
632fi
633AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
634AC_SUBST([AMDEPBACKSLASH])
635])
636
637# Generate code to set up dependency tracking.   -*- Autoconf -*-
638
639# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
640
641# This program is free software; you can redistribute it and/or modify
642# it under the terms of the GNU General Public License as published by
643# the Free Software Foundation; either version 2, or (at your option)
644# any later version.
645
646# This program is distributed in the hope that it will be useful,
647# but WITHOUT ANY WARRANTY; without even the implied warranty of
648# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
649# GNU General Public License for more details.
650
651# You should have received a copy of the GNU General Public License
652# along with this program; if not, write to the Free Software
653# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
654# 02111-1307, USA.
655
656#serial 2
657
658# _AM_OUTPUT_DEPENDENCY_COMMANDS
659# ------------------------------
660AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
661[for mf in $CONFIG_FILES; do
662  # Strip MF so we end up with the name of the file.
663  mf=`echo "$mf" | sed -e 's/:.*$//'`
664  # Check whether this is an Automake generated Makefile or not.
665  # We used to match only the files named `Makefile.in', but
666  # some people rename them; so instead we look at the file content.
667  # Grep'ing the first line is not enough: some people post-process
668  # each Makefile.in and add a new line on top of each file to say so.
669  # So let's grep whole file.
670  if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
671    dirpart=`AS_DIRNAME("$mf")`
672  else
673    continue
674  fi
675  grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
676  # Extract the definition of DEP_FILES from the Makefile without
677  # running `make'.
678  DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
679  test -z "$DEPDIR" && continue
680  # When using ansi2knr, U may be empty or an underscore; expand it
681  U=`sed -n -e '/^U = / s///p' < "$mf"`
682  test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
683  # We invoke sed twice because it is the simplest approach to
684  # changing $(DEPDIR) to its actual value in the expansion.
685  for file in `sed -n -e '
686    /^DEP_FILES = .*\\\\$/ {
687      s/^DEP_FILES = //
688      :loop
689	s/\\\\$//
690	p
691	n
692	/\\\\$/ b loop
693      p
694    }
695    /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
696       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
697    # Make sure the directory exists.
698    test -f "$dirpart/$file" && continue
699    fdir=`AS_DIRNAME(["$file"])`
700    AS_MKDIR_P([$dirpart/$fdir])
701    # echo "creating $dirpart/$file"
702    echo '# dummy' > "$dirpart/$file"
703  done
704done
705])# _AM_OUTPUT_DEPENDENCY_COMMANDS
706
707
708# AM_OUTPUT_DEPENDENCY_COMMANDS
709# -----------------------------
710# This macro should only be invoked once -- use via AC_REQUIRE.
711#
712# This code is only required when automatic dependency tracking
713# is enabled.  FIXME.  This creates each `.P' file that we will
714# need in order to bootstrap the dependency handling code.
715AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
716[AC_CONFIG_COMMANDS([depfiles],
717     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
718     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
719])
720
721# Check to see how 'make' treats includes.	-*- Autoconf -*-
722
723# Copyright (C) 2001, 2002 Free Software Foundation, Inc.
724
725# This program is free software; you can redistribute it and/or modify
726# it under the terms of the GNU General Public License as published by
727# the Free Software Foundation; either version 2, or (at your option)
728# any later version.
729
730# This program is distributed in the hope that it will be useful,
731# but WITHOUT ANY WARRANTY; without even the implied warranty of
732# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
733# GNU General Public License for more details.
734
735# You should have received a copy of the GNU General Public License
736# along with this program; if not, write to the Free Software
737# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
738# 02111-1307, USA.
739
740# serial 2
741
742# AM_MAKE_INCLUDE()
743# -----------------
744# Check to see how make treats includes.
745AC_DEFUN([AM_MAKE_INCLUDE],
746[am_make=${MAKE-make}
747cat > confinc << 'END'
748doit:
749	@echo done
750END
751# If we don't find an include directive, just comment out the code.
752AC_MSG_CHECKING([for style of include used by $am_make])
753am__include="#"
754am__quote=
755_am_result=none
756# First try GNU make style include.
757echo "include confinc" > confmf
758# We grep out `Entering directory' and `Leaving directory'
759# messages which can occur if `w' ends up in MAKEFLAGS.
760# In particular we don't look at `^make:' because GNU make might
761# be invoked under some other name (usually "gmake"), in which
762# case it prints its new name instead of `make'.
763if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
764   am__include=include
765   am__quote=
766   _am_result=GNU
767fi
768# Now try BSD make style include.
769if test "$am__include" = "#"; then
770   echo '.include "confinc"' > confmf
771   if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
772      am__include=.include
773      am__quote="\""
774      _am_result=BSD
775   fi
776fi
777AC_SUBST(am__include)
778AC_SUBST(am__quote)
779AC_MSG_RESULT($_am_result)
780rm -f confinc confmf
781])
782
783# AM_CONDITIONAL                                              -*- Autoconf -*-
784
785# Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
786
787# This program is free software; you can redistribute it and/or modify
788# it under the terms of the GNU General Public License as published by
789# the Free Software Foundation; either version 2, or (at your option)
790# any later version.
791
792# This program is distributed in the hope that it will be useful,
793# but WITHOUT ANY WARRANTY; without even the implied warranty of
794# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
795# GNU General Public License for more details.
796
797# You should have received a copy of the GNU General Public License
798# along with this program; if not, write to the Free Software
799# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
800# 02111-1307, USA.
801
802# serial 5
803
804AC_PREREQ(2.52)
805
806# AM_CONDITIONAL(NAME, SHELL-CONDITION)
807# -------------------------------------
808# Define a conditional.
809AC_DEFUN([AM_CONDITIONAL],
810[ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
811        [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
812AC_SUBST([$1_TRUE])
813AC_SUBST([$1_FALSE])
814if $2; then
815  $1_TRUE=
816  $1_FALSE='#'
817else
818  $1_TRUE='#'
819  $1_FALSE=
820fi
821AC_CONFIG_COMMANDS_PRE(
822[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
823  AC_MSG_ERROR([conditional "$1" was never defined.
824Usually this means the macro was only invoked conditionally.])
825fi])])
826
827# Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
828
829# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
830
831# This program is free software; you can redistribute it and/or modify
832# it under the terms of the GNU General Public License as published by
833# the Free Software Foundation; either version 2, or (at your option)
834# any later version.
835
836# This program is distributed in the hope that it will be useful,
837# but WITHOUT ANY WARRANTY; without even the implied warranty of
838# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
839# GNU General Public License for more details.
840
841# You should have received a copy of the GNU General Public License
842# along with this program; if not, write to the Free Software
843# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
844# 02111-1307, USA.
845
846AC_PREREQ([2.52])
847
848# serial 6
849
850# AM_CONFIG_HEADER is obsolete.  It has been replaced by AC_CONFIG_HEADERS.
851AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
852
853
854dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not)
855dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page
856dnl also defines GSTUFF_PKG_ERRORS on error
857AC_DEFUN(PKG_CHECK_MODULES, [
858  succeeded=no
859
860  if test -z "$PKG_CONFIG"; then
861    AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
862  fi
863
864  if test "$PKG_CONFIG" = "no" ; then
865     echo "*** The pkg-config script could not be found. Make sure it is"
866     echo "*** in your path, or set the PKG_CONFIG environment variable"
867     echo "*** to the full path to pkg-config."
868     echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
869  else
870     PKG_CONFIG_MIN_VERSION=0.9.0
871     if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
872        AC_MSG_CHECKING(for $2)
873
874        if $PKG_CONFIG --exists "$2" ; then
875            AC_MSG_RESULT(yes)
876            succeeded=yes
877
878            AC_MSG_CHECKING($1_CFLAGS)
879            $1_CFLAGS=`$PKG_CONFIG --cflags "$2"`
880            AC_MSG_RESULT($$1_CFLAGS)
881
882            AC_MSG_CHECKING($1_LIBS)
883            $1_LIBS=`$PKG_CONFIG --libs "$2"`
884            AC_MSG_RESULT($$1_LIBS)
885        else
886            $1_CFLAGS=""
887            $1_LIBS=""
888            ## If we have a custom action on failure, don't print errors, but
889            ## do set a variable so people can do so.
890            $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
891            ifelse([$4], ,echo $$1_PKG_ERRORS,)
892        fi
893
894        AC_SUBST($1_CFLAGS)
895        AC_SUBST($1_LIBS)
896     else
897        echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
898        echo "*** See http://www.freedesktop.org/software/pkgconfig"
899     fi
900  fi
901
902  if test $succeeded = yes; then
903     ifelse([$3], , :, [$3])
904  else
905     ifelse([$4], , AC_MSG_ERROR([Library requirements ($2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.]), [$4])
906  fi
907])
908
909
910
911