1 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
2 ## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005
3 ## 2006, 2007, 2008, 2009, 2010
4 ## Free Software Foundation, Inc.
5 ## Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
7 ## This file is free software; the Free Software Foundation gives
8 ## unlimited permission to copy and/or distribute it, with or without
9 ## modifications, as long as this notice is preserved.
11 # serial 48 AC_PROG_LIBTOOL
13 # serial 7 AC_LIB_LTDL
15 # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
16 # -----------------------------------------------------------
17 # If this macro is not defined by Autoconf, define it here.
18 m4_ifdef([AC_PROVIDE_IFELSE],
20 [m4_define([AC_PROVIDE_IFELSE],
21 [m4_ifdef([AC_PROVIDE_$1],
27 AC_DEFUN([AC_PROG_LIBTOOL],
28 [AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
29 dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
30 dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
31 AC_PROVIDE_IFELSE([AC_PROG_CXX],
33 [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
35 dnl And a similar setup for Fortran 77 support
36 AC_PROVIDE_IFELSE([AC_PROG_F77],
38 [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
41 dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
42 dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
43 dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
44 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
46 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
48 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
51 [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
52 ifdef([A][M_PROG_GCJ],
53 [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
54 ifdef([LT_AC_PROG_GCJ],
55 [define([LT_AC_PROG_GCJ],
56 defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
62 AC_DEFUN([_AC_PROG_LIBTOOL],
63 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
64 AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
65 AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
66 AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
68 # This can be used to rebuild libtool when needed
69 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
71 # Always use our own libtool.
72 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
75 # Prevent multiple expansion
76 define([AC_PROG_LIBTOOL], [])
82 AC_DEFUN([AC_LIBTOOL_SETUP],
84 AC_REQUIRE([AC_ENABLE_SHARED])dnl
85 AC_REQUIRE([AC_ENABLE_STATIC])dnl
86 AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
87 AC_REQUIRE([AC_CANONICAL_HOST])dnl
88 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
89 AC_REQUIRE([AC_PROG_CC])dnl
90 AC_REQUIRE([AC_PROG_LD])dnl
91 AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
92 AC_REQUIRE([AC_PROG_NM])dnl
94 AC_REQUIRE([AC_PROG_LN_S])dnl
95 AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
96 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
97 AC_REQUIRE([AC_OBJEXT])dnl
98 AC_REQUIRE([AC_EXEEXT])dnl
101 AC_LIBTOOL_SYS_MAX_CMD_LEN
102 AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
105 AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
106 _LT_AC_PROG_ECHO_BACKSLASH
110 # AIX sometimes has problems with the GCC collect2 program. For some
111 # reason, if we set the COLLECT_NAMES environment variable, the problems
112 # vanish in a puff of smoke.
113 if test "X${COLLECT_NAMES+set}" != Xset; then
120 # Sed substitution that helps us do robust quoting. It backslashifies
121 # metacharacters that are still active within double-quoted strings.
122 Xsed='sed -e 1s/^X//'
123 [sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
125 # Same as above, but do not quote variable references.
126 [double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
128 # Sed substitution to delay expansion of an escaped shell variable in a
129 # double_quote_subst'ed string.
130 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
132 # Sed substitution to avoid accidental globbing in evaled expressions
133 no_glob_subst='s/\*/\\\*/g'
139 default_ofile=libtool
142 # All known linkers require a `.a' archive for static linking (except MSVC,
143 # which needs '.lib').
145 ltmain="$ac_aux_dir/ltmain.sh"
146 ofile="$default_ofile"
147 with_gnu_ld="$lt_cv_prog_gnu_ld"
149 AC_CHECK_TOOL(AR, ar, false)
150 AC_CHECK_TOOL(RANLIB, ranlib, :)
151 AC_CHECK_TOOL(STRIP, strip, :)
156 # Set sane defaults for various variables
157 test -z "$AR" && AR=ar
158 test -z "$AR_FLAGS" && AR_FLAGS=cru
159 test -z "$AS" && AS=as
160 test -z "$CC" && CC=cc
161 test -z "$LTCC" && LTCC=$CC
162 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
163 test -z "$DLLTOOL" && DLLTOOL=dlltool
164 test -z "$LD" && LD=ld
165 test -z "$LN_S" && LN_S="ln -s"
166 test -z "$MAGIC_CMD" && MAGIC_CMD=file
167 test -z "$NM" && NM=nm
168 test -z "$SED" && SED=sed
169 test -z "$OBJDUMP" && OBJDUMP=objdump
170 test -z "$RANLIB" && RANLIB=:
171 test -z "$STRIP" && STRIP=:
172 test -z "$ac_objext" && ac_objext=o
174 # Determine commands to create old-style static archives.
175 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
176 old_postinstall_cmds='chmod 644 $oldlib'
177 old_postuninstall_cmds=
179 if test -n "$RANLIB"; then
182 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
185 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
188 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
191 _LT_CC_BASENAME([$compiler])
193 # Only perform the check for file, if the check method requires it
194 case $deplibs_check_method in
196 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
202 AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
203 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
204 enable_win32_dll=yes, enable_win32_dll=no)
206 AC_ARG_ENABLE([libtool-lock],
207 [AC_HELP_STRING([--disable-libtool-lock],
208 [avoid locking (might break parallel builds)])])
209 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
212 [AC_HELP_STRING([--with-pic],
213 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
214 [pic_mode="$withval"],
216 test -z "$pic_mode" && pic_mode=default
218 # Use C for the default configuration in the libtool script
220 AC_LIBTOOL_LANG_C_CONFIG
225 # _LT_AC_SYS_COMPILER
226 # -------------------
227 AC_DEFUN([_LT_AC_SYS_COMPILER],
228 [AC_REQUIRE([AC_PROG_CC])dnl
230 # If no C compiler was specified, use CC.
233 # If no C compiler flags were specified, use CFLAGS.
234 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
236 # Allow CC to be a program name with arguments.
238 ])# _LT_AC_SYS_COMPILER
241 # _LT_CC_BASENAME(CC)
242 # -------------------
243 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
244 AC_DEFUN([_LT_CC_BASENAME],
245 [for cc_temp in $1""; do
247 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
248 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
253 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
257 # _LT_COMPILER_BOILERPLATE
258 # ------------------------
259 # Check for compiler boilerplate output or warnings with
260 # the simple compiler test code.
261 AC_DEFUN([_LT_COMPILER_BOILERPLATE],
262 [ac_outfile=conftest.$ac_objext
263 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
264 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
265 _lt_compiler_boilerplate=`cat conftest.err`
267 ])# _LT_COMPILER_BOILERPLATE
270 # _LT_LINKER_BOILERPLATE
271 # ----------------------
272 # Check for linker boilerplate output or warnings with
273 # the simple link test code.
274 AC_DEFUN([_LT_LINKER_BOILERPLATE],
275 [ac_outfile=conftest.$ac_objext
276 printf "$lt_simple_link_test_code" >conftest.$ac_ext
277 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
278 _lt_linker_boilerplate=`cat conftest.err`
280 ])# _LT_LINKER_BOILERPLATE
283 # _LT_AC_SYS_LIBPATH_AIX
284 # ----------------------
285 # Links a minimal program and checks the executable
286 # for the system default hardcoded library path. In most cases,
287 # this is /usr/lib:/lib, but when the MPI compilers are used
288 # the location of the communication and MPI libs are included too.
289 # If we don't find anything, use the default library path according
290 # to the aix ld manual.
291 AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
292 [AC_LINK_IFELSE(AC_LANG_PROGRAM,[
293 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
295 # Check for a 64-bit object if we didn't find anything.
296 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; }
298 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
299 ])# _LT_AC_SYS_LIBPATH_AIX
302 # _LT_AC_SHELL_INIT(ARG)
303 # ----------------------
304 AC_DEFUN([_LT_AC_SHELL_INIT],
305 [ifdef([AC_DIVERSION_NOTICE],
306 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
307 [AC_DIVERT_PUSH(NOTICE)])
310 ])# _LT_AC_SHELL_INIT
313 # _LT_AC_PROG_ECHO_BACKSLASH
314 # --------------------------
315 # Add some code to the start of the generated configure script which
316 # will find an echo command which doesn't interpret backslashes.
317 AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
319 # Check that we are running under the correct shell.
320 SHELL=${CONFIG_SHELL-/bin/sh}
324 # Remove one level of quotation (which was required for Make).
325 ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
330 if test "X[$]1" = X--no-reexec; then
331 # Discard the --no-reexec flag, and continue.
333 elif test "X[$]1" = X--fallback-echo; then
334 # Avoid inline document here, it may be left over
336 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
337 # Yippee, $echo works!
340 # Restart under the correct shell.
341 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
344 if test "X[$]1" = X--fallback-echo; then
345 # used as fallback echo
353 # The HP-UX ksh and POSIX shell print the target directory to stdout
355 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
357 if test -z "$ECHO"; then
358 if test "X${echo_test_string+set}" != Xset; then
359 # find a string as large as possible, as long as the shell can cope with it
360 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
361 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
362 if (echo_test_string=`eval $cmd`) 2>/dev/null &&
363 echo_test_string=`eval $cmd` &&
364 (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
371 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
372 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
373 test "X$echo_testing_string" = "X$echo_test_string"; then
376 # The Solaris, AIX, and Digital Unix default echo programs unquote
377 # backslashes. This makes it impossible to quote backslashes using
378 # echo "$something" | sed 's/\\/\\\\/g'
380 # So, first we look for a working echo in the user's PATH.
382 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
383 for dir in $PATH /usr/ucb; do
385 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
386 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
387 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
388 test "X$echo_testing_string" = "X$echo_test_string"; then
395 if test "X$echo" = Xecho; then
396 # We didn't find a better echo, so look for alternatives.
397 if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
398 echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
399 test "X$echo_testing_string" = "X$echo_test_string"; then
400 # This shell has a builtin print -r that does the trick.
402 elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
403 test "X$CONFIG_SHELL" != X/bin/ksh; then
404 # If we have ksh, try running configure again with it.
405 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
406 export ORIGINAL_CONFIG_SHELL
407 CONFIG_SHELL=/bin/ksh
409 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
413 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
414 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
415 test "X$echo_testing_string" = "X$echo_test_string"; then
418 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
419 test "X$echo_testing_string" = 'X\t' &&
420 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
421 test "X$echo_testing_string" = "X$echo_test_string"; then
422 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
424 SHELL="$CONFIG_SHELL"
426 echo="$CONFIG_SHELL [$]0 --fallback-echo"
427 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
428 test "X$echo_testing_string" = 'X\t' &&
429 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
430 test "X$echo_testing_string" = "X$echo_test_string"; then
431 echo="$CONFIG_SHELL [$]0 --fallback-echo"
433 # maybe with a smaller string...
436 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
437 if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
444 if test "$prev" != 'sed 50q "[$]0"'; then
445 echo_test_string=`eval $prev`
446 export echo_test_string
447 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
449 # Oops. We lost completely, so just stick with echo.
458 # Copy echo and quote the copy suitably for passing to libtool from
459 # the Makefile, instead of quoting the original, which is used later.
461 if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
462 ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
466 ])])# _LT_AC_PROG_ECHO_BACKSLASH
471 AC_DEFUN([_LT_AC_LOCK],
472 [AC_ARG_ENABLE([libtool-lock],
473 [AC_HELP_STRING([--disable-libtool-lock],
474 [avoid locking (might break parallel builds)])])
475 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
477 # Some flags need to be propagated to the compiler or linker for good
481 # Find out which ABI we are using.
482 echo 'int i;' > conftest.$ac_ext
483 if AC_TRY_EVAL(ac_compile); then
484 case `/usr/bin/file conftest.$ac_objext` in
496 # Find out which ABI we are using.
497 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
498 if AC_TRY_EVAL(ac_compile); then
499 if test "$lt_cv_prog_gnu_ld" = yes; then
500 case `/usr/bin/file conftest.$ac_objext` in
502 LD="${LD-ld} -melf32bsmip"
505 LD="${LD-ld} -melf32bmipn32"
508 LD="${LD-ld} -melf64bmip"
512 case `/usr/bin/file conftest.$ac_objext` in
528 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
529 # Find out which ABI we are using.
530 echo 'int i;' > conftest.$ac_ext
531 if AC_TRY_EVAL(ac_compile); then
532 case `/usr/bin/file conftest.o` in
536 LD="${LD-ld} -m elf_i386"
538 ppc64-*linux*|powerpc64-*linux*)
539 LD="${LD-ld} -m elf32ppclinux"
542 LD="${LD-ld} -m elf_s390"
545 LD="${LD-ld} -m elf32_sparc"
552 LD="${LD-ld} -m elf_x86_64"
554 ppc*-*linux*|powerpc*-*linux*)
555 LD="${LD-ld} -m elf64ppc"
558 LD="${LD-ld} -m elf64_s390"
561 LD="${LD-ld} -m elf64_sparc"
571 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
572 SAVE_CFLAGS="$CFLAGS"
573 CFLAGS="$CFLAGS -belf"
574 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
576 AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
578 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
579 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
580 CFLAGS="$SAVE_CFLAGS"
584 # Find out which ABI we are using.
585 echo 'int i;' > conftest.$ac_ext
586 if AC_TRY_EVAL(ac_compile); then
587 case `/usr/bin/file conftest.o` in
589 case $lt_cv_prog_gnu_ld in
590 yes*) LD="${LD-ld} -m elf64_sparc" ;;
591 *) LD="${LD-ld} -64" ;;
599 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
600 [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
601 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
602 AC_CHECK_TOOL(AS, as, false)
603 AC_CHECK_TOOL(OBJDUMP, objdump, false)
608 need_locks="$enable_libtool_lock"
613 # AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
614 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
615 # ----------------------------------------------------------------
616 # Check whether the given compiler option works
617 AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
618 [AC_REQUIRE([LT_AC_PROG_SED])
619 AC_CACHE_CHECK([$1], [$2],
621 ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
622 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
623 lt_compiler_flag="$3"
624 # Insert the option either (1) after the last *FLAGS variable, or
625 # (2) before a word containing "conftest.", or (3) at the end.
626 # Note that $ac_compile itself does not contain backslashes and begins
627 # with a dollar sign (not a hyphen), so the echo should work correctly.
628 # The option is referenced via a variable to avoid confusing sed.
629 lt_compile=`echo "$ac_compile" | $SED \
630 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
631 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
632 -e 's:$: $lt_compiler_flag:'`
633 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
634 (eval "$lt_compile" 2>conftest.err)
636 cat conftest.err >&AS_MESSAGE_LOG_FD
637 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
638 if (exit $ac_status) && test -s "$ac_outfile"; then
639 # The compiler can only warn and ignore the option if not recognized
640 # So say no if there are warnings other than the usual output.
641 $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
642 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
643 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
650 if test x"[$]$2" = xyes; then
651 ifelse([$5], , :, [$5])
653 ifelse([$6], , :, [$6])
655 ])# AC_LIBTOOL_COMPILER_OPTION
658 # AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
659 # [ACTION-SUCCESS], [ACTION-FAILURE])
660 # ------------------------------------------------------------
661 # Check whether the given compiler option works
662 AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
663 [AC_CACHE_CHECK([$1], [$2],
665 save_LDFLAGS="$LDFLAGS"
666 LDFLAGS="$LDFLAGS $3"
667 printf "$lt_simple_link_test_code" > conftest.$ac_ext
668 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
669 # The linker can only warn and ignore the option if not recognized
670 # So say no if there are warnings
671 if test -s conftest.err; then
672 # Append any errors to the config.log.
673 cat conftest.err 1>&AS_MESSAGE_LOG_FD
674 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
675 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
676 if diff conftest.exp conftest.er2 >/dev/null; then
684 LDFLAGS="$save_LDFLAGS"
687 if test x"[$]$2" = xyes; then
688 ifelse([$4], , :, [$4])
690 ifelse([$5], , :, [$5])
692 ])# AC_LIBTOOL_LINKER_OPTION
695 # AC_LIBTOOL_SYS_MAX_CMD_LEN
696 # --------------------------
697 AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
698 [# find the maximum length of command line arguments
699 AC_MSG_CHECKING([the maximum length of command line arguments])
700 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
706 # On DJGPP, this test can blow up pretty badly due to problems in libc
707 # (any single argument exceeding 2000 bytes causes a buffer overrun
708 # during glob expansion). Even if it were fixed, the result of this
709 # check would be larger than it should be.
710 lt_cv_sys_max_cmd_len=12288; # 12K is about right
714 # Under GNU Hurd, this test is not required because there is
715 # no limit to the length of command line arguments.
716 # Libtool will interpret -1 as no limit whatsoever
717 lt_cv_sys_max_cmd_len=-1;
721 # On Win9x/ME, this test blows up -- it succeeds, but takes
722 # about 5 minutes as the teststring grows exponentially.
723 # Worse, since 9x/ME are not pre-emptively multitasking,
724 # you end up with a "frozen" computer, even though with patience
725 # the test eventually succeeds (with a max line length of 256k).
726 # Instead, let's just punt: use the minimum linelength reported by
727 # all of the supported platforms: 8192 (on NT/2K/XP).
728 lt_cv_sys_max_cmd_len=8192;
732 # On AmigaOS with pdksh, this test takes hours, literally.
733 # So we just punt and use a minimum line length of 8192.
734 lt_cv_sys_max_cmd_len=8192;
737 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
738 # This has been around since 386BSD, at least. Likely further.
739 if test -x /sbin/sysctl; then
740 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
741 elif test -x /usr/sbin/sysctl; then
742 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
744 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
746 # And add a safety zone
747 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
748 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
752 # We know the value 262144 and hardcode it with a safety zone (like BSD)
753 lt_cv_sys_max_cmd_len=196608
757 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
758 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
759 # nice to cause kernel panics so lets avoid the loop below.
760 # First set a reasonable default.
761 lt_cv_sys_max_cmd_len=16384
763 if test -x /sbin/sysconfig; then
764 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
765 *1*) lt_cv_sys_max_cmd_len=-1 ;;
770 lt_cv_sys_max_cmd_len=102400
772 sysv5* | sco5v6* | sysv4.2uw2*)
773 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
774 if test -n "$kargmax"; then
775 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
777 lt_cv_sys_max_cmd_len=32768
781 # If test is not a shell built-in, we'll probably end up computing a
782 # maximum length that is only half of the actual maximum length, but
784 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
785 while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
786 = "XX$teststring") >/dev/null 2>&1 &&
787 new_result=`expr "X$teststring" : ".*" 2>&1` &&
788 lt_cv_sys_max_cmd_len=$new_result &&
789 test $i != 17 # 1/2 MB should be enough
792 teststring=$teststring$teststring
795 # Add a significant safety factor because C++ compilers can tack on massive
796 # amounts of additional arguments before passing them to the linker.
797 # It appears as though 1/2 is a usable value.
798 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
802 if test -n $lt_cv_sys_max_cmd_len ; then
803 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
807 ])# AC_LIBTOOL_SYS_MAX_CMD_LEN
812 AC_DEFUN([_LT_AC_CHECK_DLFCN],
813 [AC_CHECK_HEADERS(dlfcn.h)dnl
814 ])# _LT_AC_CHECK_DLFCN
817 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
818 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
819 # ---------------------------------------------------------------------
820 AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
821 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
822 if test "$cross_compiling" = yes; then :
825 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
826 lt_status=$lt_dlunknown
827 cat > conftest.$ac_ext <<EOF
828 [#line __oline__ "configure"
829 #include "confdefs.h"
838 # define LT_DLGLOBAL RTLD_GLOBAL
841 # define LT_DLGLOBAL DL_GLOBAL
843 # define LT_DLGLOBAL 0
847 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
848 find out it does not work in some platform. */
849 #ifndef LT_DLLAZY_OR_NOW
851 # define LT_DLLAZY_OR_NOW RTLD_LAZY
854 # define LT_DLLAZY_OR_NOW DL_LAZY
857 # define LT_DLLAZY_OR_NOW RTLD_NOW
860 # define LT_DLLAZY_OR_NOW DL_NOW
862 # define LT_DLLAZY_OR_NOW 0
870 extern "C" void exit (int);
873 void fnord() { int i=42;}
876 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
877 int status = $lt_dlunknown;
881 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
882 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
883 /* dlclose (self); */
891 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
892 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
895 x$lt_dlno_uscore) $1 ;;
896 x$lt_dlneed_uscore) $2 ;;
897 x$lt_dlunknown|x*) $3 ;;
905 ])# _LT_AC_TRY_DLOPEN_SELF
908 # AC_LIBTOOL_DLOPEN_SELF
909 # ----------------------
910 AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
911 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
912 if test "x$enable_dlopen" != xyes; then
913 enable_dlopen=unknown
914 enable_dlopen_self=unknown
915 enable_dlopen_self_static=unknown
922 lt_cv_dlopen="load_add_on"
924 lt_cv_dlopen_self=yes
928 lt_cv_dlopen="LoadLibrary"
933 lt_cv_dlopen="dlopen"
938 # if libdl is installed we need to link against it
939 AC_CHECK_LIB([dl], [dlopen],
940 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
943 lt_cv_dlopen_self=yes
948 AC_CHECK_FUNC([shl_load],
949 [lt_cv_dlopen="shl_load"],
950 [AC_CHECK_LIB([dld], [shl_load],
951 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
952 [AC_CHECK_FUNC([dlopen],
953 [lt_cv_dlopen="dlopen"],
954 [AC_CHECK_LIB([dl], [dlopen],
955 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
956 [AC_CHECK_LIB([svld], [dlopen],
957 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
958 [AC_CHECK_LIB([dld], [dld_link],
959 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
968 if test "x$lt_cv_dlopen" != xno; then
974 case $lt_cv_dlopen in
976 save_CPPFLAGS="$CPPFLAGS"
977 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
979 save_LDFLAGS="$LDFLAGS"
980 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
983 LIBS="$lt_cv_dlopen_libs $LIBS"
985 AC_CACHE_CHECK([whether a program can dlopen itself],
986 lt_cv_dlopen_self, [dnl
987 _LT_AC_TRY_DLOPEN_SELF(
988 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
989 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
992 if test "x$lt_cv_dlopen_self" = xyes; then
993 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
994 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
995 lt_cv_dlopen_self_static, [dnl
996 _LT_AC_TRY_DLOPEN_SELF(
997 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
998 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1002 CPPFLAGS="$save_CPPFLAGS"
1003 LDFLAGS="$save_LDFLAGS"
1008 case $lt_cv_dlopen_self in
1009 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1010 *) enable_dlopen_self=unknown ;;
1013 case $lt_cv_dlopen_self_static in
1014 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1015 *) enable_dlopen_self_static=unknown ;;
1018 ])# AC_LIBTOOL_DLOPEN_SELF
1021 # AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1022 # ---------------------------------
1023 # Check to see if options -c and -o are simultaneously supported by compiler
1024 AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1025 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1026 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1027 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1028 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1029 $rm -r conftest 2>/dev/null
1033 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1035 lt_compiler_flag="-o out/conftest2.$ac_objext"
1036 # Insert the option either (1) after the last *FLAGS variable, or
1037 # (2) before a word containing "conftest.", or (3) at the end.
1038 # Note that $ac_compile itself does not contain backslashes and begins
1039 # with a dollar sign (not a hyphen), so the echo should work correctly.
1040 lt_compile=`echo "$ac_compile" | $SED \
1041 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1042 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1043 -e 's:$: $lt_compiler_flag:'`
1044 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1045 (eval "$lt_compile" 2>out/conftest.err)
1047 cat out/conftest.err >&AS_MESSAGE_LOG_FD
1048 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1049 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1051 # The compiler can only warn and ignore the option if not recognized
1052 # So say no if there are warnings
1053 $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
1054 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
1055 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1056 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1059 chmod u+w . 2>&AS_MESSAGE_LOG_FD
1061 # SGI C++ compiler will create directory out/ii_files/ for
1062 # template instantiation
1063 test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
1064 $rm out/* && rmdir out
1069 ])# AC_LIBTOOL_PROG_CC_C_O
1072 # AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
1073 # -----------------------------------------
1074 # Check to see if we can do hard links to lock some files if needed
1075 AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
1076 [AC_REQUIRE([_LT_AC_LOCK])dnl
1078 hard_links="nottested"
1079 if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1080 # do not overwrite the value of need_locks provided by the user
1081 AC_MSG_CHECKING([if we can lock with hard links])
1084 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1086 ln conftest.a conftest.b 2>&5 || hard_links=no
1087 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1088 AC_MSG_RESULT([$hard_links])
1089 if test "$hard_links" = no; then
1090 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1096 ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
1101 AC_DEFUN([AC_LIBTOOL_OBJDIR],
1102 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
1103 [rm -f .libs 2>/dev/null
1104 mkdir .libs 2>/dev/null
1105 if test -d .libs; then
1108 # MS-DOS does not allow filenames that begin with a dot.
1111 rmdir .libs 2>/dev/null])
1112 objdir=$lt_cv_objdir
1113 ])# AC_LIBTOOL_OBJDIR
1116 # AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
1117 # ----------------------------------------------
1118 # Check hardcoding attributes.
1119 AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
1120 [AC_MSG_CHECKING([how to hardcode library paths into programs])
1121 _LT_AC_TAGVAR(hardcode_action, $1)=
1122 if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
1123 test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
1124 test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
1126 # We can hardcode non-existant directories.
1127 if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
1128 # If the only mechanism to avoid hardcoding is shlibpath_var, we
1129 # have to relink, otherwise we might link with an installed library
1130 # when we should be linking with a yet-to-be-installed one
1131 ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
1132 test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
1133 # Linking always hardcodes the temporary library directory.
1134 _LT_AC_TAGVAR(hardcode_action, $1)=relink
1136 # We can link without hardcoding, and we can hardcode nonexisting dirs.
1137 _LT_AC_TAGVAR(hardcode_action, $1)=immediate
1140 # We cannot hardcode anything, or else we can only hardcode existing
1142 _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
1144 AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
1146 if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
1147 # Fast installation is not supported
1148 enable_fast_install=no
1149 elif test "$shlibpath_overrides_runpath" = yes ||
1150 test "$enable_shared" = no; then
1151 # Fast installation is not necessary
1152 enable_fast_install=needless
1154 ])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
1157 # AC_LIBTOOL_SYS_LIB_STRIP
1158 # ------------------------
1159 AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
1162 AC_MSG_CHECKING([whether stripping libraries is possible])
1163 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
1164 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
1165 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
1166 AC_MSG_RESULT([yes])
1168 # FIXME - insert some real tests, host_os isn't really good enough
1171 if test -n "$STRIP" ; then
1172 striplib="$STRIP -x"
1173 AC_MSG_RESULT([yes])
1183 ])# AC_LIBTOOL_SYS_LIB_STRIP
1186 # AC_LIBTOOL_SYS_DYNAMIC_LINKER
1187 # -----------------------------
1188 # PORTME Fill in your ld.so characteristics
1189 AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
1190 [AC_MSG_CHECKING([dynamic linker characteristics])
1192 libname_spec='lib$name'
1200 shlibpath_overrides_runpath=unknown
1202 dynamic_linker="$host_os ld.so"
1203 sys_lib_dlsearch_path_spec="/lib /usr/lib"
1204 if test "$GCC" = yes; then
1205 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1206 if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
1207 # if the path contains ";" then we assume it to be the separator
1208 # otherwise default to the standard path separator (i.e. ":") - it is
1209 # assumed that no part of a normal pathname contains ";" but that should
1210 # okay in the real world where ";" in dirpaths is itself problematic.
1211 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1213 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1216 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1218 need_lib_prefix=unknown
1219 hardcode_into_libs=no
1221 # when you set need_version to no, make sure it does not cause -set_version
1222 # flags to be left without arguments
1223 need_version=unknown
1228 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
1229 shlibpath_var=LIBPATH
1231 # AIX 3 has no versioning support, so we append a major version to the name.
1232 soname_spec='${libname}${release}${shared_ext}$major'
1239 hardcode_into_libs=yes
1240 if test "$host_cpu" = ia64; then
1241 # AIX 5 supports IA64
1242 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
1243 shlibpath_var=LD_LIBRARY_PATH
1245 # With GCC up to 2.95.x, collect2 would create an import file
1246 # for dependence libraries. The import file would start with
1247 # the line `#! .'. This would cause the generated library to
1248 # depend on `.', always an invalid library. This was fixed in
1249 # development snapshots of GCC prior to 3.0.
1251 aix4 | aix4.[[01]] | aix4.[[01]].*)
1252 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
1254 echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
1261 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
1262 # soname into executable. Probably we can add versioning support to
1263 # collect2, so additional links can be useful in future.
1264 if test "$aix_use_runtimelinking" = yes; then
1265 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
1266 # instead of lib<name>.a to let people know that these are not
1267 # typical AIX shared libraries.
1268 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1270 # We preserve .a as extension for shared libraries through AIX4.2
1271 # and later when we are not doing run time linking.
1272 library_names_spec='${libname}${release}.a $libname.a'
1273 soname_spec='${libname}${release}${shared_ext}$major'
1275 shlibpath_var=LIBPATH
1280 library_names_spec='$libname.ixlibrary $libname.a'
1281 # Create ${libname}_ixlibrary.a entries in /sys/libs.
1282 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'
1286 library_names_spec='${libname}${shared_ext}'
1287 dynamic_linker="$host_os ld.so"
1288 shlibpath_var=LIBRARY_PATH
1294 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1295 soname_spec='${libname}${release}${shared_ext}$major'
1296 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
1297 shlibpath_var=LD_LIBRARY_PATH
1298 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
1299 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
1300 # the default ld.so.conf also contains /usr/contrib/lib and
1301 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
1302 # libtool to hard-code these into programs
1305 cygwin* | mingw* | pw32*)
1306 version_type=windows
1311 case $GCC,$host_os in
1312 yes,cygwin* | yes,mingw* | yes,pw32*)
1313 library_names_spec='$libname.dll.a'
1314 # DLL is installed to $(libdir)/../bin by postinstall_cmds
1315 postinstall_cmds='base_file=`basename \${file}`~
1316 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
1317 dldir=$destdir/`dirname \$dlpath`~
1318 test -d \$dldir || mkdir -p \$dldir~
1319 $install_prog $dir/$dlname \$dldir/$dlname~
1320 chmod a+x \$dldir/$dlname'
1321 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
1322 dlpath=$dir/\$dldll~
1324 shlibpath_overrides_runpath=yes
1328 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
1329 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1330 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
1333 # MinGW DLLs use traditional 'lib' prefix
1334 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1335 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1336 if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
1337 # It is most probably a Windows format PATH printed by
1338 # mingw gcc, but we are running on Cygwin. Gcc prints its search
1339 # path with ; separators, and with drive letters. We can handle the
1340 # drive letters (cygwin fileutils understands them), so leave them,
1341 # especially as we might pass files found there to a mingw objdump,
1342 # which wouldn't understand a cygwinified path. Ahh.
1343 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1345 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1349 # pw32 DLLs use 'pw' prefix rather than 'lib'
1350 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1356 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
1359 dynamic_linker='Win32 ld.exe'
1360 # FIXME: first we should search . and the directory the executable is in
1364 darwin* | rhapsody*)
1365 dynamic_linker="$host_os dyld"
1369 library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
1370 soname_spec='${libname}${release}${major}$shared_ext'
1371 shlibpath_overrides_runpath=yes
1372 shlibpath_var=DYLD_LIBRARY_PATH
1373 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
1374 # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
1375 if test "$GCC" = yes; then
1376 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"`
1378 sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
1380 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
1387 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
1388 soname_spec='${libname}${release}${shared_ext}$major'
1389 shlibpath_var=LD_LIBRARY_PATH
1400 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1401 soname_spec='${libname}${release}${shared_ext}$major'
1402 shlibpath_var=LD_LIBRARY_PATH
1403 shlibpath_overrides_runpath=no
1404 hardcode_into_libs=yes
1405 dynamic_linker='GNU ld.so'
1408 freebsd* | dragonfly*)
1409 # DragonFly does not have aout. When/if they implement a new
1410 # versioning mechanism, adjust this.
1411 if test -x /usr/bin/objformat; then
1412 objformat=`/usr/bin/objformat`
1415 freebsd[[123]]*) objformat=aout ;;
1419 version_type=freebsd-$objformat
1420 case $version_type in
1422 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
1427 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
1431 shlibpath_var=LD_LIBRARY_PATH
1434 shlibpath_overrides_runpath=yes
1436 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
1437 shlibpath_overrides_runpath=yes
1438 hardcode_into_libs=yes
1440 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
1441 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
1442 shlibpath_overrides_runpath=no
1443 hardcode_into_libs=yes
1445 freebsd*) # from 4.6 on
1446 shlibpath_overrides_runpath=yes
1447 hardcode_into_libs=yes
1456 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
1457 soname_spec='${libname}${release}${shared_ext}$major'
1458 shlibpath_var=LD_LIBRARY_PATH
1459 hardcode_into_libs=yes
1462 hpux9* | hpux10* | hpux11*)
1463 # Give a soname corresponding to the major version so that dld.sl refuses to
1464 # link against other versions.
1471 hardcode_into_libs=yes
1472 dynamic_linker="$host_os dld.so"
1473 shlibpath_var=LD_LIBRARY_PATH
1474 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
1475 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1476 soname_spec='${libname}${release}${shared_ext}$major'
1477 if test "X$HPUX_IA64_MODE" = X32; then
1478 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
1480 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
1482 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1486 hardcode_into_libs=yes
1487 dynamic_linker="$host_os dld.sl"
1488 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
1489 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
1490 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1491 soname_spec='${libname}${release}${shared_ext}$major'
1492 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
1493 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1497 dynamic_linker="$host_os dld.sl"
1498 shlibpath_var=SHLIB_PATH
1499 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
1500 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1501 soname_spec='${libname}${release}${shared_ext}$major'
1504 # HP-UX runs *really* slowly unless shared libraries are mode 555.
1505 postinstall_cmds='chmod 555 $lib'
1512 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1513 soname_spec='${libname}${release}${shared_ext}$major'
1514 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
1515 shlibpath_var=LD_LIBRARY_PATH
1516 shlibpath_overrides_runpath=no
1517 hardcode_into_libs=yes
1520 irix5* | irix6* | nonstopux*)
1522 nonstopux*) version_type=nonstopux ;;
1524 if test "$lt_cv_prog_gnu_ld" = yes; then
1532 soname_spec='${libname}${release}${shared_ext}$major'
1533 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
1535 irix5* | nonstopux*)
1539 case $LD in # libtool.m4 will add one of these switches to LD
1540 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
1541 libsuff= shlibsuff= libmagic=32-bit;;
1542 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
1543 libsuff=32 shlibsuff=N32 libmagic=N32;;
1544 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
1545 libsuff=64 shlibsuff=64 libmagic=64-bit;;
1546 *) libsuff= shlibsuff= libmagic=never-match;;
1550 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
1551 shlibpath_overrides_runpath=no
1552 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
1553 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
1554 hardcode_into_libs=yes
1557 # No shared lib support for Linux oldld, aout, or coff.
1558 linux*oldld* | linux*aout* | linux*coff*)
1562 # This must be Linux ELF.
1567 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1568 soname_spec='${libname}${release}${shared_ext}$major'
1569 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
1570 shlibpath_var=LD_LIBRARY_PATH
1571 shlibpath_overrides_runpath=no
1572 # This implies no fast_install, which is unacceptable.
1573 # Some rework will be needed to allow for fast_install
1574 # before this can be enabled.
1575 hardcode_into_libs=yes
1577 # find out which ABI we are using
1580 x86_64*|s390x*|powerpc64*)
1581 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1582 if AC_TRY_EVAL(ac_compile); then
1583 case `/usr/bin/file conftest.$ac_objext` in
1586 sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
1594 # Append ld.so.conf contents to the search path
1595 if test -f /etc/ld.so.conf; then
1596 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' ' '`
1597 sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
1600 # We used to test for /lib/ld.so.1 and disable shared libraries on
1601 # powerpc, because MkLinux only supported shared libraries with the
1602 # GNU dynamic linker. Since this was broken with cross compilers,
1603 # most powerpc-linux boxes support dynamic linking these days and
1604 # people can always --disable-shared, the test was removed, and we
1605 # assume the GNU/Linux dynamic linker is in use.
1606 dynamic_linker='GNU/Linux ld.so'
1613 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1614 soname_spec='${libname}${release}${shared_ext}$major'
1615 shlibpath_var=LD_LIBRARY_PATH
1616 shlibpath_overrides_runpath=no
1617 hardcode_into_libs=yes
1618 dynamic_linker='GNU ld.so'
1625 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
1626 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1627 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1628 dynamic_linker='NetBSD (a.out) ld.so'
1630 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1631 soname_spec='${libname}${release}${shared_ext}$major'
1632 dynamic_linker='NetBSD ld.elf_so'
1634 shlibpath_var=LD_LIBRARY_PATH
1635 shlibpath_overrides_runpath=yes
1636 hardcode_into_libs=yes
1641 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1642 shlibpath_var=LD_LIBRARY_PATH
1643 shlibpath_overrides_runpath=yes
1650 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1651 soname_spec='${libname}${release}${shared_ext}$major'
1652 shlibpath_var=LD_LIBRARY_PATH
1653 shlibpath_overrides_runpath=yes
1658 sys_lib_dlsearch_path_spec="/usr/lib"
1660 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
1662 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
1663 *) need_version=no ;;
1665 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1666 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1667 shlibpath_var=LD_LIBRARY_PATH
1668 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
1670 openbsd2.[[89]] | openbsd2.[[89]].*)
1671 shlibpath_overrides_runpath=no
1674 shlibpath_overrides_runpath=yes
1678 shlibpath_overrides_runpath=yes
1683 libname_spec='$name'
1686 library_names_spec='$libname${shared_ext} $libname.a'
1687 dynamic_linker='OS/2 ld.exe'
1688 shlibpath_var=LIBPATH
1691 osf3* | osf4* | osf5*)
1695 soname_spec='${libname}${release}${shared_ext}$major'
1696 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1697 shlibpath_var=LD_LIBRARY_PATH
1698 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
1699 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
1706 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1707 soname_spec='${libname}${release}${shared_ext}$major'
1708 shlibpath_var=LD_LIBRARY_PATH
1709 shlibpath_overrides_runpath=yes
1710 hardcode_into_libs=yes
1711 # ldd complains unless libraries are executable
1712 postinstall_cmds='chmod +x $lib'
1717 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1718 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
1719 shlibpath_var=LD_LIBRARY_PATH
1720 shlibpath_overrides_runpath=yes
1721 if test "$with_gnu_ld" = yes; then
1729 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1730 soname_spec='${libname}${release}${shared_ext}$major'
1731 shlibpath_var=LD_LIBRARY_PATH
1732 case $host_vendor in
1734 shlibpath_overrides_runpath=no
1736 export_dynamic_flag_spec='${wl}-Blargedynsym'
1737 runpath_var=LD_RUN_PATH
1745 shlibpath_overrides_runpath=no
1746 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
1752 if test -d /usr/nec ;then
1754 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
1755 soname_spec='$libname${shared_ext}.$major'
1756 shlibpath_var=LD_LIBRARY_PATH
1760 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
1761 version_type=freebsd-elf
1764 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
1765 soname_spec='${libname}${release}${shared_ext}$major'
1766 shlibpath_var=LD_LIBRARY_PATH
1767 hardcode_into_libs=yes
1768 if test "$with_gnu_ld" = yes; then
1769 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
1770 shlibpath_overrides_runpath=no
1772 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
1773 shlibpath_overrides_runpath=yes
1776 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
1780 sys_lib_dlsearch_path_spec='/usr/lib'
1785 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1786 soname_spec='${libname}${release}${shared_ext}$major'
1787 shlibpath_var=LD_LIBRARY_PATH
1794 AC_MSG_RESULT([$dynamic_linker])
1795 test "$dynamic_linker" = no && can_build_shared=no
1797 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
1798 if test "$GCC" = yes; then
1799 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
1801 ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
1806 AC_DEFUN([_LT_AC_TAGCONFIG],
1807 [AC_ARG_WITH([tags],
1808 [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
1809 [include additional configurations @<:@automatic@:>@])],
1810 [tagnames="$withval"])
1812 if test -f "$ltmain" && test -n "$tagnames"; then
1813 if test ! -f "${ofile}"; then
1814 AC_MSG_WARN([output file `$ofile' does not exist])
1817 if test -z "$LTCC"; then
1818 eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
1819 if test -z "$LTCC"; then
1820 AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
1822 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
1825 if test -z "$LTCFLAGS"; then
1826 eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
1829 # Extract list of available tagged configurations in $ofile.
1830 # Note that this assumes the entire list is on one line.
1831 available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
1833 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
1834 for tagname in $tagnames; do
1836 # Check whether tagname contains only valid characters
1837 case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
1839 *) AC_MSG_ERROR([invalid tag name: $tagname])
1843 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
1845 AC_MSG_ERROR([tag name \"$tagname\" already exists])
1848 # Update the list of available tags.
1849 if test -n "$tagname"; then
1850 echo appending configuration tag \"$tagname\" to $ofile
1854 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
1855 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
1856 (test "X$CXX" != "Xg++"))) ; then
1857 AC_LIBTOOL_LANG_CXX_CONFIG
1864 if test -n "$F77" && test "X$F77" != "Xno"; then
1865 AC_LIBTOOL_LANG_F77_CONFIG
1872 if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
1873 AC_LIBTOOL_LANG_GCJ_CONFIG
1880 AC_LIBTOOL_LANG_RC_CONFIG
1884 AC_MSG_ERROR([Unsupported tag name: $tagname])
1888 # Append the new tag name to the list of available tags.
1889 if test -n "$tagname" ; then
1890 available_tags="$available_tags $tagname"
1896 # Now substitute the updated list of available tags.
1897 if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
1898 mv "${ofile}T" "$ofile"
1902 AC_MSG_ERROR([unable to update list of available tagged configurations.])
1905 ])# _LT_AC_TAGCONFIG
1910 # enable checks for dlopen support
1911 AC_DEFUN([AC_LIBTOOL_DLOPEN],
1912 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
1913 ])# AC_LIBTOOL_DLOPEN
1916 # AC_LIBTOOL_WIN32_DLL
1917 # --------------------
1918 # declare package support for building win32 DLLs
1919 AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
1920 [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
1921 ])# AC_LIBTOOL_WIN32_DLL
1924 # AC_ENABLE_SHARED([DEFAULT])
1925 # ---------------------------
1926 # implement the --enable-shared flag
1927 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
1928 AC_DEFUN([AC_ENABLE_SHARED],
1929 [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
1930 AC_ARG_ENABLE([shared],
1931 [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
1932 [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
1933 [p=${PACKAGE-default}
1935 yes) enable_shared=yes ;;
1936 no) enable_shared=no ;;
1939 # Look at the argument we got. We use all the common list separators.
1940 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
1941 for pkg in $enableval; do
1943 if test "X$pkg" = "X$p"; then
1950 [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
1951 ])# AC_ENABLE_SHARED
1956 # set the default shared flag to --disable-shared
1957 AC_DEFUN([AC_DISABLE_SHARED],
1958 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
1959 AC_ENABLE_SHARED(no)
1960 ])# AC_DISABLE_SHARED
1963 # AC_ENABLE_STATIC([DEFAULT])
1964 # ---------------------------
1965 # implement the --enable-static flag
1966 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
1967 AC_DEFUN([AC_ENABLE_STATIC],
1968 [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
1969 AC_ARG_ENABLE([static],
1970 [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
1971 [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
1972 [p=${PACKAGE-default}
1974 yes) enable_static=yes ;;
1975 no) enable_static=no ;;
1978 # Look at the argument we got. We use all the common list separators.
1979 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
1980 for pkg in $enableval; do
1982 if test "X$pkg" = "X$p"; then
1989 [enable_static=]AC_ENABLE_STATIC_DEFAULT)
1990 ])# AC_ENABLE_STATIC
1995 # set the default static flag to --disable-static
1996 AC_DEFUN([AC_DISABLE_STATIC],
1997 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
1998 AC_ENABLE_STATIC(no)
1999 ])# AC_DISABLE_STATIC
2002 # AC_ENABLE_FAST_INSTALL([DEFAULT])
2003 # ---------------------------------
2004 # implement the --enable-fast-install flag
2005 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2006 AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2007 [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2008 AC_ARG_ENABLE([fast-install],
2009 [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2010 [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2011 [p=${PACKAGE-default}
2013 yes) enable_fast_install=yes ;;
2014 no) enable_fast_install=no ;;
2016 enable_fast_install=no
2017 # Look at the argument we got. We use all the common list separators.
2018 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2019 for pkg in $enableval; do
2021 if test "X$pkg" = "X$p"; then
2022 enable_fast_install=yes
2028 [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2029 ])# AC_ENABLE_FAST_INSTALL
2032 # AC_DISABLE_FAST_INSTALL
2033 # -----------------------
2034 # set the default to --disable-fast-install
2035 AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2036 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2037 AC_ENABLE_FAST_INSTALL(no)
2038 ])# AC_DISABLE_FAST_INSTALL
2041 # AC_LIBTOOL_PICMODE([MODE])
2042 # --------------------------
2043 # implement the --with-pic flag
2044 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
2045 AC_DEFUN([AC_LIBTOOL_PICMODE],
2046 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2047 pic_mode=ifelse($#,1,$1,default)
2048 ])# AC_LIBTOOL_PICMODE
2053 # This is predefined starting with Autoconf 2.54, so this conditional
2054 # definition can be removed once we require Autoconf 2.54 or later.
2055 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
2056 [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
2057 [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2058 then ac_cv_prog_egrep='grep -E'
2059 else ac_cv_prog_egrep='egrep'
2061 EGREP=$ac_cv_prog_egrep
2066 # AC_PATH_TOOL_PREFIX
2067 # -------------------
2068 # find a file program which can recognise shared library
2069 AC_DEFUN([AC_PATH_TOOL_PREFIX],
2070 [AC_REQUIRE([AC_PROG_EGREP])dnl
2071 AC_MSG_CHECKING([for $1])
2072 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2074 [[\\/*] | ?:[\\/]*])
2075 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2078 lt_save_MAGIC_CMD="$MAGIC_CMD"
2079 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2080 dnl $ac_dummy forces splitting on constant user-supplied paths.
2081 dnl POSIX.2 word splitting is done only on the output of word expansions,
2082 dnl not every word. This closes a longstanding sh security hole.
2083 ac_dummy="ifelse([$2], , $PATH, [$2])"
2084 for ac_dir in $ac_dummy; do
2086 test -z "$ac_dir" && ac_dir=.
2087 if test -f $ac_dir/$1; then
2088 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2089 if test -n "$file_magic_test_file"; then
2090 case $deplibs_check_method in
2092 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
2093 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2094 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2095 $EGREP "$file_magic_regex" > /dev/null; then
2100 *** Warning: the command libtool uses to detect shared libraries,
2101 *** $file_magic_cmd, produces output that libtool cannot recognize.
2102 *** The result is that libtool may fail to recognize shared libraries
2103 *** as such. This will affect the creation of libtool libraries that
2104 *** depend on shared libraries, but programs linked with such libtool
2105 *** libraries will work regardless of this problem. Nevertheless, you
2106 *** may want to report the problem to your system manager and/or to
2107 *** bug-libtool@gnu.org
2117 MAGIC_CMD="$lt_save_MAGIC_CMD"
2120 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2121 if test -n "$MAGIC_CMD"; then
2122 AC_MSG_RESULT($MAGIC_CMD)
2126 ])# AC_PATH_TOOL_PREFIX
2131 # find a file program which can recognise a shared library
2132 AC_DEFUN([AC_PATH_MAGIC],
2133 [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2134 if test -z "$lt_cv_path_MAGIC_CMD"; then
2135 if test -n "$ac_tool_prefix"; then
2136 AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2146 # find the pathname to the GNU or non-GNU linker
2147 AC_DEFUN([AC_PROG_LD],
2148 [AC_ARG_WITH([gnu-ld],
2149 [AC_HELP_STRING([--with-gnu-ld],
2150 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
2151 [test "$withval" = no || with_gnu_ld=yes],
2153 AC_REQUIRE([LT_AC_PROG_SED])dnl
2154 AC_REQUIRE([AC_PROG_CC])dnl
2155 AC_REQUIRE([AC_CANONICAL_HOST])dnl
2156 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2158 if test "$GCC" = yes; then
2159 # Check if gcc -print-prog-name=ld gives a path.
2160 AC_MSG_CHECKING([for ld used by $CC])
2163 # gcc leaves a trailing carriage return which upsets mingw
2164 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2166 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2169 # Accept absolute paths.
2170 [[\\/]]* | ?:[[\\/]]*)
2171 re_direlt='/[[^/]][[^/]]*/\.\./'
2172 # Canonicalize the pathname of ld
2173 ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
2174 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2175 ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
2177 test -z "$LD" && LD="$ac_prog"
2180 # If it fails, then pretend we aren't using GCC.
2184 # If it is relative, then search for the first ld in PATH.
2188 elif test "$with_gnu_ld" = yes; then
2189 AC_MSG_CHECKING([for GNU ld])
2191 AC_MSG_CHECKING([for non-GNU ld])
2193 AC_CACHE_VAL(lt_cv_path_LD,
2194 [if test -z "$LD"; then
2195 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2196 for ac_dir in $PATH; do
2198 test -z "$ac_dir" && ac_dir=.
2199 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2200 lt_cv_path_LD="$ac_dir/$ac_prog"
2201 # Check to see if the program is GNU ld. I'd rather use --version,
2202 # but apparently some variants of GNU ld only accept -v.
2203 # Break only if it was the GNU/non-GNU ld that we prefer.
2204 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
2205 *GNU* | *'with BFD'*)
2206 test "$with_gnu_ld" != no && break
2209 test "$with_gnu_ld" != yes && break
2216 lt_cv_path_LD="$LD" # Let the user override the test with a path.
2219 if test -n "$LD"; then
2224 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
2231 AC_DEFUN([AC_PROG_LD_GNU],
2232 [AC_REQUIRE([AC_PROG_EGREP])dnl
2233 AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
2234 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
2235 case `$LD -v 2>&1 </dev/null` in
2236 *GNU* | *'with BFD'*)
2237 lt_cv_prog_gnu_ld=yes
2240 lt_cv_prog_gnu_ld=no
2243 with_gnu_ld=$lt_cv_prog_gnu_ld
2247 # AC_PROG_LD_RELOAD_FLAG
2248 # ----------------------
2249 # find reload flag for linker
2250 # -- PORTME Some linkers may need a different reload flag.
2251 AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
2252 [AC_CACHE_CHECK([for $LD option to reload object files],
2253 lt_cv_ld_reload_flag,
2254 [lt_cv_ld_reload_flag='-r'])
2255 reload_flag=$lt_cv_ld_reload_flag
2256 case $reload_flag in
2258 *) reload_flag=" $reload_flag" ;;
2260 reload_cmds='$LD$reload_flag -o $output$reload_objs'
2263 if test "$GCC" = yes; then
2264 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
2266 reload_cmds='$LD$reload_flag -o $output$reload_objs'
2270 ])# AC_PROG_LD_RELOAD_FLAG
2273 # AC_DEPLIBS_CHECK_METHOD
2274 # -----------------------
2275 # how to check for library dependencies
2276 # -- PORTME fill in with the dynamic library characteristics
2277 AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
2278 [AC_CACHE_CHECK([how to recognise dependent libraries],
2279 lt_cv_deplibs_check_method,
2280 [lt_cv_file_magic_cmd='$MAGIC_CMD'
2281 lt_cv_file_magic_test_file=
2282 lt_cv_deplibs_check_method='unknown'
2283 # Need to set the preceding variable on all platforms that support
2284 # interlibrary dependencies.
2285 # 'none' -- dependencies not supported.
2286 # `unknown' -- same as none, but documents that we really don't know.
2287 # 'pass_all' -- all dependencies passed with no checks.
2288 # 'test_compile' -- check by making test program.
2289 # 'file_magic [[regex]]' -- check by looking for files in library path
2290 # which responds to the $file_magic_cmd with a given extended regex.
2291 # If you have `file' or equivalent on your system and you're not sure
2292 # whether `pass_all' will *always* work, you probably want this one.
2296 lt_cv_deplibs_check_method=pass_all
2300 lt_cv_deplibs_check_method=pass_all
2304 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
2305 lt_cv_file_magic_cmd='/usr/bin/file -L'
2306 lt_cv_file_magic_test_file=/shlib/libc.so
2310 # func_win32_libid is a shell function defined in ltmain.sh
2311 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
2312 lt_cv_file_magic_cmd='func_win32_libid'
2316 # Base MSYS/MinGW do not provide the 'file' command needed by
2317 # func_win32_libid shell function, so use a weaker test based on 'objdump'.
2318 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
2319 lt_cv_file_magic_cmd='$OBJDUMP -f'
2322 darwin* | rhapsody*)
2323 lt_cv_deplibs_check_method=pass_all
2326 freebsd* | kfreebsd*-gnu | dragonfly*)
2327 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2330 # Not sure whether the presence of OpenBSD here was a mistake.
2331 # Let's accept both of them until this is cleared up.
2332 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
2333 lt_cv_file_magic_cmd=/usr/bin/file
2334 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
2338 lt_cv_deplibs_check_method=pass_all
2343 lt_cv_deplibs_check_method=pass_all
2346 hpux10.20* | hpux11*)
2347 lt_cv_file_magic_cmd=/usr/bin/file
2350 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
2351 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
2354 [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]']
2355 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
2358 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
2359 lt_cv_file_magic_test_file=/usr/lib/libc.sl
2365 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
2366 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
2369 irix5* | irix6* | nonstopux*)
2371 *-32|*"-32 ") libmagic=32-bit;;
2372 *-n32|*"-n32 ") libmagic=N32;;
2373 *-64|*"-64 ") libmagic=64-bit;;
2374 *) libmagic=never-match;;
2376 lt_cv_deplibs_check_method=pass_all
2379 # This must be Linux ELF.
2381 lt_cv_deplibs_check_method=pass_all
2385 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2386 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
2388 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
2393 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
2394 lt_cv_file_magic_cmd=/usr/bin/file
2395 lt_cv_file_magic_test_file=/usr/lib/libnls.so
2399 lt_cv_deplibs_check_method=unknown
2403 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2404 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
2406 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
2410 osf3* | osf4* | osf5*)
2411 lt_cv_deplibs_check_method=pass_all
2415 lt_cv_deplibs_check_method=pass_all
2419 case $host_vendor in
2421 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]]'
2422 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
2425 lt_cv_deplibs_check_method=pass_all
2428 lt_cv_file_magic_cmd='/bin/file'
2429 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
2432 lt_cv_file_magic_cmd='/bin/file'
2433 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
2434 lt_cv_file_magic_test_file=/lib/libc.so
2437 lt_cv_deplibs_check_method=pass_all
2440 lt_cv_deplibs_check_method=pass_all
2445 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2446 lt_cv_deplibs_check_method=pass_all
2450 file_magic_cmd=$lt_cv_file_magic_cmd
2451 deplibs_check_method=$lt_cv_deplibs_check_method
2452 test -z "$deplibs_check_method" && deplibs_check_method=unknown
2453 ])# AC_DEPLIBS_CHECK_METHOD
2458 # find the pathname to a BSD-compatible name lister
2459 AC_DEFUN([AC_PROG_NM],
2460 [AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
2461 [if test -n "$NM"; then
2462 # Let the user override the test.
2465 lt_nm_to_check="${ac_tool_prefix}nm"
2466 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
2467 lt_nm_to_check="$lt_nm_to_check nm"
2469 for lt_tmp_nm in $lt_nm_to_check; do
2470 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2471 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
2473 test -z "$ac_dir" && ac_dir=.
2474 tmp_nm="$ac_dir/$lt_tmp_nm"
2475 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
2476 # Check to see if the nm accepts a BSD-compat flag.
2477 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2478 # nm: unknown option "B" ignored
2479 # Tru64's nm complains that /dev/null is an invalid object file
2480 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
2481 */dev/null* | *'Invalid file or object type'*)
2482 lt_cv_path_NM="$tmp_nm -B"
2486 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
2488 lt_cv_path_NM="$tmp_nm -p"
2492 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
2493 continue # so that we can try to find one that supports BSD flags
2502 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
2510 # check for math library
2511 AC_DEFUN([AC_CHECK_LIBM],
2512 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2515 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
2516 # These system don't have libm, or don't need it
2519 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
2520 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
2523 AC_CHECK_LIB(m, cos, LIBM="-lm")
2529 # AC_LIBLTDL_CONVENIENCE([DIRECTORY])
2530 # -----------------------------------
2531 # sets LIBLTDL to the link flags for the libltdl convenience library and
2532 # LTDLINCL to the include flags for the libltdl header and adds
2533 # --enable-ltdl-convenience to the configure arguments. Note that
2534 # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
2535 # it is assumed to be `libltdl'. LIBLTDL will be prefixed with
2536 # '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
2537 # (note the single quotes!). If your package is not flat and you're not
2538 # using automake, define top_builddir and top_srcdir appropriately in
2540 AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
2541 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2542 case $enable_ltdl_convenience in
2543 no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
2544 "") enable_ltdl_convenience=yes
2545 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
2547 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libbase'])/libltdlc.la
2548 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
2549 # For backwards non-gettext consistent compatibility...
2551 ])# AC_LIBLTDL_CONVENIENCE
2554 # AC_LIBLTDL_INSTALLABLE([DIRECTORY])
2555 # -----------------------------------
2556 # sets LIBLTDL to the link flags for the libltdl installable library and
2557 # LTDLINCL to the include flags for the libltdl header and adds
2558 # --enable-ltdl-install to the configure arguments. Note that
2559 # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
2560 # and an installed libltdl is not found, it is assumed to be `libltdl'.
2561 # LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
2562 # '${top_srcdir}/' (note the single quotes!). If your package is not
2563 # flat and you're not using automake, define top_builddir and top_srcdir
2564 # appropriately in the Makefiles.
2565 # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
2566 AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
2567 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2568 AC_CHECK_LIB(ltdl, lt_dlinit,
2569 [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
2570 [if test x"$enable_ltdl_install" = xno; then
2571 AC_MSG_WARN([libltdl not installed, but installation disabled])
2573 enable_ltdl_install=yes
2576 if test x"$enable_ltdl_install" = x"yes"; then
2577 ac_configure_args="$ac_configure_args --enable-ltdl-install"
2578 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libbase'])/libltdl.la
2579 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
2581 ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
2585 # For backwards non-gettext consistent compatibility...
2587 ])# AC_LIBLTDL_INSTALLABLE
2592 # enable support for C++ libraries
2593 AC_DEFUN([AC_LIBTOOL_CXX],
2594 [AC_REQUIRE([_LT_AC_LANG_CXX])
2600 AC_DEFUN([_LT_AC_LANG_CXX],
2601 [AC_REQUIRE([AC_PROG_CXX])
2602 AC_REQUIRE([_LT_AC_PROG_CXXCPP])
2603 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
2606 # _LT_AC_PROG_CXXCPP
2607 # ------------------
2608 AC_DEFUN([_LT_AC_PROG_CXXCPP],
2610 AC_REQUIRE([AC_PROG_CXX])
2611 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2612 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2613 (test "X$CXX" != "Xg++"))) ; then
2616 ])# _LT_AC_PROG_CXXCPP
2620 # enable support for Fortran 77 libraries
2621 AC_DEFUN([AC_LIBTOOL_F77],
2622 [AC_REQUIRE([_LT_AC_LANG_F77])
2628 AC_DEFUN([_LT_AC_LANG_F77],
2629 [AC_REQUIRE([AC_PROG_F77])
2630 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
2636 # enable support for GCJ libraries
2637 AC_DEFUN([AC_LIBTOOL_GCJ],
2638 [AC_REQUIRE([_LT_AC_LANG_GCJ])
2644 AC_DEFUN([_LT_AC_LANG_GCJ],
2645 [AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
2646 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
2647 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
2648 [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
2649 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
2650 [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
2651 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
2657 # enable support for Windows resource files
2658 AC_DEFUN([AC_LIBTOOL_RC],
2659 [AC_REQUIRE([LT_AC_PROG_RC])
2660 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
2664 # AC_LIBTOOL_LANG_C_CONFIG
2665 # ------------------------
2666 # Ensure that the configuration vars for the C compiler are
2667 # suitably defined. Those variables are subsequently used by
2668 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
2669 AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
2670 AC_DEFUN([_LT_AC_LANG_C_CONFIG],
2674 # Source file extension for C test sources.
2677 # Object file extension for compiled C test sources.
2679 _LT_AC_TAGVAR(objext, $1)=$objext
2681 # Code to be used in simple compile tests
2682 lt_simple_compile_test_code="int some_variable = 0;\n"
2684 # Code to be used in simple link tests
2685 lt_simple_link_test_code='int main(){return(0);}\n'
2689 # save warnings/boilerplate of simple test code
2690 _LT_COMPILER_BOILERPLATE
2691 _LT_LINKER_BOILERPLATE
2694 ## There is no encapsulation within the following macros, do not change
2695 ## the running order or otherwise move them around unless you know exactly
2696 ## what you are doing...
2697 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
2698 AC_LIBTOOL_PROG_COMPILER_PIC($1)
2699 AC_LIBTOOL_PROG_CC_C_O($1)
2700 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
2701 AC_LIBTOOL_PROG_LD_SHLIBS($1)
2702 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
2703 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
2704 AC_LIBTOOL_SYS_LIB_STRIP
2705 AC_LIBTOOL_DLOPEN_SELF
2707 # Report which library types will actually be built
2708 AC_MSG_CHECKING([if libtool supports shared libraries])
2709 AC_MSG_RESULT([$can_build_shared])
2711 AC_MSG_CHECKING([whether to build shared libraries])
2712 test "$can_build_shared" = "no" && enable_shared=no
2714 # On AIX, shared libraries and static libraries use the same namespace, and
2715 # are all built from PIC.
2718 test "$enable_shared" = yes && enable_static=no
2719 if test -n "$RANLIB"; then
2720 archive_cmds="$archive_cmds~\$RANLIB \$lib"
2721 postinstall_cmds='$RANLIB $lib'
2726 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
2727 test "$enable_shared" = yes && enable_static=no
2731 AC_MSG_RESULT([$enable_shared])
2733 AC_MSG_CHECKING([whether to build static libraries])
2734 # Make sure either enable_shared or enable_static is yes.
2735 test "$enable_shared" = yes || enable_static=yes
2736 AC_MSG_RESULT([$enable_static])
2738 AC_LIBTOOL_CONFIG($1)
2742 ])# AC_LIBTOOL_LANG_C_CONFIG
2745 # AC_LIBTOOL_LANG_CXX_CONFIG
2746 # --------------------------
2747 # Ensure that the configuration vars for the C compiler are
2748 # suitably defined. Those variables are subsequently used by
2749 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
2750 AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
2751 AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
2753 AC_REQUIRE([AC_PROG_CXX])
2754 AC_REQUIRE([_LT_AC_PROG_CXXCPP])
2756 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
2757 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
2758 _LT_AC_TAGVAR(always_export_symbols, $1)=no
2759 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
2760 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
2761 _LT_AC_TAGVAR(hardcode_direct, $1)=no
2762 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
2763 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
2764 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
2765 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
2766 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2767 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
2768 _LT_AC_TAGVAR(module_cmds, $1)=
2769 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
2770 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
2771 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
2772 _LT_AC_TAGVAR(no_undefined_flag, $1)=
2773 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
2774 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
2776 # Dependencies to place before and after the object being linked:
2777 _LT_AC_TAGVAR(predep_objects, $1)=
2778 _LT_AC_TAGVAR(postdep_objects, $1)=
2779 _LT_AC_TAGVAR(predeps, $1)=
2780 _LT_AC_TAGVAR(postdeps, $1)=
2781 _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
2783 # Source file extension for C++ test sources.
2786 # Object file extension for compiled C++ test sources.
2788 _LT_AC_TAGVAR(objext, $1)=$objext
2790 # Code to be used in simple compile tests
2791 lt_simple_compile_test_code="int some_variable = 0;\n"
2793 # Code to be used in simple link tests
2794 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }\n'
2796 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
2799 # save warnings/boilerplate of simple test code
2800 _LT_COMPILER_BOILERPLATE
2801 _LT_LINKER_BOILERPLATE
2803 # Allow CC to be a program name with arguments.
2808 lt_save_with_gnu_ld=$with_gnu_ld
2809 lt_save_path_LD=$lt_cv_path_LD
2810 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
2811 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
2813 $as_unset lt_cv_prog_gnu_ld
2815 if test -n "${lt_cv_path_LDCXX+set}"; then
2816 lt_cv_path_LD=$lt_cv_path_LDCXX
2818 $as_unset lt_cv_path_LD
2820 test -z "${LDCXX+set}" || LD=$LDCXX
2823 _LT_AC_TAGVAR(compiler, $1)=$CC
2824 _LT_CC_BASENAME([$compiler])
2826 # We don't want -fno-exception wen compiling C++ code, so set the
2827 # no_builtin_flag separately
2828 if test "$GXX" = yes; then
2829 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
2831 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
2834 if test "$GXX" = yes; then
2835 # Set up default GNU C++ configuration
2839 # Check if GNU C++ uses GNU ld as the underlying linker, since the
2840 # archiving commands below assume that GNU ld is being used.
2841 if test "$with_gnu_ld" = yes; then
2842 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
2843 _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'
2845 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
2846 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
2848 # If archive_cmds runs LD, not CC, wlarc should be empty
2849 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
2850 # investigate it a little bit more. (MM)
2853 # ancient GNU ld didn't support --whole-archive et. al.
2854 if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
2855 grep 'no-whole-archive' > /dev/null; then
2856 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
2858 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
2864 # A generic and very simple default shared library creation
2865 # command for GNU C++ for the case where it uses the native
2866 # linker, instead of GNU ld. If possible, this setting should
2867 # overridden to take advantage of the native linker features on
2868 # the platform it is being used on.
2869 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
2872 # Commands to make compiler produce verbose output that lists
2873 # what "hidden" libraries, object files and flags are used when
2874 # linking a shared library.
2875 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
2883 # PORTME: fill in a description of your system's C++ link characteristics
2884 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
2885 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
2888 # FIXME: insert proper C++ library support
2889 _LT_AC_TAGVAR(ld_shlibs, $1)=no
2892 if test "$host_cpu" = ia64; then
2893 # On IA64, the linker does run time linking by default, so we don't
2894 # have to do anything special.
2895 aix_use_runtimelinking=no
2896 exp_sym_flag='-Bexport'
2899 aix_use_runtimelinking=no
2901 # Test if we are trying to use run time linking or normal
2902 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
2903 # need to do runtime linking.
2904 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
2905 for ld_flag in $LDFLAGS; do
2908 aix_use_runtimelinking=yes
2916 exp_sym_flag='-bexport'
2917 no_entry_flag='-bnoentry'
2920 # When large executables or shared objects are built, AIX ld can
2921 # have problems creating the table of contents. If linking a library
2922 # or program results in "error TOC overflow" add -mminimal-toc to
2923 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
2924 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
2926 _LT_AC_TAGVAR(archive_cmds, $1)=''
2927 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
2928 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
2929 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
2931 if test "$GXX" = yes; then
2932 case $host_os in aix4.[[012]]|aix4.[[012]].*)
2933 # We only want to do this on AIX 4.2 and lower, the check
2934 # below for broken collect2 doesn't work under 4.3+
2935 collect2name=`${CC} -print-prog-name=collect2`
2936 if test -f "$collect2name" && \
2937 strings "$collect2name" | grep resolve_lib_name >/dev/null
2939 # We have reworked collect2
2940 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
2942 # We have old collect2
2943 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
2944 # It fails to find uninstalled libraries when the uninstalled
2945 # path is not listed in the libpath. Setting hardcode_minus_L
2946 # to unsupported forces relinking
2947 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
2948 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
2949 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
2953 shared_flag='-shared'
2954 if test "$aix_use_runtimelinking" = yes; then
2955 shared_flag="$shared_flag "'${wl}-G'
2959 if test "$host_cpu" = ia64; then
2960 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
2961 # chokes on -Wl,-G. The following line is correct:
2964 if test "$aix_use_runtimelinking" = yes; then
2965 shared_flag='${wl}-G'
2967 shared_flag='${wl}-bM:SRE'
2972 # It seems that -bexpall does not export symbols beginning with
2973 # underscore (_), so it is better to generate a list of symbols to export.
2974 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
2975 if test "$aix_use_runtimelinking" = yes; then
2976 # Warning - without using the other runtime loading flags (-brtl),
2977 # -berok will link without error, but may produce a broken library.
2978 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
2979 # Determine the default libpath from the value encoded in an empty executable.
2980 _LT_AC_SYS_LIBPATH_AIX
2981 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
2983 _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"
2985 if test "$host_cpu" = ia64; then
2986 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
2987 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
2988 _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"
2990 # Determine the default libpath from the value encoded in an empty executable.
2991 _LT_AC_SYS_LIBPATH_AIX
2992 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
2993 # Warning - without using the other run time loading flags,
2994 # -berok will link without error, but may produce a broken library.
2995 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
2996 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
2997 # Exported symbols can be pulled into shared objects from archives
2998 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
2999 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3000 # This is similar to how AIX traditionally builds its shared libraries.
3001 _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'
3007 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
3008 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3009 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
3010 # support --undefined. This deserves some investigation. FIXME
3011 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
3013 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3018 case $cc_basename in
3020 # FIXME: insert proper C++ library support
3021 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3026 cygwin* | mingw* | pw32*)
3027 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3028 # as there is no search path for DLLs.
3029 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3030 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3031 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3032 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3034 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3035 _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'
3036 # If the export-symbols file already is a .def file (1st line
3037 # is EXPORTS), use it as is; otherwise, prepend...
3038 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3039 cp $export_symbols $output_objdir/$soname.def;
3041 echo EXPORTS > $output_objdir/$soname.def;
3042 cat $export_symbols >> $output_objdir/$soname.def;
3044 $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'
3046 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3049 darwin* | rhapsody*)
3051 rhapsody* | darwin1.[[012]])
3052 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
3055 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
3056 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
3058 case ${MACOSX_DEPLOYMENT_TARGET} in
3060 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
3063 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
3069 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3070 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3071 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3072 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3073 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
3074 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3076 if test "$GXX" = yes ; then
3077 lt_int_apple_cc_single_mod=no
3078 output_verbose_link_cmd='echo'
3079 if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
3080 lt_int_apple_cc_single_mod=yes
3082 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3083 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
3085 _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'
3087 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3088 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
3089 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3090 _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}'
3092 _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}'
3094 _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}'
3096 case $cc_basename in
3098 output_verbose_link_cmd='echo'
3099 _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'
3100 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3101 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
3102 _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}'
3103 _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}'
3106 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3113 case $cc_basename in
3115 # FIXME: insert proper C++ library support
3116 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3119 # Green Hills C++ Compiler
3120 # FIXME: insert proper C++ library support
3121 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3124 # FIXME: insert proper C++ library support
3125 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3130 # C++ shared libraries reported to be fairly broken before switch to ELF
3131 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3134 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3136 freebsd* | kfreebsd*-gnu | dragonfly*)
3137 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3139 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3144 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3145 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3146 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3147 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3148 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3149 # but as the default
3150 # location of the library.
3152 case $cc_basename in
3154 # FIXME: insert proper C++ library support
3155 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3158 _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'
3159 # Commands to make compiler produce verbose output that lists
3160 # what "hidden" libraries, object files and flags are used when
3161 # linking a shared library.
3163 # There doesn't appear to be a way to prevent this compiler from
3164 # explicitly linking system object files so we need to strip them
3165 # from the output so that they don't get included in the library
3167 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'
3170 if test "$GXX" = yes; then
3171 _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'
3173 # FIXME: insert proper C++ library support
3174 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3180 if test $with_gnu_ld = no; then
3181 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3182 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3186 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
3189 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3195 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3196 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3199 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3200 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3201 # but as the default
3202 # location of the library.
3206 case $cc_basename in
3208 # FIXME: insert proper C++ library support
3209 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3214 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3217 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3220 _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'
3223 # Commands to make compiler produce verbose output that lists
3224 # what "hidden" libraries, object files and flags are used when
3225 # linking a shared library.
3227 # There doesn't appear to be a way to prevent this compiler from
3228 # explicitly linking system object files so we need to strip them
3229 # from the output so that they don't get included in the library
3231 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'
3234 if test "$GXX" = yes; then
3235 if test $with_gnu_ld = no; then
3238 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3241 _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'
3244 _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'
3249 # FIXME: insert proper C++ library support
3250 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3256 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3257 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3258 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3259 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3260 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
3261 # Instead, shared libraries are loaded at an image base (0x10000000 by
3262 # default) and relocated if they conflict, which is a slow very memory
3263 # consuming and fragmenting process. To avoid this, we pick a random,
3264 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
3265 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
3266 _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'
3267 _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'
3270 case $cc_basename in
3273 _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'
3275 # Archives containing C++ object files must be created using
3276 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
3277 # necessary to make sure instantiated templates are included
3279 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
3282 if test "$GXX" = yes; then
3283 if test "$with_gnu_ld" = no; then
3284 _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'
3286 _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'
3289 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3292 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3293 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3296 case $cc_basename in
3298 # Kuck and Associates, Inc. (KAI) C++ Compiler
3300 # KCC will only create a shared library if the output file
3301 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3302 # to its proper name (with version) after linking.
3303 _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'
3304 _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'
3305 # Commands to make compiler produce verbose output that lists
3306 # what "hidden" libraries, object files and flags are used when
3307 # linking a shared library.
3309 # There doesn't appear to be a way to prevent this compiler from
3310 # explicitly linking system object files so we need to strip them
3311 # from the output so that they don't get included in the library
3313 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'
3315 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
3316 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3318 # Archives containing C++ object files must be created using
3319 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
3320 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
3325 # version 8.0 and above of icpc choke on multiply defined symbols
3326 # if we add $predep_objects and $postdep_objects, however 7.1 and
3327 # earlier do not add the objects themselves.
3328 case `$CC -V 2>&1` in
3330 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3331 _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'
3333 *) # Version 8.0 or newer
3336 ia64*) tmp_idyn=' -i_dynamic';;
3338 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
3339 _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'
3342 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3343 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3344 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3345 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
3348 # Portland Group C++ compiler
3349 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
3350 _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'
3352 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3353 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3354 _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'
3358 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3359 _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'
3361 runpath_var=LD_RUN_PATH
3362 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
3363 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3365 # Commands to make compiler produce verbose output that lists
3366 # what "hidden" libraries, object files and flags are used when
3367 # linking a shared library.
3369 # There doesn't appear to be a way to prevent this compiler from
3370 # explicitly linking system object files so we need to strip them
3371 # from the output so that they don't get included in the library
3373 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'
3378 # FIXME: insert proper C++ library support
3379 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3382 # FIXME: insert proper C++ library support
3383 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3386 case $cc_basename in
3388 # FIXME: insert proper C++ library support
3389 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3392 # FIXME: insert proper C++ library support
3393 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3398 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
3399 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
3401 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
3402 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3403 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3405 # Workaround some broken pre-1.5 toolchains
3406 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
3409 # C++ shared libraries are fairly broken
3410 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3413 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3414 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3415 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3416 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3417 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3418 _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'
3419 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3420 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3422 output_verbose_link_cmd='echo'
3425 case $cc_basename in
3427 # Kuck and Associates, Inc. (KAI) C++ Compiler
3429 # KCC will only create a shared library if the output file
3430 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3431 # to its proper name (with version) after linking.
3432 _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'
3434 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3435 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3437 # Archives containing C++ object files must be created using
3438 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
3439 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
3443 # Rational C++ 2.4.1
3444 # FIXME: insert proper C++ library support
3445 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3448 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3449 _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'
3451 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3452 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3454 # Commands to make compiler produce verbose output that lists
3455 # what "hidden" libraries, object files and flags are used when
3456 # linking a shared library.
3458 # There doesn't appear to be a way to prevent this compiler from
3459 # explicitly linking system object files so we need to strip them
3460 # from the output so that they don't get included in the library
3462 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'
3465 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3466 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3467 _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'
3469 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3470 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3472 # Commands to make compiler produce verbose output that lists
3473 # what "hidden" libraries, object files and flags are used when
3474 # linking a shared library.
3475 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3478 # FIXME: insert proper C++ library support
3479 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3485 case $cc_basename in
3487 # Kuck and Associates, Inc. (KAI) C++ Compiler
3489 # KCC will only create a shared library if the output file
3490 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3491 # to its proper name (with version) after linking.
3492 _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'
3494 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3495 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3497 # Archives containing C++ object files must be created using
3498 # the KAI C++ compiler.
3499 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
3502 # Rational C++ 2.4.1
3503 # FIXME: insert proper C++ library support
3504 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3507 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
3508 _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'
3509 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
3510 echo "-hidden">> $lib.exp~
3511 $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~
3514 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
3515 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3517 # Commands to make compiler produce verbose output that lists
3518 # what "hidden" libraries, object files and flags are used when
3519 # linking a shared library.
3521 # There doesn't appear to be a way to prevent this compiler from
3522 # explicitly linking system object files so we need to strip them
3523 # from the output so that they don't get included in the library
3525 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'
3528 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3529 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3530 _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'
3532 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3533 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3535 # Commands to make compiler produce verbose output that lists
3536 # what "hidden" libraries, object files and flags are used when
3537 # linking a shared library.
3538 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3541 # FIXME: insert proper C++ library support
3542 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3548 # FIXME: insert proper C++ library support
3549 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3552 case $cc_basename in
3555 # FIXME: insert proper C++ library support
3556 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3560 # FIXME: insert proper C++ library support
3561 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3564 # FIXME: insert proper C++ library support
3565 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3570 case $cc_basename in
3572 # Sun C++ 4.2, 5.x and Centerline C++
3573 _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
3574 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
3575 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3576 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3577 $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'
3579 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
3580 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3582 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
3584 # The C++ compiler is used as linker so we must use $wl
3585 # flag to pass the commands to the underlying system
3586 # linker. We must also pass each convience library through
3587 # to the system linker between allextract/defaultextract.
3588 # The C++ compiler will combine linker options so we
3589 # cannot just pass the convience library names through
3591 # Supported since Solaris 2.6 (maybe 2.5.1?)
3592 _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'
3595 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3597 output_verbose_link_cmd='echo'
3599 # Archives containing C++ object files must be created using
3600 # "CC -xar", where "CC" is the Sun C++ compiler. This is
3601 # necessary to make sure instantiated templates are included
3603 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
3606 # Green Hills C++ Compiler
3607 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3609 # The C++ compiler must be used to create the archive.
3610 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
3613 # GNU C++ compiler with Solaris linker
3614 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3615 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
3616 if $CC --version | grep -v '^2\.7' > /dev/null; then
3617 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3618 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3619 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3621 # Commands to make compiler produce verbose output that lists
3622 # what "hidden" libraries, object files and flags are used when
3623 # linking a shared library.
3624 output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
3626 # g++ 2.7 appears to require `-G' NOT `-shared' on this
3628 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3629 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3630 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3632 # Commands to make compiler produce verbose output that lists
3633 # what "hidden" libraries, object files and flags are used when
3634 # linking a shared library.
3635 output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
3638 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
3643 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
3644 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
3645 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3646 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3647 runpath_var='LD_RUN_PATH'
3649 case $cc_basename in
3651 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
3652 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
3655 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
3656 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
3660 sysv5* | sco3.2v5* | sco5v6*)
3661 # Note: We can NOT use -z defs as we might desire, because we do not
3662 # link with -lc, and that would cause any symbols used from libc to
3663 # always be unresolved, which means just about no library would
3664 # ever link correctly. If we're not using GNU ld we use -z text
3665 # though, which does catch some bad symbols but isn't as heavy-handed
3667 # For security reasons, it is highly recommended that you always
3668 # use absolute paths for naming shared libraries, and exclude the
3669 # DT_RUNPATH tag from executables and libraries. But doing so
3670 # requires that you compile everything twice, which is a pain.
3671 # So that behaviour is only enabled if SCOABSPATH is set to a
3672 # non-empty value in the environment. Most likely only useful for
3673 # creating official distributions of packages.
3674 # This is a hack until libtool officially supports absolute path
3675 # names for shared libraries.
3676 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
3677 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
3678 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3679 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3680 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
3681 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3682 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3683 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
3684 runpath_var='LD_RUN_PATH'
3686 case $cc_basename in
3688 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
3689 _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'
3692 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
3693 _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'
3698 case $cc_basename in
3700 # NonStop-UX NCC 3.20
3701 # FIXME: insert proper C++ library support
3702 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3705 # FIXME: insert proper C++ library support
3706 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3711 # FIXME: insert proper C++ library support
3712 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3715 # FIXME: insert proper C++ library support
3716 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3719 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
3720 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
3722 _LT_AC_TAGVAR(GCC, $1)="$GXX"
3723 _LT_AC_TAGVAR(LD, $1)="$LD"
3726 ## There is no encapsulation within the following macros, do not change
3727 ## the running order or otherwise move them around unless you know exactly
3728 ## what you are doing...
3729 AC_LIBTOOL_POSTDEP_PREDEP($1)
3730 AC_LIBTOOL_PROG_COMPILER_PIC($1)
3731 AC_LIBTOOL_PROG_CC_C_O($1)
3732 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3733 AC_LIBTOOL_PROG_LD_SHLIBS($1)
3734 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3735 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3737 AC_LIBTOOL_CONFIG($1)
3744 with_gnu_ldcxx=$with_gnu_ld
3745 with_gnu_ld=$lt_save_with_gnu_ld
3746 lt_cv_path_LDCXX=$lt_cv_path_LD
3747 lt_cv_path_LD=$lt_save_path_LD
3748 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
3749 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
3750 ])# AC_LIBTOOL_LANG_CXX_CONFIG
3752 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
3753 # ------------------------------------
3754 # Figure out "hidden" library dependencies from verbose
3755 # compiler output when linking a shared library.
3756 # Parse the compiler output and extract the necessary
3757 # objects, libraries and library flags.
3758 AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
3759 dnl we can't use the lt_simple_compile_test_code here,
3760 dnl because it contains code intended for an executable,
3761 dnl not a library. It's possible we should let each
3762 dnl tag define a new lt_????_link_test_code variable,
3763 dnl but it's only used here...
3764 ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
3766 void foo (void) { a = 0; }
3768 ],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
3772 Foo (void) { a = 0; }
3777 ],[$1],[F77],[cat > conftest.$ac_ext <<EOF
3785 ],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
3788 public void bar (void) {
3794 dnl Parse the compiler output and extract the necessary
3795 dnl objects, libraries and library flags.
3796 if AC_TRY_EVAL(ac_compile); then
3797 # Parse the compiler output and extract the necessary
3798 # objects, libraries and library flags.
3800 # Sentinel used to keep track of whether or not we are before
3801 # the conftest object file.
3802 pre_test_object_deps_done=no
3804 # The `*' in the case matches for architectures that use `case' in
3805 # $output_verbose_cmd can trigger glob expansion during the loop
3806 # eval without this substitution.
3807 output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
3809 for p in `eval $output_verbose_link_cmd`; do
3813 # Some compilers place space between "-{L,R}" and the path.
3816 || test $p = "-R"; then
3823 if test "$pre_test_object_deps_done" = no; then
3826 # Internal compiler library paths should come after those
3827 # provided the user. The postdeps already come after the
3828 # user supplied libs so there is no need to process them.
3829 if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
3830 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
3832 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
3835 # The "-l" case would never come before the object being
3836 # linked, so don't bother handling this case.
3839 if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
3840 _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
3842 _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
3848 # This assumes that the test object file only shows up
3849 # once in the compiler output.
3850 if test "$p" = "conftest.$objext"; then
3851 pre_test_object_deps_done=yes
3855 if test "$pre_test_object_deps_done" = no; then
3856 if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
3857 _LT_AC_TAGVAR(predep_objects, $1)="$p"
3859 _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
3862 if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
3863 _LT_AC_TAGVAR(postdep_objects, $1)="$p"
3865 _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
3870 *) ;; # Ignore the rest.
3878 echo "libtool.m4: error: problem compiling $1 test program"
3881 $rm -f confest.$objext
3883 # PORTME: override above test on systems where it is broken
3887 # Interix 3.5 installs completely hosed .la files for C++, so rather than
3888 # hack all around it, let's just trust "g++" to DTRT.
3889 _LT_AC_TAGVAR(predep_objects,$1)=
3890 _LT_AC_TAGVAR(postdep_objects,$1)=
3891 _LT_AC_TAGVAR(postdeps,$1)=
3895 case $cc_basename in
3897 # The more standards-conforming stlport4 library is
3898 # incompatible with the Cstd library. Avoid specifying
3899 # it if it's in CXXFLAGS. Ignore libCrun as
3900 # -library=stlport4 depends on it.
3901 case " $CXX $CXXFLAGS " in
3902 *" -library=stlport4 "*)
3903 solaris_use_stlport4=yes
3907 # Adding this requires a known-good setup of shared libraries for
3908 # Sun compiler versions before 5.6, else PIC objects from an old
3909 # archive will be linked into the output, leading to subtle bugs.
3910 if test "$solaris_use_stlport4" != yes; then
3911 _LT_AC_TAGVAR(postdeps,$1)='-lCstd -lCrun'
3919 case " $_LT_AC_TAGVAR(postdeps, $1) " in
3920 *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
3922 ])# AC_LIBTOOL_POSTDEP_PREDEP
3924 # AC_LIBTOOL_LANG_F77_CONFIG
3925 # --------------------------
3926 # Ensure that the configuration vars for the C compiler are
3927 # suitably defined. Those variables are subsequently used by
3928 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3929 AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
3930 AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
3931 [AC_REQUIRE([AC_PROG_F77])
3932 AC_LANG_PUSH(Fortran 77)
3934 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3935 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
3936 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3937 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3938 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3939 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3940 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3941 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3942 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3943 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3944 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
3945 _LT_AC_TAGVAR(module_cmds, $1)=
3946 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
3947 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3948 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3949 _LT_AC_TAGVAR(no_undefined_flag, $1)=
3950 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3951 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3953 # Source file extension for f77 test sources.
3956 # Object file extension for compiled f77 test sources.
3958 _LT_AC_TAGVAR(objext, $1)=$objext
3960 # Code to be used in simple compile tests
3961 lt_simple_compile_test_code=" subroutine t\n return\n end\n"
3963 # Code to be used in simple link tests
3964 lt_simple_link_test_code=" program t\n end\n"
3966 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
3969 # save warnings/boilerplate of simple test code
3970 _LT_COMPILER_BOILERPLATE
3971 _LT_LINKER_BOILERPLATE
3973 # Allow CC to be a program name with arguments.
3977 _LT_AC_TAGVAR(compiler, $1)=$CC
3978 _LT_CC_BASENAME([$compiler])
3980 AC_MSG_CHECKING([if libtool supports shared libraries])
3981 AC_MSG_RESULT([$can_build_shared])
3983 AC_MSG_CHECKING([whether to build shared libraries])
3984 test "$can_build_shared" = "no" && enable_shared=no
3986 # On AIX, shared libraries and static libraries use the same namespace, and
3987 # are all built from PIC.
3990 test "$enable_shared" = yes && enable_static=no
3991 if test -n "$RANLIB"; then
3992 archive_cmds="$archive_cmds~\$RANLIB \$lib"
3993 postinstall_cmds='$RANLIB $lib'
3997 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3998 test "$enable_shared" = yes && enable_static=no
4002 AC_MSG_RESULT([$enable_shared])
4004 AC_MSG_CHECKING([whether to build static libraries])
4005 # Make sure either enable_shared or enable_static is yes.
4006 test "$enable_shared" = yes || enable_static=yes
4007 AC_MSG_RESULT([$enable_static])
4009 _LT_AC_TAGVAR(GCC, $1)="$G77"
4010 _LT_AC_TAGVAR(LD, $1)="$LD"
4012 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4013 AC_LIBTOOL_PROG_CC_C_O($1)
4014 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4015 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4016 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4017 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4019 AC_LIBTOOL_CONFIG($1)
4023 ])# AC_LIBTOOL_LANG_F77_CONFIG
4026 # AC_LIBTOOL_LANG_GCJ_CONFIG
4027 # --------------------------
4028 # Ensure that the configuration vars for the C compiler are
4029 # suitably defined. Those variables are subsequently used by
4030 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4031 AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4032 AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4035 # Source file extension for Java test sources.
4038 # Object file extension for compiled Java test sources.
4040 _LT_AC_TAGVAR(objext, $1)=$objext
4042 # Code to be used in simple compile tests
4043 lt_simple_compile_test_code="class foo {}\n"
4045 # Code to be used in simple link tests
4046 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
4048 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4051 # save warnings/boilerplate of simple test code
4052 _LT_COMPILER_BOILERPLATE
4053 _LT_LINKER_BOILERPLATE
4055 # Allow CC to be a program name with arguments.
4059 _LT_AC_TAGVAR(compiler, $1)=$CC
4060 _LT_CC_BASENAME([$compiler])
4062 # GCJ did not exist at the time GCC didn't implicitly link libc in.
4063 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4065 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4068 ## There is no encapsulation within the following macros, do not change
4069 ## the running order or otherwise move them around unless you know exactly
4070 ## what you are doing...
4071 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4072 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4073 AC_LIBTOOL_PROG_CC_C_O($1)
4074 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4075 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4076 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4077 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4079 AC_LIBTOOL_CONFIG($1)
4083 ])# AC_LIBTOOL_LANG_GCJ_CONFIG
4086 # AC_LIBTOOL_LANG_RC_CONFIG
4087 # -------------------------
4088 # Ensure that the configuration vars for the Windows resource compiler are
4089 # suitably defined. Those variables are subsequently used by
4090 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4091 AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4092 AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4095 # Source file extension for RC test sources.
4098 # Object file extension for compiled RC test sources.
4100 _LT_AC_TAGVAR(objext, $1)=$objext
4102 # Code to be used in simple compile tests
4103 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
4105 # Code to be used in simple link tests
4106 lt_simple_link_test_code="$lt_simple_compile_test_code"
4108 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4111 # save warnings/boilerplate of simple test code
4112 _LT_COMPILER_BOILERPLATE
4113 _LT_LINKER_BOILERPLATE
4115 # Allow CC to be a program name with arguments.
4119 _LT_AC_TAGVAR(compiler, $1)=$CC
4120 _LT_CC_BASENAME([$compiler])
4121 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4123 AC_LIBTOOL_CONFIG($1)
4127 ])# AC_LIBTOOL_LANG_RC_CONFIG
4130 # AC_LIBTOOL_CONFIG([TAGNAME])
4131 # ----------------------------
4132 # If TAGNAME is not passed, then create an initial libtool script
4133 # with a default configuration from the untagged config vars. Otherwise
4134 # add code to config.status for appending the configuration named by
4135 # TAGNAME from the matching tagged config vars.
4136 AC_DEFUN([AC_LIBTOOL_CONFIG],
4137 [# The else clause should only fire when bootstrapping the
4138 # libtool distribution, otherwise you forgot to ship ltmain.sh
4139 # with your package, and you will get complaints that there are
4140 # no rules to generate ltmain.sh.
4141 if test -f "$ltmain"; then
4142 # See if we are running on zsh, and set the options which allow our commands through
4143 # without removal of \ escapes.
4144 if test -n "${ZSH_VERSION+set}" ; then
4145 setopt NO_GLOB_SUBST
4147 # Now quote all the things that may contain metacharacters while being
4148 # careful not to overquote the AC_SUBSTed values. We take copies of the
4149 # variables and quote the copies for generation of the libtool script.
4150 for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
4152 libname_spec library_names_spec soname_spec extract_expsyms_cmds \
4153 old_striplib striplib file_magic_cmd finish_cmds finish_eval \
4154 deplibs_check_method reload_flag reload_cmds need_locks \
4155 lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
4156 lt_cv_sys_global_symbol_to_c_name_address \
4157 sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
4158 old_postinstall_cmds old_postuninstall_cmds \
4159 _LT_AC_TAGVAR(compiler, $1) \
4160 _LT_AC_TAGVAR(CC, $1) \
4161 _LT_AC_TAGVAR(LD, $1) \
4162 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
4163 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
4164 _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
4165 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
4166 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
4167 _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
4168 _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
4169 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
4170 _LT_AC_TAGVAR(old_archive_cmds, $1) \
4171 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
4172 _LT_AC_TAGVAR(predep_objects, $1) \
4173 _LT_AC_TAGVAR(postdep_objects, $1) \
4174 _LT_AC_TAGVAR(predeps, $1) \
4175 _LT_AC_TAGVAR(postdeps, $1) \
4176 _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
4177 _LT_AC_TAGVAR(archive_cmds, $1) \
4178 _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
4179 _LT_AC_TAGVAR(postinstall_cmds, $1) \
4180 _LT_AC_TAGVAR(postuninstall_cmds, $1) \
4181 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
4182 _LT_AC_TAGVAR(allow_undefined_flag, $1) \
4183 _LT_AC_TAGVAR(no_undefined_flag, $1) \
4184 _LT_AC_TAGVAR(export_symbols_cmds, $1) \
4185 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
4186 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
4187 _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
4188 _LT_AC_TAGVAR(hardcode_automatic, $1) \
4189 _LT_AC_TAGVAR(module_cmds, $1) \
4190 _LT_AC_TAGVAR(module_expsym_cmds, $1) \
4191 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
4192 _LT_AC_TAGVAR(exclude_expsyms, $1) \
4193 _LT_AC_TAGVAR(include_expsyms, $1); do
4196 _LT_AC_TAGVAR(old_archive_cmds, $1) | \
4197 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
4198 _LT_AC_TAGVAR(archive_cmds, $1) | \
4199 _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
4200 _LT_AC_TAGVAR(module_cmds, $1) | \
4201 _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
4202 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
4203 _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
4204 extract_expsyms_cmds | reload_cmds | finish_cmds | \
4205 postinstall_cmds | postuninstall_cmds | \
4206 old_postinstall_cmds | old_postuninstall_cmds | \
4207 sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
4208 # Double-quote double-evaled strings.
4209 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
4212 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
4218 *'\[$]0 --fallback-echo"')
4219 lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
4224 [cfgfile="${ofile}T"
4225 trap "$rm \"$cfgfile\"; exit 1" 1 2 15
4227 AC_MSG_NOTICE([creating $ofile])],
4230 cat <<__EOF__ >> "$cfgfile"
4234 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
4235 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
4236 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
4238 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
4239 # Free Software Foundation, Inc.
4241 # This file is part of GNU Libtool:
4242 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
4244 # This program is free software; you can redistribute it and/or modify
4245 # it under the terms of the GNU General Public License as published by
4246 # the Free Software Foundation; either version 3 of the License, or
4247 # (at your option) any later version.
4249 # This program is distributed in the hope that it will be useful, but
4250 # WITHOUT ANY WARRANTY; without even the implied warranty of
4251 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4252 # General Public License for more details.
4254 # You should have received a copy of the GNU General Public License
4255 # along with this program; if not, write to the Free Software
4256 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
4258 # As a special exception to the GNU General Public License, if you
4259 # distribute this file as part of a program that contains a
4260 # configuration script generated by Autoconf, you may include it under
4261 # the same distribution terms that you use for the rest of that program.
4263 # A sed program that does not truncate output.
4266 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
4267 Xsed="$SED -e 1s/^X//"
4269 # The HP-UX ksh and POSIX shell print the target directory to stdout
4271 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
4273 # The names of the tagged configurations supported by this script.
4276 # ### BEGIN LIBTOOL CONFIG],
4277 [# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
4279 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4281 # Shell to use when invoking shell scripts.
4284 # Whether or not to build shared libraries.
4285 build_libtool_libs=$enable_shared
4287 # Whether or not to build static libraries.
4288 build_old_libs=$enable_static
4290 # Whether or not to add -lc for building shared libraries.
4291 build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
4293 # Whether or not to disallow shared libs when runtime libs are static
4294 allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
4296 # Whether or not to optimize for fast installation.
4297 fast_install=$enable_fast_install
4300 host_alias=$host_alias
4305 build_alias=$build_alias
4309 # An echo program that does not interpret backslashes.
4314 AR_FLAGS=$lt_AR_FLAGS
4319 # LTCC compiler flags.
4320 LTCFLAGS=$lt_LTCFLAGS
4322 # A language-specific compiler.
4323 CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
4325 # Is the compiler the GNU C compiler?
4326 with_gcc=$_LT_AC_TAGVAR(GCC, $1)
4331 # The linker used to build libraries.
4332 LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
4334 # Whether we need hard or soft links.
4337 # A BSD-compatible nm program.
4340 # A symbol stripping program
4343 # Used to examine libraries when file_magic_cmd begins "file"
4344 MAGIC_CMD=$MAGIC_CMD
4346 # Used on cygwin: DLL creation program.
4349 # Used on cygwin: object dumper.
4352 # Used on cygwin: assembler.
4355 # The name of the directory that contains temporary libtool files.
4358 # How to create reloadable object files.
4359 reload_flag=$lt_reload_flag
4360 reload_cmds=$lt_reload_cmds
4362 # How to pass a linker flag through the compiler.
4363 wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
4365 # Object file suffix (normally "o").
4368 # Old archive suffix (normally "a").
4371 # Shared library suffix (normally ".so").
4372 shrext_cmds='$shrext_cmds'
4374 # Executable file suffix (normally "").
4377 # Additional compiler flags for building library objects.
4378 pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
4381 # What is the maximum length of a command?
4382 max_cmd_len=$lt_cv_sys_max_cmd_len
4384 # Does compiler simultaneously support -c and -o options?
4385 compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
4387 # Must we lock files when doing compilation?
4388 need_locks=$lt_need_locks
4390 # Do we need the lib prefix for modules?
4391 need_lib_prefix=$need_lib_prefix
4393 # Do we need a version for libraries?
4394 need_version=$need_version
4396 # Whether dlopen is supported.
4397 dlopen_support=$enable_dlopen
4399 # Whether dlopen of programs is supported.
4400 dlopen_self=$enable_dlopen_self
4402 # Whether dlopen of statically linked programs is supported.
4403 dlopen_self_static=$enable_dlopen_self_static
4405 # Compiler flag to prevent dynamic linking.
4406 link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
4408 # Compiler flag to turn off builtin functions.
4409 no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
4411 # Compiler flag to allow reflexive dlopens.
4412 export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
4414 # Compiler flag to generate shared objects directly from archives.
4415 whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
4417 # Compiler flag to generate thread-safe objects.
4418 thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
4420 # Library versioning type.
4421 version_type=$version_type
4423 # Format of library name prefix.
4424 libname_spec=$lt_libname_spec
4426 # List of archive names. First name is the real one, the rest are links.
4427 # The last name is the one that the linker finds with -lNAME.
4428 library_names_spec=$lt_library_names_spec
4430 # The coded name of the library, if different from the real name.
4431 soname_spec=$lt_soname_spec
4433 # Commands used to build and install an old-style archive.
4435 old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
4436 old_postinstall_cmds=$lt_old_postinstall_cmds
4437 old_postuninstall_cmds=$lt_old_postuninstall_cmds
4439 # Create an old-style archive from a shared archive.
4440 old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
4442 # Create a temporary old-style archive to link instead of a shared archive.
4443 old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
4445 # Commands used to build and install a shared archive.
4446 archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
4447 archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
4448 postinstall_cmds=$lt_postinstall_cmds
4449 postuninstall_cmds=$lt_postuninstall_cmds
4451 # Commands used to build a loadable module (assumed same as above if empty)
4452 module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
4453 module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
4455 # Commands to strip libraries.
4456 old_striplib=$lt_old_striplib
4457 striplib=$lt_striplib
4459 # Dependencies to place before the objects being linked to create a
4461 predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
4463 # Dependencies to place after the objects being linked to create a
4465 postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
4467 # Dependencies to place before the objects being linked to create a
4469 predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
4471 # Dependencies to place after the objects being linked to create a
4473 postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
4475 # The library search path used internally by the compiler when linking
4477 compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
4479 # Method to check whether dependent libraries are shared objects.
4480 deplibs_check_method=$lt_deplibs_check_method
4482 # Command to use when deplibs_check_method == file_magic.
4483 file_magic_cmd=$lt_file_magic_cmd
4485 # Flag that allows shared libraries with undefined symbols to be built.
4486 allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
4488 # Flag that forces no undefined symbols.
4489 no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
4491 # Commands used to finish a libtool library installation in a directory.
4492 finish_cmds=$lt_finish_cmds
4494 # Same as above, but a single script fragment to be evaled but not shown.
4495 finish_eval=$lt_finish_eval
4497 # Take the output of nm and produce a listing of raw symbols and C names.
4498 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
4500 # Transform the output of nm in a proper C declaration
4501 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
4503 # Transform the output of nm in a C name address pair
4504 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
4506 # This is the shared library runtime path variable.
4507 runpath_var=$runpath_var
4509 # This is the shared library path variable.
4510 shlibpath_var=$shlibpath_var
4512 # Is shlibpath searched before the hard-coded library search path?
4513 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
4515 # How to hardcode a shared library path into an executable.
4516 hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
4518 # Whether we should hardcode library paths into libraries.
4519 hardcode_into_libs=$hardcode_into_libs
4521 # Flag to hardcode \$libdir into a binary during linking.
4522 # This must work even if \$libdir does not exist.
4523 hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
4525 # If ld is used when linking, flag to hardcode \$libdir into
4526 # a binary during linking. This must work even if \$libdir does
4528 hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
4530 # Whether we need a single -rpath flag with a separated argument.
4531 hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
4533 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
4535 hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
4537 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
4539 hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
4541 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
4542 # the resulting binary.
4543 hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
4545 # Set to yes if building a shared library automatically hardcodes DIR into the library
4546 # and all subsequent libraries and executables linked against it.
4547 hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
4549 # Variables whose values should be saved in libtool wrapper scripts and
4550 # restored at relink time.
4551 variables_saved_for_relink="$variables_saved_for_relink"
4553 # Whether libtool must link a program against all its dependency libraries.
4554 link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
4556 # Compile-time system search path for libraries
4557 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
4559 # Run-time system search path for libraries
4560 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
4562 # Fix the shell variable \$srcfile for the compiler.
4563 fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
4565 # Set to yes if exported symbols are required.
4566 always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
4568 # The commands to list exported symbols.
4569 export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
4571 # The commands to extract the exported symbol list from a shared archive.
4572 extract_expsyms_cmds=$lt_extract_expsyms_cmds
4574 # Symbols that should not be listed in the preloaded symbols.
4575 exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
4577 # Symbols that must always be exported.
4578 include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
4581 [# ### END LIBTOOL CONFIG],
4582 [# ### END LIBTOOL TAG CONFIG: $tagname])
4589 cat <<\EOF >> "$cfgfile"
4591 # AIX sometimes has problems with the GCC collect2 program. For some
4592 # reason, if we set the COLLECT_NAMES environment variable, the problems
4593 # vanish in a puff of smoke.
4594 if test "X${COLLECT_NAMES+set}" != Xset; then
4596 export COLLECT_NAMES
4602 # We use sed instead of cat because bash on DJGPP gets confused if
4603 # if finds mixed CR/LF and LF-only lines. Since sed operates in
4604 # text mode, it properly converts lines to CR/LF. This bash problem
4605 # is reportedly fixed, but why not run on old versions too?
4606 sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
4608 mv -f "$cfgfile" "$ofile" || \
4609 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
4613 # If there is no Makefile yet, we rely on a make rule to execute
4614 # `config.status --recheck' to rerun these tests and create the
4615 # libtool script then.
4616 ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
4617 if test -f "$ltmain_in"; then
4618 test -f Makefile && make "$ltmain"
4621 ])# AC_LIBTOOL_CONFIG
4624 # AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
4625 # -------------------------------------------
4626 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
4627 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
4629 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4631 if test "$GCC" = yes; then
4632 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
4634 AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4635 lt_cv_prog_compiler_rtti_exceptions,
4636 [-fno-rtti -fno-exceptions], [],
4637 [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4639 ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
4642 # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
4643 # ---------------------------------
4644 AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
4645 [AC_REQUIRE([AC_CANONICAL_HOST])
4646 AC_REQUIRE([AC_PROG_NM])
4647 AC_REQUIRE([AC_OBJEXT])
4648 # Check for command to grab the raw symbol name followed by C symbol from nm.
4649 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4650 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4652 # These are sane defaults that work on at least a few old systems.
4653 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4655 # Character class describing NM global symbol codes.
4656 symcode='[[BCDEGRST]]'
4658 # Regexp to match symbols that can be accessed directly from C.
4659 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4661 # Transform an extracted symbol line into a proper C declaration
4662 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
4664 # Transform an extracted symbol line into symbol name and symbol address
4665 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'"
4667 # Define system-specific variables.
4672 cygwin* | mingw* | pw32*)
4673 symcode='[[ABCDGISTW]]'
4675 hpux*) # Its linker distinguishes data from code symbols
4676 if test "$host_cpu" = ia64; then
4677 symcode='[[ABCDEGRST]]'
4679 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4680 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'"
4683 if test "$host_cpu" = ia64; then
4684 symcode='[[ABCDGIRSTW]]'
4685 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4686 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'"
4690 symcode='[[BCDEGRST]]'
4693 symcode='[[BCDEGQRST]]'
4704 sysv5* | sco5v6* | unixware* | OpenUNIX*)
4708 symcode='[[DFNSTU]]'
4712 # Handle CRLF in mingw tool chain
4716 opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4720 # If we're using GNU nm, then use its standard symbol codes.
4721 case `$NM -V 2>&1` in
4722 *GNU* | *'with BFD'*)
4723 symcode='[[ABCDGIRSTW]]' ;;
4726 # Try without a prefix undercore, then with it.
4727 for ac_symprfx in "" "_"; do
4729 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4730 symxfrm="\\1 $ac_symprfx\\2 \\2"
4732 # Write the raw and C identifiers.
4733 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4735 # Check to see that the pipe works correctly.
4739 cat > conftest.$ac_ext <<EOF
4744 void nm_test_func(){}
4748 int main(){nm_test_var='a';nm_test_func();return(0);}
4751 if AC_TRY_EVAL(ac_compile); then
4752 # Now try to grab the symbols.
4754 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
4755 # Try sorting and uniquifying the output.
4756 if sort "$nlist" | uniq > "$nlist"T; then
4757 mv -f "$nlist"T "$nlist"
4762 # Make sure that we snagged all the symbols we need.
4763 if grep ' nm_test_var$' "$nlist" >/dev/null; then
4764 if grep ' nm_test_func$' "$nlist" >/dev/null; then
4765 cat <<EOF > conftest.$ac_ext
4771 # Now generate the symbol file.
4772 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
4774 cat <<EOF >> conftest.$ac_ext
4775 #if defined (__STDC__) && __STDC__
4776 # define lt_ptr_t void *
4778 # define lt_ptr_t char *
4782 /* The mapping between symbol names and symbols. */
4787 lt_preloaded_symbols[[]] =
4790 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
4791 cat <<\EOF >> conftest.$ac_ext
4799 # Now try linking the two files.
4800 mv conftest.$ac_objext conftstm.$ac_objext
4801 lt_save_LIBS="$LIBS"
4802 lt_save_CFLAGS="$CFLAGS"
4803 LIBS="conftstm.$ac_objext"
4804 CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4805 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4808 LIBS="$lt_save_LIBS"
4809 CFLAGS="$lt_save_CFLAGS"
4811 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4814 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4817 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4820 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4821 cat conftest.$ac_ext >&5
4823 rm -f conftest* conftst*
4825 # Do not use the global_symbol_pipe unless it works.
4826 if test "$pipe_works" = yes; then
4829 lt_cv_sys_global_symbol_pipe=
4833 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4834 lt_cv_sys_global_symbol_to_cdecl=
4836 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4837 AC_MSG_RESULT(failed)
4841 ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
4844 # AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
4845 # ---------------------------------------
4846 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
4847 [_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
4848 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4849 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
4851 AC_MSG_CHECKING([for $compiler option to produce PIC])
4853 # C++ specific cases for pic, static, wl, etc.
4854 if test "$GXX" = yes; then
4855 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4856 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
4860 # All AIX code is PIC.
4861 if test "$host_cpu" = ia64; then
4862 # AIX 5 now supports IA64 processor
4863 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4867 # FIXME: we need at least 68020 code to build shared libraries, but
4868 # adding the `-m68020' flag to GCC prevents building anything better,
4870 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4872 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4873 # PIC is the default for these OSes.
4875 mingw* | os2* | pw32*)
4876 # This hack is so that the source file can tell whether it is being
4877 # built for inclusion in a dll (and should export symbols for example).
4878 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
4880 darwin* | rhapsody*)
4881 # PIC is the default on this platform
4882 # Common symbols not allowed in MH_DYLIB files
4883 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4886 # DJGPP does not support shared libraries at all
4887 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4890 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4891 # Instead, we relocate shared libraries at runtime.
4894 if test -d /usr/nec; then
4895 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4899 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4905 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4910 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4916 # All AIX code is PIC.
4917 if test "$host_cpu" = ia64; then
4918 # AIX 5 now supports IA64 processor
4919 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4921 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4925 case $cc_basename in
4927 # Green Hills C++ Compiler
4928 # _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"
4933 # PIC is the default on this platform
4934 # Common symbols not allowed in MH_DYLIB files
4935 case $cc_basename in
4937 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
4938 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4943 case $cc_basename in
4945 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4948 # Green Hills C++ Compiler
4949 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4955 freebsd* | kfreebsd*-gnu | dragonfly*)
4956 # FreeBSD uses GNU C++
4958 hpux9* | hpux10* | hpux11*)
4959 case $cc_basename in
4961 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4962 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4963 if test "$host_cpu" != ia64; then
4964 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4968 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4969 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4975 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4984 # This is c89, which is MS Visual C++ (no shared libs)
4985 # Anyone wants to do a port?
4987 irix5* | irix6* | nonstopux*)
4988 case $cc_basename in
4990 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4991 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4992 # CC pic flag -KPIC is the default.
4999 case $cc_basename in
5002 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5003 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5007 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5008 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5009 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5012 # Portland Group C++ compiler.
5013 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5014 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5015 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5019 # Make sure the PIC flag is empty. It appears that all Alpha
5020 # Linux and Compaq Tru64 Unix objects are PIC.
5021 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5022 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5033 case $cc_basename in
5035 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5043 osf3* | osf4* | osf5*)
5044 case $cc_basename in
5046 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5049 # Rational C++ 2.4.1
5050 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5053 # Digital/Compaq C++
5054 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5055 # Make sure the PIC flag is empty. It appears that all Alpha
5056 # Linux and Compaq Tru64 Unix objects are PIC.
5057 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5058 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5067 case $cc_basename in
5069 # Sun C++ 4.2, 5.x and Centerline C++
5070 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5071 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5072 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5075 # Green Hills C++ Compiler
5076 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5083 case $cc_basename in
5086 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5087 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5091 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5098 case $cc_basename in
5100 # NonStop-UX NCC 3.20
5101 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5107 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5108 case $cc_basename in
5110 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5111 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5112 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5119 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5125 if test "$GCC" = yes; then
5126 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5127 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5131 # All AIX code is PIC.
5132 if test "$host_cpu" = ia64; then
5133 # AIX 5 now supports IA64 processor
5134 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5139 # FIXME: we need at least 68020 code to build shared libraries, but
5140 # adding the `-m68020' flag to GCC prevents building anything better,
5142 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5145 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5146 # PIC is the default for these OSes.
5149 mingw* | pw32* | os2*)
5150 # This hack is so that the source file can tell whether it is being
5151 # built for inclusion in a dll (and should export symbols for example).
5152 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5155 darwin* | rhapsody*)
5156 # PIC is the default on this platform
5157 # Common symbols not allowed in MH_DYLIB files
5158 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5162 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5163 # Instead, we relocate shared libraries at runtime.
5167 # Just because we use GCC doesn't mean we suddenly get shared libraries
5168 # on systems that don't support them.
5169 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5174 if test -d /usr/nec; then
5175 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5180 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5187 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5193 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5197 # PORTME Check for flag to pass linker flags through the system compiler.
5200 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5201 if test "$host_cpu" = ia64; then
5202 # AIX 5 now supports IA64 processor
5203 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5205 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5209 # PIC is the default on this platform
5210 # Common symbols not allowed in MH_DYLIB files
5211 case $cc_basename in
5213 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
5214 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5219 mingw* | pw32* | os2*)
5220 # This hack is so that the source file can tell whether it is being
5221 # built for inclusion in a dll (and should export symbols for example).
5222 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5225 hpux9* | hpux10* | hpux11*)
5226 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5227 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5234 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5237 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5238 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5241 irix5* | irix6* | nonstopux*)
5242 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5243 # PIC (with -KPIC) is the default.
5244 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5248 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5249 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5253 case $cc_basename in
5255 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5256 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5257 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5259 pgcc* | pgf77* | pgf90* | pgf95*)
5260 # Portland Group compilers (*not* the Pentium gcc compiler,
5261 # which looks to be a dead project)
5262 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5263 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5264 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5267 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5268 # All Alpha code is PIC.
5269 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5274 osf3* | osf4* | osf5*)
5275 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5276 # All OSF/1 code is PIC.
5277 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5281 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5282 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5283 case $cc_basename in
5285 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5287 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5292 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5293 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5294 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5297 sysv4 | sysv4.2uw2* | sysv4.3*)
5298 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5299 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5300 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5304 if test -d /usr/nec ;then
5305 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5306 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5310 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5311 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5312 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5313 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5317 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5318 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5322 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5323 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5327 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5332 AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
5335 # Check to make sure the PIC flag actually works.
5337 if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
5338 AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
5339 _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
5340 [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
5341 [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
5343 *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5345 [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5346 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5349 # For platforms which do not support PIC, -DPIC is meaningless:
5351 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5354 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
5359 # Check to make sure the static flag actually works.
5361 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
5362 AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
5363 _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
5364 $lt_tmp_static_flag,
5366 [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
5370 # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
5371 # ------------------------------------
5372 # See if the linker supports building shared libraries.
5373 AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
5374 [AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5376 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5379 # If we're using GNU nm, then we don't want the "-C" option.
5380 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5381 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5382 _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'
5384 _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'
5388 _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5391 _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'
5394 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5399 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
5400 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5401 _LT_AC_TAGVAR(archive_cmds, $1)=
5402 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
5403 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
5404 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5405 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5406 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5407 _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
5408 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5409 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5410 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5411 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5412 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
5413 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5414 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
5415 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
5416 _LT_AC_TAGVAR(module_cmds, $1)=
5417 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
5418 _LT_AC_TAGVAR(always_export_symbols, $1)=no
5419 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5420 # include_expsyms should be a list of space-separated symbols to be *always*
5421 # included in the symbol list
5422 _LT_AC_TAGVAR(include_expsyms, $1)=
5423 # exclude_expsyms can be an extended regexp of symbols to exclude
5424 # it will be wrapped by ` (' and `)$', so one must not match beginning or
5425 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5426 # as well as any symbol that contains `d'.
5427 _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
5428 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5429 # platforms (ab)use it in PIC code, but their linkers get confused if
5430 # the symbol is explicitly referenced. Since portable code cannot
5431 # rely on this symbol name, it's probably fine to never include it in
5432 # preloaded symbol tables.
5433 extract_expsyms_cmds=
5434 # Just being paranoid about ensuring that cc_basename is set.
5435 _LT_CC_BASENAME([$compiler])
5437 cygwin* | mingw* | pw32*)
5438 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5439 # When not using gcc, we currently assume that we are using
5440 # Microsoft Visual C++.
5441 if test "$GCC" != yes; then
5446 # we just hope/assume this is gcc and not c89 (= MSVC++)
5454 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
5455 if test "$with_gnu_ld" = yes; then
5456 # If archive_cmds runs LD, not CC, wlarc should be empty
5459 # Set some defaults for GNU ld with shared library support. These
5460 # are reset later if shared libraries are not supported. Putting them
5461 # here allows them to be overridden if necessary.
5462 runpath_var=LD_RUN_PATH
5463 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
5464 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5465 # ancient GNU ld didn't support --whole-archive et. al.
5466 if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
5467 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5469 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5471 supports_anon_versioning=no
5472 case `$LD -v 2>/dev/null` in
5473 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5474 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5475 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5476 *\ 2.11.*) ;; # other 2.11 versions
5477 *) supports_anon_versioning=yes ;;
5480 # See if GNU ld supports shared libraries.
5482 aix3* | aix4* | aix5*)
5483 # On AIX/PPC, the GNU linker is very broken
5484 if test "$host_cpu" != ia64; then
5485 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5488 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
5489 *** to be unable to reliably create shared libraries on AIX.
5490 *** Therefore, libtool is disabling shared libraries support. If you
5491 *** really care for shared libraries, you may want to modify your PATH
5492 *** so that a non-GNU linker is found, and then restart.
5499 _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)'
5500 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5501 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5503 # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
5504 # that the semantics of dynamic libraries on AmigaOS, at least up
5505 # to version 4, is to share data among multiple programs linked
5506 # with the same dynamic library. Since this doesn't match the
5507 # behavior of shared libraries on other platforms, we can't use
5509 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5513 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5514 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5515 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5516 # support --undefined. This deserves some investigation. FIXME
5517 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5519 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5523 cygwin* | mingw* | pw32*)
5524 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5525 # as there is no search path for DLLs.
5526 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5527 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5528 _LT_AC_TAGVAR(always_export_symbols, $1)=no
5529 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5530 _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'
5532 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
5533 _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'
5534 # If the export-symbols file already is a .def file (1st line
5535 # is EXPORTS), use it as is; otherwise, prepend...
5536 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5537 cp $export_symbols $output_objdir/$soname.def;
5539 echo EXPORTS > $output_objdir/$soname.def;
5540 cat $export_symbols >> $output_objdir/$soname.def;
5542 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5544 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5549 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5550 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5551 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5552 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5553 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5554 # Instead, shared libraries are loaded at an image base (0x10000000 by
5555 # default) and relocated if they conflict, which is a slow very memory
5556 # consuming and fragmenting process. To avoid this, we pick a random,
5557 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
5558 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
5559 _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'
5560 _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'
5564 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5566 case $cc_basename,$host_cpu in
5567 pgcc*) # Portland Group C compiler
5568 _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'
5569 tmp_addflag=' $pic_flag'
5571 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
5572 _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'
5573 tmp_addflag=' $pic_flag -Mnomain' ;;
5574 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5575 tmp_addflag=' -i_dynamic' ;;
5576 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5577 tmp_addflag=' -i_dynamic -nofor_main' ;;
5578 ifc* | ifort*) # Intel Fortran compiler
5579 tmp_addflag=' -nofor_main' ;;
5581 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5583 if test $supports_anon_versioning = yes; then
5584 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
5585 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5586 $echo "local: *; };" >> $output_objdir/$libname.ver~
5587 $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5590 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5595 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5596 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5599 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5600 _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'
5605 if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
5606 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5609 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5610 *** create shared libraries on Solaris systems. Therefore, libtool
5611 *** is disabling shared libraries support. We urge you to upgrade GNU
5612 *** binutils to release 2.9.1 or newer. Another option is to modify
5613 *** your PATH or compiler configuration so that the native linker is
5614 *** used, and then restart.
5617 elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5618 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5619 _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'
5621 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5625 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5626 case `$LD -v 2>&1` in
5627 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5628 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5631 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
5632 *** reliably create shared libraries on SCO systems. Therefore, libtool
5633 *** is disabling shared libraries support. We urge you to upgrade GNU
5634 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5635 *** your PATH or compiler configuration so that the native linker is
5636 *** used, and then restart.
5641 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5642 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
5643 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
5644 _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'
5646 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5653 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5655 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5656 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5660 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5661 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5662 _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'
5664 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5669 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
5671 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5672 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5673 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5676 # PORTME fill in a description of your system's linker (not GNU ld)
5679 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5680 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5681 _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'
5682 # Note: this linker hardcodes the directories in LIBPATH if there
5683 # are no directories specified by -L.
5684 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5685 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5686 # Neither direct hardcoding nor static linking is supported with a
5688 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5693 if test "$host_cpu" = ia64; then
5694 # On IA64, the linker does run time linking by default, so we don't
5695 # have to do anything special.
5696 aix_use_runtimelinking=no
5697 exp_sym_flag='-Bexport'
5700 # If we're using GNU nm, then we don't want the "-C" option.
5701 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5702 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5703 _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'
5705 _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'
5707 aix_use_runtimelinking=no
5709 # Test if we are trying to use run time linking or normal
5710 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5711 # need to do runtime linking.
5712 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
5713 for ld_flag in $LDFLAGS; do
5714 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5715 aix_use_runtimelinking=yes
5722 exp_sym_flag='-bexport'
5723 no_entry_flag='-bnoentry'
5726 # When large executables or shared objects are built, AIX ld can
5727 # have problems creating the table of contents. If linking a library
5728 # or program results in "error TOC overflow" add -mminimal-toc to
5729 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5730 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5732 _LT_AC_TAGVAR(archive_cmds, $1)=''
5733 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5734 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
5735 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5737 if test "$GCC" = yes; then
5738 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5739 # We only want to do this on AIX 4.2 and lower, the check
5740 # below for broken collect2 doesn't work under 4.3+
5741 collect2name=`${CC} -print-prog-name=collect2`
5742 if test -f "$collect2name" && \
5743 strings "$collect2name" | grep resolve_lib_name >/dev/null
5745 # We have reworked collect2
5746 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5748 # We have old collect2
5749 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5750 # It fails to find uninstalled libraries when the uninstalled
5751 # path is not listed in the libpath. Setting hardcode_minus_L
5752 # to unsupported forces relinking
5753 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5754 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5755 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5759 shared_flag='-shared'
5760 if test "$aix_use_runtimelinking" = yes; then
5761 shared_flag="$shared_flag "'${wl}-G'
5765 if test "$host_cpu" = ia64; then
5766 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5767 # chokes on -Wl,-G. The following line is correct:
5770 if test "$aix_use_runtimelinking" = yes; then
5771 shared_flag='${wl}-G'
5773 shared_flag='${wl}-bM:SRE'
5778 # It seems that -bexpall does not export symbols beginning with
5779 # underscore (_), so it is better to generate a list of symbols to export.
5780 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5781 if test "$aix_use_runtimelinking" = yes; then
5782 # Warning - without using the other runtime loading flags (-brtl),
5783 # -berok will link without error, but may produce a broken library.
5784 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
5785 # Determine the default libpath from the value encoded in an empty executable.
5786 _LT_AC_SYS_LIBPATH_AIX
5787 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5788 _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"
5790 if test "$host_cpu" = ia64; then
5791 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5792 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5793 _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"
5795 # Determine the default libpath from the value encoded in an empty executable.
5796 _LT_AC_SYS_LIBPATH_AIX
5797 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5798 # Warning - without using the other run time loading flags,
5799 # -berok will link without error, but may produce a broken library.
5800 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5801 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5802 # Exported symbols can be pulled into shared objects from archives
5803 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5804 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
5805 # This is similar to how AIX traditionally builds its shared libraries.
5806 _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'
5812 _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)'
5813 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5814 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5815 # see comment about different semantics on the GNU ld section
5816 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5820 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5823 cygwin* | mingw* | pw32*)
5824 # When not using gcc, we currently assume that we are using
5825 # Microsoft Visual C++.
5826 # hardcode_libdir_flag_spec is actually meaningless, as there is
5827 # no search path for DLLs.
5828 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5829 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5830 # Tell ltmain to make .lib files, not .a files.
5832 # Tell ltmain to make .dll files, not .so files.
5834 # FIXME: Setting linknames here is a bad hack.
5835 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
5836 # The linker will automatically build a .lib file if we build a DLL.
5837 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
5838 # FIXME: Should let the user specify the lib program.
5839 _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
5840 _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
5841 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5844 darwin* | rhapsody*)
5846 rhapsody* | darwin1.[[012]])
5847 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
5850 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
5851 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
5853 case ${MACOSX_DEPLOYMENT_TARGET} in
5855 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
5858 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
5864 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
5865 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5866 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
5867 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5868 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
5869 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5870 if test "$GCC" = yes ; then
5871 output_verbose_link_cmd='echo'
5872 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
5873 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
5874 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
5875 _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}'
5876 _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}'
5878 case $cc_basename in
5880 output_verbose_link_cmd='echo'
5881 _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'
5882 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
5883 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
5884 _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}'
5885 _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}'
5888 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5895 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5896 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5897 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5901 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5904 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
5905 # support. Future versions do this automatically, but an explicit c++rt0.o
5906 # does not break anything, and helps significantly (at the cost of a little
5909 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
5910 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5911 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5912 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5915 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
5917 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5918 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5919 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5920 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5923 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5924 freebsd* | kfreebsd*-gnu | dragonfly*)
5925 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
5926 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5927 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5928 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5932 if test "$GCC" = yes; then
5933 _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'
5935 _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'
5937 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5938 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5939 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5941 # hardcode_minus_L: Not really in the search PATH,
5942 # but as the default location of the library.
5943 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5944 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5948 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
5949 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5951 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
5953 if test "$with_gnu_ld" = no; then
5954 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5955 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5957 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5958 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5960 # hardcode_minus_L: Not really in the search PATH,
5961 # but as the default location of the library.
5962 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5967 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
5970 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5973 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5976 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5982 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5985 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5988 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5992 if test "$with_gnu_ld" = no; then
5993 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5994 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5998 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
5999 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6000 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6003 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6004 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6006 # hardcode_minus_L: Not really in the search PATH,
6007 # but as the default location of the library.
6008 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6014 irix5* | irix6* | nonstopux*)
6015 if test "$GCC" = yes; then
6016 _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'
6018 _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'
6019 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6021 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6022 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6023 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6027 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6028 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6030 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6032 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6033 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6034 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6038 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6039 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6040 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6041 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6042 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6046 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6047 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6048 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6049 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6050 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6051 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6052 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6055 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6056 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6057 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6060 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6061 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6068 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6069 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6070 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6071 _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'
6072 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6076 if test "$GCC" = yes; then
6077 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6078 _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'
6080 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6081 _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'
6083 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6084 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6087 osf4* | osf5*) # as osf3* with the addition of -msym flag
6088 if test "$GCC" = yes; then
6089 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6090 _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'
6091 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6093 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6094 _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'
6095 _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~
6096 $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'
6098 # Both c and cxx compiler support -rpath directly
6099 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6101 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6105 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6106 if test "$GCC" = yes; then
6108 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6109 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6110 $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
6113 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6114 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6115 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6117 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6118 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6120 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6122 # The compiler driver will combine linker options so we
6123 # cannot just pass the convience library names through
6124 # without $wl, iff we do not link with $LD.
6125 # Luckily, gcc supports the same syntax we need for Sun Studio.
6126 # Supported since Solaris 2.6 (maybe 2.5.1?)
6129 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
6131 _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' ;;
6134 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6138 if test "x$host_vendor" = xsequent; then
6139 # Use $CC to link under sequent, because it throws in some extra .o
6140 # files that make .init and .fini sections work.
6141 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6143 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6145 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6146 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6147 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6148 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6152 case $host_vendor in
6154 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6155 _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6158 ## LD is ld it makes a PLAMLIB
6159 ## CC just makes a GrossModule.
6160 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6161 _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6162 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6165 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6166 _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6169 runpath_var='LD_RUN_PATH'
6170 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6174 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6175 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6176 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6180 if test -d /usr/nec; then
6181 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6182 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6183 runpath_var=LD_RUN_PATH
6184 hardcode_runpath_var=yes
6185 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
6189 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7*)
6190 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6191 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6192 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6193 runpath_var='LD_RUN_PATH'
6195 if test "$GCC" = yes; then
6196 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6197 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6199 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6200 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6204 sysv5* | sco3.2v5* | sco5v6*)
6205 # Note: We can NOT use -z defs as we might desire, because we do not
6206 # link with -lc, and that would cause any symbols used from libc to
6207 # always be unresolved, which means just about no library would
6208 # ever link correctly. If we're not using GNU ld we use -z text
6209 # though, which does catch some bad symbols but isn't as heavy-handed
6211 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6212 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6213 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6214 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6215 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
6216 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6217 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6218 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6219 runpath_var='LD_RUN_PATH'
6221 if test "$GCC" = yes; then
6222 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
6223 _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'
6225 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
6226 _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'
6231 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6232 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6233 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6237 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6242 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
6243 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6246 # Do we need to explicitly link libc?
6248 case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
6250 # Assume -lc should be added
6251 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6253 if test "$enable_shared" = yes && test "$GCC" = yes; then
6254 case $_LT_AC_TAGVAR(archive_cmds, $1) in
6256 # FIXME: we may have to deal with multi-command sequences.
6259 # Test whether the compiler implicitly links with -lc since on some
6260 # systems, -lgcc has to come before -lc. If gcc already passes -lc
6261 # to ld, don't add -lc before -lgcc.
6262 AC_MSG_CHECKING([whether -lc should be explicitly linked in])
6264 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
6266 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6269 libobjs=conftest.$ac_objext
6271 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
6272 pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
6278 lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
6279 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
6280 if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
6282 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6284 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6286 _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6288 cat conftest.err 1>&5
6291 AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
6297 ])# AC_LIBTOOL_PROG_LD_SHLIBS
6300 # _LT_AC_FILE_LTDLL_C
6301 # -------------------
6302 # Be careful that the start marker always follows a newline.
6303 AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
6304 # /* ltdll.c starts here */
6305 # #define WIN32_LEAN_AND_MEAN
6306 # #include <windows.h>
6307 # #undef WIN32_LEAN_AND_MEAN
6308 # #include <stdio.h>
6310 # #ifndef __CYGWIN__
6311 # # ifdef __CYGWIN32__
6312 # # define __CYGWIN__ __CYGWIN32__
6316 # #ifdef __cplusplus
6319 # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
6320 # #ifdef __cplusplus
6325 # #include <cygwin/cygwin_dll.h>
6326 # DECLARE_CYGWIN_DLL( DllMain );
6328 # HINSTANCE __hDllInstance_base;
6331 # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
6333 # __hDllInstance_base = hInst;
6336 # /* ltdll.c ends here */
6337 ])# _LT_AC_FILE_LTDLL_C
6340 # _LT_AC_TAGVAR(VARNAME, [TAGNAME])
6341 # ---------------------------------
6342 AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
6346 AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
6347 AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
6348 AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
6349 AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
6350 AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
6351 AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
6352 AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
6354 # This is just to silence aclocal about the macro not being used
6355 ifelse([AC_DISABLE_FAST_INSTALL])
6357 AC_DEFUN([LT_AC_PROG_GCJ],
6358 [AC_CHECK_TOOL(GCJ, gcj, no)
6359 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
6363 AC_DEFUN([LT_AC_PROG_RC],
6364 [AC_CHECK_TOOL(RC, windres, no)
6367 ############################################################
6368 # NOTE: This macro has been submitted for inclusion into #
6369 # GNU Autoconf as AC_PROG_SED. When it is available in #
6370 # a released version of Autoconf we should remove this #
6371 # macro and use it instead. #
6372 ############################################################
6375 # Check for a fully-functional sed program, that truncates
6376 # as few characters as possible. Prefer GNU sed if found.
6377 AC_DEFUN([LT_AC_PROG_SED],
6378 [AC_MSG_CHECKING([for a sed that does not truncate output])
6379 AC_CACHE_VAL(lt_cv_path_SED,
6380 [# Loop through the user's path and test for sed and gsed.
6381 # Then use that list of sed's as ones to test for truncation.
6382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6386 test -z "$as_dir" && as_dir=.
6387 for lt_ac_prog in sed gsed; do
6388 for ac_exec_ext in '' $ac_executable_extensions; do
6389 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
6390 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
6397 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
6398 # along with /bin/sed that truncates output.
6399 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
6400 test ! -f $lt_ac_sed && continue
6401 cat /dev/null > conftest.in
6403 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
6404 # Check for GNU sed and select it if it is found.
6405 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
6406 lt_cv_path_SED=$lt_ac_sed
6410 cat conftest.in conftest.in >conftest.tmp
6411 mv conftest.tmp conftest.in
6412 cp conftest.in conftest.nl
6414 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
6415 cmp -s conftest.out conftest.nl || break
6416 # 10000 chars as input seems more than enough
6417 test $lt_ac_count -gt 10 && break
6418 lt_ac_count=`expr $lt_ac_count + 1`
6419 if test $lt_ac_count -gt $lt_ac_max; then
6420 lt_ac_max=$lt_ac_count
6421 lt_cv_path_SED=$lt_ac_sed
6427 AC_MSG_RESULT([$SED])
6429 ## ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*-
6430 ## Copyright (C) 1999-2000 Free Software Foundation, Inc.
6432 ## This file is free software; the Free Software Foundation gives
6433 ## unlimited permission to copy and/or distribute it, with or without
6434 ## modifications, as long as this notice is preserved.
6438 # Clients of libltdl can use this macro to allow the installer to
6439 # choose between a shipped copy of the ltdl sources or a preinstalled
6440 # version of the library.
6441 AC_DEFUN([AC_WITH_LTDL],
6442 [AC_REQUIRE([AC_LIB_LTDL])
6446 # Unless the user asks us to check, assume no installed ltdl exists.
6447 use_installed_libltdl=no
6449 AC_ARG_WITH([included_ltdl],
6450 [ --with-included-ltdl use the GNU ltdl sources included here])
6452 if test "x$with_included_ltdl" != xyes; then
6453 # We are not being forced to use the included libltdl sources, so
6454 # decide whether there is a useful installed version we can use.
6455 AC_CHECK_HEADER([ltdl.h],
6456 [AC_CHECK_LIB([ltdl], [lt_dlcaller_register],
6457 [with_included_ltdl=no],
6458 [with_included_ltdl=yes])
6462 if test "x$enable_ltdl_install" != xyes; then
6463 # If the user did not specify an installable libltdl, then default
6464 # to a convenience lib.
6465 AC_LIBLTDL_CONVENIENCE
6468 if test "x$with_included_ltdl" = xno; then
6469 # If the included ltdl is not to be used. then Use the
6470 # preinstalled libltdl we found.
6471 AC_DEFINE([HAVE_LTDL], [1],
6472 [Define this if a modern libltdl is already installed])
6476 # Report our decision...
6477 AC_MSG_CHECKING([whether to use included libltdl])
6478 AC_MSG_RESULT([$with_included_ltdl])
6480 dnl AC_CONFIG_SUBDIRS([libltdl])
6486 # Perform all the checks necessary for compilation of the ltdl objects
6487 # -- including compiler checks and header checks.
6488 AC_DEFUN([AC_LIB_LTDL],
6490 AC_REQUIRE([AC_PROG_CC])
6491 AC_REQUIRE([AC_C_CONST])
6492 AC_REQUIRE([AC_HEADER_STDC])
6493 AC_REQUIRE([AC_HEADER_DIRENT])
6494 AC_REQUIRE([_LT_AC_CHECK_DLFCN])
6495 AC_REQUIRE([AC_LTDL_ENABLE_INSTALL])
6496 AC_REQUIRE([AC_LTDL_SHLIBEXT])
6497 AC_REQUIRE([AC_LTDL_SHLIBPATH])
6498 AC_REQUIRE([AC_LTDL_SYSSEARCHPATH])
6499 AC_REQUIRE([AC_LTDL_OBJDIR])
6500 AC_REQUIRE([AC_LTDL_DLPREOPEN])
6501 AC_REQUIRE([AC_LTDL_DLLIB])
6502 AC_REQUIRE([AC_LTDL_SYMBOL_USCORE])
6503 AC_REQUIRE([AC_LTDL_DLSYM_USCORE])
6504 AC_REQUIRE([AC_LTDL_SYS_DLOPEN_DEPLIBS])
6505 AC_REQUIRE([AC_LTDL_FUNC_ARGZ])
6507 AC_CHECK_HEADERS([assert.h ctype.h errno.h malloc.h memory.h stdlib.h \
6509 AC_CHECK_HEADERS([dl.h sys/dl.h dld.h mach-o/dyld.h])
6510 AC_CHECK_HEADERS([string.h strings.h], [break])
6512 AC_CHECK_FUNCS([strchr index], [break])
6513 AC_CHECK_FUNCS([strrchr rindex], [break])
6514 AC_CHECK_FUNCS([memcpy bcopy], [break])
6515 AC_CHECK_FUNCS([memmove strcmp])
6516 AC_CHECK_FUNCS([closedir opendir readdir])
6520 # AC_LTDL_ENABLE_INSTALL
6521 # ----------------------
6522 AC_DEFUN([AC_LTDL_ENABLE_INSTALL],
6523 [AC_ARG_ENABLE([ltdl-install],
6524 [AC_HELP_STRING([--enable-ltdl-install], [install libltdl])])
6526 AM_CONDITIONAL(INSTALL_LTDL, test x"${enable_ltdl_install-no}" != xno)
6527 AM_CONDITIONAL(CONVENIENCE_LTDL, test x"${enable_ltdl_convenience-no}" != xno)
6528 ])# AC_LTDL_ENABLE_INSTALL
6531 # AC_LTDL_SYS_DLOPEN_DEPLIBS
6532 # --------------------------
6533 AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS],
6534 [AC_REQUIRE([AC_CANONICAL_HOST])
6535 AC_CACHE_CHECK([whether deplibs are loaded by dlopen],
6536 [libltdl_cv_sys_dlopen_deplibs],
6537 [# PORTME does your system automatically load deplibs for dlopen?
6538 # or its logical equivalent (e.g. shl_load for HP-UX < 11)
6539 # For now, we just catch OSes we know something about -- in the
6540 # future, we'll try test this programmatically.
6541 libltdl_cv_sys_dlopen_deplibs=unknown
6543 aix3*|aix4.1.*|aix4.2.*)
6544 # Unknown whether this is true for these versions of AIX, but
6545 # we want this `case' here to explicitly catch those versions.
6546 libltdl_cv_sys_dlopen_deplibs=unknown
6549 libltdl_cv_sys_dlopen_deplibs=yes
6552 # Assuming the user has installed a libdl from somewhere, this is true
6553 # If you are looking for one http://www.opendarwin.org/projects/dlcompat
6554 libltdl_cv_sys_dlopen_deplibs=yes
6556 gnu* | linux* | kfreebsd*-gnu | knetbsd*-gnu)
6557 # GNU and its variants, using gnu ld.so (Glibc)
6558 libltdl_cv_sys_dlopen_deplibs=yes
6561 libltdl_cv_sys_dlopen_deplibs=yes
6564 libltdl_cv_sys_dlopen_deplibs=yes
6566 irix[[12345]]*|irix6.[[01]]*)
6567 # Catch all versions of IRIX before 6.2, and indicate that we don't
6568 # know how it worked for any of those versions.
6569 libltdl_cv_sys_dlopen_deplibs=unknown
6572 # The case above catches anything before 6.2, and it's known that
6573 # at 6.2 and later dlopen does load deplibs.
6574 libltdl_cv_sys_dlopen_deplibs=yes
6577 libltdl_cv_sys_dlopen_deplibs=yes
6580 libltdl_cv_sys_dlopen_deplibs=yes
6583 # dlopen did load deplibs (at least at 4.x), but until the 5.x series,
6584 # it did *not* use an RPATH in a shared library to find objects the
6585 # library depends on, so we explictly say `no'.
6586 libltdl_cv_sys_dlopen_deplibs=no
6588 osf5.0|osf5.0a|osf5.1)
6589 # dlopen *does* load deplibs and with the right loader patch applied
6590 # it even uses RPATH in a shared library to search for shared objects
6591 # that the library depends on, but there's no easy way to know if that
6592 # patch is installed. Since this is the case, all we can really
6593 # say is unknown -- it depends on the patch being installed. If
6594 # it is, this changes to `yes'. Without it, it would be `no'.
6595 libltdl_cv_sys_dlopen_deplibs=unknown
6598 # the two cases above should catch all versions of osf <= 5.1. Read
6599 # the comments above for what we know about them.
6600 # At > 5.1, deplibs are loaded *and* any RPATH in a shared library
6601 # is used to find them so we can finally say `yes'.
6602 libltdl_cv_sys_dlopen_deplibs=yes
6605 libltdl_cv_sys_dlopen_deplibs=yes
6607 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
6608 libltdl_cv_sys_dlopen_deplibs=yes
6612 if test "$libltdl_cv_sys_dlopen_deplibs" != yes; then
6613 AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1],
6614 [Define if the OS needs help to load dependent libraries for dlopen().])
6616 ])# AC_LTDL_SYS_DLOPEN_DEPLIBS
6621 AC_DEFUN([AC_LTDL_SHLIBEXT],
6622 [AC_REQUIRE([AC_LIBTOOL_SYS_DYNAMIC_LINKER])
6623 AC_CACHE_CHECK([which extension is used for loadable modules],
6624 [libltdl_cv_shlibext],
6627 eval libltdl_cv_shlibext=$shrext_cmds
6629 if test -n "$libltdl_cv_shlibext"; then
6630 AC_DEFINE_UNQUOTED([LTDL_SHLIB_EXT], ["$libltdl_cv_shlibext"],
6631 [Define to the extension used for shared libraries, say, ".so".])
6633 ])# AC_LTDL_SHLIBEXT
6638 AC_DEFUN([AC_LTDL_SHLIBPATH],
6639 [AC_REQUIRE([AC_LIBTOOL_SYS_DYNAMIC_LINKER])
6640 AC_CACHE_CHECK([which variable specifies run-time library path],
6641 [libltdl_cv_shlibpath_var], [libltdl_cv_shlibpath_var="$shlibpath_var"])
6642 if test -n "$libltdl_cv_shlibpath_var"; then
6643 AC_DEFINE_UNQUOTED([LTDL_SHLIBPATH_VAR], ["$libltdl_cv_shlibpath_var"],
6644 [Define to the name of the environment variable that determines the dynamic library search path.])
6646 ])# AC_LTDL_SHLIBPATH
6649 # AC_LTDL_SYSSEARCHPATH
6650 # ---------------------
6651 AC_DEFUN([AC_LTDL_SYSSEARCHPATH],
6652 [AC_REQUIRE([AC_LIBTOOL_SYS_DYNAMIC_LINKER])
6653 AC_CACHE_CHECK([for the default library search path],
6654 [libltdl_cv_sys_search_path],
6655 [libltdl_cv_sys_search_path="$sys_lib_dlsearch_path_spec"])
6656 if test -n "$libltdl_cv_sys_search_path"; then
6658 for dir in $libltdl_cv_sys_search_path; do
6659 if test -z "$sys_search_path"; then
6660 sys_search_path="$dir"
6662 sys_search_path="$sys_search_path$PATH_SEPARATOR$dir"
6665 AC_DEFINE_UNQUOTED([LTDL_SYSSEARCHPATH], ["$sys_search_path"],
6666 [Define to the system default library search path.])
6668 ])# AC_LTDL_SYSSEARCHPATH
6673 AC_DEFUN([AC_LTDL_OBJDIR],
6674 [AC_CACHE_CHECK([for objdir],
6675 [libltdl_cv_objdir],
6676 [libltdl_cv_objdir="$objdir"
6677 if test -n "$objdir"; then
6680 rm -f .libs 2>/dev/null
6681 mkdir .libs 2>/dev/null
6682 if test -d .libs; then
6683 libltdl_cv_objdir=.libs
6685 # MS-DOS does not allow filenames that begin with a dot.
6686 libltdl_cv_objdir=_libs
6688 rmdir .libs 2>/dev/null
6691 AC_DEFINE_UNQUOTED([LTDL_OBJDIR], ["$libltdl_cv_objdir/"],
6692 [Define to the sub-directory in which libtool stores uninstalled libraries.])
6698 AC_DEFUN([AC_LTDL_DLPREOPEN],
6699 [AC_REQUIRE([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])
6700 AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen],
6701 [libltdl_cv_preloaded_symbols],
6702 [if test -n "$lt_cv_sys_global_symbol_pipe"; then
6703 libltdl_cv_preloaded_symbols=yes
6705 libltdl_cv_preloaded_symbols=no
6708 if test x"$libltdl_cv_preloaded_symbols" = xyes; then
6709 AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1],
6710 [Define if libtool can extract symbol lists from object files.])
6712 ])# AC_LTDL_DLPREOPEN
6717 AC_DEFUN([AC_LTDL_DLLIB],
6722 AC_CHECK_FUNC([shl_load],
6723 [AC_DEFINE([HAVE_SHL_LOAD], [1],
6724 [Define if you have the shl_load function.])],
6725 [AC_CHECK_LIB([dld], [shl_load],
6726 [AC_DEFINE([HAVE_SHL_LOAD], [1],
6727 [Define if you have the shl_load function.])
6728 LIBADD_DL="$LIBADD_DL -ldld"],
6729 [AC_CHECK_LIB([dl], [dlopen],
6730 [AC_DEFINE([HAVE_LIBDL], [1],
6731 [Define if you have the libdl library or equivalent.])
6732 LIBADD_DL="-ldl" libltdl_cv_lib_dl_dlopen="yes"],
6733 [AC_TRY_LINK([#if HAVE_DLFCN_H
6738 [AC_DEFINE([HAVE_LIBDL], [1],
6739 [Define if you have the libdl library or equivalent.]) libltdl_cv_func_dlopen="yes"],
6740 [AC_CHECK_LIB([svld], [dlopen],
6741 [AC_DEFINE([HAVE_LIBDL], [1],
6742 [Define if you have the libdl library or equivalent.])
6743 LIBADD_DL="-lsvld" libltdl_cv_func_dlopen="yes"],
6744 [AC_CHECK_LIB([dld], [dld_link],
6745 [AC_DEFINE([HAVE_DLD], [1],
6746 [Define if you have the GNU dld library.])
6747 LIBADD_DL="$LIBADD_DL -ldld"],
6748 [AC_CHECK_FUNC([_dyld_func_lookup],
6749 [AC_DEFINE([HAVE_DYLD], [1],
6750 [Define if you have the _dyld_func_lookup function.])])
6758 if test x"$libltdl_cv_func_dlopen" = xyes || test x"$libltdl_cv_lib_dl_dlopen" = xyes
6760 lt_save_LIBS="$LIBS"
6761 LIBS="$LIBS $LIBADD_DL"
6762 AC_CHECK_FUNCS([dlerror])
6763 LIBS="$lt_save_LIBS"
6769 # AC_LTDL_SYMBOL_USCORE
6770 # ---------------------
6771 # does the compiler prefix global symbols with an underscore?
6772 AC_DEFUN([AC_LTDL_SYMBOL_USCORE],
6773 [AC_REQUIRE([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])
6774 AC_CACHE_CHECK([for _ prefix in compiled symbols],
6775 [ac_cv_sys_symbol_underscore],
6776 [ac_cv_sys_symbol_underscore=no
6777 cat > conftest.$ac_ext <<EOF
6778 void nm_test_func(){}
6779 int main(){nm_test_func;return 0;}
6781 if AC_TRY_EVAL(ac_compile); then
6782 # Now try to grab the symbols.
6783 ac_nlist=conftest.nm
6784 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then
6785 # See whether the symbols have a leading underscore.
6786 if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then
6787 ac_cv_sys_symbol_underscore=yes
6789 if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then
6792 echo "configure: cannot find nm_test_func in $ac_nlist" >&AC_FD_CC
6796 echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AC_FD_CC
6799 echo "configure: failed program was:" >&AC_FD_CC
6800 cat conftest.c >&AC_FD_CC
6804 ])# AC_LTDL_SYMBOL_USCORE
6807 # AC_LTDL_DLSYM_USCORE
6808 # --------------------
6809 AC_DEFUN([AC_LTDL_DLSYM_USCORE],
6810 [AC_REQUIRE([AC_LTDL_SYMBOL_USCORE])
6811 if test x"$ac_cv_sys_symbol_underscore" = xyes; then
6812 if test x"$libltdl_cv_func_dlopen" = xyes ||
6813 test x"$libltdl_cv_lib_dl_dlopen" = xyes ; then
6814 AC_CACHE_CHECK([whether we have to add an underscore for dlsym],
6815 [libltdl_cv_need_uscore],
6816 [libltdl_cv_need_uscore=unknown
6818 LIBS="$LIBS $LIBADD_DL"
6819 _LT_AC_TRY_DLOPEN_SELF(
6820 [libltdl_cv_need_uscore=no], [libltdl_cv_need_uscore=yes],
6821 [], [libltdl_cv_need_uscore=cross])
6827 if test x"$libltdl_cv_need_uscore" = xyes; then
6828 AC_DEFINE([NEED_USCORE], [1],
6829 [Define if dlsym() requires a leading underscore in symbol names.])
6831 ])# AC_LTDL_DLSYM_USCORE
6835 AC_DEFUN([AC_LTDL_FUNC_ARGZ],
6836 [AC_CHECK_HEADERS([argz.h])
6838 AC_CHECK_TYPES([error_t],
6840 [AC_DEFINE([error_t], [int],
6841 [Define to a type to use for `error_t' if it is not otherwise available.])],
6846 AC_CHECK_FUNCS([argz_append argz_create_sep argz_insert argz_next argz_stringify])
6847 ])# AC_LTDL_FUNC_ARGZ
6849 dnl compatibility stubs for libtool 2.x, but when using libtool 1.x.
6851 [AC_MSG_ERROR([You shouldn't be here!])
6854 AC_DEFUN([LTDL_INIT],
6855 [AC_MSG_ERROR([You shouldn't be here!])