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