[Title] update spec file for glib-networking_2.32.3
[external/glib-networking.git] / aclocal.m4
1 # generated automatically by aclocal 1.11.3 -*- Autoconf -*-
2
3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
4 # 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation,
5 # Inc.
6 # This file is free software; the Free Software Foundation
7 # gives unlimited permission to copy and/or distribute it,
8 # with or without modifications, as long as this notice is preserved.
9
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
12 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
13 # PARTICULAR PURPOSE.
14
15 m4_ifndef([AC_AUTOCONF_VERSION],
16   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
17 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],,
18 [m4_warning([this file was generated for autoconf 2.68.
19 You have another version of autoconf.  It may work, but is not guaranteed to.
20 If you have problems, you may need to regenerate the build system entirely.
21 To do so, use the procedure documented by the package, typically `autoreconf'.])])
22
23 # Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008, 2011 Free Software
24 # Foundation, Inc.
25 #
26 # This file is free software; the Free Software Foundation
27 # gives unlimited permission to copy and/or distribute it,
28 # with or without modifications, as long as this notice is preserved.
29
30 # serial 1
31
32 # AM_AUTOMAKE_VERSION(VERSION)
33 # ----------------------------
34 # Automake X.Y traces this macro to ensure aclocal.m4 has been
35 # generated from the m4 files accompanying Automake X.Y.
36 # (This private macro should not be called outside this file.)
37 AC_DEFUN([AM_AUTOMAKE_VERSION],
38 [am__api_version='1.11'
39 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
40 dnl require some minimum version.  Point them to the right macro.
41 m4_if([$1], [1.11.3], [],
42       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
43 ])
44
45 # _AM_AUTOCONF_VERSION(VERSION)
46 # -----------------------------
47 # aclocal traces this macro to find the Autoconf version.
48 # This is a private macro too.  Using m4_define simplifies
49 # the logic in aclocal, which can simply ignore this definition.
50 m4_define([_AM_AUTOCONF_VERSION], [])
51
52 # AM_SET_CURRENT_AUTOMAKE_VERSION
53 # -------------------------------
54 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
55 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
56 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
57 [AM_AUTOMAKE_VERSION([1.11.3])dnl
58 m4_ifndef([AC_AUTOCONF_VERSION],
59   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
60 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
61
62 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
63
64 # Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
65 #
66 # This file is free software; the Free Software Foundation
67 # gives unlimited permission to copy and/or distribute it,
68 # with or without modifications, as long as this notice is preserved.
69
70 # serial 1
71
72 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
73 # $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
74 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
75 #
76 # Of course, Automake must honor this variable whenever it calls a
77 # tool from the auxiliary directory.  The problem is that $srcdir (and
78 # therefore $ac_aux_dir as well) can be either absolute or relative,
79 # depending on how configure is run.  This is pretty annoying, since
80 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
81 # source directory, any form will work fine, but in subdirectories a
82 # relative path needs to be adjusted first.
83 #
84 # $ac_aux_dir/missing
85 #    fails when called from a subdirectory if $ac_aux_dir is relative
86 # $top_srcdir/$ac_aux_dir/missing
87 #    fails if $ac_aux_dir is absolute,
88 #    fails when called from a subdirectory in a VPATH build with
89 #          a relative $ac_aux_dir
90 #
91 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
92 # are both prefixed by $srcdir.  In an in-source build this is usually
93 # harmless because $srcdir is `.', but things will broke when you
94 # start a VPATH build or use an absolute $srcdir.
95 #
96 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
97 # iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
98 #   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
99 # and then we would define $MISSING as
100 #   MISSING="\${SHELL} $am_aux_dir/missing"
101 # This will work as long as MISSING is not called from configure, because
102 # unfortunately $(top_srcdir) has no meaning in configure.
103 # However there are other variables, like CC, which are often used in
104 # configure, and could therefore not use this "fixed" $ac_aux_dir.
105 #
106 # Another solution, used here, is to always expand $ac_aux_dir to an
107 # absolute PATH.  The drawback is that using absolute paths prevent a
108 # configured tree to be moved without reconfiguration.
109
110 AC_DEFUN([AM_AUX_DIR_EXPAND],
111 [dnl Rely on autoconf to set up CDPATH properly.
112 AC_PREREQ([2.50])dnl
113 # expand $ac_aux_dir to an absolute path
114 am_aux_dir=`cd $ac_aux_dir && pwd`
115 ])
116
117 # AM_CONDITIONAL                                            -*- Autoconf -*-
118
119 # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
120 # Free Software Foundation, Inc.
121 #
122 # This file is free software; the Free Software Foundation
123 # gives unlimited permission to copy and/or distribute it,
124 # with or without modifications, as long as this notice is preserved.
125
126 # serial 9
127
128 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
129 # -------------------------------------
130 # Define a conditional.
131 AC_DEFUN([AM_CONDITIONAL],
132 [AC_PREREQ(2.52)dnl
133  ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
134         [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
135 AC_SUBST([$1_TRUE])dnl
136 AC_SUBST([$1_FALSE])dnl
137 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
138 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
139 m4_define([_AM_COND_VALUE_$1], [$2])dnl
140 if $2; then
141   $1_TRUE=
142   $1_FALSE='#'
143 else
144   $1_TRUE='#'
145   $1_FALSE=
146 fi
147 AC_CONFIG_COMMANDS_PRE(
148 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
149   AC_MSG_ERROR([[conditional "$1" was never defined.
150 Usually this means the macro was only invoked conditionally.]])
151 fi])])
152
153 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009,
154 # 2010, 2011 Free Software Foundation, Inc.
155 #
156 # This file is free software; the Free Software Foundation
157 # gives unlimited permission to copy and/or distribute it,
158 # with or without modifications, as long as this notice is preserved.
159
160 # serial 12
161
162 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
163 # written in clear, in which case automake, when reading aclocal.m4,
164 # will think it sees a *use*, and therefore will trigger all it's
165 # C support machinery.  Also note that it means that autoscan, seeing
166 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
167
168
169 # _AM_DEPENDENCIES(NAME)
170 # ----------------------
171 # See how the compiler implements dependency checking.
172 # NAME is "CC", "CXX", "GCJ", or "OBJC".
173 # We try a few techniques and use that to set a single cache variable.
174 #
175 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
176 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
177 # dependency, and given that the user is not expected to run this macro,
178 # just rely on AC_PROG_CC.
179 AC_DEFUN([_AM_DEPENDENCIES],
180 [AC_REQUIRE([AM_SET_DEPDIR])dnl
181 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
182 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
183 AC_REQUIRE([AM_DEP_TRACK])dnl
184
185 ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
186        [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
187        [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
188        [$1], UPC,  [depcc="$UPC"  am_compiler_list=],
189        [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
190                    [depcc="$$1"   am_compiler_list=])
191
192 AC_CACHE_CHECK([dependency style of $depcc],
193                [am_cv_$1_dependencies_compiler_type],
194 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
195   # We make a subdir and do the tests there.  Otherwise we can end up
196   # making bogus files that we don't know about and never remove.  For
197   # instance it was reported that on HP-UX the gcc test will end up
198   # making a dummy file named `D' -- because `-MD' means `put the output
199   # in D'.
200   rm -rf conftest.dir
201   mkdir conftest.dir
202   # Copy depcomp to subdir because otherwise we won't find it if we're
203   # using a relative directory.
204   cp "$am_depcomp" conftest.dir
205   cd conftest.dir
206   # We will build objects and dependencies in a subdirectory because
207   # it helps to detect inapplicable dependency modes.  For instance
208   # both Tru64's cc and ICC support -MD to output dependencies as a
209   # side effect of compilation, but ICC will put the dependencies in
210   # the current directory while Tru64 will put them in the object
211   # directory.
212   mkdir sub
213
214   am_cv_$1_dependencies_compiler_type=none
215   if test "$am_compiler_list" = ""; then
216      am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
217   fi
218   am__universal=false
219   m4_case([$1], [CC],
220     [case " $depcc " in #(
221      *\ -arch\ *\ -arch\ *) am__universal=true ;;
222      esac],
223     [CXX],
224     [case " $depcc " in #(
225      *\ -arch\ *\ -arch\ *) am__universal=true ;;
226      esac])
227
228   for depmode in $am_compiler_list; do
229     # Setup a source with many dependencies, because some compilers
230     # like to wrap large dependency lists on column 80 (with \), and
231     # we should not choose a depcomp mode which is confused by this.
232     #
233     # We need to recreate these files for each test, as the compiler may
234     # overwrite some of them when testing with obscure command lines.
235     # This happens at least with the AIX C compiler.
236     : > sub/conftest.c
237     for i in 1 2 3 4 5 6; do
238       echo '#include "conftst'$i'.h"' >> sub/conftest.c
239       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
240       # Solaris 8's {/usr,}/bin/sh.
241       touch sub/conftst$i.h
242     done
243     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
244
245     # We check with `-c' and `-o' for the sake of the "dashmstdout"
246     # mode.  It turns out that the SunPro C++ compiler does not properly
247     # handle `-M -o', and we need to detect this.  Also, some Intel
248     # versions had trouble with output in subdirs
249     am__obj=sub/conftest.${OBJEXT-o}
250     am__minus_obj="-o $am__obj"
251     case $depmode in
252     gcc)
253       # This depmode causes a compiler race in universal mode.
254       test "$am__universal" = false || continue
255       ;;
256     nosideeffect)
257       # after this tag, mechanisms are not by side-effect, so they'll
258       # only be used when explicitly requested
259       if test "x$enable_dependency_tracking" = xyes; then
260         continue
261       else
262         break
263       fi
264       ;;
265     msvc7 | msvc7msys | msvisualcpp | msvcmsys)
266       # This compiler won't grok `-c -o', but also, the minuso test has
267       # not run yet.  These depmodes are late enough in the game, and
268       # so weak that their functioning should not be impacted.
269       am__obj=conftest.${OBJEXT-o}
270       am__minus_obj=
271       ;;
272     none) break ;;
273     esac
274     if depmode=$depmode \
275        source=sub/conftest.c object=$am__obj \
276        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
277        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
278          >/dev/null 2>conftest.err &&
279        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
280        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
281        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
282        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
283       # icc doesn't choke on unknown options, it will just issue warnings
284       # or remarks (even with -Werror).  So we grep stderr for any message
285       # that says an option was ignored or not supported.
286       # When given -MP, icc 7.0 and 7.1 complain thusly:
287       #   icc: Command line warning: ignoring option '-M'; no argument required
288       # The diagnosis changed in icc 8.0:
289       #   icc: Command line remark: option '-MP' not supported
290       if (grep 'ignoring option' conftest.err ||
291           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
292         am_cv_$1_dependencies_compiler_type=$depmode
293         break
294       fi
295     fi
296   done
297
298   cd ..
299   rm -rf conftest.dir
300 else
301   am_cv_$1_dependencies_compiler_type=none
302 fi
303 ])
304 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
305 AM_CONDITIONAL([am__fastdep$1], [
306   test "x$enable_dependency_tracking" != xno \
307   && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
308 ])
309
310
311 # AM_SET_DEPDIR
312 # -------------
313 # Choose a directory name for dependency files.
314 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
315 AC_DEFUN([AM_SET_DEPDIR],
316 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
317 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
318 ])
319
320
321 # AM_DEP_TRACK
322 # ------------
323 AC_DEFUN([AM_DEP_TRACK],
324 [AC_ARG_ENABLE(dependency-tracking,
325 [  --disable-dependency-tracking  speeds up one-time build
326   --enable-dependency-tracking   do not reject slow dependency extractors])
327 if test "x$enable_dependency_tracking" != xno; then
328   am_depcomp="$ac_aux_dir/depcomp"
329   AMDEPBACKSLASH='\'
330   am__nodep='_no'
331 fi
332 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
333 AC_SUBST([AMDEPBACKSLASH])dnl
334 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
335 AC_SUBST([am__nodep])dnl
336 _AM_SUBST_NOTMAKE([am__nodep])dnl
337 ])
338
339 # Generate code to set up dependency tracking.              -*- Autoconf -*-
340
341 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
342 # Free Software Foundation, Inc.
343 #
344 # This file is free software; the Free Software Foundation
345 # gives unlimited permission to copy and/or distribute it,
346 # with or without modifications, as long as this notice is preserved.
347
348 #serial 5
349
350 # _AM_OUTPUT_DEPENDENCY_COMMANDS
351 # ------------------------------
352 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
353 [{
354   # Autoconf 2.62 quotes --file arguments for eval, but not when files
355   # are listed without --file.  Let's play safe and only enable the eval
356   # if we detect the quoting.
357   case $CONFIG_FILES in
358   *\'*) eval set x "$CONFIG_FILES" ;;
359   *)   set x $CONFIG_FILES ;;
360   esac
361   shift
362   for mf
363   do
364     # Strip MF so we end up with the name of the file.
365     mf=`echo "$mf" | sed -e 's/:.*$//'`
366     # Check whether this is an Automake generated Makefile or not.
367     # We used to match only the files named `Makefile.in', but
368     # some people rename them; so instead we look at the file content.
369     # Grep'ing the first line is not enough: some people post-process
370     # each Makefile.in and add a new line on top of each file to say so.
371     # Grep'ing the whole file is not good either: AIX grep has a line
372     # limit of 2048, but all sed's we know have understand at least 4000.
373     if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
374       dirpart=`AS_DIRNAME("$mf")`
375     else
376       continue
377     fi
378     # Extract the definition of DEPDIR, am__include, and am__quote
379     # from the Makefile without running `make'.
380     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
381     test -z "$DEPDIR" && continue
382     am__include=`sed -n 's/^am__include = //p' < "$mf"`
383     test -z "am__include" && continue
384     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
385     # When using ansi2knr, U may be empty or an underscore; expand it
386     U=`sed -n 's/^U = //p' < "$mf"`
387     # Find all dependency output files, they are included files with
388     # $(DEPDIR) in their names.  We invoke sed twice because it is the
389     # simplest approach to changing $(DEPDIR) to its actual value in the
390     # expansion.
391     for file in `sed -n "
392       s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
393          sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
394       # Make sure the directory exists.
395       test -f "$dirpart/$file" && continue
396       fdir=`AS_DIRNAME(["$file"])`
397       AS_MKDIR_P([$dirpart/$fdir])
398       # echo "creating $dirpart/$file"
399       echo '# dummy' > "$dirpart/$file"
400     done
401   done
402 }
403 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
404
405
406 # AM_OUTPUT_DEPENDENCY_COMMANDS
407 # -----------------------------
408 # This macro should only be invoked once -- use via AC_REQUIRE.
409 #
410 # This code is only required when automatic dependency tracking
411 # is enabled.  FIXME.  This creates each `.P' file that we will
412 # need in order to bootstrap the dependency handling code.
413 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
414 [AC_CONFIG_COMMANDS([depfiles],
415      [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
416      [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
417 ])
418
419 # Do all the work for Automake.                             -*- Autoconf -*-
420
421 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
422 # 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
423 #
424 # This file is free software; the Free Software Foundation
425 # gives unlimited permission to copy and/or distribute it,
426 # with or without modifications, as long as this notice is preserved.
427
428 # serial 16
429
430 # This macro actually does too much.  Some checks are only needed if
431 # your package does certain things.  But this isn't really a big deal.
432
433 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
434 # AM_INIT_AUTOMAKE([OPTIONS])
435 # -----------------------------------------------
436 # The call with PACKAGE and VERSION arguments is the old style
437 # call (pre autoconf-2.50), which is being phased out.  PACKAGE
438 # and VERSION should now be passed to AC_INIT and removed from
439 # the call to AM_INIT_AUTOMAKE.
440 # We support both call styles for the transition.  After
441 # the next Automake release, Autoconf can make the AC_INIT
442 # arguments mandatory, and then we can depend on a new Autoconf
443 # release and drop the old call support.
444 AC_DEFUN([AM_INIT_AUTOMAKE],
445 [AC_PREREQ([2.62])dnl
446 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
447 dnl the ones we care about.
448 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
449 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
450 AC_REQUIRE([AC_PROG_INSTALL])dnl
451 if test "`cd $srcdir && pwd`" != "`pwd`"; then
452   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
453   # is not polluted with repeated "-I."
454   AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
455   # test to see if srcdir already configured
456   if test -f $srcdir/config.status; then
457     AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
458   fi
459 fi
460
461 # test whether we have cygpath
462 if test -z "$CYGPATH_W"; then
463   if (cygpath --version) >/dev/null 2>/dev/null; then
464     CYGPATH_W='cygpath -w'
465   else
466     CYGPATH_W=echo
467   fi
468 fi
469 AC_SUBST([CYGPATH_W])
470
471 # Define the identity of the package.
472 dnl Distinguish between old-style and new-style calls.
473 m4_ifval([$2],
474 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
475  AC_SUBST([PACKAGE], [$1])dnl
476  AC_SUBST([VERSION], [$2])],
477 [_AM_SET_OPTIONS([$1])dnl
478 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
479 m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
480   [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
481  AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
482  AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
483
484 _AM_IF_OPTION([no-define],,
485 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
486  AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
487
488 # Some tools Automake needs.
489 AC_REQUIRE([AM_SANITY_CHECK])dnl
490 AC_REQUIRE([AC_ARG_PROGRAM])dnl
491 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
492 AM_MISSING_PROG(AUTOCONF, autoconf)
493 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
494 AM_MISSING_PROG(AUTOHEADER, autoheader)
495 AM_MISSING_PROG(MAKEINFO, makeinfo)
496 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
497 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
498 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
499 # We need awk for the "check" target.  The system "awk" is bad on
500 # some platforms.
501 AC_REQUIRE([AC_PROG_AWK])dnl
502 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
503 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
504 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
505               [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
506                              [_AM_PROG_TAR([v7])])])
507 _AM_IF_OPTION([no-dependencies],,
508 [AC_PROVIDE_IFELSE([AC_PROG_CC],
509                   [_AM_DEPENDENCIES(CC)],
510                   [define([AC_PROG_CC],
511                           defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
512 AC_PROVIDE_IFELSE([AC_PROG_CXX],
513                   [_AM_DEPENDENCIES(CXX)],
514                   [define([AC_PROG_CXX],
515                           defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
516 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
517                   [_AM_DEPENDENCIES(OBJC)],
518                   [define([AC_PROG_OBJC],
519                           defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
520 ])
521 _AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
522 dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
523 dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
524 dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
525 AC_CONFIG_COMMANDS_PRE(dnl
526 [m4_provide_if([_AM_COMPILER_EXEEXT],
527   [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
528 ])
529
530 dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
531 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
532 dnl mangled by Autoconf and run in a shell conditional statement.
533 m4_define([_AC_COMPILER_EXEEXT],
534 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
535
536
537 # When config.status generates a header, we must update the stamp-h file.
538 # This file resides in the same directory as the config header
539 # that is generated.  The stamp files are numbered to have different names.
540
541 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
542 # loop where config.status creates the headers, so we can generate
543 # our stamp files there.
544 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
545 [# Compute $1's index in $config_headers.
546 _am_arg=$1
547 _am_stamp_count=1
548 for _am_header in $config_headers :; do
549   case $_am_header in
550     $_am_arg | $_am_arg:* )
551       break ;;
552     * )
553       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
554   esac
555 done
556 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
557
558 # Copyright (C) 2001, 2003, 2005, 2008, 2011 Free Software Foundation,
559 # Inc.
560 #
561 # This file is free software; the Free Software Foundation
562 # gives unlimited permission to copy and/or distribute it,
563 # with or without modifications, as long as this notice is preserved.
564
565 # serial 1
566
567 # AM_PROG_INSTALL_SH
568 # ------------------
569 # Define $install_sh.
570 AC_DEFUN([AM_PROG_INSTALL_SH],
571 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
572 if test x"${install_sh}" != xset; then
573   case $am_aux_dir in
574   *\ * | *\     *)
575     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
576   *)
577     install_sh="\${SHELL} $am_aux_dir/install-sh"
578   esac
579 fi
580 AC_SUBST(install_sh)])
581
582 # Copyright (C) 2003, 2005  Free Software Foundation, Inc.
583 #
584 # This file is free software; the Free Software Foundation
585 # gives unlimited permission to copy and/or distribute it,
586 # with or without modifications, as long as this notice is preserved.
587
588 # serial 2
589
590 # Check whether the underlying file-system supports filenames
591 # with a leading dot.  For instance MS-DOS doesn't.
592 AC_DEFUN([AM_SET_LEADING_DOT],
593 [rm -rf .tst 2>/dev/null
594 mkdir .tst 2>/dev/null
595 if test -d .tst; then
596   am__leading_dot=.
597 else
598   am__leading_dot=_
599 fi
600 rmdir .tst 2>/dev/null
601 AC_SUBST([am__leading_dot])])
602
603 # Add --enable-maintainer-mode option to configure.         -*- Autoconf -*-
604 # From Jim Meyering
605
606 # Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008,
607 # 2011 Free Software Foundation, Inc.
608 #
609 # This file is free software; the Free Software Foundation
610 # gives unlimited permission to copy and/or distribute it,
611 # with or without modifications, as long as this notice is preserved.
612
613 # serial 5
614
615 # AM_MAINTAINER_MODE([DEFAULT-MODE])
616 # ----------------------------------
617 # Control maintainer-specific portions of Makefiles.
618 # Default is to disable them, unless `enable' is passed literally.
619 # For symmetry, `disable' may be passed as well.  Anyway, the user
620 # can override the default with the --enable/--disable switch.
621 AC_DEFUN([AM_MAINTAINER_MODE],
622 [m4_case(m4_default([$1], [disable]),
623        [enable], [m4_define([am_maintainer_other], [disable])],
624        [disable], [m4_define([am_maintainer_other], [enable])],
625        [m4_define([am_maintainer_other], [enable])
626         m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
627 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
628   dnl maintainer-mode's default is 'disable' unless 'enable' is passed
629   AC_ARG_ENABLE([maintainer-mode],
630 [  --][am_maintainer_other][-maintainer-mode  am_maintainer_other make rules and dependencies not useful
631                           (and sometimes confusing) to the casual installer],
632       [USE_MAINTAINER_MODE=$enableval],
633       [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
634   AC_MSG_RESULT([$USE_MAINTAINER_MODE])
635   AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
636   MAINT=$MAINTAINER_MODE_TRUE
637   AC_SUBST([MAINT])dnl
638 ]
639 )
640
641 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
642
643 # Check to see how 'make' treats includes.                  -*- Autoconf -*-
644
645 # Copyright (C) 2001, 2002, 2003, 2005, 2009  Free Software Foundation, Inc.
646 #
647 # This file is free software; the Free Software Foundation
648 # gives unlimited permission to copy and/or distribute it,
649 # with or without modifications, as long as this notice is preserved.
650
651 # serial 4
652
653 # AM_MAKE_INCLUDE()
654 # -----------------
655 # Check to see how make treats includes.
656 AC_DEFUN([AM_MAKE_INCLUDE],
657 [am_make=${MAKE-make}
658 cat > confinc << 'END'
659 am__doit:
660         @echo this is the am__doit target
661 .PHONY: am__doit
662 END
663 # If we don't find an include directive, just comment out the code.
664 AC_MSG_CHECKING([for style of include used by $am_make])
665 am__include="#"
666 am__quote=
667 _am_result=none
668 # First try GNU make style include.
669 echo "include confinc" > confmf
670 # Ignore all kinds of additional output from `make'.
671 case `$am_make -s -f confmf 2> /dev/null` in #(
672 *the\ am__doit\ target*)
673   am__include=include
674   am__quote=
675   _am_result=GNU
676   ;;
677 esac
678 # Now try BSD make style include.
679 if test "$am__include" = "#"; then
680    echo '.include "confinc"' > confmf
681    case `$am_make -s -f confmf 2> /dev/null` in #(
682    *the\ am__doit\ target*)
683      am__include=.include
684      am__quote="\""
685      _am_result=BSD
686      ;;
687    esac
688 fi
689 AC_SUBST([am__include])
690 AC_SUBST([am__quote])
691 AC_MSG_RESULT([$_am_result])
692 rm -f confinc confmf
693 ])
694
695 # Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2008
696 # Free Software Foundation, Inc.
697 #
698 # This file is free software; the Free Software Foundation
699 # gives unlimited permission to copy and/or distribute it,
700 # with or without modifications, as long as this notice is preserved.
701
702 # serial 6
703
704 # AM_PROG_CC_C_O
705 # --------------
706 # Like AC_PROG_CC_C_O, but changed for automake.
707 AC_DEFUN([AM_PROG_CC_C_O],
708 [AC_REQUIRE([AC_PROG_CC_C_O])dnl
709 AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
710 AC_REQUIRE_AUX_FILE([compile])dnl
711 # FIXME: we rely on the cache variable name because
712 # there is no other way.
713 set dummy $CC
714 am_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']`
715 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
716 if test "$am_t" != yes; then
717    # Losing compiler, so override with the script.
718    # FIXME: It is wrong to rewrite CC.
719    # But if we don't then we get into trouble of one sort or another.
720    # A longer-term fix would be to have automake use am__CC in this case,
721    # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
722    CC="$am_aux_dir/compile $CC"
723 fi
724 dnl Make sure AC_PROG_CC is never called again, or it will override our
725 dnl setting of CC.
726 m4_define([AC_PROG_CC],
727           [m4_fatal([AC_PROG_CC cannot be called after AM_PROG_CC_C_O])])
728 ])
729
730 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
731
732 # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
733 # Free Software Foundation, Inc.
734 #
735 # This file is free software; the Free Software Foundation
736 # gives unlimited permission to copy and/or distribute it,
737 # with or without modifications, as long as this notice is preserved.
738
739 # serial 6
740
741 # AM_MISSING_PROG(NAME, PROGRAM)
742 # ------------------------------
743 AC_DEFUN([AM_MISSING_PROG],
744 [AC_REQUIRE([AM_MISSING_HAS_RUN])
745 $1=${$1-"${am_missing_run}$2"}
746 AC_SUBST($1)])
747
748
749 # AM_MISSING_HAS_RUN
750 # ------------------
751 # Define MISSING if not defined so far and test if it supports --run.
752 # If it does, set am_missing_run to use it, otherwise, to nothing.
753 AC_DEFUN([AM_MISSING_HAS_RUN],
754 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
755 AC_REQUIRE_AUX_FILE([missing])dnl
756 if test x"${MISSING+set}" != xset; then
757   case $am_aux_dir in
758   *\ * | *\     *)
759     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
760   *)
761     MISSING="\${SHELL} $am_aux_dir/missing" ;;
762   esac
763 fi
764 # Use eval to expand $SHELL
765 if eval "$MISSING --run true"; then
766   am_missing_run="$MISSING --run "
767 else
768   am_missing_run=
769   AC_MSG_WARN([`missing' script is too old or missing])
770 fi
771 ])
772
773 # Copyright (C) 2003, 2004, 2005, 2006, 2011 Free Software Foundation,
774 # Inc.
775 #
776 # This file is free software; the Free Software Foundation
777 # gives unlimited permission to copy and/or distribute it,
778 # with or without modifications, as long as this notice is preserved.
779
780 # serial 1
781
782 # AM_PROG_MKDIR_P
783 # ---------------
784 # Check for `mkdir -p'.
785 AC_DEFUN([AM_PROG_MKDIR_P],
786 [AC_PREREQ([2.60])dnl
787 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
788 dnl Automake 1.8 to 1.9.6 used to define mkdir_p.  We now use MKDIR_P,
789 dnl while keeping a definition of mkdir_p for backward compatibility.
790 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
791 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
792 dnl Makefile.ins that do not define MKDIR_P, so we do our own
793 dnl adjustment using top_builddir (which is defined more often than
794 dnl MKDIR_P).
795 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
796 case $mkdir_p in
797   [[\\/$]]* | ?:[[\\/]]*) ;;
798   */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
799 esac
800 ])
801
802 # Helper functions for option handling.                     -*- Autoconf -*-
803
804 # Copyright (C) 2001, 2002, 2003, 2005, 2008, 2010 Free Software
805 # Foundation, Inc.
806 #
807 # This file is free software; the Free Software Foundation
808 # gives unlimited permission to copy and/or distribute it,
809 # with or without modifications, as long as this notice is preserved.
810
811 # serial 5
812
813 # _AM_MANGLE_OPTION(NAME)
814 # -----------------------
815 AC_DEFUN([_AM_MANGLE_OPTION],
816 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
817
818 # _AM_SET_OPTION(NAME)
819 # --------------------
820 # Set option NAME.  Presently that only means defining a flag for this option.
821 AC_DEFUN([_AM_SET_OPTION],
822 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
823
824 # _AM_SET_OPTIONS(OPTIONS)
825 # ------------------------
826 # OPTIONS is a space-separated list of Automake options.
827 AC_DEFUN([_AM_SET_OPTIONS],
828 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
829
830 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
831 # -------------------------------------------
832 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
833 AC_DEFUN([_AM_IF_OPTION],
834 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
835
836 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
837
838 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
839 # Free Software Foundation, Inc.
840 #
841 # This file is free software; the Free Software Foundation
842 # gives unlimited permission to copy and/or distribute it,
843 # with or without modifications, as long as this notice is preserved.
844
845 # serial 5
846
847 # AM_SANITY_CHECK
848 # ---------------
849 AC_DEFUN([AM_SANITY_CHECK],
850 [AC_MSG_CHECKING([whether build environment is sane])
851 # Just in case
852 sleep 1
853 echo timestamp > conftest.file
854 # Reject unsafe characters in $srcdir or the absolute working directory
855 # name.  Accept space and tab only in the latter.
856 am_lf='
857 '
858 case `pwd` in
859   *[[\\\"\#\$\&\'\`$am_lf]]*)
860     AC_MSG_ERROR([unsafe absolute working directory name]);;
861 esac
862 case $srcdir in
863   *[[\\\"\#\$\&\'\`$am_lf\ \    ]]*)
864     AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
865 esac
866
867 # Do `set' in a subshell so we don't clobber the current shell's
868 # arguments.  Must try -L first in case configure is actually a
869 # symlink; some systems play weird games with the mod time of symlinks
870 # (eg FreeBSD returns the mod time of the symlink's containing
871 # directory).
872 if (
873    set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
874    if test "$[*]" = "X"; then
875       # -L didn't work.
876       set X `ls -t "$srcdir/configure" conftest.file`
877    fi
878    rm -f conftest.file
879    if test "$[*]" != "X $srcdir/configure conftest.file" \
880       && test "$[*]" != "X conftest.file $srcdir/configure"; then
881
882       # If neither matched, then we have a broken ls.  This can happen
883       # if, for instance, CONFIG_SHELL is bash and it inherits a
884       # broken ls alias from the environment.  This has actually
885       # happened.  Such a system could not be considered "sane".
886       AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
887 alias in your environment])
888    fi
889
890    test "$[2]" = conftest.file
891    )
892 then
893    # Ok.
894    :
895 else
896    AC_MSG_ERROR([newly created file is older than distributed files!
897 Check your system clock])
898 fi
899 AC_MSG_RESULT(yes)])
900
901 # Copyright (C) 2009, 2011  Free Software Foundation, Inc.
902 #
903 # This file is free software; the Free Software Foundation
904 # gives unlimited permission to copy and/or distribute it,
905 # with or without modifications, as long as this notice is preserved.
906
907 # serial 2
908
909 # AM_SILENT_RULES([DEFAULT])
910 # --------------------------
911 # Enable less verbose build rules; with the default set to DEFAULT
912 # (`yes' being less verbose, `no' or empty being verbose).
913 AC_DEFUN([AM_SILENT_RULES],
914 [AC_ARG_ENABLE([silent-rules],
915 [  --enable-silent-rules          less verbose build output (undo: `make V=1')
916   --disable-silent-rules         verbose build output (undo: `make V=0')])
917 case $enable_silent_rules in
918 yes) AM_DEFAULT_VERBOSITY=0;;
919 no)  AM_DEFAULT_VERBOSITY=1;;
920 *)   AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
921 esac
922 dnl
923 dnl A few `make' implementations (e.g., NonStop OS and NextStep)
924 dnl do not support nested variable expansions.
925 dnl See automake bug#9928 and bug#10237.
926 am_make=${MAKE-make}
927 AC_CACHE_CHECK([whether $am_make supports nested variables],
928    [am_cv_make_support_nested_variables],
929    [if AS_ECHO([['TRUE=$(BAR$(V))
930 BAR0=false
931 BAR1=true
932 V=1
933 am__doit:
934         @$(TRUE)
935 .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
936   am_cv_make_support_nested_variables=yes
937 else
938   am_cv_make_support_nested_variables=no
939 fi])
940 if test $am_cv_make_support_nested_variables = yes; then
941   dnl Using `$V' instead of `$(V)' breaks IRIX make.
942   AM_V='$(V)'
943   AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
944 else
945   AM_V=$AM_DEFAULT_VERBOSITY
946   AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
947 fi
948 AC_SUBST([AM_V])dnl
949 AM_SUBST_NOTMAKE([AM_V])dnl
950 AC_SUBST([AM_DEFAULT_V])dnl
951 AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
952 AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
953 AM_BACKSLASH='\'
954 AC_SUBST([AM_BACKSLASH])dnl
955 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
956 ])
957
958 # Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
959 #
960 # This file is free software; the Free Software Foundation
961 # gives unlimited permission to copy and/or distribute it,
962 # with or without modifications, as long as this notice is preserved.
963
964 # serial 1
965
966 # AM_PROG_INSTALL_STRIP
967 # ---------------------
968 # One issue with vendor `install' (even GNU) is that you can't
969 # specify the program used to strip binaries.  This is especially
970 # annoying in cross-compiling environments, where the build's strip
971 # is unlikely to handle the host's binaries.
972 # Fortunately install-sh will honor a STRIPPROG variable, so we
973 # always use install-sh in `make install-strip', and initialize
974 # STRIPPROG with the value of the STRIP variable (set by the user).
975 AC_DEFUN([AM_PROG_INSTALL_STRIP],
976 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
977 # Installed binaries are usually stripped using `strip' when the user
978 # run `make install-strip'.  However `strip' might not be the right
979 # tool to use in cross-compilation environments, therefore Automake
980 # will honor the `STRIP' environment variable to overrule this program.
981 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
982 if test "$cross_compiling" != no; then
983   AC_CHECK_TOOL([STRIP], [strip], :)
984 fi
985 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
986 AC_SUBST([INSTALL_STRIP_PROGRAM])])
987
988 # Copyright (C) 2006, 2008, 2010 Free Software Foundation, Inc.
989 #
990 # This file is free software; the Free Software Foundation
991 # gives unlimited permission to copy and/or distribute it,
992 # with or without modifications, as long as this notice is preserved.
993
994 # serial 3
995
996 # _AM_SUBST_NOTMAKE(VARIABLE)
997 # ---------------------------
998 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
999 # This macro is traced by Automake.
1000 AC_DEFUN([_AM_SUBST_NOTMAKE])
1001
1002 # AM_SUBST_NOTMAKE(VARIABLE)
1003 # --------------------------
1004 # Public sister of _AM_SUBST_NOTMAKE.
1005 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
1006
1007 # Check how to create a tarball.                            -*- Autoconf -*-
1008
1009 # Copyright (C) 2004, 2005, 2012 Free Software Foundation, Inc.
1010 #
1011 # This file is free software; the Free Software Foundation
1012 # gives unlimited permission to copy and/or distribute it,
1013 # with or without modifications, as long as this notice is preserved.
1014
1015 # serial 2
1016
1017 # _AM_PROG_TAR(FORMAT)
1018 # --------------------
1019 # Check how to create a tarball in format FORMAT.
1020 # FORMAT should be one of `v7', `ustar', or `pax'.
1021 #
1022 # Substitute a variable $(am__tar) that is a command
1023 # writing to stdout a FORMAT-tarball containing the directory
1024 # $tardir.
1025 #     tardir=directory && $(am__tar) > result.tar
1026 #
1027 # Substitute a variable $(am__untar) that extract such
1028 # a tarball read from stdin.
1029 #     $(am__untar) < result.tar
1030 AC_DEFUN([_AM_PROG_TAR],
1031 [# Always define AMTAR for backward compatibility.  Yes, it's still used
1032 # in the wild :-(  We should find a proper way to deprecate it ...
1033 AC_SUBST([AMTAR], ['$${TAR-tar}'])
1034 m4_if([$1], [v7],
1035      [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
1036      [m4_case([$1], [ustar],, [pax],,
1037               [m4_fatal([Unknown tar format])])
1038 AC_MSG_CHECKING([how to create a $1 tar archive])
1039 # Loop over all known methods to create a tar archive until one works.
1040 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
1041 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
1042 # Do not fold the above two line into one, because Tru64 sh and
1043 # Solaris sh will not grok spaces in the rhs of `-'.
1044 for _am_tool in $_am_tools
1045 do
1046   case $_am_tool in
1047   gnutar)
1048     for _am_tar in tar gnutar gtar;
1049     do
1050       AM_RUN_LOG([$_am_tar --version]) && break
1051     done
1052     am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
1053     am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
1054     am__untar="$_am_tar -xf -"
1055     ;;
1056   plaintar)
1057     # Must skip GNU tar: if it does not support --format= it doesn't create
1058     # ustar tarball either.
1059     (tar --version) >/dev/null 2>&1 && continue
1060     am__tar='tar chf - "$$tardir"'
1061     am__tar_='tar chf - "$tardir"'
1062     am__untar='tar xf -'
1063     ;;
1064   pax)
1065     am__tar='pax -L -x $1 -w "$$tardir"'
1066     am__tar_='pax -L -x $1 -w "$tardir"'
1067     am__untar='pax -r'
1068     ;;
1069   cpio)
1070     am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
1071     am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
1072     am__untar='cpio -i -H $1 -d'
1073     ;;
1074   none)
1075     am__tar=false
1076     am__tar_=false
1077     am__untar=false
1078     ;;
1079   esac
1080
1081   # If the value was cached, stop now.  We just wanted to have am__tar
1082   # and am__untar set.
1083   test -n "${am_cv_prog_tar_$1}" && break
1084
1085   # tar/untar a dummy directory, and stop if the command works
1086   rm -rf conftest.dir
1087   mkdir conftest.dir
1088   echo GrepMe > conftest.dir/file
1089   AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
1090   rm -rf conftest.dir
1091   if test -s conftest.tar; then
1092     AM_RUN_LOG([$am__untar <conftest.tar])
1093     grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
1094   fi
1095 done
1096 rm -rf conftest.dir
1097
1098 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
1099 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
1100 AC_SUBST([am__tar])
1101 AC_SUBST([am__untar])
1102 ]) # _AM_PROG_TAR
1103
1104
1105 dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
1106 # serial 42 IT_PROG_INTLTOOL
1107 AC_DEFUN([IT_PROG_INTLTOOL], [
1108 AC_PREREQ([2.50])dnl
1109 AC_REQUIRE([AM_NLS])dnl
1110
1111 case "$am__api_version" in
1112     1.[01234])
1113         AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
1114     ;;
1115     *)
1116     ;;
1117 esac
1118
1119 INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
1120 INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
1121 INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
1122 if test -n "$1"; then
1123     AC_MSG_CHECKING([for intltool >= $1])
1124     AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
1125     test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
1126         AC_MSG_ERROR([Your intltool is too old.  You need intltool $1 or later.])
1127 fi
1128
1129 AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
1130 AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
1131 AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
1132 if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
1133     AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
1134 fi
1135
1136 if test -z "$AM_DEFAULT_VERBOSITY"; then
1137   AM_DEFAULT_VERBOSITY=1
1138 fi
1139 AC_SUBST([AM_DEFAULT_VERBOSITY])
1140
1141 INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
1142 INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
1143 INTLTOOL__v_MERGE_0='@echo "  ITMRG " [$]@;'
1144 AC_SUBST(INTLTOOL_V_MERGE)
1145 AC_SUBST(INTLTOOL__v_MERGE_)
1146 AC_SUBST(INTLTOOL__v_MERGE_0)
1147
1148 INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
1149 intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
1150 intltool__v_merge_options_0='-q'
1151 AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
1152 AC_SUBST(intltool__v_merge_options_)
1153 AC_SUBST(intltool__v_merge_options_0)
1154
1155   INTLTOOL_DESKTOP_RULE='%.desktop:   %.desktop.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1156 INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1157      INTLTOOL_KEYS_RULE='%.keys:      %.keys.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1158      INTLTOOL_PROP_RULE='%.prop:      %.prop.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1159       INTLTOOL_OAF_RULE='%.oaf:       %.oaf.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -p $(top_srcdir)/po $< [$]@'
1160      INTLTOOL_PONG_RULE='%.pong:      %.pong.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1161    INTLTOOL_SERVER_RULE='%.server:    %.server.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1162     INTLTOOL_SHEET_RULE='%.sheet:     %.sheet.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1163 INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1164        INTLTOOL_UI_RULE='%.ui:        %.ui.in        $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1165       INTLTOOL_XML_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1166 if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
1167       INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u --no-translations $< [$]@'
1168 else
1169       INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)_it_tmp_dir=tmp.intltool.[$][$]RANDOM && mkdir [$][$]_it_tmp_dir && LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u [$][$]_it_tmp_dir $< [$]@ && rmdir [$][$]_it_tmp_dir'
1170 fi
1171       INTLTOOL_XAM_RULE='%.xam:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1172       INTLTOOL_KBD_RULE='%.kbd:       %.kbd.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1173     INTLTOOL_CAVES_RULE='%.caves:     %.caves.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1174   INTLTOOL_SCHEMAS_RULE='%.schemas:   %.schemas.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1175     INTLTOOL_THEME_RULE='%.theme:     %.theme.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
1176     INTLTOOL_SERVICE_RULE='%.service: %.service.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
1177    INTLTOOL_POLICY_RULE='%.policy:    %.policy.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
1178
1179 _IT_SUBST(INTLTOOL_DESKTOP_RULE)
1180 _IT_SUBST(INTLTOOL_DIRECTORY_RULE)
1181 _IT_SUBST(INTLTOOL_KEYS_RULE)
1182 _IT_SUBST(INTLTOOL_PROP_RULE)
1183 _IT_SUBST(INTLTOOL_OAF_RULE)
1184 _IT_SUBST(INTLTOOL_PONG_RULE)
1185 _IT_SUBST(INTLTOOL_SERVER_RULE)
1186 _IT_SUBST(INTLTOOL_SHEET_RULE)
1187 _IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
1188 _IT_SUBST(INTLTOOL_UI_RULE)
1189 _IT_SUBST(INTLTOOL_XAM_RULE)
1190 _IT_SUBST(INTLTOOL_KBD_RULE)
1191 _IT_SUBST(INTLTOOL_XML_RULE)
1192 _IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
1193 _IT_SUBST(INTLTOOL_CAVES_RULE)
1194 _IT_SUBST(INTLTOOL_SCHEMAS_RULE)
1195 _IT_SUBST(INTLTOOL_THEME_RULE)
1196 _IT_SUBST(INTLTOOL_SERVICE_RULE)
1197 _IT_SUBST(INTLTOOL_POLICY_RULE)
1198
1199 # Check the gettext tools to make sure they are GNU
1200 AC_PATH_PROG(XGETTEXT, xgettext)
1201 AC_PATH_PROG(MSGMERGE, msgmerge)
1202 AC_PATH_PROG(MSGFMT, msgfmt)
1203 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
1204 if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
1205     AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
1206 fi
1207 xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
1208 mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
1209 mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
1210 if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
1211     AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
1212 fi
1213
1214 AC_PATH_PROG(INTLTOOL_PERL, perl)
1215 if test -z "$INTLTOOL_PERL"; then
1216    AC_MSG_ERROR([perl not found])
1217 fi
1218 AC_MSG_CHECKING([for perl >= 5.8.1])
1219 $INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
1220 if test $? -ne 0; then
1221    AC_MSG_ERROR([perl 5.8.1 is required for intltool])
1222 else
1223    IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
1224    AC_MSG_RESULT([$IT_PERL_VERSION])
1225 fi
1226 if test "x$2" != "xno-xml"; then
1227    AC_MSG_CHECKING([for XML::Parser])
1228    if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
1229        AC_MSG_RESULT([ok])
1230    else
1231        AC_MSG_ERROR([XML::Parser perl module is required for intltool])
1232    fi
1233 fi
1234
1235 # Substitute ALL_LINGUAS so we can use it in po/Makefile
1236 AC_SUBST(ALL_LINGUAS)
1237
1238 # Set DATADIRNAME correctly if it is not set yet
1239 # (copied from glib-gettext.m4)
1240 if test -z "$DATADIRNAME"; then
1241   AC_LINK_IFELSE(
1242     [AC_LANG_PROGRAM([[]],
1243                      [[extern int _nl_msg_cat_cntr;
1244                        return _nl_msg_cat_cntr]])],
1245     [DATADIRNAME=share],
1246     [case $host in
1247     *-*-solaris*)
1248     dnl On Solaris, if bind_textdomain_codeset is in libc,
1249     dnl GNU format message catalog is always supported,
1250     dnl since both are added to the libc all together.
1251     dnl Hence, we'd like to go with DATADIRNAME=share
1252     dnl in this case.
1253     AC_CHECK_FUNC(bind_textdomain_codeset,
1254       [DATADIRNAME=share], [DATADIRNAME=lib])
1255     ;;
1256     *)
1257     [DATADIRNAME=lib]
1258     ;;
1259     esac])
1260 fi
1261 AC_SUBST(DATADIRNAME)
1262
1263 IT_PO_SUBDIR([po])
1264
1265 ])
1266
1267
1268 # IT_PO_SUBDIR(DIRNAME)
1269 # ---------------------
1270 # All po subdirs have to be declared with this macro; the subdir "po" is
1271 # declared by IT_PROG_INTLTOOL.
1272 #
1273 AC_DEFUN([IT_PO_SUBDIR],
1274 [AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
1275 dnl
1276 dnl The following CONFIG_COMMANDS should be executed at the very end
1277 dnl of config.status.
1278 AC_CONFIG_COMMANDS_PRE([
1279   AC_CONFIG_COMMANDS([$1/stamp-it], [
1280     if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
1281        AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
1282     fi
1283     rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
1284     >"$1/stamp-it.tmp"
1285     [sed '/^#/d
1286          s/^[[].*] *//
1287          /^[    ]*$/d
1288         '"s|^|  $ac_top_srcdir/|" \
1289       "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
1290     ]
1291     [sed '/^POTFILES =/,/[^\\]$/ {
1292                 /^POTFILES =/!d
1293                 r $1/POTFILES
1294           }
1295          ' "$1/Makefile.in" >"$1/Makefile"]
1296     rm -f "$1/Makefile.tmp"
1297     mv "$1/stamp-it.tmp" "$1/stamp-it"
1298   ])
1299 ])dnl
1300 ])
1301
1302 # _IT_SUBST(VARIABLE)
1303 # -------------------
1304 # Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
1305 #
1306 AC_DEFUN([_IT_SUBST],
1307 [
1308 AC_SUBST([$1])
1309 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
1310 ]
1311 )
1312
1313 # deprecated macros
1314 AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
1315 # A hint is needed for aclocal from Automake <= 1.9.4:
1316 # AC_DEFUN([AC_PROG_INTLTOOL], ...)
1317
1318
1319 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
1320 #
1321 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1322 #                 2006, 2007, 2008, 2009, 2010, 2011 Free Software
1323 #                 Foundation, Inc.
1324 #   Written by Gordon Matzigkeit, 1996
1325 #
1326 # This file is free software; the Free Software Foundation gives
1327 # unlimited permission to copy and/or distribute it, with or without
1328 # modifications, as long as this notice is preserved.
1329
1330 m4_define([_LT_COPYING], [dnl
1331 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1332 #                 2006, 2007, 2008, 2009, 2010, 2011 Free Software
1333 #                 Foundation, Inc.
1334 #   Written by Gordon Matzigkeit, 1996
1335 #
1336 #   This file is part of GNU Libtool.
1337 #
1338 # GNU Libtool is free software; you can redistribute it and/or
1339 # modify it under the terms of the GNU General Public License as
1340 # published by the Free Software Foundation; either version 2 of
1341 # the License, or (at your option) any later version.
1342 #
1343 # As a special exception to the GNU General Public License,
1344 # if you distribute this file as part of a program or library that
1345 # is built using GNU Libtool, you may include this file under the
1346 # same distribution terms that you use for the rest of that program.
1347 #
1348 # GNU Libtool is distributed in the hope that it will be useful,
1349 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1350 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1351 # GNU General Public License for more details.
1352 #
1353 # You should have received a copy of the GNU General Public License
1354 # along with GNU Libtool; see the file COPYING.  If not, a copy
1355 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
1356 # obtained by writing to the Free Software Foundation, Inc.,
1357 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1358 ])
1359
1360 # serial 57 LT_INIT
1361
1362
1363 # LT_PREREQ(VERSION)
1364 # ------------------
1365 # Complain and exit if this libtool version is less that VERSION.
1366 m4_defun([LT_PREREQ],
1367 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
1368        [m4_default([$3],
1369                    [m4_fatal([Libtool version $1 or higher is required],
1370                              63)])],
1371        [$2])])
1372
1373
1374 # _LT_CHECK_BUILDDIR
1375 # ------------------
1376 # Complain if the absolute build directory name contains unusual characters
1377 m4_defun([_LT_CHECK_BUILDDIR],
1378 [case `pwd` in
1379   *\ * | *\     *)
1380     AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
1381 esac
1382 ])
1383
1384
1385 # LT_INIT([OPTIONS])
1386 # ------------------
1387 AC_DEFUN([LT_INIT],
1388 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
1389 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
1390 AC_BEFORE([$0], [LT_LANG])dnl
1391 AC_BEFORE([$0], [LT_OUTPUT])dnl
1392 AC_BEFORE([$0], [LTDL_INIT])dnl
1393 m4_require([_LT_CHECK_BUILDDIR])dnl
1394
1395 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
1396 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
1397 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
1398 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
1399 dnl unless we require an AC_DEFUNed macro:
1400 AC_REQUIRE([LTOPTIONS_VERSION])dnl
1401 AC_REQUIRE([LTSUGAR_VERSION])dnl
1402 AC_REQUIRE([LTVERSION_VERSION])dnl
1403 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
1404 m4_require([_LT_PROG_LTMAIN])dnl
1405
1406 _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
1407
1408 dnl Parse OPTIONS
1409 _LT_SET_OPTIONS([$0], [$1])
1410
1411 # This can be used to rebuild libtool when needed
1412 LIBTOOL_DEPS="$ltmain"
1413
1414 # Always use our own libtool.
1415 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1416 AC_SUBST(LIBTOOL)dnl
1417
1418 _LT_SETUP
1419
1420 # Only expand once:
1421 m4_define([LT_INIT])
1422 ])# LT_INIT
1423
1424 # Old names:
1425 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
1426 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
1427 dnl aclocal-1.4 backwards compatibility:
1428 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
1429 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
1430
1431
1432 # _LT_CC_BASENAME(CC)
1433 # -------------------
1434 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
1435 m4_defun([_LT_CC_BASENAME],
1436 [for cc_temp in $1""; do
1437   case $cc_temp in
1438     compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1439     distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1440     \-*) ;;
1441     *) break;;
1442   esac
1443 done
1444 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
1445 ])
1446
1447
1448 # _LT_FILEUTILS_DEFAULTS
1449 # ----------------------
1450 # It is okay to use these file commands and assume they have been set
1451 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
1452 m4_defun([_LT_FILEUTILS_DEFAULTS],
1453 [: ${CP="cp -f"}
1454 : ${MV="mv -f"}
1455 : ${RM="rm -f"}
1456 ])# _LT_FILEUTILS_DEFAULTS
1457
1458
1459 # _LT_SETUP
1460 # ---------
1461 m4_defun([_LT_SETUP],
1462 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1463 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1464 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
1465 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
1466
1467 _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
1468 dnl
1469 _LT_DECL([], [host_alias], [0], [The host system])dnl
1470 _LT_DECL([], [host], [0])dnl
1471 _LT_DECL([], [host_os], [0])dnl
1472 dnl
1473 _LT_DECL([], [build_alias], [0], [The build system])dnl
1474 _LT_DECL([], [build], [0])dnl
1475 _LT_DECL([], [build_os], [0])dnl
1476 dnl
1477 AC_REQUIRE([AC_PROG_CC])dnl
1478 AC_REQUIRE([LT_PATH_LD])dnl
1479 AC_REQUIRE([LT_PATH_NM])dnl
1480 dnl
1481 AC_REQUIRE([AC_PROG_LN_S])dnl
1482 test -z "$LN_S" && LN_S="ln -s"
1483 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
1484 dnl
1485 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
1486 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
1487 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
1488 dnl
1489 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1490 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
1491 m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
1492 m4_require([_LT_CMD_RELOAD])dnl
1493 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
1494 m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
1495 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
1496 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
1497 m4_require([_LT_WITH_SYSROOT])dnl
1498
1499 _LT_CONFIG_LIBTOOL_INIT([
1500 # See if we are running on zsh, and set the options which allow our
1501 # commands through without removal of \ escapes INIT.
1502 if test -n "\${ZSH_VERSION+set}" ; then
1503    setopt NO_GLOB_SUBST
1504 fi
1505 ])
1506 if test -n "${ZSH_VERSION+set}" ; then
1507    setopt NO_GLOB_SUBST
1508 fi
1509
1510 _LT_CHECK_OBJDIR
1511
1512 m4_require([_LT_TAG_COMPILER])dnl
1513
1514 case $host_os in
1515 aix3*)
1516   # AIX sometimes has problems with the GCC collect2 program.  For some
1517   # reason, if we set the COLLECT_NAMES environment variable, the problems
1518   # vanish in a puff of smoke.
1519   if test "X${COLLECT_NAMES+set}" != Xset; then
1520     COLLECT_NAMES=
1521     export COLLECT_NAMES
1522   fi
1523   ;;
1524 esac
1525
1526 # Global variables:
1527 ofile=libtool
1528 can_build_shared=yes
1529
1530 # All known linkers require a `.a' archive for static linking (except MSVC,
1531 # which needs '.lib').
1532 libext=a
1533
1534 with_gnu_ld="$lt_cv_prog_gnu_ld"
1535
1536 old_CC="$CC"
1537 old_CFLAGS="$CFLAGS"
1538
1539 # Set sane defaults for various variables
1540 test -z "$CC" && CC=cc
1541 test -z "$LTCC" && LTCC=$CC
1542 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1543 test -z "$LD" && LD=ld
1544 test -z "$ac_objext" && ac_objext=o
1545
1546 _LT_CC_BASENAME([$compiler])
1547
1548 # Only perform the check for file, if the check method requires it
1549 test -z "$MAGIC_CMD" && MAGIC_CMD=file
1550 case $deplibs_check_method in
1551 file_magic*)
1552   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1553     _LT_PATH_MAGIC
1554   fi
1555   ;;
1556 esac
1557
1558 # Use C for the default configuration in the libtool script
1559 LT_SUPPORTED_TAG([CC])
1560 _LT_LANG_C_CONFIG
1561 _LT_LANG_DEFAULT_CONFIG
1562 _LT_CONFIG_COMMANDS
1563 ])# _LT_SETUP
1564
1565
1566 # _LT_PREPARE_SED_QUOTE_VARS
1567 # --------------------------
1568 # Define a few sed substitution that help us do robust quoting.
1569 m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
1570 [# Backslashify metacharacters that are still active within
1571 # double-quoted strings.
1572 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
1573
1574 # Same as above, but do not quote variable references.
1575 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
1576
1577 # Sed substitution to delay expansion of an escaped shell variable in a
1578 # double_quote_subst'ed string.
1579 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1580
1581 # Sed substitution to delay expansion of an escaped single quote.
1582 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
1583
1584 # Sed substitution to avoid accidental globbing in evaled expressions
1585 no_glob_subst='s/\*/\\\*/g'
1586 ])
1587
1588 # _LT_PROG_LTMAIN
1589 # ---------------
1590 # Note that this code is called both from `configure', and `config.status'
1591 # now that we use AC_CONFIG_COMMANDS to generate libtool.  Notably,
1592 # `config.status' has no value for ac_aux_dir unless we are using Automake,
1593 # so we pass a copy along to make sure it has a sensible value anyway.
1594 m4_defun([_LT_PROG_LTMAIN],
1595 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
1596 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
1597 ltmain="$ac_aux_dir/ltmain.sh"
1598 ])# _LT_PROG_LTMAIN
1599
1600
1601
1602 # So that we can recreate a full libtool script including additional
1603 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
1604 # in macros and then make a single call at the end using the `libtool'
1605 # label.
1606
1607
1608 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
1609 # ----------------------------------------
1610 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1611 m4_define([_LT_CONFIG_LIBTOOL_INIT],
1612 [m4_ifval([$1],
1613           [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
1614                      [$1
1615 ])])])
1616
1617 # Initialize.
1618 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
1619
1620
1621 # _LT_CONFIG_LIBTOOL([COMMANDS])
1622 # ------------------------------
1623 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1624 m4_define([_LT_CONFIG_LIBTOOL],
1625 [m4_ifval([$1],
1626           [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
1627                      [$1
1628 ])])])
1629
1630 # Initialize.
1631 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
1632
1633
1634 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
1635 # -----------------------------------------------------
1636 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
1637 [_LT_CONFIG_LIBTOOL([$1])
1638 _LT_CONFIG_LIBTOOL_INIT([$2])
1639 ])
1640
1641
1642 # _LT_FORMAT_COMMENT([COMMENT])
1643 # -----------------------------
1644 # Add leading comment marks to the start of each line, and a trailing
1645 # full-stop to the whole comment if one is not present already.
1646 m4_define([_LT_FORMAT_COMMENT],
1647 [m4_ifval([$1], [
1648 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
1649               [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
1650 )])
1651
1652
1653
1654
1655
1656 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
1657 # -------------------------------------------------------------------
1658 # CONFIGNAME is the name given to the value in the libtool script.
1659 # VARNAME is the (base) name used in the configure script.
1660 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
1661 # VARNAME.  Any other value will be used directly.
1662 m4_define([_LT_DECL],
1663 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
1664     [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
1665         [m4_ifval([$1], [$1], [$2])])
1666     lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
1667     m4_ifval([$4],
1668         [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
1669     lt_dict_add_subkey([lt_decl_dict], [$2],
1670         [tagged?], [m4_ifval([$5], [yes], [no])])])
1671 ])
1672
1673
1674 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
1675 # --------------------------------------------------------
1676 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
1677
1678
1679 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
1680 # ------------------------------------------------
1681 m4_define([lt_decl_tag_varnames],
1682 [_lt_decl_filter([tagged?], [yes], $@)])
1683
1684
1685 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
1686 # ---------------------------------------------------------
1687 m4_define([_lt_decl_filter],
1688 [m4_case([$#],
1689   [0], [m4_fatal([$0: too few arguments: $#])],
1690   [1], [m4_fatal([$0: too few arguments: $#: $1])],
1691   [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
1692   [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
1693   [lt_dict_filter([lt_decl_dict], $@)])[]dnl
1694 ])
1695
1696
1697 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
1698 # --------------------------------------------------
1699 m4_define([lt_decl_quote_varnames],
1700 [_lt_decl_filter([value], [1], $@)])
1701
1702
1703 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
1704 # ---------------------------------------------------
1705 m4_define([lt_decl_dquote_varnames],
1706 [_lt_decl_filter([value], [2], $@)])
1707
1708
1709 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
1710 # ---------------------------------------------------
1711 m4_define([lt_decl_varnames_tagged],
1712 [m4_assert([$# <= 2])dnl
1713 _$0(m4_quote(m4_default([$1], [[, ]])),
1714     m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
1715     m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
1716 m4_define([_lt_decl_varnames_tagged],
1717 [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
1718
1719
1720 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
1721 # ------------------------------------------------
1722 m4_define([lt_decl_all_varnames],
1723 [_$0(m4_quote(m4_default([$1], [[, ]])),
1724      m4_if([$2], [],
1725            m4_quote(lt_decl_varnames),
1726         m4_quote(m4_shift($@))))[]dnl
1727 ])
1728 m4_define([_lt_decl_all_varnames],
1729 [lt_join($@, lt_decl_varnames_tagged([$1],
1730                         lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
1731 ])
1732
1733
1734 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
1735 # ------------------------------------
1736 # Quote a variable value, and forward it to `config.status' so that its
1737 # declaration there will have the same value as in `configure'.  VARNAME
1738 # must have a single quote delimited value for this to work.
1739 m4_define([_LT_CONFIG_STATUS_DECLARE],
1740 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
1741
1742
1743 # _LT_CONFIG_STATUS_DECLARATIONS
1744 # ------------------------------
1745 # We delimit libtool config variables with single quotes, so when
1746 # we write them to config.status, we have to be sure to quote all
1747 # embedded single quotes properly.  In configure, this macro expands
1748 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
1749 #
1750 #    <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
1751 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
1752 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
1753     [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
1754
1755
1756 # _LT_LIBTOOL_TAGS
1757 # ----------------
1758 # Output comment and list of tags supported by the script
1759 m4_defun([_LT_LIBTOOL_TAGS],
1760 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
1761 available_tags="_LT_TAGS"dnl
1762 ])
1763
1764
1765 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
1766 # -----------------------------------
1767 # Extract the dictionary values for VARNAME (optionally with TAG) and
1768 # expand to a commented shell variable setting:
1769 #
1770 #    # Some comment about what VAR is for.
1771 #    visible_name=$lt_internal_name
1772 m4_define([_LT_LIBTOOL_DECLARE],
1773 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
1774                                            [description])))[]dnl
1775 m4_pushdef([_libtool_name],
1776     m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
1777 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
1778     [0], [_libtool_name=[$]$1],
1779     [1], [_libtool_name=$lt_[]$1],
1780     [2], [_libtool_name=$lt_[]$1],
1781     [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
1782 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
1783 ])
1784
1785
1786 # _LT_LIBTOOL_CONFIG_VARS
1787 # -----------------------
1788 # Produce commented declarations of non-tagged libtool config variables
1789 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
1790 # script.  Tagged libtool config variables (even for the LIBTOOL CONFIG
1791 # section) are produced by _LT_LIBTOOL_TAG_VARS.
1792 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
1793 [m4_foreach([_lt_var],
1794     m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
1795     [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
1796
1797
1798 # _LT_LIBTOOL_TAG_VARS(TAG)
1799 # -------------------------
1800 m4_define([_LT_LIBTOOL_TAG_VARS],
1801 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
1802     [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
1803
1804
1805 # _LT_TAGVAR(VARNAME, [TAGNAME])
1806 # ------------------------------
1807 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
1808
1809
1810 # _LT_CONFIG_COMMANDS
1811 # -------------------
1812 # Send accumulated output to $CONFIG_STATUS.  Thanks to the lists of
1813 # variables for single and double quote escaping we saved from calls
1814 # to _LT_DECL, we can put quote escaped variables declarations
1815 # into `config.status', and then the shell code to quote escape them in
1816 # for loops in `config.status'.  Finally, any additional code accumulated
1817 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
1818 m4_defun([_LT_CONFIG_COMMANDS],
1819 [AC_PROVIDE_IFELSE([LT_OUTPUT],
1820         dnl If the libtool generation code has been placed in $CONFIG_LT,
1821         dnl instead of duplicating it all over again into config.status,
1822         dnl then we will have config.status run $CONFIG_LT later, so it
1823         dnl needs to know what name is stored there:
1824         [AC_CONFIG_COMMANDS([libtool],
1825             [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
1826     dnl If the libtool generation code is destined for config.status,
1827     dnl expand the accumulated commands and init code now:
1828     [AC_CONFIG_COMMANDS([libtool],
1829         [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
1830 ])#_LT_CONFIG_COMMANDS
1831
1832
1833 # Initialize.
1834 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
1835 [
1836
1837 # The HP-UX ksh and POSIX shell print the target directory to stdout
1838 # if CDPATH is set.
1839 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1840
1841 sed_quote_subst='$sed_quote_subst'
1842 double_quote_subst='$double_quote_subst'
1843 delay_variable_subst='$delay_variable_subst'
1844 _LT_CONFIG_STATUS_DECLARATIONS
1845 LTCC='$LTCC'
1846 LTCFLAGS='$LTCFLAGS'
1847 compiler='$compiler_DEFAULT'
1848
1849 # A function that is used when there is no print builtin or printf.
1850 func_fallback_echo ()
1851 {
1852   eval 'cat <<_LTECHO_EOF
1853 \$[]1
1854 _LTECHO_EOF'
1855 }
1856
1857 # Quote evaled strings.
1858 for var in lt_decl_all_varnames([[ \
1859 ]], lt_decl_quote_varnames); do
1860     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1861     *[[\\\\\\\`\\"\\\$]]*)
1862       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1863       ;;
1864     *)
1865       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1866       ;;
1867     esac
1868 done
1869
1870 # Double-quote double-evaled strings.
1871 for var in lt_decl_all_varnames([[ \
1872 ]], lt_decl_dquote_varnames); do
1873     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1874     *[[\\\\\\\`\\"\\\$]]*)
1875       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1876       ;;
1877     *)
1878       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1879       ;;
1880     esac
1881 done
1882
1883 _LT_OUTPUT_LIBTOOL_INIT
1884 ])
1885
1886 # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
1887 # ------------------------------------
1888 # Generate a child script FILE with all initialization necessary to
1889 # reuse the environment learned by the parent script, and make the
1890 # file executable.  If COMMENT is supplied, it is inserted after the
1891 # `#!' sequence but before initialization text begins.  After this
1892 # macro, additional text can be appended to FILE to form the body of
1893 # the child script.  The macro ends with non-zero status if the
1894 # file could not be fully written (such as if the disk is full).
1895 m4_ifdef([AS_INIT_GENERATED],
1896 [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
1897 [m4_defun([_LT_GENERATED_FILE_INIT],
1898 [m4_require([AS_PREPARE])]dnl
1899 [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
1900 [lt_write_fail=0
1901 cat >$1 <<_ASEOF || lt_write_fail=1
1902 #! $SHELL
1903 # Generated by $as_me.
1904 $2
1905 SHELL=\${CONFIG_SHELL-$SHELL}
1906 export SHELL
1907 _ASEOF
1908 cat >>$1 <<\_ASEOF || lt_write_fail=1
1909 AS_SHELL_SANITIZE
1910 _AS_PREPARE
1911 exec AS_MESSAGE_FD>&1
1912 _ASEOF
1913 test $lt_write_fail = 0 && chmod +x $1[]dnl
1914 m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
1915
1916 # LT_OUTPUT
1917 # ---------
1918 # This macro allows early generation of the libtool script (before
1919 # AC_OUTPUT is called), incase it is used in configure for compilation
1920 # tests.
1921 AC_DEFUN([LT_OUTPUT],
1922 [: ${CONFIG_LT=./config.lt}
1923 AC_MSG_NOTICE([creating $CONFIG_LT])
1924 _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
1925 [# Run this file to recreate a libtool stub with the current configuration.])
1926
1927 cat >>"$CONFIG_LT" <<\_LTEOF
1928 lt_cl_silent=false
1929 exec AS_MESSAGE_LOG_FD>>config.log
1930 {
1931   echo
1932   AS_BOX([Running $as_me.])
1933 } >&AS_MESSAGE_LOG_FD
1934
1935 lt_cl_help="\
1936 \`$as_me' creates a local libtool stub from the current configuration,
1937 for use in further configure time tests before the real libtool is
1938 generated.
1939
1940 Usage: $[0] [[OPTIONS]]
1941
1942   -h, --help      print this help, then exit
1943   -V, --version   print version number, then exit
1944   -q, --quiet     do not print progress messages
1945   -d, --debug     don't remove temporary files
1946
1947 Report bugs to <bug-libtool@gnu.org>."
1948
1949 lt_cl_version="\
1950 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1951 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1952 configured by $[0], generated by m4_PACKAGE_STRING.
1953
1954 Copyright (C) 2011 Free Software Foundation, Inc.
1955 This config.lt script is free software; the Free Software Foundation
1956 gives unlimited permision to copy, distribute and modify it."
1957
1958 while test $[#] != 0
1959 do
1960   case $[1] in
1961     --version | --v* | -V )
1962       echo "$lt_cl_version"; exit 0 ;;
1963     --help | --h* | -h )
1964       echo "$lt_cl_help"; exit 0 ;;
1965     --debug | --d* | -d )
1966       debug=: ;;
1967     --quiet | --q* | --silent | --s* | -q )
1968       lt_cl_silent=: ;;
1969
1970     -*) AC_MSG_ERROR([unrecognized option: $[1]
1971 Try \`$[0] --help' for more information.]) ;;
1972
1973     *) AC_MSG_ERROR([unrecognized argument: $[1]
1974 Try \`$[0] --help' for more information.]) ;;
1975   esac
1976   shift
1977 done
1978
1979 if $lt_cl_silent; then
1980   exec AS_MESSAGE_FD>/dev/null
1981 fi
1982 _LTEOF
1983
1984 cat >>"$CONFIG_LT" <<_LTEOF
1985 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1986 _LTEOF
1987
1988 cat >>"$CONFIG_LT" <<\_LTEOF
1989 AC_MSG_NOTICE([creating $ofile])
1990 _LT_OUTPUT_LIBTOOL_COMMANDS
1991 AS_EXIT(0)
1992 _LTEOF
1993 chmod +x "$CONFIG_LT"
1994
1995 # configure is writing to config.log, but config.lt does its own redirection,
1996 # appending to config.log, which fails on DOS, as config.log is still kept
1997 # open by configure.  Here we exec the FD to /dev/null, effectively closing
1998 # config.log, so it can be properly (re)opened and appended to by config.lt.
1999 lt_cl_success=:
2000 test "$silent" = yes &&
2001   lt_config_lt_args="$lt_config_lt_args --quiet"
2002 exec AS_MESSAGE_LOG_FD>/dev/null
2003 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
2004 exec AS_MESSAGE_LOG_FD>>config.log
2005 $lt_cl_success || AS_EXIT(1)
2006 ])# LT_OUTPUT
2007
2008
2009 # _LT_CONFIG(TAG)
2010 # ---------------
2011 # If TAG is the built-in tag, create an initial libtool script with a
2012 # default configuration from the untagged config vars.  Otherwise add code
2013 # to config.status for appending the configuration named by TAG from the
2014 # matching tagged config vars.
2015 m4_defun([_LT_CONFIG],
2016 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2017 _LT_CONFIG_SAVE_COMMANDS([
2018   m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
2019   m4_if(_LT_TAG, [C], [
2020     # See if we are running on zsh, and set the options which allow our
2021     # commands through without removal of \ escapes.
2022     if test -n "${ZSH_VERSION+set}" ; then
2023       setopt NO_GLOB_SUBST
2024     fi
2025
2026     cfgfile="${ofile}T"
2027     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
2028     $RM "$cfgfile"
2029
2030     cat <<_LT_EOF >> "$cfgfile"
2031 #! $SHELL
2032
2033 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
2034 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
2035 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2036 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
2037 #
2038 _LT_COPYING
2039 _LT_LIBTOOL_TAGS
2040
2041 # ### BEGIN LIBTOOL CONFIG
2042 _LT_LIBTOOL_CONFIG_VARS
2043 _LT_LIBTOOL_TAG_VARS
2044 # ### END LIBTOOL CONFIG
2045
2046 _LT_EOF
2047
2048   case $host_os in
2049   aix3*)
2050     cat <<\_LT_EOF >> "$cfgfile"
2051 # AIX sometimes has problems with the GCC collect2 program.  For some
2052 # reason, if we set the COLLECT_NAMES environment variable, the problems
2053 # vanish in a puff of smoke.
2054 if test "X${COLLECT_NAMES+set}" != Xset; then
2055   COLLECT_NAMES=
2056   export COLLECT_NAMES
2057 fi
2058 _LT_EOF
2059     ;;
2060   esac
2061
2062   _LT_PROG_LTMAIN
2063
2064   # We use sed instead of cat because bash on DJGPP gets confused if
2065   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
2066   # text mode, it properly converts lines to CR/LF.  This bash problem
2067   # is reportedly fixed, but why not run on old versions too?
2068   sed '$q' "$ltmain" >> "$cfgfile" \
2069      || (rm -f "$cfgfile"; exit 1)
2070
2071   _LT_PROG_REPLACE_SHELLFNS
2072
2073    mv -f "$cfgfile" "$ofile" ||
2074     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
2075   chmod +x "$ofile"
2076 ],
2077 [cat <<_LT_EOF >> "$ofile"
2078
2079 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
2080 dnl in a comment (ie after a #).
2081 # ### BEGIN LIBTOOL TAG CONFIG: $1
2082 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
2083 # ### END LIBTOOL TAG CONFIG: $1
2084 _LT_EOF
2085 ])dnl /m4_if
2086 ],
2087 [m4_if([$1], [], [
2088     PACKAGE='$PACKAGE'
2089     VERSION='$VERSION'
2090     TIMESTAMP='$TIMESTAMP'
2091     RM='$RM'
2092     ofile='$ofile'], [])
2093 ])dnl /_LT_CONFIG_SAVE_COMMANDS
2094 ])# _LT_CONFIG
2095
2096
2097 # LT_SUPPORTED_TAG(TAG)
2098 # ---------------------
2099 # Trace this macro to discover what tags are supported by the libtool
2100 # --tag option, using:
2101 #    autoconf --trace 'LT_SUPPORTED_TAG:$1'
2102 AC_DEFUN([LT_SUPPORTED_TAG], [])
2103
2104
2105 # C support is built-in for now
2106 m4_define([_LT_LANG_C_enabled], [])
2107 m4_define([_LT_TAGS], [])
2108
2109
2110 # LT_LANG(LANG)
2111 # -------------
2112 # Enable libtool support for the given language if not already enabled.
2113 AC_DEFUN([LT_LANG],
2114 [AC_BEFORE([$0], [LT_OUTPUT])dnl
2115 m4_case([$1],
2116   [C],                  [_LT_LANG(C)],
2117   [C++],                [_LT_LANG(CXX)],
2118   [Go],                 [_LT_LANG(GO)],
2119   [Java],               [_LT_LANG(GCJ)],
2120   [Fortran 77],         [_LT_LANG(F77)],
2121   [Fortran],            [_LT_LANG(FC)],
2122   [Windows Resource],   [_LT_LANG(RC)],
2123   [m4_ifdef([_LT_LANG_]$1[_CONFIG],
2124     [_LT_LANG($1)],
2125     [m4_fatal([$0: unsupported language: "$1"])])])dnl
2126 ])# LT_LANG
2127
2128
2129 # _LT_LANG(LANGNAME)
2130 # ------------------
2131 m4_defun([_LT_LANG],
2132 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
2133   [LT_SUPPORTED_TAG([$1])dnl
2134   m4_append([_LT_TAGS], [$1 ])dnl
2135   m4_define([_LT_LANG_]$1[_enabled], [])dnl
2136   _LT_LANG_$1_CONFIG($1)])dnl
2137 ])# _LT_LANG
2138
2139
2140 m4_ifndef([AC_PROG_GO], [
2141 # NOTE: This macro has been submitted for inclusion into   #
2142 #  GNU Autoconf as AC_PROG_GO.  When it is available in    #
2143 #  a released version of Autoconf we should remove this    #
2144 #  macro and use it instead.                               #
2145 m4_defun([AC_PROG_GO],
2146 [AC_LANG_PUSH(Go)dnl
2147 AC_ARG_VAR([GOC],     [Go compiler command])dnl
2148 AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
2149 _AC_ARG_VAR_LDFLAGS()dnl
2150 AC_CHECK_TOOL(GOC, gccgo)
2151 if test -z "$GOC"; then
2152   if test -n "$ac_tool_prefix"; then
2153     AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
2154   fi
2155 fi
2156 if test -z "$GOC"; then
2157   AC_CHECK_PROG(GOC, gccgo, gccgo, false)
2158 fi
2159 ])#m4_defun
2160 ])#m4_ifndef
2161
2162
2163 # _LT_LANG_DEFAULT_CONFIG
2164 # -----------------------
2165 m4_defun([_LT_LANG_DEFAULT_CONFIG],
2166 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
2167   [LT_LANG(CXX)],
2168   [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
2169
2170 AC_PROVIDE_IFELSE([AC_PROG_F77],
2171   [LT_LANG(F77)],
2172   [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
2173
2174 AC_PROVIDE_IFELSE([AC_PROG_FC],
2175   [LT_LANG(FC)],
2176   [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
2177
2178 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
2179 dnl pulling things in needlessly.
2180 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
2181   [LT_LANG(GCJ)],
2182   [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
2183     [LT_LANG(GCJ)],
2184     [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
2185       [LT_LANG(GCJ)],
2186       [m4_ifdef([AC_PROG_GCJ],
2187         [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
2188        m4_ifdef([A][M_PROG_GCJ],
2189         [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
2190        m4_ifdef([LT_PROG_GCJ],
2191         [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
2192
2193 AC_PROVIDE_IFELSE([AC_PROG_GO],
2194   [LT_LANG(GO)],
2195   [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
2196
2197 AC_PROVIDE_IFELSE([LT_PROG_RC],
2198   [LT_LANG(RC)],
2199   [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
2200 ])# _LT_LANG_DEFAULT_CONFIG
2201
2202 # Obsolete macros:
2203 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
2204 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
2205 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
2206 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
2207 AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
2208 dnl aclocal-1.4 backwards compatibility:
2209 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
2210 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
2211 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
2212 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
2213 dnl AC_DEFUN([AC_LIBTOOL_RC], [])
2214
2215
2216 # _LT_TAG_COMPILER
2217 # ----------------
2218 m4_defun([_LT_TAG_COMPILER],
2219 [AC_REQUIRE([AC_PROG_CC])dnl
2220
2221 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
2222 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
2223 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
2224 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
2225
2226 # If no C compiler was specified, use CC.
2227 LTCC=${LTCC-"$CC"}
2228
2229 # If no C compiler flags were specified, use CFLAGS.
2230 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
2231
2232 # Allow CC to be a program name with arguments.
2233 compiler=$CC
2234 ])# _LT_TAG_COMPILER
2235
2236
2237 # _LT_COMPILER_BOILERPLATE
2238 # ------------------------
2239 # Check for compiler boilerplate output or warnings with
2240 # the simple compiler test code.
2241 m4_defun([_LT_COMPILER_BOILERPLATE],
2242 [m4_require([_LT_DECL_SED])dnl
2243 ac_outfile=conftest.$ac_objext
2244 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
2245 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
2246 _lt_compiler_boilerplate=`cat conftest.err`
2247 $RM conftest*
2248 ])# _LT_COMPILER_BOILERPLATE
2249
2250
2251 # _LT_LINKER_BOILERPLATE
2252 # ----------------------
2253 # Check for linker boilerplate output or warnings with
2254 # the simple link test code.
2255 m4_defun([_LT_LINKER_BOILERPLATE],
2256 [m4_require([_LT_DECL_SED])dnl
2257 ac_outfile=conftest.$ac_objext
2258 echo "$lt_simple_link_test_code" >conftest.$ac_ext
2259 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
2260 _lt_linker_boilerplate=`cat conftest.err`
2261 $RM -r conftest*
2262 ])# _LT_LINKER_BOILERPLATE
2263
2264 # _LT_REQUIRED_DARWIN_CHECKS
2265 # -------------------------
2266 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
2267   case $host_os in
2268     rhapsody* | darwin*)
2269     AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
2270     AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
2271     AC_CHECK_TOOL([LIPO], [lipo], [:])
2272     AC_CHECK_TOOL([OTOOL], [otool], [:])
2273     AC_CHECK_TOOL([OTOOL64], [otool64], [:])
2274     _LT_DECL([], [DSYMUTIL], [1],
2275       [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
2276     _LT_DECL([], [NMEDIT], [1],
2277       [Tool to change global to local symbols on Mac OS X])
2278     _LT_DECL([], [LIPO], [1],
2279       [Tool to manipulate fat objects and archives on Mac OS X])
2280     _LT_DECL([], [OTOOL], [1],
2281       [ldd/readelf like tool for Mach-O binaries on Mac OS X])
2282     _LT_DECL([], [OTOOL64], [1],
2283       [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
2284
2285     AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
2286       [lt_cv_apple_cc_single_mod=no
2287       if test -z "${LT_MULTI_MODULE}"; then
2288         # By default we will add the -single_module flag. You can override
2289         # by either setting the environment variable LT_MULTI_MODULE
2290         # non-empty at configure time, or by adding -multi_module to the
2291         # link flags.
2292         rm -rf libconftest.dylib*
2293         echo "int foo(void){return 1;}" > conftest.c
2294         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
2295 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
2296         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
2297           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
2298         _lt_result=$?
2299         # If there is a non-empty error log, and "single_module"
2300         # appears in it, assume the flag caused a linker warning
2301         if test -s conftest.err && $GREP single_module conftest.err; then
2302           cat conftest.err >&AS_MESSAGE_LOG_FD
2303         # Otherwise, if the output was created with a 0 exit code from
2304         # the compiler, it worked.
2305         elif test -f libconftest.dylib && test $_lt_result -eq 0; then
2306           lt_cv_apple_cc_single_mod=yes
2307         else
2308           cat conftest.err >&AS_MESSAGE_LOG_FD
2309         fi
2310         rm -rf libconftest.dylib*
2311         rm -f conftest.*
2312       fi])
2313
2314     AC_CACHE_CHECK([for -exported_symbols_list linker flag],
2315       [lt_cv_ld_exported_symbols_list],
2316       [lt_cv_ld_exported_symbols_list=no
2317       save_LDFLAGS=$LDFLAGS
2318       echo "_main" > conftest.sym
2319       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
2320       AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2321         [lt_cv_ld_exported_symbols_list=yes],
2322         [lt_cv_ld_exported_symbols_list=no])
2323         LDFLAGS="$save_LDFLAGS"
2324     ])
2325
2326     AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
2327       [lt_cv_ld_force_load=no
2328       cat > conftest.c << _LT_EOF
2329 int forced_loaded() { return 2;}
2330 _LT_EOF
2331       echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
2332       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
2333       echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
2334       $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
2335       echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
2336       $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
2337       cat > conftest.c << _LT_EOF
2338 int main() { return 0;}
2339 _LT_EOF
2340       echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
2341       $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
2342       _lt_result=$?
2343       if test -s conftest.err && $GREP force_load conftest.err; then
2344         cat conftest.err >&AS_MESSAGE_LOG_FD
2345       elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
2346         lt_cv_ld_force_load=yes
2347       else
2348         cat conftest.err >&AS_MESSAGE_LOG_FD
2349       fi
2350         rm -f conftest.err libconftest.a conftest conftest.c
2351         rm -rf conftest.dSYM
2352     ])
2353     case $host_os in
2354     rhapsody* | darwin1.[[012]])
2355       _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
2356     darwin1.*)
2357       _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2358     darwin*) # darwin 5.x on
2359       # if running on 10.5 or later, the deployment target defaults
2360       # to the OS version, if on x86, and 10.4, the deployment
2361       # target defaults to 10.4. Don't you love it?
2362       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
2363         10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
2364           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2365         10.[[012]]*)
2366           _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2367         10.*)
2368           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2369       esac
2370     ;;
2371   esac
2372     if test "$lt_cv_apple_cc_single_mod" = "yes"; then
2373       _lt_dar_single_mod='$single_module'
2374     fi
2375     if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
2376       _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
2377     else
2378       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
2379     fi
2380     if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
2381       _lt_dsymutil='~$DSYMUTIL $lib || :'
2382     else
2383       _lt_dsymutil=
2384     fi
2385     ;;
2386   esac
2387 ])
2388
2389
2390 # _LT_DARWIN_LINKER_FEATURES([TAG])
2391 # ---------------------------------
2392 # Checks for linker and compiler features on darwin
2393 m4_defun([_LT_DARWIN_LINKER_FEATURES],
2394 [
2395   m4_require([_LT_REQUIRED_DARWIN_CHECKS])
2396   _LT_TAGVAR(archive_cmds_need_lc, $1)=no
2397   _LT_TAGVAR(hardcode_direct, $1)=no
2398   _LT_TAGVAR(hardcode_automatic, $1)=yes
2399   _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2400   if test "$lt_cv_ld_force_load" = "yes"; then
2401     _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
2402     m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
2403                   [FC],  [_LT_TAGVAR(compiler_needs_object, $1)=yes])
2404   else
2405     _LT_TAGVAR(whole_archive_flag_spec, $1)=''
2406   fi
2407   _LT_TAGVAR(link_all_deplibs, $1)=yes
2408   _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
2409   case $cc_basename in
2410      ifort*) _lt_dar_can_shared=yes ;;
2411      *) _lt_dar_can_shared=$GCC ;;
2412   esac
2413   if test "$_lt_dar_can_shared" = "yes"; then
2414     output_verbose_link_cmd=func_echo_all
2415     _LT_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}"
2416     _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
2417     _LT_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}"
2418     _LT_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}"
2419     m4_if([$1], [CXX],
2420 [   if test "$lt_cv_apple_cc_single_mod" != "yes"; then
2421       _LT_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}"
2422       _LT_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}"
2423     fi
2424 ],[])
2425   else
2426   _LT_TAGVAR(ld_shlibs, $1)=no
2427   fi
2428 ])
2429
2430 # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
2431 # ----------------------------------
2432 # Links a minimal program and checks the executable
2433 # for the system default hardcoded library path. In most cases,
2434 # this is /usr/lib:/lib, but when the MPI compilers are used
2435 # the location of the communication and MPI libs are included too.
2436 # If we don't find anything, use the default library path according
2437 # to the aix ld manual.
2438 # Store the results from the different compilers for each TAGNAME.
2439 # Allow to override them for all tags through lt_cv_aix_libpath.
2440 m4_defun([_LT_SYS_MODULE_PATH_AIX],
2441 [m4_require([_LT_DECL_SED])dnl
2442 if test "${lt_cv_aix_libpath+set}" = set; then
2443   aix_libpath=$lt_cv_aix_libpath
2444 else
2445   AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
2446   [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
2447   lt_aix_libpath_sed='[
2448       /Import File Strings/,/^$/ {
2449           /^0/ {
2450               s/^0  *\([^ ]*\) *$/\1/
2451               p
2452           }
2453       }]'
2454   _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2455   # Check for a 64-bit object if we didn't find anything.
2456   if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
2457     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2458   fi],[])
2459   if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
2460     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
2461   fi
2462   ])
2463   aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
2464 fi
2465 ])# _LT_SYS_MODULE_PATH_AIX
2466
2467
2468 # _LT_SHELL_INIT(ARG)
2469 # -------------------
2470 m4_define([_LT_SHELL_INIT],
2471 [m4_divert_text([M4SH-INIT], [$1
2472 ])])# _LT_SHELL_INIT
2473
2474
2475
2476 # _LT_PROG_ECHO_BACKSLASH
2477 # -----------------------
2478 # Find how we can fake an echo command that does not interpret backslash.
2479 # In particular, with Autoconf 2.60 or later we add some code to the start
2480 # of the generated configure script which will find a shell with a builtin
2481 # printf (which we can use as an echo command).
2482 m4_defun([_LT_PROG_ECHO_BACKSLASH],
2483 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
2484 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
2485 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
2486
2487 AC_MSG_CHECKING([how to print strings])
2488 # Test print first, because it will be a builtin if present.
2489 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
2490    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
2491   ECHO='print -r --'
2492 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
2493   ECHO='printf %s\n'
2494 else
2495   # Use this function as a fallback that always works.
2496   func_fallback_echo ()
2497   {
2498     eval 'cat <<_LTECHO_EOF
2499 $[]1
2500 _LTECHO_EOF'
2501   }
2502   ECHO='func_fallback_echo'
2503 fi
2504
2505 # func_echo_all arg...
2506 # Invoke $ECHO with all args, space-separated.
2507 func_echo_all ()
2508 {
2509     $ECHO "$*" 
2510 }
2511
2512 case "$ECHO" in
2513   printf*) AC_MSG_RESULT([printf]) ;;
2514   print*) AC_MSG_RESULT([print -r]) ;;
2515   *) AC_MSG_RESULT([cat]) ;;
2516 esac
2517
2518 m4_ifdef([_AS_DETECT_SUGGESTED],
2519 [_AS_DETECT_SUGGESTED([
2520   test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
2521     ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
2522     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
2523     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
2524     PATH=/empty FPATH=/empty; export PATH FPATH
2525     test "X`printf %s $ECHO`" = "X$ECHO" \
2526       || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
2527
2528 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
2529 _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
2530 ])# _LT_PROG_ECHO_BACKSLASH
2531
2532
2533 # _LT_WITH_SYSROOT
2534 # ----------------
2535 AC_DEFUN([_LT_WITH_SYSROOT],
2536 [AC_MSG_CHECKING([for sysroot])
2537 AC_ARG_WITH([sysroot],
2538 [  --with-sysroot[=DIR] Search for dependent libraries within DIR
2539                         (or the compiler's sysroot if not specified).],
2540 [], [with_sysroot=no])
2541
2542 dnl lt_sysroot will always be passed unquoted.  We quote it here
2543 dnl in case the user passed a directory name.
2544 lt_sysroot=
2545 case ${with_sysroot} in #(
2546  yes)
2547    if test "$GCC" = yes; then
2548      lt_sysroot=`$CC --print-sysroot 2>/dev/null`
2549    fi
2550    ;; #(
2551  /*)
2552    lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
2553    ;; #(
2554  no|'')
2555    ;; #(
2556  *)
2557    AC_MSG_RESULT([${with_sysroot}])
2558    AC_MSG_ERROR([The sysroot must be an absolute path.])
2559    ;;
2560 esac
2561
2562  AC_MSG_RESULT([${lt_sysroot:-no}])
2563 _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
2564 [dependent libraries, and in which our libraries should be installed.])])
2565
2566 # _LT_ENABLE_LOCK
2567 # ---------------
2568 m4_defun([_LT_ENABLE_LOCK],
2569 [AC_ARG_ENABLE([libtool-lock],
2570   [AS_HELP_STRING([--disable-libtool-lock],
2571     [avoid locking (might break parallel builds)])])
2572 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
2573
2574 # Some flags need to be propagated to the compiler or linker for good
2575 # libtool support.
2576 case $host in
2577 ia64-*-hpux*)
2578   # Find out which ABI we are using.
2579   echo 'int i;' > conftest.$ac_ext
2580   if AC_TRY_EVAL(ac_compile); then
2581     case `/usr/bin/file conftest.$ac_objext` in
2582       *ELF-32*)
2583         HPUX_IA64_MODE="32"
2584         ;;
2585       *ELF-64*)
2586         HPUX_IA64_MODE="64"
2587         ;;
2588     esac
2589   fi
2590   rm -rf conftest*
2591   ;;
2592 *-*-irix6*)
2593   # Find out which ABI we are using.
2594   echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
2595   if AC_TRY_EVAL(ac_compile); then
2596     if test "$lt_cv_prog_gnu_ld" = yes; then
2597       case `/usr/bin/file conftest.$ac_objext` in
2598         *32-bit*)
2599           LD="${LD-ld} -melf32bsmip"
2600           ;;
2601         *N32*)
2602           LD="${LD-ld} -melf32bmipn32"
2603           ;;
2604         *64-bit*)
2605           LD="${LD-ld} -melf64bmip"
2606         ;;
2607       esac
2608     else
2609       case `/usr/bin/file conftest.$ac_objext` in
2610         *32-bit*)
2611           LD="${LD-ld} -32"
2612           ;;
2613         *N32*)
2614           LD="${LD-ld} -n32"
2615           ;;
2616         *64-bit*)
2617           LD="${LD-ld} -64"
2618           ;;
2619       esac
2620     fi
2621   fi
2622   rm -rf conftest*
2623   ;;
2624
2625 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
2626 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
2627   # Find out which ABI we are using.
2628   echo 'int i;' > conftest.$ac_ext
2629   if AC_TRY_EVAL(ac_compile); then
2630     case `/usr/bin/file conftest.o` in
2631       *32-bit*)
2632         case $host in
2633           x86_64-*kfreebsd*-gnu)
2634             LD="${LD-ld} -m elf_i386_fbsd"
2635             ;;
2636           x86_64-*linux*)
2637             LD="${LD-ld} -m elf_i386"
2638             ;;
2639           ppc64-*linux*|powerpc64-*linux*)
2640             LD="${LD-ld} -m elf32ppclinux"
2641             ;;
2642           s390x-*linux*)
2643             LD="${LD-ld} -m elf_s390"
2644             ;;
2645           sparc64-*linux*)
2646             LD="${LD-ld} -m elf32_sparc"
2647             ;;
2648         esac
2649         ;;
2650       *64-bit*)
2651         case $host in
2652           x86_64-*kfreebsd*-gnu)
2653             LD="${LD-ld} -m elf_x86_64_fbsd"
2654             ;;
2655           x86_64-*linux*)
2656             LD="${LD-ld} -m elf_x86_64"
2657             ;;
2658           ppc*-*linux*|powerpc*-*linux*)
2659             LD="${LD-ld} -m elf64ppc"
2660             ;;
2661           s390*-*linux*|s390*-*tpf*)
2662             LD="${LD-ld} -m elf64_s390"
2663             ;;
2664           sparc*-*linux*)
2665             LD="${LD-ld} -m elf64_sparc"
2666             ;;
2667         esac
2668         ;;
2669     esac
2670   fi
2671   rm -rf conftest*
2672   ;;
2673
2674 *-*-sco3.2v5*)
2675   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2676   SAVE_CFLAGS="$CFLAGS"
2677   CFLAGS="$CFLAGS -belf"
2678   AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
2679     [AC_LANG_PUSH(C)
2680      AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
2681      AC_LANG_POP])
2682   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2683     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2684     CFLAGS="$SAVE_CFLAGS"
2685   fi
2686   ;;
2687 *-*solaris*)
2688   # Find out which ABI we are using.
2689   echo 'int i;' > conftest.$ac_ext
2690   if AC_TRY_EVAL(ac_compile); then
2691     case `/usr/bin/file conftest.o` in
2692     *64-bit*)
2693       case $lt_cv_prog_gnu_ld in
2694       yes*)
2695         case $host in
2696         i?86-*-solaris*)
2697           LD="${LD-ld} -m elf_x86_64"
2698           ;;
2699         sparc*-*-solaris*)
2700           LD="${LD-ld} -m elf64_sparc"
2701           ;;
2702         esac
2703         # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
2704         if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
2705           LD="${LD-ld}_sol2"
2706         fi
2707         ;;
2708       *)
2709         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
2710           LD="${LD-ld} -64"
2711         fi
2712         ;;
2713       esac
2714       ;;
2715     esac
2716   fi
2717   rm -rf conftest*
2718   ;;
2719 esac
2720
2721 need_locks="$enable_libtool_lock"
2722 ])# _LT_ENABLE_LOCK
2723
2724
2725 # _LT_PROG_AR
2726 # -----------
2727 m4_defun([_LT_PROG_AR],
2728 [AC_CHECK_TOOLS(AR, [ar], false)
2729 : ${AR=ar}
2730 : ${AR_FLAGS=cru}
2731 _LT_DECL([], [AR], [1], [The archiver])
2732 _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
2733
2734 AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
2735   [lt_cv_ar_at_file=no
2736    AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
2737      [echo conftest.$ac_objext > conftest.lst
2738       lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
2739       AC_TRY_EVAL([lt_ar_try])
2740       if test "$ac_status" -eq 0; then
2741         # Ensure the archiver fails upon bogus file names.
2742         rm -f conftest.$ac_objext libconftest.a
2743         AC_TRY_EVAL([lt_ar_try])
2744         if test "$ac_status" -ne 0; then
2745           lt_cv_ar_at_file=@
2746         fi
2747       fi
2748       rm -f conftest.* libconftest.a
2749      ])
2750   ])
2751
2752 if test "x$lt_cv_ar_at_file" = xno; then
2753   archiver_list_spec=
2754 else
2755   archiver_list_spec=$lt_cv_ar_at_file
2756 fi
2757 _LT_DECL([], [archiver_list_spec], [1],
2758   [How to feed a file listing to the archiver])
2759 ])# _LT_PROG_AR
2760
2761
2762 # _LT_CMD_OLD_ARCHIVE
2763 # -------------------
2764 m4_defun([_LT_CMD_OLD_ARCHIVE],
2765 [_LT_PROG_AR
2766
2767 AC_CHECK_TOOL(STRIP, strip, :)
2768 test -z "$STRIP" && STRIP=:
2769 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
2770
2771 AC_CHECK_TOOL(RANLIB, ranlib, :)
2772 test -z "$RANLIB" && RANLIB=:
2773 _LT_DECL([], [RANLIB], [1],
2774     [Commands used to install an old-style archive])
2775
2776 # Determine commands to create old-style static archives.
2777 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
2778 old_postinstall_cmds='chmod 644 $oldlib'
2779 old_postuninstall_cmds=
2780
2781 if test -n "$RANLIB"; then
2782   case $host_os in
2783   openbsd*)
2784     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
2785     ;;
2786   *)
2787     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
2788     ;;
2789   esac
2790   old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
2791 fi
2792
2793 case $host_os in
2794   darwin*)
2795     lock_old_archive_extraction=yes ;;
2796   *)
2797     lock_old_archive_extraction=no ;;
2798 esac
2799 _LT_DECL([], [old_postinstall_cmds], [2])
2800 _LT_DECL([], [old_postuninstall_cmds], [2])
2801 _LT_TAGDECL([], [old_archive_cmds], [2],
2802     [Commands used to build an old-style archive])
2803 _LT_DECL([], [lock_old_archive_extraction], [0],
2804     [Whether to use a lock for old archive extraction])
2805 ])# _LT_CMD_OLD_ARCHIVE
2806
2807
2808 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2809 #               [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
2810 # ----------------------------------------------------------------
2811 # Check whether the given compiler option works
2812 AC_DEFUN([_LT_COMPILER_OPTION],
2813 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2814 m4_require([_LT_DECL_SED])dnl
2815 AC_CACHE_CHECK([$1], [$2],
2816   [$2=no
2817    m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
2818    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2819    lt_compiler_flag="$3"
2820    # Insert the option either (1) after the last *FLAGS variable, or
2821    # (2) before a word containing "conftest.", or (3) at the end.
2822    # Note that $ac_compile itself does not contain backslashes and begins
2823    # with a dollar sign (not a hyphen), so the echo should work correctly.
2824    # The option is referenced via a variable to avoid confusing sed.
2825    lt_compile=`echo "$ac_compile" | $SED \
2826    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2827    -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2828    -e 's:$: $lt_compiler_flag:'`
2829    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2830    (eval "$lt_compile" 2>conftest.err)
2831    ac_status=$?
2832    cat conftest.err >&AS_MESSAGE_LOG_FD
2833    echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2834    if (exit $ac_status) && test -s "$ac_outfile"; then
2835      # The compiler can only warn and ignore the option if not recognized
2836      # So say no if there are warnings other than the usual output.
2837      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
2838      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2839      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2840        $2=yes
2841      fi
2842    fi
2843    $RM conftest*
2844 ])
2845
2846 if test x"[$]$2" = xyes; then
2847     m4_if([$5], , :, [$5])
2848 else
2849     m4_if([$6], , :, [$6])
2850 fi
2851 ])# _LT_COMPILER_OPTION
2852
2853 # Old name:
2854 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2855 dnl aclocal-1.4 backwards compatibility:
2856 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2857
2858
2859 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2860 #                  [ACTION-SUCCESS], [ACTION-FAILURE])
2861 # ----------------------------------------------------
2862 # Check whether the given linker option works
2863 AC_DEFUN([_LT_LINKER_OPTION],
2864 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2865 m4_require([_LT_DECL_SED])dnl
2866 AC_CACHE_CHECK([$1], [$2],
2867   [$2=no
2868    save_LDFLAGS="$LDFLAGS"
2869    LDFLAGS="$LDFLAGS $3"
2870    echo "$lt_simple_link_test_code" > conftest.$ac_ext
2871    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2872      # The linker can only warn and ignore the option if not recognized
2873      # So say no if there are warnings
2874      if test -s conftest.err; then
2875        # Append any errors to the config.log.
2876        cat conftest.err 1>&AS_MESSAGE_LOG_FD
2877        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
2878        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2879        if diff conftest.exp conftest.er2 >/dev/null; then
2880          $2=yes
2881        fi
2882      else
2883        $2=yes
2884      fi
2885    fi
2886    $RM -r conftest*
2887    LDFLAGS="$save_LDFLAGS"
2888 ])
2889
2890 if test x"[$]$2" = xyes; then
2891     m4_if([$4], , :, [$4])
2892 else
2893     m4_if([$5], , :, [$5])
2894 fi
2895 ])# _LT_LINKER_OPTION
2896
2897 # Old name:
2898 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2899 dnl aclocal-1.4 backwards compatibility:
2900 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2901
2902
2903 # LT_CMD_MAX_LEN
2904 #---------------
2905 AC_DEFUN([LT_CMD_MAX_LEN],
2906 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2907 # find the maximum length of command line arguments
2908 AC_MSG_CHECKING([the maximum length of command line arguments])
2909 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2910   i=0
2911   teststring="ABCD"
2912
2913   case $build_os in
2914   msdosdjgpp*)
2915     # On DJGPP, this test can blow up pretty badly due to problems in libc
2916     # (any single argument exceeding 2000 bytes causes a buffer overrun
2917     # during glob expansion).  Even if it were fixed, the result of this
2918     # check would be larger than it should be.
2919     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
2920     ;;
2921
2922   gnu*)
2923     # Under GNU Hurd, this test is not required because there is
2924     # no limit to the length of command line arguments.
2925     # Libtool will interpret -1 as no limit whatsoever
2926     lt_cv_sys_max_cmd_len=-1;
2927     ;;
2928
2929   cygwin* | mingw* | cegcc*)
2930     # On Win9x/ME, this test blows up -- it succeeds, but takes
2931     # about 5 minutes as the teststring grows exponentially.
2932     # Worse, since 9x/ME are not pre-emptively multitasking,
2933     # you end up with a "frozen" computer, even though with patience
2934     # the test eventually succeeds (with a max line length of 256k).
2935     # Instead, let's just punt: use the minimum linelength reported by
2936     # all of the supported platforms: 8192 (on NT/2K/XP).
2937     lt_cv_sys_max_cmd_len=8192;
2938     ;;
2939
2940   mint*)
2941     # On MiNT this can take a long time and run out of memory.
2942     lt_cv_sys_max_cmd_len=8192;
2943     ;;
2944
2945   amigaos*)
2946     # On AmigaOS with pdksh, this test takes hours, literally.
2947     # So we just punt and use a minimum line length of 8192.
2948     lt_cv_sys_max_cmd_len=8192;
2949     ;;
2950
2951   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
2952     # This has been around since 386BSD, at least.  Likely further.
2953     if test -x /sbin/sysctl; then
2954       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2955     elif test -x /usr/sbin/sysctl; then
2956       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2957     else
2958       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
2959     fi
2960     # And add a safety zone
2961     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2962     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2963     ;;
2964
2965   interix*)
2966     # We know the value 262144 and hardcode it with a safety zone (like BSD)
2967     lt_cv_sys_max_cmd_len=196608
2968     ;;
2969
2970   os2*)
2971     # The test takes a long time on OS/2.
2972     lt_cv_sys_max_cmd_len=8192
2973     ;;
2974
2975   osf*)
2976     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2977     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2978     # nice to cause kernel panics so lets avoid the loop below.
2979     # First set a reasonable default.
2980     lt_cv_sys_max_cmd_len=16384
2981     #
2982     if test -x /sbin/sysconfig; then
2983       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2984         *1*) lt_cv_sys_max_cmd_len=-1 ;;
2985       esac
2986     fi
2987     ;;
2988   sco3.2v5*)
2989     lt_cv_sys_max_cmd_len=102400
2990     ;;
2991   sysv5* | sco5v6* | sysv4.2uw2*)
2992     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2993     if test -n "$kargmax"; then
2994       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[         ]]//'`
2995     else
2996       lt_cv_sys_max_cmd_len=32768
2997     fi
2998     ;;
2999   *)
3000     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
3001     if test -n "$lt_cv_sys_max_cmd_len"; then
3002       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
3003       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
3004     else
3005       # Make teststring a little bigger before we do anything with it.
3006       # a 1K string should be a reasonable start.
3007       for i in 1 2 3 4 5 6 7 8 ; do
3008         teststring=$teststring$teststring
3009       done
3010       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
3011       # If test is not a shell built-in, we'll probably end up computing a
3012       # maximum length that is only half of the actual maximum length, but
3013       # we can't tell.
3014       while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
3015                  = "X$teststring$teststring"; } >/dev/null 2>&1 &&
3016               test $i != 17 # 1/2 MB should be enough
3017       do
3018         i=`expr $i + 1`
3019         teststring=$teststring$teststring
3020       done
3021       # Only check the string length outside the loop.
3022       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
3023       teststring=
3024       # Add a significant safety factor because C++ compilers can tack on
3025       # massive amounts of additional arguments before passing them to the
3026       # linker.  It appears as though 1/2 is a usable value.
3027       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
3028     fi
3029     ;;
3030   esac
3031 ])
3032 if test -n $lt_cv_sys_max_cmd_len ; then
3033   AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
3034 else
3035   AC_MSG_RESULT(none)
3036 fi
3037 max_cmd_len=$lt_cv_sys_max_cmd_len
3038 _LT_DECL([], [max_cmd_len], [0],
3039     [What is the maximum length of a command?])
3040 ])# LT_CMD_MAX_LEN
3041
3042 # Old name:
3043 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
3044 dnl aclocal-1.4 backwards compatibility:
3045 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
3046
3047
3048 # _LT_HEADER_DLFCN
3049 # ----------------
3050 m4_defun([_LT_HEADER_DLFCN],
3051 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
3052 ])# _LT_HEADER_DLFCN
3053
3054
3055 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
3056 #                      ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
3057 # ----------------------------------------------------------------
3058 m4_defun([_LT_TRY_DLOPEN_SELF],
3059 [m4_require([_LT_HEADER_DLFCN])dnl
3060 if test "$cross_compiling" = yes; then :
3061   [$4]
3062 else
3063   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
3064   lt_status=$lt_dlunknown
3065   cat > conftest.$ac_ext <<_LT_EOF
3066 [#line $LINENO "configure"
3067 #include "confdefs.h"
3068
3069 #if HAVE_DLFCN_H
3070 #include <dlfcn.h>
3071 #endif
3072
3073 #include <stdio.h>
3074
3075 #ifdef RTLD_GLOBAL
3076 #  define LT_DLGLOBAL           RTLD_GLOBAL
3077 #else
3078 #  ifdef DL_GLOBAL
3079 #    define LT_DLGLOBAL         DL_GLOBAL
3080 #  else
3081 #    define LT_DLGLOBAL         0
3082 #  endif
3083 #endif
3084
3085 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
3086    find out it does not work in some platform. */
3087 #ifndef LT_DLLAZY_OR_NOW
3088 #  ifdef RTLD_LAZY
3089 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
3090 #  else
3091 #    ifdef DL_LAZY
3092 #      define LT_DLLAZY_OR_NOW          DL_LAZY
3093 #    else
3094 #      ifdef RTLD_NOW
3095 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
3096 #      else
3097 #        ifdef DL_NOW
3098 #          define LT_DLLAZY_OR_NOW      DL_NOW
3099 #        else
3100 #          define LT_DLLAZY_OR_NOW      0
3101 #        endif
3102 #      endif
3103 #    endif
3104 #  endif
3105 #endif
3106
3107 /* When -fvisbility=hidden is used, assume the code has been annotated
3108    correspondingly for the symbols needed.  */
3109 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
3110 int fnord () __attribute__((visibility("default")));
3111 #endif
3112
3113 int fnord () { return 42; }
3114 int main ()
3115 {
3116   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
3117   int status = $lt_dlunknown;
3118
3119   if (self)
3120     {
3121       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
3122       else
3123         {
3124           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
3125           else puts (dlerror ());
3126         }
3127       /* dlclose (self); */
3128     }
3129   else
3130     puts (dlerror ());
3131
3132   return status;
3133 }]
3134 _LT_EOF
3135   if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
3136     (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
3137     lt_status=$?
3138     case x$lt_status in
3139       x$lt_dlno_uscore) $1 ;;
3140       x$lt_dlneed_uscore) $2 ;;
3141       x$lt_dlunknown|x*) $3 ;;
3142     esac
3143   else :
3144     # compilation failed
3145     $3
3146   fi
3147 fi
3148 rm -fr conftest*
3149 ])# _LT_TRY_DLOPEN_SELF
3150
3151
3152 # LT_SYS_DLOPEN_SELF
3153 # ------------------
3154 AC_DEFUN([LT_SYS_DLOPEN_SELF],
3155 [m4_require([_LT_HEADER_DLFCN])dnl
3156 if test "x$enable_dlopen" != xyes; then
3157   enable_dlopen=unknown
3158   enable_dlopen_self=unknown
3159   enable_dlopen_self_static=unknown
3160 else
3161   lt_cv_dlopen=no
3162   lt_cv_dlopen_libs=
3163
3164   case $host_os in
3165   beos*)
3166     lt_cv_dlopen="load_add_on"
3167     lt_cv_dlopen_libs=
3168     lt_cv_dlopen_self=yes
3169     ;;
3170
3171   mingw* | pw32* | cegcc*)
3172     lt_cv_dlopen="LoadLibrary"
3173     lt_cv_dlopen_libs=
3174     ;;
3175
3176   cygwin*)
3177     lt_cv_dlopen="dlopen"
3178     lt_cv_dlopen_libs=
3179     ;;
3180
3181   darwin*)
3182   # if libdl is installed we need to link against it
3183     AC_CHECK_LIB([dl], [dlopen],
3184                 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
3185     lt_cv_dlopen="dyld"
3186     lt_cv_dlopen_libs=
3187     lt_cv_dlopen_self=yes
3188     ])
3189     ;;
3190
3191   *)
3192     AC_CHECK_FUNC([shl_load],
3193           [lt_cv_dlopen="shl_load"],
3194       [AC_CHECK_LIB([dld], [shl_load],
3195             [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
3196         [AC_CHECK_FUNC([dlopen],
3197               [lt_cv_dlopen="dlopen"],
3198           [AC_CHECK_LIB([dl], [dlopen],
3199                 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
3200             [AC_CHECK_LIB([svld], [dlopen],
3201                   [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
3202               [AC_CHECK_LIB([dld], [dld_link],
3203                     [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
3204               ])
3205             ])
3206           ])
3207         ])
3208       ])
3209     ;;
3210   esac
3211
3212   if test "x$lt_cv_dlopen" != xno; then
3213     enable_dlopen=yes
3214   else
3215     enable_dlopen=no
3216   fi
3217
3218   case $lt_cv_dlopen in
3219   dlopen)
3220     save_CPPFLAGS="$CPPFLAGS"
3221     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
3222
3223     save_LDFLAGS="$LDFLAGS"
3224     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
3225
3226     save_LIBS="$LIBS"
3227     LIBS="$lt_cv_dlopen_libs $LIBS"
3228
3229     AC_CACHE_CHECK([whether a program can dlopen itself],
3230           lt_cv_dlopen_self, [dnl
3231           _LT_TRY_DLOPEN_SELF(
3232             lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
3233             lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
3234     ])
3235
3236     if test "x$lt_cv_dlopen_self" = xyes; then
3237       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
3238       AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
3239           lt_cv_dlopen_self_static, [dnl
3240           _LT_TRY_DLOPEN_SELF(
3241             lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
3242             lt_cv_dlopen_self_static=no,  lt_cv_dlopen_self_static=cross)
3243       ])
3244     fi
3245
3246     CPPFLAGS="$save_CPPFLAGS"
3247     LDFLAGS="$save_LDFLAGS"
3248     LIBS="$save_LIBS"
3249     ;;
3250   esac
3251
3252   case $lt_cv_dlopen_self in
3253   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
3254   *) enable_dlopen_self=unknown ;;
3255   esac
3256
3257   case $lt_cv_dlopen_self_static in
3258   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
3259   *) enable_dlopen_self_static=unknown ;;
3260   esac
3261 fi
3262 _LT_DECL([dlopen_support], [enable_dlopen], [0],
3263          [Whether dlopen is supported])
3264 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
3265          [Whether dlopen of programs is supported])
3266 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
3267          [Whether dlopen of statically linked programs is supported])
3268 ])# LT_SYS_DLOPEN_SELF
3269
3270 # Old name:
3271 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
3272 dnl aclocal-1.4 backwards compatibility:
3273 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
3274
3275
3276 # _LT_COMPILER_C_O([TAGNAME])
3277 # ---------------------------
3278 # Check to see if options -c and -o are simultaneously supported by compiler.
3279 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
3280 m4_defun([_LT_COMPILER_C_O],
3281 [m4_require([_LT_DECL_SED])dnl
3282 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3283 m4_require([_LT_TAG_COMPILER])dnl
3284 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
3285   [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
3286   [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
3287    $RM -r conftest 2>/dev/null
3288    mkdir conftest
3289    cd conftest
3290    mkdir out
3291    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
3292
3293    lt_compiler_flag="-o out/conftest2.$ac_objext"
3294    # Insert the option either (1) after the last *FLAGS variable, or
3295    # (2) before a word containing "conftest.", or (3) at the end.
3296    # Note that $ac_compile itself does not contain backslashes and begins
3297    # with a dollar sign (not a hyphen), so the echo should work correctly.
3298    lt_compile=`echo "$ac_compile" | $SED \
3299    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
3300    -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
3301    -e 's:$: $lt_compiler_flag:'`
3302    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
3303    (eval "$lt_compile" 2>out/conftest.err)
3304    ac_status=$?
3305    cat out/conftest.err >&AS_MESSAGE_LOG_FD
3306    echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
3307    if (exit $ac_status) && test -s out/conftest2.$ac_objext
3308    then
3309      # The compiler can only warn and ignore the option if not recognized
3310      # So say no if there are warnings
3311      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
3312      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
3313      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
3314        _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
3315      fi
3316    fi
3317    chmod u+w . 2>&AS_MESSAGE_LOG_FD
3318    $RM conftest*
3319    # SGI C++ compiler will create directory out/ii_files/ for
3320    # template instantiation
3321    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
3322    $RM out/* && rmdir out
3323    cd ..
3324    $RM -r conftest
3325    $RM conftest*
3326 ])
3327 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
3328         [Does compiler simultaneously support -c and -o options?])
3329 ])# _LT_COMPILER_C_O
3330
3331
3332 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
3333 # ----------------------------------
3334 # Check to see if we can do hard links to lock some files if needed
3335 m4_defun([_LT_COMPILER_FILE_LOCKS],
3336 [m4_require([_LT_ENABLE_LOCK])dnl
3337 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3338 _LT_COMPILER_C_O([$1])
3339
3340 hard_links="nottested"
3341 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
3342   # do not overwrite the value of need_locks provided by the user
3343   AC_MSG_CHECKING([if we can lock with hard links])
3344   hard_links=yes
3345   $RM conftest*
3346   ln conftest.a conftest.b 2>/dev/null && hard_links=no
3347   touch conftest.a
3348   ln conftest.a conftest.b 2>&5 || hard_links=no
3349   ln conftest.a conftest.b 2>/dev/null && hard_links=no
3350   AC_MSG_RESULT([$hard_links])
3351   if test "$hard_links" = no; then
3352     AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
3353     need_locks=warn
3354   fi
3355 else
3356   need_locks=no
3357 fi
3358 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
3359 ])# _LT_COMPILER_FILE_LOCKS
3360
3361
3362 # _LT_CHECK_OBJDIR
3363 # ----------------
3364 m4_defun([_LT_CHECK_OBJDIR],
3365 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
3366 [rm -f .libs 2>/dev/null
3367 mkdir .libs 2>/dev/null
3368 if test -d .libs; then
3369   lt_cv_objdir=.libs
3370 else
3371   # MS-DOS does not allow filenames that begin with a dot.
3372   lt_cv_objdir=_libs
3373 fi
3374 rmdir .libs 2>/dev/null])
3375 objdir=$lt_cv_objdir
3376 _LT_DECL([], [objdir], [0],
3377          [The name of the directory that contains temporary libtool files])dnl
3378 m4_pattern_allow([LT_OBJDIR])dnl
3379 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
3380   [Define to the sub-directory in which libtool stores uninstalled libraries.])
3381 ])# _LT_CHECK_OBJDIR
3382
3383
3384 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
3385 # --------------------------------------
3386 # Check hardcoding attributes.
3387 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
3388 [AC_MSG_CHECKING([how to hardcode library paths into programs])
3389 _LT_TAGVAR(hardcode_action, $1)=
3390 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
3391    test -n "$_LT_TAGVAR(runpath_var, $1)" ||
3392    test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
3393
3394   # We can hardcode non-existent directories.
3395   if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
3396      # If the only mechanism to avoid hardcoding is shlibpath_var, we
3397      # have to relink, otherwise we might link with an installed library
3398      # when we should be linking with a yet-to-be-installed one
3399      ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
3400      test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
3401     # Linking always hardcodes the temporary library directory.
3402     _LT_TAGVAR(hardcode_action, $1)=relink
3403   else
3404     # We can link without hardcoding, and we can hardcode nonexisting dirs.
3405     _LT_TAGVAR(hardcode_action, $1)=immediate
3406   fi
3407 else
3408   # We cannot hardcode anything, or else we can only hardcode existing
3409   # directories.
3410   _LT_TAGVAR(hardcode_action, $1)=unsupported
3411 fi
3412 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
3413
3414 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
3415    test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
3416   # Fast installation is not supported
3417   enable_fast_install=no
3418 elif test "$shlibpath_overrides_runpath" = yes ||
3419      test "$enable_shared" = no; then
3420   # Fast installation is not necessary
3421   enable_fast_install=needless
3422 fi
3423 _LT_TAGDECL([], [hardcode_action], [0],
3424     [How to hardcode a shared library path into an executable])
3425 ])# _LT_LINKER_HARDCODE_LIBPATH
3426
3427
3428 # _LT_CMD_STRIPLIB
3429 # ----------------
3430 m4_defun([_LT_CMD_STRIPLIB],
3431 [m4_require([_LT_DECL_EGREP])
3432 striplib=
3433 old_striplib=
3434 AC_MSG_CHECKING([whether stripping libraries is possible])
3435 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
3436   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
3437   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
3438   AC_MSG_RESULT([yes])
3439 else
3440 # FIXME - insert some real tests, host_os isn't really good enough
3441   case $host_os in
3442   darwin*)
3443     if test -n "$STRIP" ; then
3444       striplib="$STRIP -x"
3445       old_striplib="$STRIP -S"
3446       AC_MSG_RESULT([yes])
3447     else
3448       AC_MSG_RESULT([no])
3449     fi
3450     ;;
3451   *)
3452     AC_MSG_RESULT([no])
3453     ;;
3454   esac
3455 fi
3456 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
3457 _LT_DECL([], [striplib], [1])
3458 ])# _LT_CMD_STRIPLIB
3459
3460
3461 # _LT_SYS_DYNAMIC_LINKER([TAG])
3462 # -----------------------------
3463 # PORTME Fill in your ld.so characteristics
3464 m4_defun([_LT_SYS_DYNAMIC_LINKER],
3465 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3466 m4_require([_LT_DECL_EGREP])dnl
3467 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3468 m4_require([_LT_DECL_OBJDUMP])dnl
3469 m4_require([_LT_DECL_SED])dnl
3470 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
3471 AC_MSG_CHECKING([dynamic linker characteristics])
3472 m4_if([$1],
3473         [], [
3474 if test "$GCC" = yes; then
3475   case $host_os in
3476     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
3477     *) lt_awk_arg="/^libraries:/" ;;
3478   esac
3479   case $host_os in
3480     mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
3481     *) lt_sed_strip_eq="s,=/,/,g" ;;
3482   esac
3483   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
3484   case $lt_search_path_spec in
3485   *\;*)
3486     # if the path contains ";" then we assume it to be the separator
3487     # otherwise default to the standard path separator (i.e. ":") - it is
3488     # assumed that no part of a normal pathname contains ";" but that should
3489     # okay in the real world where ";" in dirpaths is itself problematic.
3490     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
3491     ;;
3492   *)
3493     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
3494     ;;
3495   esac
3496   # Ok, now we have the path, separated by spaces, we can step through it
3497   # and add multilib dir if necessary.
3498   lt_tmp_lt_search_path_spec=
3499   lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
3500   for lt_sys_path in $lt_search_path_spec; do
3501     if test -d "$lt_sys_path/$lt_multi_os_dir"; then
3502       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
3503     else
3504       test -d "$lt_sys_path" && \
3505         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
3506     fi
3507   done
3508   lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
3509 BEGIN {RS=" "; FS="/|\n";} {
3510   lt_foo="";
3511   lt_count=0;
3512   for (lt_i = NF; lt_i > 0; lt_i--) {
3513     if ($lt_i != "" && $lt_i != ".") {
3514       if ($lt_i == "..") {
3515         lt_count++;
3516       } else {
3517         if (lt_count == 0) {
3518           lt_foo="/" $lt_i lt_foo;
3519         } else {
3520           lt_count--;
3521         }
3522       }
3523     }
3524   }
3525   if (lt_foo != "") { lt_freq[[lt_foo]]++; }
3526   if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
3527 }'`
3528   # AWK program above erroneously prepends '/' to C:/dos/paths
3529   # for these hosts.
3530   case $host_os in
3531     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
3532       $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
3533   esac
3534   sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
3535 else
3536   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
3537 fi])
3538 library_names_spec=
3539 libname_spec='lib$name'
3540 soname_spec=
3541 shrext_cmds=".so"
3542 postinstall_cmds=
3543 postuninstall_cmds=
3544 finish_cmds=
3545 finish_eval=
3546 shlibpath_var=
3547 shlibpath_overrides_runpath=unknown
3548 version_type=none
3549 dynamic_linker="$host_os ld.so"
3550 sys_lib_dlsearch_path_spec="/lib /usr/lib"
3551 need_lib_prefix=unknown
3552 hardcode_into_libs=no
3553
3554 # when you set need_version to no, make sure it does not cause -set_version
3555 # flags to be left without arguments
3556 need_version=unknown
3557
3558 case $host_os in
3559 aix3*)
3560   version_type=linux # correct to gnu/linux during the next big refactor
3561   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
3562   shlibpath_var=LIBPATH
3563
3564   # AIX 3 has no versioning support, so we append a major version to the name.
3565   soname_spec='${libname}${release}${shared_ext}$major'
3566   ;;
3567
3568 aix[[4-9]]*)
3569   version_type=linux # correct to gnu/linux during the next big refactor
3570   need_lib_prefix=no
3571   need_version=no
3572   hardcode_into_libs=yes
3573   if test "$host_cpu" = ia64; then
3574     # AIX 5 supports IA64
3575     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
3576     shlibpath_var=LD_LIBRARY_PATH
3577   else
3578     # With GCC up to 2.95.x, collect2 would create an import file
3579     # for dependence libraries.  The import file would start with
3580     # the line `#! .'.  This would cause the generated library to
3581     # depend on `.', always an invalid library.  This was fixed in
3582     # development snapshots of GCC prior to 3.0.
3583     case $host_os in
3584       aix4 | aix4.[[01]] | aix4.[[01]].*)
3585       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
3586            echo ' yes '
3587            echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
3588         :
3589       else
3590         can_build_shared=no
3591       fi
3592       ;;
3593     esac
3594     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
3595     # soname into executable. Probably we can add versioning support to
3596     # collect2, so additional links can be useful in future.
3597     if test "$aix_use_runtimelinking" = yes; then
3598       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
3599       # instead of lib<name>.a to let people know that these are not
3600       # typical AIX shared libraries.
3601       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3602     else
3603       # We preserve .a as extension for shared libraries through AIX4.2
3604       # and later when we are not doing run time linking.
3605       library_names_spec='${libname}${release}.a $libname.a'
3606       soname_spec='${libname}${release}${shared_ext}$major'
3607     fi
3608     shlibpath_var=LIBPATH
3609   fi
3610   ;;
3611
3612 amigaos*)
3613   case $host_cpu in
3614   powerpc)
3615     # Since July 2007 AmigaOS4 officially supports .so libraries.
3616     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
3617     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3618     ;;
3619   m68k)
3620     library_names_spec='$libname.ixlibrary $libname.a'
3621     # Create ${libname}_ixlibrary.a entries in /sys/libs.
3622     finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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'
3623     ;;
3624   esac
3625   ;;
3626
3627 beos*)
3628   library_names_spec='${libname}${shared_ext}'
3629   dynamic_linker="$host_os ld.so"
3630   shlibpath_var=LIBRARY_PATH
3631   ;;
3632
3633 bsdi[[45]]*)
3634   version_type=linux # correct to gnu/linux during the next big refactor
3635   need_version=no
3636   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3637   soname_spec='${libname}${release}${shared_ext}$major'
3638   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
3639   shlibpath_var=LD_LIBRARY_PATH
3640   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
3641   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
3642   # the default ld.so.conf also contains /usr/contrib/lib and
3643   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
3644   # libtool to hard-code these into programs
3645   ;;
3646
3647 cygwin* | mingw* | pw32* | cegcc*)
3648   version_type=windows
3649   shrext_cmds=".dll"
3650   need_version=no
3651   need_lib_prefix=no
3652
3653   case $GCC,$cc_basename in
3654   yes,*)
3655     # gcc
3656     library_names_spec='$libname.dll.a'
3657     # DLL is installed to $(libdir)/../bin by postinstall_cmds
3658     postinstall_cmds='base_file=`basename \${file}`~
3659       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3660       dldir=$destdir/`dirname \$dlpath`~
3661       test -d \$dldir || mkdir -p \$dldir~
3662       $install_prog $dir/$dlname \$dldir/$dlname~
3663       chmod a+x \$dldir/$dlname~
3664       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
3665         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
3666       fi'
3667     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3668       dlpath=$dir/\$dldll~
3669        $RM \$dlpath'
3670     shlibpath_overrides_runpath=yes
3671
3672     case $host_os in
3673     cygwin*)
3674       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
3675       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3676 m4_if([$1], [],[
3677       sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
3678       ;;
3679     mingw* | cegcc*)
3680       # MinGW DLLs use traditional 'lib' prefix
3681       soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3682       ;;
3683     pw32*)
3684       # pw32 DLLs use 'pw' prefix rather than 'lib'
3685       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3686       ;;
3687     esac
3688     dynamic_linker='Win32 ld.exe'
3689     ;;
3690
3691   *,cl*)
3692     # Native MSVC
3693     libname_spec='$name'
3694     soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3695     library_names_spec='${libname}.dll.lib'
3696
3697     case $build_os in
3698     mingw*)
3699       sys_lib_search_path_spec=
3700       lt_save_ifs=$IFS
3701       IFS=';'
3702       for lt_path in $LIB
3703       do
3704         IFS=$lt_save_ifs
3705         # Let DOS variable expansion print the short 8.3 style file name.
3706         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
3707         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
3708       done
3709       IFS=$lt_save_ifs
3710       # Convert to MSYS style.
3711       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
3712       ;;
3713     cygwin*)
3714       # Convert to unix form, then to dos form, then back to unix form
3715       # but this time dos style (no spaces!) so that the unix form looks
3716       # like /cygdrive/c/PROGRA~1:/cygdr...
3717       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
3718       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
3719       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3720       ;;
3721     *)
3722       sys_lib_search_path_spec="$LIB"
3723       if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
3724         # It is most probably a Windows format PATH.
3725         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
3726       else
3727         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3728       fi
3729       # FIXME: find the short name or the path components, as spaces are
3730       # common. (e.g. "Program Files" -> "PROGRA~1")
3731       ;;
3732     esac
3733
3734     # DLL is installed to $(libdir)/../bin by postinstall_cmds
3735     postinstall_cmds='base_file=`basename \${file}`~
3736       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3737       dldir=$destdir/`dirname \$dlpath`~
3738       test -d \$dldir || mkdir -p \$dldir~
3739       $install_prog $dir/$dlname \$dldir/$dlname'
3740     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3741       dlpath=$dir/\$dldll~
3742        $RM \$dlpath'
3743     shlibpath_overrides_runpath=yes
3744     dynamic_linker='Win32 link.exe'
3745     ;;
3746
3747   *)
3748     # Assume MSVC wrapper
3749     library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
3750     dynamic_linker='Win32 ld.exe'
3751     ;;
3752   esac
3753   # FIXME: first we should search . and the directory the executable is in
3754   shlibpath_var=PATH
3755   ;;
3756
3757 darwin* | rhapsody*)
3758   dynamic_linker="$host_os dyld"
3759   version_type=darwin
3760   need_lib_prefix=no
3761   need_version=no
3762   library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
3763   soname_spec='${libname}${release}${major}$shared_ext'
3764   shlibpath_overrides_runpath=yes
3765   shlibpath_var=DYLD_LIBRARY_PATH
3766   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3767 m4_if([$1], [],[
3768   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3769   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3770   ;;
3771
3772 dgux*)
3773   version_type=linux # correct to gnu/linux during the next big refactor
3774   need_lib_prefix=no
3775   need_version=no
3776   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
3777   soname_spec='${libname}${release}${shared_ext}$major'
3778   shlibpath_var=LD_LIBRARY_PATH
3779   ;;
3780
3781 freebsd* | dragonfly*)
3782   # DragonFly does not have aout.  When/if they implement a new
3783   # versioning mechanism, adjust this.
3784   if test -x /usr/bin/objformat; then
3785     objformat=`/usr/bin/objformat`
3786   else
3787     case $host_os in
3788     freebsd[[23]].*) objformat=aout ;;
3789     *) objformat=elf ;;
3790     esac
3791   fi
3792   version_type=freebsd-$objformat
3793   case $version_type in
3794     freebsd-elf*)
3795       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3796       need_version=no
3797       need_lib_prefix=no
3798       ;;
3799     freebsd-*)
3800       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
3801       need_version=yes
3802       ;;
3803   esac
3804   shlibpath_var=LD_LIBRARY_PATH
3805   case $host_os in
3806   freebsd2.*)
3807     shlibpath_overrides_runpath=yes
3808     ;;
3809   freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3810     shlibpath_overrides_runpath=yes
3811     hardcode_into_libs=yes
3812     ;;
3813   freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3814   freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3815     shlibpath_overrides_runpath=no
3816     hardcode_into_libs=yes
3817     ;;
3818   *) # from 4.6 on, and DragonFly
3819     shlibpath_overrides_runpath=yes
3820     hardcode_into_libs=yes
3821     ;;
3822   esac
3823   ;;
3824
3825 gnu*)
3826   version_type=linux # correct to gnu/linux during the next big refactor
3827   need_lib_prefix=no
3828   need_version=no
3829   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3830   soname_spec='${libname}${release}${shared_ext}$major'
3831   shlibpath_var=LD_LIBRARY_PATH
3832   shlibpath_overrides_runpath=no
3833   hardcode_into_libs=yes
3834   ;;
3835
3836 haiku*)
3837   version_type=linux # correct to gnu/linux during the next big refactor
3838   need_lib_prefix=no
3839   need_version=no
3840   dynamic_linker="$host_os runtime_loader"
3841   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3842   soname_spec='${libname}${release}${shared_ext}$major'
3843   shlibpath_var=LIBRARY_PATH
3844   shlibpath_overrides_runpath=yes
3845   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
3846   hardcode_into_libs=yes
3847   ;;
3848
3849 hpux9* | hpux10* | hpux11*)
3850   # Give a soname corresponding to the major version so that dld.sl refuses to
3851   # link against other versions.
3852   version_type=sunos
3853   need_lib_prefix=no
3854   need_version=no
3855   case $host_cpu in
3856   ia64*)
3857     shrext_cmds='.so'
3858     hardcode_into_libs=yes
3859     dynamic_linker="$host_os dld.so"
3860     shlibpath_var=LD_LIBRARY_PATH
3861     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3862     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3863     soname_spec='${libname}${release}${shared_ext}$major'
3864     if test "X$HPUX_IA64_MODE" = X32; then
3865       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3866     else
3867       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
3868     fi
3869     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3870     ;;
3871   hppa*64*)
3872     shrext_cmds='.sl'
3873     hardcode_into_libs=yes
3874     dynamic_linker="$host_os dld.sl"
3875     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
3876     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3877     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3878     soname_spec='${libname}${release}${shared_ext}$major'
3879     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3880     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3881     ;;
3882   *)
3883     shrext_cmds='.sl'
3884     dynamic_linker="$host_os dld.sl"
3885     shlibpath_var=SHLIB_PATH
3886     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3887     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3888     soname_spec='${libname}${release}${shared_ext}$major'
3889     ;;
3890   esac
3891   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
3892   postinstall_cmds='chmod 555 $lib'
3893   # or fails outright, so override atomically:
3894   install_override_mode=555
3895   ;;
3896
3897 interix[[3-9]]*)
3898   version_type=linux # correct to gnu/linux during the next big refactor
3899   need_lib_prefix=no
3900   need_version=no
3901   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3902   soname_spec='${libname}${release}${shared_ext}$major'
3903   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3904   shlibpath_var=LD_LIBRARY_PATH
3905   shlibpath_overrides_runpath=no
3906   hardcode_into_libs=yes
3907   ;;
3908
3909 irix5* | irix6* | nonstopux*)
3910   case $host_os in
3911     nonstopux*) version_type=nonstopux ;;
3912     *)
3913         if test "$lt_cv_prog_gnu_ld" = yes; then
3914                 version_type=linux # correct to gnu/linux during the next big refactor
3915         else
3916                 version_type=irix
3917         fi ;;
3918   esac
3919   need_lib_prefix=no
3920   need_version=no
3921   soname_spec='${libname}${release}${shared_ext}$major'
3922   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
3923   case $host_os in
3924   irix5* | nonstopux*)
3925     libsuff= shlibsuff=
3926     ;;
3927   *)
3928     case $LD in # libtool.m4 will add one of these switches to LD
3929     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3930       libsuff= shlibsuff= libmagic=32-bit;;
3931     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3932       libsuff=32 shlibsuff=N32 libmagic=N32;;
3933     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3934       libsuff=64 shlibsuff=64 libmagic=64-bit;;
3935     *) libsuff= shlibsuff= libmagic=never-match;;
3936     esac
3937     ;;
3938   esac
3939   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3940   shlibpath_overrides_runpath=no
3941   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
3942   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
3943   hardcode_into_libs=yes
3944   ;;
3945
3946 # No shared lib support for Linux oldld, aout, or coff.
3947 linux*oldld* | linux*aout* | linux*coff*)
3948   dynamic_linker=no
3949   ;;
3950
3951 # This must be glibc/ELF.
3952 linux* | k*bsd*-gnu | kopensolaris*-gnu)
3953   version_type=linux # correct to gnu/linux during the next big refactor
3954   need_lib_prefix=no
3955   need_version=no
3956   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3957   soname_spec='${libname}${release}${shared_ext}$major'
3958   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3959   shlibpath_var=LD_LIBRARY_PATH
3960   shlibpath_overrides_runpath=no
3961
3962   # Some binutils ld are patched to set DT_RUNPATH
3963   AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
3964     [lt_cv_shlibpath_overrides_runpath=no
3965     save_LDFLAGS=$LDFLAGS
3966     save_libdir=$libdir
3967     eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3968          LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3969     AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3970       [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3971          [lt_cv_shlibpath_overrides_runpath=yes])])
3972     LDFLAGS=$save_LDFLAGS
3973     libdir=$save_libdir
3974     ])
3975   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
3976
3977   # This implies no fast_install, which is unacceptable.
3978   # Some rework will be needed to allow for fast_install
3979   # before this can be enabled.
3980   hardcode_into_libs=yes
3981
3982   # Add ABI-specific directories to the system library path.
3983   sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
3984
3985   # Append ld.so.conf contents to the search path
3986   if test -f /etc/ld.so.conf; then
3987     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;s/"//g;/^$/d' | tr '\n' ' '`
3988     sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
3989
3990   fi
3991
3992   # We used to test for /lib/ld.so.1 and disable shared libraries on
3993   # powerpc, because MkLinux only supported shared libraries with the
3994   # GNU dynamic linker.  Since this was broken with cross compilers,
3995   # most powerpc-linux boxes support dynamic linking these days and
3996   # people can always --disable-shared, the test was removed, and we
3997   # assume the GNU/Linux dynamic linker is in use.
3998   dynamic_linker='GNU/Linux ld.so'
3999   ;;
4000
4001 netbsd*)
4002   version_type=sunos
4003   need_lib_prefix=no
4004   need_version=no
4005   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4006     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
4007     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
4008     dynamic_linker='NetBSD (a.out) ld.so'
4009   else
4010     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
4011     soname_spec='${libname}${release}${shared_ext}$major'
4012     dynamic_linker='NetBSD ld.elf_so'
4013   fi
4014   shlibpath_var=LD_LIBRARY_PATH
4015   shlibpath_overrides_runpath=yes
4016   hardcode_into_libs=yes
4017   ;;
4018
4019 newsos6)
4020   version_type=linux # correct to gnu/linux during the next big refactor
4021   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4022   shlibpath_var=LD_LIBRARY_PATH
4023   shlibpath_overrides_runpath=yes
4024   ;;
4025
4026 *nto* | *qnx*)
4027   version_type=qnx
4028   need_lib_prefix=no
4029   need_version=no
4030   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4031   soname_spec='${libname}${release}${shared_ext}$major'
4032   shlibpath_var=LD_LIBRARY_PATH
4033   shlibpath_overrides_runpath=no
4034   hardcode_into_libs=yes
4035   dynamic_linker='ldqnx.so'
4036   ;;
4037
4038 openbsd*)
4039   version_type=sunos
4040   sys_lib_dlsearch_path_spec="/usr/lib"
4041   need_lib_prefix=no
4042   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
4043   case $host_os in
4044     openbsd3.3 | openbsd3.3.*)  need_version=yes ;;
4045     *)                          need_version=no  ;;
4046   esac
4047   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
4048   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
4049   shlibpath_var=LD_LIBRARY_PATH
4050   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4051     case $host_os in
4052       openbsd2.[[89]] | openbsd2.[[89]].*)
4053         shlibpath_overrides_runpath=no
4054         ;;
4055       *)
4056         shlibpath_overrides_runpath=yes
4057         ;;
4058       esac
4059   else
4060     shlibpath_overrides_runpath=yes
4061   fi
4062   ;;
4063
4064 os2*)
4065   libname_spec='$name'
4066   shrext_cmds=".dll"
4067   need_lib_prefix=no
4068   library_names_spec='$libname${shared_ext} $libname.a'
4069   dynamic_linker='OS/2 ld.exe'
4070   shlibpath_var=LIBPATH
4071   ;;
4072
4073 osf3* | osf4* | osf5*)
4074   version_type=osf
4075   need_lib_prefix=no
4076   need_version=no
4077   soname_spec='${libname}${release}${shared_ext}$major'
4078   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4079   shlibpath_var=LD_LIBRARY_PATH
4080   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
4081   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
4082   ;;
4083
4084 rdos*)
4085   dynamic_linker=no
4086   ;;
4087
4088 solaris*)
4089   version_type=linux # correct to gnu/linux during the next big refactor
4090   need_lib_prefix=no
4091   need_version=no
4092   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4093   soname_spec='${libname}${release}${shared_ext}$major'
4094   shlibpath_var=LD_LIBRARY_PATH
4095   shlibpath_overrides_runpath=yes
4096   hardcode_into_libs=yes
4097   # ldd complains unless libraries are executable
4098   postinstall_cmds='chmod +x $lib'
4099   ;;
4100
4101 sunos4*)
4102   version_type=sunos
4103   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
4104   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
4105   shlibpath_var=LD_LIBRARY_PATH
4106   shlibpath_overrides_runpath=yes
4107   if test "$with_gnu_ld" = yes; then
4108     need_lib_prefix=no
4109   fi
4110   need_version=yes
4111   ;;
4112
4113 sysv4 | sysv4.3*)
4114   version_type=linux # correct to gnu/linux during the next big refactor
4115   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4116   soname_spec='${libname}${release}${shared_ext}$major'
4117   shlibpath_var=LD_LIBRARY_PATH
4118   case $host_vendor in
4119     sni)
4120       shlibpath_overrides_runpath=no
4121       need_lib_prefix=no
4122       runpath_var=LD_RUN_PATH
4123       ;;
4124     siemens)
4125       need_lib_prefix=no
4126       ;;
4127     motorola)
4128       need_lib_prefix=no
4129       need_version=no
4130       shlibpath_overrides_runpath=no
4131       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
4132       ;;
4133   esac
4134   ;;
4135
4136 sysv4*MP*)
4137   if test -d /usr/nec ;then
4138     version_type=linux # correct to gnu/linux during the next big refactor
4139     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
4140     soname_spec='$libname${shared_ext}.$major'
4141     shlibpath_var=LD_LIBRARY_PATH
4142   fi
4143   ;;
4144
4145 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4146   version_type=freebsd-elf
4147   need_lib_prefix=no
4148   need_version=no
4149   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
4150   soname_spec='${libname}${release}${shared_ext}$major'
4151   shlibpath_var=LD_LIBRARY_PATH
4152   shlibpath_overrides_runpath=yes
4153   hardcode_into_libs=yes
4154   if test "$with_gnu_ld" = yes; then
4155     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
4156   else
4157     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
4158     case $host_os in
4159       sco3.2v5*)
4160         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
4161         ;;
4162     esac
4163   fi
4164   sys_lib_dlsearch_path_spec='/usr/lib'
4165   ;;
4166
4167 tpf*)
4168   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
4169   version_type=linux # correct to gnu/linux during the next big refactor
4170   need_lib_prefix=no
4171   need_version=no
4172   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4173   shlibpath_var=LD_LIBRARY_PATH
4174   shlibpath_overrides_runpath=no
4175   hardcode_into_libs=yes
4176   ;;
4177
4178 uts4*)
4179   version_type=linux # correct to gnu/linux during the next big refactor
4180   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4181   soname_spec='${libname}${release}${shared_ext}$major'
4182   shlibpath_var=LD_LIBRARY_PATH
4183   ;;
4184
4185 *)
4186   dynamic_linker=no
4187   ;;
4188 esac
4189 AC_MSG_RESULT([$dynamic_linker])
4190 test "$dynamic_linker" = no && can_build_shared=no
4191
4192 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
4193 if test "$GCC" = yes; then
4194   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
4195 fi
4196
4197 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
4198   sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
4199 fi
4200 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
4201   sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
4202 fi
4203
4204 _LT_DECL([], [variables_saved_for_relink], [1],
4205     [Variables whose values should be saved in libtool wrapper scripts and
4206     restored at link time])
4207 _LT_DECL([], [need_lib_prefix], [0],
4208     [Do we need the "lib" prefix for modules?])
4209 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
4210 _LT_DECL([], [version_type], [0], [Library versioning type])
4211 _LT_DECL([], [runpath_var], [0],  [Shared library runtime path variable])
4212 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
4213 _LT_DECL([], [shlibpath_overrides_runpath], [0],
4214     [Is shlibpath searched before the hard-coded library search path?])
4215 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
4216 _LT_DECL([], [library_names_spec], [1],
4217     [[List of archive names.  First name is the real one, the rest are links.
4218     The last name is the one that the linker finds with -lNAME]])
4219 _LT_DECL([], [soname_spec], [1],
4220     [[The coded name of the library, if different from the real name]])
4221 _LT_DECL([], [install_override_mode], [1],
4222     [Permission mode override for installation of shared libraries])
4223 _LT_DECL([], [postinstall_cmds], [2],
4224     [Command to use after installation of a shared archive])
4225 _LT_DECL([], [postuninstall_cmds], [2],
4226     [Command to use after uninstallation of a shared archive])
4227 _LT_DECL([], [finish_cmds], [2],
4228     [Commands used to finish a libtool library installation in a directory])
4229 _LT_DECL([], [finish_eval], [1],
4230     [[As "finish_cmds", except a single script fragment to be evaled but
4231     not shown]])
4232 _LT_DECL([], [hardcode_into_libs], [0],
4233     [Whether we should hardcode library paths into libraries])
4234 _LT_DECL([], [sys_lib_search_path_spec], [2],
4235     [Compile-time system search path for libraries])
4236 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
4237     [Run-time system search path for libraries])
4238 ])# _LT_SYS_DYNAMIC_LINKER
4239
4240
4241 # _LT_PATH_TOOL_PREFIX(TOOL)
4242 # --------------------------
4243 # find a file program which can recognize shared library
4244 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
4245 [m4_require([_LT_DECL_EGREP])dnl
4246 AC_MSG_CHECKING([for $1])
4247 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
4248 [case $MAGIC_CMD in
4249 [[\\/*] |  ?:[\\/]*])
4250   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
4251   ;;
4252 *)
4253   lt_save_MAGIC_CMD="$MAGIC_CMD"
4254   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4255 dnl $ac_dummy forces splitting on constant user-supplied paths.
4256 dnl POSIX.2 word splitting is done only on the output of word expansions,
4257 dnl not every word.  This closes a longstanding sh security hole.
4258   ac_dummy="m4_if([$2], , $PATH, [$2])"
4259   for ac_dir in $ac_dummy; do
4260     IFS="$lt_save_ifs"
4261     test -z "$ac_dir" && ac_dir=.
4262     if test -f $ac_dir/$1; then
4263       lt_cv_path_MAGIC_CMD="$ac_dir/$1"
4264       if test -n "$file_magic_test_file"; then
4265         case $deplibs_check_method in
4266         "file_magic "*)
4267           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
4268           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
4269           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
4270             $EGREP "$file_magic_regex" > /dev/null; then
4271             :
4272           else
4273             cat <<_LT_EOF 1>&2
4274
4275 *** Warning: the command libtool uses to detect shared libraries,
4276 *** $file_magic_cmd, produces output that libtool cannot recognize.
4277 *** The result is that libtool may fail to recognize shared libraries
4278 *** as such.  This will affect the creation of libtool libraries that
4279 *** depend on shared libraries, but programs linked with such libtool
4280 *** libraries will work regardless of this problem.  Nevertheless, you
4281 *** may want to report the problem to your system manager and/or to
4282 *** bug-libtool@gnu.org
4283
4284 _LT_EOF
4285           fi ;;
4286         esac
4287       fi
4288       break
4289     fi
4290   done
4291   IFS="$lt_save_ifs"
4292   MAGIC_CMD="$lt_save_MAGIC_CMD"
4293   ;;
4294 esac])
4295 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
4296 if test -n "$MAGIC_CMD"; then
4297   AC_MSG_RESULT($MAGIC_CMD)
4298 else
4299   AC_MSG_RESULT(no)
4300 fi
4301 _LT_DECL([], [MAGIC_CMD], [0],
4302          [Used to examine libraries when file_magic_cmd begins with "file"])dnl
4303 ])# _LT_PATH_TOOL_PREFIX
4304
4305 # Old name:
4306 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
4307 dnl aclocal-1.4 backwards compatibility:
4308 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
4309
4310
4311 # _LT_PATH_MAGIC
4312 # --------------
4313 # find a file program which can recognize a shared library
4314 m4_defun([_LT_PATH_MAGIC],
4315 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
4316 if test -z "$lt_cv_path_MAGIC_CMD"; then
4317   if test -n "$ac_tool_prefix"; then
4318     _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
4319   else
4320     MAGIC_CMD=:
4321   fi
4322 fi
4323 ])# _LT_PATH_MAGIC
4324
4325
4326 # LT_PATH_LD
4327 # ----------
4328 # find the pathname to the GNU or non-GNU linker
4329 AC_DEFUN([LT_PATH_LD],
4330 [AC_REQUIRE([AC_PROG_CC])dnl
4331 AC_REQUIRE([AC_CANONICAL_HOST])dnl
4332 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
4333 m4_require([_LT_DECL_SED])dnl
4334 m4_require([_LT_DECL_EGREP])dnl
4335 m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
4336
4337 AC_ARG_WITH([gnu-ld],
4338     [AS_HELP_STRING([--with-gnu-ld],
4339         [assume the C compiler uses GNU ld @<:@default=no@:>@])],
4340     [test "$withval" = no || with_gnu_ld=yes],
4341     [with_gnu_ld=no])dnl
4342
4343 ac_prog=ld
4344 if test "$GCC" = yes; then
4345   # Check if gcc -print-prog-name=ld gives a path.
4346   AC_MSG_CHECKING([for ld used by $CC])
4347   case $host in
4348   *-*-mingw*)
4349     # gcc leaves a trailing carriage return which upsets mingw
4350     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4351   *)
4352     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4353   esac
4354   case $ac_prog in
4355     # Accept absolute paths.
4356     [[\\/]]* | ?:[[\\/]]*)
4357       re_direlt='/[[^/]][[^/]]*/\.\./'
4358       # Canonicalize the pathname of ld
4359       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4360       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4361         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4362       done
4363       test -z "$LD" && LD="$ac_prog"
4364       ;;
4365   "")
4366     # If it fails, then pretend we aren't using GCC.
4367     ac_prog=ld
4368     ;;
4369   *)
4370     # If it is relative, then search for the first ld in PATH.
4371     with_gnu_ld=unknown
4372     ;;
4373   esac
4374 elif test "$with_gnu_ld" = yes; then
4375   AC_MSG_CHECKING([for GNU ld])
4376 else
4377   AC_MSG_CHECKING([for non-GNU ld])
4378 fi
4379 AC_CACHE_VAL(lt_cv_path_LD,
4380 [if test -z "$LD"; then
4381   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4382   for ac_dir in $PATH; do
4383     IFS="$lt_save_ifs"
4384     test -z "$ac_dir" && ac_dir=.
4385     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4386       lt_cv_path_LD="$ac_dir/$ac_prog"
4387       # Check to see if the program is GNU ld.  I'd rather use --version,
4388       # but apparently some variants of GNU ld only accept -v.
4389       # Break only if it was the GNU/non-GNU ld that we prefer.
4390       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4391       *GNU* | *'with BFD'*)
4392         test "$with_gnu_ld" != no && break
4393         ;;
4394       *)
4395         test "$with_gnu_ld" != yes && break
4396         ;;
4397       esac
4398     fi
4399   done
4400   IFS="$lt_save_ifs"
4401 else
4402   lt_cv_path_LD="$LD" # Let the user override the test with a path.
4403 fi])
4404 LD="$lt_cv_path_LD"
4405 if test -n "$LD"; then
4406   AC_MSG_RESULT($LD)
4407 else
4408   AC_MSG_RESULT(no)
4409 fi
4410 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
4411 _LT_PATH_LD_GNU
4412 AC_SUBST([LD])
4413
4414 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
4415 ])# LT_PATH_LD
4416
4417 # Old names:
4418 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
4419 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
4420 dnl aclocal-1.4 backwards compatibility:
4421 dnl AC_DEFUN([AM_PROG_LD], [])
4422 dnl AC_DEFUN([AC_PROG_LD], [])
4423
4424
4425 # _LT_PATH_LD_GNU
4426 #- --------------
4427 m4_defun([_LT_PATH_LD_GNU],
4428 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
4429 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
4430 case `$LD -v 2>&1 </dev/null` in
4431 *GNU* | *'with BFD'*)
4432   lt_cv_prog_gnu_ld=yes
4433   ;;
4434 *)
4435   lt_cv_prog_gnu_ld=no
4436   ;;
4437 esac])
4438 with_gnu_ld=$lt_cv_prog_gnu_ld
4439 ])# _LT_PATH_LD_GNU
4440
4441
4442 # _LT_CMD_RELOAD
4443 # --------------
4444 # find reload flag for linker
4445 #   -- PORTME Some linkers may need a different reload flag.
4446 m4_defun([_LT_CMD_RELOAD],
4447 [AC_CACHE_CHECK([for $LD option to reload object files],
4448   lt_cv_ld_reload_flag,
4449   [lt_cv_ld_reload_flag='-r'])
4450 reload_flag=$lt_cv_ld_reload_flag
4451 case $reload_flag in
4452 "" | " "*) ;;
4453 *) reload_flag=" $reload_flag" ;;
4454 esac
4455 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4456 case $host_os in
4457   cygwin* | mingw* | pw32* | cegcc*)
4458     if test "$GCC" != yes; then
4459       reload_cmds=false
4460     fi
4461     ;;
4462   darwin*)
4463     if test "$GCC" = yes; then
4464       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
4465     else
4466       reload_cmds='$LD$reload_flag -o $output$reload_objs'
4467     fi
4468     ;;
4469 esac
4470 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
4471 _LT_TAGDECL([], [reload_cmds], [2])dnl
4472 ])# _LT_CMD_RELOAD
4473
4474
4475 # _LT_CHECK_MAGIC_METHOD
4476 # ----------------------
4477 # how to check for library dependencies
4478 #  -- PORTME fill in with the dynamic library characteristics
4479 m4_defun([_LT_CHECK_MAGIC_METHOD],
4480 [m4_require([_LT_DECL_EGREP])
4481 m4_require([_LT_DECL_OBJDUMP])
4482 AC_CACHE_CHECK([how to recognize dependent libraries],
4483 lt_cv_deplibs_check_method,
4484 [lt_cv_file_magic_cmd='$MAGIC_CMD'
4485 lt_cv_file_magic_test_file=
4486 lt_cv_deplibs_check_method='unknown'
4487 # Need to set the preceding variable on all platforms that support
4488 # interlibrary dependencies.
4489 # 'none' -- dependencies not supported.
4490 # `unknown' -- same as none, but documents that we really don't know.
4491 # 'pass_all' -- all dependencies passed with no checks.
4492 # 'test_compile' -- check by making test program.
4493 # 'file_magic [[regex]]' -- check by looking for files in library path
4494 # which responds to the $file_magic_cmd with a given extended regex.
4495 # If you have `file' or equivalent on your system and you're not sure
4496 # whether `pass_all' will *always* work, you probably want this one.
4497
4498 case $host_os in
4499 aix[[4-9]]*)
4500   lt_cv_deplibs_check_method=pass_all
4501   ;;
4502
4503 beos*)
4504   lt_cv_deplibs_check_method=pass_all
4505   ;;
4506
4507 bsdi[[45]]*)
4508   lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
4509   lt_cv_file_magic_cmd='/usr/bin/file -L'
4510   lt_cv_file_magic_test_file=/shlib/libc.so
4511   ;;
4512
4513 cygwin*)
4514   # func_win32_libid is a shell function defined in ltmain.sh
4515   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4516   lt_cv_file_magic_cmd='func_win32_libid'
4517   ;;
4518
4519 mingw* | pw32*)
4520   # Base MSYS/MinGW do not provide the 'file' command needed by
4521   # func_win32_libid shell function, so use a weaker test based on 'objdump',
4522   # unless we find 'file', for example because we are cross-compiling.
4523   # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
4524   if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
4525     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4526     lt_cv_file_magic_cmd='func_win32_libid'
4527   else
4528     # Keep this pattern in sync with the one in func_win32_libid.
4529     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
4530     lt_cv_file_magic_cmd='$OBJDUMP -f'
4531   fi
4532   ;;
4533
4534 cegcc*)
4535   # use the weaker test based on 'objdump'. See mingw*.
4536   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
4537   lt_cv_file_magic_cmd='$OBJDUMP -f'
4538   ;;
4539
4540 darwin* | rhapsody*)
4541   lt_cv_deplibs_check_method=pass_all
4542   ;;
4543
4544 freebsd* | dragonfly*)
4545   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4546     case $host_cpu in
4547     i*86 )
4548       # Not sure whether the presence of OpenBSD here was a mistake.
4549       # Let's accept both of them until this is cleared up.
4550       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
4551       lt_cv_file_magic_cmd=/usr/bin/file
4552       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4553       ;;
4554     esac
4555   else
4556     lt_cv_deplibs_check_method=pass_all
4557   fi
4558   ;;
4559
4560 gnu*)
4561   lt_cv_deplibs_check_method=pass_all
4562   ;;
4563
4564 haiku*)
4565   lt_cv_deplibs_check_method=pass_all
4566   ;;
4567
4568 hpux10.20* | hpux11*)
4569   lt_cv_file_magic_cmd=/usr/bin/file
4570   case $host_cpu in
4571   ia64*)
4572     lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
4573     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
4574     ;;
4575   hppa*64*)
4576     [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
4577     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
4578     ;;
4579   *)
4580     lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
4581     lt_cv_file_magic_test_file=/usr/lib/libc.sl
4582     ;;
4583   esac
4584   ;;
4585
4586 interix[[3-9]]*)
4587   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
4588   lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
4589   ;;
4590
4591 irix5* | irix6* | nonstopux*)
4592   case $LD in
4593   *-32|*"-32 ") libmagic=32-bit;;
4594   *-n32|*"-n32 ") libmagic=N32;;
4595   *-64|*"-64 ") libmagic=64-bit;;
4596   *) libmagic=never-match;;
4597   esac
4598   lt_cv_deplibs_check_method=pass_all
4599   ;;
4600
4601 # This must be glibc/ELF.
4602 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4603   lt_cv_deplibs_check_method=pass_all
4604   ;;
4605
4606 netbsd*)
4607   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4608     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4609   else
4610     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
4611   fi
4612   ;;
4613
4614 newos6*)
4615   lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
4616   lt_cv_file_magic_cmd=/usr/bin/file
4617   lt_cv_file_magic_test_file=/usr/lib/libnls.so
4618   ;;
4619
4620 *nto* | *qnx*)
4621   lt_cv_deplibs_check_method=pass_all
4622   ;;
4623
4624 openbsd*)
4625   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4626     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
4627   else
4628     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4629   fi
4630   ;;
4631
4632 osf3* | osf4* | osf5*)
4633   lt_cv_deplibs_check_method=pass_all
4634   ;;
4635
4636 rdos*)
4637   lt_cv_deplibs_check_method=pass_all
4638   ;;
4639
4640 solaris*)
4641   lt_cv_deplibs_check_method=pass_all
4642   ;;
4643
4644 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4645   lt_cv_deplibs_check_method=pass_all
4646   ;;
4647
4648 sysv4 | sysv4.3*)
4649   case $host_vendor in
4650   motorola)
4651     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]]'
4652     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
4653     ;;
4654   ncr)
4655     lt_cv_deplibs_check_method=pass_all
4656     ;;
4657   sequent)
4658     lt_cv_file_magic_cmd='/bin/file'
4659     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
4660     ;;
4661   sni)
4662     lt_cv_file_magic_cmd='/bin/file'
4663     lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
4664     lt_cv_file_magic_test_file=/lib/libc.so
4665     ;;
4666   siemens)
4667     lt_cv_deplibs_check_method=pass_all
4668     ;;
4669   pc)
4670     lt_cv_deplibs_check_method=pass_all
4671     ;;
4672   esac
4673   ;;
4674
4675 tpf*)
4676   lt_cv_deplibs_check_method=pass_all
4677   ;;
4678 esac
4679 ])
4680
4681 file_magic_glob=
4682 want_nocaseglob=no
4683 if test "$build" = "$host"; then
4684   case $host_os in
4685   mingw* | pw32*)
4686     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
4687       want_nocaseglob=yes
4688     else
4689       file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
4690     fi
4691     ;;
4692   esac
4693 fi
4694
4695 file_magic_cmd=$lt_cv_file_magic_cmd
4696 deplibs_check_method=$lt_cv_deplibs_check_method
4697 test -z "$deplibs_check_method" && deplibs_check_method=unknown
4698
4699 _LT_DECL([], [deplibs_check_method], [1],
4700     [Method to check whether dependent libraries are shared objects])
4701 _LT_DECL([], [file_magic_cmd], [1],
4702     [Command to use when deplibs_check_method = "file_magic"])
4703 _LT_DECL([], [file_magic_glob], [1],
4704     [How to find potential files when deplibs_check_method = "file_magic"])
4705 _LT_DECL([], [want_nocaseglob], [1],
4706     [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
4707 ])# _LT_CHECK_MAGIC_METHOD
4708
4709
4710 # LT_PATH_NM
4711 # ----------
4712 # find the pathname to a BSD- or MS-compatible name lister
4713 AC_DEFUN([LT_PATH_NM],
4714 [AC_REQUIRE([AC_PROG_CC])dnl
4715 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
4716 [if test -n "$NM"; then
4717   # Let the user override the test.
4718   lt_cv_path_NM="$NM"
4719 else
4720   lt_nm_to_check="${ac_tool_prefix}nm"
4721   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4722     lt_nm_to_check="$lt_nm_to_check nm"
4723   fi
4724   for lt_tmp_nm in $lt_nm_to_check; do
4725     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4726     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4727       IFS="$lt_save_ifs"
4728       test -z "$ac_dir" && ac_dir=.
4729       tmp_nm="$ac_dir/$lt_tmp_nm"
4730       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
4731         # Check to see if the nm accepts a BSD-compat flag.
4732         # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4733         #   nm: unknown option "B" ignored
4734         # Tru64's nm complains that /dev/null is an invalid object file
4735         case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
4736         */dev/null* | *'Invalid file or object type'*)
4737           lt_cv_path_NM="$tmp_nm -B"
4738           break
4739           ;;
4740         *)
4741           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4742           */dev/null*)
4743             lt_cv_path_NM="$tmp_nm -p"
4744             break
4745             ;;
4746           *)
4747             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4748             continue # so that we can try to find one that supports BSD flags
4749             ;;
4750           esac
4751           ;;
4752         esac
4753       fi
4754     done
4755     IFS="$lt_save_ifs"
4756   done
4757   : ${lt_cv_path_NM=no}
4758 fi])
4759 if test "$lt_cv_path_NM" != "no"; then
4760   NM="$lt_cv_path_NM"
4761 else
4762   # Didn't find any BSD compatible name lister, look for dumpbin.
4763   if test -n "$DUMPBIN"; then :
4764     # Let the user override the test.
4765   else
4766     AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
4767     case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
4768     *COFF*)
4769       DUMPBIN="$DUMPBIN -symbols"
4770       ;;
4771     *)
4772       DUMPBIN=:
4773       ;;
4774     esac
4775   fi
4776   AC_SUBST([DUMPBIN])
4777   if test "$DUMPBIN" != ":"; then
4778     NM="$DUMPBIN"
4779   fi
4780 fi
4781 test -z "$NM" && NM=nm
4782 AC_SUBST([NM])
4783 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
4784
4785 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
4786   [lt_cv_nm_interface="BSD nm"
4787   echo "int some_variable = 0;" > conftest.$ac_ext
4788   (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
4789   (eval "$ac_compile" 2>conftest.err)
4790   cat conftest.err >&AS_MESSAGE_LOG_FD
4791   (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
4792   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4793   cat conftest.err >&AS_MESSAGE_LOG_FD
4794   (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
4795   cat conftest.out >&AS_MESSAGE_LOG_FD
4796   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4797     lt_cv_nm_interface="MS dumpbin"
4798   fi
4799   rm -f conftest*])
4800 ])# LT_PATH_NM
4801
4802 # Old names:
4803 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
4804 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
4805 dnl aclocal-1.4 backwards compatibility:
4806 dnl AC_DEFUN([AM_PROG_NM], [])
4807 dnl AC_DEFUN([AC_PROG_NM], [])
4808
4809 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4810 # --------------------------------
4811 # how to determine the name of the shared library
4812 # associated with a specific link library.
4813 #  -- PORTME fill in with the dynamic library characteristics
4814 m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
4815 [m4_require([_LT_DECL_EGREP])
4816 m4_require([_LT_DECL_OBJDUMP])
4817 m4_require([_LT_DECL_DLLTOOL])
4818 AC_CACHE_CHECK([how to associate runtime and link libraries],
4819 lt_cv_sharedlib_from_linklib_cmd,
4820 [lt_cv_sharedlib_from_linklib_cmd='unknown'
4821
4822 case $host_os in
4823 cygwin* | mingw* | pw32* | cegcc*)
4824   # two different shell functions defined in ltmain.sh
4825   # decide which to use based on capabilities of $DLLTOOL
4826   case `$DLLTOOL --help 2>&1` in
4827   *--identify-strict*)
4828     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
4829     ;;
4830   *)
4831     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
4832     ;;
4833   esac
4834   ;;
4835 *)
4836   # fallback: assume linklib IS sharedlib
4837   lt_cv_sharedlib_from_linklib_cmd="$ECHO"
4838   ;;
4839 esac
4840 ])
4841 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
4842 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
4843
4844 _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
4845     [Command to associate shared and link libraries])
4846 ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4847
4848
4849 # _LT_PATH_MANIFEST_TOOL
4850 # ----------------------
4851 # locate the manifest tool
4852 m4_defun([_LT_PATH_MANIFEST_TOOL],
4853 [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
4854 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
4855 AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
4856   [lt_cv_path_mainfest_tool=no
4857   echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
4858   $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
4859   cat conftest.err >&AS_MESSAGE_LOG_FD
4860   if $GREP 'Manifest Tool' conftest.out > /dev/null; then
4861     lt_cv_path_mainfest_tool=yes
4862   fi
4863   rm -f conftest*])
4864 if test "x$lt_cv_path_mainfest_tool" != xyes; then
4865   MANIFEST_TOOL=:
4866 fi
4867 _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
4868 ])# _LT_PATH_MANIFEST_TOOL
4869
4870
4871 # LT_LIB_M
4872 # --------
4873 # check for math library
4874 AC_DEFUN([LT_LIB_M],
4875 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4876 LIBM=
4877 case $host in
4878 *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
4879   # These system don't have libm, or don't need it
4880   ;;
4881 *-ncr-sysv4.3*)
4882   AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
4883   AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
4884   ;;
4885 *)
4886   AC_CHECK_LIB(m, cos, LIBM="-lm")
4887   ;;
4888 esac
4889 AC_SUBST([LIBM])
4890 ])# LT_LIB_M
4891
4892 # Old name:
4893 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
4894 dnl aclocal-1.4 backwards compatibility:
4895 dnl AC_DEFUN([AC_CHECK_LIBM], [])
4896
4897
4898 # _LT_COMPILER_NO_RTTI([TAGNAME])
4899 # -------------------------------
4900 m4_defun([_LT_COMPILER_NO_RTTI],
4901 [m4_require([_LT_TAG_COMPILER])dnl
4902
4903 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4904
4905 if test "$GCC" = yes; then
4906   case $cc_basename in
4907   nvcc*)
4908     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
4909   *)
4910     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
4911   esac
4912
4913   _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4914     lt_cv_prog_compiler_rtti_exceptions,
4915     [-fno-rtti -fno-exceptions], [],
4916     [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4917 fi
4918 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
4919         [Compiler flag to turn off builtin functions])
4920 ])# _LT_COMPILER_NO_RTTI
4921
4922
4923 # _LT_CMD_GLOBAL_SYMBOLS
4924 # ----------------------
4925 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
4926 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4927 AC_REQUIRE([AC_PROG_CC])dnl
4928 AC_REQUIRE([AC_PROG_AWK])dnl
4929 AC_REQUIRE([LT_PATH_NM])dnl
4930 AC_REQUIRE([LT_PATH_LD])dnl
4931 m4_require([_LT_DECL_SED])dnl
4932 m4_require([_LT_DECL_EGREP])dnl
4933 m4_require([_LT_TAG_COMPILER])dnl
4934
4935 # Check for command to grab the raw symbol name followed by C symbol from nm.
4936 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4937 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4938 [
4939 # These are sane defaults that work on at least a few old systems.
4940 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
4941
4942 # Character class describing NM global symbol codes.
4943 symcode='[[BCDEGRST]]'
4944
4945 # Regexp to match symbols that can be accessed directly from C.
4946 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4947
4948 # Define system-specific variables.
4949 case $host_os in
4950 aix*)
4951   symcode='[[BCDT]]'
4952   ;;
4953 cygwin* | mingw* | pw32* | cegcc*)
4954   symcode='[[ABCDGISTW]]'
4955   ;;
4956 hpux*)
4957   if test "$host_cpu" = ia64; then
4958     symcode='[[ABCDEGRST]]'
4959   fi
4960   ;;
4961 irix* | nonstopux*)
4962   symcode='[[BCDEGRST]]'
4963   ;;
4964 osf*)
4965   symcode='[[BCDEGQRST]]'
4966   ;;
4967 solaris*)
4968   symcode='[[BDRT]]'
4969   ;;
4970 sco3.2v5*)
4971   symcode='[[DT]]'
4972   ;;
4973 sysv4.2uw2*)
4974   symcode='[[DT]]'
4975   ;;
4976 sysv5* | sco5v6* | unixware* | OpenUNIX*)
4977   symcode='[[ABDT]]'
4978   ;;
4979 sysv4)
4980   symcode='[[DFNSTU]]'
4981   ;;
4982 esac
4983
4984 # If we're using GNU nm, then use its standard symbol codes.
4985 case `$NM -V 2>&1` in
4986 *GNU* | *'with BFD'*)
4987   symcode='[[ABCDGIRSTW]]' ;;
4988 esac
4989
4990 # Transform an extracted symbol line into a proper C declaration.
4991 # Some systems (esp. on ia64) link data and code symbols differently,
4992 # so use this general approach.
4993 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4994
4995 # Transform an extracted symbol line into symbol name and symbol address
4996 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
4997 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
4998
4999 # Handle CRLF in mingw tool chain
5000 opt_cr=
5001 case $build_os in
5002 mingw*)
5003   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5004   ;;
5005 esac
5006
5007 # Try without a prefix underscore, then with it.
5008 for ac_symprfx in "" "_"; do
5009
5010   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5011   symxfrm="\\1 $ac_symprfx\\2 \\2"
5012
5013   # Write the raw and C identifiers.
5014   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
5015     # Fake it for dumpbin and say T for any non-static function
5016     # and D for any global variable.
5017     # Also find C++ and __fastcall symbols from MSVC++,
5018     # which start with @ or ?.
5019     lt_cv_sys_global_symbol_pipe="$AWK ['"\
5020 "     {last_section=section; section=\$ 3};"\
5021 "     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
5022 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
5023 "     \$ 0!~/External *\|/{next};"\
5024 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
5025 "     {if(hide[section]) next};"\
5026 "     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
5027 "     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
5028 "     s[1]~/^[@?]/{print s[1], s[1]; next};"\
5029 "     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
5030 "     ' prfx=^$ac_symprfx]"
5031   else
5032     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[     ]]\($symcode$symcode*\)[[       ]][[    ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5033   fi
5034   lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
5035
5036   # Check to see that the pipe works correctly.
5037   pipe_works=no
5038
5039   rm -f conftest*
5040   cat > conftest.$ac_ext <<_LT_EOF
5041 #ifdef __cplusplus
5042 extern "C" {
5043 #endif
5044 char nm_test_var;
5045 void nm_test_func(void);
5046 void nm_test_func(void){}
5047 #ifdef __cplusplus
5048 }
5049 #endif
5050 int main(){nm_test_var='a';nm_test_func();return(0);}
5051 _LT_EOF
5052
5053   if AC_TRY_EVAL(ac_compile); then
5054     # Now try to grab the symbols.
5055     nlist=conftest.nm
5056     if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
5057       # Try sorting and uniquifying the output.
5058       if sort "$nlist" | uniq > "$nlist"T; then
5059         mv -f "$nlist"T "$nlist"
5060       else
5061         rm -f "$nlist"T
5062       fi
5063
5064       # Make sure that we snagged all the symbols we need.
5065       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
5066         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
5067           cat <<_LT_EOF > conftest.$ac_ext
5068 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
5069 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
5070 /* DATA imports from DLLs on WIN32 con't be const, because runtime
5071    relocations are performed -- see ld's documentation on pseudo-relocs.  */
5072 # define LT@&t@_DLSYM_CONST
5073 #elif defined(__osf__)
5074 /* This system does not cope well with relocations in const data.  */
5075 # define LT@&t@_DLSYM_CONST
5076 #else
5077 # define LT@&t@_DLSYM_CONST const
5078 #endif
5079
5080 #ifdef __cplusplus
5081 extern "C" {
5082 #endif
5083
5084 _LT_EOF
5085           # Now generate the symbol file.
5086           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
5087
5088           cat <<_LT_EOF >> conftest.$ac_ext
5089
5090 /* The mapping between symbol names and symbols.  */
5091 LT@&t@_DLSYM_CONST struct {
5092   const char *name;
5093   void       *address;
5094 }
5095 lt__PROGRAM__LTX_preloaded_symbols[[]] =
5096 {
5097   { "@PROGRAM@", (void *) 0 },
5098 _LT_EOF
5099           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
5100           cat <<\_LT_EOF >> conftest.$ac_ext
5101   {0, (void *) 0}
5102 };
5103
5104 /* This works around a problem in FreeBSD linker */
5105 #ifdef FREEBSD_WORKAROUND
5106 static const void *lt_preloaded_setup() {
5107   return lt__PROGRAM__LTX_preloaded_symbols;
5108 }
5109 #endif
5110
5111 #ifdef __cplusplus
5112 }
5113 #endif
5114 _LT_EOF
5115           # Now try linking the two files.
5116           mv conftest.$ac_objext conftstm.$ac_objext
5117           lt_globsym_save_LIBS=$LIBS
5118           lt_globsym_save_CFLAGS=$CFLAGS
5119           LIBS="conftstm.$ac_objext"
5120           CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5121           if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5122             pipe_works=yes
5123           fi
5124           LIBS=$lt_globsym_save_LIBS
5125           CFLAGS=$lt_globsym_save_CFLAGS
5126         else
5127           echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5128         fi
5129       else
5130         echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5131       fi
5132     else
5133       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5134     fi
5135   else
5136     echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5137     cat conftest.$ac_ext >&5
5138   fi
5139   rm -rf conftest* conftst*
5140
5141   # Do not use the global_symbol_pipe unless it works.
5142   if test "$pipe_works" = yes; then
5143     break
5144   else
5145     lt_cv_sys_global_symbol_pipe=
5146   fi
5147 done
5148 ])
5149 if test -z "$lt_cv_sys_global_symbol_pipe"; then
5150   lt_cv_sys_global_symbol_to_cdecl=
5151 fi
5152 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5153   AC_MSG_RESULT(failed)
5154 else
5155   AC_MSG_RESULT(ok)
5156 fi
5157
5158 # Response file support.
5159 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
5160   nm_file_list_spec='@'
5161 elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
5162   nm_file_list_spec='@'
5163 fi
5164
5165 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
5166     [Take the output of nm and produce a listing of raw symbols and C names])
5167 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
5168     [Transform the output of nm in a proper C declaration])
5169 _LT_DECL([global_symbol_to_c_name_address],
5170     [lt_cv_sys_global_symbol_to_c_name_address], [1],
5171     [Transform the output of nm in a C name address pair])
5172 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
5173     [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
5174     [Transform the output of nm in a C name address pair when lib prefix is needed])
5175 _LT_DECL([], [nm_file_list_spec], [1],
5176     [Specify filename containing input files for $NM])
5177 ]) # _LT_CMD_GLOBAL_SYMBOLS
5178
5179
5180 # _LT_COMPILER_PIC([TAGNAME])
5181 # ---------------------------
5182 m4_defun([_LT_COMPILER_PIC],
5183 [m4_require([_LT_TAG_COMPILER])dnl
5184 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
5185 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5186 _LT_TAGVAR(lt_prog_compiler_static, $1)=
5187
5188 m4_if([$1], [CXX], [
5189   # C++ specific cases for pic, static, wl, etc.
5190   if test "$GXX" = yes; then
5191     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5192     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5193
5194     case $host_os in
5195     aix*)
5196       # All AIX code is PIC.
5197       if test "$host_cpu" = ia64; then
5198         # AIX 5 now supports IA64 processor
5199         _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5200       fi
5201       ;;
5202
5203     amigaos*)
5204       case $host_cpu in
5205       powerpc)
5206             # see comment about AmigaOS4 .so support
5207             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5208         ;;
5209       m68k)
5210             # FIXME: we need at least 68020 code to build shared libraries, but
5211             # adding the `-m68020' flag to GCC prevents building anything better,
5212             # like `-m68040'.
5213             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5214         ;;
5215       esac
5216       ;;
5217
5218     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5219       # PIC is the default for these OSes.
5220       ;;
5221     mingw* | cygwin* | os2* | pw32* | cegcc*)
5222       # This hack is so that the source file can tell whether it is being
5223       # built for inclusion in a dll (and should export symbols for example).
5224       # Although the cygwin gcc ignores -fPIC, still need this for old-style
5225       # (--disable-auto-import) libraries
5226       m4_if([$1], [GCJ], [],
5227         [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5228       ;;
5229     darwin* | rhapsody*)
5230       # PIC is the default on this platform
5231       # Common symbols not allowed in MH_DYLIB files
5232       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5233       ;;
5234     *djgpp*)
5235       # DJGPP does not support shared libraries at all
5236       _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5237       ;;
5238     haiku*)
5239       # PIC is the default for Haiku.
5240       # The "-static" flag exists, but is broken.
5241       _LT_TAGVAR(lt_prog_compiler_static, $1)=
5242       ;;
5243     interix[[3-9]]*)
5244       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5245       # Instead, we relocate shared libraries at runtime.
5246       ;;
5247     sysv4*MP*)
5248       if test -d /usr/nec; then
5249         _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5250       fi
5251       ;;
5252     hpux*)
5253       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5254       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
5255       # sets the default TLS model and affects inlining.
5256       case $host_cpu in
5257       hppa*64*)
5258         ;;
5259       *)
5260         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5261         ;;
5262       esac
5263       ;;
5264     *qnx* | *nto*)
5265       # QNX uses GNU C++, but need to define -shared option too, otherwise
5266       # it will coredump.
5267       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5268       ;;
5269     *)
5270       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5271       ;;
5272     esac
5273   else
5274     case $host_os in
5275       aix[[4-9]]*)
5276         # All AIX code is PIC.
5277         if test "$host_cpu" = ia64; then
5278           # AIX 5 now supports IA64 processor
5279           _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5280         else
5281           _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5282         fi
5283         ;;
5284       chorus*)
5285         case $cc_basename in
5286         cxch68*)
5287           # Green Hills C++ Compiler
5288           # _LT_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"
5289           ;;
5290         esac
5291         ;;
5292       mingw* | cygwin* | os2* | pw32* | cegcc*)
5293         # This hack is so that the source file can tell whether it is being
5294         # built for inclusion in a dll (and should export symbols for example).
5295         m4_if([$1], [GCJ], [],
5296           [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5297         ;;
5298       dgux*)
5299         case $cc_basename in
5300           ec++*)
5301             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5302             ;;
5303           ghcx*)
5304             # Green Hills C++ Compiler
5305             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5306             ;;
5307           *)
5308             ;;
5309         esac
5310         ;;
5311       freebsd* | dragonfly*)
5312         # FreeBSD uses GNU C++
5313         ;;
5314       hpux9* | hpux10* | hpux11*)
5315         case $cc_basename in
5316           CC*)
5317             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5318             _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5319             if test "$host_cpu" != ia64; then
5320               _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5321             fi
5322             ;;
5323           aCC*)
5324             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5325             _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5326             case $host_cpu in
5327             hppa*64*|ia64*)
5328               # +Z the default
5329               ;;
5330             *)
5331               _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5332               ;;
5333             esac
5334             ;;
5335           *)
5336             ;;
5337         esac
5338         ;;
5339       interix*)
5340         # This is c89, which is MS Visual C++ (no shared libs)
5341         # Anyone wants to do a port?
5342         ;;
5343       irix5* | irix6* | nonstopux*)
5344         case $cc_basename in
5345           CC*)
5346             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5347             _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5348             # CC pic flag -KPIC is the default.
5349             ;;
5350           *)
5351             ;;
5352         esac
5353         ;;
5354       linux* | k*bsd*-gnu | kopensolaris*-gnu)
5355         case $cc_basename in
5356           KCC*)
5357             # KAI C++ Compiler
5358             _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5359             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5360             ;;
5361           ecpc* )
5362             # old Intel C++ for x86_64 which still supported -KPIC.
5363             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5364             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5365             _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5366             ;;
5367           icpc* )
5368             # Intel C++, used to be incompatible with GCC.
5369             # ICC 10 doesn't accept -KPIC any more.
5370             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5371             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5372             _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5373             ;;
5374           pgCC* | pgcpp*)
5375             # Portland Group C++ compiler
5376             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5377             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5378             _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5379             ;;
5380           cxx*)
5381             # Compaq C++
5382             # Make sure the PIC flag is empty.  It appears that all Alpha
5383             # Linux and Compaq Tru64 Unix objects are PIC.
5384             _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5385             _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5386             ;;
5387           xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
5388             # IBM XL 8.0, 9.0 on PPC and BlueGene
5389             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5390             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5391             _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5392             ;;
5393           *)
5394             case `$CC -V 2>&1 | sed 5q` in
5395             *Sun\ C*)
5396               # Sun C++ 5.9
5397               _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5398               _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5399               _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5400               ;;
5401             esac
5402             ;;
5403         esac
5404         ;;
5405       lynxos*)
5406         ;;
5407       m88k*)
5408         ;;
5409       mvs*)
5410         case $cc_basename in
5411           cxx*)
5412             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5413             ;;
5414           *)
5415             ;;
5416         esac
5417         ;;
5418       netbsd*)
5419         ;;
5420       *qnx* | *nto*)
5421         # QNX uses GNU C++, but need to define -shared option too, otherwise
5422         # it will coredump.
5423         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5424         ;;
5425       osf3* | osf4* | osf5*)
5426         case $cc_basename in
5427           KCC*)
5428             _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5429             ;;
5430           RCC*)
5431             # Rational C++ 2.4.1
5432             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5433             ;;
5434           cxx*)
5435             # Digital/Compaq C++
5436             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5437             # Make sure the PIC flag is empty.  It appears that all Alpha
5438             # Linux and Compaq Tru64 Unix objects are PIC.
5439             _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5440             _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5441             ;;
5442           *)
5443             ;;
5444         esac
5445         ;;
5446       psos*)
5447         ;;
5448       solaris*)
5449         case $cc_basename in
5450           CC* | sunCC*)
5451             # Sun C++ 4.2, 5.x and Centerline C++
5452             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5453             _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5454             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5455             ;;
5456           gcx*)
5457             # Green Hills C++ Compiler
5458             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5459             ;;
5460           *)
5461             ;;
5462         esac
5463         ;;
5464       sunos4*)
5465         case $cc_basename in
5466           CC*)
5467             # Sun C++ 4.x
5468             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5469             _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5470             ;;
5471           lcc*)
5472             # Lucid
5473             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5474             ;;
5475           *)
5476             ;;
5477         esac
5478         ;;
5479       sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5480         case $cc_basename in
5481           CC*)
5482             _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5483             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5484             _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5485             ;;
5486         esac
5487         ;;
5488       tandem*)
5489         case $cc_basename in
5490           NCC*)
5491             # NonStop-UX NCC 3.20
5492             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5493             ;;
5494           *)
5495             ;;
5496         esac
5497         ;;
5498       vxworks*)
5499         ;;
5500       *)
5501         _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5502         ;;
5503     esac
5504   fi
5505 ],
5506 [
5507   if test "$GCC" = yes; then
5508     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5509     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5510
5511     case $host_os in
5512       aix*)
5513       # All AIX code is PIC.
5514       if test "$host_cpu" = ia64; then
5515         # AIX 5 now supports IA64 processor
5516         _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5517       fi
5518       ;;
5519
5520     amigaos*)
5521       case $host_cpu in
5522       powerpc)
5523             # see comment about AmigaOS4 .so support
5524             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5525         ;;
5526       m68k)
5527             # FIXME: we need at least 68020 code to build shared libraries, but
5528             # adding the `-m68020' flag to GCC prevents building anything better,
5529             # like `-m68040'.
5530             _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5531         ;;
5532       esac
5533       ;;
5534
5535     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5536       # PIC is the default for these OSes.
5537       ;;
5538
5539     mingw* | cygwin* | pw32* | os2* | cegcc*)
5540       # This hack is so that the source file can tell whether it is being
5541       # built for inclusion in a dll (and should export symbols for example).
5542       # Although the cygwin gcc ignores -fPIC, still need this for old-style
5543       # (--disable-auto-import) libraries
5544       m4_if([$1], [GCJ], [],
5545         [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5546       ;;
5547
5548     darwin* | rhapsody*)
5549       # PIC is the default on this platform
5550       # Common symbols not allowed in MH_DYLIB files
5551       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5552       ;;
5553
5554     haiku*)
5555       # PIC is the default for Haiku.
5556       # The "-static" flag exists, but is broken.
5557       _LT_TAGVAR(lt_prog_compiler_static, $1)=
5558       ;;
5559
5560     hpux*)
5561       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5562       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
5563       # sets the default TLS model and affects inlining.
5564       case $host_cpu in
5565       hppa*64*)
5566         # +Z the default
5567         ;;
5568       *)
5569         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5570         ;;
5571       esac
5572       ;;
5573
5574     interix[[3-9]]*)
5575       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5576       # Instead, we relocate shared libraries at runtime.
5577       ;;
5578
5579     msdosdjgpp*)
5580       # Just because we use GCC doesn't mean we suddenly get shared libraries
5581       # on systems that don't support them.
5582       _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5583       enable_shared=no
5584       ;;
5585
5586     *nto* | *qnx*)
5587       # QNX uses GNU C++, but need to define -shared option too, otherwise
5588       # it will coredump.
5589       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5590       ;;
5591
5592     sysv4*MP*)
5593       if test -d /usr/nec; then
5594         _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5595       fi
5596       ;;
5597
5598     *)
5599       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5600       ;;
5601     esac
5602
5603     case $cc_basename in
5604     nvcc*) # Cuda Compiler Driver 2.2
5605       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
5606       if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5607         _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
5608       fi
5609       ;;
5610     esac
5611   else
5612     # PORTME Check for flag to pass linker flags through the system compiler.
5613     case $host_os in
5614     aix*)
5615       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5616       if test "$host_cpu" = ia64; then
5617         # AIX 5 now supports IA64 processor
5618         _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5619       else
5620         _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5621       fi
5622       ;;
5623
5624     mingw* | cygwin* | pw32* | os2* | cegcc*)
5625       # This hack is so that the source file can tell whether it is being
5626       # built for inclusion in a dll (and should export symbols for example).
5627       m4_if([$1], [GCJ], [],
5628         [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5629       ;;
5630
5631     hpux9* | hpux10* | hpux11*)
5632       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5633       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5634       # not for PA HP-UX.
5635       case $host_cpu in
5636       hppa*64*|ia64*)
5637         # +Z the default
5638         ;;
5639       *)
5640         _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5641         ;;
5642       esac
5643       # Is there a better lt_prog_compiler_static that works with the bundled CC?
5644       _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5645       ;;
5646
5647     irix5* | irix6* | nonstopux*)
5648       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5649       # PIC (with -KPIC) is the default.
5650       _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5651       ;;
5652
5653     linux* | k*bsd*-gnu | kopensolaris*-gnu)
5654       case $cc_basename in
5655       # old Intel for x86_64 which still supported -KPIC.
5656       ecc*)
5657         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5658         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5659         _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5660         ;;
5661       # icc used to be incompatible with GCC.
5662       # ICC 10 doesn't accept -KPIC any more.
5663       icc* | ifort*)
5664         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5665         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5666         _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5667         ;;
5668       # Lahey Fortran 8.1.
5669       lf95*)
5670         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5671         _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
5672         _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
5673         ;;
5674       nagfor*)
5675         # NAG Fortran compiler
5676         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
5677         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5678         _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5679         ;;
5680       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
5681         # Portland Group compilers (*not* the Pentium gcc compiler,
5682         # which looks to be a dead project)
5683         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5684         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5685         _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5686         ;;
5687       ccc*)
5688         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5689         # All Alpha code is PIC.
5690         _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5691         ;;
5692       xl* | bgxl* | bgf* | mpixl*)
5693         # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
5694         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5695         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5696         _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5697         ;;
5698       *)
5699         case `$CC -V 2>&1 | sed 5q` in
5700         *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
5701           # Sun Fortran 8.3 passes all unrecognized flags to the linker
5702           _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5703           _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5704           _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
5705           ;;
5706         *Sun\ F* | *Sun*Fortran*)
5707           _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5708           _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5709           _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5710           ;;
5711         *Sun\ C*)
5712           # Sun C 5.9
5713           _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5714           _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5715           _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5716           ;;
5717         *Intel*\ [[CF]]*Compiler*)
5718           _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5719           _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5720           _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5721           ;;
5722         *Portland\ Group*)
5723           _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5724           _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5725           _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5726           ;;
5727         esac
5728         ;;
5729       esac
5730       ;;
5731
5732     newsos6)
5733       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5734       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5735       ;;
5736
5737     *nto* | *qnx*)
5738       # QNX uses GNU C++, but need to define -shared option too, otherwise
5739       # it will coredump.
5740       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5741       ;;
5742
5743     osf3* | osf4* | osf5*)
5744       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5745       # All OSF/1 code is PIC.
5746       _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5747       ;;
5748
5749     rdos*)
5750       _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5751       ;;
5752
5753     solaris*)
5754       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5755       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5756       case $cc_basename in
5757       f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
5758         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5759       *)
5760         _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5761       esac
5762       ;;
5763
5764     sunos4*)
5765       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5766       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5767       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5768       ;;
5769
5770     sysv4 | sysv4.2uw2* | sysv4.3*)
5771       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5772       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5773       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5774       ;;
5775
5776     sysv4*MP*)
5777       if test -d /usr/nec ;then
5778         _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5779         _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5780       fi
5781       ;;
5782
5783     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5784       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5785       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5786       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5787       ;;
5788
5789     unicos*)
5790       _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5791       _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5792       ;;
5793
5794     uts4*)
5795       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5796       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5797       ;;
5798
5799     *)
5800       _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5801       ;;
5802     esac
5803   fi
5804 ])
5805 case $host_os in
5806   # For platforms which do not support PIC, -DPIC is meaningless:
5807   *djgpp*)
5808     _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5809     ;;
5810   *)
5811     _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
5812     ;;
5813 esac
5814
5815 AC_CACHE_CHECK([for $compiler option to produce PIC],
5816   [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
5817   [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
5818 _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
5819
5820 #
5821 # Check to make sure the PIC flag actually works.
5822 #
5823 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5824   _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
5825     [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
5826     [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
5827     [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
5828      "" | " "*) ;;
5829      *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5830      esac],
5831     [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
5832      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5833 fi
5834 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
5835         [Additional compiler flags for building library objects])
5836
5837 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
5838         [How to pass a linker flag through the compiler])
5839 #
5840 # Check to make sure the static flag actually works.
5841 #
5842 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
5843 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
5844   _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
5845   $lt_tmp_static_flag,
5846   [],
5847   [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
5848 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
5849         [Compiler flag to prevent dynamic linking])
5850 ])# _LT_COMPILER_PIC
5851
5852
5853 # _LT_LINKER_SHLIBS([TAGNAME])
5854 # ----------------------------
5855 # See if the linker supports building shared libraries.
5856 m4_defun([_LT_LINKER_SHLIBS],
5857 [AC_REQUIRE([LT_PATH_LD])dnl
5858 AC_REQUIRE([LT_PATH_NM])dnl
5859 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5860 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5861 m4_require([_LT_DECL_EGREP])dnl
5862 m4_require([_LT_DECL_SED])dnl
5863 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
5864 m4_require([_LT_TAG_COMPILER])dnl
5865 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5866 m4_if([$1], [CXX], [
5867   _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5868   _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5869   case $host_os in
5870   aix[[4-9]]*)
5871     # If we're using GNU nm, then we don't want the "-C" option.
5872     # -C means demangle to AIX nm, but means don't demangle with GNU nm
5873     # Also, AIX nm treats weak defined symbols like other global defined
5874     # symbols, whereas GNU nm marks them as "W".
5875     if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5876       _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5877     else
5878       _LT_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'
5879     fi
5880     ;;
5881   pw32*)
5882     _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5883     ;;
5884   cygwin* | mingw* | cegcc*)
5885     case $cc_basename in
5886     cl*)
5887       _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5888       ;;
5889     *)
5890       _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
5891       _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5892       ;;
5893     esac
5894     ;;
5895   *)
5896     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5897     ;;
5898   esac
5899 ], [
5900   runpath_var=
5901   _LT_TAGVAR(allow_undefined_flag, $1)=
5902   _LT_TAGVAR(always_export_symbols, $1)=no
5903   _LT_TAGVAR(archive_cmds, $1)=
5904   _LT_TAGVAR(archive_expsym_cmds, $1)=
5905   _LT_TAGVAR(compiler_needs_object, $1)=no
5906   _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5907   _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5908   _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5909   _LT_TAGVAR(hardcode_automatic, $1)=no
5910   _LT_TAGVAR(hardcode_direct, $1)=no
5911   _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5912   _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5913   _LT_TAGVAR(hardcode_libdir_separator, $1)=
5914   _LT_TAGVAR(hardcode_minus_L, $1)=no
5915   _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5916   _LT_TAGVAR(inherit_rpath, $1)=no
5917   _LT_TAGVAR(link_all_deplibs, $1)=unknown
5918   _LT_TAGVAR(module_cmds, $1)=
5919   _LT_TAGVAR(module_expsym_cmds, $1)=
5920   _LT_TAGVAR(old_archive_from_new_cmds, $1)=
5921   _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5922   _LT_TAGVAR(thread_safe_flag_spec, $1)=
5923   _LT_TAGVAR(whole_archive_flag_spec, $1)=
5924   # include_expsyms should be a list of space-separated symbols to be *always*
5925   # included in the symbol list
5926   _LT_TAGVAR(include_expsyms, $1)=
5927   # exclude_expsyms can be an extended regexp of symbols to exclude
5928   # it will be wrapped by ` (' and `)$', so one must not match beginning or
5929   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5930   # as well as any symbol that contains `d'.
5931   _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5932   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5933   # platforms (ab)use it in PIC code, but their linkers get confused if
5934   # the symbol is explicitly referenced.  Since portable code cannot
5935   # rely on this symbol name, it's probably fine to never include it in
5936   # preloaded symbol tables.
5937   # Exclude shared library initialization/finalization symbols.
5938 dnl Note also adjust exclude_expsyms for C++ above.
5939   extract_expsyms_cmds=
5940
5941   case $host_os in
5942   cygwin* | mingw* | pw32* | cegcc*)
5943     # FIXME: the MSVC++ port hasn't been tested in a loooong time
5944     # When not using gcc, we currently assume that we are using
5945     # Microsoft Visual C++.
5946     if test "$GCC" != yes; then
5947       with_gnu_ld=no
5948     fi
5949     ;;
5950   interix*)
5951     # we just hope/assume this is gcc and not c89 (= MSVC++)
5952     with_gnu_ld=yes
5953     ;;
5954   openbsd*)
5955     with_gnu_ld=no
5956     ;;
5957   esac
5958
5959   _LT_TAGVAR(ld_shlibs, $1)=yes
5960
5961   # On some targets, GNU ld is compatible enough with the native linker
5962   # that we're better off using the native interface for both.
5963   lt_use_gnu_ld_interface=no
5964   if test "$with_gnu_ld" = yes; then
5965     case $host_os in
5966       aix*)
5967         # The AIX port of GNU ld has always aspired to compatibility
5968         # with the native linker.  However, as the warning in the GNU ld
5969         # block says, versions before 2.19.5* couldn't really create working
5970         # shared libraries, regardless of the interface used.
5971         case `$LD -v 2>&1` in
5972           *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
5973           *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
5974           *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
5975           *)
5976             lt_use_gnu_ld_interface=yes
5977             ;;
5978         esac
5979         ;;
5980       *)
5981         lt_use_gnu_ld_interface=yes
5982         ;;
5983     esac
5984   fi
5985
5986   if test "$lt_use_gnu_ld_interface" = yes; then
5987     # If archive_cmds runs LD, not CC, wlarc should be empty
5988     wlarc='${wl}'
5989
5990     # Set some defaults for GNU ld with shared library support. These
5991     # are reset later if shared libraries are not supported. Putting them
5992     # here allows them to be overridden if necessary.
5993     runpath_var=LD_RUN_PATH
5994     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5995     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5996     # ancient GNU ld didn't support --whole-archive et. al.
5997     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
5998       _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5999     else
6000       _LT_TAGVAR(whole_archive_flag_spec, $1)=
6001     fi
6002     supports_anon_versioning=no
6003     case `$LD -v 2>&1` in
6004       *GNU\ gold*) supports_anon_versioning=yes ;;
6005       *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6006       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6007       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6008       *\ 2.11.*) ;; # other 2.11 versions
6009       *) supports_anon_versioning=yes ;;
6010     esac
6011
6012     # See if GNU ld supports shared libraries.
6013     case $host_os in
6014     aix[[3-9]]*)
6015       # On AIX/PPC, the GNU linker is very broken
6016       if test "$host_cpu" != ia64; then
6017         _LT_TAGVAR(ld_shlibs, $1)=no
6018         cat <<_LT_EOF 1>&2
6019
6020 *** Warning: the GNU linker, at least up to release 2.19, is reported
6021 *** to be unable to reliably create shared libraries on AIX.
6022 *** Therefore, libtool is disabling shared libraries support.  If you
6023 *** really care for shared libraries, you may want to install binutils
6024 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
6025 *** You will then need to restart the configuration process.
6026
6027 _LT_EOF
6028       fi
6029       ;;
6030
6031     amigaos*)
6032       case $host_cpu in
6033       powerpc)
6034             # see comment about AmigaOS4 .so support
6035             _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6036             _LT_TAGVAR(archive_expsym_cmds, $1)=''
6037         ;;
6038       m68k)
6039             _LT_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)'
6040             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6041             _LT_TAGVAR(hardcode_minus_L, $1)=yes
6042         ;;
6043       esac
6044       ;;
6045
6046     beos*)
6047       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6048         _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6049         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6050         # support --undefined.  This deserves some investigation.  FIXME
6051         _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6052       else
6053         _LT_TAGVAR(ld_shlibs, $1)=no
6054       fi
6055       ;;
6056
6057     cygwin* | mingw* | pw32* | cegcc*)
6058       # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6059       # as there is no search path for DLLs.
6060       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6061       _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
6062       _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6063       _LT_TAGVAR(always_export_symbols, $1)=no
6064       _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6065       _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
6066       _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
6067
6068       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
6069         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6070         # If the export-symbols file already is a .def file (1st line
6071         # is EXPORTS), use it as is; otherwise, prepend...
6072         _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6073           cp $export_symbols $output_objdir/$soname.def;
6074         else
6075           echo EXPORTS > $output_objdir/$soname.def;
6076           cat $export_symbols >> $output_objdir/$soname.def;
6077         fi~
6078         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6079       else
6080         _LT_TAGVAR(ld_shlibs, $1)=no
6081       fi
6082       ;;
6083
6084     haiku*)
6085       _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6086       _LT_TAGVAR(link_all_deplibs, $1)=yes
6087       ;;
6088
6089     interix[[3-9]]*)
6090       _LT_TAGVAR(hardcode_direct, $1)=no
6091       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6092       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6093       _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6094       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6095       # Instead, shared libraries are loaded at an image base (0x10000000 by
6096       # default) and relocated if they conflict, which is a slow very memory
6097       # consuming and fragmenting process.  To avoid this, we pick a random,
6098       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6099       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
6100       _LT_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'
6101       _LT_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'
6102       ;;
6103
6104     gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
6105       tmp_diet=no
6106       if test "$host_os" = linux-dietlibc; then
6107         case $cc_basename in
6108           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
6109         esac
6110       fi
6111       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
6112          && test "$tmp_diet" = no
6113       then
6114         tmp_addflag=' $pic_flag'
6115         tmp_sharedflag='-shared'
6116         case $cc_basename,$host_cpu in
6117         pgcc*)                          # Portland Group C compiler
6118           _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6119           tmp_addflag=' $pic_flag'
6120           ;;
6121         pgf77* | pgf90* | pgf95* | pgfortran*)
6122                                         # Portland Group f77 and f90 compilers
6123           _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6124           tmp_addflag=' $pic_flag -Mnomain' ;;
6125         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
6126           tmp_addflag=' -i_dynamic' ;;
6127         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
6128           tmp_addflag=' -i_dynamic -nofor_main' ;;
6129         ifc* | ifort*)                  # Intel Fortran compiler
6130           tmp_addflag=' -nofor_main' ;;
6131         lf95*)                          # Lahey Fortran 8.1
6132           _LT_TAGVAR(whole_archive_flag_spec, $1)=
6133           tmp_sharedflag='--shared' ;;
6134         xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
6135           tmp_sharedflag='-qmkshrobj'
6136           tmp_addflag= ;;
6137         nvcc*)  # Cuda Compiler Driver 2.2
6138           _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6139           _LT_TAGVAR(compiler_needs_object, $1)=yes
6140           ;;
6141         esac
6142         case `$CC -V 2>&1 | sed 5q` in
6143         *Sun\ C*)                       # Sun C 5.9
6144           _LT_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; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6145           _LT_TAGVAR(compiler_needs_object, $1)=yes
6146           tmp_sharedflag='-G' ;;
6147         *Sun\ F*)                       # Sun Fortran 8.3
6148           tmp_sharedflag='-G' ;;
6149         esac
6150         _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6151
6152         if test "x$supports_anon_versioning" = xyes; then
6153           _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6154             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6155             echo "local: *; };" >> $output_objdir/$libname.ver~
6156             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6157         fi
6158
6159         case $cc_basename in
6160         xlf* | bgf* | bgxlf* | mpixlf*)
6161           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
6162           _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
6163           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6164           _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
6165           if test "x$supports_anon_versioning" = xyes; then
6166             _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6167               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6168               echo "local: *; };" >> $output_objdir/$libname.ver~
6169               $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
6170           fi
6171           ;;
6172         esac
6173       else
6174         _LT_TAGVAR(ld_shlibs, $1)=no
6175       fi
6176       ;;
6177
6178     netbsd*)
6179       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6180         _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6181         wlarc=
6182       else
6183         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6184         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6185       fi
6186       ;;
6187
6188     solaris*)
6189       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
6190         _LT_TAGVAR(ld_shlibs, $1)=no
6191         cat <<_LT_EOF 1>&2
6192
6193 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
6194 *** create shared libraries on Solaris systems.  Therefore, libtool
6195 *** is disabling shared libraries support.  We urge you to upgrade GNU
6196 *** binutils to release 2.9.1 or newer.  Another option is to modify
6197 *** your PATH or compiler configuration so that the native linker is
6198 *** used, and then restart.
6199
6200 _LT_EOF
6201       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6202         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6203         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6204       else
6205         _LT_TAGVAR(ld_shlibs, $1)=no
6206       fi
6207       ;;
6208
6209     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
6210       case `$LD -v 2>&1` in
6211         *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
6212         _LT_TAGVAR(ld_shlibs, $1)=no
6213         cat <<_LT_EOF 1>&2
6214
6215 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
6216 *** reliably create shared libraries on SCO systems.  Therefore, libtool
6217 *** is disabling shared libraries support.  We urge you to upgrade GNU
6218 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
6219 *** your PATH or compiler configuration so that the native linker is
6220 *** used, and then restart.
6221
6222 _LT_EOF
6223         ;;
6224         *)
6225           # For security reasons, it is highly recommended that you always
6226           # use absolute paths for naming shared libraries, and exclude the
6227           # DT_RUNPATH tag from executables and libraries.  But doing so
6228           # requires that you compile everything twice, which is a pain.
6229           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6230             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6231             _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6232             _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6233           else
6234             _LT_TAGVAR(ld_shlibs, $1)=no
6235           fi
6236         ;;
6237       esac
6238       ;;
6239
6240     sunos4*)
6241       _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6242       wlarc=
6243       _LT_TAGVAR(hardcode_direct, $1)=yes
6244       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6245       ;;
6246
6247     *)
6248       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6249         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6250         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6251       else
6252         _LT_TAGVAR(ld_shlibs, $1)=no
6253       fi
6254       ;;
6255     esac
6256
6257     if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
6258       runpath_var=
6259       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6260       _LT_TAGVAR(export_dynamic_flag_spec, $1)=
6261       _LT_TAGVAR(whole_archive_flag_spec, $1)=
6262     fi
6263   else
6264     # PORTME fill in a description of your system's linker (not GNU ld)
6265     case $host_os in
6266     aix3*)
6267       _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6268       _LT_TAGVAR(always_export_symbols, $1)=yes
6269       _LT_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'
6270       # Note: this linker hardcodes the directories in LIBPATH if there
6271       # are no directories specified by -L.
6272       _LT_TAGVAR(hardcode_minus_L, $1)=yes
6273       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
6274         # Neither direct hardcoding nor static linking is supported with a
6275         # broken collect2.
6276         _LT_TAGVAR(hardcode_direct, $1)=unsupported
6277       fi
6278       ;;
6279
6280     aix[[4-9]]*)
6281       if test "$host_cpu" = ia64; then
6282         # On IA64, the linker does run time linking by default, so we don't
6283         # have to do anything special.
6284         aix_use_runtimelinking=no
6285         exp_sym_flag='-Bexport'
6286         no_entry_flag=""
6287       else
6288         # If we're using GNU nm, then we don't want the "-C" option.
6289         # -C means demangle to AIX nm, but means don't demangle with GNU nm
6290         # Also, AIX nm treats weak defined symbols like other global
6291         # defined symbols, whereas GNU nm marks them as "W".
6292         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
6293           _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
6294         else
6295           _LT_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'
6296         fi
6297         aix_use_runtimelinking=no
6298
6299         # Test if we are trying to use run time linking or normal
6300         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6301         # need to do runtime linking.
6302         case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6303           for ld_flag in $LDFLAGS; do
6304           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6305             aix_use_runtimelinking=yes
6306             break
6307           fi
6308           done
6309           ;;
6310         esac
6311
6312         exp_sym_flag='-bexport'
6313         no_entry_flag='-bnoentry'
6314       fi
6315
6316       # When large executables or shared objects are built, AIX ld can
6317       # have problems creating the table of contents.  If linking a library
6318       # or program results in "error TOC overflow" add -mminimal-toc to
6319       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
6320       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6321
6322       _LT_TAGVAR(archive_cmds, $1)=''
6323       _LT_TAGVAR(hardcode_direct, $1)=yes
6324       _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6325       _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6326       _LT_TAGVAR(link_all_deplibs, $1)=yes
6327       _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6328
6329       if test "$GCC" = yes; then
6330         case $host_os in aix4.[[012]]|aix4.[[012]].*)
6331         # We only want to do this on AIX 4.2 and lower, the check
6332         # below for broken collect2 doesn't work under 4.3+
6333           collect2name=`${CC} -print-prog-name=collect2`
6334           if test -f "$collect2name" &&
6335            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6336           then
6337           # We have reworked collect2
6338           :
6339           else
6340           # We have old collect2
6341           _LT_TAGVAR(hardcode_direct, $1)=unsupported
6342           # It fails to find uninstalled libraries when the uninstalled
6343           # path is not listed in the libpath.  Setting hardcode_minus_L
6344           # to unsupported forces relinking
6345           _LT_TAGVAR(hardcode_minus_L, $1)=yes
6346           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6347           _LT_TAGVAR(hardcode_libdir_separator, $1)=
6348           fi
6349           ;;
6350         esac
6351         shared_flag='-shared'
6352         if test "$aix_use_runtimelinking" = yes; then
6353           shared_flag="$shared_flag "'${wl}-G'
6354         fi
6355       else
6356         # not using gcc
6357         if test "$host_cpu" = ia64; then
6358         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6359         # chokes on -Wl,-G. The following line is correct:
6360           shared_flag='-G'
6361         else
6362           if test "$aix_use_runtimelinking" = yes; then
6363             shared_flag='${wl}-G'
6364           else
6365             shared_flag='${wl}-bM:SRE'
6366           fi
6367         fi
6368       fi
6369
6370       _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6371       # It seems that -bexpall does not export symbols beginning with
6372       # underscore (_), so it is better to generate a list of symbols to export.
6373       _LT_TAGVAR(always_export_symbols, $1)=yes
6374       if test "$aix_use_runtimelinking" = yes; then
6375         # Warning - without using the other runtime loading flags (-brtl),
6376         # -berok will link without error, but may produce a broken library.
6377         _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6378         # Determine the default libpath from the value encoded in an
6379         # empty executable.
6380         _LT_SYS_MODULE_PATH_AIX([$1])
6381         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6382         _LT_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 func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6383       else
6384         if test "$host_cpu" = ia64; then
6385           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6386           _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6387           _LT_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"
6388         else
6389          # Determine the default libpath from the value encoded in an
6390          # empty executable.
6391          _LT_SYS_MODULE_PATH_AIX([$1])
6392          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6393           # Warning - without using the other run time loading flags,
6394           # -berok will link without error, but may produce a broken library.
6395           _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6396           _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6397           if test "$with_gnu_ld" = yes; then
6398             # We only use this code for GNU lds that support --whole-archive.
6399             _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6400           else
6401             # Exported symbols can be pulled into shared objects from archives
6402             _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6403           fi
6404           _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6405           # This is similar to how AIX traditionally builds its shared libraries.
6406           _LT_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'
6407         fi
6408       fi
6409       ;;
6410
6411     amigaos*)
6412       case $host_cpu in
6413       powerpc)
6414             # see comment about AmigaOS4 .so support
6415             _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6416             _LT_TAGVAR(archive_expsym_cmds, $1)=''
6417         ;;
6418       m68k)
6419             _LT_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)'
6420             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6421             _LT_TAGVAR(hardcode_minus_L, $1)=yes
6422         ;;
6423       esac
6424       ;;
6425
6426     bsdi[[45]]*)
6427       _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6428       ;;
6429
6430     cygwin* | mingw* | pw32* | cegcc*)
6431       # When not using gcc, we currently assume that we are using
6432       # Microsoft Visual C++.
6433       # hardcode_libdir_flag_spec is actually meaningless, as there is
6434       # no search path for DLLs.
6435       case $cc_basename in
6436       cl*)
6437         # Native MSVC
6438         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6439         _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6440         _LT_TAGVAR(always_export_symbols, $1)=yes
6441         _LT_TAGVAR(file_list_spec, $1)='@'
6442         # Tell ltmain to make .lib files, not .a files.
6443         libext=lib
6444         # Tell ltmain to make .dll files, not .so files.
6445         shrext_cmds=".dll"
6446         # FIXME: Setting linknames here is a bad hack.
6447         _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
6448         _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6449             sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
6450           else
6451             sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
6452           fi~
6453           $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6454           linknames='
6455         # The linker will not automatically build a static lib if we build a DLL.
6456         # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6457         _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6458         _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
6459         _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
6460         # Don't use ranlib
6461         _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6462         _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6463           lt_tool_outputfile="@TOOL_OUTPUT@"~
6464           case $lt_outputfile in
6465             *.exe|*.EXE) ;;
6466             *)
6467               lt_outputfile="$lt_outputfile.exe"
6468               lt_tool_outputfile="$lt_tool_outputfile.exe"
6469               ;;
6470           esac~
6471           if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
6472             $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6473             $RM "$lt_outputfile.manifest";
6474           fi'
6475         ;;
6476       *)
6477         # Assume MSVC wrapper
6478         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6479         _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6480         # Tell ltmain to make .lib files, not .a files.
6481         libext=lib
6482         # Tell ltmain to make .dll files, not .so files.
6483         shrext_cmds=".dll"
6484         # FIXME: Setting linknames here is a bad hack.
6485         _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
6486         # The linker will automatically build a .lib file if we build a DLL.
6487         _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6488         # FIXME: Should let the user specify the lib program.
6489         _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6490         _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6491         ;;
6492       esac
6493       ;;
6494
6495     darwin* | rhapsody*)
6496       _LT_DARWIN_LINKER_FEATURES($1)
6497       ;;
6498
6499     dgux*)
6500       _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6501       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6502       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6503       ;;
6504
6505     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6506     # support.  Future versions do this automatically, but an explicit c++rt0.o
6507     # does not break anything, and helps significantly (at the cost of a little
6508     # extra space).
6509     freebsd2.2*)
6510       _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6511       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6512       _LT_TAGVAR(hardcode_direct, $1)=yes
6513       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6514       ;;
6515
6516     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6517     freebsd2.*)
6518       _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6519       _LT_TAGVAR(hardcode_direct, $1)=yes
6520       _LT_TAGVAR(hardcode_minus_L, $1)=yes
6521       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6522       ;;
6523
6524     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6525     freebsd* | dragonfly*)
6526       _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6527       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6528       _LT_TAGVAR(hardcode_direct, $1)=yes
6529       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6530       ;;
6531
6532     hpux9*)
6533       if test "$GCC" = yes; then
6534         _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6535       else
6536         _LT_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'
6537       fi
6538       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6539       _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6540       _LT_TAGVAR(hardcode_direct, $1)=yes
6541
6542       # hardcode_minus_L: Not really in the search PATH,
6543       # but as the default location of the library.
6544       _LT_TAGVAR(hardcode_minus_L, $1)=yes
6545       _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6546       ;;
6547
6548     hpux10*)
6549       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
6550         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6551       else
6552         _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6553       fi
6554       if test "$with_gnu_ld" = no; then
6555         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6556         _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6557         _LT_TAGVAR(hardcode_direct, $1)=yes
6558         _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6559         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6560         # hardcode_minus_L: Not really in the search PATH,
6561         # but as the default location of the library.
6562         _LT_TAGVAR(hardcode_minus_L, $1)=yes
6563       fi
6564       ;;
6565
6566     hpux11*)
6567       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
6568         case $host_cpu in
6569         hppa*64*)
6570           _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6571           ;;
6572         ia64*)
6573           _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6574           ;;
6575         *)
6576           _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6577           ;;
6578         esac
6579       else
6580         case $host_cpu in
6581         hppa*64*)
6582           _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6583           ;;
6584         ia64*)
6585           _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6586           ;;
6587         *)
6588         m4_if($1, [], [
6589           # Older versions of the 11.00 compiler do not understand -b yet
6590           # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
6591           _LT_LINKER_OPTION([if $CC understands -b],
6592             _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
6593             [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
6594             [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
6595           [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
6596           ;;
6597         esac
6598       fi
6599       if test "$with_gnu_ld" = no; then
6600         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6601         _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6602
6603         case $host_cpu in
6604         hppa*64*|ia64*)
6605           _LT_TAGVAR(hardcode_direct, $1)=no
6606           _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6607           ;;
6608         *)
6609           _LT_TAGVAR(hardcode_direct, $1)=yes
6610           _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6611           _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6612
6613           # hardcode_minus_L: Not really in the search PATH,
6614           # but as the default location of the library.
6615           _LT_TAGVAR(hardcode_minus_L, $1)=yes
6616           ;;
6617         esac
6618       fi
6619       ;;
6620
6621     irix5* | irix6* | nonstopux*)
6622       if test "$GCC" = yes; then
6623         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6624         # Try to use the -exported_symbol ld option, if it does not
6625         # work, assume that -exports_file does not work either and
6626         # implicitly export all symbols.
6627         # This should be the same for all languages, so no per-tag cache variable.
6628         AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
6629           [lt_cv_irix_exported_symbol],
6630           [save_LDFLAGS="$LDFLAGS"
6631            LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
6632            AC_LINK_IFELSE(
6633              [AC_LANG_SOURCE(
6634                 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
6635                               [C++], [[int foo (void) { return 0; }]],
6636                               [Fortran 77], [[
6637       subroutine foo
6638       end]],
6639                               [Fortran], [[
6640       subroutine foo
6641       end]])])],
6642               [lt_cv_irix_exported_symbol=yes],
6643               [lt_cv_irix_exported_symbol=no])
6644            LDFLAGS="$save_LDFLAGS"])
6645         if test "$lt_cv_irix_exported_symbol" = yes; then
6646           _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
6647         fi
6648       else
6649         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6650         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
6651       fi
6652       _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6653       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6654       _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6655       _LT_TAGVAR(inherit_rpath, $1)=yes
6656       _LT_TAGVAR(link_all_deplibs, $1)=yes
6657       ;;
6658
6659     netbsd*)
6660       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6661         _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
6662       else
6663         _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
6664       fi
6665       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6666       _LT_TAGVAR(hardcode_direct, $1)=yes
6667       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6668       ;;
6669
6670     newsos6)
6671       _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6672       _LT_TAGVAR(hardcode_direct, $1)=yes
6673       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6674       _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6675       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6676       ;;
6677
6678     *nto* | *qnx*)
6679       ;;
6680
6681     openbsd*)
6682       if test -f /usr/libexec/ld.so; then
6683         _LT_TAGVAR(hardcode_direct, $1)=yes
6684         _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6685         _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6686         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6687           _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6688           _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6689           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6690           _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6691         else
6692           case $host_os in
6693            openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6694              _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6695              _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6696              ;;
6697            *)
6698              _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6699              _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6700              ;;
6701           esac
6702         fi
6703       else
6704         _LT_TAGVAR(ld_shlibs, $1)=no
6705       fi
6706       ;;
6707
6708     os2*)
6709       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6710       _LT_TAGVAR(hardcode_minus_L, $1)=yes
6711       _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6712       _LT_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'
6713       _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6714       ;;
6715
6716     osf3*)
6717       if test "$GCC" = yes; then
6718         _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6719         _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6720       else
6721         _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6722         _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6723       fi
6724       _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6725       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6726       _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6727       ;;
6728
6729     osf4* | osf5*)      # as osf3* with the addition of -msym flag
6730       if test "$GCC" = yes; then
6731         _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6732         _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6733         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6734       else
6735         _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6736         _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6737         _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
6738         $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
6739
6740         # Both c and cxx compiler support -rpath directly
6741         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6742       fi
6743       _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6744       _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6745       ;;
6746
6747     solaris*)
6748       _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
6749       if test "$GCC" = yes; then
6750         wlarc='${wl}'
6751         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6752         _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6753           $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6754       else
6755         case `$CC -V 2>&1` in
6756         *"Compilers 5.0"*)
6757           wlarc=''
6758           _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6759           _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6760           $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
6761           ;;
6762         *)
6763           wlarc='${wl}'
6764           _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
6765           _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6766           $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6767           ;;
6768         esac
6769       fi
6770       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6771       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6772       case $host_os in
6773       solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6774       *)
6775         # The compiler driver will combine and reorder linker options,
6776         # but understands `-z linker_flag'.  GCC discards it without `$wl',
6777         # but is careful enough not to reorder.
6778         # Supported since Solaris 2.6 (maybe 2.5.1?)
6779         if test "$GCC" = yes; then
6780           _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6781         else
6782           _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6783         fi
6784         ;;
6785       esac
6786       _LT_TAGVAR(link_all_deplibs, $1)=yes
6787       ;;
6788
6789     sunos4*)
6790       if test "x$host_vendor" = xsequent; then
6791         # Use $CC to link under sequent, because it throws in some extra .o
6792         # files that make .init and .fini sections work.
6793         _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6794       else
6795         _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6796       fi
6797       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6798       _LT_TAGVAR(hardcode_direct, $1)=yes
6799       _LT_TAGVAR(hardcode_minus_L, $1)=yes
6800       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6801       ;;
6802
6803     sysv4)
6804       case $host_vendor in
6805         sni)
6806           _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6807           _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6808         ;;
6809         siemens)
6810           ## LD is ld it makes a PLAMLIB
6811           ## CC just makes a GrossModule.
6812           _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6813           _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6814           _LT_TAGVAR(hardcode_direct, $1)=no
6815         ;;
6816         motorola)
6817           _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6818           _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6819         ;;
6820       esac
6821       runpath_var='LD_RUN_PATH'
6822       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6823       ;;
6824
6825     sysv4.3*)
6826       _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6827       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6828       _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6829       ;;
6830
6831     sysv4*MP*)
6832       if test -d /usr/nec; then
6833         _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6834         _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6835         runpath_var=LD_RUN_PATH
6836         hardcode_runpath_var=yes
6837         _LT_TAGVAR(ld_shlibs, $1)=yes
6838       fi
6839       ;;
6840
6841     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6842       _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6843       _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6844       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6845       runpath_var='LD_RUN_PATH'
6846
6847       if test "$GCC" = yes; then
6848         _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6849         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6850       else
6851         _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6852         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6853       fi
6854       ;;
6855
6856     sysv5* | sco3.2v5* | sco5v6*)
6857       # Note: We can NOT use -z defs as we might desire, because we do not
6858       # link with -lc, and that would cause any symbols used from libc to
6859       # always be unresolved, which means just about no library would
6860       # ever link correctly.  If we're not using GNU ld we use -z text
6861       # though, which does catch some bad symbols but isn't as heavy-handed
6862       # as -z defs.
6863       _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6864       _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6865       _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6866       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6867       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6868       _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6869       _LT_TAGVAR(link_all_deplibs, $1)=yes
6870       _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6871       runpath_var='LD_RUN_PATH'
6872
6873       if test "$GCC" = yes; then
6874         _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6875         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6876       else
6877         _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6878         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6879       fi
6880       ;;
6881
6882     uts4*)
6883       _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6884       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6885       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6886       ;;
6887
6888     *)
6889       _LT_TAGVAR(ld_shlibs, $1)=no
6890       ;;
6891     esac
6892
6893     if test x$host_vendor = xsni; then
6894       case $host in
6895       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6896         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
6897         ;;
6898       esac
6899     fi
6900   fi
6901 ])
6902 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6903 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6904
6905 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
6906
6907 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
6908 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
6909 _LT_DECL([], [extract_expsyms_cmds], [2],
6910     [The commands to extract the exported symbol list from a shared archive])
6911
6912 #
6913 # Do we need to explicitly link libc?
6914 #
6915 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
6916 x|xyes)
6917   # Assume -lc should be added
6918   _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6919
6920   if test "$enable_shared" = yes && test "$GCC" = yes; then
6921     case $_LT_TAGVAR(archive_cmds, $1) in
6922     *'~'*)
6923       # FIXME: we may have to deal with multi-command sequences.
6924       ;;
6925     '$CC '*)
6926       # Test whether the compiler implicitly links with -lc since on some
6927       # systems, -lgcc has to come before -lc. If gcc already passes -lc
6928       # to ld, don't add -lc before -lgcc.
6929       AC_CACHE_CHECK([whether -lc should be explicitly linked in],
6930         [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
6931         [$RM conftest*
6932         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6933
6934         if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6935           soname=conftest
6936           lib=conftest
6937           libobjs=conftest.$ac_objext
6938           deplibs=
6939           wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
6940           pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
6941           compiler_flags=-v
6942           linker_flags=-v
6943           verstring=
6944           output_objdir=.
6945           libname=conftest
6946           lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
6947           _LT_TAGVAR(allow_undefined_flag, $1)=
6948           if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
6949           then
6950             lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6951           else
6952             lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6953           fi
6954           _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6955         else
6956           cat conftest.err 1>&5
6957         fi
6958         $RM conftest*
6959         ])
6960       _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
6961       ;;
6962     esac
6963   fi
6964   ;;
6965 esac
6966
6967 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
6968     [Whether or not to add -lc for building shared libraries])
6969 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
6970     [enable_shared_with_static_runtimes], [0],
6971     [Whether or not to disallow shared libs when runtime libs are static])
6972 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
6973     [Compiler flag to allow reflexive dlopens])
6974 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
6975     [Compiler flag to generate shared objects directly from archives])
6976 _LT_TAGDECL([], [compiler_needs_object], [1],
6977     [Whether the compiler copes with passing no objects directly])
6978 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
6979     [Create an old-style archive from a shared archive])
6980 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
6981     [Create a temporary old-style archive to link instead of a shared archive])
6982 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
6983 _LT_TAGDECL([], [archive_expsym_cmds], [2])
6984 _LT_TAGDECL([], [module_cmds], [2],
6985     [Commands used to build a loadable module if different from building
6986     a shared archive.])
6987 _LT_TAGDECL([], [module_expsym_cmds], [2])
6988 _LT_TAGDECL([], [with_gnu_ld], [1],
6989     [Whether we are building with GNU ld or not])
6990 _LT_TAGDECL([], [allow_undefined_flag], [1],
6991     [Flag that allows shared libraries with undefined symbols to be built])
6992 _LT_TAGDECL([], [no_undefined_flag], [1],
6993     [Flag that enforces no undefined symbols])
6994 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
6995     [Flag to hardcode $libdir into a binary during linking.
6996     This must work even if $libdir does not exist])
6997 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
6998     [Whether we need a single "-rpath" flag with a separated argument])
6999 _LT_TAGDECL([], [hardcode_direct], [0],
7000     [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
7001     DIR into the resulting binary])
7002 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
7003     [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
7004     DIR into the resulting binary and the resulting library dependency is
7005     "absolute", i.e impossible to change by setting ${shlibpath_var} if the
7006     library is relocated])
7007 _LT_TAGDECL([], [hardcode_minus_L], [0],
7008     [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
7009     into the resulting binary])
7010 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
7011     [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
7012     into the resulting binary])
7013 _LT_TAGDECL([], [hardcode_automatic], [0],
7014     [Set to "yes" if building a shared library automatically hardcodes DIR
7015     into the library and all subsequent libraries and executables linked
7016     against it])
7017 _LT_TAGDECL([], [inherit_rpath], [0],
7018     [Set to yes if linker adds runtime paths of dependent libraries
7019     to runtime path list])
7020 _LT_TAGDECL([], [link_all_deplibs], [0],
7021     [Whether libtool must link a program against all its dependency libraries])
7022 _LT_TAGDECL([], [always_export_symbols], [0],
7023     [Set to "yes" if exported symbols are required])
7024 _LT_TAGDECL([], [export_symbols_cmds], [2],
7025     [The commands to list exported symbols])
7026 _LT_TAGDECL([], [exclude_expsyms], [1],
7027     [Symbols that should not be listed in the preloaded symbols])
7028 _LT_TAGDECL([], [include_expsyms], [1],
7029     [Symbols that must always be exported])
7030 _LT_TAGDECL([], [prelink_cmds], [2],
7031     [Commands necessary for linking programs (against libraries) with templates])
7032 _LT_TAGDECL([], [postlink_cmds], [2],
7033     [Commands necessary for finishing linking programs])
7034 _LT_TAGDECL([], [file_list_spec], [1],
7035     [Specify filename containing input files])
7036 dnl FIXME: Not yet implemented
7037 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
7038 dnl    [Compiler flag to generate thread safe objects])
7039 ])# _LT_LINKER_SHLIBS
7040
7041
7042 # _LT_LANG_C_CONFIG([TAG])
7043 # ------------------------
7044 # Ensure that the configuration variables for a C compiler are suitably
7045 # defined.  These variables are subsequently used by _LT_CONFIG to write
7046 # the compiler configuration to `libtool'.
7047 m4_defun([_LT_LANG_C_CONFIG],
7048 [m4_require([_LT_DECL_EGREP])dnl
7049 lt_save_CC="$CC"
7050 AC_LANG_PUSH(C)
7051
7052 # Source file extension for C test sources.
7053 ac_ext=c
7054
7055 # Object file extension for compiled C test sources.
7056 objext=o
7057 _LT_TAGVAR(objext, $1)=$objext
7058
7059 # Code to be used in simple compile tests
7060 lt_simple_compile_test_code="int some_variable = 0;"
7061
7062 # Code to be used in simple link tests
7063 lt_simple_link_test_code='int main(){return(0);}'
7064
7065 _LT_TAG_COMPILER
7066 # Save the default compiler, since it gets overwritten when the other
7067 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
7068 compiler_DEFAULT=$CC
7069
7070 # save warnings/boilerplate of simple test code
7071 _LT_COMPILER_BOILERPLATE
7072 _LT_LINKER_BOILERPLATE
7073
7074 if test -n "$compiler"; then
7075   _LT_COMPILER_NO_RTTI($1)
7076   _LT_COMPILER_PIC($1)
7077   _LT_COMPILER_C_O($1)
7078   _LT_COMPILER_FILE_LOCKS($1)
7079   _LT_LINKER_SHLIBS($1)
7080   _LT_SYS_DYNAMIC_LINKER($1)
7081   _LT_LINKER_HARDCODE_LIBPATH($1)
7082   LT_SYS_DLOPEN_SELF
7083   _LT_CMD_STRIPLIB
7084
7085   # Report which library types will actually be built
7086   AC_MSG_CHECKING([if libtool supports shared libraries])
7087   AC_MSG_RESULT([$can_build_shared])
7088
7089   AC_MSG_CHECKING([whether to build shared libraries])
7090   test "$can_build_shared" = "no" && enable_shared=no
7091
7092   # On AIX, shared libraries and static libraries use the same namespace, and
7093   # are all built from PIC.
7094   case $host_os in
7095   aix3*)
7096     test "$enable_shared" = yes && enable_static=no
7097     if test -n "$RANLIB"; then
7098       archive_cmds="$archive_cmds~\$RANLIB \$lib"
7099       postinstall_cmds='$RANLIB $lib'
7100     fi
7101     ;;
7102
7103   aix[[4-9]]*)
7104     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7105       test "$enable_shared" = yes && enable_static=no
7106     fi
7107     ;;
7108   esac
7109   AC_MSG_RESULT([$enable_shared])
7110
7111   AC_MSG_CHECKING([whether to build static libraries])
7112   # Make sure either enable_shared or enable_static is yes.
7113   test "$enable_shared" = yes || enable_static=yes
7114   AC_MSG_RESULT([$enable_static])
7115
7116   _LT_CONFIG($1)
7117 fi
7118 AC_LANG_POP
7119 CC="$lt_save_CC"
7120 ])# _LT_LANG_C_CONFIG
7121
7122
7123 # _LT_LANG_CXX_CONFIG([TAG])
7124 # --------------------------
7125 # Ensure that the configuration variables for a C++ compiler are suitably
7126 # defined.  These variables are subsequently used by _LT_CONFIG to write
7127 # the compiler configuration to `libtool'.
7128 m4_defun([_LT_LANG_CXX_CONFIG],
7129 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7130 m4_require([_LT_DECL_EGREP])dnl
7131 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
7132 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
7133     ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
7134     (test "X$CXX" != "Xg++"))) ; then
7135   AC_PROG_CXXCPP
7136 else
7137   _lt_caught_CXX_error=yes
7138 fi
7139
7140 AC_LANG_PUSH(C++)
7141 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7142 _LT_TAGVAR(allow_undefined_flag, $1)=
7143 _LT_TAGVAR(always_export_symbols, $1)=no
7144 _LT_TAGVAR(archive_expsym_cmds, $1)=
7145 _LT_TAGVAR(compiler_needs_object, $1)=no
7146 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7147 _LT_TAGVAR(hardcode_direct, $1)=no
7148 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7149 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7150 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7151 _LT_TAGVAR(hardcode_minus_L, $1)=no
7152 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
7153 _LT_TAGVAR(hardcode_automatic, $1)=no
7154 _LT_TAGVAR(inherit_rpath, $1)=no
7155 _LT_TAGVAR(module_cmds, $1)=
7156 _LT_TAGVAR(module_expsym_cmds, $1)=
7157 _LT_TAGVAR(link_all_deplibs, $1)=unknown
7158 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7159 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7160 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7161 _LT_TAGVAR(no_undefined_flag, $1)=
7162 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7163 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7164
7165 # Source file extension for C++ test sources.
7166 ac_ext=cpp
7167
7168 # Object file extension for compiled C++ test sources.
7169 objext=o
7170 _LT_TAGVAR(objext, $1)=$objext
7171
7172 # No sense in running all these tests if we already determined that
7173 # the CXX compiler isn't working.  Some variables (like enable_shared)
7174 # are currently assumed to apply to all compilers on this platform,
7175 # and will be corrupted by setting them based on a non-working compiler.
7176 if test "$_lt_caught_CXX_error" != yes; then
7177   # Code to be used in simple compile tests
7178   lt_simple_compile_test_code="int some_variable = 0;"
7179
7180   # Code to be used in simple link tests
7181   lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
7182
7183   # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7184   _LT_TAG_COMPILER
7185
7186   # save warnings/boilerplate of simple test code
7187   _LT_COMPILER_BOILERPLATE
7188   _LT_LINKER_BOILERPLATE
7189
7190   # Allow CC to be a program name with arguments.
7191   lt_save_CC=$CC
7192   lt_save_CFLAGS=$CFLAGS
7193   lt_save_LD=$LD
7194   lt_save_GCC=$GCC
7195   GCC=$GXX
7196   lt_save_with_gnu_ld=$with_gnu_ld
7197   lt_save_path_LD=$lt_cv_path_LD
7198   if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
7199     lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
7200   else
7201     $as_unset lt_cv_prog_gnu_ld
7202   fi
7203   if test -n "${lt_cv_path_LDCXX+set}"; then
7204     lt_cv_path_LD=$lt_cv_path_LDCXX
7205   else
7206     $as_unset lt_cv_path_LD
7207   fi
7208   test -z "${LDCXX+set}" || LD=$LDCXX
7209   CC=${CXX-"c++"}
7210   CFLAGS=$CXXFLAGS
7211   compiler=$CC
7212   _LT_TAGVAR(compiler, $1)=$CC
7213   _LT_CC_BASENAME([$compiler])
7214
7215   if test -n "$compiler"; then
7216     # We don't want -fno-exception when compiling C++ code, so set the
7217     # no_builtin_flag separately
7218     if test "$GXX" = yes; then
7219       _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
7220     else
7221       _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
7222     fi
7223
7224     if test "$GXX" = yes; then
7225       # Set up default GNU C++ configuration
7226
7227       LT_PATH_LD
7228
7229       # Check if GNU C++ uses GNU ld as the underlying linker, since the
7230       # archiving commands below assume that GNU ld is being used.
7231       if test "$with_gnu_ld" = yes; then
7232         _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7233         _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7234
7235         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7236         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7237
7238         # If archive_cmds runs LD, not CC, wlarc should be empty
7239         # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
7240         #     investigate it a little bit more. (MM)
7241         wlarc='${wl}'
7242
7243         # ancient GNU ld didn't support --whole-archive et. al.
7244         if eval "`$CC -print-prog-name=ld` --help 2>&1" |
7245           $GREP 'no-whole-archive' > /dev/null; then
7246           _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7247         else
7248           _LT_TAGVAR(whole_archive_flag_spec, $1)=
7249         fi
7250       else
7251         with_gnu_ld=no
7252         wlarc=
7253
7254         # A generic and very simple default shared library creation
7255         # command for GNU C++ for the case where it uses the native
7256         # linker, instead of GNU ld.  If possible, this setting should
7257         # overridden to take advantage of the native linker features on
7258         # the platform it is being used on.
7259         _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7260       fi
7261
7262       # Commands to make compiler produce verbose output that lists
7263       # what "hidden" libraries, object files and flags are used when
7264       # linking a shared library.
7265       output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7266
7267     else
7268       GXX=no
7269       with_gnu_ld=no
7270       wlarc=
7271     fi
7272
7273     # PORTME: fill in a description of your system's C++ link characteristics
7274     AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
7275     _LT_TAGVAR(ld_shlibs, $1)=yes
7276     case $host_os in
7277       aix3*)
7278         # FIXME: insert proper C++ library support
7279         _LT_TAGVAR(ld_shlibs, $1)=no
7280         ;;
7281       aix[[4-9]]*)
7282         if test "$host_cpu" = ia64; then
7283           # On IA64, the linker does run time linking by default, so we don't
7284           # have to do anything special.
7285           aix_use_runtimelinking=no
7286           exp_sym_flag='-Bexport'
7287           no_entry_flag=""
7288         else
7289           aix_use_runtimelinking=no
7290
7291           # Test if we are trying to use run time linking or normal
7292           # AIX style linking. If -brtl is somewhere in LDFLAGS, we
7293           # need to do runtime linking.
7294           case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
7295             for ld_flag in $LDFLAGS; do
7296               case $ld_flag in
7297               *-brtl*)
7298                 aix_use_runtimelinking=yes
7299                 break
7300                 ;;
7301               esac
7302             done
7303             ;;
7304           esac
7305
7306           exp_sym_flag='-bexport'
7307           no_entry_flag='-bnoentry'
7308         fi
7309
7310         # When large executables or shared objects are built, AIX ld can
7311         # have problems creating the table of contents.  If linking a library
7312         # or program results in "error TOC overflow" add -mminimal-toc to
7313         # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
7314         # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
7315
7316         _LT_TAGVAR(archive_cmds, $1)=''
7317         _LT_TAGVAR(hardcode_direct, $1)=yes
7318         _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7319         _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7320         _LT_TAGVAR(link_all_deplibs, $1)=yes
7321         _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
7322
7323         if test "$GXX" = yes; then
7324           case $host_os in aix4.[[012]]|aix4.[[012]].*)
7325           # We only want to do this on AIX 4.2 and lower, the check
7326           # below for broken collect2 doesn't work under 4.3+
7327           collect2name=`${CC} -print-prog-name=collect2`
7328           if test -f "$collect2name" &&
7329              strings "$collect2name" | $GREP resolve_lib_name >/dev/null
7330           then
7331             # We have reworked collect2
7332             :
7333           else
7334             # We have old collect2
7335             _LT_TAGVAR(hardcode_direct, $1)=unsupported
7336             # It fails to find uninstalled libraries when the uninstalled
7337             # path is not listed in the libpath.  Setting hardcode_minus_L
7338             # to unsupported forces relinking
7339             _LT_TAGVAR(hardcode_minus_L, $1)=yes
7340             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7341             _LT_TAGVAR(hardcode_libdir_separator, $1)=
7342           fi
7343           esac
7344           shared_flag='-shared'
7345           if test "$aix_use_runtimelinking" = yes; then
7346             shared_flag="$shared_flag "'${wl}-G'
7347           fi
7348         else
7349           # not using gcc
7350           if test "$host_cpu" = ia64; then
7351           # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
7352           # chokes on -Wl,-G. The following line is correct:
7353           shared_flag='-G'
7354           else
7355             if test "$aix_use_runtimelinking" = yes; then
7356               shared_flag='${wl}-G'
7357             else
7358               shared_flag='${wl}-bM:SRE'
7359             fi
7360           fi
7361         fi
7362
7363         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
7364         # It seems that -bexpall does not export symbols beginning with
7365         # underscore (_), so it is better to generate a list of symbols to
7366         # export.
7367         _LT_TAGVAR(always_export_symbols, $1)=yes
7368         if test "$aix_use_runtimelinking" = yes; then
7369           # Warning - without using the other runtime loading flags (-brtl),
7370           # -berok will link without error, but may produce a broken library.
7371           _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
7372           # Determine the default libpath from the value encoded in an empty
7373           # executable.
7374           _LT_SYS_MODULE_PATH_AIX([$1])
7375           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7376
7377           _LT_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 func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
7378         else
7379           if test "$host_cpu" = ia64; then
7380             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
7381             _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7382             _LT_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"
7383           else
7384             # Determine the default libpath from the value encoded in an
7385             # empty executable.
7386             _LT_SYS_MODULE_PATH_AIX([$1])
7387             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7388             # Warning - without using the other run time loading flags,
7389             # -berok will link without error, but may produce a broken library.
7390             _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
7391             _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
7392             if test "$with_gnu_ld" = yes; then
7393               # We only use this code for GNU lds that support --whole-archive.
7394               _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7395             else
7396               # Exported symbols can be pulled into shared objects from archives
7397               _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
7398             fi
7399             _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
7400             # This is similar to how AIX traditionally builds its shared
7401             # libraries.
7402             _LT_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'
7403           fi
7404         fi
7405         ;;
7406
7407       beos*)
7408         if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7409           _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7410           # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
7411           # support --undefined.  This deserves some investigation.  FIXME
7412           _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7413         else
7414           _LT_TAGVAR(ld_shlibs, $1)=no
7415         fi
7416         ;;
7417
7418       chorus*)
7419         case $cc_basename in
7420           *)
7421           # FIXME: insert proper C++ library support
7422           _LT_TAGVAR(ld_shlibs, $1)=no
7423           ;;
7424         esac
7425         ;;
7426
7427       cygwin* | mingw* | pw32* | cegcc*)
7428         case $GXX,$cc_basename in
7429         ,cl* | no,cl*)
7430           # Native MSVC
7431           # hardcode_libdir_flag_spec is actually meaningless, as there is
7432           # no search path for DLLs.
7433           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
7434           _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7435           _LT_TAGVAR(always_export_symbols, $1)=yes
7436           _LT_TAGVAR(file_list_spec, $1)='@'
7437           # Tell ltmain to make .lib files, not .a files.
7438           libext=lib
7439           # Tell ltmain to make .dll files, not .so files.
7440           shrext_cmds=".dll"
7441           # FIXME: Setting linknames here is a bad hack.
7442           _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
7443           _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7444               $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
7445             else
7446               $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
7447             fi~
7448             $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
7449             linknames='
7450           # The linker will not automatically build a static lib if we build a DLL.
7451           # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
7452           _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7453           # Don't use ranlib
7454           _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
7455           _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
7456             lt_tool_outputfile="@TOOL_OUTPUT@"~
7457             case $lt_outputfile in
7458               *.exe|*.EXE) ;;
7459               *)
7460                 lt_outputfile="$lt_outputfile.exe"
7461                 lt_tool_outputfile="$lt_tool_outputfile.exe"
7462                 ;;
7463             esac~
7464             func_to_tool_file "$lt_outputfile"~
7465             if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
7466               $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
7467               $RM "$lt_outputfile.manifest";
7468             fi'
7469           ;;
7470         *)
7471           # g++
7472           # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
7473           # as there is no search path for DLLs.
7474           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7475           _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
7476           _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7477           _LT_TAGVAR(always_export_symbols, $1)=no
7478           _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7479
7480           if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7481             _LT_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'
7482             # If the export-symbols file already is a .def file (1st line
7483             # is EXPORTS), use it as is; otherwise, prepend...
7484             _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7485               cp $export_symbols $output_objdir/$soname.def;
7486             else
7487               echo EXPORTS > $output_objdir/$soname.def;
7488               cat $export_symbols >> $output_objdir/$soname.def;
7489             fi~
7490             $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'
7491           else
7492             _LT_TAGVAR(ld_shlibs, $1)=no
7493           fi
7494           ;;
7495         esac
7496         ;;
7497       darwin* | rhapsody*)
7498         _LT_DARWIN_LINKER_FEATURES($1)
7499         ;;
7500
7501       dgux*)
7502         case $cc_basename in
7503           ec++*)
7504             # FIXME: insert proper C++ library support
7505             _LT_TAGVAR(ld_shlibs, $1)=no
7506             ;;
7507           ghcx*)
7508             # Green Hills C++ Compiler
7509             # FIXME: insert proper C++ library support
7510             _LT_TAGVAR(ld_shlibs, $1)=no
7511             ;;
7512           *)
7513             # FIXME: insert proper C++ library support
7514             _LT_TAGVAR(ld_shlibs, $1)=no
7515             ;;
7516         esac
7517         ;;
7518
7519       freebsd2.*)
7520         # C++ shared libraries reported to be fairly broken before
7521         # switch to ELF
7522         _LT_TAGVAR(ld_shlibs, $1)=no
7523         ;;
7524
7525       freebsd-elf*)
7526         _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7527         ;;
7528
7529       freebsd* | dragonfly*)
7530         # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
7531         # conventions
7532         _LT_TAGVAR(ld_shlibs, $1)=yes
7533         ;;
7534
7535       gnu*)
7536         ;;
7537
7538       haiku*)
7539         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7540         _LT_TAGVAR(link_all_deplibs, $1)=yes
7541         ;;
7542
7543       hpux9*)
7544         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7545         _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7546         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7547         _LT_TAGVAR(hardcode_direct, $1)=yes
7548         _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7549                                              # but as the default
7550                                              # location of the library.
7551
7552         case $cc_basename in
7553           CC*)
7554             # FIXME: insert proper C++ library support
7555             _LT_TAGVAR(ld_shlibs, $1)=no
7556             ;;
7557           aCC*)
7558             _LT_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'
7559             # Commands to make compiler produce verbose output that lists
7560             # what "hidden" libraries, object files and flags are used when
7561             # linking a shared library.
7562             #
7563             # There doesn't appear to be a way to prevent this compiler from
7564             # explicitly linking system object files so we need to strip them
7565             # from the output so that they don't get included in the library
7566             # dependencies.
7567             output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
7568             ;;
7569           *)
7570             if test "$GXX" = yes; then
7571               _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${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'
7572             else
7573               # FIXME: insert proper C++ library support
7574               _LT_TAGVAR(ld_shlibs, $1)=no
7575             fi
7576             ;;
7577         esac
7578         ;;
7579
7580       hpux10*|hpux11*)
7581         if test $with_gnu_ld = no; then
7582           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7583           _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7584
7585           case $host_cpu in
7586             hppa*64*|ia64*)
7587               ;;
7588             *)
7589               _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7590               ;;
7591           esac
7592         fi
7593         case $host_cpu in
7594           hppa*64*|ia64*)
7595             _LT_TAGVAR(hardcode_direct, $1)=no
7596             _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7597             ;;
7598           *)
7599             _LT_TAGVAR(hardcode_direct, $1)=yes
7600             _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7601             _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7602                                                  # but as the default
7603                                                  # location of the library.
7604             ;;
7605         esac
7606
7607         case $cc_basename in
7608           CC*)
7609             # FIXME: insert proper C++ library support
7610             _LT_TAGVAR(ld_shlibs, $1)=no
7611             ;;
7612           aCC*)
7613             case $host_cpu in
7614               hppa*64*)
7615                 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7616                 ;;
7617               ia64*)
7618                 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7619                 ;;
7620               *)
7621                 _LT_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'
7622                 ;;
7623             esac
7624             # Commands to make compiler produce verbose output that lists
7625             # what "hidden" libraries, object files and flags are used when
7626             # linking a shared library.
7627             #
7628             # There doesn't appear to be a way to prevent this compiler from
7629             # explicitly linking system object files so we need to strip them
7630             # from the output so that they don't get included in the library
7631             # dependencies.
7632             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; func_echo_all "$list"'
7633             ;;
7634           *)
7635             if test "$GXX" = yes; then
7636               if test $with_gnu_ld = no; then
7637                 case $host_cpu in
7638                   hppa*64*)
7639                     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7640                     ;;
7641                   ia64*)
7642                     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7643                     ;;
7644                   *)
7645                     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7646                     ;;
7647                 esac
7648               fi
7649             else
7650               # FIXME: insert proper C++ library support
7651               _LT_TAGVAR(ld_shlibs, $1)=no
7652             fi
7653             ;;
7654         esac
7655         ;;
7656
7657       interix[[3-9]]*)
7658         _LT_TAGVAR(hardcode_direct, $1)=no
7659         _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7660         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7661         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7662         # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
7663         # Instead, shared libraries are loaded at an image base (0x10000000 by
7664         # default) and relocated if they conflict, which is a slow very memory
7665         # consuming and fragmenting process.  To avoid this, we pick a random,
7666         # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
7667         # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
7668         _LT_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'
7669         _LT_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'
7670         ;;
7671       irix5* | irix6*)
7672         case $cc_basename in
7673           CC*)
7674             # SGI C++
7675             _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
7676
7677             # Archives containing C++ object files must be created using
7678             # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
7679             # necessary to make sure instantiated templates are included
7680             # in the archive.
7681             _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
7682             ;;
7683           *)
7684             if test "$GXX" = yes; then
7685               if test "$with_gnu_ld" = no; then
7686                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7687               else
7688                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
7689               fi
7690             fi
7691             _LT_TAGVAR(link_all_deplibs, $1)=yes
7692             ;;
7693         esac
7694         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7695         _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7696         _LT_TAGVAR(inherit_rpath, $1)=yes
7697         ;;
7698
7699       linux* | k*bsd*-gnu | kopensolaris*-gnu)
7700         case $cc_basename in
7701           KCC*)
7702             # Kuck and Associates, Inc. (KAI) C++ Compiler
7703
7704             # KCC will only create a shared library if the output file
7705             # ends with ".so" (or ".sl" for HP-UX), so rename the library
7706             # to its proper name (with version) after linking.
7707             _LT_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'
7708             _LT_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'
7709             # Commands to make compiler produce verbose output that lists
7710             # what "hidden" libraries, object files and flags are used when
7711             # linking a shared library.
7712             #
7713             # There doesn't appear to be a way to prevent this compiler from
7714             # explicitly linking system object files so we need to strip them
7715             # from the output so that they don't get included in the library
7716             # dependencies.
7717             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; func_echo_all "$list"'
7718
7719             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7720             _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7721
7722             # Archives containing C++ object files must be created using
7723             # "CC -Bstatic", where "CC" is the KAI C++ compiler.
7724             _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
7725             ;;
7726           icpc* | ecpc* )
7727             # Intel C++
7728             with_gnu_ld=yes
7729             # version 8.0 and above of icpc choke on multiply defined symbols
7730             # if we add $predep_objects and $postdep_objects, however 7.1 and
7731             # earlier do not add the objects themselves.
7732             case `$CC -V 2>&1` in
7733               *"Version 7."*)
7734                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7735                 _LT_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'
7736                 ;;
7737               *)  # Version 8.0 or newer
7738                 tmp_idyn=
7739                 case $host_cpu in
7740                   ia64*) tmp_idyn=' -i_dynamic';;
7741                 esac
7742                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7743                 _LT_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'
7744                 ;;
7745             esac
7746             _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7747             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7748             _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7749             _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7750             ;;
7751           pgCC* | pgcpp*)
7752             # Portland Group C++ compiler
7753             case `$CC -V` in
7754             *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
7755               _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
7756                 rm -rf $tpldir~
7757                 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
7758                 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
7759               _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
7760                 rm -rf $tpldir~
7761                 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
7762                 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
7763                 $RANLIB $oldlib'
7764               _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
7765                 rm -rf $tpldir~
7766                 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7767                 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7768               _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
7769                 rm -rf $tpldir~
7770                 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7771                 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
7772               ;;
7773             *) # Version 6 and above use weak symbols
7774               _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7775               _LT_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'
7776               ;;
7777             esac
7778
7779             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
7780             _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7781             _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
7782             ;;
7783           cxx*)
7784             # Compaq C++
7785             _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7786             _LT_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'
7787
7788             runpath_var=LD_RUN_PATH
7789             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7790             _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7791
7792             # Commands to make compiler produce verbose output that lists
7793             # what "hidden" libraries, object files and flags are used when
7794             # linking a shared library.
7795             #
7796             # There doesn't appear to be a way to prevent this compiler from
7797             # explicitly linking system object files so we need to strip them
7798             # from the output so that they don't get included in the library
7799             # dependencies.
7800             output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$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; func_echo_all "X$list" | $Xsed'
7801             ;;
7802           xl* | mpixl* | bgxl*)
7803             # IBM XL 8.0 on PPC, with GNU ld
7804             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7805             _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7806             _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7807             if test "x$supports_anon_versioning" = xyes; then
7808               _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7809                 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7810                 echo "local: *; };" >> $output_objdir/$libname.ver~
7811                 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
7812             fi
7813             ;;
7814           *)
7815             case `$CC -V 2>&1 | sed 5q` in
7816             *Sun\ C*)
7817               # Sun C++ 5.9
7818               _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7819               _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7820               _LT_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'
7821               _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7822               _LT_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; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
7823               _LT_TAGVAR(compiler_needs_object, $1)=yes
7824
7825               # Not sure whether something based on
7826               # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
7827               # would be better.
7828               output_verbose_link_cmd='func_echo_all'
7829
7830               # Archives containing C++ object files must be created using
7831               # "CC -xar", where "CC" is the Sun C++ compiler.  This is
7832               # necessary to make sure instantiated templates are included
7833               # in the archive.
7834               _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7835               ;;
7836             esac
7837             ;;
7838         esac
7839         ;;
7840
7841       lynxos*)
7842         # FIXME: insert proper C++ library support
7843         _LT_TAGVAR(ld_shlibs, $1)=no
7844         ;;
7845
7846       m88k*)
7847         # FIXME: insert proper C++ library support
7848         _LT_TAGVAR(ld_shlibs, $1)=no
7849         ;;
7850
7851       mvs*)
7852         case $cc_basename in
7853           cxx*)
7854             # FIXME: insert proper C++ library support
7855             _LT_TAGVAR(ld_shlibs, $1)=no
7856             ;;
7857           *)
7858             # FIXME: insert proper C++ library support
7859             _LT_TAGVAR(ld_shlibs, $1)=no
7860             ;;
7861         esac
7862         ;;
7863
7864       netbsd*)
7865         if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7866           _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
7867           wlarc=
7868           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7869           _LT_TAGVAR(hardcode_direct, $1)=yes
7870           _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7871         fi
7872         # Workaround some broken pre-1.5 toolchains
7873         output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
7874         ;;
7875
7876       *nto* | *qnx*)
7877         _LT_TAGVAR(ld_shlibs, $1)=yes
7878         ;;
7879
7880       openbsd2*)
7881         # C++ shared libraries are fairly broken
7882         _LT_TAGVAR(ld_shlibs, $1)=no
7883         ;;
7884
7885       openbsd*)
7886         if test -f /usr/libexec/ld.so; then
7887           _LT_TAGVAR(hardcode_direct, $1)=yes
7888           _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7889           _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7890           _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7891           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7892           if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7893             _LT_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'
7894             _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7895             _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7896           fi
7897           output_verbose_link_cmd=func_echo_all
7898         else
7899           _LT_TAGVAR(ld_shlibs, $1)=no
7900         fi
7901         ;;
7902
7903       osf3* | osf4* | osf5*)
7904         case $cc_basename in
7905           KCC*)
7906             # Kuck and Associates, Inc. (KAI) C++ Compiler
7907
7908             # KCC will only create a shared library if the output file
7909             # ends with ".so" (or ".sl" for HP-UX), so rename the library
7910             # to its proper name (with version) after linking.
7911             _LT_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'
7912
7913             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7914             _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7915
7916             # Archives containing C++ object files must be created using
7917             # the KAI C++ compiler.
7918             case $host in
7919               osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
7920               *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
7921             esac
7922             ;;
7923           RCC*)
7924             # Rational C++ 2.4.1
7925             # FIXME: insert proper C++ library support
7926             _LT_TAGVAR(ld_shlibs, $1)=no
7927             ;;
7928           cxx*)
7929             case $host in
7930               osf3*)
7931                 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7932                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
7933                 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7934                 ;;
7935               *)
7936                 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7937                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
7938                 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
7939                   echo "-hidden">> $lib.exp~
7940                   $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~
7941                   $RM $lib.exp'
7942                 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7943                 ;;
7944             esac
7945
7946             _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7947
7948             # Commands to make compiler produce verbose output that lists
7949             # what "hidden" libraries, object files and flags are used when
7950             # linking a shared library.
7951             #
7952             # There doesn't appear to be a way to prevent this compiler from
7953             # explicitly linking system object files so we need to strip them
7954             # from the output so that they don't get included in the library
7955             # dependencies.
7956             output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$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; func_echo_all "$list"'
7957             ;;
7958           *)
7959             if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7960               _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7961               case $host in
7962                 osf3*)
7963                   _LT_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" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7964                   ;;
7965                 *)
7966                   _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7967                   ;;
7968               esac
7969
7970               _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7971               _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7972
7973               # Commands to make compiler produce verbose output that lists
7974               # what "hidden" libraries, object files and flags are used when
7975               # linking a shared library.
7976               output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7977
7978             else
7979               # FIXME: insert proper C++ library support
7980               _LT_TAGVAR(ld_shlibs, $1)=no
7981             fi
7982             ;;
7983         esac
7984         ;;
7985
7986       psos*)
7987         # FIXME: insert proper C++ library support
7988         _LT_TAGVAR(ld_shlibs, $1)=no
7989         ;;
7990
7991       sunos4*)
7992         case $cc_basename in
7993           CC*)
7994             # Sun C++ 4.x
7995             # FIXME: insert proper C++ library support
7996             _LT_TAGVAR(ld_shlibs, $1)=no
7997             ;;
7998           lcc*)
7999             # Lucid
8000             # FIXME: insert proper C++ library support
8001             _LT_TAGVAR(ld_shlibs, $1)=no
8002             ;;
8003           *)
8004             # FIXME: insert proper C++ library support
8005             _LT_TAGVAR(ld_shlibs, $1)=no
8006             ;;
8007         esac
8008         ;;
8009
8010       solaris*)
8011         case $cc_basename in
8012           CC* | sunCC*)
8013             # Sun C++ 4.2, 5.x and Centerline C++
8014             _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
8015             _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
8016             _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
8017             _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
8018               $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'
8019
8020             _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
8021             _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8022             case $host_os in
8023               solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
8024               *)
8025                 # The compiler driver will combine and reorder linker options,
8026                 # but understands `-z linker_flag'.
8027                 # Supported since Solaris 2.6 (maybe 2.5.1?)
8028                 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
8029                 ;;
8030             esac
8031             _LT_TAGVAR(link_all_deplibs, $1)=yes
8032
8033             output_verbose_link_cmd='func_echo_all'
8034
8035             # Archives containing C++ object files must be created using
8036             # "CC -xar", where "CC" is the Sun C++ compiler.  This is
8037             # necessary to make sure instantiated templates are included
8038             # in the archive.
8039             _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
8040             ;;
8041           gcx*)
8042             # Green Hills C++ Compiler
8043             _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
8044
8045             # The C++ compiler must be used to create the archive.
8046             _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
8047             ;;
8048           *)
8049             # GNU C++ compiler with Solaris linker
8050             if test "$GXX" = yes && test "$with_gnu_ld" = no; then
8051               _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
8052               if $CC --version | $GREP -v '^2\.7' > /dev/null; then
8053                 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
8054                 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
8055                   $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
8056
8057                 # Commands to make compiler produce verbose output that lists
8058                 # what "hidden" libraries, object files and flags are used when
8059                 # linking a shared library.
8060                 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
8061               else
8062                 # g++ 2.7 appears to require `-G' NOT `-shared' on this
8063                 # platform.
8064                 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
8065                 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
8066                   $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
8067
8068                 # Commands to make compiler produce verbose output that lists
8069                 # what "hidden" libraries, object files and flags are used when
8070                 # linking a shared library.
8071                 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
8072               fi
8073
8074               _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
8075               case $host_os in
8076                 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
8077                 *)
8078                   _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
8079                   ;;
8080               esac
8081             fi
8082             ;;
8083         esac
8084         ;;
8085
8086     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
8087       _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
8088       _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8089       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8090       runpath_var='LD_RUN_PATH'
8091
8092       case $cc_basename in
8093         CC*)
8094           _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8095           _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8096           ;;
8097         *)
8098           _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8099           _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8100           ;;
8101       esac
8102       ;;
8103
8104       sysv5* | sco3.2v5* | sco5v6*)
8105         # Note: We can NOT use -z defs as we might desire, because we do not
8106         # link with -lc, and that would cause any symbols used from libc to
8107         # always be unresolved, which means just about no library would
8108         # ever link correctly.  If we're not using GNU ld we use -z text
8109         # though, which does catch some bad symbols but isn't as heavy-handed
8110         # as -z defs.
8111         _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
8112         _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
8113         _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8114         _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
8115         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
8116         _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
8117         _LT_TAGVAR(link_all_deplibs, $1)=yes
8118         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
8119         runpath_var='LD_RUN_PATH'
8120
8121         case $cc_basename in
8122           CC*)
8123             _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8124             _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8125             _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
8126               '"$_LT_TAGVAR(old_archive_cmds, $1)"
8127             _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
8128               '"$_LT_TAGVAR(reload_cmds, $1)"
8129             ;;
8130           *)
8131             _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8132             _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
8133             ;;
8134         esac
8135       ;;
8136
8137       tandem*)
8138         case $cc_basename in
8139           NCC*)
8140             # NonStop-UX NCC 3.20
8141             # FIXME: insert proper C++ library support
8142             _LT_TAGVAR(ld_shlibs, $1)=no
8143             ;;
8144           *)
8145             # FIXME: insert proper C++ library support
8146             _LT_TAGVAR(ld_shlibs, $1)=no
8147             ;;
8148         esac
8149         ;;
8150
8151       vxworks*)
8152         # FIXME: insert proper C++ library support
8153         _LT_TAGVAR(ld_shlibs, $1)=no
8154         ;;
8155
8156       *)
8157         # FIXME: insert proper C++ library support
8158         _LT_TAGVAR(ld_shlibs, $1)=no
8159         ;;
8160     esac
8161
8162     AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
8163     test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
8164
8165     _LT_TAGVAR(GCC, $1)="$GXX"
8166     _LT_TAGVAR(LD, $1)="$LD"
8167
8168     ## CAVEAT EMPTOR:
8169     ## There is no encapsulation within the following macros, do not change
8170     ## the running order or otherwise move them around unless you know exactly
8171     ## what you are doing...
8172     _LT_SYS_HIDDEN_LIBDEPS($1)
8173     _LT_COMPILER_PIC($1)
8174     _LT_COMPILER_C_O($1)
8175     _LT_COMPILER_FILE_LOCKS($1)
8176     _LT_LINKER_SHLIBS($1)
8177     _LT_SYS_DYNAMIC_LINKER($1)
8178     _LT_LINKER_HARDCODE_LIBPATH($1)
8179
8180     _LT_CONFIG($1)
8181   fi # test -n "$compiler"
8182
8183   CC=$lt_save_CC
8184   CFLAGS=$lt_save_CFLAGS
8185   LDCXX=$LD
8186   LD=$lt_save_LD
8187   GCC=$lt_save_GCC
8188   with_gnu_ld=$lt_save_with_gnu_ld
8189   lt_cv_path_LDCXX=$lt_cv_path_LD
8190   lt_cv_path_LD=$lt_save_path_LD
8191   lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
8192   lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
8193 fi # test "$_lt_caught_CXX_error" != yes
8194
8195 AC_LANG_POP
8196 ])# _LT_LANG_CXX_CONFIG
8197
8198
8199 # _LT_FUNC_STRIPNAME_CNF
8200 # ----------------------
8201 # func_stripname_cnf prefix suffix name
8202 # strip PREFIX and SUFFIX off of NAME.
8203 # PREFIX and SUFFIX must not contain globbing or regex special
8204 # characters, hashes, percent signs, but SUFFIX may contain a leading
8205 # dot (in which case that matches only a dot).
8206 #
8207 # This function is identical to the (non-XSI) version of func_stripname,
8208 # except this one can be used by m4 code that may be executed by configure,
8209 # rather than the libtool script.
8210 m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
8211 AC_REQUIRE([_LT_DECL_SED])
8212 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
8213 func_stripname_cnf ()
8214 {
8215   case ${2} in
8216   .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
8217   *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
8218   esac
8219 } # func_stripname_cnf
8220 ])# _LT_FUNC_STRIPNAME_CNF
8221
8222 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
8223 # ---------------------------------
8224 # Figure out "hidden" library dependencies from verbose
8225 # compiler output when linking a shared library.
8226 # Parse the compiler output and extract the necessary
8227 # objects, libraries and library flags.
8228 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
8229 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
8230 AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
8231 # Dependencies to place before and after the object being linked:
8232 _LT_TAGVAR(predep_objects, $1)=
8233 _LT_TAGVAR(postdep_objects, $1)=
8234 _LT_TAGVAR(predeps, $1)=
8235 _LT_TAGVAR(postdeps, $1)=
8236 _LT_TAGVAR(compiler_lib_search_path, $1)=
8237
8238 dnl we can't use the lt_simple_compile_test_code here,
8239 dnl because it contains code intended for an executable,
8240 dnl not a library.  It's possible we should let each
8241 dnl tag define a new lt_????_link_test_code variable,
8242 dnl but it's only used here...
8243 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
8244 int a;
8245 void foo (void) { a = 0; }
8246 _LT_EOF
8247 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
8248 class Foo
8249 {
8250 public:
8251   Foo (void) { a = 0; }
8252 private:
8253   int a;
8254 };
8255 _LT_EOF
8256 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
8257       subroutine foo
8258       implicit none
8259       integer*4 a
8260       a=0
8261       return
8262       end
8263 _LT_EOF
8264 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
8265       subroutine foo
8266       implicit none
8267       integer a
8268       a=0
8269       return
8270       end
8271 _LT_EOF
8272 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
8273 public class foo {
8274   private int a;
8275   public void bar (void) {
8276     a = 0;
8277   }
8278 };
8279 _LT_EOF
8280 ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
8281 package foo
8282 func foo() {
8283 }
8284 _LT_EOF
8285 ])
8286
8287 _lt_libdeps_save_CFLAGS=$CFLAGS
8288 case "$CC $CFLAGS " in #(
8289 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
8290 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
8291 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
8292 esac
8293
8294 dnl Parse the compiler output and extract the necessary
8295 dnl objects, libraries and library flags.
8296 if AC_TRY_EVAL(ac_compile); then
8297   # Parse the compiler output and extract the necessary
8298   # objects, libraries and library flags.
8299
8300   # Sentinel used to keep track of whether or not we are before
8301   # the conftest object file.
8302   pre_test_object_deps_done=no
8303
8304   for p in `eval "$output_verbose_link_cmd"`; do
8305     case ${prev}${p} in
8306
8307     -L* | -R* | -l*)
8308        # Some compilers place space between "-{L,R}" and the path.
8309        # Remove the space.
8310        if test $p = "-L" ||
8311           test $p = "-R"; then
8312          prev=$p
8313          continue
8314        fi
8315
8316        # Expand the sysroot to ease extracting the directories later.
8317        if test -z "$prev"; then
8318          case $p in
8319          -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
8320          -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
8321          -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
8322          esac
8323        fi
8324        case $p in
8325        =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
8326        esac
8327        if test "$pre_test_object_deps_done" = no; then
8328          case ${prev} in
8329          -L | -R)
8330            # Internal compiler library paths should come after those
8331            # provided the user.  The postdeps already come after the
8332            # user supplied libs so there is no need to process them.
8333            if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
8334              _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
8335            else
8336              _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
8337            fi
8338            ;;
8339          # The "-l" case would never come before the object being
8340          # linked, so don't bother handling this case.
8341          esac
8342        else
8343          if test -z "$_LT_TAGVAR(postdeps, $1)"; then
8344            _LT_TAGVAR(postdeps, $1)="${prev}${p}"
8345          else
8346            _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
8347          fi
8348        fi
8349        prev=
8350        ;;
8351
8352     *.lto.$objext) ;; # Ignore GCC LTO objects
8353     *.$objext)
8354        # This assumes that the test object file only shows up
8355        # once in the compiler output.
8356        if test "$p" = "conftest.$objext"; then
8357          pre_test_object_deps_done=yes
8358          continue
8359        fi
8360
8361        if test "$pre_test_object_deps_done" = no; then
8362          if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
8363            _LT_TAGVAR(predep_objects, $1)="$p"
8364          else
8365            _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
8366          fi
8367        else
8368          if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
8369            _LT_TAGVAR(postdep_objects, $1)="$p"
8370          else
8371            _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
8372          fi
8373        fi
8374        ;;
8375
8376     *) ;; # Ignore the rest.
8377
8378     esac
8379   done
8380
8381   # Clean up.
8382   rm -f a.out a.exe
8383 else
8384   echo "libtool.m4: error: problem compiling $1 test program"
8385 fi
8386
8387 $RM -f confest.$objext
8388 CFLAGS=$_lt_libdeps_save_CFLAGS
8389
8390 # PORTME: override above test on systems where it is broken
8391 m4_if([$1], [CXX],
8392 [case $host_os in
8393 interix[[3-9]]*)
8394   # Interix 3.5 installs completely hosed .la files for C++, so rather than
8395   # hack all around it, let's just trust "g++" to DTRT.
8396   _LT_TAGVAR(predep_objects,$1)=
8397   _LT_TAGVAR(postdep_objects,$1)=
8398   _LT_TAGVAR(postdeps,$1)=
8399   ;;
8400
8401 linux*)
8402   case `$CC -V 2>&1 | sed 5q` in
8403   *Sun\ C*)
8404     # Sun C++ 5.9
8405
8406     # The more standards-conforming stlport4 library is
8407     # incompatible with the Cstd library. Avoid specifying
8408     # it if it's in CXXFLAGS. Ignore libCrun as
8409     # -library=stlport4 depends on it.
8410     case " $CXX $CXXFLAGS " in
8411     *" -library=stlport4 "*)
8412       solaris_use_stlport4=yes
8413       ;;
8414     esac
8415
8416     if test "$solaris_use_stlport4" != yes; then
8417       _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8418     fi
8419     ;;
8420   esac
8421   ;;
8422
8423 solaris*)
8424   case $cc_basename in
8425   CC* | sunCC*)
8426     # The more standards-conforming stlport4 library is
8427     # incompatible with the Cstd library. Avoid specifying
8428     # it if it's in CXXFLAGS. Ignore libCrun as
8429     # -library=stlport4 depends on it.
8430     case " $CXX $CXXFLAGS " in
8431     *" -library=stlport4 "*)
8432       solaris_use_stlport4=yes
8433       ;;
8434     esac
8435
8436     # Adding this requires a known-good setup of shared libraries for
8437     # Sun compiler versions before 5.6, else PIC objects from an old
8438     # archive will be linked into the output, leading to subtle bugs.
8439     if test "$solaris_use_stlport4" != yes; then
8440       _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8441     fi
8442     ;;
8443   esac
8444   ;;
8445 esac
8446 ])
8447
8448 case " $_LT_TAGVAR(postdeps, $1) " in
8449 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
8450 esac
8451  _LT_TAGVAR(compiler_lib_search_dirs, $1)=
8452 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
8453  _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
8454 fi
8455 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
8456     [The directories searched by this compiler when creating a shared library])
8457 _LT_TAGDECL([], [predep_objects], [1],
8458     [Dependencies to place before and after the objects being linked to
8459     create a shared library])
8460 _LT_TAGDECL([], [postdep_objects], [1])
8461 _LT_TAGDECL([], [predeps], [1])
8462 _LT_TAGDECL([], [postdeps], [1])
8463 _LT_TAGDECL([], [compiler_lib_search_path], [1],
8464     [The library search path used internally by the compiler when linking
8465     a shared library])
8466 ])# _LT_SYS_HIDDEN_LIBDEPS
8467
8468
8469 # _LT_LANG_F77_CONFIG([TAG])
8470 # --------------------------
8471 # Ensure that the configuration variables for a Fortran 77 compiler are
8472 # suitably defined.  These variables are subsequently used by _LT_CONFIG
8473 # to write the compiler configuration to `libtool'.
8474 m4_defun([_LT_LANG_F77_CONFIG],
8475 [AC_LANG_PUSH(Fortran 77)
8476 if test -z "$F77" || test "X$F77" = "Xno"; then
8477   _lt_disable_F77=yes
8478 fi
8479
8480 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8481 _LT_TAGVAR(allow_undefined_flag, $1)=
8482 _LT_TAGVAR(always_export_symbols, $1)=no
8483 _LT_TAGVAR(archive_expsym_cmds, $1)=
8484 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8485 _LT_TAGVAR(hardcode_direct, $1)=no
8486 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8487 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8488 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8489 _LT_TAGVAR(hardcode_minus_L, $1)=no
8490 _LT_TAGVAR(hardcode_automatic, $1)=no
8491 _LT_TAGVAR(inherit_rpath, $1)=no
8492 _LT_TAGVAR(module_cmds, $1)=
8493 _LT_TAGVAR(module_expsym_cmds, $1)=
8494 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8495 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8496 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8497 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8498 _LT_TAGVAR(no_undefined_flag, $1)=
8499 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8500 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8501
8502 # Source file extension for f77 test sources.
8503 ac_ext=f
8504
8505 # Object file extension for compiled f77 test sources.
8506 objext=o
8507 _LT_TAGVAR(objext, $1)=$objext
8508
8509 # No sense in running all these tests if we already determined that
8510 # the F77 compiler isn't working.  Some variables (like enable_shared)
8511 # are currently assumed to apply to all compilers on this platform,
8512 # and will be corrupted by setting them based on a non-working compiler.
8513 if test "$_lt_disable_F77" != yes; then
8514   # Code to be used in simple compile tests
8515   lt_simple_compile_test_code="\
8516       subroutine t
8517       return
8518       end
8519 "
8520
8521   # Code to be used in simple link tests
8522   lt_simple_link_test_code="\
8523       program t
8524       end
8525 "
8526
8527   # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8528   _LT_TAG_COMPILER
8529
8530   # save warnings/boilerplate of simple test code
8531   _LT_COMPILER_BOILERPLATE
8532   _LT_LINKER_BOILERPLATE
8533
8534   # Allow CC to be a program name with arguments.
8535   lt_save_CC="$CC"
8536   lt_save_GCC=$GCC
8537   lt_save_CFLAGS=$CFLAGS
8538   CC=${F77-"f77"}
8539   CFLAGS=$FFLAGS
8540   compiler=$CC
8541   _LT_TAGVAR(compiler, $1)=$CC
8542   _LT_CC_BASENAME([$compiler])
8543   GCC=$G77
8544   if test -n "$compiler"; then
8545     AC_MSG_CHECKING([if libtool supports shared libraries])
8546     AC_MSG_RESULT([$can_build_shared])
8547
8548     AC_MSG_CHECKING([whether to build shared libraries])
8549     test "$can_build_shared" = "no" && enable_shared=no
8550
8551     # On AIX, shared libraries and static libraries use the same namespace, and
8552     # are all built from PIC.
8553     case $host_os in
8554       aix3*)
8555         test "$enable_shared" = yes && enable_static=no
8556         if test -n "$RANLIB"; then
8557           archive_cmds="$archive_cmds~\$RANLIB \$lib"
8558           postinstall_cmds='$RANLIB $lib'
8559         fi
8560         ;;
8561       aix[[4-9]]*)
8562         if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8563           test "$enable_shared" = yes && enable_static=no
8564         fi
8565         ;;
8566     esac
8567     AC_MSG_RESULT([$enable_shared])
8568
8569     AC_MSG_CHECKING([whether to build static libraries])
8570     # Make sure either enable_shared or enable_static is yes.
8571     test "$enable_shared" = yes || enable_static=yes
8572     AC_MSG_RESULT([$enable_static])
8573
8574     _LT_TAGVAR(GCC, $1)="$G77"
8575     _LT_TAGVAR(LD, $1)="$LD"
8576
8577     ## CAVEAT EMPTOR:
8578     ## There is no encapsulation within the following macros, do not change
8579     ## the running order or otherwise move them around unless you know exactly
8580     ## what you are doing...
8581     _LT_COMPILER_PIC($1)
8582     _LT_COMPILER_C_O($1)
8583     _LT_COMPILER_FILE_LOCKS($1)
8584     _LT_LINKER_SHLIBS($1)
8585     _LT_SYS_DYNAMIC_LINKER($1)
8586     _LT_LINKER_HARDCODE_LIBPATH($1)
8587
8588     _LT_CONFIG($1)
8589   fi # test -n "$compiler"
8590
8591   GCC=$lt_save_GCC
8592   CC="$lt_save_CC"
8593   CFLAGS="$lt_save_CFLAGS"
8594 fi # test "$_lt_disable_F77" != yes
8595
8596 AC_LANG_POP
8597 ])# _LT_LANG_F77_CONFIG
8598
8599
8600 # _LT_LANG_FC_CONFIG([TAG])
8601 # -------------------------
8602 # Ensure that the configuration variables for a Fortran compiler are
8603 # suitably defined.  These variables are subsequently used by _LT_CONFIG
8604 # to write the compiler configuration to `libtool'.
8605 m4_defun([_LT_LANG_FC_CONFIG],
8606 [AC_LANG_PUSH(Fortran)
8607
8608 if test -z "$FC" || test "X$FC" = "Xno"; then
8609   _lt_disable_FC=yes
8610 fi
8611
8612 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8613 _LT_TAGVAR(allow_undefined_flag, $1)=
8614 _LT_TAGVAR(always_export_symbols, $1)=no
8615 _LT_TAGVAR(archive_expsym_cmds, $1)=
8616 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8617 _LT_TAGVAR(hardcode_direct, $1)=no
8618 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8619 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8620 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8621 _LT_TAGVAR(hardcode_minus_L, $1)=no
8622 _LT_TAGVAR(hardcode_automatic, $1)=no
8623 _LT_TAGVAR(inherit_rpath, $1)=no
8624 _LT_TAGVAR(module_cmds, $1)=
8625 _LT_TAGVAR(module_expsym_cmds, $1)=
8626 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8627 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8628 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8629 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8630 _LT_TAGVAR(no_undefined_flag, $1)=
8631 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8632 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8633
8634 # Source file extension for fc test sources.
8635 ac_ext=${ac_fc_srcext-f}
8636
8637 # Object file extension for compiled fc test sources.
8638 objext=o
8639 _LT_TAGVAR(objext, $1)=$objext
8640
8641 # No sense in running all these tests if we already determined that
8642 # the FC compiler isn't working.  Some variables (like enable_shared)
8643 # are currently assumed to apply to all compilers on this platform,
8644 # and will be corrupted by setting them based on a non-working compiler.
8645 if test "$_lt_disable_FC" != yes; then
8646   # Code to be used in simple compile tests
8647   lt_simple_compile_test_code="\
8648       subroutine t
8649       return
8650       end
8651 "
8652
8653   # Code to be used in simple link tests
8654   lt_simple_link_test_code="\
8655       program t
8656       end
8657 "
8658
8659   # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8660   _LT_TAG_COMPILER
8661
8662   # save warnings/boilerplate of simple test code
8663   _LT_COMPILER_BOILERPLATE
8664   _LT_LINKER_BOILERPLATE
8665
8666   # Allow CC to be a program name with arguments.
8667   lt_save_CC="$CC"
8668   lt_save_GCC=$GCC
8669   lt_save_CFLAGS=$CFLAGS
8670   CC=${FC-"f95"}
8671   CFLAGS=$FCFLAGS
8672   compiler=$CC
8673   GCC=$ac_cv_fc_compiler_gnu
8674
8675   _LT_TAGVAR(compiler, $1)=$CC
8676   _LT_CC_BASENAME([$compiler])
8677
8678   if test -n "$compiler"; then
8679     AC_MSG_CHECKING([if libtool supports shared libraries])
8680     AC_MSG_RESULT([$can_build_shared])
8681
8682     AC_MSG_CHECKING([whether to build shared libraries])
8683     test "$can_build_shared" = "no" && enable_shared=no
8684
8685     # On AIX, shared libraries and static libraries use the same namespace, and
8686     # are all built from PIC.
8687     case $host_os in
8688       aix3*)
8689         test "$enable_shared" = yes && enable_static=no
8690         if test -n "$RANLIB"; then
8691           archive_cmds="$archive_cmds~\$RANLIB \$lib"
8692           postinstall_cmds='$RANLIB $lib'
8693         fi
8694         ;;
8695       aix[[4-9]]*)
8696         if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8697           test "$enable_shared" = yes && enable_static=no
8698         fi
8699         ;;
8700     esac
8701     AC_MSG_RESULT([$enable_shared])
8702
8703     AC_MSG_CHECKING([whether to build static libraries])
8704     # Make sure either enable_shared or enable_static is yes.
8705     test "$enable_shared" = yes || enable_static=yes
8706     AC_MSG_RESULT([$enable_static])
8707
8708     _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
8709     _LT_TAGVAR(LD, $1)="$LD"
8710
8711     ## CAVEAT EMPTOR:
8712     ## There is no encapsulation within the following macros, do not change
8713     ## the running order or otherwise move them around unless you know exactly
8714     ## what you are doing...
8715     _LT_SYS_HIDDEN_LIBDEPS($1)
8716     _LT_COMPILER_PIC($1)
8717     _LT_COMPILER_C_O($1)
8718     _LT_COMPILER_FILE_LOCKS($1)
8719     _LT_LINKER_SHLIBS($1)
8720     _LT_SYS_DYNAMIC_LINKER($1)
8721     _LT_LINKER_HARDCODE_LIBPATH($1)
8722
8723     _LT_CONFIG($1)
8724   fi # test -n "$compiler"
8725
8726   GCC=$lt_save_GCC
8727   CC=$lt_save_CC
8728   CFLAGS=$lt_save_CFLAGS
8729 fi # test "$_lt_disable_FC" != yes
8730
8731 AC_LANG_POP
8732 ])# _LT_LANG_FC_CONFIG
8733
8734
8735 # _LT_LANG_GCJ_CONFIG([TAG])
8736 # --------------------------
8737 # Ensure that the configuration variables for the GNU Java Compiler compiler
8738 # are suitably defined.  These variables are subsequently used by _LT_CONFIG
8739 # to write the compiler configuration to `libtool'.
8740 m4_defun([_LT_LANG_GCJ_CONFIG],
8741 [AC_REQUIRE([LT_PROG_GCJ])dnl
8742 AC_LANG_SAVE
8743
8744 # Source file extension for Java test sources.
8745 ac_ext=java
8746
8747 # Object file extension for compiled Java test sources.
8748 objext=o
8749 _LT_TAGVAR(objext, $1)=$objext
8750
8751 # Code to be used in simple compile tests
8752 lt_simple_compile_test_code="class foo {}"
8753
8754 # Code to be used in simple link tests
8755 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
8756
8757 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8758 _LT_TAG_COMPILER
8759
8760 # save warnings/boilerplate of simple test code
8761 _LT_COMPILER_BOILERPLATE
8762 _LT_LINKER_BOILERPLATE
8763
8764 # Allow CC to be a program name with arguments.
8765 lt_save_CC=$CC
8766 lt_save_CFLAGS=$CFLAGS
8767 lt_save_GCC=$GCC
8768 GCC=yes
8769 CC=${GCJ-"gcj"}
8770 CFLAGS=$GCJFLAGS
8771 compiler=$CC
8772 _LT_TAGVAR(compiler, $1)=$CC
8773 _LT_TAGVAR(LD, $1)="$LD"
8774 _LT_CC_BASENAME([$compiler])
8775
8776 # GCJ did not exist at the time GCC didn't implicitly link libc in.
8777 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8778
8779 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8780 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8781 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8782
8783 if test -n "$compiler"; then
8784   _LT_COMPILER_NO_RTTI($1)
8785   _LT_COMPILER_PIC($1)
8786   _LT_COMPILER_C_O($1)
8787   _LT_COMPILER_FILE_LOCKS($1)
8788   _LT_LINKER_SHLIBS($1)
8789   _LT_LINKER_HARDCODE_LIBPATH($1)
8790
8791   _LT_CONFIG($1)
8792 fi
8793
8794 AC_LANG_RESTORE
8795
8796 GCC=$lt_save_GCC
8797 CC=$lt_save_CC
8798 CFLAGS=$lt_save_CFLAGS
8799 ])# _LT_LANG_GCJ_CONFIG
8800
8801
8802 # _LT_LANG_GO_CONFIG([TAG])
8803 # --------------------------
8804 # Ensure that the configuration variables for the GNU Go compiler
8805 # are suitably defined.  These variables are subsequently used by _LT_CONFIG
8806 # to write the compiler configuration to `libtool'.
8807 m4_defun([_LT_LANG_GO_CONFIG],
8808 [AC_REQUIRE([LT_PROG_GO])dnl
8809 AC_LANG_SAVE
8810
8811 # Source file extension for Go test sources.
8812 ac_ext=go
8813
8814 # Object file extension for compiled Go test sources.
8815 objext=o
8816 _LT_TAGVAR(objext, $1)=$objext
8817
8818 # Code to be used in simple compile tests
8819 lt_simple_compile_test_code="package main; func main() { }"
8820
8821 # Code to be used in simple link tests
8822 lt_simple_link_test_code='package main; func main() { }'
8823
8824 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8825 _LT_TAG_COMPILER
8826
8827 # save warnings/boilerplate of simple test code
8828 _LT_COMPILER_BOILERPLATE
8829 _LT_LINKER_BOILERPLATE
8830
8831 # Allow CC to be a program name with arguments.
8832 lt_save_CC=$CC
8833 lt_save_CFLAGS=$CFLAGS
8834 lt_save_GCC=$GCC
8835 GCC=yes
8836 CC=${GOC-"gccgo"}
8837 CFLAGS=$GOFLAGS
8838 compiler=$CC
8839 _LT_TAGVAR(compiler, $1)=$CC
8840 _LT_TAGVAR(LD, $1)="$LD"
8841 _LT_CC_BASENAME([$compiler])
8842
8843 # Go did not exist at the time GCC didn't implicitly link libc in.
8844 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8845
8846 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8847 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8848 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8849
8850 if test -n "$compiler"; then
8851   _LT_COMPILER_NO_RTTI($1)
8852   _LT_COMPILER_PIC($1)
8853   _LT_COMPILER_C_O($1)
8854   _LT_COMPILER_FILE_LOCKS($1)
8855   _LT_LINKER_SHLIBS($1)
8856   _LT_LINKER_HARDCODE_LIBPATH($1)
8857
8858   _LT_CONFIG($1)
8859 fi
8860
8861 AC_LANG_RESTORE
8862
8863 GCC=$lt_save_GCC
8864 CC=$lt_save_CC
8865 CFLAGS=$lt_save_CFLAGS
8866 ])# _LT_LANG_GO_CONFIG
8867
8868
8869 # _LT_LANG_RC_CONFIG([TAG])
8870 # -------------------------
8871 # Ensure that the configuration variables for the Windows resource compiler
8872 # are suitably defined.  These variables are subsequently used by _LT_CONFIG
8873 # to write the compiler configuration to `libtool'.
8874 m4_defun([_LT_LANG_RC_CONFIG],
8875 [AC_REQUIRE([LT_PROG_RC])dnl
8876 AC_LANG_SAVE
8877
8878 # Source file extension for RC test sources.
8879 ac_ext=rc
8880
8881 # Object file extension for compiled RC test sources.
8882 objext=o
8883 _LT_TAGVAR(objext, $1)=$objext
8884
8885 # Code to be used in simple compile tests
8886 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8887
8888 # Code to be used in simple link tests
8889 lt_simple_link_test_code="$lt_simple_compile_test_code"
8890
8891 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8892 _LT_TAG_COMPILER
8893
8894 # save warnings/boilerplate of simple test code
8895 _LT_COMPILER_BOILERPLATE
8896 _LT_LINKER_BOILERPLATE
8897
8898 # Allow CC to be a program name with arguments.
8899 lt_save_CC="$CC"
8900 lt_save_CFLAGS=$CFLAGS
8901 lt_save_GCC=$GCC
8902 GCC=
8903 CC=${RC-"windres"}
8904 CFLAGS=
8905 compiler=$CC
8906 _LT_TAGVAR(compiler, $1)=$CC
8907 _LT_CC_BASENAME([$compiler])
8908 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8909
8910 if test -n "$compiler"; then
8911   :
8912   _LT_CONFIG($1)
8913 fi
8914
8915 GCC=$lt_save_GCC
8916 AC_LANG_RESTORE
8917 CC=$lt_save_CC
8918 CFLAGS=$lt_save_CFLAGS
8919 ])# _LT_LANG_RC_CONFIG
8920
8921
8922 # LT_PROG_GCJ
8923 # -----------
8924 AC_DEFUN([LT_PROG_GCJ],
8925 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
8926   [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
8927     [AC_CHECK_TOOL(GCJ, gcj,)
8928       test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
8929       AC_SUBST(GCJFLAGS)])])[]dnl
8930 ])
8931
8932 # Old name:
8933 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
8934 dnl aclocal-1.4 backwards compatibility:
8935 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
8936
8937
8938 # LT_PROG_GO
8939 # ----------
8940 AC_DEFUN([LT_PROG_GO],
8941 [AC_CHECK_TOOL(GOC, gccgo,)
8942 ])
8943
8944
8945 # LT_PROG_RC
8946 # ----------
8947 AC_DEFUN([LT_PROG_RC],
8948 [AC_CHECK_TOOL(RC, windres,)
8949 ])
8950
8951 # Old name:
8952 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
8953 dnl aclocal-1.4 backwards compatibility:
8954 dnl AC_DEFUN([LT_AC_PROG_RC], [])
8955
8956
8957 # _LT_DECL_EGREP
8958 # --------------
8959 # If we don't have a new enough Autoconf to choose the best grep
8960 # available, choose the one first in the user's PATH.
8961 m4_defun([_LT_DECL_EGREP],
8962 [AC_REQUIRE([AC_PROG_EGREP])dnl
8963 AC_REQUIRE([AC_PROG_FGREP])dnl
8964 test -z "$GREP" && GREP=grep
8965 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
8966 _LT_DECL([], [EGREP], [1], [An ERE matcher])
8967 _LT_DECL([], [FGREP], [1], [A literal string matcher])
8968 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
8969 AC_SUBST([GREP])
8970 ])
8971
8972
8973 # _LT_DECL_OBJDUMP
8974 # --------------
8975 # If we don't have a new enough Autoconf to choose the best objdump
8976 # available, choose the one first in the user's PATH.
8977 m4_defun([_LT_DECL_OBJDUMP],
8978 [AC_CHECK_TOOL(OBJDUMP, objdump, false)
8979 test -z "$OBJDUMP" && OBJDUMP=objdump
8980 _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
8981 AC_SUBST([OBJDUMP])
8982 ])
8983
8984 # _LT_DECL_DLLTOOL
8985 # ----------------
8986 # Ensure DLLTOOL variable is set.
8987 m4_defun([_LT_DECL_DLLTOOL],
8988 [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8989 test -z "$DLLTOOL" && DLLTOOL=dlltool
8990 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
8991 AC_SUBST([DLLTOOL])
8992 ])
8993
8994 # _LT_DECL_SED
8995 # ------------
8996 # Check for a fully-functional sed program, that truncates
8997 # as few characters as possible.  Prefer GNU sed if found.
8998 m4_defun([_LT_DECL_SED],
8999 [AC_PROG_SED
9000 test -z "$SED" && SED=sed
9001 Xsed="$SED -e 1s/^X//"
9002 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
9003 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
9004     [Sed that helps us avoid accidentally triggering echo(1) options like -n])
9005 ])# _LT_DECL_SED
9006
9007 m4_ifndef([AC_PROG_SED], [
9008 # NOTE: This macro has been submitted for inclusion into   #
9009 #  GNU Autoconf as AC_PROG_SED.  When it is available in   #
9010 #  a released version of Autoconf we should remove this    #
9011 #  macro and use it instead.                               #
9012
9013 m4_defun([AC_PROG_SED],
9014 [AC_MSG_CHECKING([for a sed that does not truncate output])
9015 AC_CACHE_VAL(lt_cv_path_SED,
9016 [# Loop through the user's path and test for sed and gsed.
9017 # Then use that list of sed's as ones to test for truncation.
9018 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9019 for as_dir in $PATH
9020 do
9021   IFS=$as_save_IFS
9022   test -z "$as_dir" && as_dir=.
9023   for lt_ac_prog in sed gsed; do
9024     for ac_exec_ext in '' $ac_executable_extensions; do
9025       if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
9026         lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
9027       fi
9028     done
9029   done
9030 done
9031 IFS=$as_save_IFS
9032 lt_ac_max=0
9033 lt_ac_count=0
9034 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
9035 # along with /bin/sed that truncates output.
9036 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
9037   test ! -f $lt_ac_sed && continue
9038   cat /dev/null > conftest.in
9039   lt_ac_count=0
9040   echo $ECHO_N "0123456789$ECHO_C" >conftest.in
9041   # Check for GNU sed and select it if it is found.
9042   if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
9043     lt_cv_path_SED=$lt_ac_sed
9044     break
9045   fi
9046   while true; do
9047     cat conftest.in conftest.in >conftest.tmp
9048     mv conftest.tmp conftest.in
9049     cp conftest.in conftest.nl
9050     echo >>conftest.nl
9051     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
9052     cmp -s conftest.out conftest.nl || break
9053     # 10000 chars as input seems more than enough
9054     test $lt_ac_count -gt 10 && break
9055     lt_ac_count=`expr $lt_ac_count + 1`
9056     if test $lt_ac_count -gt $lt_ac_max; then
9057       lt_ac_max=$lt_ac_count
9058       lt_cv_path_SED=$lt_ac_sed
9059     fi
9060   done
9061 done
9062 ])
9063 SED=$lt_cv_path_SED
9064 AC_SUBST([SED])
9065 AC_MSG_RESULT([$SED])
9066 ])#AC_PROG_SED
9067 ])#m4_ifndef
9068
9069 # Old name:
9070 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
9071 dnl aclocal-1.4 backwards compatibility:
9072 dnl AC_DEFUN([LT_AC_PROG_SED], [])
9073
9074
9075 # _LT_CHECK_SHELL_FEATURES
9076 # ------------------------
9077 # Find out whether the shell is Bourne or XSI compatible,
9078 # or has some other useful features.
9079 m4_defun([_LT_CHECK_SHELL_FEATURES],
9080 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
9081 # Try some XSI features
9082 xsi_shell=no
9083 ( _lt_dummy="a/b/c"
9084   test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
9085       = c,a/b,b/c, \
9086     && eval 'test $(( 1 + 1 )) -eq 2 \
9087     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
9088   && xsi_shell=yes
9089 AC_MSG_RESULT([$xsi_shell])
9090 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
9091
9092 AC_MSG_CHECKING([whether the shell understands "+="])
9093 lt_shell_append=no
9094 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
9095     >/dev/null 2>&1 \
9096   && lt_shell_append=yes
9097 AC_MSG_RESULT([$lt_shell_append])
9098 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
9099
9100 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
9101   lt_unset=unset
9102 else
9103   lt_unset=false
9104 fi
9105 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
9106
9107 # test EBCDIC or ASCII
9108 case `echo X|tr X '\101'` in
9109  A) # ASCII based system
9110     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
9111   lt_SP2NL='tr \040 \012'
9112   lt_NL2SP='tr \015\012 \040\040'
9113   ;;
9114  *) # EBCDIC based system
9115   lt_SP2NL='tr \100 \n'
9116   lt_NL2SP='tr \r\n \100\100'
9117   ;;
9118 esac
9119 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
9120 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
9121 ])# _LT_CHECK_SHELL_FEATURES
9122
9123
9124 # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
9125 # ------------------------------------------------------
9126 # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
9127 # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
9128 m4_defun([_LT_PROG_FUNCTION_REPLACE],
9129 [dnl {
9130 sed -e '/^$1 ()$/,/^} # $1 /c\
9131 $1 ()\
9132 {\
9133 m4_bpatsubsts([$2], [$], [\\], [^\([     ]\)], [\\\1])
9134 } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
9135   && mv -f "$cfgfile.tmp" "$cfgfile" \
9136     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9137 test 0 -eq $? || _lt_function_replace_fail=:
9138 ])
9139
9140
9141 # _LT_PROG_REPLACE_SHELLFNS
9142 # -------------------------
9143 # Replace existing portable implementations of several shell functions with
9144 # equivalent extended shell implementations where those features are available..
9145 m4_defun([_LT_PROG_REPLACE_SHELLFNS],
9146 [if test x"$xsi_shell" = xyes; then
9147   _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
9148     case ${1} in
9149       */*) func_dirname_result="${1%/*}${2}" ;;
9150       *  ) func_dirname_result="${3}" ;;
9151     esac])
9152
9153   _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
9154     func_basename_result="${1##*/}"])
9155
9156   _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
9157     case ${1} in
9158       */*) func_dirname_result="${1%/*}${2}" ;;
9159       *  ) func_dirname_result="${3}" ;;
9160     esac
9161     func_basename_result="${1##*/}"])
9162
9163   _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
9164     # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
9165     # positional parameters, so assign one to ordinary parameter first.
9166     func_stripname_result=${3}
9167     func_stripname_result=${func_stripname_result#"${1}"}
9168     func_stripname_result=${func_stripname_result%"${2}"}])
9169
9170   _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
9171     func_split_long_opt_name=${1%%=*}
9172     func_split_long_opt_arg=${1#*=}])
9173
9174   _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
9175     func_split_short_opt_arg=${1#??}
9176     func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
9177
9178   _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
9179     case ${1} in
9180       *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
9181       *)    func_lo2o_result=${1} ;;
9182     esac])
9183
9184   _LT_PROG_FUNCTION_REPLACE([func_xform], [    func_xform_result=${1%.*}.lo])
9185
9186   _LT_PROG_FUNCTION_REPLACE([func_arith], [    func_arith_result=$(( $[*] ))])
9187
9188   _LT_PROG_FUNCTION_REPLACE([func_len], [    func_len_result=${#1}])
9189 fi
9190
9191 if test x"$lt_shell_append" = xyes; then
9192   _LT_PROG_FUNCTION_REPLACE([func_append], [    eval "${1}+=\\${2}"])
9193
9194   _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
9195     func_quote_for_eval "${2}"
9196 dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
9197     eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
9198
9199   # Save a `func_append' function call where possible by direct use of '+='
9200   sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
9201     && mv -f "$cfgfile.tmp" "$cfgfile" \
9202       || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9203   test 0 -eq $? || _lt_function_replace_fail=:
9204 else
9205   # Save a `func_append' function call even when '+=' is not available
9206   sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
9207     && mv -f "$cfgfile.tmp" "$cfgfile" \
9208       || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
9209   test 0 -eq $? || _lt_function_replace_fail=:
9210 fi
9211
9212 if test x"$_lt_function_replace_fail" = x":"; then
9213   AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
9214 fi
9215 ])
9216
9217 # _LT_PATH_CONVERSION_FUNCTIONS
9218 # -----------------------------
9219 # Determine which file name conversion functions should be used by
9220 # func_to_host_file (and, implicitly, by func_to_host_path).  These are needed
9221 # for certain cross-compile configurations and native mingw.
9222 m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
9223 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
9224 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
9225 AC_MSG_CHECKING([how to convert $build file names to $host format])
9226 AC_CACHE_VAL(lt_cv_to_host_file_cmd,
9227 [case $host in
9228   *-*-mingw* )
9229     case $build in
9230       *-*-mingw* ) # actually msys
9231         lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
9232         ;;
9233       *-*-cygwin* )
9234         lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
9235         ;;
9236       * ) # otherwise, assume *nix
9237         lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
9238         ;;
9239     esac
9240     ;;
9241   *-*-cygwin* )
9242     case $build in
9243       *-*-mingw* ) # actually msys
9244         lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
9245         ;;
9246       *-*-cygwin* )
9247         lt_cv_to_host_file_cmd=func_convert_file_noop
9248         ;;
9249       * ) # otherwise, assume *nix
9250         lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
9251         ;;
9252     esac
9253     ;;
9254   * ) # unhandled hosts (and "normal" native builds)
9255     lt_cv_to_host_file_cmd=func_convert_file_noop
9256     ;;
9257 esac
9258 ])
9259 to_host_file_cmd=$lt_cv_to_host_file_cmd
9260 AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
9261 _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
9262          [0], [convert $build file names to $host format])dnl
9263
9264 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
9265 AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
9266 [#assume ordinary cross tools, or native build.
9267 lt_cv_to_tool_file_cmd=func_convert_file_noop
9268 case $host in
9269   *-*-mingw* )
9270     case $build in
9271       *-*-mingw* ) # actually msys
9272         lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
9273         ;;
9274     esac
9275     ;;
9276 esac
9277 ])
9278 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
9279 AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
9280 _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
9281          [0], [convert $build files to toolchain format])dnl
9282 ])# _LT_PATH_CONVERSION_FUNCTIONS
9283
9284 # Helper functions for option handling.                    -*- Autoconf -*-
9285 #
9286 #   Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
9287 #   Inc.
9288 #   Written by Gary V. Vaughan, 2004
9289 #
9290 # This file is free software; the Free Software Foundation gives
9291 # unlimited permission to copy and/or distribute it, with or without
9292 # modifications, as long as this notice is preserved.
9293
9294 # serial 7 ltoptions.m4
9295
9296 # This is to help aclocal find these macros, as it can't see m4_define.
9297 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
9298
9299
9300 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
9301 # ------------------------------------------
9302 m4_define([_LT_MANGLE_OPTION],
9303 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
9304
9305
9306 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
9307 # ---------------------------------------
9308 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
9309 # matching handler defined, dispatch to it.  Other OPTION-NAMEs are
9310 # saved as a flag.
9311 m4_define([_LT_SET_OPTION],
9312 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
9313 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
9314         _LT_MANGLE_DEFUN([$1], [$2]),
9315     [m4_warning([Unknown $1 option `$2'])])[]dnl
9316 ])
9317
9318
9319 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
9320 # ------------------------------------------------------------
9321 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
9322 m4_define([_LT_IF_OPTION],
9323 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
9324
9325
9326 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
9327 # -------------------------------------------------------
9328 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
9329 # are set.
9330 m4_define([_LT_UNLESS_OPTIONS],
9331 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9332             [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
9333                       [m4_define([$0_found])])])[]dnl
9334 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
9335 ])[]dnl
9336 ])
9337
9338
9339 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
9340 # ----------------------------------------
9341 # OPTION-LIST is a space-separated list of Libtool options associated
9342 # with MACRO-NAME.  If any OPTION has a matching handler declared with
9343 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
9344 # the unknown option and exit.
9345 m4_defun([_LT_SET_OPTIONS],
9346 [# Set options
9347 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9348     [_LT_SET_OPTION([$1], _LT_Option)])
9349
9350 m4_if([$1],[LT_INIT],[
9351   dnl
9352   dnl Simply set some default values (i.e off) if boolean options were not
9353   dnl specified:
9354   _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
9355   ])
9356   _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
9357   ])
9358   dnl
9359   dnl If no reference was made to various pairs of opposing options, then
9360   dnl we run the default mode handler for the pair.  For example, if neither
9361   dnl `shared' nor `disable-shared' was passed, we enable building of shared
9362   dnl archives by default:
9363   _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
9364   _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
9365   _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
9366   _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
9367                    [_LT_ENABLE_FAST_INSTALL])
9368   ])
9369 ])# _LT_SET_OPTIONS
9370
9371
9372
9373 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
9374 # -----------------------------------------
9375 m4_define([_LT_MANGLE_DEFUN],
9376 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
9377
9378
9379 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
9380 # -----------------------------------------------
9381 m4_define([LT_OPTION_DEFINE],
9382 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
9383 ])# LT_OPTION_DEFINE
9384
9385
9386 # dlopen
9387 # ------
9388 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
9389 ])
9390
9391 AU_DEFUN([AC_LIBTOOL_DLOPEN],
9392 [_LT_SET_OPTION([LT_INIT], [dlopen])
9393 AC_DIAGNOSE([obsolete],
9394 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9395 put the `dlopen' option into LT_INIT's first parameter.])
9396 ])
9397
9398 dnl aclocal-1.4 backwards compatibility:
9399 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
9400
9401
9402 # win32-dll
9403 # ---------
9404 # Declare package support for building win32 dll's.
9405 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
9406 [enable_win32_dll=yes
9407
9408 case $host in
9409 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
9410   AC_CHECK_TOOL(AS, as, false)
9411   AC_CHECK_TOOL(DLLTOOL, dlltool, false)
9412   AC_CHECK_TOOL(OBJDUMP, objdump, false)
9413   ;;
9414 esac
9415
9416 test -z "$AS" && AS=as
9417 _LT_DECL([], [AS],      [1], [Assembler program])dnl
9418
9419 test -z "$DLLTOOL" && DLLTOOL=dlltool
9420 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
9421
9422 test -z "$OBJDUMP" && OBJDUMP=objdump
9423 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
9424 ])# win32-dll
9425
9426 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
9427 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
9428 _LT_SET_OPTION([LT_INIT], [win32-dll])
9429 AC_DIAGNOSE([obsolete],
9430 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9431 put the `win32-dll' option into LT_INIT's first parameter.])
9432 ])
9433
9434 dnl aclocal-1.4 backwards compatibility:
9435 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
9436
9437
9438 # _LT_ENABLE_SHARED([DEFAULT])
9439 # ----------------------------
9440 # implement the --enable-shared flag, and supports the `shared' and
9441 # `disable-shared' LT_INIT options.
9442 # DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
9443 m4_define([_LT_ENABLE_SHARED],
9444 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
9445 AC_ARG_ENABLE([shared],
9446     [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
9447         [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
9448     [p=${PACKAGE-default}
9449     case $enableval in
9450     yes) enable_shared=yes ;;
9451     no) enable_shared=no ;;
9452     *)
9453       enable_shared=no
9454       # Look at the argument we got.  We use all the common list separators.
9455       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9456       for pkg in $enableval; do
9457         IFS="$lt_save_ifs"
9458         if test "X$pkg" = "X$p"; then
9459           enable_shared=yes
9460         fi
9461       done
9462       IFS="$lt_save_ifs"
9463       ;;
9464     esac],
9465     [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
9466
9467     _LT_DECL([build_libtool_libs], [enable_shared], [0],
9468         [Whether or not to build shared libraries])
9469 ])# _LT_ENABLE_SHARED
9470
9471 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
9472 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
9473
9474 # Old names:
9475 AC_DEFUN([AC_ENABLE_SHARED],
9476 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
9477 ])
9478
9479 AC_DEFUN([AC_DISABLE_SHARED],
9480 [_LT_SET_OPTION([LT_INIT], [disable-shared])
9481 ])
9482
9483 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
9484 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
9485
9486 dnl aclocal-1.4 backwards compatibility:
9487 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
9488 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
9489
9490
9491
9492 # _LT_ENABLE_STATIC([DEFAULT])
9493 # ----------------------------
9494 # implement the --enable-static flag, and support the `static' and
9495 # `disable-static' LT_INIT options.
9496 # DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
9497 m4_define([_LT_ENABLE_STATIC],
9498 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
9499 AC_ARG_ENABLE([static],
9500     [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
9501         [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
9502     [p=${PACKAGE-default}
9503     case $enableval in
9504     yes) enable_static=yes ;;
9505     no) enable_static=no ;;
9506     *)
9507      enable_static=no
9508       # Look at the argument we got.  We use all the common list separators.
9509       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9510       for pkg in $enableval; do
9511         IFS="$lt_save_ifs"
9512         if test "X$pkg" = "X$p"; then
9513           enable_static=yes
9514         fi
9515       done
9516       IFS="$lt_save_ifs"
9517       ;;
9518     esac],
9519     [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
9520
9521     _LT_DECL([build_old_libs], [enable_static], [0],
9522         [Whether or not to build static libraries])
9523 ])# _LT_ENABLE_STATIC
9524
9525 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
9526 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
9527
9528 # Old names:
9529 AC_DEFUN([AC_ENABLE_STATIC],
9530 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
9531 ])
9532
9533 AC_DEFUN([AC_DISABLE_STATIC],
9534 [_LT_SET_OPTION([LT_INIT], [disable-static])
9535 ])
9536
9537 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
9538 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
9539
9540 dnl aclocal-1.4 backwards compatibility:
9541 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
9542 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
9543
9544
9545
9546 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
9547 # ----------------------------------
9548 # implement the --enable-fast-install flag, and support the `fast-install'
9549 # and `disable-fast-install' LT_INIT options.
9550 # DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
9551 m4_define([_LT_ENABLE_FAST_INSTALL],
9552 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
9553 AC_ARG_ENABLE([fast-install],
9554     [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
9555     [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
9556     [p=${PACKAGE-default}
9557     case $enableval in
9558     yes) enable_fast_install=yes ;;
9559     no) enable_fast_install=no ;;
9560     *)
9561       enable_fast_install=no
9562       # Look at the argument we got.  We use all the common list separators.
9563       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9564       for pkg in $enableval; do
9565         IFS="$lt_save_ifs"
9566         if test "X$pkg" = "X$p"; then
9567           enable_fast_install=yes
9568         fi
9569       done
9570       IFS="$lt_save_ifs"
9571       ;;
9572     esac],
9573     [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
9574
9575 _LT_DECL([fast_install], [enable_fast_install], [0],
9576          [Whether or not to optimize for fast installation])dnl
9577 ])# _LT_ENABLE_FAST_INSTALL
9578
9579 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
9580 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
9581
9582 # Old names:
9583 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
9584 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
9585 AC_DIAGNOSE([obsolete],
9586 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9587 the `fast-install' option into LT_INIT's first parameter.])
9588 ])
9589
9590 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
9591 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
9592 AC_DIAGNOSE([obsolete],
9593 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9594 the `disable-fast-install' option into LT_INIT's first parameter.])
9595 ])
9596
9597 dnl aclocal-1.4 backwards compatibility:
9598 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
9599 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
9600
9601
9602 # _LT_WITH_PIC([MODE])
9603 # --------------------
9604 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
9605 # LT_INIT options.
9606 # MODE is either `yes' or `no'.  If omitted, it defaults to `both'.
9607 m4_define([_LT_WITH_PIC],
9608 [AC_ARG_WITH([pic],
9609     [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
9610         [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
9611     [lt_p=${PACKAGE-default}
9612     case $withval in
9613     yes|no) pic_mode=$withval ;;
9614     *)
9615       pic_mode=default
9616       # Look at the argument we got.  We use all the common list separators.
9617       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9618       for lt_pkg in $withval; do
9619         IFS="$lt_save_ifs"
9620         if test "X$lt_pkg" = "X$lt_p"; then
9621           pic_mode=yes
9622         fi
9623       done
9624       IFS="$lt_save_ifs"
9625       ;;
9626     esac],
9627     [pic_mode=default])
9628
9629 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
9630
9631 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
9632 ])# _LT_WITH_PIC
9633
9634 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
9635 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
9636
9637 # Old name:
9638 AU_DEFUN([AC_LIBTOOL_PICMODE],
9639 [_LT_SET_OPTION([LT_INIT], [pic-only])
9640 AC_DIAGNOSE([obsolete],
9641 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9642 put the `pic-only' option into LT_INIT's first parameter.])
9643 ])
9644
9645 dnl aclocal-1.4 backwards compatibility:
9646 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
9647
9648
9649 m4_define([_LTDL_MODE], [])
9650 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
9651                  [m4_define([_LTDL_MODE], [nonrecursive])])
9652 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
9653                  [m4_define([_LTDL_MODE], [recursive])])
9654 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
9655                  [m4_define([_LTDL_MODE], [subproject])])
9656
9657 m4_define([_LTDL_TYPE], [])
9658 LT_OPTION_DEFINE([LTDL_INIT], [installable],
9659                  [m4_define([_LTDL_TYPE], [installable])])
9660 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
9661                  [m4_define([_LTDL_TYPE], [convenience])])
9662
9663 # ltsugar.m4 -- libtool m4 base layer.                         -*-Autoconf-*-
9664 #
9665 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
9666 # Written by Gary V. Vaughan, 2004
9667 #
9668 # This file is free software; the Free Software Foundation gives
9669 # unlimited permission to copy and/or distribute it, with or without
9670 # modifications, as long as this notice is preserved.
9671
9672 # serial 6 ltsugar.m4
9673
9674 # This is to help aclocal find these macros, as it can't see m4_define.
9675 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
9676
9677
9678 # lt_join(SEP, ARG1, [ARG2...])
9679 # -----------------------------
9680 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
9681 # associated separator.
9682 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
9683 # versions in m4sugar had bugs.
9684 m4_define([lt_join],
9685 [m4_if([$#], [1], [],
9686        [$#], [2], [[$2]],
9687        [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
9688 m4_define([_lt_join],
9689 [m4_if([$#$2], [2], [],
9690        [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
9691
9692
9693 # lt_car(LIST)
9694 # lt_cdr(LIST)
9695 # ------------
9696 # Manipulate m4 lists.
9697 # These macros are necessary as long as will still need to support
9698 # Autoconf-2.59 which quotes differently.
9699 m4_define([lt_car], [[$1]])
9700 m4_define([lt_cdr],
9701 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
9702        [$#], 1, [],
9703        [m4_dquote(m4_shift($@))])])
9704 m4_define([lt_unquote], $1)
9705
9706
9707 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
9708 # ------------------------------------------
9709 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
9710 # Note that neither SEPARATOR nor STRING are expanded; they are appended
9711 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
9712 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
9713 # than defined and empty).
9714 #
9715 # This macro is needed until we can rely on Autoconf 2.62, since earlier
9716 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
9717 m4_define([lt_append],
9718 [m4_define([$1],
9719            m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
9720
9721
9722
9723 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
9724 # ----------------------------------------------------------
9725 # Produce a SEP delimited list of all paired combinations of elements of
9726 # PREFIX-LIST with SUFFIX1 through SUFFIXn.  Each element of the list
9727 # has the form PREFIXmINFIXSUFFIXn.
9728 # Needed until we can rely on m4_combine added in Autoconf 2.62.
9729 m4_define([lt_combine],
9730 [m4_if(m4_eval([$# > 3]), [1],
9731        [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
9732 [[m4_foreach([_Lt_prefix], [$2],
9733              [m4_foreach([_Lt_suffix],
9734                 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
9735         [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
9736
9737
9738 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
9739 # -----------------------------------------------------------------------
9740 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
9741 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
9742 m4_define([lt_if_append_uniq],
9743 [m4_ifdef([$1],
9744           [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
9745                  [lt_append([$1], [$2], [$3])$4],
9746                  [$5])],
9747           [lt_append([$1], [$2], [$3])$4])])
9748
9749
9750 # lt_dict_add(DICT, KEY, VALUE)
9751 # -----------------------------
9752 m4_define([lt_dict_add],
9753 [m4_define([$1($2)], [$3])])
9754
9755
9756 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
9757 # --------------------------------------------
9758 m4_define([lt_dict_add_subkey],
9759 [m4_define([$1($2:$3)], [$4])])
9760
9761
9762 # lt_dict_fetch(DICT, KEY, [SUBKEY])
9763 # ----------------------------------
9764 m4_define([lt_dict_fetch],
9765 [m4_ifval([$3],
9766         m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
9767     m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
9768
9769
9770 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
9771 # -----------------------------------------------------------------
9772 m4_define([lt_if_dict_fetch],
9773 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
9774         [$5],
9775     [$6])])
9776
9777
9778 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
9779 # --------------------------------------------------------------
9780 m4_define([lt_dict_filter],
9781 [m4_if([$5], [], [],
9782   [lt_join(m4_quote(m4_default([$4], [[, ]])),
9783            lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
9784                       [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
9785 ])
9786
9787 # ltversion.m4 -- version numbers                       -*- Autoconf -*-
9788 #
9789 #   Copyright (C) 2004 Free Software Foundation, Inc.
9790 #   Written by Scott James Remnant, 2004
9791 #
9792 # This file is free software; the Free Software Foundation gives
9793 # unlimited permission to copy and/or distribute it, with or without
9794 # modifications, as long as this notice is preserved.
9795
9796 # @configure_input@
9797
9798 # serial 3337 ltversion.m4
9799 # This file is part of GNU Libtool
9800
9801 m4_define([LT_PACKAGE_VERSION], [2.4.2])
9802 m4_define([LT_PACKAGE_REVISION], [1.3337])
9803
9804 AC_DEFUN([LTVERSION_VERSION],
9805 [macro_version='2.4.2'
9806 macro_revision='1.3337'
9807 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
9808 _LT_DECL(, macro_revision, 0)
9809 ])
9810
9811 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions.    -*-Autoconf-*-
9812 #
9813 #   Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
9814 #   Written by Scott James Remnant, 2004.
9815 #
9816 # This file is free software; the Free Software Foundation gives
9817 # unlimited permission to copy and/or distribute it, with or without
9818 # modifications, as long as this notice is preserved.
9819
9820 # serial 5 lt~obsolete.m4
9821
9822 # These exist entirely to fool aclocal when bootstrapping libtool.
9823 #
9824 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
9825 # which have later been changed to m4_define as they aren't part of the
9826 # exported API, or moved to Autoconf or Automake where they belong.
9827 #
9828 # The trouble is, aclocal is a bit thick.  It'll see the old AC_DEFUN
9829 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
9830 # using a macro with the same name in our local m4/libtool.m4 it'll
9831 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
9832 # and doesn't know about Autoconf macros at all.)
9833 #
9834 # So we provide this file, which has a silly filename so it's always
9835 # included after everything else.  This provides aclocal with the
9836 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
9837 # because those macros already exist, or will be overwritten later.
9838 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 
9839 #
9840 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
9841 # Yes, that means every name once taken will need to remain here until
9842 # we give up compatibility with versions before 1.7, at which point
9843 # we need to keep only those names which we still refer to.
9844
9845 # This is to help aclocal find these macros, as it can't see m4_define.
9846 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
9847
9848 m4_ifndef([AC_LIBTOOL_LINKER_OPTION],   [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
9849 m4_ifndef([AC_PROG_EGREP],              [AC_DEFUN([AC_PROG_EGREP])])
9850 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
9851 m4_ifndef([_LT_AC_SHELL_INIT],          [AC_DEFUN([_LT_AC_SHELL_INIT])])
9852 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX],     [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
9853 m4_ifndef([_LT_PROG_LTMAIN],            [AC_DEFUN([_LT_PROG_LTMAIN])])
9854 m4_ifndef([_LT_AC_TAGVAR],              [AC_DEFUN([_LT_AC_TAGVAR])])
9855 m4_ifndef([AC_LTDL_ENABLE_INSTALL],     [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
9856 m4_ifndef([AC_LTDL_PREOPEN],            [AC_DEFUN([AC_LTDL_PREOPEN])])
9857 m4_ifndef([_LT_AC_SYS_COMPILER],        [AC_DEFUN([_LT_AC_SYS_COMPILER])])
9858 m4_ifndef([_LT_AC_LOCK],                [AC_DEFUN([_LT_AC_LOCK])])
9859 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
9860 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF],     [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
9861 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O],     [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
9862 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
9863 m4_ifndef([AC_LIBTOOL_OBJDIR],          [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
9864 m4_ifndef([AC_LTDL_OBJDIR],             [AC_DEFUN([AC_LTDL_OBJDIR])])
9865 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
9866 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP],   [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
9867 m4_ifndef([AC_PATH_MAGIC],              [AC_DEFUN([AC_PATH_MAGIC])])
9868 m4_ifndef([AC_PROG_LD_GNU],             [AC_DEFUN([AC_PROG_LD_GNU])])
9869 m4_ifndef([AC_PROG_LD_RELOAD_FLAG],     [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
9870 m4_ifndef([AC_DEPLIBS_CHECK_METHOD],    [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
9871 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
9872 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
9873 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
9874 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS],  [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
9875 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP],  [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
9876 m4_ifndef([LT_AC_PROG_EGREP],           [AC_DEFUN([LT_AC_PROG_EGREP])])
9877 m4_ifndef([LT_AC_PROG_SED],             [AC_DEFUN([LT_AC_PROG_SED])])
9878 m4_ifndef([_LT_CC_BASENAME],            [AC_DEFUN([_LT_CC_BASENAME])])
9879 m4_ifndef([_LT_COMPILER_BOILERPLATE],   [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
9880 m4_ifndef([_LT_LINKER_BOILERPLATE],     [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
9881 m4_ifndef([_AC_PROG_LIBTOOL],           [AC_DEFUN([_AC_PROG_LIBTOOL])])
9882 m4_ifndef([AC_LIBTOOL_SETUP],           [AC_DEFUN([AC_LIBTOOL_SETUP])])
9883 m4_ifndef([_LT_AC_CHECK_DLFCN],         [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
9884 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER],      [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
9885 m4_ifndef([_LT_AC_TAGCONFIG],           [AC_DEFUN([_LT_AC_TAGCONFIG])])
9886 m4_ifndef([AC_DISABLE_FAST_INSTALL],    [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
9887 m4_ifndef([_LT_AC_LANG_CXX],            [AC_DEFUN([_LT_AC_LANG_CXX])])
9888 m4_ifndef([_LT_AC_LANG_F77],            [AC_DEFUN([_LT_AC_LANG_F77])])
9889 m4_ifndef([_LT_AC_LANG_GCJ],            [AC_DEFUN([_LT_AC_LANG_GCJ])])
9890 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG],   [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
9891 m4_ifndef([_LT_AC_LANG_C_CONFIG],       [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
9892 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
9893 m4_ifndef([_LT_AC_LANG_CXX_CONFIG],     [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
9894 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
9895 m4_ifndef([_LT_AC_LANG_F77_CONFIG],     [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
9896 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
9897 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG],     [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
9898 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG],  [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
9899 m4_ifndef([_LT_AC_LANG_RC_CONFIG],      [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
9900 m4_ifndef([AC_LIBTOOL_CONFIG],          [AC_DEFUN([AC_LIBTOOL_CONFIG])])
9901 m4_ifndef([_LT_AC_FILE_LTDLL_C],        [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
9902 m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
9903 m4_ifndef([_LT_AC_PROG_CXXCPP],         [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
9904 m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
9905 m4_ifndef([_LT_PROG_ECHO_BACKSLASH],    [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
9906 m4_ifndef([_LT_PROG_F77],               [AC_DEFUN([_LT_PROG_F77])])
9907 m4_ifndef([_LT_PROG_FC],                [AC_DEFUN([_LT_PROG_FC])])
9908 m4_ifndef([_LT_PROG_CXX],               [AC_DEFUN([_LT_PROG_CXX])])
9909
9910 # nls.m4 serial 5 (gettext-0.18)
9911 dnl Copyright (C) 1995-2003, 2005-2006, 2008-2010 Free Software Foundation,
9912 dnl Inc.
9913 dnl This file is free software; the Free Software Foundation
9914 dnl gives unlimited permission to copy and/or distribute it,
9915 dnl with or without modifications, as long as this notice is preserved.
9916 dnl
9917 dnl This file can can be used in projects which are not available under
9918 dnl the GNU General Public License or the GNU Library General Public
9919 dnl License but which still want to provide support for the GNU gettext
9920 dnl functionality.
9921 dnl Please note that the actual code of the GNU gettext library is covered
9922 dnl by the GNU Library General Public License, and the rest of the GNU
9923 dnl gettext package package is covered by the GNU General Public License.
9924 dnl They are *not* in the public domain.
9925
9926 dnl Authors:
9927 dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
9928 dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2003.
9929
9930 AC_PREREQ([2.50])
9931
9932 AC_DEFUN([AM_NLS],
9933 [
9934   AC_MSG_CHECKING([whether NLS is requested])
9935   dnl Default is enabled NLS
9936   AC_ARG_ENABLE([nls],
9937     [  --disable-nls           do not use Native Language Support],
9938     USE_NLS=$enableval, USE_NLS=yes)
9939   AC_MSG_RESULT([$USE_NLS])
9940   AC_SUBST([USE_NLS])
9941 ])
9942
9943 # pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
9944 # serial 1 (pkg-config-0.24)
9945
9946 # Copyright Â© 2004 Scott James Remnant <scott@netsplit.com>.
9947 #
9948 # This program is free software; you can redistribute it and/or modify
9949 # it under the terms of the GNU General Public License as published by
9950 # the Free Software Foundation; either version 2 of the License, or
9951 # (at your option) any later version.
9952 #
9953 # This program is distributed in the hope that it will be useful, but
9954 # WITHOUT ANY WARRANTY; without even the implied warranty of
9955 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
9956 # General Public License for more details.
9957 #
9958 # You should have received a copy of the GNU General Public License
9959 # along with this program; if not, write to the Free Software
9960 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
9961 #
9962 # As a special exception to the GNU General Public License, if you
9963 # distribute this file as part of a program that contains a
9964 # configuration script generated by Autoconf, you may include it under
9965 # the same distribution terms that you use for the rest of that program.
9966
9967 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
9968 # ----------------------------------
9969 AC_DEFUN([PKG_PROG_PKG_CONFIG],
9970 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
9971 m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
9972 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
9973 AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
9974 AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
9975
9976 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
9977         AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
9978 fi
9979 if test -n "$PKG_CONFIG"; then
9980         _pkg_min_version=m4_default([$1], [0.9.0])
9981         AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
9982         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
9983                 AC_MSG_RESULT([yes])
9984         else
9985                 AC_MSG_RESULT([no])
9986                 PKG_CONFIG=""
9987         fi
9988 fi[]dnl
9989 ])# PKG_PROG_PKG_CONFIG
9990
9991 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9992 #
9993 # Check to see whether a particular set of modules exists.  Similar
9994 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
9995 #
9996 # Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9997 # only at the first occurence in configure.ac, so if the first place
9998 # it's called might be skipped (such as if it is within an "if", you
9999 # have to call PKG_CHECK_EXISTS manually
10000 # --------------------------------------------------------------
10001 AC_DEFUN([PKG_CHECK_EXISTS],
10002 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
10003 if test -n "$PKG_CONFIG" && \
10004     AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
10005   m4_default([$2], [:])
10006 m4_ifvaln([$3], [else
10007   $3])dnl
10008 fi])
10009
10010 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
10011 # ---------------------------------------------
10012 m4_define([_PKG_CONFIG],
10013 [if test -n "$$1"; then
10014     pkg_cv_[]$1="$$1"
10015  elif test -n "$PKG_CONFIG"; then
10016     PKG_CHECK_EXISTS([$3],
10017                      [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
10018                      [pkg_failed=yes])
10019  else
10020     pkg_failed=untried
10021 fi[]dnl
10022 ])# _PKG_CONFIG
10023
10024 # _PKG_SHORT_ERRORS_SUPPORTED
10025 # -----------------------------
10026 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
10027 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
10028 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
10029         _pkg_short_errors_supported=yes
10030 else
10031         _pkg_short_errors_supported=no
10032 fi[]dnl
10033 ])# _PKG_SHORT_ERRORS_SUPPORTED
10034
10035
10036 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
10037 # [ACTION-IF-NOT-FOUND])
10038 #
10039 #
10040 # Note that if there is a possibility the first call to
10041 # PKG_CHECK_MODULES might not happen, you should be sure to include an
10042 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
10043 #
10044 #
10045 # --------------------------------------------------------------
10046 AC_DEFUN([PKG_CHECK_MODULES],
10047 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
10048 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
10049 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
10050
10051 pkg_failed=no
10052 AC_MSG_CHECKING([for $1])
10053
10054 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
10055 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
10056
10057 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
10058 and $1[]_LIBS to avoid the need to call pkg-config.
10059 See the pkg-config man page for more details.])
10060
10061 if test $pkg_failed = yes; then
10062         AC_MSG_RESULT([no])
10063         _PKG_SHORT_ERRORS_SUPPORTED
10064         if test $_pkg_short_errors_supported = yes; then
10065                 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
10066         else 
10067                 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
10068         fi
10069         # Put the nasty error message in config.log where it belongs
10070         echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
10071
10072         m4_default([$4], [AC_MSG_ERROR(
10073 [Package requirements ($2) were not met:
10074
10075 $$1_PKG_ERRORS
10076
10077 Consider adjusting the PKG_CONFIG_PATH environment variable if you
10078 installed software in a non-standard prefix.
10079
10080 _PKG_TEXT])
10081         ])
10082 elif test $pkg_failed = untried; then
10083         AC_MSG_RESULT([no])
10084         m4_default([$4], [AC_MSG_FAILURE(
10085 [The pkg-config script could not be found or is too old.  Make sure it
10086 is in your PATH or set the PKG_CONFIG environment variable to the full
10087 path to pkg-config.
10088
10089 _PKG_TEXT
10090
10091 To get pkg-config, see <http://pkg-config.freedesktop.org/>.])
10092         ])
10093 else
10094         $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
10095         $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
10096         AC_MSG_RESULT([yes])
10097         $3
10098 fi[]dnl
10099 ])# PKG_CHECK_MODULES
10100
10101 # Configure paths for GLIB
10102 # Owen Taylor     1997-2001
10103
10104 dnl AM_PATH_GLIB_2_0([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]])
10105 dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if gmodule, gobject,
10106 dnl gthread, or gio is specified in MODULES, pass to pkg-config
10107 dnl
10108 AC_DEFUN([AM_PATH_GLIB_2_0],
10109 [dnl 
10110 dnl Get the cflags and libraries from pkg-config
10111 dnl
10112 AC_ARG_ENABLE(glibtest, [  --disable-glibtest      do not try to compile and run a test GLIB program],
10113                     , enable_glibtest=yes)
10114
10115   pkg_config_args=glib-2.0
10116   for module in . $4
10117   do
10118       case "$module" in
10119          gmodule) 
10120              pkg_config_args="$pkg_config_args gmodule-2.0"
10121          ;;
10122          gmodule-no-export) 
10123              pkg_config_args="$pkg_config_args gmodule-no-export-2.0"
10124          ;;
10125          gobject) 
10126              pkg_config_args="$pkg_config_args gobject-2.0"
10127          ;;
10128          gthread) 
10129              pkg_config_args="$pkg_config_args gthread-2.0"
10130          ;;
10131          gio*) 
10132              pkg_config_args="$pkg_config_args $module-2.0"
10133          ;;
10134       esac
10135   done
10136
10137   PKG_PROG_PKG_CONFIG([0.16])
10138
10139   no_glib=""
10140
10141   if test "x$PKG_CONFIG" = x ; then
10142     no_glib=yes
10143     PKG_CONFIG=no
10144   fi
10145
10146   min_glib_version=ifelse([$1], ,2.0.0,$1)
10147   AC_MSG_CHECKING(for GLIB - version >= $min_glib_version)
10148
10149   if test x$PKG_CONFIG != xno ; then
10150     ## don't try to run the test against uninstalled libtool libs
10151     if $PKG_CONFIG --uninstalled $pkg_config_args; then
10152           echo "Will use uninstalled version of GLib found in PKG_CONFIG_PATH"
10153           enable_glibtest=no
10154     fi
10155
10156     if $PKG_CONFIG --atleast-version $min_glib_version $pkg_config_args; then
10157           :
10158     else
10159           no_glib=yes
10160     fi
10161   fi
10162
10163   if test x"$no_glib" = x ; then
10164     GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
10165     GOBJECT_QUERY=`$PKG_CONFIG --variable=gobject_query glib-2.0`
10166     GLIB_MKENUMS=`$PKG_CONFIG --variable=glib_mkenums glib-2.0`
10167     GLIB_COMPILE_RESOURCES=`$PKG_CONFIG --variable=glib_compile_resources gio-2.0`
10168
10169     GLIB_CFLAGS=`$PKG_CONFIG --cflags $pkg_config_args`
10170     GLIB_LIBS=`$PKG_CONFIG --libs $pkg_config_args`
10171     glib_config_major_version=`$PKG_CONFIG --modversion glib-2.0 | \
10172            sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
10173     glib_config_minor_version=`$PKG_CONFIG --modversion glib-2.0 | \
10174            sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
10175     glib_config_micro_version=`$PKG_CONFIG --modversion glib-2.0 | \
10176            sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
10177     if test "x$enable_glibtest" = "xyes" ; then
10178       ac_save_CFLAGS="$CFLAGS"
10179       ac_save_LIBS="$LIBS"
10180       CFLAGS="$CFLAGS $GLIB_CFLAGS"
10181       LIBS="$GLIB_LIBS $LIBS"
10182 dnl
10183 dnl Now check if the installed GLIB is sufficiently new. (Also sanity
10184 dnl checks the results of pkg-config to some extent)
10185 dnl
10186       rm -f conf.glibtest
10187       AC_TRY_RUN([
10188 #include <glib.h>
10189 #include <stdio.h>
10190 #include <stdlib.h>
10191
10192 int 
10193 main ()
10194 {
10195   unsigned int major, minor, micro;
10196   char *tmp_version;
10197
10198   fclose (fopen ("conf.glibtest", "w"));
10199
10200   /* HP/UX 9 (%@#!) writes to sscanf strings */
10201   tmp_version = g_strdup("$min_glib_version");
10202   if (sscanf(tmp_version, "%u.%u.%u", &major, &minor, &micro) != 3) {
10203      printf("%s, bad version string\n", "$min_glib_version");
10204      exit(1);
10205    }
10206
10207   if ((glib_major_version != $glib_config_major_version) ||
10208       (glib_minor_version != $glib_config_minor_version) ||
10209       (glib_micro_version != $glib_config_micro_version))
10210     {
10211       printf("\n*** 'pkg-config --modversion glib-2.0' returned %d.%d.%d, but GLIB (%d.%d.%d)\n", 
10212              $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version,
10213              glib_major_version, glib_minor_version, glib_micro_version);
10214       printf ("*** was found! If pkg-config was correct, then it is best\n");
10215       printf ("*** to remove the old version of GLib. You may also be able to fix the error\n");
10216       printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
10217       printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
10218       printf("*** required on your system.\n");
10219       printf("*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH\n");
10220       printf("*** to point to the correct configuration files\n");
10221     } 
10222   else if ((glib_major_version != GLIB_MAJOR_VERSION) ||
10223            (glib_minor_version != GLIB_MINOR_VERSION) ||
10224            (glib_micro_version != GLIB_MICRO_VERSION))
10225     {
10226       printf("*** GLIB header files (version %d.%d.%d) do not match\n",
10227              GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION);
10228       printf("*** library (version %d.%d.%d)\n",
10229              glib_major_version, glib_minor_version, glib_micro_version);
10230     }
10231   else
10232     {
10233       if ((glib_major_version > major) ||
10234         ((glib_major_version == major) && (glib_minor_version > minor)) ||
10235         ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro)))
10236       {
10237         return 0;
10238        }
10239      else
10240       {
10241         printf("\n*** An old version of GLIB (%u.%u.%u) was found.\n",
10242                glib_major_version, glib_minor_version, glib_micro_version);
10243         printf("*** You need a version of GLIB newer than %u.%u.%u. The latest version of\n",
10244                major, minor, micro);
10245         printf("*** GLIB is always available from ftp://ftp.gtk.org.\n");
10246         printf("***\n");
10247         printf("*** If you have already installed a sufficiently new version, this error\n");
10248         printf("*** probably means that the wrong copy of the pkg-config shell script is\n");
10249         printf("*** being found. The easiest way to fix this is to remove the old version\n");
10250         printf("*** of GLIB, but you can also set the PKG_CONFIG environment to point to the\n");
10251         printf("*** correct copy of pkg-config. (In this case, you will have to\n");
10252         printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
10253         printf("*** so that the correct libraries are found at run-time))\n");
10254       }
10255     }
10256   return 1;
10257 }
10258 ],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
10259        CFLAGS="$ac_save_CFLAGS"
10260        LIBS="$ac_save_LIBS"
10261      fi
10262   fi
10263   if test "x$no_glib" = x ; then
10264      AC_MSG_RESULT(yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version))
10265      ifelse([$2], , :, [$2])     
10266   else
10267      AC_MSG_RESULT(no)
10268      if test "$PKG_CONFIG" = "no" ; then
10269        echo "*** A new enough version of pkg-config was not found."
10270        echo "*** See http://www.freedesktop.org/software/pkgconfig/"
10271      else
10272        if test -f conf.glibtest ; then
10273         :
10274        else
10275           echo "*** Could not run GLIB test program, checking why..."
10276           ac_save_CFLAGS="$CFLAGS"
10277           ac_save_LIBS="$LIBS"
10278           CFLAGS="$CFLAGS $GLIB_CFLAGS"
10279           LIBS="$LIBS $GLIB_LIBS"
10280           AC_TRY_LINK([
10281 #include <glib.h>
10282 #include <stdio.h>
10283 ],      [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ],
10284         [ echo "*** The test program compiled, but did not run. This usually means"
10285           echo "*** that the run-time linker is not finding GLIB or finding the wrong"
10286           echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your"
10287           echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
10288           echo "*** to the installed location  Also, make sure you have run ldconfig if that"
10289           echo "*** is required on your system"
10290           echo "***"
10291           echo "*** If you have an old version installed, it is best to remove it, although"
10292           echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ],
10293         [ echo "*** The test program failed to compile or link. See the file config.log for the"
10294           echo "*** exact error that occured. This usually means GLIB is incorrectly installed."])
10295           CFLAGS="$ac_save_CFLAGS"
10296           LIBS="$ac_save_LIBS"
10297        fi
10298      fi
10299      GLIB_CFLAGS=""
10300      GLIB_LIBS=""
10301      GLIB_GENMARSHAL=""
10302      GOBJECT_QUERY=""
10303      GLIB_MKENUMS=""
10304      GLIB_COMPILE_RESOURCES=""
10305      ifelse([$3], , :, [$3])
10306   fi
10307   AC_SUBST(GLIB_CFLAGS)
10308   AC_SUBST(GLIB_LIBS)
10309   AC_SUBST(GLIB_GENMARSHAL)
10310   AC_SUBST(GOBJECT_QUERY)
10311   AC_SUBST(GLIB_MKENUMS)
10312   AC_SUBST(GLIB_COMPILE_RESOURCES)
10313   rm -f conf.glibtest
10314 ])
10315
10316 # Copyright (C) 1995-2002 Free Software Foundation, Inc.
10317 # Copyright (C) 2001-2003,2004 Red Hat, Inc.
10318 #
10319 # This file is free software, distributed under the terms of the GNU
10320 # General Public License.  As a special exception to the GNU General
10321 # Public License, this file may be distributed as part of a program
10322 # that contains a configuration script generated by Autoconf, under
10323 # the same distribution terms as the rest of that program.
10324 #
10325 # This file can be copied and used freely without restrictions.  It can
10326 # be used in projects which are not available under the GNU Public License
10327 # but which still want to provide support for the GNU gettext functionality.
10328 #
10329 # Macro to add for using GNU gettext.
10330 # Ulrich Drepper <drepper@cygnus.com>, 1995, 1996
10331 #
10332 # Modified to never use included libintl. 
10333 # Owen Taylor <otaylor@redhat.com>, 12/15/1998
10334 #
10335 # Major rework to remove unused code
10336 # Owen Taylor <otaylor@redhat.com>, 12/11/2002
10337 #
10338 # Added better handling of ALL_LINGUAS from GNU gettext version 
10339 # written by Bruno Haible, Owen Taylor <otaylor.redhat.com> 5/30/3002
10340 #
10341 # Modified to require ngettext
10342 # Matthias Clasen <mclasen@redhat.com> 08/06/2004
10343 #
10344 # We need this here as well, since someone might use autoconf-2.5x
10345 # to configure GLib then an older version to configure a package
10346 # using AM_GLIB_GNU_GETTEXT
10347 AC_PREREQ(2.53)
10348
10349 dnl
10350 dnl We go to great lengths to make sure that aclocal won't 
10351 dnl try to pull in the installed version of these macros
10352 dnl when running aclocal in the glib directory.
10353 dnl
10354 m4_copy([AC_DEFUN],[glib_DEFUN])
10355 m4_copy([AC_REQUIRE],[glib_REQUIRE])
10356 dnl
10357 dnl At the end, if we're not within glib, we'll define the public
10358 dnl definitions in terms of our private definitions.
10359 dnl
10360
10361 # GLIB_LC_MESSAGES
10362 #--------------------
10363 glib_DEFUN([GLIB_LC_MESSAGES],
10364   [AC_CHECK_HEADERS([locale.h])
10365     if test $ac_cv_header_locale_h = yes; then
10366     AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
10367       [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
10368        am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
10369     if test $am_cv_val_LC_MESSAGES = yes; then
10370       AC_DEFINE(HAVE_LC_MESSAGES, 1,
10371         [Define if your <locale.h> file defines LC_MESSAGES.])
10372     fi
10373   fi])
10374
10375 # GLIB_PATH_PROG_WITH_TEST
10376 #----------------------------
10377 dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
10378 dnl   TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
10379 glib_DEFUN([GLIB_PATH_PROG_WITH_TEST],
10380 [# Extract the first word of "$2", so it can be a program name with args.
10381 set dummy $2; ac_word=[$]2
10382 AC_MSG_CHECKING([for $ac_word])
10383 AC_CACHE_VAL(ac_cv_path_$1,
10384 [case "[$]$1" in
10385   /*)
10386   ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
10387   ;;
10388   *)
10389   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
10390   for ac_dir in ifelse([$5], , $PATH, [$5]); do
10391     test -z "$ac_dir" && ac_dir=.
10392     if test -f $ac_dir/$ac_word; then
10393       if [$3]; then
10394         ac_cv_path_$1="$ac_dir/$ac_word"
10395         break
10396       fi
10397     fi
10398   done
10399   IFS="$ac_save_ifs"
10400 dnl If no 4th arg is given, leave the cache variable unset,
10401 dnl so AC_PATH_PROGS will keep looking.
10402 ifelse([$4], , , [  test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
10403 ])dnl
10404   ;;
10405 esac])dnl
10406 $1="$ac_cv_path_$1"
10407 if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
10408   AC_MSG_RESULT([$]$1)
10409 else
10410   AC_MSG_RESULT(no)
10411 fi
10412 AC_SUBST($1)dnl
10413 ])
10414
10415 # GLIB_WITH_NLS
10416 #-----------------
10417 glib_DEFUN([GLIB_WITH_NLS],
10418   dnl NLS is obligatory
10419   [USE_NLS=yes
10420     AC_SUBST(USE_NLS)
10421
10422     gt_cv_have_gettext=no
10423
10424     CATOBJEXT=NONE
10425     XGETTEXT=:
10426     INTLLIBS=
10427
10428     AC_CHECK_HEADER(libintl.h,
10429      [gt_cv_func_dgettext_libintl="no"
10430       libintl_extra_libs=""
10431
10432       #
10433       # First check in libc
10434       #
10435       AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc,
10436         [AC_TRY_LINK([
10437 #include <libintl.h>
10438 ],
10439          [return !ngettext ("","", 1)],
10440           gt_cv_func_ngettext_libc=yes,
10441           gt_cv_func_ngettext_libc=no)
10442         ])
10443   
10444       if test "$gt_cv_func_ngettext_libc" = "yes" ; then
10445               AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc,
10446                 [AC_TRY_LINK([
10447 #include <libintl.h>
10448 ],
10449                   [return !dgettext ("","")],
10450                   gt_cv_func_dgettext_libc=yes,
10451                   gt_cv_func_dgettext_libc=no)
10452                 ])
10453       fi
10454   
10455       if test "$gt_cv_func_ngettext_libc" = "yes" ; then
10456         AC_CHECK_FUNCS(bind_textdomain_codeset)
10457       fi
10458
10459       #
10460       # If we don't have everything we want, check in libintl
10461       #
10462       if test "$gt_cv_func_dgettext_libc" != "yes" \
10463          || test "$gt_cv_func_ngettext_libc" != "yes" \
10464          || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then
10465         
10466         AC_CHECK_LIB(intl, bindtextdomain,
10467             [AC_CHECK_LIB(intl, ngettext,
10468                     [AC_CHECK_LIB(intl, dgettext,
10469                                   gt_cv_func_dgettext_libintl=yes)])])
10470
10471         if test "$gt_cv_func_dgettext_libintl" != "yes" ; then
10472           AC_MSG_CHECKING([if -liconv is needed to use gettext])
10473           AC_MSG_RESULT([])
10474           AC_CHECK_LIB(intl, ngettext,
10475                 [AC_CHECK_LIB(intl, dcgettext,
10476                        [gt_cv_func_dgettext_libintl=yes
10477                         libintl_extra_libs=-liconv],
10478                         :,-liconv)],
10479                 :,-liconv)
10480         fi
10481
10482         #
10483         # If we found libintl, then check in it for bind_textdomain_codeset();
10484         # we'll prefer libc if neither have bind_textdomain_codeset(),
10485         # and both have dgettext and ngettext
10486         #
10487         if test "$gt_cv_func_dgettext_libintl" = "yes" ; then
10488           glib_save_LIBS="$LIBS"
10489           LIBS="$LIBS -lintl $libintl_extra_libs"
10490           unset ac_cv_func_bind_textdomain_codeset
10491           AC_CHECK_FUNCS(bind_textdomain_codeset)
10492           LIBS="$glib_save_LIBS"
10493
10494           if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then
10495             gt_cv_func_dgettext_libc=no
10496           else
10497             if test "$gt_cv_func_dgettext_libc" = "yes" \
10498                 && test "$gt_cv_func_ngettext_libc" = "yes"; then
10499               gt_cv_func_dgettext_libintl=no
10500             fi
10501           fi
10502         fi
10503       fi
10504
10505       if test "$gt_cv_func_dgettext_libc" = "yes" \
10506         || test "$gt_cv_func_dgettext_libintl" = "yes"; then
10507         gt_cv_have_gettext=yes
10508       fi
10509   
10510       if test "$gt_cv_func_dgettext_libintl" = "yes"; then
10511         INTLLIBS="-lintl $libintl_extra_libs"
10512       fi
10513   
10514       if test "$gt_cv_have_gettext" = "yes"; then
10515         AC_DEFINE(HAVE_GETTEXT,1,
10516           [Define if the GNU gettext() function is already present or preinstalled.])
10517         GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
10518           [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
10519         if test "$MSGFMT" != "no"; then
10520           glib_save_LIBS="$LIBS"
10521           LIBS="$LIBS $INTLLIBS"
10522           AC_CHECK_FUNCS(dcgettext)
10523           MSGFMT_OPTS=
10524           AC_MSG_CHECKING([if msgfmt accepts -c])
10525           GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[
10526 msgid ""
10527 msgstr ""
10528 "Content-Type: text/plain; charset=UTF-8\n"
10529 "Project-Id-Version: test 1.0\n"
10530 "PO-Revision-Date: 2007-02-15 12:01+0100\n"
10531 "Last-Translator: test <foo@bar.xx>\n"
10532 "Language-Team: C <LL@li.org>\n"
10533 "MIME-Version: 1.0\n"
10534 "Content-Transfer-Encoding: 8bit\n"
10535 ], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])])
10536           AC_SUBST(MSGFMT_OPTS)
10537           AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
10538           GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
10539             [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
10540           AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
10541                          return _nl_msg_cat_cntr],
10542             [CATOBJEXT=.gmo 
10543              DATADIRNAME=share],
10544             [case $host in
10545             *-*-solaris*)
10546             dnl On Solaris, if bind_textdomain_codeset is in libc,
10547             dnl GNU format message catalog is always supported,
10548             dnl since both are added to the libc all together.
10549             dnl Hence, we'd like to go with DATADIRNAME=share and
10550             dnl and CATOBJEXT=.gmo in this case.
10551             AC_CHECK_FUNC(bind_textdomain_codeset,
10552               [CATOBJEXT=.gmo 
10553                DATADIRNAME=share],
10554               [CATOBJEXT=.mo
10555                DATADIRNAME=lib])
10556             ;;
10557             *-*-openbsd*)
10558             CATOBJEXT=.mo
10559             DATADIRNAME=share
10560             ;;
10561             *)
10562             CATOBJEXT=.mo
10563             DATADIRNAME=lib
10564             ;;
10565             esac])
10566           LIBS="$glib_save_LIBS"
10567           INSTOBJEXT=.mo
10568         else
10569           gt_cv_have_gettext=no
10570         fi
10571       fi
10572     ])
10573
10574     if test "$gt_cv_have_gettext" = "yes" ; then
10575       AC_DEFINE(ENABLE_NLS, 1,
10576         [always defined to indicate that i18n is enabled])
10577     fi
10578
10579     dnl Test whether we really found GNU xgettext.
10580     if test "$XGETTEXT" != ":"; then
10581       dnl If it is not GNU xgettext we define it as : so that the
10582       dnl Makefiles still can work.
10583       if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
10584         : ;
10585       else
10586         AC_MSG_RESULT(
10587           [found xgettext program is not GNU xgettext; ignore it])
10588         XGETTEXT=":"
10589       fi
10590     fi
10591
10592     # We need to process the po/ directory.
10593     POSUB=po
10594
10595     AC_OUTPUT_COMMANDS(
10596       [case "$CONFIG_FILES" in *po/Makefile.in*)
10597         sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
10598       esac])
10599
10600     dnl These rules are solely for the distribution goal.  While doing this
10601     dnl we only have to keep exactly one list of the available catalogs
10602     dnl in configure.ac.
10603     for lang in $ALL_LINGUAS; do
10604       GMOFILES="$GMOFILES $lang.gmo"
10605       POFILES="$POFILES $lang.po"
10606     done
10607
10608     dnl Make all variables we use known to autoconf.
10609     AC_SUBST(CATALOGS)
10610     AC_SUBST(CATOBJEXT)
10611     AC_SUBST(DATADIRNAME)
10612     AC_SUBST(GMOFILES)
10613     AC_SUBST(INSTOBJEXT)
10614     AC_SUBST(INTLLIBS)
10615     AC_SUBST(PO_IN_DATADIR_TRUE)
10616     AC_SUBST(PO_IN_DATADIR_FALSE)
10617     AC_SUBST(POFILES)
10618     AC_SUBST(POSUB)
10619   ])
10620
10621 # AM_GLIB_GNU_GETTEXT
10622 # -------------------
10623 # Do checks necessary for use of gettext. If a suitable implementation 
10624 # of gettext is found in either in libintl or in the C library,
10625 # it will set INTLLIBS to the libraries needed for use of gettext
10626 # and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable
10627 # gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST()
10628 # on various variables needed by the Makefile.in.in installed by 
10629 # glib-gettextize.
10630 dnl
10631 glib_DEFUN([GLIB_GNU_GETTEXT],
10632   [AC_REQUIRE([AC_PROG_CC])dnl
10633    AC_REQUIRE([AC_HEADER_STDC])dnl
10634    
10635    GLIB_LC_MESSAGES
10636    GLIB_WITH_NLS
10637
10638    if test "$gt_cv_have_gettext" = "yes"; then
10639      if test "x$ALL_LINGUAS" = "x"; then
10640        LINGUAS=
10641      else
10642        AC_MSG_CHECKING(for catalogs to be installed)
10643        NEW_LINGUAS=
10644        for presentlang in $ALL_LINGUAS; do
10645          useit=no
10646          if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then
10647            desiredlanguages="$LINGUAS"
10648          else
10649            desiredlanguages="$ALL_LINGUAS"
10650          fi
10651          for desiredlang in $desiredlanguages; do
10652            # Use the presentlang catalog if desiredlang is
10653            #   a. equal to presentlang, or
10654            #   b. a variant of presentlang (because in this case,
10655            #      presentlang can be used as a fallback for messages
10656            #      which are not translated in the desiredlang catalog).
10657            case "$desiredlang" in
10658              "$presentlang"*) useit=yes;;
10659            esac
10660          done
10661          if test $useit = yes; then
10662            NEW_LINGUAS="$NEW_LINGUAS $presentlang"
10663          fi
10664        done
10665        LINGUAS=$NEW_LINGUAS
10666        AC_MSG_RESULT($LINGUAS)
10667      fi
10668
10669      dnl Construct list of names of catalog files to be constructed.
10670      if test -n "$LINGUAS"; then
10671        for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
10672      fi
10673    fi
10674
10675    dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
10676    dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
10677    dnl Try to locate is.
10678    MKINSTALLDIRS=
10679    if test -n "$ac_aux_dir"; then
10680      MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
10681    fi
10682    if test -z "$MKINSTALLDIRS"; then
10683      MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
10684    fi
10685    AC_SUBST(MKINSTALLDIRS)
10686
10687    dnl Generate list of files to be processed by xgettext which will
10688    dnl be included in po/Makefile.
10689    test -d po || mkdir po
10690    if test "x$srcdir" != "x."; then
10691      if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
10692        posrcprefix="$srcdir/"
10693      else
10694        posrcprefix="../$srcdir/"
10695      fi
10696    else
10697      posrcprefix="../"
10698    fi
10699    rm -f po/POTFILES
10700    sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
10701         < $srcdir/po/POTFILES.in > po/POTFILES
10702   ])
10703
10704 # AM_GLIB_DEFINE_LOCALEDIR(VARIABLE)
10705 # -------------------------------
10706 # Define VARIABLE to the location where catalog files will
10707 # be installed by po/Makefile.
10708 glib_DEFUN([GLIB_DEFINE_LOCALEDIR],
10709 [glib_REQUIRE([GLIB_GNU_GETTEXT])dnl
10710 glib_save_prefix="$prefix"
10711 glib_save_exec_prefix="$exec_prefix"
10712 glib_save_datarootdir="$datarootdir"
10713 test "x$prefix" = xNONE && prefix=$ac_default_prefix
10714 test "x$exec_prefix" = xNONE && exec_prefix=$prefix
10715 datarootdir=`eval echo "${datarootdir}"`
10716 if test "x$CATOBJEXT" = "x.mo" ; then
10717   localedir=`eval echo "${libdir}/locale"`
10718 else
10719   localedir=`eval echo "${datadir}/locale"`
10720 fi
10721 prefix="$glib_save_prefix"
10722 exec_prefix="$glib_save_exec_prefix"
10723 datarootdir="$glib_save_datarootdir"
10724 AC_DEFINE_UNQUOTED($1, "$localedir",
10725   [Define the location where the catalogs will be installed])
10726 ])
10727
10728 dnl
10729 dnl Now the definitions that aclocal will find
10730 dnl
10731 ifdef(glib_configure_ac,[],[
10732 AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)])
10733 AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)])
10734 ])dnl
10735
10736 # GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL])
10737
10738 # Create a temporary file with TEST-FILE as its contents and pass the
10739 # file name to PROGRAM.  Perform ACTION-IF-PASS if PROGRAM exits with
10740 # 0 and perform ACTION-IF-FAIL for any other exit status.
10741 AC_DEFUN([GLIB_RUN_PROG],
10742 [cat >conftest.foo <<_ACEOF
10743 $2
10744 _ACEOF
10745 if AC_RUN_LOG([$1 conftest.foo]); then
10746   m4_ifval([$3], [$3], [:])
10747 m4_ifvaln([$4], [else $4])dnl
10748 echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD
10749 sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
10750 fi])
10751
10752