source: trunk/third/startup-notification/aclocal.m4 @ 21546

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