source: trunk/third/libgsf/aclocal.m4 @ 22006

Revision 22006, 243.6 KB checked in by ghudson, 19 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r22005, 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
14dnl
15dnl This is a dummy file. Copy acinclude.m4.am15 over this if you have
16dnl automake >= 1.5 and want to build with python bindings. See
17dnl python/README-python
18dnl
19
20# Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
21
22# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
23
24# This program is free software; you can redistribute it and/or modify
25# it under the terms of the GNU General Public License as published by
26# the Free Software Foundation; either version 2, or (at your option)
27# any later version.
28
29# This program is distributed in the hope that it will be useful,
30# but WITHOUT ANY WARRANTY; without even the implied warranty of
31# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
32# GNU General Public License for more details.
33
34# You should have received a copy of the GNU General Public License
35# along with this program; if not, write to the Free Software
36# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
37# 02111-1307, USA.
38
39AC_PREREQ([2.52])
40
41# serial 6
42
43# AM_CONFIG_HEADER is obsolete.  It has been replaced by AC_CONFIG_HEADERS.
44AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
45
46# Do all the work for Automake.                            -*- Autoconf -*-
47
48# This macro actually does too much some checks are only needed if
49# your package does certain things.  But this isn't really a big deal.
50
51# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
52# Free Software Foundation, Inc.
53
54# This program is free software; you can redistribute it and/or modify
55# it under the terms of the GNU General Public License as published by
56# the Free Software Foundation; either version 2, or (at your option)
57# any later version.
58
59# This program is distributed in the hope that it will be useful,
60# but WITHOUT ANY WARRANTY; without even the implied warranty of
61# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
62# GNU General Public License for more details.
63
64# You should have received a copy of the GNU General Public License
65# along with this program; if not, write to the Free Software
66# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
67# 02111-1307, USA.
68
69# serial 10
70
71AC_PREREQ([2.54])
72
73# Autoconf 2.50 wants to disallow AM_ names.  We explicitly allow
74# the ones we care about.
75m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
76
77# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
78# AM_INIT_AUTOMAKE([OPTIONS])
79# -----------------------------------------------
80# The call with PACKAGE and VERSION arguments is the old style
81# call (pre autoconf-2.50), which is being phased out.  PACKAGE
82# and VERSION should now be passed to AC_INIT and removed from
83# the call to AM_INIT_AUTOMAKE.
84# We support both call styles for the transition.  After
85# the next Automake release, Autoconf can make the AC_INIT
86# arguments mandatory, and then we can depend on a new Autoconf
87# release and drop the old call support.
88AC_DEFUN([AM_INIT_AUTOMAKE],
89[AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
90 AC_REQUIRE([AC_PROG_INSTALL])dnl
91# test to see if srcdir already configured
92if test "`cd $srcdir && pwd`" != "`pwd`" &&
93   test -f $srcdir/config.status; then
94  AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
95fi
96
97# test whether we have cygpath
98if test -z "$CYGPATH_W"; then
99  if (cygpath --version) >/dev/null 2>/dev/null; then
100    CYGPATH_W='cygpath -w'
101  else
102    CYGPATH_W=echo
103  fi
104fi
105AC_SUBST([CYGPATH_W])
106
107# Define the identity of the package.
108dnl Distinguish between old-style and new-style calls.
109m4_ifval([$2],
110[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
111 AC_SUBST([PACKAGE], [$1])dnl
112 AC_SUBST([VERSION], [$2])],
113[_AM_SET_OPTIONS([$1])dnl
114 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
115 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
116
117_AM_IF_OPTION([no-define],,
118[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
119 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
120
121# Some tools Automake needs.
122AC_REQUIRE([AM_SANITY_CHECK])dnl
123AC_REQUIRE([AC_ARG_PROGRAM])dnl
124AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
125AM_MISSING_PROG(AUTOCONF, autoconf)
126AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
127AM_MISSING_PROG(AUTOHEADER, autoheader)
128AM_MISSING_PROG(MAKEINFO, makeinfo)
129AM_MISSING_PROG(AMTAR, tar)
130AM_PROG_INSTALL_SH
131AM_PROG_INSTALL_STRIP
132# We need awk for the "check" target.  The system "awk" is bad on
133# some platforms.
134AC_REQUIRE([AC_PROG_AWK])dnl
135AC_REQUIRE([AC_PROG_MAKE_SET])dnl
136AC_REQUIRE([AM_SET_LEADING_DOT])dnl
137
138_AM_IF_OPTION([no-dependencies],,
139[AC_PROVIDE_IFELSE([AC_PROG_CC],
140                  [_AM_DEPENDENCIES(CC)],
141                  [define([AC_PROG_CC],
142                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
143AC_PROVIDE_IFELSE([AC_PROG_CXX],
144                  [_AM_DEPENDENCIES(CXX)],
145                  [define([AC_PROG_CXX],
146                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
147])
148])
149
150
151# When config.status generates a header, we must update the stamp-h file.
152# This file resides in the same directory as the config header
153# that is generated.  The stamp files are numbered to have different names.
154
155# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
156# loop where config.status creates the headers, so we can generate
157# our stamp files there.
158AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
159[# Compute $1's index in $config_headers.
160_am_stamp_count=1
161for _am_header in $config_headers :; do
162  case $_am_header in
163    $1 | $1:* )
164      break ;;
165    * )
166      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
167  esac
168done
169echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
170
171# Copyright 2002  Free Software Foundation, Inc.
172
173# This program is free software; you can redistribute it and/or modify
174# it under the terms of the GNU General Public License as published by
175# the Free Software Foundation; either version 2, or (at your option)
176# any later version.
177
178# This program is distributed in the hope that it will be useful,
179# but WITHOUT ANY WARRANTY; without even the implied warranty of
180# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
181# GNU General Public License for more details.
182
183# You should have received a copy of the GNU General Public License
184# along with this program; if not, write to the Free Software
185# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
186
187# AM_AUTOMAKE_VERSION(VERSION)
188# ----------------------------
189# Automake X.Y traces this macro to ensure aclocal.m4 has been
190# generated from the m4 files accompanying Automake X.Y.
191AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.7"])
192
193# AM_SET_CURRENT_AUTOMAKE_VERSION
194# -------------------------------
195# Call AM_AUTOMAKE_VERSION so it can be traced.
196# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
197AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
198         [AM_AUTOMAKE_VERSION([1.7.9])])
199
200# Helper functions for option handling.                    -*- Autoconf -*-
201
202# Copyright 2001, 2002  Free Software Foundation, Inc.
203
204# This program is free software; you can redistribute it and/or modify
205# it under the terms of the GNU General Public License as published by
206# the Free Software Foundation; either version 2, or (at your option)
207# any later version.
208
209# This program is distributed in the hope that it will be useful,
210# but WITHOUT ANY WARRANTY; without even the implied warranty of
211# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
212# GNU General Public License for more details.
213
214# You should have received a copy of the GNU General Public License
215# along with this program; if not, write to the Free Software
216# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
217# 02111-1307, USA.
218
219# serial 2
220
221# _AM_MANGLE_OPTION(NAME)
222# -----------------------
223AC_DEFUN([_AM_MANGLE_OPTION],
224[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
225
226# _AM_SET_OPTION(NAME)
227# ------------------------------
228# Set option NAME.  Presently that only means defining a flag for this option.
229AC_DEFUN([_AM_SET_OPTION],
230[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
231
232# _AM_SET_OPTIONS(OPTIONS)
233# ----------------------------------
234# OPTIONS is a space-separated list of Automake options.
235AC_DEFUN([_AM_SET_OPTIONS],
236[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
237
238# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
239# -------------------------------------------
240# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
241AC_DEFUN([_AM_IF_OPTION],
242[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
243
244#
245# Check to make sure that the build environment is sane.
246#
247
248# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
249
250# This program is free software; you can redistribute it and/or modify
251# it under the terms of the GNU General Public License as published by
252# the Free Software Foundation; either version 2, or (at your option)
253# any later version.
254
255# This program is distributed in the hope that it will be useful,
256# but WITHOUT ANY WARRANTY; without even the implied warranty of
257# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
258# GNU General Public License for more details.
259
260# You should have received a copy of the GNU General Public License
261# along with this program; if not, write to the Free Software
262# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
263# 02111-1307, USA.
264
265# serial 3
266
267# AM_SANITY_CHECK
268# ---------------
269AC_DEFUN([AM_SANITY_CHECK],
270[AC_MSG_CHECKING([whether build environment is sane])
271# Just in case
272sleep 1
273echo timestamp > conftest.file
274# Do `set' in a subshell so we don't clobber the current shell's
275# arguments.  Must try -L first in case configure is actually a
276# symlink; some systems play weird games with the mod time of symlinks
277# (eg FreeBSD returns the mod time of the symlink's containing
278# directory).
279if (
280   set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
281   if test "$[*]" = "X"; then
282      # -L didn't work.
283      set X `ls -t $srcdir/configure conftest.file`
284   fi
285   rm -f conftest.file
286   if test "$[*]" != "X $srcdir/configure conftest.file" \
287      && test "$[*]" != "X conftest.file $srcdir/configure"; then
288
289      # If neither matched, then we have a broken ls.  This can happen
290      # if, for instance, CONFIG_SHELL is bash and it inherits a
291      # broken ls alias from the environment.  This has actually
292      # happened.  Such a system could not be considered "sane".
293      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
294alias in your environment])
295   fi
296
297   test "$[2]" = conftest.file
298   )
299then
300   # Ok.
301   :
302else
303   AC_MSG_ERROR([newly created file is older than distributed files!
304Check your system clock])
305fi
306AC_MSG_RESULT(yes)])
307
308#  -*- Autoconf -*-
309
310
311# Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
312
313# This program is free software; you can redistribute it and/or modify
314# it under the terms of the GNU General Public License as published by
315# the Free Software Foundation; either version 2, or (at your option)
316# any later version.
317
318# This program is distributed in the hope that it will be useful,
319# but WITHOUT ANY WARRANTY; without even the implied warranty of
320# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
321# GNU General Public License for more details.
322
323# You should have received a copy of the GNU General Public License
324# along with this program; if not, write to the Free Software
325# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
326# 02111-1307, USA.
327
328# serial 3
329
330# AM_MISSING_PROG(NAME, PROGRAM)
331# ------------------------------
332AC_DEFUN([AM_MISSING_PROG],
333[AC_REQUIRE([AM_MISSING_HAS_RUN])
334$1=${$1-"${am_missing_run}$2"}
335AC_SUBST($1)])
336
337
338# AM_MISSING_HAS_RUN
339# ------------------
340# Define MISSING if not defined so far and test if it supports --run.
341# If it does, set am_missing_run to use it, otherwise, to nothing.
342AC_DEFUN([AM_MISSING_HAS_RUN],
343[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
344test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
345# Use eval to expand $SHELL
346if eval "$MISSING --run true"; then
347  am_missing_run="$MISSING --run "
348else
349  am_missing_run=
350  AC_MSG_WARN([`missing' script is too old or missing])
351fi
352])
353
354# AM_AUX_DIR_EXPAND
355
356# Copyright 2001 Free Software Foundation, Inc.
357
358# This program is free software; you can redistribute it and/or modify
359# it under the terms of the GNU General Public License as published by
360# the Free Software Foundation; either version 2, or (at your option)
361# any later version.
362
363# This program is distributed in the hope that it will be useful,
364# but WITHOUT ANY WARRANTY; without even the implied warranty of
365# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
366# GNU General Public License for more details.
367
368# You should have received a copy of the GNU General Public License
369# along with this program; if not, write to the Free Software
370# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
371# 02111-1307, USA.
372
373# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
374# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
375# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
376#
377# Of course, Automake must honor this variable whenever it calls a
378# tool from the auxiliary directory.  The problem is that $srcdir (and
379# therefore $ac_aux_dir as well) can be either absolute or relative,
380# depending on how configure is run.  This is pretty annoying, since
381# it makes $ac_aux_dir quite unusable in subdirectories: in the top
382# source directory, any form will work fine, but in subdirectories a
383# relative path needs to be adjusted first.
384#
385# $ac_aux_dir/missing
386#    fails when called from a subdirectory if $ac_aux_dir is relative
387# $top_srcdir/$ac_aux_dir/missing
388#    fails if $ac_aux_dir is absolute,
389#    fails when called from a subdirectory in a VPATH build with
390#          a relative $ac_aux_dir
391#
392# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
393# are both prefixed by $srcdir.  In an in-source build this is usually
394# harmless because $srcdir is `.', but things will broke when you
395# start a VPATH build or use an absolute $srcdir.
396#
397# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
398# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
399#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
400# and then we would define $MISSING as
401#   MISSING="\${SHELL} $am_aux_dir/missing"
402# This will work as long as MISSING is not called from configure, because
403# unfortunately $(top_srcdir) has no meaning in configure.
404# However there are other variables, like CC, which are often used in
405# configure, and could therefore not use this "fixed" $ac_aux_dir.
406#
407# Another solution, used here, is to always expand $ac_aux_dir to an
408# absolute PATH.  The drawback is that using absolute paths prevent a
409# configured tree to be moved without reconfiguration.
410
411# Rely on autoconf to set up CDPATH properly.
412AC_PREREQ([2.50])
413
414AC_DEFUN([AM_AUX_DIR_EXPAND], [
415# expand $ac_aux_dir to an absolute path
416am_aux_dir=`cd $ac_aux_dir && pwd`
417])
418
419# AM_PROG_INSTALL_SH
420# ------------------
421# Define $install_sh.
422
423# Copyright 2001 Free Software Foundation, Inc.
424
425# This program is free software; you can redistribute it and/or modify
426# it under the terms of the GNU General Public License as published by
427# the Free Software Foundation; either version 2, or (at your option)
428# any later version.
429
430# This program is distributed in the hope that it will be useful,
431# but WITHOUT ANY WARRANTY; without even the implied warranty of
432# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
433# GNU General Public License for more details.
434
435# You should have received a copy of the GNU General Public License
436# along with this program; if not, write to the Free Software
437# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
438# 02111-1307, USA.
439
440AC_DEFUN([AM_PROG_INSTALL_SH],
441[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
442install_sh=${install_sh-"$am_aux_dir/install-sh"}
443AC_SUBST(install_sh)])
444
445# AM_PROG_INSTALL_STRIP
446
447# Copyright 2001 Free Software Foundation, Inc.
448
449# This program is free software; you can redistribute it and/or modify
450# it under the terms of the GNU General Public License as published by
451# the Free Software Foundation; either version 2, or (at your option)
452# any later version.
453
454# This program is distributed in the hope that it will be useful,
455# but WITHOUT ANY WARRANTY; without even the implied warranty of
456# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
457# GNU General Public License for more details.
458
459# You should have received a copy of the GNU General Public License
460# along with this program; if not, write to the Free Software
461# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
462# 02111-1307, USA.
463
464# One issue with vendor `install' (even GNU) is that you can't
465# specify the program used to strip binaries.  This is especially
466# annoying in cross-compiling environments, where the build's strip
467# is unlikely to handle the host's binaries.
468# Fortunately install-sh will honor a STRIPPROG variable, so we
469# always use install-sh in `make install-strip', and initialize
470# STRIPPROG with the value of the STRIP variable (set by the user).
471AC_DEFUN([AM_PROG_INSTALL_STRIP],
472[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
473# Installed binaries are usually stripped using `strip' when the user
474# run `make install-strip'.  However `strip' might not be the right
475# tool to use in cross-compilation environments, therefore Automake
476# will honor the `STRIP' environment variable to overrule this program.
477dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
478if test "$cross_compiling" != no; then
479  AC_CHECK_TOOL([STRIP], [strip], :)
480fi
481INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
482AC_SUBST([INSTALL_STRIP_PROGRAM])])
483
484#                                                          -*- Autoconf -*-
485# Copyright (C) 2003  Free Software Foundation, Inc.
486
487# This program is free software; you can redistribute it and/or modify
488# it under the terms of the GNU General Public License as published by
489# the Free Software Foundation; either version 2, or (at your option)
490# any later version.
491
492# This program is distributed in the hope that it will be useful,
493# but WITHOUT ANY WARRANTY; without even the implied warranty of
494# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
495# GNU General Public License for more details.
496
497# You should have received a copy of the GNU General Public License
498# along with this program; if not, write to the Free Software
499# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
500# 02111-1307, USA.
501
502# serial 1
503
504# Check whether the underlying file-system supports filenames
505# with a leading dot.  For instance MS-DOS doesn't.
506AC_DEFUN([AM_SET_LEADING_DOT],
507[rm -rf .tst 2>/dev/null
508mkdir .tst 2>/dev/null
509if test -d .tst; then
510  am__leading_dot=.
511else
512  am__leading_dot=_
513fi
514rmdir .tst 2>/dev/null
515AC_SUBST([am__leading_dot])])
516
517# serial 5                                              -*- Autoconf -*-
518
519# Copyright (C) 1999, 2000, 2001, 2002, 2003  Free Software Foundation, Inc.
520
521# This program is free software; you can redistribute it and/or modify
522# it under the terms of the GNU General Public License as published by
523# the Free Software Foundation; either version 2, or (at your option)
524# any later version.
525
526# This program is distributed in the hope that it will be useful,
527# but WITHOUT ANY WARRANTY; without even the implied warranty of
528# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
529# GNU General Public License for more details.
530
531# You should have received a copy of the GNU General Public License
532# along with this program; if not, write to the Free Software
533# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
534# 02111-1307, USA.
535
536
537# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
538# written in clear, in which case automake, when reading aclocal.m4,
539# will think it sees a *use*, and therefore will trigger all it's
540# C support machinery.  Also note that it means that autoscan, seeing
541# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
542
543
544
545# _AM_DEPENDENCIES(NAME)
546# ----------------------
547# See how the compiler implements dependency checking.
548# NAME is "CC", "CXX", "GCJ", or "OBJC".
549# We try a few techniques and use that to set a single cache variable.
550#
551# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
552# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
553# dependency, and given that the user is not expected to run this macro,
554# just rely on AC_PROG_CC.
555AC_DEFUN([_AM_DEPENDENCIES],
556[AC_REQUIRE([AM_SET_DEPDIR])dnl
557AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
558AC_REQUIRE([AM_MAKE_INCLUDE])dnl
559AC_REQUIRE([AM_DEP_TRACK])dnl
560
561ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
562       [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
563       [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
564       [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
565                   [depcc="$$1"   am_compiler_list=])
566
567AC_CACHE_CHECK([dependency style of $depcc],
568               [am_cv_$1_dependencies_compiler_type],
569[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
570  # We make a subdir and do the tests there.  Otherwise we can end up
571  # making bogus files that we don't know about and never remove.  For
572  # instance it was reported that on HP-UX the gcc test will end up
573  # making a dummy file named `D' -- because `-MD' means `put the output
574  # in D'.
575  mkdir conftest.dir
576  # Copy depcomp to subdir because otherwise we won't find it if we're
577  # using a relative directory.
578  cp "$am_depcomp" conftest.dir
579  cd conftest.dir
580  # We will build objects and dependencies in a subdirectory because
581  # it helps to detect inapplicable dependency modes.  For instance
582  # both Tru64's cc and ICC support -MD to output dependencies as a
583  # side effect of compilation, but ICC will put the dependencies in
584  # the current directory while Tru64 will put them in the object
585  # directory.
586  mkdir sub
587
588  am_cv_$1_dependencies_compiler_type=none
589  if test "$am_compiler_list" = ""; then
590     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
591  fi
592  for depmode in $am_compiler_list; do
593    # Setup a source with many dependencies, because some compilers
594    # like to wrap large dependency lists on column 80 (with \), and
595    # we should not choose a depcomp mode which is confused by this.
596    #
597    # We need to recreate these files for each test, as the compiler may
598    # overwrite some of them when testing with obscure command lines.
599    # This happens at least with the AIX C compiler.
600    : > sub/conftest.c
601    for i in 1 2 3 4 5 6; do
602      echo '#include "conftst'$i'.h"' >> sub/conftest.c
603      : > sub/conftst$i.h
604    done
605    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
606
607    case $depmode in
608    nosideeffect)
609      # after this tag, mechanisms are not by side-effect, so they'll
610      # only be used when explicitly requested
611      if test "x$enable_dependency_tracking" = xyes; then
612        continue
613      else
614        break
615      fi
616      ;;
617    none) break ;;
618    esac
619    # We check with `-c' and `-o' for the sake of the "dashmstdout"
620    # mode.  It turns out that the SunPro C++ compiler does not properly
621    # handle `-M -o', and we need to detect this.
622    if depmode=$depmode \
623       source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
624       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
625       $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
626         >/dev/null 2>conftest.err &&
627       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
628       grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
629       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
630      # icc doesn't choke on unknown options, it will just issue warnings
631      # (even with -Werror).  So we grep stderr for any message
632      # that says an option was ignored.
633      if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
634        am_cv_$1_dependencies_compiler_type=$depmode
635        break
636      fi
637    fi
638  done
639
640  cd ..
641  rm -rf conftest.dir
642else
643  am_cv_$1_dependencies_compiler_type=none
644fi
645])
646AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
647AM_CONDITIONAL([am__fastdep$1], [
648  test "x$enable_dependency_tracking" != xno \
649  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
650])
651
652
653# AM_SET_DEPDIR
654# -------------
655# Choose a directory name for dependency files.
656# This macro is AC_REQUIREd in _AM_DEPENDENCIES
657AC_DEFUN([AM_SET_DEPDIR],
658[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
659AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
660])
661
662
663# AM_DEP_TRACK
664# ------------
665AC_DEFUN([AM_DEP_TRACK],
666[AC_ARG_ENABLE(dependency-tracking,
667[  --disable-dependency-tracking Speeds up one-time builds
668  --enable-dependency-tracking  Do not reject slow dependency extractors])
669if test "x$enable_dependency_tracking" != xno; then
670  am_depcomp="$ac_aux_dir/depcomp"
671  AMDEPBACKSLASH='\'
672fi
673AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
674AC_SUBST([AMDEPBACKSLASH])
675])
676
677# Generate code to set up dependency tracking.   -*- Autoconf -*-
678
679# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
680
681# This program is free software; you can redistribute it and/or modify
682# it under the terms of the GNU General Public License as published by
683# the Free Software Foundation; either version 2, or (at your option)
684# any later version.
685
686# This program is distributed in the hope that it will be useful,
687# but WITHOUT ANY WARRANTY; without even the implied warranty of
688# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
689# GNU General Public License for more details.
690
691# You should have received a copy of the GNU General Public License
692# along with this program; if not, write to the Free Software
693# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
694# 02111-1307, USA.
695
696#serial 2
697
698# _AM_OUTPUT_DEPENDENCY_COMMANDS
699# ------------------------------
700AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
701[for mf in $CONFIG_FILES; do
702  # Strip MF so we end up with the name of the file.
703  mf=`echo "$mf" | sed -e 's/:.*$//'`
704  # Check whether this is an Automake generated Makefile or not.
705  # We used to match only the files named `Makefile.in', but
706  # some people rename them; so instead we look at the file content.
707  # Grep'ing the first line is not enough: some people post-process
708  # each Makefile.in and add a new line on top of each file to say so.
709  # So let's grep whole file.
710  if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
711    dirpart=`AS_DIRNAME("$mf")`
712  else
713    continue
714  fi
715  grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
716  # Extract the definition of DEP_FILES from the Makefile without
717  # running `make'.
718  DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
719  test -z "$DEPDIR" && continue
720  # When using ansi2knr, U may be empty or an underscore; expand it
721  U=`sed -n -e '/^U = / s///p' < "$mf"`
722  test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
723  # We invoke sed twice because it is the simplest approach to
724  # changing $(DEPDIR) to its actual value in the expansion.
725  for file in `sed -n -e '
726    /^DEP_FILES = .*\\\\$/ {
727      s/^DEP_FILES = //
728      :loop
729        s/\\\\$//
730        p
731        n
732        /\\\\$/ b loop
733      p
734    }
735    /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
736       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
737    # Make sure the directory exists.
738    test -f "$dirpart/$file" && continue
739    fdir=`AS_DIRNAME(["$file"])`
740    AS_MKDIR_P([$dirpart/$fdir])
741    # echo "creating $dirpart/$file"
742    echo '# dummy' > "$dirpart/$file"
743  done
744done
745])# _AM_OUTPUT_DEPENDENCY_COMMANDS
746
747
748# AM_OUTPUT_DEPENDENCY_COMMANDS
749# -----------------------------
750# This macro should only be invoked once -- use via AC_REQUIRE.
751#
752# This code is only required when automatic dependency tracking
753# is enabled.  FIXME.  This creates each `.P' file that we will
754# need in order to bootstrap the dependency handling code.
755AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
756[AC_CONFIG_COMMANDS([depfiles],
757     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
758     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
759])
760
761# Check to see how 'make' treats includes.      -*- Autoconf -*-
762
763# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
764
765# This program is free software; you can redistribute it and/or modify
766# it under the terms of the GNU General Public License as published by
767# the Free Software Foundation; either version 2, or (at your option)
768# any later version.
769
770# This program is distributed in the hope that it will be useful,
771# but WITHOUT ANY WARRANTY; without even the implied warranty of
772# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
773# GNU General Public License for more details.
774
775# You should have received a copy of the GNU General Public License
776# along with this program; if not, write to the Free Software
777# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
778# 02111-1307, USA.
779
780# serial 2
781
782# AM_MAKE_INCLUDE()
783# -----------------
784# Check to see how make treats includes.
785AC_DEFUN([AM_MAKE_INCLUDE],
786[am_make=${MAKE-make}
787cat > confinc << 'END'
788am__doit:
789        @echo done
790.PHONY: am__doit
791END
792# If we don't find an include directive, just comment out the code.
793AC_MSG_CHECKING([for style of include used by $am_make])
794am__include="#"
795am__quote=
796_am_result=none
797# First try GNU make style include.
798echo "include confinc" > confmf
799# We grep out `Entering directory' and `Leaving directory'
800# messages which can occur if `w' ends up in MAKEFLAGS.
801# In particular we don't look at `^make:' because GNU make might
802# be invoked under some other name (usually "gmake"), in which
803# case it prints its new name instead of `make'.
804if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
805   am__include=include
806   am__quote=
807   _am_result=GNU
808fi
809# Now try BSD make style include.
810if test "$am__include" = "#"; then
811   echo '.include "confinc"' > confmf
812   if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
813      am__include=.include
814      am__quote="\""
815      _am_result=BSD
816   fi
817fi
818AC_SUBST([am__include])
819AC_SUBST([am__quote])
820AC_MSG_RESULT([$_am_result])
821rm -f confinc confmf
822])
823
824# AM_CONDITIONAL                                              -*- Autoconf -*-
825
826# Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
827
828# This program is free software; you can redistribute it and/or modify
829# it under the terms of the GNU General Public License as published by
830# the Free Software Foundation; either version 2, or (at your option)
831# any later version.
832
833# This program is distributed in the hope that it will be useful,
834# but WITHOUT ANY WARRANTY; without even the implied warranty of
835# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
836# GNU General Public License for more details.
837
838# You should have received a copy of the GNU General Public License
839# along with this program; if not, write to the Free Software
840# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
841# 02111-1307, USA.
842
843# serial 5
844
845AC_PREREQ(2.52)
846
847# AM_CONDITIONAL(NAME, SHELL-CONDITION)
848# -------------------------------------
849# Define a conditional.
850AC_DEFUN([AM_CONDITIONAL],
851[ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
852        [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
853AC_SUBST([$1_TRUE])
854AC_SUBST([$1_FALSE])
855if $2; then
856  $1_TRUE=
857  $1_FALSE='#'
858else
859  $1_TRUE='#'
860  $1_FALSE=
861fi
862AC_CONFIG_COMMANDS_PRE(
863[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
864  AC_MSG_ERROR([conditional "$1" was never defined.
865Usually this means the macro was only invoked conditionally.])
866fi])])
867
868# Add --enable-maintainer-mode option to configure.
869# From Jim Meyering
870
871# Copyright 1996, 1998, 2000, 2001, 2002  Free Software Foundation, Inc.
872
873# This program is free software; you can redistribute it and/or modify
874# it under the terms of the GNU General Public License as published by
875# the Free Software Foundation; either version 2, or (at your option)
876# any later version.
877
878# This program is distributed in the hope that it will be useful,
879# but WITHOUT ANY WARRANTY; without even the implied warranty of
880# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
881# GNU General Public License for more details.
882
883# You should have received a copy of the GNU General Public License
884# along with this program; if not, write to the Free Software
885# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
886# 02111-1307, USA.
887
888# serial 2
889
890AC_DEFUN([AM_MAINTAINER_MODE],
891[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
892  dnl maintainer-mode is disabled by default
893  AC_ARG_ENABLE(maintainer-mode,
894[  --enable-maintainer-mode enable make rules and dependencies not useful
895                          (and sometimes confusing) to the casual installer],
896      USE_MAINTAINER_MODE=$enableval,
897      USE_MAINTAINER_MODE=no)
898  AC_MSG_RESULT([$USE_MAINTAINER_MODE])
899  AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
900  MAINT=$MAINTAINER_MODE_TRUE
901  AC_SUBST(MAINT)dnl
902]
903)
904
905AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
906
907# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
908
909# serial 47 AC_PROG_LIBTOOL
910# Debian $Rev: 214 $
911
912
913# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
914# -----------------------------------------------------------
915# If this macro is not defined by Autoconf, define it here.
916m4_ifdef([AC_PROVIDE_IFELSE],
917         [],
918         [m4_define([AC_PROVIDE_IFELSE],
919                 [m4_ifdef([AC_PROVIDE_$1],
920                           [$2], [$3])])])
921
922
923# AC_PROG_LIBTOOL
924# ---------------
925AC_DEFUN([AC_PROG_LIBTOOL],
926[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
927dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
928dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
929  AC_PROVIDE_IFELSE([AC_PROG_CXX],
930    [AC_LIBTOOL_CXX],
931    [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
932  ])])
933dnl And a similar setup for Fortran 77 support
934  AC_PROVIDE_IFELSE([AC_PROG_F77],
935    [AC_LIBTOOL_F77],
936    [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
937])])
938
939dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
940dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
941dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
942  AC_PROVIDE_IFELSE([AC_PROG_GCJ],
943    [AC_LIBTOOL_GCJ],
944    [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
945      [AC_LIBTOOL_GCJ],
946      [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
947        [AC_LIBTOOL_GCJ],
948      [ifdef([AC_PROG_GCJ],
949             [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
950       ifdef([A][M_PROG_GCJ],
951             [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
952       ifdef([LT_AC_PROG_GCJ],
953             [define([LT_AC_PROG_GCJ],
954                defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
955])])# AC_PROG_LIBTOOL
956
957
958# _AC_PROG_LIBTOOL
959# ----------------
960AC_DEFUN([_AC_PROG_LIBTOOL],
961[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
962AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
963AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
964AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
965
966# This can be used to rebuild libtool when needed
967LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
968
969# Always use our own libtool.
970LIBTOOL='$(SHELL) $(top_builddir)/libtool'
971AC_SUBST(LIBTOOL)dnl
972
973# Prevent multiple expansion
974define([AC_PROG_LIBTOOL], [])
975])# _AC_PROG_LIBTOOL
976
977
978# AC_LIBTOOL_SETUP
979# ----------------
980AC_DEFUN([AC_LIBTOOL_SETUP],
981[AC_PREREQ(2.50)dnl
982AC_REQUIRE([AC_ENABLE_SHARED])dnl
983AC_REQUIRE([AC_ENABLE_STATIC])dnl
984AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
985AC_REQUIRE([AC_CANONICAL_HOST])dnl
986AC_REQUIRE([AC_CANONICAL_BUILD])dnl
987AC_REQUIRE([AC_PROG_CC])dnl
988AC_REQUIRE([AC_PROG_LD])dnl
989AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
990AC_REQUIRE([AC_PROG_NM])dnl
991
992AC_REQUIRE([AC_PROG_LN_S])dnl
993AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
994# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
995AC_REQUIRE([AC_OBJEXT])dnl
996AC_REQUIRE([AC_EXEEXT])dnl
997dnl
998
999AC_LIBTOOL_SYS_MAX_CMD_LEN
1000AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
1001AC_LIBTOOL_OBJDIR
1002
1003AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1004_LT_AC_PROG_ECHO_BACKSLASH
1005
1006case $host_os in
1007aix3*)
1008  # AIX sometimes has problems with the GCC collect2 program.  For some
1009  # reason, if we set the COLLECT_NAMES environment variable, the problems
1010  # vanish in a puff of smoke.
1011  if test "X${COLLECT_NAMES+set}" != Xset; then
1012    COLLECT_NAMES=
1013    export COLLECT_NAMES
1014  fi
1015  ;;
1016esac
1017
1018# Sed substitution that helps us do robust quoting.  It backslashifies
1019# metacharacters that are still active within double-quoted strings.
1020Xsed='sed -e s/^X//'
1021[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
1022
1023# Same as above, but do not quote variable references.
1024[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
1025
1026# Sed substitution to delay expansion of an escaped shell variable in a
1027# double_quote_subst'ed string.
1028delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1029
1030# Sed substitution to avoid accidental globbing in evaled expressions
1031no_glob_subst='s/\*/\\\*/g'
1032
1033# Constants:
1034rm="rm -f"
1035
1036# Global variables:
1037default_ofile=libtool
1038can_build_shared=yes
1039
1040# All known linkers require a `.a' archive for static linking (except M$VC,
1041# which needs '.lib').
1042libext=a
1043ltmain="$ac_aux_dir/ltmain.sh"
1044ofile="$default_ofile"
1045with_gnu_ld="$lt_cv_prog_gnu_ld"
1046
1047AC_CHECK_TOOL(AR, ar, false)
1048AC_CHECK_TOOL(RANLIB, ranlib, :)
1049AC_CHECK_TOOL(STRIP, strip, :)
1050
1051old_CC="$CC"
1052old_CFLAGS="$CFLAGS"
1053
1054# Set sane defaults for various variables
1055test -z "$AR" && AR=ar
1056test -z "$AR_FLAGS" && AR_FLAGS=cru
1057test -z "$AS" && AS=as
1058test -z "$CC" && CC=cc
1059test -z "$LTCC" && LTCC=$CC
1060test -z "$DLLTOOL" && DLLTOOL=dlltool
1061test -z "$LD" && LD=ld
1062test -z "$LN_S" && LN_S="ln -s"
1063test -z "$MAGIC_CMD" && MAGIC_CMD=file
1064test -z "$NM" && NM=nm
1065test -z "$SED" && SED=sed
1066test -z "$OBJDUMP" && OBJDUMP=objdump
1067test -z "$RANLIB" && RANLIB=:
1068test -z "$STRIP" && STRIP=:
1069test -z "$ac_objext" && ac_objext=o
1070
1071# Determine commands to create old-style static archives.
1072old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
1073old_postinstall_cmds='chmod 644 $oldlib'
1074old_postuninstall_cmds=
1075
1076if test -n "$RANLIB"; then
1077  case $host_os in
1078  openbsd*)
1079    old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
1080    ;;
1081  *)
1082    old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
1083    ;;
1084  esac
1085  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
1086fi
1087
1088# Only perform the check for file, if the check method requires it
1089case $deplibs_check_method in
1090file_magic*)
1091  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1092    AC_PATH_MAGIC
1093  fi
1094  ;;
1095esac
1096
1097AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
1098AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1099enable_win32_dll=yes, enable_win32_dll=no)
1100
1101AC_ARG_ENABLE([libtool-lock],
1102    [AC_HELP_STRING([--disable-libtool-lock],
1103        [avoid locking (might break parallel builds)])])
1104test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1105
1106AC_ARG_WITH([pic],
1107    [AC_HELP_STRING([--with-pic],
1108        [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
1109    [pic_mode="$withval"],
1110    [pic_mode=default])
1111test -z "$pic_mode" && pic_mode=default
1112
1113# Use C for the default configuration in the libtool script
1114tagname=
1115AC_LIBTOOL_LANG_C_CONFIG
1116_LT_AC_TAGCONFIG
1117])# AC_LIBTOOL_SETUP
1118
1119
1120# _LT_AC_SYS_COMPILER
1121# -------------------
1122AC_DEFUN([_LT_AC_SYS_COMPILER],
1123[AC_REQUIRE([AC_PROG_CC])dnl
1124
1125# If no C compiler was specified, use CC.
1126LTCC=${LTCC-"$CC"}
1127
1128# Allow CC to be a program name with arguments.
1129compiler=$CC
1130])# _LT_AC_SYS_COMPILER
1131
1132
1133# _LT_AC_SYS_LIBPATH_AIX
1134# ----------------------
1135# Links a minimal program and checks the executable
1136# for the system default hardcoded library path. In most cases,
1137# this is /usr/lib:/lib, but when the MPI compilers are used
1138# the location of the communication and MPI libs are included too.
1139# If we don't find anything, use the default library path according
1140# to the aix ld manual.
1141AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
1142[AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1143aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
1144}'`
1145# Check for a 64-bit object if we didn't find anything.
1146if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
1147}'`; fi],[])
1148if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1149])# _LT_AC_SYS_LIBPATH_AIX
1150
1151
1152# _LT_AC_SHELL_INIT(ARG)
1153# ----------------------
1154AC_DEFUN([_LT_AC_SHELL_INIT],
1155[ifdef([AC_DIVERSION_NOTICE],
1156             [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1157         [AC_DIVERT_PUSH(NOTICE)])
1158$1
1159AC_DIVERT_POP
1160])# _LT_AC_SHELL_INIT
1161
1162
1163# _LT_AC_PROG_ECHO_BACKSLASH
1164# --------------------------
1165# Add some code to the start of the generated configure script which
1166# will find an echo command which doesn't interpret backslashes.
1167AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
1168[_LT_AC_SHELL_INIT([
1169# Check that we are running under the correct shell.
1170SHELL=${CONFIG_SHELL-/bin/sh}
1171
1172case X$ECHO in
1173X*--fallback-echo)
1174  # Remove one level of quotation (which was required for Make).
1175  ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1176  ;;
1177esac
1178
1179echo=${ECHO-echo}
1180if test "X[$]1" = X--no-reexec; then
1181  # Discard the --no-reexec flag, and continue.
1182  shift
1183elif test "X[$]1" = X--fallback-echo; then
1184  # Avoid inline document here, it may be left over
1185  :
1186elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
1187  # Yippee, $echo works!
1188  :
1189else
1190  # Restart under the correct shell.
1191  exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1192fi
1193
1194if test "X[$]1" = X--fallback-echo; then
1195  # used as fallback echo
1196  shift
1197  cat <<EOF
1198[$]*
1199EOF
1200  exit 0
1201fi
1202
1203# The HP-UX ksh and POSIX shell print the target directory to stdout
1204# if CDPATH is set.
1205if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
1206
1207if test -z "$ECHO"; then
1208if test "X${echo_test_string+set}" != Xset; then
1209# find a string as large as possible, as long as the shell can cope with it
1210  for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1211    # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1212    if (echo_test_string="`eval $cmd`") 2>/dev/null &&
1213       echo_test_string="`eval $cmd`" &&
1214       (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
1215    then
1216      break
1217    fi
1218  done
1219fi
1220
1221if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1222   echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1223   test "X$echo_testing_string" = "X$echo_test_string"; then
1224  :
1225else
1226  # The Solaris, AIX, and Digital Unix default echo programs unquote
1227  # backslashes.  This makes it impossible to quote backslashes using
1228  #   echo "$something" | sed 's/\\/\\\\/g'
1229  #
1230  # So, first we look for a working echo in the user's PATH.
1231
1232  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1233  for dir in $PATH /usr/ucb; do
1234    IFS="$lt_save_ifs"
1235    if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1236       test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1237       echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1238       test "X$echo_testing_string" = "X$echo_test_string"; then
1239      echo="$dir/echo"
1240      break
1241    fi
1242  done
1243  IFS="$lt_save_ifs"
1244
1245  if test "X$echo" = Xecho; then
1246    # We didn't find a better echo, so look for alternatives.
1247    if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
1248       echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
1249       test "X$echo_testing_string" = "X$echo_test_string"; then
1250      # This shell has a builtin print -r that does the trick.
1251      echo='print -r'
1252    elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
1253         test "X$CONFIG_SHELL" != X/bin/ksh; then
1254      # If we have ksh, try running configure again with it.
1255      ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1256      export ORIGINAL_CONFIG_SHELL
1257      CONFIG_SHELL=/bin/ksh
1258      export CONFIG_SHELL
1259      exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1260    else
1261      # Try using printf.
1262      echo='printf %s\n'
1263      if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1264         echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1265         test "X$echo_testing_string" = "X$echo_test_string"; then
1266        # Cool, printf works
1267        :
1268      elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1269           test "X$echo_testing_string" = 'X\t' &&
1270           echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1271           test "X$echo_testing_string" = "X$echo_test_string"; then
1272        CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1273        export CONFIG_SHELL
1274        SHELL="$CONFIG_SHELL"
1275        export SHELL
1276        echo="$CONFIG_SHELL [$]0 --fallback-echo"
1277      elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1278           test "X$echo_testing_string" = 'X\t' &&
1279           echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1280           test "X$echo_testing_string" = "X$echo_test_string"; then
1281        echo="$CONFIG_SHELL [$]0 --fallback-echo"
1282      else
1283        # maybe with a smaller string...
1284        prev=:
1285
1286        for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1287          if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
1288          then
1289            break
1290          fi
1291          prev="$cmd"
1292        done
1293
1294        if test "$prev" != 'sed 50q "[$]0"'; then
1295          echo_test_string=`eval $prev`
1296          export echo_test_string
1297          exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1298        else
1299          # Oops.  We lost completely, so just stick with echo.
1300          echo=echo
1301        fi
1302      fi
1303    fi
1304  fi
1305fi
1306fi
1307
1308# Copy echo and quote the copy suitably for passing to libtool from
1309# the Makefile, instead of quoting the original, which is used later.
1310ECHO=$echo
1311if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1312   ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1313fi
1314
1315AC_SUBST(ECHO)
1316])])# _LT_AC_PROG_ECHO_BACKSLASH
1317
1318
1319# _LT_AC_LOCK
1320# -----------
1321AC_DEFUN([_LT_AC_LOCK],
1322[AC_ARG_ENABLE([libtool-lock],
1323    [AC_HELP_STRING([--disable-libtool-lock],
1324        [avoid locking (might break parallel builds)])])
1325test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1326
1327# Some flags need to be propagated to the compiler or linker for good
1328# libtool support.
1329case $host in
1330ia64-*-hpux*)
1331  # Find out which ABI we are using.
1332  echo 'int i;' > conftest.$ac_ext
1333  if AC_TRY_EVAL(ac_compile); then
1334    case `/usr/bin/file conftest.$ac_objext` in
1335    *ELF-32*)
1336      HPUX_IA64_MODE="32"
1337      ;;
1338    *ELF-64*)
1339      HPUX_IA64_MODE="64"
1340      ;;
1341    esac
1342  fi
1343  rm -rf conftest*
1344  ;;
1345*-*-irix6*)
1346  # Find out which ABI we are using.
1347  echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1348  if AC_TRY_EVAL(ac_compile); then
1349   if test "$lt_cv_prog_gnu_ld" = yes; then
1350    case `/usr/bin/file conftest.$ac_objext` in
1351    *32-bit*)
1352      LD="${LD-ld} -melf32bsmip"
1353      ;;
1354    *N32*)
1355      LD="${LD-ld} -melf32bmipn32"
1356      ;;
1357    *64-bit*)
1358      LD="${LD-ld} -melf64bmip"
1359      ;;
1360    esac
1361   else
1362    case `/usr/bin/file conftest.$ac_objext` in
1363    *32-bit*)
1364      LD="${LD-ld} -32"
1365      ;;
1366    *N32*)
1367      LD="${LD-ld} -n32"
1368      ;;
1369    *64-bit*)
1370      LD="${LD-ld} -64"
1371      ;;
1372    esac
1373   fi
1374  fi
1375  rm -rf conftest*
1376  ;;
1377
1378x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
1379  # Find out which ABI we are using.
1380  echo 'int i;' > conftest.$ac_ext
1381  if AC_TRY_EVAL(ac_compile); then
1382    case "`/usr/bin/file conftest.o`" in
1383    *32-bit*)
1384      case $host in
1385        x86_64-*linux*)
1386          LD="${LD-ld} -m elf_i386"
1387          ;;
1388        ppc64-*linux*|powerpc64-*linux*)
1389          LD="${LD-ld} -m elf32ppclinux"
1390          ;;
1391        s390x-*linux*)
1392          LD="${LD-ld} -m elf_s390"
1393          ;;
1394        sparc64-*linux*)
1395          LD="${LD-ld} -m elf32_sparc"
1396          ;;
1397      esac
1398      ;;
1399    *64-bit*)
1400      case $host in
1401        x86_64-*linux*)
1402          LD="${LD-ld} -m elf_x86_64"
1403          ;;
1404        ppc*-*linux*|powerpc*-*linux*)
1405          LD="${LD-ld} -m elf64ppc"
1406          ;;
1407        s390*-*linux*)
1408          LD="${LD-ld} -m elf64_s390"
1409          ;;
1410        sparc*-*linux*)
1411          LD="${LD-ld} -m elf64_sparc"
1412          ;;
1413      esac
1414      ;;
1415    esac
1416  fi
1417  rm -rf conftest*
1418  ;;
1419
1420*-*-sco3.2v5*)
1421  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1422  SAVE_CFLAGS="$CFLAGS"
1423  CFLAGS="$CFLAGS -belf"
1424  AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1425    [AC_LANG_PUSH(C)
1426     AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1427     AC_LANG_POP])
1428  if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1429    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1430    CFLAGS="$SAVE_CFLAGS"
1431  fi
1432  ;;
1433AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1434[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
1435  AC_CHECK_TOOL(DLLTOOL, dlltool, false)
1436  AC_CHECK_TOOL(AS, as, false)
1437  AC_CHECK_TOOL(OBJDUMP, objdump, false)
1438  ;;
1439  ])
1440esac
1441
1442need_locks="$enable_libtool_lock"
1443
1444])# _LT_AC_LOCK
1445
1446
1447# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1448#               [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1449# ----------------------------------------------------------------
1450# Check whether the given compiler option works
1451AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
1452[AC_REQUIRE([LT_AC_PROG_SED])
1453AC_CACHE_CHECK([$1], [$2],
1454  [$2=no
1455  ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1456   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1457   lt_compiler_flag="$3"
1458   # Insert the option either (1) after the last *FLAGS variable, or
1459   # (2) before a word containing "conftest.", or (3) at the end.
1460   # Note that $ac_compile itself does not contain backslashes and begins
1461   # with a dollar sign (not a hyphen), so the echo should work correctly.
1462   # The option is referenced via a variable to avoid confusing sed.
1463   lt_compile=`echo "$ac_compile" | $SED \
1464   -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
1465   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1466   -e 's:$: $lt_compiler_flag:'`
1467   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1468   (eval "$lt_compile" 2>conftest.err)
1469   ac_status=$?
1470   cat conftest.err >&AS_MESSAGE_LOG_FD
1471   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1472   if (exit $ac_status) && test -s "$ac_outfile"; then
1473     # The compiler can only warn and ignore the option if not recognized
1474     # So say no if there are warnings
1475     if test ! -s conftest.err; then
1476       $2=yes
1477     fi
1478   fi
1479   $rm conftest*
1480])
1481
1482if test x"[$]$2" = xyes; then
1483    ifelse([$5], , :, [$5])
1484else
1485    ifelse([$6], , :, [$6])
1486fi
1487])# AC_LIBTOOL_COMPILER_OPTION
1488
1489
1490# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1491#                          [ACTION-SUCCESS], [ACTION-FAILURE])
1492# ------------------------------------------------------------
1493# Check whether the given compiler option works
1494AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
1495[AC_CACHE_CHECK([$1], [$2],
1496  [$2=no
1497   save_LDFLAGS="$LDFLAGS"
1498   LDFLAGS="$LDFLAGS $3"
1499   printf "$lt_simple_link_test_code" > conftest.$ac_ext
1500   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1501     # The compiler can only warn and ignore the option if not recognized
1502     # So say no if there are warnings
1503     if test -s conftest.err; then
1504       # Append any errors to the config.log.
1505       cat conftest.err 1>&AS_MESSAGE_LOG_FD
1506     else
1507       $2=yes
1508     fi
1509   fi
1510   $rm conftest*
1511   LDFLAGS="$save_LDFLAGS"
1512])
1513
1514if test x"[$]$2" = xyes; then
1515    ifelse([$4], , :, [$4])
1516else
1517    ifelse([$5], , :, [$5])
1518fi
1519])# AC_LIBTOOL_LINKER_OPTION
1520
1521
1522# AC_LIBTOOL_SYS_MAX_CMD_LEN
1523# --------------------------
1524AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
1525[# find the maximum length of command line arguments
1526AC_MSG_CHECKING([the maximum length of command line arguments])
1527AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1528  i=0
1529  teststring="ABCD"
1530
1531  case $build_os in
1532  msdosdjgpp*)
1533    # On DJGPP, this test can blow up pretty badly due to problems in libc
1534    # (any single argument exceeding 2000 bytes causes a buffer overrun
1535    # during glob expansion).  Even if it were fixed, the result of this
1536    # check would be larger than it should be.
1537    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
1538    ;;
1539
1540  gnu*)
1541    # Under GNU Hurd, this test is not required because there is
1542    # no limit to the length of command line arguments.
1543    # Libtool will interpret -1 as no limit whatsoever
1544    lt_cv_sys_max_cmd_len=-1;
1545    ;;
1546
1547  cygwin* | mingw*)
1548    # On Win9x/ME, this test blows up -- it succeeds, but takes
1549    # about 5 minutes as the teststring grows exponentially.
1550    # Worse, since 9x/ME are not pre-emptively multitasking,
1551    # you end up with a "frozen" computer, even though with patience
1552    # the test eventually succeeds (with a max line length of 256k).
1553    # Instead, let's just punt: use the minimum linelength reported by
1554    # all of the supported platforms: 8192 (on NT/2K/XP).
1555    lt_cv_sys_max_cmd_len=8192;
1556    ;;
1557
1558  amigaos*)
1559    # On AmigaOS with pdksh, this test takes hours, literally.
1560    # So we just punt and use a minimum line length of 8192.
1561    lt_cv_sys_max_cmd_len=8192;
1562    ;;
1563
1564 *)
1565    # If test is not a shell built-in, we'll probably end up computing a
1566    # maximum length that is only half of the actual maximum length, but
1567    # we can't tell.
1568    while (test "X"`$CONFIG_SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
1569               = "XX$teststring") >/dev/null 2>&1 &&
1570            new_result=`expr "X$teststring" : ".*" 2>&1` &&
1571            lt_cv_sys_max_cmd_len=$new_result &&
1572            test $i != 17 # 1/2 MB should be enough
1573    do
1574      i=`expr $i + 1`
1575      teststring=$teststring$teststring
1576    done
1577    teststring=
1578    # Add a significant safety factor because C++ compilers can tack on massive
1579    # amounts of additional arguments before passing them to the linker.
1580    # It appears as though 1/2 is a usable value.
1581    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1582    ;;
1583  esac
1584])
1585if test -n $lt_cv_sys_max_cmd_len ; then
1586  AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1587else
1588  AC_MSG_RESULT(none)
1589fi
1590])# AC_LIBTOOL_SYS_MAX_CMD_LEN
1591
1592
1593# _LT_AC_CHECK_DLFCN
1594# --------------------
1595AC_DEFUN([_LT_AC_CHECK_DLFCN],
1596[AC_CHECK_HEADERS(dlfcn.h)dnl
1597])# _LT_AC_CHECK_DLFCN
1598
1599
1600# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1601#                           ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1602# ------------------------------------------------------------------
1603AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
1604[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1605if test "$cross_compiling" = yes; then :
1606  [$4]
1607else
1608  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1609  lt_status=$lt_dlunknown
1610  cat > conftest.$ac_ext <<EOF
1611[#line __oline__ "configure"
1612#include "confdefs.h"
1613
1614#if HAVE_DLFCN_H
1615#include <dlfcn.h>
1616#endif
1617
1618#include <stdio.h>
1619
1620#ifdef RTLD_GLOBAL
1621#  define LT_DLGLOBAL           RTLD_GLOBAL
1622#else
1623#  ifdef DL_GLOBAL
1624#    define LT_DLGLOBAL         DL_GLOBAL
1625#  else
1626#    define LT_DLGLOBAL         0
1627#  endif
1628#endif
1629
1630/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1631   find out it does not work in some platform. */
1632#ifndef LT_DLLAZY_OR_NOW
1633#  ifdef RTLD_LAZY
1634#    define LT_DLLAZY_OR_NOW            RTLD_LAZY
1635#  else
1636#    ifdef DL_LAZY
1637#      define LT_DLLAZY_OR_NOW          DL_LAZY
1638#    else
1639#      ifdef RTLD_NOW
1640#        define LT_DLLAZY_OR_NOW        RTLD_NOW
1641#      else
1642#        ifdef DL_NOW
1643#          define LT_DLLAZY_OR_NOW      DL_NOW
1644#        else
1645#          define LT_DLLAZY_OR_NOW      0
1646#        endif
1647#      endif
1648#    endif
1649#  endif
1650#endif
1651
1652#ifdef __cplusplus
1653extern "C" void exit (int);
1654#endif
1655
1656void fnord() { int i=42;}
1657int main ()
1658{
1659  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1660  int status = $lt_dlunknown;
1661
1662  if (self)
1663    {
1664      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
1665      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1666      /* dlclose (self); */
1667    }
1668
1669    exit (status);
1670}]
1671EOF
1672  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1673    (./conftest; exit; ) 2>/dev/null
1674    lt_status=$?
1675    case x$lt_status in
1676      x$lt_dlno_uscore) $1 ;;
1677      x$lt_dlneed_uscore) $2 ;;
1678      x$lt_unknown|x*) $3 ;;
1679    esac
1680  else :
1681    # compilation failed
1682    $3
1683  fi
1684fi
1685rm -fr conftest*
1686])# _LT_AC_TRY_DLOPEN_SELF
1687
1688
1689# AC_LIBTOOL_DLOPEN_SELF
1690# -------------------
1691AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
1692[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1693if test "x$enable_dlopen" != xyes; then
1694  enable_dlopen=unknown
1695  enable_dlopen_self=unknown
1696  enable_dlopen_self_static=unknown
1697else
1698  lt_cv_dlopen=no
1699  lt_cv_dlopen_libs=
1700
1701  case $host_os in
1702  beos*)
1703    lt_cv_dlopen="load_add_on"
1704    lt_cv_dlopen_libs=
1705    lt_cv_dlopen_self=yes
1706    ;;
1707
1708  mingw* | pw32*)
1709    lt_cv_dlopen="LoadLibrary"
1710    lt_cv_dlopen_libs=
1711   ;;
1712
1713  cygwin*)
1714    lt_cv_dlopen="dlopen"
1715    lt_cv_dlopen_libs=
1716   ;;
1717
1718  darwin*)
1719  # if libdl is installed we need to link against it
1720    AC_CHECK_LIB([dl], [dlopen],
1721                [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1722    lt_cv_dlopen="dyld"
1723    lt_cv_dlopen_libs=
1724    lt_cv_dlopen_self=yes
1725    ])
1726   ;;
1727
1728  *)
1729    AC_CHECK_FUNC([shl_load],
1730          [lt_cv_dlopen="shl_load"],
1731      [AC_CHECK_LIB([dld], [shl_load],
1732            [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
1733        [AC_CHECK_FUNC([dlopen],
1734              [lt_cv_dlopen="dlopen"],
1735          [AC_CHECK_LIB([dl], [dlopen],
1736                [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1737            [AC_CHECK_LIB([svld], [dlopen],
1738                  [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1739              [AC_CHECK_LIB([dld], [dld_link],
1740                    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
1741              ])
1742            ])
1743          ])
1744        ])
1745      ])
1746    ;;
1747  esac
1748
1749  if test "x$lt_cv_dlopen" != xno; then
1750    enable_dlopen=yes
1751  else
1752    enable_dlopen=no
1753  fi
1754
1755  case $lt_cv_dlopen in
1756  dlopen)
1757    save_CPPFLAGS="$CPPFLAGS"
1758    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1759
1760    save_LDFLAGS="$LDFLAGS"
1761    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1762
1763    save_LIBS="$LIBS"
1764    LIBS="$lt_cv_dlopen_libs $LIBS"
1765
1766    AC_CACHE_CHECK([whether a program can dlopen itself],
1767          lt_cv_dlopen_self, [dnl
1768          _LT_AC_TRY_DLOPEN_SELF(
1769            lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1770            lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1771    ])
1772
1773    if test "x$lt_cv_dlopen_self" = xyes; then
1774      LDFLAGS="$LDFLAGS $link_static_flag"
1775      AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1776          lt_cv_dlopen_self_static, [dnl
1777          _LT_AC_TRY_DLOPEN_SELF(
1778            lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1779            lt_cv_dlopen_self_static=no,  lt_cv_dlopen_self_static=cross)
1780      ])
1781    fi
1782
1783    CPPFLAGS="$save_CPPFLAGS"
1784    LDFLAGS="$save_LDFLAGS"
1785    LIBS="$save_LIBS"
1786    ;;
1787  esac
1788
1789  case $lt_cv_dlopen_self in
1790  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1791  *) enable_dlopen_self=unknown ;;
1792  esac
1793
1794  case $lt_cv_dlopen_self_static in
1795  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1796  *) enable_dlopen_self_static=unknown ;;
1797  esac
1798fi
1799])# AC_LIBTOOL_DLOPEN_SELF
1800
1801
1802# AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1803# ---------------------------------
1804# Check to see if options -c and -o are simultaneously supported by compiler
1805AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1806[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1807AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1808  [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1809  [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1810   $rm -r conftest 2>/dev/null
1811   mkdir conftest
1812   cd conftest
1813   mkdir out
1814   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1815
1816   lt_compiler_flag="-o out/conftest2.$ac_objext"
1817   # Insert the option either (1) after the last *FLAGS variable, or
1818   # (2) before a word containing "conftest.", or (3) at the end.
1819   # Note that $ac_compile itself does not contain backslashes and begins
1820   # with a dollar sign (not a hyphen), so the echo should work correctly.
1821   lt_compile=`echo "$ac_compile" | $SED \
1822   -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
1823   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1824   -e 's:$: $lt_compiler_flag:'`
1825   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1826   (eval "$lt_compile" 2>out/conftest.err)
1827   ac_status=$?
1828   cat out/conftest.err >&AS_MESSAGE_LOG_FD
1829   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1830   if (exit $ac_status) && test -s out/conftest2.$ac_objext
1831   then
1832     # The compiler can only warn and ignore the option if not recognized
1833     # So say no if there are warnings
1834     if test ! -s out/conftest.err; then
1835       _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1836     fi
1837   fi
1838   chmod u+w .
1839   $rm conftest*
1840   # SGI C++ compiler will create directory out/ii_files/ for
1841   # template instantiation
1842   test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
1843   $rm out/* && rmdir out
1844   cd ..
1845   rmdir conftest
1846   $rm conftest*
1847])
1848])# AC_LIBTOOL_PROG_CC_C_O
1849
1850
1851# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
1852# -----------------------------------------
1853# Check to see if we can do hard links to lock some files if needed
1854AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
1855[AC_REQUIRE([_LT_AC_LOCK])dnl
1856
1857hard_links="nottested"
1858if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1859  # do not overwrite the value of need_locks provided by the user
1860  AC_MSG_CHECKING([if we can lock with hard links])
1861  hard_links=yes
1862  $rm conftest*
1863  ln conftest.a conftest.b 2>/dev/null && hard_links=no
1864  touch conftest.a
1865  ln conftest.a conftest.b 2>&5 || hard_links=no
1866  ln conftest.a conftest.b 2>/dev/null && hard_links=no
1867  AC_MSG_RESULT([$hard_links])
1868  if test "$hard_links" = no; then
1869    AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1870    need_locks=warn
1871  fi
1872else
1873  need_locks=no
1874fi
1875])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
1876
1877
1878# AC_LIBTOOL_OBJDIR
1879# -----------------
1880AC_DEFUN([AC_LIBTOOL_OBJDIR],
1881[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
1882[rm -f .libs 2>/dev/null
1883mkdir .libs 2>/dev/null
1884if test -d .libs; then
1885  lt_cv_objdir=.libs
1886else
1887  # MS-DOS does not allow filenames that begin with a dot.
1888  lt_cv_objdir=_libs
1889fi
1890rmdir .libs 2>/dev/null])
1891objdir=$lt_cv_objdir
1892])# AC_LIBTOOL_OBJDIR
1893
1894
1895# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
1896# ----------------------------------------------
1897# Check hardcoding attributes.
1898AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
1899[AC_MSG_CHECKING([how to hardcode library paths into programs])
1900_LT_AC_TAGVAR(hardcode_action, $1)=
1901if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
1902   test -n "$_LT_AC_TAGVAR(runpath_var $1)" || \
1903   test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)"="Xyes" ; then
1904
1905  # We can hardcode non-existant directories.
1906  if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
1907     # If the only mechanism to avoid hardcoding is shlibpath_var, we
1908     # have to relink, otherwise we might link with an installed library
1909     # when we should be linking with a yet-to-be-installed one
1910     ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
1911     test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
1912    # Linking always hardcodes the temporary library directory.
1913    _LT_AC_TAGVAR(hardcode_action, $1)=relink
1914  else
1915    # We can link without hardcoding, and we can hardcode nonexisting dirs.
1916    _LT_AC_TAGVAR(hardcode_action, $1)=immediate
1917  fi
1918else
1919  # We cannot hardcode anything, or else we can only hardcode existing
1920  # directories.
1921  _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
1922fi
1923AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
1924
1925if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
1926  # Fast installation is not supported
1927  enable_fast_install=no
1928elif test "$shlibpath_overrides_runpath" = yes ||
1929     test "$enable_shared" = no; then
1930  # Fast installation is not necessary
1931  enable_fast_install=needless
1932fi
1933])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
1934
1935
1936# AC_LIBTOOL_SYS_LIB_STRIP
1937# ------------------------
1938AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
1939[striplib=
1940old_striplib=
1941AC_MSG_CHECKING([whether stripping libraries is possible])
1942if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
1943  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
1944  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
1945  AC_MSG_RESULT([yes])
1946else
1947# FIXME - insert some real tests, host_os isn't really good enough
1948  case $host_os in
1949   darwin*)
1950       if test -n "$STRIP" ; then
1951         striplib="$STRIP -x"
1952         AC_MSG_RESULT([yes])
1953       else
1954  AC_MSG_RESULT([no])
1955fi
1956       ;;
1957   *)
1958  AC_MSG_RESULT([no])
1959    ;;
1960  esac
1961fi
1962])# AC_LIBTOOL_SYS_LIB_STRIP
1963
1964
1965# AC_LIBTOOL_SYS_DYNAMIC_LINKER
1966# -----------------------------
1967# PORTME Fill in your ld.so characteristics
1968AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
1969[AC_MSG_CHECKING([dynamic linker characteristics])
1970library_names_spec=
1971libname_spec='lib$name'
1972soname_spec=
1973shrext_cmds=".so"
1974postinstall_cmds=
1975postuninstall_cmds=
1976finish_cmds=
1977finish_eval=
1978shlibpath_var=
1979shlibpath_overrides_runpath=unknown
1980version_type=none
1981dynamic_linker="$host_os ld.so"
1982sys_lib_dlsearch_path_spec="/lib /usr/lib"
1983if test "$GCC" = yes; then
1984  sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1985  if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
1986    # if the path contains ";" then we assume it to be the separator
1987    # otherwise default to the standard path separator (i.e. ":") - it is
1988    # assumed that no part of a normal pathname contains ";" but that should
1989    # okay in the real world where ";" in dirpaths is itself problematic.
1990    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1991  else
1992    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
1993  fi
1994else
1995  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1996fi
1997need_lib_prefix=unknown
1998hardcode_into_libs=no
1999
2000# when you set need_version to no, make sure it does not cause -set_version
2001# flags to be left without arguments
2002need_version=unknown
2003
2004case $host_os in
2005aix3*)
2006  version_type=linux
2007  library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2008  shlibpath_var=LIBPATH
2009
2010  # AIX 3 has no versioning support, so we append a major version to the name.
2011  soname_spec='${libname}${release}${shared_ext}$major'
2012  ;;
2013
2014aix4* | aix5*)
2015  version_type=linux
2016  need_lib_prefix=no
2017  need_version=no
2018  hardcode_into_libs=yes
2019  if test "$host_cpu" = ia64; then
2020    # AIX 5 supports IA64
2021    library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2022    shlibpath_var=LD_LIBRARY_PATH
2023  else
2024    # With GCC up to 2.95.x, collect2 would create an import file
2025    # for dependence libraries.  The import file would start with
2026    # the line `#! .'.  This would cause the generated library to
2027    # depend on `.', always an invalid library.  This was fixed in
2028    # development snapshots of GCC prior to 3.0.
2029    case $host_os in
2030      aix4 | aix4.[[01]] | aix4.[[01]].*)
2031      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2032           echo ' yes '
2033           echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
2034        :
2035      else
2036        can_build_shared=no
2037      fi
2038      ;;
2039    esac
2040    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2041    # soname into executable. Probably we can add versioning support to
2042    # collect2, so additional links can be useful in future.
2043    if test "$aix_use_runtimelinking" = yes; then
2044      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2045      # instead of lib<name>.a to let people know that these are not
2046      # typical AIX shared libraries.
2047      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2048    else
2049      # We preserve .a as extension for shared libraries through AIX4.2
2050      # and later when we are not doing run time linking.
2051      library_names_spec='${libname}${release}.a $libname.a'
2052      soname_spec='${libname}${release}${shared_ext}$major'
2053    fi
2054    shlibpath_var=LIBPATH
2055  fi
2056  ;;
2057
2058amigaos*)
2059  library_names_spec='$libname.ixlibrary $libname.a'
2060  # Create ${libname}_ixlibrary.a entries in /sys/libs.
2061  finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2062  ;;
2063
2064beos*)
2065  library_names_spec='${libname}${shared_ext}'
2066  dynamic_linker="$host_os ld.so"
2067  shlibpath_var=LIBRARY_PATH
2068  ;;
2069
2070bsdi4*)
2071  version_type=linux
2072  need_version=no
2073  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2074  soname_spec='${libname}${release}${shared_ext}$major'
2075  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2076  shlibpath_var=LD_LIBRARY_PATH
2077  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2078  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2079  # the default ld.so.conf also contains /usr/contrib/lib and
2080  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2081  # libtool to hard-code these into programs
2082  ;;
2083
2084cygwin* | mingw* | pw32*)
2085  version_type=windows
2086  shrext_cmds=".dll"
2087  need_version=no
2088  need_lib_prefix=no
2089
2090  case $GCC,$host_os in
2091  yes,cygwin* | yes,mingw* | yes,pw32*)
2092    library_names_spec='$libname.dll.a'
2093    # DLL is installed to $(libdir)/../bin by postinstall_cmds
2094    postinstall_cmds='base_file=`basename \${file}`~
2095      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
2096      dldir=$destdir/`dirname \$dlpath`~
2097      test -d \$dldir || mkdir -p \$dldir~
2098      $install_prog $dir/$dlname \$dldir/$dlname'
2099    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2100      dlpath=$dir/\$dldll~
2101       $rm \$dlpath'
2102    shlibpath_overrides_runpath=yes
2103
2104    case $host_os in
2105    cygwin*)
2106      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2107      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2108      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2109      ;;
2110    mingw*)
2111      # MinGW DLLs use traditional 'lib' prefix
2112      soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2113      sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2114      if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
2115        # It is most probably a Windows format PATH printed by
2116        # mingw gcc, but we are running on Cygwin. Gcc prints its search
2117        # path with ; separators, and with drive letters. We can handle the
2118        # drive letters (cygwin fileutils understands them), so leave them,
2119        # especially as we might pass files found there to a mingw objdump,
2120        # which wouldn't understand a cygwinified path. Ahh.
2121        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2122      else
2123        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
2124      fi
2125      ;;
2126    pw32*)
2127      # pw32 DLLs use 'pw' prefix rather than 'lib'
2128      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
2129      ;;
2130    esac
2131    ;;
2132
2133  *)
2134    library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2135    ;;
2136  esac
2137  dynamic_linker='Win32 ld.exe'
2138  # FIXME: first we should search . and the directory the executable is in
2139  shlibpath_var=PATH
2140  ;;
2141
2142darwin* | rhapsody*)
2143  dynamic_linker="$host_os dyld"
2144  version_type=darwin
2145  need_lib_prefix=no
2146  need_version=no
2147  library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2148  soname_spec='${libname}${release}${major}$shared_ext'
2149  shlibpath_overrides_runpath=yes
2150  shlibpath_var=DYLD_LIBRARY_PATH
2151  shrext_cmds='$(test .$module = .yes && echo .so || echo .dylib)'
2152  # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
2153  if test "$GCC" = yes; then
2154    sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
2155  else
2156    sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
2157  fi
2158  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2159  ;;
2160
2161dgux*)
2162  version_type=linux
2163  need_lib_prefix=no
2164  need_version=no
2165  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2166  soname_spec='${libname}${release}${shared_ext}$major'
2167  shlibpath_var=LD_LIBRARY_PATH
2168  ;;
2169
2170freebsd1*)
2171  dynamic_linker=no
2172  ;;
2173
2174kfreebsd*-gnu)
2175  version_type=linux
2176  need_lib_prefix=no
2177  need_version=no
2178  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2179  soname_spec='${libname}${release}${shared_ext}$major'
2180  shlibpath_var=LD_LIBRARY_PATH
2181  shlibpath_overrides_runpath=no
2182  hardcode_into_libs=yes
2183  dynamic_linker='GNU ld.so'
2184  ;;
2185
2186freebsd*)
2187  objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
2188  version_type=freebsd-$objformat
2189  case $version_type in
2190    freebsd-elf*)
2191      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2192      need_version=no
2193      need_lib_prefix=no
2194      ;;
2195    freebsd-*)
2196      library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2197      need_version=yes
2198      ;;
2199  esac
2200  shlibpath_var=LD_LIBRARY_PATH
2201  case $host_os in
2202  freebsd2*)
2203    shlibpath_overrides_runpath=yes
2204    ;;
2205  freebsd3.[01]* | freebsdelf3.[01]*)
2206    shlibpath_overrides_runpath=yes
2207    hardcode_into_libs=yes
2208    ;;
2209  *) # from 3.2 on
2210    shlibpath_overrides_runpath=no
2211    hardcode_into_libs=yes
2212    ;;
2213  esac
2214  ;;
2215
2216gnu*)
2217  version_type=linux
2218  need_lib_prefix=no
2219  need_version=no
2220  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2221  soname_spec='${libname}${release}${shared_ext}$major'
2222  shlibpath_var=LD_LIBRARY_PATH
2223  hardcode_into_libs=yes
2224  ;;
2225
2226hpux9* | hpux10* | hpux11*)
2227  # Give a soname corresponding to the major version so that dld.sl refuses to
2228  # link against other versions.
2229  version_type=sunos
2230  need_lib_prefix=no
2231  need_version=no
2232  case "$host_cpu" in
2233  ia64*)
2234    shrext_cmds='.so'
2235    hardcode_into_libs=yes
2236    dynamic_linker="$host_os dld.so"
2237    shlibpath_var=LD_LIBRARY_PATH
2238    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2239    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2240    soname_spec='${libname}${release}${shared_ext}$major'
2241    if test "X$HPUX_IA64_MODE" = X32; then
2242      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2243    else
2244      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2245    fi
2246    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2247    ;;
2248   hppa*64*)
2249     shrext_cmds='.sl'
2250     hardcode_into_libs=yes
2251     dynamic_linker="$host_os dld.sl"
2252     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2253     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2254     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2255     soname_spec='${libname}${release}${shared_ext}$major'
2256     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2257     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2258     ;;
2259   *)
2260    shrext_cmds='.sl'
2261    dynamic_linker="$host_os dld.sl"
2262    shlibpath_var=SHLIB_PATH
2263    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2264    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2265    soname_spec='${libname}${release}${shared_ext}$major'
2266    ;;
2267  esac
2268  # HP-UX runs *really* slowly unless shared libraries are mode 555.
2269  postinstall_cmds='chmod 555 $lib'
2270  ;;
2271
2272irix5* | irix6* | nonstopux*)
2273  case $host_os in
2274    nonstopux*) version_type=nonstopux ;;
2275    *)
2276        if test "$lt_cv_prog_gnu_ld" = yes; then
2277                version_type=linux
2278        else
2279                version_type=irix
2280        fi ;;
2281  esac
2282  need_lib_prefix=no
2283  need_version=no
2284  soname_spec='${libname}${release}${shared_ext}$major'
2285  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2286  case $host_os in
2287  irix5* | nonstopux*)
2288    libsuff= shlibsuff=
2289    ;;
2290  *)
2291    case $LD in # libtool.m4 will add one of these switches to LD
2292    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2293      libsuff= shlibsuff= libmagic=32-bit;;
2294    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2295      libsuff=32 shlibsuff=N32 libmagic=N32;;
2296    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2297      libsuff=64 shlibsuff=64 libmagic=64-bit;;
2298    *) libsuff= shlibsuff= libmagic=never-match;;
2299    esac
2300    ;;
2301  esac
2302  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2303  shlibpath_overrides_runpath=no
2304  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2305  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2306  hardcode_into_libs=yes
2307  ;;
2308
2309# No shared lib support for Linux oldld, aout, or coff.
2310linux*oldld* | linux*aout* | linux*coff*)
2311  dynamic_linker=no
2312  ;;
2313
2314# This must be Linux ELF.
2315linux*)
2316  version_type=linux
2317  need_lib_prefix=no
2318  need_version=no
2319  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2320  soname_spec='${libname}${release}${shared_ext}$major'
2321  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2322  shlibpath_var=LD_LIBRARY_PATH
2323  shlibpath_overrides_runpath=no
2324  # This implies no fast_install, which is unacceptable.
2325  # Some rework will be needed to allow for fast_install
2326  # before this can be enabled.
2327  hardcode_into_libs=yes
2328
2329  # Append ld.so.conf contents to the search path
2330  if test -f /etc/ld.so.conf; then
2331    lt_ld_extra=`$SED -e 's/[:,\t]/ /g;s/=[^=]*$//;s/=[^= ]* / /g' /etc/ld.so.conf | tr '\n' ' '`
2332    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2333  fi
2334
2335  # We used to test for /lib/ld.so.1 and disable shared libraries on
2336  # powerpc, because MkLinux only supported shared libraries with the
2337  # GNU dynamic linker.  Since this was broken with cross compilers,
2338  # most powerpc-linux boxes support dynamic linking these days and
2339  # people can always --disable-shared, the test was removed, and we
2340  # assume the GNU/Linux dynamic linker is in use.
2341  dynamic_linker='GNU/Linux ld.so'
2342  ;;
2343
2344netbsdelf*-gnu)
2345  version_type=linux
2346  need_lib_prefix=no
2347  need_version=no
2348  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2349  soname_spec='${libname}${release}${shared_ext}$major'
2350  shlibpath_var=LD_LIBRARY_PATH
2351  shlibpath_overrides_runpath=no
2352  hardcode_into_libs=yes
2353  dynamic_linker='NetBSD ld.elf_so'
2354  ;;
2355
2356knetbsd*-gnu)
2357  version_type=linux
2358  need_lib_prefix=no
2359  need_version=no
2360  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2361  soname_spec='${libname}${release}${shared_ext}$major'
2362  shlibpath_var=LD_LIBRARY_PATH
2363  shlibpath_overrides_runpath=no
2364  hardcode_into_libs=yes
2365  dynamic_linker='GNU ld.so'
2366  ;;
2367
2368netbsd*)
2369  version_type=sunos
2370  need_lib_prefix=no
2371  need_version=no
2372  if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
2373    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2374    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2375    dynamic_linker='NetBSD (a.out) ld.so'
2376  else
2377    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2378    soname_spec='${libname}${release}${shared_ext}$major'
2379    dynamic_linker='NetBSD ld.elf_so'
2380  fi
2381  shlibpath_var=LD_LIBRARY_PATH
2382  shlibpath_overrides_runpath=yes
2383  hardcode_into_libs=yes
2384  ;;
2385
2386newsos6)
2387  version_type=linux
2388  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2389  shlibpath_var=LD_LIBRARY_PATH
2390  shlibpath_overrides_runpath=yes
2391  ;;
2392
2393nto-qnx*)
2394  version_type=linux
2395  need_lib_prefix=no
2396  need_version=no
2397  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2398  soname_spec='${libname}${release}${shared_ext}$major'
2399  shlibpath_var=LD_LIBRARY_PATH
2400  shlibpath_overrides_runpath=yes
2401  ;;
2402
2403openbsd*)
2404  version_type=sunos
2405  need_lib_prefix=no
2406  need_version=yes
2407  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2408  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2409  shlibpath_var=LD_LIBRARY_PATH
2410  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2411    case $host_os in
2412      openbsd2.[[89]] | openbsd2.[[89]].*)
2413        shlibpath_overrides_runpath=no
2414        ;;
2415      *)
2416        shlibpath_overrides_runpath=yes
2417        ;;
2418      esac
2419  else
2420    shlibpath_overrides_runpath=yes
2421  fi
2422  ;;
2423
2424os2*)
2425  libname_spec='$name'
2426  shrext_cmds=".dll"
2427  need_lib_prefix=no
2428  library_names_spec='$libname${shared_ext} $libname.a'
2429  dynamic_linker='OS/2 ld.exe'
2430  shlibpath_var=LIBPATH
2431  ;;
2432
2433osf3* | osf4* | osf5*)
2434  version_type=osf
2435  need_lib_prefix=no
2436  need_version=no
2437  soname_spec='${libname}${release}${shared_ext}$major'
2438  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2439  shlibpath_var=LD_LIBRARY_PATH
2440  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2441  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2442  ;;
2443
2444sco3.2v5*)
2445  version_type=osf
2446  soname_spec='${libname}${release}${shared_ext}$major'
2447  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2448  shlibpath_var=LD_LIBRARY_PATH
2449  ;;
2450
2451solaris*)
2452  version_type=linux
2453  need_lib_prefix=no
2454  need_version=no
2455  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2456  soname_spec='${libname}${release}${shared_ext}$major'
2457  shlibpath_var=LD_LIBRARY_PATH
2458  shlibpath_overrides_runpath=yes
2459  hardcode_into_libs=yes
2460  # ldd complains unless libraries are executable
2461  postinstall_cmds='chmod +x $lib'
2462  ;;
2463
2464sunos4*)
2465  version_type=sunos
2466  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2467  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2468  shlibpath_var=LD_LIBRARY_PATH
2469  shlibpath_overrides_runpath=yes
2470  if test "$with_gnu_ld" = yes; then
2471    need_lib_prefix=no
2472  fi
2473  need_version=yes
2474  ;;
2475
2476sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
2477  version_type=linux
2478  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2479  soname_spec='${libname}${release}${shared_ext}$major'
2480  shlibpath_var=LD_LIBRARY_PATH
2481  case $host_vendor in
2482    sni)
2483      shlibpath_overrides_runpath=no
2484      need_lib_prefix=no
2485      export_dynamic_flag_spec='${wl}-Blargedynsym'
2486      runpath_var=LD_RUN_PATH
2487      ;;
2488    siemens)
2489      need_lib_prefix=no
2490      ;;
2491    motorola)
2492      need_lib_prefix=no
2493      need_version=no
2494      shlibpath_overrides_runpath=no
2495      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2496      ;;
2497  esac
2498  ;;
2499
2500sysv4*MP*)
2501  if test -d /usr/nec ;then
2502    version_type=linux
2503    library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2504    soname_spec='$libname${shared_ext}.$major'
2505    shlibpath_var=LD_LIBRARY_PATH
2506  fi
2507  ;;
2508
2509uts4*)
2510  version_type=linux
2511  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2512  soname_spec='${libname}${release}${shared_ext}$major'
2513  shlibpath_var=LD_LIBRARY_PATH
2514  ;;
2515
2516*)
2517  dynamic_linker=no
2518  ;;
2519esac
2520AC_MSG_RESULT([$dynamic_linker])
2521test "$dynamic_linker" = no && can_build_shared=no
2522])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2523
2524
2525# _LT_AC_TAGCONFIG
2526# ----------------
2527AC_DEFUN([_LT_AC_TAGCONFIG],
2528[AC_ARG_WITH([tags],
2529    [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2530        [include additional configurations @<:@automatic@:>@])],
2531    [tagnames="$withval"])
2532
2533if test -f "$ltmain" && test -n "$tagnames"; then
2534  if test ! -f "${ofile}"; then
2535    AC_MSG_WARN([output file `$ofile' does not exist])
2536  fi
2537
2538  if test -z "$LTCC"; then
2539    eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2540    if test -z "$LTCC"; then
2541      AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2542    else
2543      AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2544    fi
2545  fi
2546
2547  # Extract list of available tagged configurations in $ofile.
2548  # Note that this assumes the entire list is on one line.
2549  available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2550
2551  lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2552  for tagname in $tagnames; do
2553    IFS="$lt_save_ifs"
2554    # Check whether tagname contains only valid characters
2555    case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2556    "") ;;
2557    *)  AC_MSG_ERROR([invalid tag name: $tagname])
2558        ;;
2559    esac
2560
2561    if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2562    then
2563      AC_MSG_ERROR([tag name \"$tagname\" already exists])
2564    fi
2565
2566    # Update the list of available tags.
2567    if test -n "$tagname"; then
2568      echo appending configuration tag \"$tagname\" to $ofile
2569
2570      case $tagname in
2571      CXX)
2572        if test -n "$CXX" && test "X$CXX" != "Xno"; then
2573          AC_LIBTOOL_LANG_CXX_CONFIG
2574        else
2575          tagname=""
2576        fi
2577        ;;
2578
2579      F77)
2580        if test -n "$F77" && test "X$F77" != "Xno"; then
2581          AC_LIBTOOL_LANG_F77_CONFIG
2582        else
2583          tagname=""
2584        fi
2585        ;;
2586
2587      GCJ)
2588        if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2589          AC_LIBTOOL_LANG_GCJ_CONFIG
2590        else
2591          tagname=""
2592        fi
2593        ;;
2594
2595      RC)
2596        AC_LIBTOOL_LANG_RC_CONFIG
2597        ;;
2598
2599      *)
2600        AC_MSG_ERROR([Unsupported tag name: $tagname])
2601        ;;
2602      esac
2603
2604      # Append the new tag name to the list of available tags.
2605      if test -n "$tagname" ; then
2606      available_tags="$available_tags $tagname"
2607    fi
2608    fi
2609  done
2610  IFS="$lt_save_ifs"
2611
2612  # Now substitute the updated list of available tags.
2613  if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2614    mv "${ofile}T" "$ofile"
2615    chmod +x "$ofile"
2616  else
2617    rm -f "${ofile}T"
2618    AC_MSG_ERROR([unable to update list of available tagged configurations.])
2619  fi
2620fi
2621])# _LT_AC_TAGCONFIG
2622
2623
2624# AC_LIBTOOL_DLOPEN
2625# -----------------
2626# enable checks for dlopen support
2627AC_DEFUN([AC_LIBTOOL_DLOPEN],
2628 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2629])# AC_LIBTOOL_DLOPEN
2630
2631
2632# AC_LIBTOOL_WIN32_DLL
2633# --------------------
2634# declare package support for building win32 dll's
2635AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2636[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2637])# AC_LIBTOOL_WIN32_DLL
2638
2639
2640# AC_ENABLE_SHARED([DEFAULT])
2641# ---------------------------
2642# implement the --enable-shared flag
2643# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
2644AC_DEFUN([AC_ENABLE_SHARED],
2645[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2646AC_ARG_ENABLE([shared],
2647    [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2648        [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2649    [p=${PACKAGE-default}
2650    case $enableval in
2651    yes) enable_shared=yes ;;
2652    no) enable_shared=no ;;
2653    *)
2654      enable_shared=no
2655      # Look at the argument we got.  We use all the common list separators.
2656      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2657      for pkg in $enableval; do
2658        IFS="$lt_save_ifs"
2659        if test "X$pkg" = "X$p"; then
2660          enable_shared=yes
2661        fi
2662      done
2663      IFS="$lt_save_ifs"
2664      ;;
2665    esac],
2666    [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2667])# AC_ENABLE_SHARED
2668
2669
2670# AC_DISABLE_SHARED
2671# -----------------
2672#- set the default shared flag to --disable-shared
2673AC_DEFUN([AC_DISABLE_SHARED],
2674[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2675AC_ENABLE_SHARED(no)
2676])# AC_DISABLE_SHARED
2677
2678
2679# AC_ENABLE_STATIC([DEFAULT])
2680# ---------------------------
2681# implement the --enable-static flag
2682# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
2683AC_DEFUN([AC_ENABLE_STATIC],
2684[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2685AC_ARG_ENABLE([static],
2686    [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2687        [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2688    [p=${PACKAGE-default}
2689    case $enableval in
2690    yes) enable_static=yes ;;
2691    no) enable_static=no ;;
2692    *)
2693     enable_static=no
2694      # Look at the argument we got.  We use all the common list separators.
2695      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2696      for pkg in $enableval; do
2697        IFS="$lt_save_ifs"
2698        if test "X$pkg" = "X$p"; then
2699          enable_static=yes
2700        fi
2701      done
2702      IFS="$lt_save_ifs"
2703      ;;
2704    esac],
2705    [enable_static=]AC_ENABLE_STATIC_DEFAULT)
2706])# AC_ENABLE_STATIC
2707
2708
2709# AC_DISABLE_STATIC
2710# -----------------
2711# set the default static flag to --disable-static
2712AC_DEFUN([AC_DISABLE_STATIC],
2713[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2714AC_ENABLE_STATIC(no)
2715])# AC_DISABLE_STATIC
2716
2717
2718# AC_ENABLE_FAST_INSTALL([DEFAULT])
2719# ---------------------------------
2720# implement the --enable-fast-install flag
2721# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
2722AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2723[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2724AC_ARG_ENABLE([fast-install],
2725    [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2726    [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2727    [p=${PACKAGE-default}
2728    case $enableval in
2729    yes) enable_fast_install=yes ;;
2730    no) enable_fast_install=no ;;
2731    *)
2732      enable_fast_install=no
2733      # Look at the argument we got.  We use all the common list separators.
2734      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2735      for pkg in $enableval; do
2736        IFS="$lt_save_ifs"
2737        if test "X$pkg" = "X$p"; then
2738          enable_fast_install=yes
2739        fi
2740      done
2741      IFS="$lt_save_ifs"
2742      ;;
2743    esac],
2744    [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2745])# AC_ENABLE_FAST_INSTALL
2746
2747
2748# AC_DISABLE_FAST_INSTALL
2749# -----------------------
2750# set the default to --disable-fast-install
2751AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2752[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2753AC_ENABLE_FAST_INSTALL(no)
2754])# AC_DISABLE_FAST_INSTALL
2755
2756
2757# AC_LIBTOOL_PICMODE([MODE])
2758# --------------------------
2759# implement the --with-pic flag
2760# MODE is either `yes' or `no'.  If omitted, it defaults to `both'.
2761AC_DEFUN([AC_LIBTOOL_PICMODE],
2762[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2763pic_mode=ifelse($#,1,$1,default)
2764])# AC_LIBTOOL_PICMODE
2765
2766
2767# AC_PROG_EGREP
2768# -------------
2769# This is predefined starting with Autoconf 2.54, so this conditional
2770# definition can be removed once we require Autoconf 2.54 or later.
2771m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
2772[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
2773   [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2774    then ac_cv_prog_egrep='grep -E'
2775    else ac_cv_prog_egrep='egrep'
2776    fi])
2777 EGREP=$ac_cv_prog_egrep
2778 AC_SUBST([EGREP])
2779])])
2780
2781
2782# AC_PATH_TOOL_PREFIX
2783# -------------------
2784# find a file program which can recognise shared library
2785AC_DEFUN([AC_PATH_TOOL_PREFIX],
2786[AC_REQUIRE([AC_PROG_EGREP])dnl
2787AC_MSG_CHECKING([for $1])
2788AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2789[case $MAGIC_CMD in
2790[[\\/*] |  ?:[\\/]*])
2791  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2792  ;;
2793*)
2794  lt_save_MAGIC_CMD="$MAGIC_CMD"
2795  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2796dnl $ac_dummy forces splitting on constant user-supplied paths.
2797dnl POSIX.2 word splitting is done only on the output of word expansions,
2798dnl not every word.  This closes a longstanding sh security hole.
2799  ac_dummy="ifelse([$2], , $PATH, [$2])"
2800  for ac_dir in $ac_dummy; do
2801    IFS="$lt_save_ifs"
2802    test -z "$ac_dir" && ac_dir=.
2803    if test -f $ac_dir/$1; then
2804      lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2805      if test -n "$file_magic_test_file"; then
2806        case $deplibs_check_method in
2807        "file_magic "*)
2808          file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
2809          MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2810          if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2811            $EGREP "$file_magic_regex" > /dev/null; then
2812            :
2813          else
2814            cat <<EOF 1>&2
2815
2816*** Warning: the command libtool uses to detect shared libraries,
2817*** $file_magic_cmd, produces output that libtool cannot recognize.
2818*** The result is that libtool may fail to recognize shared libraries
2819*** as such.  This will affect the creation of libtool libraries that
2820*** depend on shared libraries, but programs linked with such libtool
2821*** libraries will work regardless of this problem.  Nevertheless, you
2822*** may want to report the problem to your system manager and/or to
2823*** bug-libtool@gnu.org
2824
2825EOF
2826          fi ;;
2827        esac
2828      fi
2829      break
2830    fi
2831  done
2832  IFS="$lt_save_ifs"
2833  MAGIC_CMD="$lt_save_MAGIC_CMD"
2834  ;;
2835esac])
2836MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2837if test -n "$MAGIC_CMD"; then
2838  AC_MSG_RESULT($MAGIC_CMD)
2839else
2840  AC_MSG_RESULT(no)
2841fi
2842])# AC_PATH_TOOL_PREFIX
2843
2844
2845# AC_PATH_MAGIC
2846# -------------
2847# find a file program which can recognise a shared library
2848AC_DEFUN([AC_PATH_MAGIC],
2849[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2850if test -z "$lt_cv_path_MAGIC_CMD"; then
2851  if test -n "$ac_tool_prefix"; then
2852    AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2853  else
2854    MAGIC_CMD=:
2855  fi
2856fi
2857])# AC_PATH_MAGIC
2858
2859
2860# AC_PROG_LD
2861# ----------
2862# find the pathname to the GNU or non-GNU linker
2863AC_DEFUN([AC_PROG_LD],
2864[AC_ARG_WITH([gnu-ld],
2865    [AC_HELP_STRING([--with-gnu-ld],
2866        [assume the C compiler uses GNU ld @<:@default=no@:>@])],
2867    [test "$withval" = no || with_gnu_ld=yes],
2868    [with_gnu_ld=no])
2869AC_REQUIRE([LT_AC_PROG_SED])dnl
2870AC_REQUIRE([AC_PROG_CC])dnl
2871AC_REQUIRE([AC_CANONICAL_HOST])dnl
2872AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2873ac_prog=ld
2874if test "$GCC" = yes; then
2875  # Check if gcc -print-prog-name=ld gives a path.
2876  AC_MSG_CHECKING([for ld used by $CC])
2877  case $host in
2878  *-*-mingw*)
2879    # gcc leaves a trailing carriage return which upsets mingw
2880    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2881  *)
2882    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2883  esac
2884  case $ac_prog in
2885    # Accept absolute paths.
2886    [[\\/]]* | ?:[[\\/]]*)
2887      re_direlt='/[[^/]][[^/]]*/\.\./'
2888      # Canonicalize the pathname of ld
2889      ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
2890      while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2891        ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
2892      done
2893      test -z "$LD" && LD="$ac_prog"
2894      ;;
2895  "")
2896    # If it fails, then pretend we aren't using GCC.
2897    ac_prog=ld
2898    ;;
2899  *)
2900    # If it is relative, then search for the first ld in PATH.
2901    with_gnu_ld=unknown
2902    ;;
2903  esac
2904elif test "$with_gnu_ld" = yes; then
2905  AC_MSG_CHECKING([for GNU ld])
2906else
2907  AC_MSG_CHECKING([for non-GNU ld])
2908fi
2909AC_CACHE_VAL(lt_cv_path_LD,
2910[if test -z "$LD"; then
2911  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2912  for ac_dir in $PATH; do
2913    IFS="$lt_save_ifs"
2914    test -z "$ac_dir" && ac_dir=.
2915    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2916      lt_cv_path_LD="$ac_dir/$ac_prog"
2917      # Check to see if the program is GNU ld.  I'd rather use --version,
2918      # but apparently some GNU ld's only accept -v.
2919      # Break only if it was the GNU/non-GNU ld that we prefer.
2920      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
2921      *GNU* | *'with BFD'*)
2922        test "$with_gnu_ld" != no && break
2923        ;;
2924      *)
2925        test "$with_gnu_ld" != yes && break
2926        ;;
2927      esac
2928    fi
2929  done
2930  IFS="$lt_save_ifs"
2931else
2932  lt_cv_path_LD="$LD" # Let the user override the test with a path.
2933fi])
2934LD="$lt_cv_path_LD"
2935if test -n "$LD"; then
2936  AC_MSG_RESULT($LD)
2937else
2938  AC_MSG_RESULT(no)
2939fi
2940test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
2941AC_PROG_LD_GNU
2942])# AC_PROG_LD
2943
2944
2945# AC_PROG_LD_GNU
2946# --------------
2947AC_DEFUN([AC_PROG_LD_GNU],
2948[AC_REQUIRE([AC_PROG_EGREP])dnl
2949AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
2950[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
2951case `$LD -v 2>&1 </dev/null` in
2952*GNU* | *'with BFD'*)
2953  lt_cv_prog_gnu_ld=yes
2954  ;;
2955*)
2956  lt_cv_prog_gnu_ld=no
2957  ;;
2958esac])
2959with_gnu_ld=$lt_cv_prog_gnu_ld
2960])# AC_PROG_LD_GNU
2961
2962
2963# AC_PROG_LD_RELOAD_FLAG
2964# ----------------------
2965# find reload flag for linker
2966#   -- PORTME Some linkers may need a different reload flag.
2967AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
2968[AC_CACHE_CHECK([for $LD option to reload object files],
2969  lt_cv_ld_reload_flag,
2970  [lt_cv_ld_reload_flag='-r'])
2971reload_flag=$lt_cv_ld_reload_flag
2972case $reload_flag in
2973"" | " "*) ;;
2974*) reload_flag=" $reload_flag" ;;
2975esac
2976reload_cmds='$LD$reload_flag -o $output$reload_objs'
2977])# AC_PROG_LD_RELOAD_FLAG
2978
2979
2980# AC_DEPLIBS_CHECK_METHOD
2981# -----------------------
2982# how to check for library dependencies
2983#  -- PORTME fill in with the dynamic library characteristics
2984AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
2985[AC_CACHE_CHECK([how to recognise dependent libraries],
2986lt_cv_deplibs_check_method,
2987[lt_cv_file_magic_cmd='$MAGIC_CMD'
2988lt_cv_file_magic_test_file=
2989lt_cv_deplibs_check_method='unknown'
2990# Need to set the preceding variable on all platforms that support
2991# interlibrary dependencies.
2992# 'none' -- dependencies not supported.
2993# `unknown' -- same as none, but documents that we really don't know.
2994# 'pass_all' -- all dependencies passed with no checks.
2995# 'test_compile' -- check by making test program.
2996# 'file_magic [[regex]]' -- check by looking for files in library path
2997# which responds to the $file_magic_cmd with a given extended regex.
2998# If you have `file' or equivalent on your system and you're not sure
2999# whether `pass_all' will *always* work, you probably want this one.
3000
3001case $host_os in
3002aix4* | aix5*)
3003  lt_cv_deplibs_check_method=pass_all
3004  ;;
3005
3006beos*)
3007  lt_cv_deplibs_check_method=pass_all
3008  ;;
3009
3010bsdi4*)
3011  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3012  lt_cv_file_magic_cmd='/usr/bin/file -L'
3013  lt_cv_file_magic_test_file=/shlib/libc.so
3014  ;;
3015
3016cygwin*)
3017  # func_win32_libid is a shell function defined in ltmain.sh
3018  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3019  lt_cv_file_magic_cmd='func_win32_libid'
3020  ;;
3021
3022mingw* | pw32*)
3023  # Base MSYS/MinGW do not provide the 'file' command needed by
3024  # func_win32_libid shell function, so use a weaker test based on 'objdump'.
3025  lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3026  lt_cv_file_magic_cmd='$OBJDUMP -f'
3027  ;;
3028
3029darwin* | rhapsody*)
3030  lt_cv_deplibs_check_method=pass_all
3031  ;;
3032
3033freebsd* | kfreebsd*-gnu)
3034  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3035    case $host_cpu in
3036    i*86 )
3037      # Not sure whether the presence of OpenBSD here was a mistake.
3038      # Let's accept both of them until this is cleared up.
3039      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[[3-9]]86 (compact )?demand paged shared library'
3040      lt_cv_file_magic_cmd=/usr/bin/file
3041      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3042      ;;
3043    esac
3044  else
3045    lt_cv_deplibs_check_method=pass_all
3046  fi
3047  ;;
3048
3049gnu*)
3050  lt_cv_deplibs_check_method=pass_all
3051  ;;
3052
3053hpux10.20* | hpux11*)
3054  lt_cv_file_magic_cmd=/usr/bin/file
3055  case "$host_cpu" in
3056  ia64*)
3057    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3058    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3059    ;;
3060  hppa*64*)
3061    [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
3062    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3063    ;;
3064  *)
3065    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3066    lt_cv_file_magic_test_file=/usr/lib/libc.sl
3067    ;;
3068  esac
3069  ;;
3070
3071irix5* | irix6* | nonstopux*)
3072  case $LD in
3073  *-32|*"-32 ") libmagic=32-bit;;
3074  *-n32|*"-n32 ") libmagic=N32;;
3075  *-64|*"-64 ") libmagic=64-bit;;
3076  *) libmagic=never-match;;
3077  esac
3078  lt_cv_deplibs_check_method=pass_all
3079  ;;
3080
3081# This must be Linux ELF.
3082linux*)
3083  lt_cv_deplibs_check_method=pass_all
3084  ;;
3085
3086netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
3087  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3088    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3089  else
3090    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3091  fi
3092  ;;
3093
3094newos6*)
3095  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3096  lt_cv_file_magic_cmd=/usr/bin/file
3097  lt_cv_file_magic_test_file=/usr/lib/libnls.so
3098  ;;
3099
3100nto-qnx*)
3101  lt_cv_deplibs_check_method=unknown
3102  ;;
3103
3104openbsd*)
3105  lt_cv_file_magic_cmd=/usr/bin/file
3106  lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3107  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3108    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB shared object'
3109  else
3110    lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library'
3111  fi
3112  ;;
3113
3114osf3* | osf4* | osf5*)
3115  lt_cv_deplibs_check_method=pass_all
3116  ;;
3117
3118sco3.2v5*)
3119  lt_cv_deplibs_check_method=pass_all
3120  ;;
3121
3122solaris*)
3123  lt_cv_deplibs_check_method=pass_all
3124  ;;
3125
3126sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
3127  case $host_vendor in
3128  motorola)
3129    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
3130    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3131    ;;
3132  ncr)
3133    lt_cv_deplibs_check_method=pass_all
3134    ;;
3135  sequent)
3136    lt_cv_file_magic_cmd='/bin/file'
3137    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3138    ;;
3139  sni)
3140    lt_cv_file_magic_cmd='/bin/file'
3141    lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3142    lt_cv_file_magic_test_file=/lib/libc.so
3143    ;;
3144  siemens)
3145    lt_cv_deplibs_check_method=pass_all
3146    ;;
3147  esac
3148  ;;
3149
3150sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
3151  lt_cv_deplibs_check_method=pass_all
3152  ;;
3153esac
3154])
3155file_magic_cmd=$lt_cv_file_magic_cmd
3156deplibs_check_method=$lt_cv_deplibs_check_method
3157test -z "$deplibs_check_method" && deplibs_check_method=unknown
3158])# AC_DEPLIBS_CHECK_METHOD
3159
3160
3161# AC_PROG_NM
3162# ----------
3163# find the pathname to a BSD-compatible name lister
3164AC_DEFUN([AC_PROG_NM],
3165[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
3166[if test -n "$NM"; then
3167  # Let the user override the test.
3168  lt_cv_path_NM="$NM"
3169else
3170  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3171  for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
3172    IFS="$lt_save_ifs"
3173    test -z "$ac_dir" && ac_dir=.
3174    tmp_nm="$ac_dir/${ac_tool_prefix}nm"
3175    if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3176      # Check to see if the nm accepts a BSD-compat flag.
3177      # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3178      #   nm: unknown option "B" ignored
3179      # Tru64's nm complains that /dev/null is an invalid object file
3180      case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3181      */dev/null* | *'Invalid file or object type'*)
3182        lt_cv_path_NM="$tmp_nm -B"
3183        break
3184        ;;
3185      *)
3186        case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3187        */dev/null*)
3188          lt_cv_path_NM="$tmp_nm -p"
3189          break
3190          ;;
3191        *)
3192          lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3193          continue # so that we can try to find one that supports BSD flags
3194          ;;
3195        esac
3196      esac
3197    fi
3198  done
3199  IFS="$lt_save_ifs"
3200  test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3201fi])
3202NM="$lt_cv_path_NM"
3203])# AC_PROG_NM
3204
3205
3206# AC_CHECK_LIBM
3207# -------------
3208# check for math library
3209AC_DEFUN([AC_CHECK_LIBM],
3210[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3211LIBM=
3212case $host in
3213*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3214  # These system don't have libm, or don't need it
3215  ;;
3216*-ncr-sysv4.3*)
3217  AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3218  AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3219  ;;
3220*)
3221  AC_CHECK_LIB(m, cos, LIBM="-lm")
3222  ;;
3223esac
3224])# AC_CHECK_LIBM
3225
3226
3227# AC_LIBLTDL_CONVENIENCE([DIRECTORY])
3228# -----------------------------------
3229# sets LIBLTDL to the link flags for the libltdl convenience library and
3230# LTDLINCL to the include flags for the libltdl header and adds
3231# --enable-ltdl-convenience to the configure arguments.  Note that LIBLTDL
3232# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called.  If
3233# DIRECTORY is not provided, it is assumed to be `libltdl'.  LIBLTDL will
3234# be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed with
3235# '${top_srcdir}/' (note the single quotes!).  If your package is not
3236# flat and you're not using automake, define top_builddir and
3237# top_srcdir appropriately in the Makefiles.
3238AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3239[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3240  case $enable_ltdl_convenience in
3241  no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3242  "") enable_ltdl_convenience=yes
3243      ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3244  esac
3245  LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3246  LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3247  # For backwards non-gettext consistent compatibility...
3248  INCLTDL="$LTDLINCL"
3249])# AC_LIBLTDL_CONVENIENCE
3250
3251
3252# AC_LIBLTDL_INSTALLABLE([DIRECTORY])
3253# -----------------------------------
3254# sets LIBLTDL to the link flags for the libltdl installable library and
3255# LTDLINCL to the include flags for the libltdl header and adds
3256# --enable-ltdl-install to the configure arguments.  Note that LIBLTDL
3257# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called.  If
3258# DIRECTORY is not provided and an installed libltdl is not found, it is
3259# assumed to be `libltdl'.  LIBLTDL will be prefixed with '${top_builddir}/'
3260# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single
3261# quotes!).  If your package is not flat and you're not using automake,
3262# define top_builddir and top_srcdir appropriately in the Makefiles.
3263# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3264AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3265[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3266  AC_CHECK_LIB(ltdl, lt_dlinit,
3267  [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3268  [if test x"$enable_ltdl_install" = xno; then
3269     AC_MSG_WARN([libltdl not installed, but installation disabled])
3270   else
3271     enable_ltdl_install=yes
3272   fi
3273  ])
3274  if test x"$enable_ltdl_install" = x"yes"; then
3275    ac_configure_args="$ac_configure_args --enable-ltdl-install"
3276    LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3277    LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3278  else
3279    ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
3280    LIBLTDL="-lltdl"
3281    LTDLINCL=
3282  fi
3283  # For backwards non-gettext consistent compatibility...
3284  INCLTDL="$LTDLINCL"
3285])# AC_LIBLTDL_INSTALLABLE
3286
3287
3288# AC_LIBTOOL_CXX
3289# --------------
3290# enable support for C++ libraries
3291AC_DEFUN([AC_LIBTOOL_CXX],
3292[AC_REQUIRE([_LT_AC_LANG_CXX])
3293])# AC_LIBTOOL_CXX
3294
3295
3296# _LT_AC_LANG_CXX
3297# ---------------
3298AC_DEFUN([_LT_AC_LANG_CXX],
3299[AC_REQUIRE([AC_PROG_CXX])
3300AC_REQUIRE([AC_PROG_CXXCPP])
3301_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
3302])# _LT_AC_LANG_CXX
3303
3304
3305# AC_LIBTOOL_F77
3306# --------------
3307# enable support for Fortran 77 libraries
3308AC_DEFUN([AC_LIBTOOL_F77],
3309[AC_REQUIRE([_LT_AC_LANG_F77])
3310])# AC_LIBTOOL_F77
3311
3312
3313# _LT_AC_LANG_F77
3314# ---------------
3315AC_DEFUN([_LT_AC_LANG_F77],
3316[AC_REQUIRE([AC_PROG_F77])
3317_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
3318])# _LT_AC_LANG_F77
3319
3320
3321# AC_LIBTOOL_GCJ
3322# --------------
3323# enable support for GCJ libraries
3324AC_DEFUN([AC_LIBTOOL_GCJ],
3325[AC_REQUIRE([_LT_AC_LANG_GCJ])
3326])# AC_LIBTOOL_GCJ
3327
3328
3329# _LT_AC_LANG_GCJ
3330# ---------------
3331AC_DEFUN([_LT_AC_LANG_GCJ],
3332[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
3333  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
3334    [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
3335      [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
3336         [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
3337           [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
3338_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
3339])# _LT_AC_LANG_GCJ
3340
3341
3342# AC_LIBTOOL_RC
3343# --------------
3344# enable support for Windows resource files
3345AC_DEFUN([AC_LIBTOOL_RC],
3346[AC_REQUIRE([LT_AC_PROG_RC])
3347_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
3348])# AC_LIBTOOL_RC
3349
3350
3351# AC_LIBTOOL_LANG_C_CONFIG
3352# ------------------------
3353# Ensure that the configuration vars for the C compiler are
3354# suitably defined.  Those variables are subsequently used by
3355# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3356AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
3357AC_DEFUN([_LT_AC_LANG_C_CONFIG],
3358[lt_save_CC="$CC"
3359AC_LANG_PUSH(C)
3360
3361# Source file extension for C test sources.
3362ac_ext=c
3363
3364# Object file extension for compiled C test sources.
3365objext=o
3366_LT_AC_TAGVAR(objext, $1)=$objext
3367
3368# Code to be used in simple compile tests
3369lt_simple_compile_test_code="int some_variable = 0;\n"
3370
3371# Code to be used in simple link tests
3372lt_simple_link_test_code='int main(){return(0);}\n'
3373
3374_LT_AC_SYS_COMPILER
3375
3376#
3377# Check for any special shared library compilation flags.
3378#
3379_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
3380if test "$GCC" = no; then
3381  case $host_os in
3382  sco3.2v5*)
3383    _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
3384    ;;
3385  esac
3386fi
3387if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
3388  AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
3389  if echo "$old_CC $old_CFLAGS " | grep "[[     ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[        ]]" >/dev/null; then :
3390  else
3391    AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
3392    _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
3393  fi
3394fi
3395
3396
3397#
3398# Check to make sure the static flag actually works.
3399#
3400AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
3401  _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
3402  $_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
3403  [],
3404  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
3405
3406
3407AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
3408AC_LIBTOOL_PROG_COMPILER_PIC($1)
3409AC_LIBTOOL_PROG_CC_C_O($1)
3410AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3411AC_LIBTOOL_PROG_LD_SHLIBS($1)
3412AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3413AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3414AC_LIBTOOL_SYS_LIB_STRIP
3415AC_LIBTOOL_DLOPEN_SELF($1)
3416
3417# Report which librarie types wil actually be built
3418AC_MSG_CHECKING([if libtool supports shared libraries])
3419AC_MSG_RESULT([$can_build_shared])
3420
3421AC_MSG_CHECKING([whether to build shared libraries])
3422test "$can_build_shared" = "no" && enable_shared=no
3423
3424# On AIX, shared libraries and static libraries use the same namespace, and
3425# are all built from PIC.
3426case "$host_os" in
3427aix3*)
3428  test "$enable_shared" = yes && enable_static=no
3429  if test -n "$RANLIB"; then
3430    archive_cmds="$archive_cmds~\$RANLIB \$lib"
3431    postinstall_cmds='$RANLIB $lib'
3432  fi
3433  ;;
3434
3435aix4* | aix5*)
3436  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3437    test "$enable_shared" = yes && enable_static=no
3438  fi
3439  ;;
3440  darwin* | rhapsody*)
3441  if test "$GCC" = yes; then
3442    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3443    case "$host_os" in
3444    rhapsody* | darwin1.[[012]])
3445      _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
3446      ;;
3447    *) # Darwin 1.3 on
3448      if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
3449        _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
3450      else
3451        case ${MACOSX_DEPLOYMENT_TARGET} in
3452          10.[[012]])
3453            _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
3454            ;;
3455          10.*)
3456            _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup'
3457            ;;
3458        esac
3459      fi
3460      ;;
3461    esac
3462    output_verbose_link_cmd='echo'
3463    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring'
3464    _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3465    # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
3466    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag  -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3467    _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3468    _LT_AC_TAGVAR(hardcode_direct, $1)=no
3469    _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3470    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3471    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
3472    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3473  else
3474    _LT_AC_TAGVAR(ld_shlibs, $1)=no
3475  fi
3476    ;;
3477esac
3478AC_MSG_RESULT([$enable_shared])
3479
3480AC_MSG_CHECKING([whether to build static libraries])
3481# Make sure either enable_shared or enable_static is yes.
3482test "$enable_shared" = yes || enable_static=yes
3483AC_MSG_RESULT([$enable_static])
3484
3485AC_LIBTOOL_CONFIG($1)
3486
3487AC_LANG_POP
3488CC="$lt_save_CC"
3489])# AC_LIBTOOL_LANG_C_CONFIG
3490
3491
3492# AC_LIBTOOL_LANG_CXX_CONFIG
3493# --------------------------
3494# Ensure that the configuration vars for the C compiler are
3495# suitably defined.  Those variables are subsequently used by
3496# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3497AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
3498AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
3499[AC_LANG_PUSH(C++)
3500AC_REQUIRE([AC_PROG_CXX])
3501AC_REQUIRE([AC_PROG_CXXCPP])
3502
3503_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3504_LT_AC_TAGVAR(allow_undefined_flag, $1)=
3505_LT_AC_TAGVAR(always_export_symbols, $1)=no
3506_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3507_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3508_LT_AC_TAGVAR(hardcode_direct, $1)=no
3509_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3510_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3511_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3512_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3513_LT_AC_TAGVAR(hardcode_automatic, $1)=no
3514_LT_AC_TAGVAR(module_cmds, $1)=
3515_LT_AC_TAGVAR(module_expsym_cmds, $1)=
3516_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3517_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3518_LT_AC_TAGVAR(no_undefined_flag, $1)=
3519_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3520_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3521
3522# Dependencies to place before and after the object being linked:
3523_LT_AC_TAGVAR(predep_objects, $1)=
3524_LT_AC_TAGVAR(postdep_objects, $1)=
3525_LT_AC_TAGVAR(predeps, $1)=
3526_LT_AC_TAGVAR(postdeps, $1)=
3527_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3528
3529# Source file extension for C++ test sources.
3530ac_ext=cc
3531
3532# Object file extension for compiled C++ test sources.
3533objext=o
3534_LT_AC_TAGVAR(objext, $1)=$objext
3535
3536# Code to be used in simple compile tests
3537lt_simple_compile_test_code="int some_variable = 0;\n"
3538
3539# Code to be used in simple link tests
3540lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
3541
3542# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3543_LT_AC_SYS_COMPILER
3544
3545# Allow CC to be a program name with arguments.
3546lt_save_CC=$CC
3547lt_save_LD=$LD
3548lt_save_GCC=$GCC
3549GCC=$GXX
3550lt_save_with_gnu_ld=$with_gnu_ld
3551lt_save_path_LD=$lt_cv_path_LD
3552if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3553  lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3554else
3555  unset lt_cv_prog_gnu_ld
3556fi
3557if test -n "${lt_cv_path_LDCXX+set}"; then
3558  lt_cv_path_LD=$lt_cv_path_LDCXX
3559else
3560  unset lt_cv_path_LD
3561fi
3562test -z "${LDCXX+set}" || LD=$LDCXX
3563CC=${CXX-"c++"}
3564compiler=$CC
3565_LT_AC_TAGVAR(compiler, $1)=$CC
3566cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
3567
3568# We don't want -fno-exception wen compiling C++ code, so set the
3569# no_builtin_flag separately
3570if test "$GXX" = yes; then
3571  _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3572else
3573  _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3574fi
3575
3576if test "$GXX" = yes; then
3577  # Set up default GNU C++ configuration
3578
3579  AC_PROG_LD
3580
3581  # Check if GNU C++ uses GNU ld as the underlying linker, since the
3582  # archiving commands below assume that GNU ld is being used.
3583  if test "$with_gnu_ld" = yes; then
3584    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3585    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3586
3587    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3588    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3589
3590    # If archive_cmds runs LD, not CC, wlarc should be empty
3591    # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3592    #     investigate it a little bit more. (MM)
3593    wlarc='${wl}'
3594
3595    # ancient GNU ld didn't support --whole-archive et. al.
3596    if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3597        grep 'no-whole-archive' > /dev/null; then
3598      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3599    else
3600      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3601    fi
3602  else
3603    with_gnu_ld=no
3604    wlarc=
3605
3606    # A generic and very simple default shared library creation
3607    # command for GNU C++ for the case where it uses the native
3608    # linker, instead of GNU ld.  If possible, this setting should
3609    # overridden to take advantage of the native linker features on
3610    # the platform it is being used on.
3611    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3612  fi
3613
3614  # Commands to make compiler produce verbose output that lists
3615  # what "hidden" libraries, object files and flags are used when
3616  # linking a shared library.
3617  output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3618
3619else
3620  GXX=no
3621  with_gnu_ld=no
3622  wlarc=
3623fi
3624
3625# PORTME: fill in a description of your system's C++ link characteristics
3626AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3627_LT_AC_TAGVAR(ld_shlibs, $1)=yes
3628case $host_os in
3629  aix3*)
3630    # FIXME: insert proper C++ library support
3631    _LT_AC_TAGVAR(ld_shlibs, $1)=no
3632    ;;
3633  aix4* | aix5*)
3634    if test "$host_cpu" = ia64; then
3635      # On IA64, the linker does run time linking by default, so we don't
3636      # have to do anything special.
3637      aix_use_runtimelinking=no
3638      exp_sym_flag='-Bexport'
3639      no_entry_flag=""
3640    else
3641      aix_use_runtimelinking=no
3642
3643      # Test if we are trying to use run time linking or normal
3644      # AIX style linking. If -brtl is somewhere in LDFLAGS, we
3645      # need to do runtime linking.
3646      case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
3647        for ld_flag in $LDFLAGS; do
3648          case $ld_flag in
3649          *-brtl*)
3650            aix_use_runtimelinking=yes
3651            break
3652            ;;
3653          esac
3654        done
3655      esac
3656
3657      exp_sym_flag='-bexport'
3658      no_entry_flag='-bnoentry'
3659    fi
3660
3661    # When large executables or shared objects are built, AIX ld can
3662    # have problems creating the table of contents.  If linking a library
3663    # or program results in "error TOC overflow" add -mminimal-toc to
3664    # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
3665    # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3666
3667    _LT_AC_TAGVAR(archive_cmds, $1)=''
3668    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3669    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3670    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3671
3672    if test "$GXX" = yes; then
3673      case $host_os in aix4.[012]|aix4.[012].*)
3674      # We only want to do this on AIX 4.2 and lower, the check
3675      # below for broken collect2 doesn't work under 4.3+
3676        collect2name=`${CC} -print-prog-name=collect2`
3677        if test -f "$collect2name" && \
3678           strings "$collect2name" | grep resolve_lib_name >/dev/null
3679        then
3680          # We have reworked collect2
3681          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3682        else
3683          # We have old collect2
3684          _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3685          # It fails to find uninstalled libraries when the uninstalled
3686          # path is not listed in the libpath.  Setting hardcode_minus_L
3687          # to unsupported forces relinking
3688          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3689          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3690          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3691        fi
3692      esac
3693      shared_flag='-shared'
3694    else
3695      # not using gcc
3696      if test "$host_cpu" = ia64; then
3697        # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3698        # chokes on -Wl,-G. The following line is correct:
3699        shared_flag='-G'
3700      else
3701        if test "$aix_use_runtimelinking" = yes; then
3702          shared_flag='${wl}-G'
3703        else
3704          shared_flag='${wl}-bM:SRE'
3705        fi
3706      fi
3707    fi
3708
3709    # It seems that -bexpall does not export symbols beginning with
3710    # underscore (_), so it is better to generate a list of symbols to export.
3711    _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3712    if test "$aix_use_runtimelinking" = yes; then
3713      # Warning - without using the other runtime loading flags (-brtl),
3714      # -berok will link without error, but may produce a broken library.
3715      _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3716      # Determine the default libpath from the value encoded in an empty executable.
3717      _LT_AC_SYS_LIBPATH_AIX
3718      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3719
3720      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3721     else
3722      if test "$host_cpu" = ia64; then
3723        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3724        _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3725        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
3726      else
3727        # Determine the default libpath from the value encoded in an empty executable.
3728        _LT_AC_SYS_LIBPATH_AIX
3729        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3730        # Warning - without using the other run time loading flags,
3731        # -berok will link without error, but may produce a broken library.
3732        _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3733        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3734        # -bexpall does not export symbols beginning with underscore (_)
3735        _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3736        # Exported symbols can be pulled into shared objects from archives
3737        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
3738        _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3739        # This is similar to how AIX traditionally builds it's shared libraries.
3740        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
3741      fi
3742    fi
3743    ;;
3744  chorus*)
3745    case $cc_basename in
3746      *)
3747        # FIXME: insert proper C++ library support
3748        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3749        ;;
3750    esac
3751    ;;
3752
3753  cygwin* | mingw* | pw32*)
3754    # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3755    # as there is no search path for DLLs.
3756    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3757    _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3758    _LT_AC_TAGVAR(always_export_symbols, $1)=no
3759    _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3760
3761    if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3762      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
3763      # If the export-symbols file already is a .def file (1st line
3764      # is EXPORTS), use it as is; otherwise, prepend...
3765      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3766        cp $export_symbols $output_objdir/$soname.def;
3767      else
3768        echo EXPORTS > $output_objdir/$soname.def;
3769        cat $export_symbols >> $output_objdir/$soname.def;
3770      fi~
3771      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
3772    else
3773      _LT_AC_TAGVAR(ld_shlibs, $1)=no
3774    fi
3775  ;;
3776
3777  darwin* | rhapsody*)
3778  if test "$GXX" = yes; then
3779    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3780    case "$host_os" in
3781    rhapsody* | darwin1.[[012]])
3782      _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
3783      ;;
3784    *) # Darwin 1.3 on
3785      if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
3786        _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
3787      else
3788        case ${MACOSX_DEPLOYMENT_TARGET} in
3789          10.[[012]])
3790            _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
3791            ;;
3792          10.*)
3793            _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup'
3794            ;;
3795        esac
3796      fi
3797      ;;
3798    esac
3799    lt_int_apple_cc_single_mod=no
3800    output_verbose_link_cmd='echo'
3801    if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
3802      lt_int_apple_cc_single_mod=yes
3803    fi
3804    if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3805      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
3806    else
3807      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
3808    fi
3809    _LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3810
3811    # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
3812    if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3813      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3814    else
3815      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3816    fi
3817    _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3818    _LT_AC_TAGVAR(hardcode_direct, $1)=no
3819    _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3820    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3821    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
3822    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3823  else
3824    _LT_AC_TAGVAR(ld_shlibs, $1)=no
3825  fi
3826    ;;
3827
3828  dgux*)
3829    case $cc_basename in
3830      ec++)
3831        # FIXME: insert proper C++ library support
3832        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3833        ;;
3834      ghcx)
3835        # Green Hills C++ Compiler
3836        # FIXME: insert proper C++ library support
3837        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3838        ;;
3839      *)
3840        # FIXME: insert proper C++ library support
3841        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3842        ;;
3843    esac
3844    ;;
3845  freebsd[12]*)
3846    # C++ shared libraries reported to be fairly broken before switch to ELF
3847    _LT_AC_TAGVAR(ld_shlibs, $1)=no
3848    ;;
3849  freebsd-elf*)
3850    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3851    ;;
3852  freebsd* | kfreebsd*-gnu)
3853    # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3854    # conventions
3855    _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3856    ;;
3857  gnu*)
3858    ;;
3859  hpux9*)
3860    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3861    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3862    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3863    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3864    _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3865                                # but as the default
3866                                # location of the library.
3867
3868    case $cc_basename in
3869    CC)
3870      # FIXME: insert proper C++ library support
3871      _LT_AC_TAGVAR(ld_shlibs, $1)=no
3872      ;;
3873    aCC)
3874      _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3875      # Commands to make compiler produce verbose output that lists
3876      # what "hidden" libraries, object files and flags are used when
3877      # linking a shared library.
3878      #
3879      # There doesn't appear to be a way to prevent this compiler from
3880      # explicitly linking system object files so we need to strip them
3881      # from the output so that they don't get included in the library
3882      # dependencies.
3883      output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[-]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3884      ;;
3885    *)
3886      if test "$GXX" = yes; then
3887        _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3888      else
3889        # FIXME: insert proper C++ library support
3890        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3891      fi
3892      ;;
3893    esac
3894    ;;
3895  hpux10*|hpux11*)
3896    if test $with_gnu_ld = no; then
3897      case "$host_cpu" in
3898      hppa*64*)
3899        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3900        _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
3901        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3902        ;;
3903      ia64*)
3904        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3905        ;;
3906      *)
3907        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3908        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3909        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3910        ;;
3911      esac
3912    fi
3913    case "$host_cpu" in
3914    hppa*64*)
3915      _LT_AC_TAGVAR(hardcode_direct, $1)=no
3916      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3917      ;;
3918    ia64*)
3919      _LT_AC_TAGVAR(hardcode_direct, $1)=no
3920      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3921      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3922                                              # but as the default
3923                                              # location of the library.
3924      ;;
3925    *)
3926      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3927      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3928                                              # but as the default
3929                                              # location of the library.
3930      ;;
3931    esac
3932
3933    case $cc_basename in
3934      CC)
3935        # FIXME: insert proper C++ library support
3936        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3937        ;;
3938      aCC)
3939        case "$host_cpu" in
3940        hppa*64*|ia64*)
3941          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
3942          ;;
3943        *)
3944          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3945          ;;
3946        esac
3947        # Commands to make compiler produce verbose output that lists
3948        # what "hidden" libraries, object files and flags are used when
3949        # linking a shared library.
3950        #
3951        # There doesn't appear to be a way to prevent this compiler from
3952        # explicitly linking system object files so we need to strip them
3953        # from the output so that they don't get included in the library
3954        # dependencies.
3955        output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3956        ;;
3957      *)
3958        if test "$GXX" = yes; then
3959          if test $with_gnu_ld = no; then
3960            case "$host_cpu" in
3961            ia64*|hppa*64*)
3962              _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
3963              ;;
3964            *)
3965              _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3966              ;;
3967            esac
3968          fi
3969        else
3970          # FIXME: insert proper C++ library support
3971          _LT_AC_TAGVAR(ld_shlibs, $1)=no
3972        fi
3973        ;;
3974    esac
3975    ;;
3976  irix5* | irix6*)
3977    case $cc_basename in
3978      CC)
3979        # SGI C++
3980        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib'
3981
3982        # Archives containing C++ object files must be created using
3983        # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
3984        # necessary to make sure instantiated templates are included
3985        # in the archive.
3986        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
3987        ;;
3988      *)
3989        if test "$GXX" = yes; then
3990          if test "$with_gnu_ld" = no; then
3991            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
3992          else
3993            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
3994          fi
3995        fi
3996        _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3997        ;;
3998    esac
3999    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4000    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4001    ;;
4002  linux*)
4003    case $cc_basename in
4004      KCC)
4005        # Kuck and Associates, Inc. (KAI) C++ Compiler
4006
4007        # KCC will only create a shared library if the output file
4008        # ends with ".so" (or ".sl" for HP-UX), so rename the library
4009        # to its proper name (with version) after linking.
4010        _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4011        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
4012        # Commands to make compiler produce verbose output that lists
4013        # what "hidden" libraries, object files and flags are used when
4014        # linking a shared library.
4015        #
4016        # There doesn't appear to be a way to prevent this compiler from
4017        # explicitly linking system object files so we need to strip them
4018        # from the output so that they don't get included in the library
4019        # dependencies.
4020        output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4021
4022        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
4023        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4024
4025        # Archives containing C++ object files must be created using
4026        # "CC -Bstatic", where "CC" is the KAI C++ compiler.
4027        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4028        ;;
4029      icpc)
4030        # Intel C++
4031        with_gnu_ld=yes
4032        _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4033        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4034        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4035        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4036        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4037        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
4038        ;;
4039      cxx)
4040        # Compaq C++
4041        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4042        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname  -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
4043
4044        runpath_var=LD_RUN_PATH
4045        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4046        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4047
4048        # Commands to make compiler produce verbose output that lists
4049        # what "hidden" libraries, object files and flags are used when
4050        # linking a shared library.
4051        #
4052        # There doesn't appear to be a way to prevent this compiler from
4053        # explicitly linking system object files so we need to strip them
4054        # from the output so that they don't get included in the library
4055        # dependencies.
4056        output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4057        ;;
4058    esac
4059    ;;
4060  lynxos*)
4061    # FIXME: insert proper C++ library support
4062    _LT_AC_TAGVAR(ld_shlibs, $1)=no
4063    ;;
4064  m88k*)
4065    # FIXME: insert proper C++ library support
4066    _LT_AC_TAGVAR(ld_shlibs, $1)=no
4067    ;;
4068  mvs*)
4069    case $cc_basename in
4070      cxx)
4071        # FIXME: insert proper C++ library support
4072        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4073        ;;
4074      *)
4075        # FIXME: insert proper C++ library support
4076        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4077        ;;
4078    esac
4079    ;;
4080  netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
4081    if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4082      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
4083      wlarc=
4084      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4085      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4086      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4087    fi
4088    # Workaround some broken pre-1.5 toolchains
4089    output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
4090    ;;
4091  osf3*)
4092    case $cc_basename in
4093      KCC)
4094        # Kuck and Associates, Inc. (KAI) C++ Compiler
4095
4096        # KCC will only create a shared library if the output file
4097        # ends with ".so" (or ".sl" for HP-UX), so rename the library
4098        # to its proper name (with version) after linking.
4099        _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4100
4101        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4102        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4103
4104        # Archives containing C++ object files must be created using
4105        # "CC -Bstatic", where "CC" is the KAI C++ compiler.
4106        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4107
4108        ;;
4109      RCC)
4110        # Rational C++ 2.4.1
4111        # FIXME: insert proper C++ library support
4112        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4113        ;;
4114      cxx)
4115        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4116        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${objdir}/so_locations -o $lib'
4117
4118        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4119        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4120
4121        # Commands to make compiler produce verbose output that lists
4122        # what "hidden" libraries, object files and flags are used when
4123        # linking a shared library.
4124        #
4125        # There doesn't appear to be a way to prevent this compiler from
4126        # explicitly linking system object files so we need to strip them
4127        # from the output so that they don't get included in the library
4128        # dependencies.
4129        output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4130        ;;
4131      *)
4132        if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4133          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4134          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
4135
4136          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4137          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4138
4139          # Commands to make compiler produce verbose output that lists
4140          # what "hidden" libraries, object files and flags are used when
4141          # linking a shared library.
4142          output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4143
4144        else
4145          # FIXME: insert proper C++ library support
4146          _LT_AC_TAGVAR(ld_shlibs, $1)=no
4147        fi
4148        ;;
4149    esac
4150    ;;
4151  osf4* | osf5*)
4152    case $cc_basename in
4153      KCC)
4154        # Kuck and Associates, Inc. (KAI) C++ Compiler
4155
4156        # KCC will only create a shared library if the output file
4157        # ends with ".so" (or ".sl" for HP-UX), so rename the library
4158        # to its proper name (with version) after linking.
4159        _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4160
4161        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4162        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4163
4164        # Archives containing C++ object files must be created using
4165        # the KAI C++ compiler.
4166        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
4167        ;;
4168      RCC)
4169        # Rational C++ 2.4.1
4170        # FIXME: insert proper C++ library support
4171        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4172        ;;
4173      cxx)
4174        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
4175        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib'
4176        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
4177          echo "-hidden">> $lib.exp~
4178          $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp  `test -n "$verstring" && echo -set_version $verstring` -update_registry $objdir/so_locations -o $lib~
4179          $rm $lib.exp'
4180
4181        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4182        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4183
4184        # Commands to make compiler produce verbose output that lists
4185        # what "hidden" libraries, object files and flags are used when
4186        # linking a shared library.
4187        #
4188        # There doesn't appear to be a way to prevent this compiler from
4189        # explicitly linking system object files so we need to strip them
4190        # from the output so that they don't get included in the library
4191        # dependencies.
4192        output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4193        ;;
4194      *)
4195        if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4196          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4197         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
4198
4199          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4200          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4201
4202          # Commands to make compiler produce verbose output that lists
4203          # what "hidden" libraries, object files and flags are used when
4204          # linking a shared library.
4205          output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4206
4207        else
4208          # FIXME: insert proper C++ library support
4209          _LT_AC_TAGVAR(ld_shlibs, $1)=no
4210        fi
4211        ;;
4212    esac
4213    ;;
4214  psos*)
4215    # FIXME: insert proper C++ library support
4216    _LT_AC_TAGVAR(ld_shlibs, $1)=no
4217    ;;
4218  sco*)
4219    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4220    case $cc_basename in
4221      CC)
4222        # FIXME: insert proper C++ library support
4223        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4224        ;;
4225      *)
4226        # FIXME: insert proper C++ library support
4227        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4228        ;;
4229    esac
4230    ;;
4231  sunos4*)
4232    case $cc_basename in
4233      CC)
4234        # Sun C++ 4.x
4235        # FIXME: insert proper C++ library support
4236        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4237        ;;
4238      lcc)
4239        # Lucid
4240        # FIXME: insert proper C++ library support
4241        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4242        ;;
4243      *)
4244        # FIXME: insert proper C++ library support
4245        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4246        ;;
4247    esac
4248    ;;
4249  solaris*)
4250    case $cc_basename in
4251      CC)
4252        # Sun C++ 4.2, 5.x and Centerline C++
4253        _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4254        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4255        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4256        $CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4257
4258        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4259        _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4260        case $host_os in
4261          solaris2.[0-5] | solaris2.[0-5].*) ;;
4262          *)
4263            # The C++ compiler is used as linker so we must use $wl
4264            # flag to pass the commands to the underlying system
4265            # linker.
4266            # Supported since Solaris 2.6 (maybe 2.5.1?)
4267            _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
4268            ;;
4269        esac
4270        _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4271
4272        # Commands to make compiler produce verbose output that lists
4273        # what "hidden" libraries, object files and flags are used when
4274        # linking a shared library.
4275        #
4276        # There doesn't appear to be a way to prevent this compiler from
4277        # explicitly linking system object files so we need to strip them
4278        # from the output so that they don't get included in the library
4279        # dependencies.
4280        output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4281
4282        # Archives containing C++ object files must be created using
4283        # "CC -xar", where "CC" is the Sun C++ compiler.  This is
4284        # necessary to make sure instantiated templates are included
4285        # in the archive.
4286        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4287        ;;
4288      gcx)
4289        # Green Hills C++ Compiler
4290        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4291
4292        # The C++ compiler must be used to create the archive.
4293        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
4294        ;;
4295      *)
4296        # GNU C++ compiler with Solaris linker
4297        if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4298          _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
4299          if $CC --version | grep -v '^2\.7' > /dev/null; then
4300            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4301            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4302                $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4303
4304            # Commands to make compiler produce verbose output that lists
4305            # what "hidden" libraries, object files and flags are used when
4306            # linking a shared library.
4307            output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4308          else
4309            # g++ 2.7 appears to require `-G' NOT `-shared' on this
4310            # platform.
4311            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4312            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4313                $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4314
4315            # Commands to make compiler produce verbose output that lists
4316            # what "hidden" libraries, object files and flags are used when
4317            # linking a shared library.
4318            output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4319          fi
4320
4321          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
4322        fi
4323        ;;
4324    esac
4325    ;;
4326  sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
4327    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4328    ;;
4329  tandem*)
4330    case $cc_basename in
4331      NCC)
4332        # NonStop-UX NCC 3.20
4333        # FIXME: insert proper C++ library support
4334        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4335        ;;
4336      *)
4337        # FIXME: insert proper C++ library support
4338        _LT_AC_TAGVAR(ld_shlibs, $1)=no
4339        ;;
4340    esac
4341    ;;
4342  vxworks*)
4343    # FIXME: insert proper C++ library support
4344    _LT_AC_TAGVAR(ld_shlibs, $1)=no
4345    ;;
4346  *)
4347    # FIXME: insert proper C++ library support
4348    _LT_AC_TAGVAR(ld_shlibs, $1)=no
4349    ;;
4350esac
4351AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
4352test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4353
4354_LT_AC_TAGVAR(GCC, $1)="$GXX"
4355_LT_AC_TAGVAR(LD, $1)="$LD"
4356
4357AC_LIBTOOL_POSTDEP_PREDEP($1)
4358AC_LIBTOOL_PROG_COMPILER_PIC($1)
4359AC_LIBTOOL_PROG_CC_C_O($1)
4360AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4361AC_LIBTOOL_PROG_LD_SHLIBS($1)
4362AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4363AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4364AC_LIBTOOL_SYS_LIB_STRIP
4365AC_LIBTOOL_DLOPEN_SELF($1)
4366
4367AC_LIBTOOL_CONFIG($1)
4368
4369AC_LANG_POP
4370CC=$lt_save_CC
4371LDCXX=$LD
4372LD=$lt_save_LD
4373GCC=$lt_save_GCC
4374with_gnu_ldcxx=$with_gnu_ld
4375with_gnu_ld=$lt_save_with_gnu_ld
4376lt_cv_path_LDCXX=$lt_cv_path_LD
4377lt_cv_path_LD=$lt_save_path_LD
4378lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
4379lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
4380])# AC_LIBTOOL_LANG_CXX_CONFIG
4381
4382# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
4383# ------------------------
4384# Figure out "hidden" library dependencies from verbose
4385# compiler output when linking a shared library.
4386# Parse the compiler output and extract the necessary
4387# objects, libraries and library flags.
4388AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
4389dnl we can't use the lt_simple_compile_test_code here,
4390dnl because it contains code intended for an executable,
4391dnl not a library.  It's possible we should let each
4392dnl tag define a new lt_????_link_test_code variable,
4393dnl but it's only used here...
4394ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
4395int a;
4396void foo (void) { a = 0; }
4397EOF
4398],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
4399class Foo
4400{
4401public:
4402  Foo (void) { a = 0; }
4403private:
4404  int a;
4405};
4406EOF
4407],[$1],[F77],[cat > conftest.$ac_ext <<EOF
4408      subroutine foo
4409      implicit none
4410      integer*4 a
4411      a=0
4412      return
4413      end
4414EOF
4415],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
4416public class foo {
4417  private int a;
4418  public void bar (void) {
4419    a = 0;
4420  }
4421};
4422EOF
4423])
4424dnl Parse the compiler output and extract the necessary
4425dnl objects, libraries and library flags.
4426if AC_TRY_EVAL(ac_compile); then
4427  # Parse the compiler output and extract the necessary
4428  # objects, libraries and library flags.
4429
4430  # Sentinel used to keep track of whether or not we are before
4431  # the conftest object file.
4432  pre_test_object_deps_done=no
4433
4434  # The `*' in the case matches for architectures that use `case' in
4435  # $output_verbose_cmd can trigger glob expansion during the loop
4436  # eval without this substitution.
4437  output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`"
4438
4439  for p in `eval $output_verbose_link_cmd`; do
4440    case $p in
4441
4442    -L* | -R* | -l*)
4443       # Some compilers place space between "-{L,R}" and the path.
4444       # Remove the space.
4445       if test $p = "-L" \
4446          || test $p = "-R"; then
4447         prev=$p
4448         continue
4449       else
4450         prev=
4451       fi
4452
4453       if test "$pre_test_object_deps_done" = no; then
4454         case $p in
4455         -L* | -R*)
4456           # Internal compiler library paths should come after those
4457           # provided the user.  The postdeps already come after the
4458           # user supplied libs so there is no need to process them.
4459           if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4460             _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
4461           else
4462             _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
4463           fi
4464           ;;
4465         # The "-l" case would never come before the object being
4466         # linked, so don't bother handling this case.
4467         esac
4468       else
4469         if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
4470           _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
4471         else
4472           _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
4473         fi
4474       fi
4475       ;;
4476
4477    *.$objext)
4478       # This assumes that the test object file only shows up
4479       # once in the compiler output.
4480       if test "$p" = "conftest.$objext"; then
4481         pre_test_object_deps_done=yes
4482         continue
4483       fi
4484
4485       if test "$pre_test_object_deps_done" = no; then
4486         if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
4487           _LT_AC_TAGVAR(predep_objects, $1)="$p"
4488         else
4489           _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
4490         fi
4491       else
4492         if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
4493           _LT_AC_TAGVAR(postdep_objects, $1)="$p"
4494         else
4495           _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
4496         fi
4497       fi
4498       ;;
4499
4500    *) ;; # Ignore the rest.
4501
4502    esac
4503  done
4504
4505  # Clean up.
4506  rm -f a.out a.exe
4507else
4508  echo "libtool.m4: error: problem compiling $1 test program"
4509fi
4510
4511$rm -f confest.$objext
4512
4513case " $_LT_AC_TAGVAR(postdeps, $1) " in
4514*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4515esac
4516])# AC_LIBTOOL_POSTDEP_PREDEP
4517
4518# AC_LIBTOOL_LANG_F77_CONFIG
4519# ------------------------
4520# Ensure that the configuration vars for the C compiler are
4521# suitably defined.  Those variables are subsequently used by
4522# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4523AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4524AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4525[AC_REQUIRE([AC_PROG_F77])
4526AC_LANG_PUSH(Fortran 77)
4527
4528_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4529_LT_AC_TAGVAR(allow_undefined_flag, $1)=
4530_LT_AC_TAGVAR(always_export_symbols, $1)=no
4531_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
4532_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
4533_LT_AC_TAGVAR(hardcode_direct, $1)=no
4534_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
4535_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4536_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
4537_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
4538_LT_AC_TAGVAR(hardcode_automatic, $1)=no
4539_LT_AC_TAGVAR(module_cmds, $1)=
4540_LT_AC_TAGVAR(module_expsym_cmds, $1)=
4541_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
4542_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4543_LT_AC_TAGVAR(no_undefined_flag, $1)=
4544_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
4545_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4546
4547# Source file extension for f77 test sources.
4548ac_ext=f
4549
4550# Object file extension for compiled f77 test sources.
4551objext=o
4552_LT_AC_TAGVAR(objext, $1)=$objext
4553
4554# Code to be used in simple compile tests
4555lt_simple_compile_test_code="      subroutine t\n      return\n      end\n"
4556
4557# Code to be used in simple link tests
4558lt_simple_link_test_code="      program t\n      end\n"
4559
4560# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4561_LT_AC_SYS_COMPILER
4562
4563# Allow CC to be a program name with arguments.
4564lt_save_CC="$CC"
4565CC=${F77-"f77"}
4566compiler=$CC
4567_LT_AC_TAGVAR(compiler, $1)=$CC
4568cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
4569
4570AC_MSG_CHECKING([if libtool supports shared libraries])
4571AC_MSG_RESULT([$can_build_shared])
4572
4573AC_MSG_CHECKING([whether to build shared libraries])
4574test "$can_build_shared" = "no" && enable_shared=no
4575
4576# On AIX, shared libraries and static libraries use the same namespace, and
4577# are all built from PIC.
4578case "$host_os" in
4579aix3*)
4580  test "$enable_shared" = yes && enable_static=no
4581  if test -n "$RANLIB"; then
4582    archive_cmds="$archive_cmds~\$RANLIB \$lib"
4583    postinstall_cmds='$RANLIB $lib'
4584  fi
4585  ;;
4586aix4* | aix5*)
4587  test "$enable_shared" = yes && enable_static=no
4588  ;;
4589esac
4590AC_MSG_RESULT([$enable_shared])
4591
4592AC_MSG_CHECKING([whether to build static libraries])
4593# Make sure either enable_shared or enable_static is yes.
4594test "$enable_shared" = yes || enable_static=yes
4595AC_MSG_RESULT([$enable_static])
4596
4597test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4598
4599_LT_AC_TAGVAR(GCC, $1)="$G77"
4600_LT_AC_TAGVAR(LD, $1)="$LD"
4601
4602AC_LIBTOOL_PROG_COMPILER_PIC($1)
4603AC_LIBTOOL_PROG_CC_C_O($1)
4604AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4605AC_LIBTOOL_PROG_LD_SHLIBS($1)
4606AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4607AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4608AC_LIBTOOL_SYS_LIB_STRIP
4609
4610
4611AC_LIBTOOL_CONFIG($1)
4612
4613AC_LANG_POP
4614CC="$lt_save_CC"
4615])# AC_LIBTOOL_LANG_F77_CONFIG
4616
4617
4618# AC_LIBTOOL_LANG_GCJ_CONFIG
4619# --------------------------
4620# Ensure that the configuration vars for the C compiler are
4621# suitably defined.  Those variables are subsequently used by
4622# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4623AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4624AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4625[AC_LANG_SAVE
4626
4627# Source file extension for Java test sources.
4628ac_ext=java
4629
4630# Object file extension for compiled Java test sources.
4631objext=o
4632_LT_AC_TAGVAR(objext, $1)=$objext
4633
4634# Code to be used in simple compile tests
4635lt_simple_compile_test_code="class foo {}\n"
4636
4637# Code to be used in simple link tests
4638lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n'
4639
4640# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4641_LT_AC_SYS_COMPILER
4642
4643# Allow CC to be a program name with arguments.
4644lt_save_CC="$CC"
4645CC=${GCJ-"gcj"}
4646compiler=$CC
4647_LT_AC_TAGVAR(compiler, $1)=$CC
4648
4649# GCJ did not exist at the time GCC didn't implicitly link libc in.
4650_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4651
4652AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4653AC_LIBTOOL_PROG_COMPILER_PIC($1)
4654AC_LIBTOOL_PROG_CC_C_O($1)
4655AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4656AC_LIBTOOL_PROG_LD_SHLIBS($1)
4657AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4658AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4659AC_LIBTOOL_SYS_LIB_STRIP
4660AC_LIBTOOL_DLOPEN_SELF($1)
4661
4662AC_LIBTOOL_CONFIG($1)
4663
4664AC_LANG_RESTORE
4665CC="$lt_save_CC"
4666])# AC_LIBTOOL_LANG_GCJ_CONFIG
4667
4668
4669# AC_LIBTOOL_LANG_RC_CONFIG
4670# --------------------------
4671# Ensure that the configuration vars for the Windows resource compiler are
4672# suitably defined.  Those variables are subsequently used by
4673# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4674AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4675AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4676[AC_LANG_SAVE
4677
4678# Source file extension for RC test sources.
4679ac_ext=rc
4680
4681# Object file extension for compiled RC test sources.
4682objext=o
4683_LT_AC_TAGVAR(objext, $1)=$objext
4684
4685# Code to be used in simple compile tests
4686lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
4687
4688# Code to be used in simple link tests
4689lt_simple_link_test_code="$lt_simple_compile_test_code"
4690
4691# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4692_LT_AC_SYS_COMPILER
4693
4694# Allow CC to be a program name with arguments.
4695lt_save_CC="$CC"
4696CC=${RC-"windres"}
4697compiler=$CC
4698_LT_AC_TAGVAR(compiler, $1)=$CC
4699_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4700
4701AC_LIBTOOL_CONFIG($1)
4702
4703AC_LANG_RESTORE
4704CC="$lt_save_CC"
4705])# AC_LIBTOOL_LANG_RC_CONFIG
4706
4707
4708# AC_LIBTOOL_CONFIG([TAGNAME])
4709# ----------------------------
4710# If TAGNAME is not passed, then create an initial libtool script
4711# with a default configuration from the untagged config vars.  Otherwise
4712# add code to config.status for appending the configuration named by
4713# TAGNAME from the matching tagged config vars.
4714AC_DEFUN([AC_LIBTOOL_CONFIG],
4715[# The else clause should only fire when bootstrapping the
4716# libtool distribution, otherwise you forgot to ship ltmain.sh
4717# with your package, and you will get complaints that there are
4718# no rules to generate ltmain.sh.
4719if test -f "$ltmain"; then
4720  # See if we are running on zsh, and set the options which allow our commands through
4721  # without removal of \ escapes.
4722  if test -n "${ZSH_VERSION+set}" ; then
4723    setopt NO_GLOB_SUBST
4724  fi
4725  # Now quote all the things that may contain metacharacters while being
4726  # careful not to overquote the AC_SUBSTed values.  We take copies of the
4727  # variables and quote the copies for generation of the libtool script.
4728  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
4729    SED SHELL STRIP \
4730    libname_spec library_names_spec soname_spec extract_expsyms_cmds \
4731    old_striplib striplib file_magic_cmd finish_cmds finish_eval \
4732    deplibs_check_method reload_flag reload_cmds need_locks \
4733    lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
4734    lt_cv_sys_global_symbol_to_c_name_address \
4735    sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
4736    old_postinstall_cmds old_postuninstall_cmds \
4737    _LT_AC_TAGVAR(compiler, $1) \
4738    _LT_AC_TAGVAR(CC, $1) \
4739    _LT_AC_TAGVAR(LD, $1) \
4740    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
4741    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
4742    _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
4743    _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
4744    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
4745    _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
4746    _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
4747    _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
4748    _LT_AC_TAGVAR(old_archive_cmds, $1) \
4749    _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
4750    _LT_AC_TAGVAR(predep_objects, $1) \
4751    _LT_AC_TAGVAR(postdep_objects, $1) \
4752    _LT_AC_TAGVAR(predeps, $1) \
4753    _LT_AC_TAGVAR(postdeps, $1) \
4754    _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
4755    _LT_AC_TAGVAR(archive_cmds, $1) \
4756    _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
4757    _LT_AC_TAGVAR(postinstall_cmds, $1) \
4758    _LT_AC_TAGVAR(postuninstall_cmds, $1) \
4759    _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
4760    _LT_AC_TAGVAR(allow_undefined_flag, $1) \
4761    _LT_AC_TAGVAR(no_undefined_flag, $1) \
4762    _LT_AC_TAGVAR(export_symbols_cmds, $1) \
4763    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
4764    _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
4765    _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
4766    _LT_AC_TAGVAR(hardcode_automatic, $1) \
4767    _LT_AC_TAGVAR(module_cmds, $1) \
4768    _LT_AC_TAGVAR(module_expsym_cmds, $1) \
4769    _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
4770    _LT_AC_TAGVAR(exclude_expsyms, $1) \
4771    _LT_AC_TAGVAR(include_expsyms, $1); do
4772
4773    case $var in
4774    _LT_AC_TAGVAR(old_archive_cmds, $1) | \
4775    _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
4776    _LT_AC_TAGVAR(archive_cmds, $1) | \
4777    _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
4778    _LT_AC_TAGVAR(module_cmds, $1) | \
4779    _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
4780    _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
4781    _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
4782    extract_expsyms_cmds | reload_cmds | finish_cmds | \
4783    postinstall_cmds | postuninstall_cmds | \
4784    old_postinstall_cmds | old_postuninstall_cmds | \
4785    sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
4786      # Double-quote double-evaled strings.
4787      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
4788      ;;
4789    *)
4790      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
4791      ;;
4792    esac
4793  done
4794
4795  case $lt_echo in
4796  *'\[$]0 --fallback-echo"')
4797    lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
4798    ;;
4799  esac
4800
4801ifelse([$1], [],
4802  [cfgfile="${ofile}T"
4803  trap "$rm \"$cfgfile\"; exit 1" 1 2 15
4804  $rm -f "$cfgfile"
4805  AC_MSG_NOTICE([creating $ofile])],
4806  [cfgfile="$ofile"])
4807
4808  cat <<__EOF__ >> "$cfgfile"
4809ifelse([$1], [],
4810[#! $SHELL
4811
4812# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
4813# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
4814# NOTE: Changes made to this file will be lost: look at ltmain.sh.
4815#
4816# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
4817# Free Software Foundation, Inc.
4818#
4819# This file is part of GNU Libtool:
4820# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
4821#
4822# This program is free software; you can redistribute it and/or modify
4823# it under the terms of the GNU General Public License as published by
4824# the Free Software Foundation; either version 2 of the License, or
4825# (at your option) any later version.
4826#
4827# This program is distributed in the hope that it will be useful, but
4828# WITHOUT ANY WARRANTY; without even the implied warranty of
4829# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
4830# General Public License for more details.
4831#
4832# You should have received a copy of the GNU General Public License
4833# along with this program; if not, write to the Free Software
4834# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
4835#
4836# As a special exception to the GNU General Public License, if you
4837# distribute this file as part of a program that contains a
4838# configuration script generated by Autoconf, you may include it under
4839# the same distribution terms that you use for the rest of that program.
4840
4841# A sed program that does not truncate output.
4842SED=$lt_SED
4843
4844# Sed that helps us avoid accidentally triggering echo(1) options like -n.
4845Xsed="$SED -e s/^X//"
4846
4847# The HP-UX ksh and POSIX shell print the target directory to stdout
4848# if CDPATH is set.
4849if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
4850
4851# The names of the tagged configurations supported by this script.
4852available_tags=
4853
4854# ### BEGIN LIBTOOL CONFIG],
4855[# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
4856
4857# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4858
4859# Shell to use when invoking shell scripts.
4860SHELL=$lt_SHELL
4861
4862# Whether or not to build shared libraries.
4863build_libtool_libs=$enable_shared
4864
4865# Whether or not to build static libraries.
4866build_old_libs=$enable_static
4867
4868# Whether or not to add -lc for building shared libraries.
4869build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
4870
4871# Whether or not to disallow shared libs when runtime libs are static
4872allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
4873
4874# Whether or not to optimize for fast installation.
4875fast_install=$enable_fast_install
4876
4877# The host system.
4878host_alias=$host_alias
4879host=$host
4880
4881# An echo program that does not interpret backslashes.
4882echo=$lt_echo
4883
4884# The archiver.
4885AR=$lt_AR
4886AR_FLAGS=$lt_AR_FLAGS
4887
4888# A C compiler.
4889LTCC=$lt_LTCC
4890
4891# A language-specific compiler.
4892CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
4893
4894# Is the compiler the GNU C compiler?
4895with_gcc=$_LT_AC_TAGVAR(GCC, $1)
4896
4897# An ERE matcher.
4898EGREP=$lt_EGREP
4899
4900# The linker used to build libraries.
4901LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
4902
4903# Whether we need hard or soft links.
4904LN_S=$lt_LN_S
4905
4906# A BSD-compatible nm program.
4907NM=$lt_NM
4908
4909# A symbol stripping program
4910STRIP=$lt_STRIP
4911
4912# Used to examine libraries when file_magic_cmd begins "file"
4913MAGIC_CMD=$MAGIC_CMD
4914
4915# Used on cygwin: DLL creation program.
4916DLLTOOL="$DLLTOOL"
4917
4918# Used on cygwin: object dumper.
4919OBJDUMP="$OBJDUMP"
4920
4921# Used on cygwin: assembler.
4922AS="$AS"
4923
4924# The name of the directory that contains temporary libtool files.
4925objdir=$objdir
4926
4927# How to create reloadable object files.
4928reload_flag=$lt_reload_flag
4929reload_cmds=$lt_reload_cmds
4930
4931# How to pass a linker flag through the compiler.
4932wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
4933
4934# Object file suffix (normally "o").
4935objext="$ac_objext"
4936
4937# Old archive suffix (normally "a").
4938libext="$libext"
4939
4940# Shared library suffix (normally ".so").
4941shrext_cmds='$shrext_cmds'
4942
4943# Executable file suffix (normally "").
4944exeext="$exeext"
4945
4946# Additional compiler flags for building library objects.
4947pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
4948pic_mode=$pic_mode
4949
4950# What is the maximum length of a command?
4951max_cmd_len=$lt_cv_sys_max_cmd_len
4952
4953# Does compiler simultaneously support -c and -o options?
4954compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
4955
4956# Must we lock files when doing compilation ?
4957need_locks=$lt_need_locks
4958
4959# Do we need the lib prefix for modules?
4960need_lib_prefix=$need_lib_prefix
4961
4962# Do we need a version for libraries?
4963need_version=$need_version
4964
4965# Whether dlopen is supported.
4966dlopen_support=$enable_dlopen
4967
4968# Whether dlopen of programs is supported.
4969dlopen_self=$enable_dlopen_self
4970
4971# Whether dlopen of statically linked programs is supported.
4972dlopen_self_static=$enable_dlopen_self_static
4973
4974# Compiler flag to prevent dynamic linking.
4975link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
4976
4977# Compiler flag to turn off builtin functions.
4978no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
4979
4980# Compiler flag to allow reflexive dlopens.
4981export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
4982
4983# Compiler flag to generate shared objects directly from archives.
4984whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
4985
4986# Compiler flag to generate thread-safe objects.
4987thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
4988
4989# Library versioning type.
4990version_type=$version_type
4991
4992# Format of library name prefix.
4993libname_spec=$lt_libname_spec
4994
4995# List of archive names.  First name is the real one, the rest are links.
4996# The last name is the one that the linker finds with -lNAME.
4997library_names_spec=$lt_library_names_spec
4998
4999# The coded name of the library, if different from the real name.
5000soname_spec=$lt_soname_spec
5001
5002# Commands used to build and install an old-style archive.
5003RANLIB=$lt_RANLIB
5004old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
5005old_postinstall_cmds=$lt_old_postinstall_cmds
5006old_postuninstall_cmds=$lt_old_postuninstall_cmds
5007
5008# Create an old-style archive from a shared archive.
5009old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
5010
5011# Create a temporary old-style archive to link instead of a shared archive.
5012old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
5013
5014# Commands used to build and install a shared archive.
5015archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
5016archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
5017postinstall_cmds=$lt_postinstall_cmds
5018postuninstall_cmds=$lt_postuninstall_cmds
5019
5020# Commands used to build a loadable module (assumed same as above if empty)
5021module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
5022module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
5023
5024# Commands to strip libraries.
5025old_striplib=$lt_old_striplib
5026striplib=$lt_striplib
5027
5028# Dependencies to place before the objects being linked to create a
5029# shared library.
5030predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
5031
5032# Dependencies to place after the objects being linked to create a
5033# shared library.
5034postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
5035
5036# Dependencies to place before the objects being linked to create a
5037# shared library.
5038predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
5039
5040# Dependencies to place after the objects being linked to create a
5041# shared library.
5042postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
5043
5044# The library search path used internally by the compiler when linking
5045# a shared library.
5046compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
5047
5048# Method to check whether dependent libraries are shared objects.
5049deplibs_check_method=$lt_deplibs_check_method
5050
5051# Command to use when deplibs_check_method == file_magic.
5052file_magic_cmd=$lt_file_magic_cmd
5053
5054# Flag that allows shared libraries with undefined symbols to be built.
5055allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
5056
5057# Flag that forces no undefined symbols.
5058no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
5059
5060# Commands used to finish a libtool library installation in a directory.
5061finish_cmds=$lt_finish_cmds
5062
5063# Same as above, but a single script fragment to be evaled but not shown.
5064finish_eval=$lt_finish_eval
5065
5066# Take the output of nm and produce a listing of raw symbols and C names.
5067global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
5068
5069# Transform the output of nm in a proper C declaration
5070global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
5071
5072# Transform the output of nm in a C name address pair
5073global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
5074
5075# This is the shared library runtime path variable.
5076runpath_var=$runpath_var
5077
5078# This is the shared library path variable.
5079shlibpath_var=$shlibpath_var
5080
5081# Is shlibpath searched before the hard-coded library search path?
5082shlibpath_overrides_runpath=$shlibpath_overrides_runpath
5083
5084# How to hardcode a shared library path into an executable.
5085hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
5086
5087# Whether we should hardcode library paths into libraries.
5088hardcode_into_libs=$hardcode_into_libs
5089
5090# Flag to hardcode \$libdir into a binary during linking.
5091# This must work even if \$libdir does not exist.
5092hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
5093
5094# If ld is used when linking, flag to hardcode \$libdir into
5095# a binary during linking. This must work even if \$libdir does
5096# not exist.
5097hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
5098
5099# Whether we need a single -rpath flag with a separated argument.
5100hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
5101
5102# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
5103# resulting binary.
5104hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
5105
5106# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
5107# resulting binary.
5108hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
5109
5110# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
5111# the resulting binary.
5112hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
5113
5114# Set to yes if building a shared library automatically hardcodes DIR into the library
5115# and all subsequent libraries and executables linked against it.
5116hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
5117
5118# Variables whose values should be saved in libtool wrapper scripts and
5119# restored at relink time.
5120variables_saved_for_relink="$variables_saved_for_relink"
5121
5122# Whether libtool must link a program against all its dependency libraries.
5123link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
5124
5125# Compile-time system search path for libraries
5126sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
5127
5128# Run-time system search path for libraries
5129sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
5130
5131# Fix the shell variable \$srcfile for the compiler.
5132fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
5133
5134# Set to yes if exported symbols are required.
5135always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
5136
5137# The commands to list exported symbols.
5138export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
5139
5140# The commands to extract the exported symbol list from a shared archive.
5141extract_expsyms_cmds=$lt_extract_expsyms_cmds
5142
5143# Symbols that should not be listed in the preloaded symbols.
5144exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
5145
5146# Symbols that must always be exported.
5147include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
5148
5149ifelse([$1],[],
5150[# ### END LIBTOOL CONFIG],
5151[# ### END LIBTOOL TAG CONFIG: $tagname])
5152
5153__EOF__
5154
5155ifelse([$1],[], [
5156  case $host_os in
5157  aix3*)
5158    cat <<\EOF >> "$cfgfile"
5159
5160# AIX sometimes has problems with the GCC collect2 program.  For some
5161# reason, if we set the COLLECT_NAMES environment variable, the problems
5162# vanish in a puff of smoke.
5163if test "X${COLLECT_NAMES+set}" != Xset; then
5164  COLLECT_NAMES=
5165  export COLLECT_NAMES
5166fi
5167EOF
5168    ;;
5169  esac
5170
5171  # We use sed instead of cat because bash on DJGPP gets confused if
5172  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
5173  # text mode, it properly converts lines to CR/LF.  This bash problem
5174  # is reportedly fixed, but why not run on old versions too?
5175  sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
5176
5177  mv -f "$cfgfile" "$ofile" || \
5178    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
5179  chmod +x "$ofile"
5180])
5181else
5182  # If there is no Makefile yet, we rely on a make rule to execute
5183  # `config.status --recheck' to rerun these tests and create the
5184  # libtool script then.
5185  ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
5186  if test -f "$ltmain_in"; then
5187    test -f Makefile && make "$ltmain"
5188  fi
5189fi
5190])# AC_LIBTOOL_CONFIG
5191
5192
5193# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
5194# -------------------------------------------
5195AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
5196[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
5197
5198_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5199
5200if test "$GCC" = yes; then
5201  _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5202
5203  AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
5204    lt_cv_prog_compiler_rtti_exceptions,
5205    [-fno-rtti -fno-exceptions], [],
5206    [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
5207fi
5208])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
5209
5210
5211# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5212# ---------------------------------
5213AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
5214[AC_REQUIRE([AC_CANONICAL_HOST])
5215AC_REQUIRE([AC_PROG_NM])
5216AC_REQUIRE([AC_OBJEXT])
5217# Check for command to grab the raw symbol name followed by C symbol from nm.
5218AC_MSG_CHECKING([command to parse $NM output from $compiler object])
5219AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
5220[
5221# These are sane defaults that work on at least a few old systems.
5222# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
5223
5224# Character class describing NM global symbol codes.
5225symcode='[[BCDEGRST]]'
5226
5227# Regexp to match symbols that can be accessed directly from C.
5228sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
5229
5230# Transform the above into a raw symbol and a C symbol.
5231symxfrm='\1 \2\3 \3'
5232
5233# Transform an extracted symbol line into a proper C declaration
5234lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
5235
5236# Transform an extracted symbol line into symbol name and symbol address
5237lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
5238
5239# Define system-specific variables.
5240case $host_os in
5241aix*)
5242  symcode='[[BCDT]]'
5243  ;;
5244cygwin* | mingw* | pw32*)
5245  symcode='[[ABCDGISTW]]'
5246  ;;
5247hpux*) # Its linker distinguishes data from code symbols
5248  if test "$host_cpu" = ia64; then
5249    symcode='[[ABCDEGRST]]'
5250  fi
5251  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5252  lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
5253  ;;
5254irix* | nonstopux*)
5255  symcode='[[BCDEGRST]]'
5256  ;;
5257osf*)
5258  symcode='[[BCDEGQRST]]'
5259  ;;
5260solaris* | sysv5*)
5261  symcode='[[BDRT]]'
5262  ;;
5263sysv4)
5264  symcode='[[DFNSTU]]'
5265  ;;
5266esac
5267
5268# Handle CRLF in mingw tool chain
5269opt_cr=
5270case $build_os in
5271mingw*)
5272  opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5273  ;;
5274esac
5275
5276# If we're using GNU nm, then use its standard symbol codes.
5277case `$NM -V 2>&1` in
5278*GNU* | *'with BFD'*)
5279  symcode='[[ABCDGIRSTW]]' ;;
5280esac
5281
5282# Try without a prefix undercore, then with it.
5283for ac_symprfx in "" "_"; do
5284
5285  # Write the raw and C identifiers.
5286  lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[      ]]\($symcode$symcode*\)[[       ]][[    ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
5287
5288  # Check to see that the pipe works correctly.
5289  pipe_works=no
5290
5291  rm -f conftest*
5292  cat > conftest.$ac_ext <<EOF
5293#ifdef __cplusplus
5294extern "C" {
5295#endif
5296char nm_test_var;
5297void nm_test_func(){}
5298#ifdef __cplusplus
5299}
5300#endif
5301int main(){nm_test_var='a';nm_test_func();return(0);}
5302EOF
5303
5304  if AC_TRY_EVAL(ac_compile); then
5305    # Now try to grab the symbols.
5306    nlist=conftest.nm
5307    if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5308      # Try sorting and uniquifying the output.
5309      if sort "$nlist" | uniq > "$nlist"T; then
5310        mv -f "$nlist"T "$nlist"
5311      else
5312        rm -f "$nlist"T
5313      fi
5314
5315      # Make sure that we snagged all the symbols we need.
5316      if grep ' nm_test_var$' "$nlist" >/dev/null; then
5317        if grep ' nm_test_func$' "$nlist" >/dev/null; then
5318          cat <<EOF > conftest.$ac_ext
5319#ifdef __cplusplus
5320extern "C" {
5321#endif
5322
5323EOF
5324          # Now generate the symbol file.
5325          eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
5326
5327          cat <<EOF >> conftest.$ac_ext
5328#if defined (__STDC__) && __STDC__
5329# define lt_ptr_t void *
5330#else
5331# define lt_ptr_t char *
5332# define const
5333#endif
5334
5335/* The mapping between symbol names and symbols. */
5336const struct {
5337  const char *name;
5338  lt_ptr_t address;
5339}
5340lt_preloaded_symbols[[]] =
5341{
5342EOF
5343          $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
5344          cat <<\EOF >> conftest.$ac_ext
5345  {0, (lt_ptr_t) 0}
5346};
5347
5348#ifdef __cplusplus
5349}
5350#endif
5351EOF
5352          # Now try linking the two files.
5353          mv conftest.$ac_objext conftstm.$ac_objext
5354          lt_save_LIBS="$LIBS"
5355          lt_save_CFLAGS="$CFLAGS"
5356          LIBS="conftstm.$ac_objext"
5357          CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5358          if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5359            pipe_works=yes
5360          fi
5361          LIBS="$lt_save_LIBS"
5362          CFLAGS="$lt_save_CFLAGS"
5363        else
5364          echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5365        fi
5366      else
5367        echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5368      fi
5369    else
5370      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5371    fi
5372  else
5373    echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5374    cat conftest.$ac_ext >&5
5375  fi
5376  rm -f conftest* conftst*
5377
5378  # Do not use the global_symbol_pipe unless it works.
5379  if test "$pipe_works" = yes; then
5380    break
5381  else
5382    lt_cv_sys_global_symbol_pipe=
5383  fi
5384done
5385])
5386if test -z "$lt_cv_sys_global_symbol_pipe"; then
5387  lt_cv_sys_global_symbol_to_cdecl=
5388fi
5389if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5390  AC_MSG_RESULT(failed)
5391else
5392  AC_MSG_RESULT(ok)
5393fi
5394]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5395
5396
5397# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
5398# ---------------------------------------
5399AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
5400[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
5401_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5402_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
5403
5404AC_MSG_CHECKING([for $compiler option to produce PIC])
5405 ifelse([$1],[CXX],[
5406  # C++ specific cases for pic, static, wl, etc.
5407  if test "$GXX" = yes; then
5408    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5409    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5410
5411    case $host_os in
5412    aix*)
5413      # All AIX code is PIC.
5414      if test "$host_cpu" = ia64; then
5415        # AIX 5 now supports IA64 processor
5416        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5417      fi
5418      ;;
5419    amigaos*)
5420      # FIXME: we need at least 68020 code to build shared libraries, but
5421      # adding the `-m68020' flag to GCC prevents building anything better,
5422      # like `-m68040'.
5423      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5424      ;;
5425    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5426      # PIC is the default for these OSes.
5427      ;;
5428    mingw* | os2* | pw32*)
5429      # This hack is so that the source file can tell whether it is being
5430      # built for inclusion in a dll (and should export symbols for example).
5431      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5432      ;;
5433    darwin* | rhapsody*)
5434      # PIC is the default on this platform
5435      # Common symbols not allowed in MH_DYLIB files
5436      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5437      ;;
5438    *djgpp*)
5439      # DJGPP does not support shared libraries at all
5440      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5441      ;;
5442    sysv4*MP*)
5443      if test -d /usr/nec; then
5444        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5445      fi
5446      ;;
5447    hpux*)
5448      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5449      # not for PA HP-UX.
5450      case "$host_cpu" in
5451      hppa*64*|ia64*)
5452        ;;
5453      *)
5454        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5455        ;;
5456      esac
5457      ;;
5458    *)
5459      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5460      ;;
5461    esac
5462  else
5463    case $host_os in
5464      aix4* | aix5*)
5465        # All AIX code is PIC.
5466        if test "$host_cpu" = ia64; then
5467          # AIX 5 now supports IA64 processor
5468          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5469        else
5470          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5471        fi
5472        ;;
5473      chorus*)
5474        case $cc_basename in
5475        cxch68)
5476          # Green Hills C++ Compiler
5477          # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
5478          ;;
5479        esac
5480        ;;
5481      dgux*)
5482        case $cc_basename in
5483          ec++)
5484            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5485            ;;
5486          ghcx)
5487            # Green Hills C++ Compiler
5488            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5489            ;;
5490          *)
5491            ;;
5492        esac
5493        ;;
5494      freebsd* | kfreebsd*-gnu)
5495        # FreeBSD uses GNU C++
5496        ;;
5497      hpux9* | hpux10* | hpux11*)
5498        case $cc_basename in
5499          CC)
5500            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5501            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
5502            if test "$host_cpu" != ia64; then
5503              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5504            fi
5505            ;;
5506          aCC)
5507            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5508            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
5509            case "$host_cpu" in
5510            hppa*64*|ia64*)
5511              # +Z the default
5512              ;;
5513            *)
5514              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5515              ;;
5516            esac
5517            ;;
5518          *)
5519            ;;
5520        esac
5521        ;;
5522      irix5* | irix6* | nonstopux*)
5523        case $cc_basename in
5524          CC)
5525            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5526            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5527            # CC pic flag -KPIC is the default.
5528            ;;
5529          *)
5530            ;;
5531        esac
5532        ;;
5533      linux*)
5534        case $cc_basename in
5535          KCC)
5536            # KAI C++ Compiler
5537            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5538            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5539            ;;
5540          icpc)
5541            # Intel C++
5542            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5543            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5544            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5545            ;;
5546          cxx)
5547            # Compaq C++
5548            # Make sure the PIC flag is empty.  It appears that all Alpha
5549            # Linux and Compaq Tru64 Unix objects are PIC.
5550            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5551            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5552            ;;
5553          *)
5554            ;;
5555        esac
5556        ;;
5557      lynxos*)
5558        ;;
5559      m88k*)
5560        ;;
5561      mvs*)
5562        case $cc_basename in
5563          cxx)
5564            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5565            ;;
5566          *)
5567            ;;
5568        esac
5569        ;;
5570      netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
5571        ;;
5572      osf3* | osf4* | osf5*)
5573        case $cc_basename in
5574          KCC)
5575            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5576            ;;
5577          RCC)
5578            # Rational C++ 2.4.1
5579            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5580            ;;
5581          cxx)
5582            # Digital/Compaq C++
5583            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5584            # Make sure the PIC flag is empty.  It appears that all Alpha
5585            # Linux and Compaq Tru64 Unix objects are PIC.
5586            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5587            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5588            ;;
5589          *)
5590            ;;
5591        esac
5592        ;;
5593      psos*)
5594        ;;
5595      sco*)
5596        case $cc_basename in
5597          CC)
5598            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5599            ;;
5600          *)
5601            ;;
5602        esac
5603        ;;
5604      solaris*)
5605        case $cc_basename in
5606          CC)
5607            # Sun C++ 4.2, 5.x and Centerline C++
5608            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5609            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5610            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5611            ;;
5612          gcx)
5613            # Green Hills C++ Compiler
5614            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5615            ;;
5616          *)
5617            ;;
5618        esac
5619        ;;
5620      sunos4*)
5621        case $cc_basename in
5622          CC)
5623            # Sun C++ 4.x
5624            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5625            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5626            ;;
5627          lcc)
5628            # Lucid
5629            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5630            ;;
5631          *)
5632            ;;
5633        esac
5634        ;;
5635      tandem*)
5636        case $cc_basename in
5637          NCC)
5638            # NonStop-UX NCC 3.20
5639            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5640            ;;
5641          *)
5642            ;;
5643        esac
5644        ;;
5645      unixware*)
5646        ;;
5647      vxworks*)
5648        ;;
5649      *)
5650        _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5651        ;;
5652    esac
5653  fi
5654],
5655[
5656  if test "$GCC" = yes; then
5657    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5658    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5659
5660    case $host_os in
5661      aix*)
5662      # All AIX code is PIC.
5663      if test "$host_cpu" = ia64; then
5664        # AIX 5 now supports IA64 processor
5665        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5666      fi
5667      ;;
5668
5669    amigaos*)
5670      # FIXME: we need at least 68020 code to build shared libraries, but
5671      # adding the `-m68020' flag to GCC prevents building anything better,
5672      # like `-m68040'.
5673      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5674      ;;
5675
5676    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5677      # PIC is the default for these OSes.
5678      ;;
5679
5680    mingw* | pw32* | os2*)
5681      # This hack is so that the source file can tell whether it is being
5682      # built for inclusion in a dll (and should export symbols for example).
5683      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5684      ;;
5685
5686    darwin* | rhapsody*)
5687      # PIC is the default on this platform
5688      # Common symbols not allowed in MH_DYLIB files
5689      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5690      ;;
5691
5692    msdosdjgpp*)
5693      # Just because we use GCC doesn't mean we suddenly get shared libraries
5694      # on systems that don't support them.
5695      _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5696      enable_shared=no
5697      ;;
5698
5699    sysv4*MP*)
5700      if test -d /usr/nec; then
5701        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5702      fi
5703      ;;
5704
5705    hpux*)
5706      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5707      # not for PA HP-UX.
5708      case "$host_cpu" in
5709      hppa*64*|ia64*)
5710        # +Z the default
5711        ;;
5712      *)
5713        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5714        ;;
5715      esac
5716      ;;
5717
5718    *)
5719      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5720      ;;
5721    esac
5722  else
5723    # PORTME Check for flag to pass linker flags through the system compiler.
5724    case $host_os in
5725    aix*)
5726      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5727      if test "$host_cpu" = ia64; then
5728        # AIX 5 now supports IA64 processor
5729        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5730      else
5731        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5732      fi
5733      ;;
5734
5735    mingw* | pw32* | os2*)
5736      # This hack is so that the source file can tell whether it is being
5737      # built for inclusion in a dll (and should export symbols for example).
5738      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5739      ;;
5740
5741    hpux9* | hpux10* | hpux11*)
5742      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5743      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5744      # not for PA HP-UX.
5745      case "$host_cpu" in
5746      hppa*64*|ia64*)
5747        # +Z the default
5748        ;;
5749      *)
5750        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5751        ;;
5752      esac
5753      # Is there a better lt_prog_compiler_static that works with the bundled CC?
5754      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5755      ;;
5756
5757    irix5* | irix6* | nonstopux*)
5758      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5759      # PIC (with -KPIC) is the default.
5760      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5761      ;;
5762
5763    newsos6)
5764      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5765      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5766      ;;
5767
5768    linux*)
5769      case $CC in
5770      icc* | ecc*)
5771        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5772        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5773        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5774        ;;
5775      ccc*)
5776        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5777        # All Alpha code is PIC.
5778        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5779        ;;
5780      esac
5781      ;;
5782
5783    osf3* | osf4* | osf5*)
5784      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5785      # All OSF/1 code is PIC.
5786      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5787      ;;
5788
5789    sco3.2v5*)
5790      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
5791      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
5792      ;;
5793
5794    solaris*)
5795      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5796      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5797      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5798      ;;
5799
5800    sunos4*)
5801      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5802      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5803      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5804      ;;
5805
5806    sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5807      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5808      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5809      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5810      ;;
5811
5812    sysv4*MP*)
5813      if test -d /usr/nec ;then
5814        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5815        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5816      fi
5817      ;;
5818
5819    uts4*)
5820      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5821      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5822      ;;
5823
5824    *)
5825      _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5826      ;;
5827    esac
5828  fi
5829])
5830AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
5831
5832#
5833# Check to make sure the PIC flag actually works.
5834#
5835if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
5836  AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
5837    _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
5838    [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
5839    [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
5840     "" | " "*) ;;
5841     *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5842     esac],
5843    [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5844     _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5845fi
5846case "$host_os" in
5847  # For platforms which do not support PIC, -DPIC is meaningless:
5848  *djgpp*)
5849    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5850    ;;
5851  *)
5852    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
5853    ;;
5854esac
5855])
5856
5857
5858# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
5859# ------------------------------------
5860# See if the linker supports building shared libraries.
5861AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
5862[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5863ifelse([$1],[CXX],[
5864  _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5865  case $host_os in
5866  aix4* | aix5*)
5867    # If we're using GNU nm, then we don't want the "-C" option.
5868    # -C means demangle to AIX nm, but means don't demangle with GNU nm
5869    if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5870      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
5871    else
5872      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
5873    fi
5874    ;;
5875  pw32*)
5876    _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5877  ;;
5878  cygwin* | mingw*)
5879    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
5880  ;;
5881  linux*)
5882    _LT_AC_TAGVAR(link_all_deplibs, $1)=no
5883  ;;
5884  *)
5885    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5886  ;;
5887  esac
5888],[
5889  runpath_var=
5890  _LT_AC_TAGVAR(allow_undefined_flag, $1)=
5891  _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5892  _LT_AC_TAGVAR(archive_cmds, $1)=
5893  _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
5894  _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
5895  _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5896  _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5897  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5898  _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
5899  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5900  _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5901  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5902  _LT_AC_TAGVAR(hardcode_direct, $1)=no
5903  _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
5904  _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5905  _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
5906  _LT_AC_TAGVAR(hardcode_automatic, $1)=no
5907  _LT_AC_TAGVAR(module_cmds, $1)=
5908  _LT_AC_TAGVAR(module_expsym_cmds, $1)=
5909  _LT_AC_TAGVAR(always_export_symbols, $1)=no
5910  _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5911  # include_expsyms should be a list of space-separated symbols to be *always*
5912  # included in the symbol list
5913  _LT_AC_TAGVAR(include_expsyms, $1)=
5914  # exclude_expsyms can be an extended regexp of symbols to exclude
5915  # it will be wrapped by ` (' and `)$', so one must not match beginning or
5916  # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5917  # as well as any symbol that contains `d'.
5918  _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
5919  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5920  # platforms (ab)use it in PIC code, but their linkers get confused if
5921  # the symbol is explicitly referenced.  Since portable code cannot
5922  # rely on this symbol name, it's probably fine to never include it in
5923  # preloaded symbol tables.
5924  extract_expsyms_cmds=
5925
5926  case $host_os in
5927  cygwin* | mingw* | pw32*)
5928    # FIXME: the MSVC++ port hasn't been tested in a loooong time
5929    # When not using gcc, we currently assume that we are using
5930    # Microsoft Visual C++.
5931    if test "$GCC" != yes; then
5932      with_gnu_ld=no
5933    fi
5934    ;;
5935  openbsd*)
5936    with_gnu_ld=no
5937    ;;
5938  esac
5939
5940  _LT_AC_TAGVAR(ld_shlibs, $1)=yes
5941  if test "$with_gnu_ld" = yes; then
5942    # If archive_cmds runs LD, not CC, wlarc should be empty
5943    wlarc='${wl}'
5944
5945    # See if GNU ld supports shared libraries.
5946    case $host_os in
5947    aix3* | aix4* | aix5*)
5948      # On AIX/PPC, the GNU linker is very broken
5949      if test "$host_cpu" != ia64; then
5950        _LT_AC_TAGVAR(ld_shlibs, $1)=no
5951        cat <<EOF 1>&2
5952
5953*** Warning: the GNU linker, at least up to release 2.9.1, is reported
5954*** to be unable to reliably create shared libraries on AIX.
5955*** Therefore, libtool is disabling shared libraries support.  If you
5956*** really care for shared libraries, you may want to modify your PATH
5957*** so that a non-GNU linker is found, and then restart.
5958
5959EOF
5960      fi
5961      ;;
5962
5963    amigaos*)
5964      _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
5965      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5966      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5967
5968      # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
5969      # that the semantics of dynamic libraries on AmigaOS, at least up
5970      # to version 4, is to share data among multiple programs linked
5971      # with the same dynamic library.  Since this doesn't match the
5972      # behavior of shared libraries on other platforms, we can't use
5973      # them.
5974      _LT_AC_TAGVAR(ld_shlibs, $1)=no
5975      ;;
5976
5977    beos*)
5978      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5979        _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5980        # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5981        # support --undefined.  This deserves some investigation.  FIXME
5982        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5983      else
5984        _LT_AC_TAGVAR(ld_shlibs, $1)=no
5985      fi
5986      ;;
5987
5988    cygwin* | mingw* | pw32*)
5989      # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5990      # as there is no search path for DLLs.
5991      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5992      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5993      _LT_AC_TAGVAR(always_export_symbols, $1)=no
5994      _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5995      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
5996
5997      if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
5998        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
5999        # If the export-symbols file already is a .def file (1st line
6000        # is EXPORTS), use it as is; otherwise, prepend...
6001        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6002          cp $export_symbols $output_objdir/$soname.def;
6003        else
6004          echo EXPORTS > $output_objdir/$soname.def;
6005          cat $export_symbols >> $output_objdir/$soname.def;
6006        fi~
6007        $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
6008      else
6009        ld_shlibs=no
6010      fi
6011      ;;
6012
6013    netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
6014      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6015        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6016        wlarc=
6017      else
6018        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6019        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6020      fi
6021      ;;
6022
6023    solaris* | sysv5*)
6024      if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
6025        _LT_AC_TAGVAR(ld_shlibs, $1)=no
6026        cat <<EOF 1>&2
6027
6028*** Warning: The releases 2.8.* of the GNU linker cannot reliably
6029*** create shared libraries on Solaris systems.  Therefore, libtool
6030*** is disabling shared libraries support.  We urge you to upgrade GNU
6031*** binutils to release 2.9.1 or newer.  Another option is to modify
6032*** your PATH or compiler configuration so that the native linker is
6033*** used, and then restart.
6034
6035EOF
6036      elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6037        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6038        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6039      else
6040        _LT_AC_TAGVAR(ld_shlibs, $1)=no
6041      fi
6042      ;;
6043
6044    sunos4*)
6045      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6046      wlarc=
6047      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6048      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6049      ;;
6050
6051  linux*)
6052    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6053        tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6054        _LT_AC_TAGVAR(archive_cmds, $1)="$tmp_archive_cmds"
6055      supports_anon_versioning=no
6056      case `$LD -v 2>/dev/null` in
6057        *\ [01].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6058        *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6059        *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6060        *\ 2.11.*) ;; # other 2.11 versions
6061        *) supports_anon_versioning=yes ;;
6062      esac
6063      if test $supports_anon_versioning = yes; then
6064        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
6065cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6066$echo "local: *; };" >> $output_objdir/$libname.ver~
6067        $CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6068      else
6069        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="$tmp_archive_cmds"
6070      fi
6071      _LT_AC_TAGVAR(link_all_deplibs, $1)=no
6072    else
6073      _LT_AC_TAGVAR(ld_shlibs, $1)=no
6074    fi
6075    ;;
6076
6077    *)
6078      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6079        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6080        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6081      else
6082        _LT_AC_TAGVAR(ld_shlibs, $1)=no
6083      fi
6084      ;;
6085    esac
6086
6087    if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = yes; then
6088      runpath_var=LD_RUN_PATH
6089      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6090      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6091      # ancient GNU ld didn't support --whole-archive et. al.
6092      if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
6093        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6094      else
6095        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6096      fi
6097    fi
6098  else
6099    # PORTME fill in a description of your system's linker (not GNU ld)
6100    case $host_os in
6101    aix3*)
6102      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6103      _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6104      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
6105      # Note: this linker hardcodes the directories in LIBPATH if there
6106      # are no directories specified by -L.
6107      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6108      if test "$GCC" = yes && test -z "$link_static_flag"; then
6109        # Neither direct hardcoding nor static linking is supported with a
6110        # broken collect2.
6111        _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6112      fi
6113      ;;
6114
6115    aix4* | aix5*)
6116      if test "$host_cpu" = ia64; then
6117        # On IA64, the linker does run time linking by default, so we don't
6118        # have to do anything special.
6119        aix_use_runtimelinking=no
6120        exp_sym_flag='-Bexport'
6121        no_entry_flag=""
6122      else
6123        # If we're using GNU nm, then we don't want the "-C" option.
6124        # -C means demangle to AIX nm, but means don't demangle with GNU nm
6125        if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6126          _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6127        else
6128          _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6129        fi
6130        aix_use_runtimelinking=no
6131
6132        # Test if we are trying to use run time linking or normal
6133        # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6134        # need to do runtime linking.
6135        case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
6136          for ld_flag in $LDFLAGS; do
6137          if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6138            aix_use_runtimelinking=yes
6139            break
6140          fi
6141          done
6142        esac
6143
6144        exp_sym_flag='-bexport'
6145        no_entry_flag='-bnoentry'
6146      fi
6147
6148      # When large executables or shared objects are built, AIX ld can
6149      # have problems creating the table of contents.  If linking a library
6150      # or program results in "error TOC overflow" add -mminimal-toc to
6151      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
6152      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6153
6154      _LT_AC_TAGVAR(archive_cmds, $1)=''
6155      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6156      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6157      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6158
6159      if test "$GCC" = yes; then
6160        case $host_os in aix4.[012]|aix4.[012].*)
6161        # We only want to do this on AIX 4.2 and lower, the check
6162        # below for broken collect2 doesn't work under 4.3+
6163          collect2name=`${CC} -print-prog-name=collect2`
6164          if test -f "$collect2name" && \
6165           strings "$collect2name" | grep resolve_lib_name >/dev/null
6166          then
6167          # We have reworked collect2
6168          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6169          else
6170          # We have old collect2
6171          _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6172          # It fails to find uninstalled libraries when the uninstalled
6173          # path is not listed in the libpath.  Setting hardcode_minus_L
6174          # to unsupported forces relinking
6175          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6176          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6177          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6178          fi
6179        esac
6180        shared_flag='-shared'
6181      else
6182        # not using gcc
6183        if test "$host_cpu" = ia64; then
6184        # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6185        # chokes on -Wl,-G. The following line is correct:
6186          shared_flag='-G'
6187        else
6188        if test "$aix_use_runtimelinking" = yes; then
6189            shared_flag='${wl}-G'
6190          else
6191            shared_flag='${wl}-bM:SRE'
6192        fi
6193        fi
6194      fi
6195
6196      # It seems that -bexpall does not export symbols beginning with
6197      # underscore (_), so it is better to generate a list of symbols to export.
6198      _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6199      if test "$aix_use_runtimelinking" = yes; then
6200        # Warning - without using the other runtime loading flags (-brtl),
6201        # -berok will link without error, but may produce a broken library.
6202        _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
6203       # Determine the default libpath from the value encoded in an empty executable.
6204       _LT_AC_SYS_LIBPATH_AIX
6205       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6206        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6207       else
6208        if test "$host_cpu" = ia64; then
6209          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6210          _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6211          _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
6212        else
6213         # Determine the default libpath from the value encoded in an empty executable.
6214         _LT_AC_SYS_LIBPATH_AIX
6215         _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6216          # Warning - without using the other run time loading flags,
6217          # -berok will link without error, but may produce a broken library.
6218          _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6219          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6220          # -bexpall does not export symbols beginning with underscore (_)
6221          _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6222          # Exported symbols can be pulled into shared objects from archives
6223          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
6224          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6225          # This is similar to how AIX traditionally builds it's shared libraries.
6226          _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6227        fi
6228      fi
6229      ;;
6230
6231    amigaos*)
6232      _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
6233      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6234      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6235      # see comment about different semantics on the GNU ld section
6236      _LT_AC_TAGVAR(ld_shlibs, $1)=no
6237      ;;
6238
6239    bsdi4*)
6240      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6241      ;;
6242
6243    cygwin* | mingw* | pw32*)
6244      # When not using gcc, we currently assume that we are using
6245      # Microsoft Visual C++.
6246      # hardcode_libdir_flag_spec is actually meaningless, as there is
6247      # no search path for DLLs.
6248      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6249      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6250      # Tell ltmain to make .lib files, not .a files.
6251      libext=lib
6252      # Tell ltmain to make .dll files, not .so files.
6253      shrext_cmds=".dll"
6254      # FIXME: Setting linknames here is a bad hack.
6255      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
6256      # The linker will automatically build a .lib file if we build a DLL.
6257      _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
6258      # FIXME: Should let the user specify the lib program.
6259      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
6260      fix_srcfile_path='`cygpath -w "$srcfile"`'
6261      _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6262      ;;
6263
6264    darwin* | rhapsody*)
6265    if test "$GXX" = yes ; then
6266      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6267      case "$host_os" in
6268      rhapsody* | darwin1.[[012]])
6269        _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
6270        ;;
6271      *) # Darwin 1.3 on
6272      if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
6273        _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
6274      else
6275        case ${MACOSX_DEPLOYMENT_TARGET} in
6276          10.[[012]])
6277            _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
6278            ;;
6279          10.*)
6280            _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup'
6281            ;;
6282        esac
6283      fi
6284        ;;
6285      esac
6286        lt_int_apple_cc_single_mod=no
6287        output_verbose_link_cmd='echo'
6288        if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
6289          lt_int_apple_cc_single_mod=yes
6290        fi
6291        if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
6292          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
6293        else
6294        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
6295      fi
6296      _LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6297      # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
6298        if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
6299          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6300        else
6301          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6302        fi
6303          _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6304      _LT_AC_TAGVAR(hardcode_direct, $1)=no
6305      _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
6306      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6307      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
6308      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6309    else
6310      _LT_AC_TAGVAR(ld_shlibs, $1)=no
6311    fi
6312      ;;
6313
6314    dgux*)
6315      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6316      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6317      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6318      ;;
6319
6320    freebsd1*)
6321      _LT_AC_TAGVAR(ld_shlibs, $1)=no
6322      ;;
6323
6324    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6325    # support.  Future versions do this automatically, but an explicit c++rt0.o
6326    # does not break anything, and helps significantly (at the cost of a little
6327    # extra space).
6328    freebsd2.2*)
6329      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6330      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6331      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6332      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6333      ;;
6334
6335    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6336    freebsd2*)
6337      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6338      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6339      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6340      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6341      ;;
6342
6343    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6344    freebsd* | kfreebsd*-gnu)
6345      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
6346      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6347      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6348      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6349      ;;
6350
6351    hpux9*)
6352      if test "$GCC" = yes; then
6353        _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6354      else
6355        _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6356      fi
6357      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6358      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6359      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6360
6361      # hardcode_minus_L: Not really in the search PATH,
6362      # but as the default location of the library.
6363      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6364      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6365      ;;
6366
6367    hpux10* | hpux11*)
6368      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6369        case "$host_cpu" in
6370        hppa*64*|ia64*)
6371          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6372          ;;
6373        *)
6374          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6375          ;;
6376        esac
6377      else
6378        case "$host_cpu" in
6379        hppa*64*|ia64*)
6380          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
6381          ;;
6382        *)
6383          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6384          ;;
6385        esac
6386      fi
6387      if test "$with_gnu_ld" = no; then
6388        case "$host_cpu" in
6389        hppa*64*)
6390          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6391          _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
6392          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6393          _LT_AC_TAGVAR(hardcode_direct, $1)=no
6394          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6395          ;;
6396        ia64*)
6397          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6398          _LT_AC_TAGVAR(hardcode_direct, $1)=no
6399          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6400
6401          # hardcode_minus_L: Not really in the search PATH,
6402          # but as the default location of the library.
6403          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6404          ;;
6405        *)
6406          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6407          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6408          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6409          _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6410
6411          # hardcode_minus_L: Not really in the search PATH,
6412          # but as the default location of the library.
6413          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6414          ;;
6415        esac
6416      fi
6417      ;;
6418
6419    irix5* | irix6* | nonstopux*)
6420      if test "$GCC" = yes; then
6421        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6422      else
6423        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6424        _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6425      fi
6426      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6427      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6428      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6429      ;;
6430
6431    netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
6432      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6433        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
6434      else
6435        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
6436      fi
6437      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6438      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6439      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6440      ;;
6441
6442    newsos6)
6443      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6444      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6445      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6446      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6447      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6448      ;;
6449
6450    openbsd*)
6451      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6452      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6453      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6454        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6455        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6456        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6457      else
6458       case $host_os in
6459         openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6460           _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6461           _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6462           ;;
6463         *)
6464           _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6465           _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6466           ;;
6467       esac
6468      fi
6469      ;;
6470
6471    os2*)
6472      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6473      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6474      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6475      _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
6476      _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6477      ;;
6478
6479    osf3*)
6480      if test "$GCC" = yes; then
6481        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6482        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6483      else
6484        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6485        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6486      fi
6487      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6488      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6489      ;;
6490
6491    osf4* | osf5*)      # as osf3* with the addition of -msym flag
6492      if test "$GCC" = yes; then
6493        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6494        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6495        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6496      else
6497        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6498        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6499        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
6500        $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
6501
6502        # Both c and cxx compiler support -rpath directly
6503        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6504      fi
6505      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6506      ;;
6507
6508    sco3.2v5*)
6509      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6510      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6511      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6512      runpath_var=LD_RUN_PATH
6513      hardcode_runpath_var=yes
6514      ;;
6515
6516    solaris*)
6517      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6518      if test "$GCC" = yes; then
6519        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6520        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6521          $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
6522      else
6523        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6524        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6525        $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6526      fi
6527      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6528      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6529      case $host_os in
6530      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6531      *) # Supported since Solaris 2.6 (maybe 2.5.1?)
6532        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
6533      esac
6534      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6535      ;;
6536
6537    sunos4*)
6538      if test "x$host_vendor" = xsequent; then
6539        # Use $CC to link under sequent, because it throws in some extra .o
6540        # files that make .init and .fini sections work.
6541        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6542      else
6543        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6544      fi
6545      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6546      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6547      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6548      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6549      ;;
6550
6551    sysv4)
6552      case $host_vendor in
6553        sni)
6554          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6555          _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6556        ;;
6557        siemens)
6558          ## LD is ld it makes a PLAMLIB
6559          ## CC just makes a GrossModule.
6560          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6561          _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6562          _LT_AC_TAGVAR(hardcode_direct, $1)=no
6563        ;;
6564        motorola)
6565          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6566          _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6567        ;;
6568      esac
6569      runpath_var='LD_RUN_PATH'
6570      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6571      ;;
6572
6573    sysv4.3*)
6574      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6575      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6576      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6577      ;;
6578
6579    sysv4*MP*)
6580      if test -d /usr/nec; then
6581        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6582        _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6583        runpath_var=LD_RUN_PATH
6584        hardcode_runpath_var=yes
6585        _LT_AC_TAGVAR(ld_shlibs, $1)=yes
6586      fi
6587      ;;
6588
6589    sysv4.2uw2*)
6590      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6591      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6592      _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6593      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6594      hardcode_runpath_var=yes
6595      runpath_var=LD_RUN_PATH
6596      ;;
6597
6598   sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[[78]]* | unixware7*)
6599      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
6600      if test "$GCC" = yes; then
6601        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6602      else
6603        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6604      fi
6605      runpath_var='LD_RUN_PATH'
6606      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6607      ;;
6608
6609    sysv5*)
6610      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6611      # $CC -shared without GNU ld will not create a library from C++
6612      # object files and a static libstdc++, better avoid it by now
6613      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6614      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6615                $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6616      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6617      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6618      runpath_var='LD_RUN_PATH'
6619      ;;
6620
6621    uts4*)
6622      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6623      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6624      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6625      ;;
6626
6627    *)
6628      _LT_AC_TAGVAR(ld_shlibs, $1)=no
6629      ;;
6630    esac
6631  fi
6632])
6633AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
6634test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6635
6636variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
6637if test "$GCC" = yes; then
6638  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
6639fi
6640
6641#
6642# Do we need to explicitly link libc?
6643#
6644case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
6645x|xyes)
6646  # Assume -lc should be added
6647  _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6648
6649  if test "$enable_shared" = yes && test "$GCC" = yes; then
6650    case $_LT_AC_TAGVAR(archive_cmds, $1) in
6651    *'~'*)
6652      # FIXME: we may have to deal with multi-command sequences.
6653      ;;
6654    '$CC '*)
6655      # Test whether the compiler implicitly links with -lc since on some
6656      # systems, -lgcc has to come before -lc. If gcc already passes -lc
6657      # to ld, don't add -lc before -lgcc.
6658      AC_MSG_CHECKING([whether -lc should be explicitly linked in])
6659      $rm conftest*
6660      printf "$lt_simple_compile_test_code" > conftest.$ac_ext
6661
6662      if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6663        soname=conftest
6664        lib=conftest
6665        libobjs=conftest.$ac_objext
6666        deplibs=
6667        wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
6668        compiler_flags=-v
6669        linker_flags=-v
6670        verstring=
6671        output_objdir=.
6672        libname=conftest
6673        lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
6674        _LT_AC_TAGVAR(allow_undefined_flag, $1)=
6675        if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
6676        then
6677          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6678        else
6679          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6680        fi
6681        _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6682      else
6683        cat conftest.err 1>&5
6684      fi
6685      $rm conftest*
6686      AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
6687      ;;
6688    esac
6689  fi
6690  ;;
6691esac
6692])# AC_LIBTOOL_PROG_LD_SHLIBS
6693
6694
6695# _LT_AC_FILE_LTDLL_C
6696# -------------------
6697# Be careful that the start marker always follows a newline.
6698AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
6699# /* ltdll.c starts here */
6700# #define WIN32_LEAN_AND_MEAN
6701# #include <windows.h>
6702# #undef WIN32_LEAN_AND_MEAN
6703# #include <stdio.h>
6704#
6705# #ifndef __CYGWIN__
6706# #  ifdef __CYGWIN32__
6707# #    define __CYGWIN__ __CYGWIN32__
6708# #  endif
6709# #endif
6710#
6711# #ifdef __cplusplus
6712# extern "C" {
6713# #endif
6714# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
6715# #ifdef __cplusplus
6716# }
6717# #endif
6718#
6719# #ifdef __CYGWIN__
6720# #include <cygwin/cygwin_dll.h>
6721# DECLARE_CYGWIN_DLL( DllMain );
6722# #endif
6723# HINSTANCE __hDllInstance_base;
6724#
6725# BOOL APIENTRY
6726# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
6727# {
6728#   __hDllInstance_base = hInst;
6729#   return TRUE;
6730# }
6731# /* ltdll.c ends here */
6732])# _LT_AC_FILE_LTDLL_C
6733
6734
6735# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
6736# ---------------------------------
6737AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
6738
6739
6740# old names
6741AC_DEFUN([AM_PROG_LIBTOOL],   [AC_PROG_LIBTOOL])
6742AC_DEFUN([AM_ENABLE_SHARED],  [AC_ENABLE_SHARED($@)])
6743AC_DEFUN([AM_ENABLE_STATIC],  [AC_ENABLE_STATIC($@)])
6744AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
6745AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
6746AC_DEFUN([AM_PROG_LD],        [AC_PROG_LD])
6747AC_DEFUN([AM_PROG_NM],        [AC_PROG_NM])
6748
6749# This is just to silence aclocal about the macro not being used
6750ifelse([AC_DISABLE_FAST_INSTALL])
6751
6752AC_DEFUN([LT_AC_PROG_GCJ],
6753[AC_CHECK_TOOL(GCJ, gcj, no)
6754  test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
6755  AC_SUBST(GCJFLAGS)
6756])
6757
6758AC_DEFUN([LT_AC_PROG_RC],
6759[AC_CHECK_TOOL(RC, windres, no)
6760])
6761
6762# NOTE: This macro has been submitted for inclusion into   #
6763#  GNU Autoconf as AC_PROG_SED.  When it is available in   #
6764#  a released version of Autoconf we should remove this    #
6765#  macro and use it instead.                               #
6766# LT_AC_PROG_SED
6767# --------------
6768# Check for a fully-functional sed program, that truncates
6769# as few characters as possible.  Prefer GNU sed if found.
6770AC_DEFUN([LT_AC_PROG_SED],
6771[AC_MSG_CHECKING([for a sed that does not truncate output])
6772AC_CACHE_VAL(lt_cv_path_SED,
6773[# Loop through the user's path and test for sed and gsed.
6774# Then use that list of sed's as ones to test for truncation.
6775as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6776for as_dir in $PATH
6777do
6778  IFS=$as_save_IFS
6779  test -z "$as_dir" && as_dir=.
6780  for lt_ac_prog in sed gsed; do
6781    for ac_exec_ext in '' $ac_executable_extensions; do
6782      if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
6783        lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
6784      fi
6785    done
6786  done
6787done
6788lt_ac_max=0
6789lt_ac_count=0
6790# Add /usr/xpg4/bin/sed as it is typically found on Solaris
6791# along with /bin/sed that truncates output.
6792for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
6793  test ! -f $lt_ac_sed && break
6794  cat /dev/null > conftest.in
6795  lt_ac_count=0
6796  echo $ECHO_N "0123456789$ECHO_C" >conftest.in
6797  # Check for GNU sed and select it if it is found.
6798  if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
6799    lt_cv_path_SED=$lt_ac_sed
6800    break
6801  fi
6802  while true; do
6803    cat conftest.in conftest.in >conftest.tmp
6804    mv conftest.tmp conftest.in
6805    cp conftest.in conftest.nl
6806    echo >>conftest.nl
6807    $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
6808    cmp -s conftest.out conftest.nl || break
6809    # 10000 chars as input seems more than enough
6810    test $lt_ac_count -gt 10 && break
6811    lt_ac_count=`expr $lt_ac_count + 1`
6812    if test $lt_ac_count -gt $lt_ac_max; then
6813      lt_ac_max=$lt_ac_count
6814      lt_cv_path_SED=$lt_ac_sed
6815    fi
6816  done
6817done
6818SED=$lt_cv_path_SED
6819])
6820AC_MSG_RESULT([$SED])
6821])
6822
6823
6824dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not)
6825dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page
6826dnl also defines GSTUFF_PKG_ERRORS on error
6827AC_DEFUN(PKG_CHECK_MODULES, [
6828  succeeded=no
6829
6830  if test -z "$PKG_CONFIG"; then
6831    AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
6832  fi
6833
6834  if test "$PKG_CONFIG" = "no" ; then
6835     echo "*** The pkg-config script could not be found. Make sure it is"
6836     echo "*** in your path, or set the PKG_CONFIG environment variable"
6837     echo "*** to the full path to pkg-config."
6838     echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
6839  else
6840     PKG_CONFIG_MIN_VERSION=0.9.0
6841     if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
6842        AC_MSG_CHECKING(for $2)
6843
6844        if $PKG_CONFIG --exists "$2" ; then
6845            AC_MSG_RESULT(yes)
6846            succeeded=yes
6847
6848            AC_MSG_CHECKING($1_CFLAGS)
6849            $1_CFLAGS=`$PKG_CONFIG --cflags "$2"`
6850            AC_MSG_RESULT($$1_CFLAGS)
6851
6852            AC_MSG_CHECKING($1_LIBS)
6853            $1_LIBS=`$PKG_CONFIG --libs "$2"`
6854            AC_MSG_RESULT($$1_LIBS)
6855        else
6856            $1_CFLAGS=""
6857            $1_LIBS=""
6858            ## If we have a custom action on failure, don't print errors, but
6859            ## do set a variable so people can do so.
6860            $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
6861            ifelse([$4], ,echo $$1_PKG_ERRORS,)
6862        fi
6863
6864        AC_SUBST($1_CFLAGS)
6865        AC_SUBST($1_LIBS)
6866     else
6867        echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
6868        echo "*** See http://www.freedesktop.org/software/pkgconfig"
6869     fi
6870  fi
6871
6872  if test $succeeded = yes; then
6873     ifelse([$3], , :, [$3])
6874  else
6875     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])
6876  fi
6877])
6878
6879
6880
6881dnl GNOME_COMPILE_WARNINGS
6882dnl Turn on many useful compiler warnings
6883dnl For now, only works on GCC
6884AC_DEFUN([GNOME_COMPILE_WARNINGS],[
6885    dnl ******************************
6886    dnl More compiler warnings
6887    dnl ******************************
6888
6889    AC_ARG_ENABLE(compile-warnings,
6890                  AC_HELP_STRING([--enable-compile-warnings=@<:@no/minimum/yes/maximum/error@:>@],
6891                                 [Turn on compiler warnings]),,
6892                  [enable_compile_warnings="m4_default([$1],[yes])"])
6893
6894    warnCFLAGS=
6895    if test "x$GCC" != xyes; then
6896        enable_compile_warnings=no
6897    fi
6898
6899    warning_flags=
6900    realsave_CFLAGS="$CFLAGS"
6901
6902    case "$enable_compile_warnings" in
6903    no)
6904        warning_flags=
6905        ;;
6906    minimum)
6907        warning_flags="-Wall"
6908        ;;
6909    yes)
6910        warning_flags="-Wall -Wmissing-prototypes"
6911        ;;
6912    maximum|error)
6913        warning_flags="-Wall -Wmissing-prototypes -Wnested-externs -Wpointer-arith"
6914        CFLAGS="$warning_flags $CFLAGS"
6915        for option in -Wno-sign-compare; do
6916                SAVE_CFLAGS="$CFLAGS"
6917                CFLAGS="$CFLAGS $option"
6918                AC_MSG_CHECKING([whether gcc understands $option])
6919                AC_TRY_COMPILE([], [],
6920                        has_option=yes,
6921                        has_option=no,)
6922                CFLAGS="$SAVE_CFLAGS"
6923                AC_MSG_RESULT($has_option)
6924                if test $has_option = yes; then
6925                  warning_flags="$warning_flags $option"
6926                fi
6927                unset has_option
6928                unset SAVE_CFLAGS
6929        done
6930        unset option
6931        if test "$enable_compile_warnings" = "error" ; then
6932            warning_flags="$warning_flags -Werror"
6933        fi
6934        ;;
6935    *)
6936        AC_MSG_ERROR(Unknown argument '$enable_compile_warnings' to --enable-compile-warnings)
6937        ;;
6938    esac
6939    CFLAGS="$realsave_CFLAGS"
6940    AC_MSG_CHECKING(what warning flags to pass to the C compiler)
6941    AC_MSG_RESULT($warning_flags)
6942
6943    AC_ARG_ENABLE(iso-c,
6944                  AC_HELP_STRING([--enable-iso-c],
6945                                 [Try to warn if code is not ISO C ]),,
6946                  [enable_iso_c=no])
6947
6948    AC_MSG_CHECKING(what language compliance flags to pass to the C compiler)
6949    complCFLAGS=
6950    if test "x$enable_iso_c" != "xno"; then
6951        if test "x$GCC" = "xyes"; then
6952        case " $CFLAGS " in
6953            *[\ \       ]-ansi[\ \      ]*) ;;
6954            *) complCFLAGS="$complCFLAGS -ansi" ;;
6955        esac
6956        case " $CFLAGS " in
6957            *[\ \       ]-pedantic[\ \  ]*) ;;
6958            *) complCFLAGS="$complCFLAGS -pedantic" ;;
6959        esac
6960        fi
6961    fi
6962    AC_MSG_RESULT($complCFLAGS)
6963
6964    WARN_CFLAGS="$warning_flags $complCFLAGS"
6965    AC_SUBST(WARN_CFLAGS)
6966])
6967
6968dnl For C++, do basically the same thing.
6969
6970AC_DEFUN([GNOME_CXX_WARNINGS],[
6971  AC_ARG_ENABLE(cxx-warnings,
6972                AC_HELP_STRING([--enable-cxx-warnings=@<:@no/minimum/yes@:>@]
6973                               [Turn on compiler warnings.]),,
6974                [enable_cxx_warnings="m4_default([$1],[minimum])"])
6975
6976  AC_MSG_CHECKING(what warning flags to pass to the C++ compiler)
6977  warnCXXFLAGS=
6978  if test "x$GCC" != xyes; then
6979    enable_compile_warnings=no
6980  fi
6981  if test "x$enable_cxx_warnings" != "xno"; then
6982    if test "x$GCC" = "xyes"; then
6983      case " $CXXFLAGS " in
6984      *[\ \     ]-Wall[\ \      ]*) ;;
6985      *) warnCXXFLAGS="-Wall -Wno-unused" ;;
6986      esac
6987
6988      ## -W is not all that useful.  And it cannot be controlled
6989      ## with individual -Wno-xxx flags, unlike -Wall
6990      if test "x$enable_cxx_warnings" = "xyes"; then
6991        warnCXXFLAGS="$warnCXXFLAGS -Wshadow -Woverloaded-virtual"
6992      fi
6993    fi
6994  fi
6995  AC_MSG_RESULT($warnCXXFLAGS)
6996
6997   AC_ARG_ENABLE(iso-cxx,
6998                 AC_HELP_STRING([--enable-iso-cxx],
6999                                [Try to warn if code is not ISO C++ ]),,
7000                 [enable_iso_cxx=no])
7001
7002   AC_MSG_CHECKING(what language compliance flags to pass to the C++ compiler)
7003   complCXXFLAGS=
7004   if test "x$enable_iso_cxx" != "xno"; then
7005     if test "x$GCC" = "xyes"; then
7006      case " $CXXFLAGS " in
7007      *[\ \     ]-ansi[\ \      ]*) ;;
7008      *) complCXXFLAGS="$complCXXFLAGS -ansi" ;;
7009      esac
7010
7011      case " $CXXFLAGS " in
7012      *[\ \     ]-pedantic[\ \  ]*) ;;
7013      *) complCXXFLAGS="$complCXXFLAGS -pedantic" ;;
7014      esac
7015     fi
7016   fi
7017  AC_MSG_RESULT($complCXXFLAGS)
7018
7019  WARN_CXXFLAGS="$CXXFLAGS $warnCXXFLAGS $complCXXFLAGS"
7020  AC_SUBST(WARN_CXXFLAGS)
7021])
7022
7023dnl -*- mode: autoconf -*-
7024
7025# serial 1
7026
7027dnl Usage:
7028dnl   GTK_DOC_CHECK([minimum-gtk-doc-version])
7029AC_DEFUN([GTK_DOC_CHECK],
7030[
7031  AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
7032  AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
7033  dnl for overriding the documentation installation directory
7034  AC_ARG_WITH(html-dir,
7035    AC_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
7036    [with_html_dir='${datadir}/gtk-doc/html'])
7037  HTML_DIR="$with_html_dir"
7038  AC_SUBST(HTML_DIR)
7039
7040  dnl enable/disable documentation building
7041  AC_ARG_ENABLE(gtk-doc,
7042    AC_HELP_STRING([--enable-gtk-doc],
7043                   [use gtk-doc to build documentation [default=no]]),,
7044    enable_gtk_doc=no)
7045
7046  have_gtk_doc=no
7047  if test x$enable_gtk_doc = xyes; then
7048    if test -z "$PKG_CONFIG"; then
7049      AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
7050    fi
7051    if test "$PKG_CONFIG" != "no" && $PKG_CONFIG --exists gtk-doc; then
7052      have_gtk_doc=yes
7053    fi
7054
7055  dnl do we want to do a version check?
7056ifelse([$1],[],,
7057    [gtk_doc_min_version=$1
7058    if test "$have_gtk_doc" = yes; then
7059      AC_MSG_CHECKING([gtk-doc version >= $gtk_doc_min_version])
7060      if $PKG_CONFIG --atleast-version $gtk_doc_min_version gtk-doc; then
7061        AC_MSG_RESULT(yes)
7062      else
7063        AC_MSG_RESULT(no)
7064        have_gtk_doc=no
7065      fi
7066    fi
7067])
7068    if test "$have_gtk_doc" != yes; then
7069      enable_gtk_doc=no
7070    fi
7071  fi
7072
7073  AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes)
7074  AM_CONDITIONAL(GTK_DOC_USE_LIBTOOL, test -n "$LIBTOOL")
7075])
7076
Note: See TracBrowser for help on using the repository browser.