source: trunk/third/vte/gnome-pty-helper/aclocal.m4 @ 20883

Revision 20883, 45.0 KB checked in by ghudson, 20 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r20882, which included commits to RCS files with non-trunk default branches.
Line 
1# generated automatically by aclocal 1.7.9 -*- 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# Checks for availability of various utmp fields
15#
16# Original code by Bernhard Rosenkraenzer (bero@linux.net.eu.org), 1998.
17# Modifications by Timur Bakeyev (timur@gnu.org), 1999.
18# Patched from http://bugzilla.gnome.org/show_bug.cgi?id=93774
19#
20
21dnl GPH_CHECK_UTMP()
22dnl Test for presence of the field and define HAVE_UT_UT_field macro
23dnl
24
25AC_DEFUN([GPH_CHECK_UTMP],[
26
27AC_CHECK_HEADERS(sys/time.h utmp.h utmpx.h)
28AC_HEADER_TIME
29
30if test "$ac_cv_header_utmpx_h" = "yes"; then
31    AC_DEFINE(UTMP,[struct utmpx],[Define to the name of a structure which holds utmp data.])
32else
33    AC_DEFINE(UTMP,[struct utmp],[Define to the name of a structure which holds utmp data.])
34fi
35
36dnl some systems (BSD4.4-like) require time.h to be included before utmp.h :/
37AC_MSG_CHECKING(for ut_host field in the utmp structure)
38AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
39#include <sys/time.h>
40#include <time.h>
41#else
42#ifdef HAVE_SYS_TIME_H
43#include <sys/time.h>
44#else
45#include <time.h>
46#endif
47#endif
48#ifdef HAVE_UTMP_H
49#include <utmp.h>
50#endif
51#ifdef HAVE_UTMPX_H
52#include <utmpx.h>
53#endif],[UTMP ut; char *p; p=ut.ut_host;],result=yes,result=no)
54if test "$result" = "yes"; then
55  AC_DEFINE(HAVE_UT_UT_HOST,1,[Define if your utmp struct contains a ut_host field.])
56fi
57AC_MSG_RESULT($result)
58
59AC_MSG_CHECKING(for ut_pid field in the utmp structure)
60AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
61#include <sys/time.h>
62#include <time.h>
63#else
64#ifdef HAVE_SYS_TIME_H
65#include <sys/time.h>
66#else
67#include <time.h>
68#endif
69#endif
70#ifdef HAVE_UTMP_H
71#include <utmp.h>
72#endif
73#ifdef HAVE_UTMPX_H
74#include <utmpx.h>
75#endif],[UTMP ut; int i; i=ut.ut_pid;],result=yes,result=no)
76if test "$result" = "yes"; then
77  AC_DEFINE(HAVE_UT_UT_PID,1,[Define if your utmp struct contains a ut_pid field.])
78fi
79AC_MSG_RESULT($result)
80
81AC_MSG_CHECKING(for ut_id field in the utmp structure)
82AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
83#include <sys/time.h>
84#include <time.h>
85#else
86#ifdef HAVE_SYS_TIME_H
87#include <sys/time.h>
88#else
89#include <time.h>
90#endif
91#endif
92#ifdef HAVE_UTMP_H
93#include <utmp.h>
94#endif
95#ifdef HAVE_UTMPX_H
96#include <utmpx.h>
97#endif],[UTMP ut; char *p; p=ut.ut_id;],result=yes,result=no)
98if test "$result" = "yes"; then
99  AC_DEFINE(HAVE_UT_UT_ID,1,[Define if your utmp struct contains a ut_id field.])
100fi
101AC_MSG_RESULT($result)
102
103AC_MSG_CHECKING(for ut_name field in the utmp structure)
104AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
105#include <sys/time.h>
106#include <time.h>
107#else
108#ifdef HAVE_SYS_TIME_H
109#include <sys/time.h>
110#else
111#include <time.h>
112#endif
113#endif
114#ifdef HAVE_UTMP_H
115#include <utmp.h>
116#endif
117#ifdef HAVE_UTMPX_H
118#include <utmpx.h>
119#endif],[UTMP ut; char *p; p=ut.ut_name;],result=yes,result=no)
120if test "$result" = "yes"; then
121  AC_DEFINE(HAVE_UT_UT_NAME,1,[Define if your utmp struct contains a ut_name field.])
122fi
123AC_MSG_RESULT($result)
124
125AC_MSG_CHECKING(for ut_type field in the utmp structure)
126AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
127#include <sys/time.h>
128#include <time.h>
129#else
130#ifdef HAVE_SYS_TIME_H
131#include <sys/time.h>
132#else
133#include <time.h>
134#endif
135#endif
136#ifdef HAVE_UTMP_H
137#include <utmp.h>
138#endif
139#ifdef HAVE_UTMPX_H
140#include <utmpx.h>
141#endif],[UTMP ut; int i; i=(int) ut.ut_type;],result=yes,result=no)
142if test "$result" = "yes"; then
143  AC_DEFINE(HAVE_UT_UT_TYPE,1,[Define if your utmp struct contains a ut_type field.])
144fi
145AC_MSG_RESULT($result)
146
147AC_MSG_CHECKING(for ut_exit.e_termination field in the utmp structure)
148AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
149#include <sys/time.h>
150#include <time.h>
151#else
152#ifdef HAVE_SYS_TIME_H
153#include <sys/time.h>
154#else
155#include <time.h>
156#endif
157#endif
158#ifdef HAVE_UTMP_H
159#include <utmp.h>
160#endif
161#ifdef HAVE_UTMPX_H
162#include <utmpx.h>
163#endif],[UTMP ut; ut.ut_exit.e_termination=0;],result=yes,result=no)
164if test "$result" = "yes"; then
165  AC_DEFINE(HAVE_UT_UT_EXIT_E_TERMINATION,1,[Define if your utmp struct contains a ut_exit.e_termination field.])
166fi
167AC_MSG_RESULT($result)
168
169AC_MSG_CHECKING(for ut_user field in the utmp structure)
170AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
171#include <sys/time.h>
172#include <time.h>
173#else
174#ifdef HAVE_SYS_TIME_H
175#include <sys/time.h>
176#else
177#include <time.h>
178#endif
179#endif
180#ifdef HAVE_UTMP_H
181#include <utmp.h>
182#endif
183#ifdef HAVE_UTMPX_H
184#include <utmpx.h>
185#endif],[UTMP ut; char *p; p=ut.ut_user;],result=yes,result=no)
186if test "$result" = "yes"; then
187  AC_DEFINE(HAVE_UT_UT_USER,1,[Define if your utmp struct contains a ut_user field.])
188fi
189AC_MSG_RESULT($result)
190
191AC_MSG_CHECKING(for ut_time field in the utmp structure)
192AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
193#include <sys/time.h>
194#include <time.h>
195#else
196#ifdef HAVE_SYS_TIME_H
197#include <sys/time.h>
198#else
199#include <time.h>
200#endif
201#endif
202#ifdef HAVE_UTMP_H
203#include <utmp.h>
204#endif
205#ifdef HAVE_UTMPX_H
206#include <utmpx.h>
207#endif],[UTMP ut; ut.ut_time=0;],result=yes,result=no)
208if test "$result" = "yes"; then
209  AC_DEFINE(HAVE_UT_UT_TIME,1,[Define if your utmp struct contains a ut_time field.])
210fi
211AC_MSG_RESULT($result)
212
213AC_MSG_CHECKING(for ut_tv field in the utmp structure)
214AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
215#include <sys/time.h>
216#include <time.h>
217#else
218#ifdef HAVE_SYS_TIME_H
219#include <sys/time.h>
220#else
221#include <time.h>
222#endif
223#endif
224#ifdef HAVE_UTMP_H
225#include <utmp.h>
226#endif
227#ifdef HAVE_UTMPX_H
228#include <utmpx.h>
229#endif],[UTMP ut; ut.ut_tv.tv_sec=0; ut.ut_tv.tv_usec=0; ],result=yes,result=no)
230if test "$result" = "yes"; then
231  AC_DEFINE(HAVE_UT_UT_TV,1,[Define if your utmp struct contains a ut_tv field.])
232fi
233AC_MSG_RESULT($result)
234
235AC_MSG_CHECKING(for ut_syslen field in the utmp structure)
236AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME
237#include <sys/time.h>
238#include <time.h>
239#else
240#ifdef HAVE_SYS_TIME_H
241#include <sys/time.h>
242#else
243#include <time.h>
244#endif
245#endif
246#ifdef HAVE_UTMP_H
247#include <utmp.h>
248#endif
249#ifdef HAVE_UTMPX_H
250#include <utmpx.h>
251#endif],[UTMP ut; ut.ut_syslen=0;],result=yes,result=no)
252if test "$result" = "yes"; then
253  AC_DEFINE(HAVE_UT_UT_SYSLEN,1,[Define if your utmp struct contains a ut_syslen field.])
254fi
255AC_MSG_RESULT($result)
256
257])
258
259# Do all the work for Automake.                            -*- Autoconf -*-
260
261# This macro actually does too much some checks are only needed if
262# your package does certain things.  But this isn't really a big deal.
263
264# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
265# Free Software Foundation, Inc.
266
267# This program is free software; you can redistribute it and/or modify
268# it under the terms of the GNU General Public License as published by
269# the Free Software Foundation; either version 2, or (at your option)
270# any later version.
271
272# This program is distributed in the hope that it will be useful,
273# but WITHOUT ANY WARRANTY; without even the implied warranty of
274# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
275# GNU General Public License for more details.
276
277# You should have received a copy of the GNU General Public License
278# along with this program; if not, write to the Free Software
279# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
280# 02111-1307, USA.
281
282# serial 10
283
284AC_PREREQ([2.54])
285
286# Autoconf 2.50 wants to disallow AM_ names.  We explicitly allow
287# the ones we care about.
288m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
289
290# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
291# AM_INIT_AUTOMAKE([OPTIONS])
292# -----------------------------------------------
293# The call with PACKAGE and VERSION arguments is the old style
294# call (pre autoconf-2.50), which is being phased out.  PACKAGE
295# and VERSION should now be passed to AC_INIT and removed from
296# the call to AM_INIT_AUTOMAKE.
297# We support both call styles for the transition.  After
298# the next Automake release, Autoconf can make the AC_INIT
299# arguments mandatory, and then we can depend on a new Autoconf
300# release and drop the old call support.
301AC_DEFUN([AM_INIT_AUTOMAKE],
302[AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
303 AC_REQUIRE([AC_PROG_INSTALL])dnl
304# test to see if srcdir already configured
305if test "`cd $srcdir && pwd`" != "`pwd`" &&
306   test -f $srcdir/config.status; then
307  AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
308fi
309
310# test whether we have cygpath
311if test -z "$CYGPATH_W"; then
312  if (cygpath --version) >/dev/null 2>/dev/null; then
313    CYGPATH_W='cygpath -w'
314  else
315    CYGPATH_W=echo
316  fi
317fi
318AC_SUBST([CYGPATH_W])
319
320# Define the identity of the package.
321dnl Distinguish between old-style and new-style calls.
322m4_ifval([$2],
323[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
324 AC_SUBST([PACKAGE], [$1])dnl
325 AC_SUBST([VERSION], [$2])],
326[_AM_SET_OPTIONS([$1])dnl
327 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
328 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
329
330_AM_IF_OPTION([no-define],,
331[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
332 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
333
334# Some tools Automake needs.
335AC_REQUIRE([AM_SANITY_CHECK])dnl
336AC_REQUIRE([AC_ARG_PROGRAM])dnl
337AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
338AM_MISSING_PROG(AUTOCONF, autoconf)
339AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
340AM_MISSING_PROG(AUTOHEADER, autoheader)
341AM_MISSING_PROG(MAKEINFO, makeinfo)
342AM_MISSING_PROG(AMTAR, tar)
343AM_PROG_INSTALL_SH
344AM_PROG_INSTALL_STRIP
345# We need awk for the "check" target.  The system "awk" is bad on
346# some platforms.
347AC_REQUIRE([AC_PROG_AWK])dnl
348AC_REQUIRE([AC_PROG_MAKE_SET])dnl
349AC_REQUIRE([AM_SET_LEADING_DOT])dnl
350
351_AM_IF_OPTION([no-dependencies],,
352[AC_PROVIDE_IFELSE([AC_PROG_CC],
353                  [_AM_DEPENDENCIES(CC)],
354                  [define([AC_PROG_CC],
355                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
356AC_PROVIDE_IFELSE([AC_PROG_CXX],
357                  [_AM_DEPENDENCIES(CXX)],
358                  [define([AC_PROG_CXX],
359                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
360])
361])
362
363
364# When config.status generates a header, we must update the stamp-h file.
365# This file resides in the same directory as the config header
366# that is generated.  The stamp files are numbered to have different names.
367
368# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
369# loop where config.status creates the headers, so we can generate
370# our stamp files there.
371AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
372[# Compute $1's index in $config_headers.
373_am_stamp_count=1
374for _am_header in $config_headers :; do
375  case $_am_header in
376    $1 | $1:* )
377      break ;;
378    * )
379      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
380  esac
381done
382echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
383
384# Copyright 2002  Free Software Foundation, Inc.
385
386# This program is free software; you can redistribute it and/or modify
387# it under the terms of the GNU General Public License as published by
388# the Free Software Foundation; either version 2, or (at your option)
389# any later version.
390
391# This program is distributed in the hope that it will be useful,
392# but WITHOUT ANY WARRANTY; without even the implied warranty of
393# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
394# GNU General Public License for more details.
395
396# You should have received a copy of the GNU General Public License
397# along with this program; if not, write to the Free Software
398# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
399
400# AM_AUTOMAKE_VERSION(VERSION)
401# ----------------------------
402# Automake X.Y traces this macro to ensure aclocal.m4 has been
403# generated from the m4 files accompanying Automake X.Y.
404AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.7"])
405
406# AM_SET_CURRENT_AUTOMAKE_VERSION
407# -------------------------------
408# Call AM_AUTOMAKE_VERSION so it can be traced.
409# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
410AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
411         [AM_AUTOMAKE_VERSION([1.7.9])])
412
413# Helper functions for option handling.                    -*- Autoconf -*-
414
415# Copyright 2001, 2002  Free Software Foundation, Inc.
416
417# This program is free software; you can redistribute it and/or modify
418# it under the terms of the GNU General Public License as published by
419# the Free Software Foundation; either version 2, or (at your option)
420# any later version.
421
422# This program is distributed in the hope that it will be useful,
423# but WITHOUT ANY WARRANTY; without even the implied warranty of
424# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
425# GNU General Public License for more details.
426
427# You should have received a copy of the GNU General Public License
428# along with this program; if not, write to the Free Software
429# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
430# 02111-1307, USA.
431
432# serial 2
433
434# _AM_MANGLE_OPTION(NAME)
435# -----------------------
436AC_DEFUN([_AM_MANGLE_OPTION],
437[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
438
439# _AM_SET_OPTION(NAME)
440# ------------------------------
441# Set option NAME.  Presently that only means defining a flag for this option.
442AC_DEFUN([_AM_SET_OPTION],
443[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
444
445# _AM_SET_OPTIONS(OPTIONS)
446# ----------------------------------
447# OPTIONS is a space-separated list of Automake options.
448AC_DEFUN([_AM_SET_OPTIONS],
449[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
450
451# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
452# -------------------------------------------
453# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
454AC_DEFUN([_AM_IF_OPTION],
455[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
456
457#
458# Check to make sure that the build environment is sane.
459#
460
461# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
462
463# This program is free software; you can redistribute it and/or modify
464# it under the terms of the GNU General Public License as published by
465# the Free Software Foundation; either version 2, or (at your option)
466# any later version.
467
468# This program is distributed in the hope that it will be useful,
469# but WITHOUT ANY WARRANTY; without even the implied warranty of
470# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
471# GNU General Public License for more details.
472
473# You should have received a copy of the GNU General Public License
474# along with this program; if not, write to the Free Software
475# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
476# 02111-1307, USA.
477
478# serial 3
479
480# AM_SANITY_CHECK
481# ---------------
482AC_DEFUN([AM_SANITY_CHECK],
483[AC_MSG_CHECKING([whether build environment is sane])
484# Just in case
485sleep 1
486echo timestamp > conftest.file
487# Do `set' in a subshell so we don't clobber the current shell's
488# arguments.  Must try -L first in case configure is actually a
489# symlink; some systems play weird games with the mod time of symlinks
490# (eg FreeBSD returns the mod time of the symlink's containing
491# directory).
492if (
493   set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
494   if test "$[*]" = "X"; then
495      # -L didn't work.
496      set X `ls -t $srcdir/configure conftest.file`
497   fi
498   rm -f conftest.file
499   if test "$[*]" != "X $srcdir/configure conftest.file" \
500      && test "$[*]" != "X conftest.file $srcdir/configure"; then
501
502      # If neither matched, then we have a broken ls.  This can happen
503      # if, for instance, CONFIG_SHELL is bash and it inherits a
504      # broken ls alias from the environment.  This has actually
505      # happened.  Such a system could not be considered "sane".
506      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
507alias in your environment])
508   fi
509
510   test "$[2]" = conftest.file
511   )
512then
513   # Ok.
514   :
515else
516   AC_MSG_ERROR([newly created file is older than distributed files!
517Check your system clock])
518fi
519AC_MSG_RESULT(yes)])
520
521#  -*- Autoconf -*-
522
523
524# Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
525
526# This program is free software; you can redistribute it and/or modify
527# it under the terms of the GNU General Public License as published by
528# the Free Software Foundation; either version 2, or (at your option)
529# any later version.
530
531# This program is distributed in the hope that it will be useful,
532# but WITHOUT ANY WARRANTY; without even the implied warranty of
533# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
534# GNU General Public License for more details.
535
536# You should have received a copy of the GNU General Public License
537# along with this program; if not, write to the Free Software
538# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
539# 02111-1307, USA.
540
541# serial 3
542
543# AM_MISSING_PROG(NAME, PROGRAM)
544# ------------------------------
545AC_DEFUN([AM_MISSING_PROG],
546[AC_REQUIRE([AM_MISSING_HAS_RUN])
547$1=${$1-"${am_missing_run}$2"}
548AC_SUBST($1)])
549
550
551# AM_MISSING_HAS_RUN
552# ------------------
553# Define MISSING if not defined so far and test if it supports --run.
554# If it does, set am_missing_run to use it, otherwise, to nothing.
555AC_DEFUN([AM_MISSING_HAS_RUN],
556[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
557test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
558# Use eval to expand $SHELL
559if eval "$MISSING --run true"; then
560  am_missing_run="$MISSING --run "
561else
562  am_missing_run=
563  AC_MSG_WARN([`missing' script is too old or missing])
564fi
565])
566
567# AM_AUX_DIR_EXPAND
568
569# Copyright 2001 Free Software Foundation, Inc.
570
571# This program is free software; you can redistribute it and/or modify
572# it under the terms of the GNU General Public License as published by
573# the Free Software Foundation; either version 2, or (at your option)
574# any later version.
575
576# This program is distributed in the hope that it will be useful,
577# but WITHOUT ANY WARRANTY; without even the implied warranty of
578# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
579# GNU General Public License for more details.
580
581# You should have received a copy of the GNU General Public License
582# along with this program; if not, write to the Free Software
583# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
584# 02111-1307, USA.
585
586# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
587# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
588# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
589#
590# Of course, Automake must honor this variable whenever it calls a
591# tool from the auxiliary directory.  The problem is that $srcdir (and
592# therefore $ac_aux_dir as well) can be either absolute or relative,
593# depending on how configure is run.  This is pretty annoying, since
594# it makes $ac_aux_dir quite unusable in subdirectories: in the top
595# source directory, any form will work fine, but in subdirectories a
596# relative path needs to be adjusted first.
597#
598# $ac_aux_dir/missing
599#    fails when called from a subdirectory if $ac_aux_dir is relative
600# $top_srcdir/$ac_aux_dir/missing
601#    fails if $ac_aux_dir is absolute,
602#    fails when called from a subdirectory in a VPATH build with
603#          a relative $ac_aux_dir
604#
605# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
606# are both prefixed by $srcdir.  In an in-source build this is usually
607# harmless because $srcdir is `.', but things will broke when you
608# start a VPATH build or use an absolute $srcdir.
609#
610# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
611# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
612#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
613# and then we would define $MISSING as
614#   MISSING="\${SHELL} $am_aux_dir/missing"
615# This will work as long as MISSING is not called from configure, because
616# unfortunately $(top_srcdir) has no meaning in configure.
617# However there are other variables, like CC, which are often used in
618# configure, and could therefore not use this "fixed" $ac_aux_dir.
619#
620# Another solution, used here, is to always expand $ac_aux_dir to an
621# absolute PATH.  The drawback is that using absolute paths prevent a
622# configured tree to be moved without reconfiguration.
623
624# Rely on autoconf to set up CDPATH properly.
625AC_PREREQ([2.50])
626
627AC_DEFUN([AM_AUX_DIR_EXPAND], [
628# expand $ac_aux_dir to an absolute path
629am_aux_dir=`cd $ac_aux_dir && pwd`
630])
631
632# AM_PROG_INSTALL_SH
633# ------------------
634# Define $install_sh.
635
636# Copyright 2001 Free Software Foundation, Inc.
637
638# This program is free software; you can redistribute it and/or modify
639# it under the terms of the GNU General Public License as published by
640# the Free Software Foundation; either version 2, or (at your option)
641# any later version.
642
643# This program is distributed in the hope that it will be useful,
644# but WITHOUT ANY WARRANTY; without even the implied warranty of
645# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
646# GNU General Public License for more details.
647
648# You should have received a copy of the GNU General Public License
649# along with this program; if not, write to the Free Software
650# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
651# 02111-1307, USA.
652
653AC_DEFUN([AM_PROG_INSTALL_SH],
654[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
655install_sh=${install_sh-"$am_aux_dir/install-sh"}
656AC_SUBST(install_sh)])
657
658# AM_PROG_INSTALL_STRIP
659
660# Copyright 2001 Free Software Foundation, Inc.
661
662# This program is free software; you can redistribute it and/or modify
663# it under the terms of the GNU General Public License as published by
664# the Free Software Foundation; either version 2, or (at your option)
665# any later version.
666
667# This program is distributed in the hope that it will be useful,
668# but WITHOUT ANY WARRANTY; without even the implied warranty of
669# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
670# GNU General Public License for more details.
671
672# You should have received a copy of the GNU General Public License
673# along with this program; if not, write to the Free Software
674# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
675# 02111-1307, USA.
676
677# One issue with vendor `install' (even GNU) is that you can't
678# specify the program used to strip binaries.  This is especially
679# annoying in cross-compiling environments, where the build's strip
680# is unlikely to handle the host's binaries.
681# Fortunately install-sh will honor a STRIPPROG variable, so we
682# always use install-sh in `make install-strip', and initialize
683# STRIPPROG with the value of the STRIP variable (set by the user).
684AC_DEFUN([AM_PROG_INSTALL_STRIP],
685[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
686# Installed binaries are usually stripped using `strip' when the user
687# run `make install-strip'.  However `strip' might not be the right
688# tool to use in cross-compilation environments, therefore Automake
689# will honor the `STRIP' environment variable to overrule this program.
690dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
691if test "$cross_compiling" != no; then
692  AC_CHECK_TOOL([STRIP], [strip], :)
693fi
694INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
695AC_SUBST([INSTALL_STRIP_PROGRAM])])
696
697#                                                          -*- Autoconf -*-
698# Copyright (C) 2003  Free Software Foundation, Inc.
699
700# This program is free software; you can redistribute it and/or modify
701# it under the terms of the GNU General Public License as published by
702# the Free Software Foundation; either version 2, or (at your option)
703# any later version.
704
705# This program is distributed in the hope that it will be useful,
706# but WITHOUT ANY WARRANTY; without even the implied warranty of
707# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
708# GNU General Public License for more details.
709
710# You should have received a copy of the GNU General Public License
711# along with this program; if not, write to the Free Software
712# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
713# 02111-1307, USA.
714
715# serial 1
716
717# Check whether the underlying file-system supports filenames
718# with a leading dot.  For instance MS-DOS doesn't.
719AC_DEFUN([AM_SET_LEADING_DOT],
720[rm -rf .tst 2>/dev/null
721mkdir .tst 2>/dev/null
722if test -d .tst; then
723  am__leading_dot=.
724else
725  am__leading_dot=_
726fi
727rmdir .tst 2>/dev/null
728AC_SUBST([am__leading_dot])])
729
730# serial 5                                              -*- Autoconf -*-
731
732# Copyright (C) 1999, 2000, 2001, 2002, 2003  Free Software Foundation, Inc.
733
734# This program is free software; you can redistribute it and/or modify
735# it under the terms of the GNU General Public License as published by
736# the Free Software Foundation; either version 2, or (at your option)
737# any later version.
738
739# This program is distributed in the hope that it will be useful,
740# but WITHOUT ANY WARRANTY; without even the implied warranty of
741# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
742# GNU General Public License for more details.
743
744# You should have received a copy of the GNU General Public License
745# along with this program; if not, write to the Free Software
746# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
747# 02111-1307, USA.
748
749
750# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
751# written in clear, in which case automake, when reading aclocal.m4,
752# will think it sees a *use*, and therefore will trigger all it's
753# C support machinery.  Also note that it means that autoscan, seeing
754# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
755
756
757
758# _AM_DEPENDENCIES(NAME)
759# ----------------------
760# See how the compiler implements dependency checking.
761# NAME is "CC", "CXX", "GCJ", or "OBJC".
762# We try a few techniques and use that to set a single cache variable.
763#
764# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
765# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
766# dependency, and given that the user is not expected to run this macro,
767# just rely on AC_PROG_CC.
768AC_DEFUN([_AM_DEPENDENCIES],
769[AC_REQUIRE([AM_SET_DEPDIR])dnl
770AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
771AC_REQUIRE([AM_MAKE_INCLUDE])dnl
772AC_REQUIRE([AM_DEP_TRACK])dnl
773
774ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
775       [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
776       [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
777       [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
778                   [depcc="$$1"   am_compiler_list=])
779
780AC_CACHE_CHECK([dependency style of $depcc],
781               [am_cv_$1_dependencies_compiler_type],
782[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
783  # We make a subdir and do the tests there.  Otherwise we can end up
784  # making bogus files that we don't know about and never remove.  For
785  # instance it was reported that on HP-UX the gcc test will end up
786  # making a dummy file named `D' -- because `-MD' means `put the output
787  # in D'.
788  mkdir conftest.dir
789  # Copy depcomp to subdir because otherwise we won't find it if we're
790  # using a relative directory.
791  cp "$am_depcomp" conftest.dir
792  cd conftest.dir
793  # We will build objects and dependencies in a subdirectory because
794  # it helps to detect inapplicable dependency modes.  For instance
795  # both Tru64's cc and ICC support -MD to output dependencies as a
796  # side effect of compilation, but ICC will put the dependencies in
797  # the current directory while Tru64 will put them in the object
798  # directory.
799  mkdir sub
800
801  am_cv_$1_dependencies_compiler_type=none
802  if test "$am_compiler_list" = ""; then
803     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
804  fi
805  for depmode in $am_compiler_list; do
806    # Setup a source with many dependencies, because some compilers
807    # like to wrap large dependency lists on column 80 (with \), and
808    # we should not choose a depcomp mode which is confused by this.
809    #
810    # We need to recreate these files for each test, as the compiler may
811    # overwrite some of them when testing with obscure command lines.
812    # This happens at least with the AIX C compiler.
813    : > sub/conftest.c
814    for i in 1 2 3 4 5 6; do
815      echo '#include "conftst'$i'.h"' >> sub/conftest.c
816      : > sub/conftst$i.h
817    done
818    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
819
820    case $depmode in
821    nosideeffect)
822      # after this tag, mechanisms are not by side-effect, so they'll
823      # only be used when explicitly requested
824      if test "x$enable_dependency_tracking" = xyes; then
825        continue
826      else
827        break
828      fi
829      ;;
830    none) break ;;
831    esac
832    # We check with `-c' and `-o' for the sake of the "dashmstdout"
833    # mode.  It turns out that the SunPro C++ compiler does not properly
834    # handle `-M -o', and we need to detect this.
835    if depmode=$depmode \
836       source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
837       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
838       $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
839         >/dev/null 2>conftest.err &&
840       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
841       grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
842       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
843      # icc doesn't choke on unknown options, it will just issue warnings
844      # (even with -Werror).  So we grep stderr for any message
845      # that says an option was ignored.
846      if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
847        am_cv_$1_dependencies_compiler_type=$depmode
848        break
849      fi
850    fi
851  done
852
853  cd ..
854  rm -rf conftest.dir
855else
856  am_cv_$1_dependencies_compiler_type=none
857fi
858])
859AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
860AM_CONDITIONAL([am__fastdep$1], [
861  test "x$enable_dependency_tracking" != xno \
862  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
863])
864
865
866# AM_SET_DEPDIR
867# -------------
868# Choose a directory name for dependency files.
869# This macro is AC_REQUIREd in _AM_DEPENDENCIES
870AC_DEFUN([AM_SET_DEPDIR],
871[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
872AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
873])
874
875
876# AM_DEP_TRACK
877# ------------
878AC_DEFUN([AM_DEP_TRACK],
879[AC_ARG_ENABLE(dependency-tracking,
880[  --disable-dependency-tracking Speeds up one-time builds
881  --enable-dependency-tracking  Do not reject slow dependency extractors])
882if test "x$enable_dependency_tracking" != xno; then
883  am_depcomp="$ac_aux_dir/depcomp"
884  AMDEPBACKSLASH='\'
885fi
886AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
887AC_SUBST([AMDEPBACKSLASH])
888])
889
890# Generate code to set up dependency tracking.   -*- Autoconf -*-
891
892# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
893
894# This program is free software; you can redistribute it and/or modify
895# it under the terms of the GNU General Public License as published by
896# the Free Software Foundation; either version 2, or (at your option)
897# any later version.
898
899# This program is distributed in the hope that it will be useful,
900# but WITHOUT ANY WARRANTY; without even the implied warranty of
901# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
902# GNU General Public License for more details.
903
904# You should have received a copy of the GNU General Public License
905# along with this program; if not, write to the Free Software
906# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
907# 02111-1307, USA.
908
909#serial 2
910
911# _AM_OUTPUT_DEPENDENCY_COMMANDS
912# ------------------------------
913AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
914[for mf in $CONFIG_FILES; do
915  # Strip MF so we end up with the name of the file.
916  mf=`echo "$mf" | sed -e 's/:.*$//'`
917  # Check whether this is an Automake generated Makefile or not.
918  # We used to match only the files named `Makefile.in', but
919  # some people rename them; so instead we look at the file content.
920  # Grep'ing the first line is not enough: some people post-process
921  # each Makefile.in and add a new line on top of each file to say so.
922  # So let's grep whole file.
923  if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
924    dirpart=`AS_DIRNAME("$mf")`
925  else
926    continue
927  fi
928  grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
929  # Extract the definition of DEP_FILES from the Makefile without
930  # running `make'.
931  DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
932  test -z "$DEPDIR" && continue
933  # When using ansi2knr, U may be empty or an underscore; expand it
934  U=`sed -n -e '/^U = / s///p' < "$mf"`
935  test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
936  # We invoke sed twice because it is the simplest approach to
937  # changing $(DEPDIR) to its actual value in the expansion.
938  for file in `sed -n -e '
939    /^DEP_FILES = .*\\\\$/ {
940      s/^DEP_FILES = //
941      :loop
942        s/\\\\$//
943        p
944        n
945        /\\\\$/ b loop
946      p
947    }
948    /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
949       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
950    # Make sure the directory exists.
951    test -f "$dirpart/$file" && continue
952    fdir=`AS_DIRNAME(["$file"])`
953    AS_MKDIR_P([$dirpart/$fdir])
954    # echo "creating $dirpart/$file"
955    echo '# dummy' > "$dirpart/$file"
956  done
957done
958])# _AM_OUTPUT_DEPENDENCY_COMMANDS
959
960
961# AM_OUTPUT_DEPENDENCY_COMMANDS
962# -----------------------------
963# This macro should only be invoked once -- use via AC_REQUIRE.
964#
965# This code is only required when automatic dependency tracking
966# is enabled.  FIXME.  This creates each `.P' file that we will
967# need in order to bootstrap the dependency handling code.
968AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
969[AC_CONFIG_COMMANDS([depfiles],
970     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
971     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
972])
973
974# Check to see how 'make' treats includes.      -*- Autoconf -*-
975
976# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
977
978# This program is free software; you can redistribute it and/or modify
979# it under the terms of the GNU General Public License as published by
980# the Free Software Foundation; either version 2, or (at your option)
981# any later version.
982
983# This program is distributed in the hope that it will be useful,
984# but WITHOUT ANY WARRANTY; without even the implied warranty of
985# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
986# GNU General Public License for more details.
987
988# You should have received a copy of the GNU General Public License
989# along with this program; if not, write to the Free Software
990# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
991# 02111-1307, USA.
992
993# serial 2
994
995# AM_MAKE_INCLUDE()
996# -----------------
997# Check to see how make treats includes.
998AC_DEFUN([AM_MAKE_INCLUDE],
999[am_make=${MAKE-make}
1000cat > confinc << 'END'
1001am__doit:
1002        @echo done
1003.PHONY: am__doit
1004END
1005# If we don't find an include directive, just comment out the code.
1006AC_MSG_CHECKING([for style of include used by $am_make])
1007am__include="#"
1008am__quote=
1009_am_result=none
1010# First try GNU make style include.
1011echo "include confinc" > confmf
1012# We grep out `Entering directory' and `Leaving directory'
1013# messages which can occur if `w' ends up in MAKEFLAGS.
1014# In particular we don't look at `^make:' because GNU make might
1015# be invoked under some other name (usually "gmake"), in which
1016# case it prints its new name instead of `make'.
1017if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
1018   am__include=include
1019   am__quote=
1020   _am_result=GNU
1021fi
1022# Now try BSD make style include.
1023if test "$am__include" = "#"; then
1024   echo '.include "confinc"' > confmf
1025   if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
1026      am__include=.include
1027      am__quote="\""
1028      _am_result=BSD
1029   fi
1030fi
1031AC_SUBST([am__include])
1032AC_SUBST([am__quote])
1033AC_MSG_RESULT([$_am_result])
1034rm -f confinc confmf
1035])
1036
1037# AM_CONDITIONAL                                              -*- Autoconf -*-
1038
1039# Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
1040
1041# This program is free software; you can redistribute it and/or modify
1042# it under the terms of the GNU General Public License as published by
1043# the Free Software Foundation; either version 2, or (at your option)
1044# any later version.
1045
1046# This program is distributed in the hope that it will be useful,
1047# but WITHOUT ANY WARRANTY; without even the implied warranty of
1048# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1049# GNU General Public License for more details.
1050
1051# You should have received a copy of the GNU General Public License
1052# along with this program; if not, write to the Free Software
1053# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
1054# 02111-1307, USA.
1055
1056# serial 5
1057
1058AC_PREREQ(2.52)
1059
1060# AM_CONDITIONAL(NAME, SHELL-CONDITION)
1061# -------------------------------------
1062# Define a conditional.
1063AC_DEFUN([AM_CONDITIONAL],
1064[ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
1065        [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
1066AC_SUBST([$1_TRUE])
1067AC_SUBST([$1_FALSE])
1068if $2; then
1069  $1_TRUE=
1070  $1_FALSE='#'
1071else
1072  $1_TRUE='#'
1073  $1_FALSE=
1074fi
1075AC_CONFIG_COMMANDS_PRE(
1076[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
1077  AC_MSG_ERROR([conditional "$1" was never defined.
1078Usually this means the macro was only invoked conditionally.])
1079fi])])
1080
1081# isc-posix.m4 serial 2 (gettext-0.11.2)
1082dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
1083dnl This file is free software, distributed under the terms of the GNU
1084dnl General Public License.  As a special exception to the GNU General
1085dnl Public License, this file may be distributed as part of a program
1086dnl that contains a configuration script generated by Autoconf, under
1087dnl the same distribution terms as the rest of that program.
1088
1089# This file is not needed with autoconf-2.53 and newer.  Remove it in 2005.
1090
1091# This test replaces the one in autoconf.
1092# Currently this macro should have the same name as the autoconf macro
1093# because gettext's gettext.m4 (distributed in the automake package)
1094# still uses it.  Otherwise, the use in gettext.m4 makes autoheader
1095# give these diagnostics:
1096#   configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
1097#   configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
1098
1099undefine([AC_ISC_POSIX])
1100
1101AC_DEFUN([AC_ISC_POSIX],
1102  [
1103    dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
1104    AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
1105  ]
1106)
1107
1108
1109# Copyright 1996, 1997, 1999, 2000, 2001, 2002  Free Software Foundation, Inc.
1110
1111# This program is free software; you can redistribute it and/or modify
1112# it under the terms of the GNU General Public License as published by
1113# the Free Software Foundation; either version 2, or (at your option)
1114# any later version.
1115
1116# This program is distributed in the hope that it will be useful,
1117# but WITHOUT ANY WARRANTY; without even the implied warranty of
1118# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1119# GNU General Public License for more details.
1120
1121# You should have received a copy of the GNU General Public License
1122# along with this program; if not, write to the Free Software
1123# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
1124# 02111-1307, USA.
1125
1126# serial 2
1127
1128# @defmac AC_PROG_CC_STDC
1129# @maindex PROG_CC_STDC
1130# @ovindex CC
1131# If the C compiler in not in ANSI C mode by default, try to add an option
1132# to output variable @code{CC} to make it so.  This macro tries various
1133# options that select ANSI C on some system or another.  It considers the
1134# compiler to be in ANSI C mode if it handles function prototypes correctly.
1135#
1136# If you use this macro, you should check after calling it whether the C
1137# compiler has been set to accept ANSI C; if not, the shell variable
1138# @code{am_cv_prog_cc_stdc} is set to @samp{no}.  If you wrote your source
1139# code in ANSI C, you can make an un-ANSIfied copy of it by using the
1140# program @code{ansi2knr}, which comes with Ghostscript.
1141# @end defmac
1142
1143AC_DEFUN([AM_PROG_CC_STDC],
1144[AC_REQUIRE([AC_PROG_CC])
1145AC_BEFORE([$0], [AC_C_INLINE])
1146AC_BEFORE([$0], [AC_C_CONST])
1147dnl Force this before AC_PROG_CPP.  Some cpp's, eg on HPUX, require
1148dnl a magic option to avoid problems with ANSI preprocessor commands
1149dnl like #elif.
1150dnl FIXME: can't do this because then AC_AIX won't work due to a
1151dnl circular dependency.
1152dnl AC_BEFORE([$0], [AC_PROG_CPP])
1153AC_MSG_CHECKING([for ${CC-cc} option to accept ANSI C])
1154AC_CACHE_VAL(am_cv_prog_cc_stdc,
1155[am_cv_prog_cc_stdc=no
1156ac_save_CC="$CC"
1157# Don't try gcc -ansi; that turns off useful extensions and
1158# breaks some systems' header files.
1159# AIX                   -qlanglvl=ansi
1160# Ultrix and OSF/1      -std1
1161# HP-UX 10.20 and later -Ae
1162# HP-UX older versions  -Aa -D_HPUX_SOURCE
1163# SVR4                  -Xc -D__EXTENSIONS__
1164for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1165do
1166  CC="$ac_save_CC $ac_arg"
1167  AC_TRY_COMPILE(
1168[#include <stdarg.h>
1169#include <stdio.h>
1170#include <sys/types.h>
1171#include <sys/stat.h>
1172/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
1173struct buf { int x; };
1174FILE * (*rcsopen) (struct buf *, struct stat *, int);
1175static char *e (p, i)
1176     char **p;
1177     int i;
1178{
1179  return p[i];
1180}
1181static char *f (char * (*g) (char **, int), char **p, ...)
1182{
1183  char *s;
1184  va_list v;
1185  va_start (v,p);
1186  s = g (p, va_arg (v,int));
1187  va_end (v);
1188  return s;
1189}
1190int test (int i, double x);
1191struct s1 {int (*f) (int a);};
1192struct s2 {int (*f) (double a);};
1193int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1194int argc;
1195char **argv;
1196], [
1197return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
1198],
1199[am_cv_prog_cc_stdc="$ac_arg"; break])
1200done
1201CC="$ac_save_CC"
1202])
1203if test -z "$am_cv_prog_cc_stdc"; then
1204  AC_MSG_RESULT([none needed])
1205else
1206  AC_MSG_RESULT([$am_cv_prog_cc_stdc])
1207fi
1208case "x$am_cv_prog_cc_stdc" in
1209  x|xno) ;;
1210  *) CC="$CC $am_cv_prog_cc_stdc" ;;
1211esac
1212])
1213
1214AU_DEFUN([fp_PROG_CC_STDC], [AM_PROG_CC_STDC])
1215
1216# Add --enable-maintainer-mode option to configure.
1217# From Jim Meyering
1218
1219# Copyright 1996, 1998, 2000, 2001, 2002  Free Software Foundation, Inc.
1220
1221# This program is free software; you can redistribute it and/or modify
1222# it under the terms of the GNU General Public License as published by
1223# the Free Software Foundation; either version 2, or (at your option)
1224# any later version.
1225
1226# This program is distributed in the hope that it will be useful,
1227# but WITHOUT ANY WARRANTY; without even the implied warranty of
1228# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1229# GNU General Public License for more details.
1230
1231# You should have received a copy of the GNU General Public License
1232# along with this program; if not, write to the Free Software
1233# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
1234# 02111-1307, USA.
1235
1236# serial 2
1237
1238AC_DEFUN([AM_MAINTAINER_MODE],
1239[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
1240  dnl maintainer-mode is disabled by default
1241  AC_ARG_ENABLE(maintainer-mode,
1242[  --enable-maintainer-mode enable make rules and dependencies not useful
1243                          (and sometimes confusing) to the casual installer],
1244      USE_MAINTAINER_MODE=$enableval,
1245      USE_MAINTAINER_MODE=no)
1246  AC_MSG_RESULT([$USE_MAINTAINER_MODE])
1247  AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
1248  MAINT=$MAINTAINER_MODE_TRUE
1249  AC_SUBST(MAINT)dnl
1250]
1251)
1252
1253AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
1254
1255
1256dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not)
1257dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page
1258dnl also defines GSTUFF_PKG_ERRORS on error
1259AC_DEFUN(PKG_CHECK_MODULES, [
1260  succeeded=no
1261
1262  if test -z "$PKG_CONFIG"; then
1263    AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
1264  fi
1265
1266  if test "$PKG_CONFIG" = "no" ; then
1267     echo "*** The pkg-config script could not be found. Make sure it is"
1268     echo "*** in your path, or set the PKG_CONFIG environment variable"
1269     echo "*** to the full path to pkg-config."
1270     echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
1271  else
1272     PKG_CONFIG_MIN_VERSION=0.9.0
1273     if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
1274        AC_MSG_CHECKING(for $2)
1275
1276        if $PKG_CONFIG --exists "$2" ; then
1277            AC_MSG_RESULT(yes)
1278            succeeded=yes
1279
1280            AC_MSG_CHECKING($1_CFLAGS)
1281            $1_CFLAGS=`$PKG_CONFIG --cflags "$2"`
1282            AC_MSG_RESULT($$1_CFLAGS)
1283
1284            AC_MSG_CHECKING($1_LIBS)
1285            $1_LIBS=`$PKG_CONFIG --libs "$2"`
1286            AC_MSG_RESULT($$1_LIBS)
1287        else
1288            $1_CFLAGS=""
1289            $1_LIBS=""
1290            ## If we have a custom action on failure, don't print errors, but
1291            ## do set a variable so people can do so.
1292            $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
1293            ifelse([$4], ,echo $$1_PKG_ERRORS,)
1294        fi
1295
1296        AC_SUBST($1_CFLAGS)
1297        AC_SUBST($1_LIBS)
1298     else
1299        echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
1300        echo "*** See http://www.freedesktop.org/software/pkgconfig"
1301     fi
1302  fi
1303
1304  if test $succeeded = yes; then
1305     ifelse([$3], , :, [$3])
1306  else
1307     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])
1308  fi
1309])
1310
1311
1312
1313# Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
1314
1315# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
1316
1317# This program is free software; you can redistribute it and/or modify
1318# it under the terms of the GNU General Public License as published by
1319# the Free Software Foundation; either version 2, or (at your option)
1320# any later version.
1321
1322# This program is distributed in the hope that it will be useful,
1323# but WITHOUT ANY WARRANTY; without even the implied warranty of
1324# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1325# GNU General Public License for more details.
1326
1327# You should have received a copy of the GNU General Public License
1328# along with this program; if not, write to the Free Software
1329# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
1330# 02111-1307, USA.
1331
1332AC_PREREQ([2.52])
1333
1334# serial 6
1335
1336# AM_CONFIG_HEADER is obsolete.  It has been replaced by AC_CONFIG_HEADERS.
1337AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
1338
Note: See TracBrowser for help on using the repository browser.