1 # generated automatically by aclocal 1.10 -*- Autoconf -*-
3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
4 # 2005, 2006 Free Software Foundation, Inc.
5 # This file is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
14 m4_if(m4_PACKAGE_VERSION, [2.61],,
15 [m4_fatal([this file was generated for autoconf 2.61.
16 You have another version of autoconf. If you want to use that,
17 you should regenerate the build system entirely.], [63])])
19 # Copyright (C) 2002, 2003, 2005, 2006 Free Software Foundation, Inc.
21 # This file is free software; the Free Software Foundation
22 # gives unlimited permission to copy and/or distribute it,
23 # with or without modifications, as long as this notice is preserved.
25 # AM_AUTOMAKE_VERSION(VERSION)
26 # ----------------------------
27 # Automake X.Y traces this macro to ensure aclocal.m4 has been
28 # generated from the m4 files accompanying Automake X.Y.
29 # (This private macro should not be called outside this file.)
30 AC_DEFUN([AM_AUTOMAKE_VERSION],
31 [am__api_version='1.10'
32 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
33 dnl require some minimum version. Point them to the right macro.
34 m4_if([$1], [1.10], [],
35 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
38 # _AM_AUTOCONF_VERSION(VERSION)
39 # -----------------------------
40 # aclocal traces this macro to find the Autoconf version.
41 # This is a private macro too. Using m4_define simplifies
42 # the logic in aclocal, which can simply ignore this definition.
43 m4_define([_AM_AUTOCONF_VERSION], [])
45 # AM_SET_CURRENT_AUTOMAKE_VERSION
46 # -------------------------------
47 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
48 # This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
49 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
50 [AM_AUTOMAKE_VERSION([1.10])dnl
51 _AM_AUTOCONF_VERSION(m4_PACKAGE_VERSION)])
53 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
55 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
57 # This file is free software; the Free Software Foundation
58 # gives unlimited permission to copy and/or distribute it,
59 # with or without modifications, as long as this notice is preserved.
61 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
62 # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
63 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
65 # Of course, Automake must honor this variable whenever it calls a
66 # tool from the auxiliary directory. The problem is that $srcdir (and
67 # therefore $ac_aux_dir as well) can be either absolute or relative,
68 # depending on how configure is run. This is pretty annoying, since
69 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
70 # source directory, any form will work fine, but in subdirectories a
71 # relative path needs to be adjusted first.
74 # fails when called from a subdirectory if $ac_aux_dir is relative
75 # $top_srcdir/$ac_aux_dir/missing
76 # fails if $ac_aux_dir is absolute,
77 # fails when called from a subdirectory in a VPATH build with
78 # a relative $ac_aux_dir
80 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
81 # are both prefixed by $srcdir. In an in-source build this is usually
82 # harmless because $srcdir is `.', but things will broke when you
83 # start a VPATH build or use an absolute $srcdir.
85 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
86 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
87 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
88 # and then we would define $MISSING as
89 # MISSING="\${SHELL} $am_aux_dir/missing"
90 # This will work as long as MISSING is not called from configure, because
91 # unfortunately $(top_srcdir) has no meaning in configure.
92 # However there are other variables, like CC, which are often used in
93 # configure, and could therefore not use this "fixed" $ac_aux_dir.
95 # Another solution, used here, is to always expand $ac_aux_dir to an
96 # absolute PATH. The drawback is that using absolute paths prevent a
97 # configured tree to be moved without reconfiguration.
99 AC_DEFUN([AM_AUX_DIR_EXPAND],
100 [dnl Rely on autoconf to set up CDPATH properly.
102 # expand $ac_aux_dir to an absolute path
103 am_aux_dir=`cd $ac_aux_dir && pwd`
106 # AM_CONDITIONAL -*- Autoconf -*-
108 # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
109 # Free Software Foundation, Inc.
111 # This file is free software; the Free Software Foundation
112 # gives unlimited permission to copy and/or distribute it,
113 # with or without modifications, as long as this notice is preserved.
117 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
118 # -------------------------------------
119 # Define a conditional.
120 AC_DEFUN([AM_CONDITIONAL],
122 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
123 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
124 AC_SUBST([$1_TRUE])dnl
125 AC_SUBST([$1_FALSE])dnl
126 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
127 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
135 AC_CONFIG_COMMANDS_PRE(
136 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
137 AC_MSG_ERROR([[conditional "$1" was never defined.
138 Usually this means the macro was only invoked conditionally.]])
141 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
142 # Free Software Foundation, Inc.
144 # This file is free software; the Free Software Foundation
145 # gives unlimited permission to copy and/or distribute it,
146 # with or without modifications, as long as this notice is preserved.
150 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
151 # written in clear, in which case automake, when reading aclocal.m4,
152 # will think it sees a *use*, and therefore will trigger all it's
153 # C support machinery. Also note that it means that autoscan, seeing
154 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
157 # _AM_DEPENDENCIES(NAME)
158 # ----------------------
159 # See how the compiler implements dependency checking.
160 # NAME is "CC", "CXX", "GCJ", or "OBJC".
161 # We try a few techniques and use that to set a single cache variable.
163 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
164 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
165 # dependency, and given that the user is not expected to run this macro,
166 # just rely on AC_PROG_CC.
167 AC_DEFUN([_AM_DEPENDENCIES],
168 [AC_REQUIRE([AM_SET_DEPDIR])dnl
169 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
170 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
171 AC_REQUIRE([AM_DEP_TRACK])dnl
173 ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
174 [$1], CXX, [depcc="$CXX" am_compiler_list=],
175 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
176 [$1], UPC, [depcc="$UPC" am_compiler_list=],
177 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
178 [depcc="$$1" am_compiler_list=])
180 AC_CACHE_CHECK([dependency style of $depcc],
181 [am_cv_$1_dependencies_compiler_type],
182 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
183 # We make a subdir and do the tests there. Otherwise we can end up
184 # making bogus files that we don't know about and never remove. For
185 # instance it was reported that on HP-UX the gcc test will end up
186 # making a dummy file named `D' -- because `-MD' means `put the output
189 # Copy depcomp to subdir because otherwise we won't find it if we're
190 # using a relative directory.
191 cp "$am_depcomp" conftest.dir
193 # We will build objects and dependencies in a subdirectory because
194 # it helps to detect inapplicable dependency modes. For instance
195 # both Tru64's cc and ICC support -MD to output dependencies as a
196 # side effect of compilation, but ICC will put the dependencies in
197 # the current directory while Tru64 will put them in the object
201 am_cv_$1_dependencies_compiler_type=none
202 if test "$am_compiler_list" = ""; then
203 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
205 for depmode in $am_compiler_list; do
206 # Setup a source with many dependencies, because some compilers
207 # like to wrap large dependency lists on column 80 (with \), and
208 # we should not choose a depcomp mode which is confused by this.
210 # We need to recreate these files for each test, as the compiler may
211 # overwrite some of them when testing with obscure command lines.
212 # This happens at least with the AIX C compiler.
214 for i in 1 2 3 4 5 6; do
215 echo '#include "conftst'$i'.h"' >> sub/conftest.c
216 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
217 # Solaris 8's {/usr,}/bin/sh.
218 touch sub/conftst$i.h
220 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
224 # after this tag, mechanisms are not by side-effect, so they'll
225 # only be used when explicitly requested
226 if test "x$enable_dependency_tracking" = xyes; then
234 # We check with `-c' and `-o' for the sake of the "dashmstdout"
235 # mode. It turns out that the SunPro C++ compiler does not properly
236 # handle `-M -o', and we need to detect this.
237 if depmode=$depmode \
238 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
239 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
240 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
241 >/dev/null 2>conftest.err &&
242 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
243 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
244 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
245 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
246 # icc doesn't choke on unknown options, it will just issue warnings
247 # or remarks (even with -Werror). So we grep stderr for any message
248 # that says an option was ignored or not supported.
249 # When given -MP, icc 7.0 and 7.1 complain thusly:
250 # icc: Command line warning: ignoring option '-M'; no argument required
251 # The diagnosis changed in icc 8.0:
252 # icc: Command line remark: option '-MP' not supported
253 if (grep 'ignoring option' conftest.err ||
254 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
255 am_cv_$1_dependencies_compiler_type=$depmode
264 am_cv_$1_dependencies_compiler_type=none
267 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
268 AM_CONDITIONAL([am__fastdep$1], [
269 test "x$enable_dependency_tracking" != xno \
270 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
276 # Choose a directory name for dependency files.
277 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
278 AC_DEFUN([AM_SET_DEPDIR],
279 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
280 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
286 AC_DEFUN([AM_DEP_TRACK],
287 [AC_ARG_ENABLE(dependency-tracking,
288 [ --disable-dependency-tracking speeds up one-time build
289 --enable-dependency-tracking do not reject slow dependency extractors])
290 if test "x$enable_dependency_tracking" != xno; then
291 am_depcomp="$ac_aux_dir/depcomp"
294 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
295 AC_SUBST([AMDEPBACKSLASH])dnl
296 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
299 # Generate code to set up dependency tracking. -*- Autoconf -*-
301 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
302 # Free Software Foundation, Inc.
304 # This file is free software; the Free Software Foundation
305 # gives unlimited permission to copy and/or distribute it,
306 # with or without modifications, as long as this notice is preserved.
310 # _AM_OUTPUT_DEPENDENCY_COMMANDS
311 # ------------------------------
312 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
313 [for mf in $CONFIG_FILES; do
314 # Strip MF so we end up with the name of the file.
315 mf=`echo "$mf" | sed -e 's/:.*$//'`
316 # Check whether this is an Automake generated Makefile or not.
317 # We used to match only the files named `Makefile.in', but
318 # some people rename them; so instead we look at the file content.
319 # Grep'ing the first line is not enough: some people post-process
320 # each Makefile.in and add a new line on top of each file to say so.
321 # Grep'ing the whole file is not good either: AIX grep has a line
322 # limit of 2048, but all sed's we know have understand at least 4000.
323 if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then
324 dirpart=`AS_DIRNAME("$mf")`
328 # Extract the definition of DEPDIR, am__include, and am__quote
329 # from the Makefile without running `make'.
330 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
331 test -z "$DEPDIR" && continue
332 am__include=`sed -n 's/^am__include = //p' < "$mf"`
333 test -z "am__include" && continue
334 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
335 # When using ansi2knr, U may be empty or an underscore; expand it
336 U=`sed -n 's/^U = //p' < "$mf"`
337 # Find all dependency output files, they are included files with
338 # $(DEPDIR) in their names. We invoke sed twice because it is the
339 # simplest approach to changing $(DEPDIR) to its actual value in the
341 for file in `sed -n "
342 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
343 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
344 # Make sure the directory exists.
345 test -f "$dirpart/$file" && continue
346 fdir=`AS_DIRNAME(["$file"])`
347 AS_MKDIR_P([$dirpart/$fdir])
348 # echo "creating $dirpart/$file"
349 echo '# dummy' > "$dirpart/$file"
352 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
355 # AM_OUTPUT_DEPENDENCY_COMMANDS
356 # -----------------------------
357 # This macro should only be invoked once -- use via AC_REQUIRE.
359 # This code is only required when automatic dependency tracking
360 # is enabled. FIXME. This creates each `.P' file that we will
361 # need in order to bootstrap the dependency handling code.
362 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
363 [AC_CONFIG_COMMANDS([depfiles],
364 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
365 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
368 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
369 # Free Software Foundation, Inc.
371 # This file is free software; the Free Software Foundation
372 # gives unlimited permission to copy and/or distribute it,
373 # with or without modifications, as long as this notice is preserved.
377 # AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS.
378 AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
380 # Do all the work for Automake. -*- Autoconf -*-
382 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
383 # 2005, 2006 Free Software Foundation, Inc.
385 # This file is free software; the Free Software Foundation
386 # gives unlimited permission to copy and/or distribute it,
387 # with or without modifications, as long as this notice is preserved.
391 # This macro actually does too much. Some checks are only needed if
392 # your package does certain things. But this isn't really a big deal.
394 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
395 # AM_INIT_AUTOMAKE([OPTIONS])
396 # -----------------------------------------------
397 # The call with PACKAGE and VERSION arguments is the old style
398 # call (pre autoconf-2.50), which is being phased out. PACKAGE
399 # and VERSION should now be passed to AC_INIT and removed from
400 # the call to AM_INIT_AUTOMAKE.
401 # We support both call styles for the transition. After
402 # the next Automake release, Autoconf can make the AC_INIT
403 # arguments mandatory, and then we can depend on a new Autoconf
404 # release and drop the old call support.
405 AC_DEFUN([AM_INIT_AUTOMAKE],
406 [AC_PREREQ([2.60])dnl
407 dnl Autoconf wants to disallow AM_ names. We explicitly allow
408 dnl the ones we care about.
409 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
410 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
411 AC_REQUIRE([AC_PROG_INSTALL])dnl
412 if test "`cd $srcdir && pwd`" != "`pwd`"; then
413 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
414 # is not polluted with repeated "-I."
415 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
416 # test to see if srcdir already configured
417 if test -f $srcdir/config.status; then
418 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
422 # test whether we have cygpath
423 if test -z "$CYGPATH_W"; then
424 if (cygpath --version) >/dev/null 2>/dev/null; then
425 CYGPATH_W='cygpath -w'
430 AC_SUBST([CYGPATH_W])
432 # Define the identity of the package.
433 dnl Distinguish between old-style and new-style calls.
435 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
436 AC_SUBST([PACKAGE], [$1])dnl
437 AC_SUBST([VERSION], [$2])],
438 [_AM_SET_OPTIONS([$1])dnl
439 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
440 m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
441 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
442 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
443 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
445 _AM_IF_OPTION([no-define],,
446 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
447 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
449 # Some tools Automake needs.
450 AC_REQUIRE([AM_SANITY_CHECK])dnl
451 AC_REQUIRE([AC_ARG_PROGRAM])dnl
452 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
453 AM_MISSING_PROG(AUTOCONF, autoconf)
454 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
455 AM_MISSING_PROG(AUTOHEADER, autoheader)
456 AM_MISSING_PROG(MAKEINFO, makeinfo)
458 AM_PROG_INSTALL_STRIP
459 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
460 # We need awk for the "check" target. The system "awk" is bad on
462 AC_REQUIRE([AC_PROG_AWK])dnl
463 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
464 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
465 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
466 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
467 [_AM_PROG_TAR([v7])])])
468 _AM_IF_OPTION([no-dependencies],,
469 [AC_PROVIDE_IFELSE([AC_PROG_CC],
470 [_AM_DEPENDENCIES(CC)],
471 [define([AC_PROG_CC],
472 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
473 AC_PROVIDE_IFELSE([AC_PROG_CXX],
474 [_AM_DEPENDENCIES(CXX)],
475 [define([AC_PROG_CXX],
476 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
477 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
478 [_AM_DEPENDENCIES(OBJC)],
479 [define([AC_PROG_OBJC],
480 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
485 # When config.status generates a header, we must update the stamp-h file.
486 # This file resides in the same directory as the config header
487 # that is generated. The stamp files are numbered to have different names.
489 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
490 # loop where config.status creates the headers, so we can generate
491 # our stamp files there.
492 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
493 [# Compute $1's index in $config_headers.
495 for _am_header in $config_headers :; do
500 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
503 echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
505 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
507 # This file is free software; the Free Software Foundation
508 # gives unlimited permission to copy and/or distribute it,
509 # with or without modifications, as long as this notice is preserved.
513 # Define $install_sh.
514 AC_DEFUN([AM_PROG_INSTALL_SH],
515 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
516 install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
517 AC_SUBST(install_sh)])
519 # Copyright (C) 2003, 2005 Free Software Foundation, Inc.
521 # This file is free software; the Free Software Foundation
522 # gives unlimited permission to copy and/or distribute it,
523 # with or without modifications, as long as this notice is preserved.
527 # Check whether the underlying file-system supports filenames
528 # with a leading dot. For instance MS-DOS doesn't.
529 AC_DEFUN([AM_SET_LEADING_DOT],
530 [rm -rf .tst 2>/dev/null
531 mkdir .tst 2>/dev/null
532 if test -d .tst; then
537 rmdir .tst 2>/dev/null
538 AC_SUBST([am__leading_dot])])
540 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
543 # Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005
544 # Free Software Foundation, Inc.
546 # This file is free software; the Free Software Foundation
547 # gives unlimited permission to copy and/or distribute it,
548 # with or without modifications, as long as this notice is preserved.
552 AC_DEFUN([AM_MAINTAINER_MODE],
553 [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
554 dnl maintainer-mode is disabled by default
555 AC_ARG_ENABLE(maintainer-mode,
556 [ --enable-maintainer-mode enable make rules and dependencies not useful
557 (and sometimes confusing) to the casual installer],
558 USE_MAINTAINER_MODE=$enableval,
559 USE_MAINTAINER_MODE=no)
560 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
561 AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
562 MAINT=$MAINTAINER_MODE_TRUE
567 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
569 # Check to see how 'make' treats includes. -*- Autoconf -*-
571 # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
573 # This file is free software; the Free Software Foundation
574 # gives unlimited permission to copy and/or distribute it,
575 # with or without modifications, as long as this notice is preserved.
581 # Check to see how make treats includes.
582 AC_DEFUN([AM_MAKE_INCLUDE],
583 [am_make=${MAKE-make}
584 cat > confinc << 'END'
589 # If we don't find an include directive, just comment out the code.
590 AC_MSG_CHECKING([for style of include used by $am_make])
594 # First try GNU make style include.
595 echo "include confinc" > confmf
596 # We grep out `Entering directory' and `Leaving directory'
597 # messages which can occur if `w' ends up in MAKEFLAGS.
598 # In particular we don't look at `^make:' because GNU make might
599 # be invoked under some other name (usually "gmake"), in which
600 # case it prints its new name instead of `make'.
601 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
606 # Now try BSD make style include.
607 if test "$am__include" = "#"; then
608 echo '.include "confinc"' > confmf
609 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
615 AC_SUBST([am__include])
616 AC_SUBST([am__quote])
617 AC_MSG_RESULT([$_am_result])
621 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
623 # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
624 # Free Software Foundation, Inc.
626 # This file is free software; the Free Software Foundation
627 # gives unlimited permission to copy and/or distribute it,
628 # with or without modifications, as long as this notice is preserved.
632 # AM_MISSING_PROG(NAME, PROGRAM)
633 # ------------------------------
634 AC_DEFUN([AM_MISSING_PROG],
635 [AC_REQUIRE([AM_MISSING_HAS_RUN])
636 $1=${$1-"${am_missing_run}$2"}
642 # Define MISSING if not defined so far and test if it supports --run.
643 # If it does, set am_missing_run to use it, otherwise, to nothing.
644 AC_DEFUN([AM_MISSING_HAS_RUN],
645 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
646 AC_REQUIRE_AUX_FILE([missing])dnl
647 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
648 # Use eval to expand $SHELL
649 if eval "$MISSING --run true"; then
650 am_missing_run="$MISSING --run "
653 AC_MSG_WARN([`missing' script is too old or missing])
657 # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
659 # This file is free software; the Free Software Foundation
660 # gives unlimited permission to copy and/or distribute it,
661 # with or without modifications, as long as this notice is preserved.
665 # Check for `mkdir -p'.
666 AC_DEFUN([AM_PROG_MKDIR_P],
667 [AC_PREREQ([2.60])dnl
668 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
669 dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
670 dnl while keeping a definition of mkdir_p for backward compatibility.
671 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
672 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
673 dnl Makefile.ins that do not define MKDIR_P, so we do our own
674 dnl adjustment using top_builddir (which is defined more often than
676 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
678 [[\\/$]]* | ?:[[\\/]]*) ;;
679 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
683 # Helper functions for option handling. -*- Autoconf -*-
685 # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
687 # This file is free software; the Free Software Foundation
688 # gives unlimited permission to copy and/or distribute it,
689 # with or without modifications, as long as this notice is preserved.
693 # _AM_MANGLE_OPTION(NAME)
694 # -----------------------
695 AC_DEFUN([_AM_MANGLE_OPTION],
696 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
698 # _AM_SET_OPTION(NAME)
699 # ------------------------------
700 # Set option NAME. Presently that only means defining a flag for this option.
701 AC_DEFUN([_AM_SET_OPTION],
702 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
704 # _AM_SET_OPTIONS(OPTIONS)
705 # ----------------------------------
706 # OPTIONS is a space-separated list of Automake options.
707 AC_DEFUN([_AM_SET_OPTIONS],
708 [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
710 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
711 # -------------------------------------------
712 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
713 AC_DEFUN([_AM_IF_OPTION],
714 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
716 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
718 # This file is free software; the Free Software Foundation
719 # gives unlimited permission to copy and/or distribute it,
720 # with or without modifications, as long as this notice is preserved.
722 # AM_RUN_LOG(COMMAND)
723 # -------------------
724 # Run COMMAND, save the exit status in ac_status, and log it.
725 # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
726 AC_DEFUN([AM_RUN_LOG],
727 [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
728 ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
730 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
731 (exit $ac_status); }])
733 # Check to make sure that the build environment is sane. -*- Autoconf -*-
735 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
736 # Free Software Foundation, Inc.
738 # This file is free software; the Free Software Foundation
739 # gives unlimited permission to copy and/or distribute it,
740 # with or without modifications, as long as this notice is preserved.
746 AC_DEFUN([AM_SANITY_CHECK],
747 [AC_MSG_CHECKING([whether build environment is sane])
750 echo timestamp > conftest.file
751 # Do `set' in a subshell so we don't clobber the current shell's
752 # arguments. Must try -L first in case configure is actually a
753 # symlink; some systems play weird games with the mod time of symlinks
754 # (eg FreeBSD returns the mod time of the symlink's containing
757 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
758 if test "$[*]" = "X"; then
760 set X `ls -t $srcdir/configure conftest.file`
763 if test "$[*]" != "X $srcdir/configure conftest.file" \
764 && test "$[*]" != "X conftest.file $srcdir/configure"; then
766 # If neither matched, then we have a broken ls. This can happen
767 # if, for instance, CONFIG_SHELL is bash and it inherits a
768 # broken ls alias from the environment. This has actually
769 # happened. Such a system could not be considered "sane".
770 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
771 alias in your environment])
774 test "$[2]" = conftest.file
780 AC_MSG_ERROR([newly created file is older than distributed files!
781 Check your system clock])
785 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
787 # This file is free software; the Free Software Foundation
788 # gives unlimited permission to copy and/or distribute it,
789 # with or without modifications, as long as this notice is preserved.
791 # AM_PROG_INSTALL_STRIP
792 # ---------------------
793 # One issue with vendor `install' (even GNU) is that you can't
794 # specify the program used to strip binaries. This is especially
795 # annoying in cross-compiling environments, where the build's strip
796 # is unlikely to handle the host's binaries.
797 # Fortunately install-sh will honor a STRIPPROG variable, so we
798 # always use install-sh in `make install-strip', and initialize
799 # STRIPPROG with the value of the STRIP variable (set by the user).
800 AC_DEFUN([AM_PROG_INSTALL_STRIP],
801 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
802 # Installed binaries are usually stripped using `strip' when the user
803 # run `make install-strip'. However `strip' might not be the right
804 # tool to use in cross-compilation environments, therefore Automake
805 # will honor the `STRIP' environment variable to overrule this program.
806 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
807 if test "$cross_compiling" != no; then
808 AC_CHECK_TOOL([STRIP], [strip], :)
810 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
811 AC_SUBST([INSTALL_STRIP_PROGRAM])])
813 # Copyright (C) 2006 Free Software Foundation, Inc.
815 # This file is free software; the Free Software Foundation
816 # gives unlimited permission to copy and/or distribute it,
817 # with or without modifications, as long as this notice is preserved.
819 # _AM_SUBST_NOTMAKE(VARIABLE)
820 # ---------------------------
821 # Prevent Automake from outputing VARIABLE = @VARIABLE@ in Makefile.in.
822 # This macro is traced by Automake.
823 AC_DEFUN([_AM_SUBST_NOTMAKE])
825 # Check how to create a tarball. -*- Autoconf -*-
827 # Copyright (C) 2004, 2005 Free Software Foundation, Inc.
829 # This file is free software; the Free Software Foundation
830 # gives unlimited permission to copy and/or distribute it,
831 # with or without modifications, as long as this notice is preserved.
835 # _AM_PROG_TAR(FORMAT)
836 # --------------------
837 # Check how to create a tarball in format FORMAT.
838 # FORMAT should be one of `v7', `ustar', or `pax'.
840 # Substitute a variable $(am__tar) that is a command
841 # writing to stdout a FORMAT-tarball containing the directory
843 # tardir=directory && $(am__tar) > result.tar
845 # Substitute a variable $(am__untar) that extract such
846 # a tarball read from stdin.
847 # $(am__untar) < result.tar
848 AC_DEFUN([_AM_PROG_TAR],
849 [# Always define AMTAR for backward compatibility.
850 AM_MISSING_PROG([AMTAR], [tar])
852 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
853 [m4_case([$1], [ustar],, [pax],,
854 [m4_fatal([Unknown tar format])])
855 AC_MSG_CHECKING([how to create a $1 tar archive])
856 # Loop over all known methods to create a tar archive until one works.
857 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
858 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
859 # Do not fold the above two line into one, because Tru64 sh and
860 # Solaris sh will not grok spaces in the rhs of `-'.
861 for _am_tool in $_am_tools
865 for _am_tar in tar gnutar gtar;
867 AM_RUN_LOG([$_am_tar --version]) && break
869 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
870 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
871 am__untar="$_am_tar -xf -"
874 # Must skip GNU tar: if it does not support --format= it doesn't create
875 # ustar tarball either.
876 (tar --version) >/dev/null 2>&1 && continue
877 am__tar='tar chf - "$$tardir"'
878 am__tar_='tar chf - "$tardir"'
882 am__tar='pax -L -x $1 -w "$$tardir"'
883 am__tar_='pax -L -x $1 -w "$tardir"'
887 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
888 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
889 am__untar='cpio -i -H $1 -d'
898 # If the value was cached, stop now. We just wanted to have am__tar
900 test -n "${am_cv_prog_tar_$1}" && break
902 # tar/untar a dummy directory, and stop if the command works
905 echo GrepMe > conftest.dir/file
906 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
908 if test -s conftest.tar; then
909 AM_RUN_LOG([$am__untar <conftest.tar])
910 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
915 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
916 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
918 AC_SUBST([am__untar])
922 dnl Some macros needed for autoconf
926 AC_DEFUN([GLIBMM_CV_PERL_VERSION],[glibmm_cv_perl_version_[]m4_translit([$1],[.${}],[____])])
929 AC_DEFUN([GLIBMM_CHECK_PERL],
931 glibmm_perl_result=no
933 AC_PATH_PROGS([PERL_PATH], [perl perl5], [not found])
935 if test "x$PERL_PATH" != "xnot found"; then
938 [whether Perl is new enough],
939 GLIBMM_CV_PERL_VERSION([$1]),
941 ]GLIBMM_CV_PERL_VERSION([$1])[=no
942 "$PERL_PATH" -e "require v$1; exit 0;" >/dev/null 2>&1 && ]GLIBMM_CV_PERL_VERSION([$1])[=yes
944 test "x${GLIBMM_CV_PERL_VERSION([$1])}" = xyes && glibmm_perl_result=yes
948 # Make sure we have something sensible, even if it doesn't work.
953 if test "x$glibmm_perl_result" = xno && test "x$USE_MAINTAINER_MODE" = xyes; then
956 *** Perl >= ]$1[ is required for building $PACKAGE in maintainer-mode.
961 AC_SUBST([PERL_PATH])
965 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
967 # serial 48 AC_PROG_LIBTOOL
970 # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
971 # -----------------------------------------------------------
972 # If this macro is not defined by Autoconf, define it here.
973 m4_ifdef([AC_PROVIDE_IFELSE],
975 [m4_define([AC_PROVIDE_IFELSE],
976 [m4_ifdef([AC_PROVIDE_$1],
982 AC_DEFUN([AC_PROG_LIBTOOL],
983 [AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
984 dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
985 dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
986 AC_PROVIDE_IFELSE([AC_PROG_CXX],
988 [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
990 dnl And a similar setup for Fortran 77 support
991 AC_PROVIDE_IFELSE([AC_PROG_F77],
993 [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
996 dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
997 dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
998 dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
999 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1001 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1003 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
1005 [ifdef([AC_PROG_GCJ],
1006 [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
1007 ifdef([A][M_PROG_GCJ],
1008 [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
1009 ifdef([LT_AC_PROG_GCJ],
1010 [define([LT_AC_PROG_GCJ],
1011 defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
1012 ])])# AC_PROG_LIBTOOL
1017 AC_DEFUN([_AC_PROG_LIBTOOL],
1018 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
1019 AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
1020 AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
1021 AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
1023 # This can be used to rebuild libtool when needed
1024 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
1026 # Always use our own libtool.
1027 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1028 AC_SUBST(LIBTOOL)dnl
1030 # Prevent multiple expansion
1031 define([AC_PROG_LIBTOOL], [])
1032 ])# _AC_PROG_LIBTOOL
1037 AC_DEFUN([AC_LIBTOOL_SETUP],
1039 AC_REQUIRE([AC_ENABLE_SHARED])dnl
1040 AC_REQUIRE([AC_ENABLE_STATIC])dnl
1041 AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
1042 AC_REQUIRE([AC_CANONICAL_HOST])dnl
1043 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1044 AC_REQUIRE([AC_PROG_CC])dnl
1045 AC_REQUIRE([AC_PROG_LD])dnl
1046 AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
1047 AC_REQUIRE([AC_PROG_NM])dnl
1049 AC_REQUIRE([AC_PROG_LN_S])dnl
1050 AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
1051 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
1052 AC_REQUIRE([AC_OBJEXT])dnl
1053 AC_REQUIRE([AC_EXEEXT])dnl
1056 AC_LIBTOOL_SYS_MAX_CMD_LEN
1057 AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
1060 AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1061 _LT_AC_PROG_ECHO_BACKSLASH
1065 # AIX sometimes has problems with the GCC collect2 program. For some
1066 # reason, if we set the COLLECT_NAMES environment variable, the problems
1067 # vanish in a puff of smoke.
1068 if test "X${COLLECT_NAMES+set}" != Xset; then
1070 export COLLECT_NAMES
1075 # Sed substitution that helps us do robust quoting. It backslashifies
1076 # metacharacters that are still active within double-quoted strings.
1077 Xsed='sed -e 1s/^X//'
1078 [sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
1080 # Same as above, but do not quote variable references.
1081 [double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
1083 # Sed substitution to delay expansion of an escaped shell variable in a
1084 # double_quote_subst'ed string.
1085 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1087 # Sed substitution to avoid accidental globbing in evaled expressions
1088 no_glob_subst='s/\*/\\\*/g'
1094 default_ofile=libtool
1095 can_build_shared=yes
1097 # All known linkers require a `.a' archive for static linking (except MSVC,
1098 # which needs '.lib').
1100 ltmain="$ac_aux_dir/ltmain.sh"
1101 ofile="$default_ofile"
1102 with_gnu_ld="$lt_cv_prog_gnu_ld"
1104 AC_CHECK_TOOL(AR, ar, false)
1105 AC_CHECK_TOOL(RANLIB, ranlib, :)
1106 AC_CHECK_TOOL(STRIP, strip, :)
1109 old_CFLAGS="$CFLAGS"
1111 # Set sane defaults for various variables
1112 test -z "$AR" && AR=ar
1113 test -z "$AR_FLAGS" && AR_FLAGS=cru
1114 test -z "$AS" && AS=as
1115 test -z "$CC" && CC=cc
1116 test -z "$LTCC" && LTCC=$CC
1117 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1118 test -z "$DLLTOOL" && DLLTOOL=dlltool
1119 test -z "$LD" && LD=ld
1120 test -z "$LN_S" && LN_S="ln -s"
1121 test -z "$MAGIC_CMD" && MAGIC_CMD=file
1122 test -z "$NM" && NM=nm
1123 test -z "$SED" && SED=sed
1124 test -z "$OBJDUMP" && OBJDUMP=objdump
1125 test -z "$RANLIB" && RANLIB=:
1126 test -z "$STRIP" && STRIP=:
1127 test -z "$ac_objext" && ac_objext=o
1129 # Determine commands to create old-style static archives.
1130 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
1131 old_postinstall_cmds='chmod 644 $oldlib'
1132 old_postuninstall_cmds=
1134 if test -n "$RANLIB"; then
1137 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
1140 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
1143 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
1146 _LT_CC_BASENAME([$compiler])
1148 # Only perform the check for file, if the check method requires it
1149 case $deplibs_check_method in
1151 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1157 AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
1158 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1159 enable_win32_dll=yes, enable_win32_dll=no)
1161 AC_ARG_ENABLE([libtool-lock],
1162 [AC_HELP_STRING([--disable-libtool-lock],
1163 [avoid locking (might break parallel builds)])])
1164 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1167 [AC_HELP_STRING([--with-pic],
1168 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
1169 [pic_mode="$withval"],
1171 test -z "$pic_mode" && pic_mode=default
1173 # Use C for the default configuration in the libtool script
1175 AC_LIBTOOL_LANG_C_CONFIG
1177 ])# AC_LIBTOOL_SETUP
1180 # _LT_AC_SYS_COMPILER
1181 # -------------------
1182 AC_DEFUN([_LT_AC_SYS_COMPILER],
1183 [AC_REQUIRE([AC_PROG_CC])dnl
1185 # If no C compiler was specified, use CC.
1188 # If no C compiler flags were specified, use CFLAGS.
1189 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1191 # Allow CC to be a program name with arguments.
1193 ])# _LT_AC_SYS_COMPILER
1196 # _LT_CC_BASENAME(CC)
1197 # -------------------
1198 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
1199 AC_DEFUN([_LT_CC_BASENAME],
1200 [for cc_temp in $1""; do
1202 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1203 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1208 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
1212 # _LT_COMPILER_BOILERPLATE
1213 # ------------------------
1214 # Check for compiler boilerplate output or warnings with
1215 # the simple compiler test code.
1216 AC_DEFUN([_LT_COMPILER_BOILERPLATE],
1217 [ac_outfile=conftest.$ac_objext
1218 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
1219 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1220 _lt_compiler_boilerplate=`cat conftest.err`
1222 ])# _LT_COMPILER_BOILERPLATE
1225 # _LT_LINKER_BOILERPLATE
1226 # ----------------------
1227 # Check for linker boilerplate output or warnings with
1228 # the simple link test code.
1229 AC_DEFUN([_LT_LINKER_BOILERPLATE],
1230 [ac_outfile=conftest.$ac_objext
1231 printf "$lt_simple_link_test_code" >conftest.$ac_ext
1232 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1233 _lt_linker_boilerplate=`cat conftest.err`
1235 ])# _LT_LINKER_BOILERPLATE
1238 # _LT_AC_SYS_LIBPATH_AIX
1239 # ----------------------
1240 # Links a minimal program and checks the executable
1241 # for the system default hardcoded library path. In most cases,
1242 # this is /usr/lib:/lib, but when the MPI compilers are used
1243 # the location of the communication and MPI libs are included too.
1244 # If we don't find anything, use the default library path according
1245 # to the aix ld manual.
1246 AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
1247 [AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1248 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
1250 # Check for a 64-bit object if we didn't find anything.
1251 if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
1253 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1254 ])# _LT_AC_SYS_LIBPATH_AIX
1257 # _LT_AC_SHELL_INIT(ARG)
1258 # ----------------------
1259 AC_DEFUN([_LT_AC_SHELL_INIT],
1260 [ifdef([AC_DIVERSION_NOTICE],
1261 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1262 [AC_DIVERT_PUSH(NOTICE)])
1265 ])# _LT_AC_SHELL_INIT
1268 # _LT_AC_PROG_ECHO_BACKSLASH
1269 # --------------------------
1270 # Add some code to the start of the generated configure script which
1271 # will find an echo command which doesn't interpret backslashes.
1272 AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
1273 [_LT_AC_SHELL_INIT([
1274 # Check that we are running under the correct shell.
1275 SHELL=${CONFIG_SHELL-/bin/sh}
1279 # Remove one level of quotation (which was required for Make).
1280 ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1285 if test "X[$]1" = X--no-reexec; then
1286 # Discard the --no-reexec flag, and continue.
1288 elif test "X[$]1" = X--fallback-echo; then
1289 # Avoid inline document here, it may be left over
1291 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
1292 # Yippee, $echo works!
1295 # Restart under the correct shell.
1296 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1299 if test "X[$]1" = X--fallback-echo; then
1300 # used as fallback echo
1308 # The HP-UX ksh and POSIX shell print the target directory to stdout
1310 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1312 if test -z "$ECHO"; then
1313 if test "X${echo_test_string+set}" != Xset; then
1314 # find a string as large as possible, as long as the shell can cope with it
1315 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1316 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1317 if (echo_test_string=`eval $cmd`) 2>/dev/null &&
1318 echo_test_string=`eval $cmd` &&
1319 (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
1326 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1327 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1328 test "X$echo_testing_string" = "X$echo_test_string"; then
1331 # The Solaris, AIX, and Digital Unix default echo programs unquote
1332 # backslashes. This makes it impossible to quote backslashes using
1333 # echo "$something" | sed 's/\\/\\\\/g'
1335 # So, first we look for a working echo in the user's PATH.
1337 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1338 for dir in $PATH /usr/ucb; do
1340 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1341 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1342 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1343 test "X$echo_testing_string" = "X$echo_test_string"; then
1350 if test "X$echo" = Xecho; then
1351 # We didn't find a better echo, so look for alternatives.
1352 if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
1353 echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
1354 test "X$echo_testing_string" = "X$echo_test_string"; then
1355 # This shell has a builtin print -r that does the trick.
1357 elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
1358 test "X$CONFIG_SHELL" != X/bin/ksh; then
1359 # If we have ksh, try running configure again with it.
1360 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1361 export ORIGINAL_CONFIG_SHELL
1362 CONFIG_SHELL=/bin/ksh
1364 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1368 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1369 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1370 test "X$echo_testing_string" = "X$echo_test_string"; then
1371 # Cool, printf works
1373 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1374 test "X$echo_testing_string" = 'X\t' &&
1375 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1376 test "X$echo_testing_string" = "X$echo_test_string"; then
1377 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1379 SHELL="$CONFIG_SHELL"
1381 echo="$CONFIG_SHELL [$]0 --fallback-echo"
1382 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1383 test "X$echo_testing_string" = 'X\t' &&
1384 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1385 test "X$echo_testing_string" = "X$echo_test_string"; then
1386 echo="$CONFIG_SHELL [$]0 --fallback-echo"
1388 # maybe with a smaller string...
1391 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1392 if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
1399 if test "$prev" != 'sed 50q "[$]0"'; then
1400 echo_test_string=`eval $prev`
1401 export echo_test_string
1402 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1404 # Oops. We lost completely, so just stick with echo.
1413 # Copy echo and quote the copy suitably for passing to libtool from
1414 # the Makefile, instead of quoting the original, which is used later.
1416 if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1417 ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1421 ])])# _LT_AC_PROG_ECHO_BACKSLASH
1426 AC_DEFUN([_LT_AC_LOCK],
1427 [AC_ARG_ENABLE([libtool-lock],
1428 [AC_HELP_STRING([--disable-libtool-lock],
1429 [avoid locking (might break parallel builds)])])
1430 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1432 # Some flags need to be propagated to the compiler or linker for good
1436 # Find out which ABI we are using.
1437 echo 'int i;' > conftest.$ac_ext
1438 if AC_TRY_EVAL(ac_compile); then
1439 case `/usr/bin/file conftest.$ac_objext` in
1451 # Find out which ABI we are using.
1452 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1453 if AC_TRY_EVAL(ac_compile); then
1454 if test "$lt_cv_prog_gnu_ld" = yes; then
1455 case `/usr/bin/file conftest.$ac_objext` in
1457 LD="${LD-ld} -melf32bsmip"
1460 LD="${LD-ld} -melf32bmipn32"
1463 LD="${LD-ld} -melf64bmip"
1467 case `/usr/bin/file conftest.$ac_objext` in
1483 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
1484 # Find out which ABI we are using.
1485 echo 'int i;' > conftest.$ac_ext
1486 if AC_TRY_EVAL(ac_compile); then
1487 case `/usr/bin/file conftest.o` in
1491 LD="${LD-ld} -m elf_i386"
1493 ppc64-*linux*|powerpc64-*linux*)
1494 LD="${LD-ld} -m elf32ppclinux"
1497 LD="${LD-ld} -m elf_s390"
1500 LD="${LD-ld} -m elf32_sparc"
1507 LD="${LD-ld} -m elf_x86_64"
1509 ppc*-*linux*|powerpc*-*linux*)
1510 LD="${LD-ld} -m elf64ppc"
1513 LD="${LD-ld} -m elf64_s390"
1516 LD="${LD-ld} -m elf64_sparc"
1526 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1527 SAVE_CFLAGS="$CFLAGS"
1528 CFLAGS="$CFLAGS -belf"
1529 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1531 AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1533 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1534 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1535 CFLAGS="$SAVE_CFLAGS"
1539 # Find out which ABI we are using.
1540 echo 'int i;' > conftest.$ac_ext
1541 if AC_TRY_EVAL(ac_compile); then
1542 case `/usr/bin/file conftest.o` in
1544 case $lt_cv_prog_gnu_ld in
1545 yes*) LD="${LD-ld} -m elf64_sparc" ;;
1546 *) LD="${LD-ld} -64" ;;
1554 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1555 [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
1556 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
1557 AC_CHECK_TOOL(AS, as, false)
1558 AC_CHECK_TOOL(OBJDUMP, objdump, false)
1563 need_locks="$enable_libtool_lock"
1568 # AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1569 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1570 # ----------------------------------------------------------------
1571 # Check whether the given compiler option works
1572 AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
1573 [AC_REQUIRE([LT_AC_PROG_SED])
1574 AC_CACHE_CHECK([$1], [$2],
1576 ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1577 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1578 lt_compiler_flag="$3"
1579 # Insert the option either (1) after the last *FLAGS variable, or
1580 # (2) before a word containing "conftest.", or (3) at the end.
1581 # Note that $ac_compile itself does not contain backslashes and begins
1582 # with a dollar sign (not a hyphen), so the echo should work correctly.
1583 # The option is referenced via a variable to avoid confusing sed.
1584 lt_compile=`echo "$ac_compile" | $SED \
1585 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1586 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1587 -e 's:$: $lt_compiler_flag:'`
1588 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1589 (eval "$lt_compile" 2>conftest.err)
1591 cat conftest.err >&AS_MESSAGE_LOG_FD
1592 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1593 if (exit $ac_status) && test -s "$ac_outfile"; then
1594 # The compiler can only warn and ignore the option if not recognized
1595 # So say no if there are warnings other than the usual output.
1596 $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
1597 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1598 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1605 if test x"[$]$2" = xyes; then
1606 ifelse([$5], , :, [$5])
1608 ifelse([$6], , :, [$6])
1610 ])# AC_LIBTOOL_COMPILER_OPTION
1613 # AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1614 # [ACTION-SUCCESS], [ACTION-FAILURE])
1615 # ------------------------------------------------------------
1616 # Check whether the given compiler option works
1617 AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
1618 [AC_CACHE_CHECK([$1], [$2],
1620 save_LDFLAGS="$LDFLAGS"
1621 LDFLAGS="$LDFLAGS $3"
1622 printf "$lt_simple_link_test_code" > conftest.$ac_ext
1623 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1624 # The linker can only warn and ignore the option if not recognized
1625 # So say no if there are warnings
1626 if test -s conftest.err; then
1627 # Append any errors to the config.log.
1628 cat conftest.err 1>&AS_MESSAGE_LOG_FD
1629 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
1630 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1631 if diff conftest.exp conftest.er2 >/dev/null; then
1639 LDFLAGS="$save_LDFLAGS"
1642 if test x"[$]$2" = xyes; then
1643 ifelse([$4], , :, [$4])
1645 ifelse([$5], , :, [$5])
1647 ])# AC_LIBTOOL_LINKER_OPTION
1650 # AC_LIBTOOL_SYS_MAX_CMD_LEN
1651 # --------------------------
1652 AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
1653 [# find the maximum length of command line arguments
1654 AC_MSG_CHECKING([the maximum length of command line arguments])
1655 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1661 # On DJGPP, this test can blow up pretty badly due to problems in libc
1662 # (any single argument exceeding 2000 bytes causes a buffer overrun
1663 # during glob expansion). Even if it were fixed, the result of this
1664 # check would be larger than it should be.
1665 lt_cv_sys_max_cmd_len=12288; # 12K is about right
1669 # Under GNU Hurd, this test is not required because there is
1670 # no limit to the length of command line arguments.
1671 # Libtool will interpret -1 as no limit whatsoever
1672 lt_cv_sys_max_cmd_len=-1;
1676 # On Win9x/ME, this test blows up -- it succeeds, but takes
1677 # about 5 minutes as the teststring grows exponentially.
1678 # Worse, since 9x/ME are not pre-emptively multitasking,
1679 # you end up with a "frozen" computer, even though with patience
1680 # the test eventually succeeds (with a max line length of 256k).
1681 # Instead, let's just punt: use the minimum linelength reported by
1682 # all of the supported platforms: 8192 (on NT/2K/XP).
1683 lt_cv_sys_max_cmd_len=8192;
1687 # On AmigaOS with pdksh, this test takes hours, literally.
1688 # So we just punt and use a minimum line length of 8192.
1689 lt_cv_sys_max_cmd_len=8192;
1692 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1693 # This has been around since 386BSD, at least. Likely further.
1694 if test -x /sbin/sysctl; then
1695 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1696 elif test -x /usr/sbin/sysctl; then
1697 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1699 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1701 # And add a safety zone
1702 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1703 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1707 # We know the value 262144 and hardcode it with a safety zone (like BSD)
1708 lt_cv_sys_max_cmd_len=196608
1712 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1713 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1714 # nice to cause kernel panics so lets avoid the loop below.
1715 # First set a reasonable default.
1716 lt_cv_sys_max_cmd_len=16384
1718 if test -x /sbin/sysconfig; then
1719 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1720 *1*) lt_cv_sys_max_cmd_len=-1 ;;
1725 lt_cv_sys_max_cmd_len=102400
1727 sysv5* | sco5v6* | sysv4.2uw2*)
1728 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1729 if test -n "$kargmax"; then
1730 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1732 lt_cv_sys_max_cmd_len=32768
1736 # If test is not a shell built-in, we'll probably end up computing a
1737 # maximum length that is only half of the actual maximum length, but
1739 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1740 while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
1741 = "XX$teststring") >/dev/null 2>&1 &&
1742 new_result=`expr "X$teststring" : ".*" 2>&1` &&
1743 lt_cv_sys_max_cmd_len=$new_result &&
1744 test $i != 17 # 1/2 MB should be enough
1747 teststring=$teststring$teststring
1750 # Add a significant safety factor because C++ compilers can tack on massive
1751 # amounts of additional arguments before passing them to the linker.
1752 # It appears as though 1/2 is a usable value.
1753 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1757 if test -n $lt_cv_sys_max_cmd_len ; then
1758 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1762 ])# AC_LIBTOOL_SYS_MAX_CMD_LEN
1765 # _LT_AC_CHECK_DLFCN
1766 # ------------------
1767 AC_DEFUN([_LT_AC_CHECK_DLFCN],
1768 [AC_CHECK_HEADERS(dlfcn.h)dnl
1769 ])# _LT_AC_CHECK_DLFCN
1772 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1773 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1774 # ---------------------------------------------------------------------
1775 AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
1776 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1777 if test "$cross_compiling" = yes; then :
1780 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1781 lt_status=$lt_dlunknown
1782 cat > conftest.$ac_ext <<EOF
1783 [#line __oline__ "configure"
1784 #include "confdefs.h"
1793 # define LT_DLGLOBAL RTLD_GLOBAL
1796 # define LT_DLGLOBAL DL_GLOBAL
1798 # define LT_DLGLOBAL 0
1802 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1803 find out it does not work in some platform. */
1804 #ifndef LT_DLLAZY_OR_NOW
1806 # define LT_DLLAZY_OR_NOW RTLD_LAZY
1809 # define LT_DLLAZY_OR_NOW DL_LAZY
1812 # define LT_DLLAZY_OR_NOW RTLD_NOW
1815 # define LT_DLLAZY_OR_NOW DL_NOW
1817 # define LT_DLLAZY_OR_NOW 0
1825 extern "C" void exit (int);
1828 void fnord() { int i=42;}
1831 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1832 int status = $lt_dlunknown;
1836 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1837 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1838 /* dlclose (self); */
1846 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1847 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1850 x$lt_dlno_uscore) $1 ;;
1851 x$lt_dlneed_uscore) $2 ;;
1852 x$lt_dlunknown|x*) $3 ;;
1855 # compilation failed
1860 ])# _LT_AC_TRY_DLOPEN_SELF
1863 # AC_LIBTOOL_DLOPEN_SELF
1864 # ----------------------
1865 AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
1866 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1867 if test "x$enable_dlopen" != xyes; then
1868 enable_dlopen=unknown
1869 enable_dlopen_self=unknown
1870 enable_dlopen_self_static=unknown
1877 lt_cv_dlopen="load_add_on"
1879 lt_cv_dlopen_self=yes
1883 lt_cv_dlopen="LoadLibrary"
1888 lt_cv_dlopen="dlopen"
1893 # if libdl is installed we need to link against it
1894 AC_CHECK_LIB([dl], [dlopen],
1895 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1898 lt_cv_dlopen_self=yes
1903 AC_CHECK_FUNC([shl_load],
1904 [lt_cv_dlopen="shl_load"],
1905 [AC_CHECK_LIB([dld], [shl_load],
1906 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
1907 [AC_CHECK_FUNC([dlopen],
1908 [lt_cv_dlopen="dlopen"],
1909 [AC_CHECK_LIB([dl], [dlopen],
1910 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1911 [AC_CHECK_LIB([svld], [dlopen],
1912 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1913 [AC_CHECK_LIB([dld], [dld_link],
1914 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
1923 if test "x$lt_cv_dlopen" != xno; then
1929 case $lt_cv_dlopen in
1931 save_CPPFLAGS="$CPPFLAGS"
1932 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1934 save_LDFLAGS="$LDFLAGS"
1935 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1938 LIBS="$lt_cv_dlopen_libs $LIBS"
1940 AC_CACHE_CHECK([whether a program can dlopen itself],
1941 lt_cv_dlopen_self, [dnl
1942 _LT_AC_TRY_DLOPEN_SELF(
1943 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1944 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1947 if test "x$lt_cv_dlopen_self" = xyes; then
1948 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1949 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1950 lt_cv_dlopen_self_static, [dnl
1951 _LT_AC_TRY_DLOPEN_SELF(
1952 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1953 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1957 CPPFLAGS="$save_CPPFLAGS"
1958 LDFLAGS="$save_LDFLAGS"
1963 case $lt_cv_dlopen_self in
1964 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1965 *) enable_dlopen_self=unknown ;;
1968 case $lt_cv_dlopen_self_static in
1969 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1970 *) enable_dlopen_self_static=unknown ;;
1973 ])# AC_LIBTOOL_DLOPEN_SELF
1976 # AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1977 # ---------------------------------
1978 # Check to see if options -c and -o are simultaneously supported by compiler
1979 AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1980 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1981 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1982 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1983 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1984 $rm -r conftest 2>/dev/null
1988 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1990 lt_compiler_flag="-o out/conftest2.$ac_objext"
1991 # Insert the option either (1) after the last *FLAGS variable, or
1992 # (2) before a word containing "conftest.", or (3) at the end.
1993 # Note that $ac_compile itself does not contain backslashes and begins
1994 # with a dollar sign (not a hyphen), so the echo should work correctly.
1995 lt_compile=`echo "$ac_compile" | $SED \
1996 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1997 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1998 -e 's:$: $lt_compiler_flag:'`
1999 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2000 (eval "$lt_compile" 2>out/conftest.err)
2002 cat out/conftest.err >&AS_MESSAGE_LOG_FD
2003 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2004 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2006 # The compiler can only warn and ignore the option if not recognized
2007 # So say no if there are warnings
2008 $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
2009 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2010 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2011 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2014 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2016 # SGI C++ compiler will create directory out/ii_files/ for
2017 # template instantiation
2018 test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
2019 $rm out/* && rmdir out
2024 ])# AC_LIBTOOL_PROG_CC_C_O
2027 # AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
2028 # -----------------------------------------
2029 # Check to see if we can do hard links to lock some files if needed
2030 AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
2031 [AC_REQUIRE([_LT_AC_LOCK])dnl
2033 hard_links="nottested"
2034 if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2035 # do not overwrite the value of need_locks provided by the user
2036 AC_MSG_CHECKING([if we can lock with hard links])
2039 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2041 ln conftest.a conftest.b 2>&5 || hard_links=no
2042 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2043 AC_MSG_RESULT([$hard_links])
2044 if test "$hard_links" = no; then
2045 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2051 ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
2056 AC_DEFUN([AC_LIBTOOL_OBJDIR],
2057 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2058 [rm -f .libs 2>/dev/null
2059 mkdir .libs 2>/dev/null
2060 if test -d .libs; then
2063 # MS-DOS does not allow filenames that begin with a dot.
2066 rmdir .libs 2>/dev/null])
2067 objdir=$lt_cv_objdir
2068 ])# AC_LIBTOOL_OBJDIR
2071 # AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
2072 # ----------------------------------------------
2073 # Check hardcoding attributes.
2074 AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
2075 [AC_MSG_CHECKING([how to hardcode library paths into programs])
2076 _LT_AC_TAGVAR(hardcode_action, $1)=
2077 if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
2078 test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
2079 test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2081 # We can hardcode non-existant directories.
2082 if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
2083 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2084 # have to relink, otherwise we might link with an installed library
2085 # when we should be linking with a yet-to-be-installed one
2086 ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2087 test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
2088 # Linking always hardcodes the temporary library directory.
2089 _LT_AC_TAGVAR(hardcode_action, $1)=relink
2091 # We can link without hardcoding, and we can hardcode nonexisting dirs.
2092 _LT_AC_TAGVAR(hardcode_action, $1)=immediate
2095 # We cannot hardcode anything, or else we can only hardcode existing
2097 _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
2099 AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
2101 if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
2102 # Fast installation is not supported
2103 enable_fast_install=no
2104 elif test "$shlibpath_overrides_runpath" = yes ||
2105 test "$enable_shared" = no; then
2106 # Fast installation is not necessary
2107 enable_fast_install=needless
2109 ])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
2112 # AC_LIBTOOL_SYS_LIB_STRIP
2113 # ------------------------
2114 AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
2117 AC_MSG_CHECKING([whether stripping libraries is possible])
2118 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
2119 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2120 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2121 AC_MSG_RESULT([yes])
2123 # FIXME - insert some real tests, host_os isn't really good enough
2126 if test -n "$STRIP" ; then
2127 striplib="$STRIP -x"
2128 AC_MSG_RESULT([yes])
2138 ])# AC_LIBTOOL_SYS_LIB_STRIP
2141 # AC_LIBTOOL_SYS_DYNAMIC_LINKER
2142 # -----------------------------
2143 # PORTME Fill in your ld.so characteristics
2144 AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
2145 [AC_MSG_CHECKING([dynamic linker characteristics])
2147 libname_spec='lib$name'
2155 shlibpath_overrides_runpath=unknown
2157 dynamic_linker="$host_os ld.so"
2158 sys_lib_dlsearch_path_spec="/lib /usr/lib"
2159 if test "$GCC" = yes; then
2160 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2161 if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
2162 # if the path contains ";" then we assume it to be the separator
2163 # otherwise default to the standard path separator (i.e. ":") - it is
2164 # assumed that no part of a normal pathname contains ";" but that should
2165 # okay in the real world where ";" in dirpaths is itself problematic.
2166 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2168 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2171 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2173 need_lib_prefix=unknown
2174 hardcode_into_libs=no
2176 # when you set need_version to no, make sure it does not cause -set_version
2177 # flags to be left without arguments
2178 need_version=unknown
2183 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2184 shlibpath_var=LIBPATH
2186 # AIX 3 has no versioning support, so we append a major version to the name.
2187 soname_spec='${libname}${release}${shared_ext}$major'
2194 hardcode_into_libs=yes
2195 if test "$host_cpu" = ia64; then
2196 # AIX 5 supports IA64
2197 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2198 shlibpath_var=LD_LIBRARY_PATH
2200 # With GCC up to 2.95.x, collect2 would create an import file
2201 # for dependence libraries. The import file would start with
2202 # the line `#! .'. This would cause the generated library to
2203 # depend on `.', always an invalid library. This was fixed in
2204 # development snapshots of GCC prior to 3.0.
2206 aix4 | aix4.[[01]] | aix4.[[01]].*)
2207 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2209 echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
2216 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2217 # soname into executable. Probably we can add versioning support to
2218 # collect2, so additional links can be useful in future.
2219 if test "$aix_use_runtimelinking" = yes; then
2220 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2221 # instead of lib<name>.a to let people know that these are not
2222 # typical AIX shared libraries.
2223 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2225 # We preserve .a as extension for shared libraries through AIX4.2
2226 # and later when we are not doing run time linking.
2227 library_names_spec='${libname}${release}.a $libname.a'
2228 soname_spec='${libname}${release}${shared_ext}$major'
2230 shlibpath_var=LIBPATH
2235 library_names_spec='$libname.ixlibrary $libname.a'
2236 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2237 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2241 library_names_spec='${libname}${shared_ext}'
2242 dynamic_linker="$host_os ld.so"
2243 shlibpath_var=LIBRARY_PATH
2249 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2250 soname_spec='${libname}${release}${shared_ext}$major'
2251 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2252 shlibpath_var=LD_LIBRARY_PATH
2253 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2254 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2255 # the default ld.so.conf also contains /usr/contrib/lib and
2256 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2257 # libtool to hard-code these into programs
2260 cygwin* | mingw* | pw32*)
2261 version_type=windows
2266 case $GCC,$host_os in
2267 yes,cygwin* | yes,mingw* | yes,pw32*)
2268 library_names_spec='$libname.dll.a'
2269 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2270 postinstall_cmds='base_file=`basename \${file}`~
2271 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
2272 dldir=$destdir/`dirname \$dlpath`~
2273 test -d \$dldir || mkdir -p \$dldir~
2274 $install_prog $dir/$dlname \$dldir/$dlname~
2275 chmod a+x \$dldir/$dlname'
2276 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2277 dlpath=$dir/\$dldll~
2279 shlibpath_overrides_runpath=yes
2283 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2284 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2285 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2288 # MinGW DLLs use traditional 'lib' prefix
2289 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2290 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2291 if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
2292 # It is most probably a Windows format PATH printed by
2293 # mingw gcc, but we are running on Cygwin. Gcc prints its search
2294 # path with ; separators, and with drive letters. We can handle the
2295 # drive letters (cygwin fileutils understands them), so leave them,
2296 # especially as we might pass files found there to a mingw objdump,
2297 # which wouldn't understand a cygwinified path. Ahh.
2298 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2300 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2304 # pw32 DLLs use 'pw' prefix rather than 'lib'
2305 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2311 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2314 dynamic_linker='Win32 ld.exe'
2315 # FIXME: first we should search . and the directory the executable is in
2319 darwin* | rhapsody*)
2320 dynamic_linker="$host_os dyld"
2324 library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2325 soname_spec='${libname}${release}${major}$shared_ext'
2326 shlibpath_overrides_runpath=yes
2327 shlibpath_var=DYLD_LIBRARY_PATH
2328 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2329 # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
2330 if test "$GCC" = yes; then
2331 sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
2333 sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
2335 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2342 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2343 soname_spec='${libname}${release}${shared_ext}$major'
2344 shlibpath_var=LD_LIBRARY_PATH
2355 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2356 soname_spec='${libname}${release}${shared_ext}$major'
2357 shlibpath_var=LD_LIBRARY_PATH
2358 shlibpath_overrides_runpath=no
2359 hardcode_into_libs=yes
2360 dynamic_linker='GNU ld.so'
2363 freebsd* | dragonfly*)
2364 # DragonFly does not have aout. When/if they implement a new
2365 # versioning mechanism, adjust this.
2366 if test -x /usr/bin/objformat; then
2367 objformat=`/usr/bin/objformat`
2370 freebsd[[123]]*) objformat=aout ;;
2374 version_type=freebsd-$objformat
2375 case $version_type in
2377 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2382 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2386 shlibpath_var=LD_LIBRARY_PATH
2389 shlibpath_overrides_runpath=yes
2391 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2392 shlibpath_overrides_runpath=yes
2393 hardcode_into_libs=yes
2395 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2396 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2397 shlibpath_overrides_runpath=no
2398 hardcode_into_libs=yes
2400 freebsd*) # from 4.6 on
2401 shlibpath_overrides_runpath=yes
2402 hardcode_into_libs=yes
2411 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2412 soname_spec='${libname}${release}${shared_ext}$major'
2413 shlibpath_var=LD_LIBRARY_PATH
2414 hardcode_into_libs=yes
2417 hpux9* | hpux10* | hpux11*)
2418 # Give a soname corresponding to the major version so that dld.sl refuses to
2419 # link against other versions.
2426 hardcode_into_libs=yes
2427 dynamic_linker="$host_os dld.so"
2428 shlibpath_var=LD_LIBRARY_PATH
2429 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2430 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2431 soname_spec='${libname}${release}${shared_ext}$major'
2432 if test "X$HPUX_IA64_MODE" = X32; then
2433 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2435 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2437 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2441 hardcode_into_libs=yes
2442 dynamic_linker="$host_os dld.sl"
2443 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2444 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2445 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2446 soname_spec='${libname}${release}${shared_ext}$major'
2447 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2448 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2452 dynamic_linker="$host_os dld.sl"
2453 shlibpath_var=SHLIB_PATH
2454 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2455 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2456 soname_spec='${libname}${release}${shared_ext}$major'
2459 # HP-UX runs *really* slowly unless shared libraries are mode 555.
2460 postinstall_cmds='chmod 555 $lib'
2467 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2468 soname_spec='${libname}${release}${shared_ext}$major'
2469 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2470 shlibpath_var=LD_LIBRARY_PATH
2471 shlibpath_overrides_runpath=no
2472 hardcode_into_libs=yes
2475 irix5* | irix6* | nonstopux*)
2477 nonstopux*) version_type=nonstopux ;;
2479 if test "$lt_cv_prog_gnu_ld" = yes; then
2487 soname_spec='${libname}${release}${shared_ext}$major'
2488 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2490 irix5* | nonstopux*)
2494 case $LD in # libtool.m4 will add one of these switches to LD
2495 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2496 libsuff= shlibsuff= libmagic=32-bit;;
2497 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2498 libsuff=32 shlibsuff=N32 libmagic=N32;;
2499 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2500 libsuff=64 shlibsuff=64 libmagic=64-bit;;
2501 *) libsuff= shlibsuff= libmagic=never-match;;
2505 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2506 shlibpath_overrides_runpath=no
2507 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2508 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2509 hardcode_into_libs=yes
2512 # No shared lib support for Linux oldld, aout, or coff.
2513 linux*oldld* | linux*aout* | linux*coff*)
2517 # This must be Linux ELF.
2522 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2523 soname_spec='${libname}${release}${shared_ext}$major'
2524 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2525 shlibpath_var=LD_LIBRARY_PATH
2526 shlibpath_overrides_runpath=no
2527 # This implies no fast_install, which is unacceptable.
2528 # Some rework will be needed to allow for fast_install
2529 # before this can be enabled.
2530 hardcode_into_libs=yes
2532 # find out which ABI we are using
2535 x86_64*|s390x*|powerpc64*)
2536 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
2537 if AC_TRY_EVAL(ac_compile); then
2538 case `/usr/bin/file conftest.$ac_objext` in
2541 sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
2549 # Append ld.so.conf contents to the search path
2550 if test -f /etc/ld.so.conf; then
2551 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
2552 sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
2555 # We used to test for /lib/ld.so.1 and disable shared libraries on
2556 # powerpc, because MkLinux only supported shared libraries with the
2557 # GNU dynamic linker. Since this was broken with cross compilers,
2558 # most powerpc-linux boxes support dynamic linking these days and
2559 # people can always --disable-shared, the test was removed, and we
2560 # assume the GNU/Linux dynamic linker is in use.
2561 dynamic_linker='GNU/Linux ld.so'
2568 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2569 soname_spec='${libname}${release}${shared_ext}$major'
2570 shlibpath_var=LD_LIBRARY_PATH
2571 shlibpath_overrides_runpath=no
2572 hardcode_into_libs=yes
2573 dynamic_linker='GNU ld.so'
2580 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
2581 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2582 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2583 dynamic_linker='NetBSD (a.out) ld.so'
2585 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2586 soname_spec='${libname}${release}${shared_ext}$major'
2587 dynamic_linker='NetBSD ld.elf_so'
2589 shlibpath_var=LD_LIBRARY_PATH
2590 shlibpath_overrides_runpath=yes
2591 hardcode_into_libs=yes
2596 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2597 shlibpath_var=LD_LIBRARY_PATH
2598 shlibpath_overrides_runpath=yes
2605 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2606 soname_spec='${libname}${release}${shared_ext}$major'
2607 shlibpath_var=LD_LIBRARY_PATH
2608 shlibpath_overrides_runpath=yes
2613 sys_lib_dlsearch_path_spec="/usr/lib"
2615 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2617 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2618 *) need_version=no ;;
2620 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2621 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2622 shlibpath_var=LD_LIBRARY_PATH
2623 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2625 openbsd2.[[89]] | openbsd2.[[89]].*)
2626 shlibpath_overrides_runpath=no
2629 shlibpath_overrides_runpath=yes
2633 shlibpath_overrides_runpath=yes
2638 libname_spec='$name'
2641 library_names_spec='$libname${shared_ext} $libname.a'
2642 dynamic_linker='OS/2 ld.exe'
2643 shlibpath_var=LIBPATH
2646 osf3* | osf4* | osf5*)
2650 soname_spec='${libname}${release}${shared_ext}$major'
2651 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2652 shlibpath_var=LD_LIBRARY_PATH
2653 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2654 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2661 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2662 soname_spec='${libname}${release}${shared_ext}$major'
2663 shlibpath_var=LD_LIBRARY_PATH
2664 shlibpath_overrides_runpath=yes
2665 hardcode_into_libs=yes
2666 # ldd complains unless libraries are executable
2667 postinstall_cmds='chmod +x $lib'
2672 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2673 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2674 shlibpath_var=LD_LIBRARY_PATH
2675 shlibpath_overrides_runpath=yes
2676 if test "$with_gnu_ld" = yes; then
2684 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2685 soname_spec='${libname}${release}${shared_ext}$major'
2686 shlibpath_var=LD_LIBRARY_PATH
2687 case $host_vendor in
2689 shlibpath_overrides_runpath=no
2691 export_dynamic_flag_spec='${wl}-Blargedynsym'
2692 runpath_var=LD_RUN_PATH
2700 shlibpath_overrides_runpath=no
2701 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2707 if test -d /usr/nec ;then
2709 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2710 soname_spec='$libname${shared_ext}.$major'
2711 shlibpath_var=LD_LIBRARY_PATH
2715 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2716 version_type=freebsd-elf
2719 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2720 soname_spec='${libname}${release}${shared_ext}$major'
2721 shlibpath_var=LD_LIBRARY_PATH
2722 hardcode_into_libs=yes
2723 if test "$with_gnu_ld" = yes; then
2724 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2725 shlibpath_overrides_runpath=no
2727 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2728 shlibpath_overrides_runpath=yes
2731 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2735 sys_lib_dlsearch_path_spec='/usr/lib'
2740 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2741 soname_spec='${libname}${release}${shared_ext}$major'
2742 shlibpath_var=LD_LIBRARY_PATH
2749 AC_MSG_RESULT([$dynamic_linker])
2750 test "$dynamic_linker" = no && can_build_shared=no
2752 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2753 if test "$GCC" = yes; then
2754 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2756 ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2761 AC_DEFUN([_LT_AC_TAGCONFIG],
2762 [AC_ARG_WITH([tags],
2763 [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2764 [include additional configurations @<:@automatic@:>@])],
2765 [tagnames="$withval"])
2767 if test -f "$ltmain" && test -n "$tagnames"; then
2768 if test ! -f "${ofile}"; then
2769 AC_MSG_WARN([output file `$ofile' does not exist])
2772 if test -z "$LTCC"; then
2773 eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2774 if test -z "$LTCC"; then
2775 AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2777 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2780 if test -z "$LTCFLAGS"; then
2781 eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
2784 # Extract list of available tagged configurations in $ofile.
2785 # Note that this assumes the entire list is on one line.
2786 available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2788 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2789 for tagname in $tagnames; do
2791 # Check whether tagname contains only valid characters
2792 case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2794 *) AC_MSG_ERROR([invalid tag name: $tagname])
2798 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2800 AC_MSG_ERROR([tag name \"$tagname\" already exists])
2803 # Update the list of available tags.
2804 if test -n "$tagname"; then
2805 echo appending configuration tag \"$tagname\" to $ofile
2809 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2810 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2811 (test "X$CXX" != "Xg++"))) ; then
2812 AC_LIBTOOL_LANG_CXX_CONFIG
2819 if test -n "$F77" && test "X$F77" != "Xno"; then
2820 AC_LIBTOOL_LANG_F77_CONFIG
2827 if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2828 AC_LIBTOOL_LANG_GCJ_CONFIG
2835 AC_LIBTOOL_LANG_RC_CONFIG
2839 AC_MSG_ERROR([Unsupported tag name: $tagname])
2843 # Append the new tag name to the list of available tags.
2844 if test -n "$tagname" ; then
2845 available_tags="$available_tags $tagname"
2851 # Now substitute the updated list of available tags.
2852 if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2853 mv "${ofile}T" "$ofile"
2857 AC_MSG_ERROR([unable to update list of available tagged configurations.])
2860 ])# _LT_AC_TAGCONFIG
2865 # enable checks for dlopen support
2866 AC_DEFUN([AC_LIBTOOL_DLOPEN],
2867 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2868 ])# AC_LIBTOOL_DLOPEN
2871 # AC_LIBTOOL_WIN32_DLL
2872 # --------------------
2873 # declare package support for building win32 DLLs
2874 AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2875 [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2876 ])# AC_LIBTOOL_WIN32_DLL
2879 # AC_ENABLE_SHARED([DEFAULT])
2880 # ---------------------------
2881 # implement the --enable-shared flag
2882 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2883 AC_DEFUN([AC_ENABLE_SHARED],
2884 [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2885 AC_ARG_ENABLE([shared],
2886 [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2887 [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2888 [p=${PACKAGE-default}
2890 yes) enable_shared=yes ;;
2891 no) enable_shared=no ;;
2894 # Look at the argument we got. We use all the common list separators.
2895 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2896 for pkg in $enableval; do
2898 if test "X$pkg" = "X$p"; then
2905 [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2906 ])# AC_ENABLE_SHARED
2911 # set the default shared flag to --disable-shared
2912 AC_DEFUN([AC_DISABLE_SHARED],
2913 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2914 AC_ENABLE_SHARED(no)
2915 ])# AC_DISABLE_SHARED
2918 # AC_ENABLE_STATIC([DEFAULT])
2919 # ---------------------------
2920 # implement the --enable-static flag
2921 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2922 AC_DEFUN([AC_ENABLE_STATIC],
2923 [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2924 AC_ARG_ENABLE([static],
2925 [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2926 [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2927 [p=${PACKAGE-default}
2929 yes) enable_static=yes ;;
2930 no) enable_static=no ;;
2933 # Look at the argument we got. We use all the common list separators.
2934 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2935 for pkg in $enableval; do
2937 if test "X$pkg" = "X$p"; then
2944 [enable_static=]AC_ENABLE_STATIC_DEFAULT)
2945 ])# AC_ENABLE_STATIC
2950 # set the default static flag to --disable-static
2951 AC_DEFUN([AC_DISABLE_STATIC],
2952 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2953 AC_ENABLE_STATIC(no)
2954 ])# AC_DISABLE_STATIC
2957 # AC_ENABLE_FAST_INSTALL([DEFAULT])
2958 # ---------------------------------
2959 # implement the --enable-fast-install flag
2960 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2961 AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2962 [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2963 AC_ARG_ENABLE([fast-install],
2964 [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2965 [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2966 [p=${PACKAGE-default}
2968 yes) enable_fast_install=yes ;;
2969 no) enable_fast_install=no ;;
2971 enable_fast_install=no
2972 # Look at the argument we got. We use all the common list separators.
2973 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2974 for pkg in $enableval; do
2976 if test "X$pkg" = "X$p"; then
2977 enable_fast_install=yes
2983 [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2984 ])# AC_ENABLE_FAST_INSTALL
2987 # AC_DISABLE_FAST_INSTALL
2988 # -----------------------
2989 # set the default to --disable-fast-install
2990 AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2991 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2992 AC_ENABLE_FAST_INSTALL(no)
2993 ])# AC_DISABLE_FAST_INSTALL
2996 # AC_LIBTOOL_PICMODE([MODE])
2997 # --------------------------
2998 # implement the --with-pic flag
2999 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
3000 AC_DEFUN([AC_LIBTOOL_PICMODE],
3001 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3002 pic_mode=ifelse($#,1,$1,default)
3003 ])# AC_LIBTOOL_PICMODE
3008 # This is predefined starting with Autoconf 2.54, so this conditional
3009 # definition can be removed once we require Autoconf 2.54 or later.
3010 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
3011 [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
3012 [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3013 then ac_cv_prog_egrep='grep -E'
3014 else ac_cv_prog_egrep='egrep'
3016 EGREP=$ac_cv_prog_egrep
3021 # AC_PATH_TOOL_PREFIX
3022 # -------------------
3023 # find a file program which can recognise shared library
3024 AC_DEFUN([AC_PATH_TOOL_PREFIX],
3025 [AC_REQUIRE([AC_PROG_EGREP])dnl
3026 AC_MSG_CHECKING([for $1])
3027 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3029 [[\\/*] | ?:[\\/]*])
3030 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3033 lt_save_MAGIC_CMD="$MAGIC_CMD"
3034 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3035 dnl $ac_dummy forces splitting on constant user-supplied paths.
3036 dnl POSIX.2 word splitting is done only on the output of word expansions,
3037 dnl not every word. This closes a longstanding sh security hole.
3038 ac_dummy="ifelse([$2], , $PATH, [$2])"
3039 for ac_dir in $ac_dummy; do
3041 test -z "$ac_dir" && ac_dir=.
3042 if test -f $ac_dir/$1; then
3043 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3044 if test -n "$file_magic_test_file"; then
3045 case $deplibs_check_method in
3047 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3048 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3049 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3050 $EGREP "$file_magic_regex" > /dev/null; then
3055 *** Warning: the command libtool uses to detect shared libraries,
3056 *** $file_magic_cmd, produces output that libtool cannot recognize.
3057 *** The result is that libtool may fail to recognize shared libraries
3058 *** as such. This will affect the creation of libtool libraries that
3059 *** depend on shared libraries, but programs linked with such libtool
3060 *** libraries will work regardless of this problem. Nevertheless, you
3061 *** may want to report the problem to your system manager and/or to
3062 *** bug-libtool@gnu.org
3072 MAGIC_CMD="$lt_save_MAGIC_CMD"
3075 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3076 if test -n "$MAGIC_CMD"; then
3077 AC_MSG_RESULT($MAGIC_CMD)
3081 ])# AC_PATH_TOOL_PREFIX
3086 # find a file program which can recognise a shared library
3087 AC_DEFUN([AC_PATH_MAGIC],
3088 [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3089 if test -z "$lt_cv_path_MAGIC_CMD"; then
3090 if test -n "$ac_tool_prefix"; then
3091 AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3101 # find the pathname to the GNU or non-GNU linker
3102 AC_DEFUN([AC_PROG_LD],
3103 [AC_ARG_WITH([gnu-ld],
3104 [AC_HELP_STRING([--with-gnu-ld],
3105 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3106 [test "$withval" = no || with_gnu_ld=yes],
3108 AC_REQUIRE([LT_AC_PROG_SED])dnl
3109 AC_REQUIRE([AC_PROG_CC])dnl
3110 AC_REQUIRE([AC_CANONICAL_HOST])dnl
3111 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3113 if test "$GCC" = yes; then
3114 # Check if gcc -print-prog-name=ld gives a path.
3115 AC_MSG_CHECKING([for ld used by $CC])
3118 # gcc leaves a trailing carriage return which upsets mingw
3119 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3121 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3124 # Accept absolute paths.
3125 [[\\/]]* | ?:[[\\/]]*)
3126 re_direlt='/[[^/]][[^/]]*/\.\./'
3127 # Canonicalize the pathname of ld
3128 ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
3129 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3130 ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
3132 test -z "$LD" && LD="$ac_prog"
3135 # If it fails, then pretend we aren't using GCC.
3139 # If it is relative, then search for the first ld in PATH.
3143 elif test "$with_gnu_ld" = yes; then
3144 AC_MSG_CHECKING([for GNU ld])
3146 AC_MSG_CHECKING([for non-GNU ld])
3148 AC_CACHE_VAL(lt_cv_path_LD,
3149 [if test -z "$LD"; then
3150 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3151 for ac_dir in $PATH; do
3153 test -z "$ac_dir" && ac_dir=.
3154 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3155 lt_cv_path_LD="$ac_dir/$ac_prog"
3156 # Check to see if the program is GNU ld. I'd rather use --version,
3157 # but apparently some variants of GNU ld only accept -v.
3158 # Break only if it was the GNU/non-GNU ld that we prefer.
3159 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3160 *GNU* | *'with BFD'*)
3161 test "$with_gnu_ld" != no && break
3164 test "$with_gnu_ld" != yes && break
3171 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3174 if test -n "$LD"; then
3179 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3186 AC_DEFUN([AC_PROG_LD_GNU],
3187 [AC_REQUIRE([AC_PROG_EGREP])dnl
3188 AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3189 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
3190 case `$LD -v 2>&1 </dev/null` in
3191 *GNU* | *'with BFD'*)
3192 lt_cv_prog_gnu_ld=yes
3195 lt_cv_prog_gnu_ld=no
3198 with_gnu_ld=$lt_cv_prog_gnu_ld
3202 # AC_PROG_LD_RELOAD_FLAG
3203 # ----------------------
3204 # find reload flag for linker
3205 # -- PORTME Some linkers may need a different reload flag.
3206 AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
3207 [AC_CACHE_CHECK([for $LD option to reload object files],
3208 lt_cv_ld_reload_flag,
3209 [lt_cv_ld_reload_flag='-r'])
3210 reload_flag=$lt_cv_ld_reload_flag
3211 case $reload_flag in
3213 *) reload_flag=" $reload_flag" ;;
3215 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3218 if test "$GCC" = yes; then
3219 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3221 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3225 ])# AC_PROG_LD_RELOAD_FLAG
3228 # AC_DEPLIBS_CHECK_METHOD
3229 # -----------------------
3230 # how to check for library dependencies
3231 # -- PORTME fill in with the dynamic library characteristics
3232 AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
3233 [AC_CACHE_CHECK([how to recognise dependent libraries],
3234 lt_cv_deplibs_check_method,
3235 [lt_cv_file_magic_cmd='$MAGIC_CMD'
3236 lt_cv_file_magic_test_file=
3237 lt_cv_deplibs_check_method='unknown'
3238 # Need to set the preceding variable on all platforms that support
3239 # interlibrary dependencies.
3240 # 'none' -- dependencies not supported.
3241 # `unknown' -- same as none, but documents that we really don't know.
3242 # 'pass_all' -- all dependencies passed with no checks.
3243 # 'test_compile' -- check by making test program.
3244 # 'file_magic [[regex]]' -- check by looking for files in library path
3245 # which responds to the $file_magic_cmd with a given extended regex.
3246 # If you have `file' or equivalent on your system and you're not sure
3247 # whether `pass_all' will *always* work, you probably want this one.
3251 lt_cv_deplibs_check_method=pass_all
3255 lt_cv_deplibs_check_method=pass_all
3259 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3260 lt_cv_file_magic_cmd='/usr/bin/file -L'
3261 lt_cv_file_magic_test_file=/shlib/libc.so
3265 # func_win32_libid is a shell function defined in ltmain.sh
3266 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3267 lt_cv_file_magic_cmd='func_win32_libid'
3271 # Base MSYS/MinGW do not provide the 'file' command needed by
3272 # func_win32_libid shell function, so use a weaker test based on 'objdump'.
3273 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3274 lt_cv_file_magic_cmd='$OBJDUMP -f'
3277 darwin* | rhapsody*)
3278 lt_cv_deplibs_check_method=pass_all
3281 freebsd* | kfreebsd*-gnu | dragonfly*)
3282 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3285 # Not sure whether the presence of OpenBSD here was a mistake.
3286 # Let's accept both of them until this is cleared up.
3287 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3288 lt_cv_file_magic_cmd=/usr/bin/file
3289 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3293 lt_cv_deplibs_check_method=pass_all
3298 lt_cv_deplibs_check_method=pass_all
3301 hpux10.20* | hpux11*)
3302 lt_cv_file_magic_cmd=/usr/bin/file
3305 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3306 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3309 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
3310 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3313 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3314 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3320 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3321 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3324 irix5* | irix6* | nonstopux*)
3326 *-32|*"-32 ") libmagic=32-bit;;
3327 *-n32|*"-n32 ") libmagic=N32;;
3328 *-64|*"-64 ") libmagic=64-bit;;
3329 *) libmagic=never-match;;
3331 lt_cv_deplibs_check_method=pass_all
3334 # This must be Linux ELF.
3336 lt_cv_deplibs_check_method=pass_all
3340 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3341 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3343 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3348 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3349 lt_cv_file_magic_cmd=/usr/bin/file
3350 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3354 lt_cv_deplibs_check_method=unknown
3358 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3359 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3361 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3365 osf3* | osf4* | osf5*)
3366 lt_cv_deplibs_check_method=pass_all
3370 lt_cv_deplibs_check_method=pass_all
3374 case $host_vendor in
3376 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]]'
3377 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3380 lt_cv_deplibs_check_method=pass_all
3383 lt_cv_file_magic_cmd='/bin/file'
3384 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3387 lt_cv_file_magic_cmd='/bin/file'
3388 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3389 lt_cv_file_magic_test_file=/lib/libc.so
3392 lt_cv_deplibs_check_method=pass_all
3395 lt_cv_deplibs_check_method=pass_all
3400 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3401 lt_cv_deplibs_check_method=pass_all
3405 file_magic_cmd=$lt_cv_file_magic_cmd
3406 deplibs_check_method=$lt_cv_deplibs_check_method
3407 test -z "$deplibs_check_method" && deplibs_check_method=unknown
3408 ])# AC_DEPLIBS_CHECK_METHOD
3413 # find the pathname to a BSD-compatible name lister
3414 AC_DEFUN([AC_PROG_NM],
3415 [AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
3416 [if test -n "$NM"; then
3417 # Let the user override the test.
3420 lt_nm_to_check="${ac_tool_prefix}nm"
3421 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3422 lt_nm_to_check="$lt_nm_to_check nm"
3424 for lt_tmp_nm in $lt_nm_to_check; do
3425 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3426 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3428 test -z "$ac_dir" && ac_dir=.
3429 tmp_nm="$ac_dir/$lt_tmp_nm"
3430 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3431 # Check to see if the nm accepts a BSD-compat flag.
3432 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3433 # nm: unknown option "B" ignored
3434 # Tru64's nm complains that /dev/null is an invalid object file
3435 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3436 */dev/null* | *'Invalid file or object type'*)
3437 lt_cv_path_NM="$tmp_nm -B"
3441 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3443 lt_cv_path_NM="$tmp_nm -p"
3447 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3448 continue # so that we can try to find one that supports BSD flags
3457 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3465 # check for math library
3466 AC_DEFUN([AC_CHECK_LIBM],
3467 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3470 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3471 # These system don't have libm, or don't need it
3474 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3475 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3478 AC_CHECK_LIB(m, cos, LIBM="-lm")
3484 # AC_LIBLTDL_CONVENIENCE([DIRECTORY])
3485 # -----------------------------------
3486 # sets LIBLTDL to the link flags for the libltdl convenience library and
3487 # LTDLINCL to the include flags for the libltdl header and adds
3488 # --enable-ltdl-convenience to the configure arguments. Note that
3489 # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3490 # it is assumed to be `libltdl'. LIBLTDL will be prefixed with
3491 # '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
3492 # (note the single quotes!). If your package is not flat and you're not
3493 # using automake, define top_builddir and top_srcdir appropriately in
3495 AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3496 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3497 case $enable_ltdl_convenience in
3498 no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3499 "") enable_ltdl_convenience=yes
3500 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3502 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3503 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3504 # For backwards non-gettext consistent compatibility...
3506 ])# AC_LIBLTDL_CONVENIENCE
3509 # AC_LIBLTDL_INSTALLABLE([DIRECTORY])
3510 # -----------------------------------
3511 # sets LIBLTDL to the link flags for the libltdl installable library and
3512 # LTDLINCL to the include flags for the libltdl header and adds
3513 # --enable-ltdl-install to the configure arguments. Note that
3514 # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3515 # and an installed libltdl is not found, it is assumed to be `libltdl'.
3516 # LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
3517 # '${top_srcdir}/' (note the single quotes!). If your package is not
3518 # flat and you're not using automake, define top_builddir and top_srcdir
3519 # appropriately in the Makefiles.
3520 # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3521 AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3522 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3523 AC_CHECK_LIB(ltdl, lt_dlinit,
3524 [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3525 [if test x"$enable_ltdl_install" = xno; then
3526 AC_MSG_WARN([libltdl not installed, but installation disabled])
3528 enable_ltdl_install=yes
3531 if test x"$enable_ltdl_install" = x"yes"; then
3532 ac_configure_args="$ac_configure_args --enable-ltdl-install"
3533 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3534 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3536 ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
3540 # For backwards non-gettext consistent compatibility...
3542 ])# AC_LIBLTDL_INSTALLABLE
3547 # enable support for C++ libraries
3548 AC_DEFUN([AC_LIBTOOL_CXX],
3549 [AC_REQUIRE([_LT_AC_LANG_CXX])
3555 AC_DEFUN([_LT_AC_LANG_CXX],
3556 [AC_REQUIRE([AC_PROG_CXX])
3557 AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3558 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
3561 # _LT_AC_PROG_CXXCPP
3562 # ------------------
3563 AC_DEFUN([_LT_AC_PROG_CXXCPP],
3565 AC_REQUIRE([AC_PROG_CXX])
3566 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
3567 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
3568 (test "X$CXX" != "Xg++"))) ; then
3571 ])# _LT_AC_PROG_CXXCPP
3575 # enable support for Fortran 77 libraries
3576 AC_DEFUN([AC_LIBTOOL_F77],
3577 [AC_REQUIRE([_LT_AC_LANG_F77])
3583 AC_DEFUN([_LT_AC_LANG_F77],
3584 [AC_REQUIRE([AC_PROG_F77])
3585 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
3591 # enable support for GCJ libraries
3592 AC_DEFUN([AC_LIBTOOL_GCJ],
3593 [AC_REQUIRE([_LT_AC_LANG_GCJ])
3599 AC_DEFUN([_LT_AC_LANG_GCJ],
3600 [AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
3601 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
3602 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
3603 [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
3604 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
3605 [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
3606 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
3612 # enable support for Windows resource files
3613 AC_DEFUN([AC_LIBTOOL_RC],
3614 [AC_REQUIRE([LT_AC_PROG_RC])
3615 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
3619 # AC_LIBTOOL_LANG_C_CONFIG
3620 # ------------------------
3621 # Ensure that the configuration vars for the C compiler are
3622 # suitably defined. Those variables are subsequently used by
3623 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3624 AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
3625 AC_DEFUN([_LT_AC_LANG_C_CONFIG],
3629 # Source file extension for C test sources.
3632 # Object file extension for compiled C test sources.
3634 _LT_AC_TAGVAR(objext, $1)=$objext
3636 # Code to be used in simple compile tests
3637 lt_simple_compile_test_code="int some_variable = 0;\n"
3639 # Code to be used in simple link tests
3640 lt_simple_link_test_code='int main(){return(0);}\n'
3644 # save warnings/boilerplate of simple test code
3645 _LT_COMPILER_BOILERPLATE
3646 _LT_LINKER_BOILERPLATE
3648 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
3649 AC_LIBTOOL_PROG_COMPILER_PIC($1)
3650 AC_LIBTOOL_PROG_CC_C_O($1)
3651 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3652 AC_LIBTOOL_PROG_LD_SHLIBS($1)
3653 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3654 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3655 AC_LIBTOOL_SYS_LIB_STRIP
3656 AC_LIBTOOL_DLOPEN_SELF
3658 # Report which library types will actually be built
3659 AC_MSG_CHECKING([if libtool supports shared libraries])
3660 AC_MSG_RESULT([$can_build_shared])
3662 AC_MSG_CHECKING([whether to build shared libraries])
3663 test "$can_build_shared" = "no" && enable_shared=no
3665 # On AIX, shared libraries and static libraries use the same namespace, and
3666 # are all built from PIC.
3669 test "$enable_shared" = yes && enable_static=no
3670 if test -n "$RANLIB"; then
3671 archive_cmds="$archive_cmds~\$RANLIB \$lib"
3672 postinstall_cmds='$RANLIB $lib'
3677 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3678 test "$enable_shared" = yes && enable_static=no
3682 AC_MSG_RESULT([$enable_shared])
3684 AC_MSG_CHECKING([whether to build static libraries])
3685 # Make sure either enable_shared or enable_static is yes.
3686 test "$enable_shared" = yes || enable_static=yes
3687 AC_MSG_RESULT([$enable_static])
3689 AC_LIBTOOL_CONFIG($1)
3693 ])# AC_LIBTOOL_LANG_C_CONFIG
3696 # AC_LIBTOOL_LANG_CXX_CONFIG
3697 # --------------------------
3698 # Ensure that the configuration vars for the C compiler are
3699 # suitably defined. Those variables are subsequently used by
3700 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3701 AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
3702 AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
3704 AC_REQUIRE([AC_PROG_CXX])
3705 AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3707 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3708 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
3709 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3710 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3711 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3712 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3713 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3714 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3715 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3716 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3717 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3718 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
3719 _LT_AC_TAGVAR(module_cmds, $1)=
3720 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
3721 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3722 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3723 _LT_AC_TAGVAR(no_undefined_flag, $1)=
3724 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3725 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3727 # Dependencies to place before and after the object being linked:
3728 _LT_AC_TAGVAR(predep_objects, $1)=
3729 _LT_AC_TAGVAR(postdep_objects, $1)=
3730 _LT_AC_TAGVAR(predeps, $1)=
3731 _LT_AC_TAGVAR(postdeps, $1)=
3732 _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3734 # Source file extension for C++ test sources.
3737 # Object file extension for compiled C++ test sources.
3739 _LT_AC_TAGVAR(objext, $1)=$objext
3741 # Code to be used in simple compile tests
3742 lt_simple_compile_test_code="int some_variable = 0;\n"
3744 # Code to be used in simple link tests
3745 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }\n'
3747 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
3750 # save warnings/boilerplate of simple test code
3751 _LT_COMPILER_BOILERPLATE
3752 _LT_LINKER_BOILERPLATE
3754 # Allow CC to be a program name with arguments.
3759 lt_save_with_gnu_ld=$with_gnu_ld
3760 lt_save_path_LD=$lt_cv_path_LD
3761 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3762 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3764 $as_unset lt_cv_prog_gnu_ld
3766 if test -n "${lt_cv_path_LDCXX+set}"; then
3767 lt_cv_path_LD=$lt_cv_path_LDCXX
3769 $as_unset lt_cv_path_LD
3771 test -z "${LDCXX+set}" || LD=$LDCXX
3774 _LT_AC_TAGVAR(compiler, $1)=$CC
3775 _LT_CC_BASENAME([$compiler])
3777 # We don't want -fno-exception wen compiling C++ code, so set the
3778 # no_builtin_flag separately
3779 if test "$GXX" = yes; then
3780 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3782 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3785 if test "$GXX" = yes; then
3786 # Set up default GNU C++ configuration
3790 # Check if GNU C++ uses GNU ld as the underlying linker, since the
3791 # archiving commands below assume that GNU ld is being used.
3792 if test "$with_gnu_ld" = yes; then
3793 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3794 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3796 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3797 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3799 # If archive_cmds runs LD, not CC, wlarc should be empty
3800 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3801 # investigate it a little bit more. (MM)
3804 # ancient GNU ld didn't support --whole-archive et. al.
3805 if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3806 grep 'no-whole-archive' > /dev/null; then
3807 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3809 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3815 # A generic and very simple default shared library creation
3816 # command for GNU C++ for the case where it uses the native
3817 # linker, instead of GNU ld. If possible, this setting should
3818 # overridden to take advantage of the native linker features on
3819 # the platform it is being used on.
3820 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3823 # Commands to make compiler produce verbose output that lists
3824 # what "hidden" libraries, object files and flags are used when
3825 # linking a shared library.
3826 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3834 # PORTME: fill in a description of your system's C++ link characteristics
3835 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3836 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3839 # FIXME: insert proper C++ library support
3840 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3843 if test "$host_cpu" = ia64; then
3844 # On IA64, the linker does run time linking by default, so we don't
3845 # have to do anything special.
3846 aix_use_runtimelinking=no
3847 exp_sym_flag='-Bexport'
3850 aix_use_runtimelinking=no
3852 # Test if we are trying to use run time linking or normal
3853 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
3854 # need to do runtime linking.
3855 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
3856 for ld_flag in $LDFLAGS; do
3859 aix_use_runtimelinking=yes
3867 exp_sym_flag='-bexport'
3868 no_entry_flag='-bnoentry'
3871 # When large executables or shared objects are built, AIX ld can
3872 # have problems creating the table of contents. If linking a library
3873 # or program results in "error TOC overflow" add -mminimal-toc to
3874 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
3875 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3877 _LT_AC_TAGVAR(archive_cmds, $1)=''
3878 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3879 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3880 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3882 if test "$GXX" = yes; then
3883 case $host_os in aix4.[[012]]|aix4.[[012]].*)
3884 # We only want to do this on AIX 4.2 and lower, the check
3885 # below for broken collect2 doesn't work under 4.3+
3886 collect2name=`${CC} -print-prog-name=collect2`
3887 if test -f "$collect2name" && \
3888 strings "$collect2name" | grep resolve_lib_name >/dev/null
3890 # We have reworked collect2
3891 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3893 # We have old collect2
3894 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3895 # It fails to find uninstalled libraries when the uninstalled
3896 # path is not listed in the libpath. Setting hardcode_minus_L
3897 # to unsupported forces relinking
3898 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3899 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3900 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3904 shared_flag='-shared'
3905 if test "$aix_use_runtimelinking" = yes; then
3906 shared_flag="$shared_flag "'${wl}-G'
3910 if test "$host_cpu" = ia64; then
3911 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3912 # chokes on -Wl,-G. The following line is correct:
3915 if test "$aix_use_runtimelinking" = yes; then
3916 shared_flag='${wl}-G'
3918 shared_flag='${wl}-bM:SRE'
3923 # It seems that -bexpall does not export symbols beginning with
3924 # underscore (_), so it is better to generate a list of symbols to export.
3925 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3926 if test "$aix_use_runtimelinking" = yes; then
3927 # Warning - without using the other runtime loading flags (-brtl),
3928 # -berok will link without error, but may produce a broken library.
3929 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3930 # Determine the default libpath from the value encoded in an empty executable.
3931 _LT_AC_SYS_LIBPATH_AIX
3932 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3934 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3936 if test "$host_cpu" = ia64; then
3937 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3938 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3939 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
3941 # Determine the default libpath from the value encoded in an empty executable.
3942 _LT_AC_SYS_LIBPATH_AIX
3943 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3944 # Warning - without using the other run time loading flags,
3945 # -berok will link without error, but may produce a broken library.
3946 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3947 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3948 # Exported symbols can be pulled into shared objects from archives
3949 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
3950 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3951 # This is similar to how AIX traditionally builds its shared libraries.
3952 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
3958 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
3959 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3960 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
3961 # support --undefined. This deserves some investigation. FIXME
3962 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
3964 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3969 case $cc_basename in
3971 # FIXME: insert proper C++ library support
3972 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3977 cygwin* | mingw* | pw32*)
3978 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3979 # as there is no search path for DLLs.
3980 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3981 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3982 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3983 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3985 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3986 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
3987 # If the export-symbols file already is a .def file (1st line
3988 # is EXPORTS), use it as is; otherwise, prepend...
3989 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3990 cp $export_symbols $output_objdir/$soname.def;
3992 echo EXPORTS > $output_objdir/$soname.def;
3993 cat $export_symbols >> $output_objdir/$soname.def;
3995 $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'
3997 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4000 darwin* | rhapsody*)
4002 rhapsody* | darwin1.[[012]])
4003 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
4006 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
4007 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
4009 case ${MACOSX_DEPLOYMENT_TARGET} in
4011 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
4014 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
4020 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4021 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4022 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
4023 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4024 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
4025 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4027 if test "$GXX" = yes ; then
4028 lt_int_apple_cc_single_mod=no
4029 output_verbose_link_cmd='echo'
4030 if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
4031 lt_int_apple_cc_single_mod=yes
4033 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
4034 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
4036 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
4038 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
4039 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
4040 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
4041 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4043 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4045 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4047 case $cc_basename in
4049 output_verbose_link_cmd='echo'
4050 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
4051 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
4052 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
4053 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4054 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4057 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4064 case $cc_basename in
4066 # FIXME: insert proper C++ library support
4067 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4070 # Green Hills C++ Compiler
4071 # FIXME: insert proper C++ library support
4072 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4075 # FIXME: insert proper C++ library support
4076 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4081 # C++ shared libraries reported to be fairly broken before switch to ELF
4082 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4085 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4087 freebsd* | kfreebsd*-gnu | dragonfly*)
4088 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
4090 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
4095 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4096 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4097 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4098 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4099 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4100 # but as the default
4101 # location of the library.
4103 case $cc_basename in
4105 # FIXME: insert proper C++ library support
4106 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4109 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4110 # Commands to make compiler produce verbose output that lists
4111 # what "hidden" libraries, object files and flags are used when
4112 # linking a shared library.
4114 # There doesn't appear to be a way to prevent this compiler from
4115 # explicitly linking system object files so we need to strip them
4116 # from the output so that they don't get included in the library
4118 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4121 if test "$GXX" = yes; then
4122 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4124 # FIXME: insert proper C++ library support
4125 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4131 if test $with_gnu_ld = no; then
4132 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4133 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4137 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
4140 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4146 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4147 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4150 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4151 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4152 # but as the default
4153 # location of the library.
4157 case $cc_basename in
4159 # FIXME: insert proper C++ library support
4160 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4165 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4168 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4171 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4174 # Commands to make compiler produce verbose output that lists
4175 # what "hidden" libraries, object files and flags are used when
4176 # linking a shared library.
4178 # There doesn't appear to be a way to prevent this compiler from
4179 # explicitly linking system object files so we need to strip them
4180 # from the output so that they don't get included in the library
4182 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4185 if test "$GXX" = yes; then
4186 if test $with_gnu_ld = no; then
4189 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4192 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4195 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4200 # FIXME: insert proper C++ library support
4201 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4207 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4208 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4209 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4210 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4211 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4212 # Instead, shared libraries are loaded at an image base (0x10000000 by
4213 # default) and relocated if they conflict, which is a slow very memory
4214 # consuming and fragmenting process. To avoid this, we pick a random,
4215 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4216 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
4217 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4218 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4221 case $cc_basename in
4224 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4226 # Archives containing C++ object files must be created using
4227 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
4228 # necessary to make sure instantiated templates are included
4230 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
4233 if test "$GXX" = yes; then
4234 if test "$with_gnu_ld" = no; then
4235 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4237 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
4240 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4243 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4244 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4247 case $cc_basename in
4249 # Kuck and Associates, Inc. (KAI) C++ Compiler
4251 # KCC will only create a shared library if the output file
4252 # ends with ".so" (or ".sl" for HP-UX), so rename the library
4253 # to its proper name (with version) after linking.
4254 _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4255 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
4256 # Commands to make compiler produce verbose output that lists
4257 # what "hidden" libraries, object files and flags are used when
4258 # linking a shared library.
4260 # There doesn't appear to be a way to prevent this compiler from
4261 # explicitly linking system object files so we need to strip them
4262 # from the output so that they don't get included in the library
4264 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4266 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
4267 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4269 # Archives containing C++ object files must be created using
4270 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
4271 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4276 # version 8.0 and above of icpc choke on multiply defined symbols
4277 # if we add $predep_objects and $postdep_objects, however 7.1 and
4278 # earlier do not add the objects themselves.
4279 case `$CC -V 2>&1` in
4281 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4282 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4284 *) # Version 8.0 or newer
4287 ia64*) tmp_idyn=' -i_dynamic';;
4289 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4290 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4293 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4294 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4295 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4296 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
4299 # Portland Group C++ compiler
4300 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
4301 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
4303 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
4304 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4305 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
4309 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4310 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
4312 runpath_var=LD_RUN_PATH
4313 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4314 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4316 # Commands to make compiler produce verbose output that lists
4317 # what "hidden" libraries, object files and flags are used when
4318 # linking a shared library.
4320 # There doesn't appear to be a way to prevent this compiler from
4321 # explicitly linking system object files so we need to strip them
4322 # from the output so that they don't get included in the library
4324 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4329 # FIXME: insert proper C++ library support
4330 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4333 # FIXME: insert proper C++ library support
4334 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4337 case $cc_basename in
4339 # FIXME: insert proper C++ library support
4340 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4343 # FIXME: insert proper C++ library support
4344 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4349 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4350 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
4352 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4353 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4354 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4356 # Workaround some broken pre-1.5 toolchains
4357 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
4360 # C++ shared libraries are fairly broken
4361 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4364 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4365 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4366 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
4367 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4368 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4369 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
4370 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4371 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4373 output_verbose_link_cmd='echo'
4376 case $cc_basename in
4378 # Kuck and Associates, Inc. (KAI) C++ Compiler
4380 # KCC will only create a shared library if the output file
4381 # ends with ".so" (or ".sl" for HP-UX), so rename the library
4382 # to its proper name (with version) after linking.
4383 _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4385 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4386 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4388 # Archives containing C++ object files must be created using
4389 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
4390 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4394 # Rational C++ 2.4.1
4395 # FIXME: insert proper C++ library support
4396 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4399 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4400 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4402 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4403 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4405 # Commands to make compiler produce verbose output that lists
4406 # what "hidden" libraries, object files and flags are used when
4407 # linking a shared library.
4409 # There doesn't appear to be a way to prevent this compiler from
4410 # explicitly linking system object files so we need to strip them
4411 # from the output so that they don't get included in the library
4413 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4416 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4417 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4418 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4420 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4421 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4423 # Commands to make compiler produce verbose output that lists
4424 # what "hidden" libraries, object files and flags are used when
4425 # linking a shared library.
4426 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4429 # FIXME: insert proper C++ library support
4430 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4436 case $cc_basename in
4438 # Kuck and Associates, Inc. (KAI) C++ Compiler
4440 # KCC will only create a shared library if the output file
4441 # ends with ".so" (or ".sl" for HP-UX), so rename the library
4442 # to its proper name (with version) after linking.
4443 _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4445 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4446 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4448 # Archives containing C++ object files must be created using
4449 # the KAI C++ compiler.
4450 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
4453 # Rational C++ 2.4.1
4454 # FIXME: insert proper C++ library support
4455 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4458 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
4459 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4460 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
4461 echo "-hidden">> $lib.exp~
4462 $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~
4465 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4466 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4468 # Commands to make compiler produce verbose output that lists
4469 # what "hidden" libraries, object files and flags are used when
4470 # linking a shared library.
4472 # There doesn't appear to be a way to prevent this compiler from
4473 # explicitly linking system object files so we need to strip them
4474 # from the output so that they don't get included in the library
4476 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4479 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4480 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4481 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4483 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4484 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4486 # Commands to make compiler produce verbose output that lists
4487 # what "hidden" libraries, object files and flags are used when
4488 # linking a shared library.
4489 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4492 # FIXME: insert proper C++ library support
4493 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4499 # FIXME: insert proper C++ library support
4500 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4503 case $cc_basename in
4506 # FIXME: insert proper C++ library support
4507 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4511 # FIXME: insert proper C++ library support
4512 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4515 # FIXME: insert proper C++ library support
4516 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4521 case $cc_basename in
4523 # Sun C++ 4.2, 5.x and Centerline C++
4524 _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
4525 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4526 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4527 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4528 $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'
4530 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4531 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4533 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
4535 # The C++ compiler is used as linker so we must use $wl
4536 # flag to pass the commands to the underlying system
4537 # linker. We must also pass each convience library through
4538 # to the system linker between allextract/defaultextract.
4539 # The C++ compiler will combine linker options so we
4540 # cannot just pass the convience library names through
4542 # Supported since Solaris 2.6 (maybe 2.5.1?)
4543 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
4546 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4548 output_verbose_link_cmd='echo'
4550 # Archives containing C++ object files must be created using
4551 # "CC -xar", where "CC" is the Sun C++ compiler. This is
4552 # necessary to make sure instantiated templates are included
4554 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4557 # Green Hills C++ Compiler
4558 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4560 # The C++ compiler must be used to create the archive.
4561 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
4564 # GNU C++ compiler with Solaris linker
4565 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4566 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
4567 if $CC --version | grep -v '^2\.7' > /dev/null; then
4568 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4569 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4570 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4572 # Commands to make compiler produce verbose output that lists
4573 # what "hidden" libraries, object files and flags are used when
4574 # linking a shared library.
4575 output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4577 # g++ 2.7 appears to require `-G' NOT `-shared' on this
4579 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4580 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4581 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4583 # Commands to make compiler produce verbose output that lists
4584 # what "hidden" libraries, object files and flags are used when
4585 # linking a shared library.
4586 output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4589 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
4594 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
4595 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4596 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4597 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4598 runpath_var='LD_RUN_PATH'
4600 case $cc_basename in
4602 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4603 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4606 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4607 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4611 sysv5* | sco3.2v5* | sco5v6*)
4612 # Note: We can NOT use -z defs as we might desire, because we do not
4613 # link with -lc, and that would cause any symbols used from libc to
4614 # always be unresolved, which means just about no library would
4615 # ever link correctly. If we're not using GNU ld we use -z text
4616 # though, which does catch some bad symbols but isn't as heavy-handed
4618 # For security reasons, it is highly recommended that you always
4619 # use absolute paths for naming shared libraries, and exclude the
4620 # DT_RUNPATH tag from executables and libraries. But doing so
4621 # requires that you compile everything twice, which is a pain.
4622 # So that behaviour is only enabled if SCOABSPATH is set to a
4623 # non-empty value in the environment. Most likely only useful for
4624 # creating official distributions of packages.
4625 # This is a hack until libtool officially supports absolute path
4626 # names for shared libraries.
4627 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4628 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
4629 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4630 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4631 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
4632 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
4633 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4634 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
4635 runpath_var='LD_RUN_PATH'
4637 case $cc_basename in
4639 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4640 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4643 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4644 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4649 case $cc_basename in
4651 # NonStop-UX NCC 3.20
4652 # FIXME: insert proper C++ library support
4653 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4656 # FIXME: insert proper C++ library support
4657 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4662 # FIXME: insert proper C++ library support
4663 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4666 # FIXME: insert proper C++ library support
4667 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4670 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
4671 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4673 _LT_AC_TAGVAR(GCC, $1)="$GXX"
4674 _LT_AC_TAGVAR(LD, $1)="$LD"
4676 AC_LIBTOOL_POSTDEP_PREDEP($1)
4677 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4678 AC_LIBTOOL_PROG_CC_C_O($1)
4679 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4680 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4681 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4682 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4684 AC_LIBTOOL_CONFIG($1)
4691 with_gnu_ldcxx=$with_gnu_ld
4692 with_gnu_ld=$lt_save_with_gnu_ld
4693 lt_cv_path_LDCXX=$lt_cv_path_LD
4694 lt_cv_path_LD=$lt_save_path_LD
4695 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
4696 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
4697 ])# AC_LIBTOOL_LANG_CXX_CONFIG
4699 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
4700 # ------------------------------------
4701 # Figure out "hidden" library dependencies from verbose
4702 # compiler output when linking a shared library.
4703 # Parse the compiler output and extract the necessary
4704 # objects, libraries and library flags.
4705 AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
4706 dnl we can't use the lt_simple_compile_test_code here,
4707 dnl because it contains code intended for an executable,
4708 dnl not a library. It's possible we should let each
4709 dnl tag define a new lt_????_link_test_code variable,
4710 dnl but it's only used here...
4711 ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
4713 void foo (void) { a = 0; }
4715 ],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
4719 Foo (void) { a = 0; }
4724 ],[$1],[F77],[cat > conftest.$ac_ext <<EOF
4732 ],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
4735 public void bar (void) {
4741 dnl Parse the compiler output and extract the necessary
4742 dnl objects, libraries and library flags.
4743 if AC_TRY_EVAL(ac_compile); then
4744 # Parse the compiler output and extract the necessary
4745 # objects, libraries and library flags.
4747 # Sentinel used to keep track of whether or not we are before
4748 # the conftest object file.
4749 pre_test_object_deps_done=no
4751 # The `*' in the case matches for architectures that use `case' in
4752 # $output_verbose_cmd can trigger glob expansion during the loop
4753 # eval without this substitution.
4754 output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
4756 for p in `eval $output_verbose_link_cmd`; do
4760 # Some compilers place space between "-{L,R}" and the path.
4763 || test $p = "-R"; then
4770 if test "$pre_test_object_deps_done" = no; then
4773 # Internal compiler library paths should come after those
4774 # provided the user. The postdeps already come after the
4775 # user supplied libs so there is no need to process them.
4776 if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4777 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
4779 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
4782 # The "-l" case would never come before the object being
4783 # linked, so don't bother handling this case.
4786 if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
4787 _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
4789 _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
4795 # This assumes that the test object file only shows up
4796 # once in the compiler output.
4797 if test "$p" = "conftest.$objext"; then
4798 pre_test_object_deps_done=yes
4802 if test "$pre_test_object_deps_done" = no; then
4803 if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
4804 _LT_AC_TAGVAR(predep_objects, $1)="$p"
4806 _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
4809 if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
4810 _LT_AC_TAGVAR(postdep_objects, $1)="$p"
4812 _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
4817 *) ;; # Ignore the rest.
4825 echo "libtool.m4: error: problem compiling $1 test program"
4828 $rm -f confest.$objext
4830 # PORTME: override above test on systems where it is broken
4834 # Interix 3.5 installs completely hosed .la files for C++, so rather than
4835 # hack all around it, let's just trust "g++" to DTRT.
4836 _LT_AC_TAGVAR(predep_objects,$1)=
4837 _LT_AC_TAGVAR(postdep_objects,$1)=
4838 _LT_AC_TAGVAR(postdeps,$1)=
4842 case $cc_basename in
4844 # Adding this requires a known-good setup of shared libraries for
4845 # Sun compiler versions before 5.6, else PIC objects from an old
4846 # archive will be linked into the output, leading to subtle bugs.
4847 _LT_AC_TAGVAR(postdeps,$1)='-lCstd -lCrun'
4854 case " $_LT_AC_TAGVAR(postdeps, $1) " in
4855 *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4857 ])# AC_LIBTOOL_POSTDEP_PREDEP
4859 # AC_LIBTOOL_LANG_F77_CONFIG
4860 # --------------------------
4861 # Ensure that the configuration vars for the C compiler are
4862 # suitably defined. Those variables are subsequently used by
4863 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4864 AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4865 AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4866 [AC_REQUIRE([AC_PROG_F77])
4867 AC_LANG_PUSH(Fortran 77)
4869 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4870 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
4871 _LT_AC_TAGVAR(always_export_symbols, $1)=no
4872 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
4873 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
4874 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4875 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
4876 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4877 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
4878 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
4879 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
4880 _LT_AC_TAGVAR(module_cmds, $1)=
4881 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
4882 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
4883 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4884 _LT_AC_TAGVAR(no_undefined_flag, $1)=
4885 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
4886 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4888 # Source file extension for f77 test sources.
4891 # Object file extension for compiled f77 test sources.
4893 _LT_AC_TAGVAR(objext, $1)=$objext
4895 # Code to be used in simple compile tests
4896 lt_simple_compile_test_code=" subroutine t\n return\n end\n"
4898 # Code to be used in simple link tests
4899 lt_simple_link_test_code=" program t\n end\n"
4901 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4904 # save warnings/boilerplate of simple test code
4905 _LT_COMPILER_BOILERPLATE
4906 _LT_LINKER_BOILERPLATE
4908 # Allow CC to be a program name with arguments.
4912 _LT_AC_TAGVAR(compiler, $1)=$CC
4913 _LT_CC_BASENAME([$compiler])
4915 AC_MSG_CHECKING([if libtool supports shared libraries])
4916 AC_MSG_RESULT([$can_build_shared])
4918 AC_MSG_CHECKING([whether to build shared libraries])
4919 test "$can_build_shared" = "no" && enable_shared=no
4921 # On AIX, shared libraries and static libraries use the same namespace, and
4922 # are all built from PIC.
4925 test "$enable_shared" = yes && enable_static=no
4926 if test -n "$RANLIB"; then
4927 archive_cmds="$archive_cmds~\$RANLIB \$lib"
4928 postinstall_cmds='$RANLIB $lib'
4932 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
4933 test "$enable_shared" = yes && enable_static=no
4937 AC_MSG_RESULT([$enable_shared])
4939 AC_MSG_CHECKING([whether to build static libraries])
4940 # Make sure either enable_shared or enable_static is yes.
4941 test "$enable_shared" = yes || enable_static=yes
4942 AC_MSG_RESULT([$enable_static])
4944 _LT_AC_TAGVAR(GCC, $1)="$G77"
4945 _LT_AC_TAGVAR(LD, $1)="$LD"
4947 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4948 AC_LIBTOOL_PROG_CC_C_O($1)
4949 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4950 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4951 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4952 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4954 AC_LIBTOOL_CONFIG($1)
4958 ])# AC_LIBTOOL_LANG_F77_CONFIG
4961 # AC_LIBTOOL_LANG_GCJ_CONFIG
4962 # --------------------------
4963 # Ensure that the configuration vars for the C compiler are
4964 # suitably defined. Those variables are subsequently used by
4965 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4966 AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4967 AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4970 # Source file extension for Java test sources.
4973 # Object file extension for compiled Java test sources.
4975 _LT_AC_TAGVAR(objext, $1)=$objext
4977 # Code to be used in simple compile tests
4978 lt_simple_compile_test_code="class foo {}\n"
4980 # Code to be used in simple link tests
4981 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
4983 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4986 # save warnings/boilerplate of simple test code
4987 _LT_COMPILER_BOILERPLATE
4988 _LT_LINKER_BOILERPLATE
4990 # Allow CC to be a program name with arguments.
4994 _LT_AC_TAGVAR(compiler, $1)=$CC
4995 _LT_CC_BASENAME([$compiler])
4997 # GCJ did not exist at the time GCC didn't implicitly link libc in.
4998 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
5000 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5002 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
5003 AC_LIBTOOL_PROG_COMPILER_PIC($1)
5004 AC_LIBTOOL_PROG_CC_C_O($1)
5005 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
5006 AC_LIBTOOL_PROG_LD_SHLIBS($1)
5007 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
5008 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
5010 AC_LIBTOOL_CONFIG($1)
5014 ])# AC_LIBTOOL_LANG_GCJ_CONFIG
5017 # AC_LIBTOOL_LANG_RC_CONFIG
5018 # -------------------------
5019 # Ensure that the configuration vars for the Windows resource compiler are
5020 # suitably defined. Those variables are subsequently used by
5021 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
5022 AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
5023 AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
5026 # Source file extension for RC test sources.
5029 # Object file extension for compiled RC test sources.
5031 _LT_AC_TAGVAR(objext, $1)=$objext
5033 # Code to be used in simple compile tests
5034 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
5036 # Code to be used in simple link tests
5037 lt_simple_link_test_code="$lt_simple_compile_test_code"
5039 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
5042 # save warnings/boilerplate of simple test code
5043 _LT_COMPILER_BOILERPLATE
5044 _LT_LINKER_BOILERPLATE
5046 # Allow CC to be a program name with arguments.
5050 _LT_AC_TAGVAR(compiler, $1)=$CC
5051 _LT_CC_BASENAME([$compiler])
5052 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
5054 AC_LIBTOOL_CONFIG($1)
5058 ])# AC_LIBTOOL_LANG_RC_CONFIG
5061 # AC_LIBTOOL_CONFIG([TAGNAME])
5062 # ----------------------------
5063 # If TAGNAME is not passed, then create an initial libtool script
5064 # with a default configuration from the untagged config vars. Otherwise
5065 # add code to config.status for appending the configuration named by
5066 # TAGNAME from the matching tagged config vars.
5067 AC_DEFUN([AC_LIBTOOL_CONFIG],
5068 [# The else clause should only fire when bootstrapping the
5069 # libtool distribution, otherwise you forgot to ship ltmain.sh
5070 # with your package, and you will get complaints that there are
5071 # no rules to generate ltmain.sh.
5072 if test -f "$ltmain"; then
5073 # See if we are running on zsh, and set the options which allow our commands through
5074 # without removal of \ escapes.
5075 if test -n "${ZSH_VERSION+set}" ; then
5076 setopt NO_GLOB_SUBST
5078 # Now quote all the things that may contain metacharacters while being
5079 # careful not to overquote the AC_SUBSTed values. We take copies of the
5080 # variables and quote the copies for generation of the libtool script.
5081 for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
5083 libname_spec library_names_spec soname_spec extract_expsyms_cmds \
5084 old_striplib striplib file_magic_cmd finish_cmds finish_eval \
5085 deplibs_check_method reload_flag reload_cmds need_locks \
5086 lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
5087 lt_cv_sys_global_symbol_to_c_name_address \
5088 sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
5089 old_postinstall_cmds old_postuninstall_cmds \
5090 _LT_AC_TAGVAR(compiler, $1) \
5091 _LT_AC_TAGVAR(CC, $1) \
5092 _LT_AC_TAGVAR(LD, $1) \
5093 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
5094 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
5095 _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
5096 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
5097 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
5098 _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
5099 _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
5100 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
5101 _LT_AC_TAGVAR(old_archive_cmds, $1) \
5102 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
5103 _LT_AC_TAGVAR(predep_objects, $1) \
5104 _LT_AC_TAGVAR(postdep_objects, $1) \
5105 _LT_AC_TAGVAR(predeps, $1) \
5106 _LT_AC_TAGVAR(postdeps, $1) \
5107 _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
5108 _LT_AC_TAGVAR(archive_cmds, $1) \
5109 _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
5110 _LT_AC_TAGVAR(postinstall_cmds, $1) \
5111 _LT_AC_TAGVAR(postuninstall_cmds, $1) \
5112 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
5113 _LT_AC_TAGVAR(allow_undefined_flag, $1) \
5114 _LT_AC_TAGVAR(no_undefined_flag, $1) \
5115 _LT_AC_TAGVAR(export_symbols_cmds, $1) \
5116 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
5117 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
5118 _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
5119 _LT_AC_TAGVAR(hardcode_automatic, $1) \
5120 _LT_AC_TAGVAR(module_cmds, $1) \
5121 _LT_AC_TAGVAR(module_expsym_cmds, $1) \
5122 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
5123 _LT_AC_TAGVAR(exclude_expsyms, $1) \
5124 _LT_AC_TAGVAR(include_expsyms, $1); do
5127 _LT_AC_TAGVAR(old_archive_cmds, $1) | \
5128 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
5129 _LT_AC_TAGVAR(archive_cmds, $1) | \
5130 _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
5131 _LT_AC_TAGVAR(module_cmds, $1) | \
5132 _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
5133 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
5134 _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
5135 extract_expsyms_cmds | reload_cmds | finish_cmds | \
5136 postinstall_cmds | postuninstall_cmds | \
5137 old_postinstall_cmds | old_postuninstall_cmds | \
5138 sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
5139 # Double-quote double-evaled strings.
5140 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
5143 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
5149 *'\[$]0 --fallback-echo"')
5150 lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
5155 [cfgfile="${ofile}T"
5156 trap "$rm \"$cfgfile\"; exit 1" 1 2 15
5158 AC_MSG_NOTICE([creating $ofile])],
5161 cat <<__EOF__ >> "$cfgfile"
5165 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
5166 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
5167 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
5169 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
5170 # Free Software Foundation, Inc.
5172 # This file is part of GNU Libtool:
5173 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
5175 # This program is free software; you can redistribute it and/or modify
5176 # it under the terms of the GNU General Public License as published by
5177 # the Free Software Foundation; either version 2 of the License, or
5178 # (at your option) any later version.
5180 # This program is distributed in the hope that it will be useful, but
5181 # WITHOUT ANY WARRANTY; without even the implied warranty of
5182 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5183 # General Public License for more details.
5185 # You should have received a copy of the GNU General Public License
5186 # along with this program; if not, write to the Free Software
5187 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
5189 # As a special exception to the GNU General Public License, if you
5190 # distribute this file as part of a program that contains a
5191 # configuration script generated by Autoconf, you may include it under
5192 # the same distribution terms that you use for the rest of that program.
5194 # A sed program that does not truncate output.
5197 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
5198 Xsed="$SED -e 1s/^X//"
5200 # The HP-UX ksh and POSIX shell print the target directory to stdout
5202 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
5204 # The names of the tagged configurations supported by this script.
5207 # ### BEGIN LIBTOOL CONFIG],
5208 [# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
5210 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5212 # Shell to use when invoking shell scripts.
5215 # Whether or not to build shared libraries.
5216 build_libtool_libs=$enable_shared
5218 # Whether or not to build static libraries.
5219 build_old_libs=$enable_static
5221 # Whether or not to add -lc for building shared libraries.
5222 build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
5224 # Whether or not to disallow shared libs when runtime libs are static
5225 allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
5227 # Whether or not to optimize for fast installation.
5228 fast_install=$enable_fast_install
5231 host_alias=$host_alias
5236 build_alias=$build_alias
5240 # An echo program that does not interpret backslashes.
5245 AR_FLAGS=$lt_AR_FLAGS
5250 # LTCC compiler flags.
5251 LTCFLAGS=$lt_LTCFLAGS
5253 # A language-specific compiler.
5254 CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
5256 # Is the compiler the GNU C compiler?
5257 with_gcc=$_LT_AC_TAGVAR(GCC, $1)
5262 # The linker used to build libraries.
5263 LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
5265 # Whether we need hard or soft links.
5268 # A BSD-compatible nm program.
5271 # A symbol stripping program
5274 # Used to examine libraries when file_magic_cmd begins "file"
5275 MAGIC_CMD=$MAGIC_CMD
5277 # Used on cygwin: DLL creation program.
5280 # Used on cygwin: object dumper.
5283 # Used on cygwin: assembler.
5286 # The name of the directory that contains temporary libtool files.
5289 # How to create reloadable object files.
5290 reload_flag=$lt_reload_flag
5291 reload_cmds=$lt_reload_cmds
5293 # How to pass a linker flag through the compiler.
5294 wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
5296 # Object file suffix (normally "o").
5299 # Old archive suffix (normally "a").
5302 # Shared library suffix (normally ".so").
5303 shrext_cmds='$shrext_cmds'
5305 # Executable file suffix (normally "").
5308 # Additional compiler flags for building library objects.
5309 pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
5312 # What is the maximum length of a command?
5313 max_cmd_len=$lt_cv_sys_max_cmd_len
5315 # Does compiler simultaneously support -c and -o options?
5316 compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
5318 # Must we lock files when doing compilation?
5319 need_locks=$lt_need_locks
5321 # Do we need the lib prefix for modules?
5322 need_lib_prefix=$need_lib_prefix
5324 # Do we need a version for libraries?
5325 need_version=$need_version
5327 # Whether dlopen is supported.
5328 dlopen_support=$enable_dlopen
5330 # Whether dlopen of programs is supported.
5331 dlopen_self=$enable_dlopen_self
5333 # Whether dlopen of statically linked programs is supported.
5334 dlopen_self_static=$enable_dlopen_self_static
5336 # Compiler flag to prevent dynamic linking.
5337 link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
5339 # Compiler flag to turn off builtin functions.
5340 no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
5342 # Compiler flag to allow reflexive dlopens.
5343 export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
5345 # Compiler flag to generate shared objects directly from archives.
5346 whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
5348 # Compiler flag to generate thread-safe objects.
5349 thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
5351 # Library versioning type.
5352 version_type=$version_type
5354 # Format of library name prefix.
5355 libname_spec=$lt_libname_spec
5357 # List of archive names. First name is the real one, the rest are links.
5358 # The last name is the one that the linker finds with -lNAME.
5359 library_names_spec=$lt_library_names_spec
5361 # The coded name of the library, if different from the real name.
5362 soname_spec=$lt_soname_spec
5364 # Commands used to build and install an old-style archive.
5366 old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
5367 old_postinstall_cmds=$lt_old_postinstall_cmds
5368 old_postuninstall_cmds=$lt_old_postuninstall_cmds
5370 # Create an old-style archive from a shared archive.
5371 old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
5373 # Create a temporary old-style archive to link instead of a shared archive.
5374 old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
5376 # Commands used to build and install a shared archive.
5377 archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
5378 archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
5379 postinstall_cmds=$lt_postinstall_cmds
5380 postuninstall_cmds=$lt_postuninstall_cmds
5382 # Commands used to build a loadable module (assumed same as above if empty)
5383 module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
5384 module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
5386 # Commands to strip libraries.
5387 old_striplib=$lt_old_striplib
5388 striplib=$lt_striplib
5390 # Dependencies to place before the objects being linked to create a
5392 predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
5394 # Dependencies to place after the objects being linked to create a
5396 postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
5398 # Dependencies to place before the objects being linked to create a
5400 predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
5402 # Dependencies to place after the objects being linked to create a
5404 postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
5406 # The library search path used internally by the compiler when linking
5408 compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
5410 # Method to check whether dependent libraries are shared objects.
5411 deplibs_check_method=$lt_deplibs_check_method
5413 # Command to use when deplibs_check_method == file_magic.
5414 file_magic_cmd=$lt_file_magic_cmd
5416 # Flag that allows shared libraries with undefined symbols to be built.
5417 allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
5419 # Flag that forces no undefined symbols.
5420 no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
5422 # Commands used to finish a libtool library installation in a directory.
5423 finish_cmds=$lt_finish_cmds
5425 # Same as above, but a single script fragment to be evaled but not shown.
5426 finish_eval=$lt_finish_eval
5428 # Take the output of nm and produce a listing of raw symbols and C names.
5429 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
5431 # Transform the output of nm in a proper C declaration
5432 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
5434 # Transform the output of nm in a C name address pair
5435 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
5437 # This is the shared library runtime path variable.
5438 runpath_var=$runpath_var
5440 # This is the shared library path variable.
5441 shlibpath_var=$shlibpath_var
5443 # Is shlibpath searched before the hard-coded library search path?
5444 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
5446 # How to hardcode a shared library path into an executable.
5447 hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
5449 # Whether we should hardcode library paths into libraries.
5450 hardcode_into_libs=$hardcode_into_libs
5452 # Flag to hardcode \$libdir into a binary during linking.
5453 # This must work even if \$libdir does not exist.
5454 hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
5456 # If ld is used when linking, flag to hardcode \$libdir into
5457 # a binary during linking. This must work even if \$libdir does
5459 hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
5461 # Whether we need a single -rpath flag with a separated argument.
5462 hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
5464 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
5466 hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
5468 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
5470 hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
5472 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
5473 # the resulting binary.
5474 hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
5476 # Set to yes if building a shared library automatically hardcodes DIR into the library
5477 # and all subsequent libraries and executables linked against it.
5478 hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
5480 # Variables whose values should be saved in libtool wrapper scripts and
5481 # restored at relink time.
5482 variables_saved_for_relink="$variables_saved_for_relink"
5484 # Whether libtool must link a program against all its dependency libraries.
5485 link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
5487 # Compile-time system search path for libraries
5488 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
5490 # Run-time system search path for libraries
5491 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
5493 # Fix the shell variable \$srcfile for the compiler.
5494 fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
5496 # Set to yes if exported symbols are required.
5497 always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
5499 # The commands to list exported symbols.
5500 export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
5502 # The commands to extract the exported symbol list from a shared archive.
5503 extract_expsyms_cmds=$lt_extract_expsyms_cmds
5505 # Symbols that should not be listed in the preloaded symbols.
5506 exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
5508 # Symbols that must always be exported.
5509 include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
5512 [# ### END LIBTOOL CONFIG],
5513 [# ### END LIBTOOL TAG CONFIG: $tagname])
5520 cat <<\EOF >> "$cfgfile"
5522 # AIX sometimes has problems with the GCC collect2 program. For some
5523 # reason, if we set the COLLECT_NAMES environment variable, the problems
5524 # vanish in a puff of smoke.
5525 if test "X${COLLECT_NAMES+set}" != Xset; then
5527 export COLLECT_NAMES
5533 # We use sed instead of cat because bash on DJGPP gets confused if
5534 # if finds mixed CR/LF and LF-only lines. Since sed operates in
5535 # text mode, it properly converts lines to CR/LF. This bash problem
5536 # is reportedly fixed, but why not run on old versions too?
5537 sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
5539 mv -f "$cfgfile" "$ofile" || \
5540 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
5544 # If there is no Makefile yet, we rely on a make rule to execute
5545 # `config.status --recheck' to rerun these tests and create the
5546 # libtool script then.
5547 ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
5548 if test -f "$ltmain_in"; then
5549 test -f Makefile && make "$ltmain"
5552 ])# AC_LIBTOOL_CONFIG
5555 # AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
5556 # -------------------------------------------
5557 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
5558 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
5560 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5562 if test "$GCC" = yes; then
5563 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5565 AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
5566 lt_cv_prog_compiler_rtti_exceptions,
5567 [-fno-rtti -fno-exceptions], [],
5568 [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
5570 ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
5573 # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5574 # ---------------------------------
5575 AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
5576 [AC_REQUIRE([AC_CANONICAL_HOST])
5577 AC_REQUIRE([AC_PROG_NM])
5578 AC_REQUIRE([AC_OBJEXT])
5579 # Check for command to grab the raw symbol name followed by C symbol from nm.
5580 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
5581 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
5583 # These are sane defaults that work on at least a few old systems.
5584 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
5586 # Character class describing NM global symbol codes.
5587 symcode='[[BCDEGRST]]'
5589 # Regexp to match symbols that can be accessed directly from C.
5590 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
5592 # Transform an extracted symbol line into a proper C declaration
5593 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
5595 # Transform an extracted symbol line into symbol name and symbol address
5596 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5598 # Define system-specific variables.
5603 cygwin* | mingw* | pw32*)
5604 symcode='[[ABCDGISTW]]'
5606 hpux*) # Its linker distinguishes data from code symbols
5607 if test "$host_cpu" = ia64; then
5608 symcode='[[ABCDEGRST]]'
5610 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5611 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5614 if test "$host_cpu" = ia64; then
5615 symcode='[[ABCDGIRSTW]]'
5616 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5617 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5621 symcode='[[BCDEGRST]]'
5624 symcode='[[BCDEGQRST]]'
5635 sysv5* | sco5v6* | unixware* | OpenUNIX*)
5639 symcode='[[DFNSTU]]'
5643 # Handle CRLF in mingw tool chain
5647 opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5651 # If we're using GNU nm, then use its standard symbol codes.
5652 case `$NM -V 2>&1` in
5653 *GNU* | *'with BFD'*)
5654 symcode='[[ABCDGIRSTW]]' ;;
5657 # Try without a prefix undercore, then with it.
5658 for ac_symprfx in "" "_"; do
5660 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5661 symxfrm="\\1 $ac_symprfx\\2 \\2"
5663 # Write the raw and C identifiers.
5664 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5666 # Check to see that the pipe works correctly.
5670 cat > conftest.$ac_ext <<EOF
5675 void nm_test_func(){}
5679 int main(){nm_test_var='a';nm_test_func();return(0);}
5682 if AC_TRY_EVAL(ac_compile); then
5683 # Now try to grab the symbols.
5685 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5686 # Try sorting and uniquifying the output.
5687 if sort "$nlist" | uniq > "$nlist"T; then
5688 mv -f "$nlist"T "$nlist"
5693 # Make sure that we snagged all the symbols we need.
5694 if grep ' nm_test_var$' "$nlist" >/dev/null; then
5695 if grep ' nm_test_func$' "$nlist" >/dev/null; then
5696 cat <<EOF > conftest.$ac_ext
5702 # Now generate the symbol file.
5703 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
5705 cat <<EOF >> conftest.$ac_ext
5706 #if defined (__STDC__) && __STDC__
5707 # define lt_ptr_t void *
5709 # define lt_ptr_t char *
5713 /* The mapping between symbol names and symbols. */
5718 lt_preloaded_symbols[[]] =
5721 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
5722 cat <<\EOF >> conftest.$ac_ext
5730 # Now try linking the two files.
5731 mv conftest.$ac_objext conftstm.$ac_objext
5732 lt_save_LIBS="$LIBS"
5733 lt_save_CFLAGS="$CFLAGS"
5734 LIBS="conftstm.$ac_objext"
5735 CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5736 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5739 LIBS="$lt_save_LIBS"
5740 CFLAGS="$lt_save_CFLAGS"
5742 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5745 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5748 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5751 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5752 cat conftest.$ac_ext >&5
5754 rm -f conftest* conftst*
5756 # Do not use the global_symbol_pipe unless it works.
5757 if test "$pipe_works" = yes; then
5760 lt_cv_sys_global_symbol_pipe=
5764 if test -z "$lt_cv_sys_global_symbol_pipe"; then
5765 lt_cv_sys_global_symbol_to_cdecl=
5767 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5768 AC_MSG_RESULT(failed)
5772 ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5775 # AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
5776 # ---------------------------------------
5777 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
5778 [_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
5779 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5780 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
5782 AC_MSG_CHECKING([for $compiler option to produce PIC])
5784 # C++ specific cases for pic, static, wl, etc.
5785 if test "$GXX" = yes; then
5786 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5787 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5791 # All AIX code is PIC.
5792 if test "$host_cpu" = ia64; then
5793 # AIX 5 now supports IA64 processor
5794 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5798 # FIXME: we need at least 68020 code to build shared libraries, but
5799 # adding the `-m68020' flag to GCC prevents building anything better,
5801 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5803 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5804 # PIC is the default for these OSes.
5806 mingw* | os2* | pw32*)
5807 # This hack is so that the source file can tell whether it is being
5808 # built for inclusion in a dll (and should export symbols for example).
5809 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5811 darwin* | rhapsody*)
5812 # PIC is the default on this platform
5813 # Common symbols not allowed in MH_DYLIB files
5814 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5817 # DJGPP does not support shared libraries at all
5818 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5821 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5822 # Instead, we relocate shared libraries at runtime.
5825 if test -d /usr/nec; then
5826 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5830 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5836 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5841 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5847 # All AIX code is PIC.
5848 if test "$host_cpu" = ia64; then
5849 # AIX 5 now supports IA64 processor
5850 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5852 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5856 case $cc_basename in
5858 # Green Hills C++ Compiler
5859 # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
5864 # PIC is the default on this platform
5865 # Common symbols not allowed in MH_DYLIB files
5866 case $cc_basename in
5868 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
5869 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5874 case $cc_basename in
5876 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5879 # Green Hills C++ Compiler
5880 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5886 freebsd* | kfreebsd*-gnu | dragonfly*)
5887 # FreeBSD uses GNU C++
5889 hpux9* | hpux10* | hpux11*)
5890 case $cc_basename in
5892 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5893 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5894 if test "$host_cpu" != ia64; then
5895 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5899 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5900 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5906 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5915 # This is c89, which is MS Visual C++ (no shared libs)
5916 # Anyone wants to do a port?
5918 irix5* | irix6* | nonstopux*)
5919 case $cc_basename in
5921 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5922 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5923 # CC pic flag -KPIC is the default.
5930 case $cc_basename in
5933 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5934 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5938 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5939 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5940 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5943 # Portland Group C++ compiler.
5944 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5945 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5946 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5950 # Make sure the PIC flag is empty. It appears that all Alpha
5951 # Linux and Compaq Tru64 Unix objects are PIC.
5952 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5953 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5964 case $cc_basename in
5966 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5974 osf3* | osf4* | osf5*)
5975 case $cc_basename in
5977 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5980 # Rational C++ 2.4.1
5981 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5984 # Digital/Compaq C++
5985 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5986 # Make sure the PIC flag is empty. It appears that all Alpha
5987 # Linux and Compaq Tru64 Unix objects are PIC.
5988 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5989 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5998 case $cc_basename in
6000 # Sun C++ 4.2, 5.x and Centerline C++
6001 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6002 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6003 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6006 # Green Hills C++ Compiler
6007 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6014 case $cc_basename in
6017 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6018 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6022 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6029 case $cc_basename in
6031 # NonStop-UX NCC 3.20
6032 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6038 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6039 case $cc_basename in
6041 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6042 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6043 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6050 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6056 if test "$GCC" = yes; then
6057 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6058 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6062 # All AIX code is PIC.
6063 if test "$host_cpu" = ia64; then
6064 # AIX 5 now supports IA64 processor
6065 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6070 # FIXME: we need at least 68020 code to build shared libraries, but
6071 # adding the `-m68020' flag to GCC prevents building anything better,
6073 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
6076 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
6077 # PIC is the default for these OSes.
6080 mingw* | pw32* | os2*)
6081 # This hack is so that the source file can tell whether it is being
6082 # built for inclusion in a dll (and should export symbols for example).
6083 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
6086 darwin* | rhapsody*)
6087 # PIC is the default on this platform
6088 # Common symbols not allowed in MH_DYLIB files
6089 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
6093 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
6094 # Instead, we relocate shared libraries at runtime.
6098 # Just because we use GCC doesn't mean we suddenly get shared libraries
6099 # on systems that don't support them.
6100 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6105 if test -d /usr/nec; then
6106 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
6111 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6118 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6124 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6128 # PORTME Check for flag to pass linker flags through the system compiler.
6131 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6132 if test "$host_cpu" = ia64; then
6133 # AIX 5 now supports IA64 processor
6134 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6136 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
6140 # PIC is the default on this platform
6141 # Common symbols not allowed in MH_DYLIB files
6142 case $cc_basename in
6144 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
6145 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6150 mingw* | pw32* | os2*)
6151 # This hack is so that the source file can tell whether it is being
6152 # built for inclusion in a dll (and should export symbols for example).
6153 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
6156 hpux9* | hpux10* | hpux11*)
6157 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6158 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6165 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6168 # Is there a better lt_prog_compiler_static that works with the bundled CC?
6169 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6172 irix5* | irix6* | nonstopux*)
6173 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6174 # PIC (with -KPIC) is the default.
6175 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6179 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6180 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6184 case $cc_basename in
6186 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6187 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6188 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6190 pgcc* | pgf77* | pgf90* | pgf95*)
6191 # Portland Group compilers (*not* the Pentium gcc compiler,
6192 # which looks to be a dead project)
6193 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6194 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
6195 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6198 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6199 # All Alpha code is PIC.
6200 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6205 osf3* | osf4* | osf5*)
6206 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6207 # All OSF/1 code is PIC.
6208 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6212 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6213 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6214 case $cc_basename in
6216 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
6218 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
6223 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6224 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6225 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6228 sysv4 | sysv4.2uw2* | sysv4.3*)
6229 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6230 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6231 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6235 if test -d /usr/nec ;then
6236 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
6237 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6241 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6242 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6243 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6244 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6248 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6249 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6253 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6254 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6258 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6263 AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
6266 # Check to make sure the PIC flag actually works.
6268 if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
6269 AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
6270 _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
6271 [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
6272 [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
6274 *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
6276 [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6277 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
6280 # For platforms which do not support PIC, -DPIC is meaningless:
6282 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6285 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
6290 # Check to make sure the static flag actually works.
6292 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
6293 AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
6294 _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
6295 $lt_tmp_static_flag,
6297 [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
6301 # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
6302 # ------------------------------------
6303 # See if the linker supports building shared libraries.
6304 AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
6305 [AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6307 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6310 # If we're using GNU nm, then we don't want the "-C" option.
6311 # -C means demangle to AIX nm, but means don't demangle with GNU nm
6312 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6313 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6315 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6319 _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
6322 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
6325 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6330 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
6331 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6332 _LT_AC_TAGVAR(archive_cmds, $1)=
6333 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
6334 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
6335 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
6336 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6337 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6338 _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
6339 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6340 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6341 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6342 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6343 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6344 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6345 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
6346 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
6347 _LT_AC_TAGVAR(module_cmds, $1)=
6348 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
6349 _LT_AC_TAGVAR(always_export_symbols, $1)=no
6350 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6351 # include_expsyms should be a list of space-separated symbols to be *always*
6352 # included in the symbol list
6353 _LT_AC_TAGVAR(include_expsyms, $1)=
6354 # exclude_expsyms can be an extended regexp of symbols to exclude
6355 # it will be wrapped by ` (' and `)$', so one must not match beginning or
6356 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
6357 # as well as any symbol that contains `d'.
6358 _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
6359 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
6360 # platforms (ab)use it in PIC code, but their linkers get confused if
6361 # the symbol is explicitly referenced. Since portable code cannot
6362 # rely on this symbol name, it's probably fine to never include it in
6363 # preloaded symbol tables.
6364 extract_expsyms_cmds=
6365 # Just being paranoid about ensuring that cc_basename is set.
6366 _LT_CC_BASENAME([$compiler])
6368 cygwin* | mingw* | pw32*)
6369 # FIXME: the MSVC++ port hasn't been tested in a loooong time
6370 # When not using gcc, we currently assume that we are using
6371 # Microsoft Visual C++.
6372 if test "$GCC" != yes; then
6377 # we just hope/assume this is gcc and not c89 (= MSVC++)
6385 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
6386 if test "$with_gnu_ld" = yes; then
6387 # If archive_cmds runs LD, not CC, wlarc should be empty
6390 # Set some defaults for GNU ld with shared library support. These
6391 # are reset later if shared libraries are not supported. Putting them
6392 # here allows them to be overridden if necessary.
6393 runpath_var=LD_RUN_PATH
6394 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6395 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6396 # ancient GNU ld didn't support --whole-archive et. al.
6397 if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
6398 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6400 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6402 supports_anon_versioning=no
6403 case `$LD -v 2>/dev/null` in
6404 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6405 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6406 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6407 *\ 2.11.*) ;; # other 2.11 versions
6408 *) supports_anon_versioning=yes ;;
6411 # See if GNU ld supports shared libraries.
6413 aix3* | aix4* | aix5*)
6414 # On AIX/PPC, the GNU linker is very broken
6415 if test "$host_cpu" != ia64; then
6416 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6419 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
6420 *** to be unable to reliably create shared libraries on AIX.
6421 *** Therefore, libtool is disabling shared libraries support. If you
6422 *** really care for shared libraries, you may want to modify your PATH
6423 *** so that a non-GNU linker is found, and then restart.
6430 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
6431 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6432 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6434 # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
6435 # that the semantics of dynamic libraries on AmigaOS, at least up
6436 # to version 4, is to share data among multiple programs linked
6437 # with the same dynamic library. Since this doesn't match the
6438 # behavior of shared libraries on other platforms, we can't use
6440 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6444 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6445 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6446 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6447 # support --undefined. This deserves some investigation. FIXME
6448 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6450 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6454 cygwin* | mingw* | pw32*)
6455 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6456 # as there is no search path for DLLs.
6457 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6458 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6459 _LT_AC_TAGVAR(always_export_symbols, $1)=no
6460 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6461 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
6463 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
6464 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6465 # If the export-symbols file already is a .def file (1st line
6466 # is EXPORTS), use it as is; otherwise, prepend...
6467 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6468 cp $export_symbols $output_objdir/$soname.def;
6470 echo EXPORTS > $output_objdir/$soname.def;
6471 cat $export_symbols >> $output_objdir/$soname.def;
6473 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6475 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6480 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6481 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6482 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6483 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6484 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6485 # Instead, shared libraries are loaded at an image base (0x10000000 by
6486 # default) and relocated if they conflict, which is a slow very memory
6487 # consuming and fragmenting process. To avoid this, we pick a random,
6488 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6489 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6490 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6491 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6495 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6497 case $cc_basename,$host_cpu in
6498 pgcc*) # Portland Group C compiler
6499 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6500 tmp_addflag=' $pic_flag'
6502 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
6503 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6504 tmp_addflag=' $pic_flag -Mnomain' ;;
6505 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
6506 tmp_addflag=' -i_dynamic' ;;
6507 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
6508 tmp_addflag=' -i_dynamic -nofor_main' ;;
6509 ifc* | ifort*) # Intel Fortran compiler
6510 tmp_addflag=' -nofor_main' ;;
6512 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6514 if test $supports_anon_versioning = yes; then
6515 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
6516 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6517 $echo "local: *; };" >> $output_objdir/$libname.ver~
6518 $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6521 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6526 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6527 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6530 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6531 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6536 if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
6537 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6540 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
6541 *** create shared libraries on Solaris systems. Therefore, libtool
6542 *** is disabling shared libraries support. We urge you to upgrade GNU
6543 *** binutils to release 2.9.1 or newer. Another option is to modify
6544 *** your PATH or compiler configuration so that the native linker is
6545 *** used, and then restart.
6548 elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6549 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6550 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6552 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6556 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
6557 case `$LD -v 2>&1` in
6558 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
6559 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6562 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
6563 *** reliably create shared libraries on SCO systems. Therefore, libtool
6564 *** is disabling shared libraries support. We urge you to upgrade GNU
6565 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
6566 *** your PATH or compiler configuration so that the native linker is
6567 *** used, and then restart.
6572 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6573 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
6574 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
6575 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
6577 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6584 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6586 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6587 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6591 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6592 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6593 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6595 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6600 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
6602 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6603 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6604 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6607 # PORTME fill in a description of your system's linker (not GNU ld)
6610 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6611 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6612 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
6613 # Note: this linker hardcodes the directories in LIBPATH if there
6614 # are no directories specified by -L.
6615 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6616 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
6617 # Neither direct hardcoding nor static linking is supported with a
6619 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6624 if test "$host_cpu" = ia64; then
6625 # On IA64, the linker does run time linking by default, so we don't
6626 # have to do anything special.
6627 aix_use_runtimelinking=no
6628 exp_sym_flag='-Bexport'
6631 # If we're using GNU nm, then we don't want the "-C" option.
6632 # -C means demangle to AIX nm, but means don't demangle with GNU nm
6633 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6634 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6636 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6638 aix_use_runtimelinking=no
6640 # Test if we are trying to use run time linking or normal
6641 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6642 # need to do runtime linking.
6643 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
6644 for ld_flag in $LDFLAGS; do
6645 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6646 aix_use_runtimelinking=yes
6653 exp_sym_flag='-bexport'
6654 no_entry_flag='-bnoentry'
6657 # When large executables or shared objects are built, AIX ld can
6658 # have problems creating the table of contents. If linking a library
6659 # or program results in "error TOC overflow" add -mminimal-toc to
6660 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6661 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6663 _LT_AC_TAGVAR(archive_cmds, $1)=''
6664 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6665 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6666 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6668 if test "$GCC" = yes; then
6669 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6670 # We only want to do this on AIX 4.2 and lower, the check
6671 # below for broken collect2 doesn't work under 4.3+
6672 collect2name=`${CC} -print-prog-name=collect2`
6673 if test -f "$collect2name" && \
6674 strings "$collect2name" | grep resolve_lib_name >/dev/null
6676 # We have reworked collect2
6677 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6679 # We have old collect2
6680 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6681 # It fails to find uninstalled libraries when the uninstalled
6682 # path is not listed in the libpath. Setting hardcode_minus_L
6683 # to unsupported forces relinking
6684 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6685 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6686 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6690 shared_flag='-shared'
6691 if test "$aix_use_runtimelinking" = yes; then
6692 shared_flag="$shared_flag "'${wl}-G'
6696 if test "$host_cpu" = ia64; then
6697 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6698 # chokes on -Wl,-G. The following line is correct:
6701 if test "$aix_use_runtimelinking" = yes; then
6702 shared_flag='${wl}-G'
6704 shared_flag='${wl}-bM:SRE'
6709 # It seems that -bexpall does not export symbols beginning with
6710 # underscore (_), so it is better to generate a list of symbols to export.
6711 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6712 if test "$aix_use_runtimelinking" = yes; then
6713 # Warning - without using the other runtime loading flags (-brtl),
6714 # -berok will link without error, but may produce a broken library.
6715 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
6716 # Determine the default libpath from the value encoded in an empty executable.
6717 _LT_AC_SYS_LIBPATH_AIX
6718 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6719 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6721 if test "$host_cpu" = ia64; then
6722 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6723 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6724 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
6726 # Determine the default libpath from the value encoded in an empty executable.
6727 _LT_AC_SYS_LIBPATH_AIX
6728 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6729 # Warning - without using the other run time loading flags,
6730 # -berok will link without error, but may produce a broken library.
6731 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6732 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6733 # Exported symbols can be pulled into shared objects from archives
6734 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6735 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6736 # This is similar to how AIX traditionally builds its shared libraries.
6737 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6743 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
6744 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6745 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6746 # see comment about different semantics on the GNU ld section
6747 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6751 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6754 cygwin* | mingw* | pw32*)
6755 # When not using gcc, we currently assume that we are using
6756 # Microsoft Visual C++.
6757 # hardcode_libdir_flag_spec is actually meaningless, as there is
6758 # no search path for DLLs.
6759 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6760 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6761 # Tell ltmain to make .lib files, not .a files.
6763 # Tell ltmain to make .dll files, not .so files.
6765 # FIXME: Setting linknames here is a bad hack.
6766 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
6767 # The linker will automatically build a .lib file if we build a DLL.
6768 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
6769 # FIXME: Should let the user specify the lib program.
6770 _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
6771 _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
6772 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6775 darwin* | rhapsody*)
6777 rhapsody* | darwin1.[[012]])
6778 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
6781 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
6782 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6784 case ${MACOSX_DEPLOYMENT_TARGET} in
6786 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6789 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
6795 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6796 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6797 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
6798 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6799 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
6800 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6801 if test "$GCC" = yes ; then
6802 output_verbose_link_cmd='echo'
6803 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
6804 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6805 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
6806 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6807 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6809 case $cc_basename in
6811 output_verbose_link_cmd='echo'
6812 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
6813 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6814 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
6815 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6816 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6819 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6826 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6827 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6828 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6832 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6835 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6836 # support. Future versions do this automatically, but an explicit c++rt0.o
6837 # does not break anything, and helps significantly (at the cost of a little
6840 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6841 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6842 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6843 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6846 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6848 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6849 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6850 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6851 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6854 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6855 freebsd* | kfreebsd*-gnu | dragonfly*)
6856 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
6857 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6858 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6859 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6863 if test "$GCC" = yes; then
6864 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6866 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6868 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6869 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6870 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6872 # hardcode_minus_L: Not really in the search PATH,
6873 # but as the default location of the library.
6874 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6875 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6879 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6880 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6882 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6884 if test "$with_gnu_ld" = no; then
6885 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6886 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6888 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6889 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6891 # hardcode_minus_L: Not really in the search PATH,
6892 # but as the default location of the library.
6893 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6898 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6901 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6904 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6907 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6913 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6916 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6919 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6923 if test "$with_gnu_ld" = no; then
6924 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6925 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6929 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
6930 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6931 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6934 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6935 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6937 # hardcode_minus_L: Not really in the search PATH,
6938 # but as the default location of the library.
6939 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6945 irix5* | irix6* | nonstopux*)
6946 if test "$GCC" = yes; then
6947 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6949 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6950 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6952 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6953 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6954 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6958 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6959 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6961 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6963 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6964 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6965 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6969 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6970 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6971 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6972 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6973 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6977 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6978 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6979 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6980 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6981 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6982 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6983 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6986 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6987 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6988 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6991 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6992 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6999 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7000 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7001 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
7002 _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
7003 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
7007 if test "$GCC" = yes; then
7008 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7009 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7011 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7012 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
7014 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7015 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7018 osf4* | osf5*) # as osf3* with the addition of -msym flag
7019 if test "$GCC" = yes; then
7020 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7021 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7022 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7024 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7025 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
7026 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
7027 $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
7029 # Both c and cxx compiler support -rpath directly
7030 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7032 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7036 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
7037 if test "$GCC" = yes; then
7039 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7040 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7041 $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
7044 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
7045 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7046 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
7048 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7049 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7051 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7053 # The compiler driver will combine linker options so we
7054 # cannot just pass the convience library names through
7055 # without $wl, iff we do not link with $LD.
7056 # Luckily, gcc supports the same syntax we need for Sun Studio.
7057 # Supported since Solaris 2.6 (maybe 2.5.1?)
7060 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
7062 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
7065 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7069 if test "x$host_vendor" = xsequent; then
7070 # Use $CC to link under sequent, because it throws in some extra .o
7071 # files that make .init and .fini sections work.
7072 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
7074 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
7076 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7077 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
7078 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7079 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7083 case $host_vendor in
7085 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7086 _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
7089 ## LD is ld it makes a PLAMLIB
7090 ## CC just makes a GrossModule.
7091 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
7092 _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
7093 _LT_AC_TAGVAR(hardcode_direct, $1)=no
7096 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7097 _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
7100 runpath_var='LD_RUN_PATH'
7101 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7105 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7106 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7107 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
7111 if test -d /usr/nec; then
7112 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7113 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7114 runpath_var=LD_RUN_PATH
7115 hardcode_runpath_var=yes
7116 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
7120 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7*)
7121 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7122 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7123 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7124 runpath_var='LD_RUN_PATH'
7126 if test "$GCC" = yes; then
7127 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7128 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7130 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7131 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7135 sysv5* | sco3.2v5* | sco5v6*)
7136 # Note: We can NOT use -z defs as we might desire, because we do not
7137 # link with -lc, and that would cause any symbols used from libc to
7138 # always be unresolved, which means just about no library would
7139 # ever link correctly. If we're not using GNU ld we use -z text
7140 # though, which does catch some bad symbols but isn't as heavy-handed
7142 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7143 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7144 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7145 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7146 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
7147 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
7148 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7149 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7150 runpath_var='LD_RUN_PATH'
7152 if test "$GCC" = yes; then
7153 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7154 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7156 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7157 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7162 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7163 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7164 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7168 _LT_AC_TAGVAR(ld_shlibs, $1)=no
7173 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
7174 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7177 # Do we need to explicitly link libc?
7179 case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
7181 # Assume -lc should be added
7182 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7184 if test "$enable_shared" = yes && test "$GCC" = yes; then
7185 case $_LT_AC_TAGVAR(archive_cmds, $1) in
7187 # FIXME: we may have to deal with multi-command sequences.
7190 # Test whether the compiler implicitly links with -lc since on some
7191 # systems, -lgcc has to come before -lc. If gcc already passes -lc
7192 # to ld, don't add -lc before -lgcc.
7193 AC_MSG_CHECKING([whether -lc should be explicitly linked in])
7195 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7197 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
7200 libobjs=conftest.$ac_objext
7202 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
7203 pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
7209 lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
7210 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
7211 if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
7213 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7215 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7217 _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
7219 cat conftest.err 1>&5
7222 AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
7228 ])# AC_LIBTOOL_PROG_LD_SHLIBS
7231 # _LT_AC_FILE_LTDLL_C
7232 # -------------------
7233 # Be careful that the start marker always follows a newline.
7234 AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
7235 # /* ltdll.c starts here */
7236 # #define WIN32_LEAN_AND_MEAN
7237 # #include <windows.h>
7238 # #undef WIN32_LEAN_AND_MEAN
7239 # #include <stdio.h>
7241 # #ifndef __CYGWIN__
7242 # # ifdef __CYGWIN32__
7243 # # define __CYGWIN__ __CYGWIN32__
7247 # #ifdef __cplusplus
7250 # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
7251 # #ifdef __cplusplus
7256 # #include <cygwin/cygwin_dll.h>
7257 # DECLARE_CYGWIN_DLL( DllMain );
7259 # HINSTANCE __hDllInstance_base;
7262 # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
7264 # __hDllInstance_base = hInst;
7267 # /* ltdll.c ends here */
7268 ])# _LT_AC_FILE_LTDLL_C
7271 # _LT_AC_TAGVAR(VARNAME, [TAGNAME])
7272 # ---------------------------------
7273 AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
7277 AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
7278 AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
7279 AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
7280 AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
7281 AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
7282 AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
7283 AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
7285 # This is just to silence aclocal about the macro not being used
7286 ifelse([AC_DISABLE_FAST_INSTALL])
7288 AC_DEFUN([LT_AC_PROG_GCJ],
7289 [AC_CHECK_TOOL(GCJ, gcj, no)
7290 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7294 AC_DEFUN([LT_AC_PROG_RC],
7295 [AC_CHECK_TOOL(RC, windres, no)
7298 # NOTE: This macro has been submitted for inclusion into #
7299 # GNU Autoconf as AC_PROG_SED. When it is available in #
7300 # a released version of Autoconf we should remove this #
7301 # macro and use it instead. #
7304 # Check for a fully-functional sed program, that truncates
7305 # as few characters as possible. Prefer GNU sed if found.
7306 AC_DEFUN([LT_AC_PROG_SED],
7307 [AC_MSG_CHECKING([for a sed that does not truncate output])
7308 AC_CACHE_VAL(lt_cv_path_SED,
7309 [# Loop through the user's path and test for sed and gsed.
7310 # Then use that list of sed's as ones to test for truncation.
7311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7315 test -z "$as_dir" && as_dir=.
7316 for lt_ac_prog in sed gsed; do
7317 for ac_exec_ext in '' $ac_executable_extensions; do
7318 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
7319 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7326 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
7327 # along with /bin/sed that truncates output.
7328 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7329 test ! -f $lt_ac_sed && continue
7330 cat /dev/null > conftest.in
7332 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7333 # Check for GNU sed and select it if it is found.
7334 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7335 lt_cv_path_SED=$lt_ac_sed
7339 cat conftest.in conftest.in >conftest.tmp
7340 mv conftest.tmp conftest.in
7341 cp conftest.in conftest.nl
7343 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7344 cmp -s conftest.out conftest.nl || break
7345 # 10000 chars as input seems more than enough
7346 test $lt_ac_count -gt 10 && break
7347 lt_ac_count=`expr $lt_ac_count + 1`
7348 if test $lt_ac_count -gt $lt_ac_max; then
7349 lt_ac_max=$lt_ac_count
7350 lt_cv_path_SED=$lt_ac_sed
7356 AC_MSG_RESULT([$SED])
7359 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
7361 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
7363 # This program is free software; you can redistribute it and/or modify
7364 # it under the terms of the GNU General Public License as published by
7365 # the Free Software Foundation; either version 2 of the License, or
7366 # (at your option) any later version.
7368 # This program is distributed in the hope that it will be useful, but
7369 # WITHOUT ANY WARRANTY; without even the implied warranty of
7370 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
7371 # General Public License for more details.
7373 # You should have received a copy of the GNU General Public License
7374 # along with this program; if not, write to the Free Software
7375 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
7377 # As a special exception to the GNU General Public License, if you
7378 # distribute this file as part of a program that contains a
7379 # configuration script generated by Autoconf, you may include it under
7380 # the same distribution terms that you use for the rest of that program.
7382 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
7383 # ----------------------------------
7384 AC_DEFUN([PKG_PROG_PKG_CONFIG],
7385 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
7386 m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
7387 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl
7388 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
7389 AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
7391 if test -n "$PKG_CONFIG"; then
7392 _pkg_min_version=m4_default([$1], [0.9.0])
7393 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
7394 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
7395 AC_MSG_RESULT([yes])
7402 ])# PKG_PROG_PKG_CONFIG
7404 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
7406 # Check to see whether a particular set of modules exists. Similar
7407 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
7410 # Similar to PKG_CHECK_MODULES, make sure that the first instance of
7411 # this or PKG_CHECK_MODULES is called, or make sure to call
7412 # PKG_CHECK_EXISTS manually
7413 # --------------------------------------------------------------
7414 AC_DEFUN([PKG_CHECK_EXISTS],
7415 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
7416 if test -n "$PKG_CONFIG" && \
7417 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
7418 m4_ifval([$2], [$2], [:])
7419 m4_ifvaln([$3], [else
7424 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
7425 # ---------------------------------------------
7426 m4_define([_PKG_CONFIG],
7427 [if test -n "$PKG_CONFIG"; then
7428 if test -n "$$1"; then
7431 PKG_CHECK_EXISTS([$3],
7432 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
7440 # _PKG_SHORT_ERRORS_SUPPORTED
7441 # -----------------------------
7442 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
7443 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
7444 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
7445 _pkg_short_errors_supported=yes
7447 _pkg_short_errors_supported=no
7449 ])# _PKG_SHORT_ERRORS_SUPPORTED
7452 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
7453 # [ACTION-IF-NOT-FOUND])
7456 # Note that if there is a possibility the first call to
7457 # PKG_CHECK_MODULES might not happen, you should be sure to include an
7458 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
7461 # --------------------------------------------------------------
7462 AC_DEFUN([PKG_CHECK_MODULES],
7463 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
7464 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
7465 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
7468 AC_MSG_CHECKING([for $1])
7470 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
7471 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
7473 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
7474 and $1[]_LIBS to avoid the need to call pkg-config.
7475 See the pkg-config man page for more details.])
7477 if test $pkg_failed = yes; then
7478 _PKG_SHORT_ERRORS_SUPPORTED
7479 if test $_pkg_short_errors_supported = yes; then
7480 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$2"`
7482 $1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
7484 # Put the nasty error message in config.log where it belongs
7485 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
7487 ifelse([$4], , [AC_MSG_ERROR(dnl
7488 [Package requirements ($2) were not met:
7492 Consider adjusting the PKG_CONFIG_PATH environment variable if you
7493 installed software in a non-standard prefix.
7497 [AC_MSG_RESULT([no])
7499 elif test $pkg_failed = untried; then
7500 ifelse([$4], , [AC_MSG_FAILURE(dnl
7501 [The pkg-config script could not be found or is too old. Make sure it
7502 is in your PATH or set the PKG_CONFIG environment variable to the full
7507 To get pkg-config, see <http://www.freedesktop.org/software/pkgconfig>.])],
7510 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
7511 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
7512 AC_MSG_RESULT([yes])
7513 ifelse([$3], , :, [$3])
7515 ])# PKG_CHECK_MODULES
7517 m4_include([scripts/docgen.m4])
7518 m4_include([scripts/macros.m4])
7519 m4_include([scripts/reduced.m4])