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