1 dnl $Id: aclocal.m4,v 1.19 2006/07/12 19:53:04 ghudson Exp $
3 dnl Copyright 1996 by the Massachusetts Institute of Technology.
5 dnl Permission to use, copy, modify, and distribute this
6 dnl software and its documentation for any purpose and without
7 dnl fee is hereby granted, provided that the above copyright
8 dnl notice appear in all copies and that both that copyright
9 dnl notice and this permission notice appear in supporting
10 dnl documentation, and that the name of M.I.T. not be used in
11 dnl advertising or publicity pertaining to distribution of the
12 dnl software without specific, written prior permission.
13 dnl M.I.T. makes no representations about the suitability of
14 dnl this software for any purpose. It is provided "as is"
15 dnl without express or implied warranty.
17 dnl This file provides local macros for packages which use specific
18 dnl external libraries. The public macros are:
20 dnl ATHENA_UTIL_COM_ERR
21 dnl Generates error if com_err not found.
23 dnl Generates error if ss not found.
25 dnl Sets REGEX_LIBS if rx library used; ensures POSIX
28 dnl Sets MOTIF_LIBS and defines HAVE_MOTIF if Motif used.
29 dnl ATHENA_MOTIF_REQUIRED
30 dnl Generates error if Motif not found.
32 dnl Sets AFS_LIBS and defines HAVE_AFS if AFS used. Pass
33 dnl in an argument giving the desired AFS libraries;
34 dnl AFS_LIBS will be set to that value if AFS is found.
35 dnl AFS_DIR will be set to the prefix given.
36 dnl ATHENA_AFS_REQUIRED
37 dnl Generates error if AFS libraries not found. AFS_DIR
38 dnl will be set to the prefix given.
40 dnl Sets KRB4_LIBS and defines HAVE_KRB4 if krb4 used.
41 dnl ATHENA_KRB4_REQUIRED
42 dnl Generates error if krb4 not found. Sets KRB4_LIBS
43 dnl otherwise. (Special behavior because krb4 libraries
44 dnl may be different if using krb4 compatibility libraries
47 dnl Sets KRB5_LIBS and defines HAVE_KRB5 if krb5 used.
48 dnl ATHENA_KRB5_REQUIRED
49 dnl Generates error if krb5 not found.
51 dnl Sets HESIOD_LIBS and defines HAVE_HESIOD if Hesiod
53 dnl ATHENA_HESIOD_REQUIRED
54 dnl Generates error if Hesiod not found.
56 dnl Sets ARES_LIBS and defines HAVE_ARES if libares
58 dnl ATHENA_ARES_REQUIRED
59 dnl Generates error if libares not found.
61 dnl Sets ZEPHYR_LIBS and defines HAVE_ZEPHYR if zephyr
63 dnl ATHENA_ZEPHYR_REQUIRED
64 dnl Generates error if zephyr not found.
66 dnl All of the macros may extend CPPFLAGS and LDFLAGS to let the
67 dnl compiler find the requested libraries. Put ATHENA_UTIL_COM_ERR
68 dnl and ATHENA_UTIL_SS before ATHENA_AFS or ATHENA_AFS_REQUIRED; there
69 dnl is a com_err library in the AFS libraries which requires -lutil.
71 dnl ----- com_err -----
73 AC_DEFUN([ATHENA_UTIL_COM_ERR],
75 [ --with-com_err=PREFIX Specify location of com_err],
76 [com_err="$withval"], [com_err=yes])
77 if test "$com_err" != no; then
78 if test "$com_err" != yes; then
79 CPPFLAGS="$CPPFLAGS -I$com_err/include"
80 LDFLAGS="$LDFLAGS -L$com_err/lib"
82 AC_CHECK_LIB(com_err, com_err, :,
83 [AC_MSG_ERROR(com_err library not found)])
85 AC_MSG_ERROR(This package requires com_err.)
90 AC_DEFUN([ATHENA_UTIL_SS],
92 [ --with-ss=PREFIX Specify location of ss (requires com_err)],
93 [ss="$withval"], [ss=yes])
94 if test "$ss" != no; then
95 if test "$ss" != yes; then
96 CPPFLAGS="$CPPFLAGS -I$ss/include"
97 LDFLAGS="$LDFLAGS -L$ss/lib"
99 AC_CHECK_LIB(curses, initscr)
100 AC_CHECK_LIB(readline, readline)
101 AC_CHECK_LIB(ss, ss_perror, :,
102 [AC_MSG_ERROR(ss library not found)], -lcom_err)
104 AC_MSG_ERROR(This package requires ss.)
107 dnl ----- Regular expressions -----
109 AC_DEFUN([ATHENA_REGEXP],
111 [ --with-regex=PREFIX Use installed regex library],
112 [regex="$withval"], [regex=no])
113 if test "$regex" != no; then
114 if test "$regex" != yes; then
115 CPPFLAGS="$CPPFLAGS -I$regex/include"
116 LDFLAGS="$LDFLAGS -L$regex/lib"
118 AC_CHECK_LIB(regex, regcomp, REGEX_LIBS=-lregex,
119 [AC_MSG_ERROR(regex library not found)])
121 AC_CHECK_FUNC(regcomp, :,
122 [AC_MSG_ERROR(can't find POSIX regexp support)])
124 AC_SUBST(REGEX_LIBS)])
126 dnl ----- Motif -----
128 AC_DEFUN([ATHENA_MOTIF_CHECK],
129 [if test "$motif" != yes; then
130 CPPFLAGS="$CPPFLAGS -I$motif/include"
131 LDFLAGS="$LDFLAGS -L$motif/lib"
133 AC_CHECK_LIB(Xm, XmStringFree, :, [AC_MSG_ERROR(Motif library not found)])])
135 AC_DEFUN([ATHENA_MOTIF],
137 [ --with-motif=PREFIX Use Motif],
138 [motif="$withval"], [motif=no])
139 if test "$motif" != no; then
142 AC_DEFINE(HAVE_MOTIF)
144 AC_SUBST(MOTIF_LIBS)])
146 AC_DEFUN([ATHENA_MOTIF_REQUIRED],
148 [ --with-motif=PREFIX Specify location of Motif],
149 [motif="$withval"], [motif=yes])
150 if test "$motif" != no; then
153 AC_MSG_ERROR(This package requires Motif.)
158 AC_DEFUN([ATHENA_AFS_CHECK],
159 [AC_CHECK_FUNC(insque, :, AC_CHECK_LIB(compat, insque))
160 AC_CHECK_FUNC(gethostbyname, :, AC_CHECK_LIB(nsl, gethostbyname))
161 AC_CHECK_FUNC(socket, :, AC_CHECK_LIB(socket, socket))
162 AC_CHECK_FUNC(res_send, :, AC_CHECK_LIB(resolv, res_send))
163 if test "$afs" != yes; then
164 CPPFLAGS="$CPPFLAGS -I$afs/include"
165 LDFLAGS="$LDFLAGS -L$afs/lib -L$afs/lib/afs"
167 AC_CHECK_LIB(sys, pioctl, :, [AC_MSG_ERROR(AFS libraries not found)],
168 -lrx -llwp -lsys -lafsutil)
172 dnl Specify desired AFS libraries as a parameter.
173 AC_DEFUN([ATHENA_AFS],
175 [ --with-afs=PREFIX Use AFS libraries],
176 [afs="$withval"], [afs=no])
177 if test "$afs" != no; then
184 AC_DEFUN([ATHENA_AFS_REQUIRED],
186 [ --with-afs=PREFIX Specify location of AFS libraries],
187 [afs="$withval"], [afs=/usr/afsws])
188 if test "$afs" != no; then
191 AC_MSG_ERROR(This package requires AFS libraries.)
194 dnl ----- Kerberos 4 -----
196 AC_DEFUN([ATHENA_KRB4_CHECK],
197 [AC_CHECK_FUNC(gethostbyname, :, AC_CHECK_LIB(nsl, gethostbyname))
198 AC_CHECK_FUNC(socket, :, AC_CHECK_LIB(socket, socket))
199 AC_CHECK_LIB(gen, compile)
200 if test "$krb4" != yes; then
201 CPPFLAGS="$CPPFLAGS -I$krb4/include"
202 if test -d "$krb4/include/kerberosIV"; then
203 CPPFLAGS="$CPPFLAGS -I$krb4/include/kerberosIV"
205 LDFLAGS="$LDFLAGS -L$krb4/lib"
207 AC_CHECK_LIB(krb4, krb_rd_req,
208 [KRB4_LIBS="-lkrb4 -ldes425 -lkrb5 -lk5crypto -lcom_err"],
209 [AC_CHECK_LIB(krb, krb_rd_req,
210 [KRB4_LIBS="-lkrb -ldes"],
211 [AC_MSG_ERROR(Kerberos 4 libraries not found)],
213 -ldes425 -lkrb5 -lk5crypto -lcom_err)])
215 AC_DEFUN([ATHENA_KRB4],
217 [ --with-krb4=PREFIX Use Kerberos 4],
218 [krb4="$withval"], [krb4=no])
219 if test "$krb4" != no; then
223 AC_SUBST(KRB4_LIBS)])
225 AC_DEFUN([ATHENA_KRB4_REQUIRED],
227 [ --with-krb4=PREFIX Specify location of Kerberos 4],
228 [krb4="$withval"], [krb4=yes])
229 if test "$krb4" != no; then
233 AC_MSG_ERROR(This package requires Kerberos 4.)
236 dnl ----- Kerberos 5 -----
238 AC_DEFUN([ATHENA_KRB5_CHECK],
239 [AC_SEARCH_LIBS(gethostbyname, nsl)
240 AC_SEARCH_LIBS(socket, socket)
241 AC_CHECK_LIB(gen, compile)
242 if test "$krb5" != yes; then
243 CPPFLAGS="$CPPFLAGS -I$krb5/include"
244 LDFLAGS="$LDFLAGS -L$krb5/lib"
246 AC_CHECK_LIB(krb5, krb5_init_context, :,
247 [AC_MSG_ERROR(Kerberos 5 libraries not found)],
248 -lk5crypto -lcom_err)])
250 AC_DEFUN([ATHENA_KRB5],
252 [ --with-krb5=PREFIX Use Kerberos 5],
253 [krb5="$withval"], [krb5=no])
254 if test "$krb5" != no; then
256 KRB5_LIBS="-lkrb5 -lk5crypto -lcom_err"
259 AC_SUBST(KRB5_LIBS)])
261 AC_DEFUN([ATHENA_KRB5_REQUIRED],
263 [ --with-krb5=PREFIX Specify location of Kerberos 5],
264 [krb5="$withval"], [krb5=yes])
265 if test "$krb5" != no; then
268 AC_MSG_ERROR(This package requires Kerberos 5.)
271 dnl ----- Hesiod -----
273 AC_DEFUN([ATHENA_HESIOD_CHECK],
274 [AC_CHECK_FUNC(res_send, :, AC_CHECK_LIB(resolv, res_send))
275 if test "$hesiod" != yes; then
276 CPPFLAGS="$CPPFLAGS -I$hesiod/include"
277 LDFLAGS="$LDFLAGS -L$hesiod/lib"
279 AC_CHECK_LIB(hesiod, hes_resolve, :,
280 [AC_MSG_ERROR(Hesiod library not found)])])
282 AC_DEFUN([ATHENA_HESIOD],
284 [ --with-hesiod=PREFIX Use Hesiod],
285 [hesiod="$withval"], [hesiod=no])
286 if test "$hesiod" != no; then
288 HESIOD_LIBS="-lhesiod"
289 AC_DEFINE(HAVE_HESIOD)
291 AC_SUBST(HESIOD_LIBS)])
293 AC_DEFUN([ATHENA_HESIOD_REQUIRED],
295 [ --with-hesiod=PREFIX Specify location of Hesiod],
296 [hesiod="$withval"], [hesiod=yes])
297 if test "$hesiod" != no; then
300 AC_MSG_ERROR(This package requires Hesiod.)
303 dnl ----- libares -----
305 AC_DEFUN([ATHENA_ARES_CHECK],
306 [AC_CHECK_FUNC(res_send, :, AC_CHECK_LIB(resolv, res_send))
307 if test "$ares" != yes; then
308 CPPFLAGS="$CPPFLAGS -I$ares/include"
309 LDFLAGS="$LDFLAGS -L$ares/lib"
311 AC_CHECK_LIB(ares, ares_init, :, [AC_MSG_ERROR(libares not found)])])
313 AC_DEFUN([ATHENA_ARES],
315 [ --with-ares=PREFIX Use libares],
316 [ares="$withval"], [ares=no])
317 if test "$ares" != no; then
322 AC_SUBST(ARES_LIBS)])
324 AC_DEFUN([ATHENA_ARES_REQUIRED],
326 [ --with-ares=PREFIX Specify location of libares],
327 [ares="$withval"], [ares=yes])
328 if test "$ares" != no; then
331 AC_MSG_ERROR(This package requires libares.)
333 dnl ----- zephyr -----
335 AC_DEFUN([ATHENA_ZEPHYR_CHECK],
336 [if test "$zephyr" != yes; then
337 CPPFLAGS="$CPPFLAGS -I$zephyr/include"
338 LDFLAGS="$LDFLAGS -L$zephyr/lib"
340 AC_CHECK_LIB(zephyr, ZFreeNotice, :, [AC_MSG_ERROR(zephyr not found)])])
342 AC_DEFUN([ATHENA_ZEPHYR],
344 [ --with-zephyr=PREFIX Use zephyr],
345 [zephyr="$withval"], [zephyr=no])
346 if test "$zephyr" != no; then
348 ZEPHYR_LIBS="-lzephyr"
349 AC_DEFINE(HAVE_ZEPHYR)
351 AC_SUBST(ZEPHYR_LIBS)])
353 AC_DEFUN([ATHENA_ZEPHYR_REQUIRED],
355 [ --with-zephyr=PREFIX Specify location of zephyr],
356 [zephyr="$withval"], [zephyr=yes])
357 if test "$zephyr" != no; then
360 AC_MSG_ERROR(This package requires zephyr.)
362 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
363 ## Copyright 1996, 1997, 1998, 1999, 2000, 2001
364 ## Free Software Foundation, Inc.
365 ## Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
367 ## This program is free software; you can redistribute it and/or modify
368 ## it under the terms of the GNU General Public License as published by
369 ## the Free Software Foundation; either version 2 of the License, or
370 ## (at your option) any later version.
372 ## This program is distributed in the hope that it will be useful, but
373 ## WITHOUT ANY WARRANTY; without even the implied warranty of
374 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
375 ## General Public License for more details.
377 ## You should have received a copy of the GNU General Public License
378 ## along with this program; if not, write to the Free Software
379 ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
381 ## As a special exception to the GNU General Public License, if you
382 ## distribute this file as part of a program that contains a
383 ## configuration script generated by Autoconf, you may include it under
384 ## the same distribution terms that you use for the rest of that program.
386 # serial 47 AC_PROG_LIBTOOL
389 # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
390 # -----------------------------------------------------------
391 # If this macro is not defined by Autoconf, define it here.
392 m4_ifdef([AC_PROVIDE_IFELSE],
394 [m4_define([AC_PROVIDE_IFELSE],
395 [m4_ifdef([AC_PROVIDE_$1],
401 AC_DEFUN([AC_PROG_LIBTOOL],
402 [AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
403 dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
404 dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
405 AC_PROVIDE_IFELSE([AC_PROG_CXX],
407 [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
409 dnl And a similar setup for Fortran 77 support
410 AC_PROVIDE_IFELSE([AC_PROG_F77],
412 [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
415 dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
416 dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
417 dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
418 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
420 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
422 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
424 [ifdef([AC_PROG_GCJ],
425 [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
426 ifdef([A][M_PROG_GCJ],
427 [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
428 ifdef([LT_AC_PROG_GCJ],
429 [define([LT_AC_PROG_GCJ],
430 defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
431 ])])# AC_PROG_LIBTOOL
436 AC_DEFUN([_AC_PROG_LIBTOOL],
437 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
438 AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
439 AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
440 AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
442 # This can be used to rebuild libtool when needed
443 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
445 # Always use our own libtool.
446 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
449 # Prevent multiple expansion
450 define([AC_PROG_LIBTOOL], [])
456 AC_DEFUN([AC_LIBTOOL_SETUP],
458 AC_REQUIRE([AC_ENABLE_SHARED])dnl
459 AC_REQUIRE([AC_ENABLE_STATIC])dnl
460 AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
461 AC_REQUIRE([AC_CANONICAL_HOST])dnl
462 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
463 AC_REQUIRE([AC_PROG_CC])dnl
464 AC_REQUIRE([AC_PROG_LD])dnl
465 AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
466 AC_REQUIRE([AC_PROG_NM])dnl
468 AC_REQUIRE([AC_PROG_LN_S])dnl
469 AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
470 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
471 AC_REQUIRE([AC_OBJEXT])dnl
472 AC_REQUIRE([AC_EXEEXT])dnl
475 AC_LIBTOOL_SYS_MAX_CMD_LEN
476 AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
479 AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
480 _LT_AC_PROG_ECHO_BACKSLASH
484 # AIX sometimes has problems with the GCC collect2 program. For some
485 # reason, if we set the COLLECT_NAMES environment variable, the problems
486 # vanish in a puff of smoke.
487 if test "X${COLLECT_NAMES+set}" != Xset; then
494 # Sed substitution that helps us do robust quoting. It backslashifies
495 # metacharacters that are still active within double-quoted strings.
497 [sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
499 # Same as above, but do not quote variable references.
500 [double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
502 # Sed substitution to delay expansion of an escaped shell variable in a
503 # double_quote_subst'ed string.
504 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
506 # Sed substitution to avoid accidental globbing in evaled expressions
507 no_glob_subst='s/\*/\\\*/g'
513 default_ofile=libtool
516 # All known linkers require a `.a' archive for static linking (except M$VC,
517 # which needs '.lib').
519 ltmain="$ac_aux_dir/ltmain.sh"
520 ofile="$default_ofile"
521 with_gnu_ld="$lt_cv_prog_gnu_ld"
523 AC_CHECK_TOOL(AR, ar, false)
524 AC_CHECK_TOOL(RANLIB, ranlib, :)
525 AC_CHECK_TOOL(STRIP, strip, :)
530 # Set sane defaults for various variables
531 test -z "$AR" && AR=ar
532 test -z "$AR_FLAGS" && AR_FLAGS=cru
533 test -z "$AS" && AS=as
534 test -z "$CC" && CC=cc
535 test -z "$LTCC" && LTCC=$CC
536 test -z "$DLLTOOL" && DLLTOOL=dlltool
537 test -z "$LD" && LD=ld
538 test -z "$LN_S" && LN_S="ln -s"
539 test -z "$MAGIC_CMD" && MAGIC_CMD=file
540 test -z "$NM" && NM=nm
541 test -z "$SED" && SED=sed
542 test -z "$OBJDUMP" && OBJDUMP=objdump
543 test -z "$RANLIB" && RANLIB=:
544 test -z "$STRIP" && STRIP=:
545 test -z "$ac_objext" && ac_objext=o
547 # Determine commands to create old-style static archives.
548 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
549 old_postinstall_cmds='chmod 644 $oldlib'
550 old_postuninstall_cmds=
552 if test -n "$RANLIB"; then
555 old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
558 old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
561 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
564 # Only perform the check for file, if the check method requires it
565 case $deplibs_check_method in
567 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
573 AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
574 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
575 enable_win32_dll=yes, enable_win32_dll=no)
577 AC_ARG_ENABLE([libtool-lock],
578 [AC_HELP_STRING([--disable-libtool-lock],
579 [avoid locking (might break parallel builds)])])
580 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
583 [AC_HELP_STRING([--with-pic],
584 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
585 [pic_mode="$withval"],
587 test -z "$pic_mode" && pic_mode=default
589 # Use C for the default configuration in the libtool script
591 AC_LIBTOOL_LANG_C_CONFIG
596 # _LT_AC_SYS_COMPILER
597 # -------------------
598 AC_DEFUN([_LT_AC_SYS_COMPILER],
599 [AC_REQUIRE([AC_PROG_CC])dnl
601 # If no C compiler was specified, use CC.
604 # Allow CC to be a program name with arguments.
606 ])# _LT_AC_SYS_COMPILER
609 # _LT_AC_SYS_LIBPATH_AIX
610 # ----------------------
611 # Links a minimal program and checks the executable
612 # for the system default hardcoded library path. In most cases,
613 # this is /usr/lib:/lib, but when the MPI compilers are used
614 # the location of the communication and MPI libs are included too.
615 # If we don't find anything, use the default library path according
616 # to the aix ld manual.
617 AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
618 [AC_LINK_IFELSE(AC_LANG_PROGRAM,[
619 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
621 # Check for a 64-bit object if we didn't find anything.
622 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; }
624 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
625 ])# _LT_AC_SYS_LIBPATH_AIX
628 # _LT_AC_SHELL_INIT(ARG)
629 # ----------------------
630 AC_DEFUN([_LT_AC_SHELL_INIT],
631 [ifdef([AC_DIVERSION_NOTICE],
632 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
633 [AC_DIVERT_PUSH(NOTICE)])
636 ])# _LT_AC_SHELL_INIT
639 # _LT_AC_PROG_ECHO_BACKSLASH
640 # --------------------------
641 # Add some code to the start of the generated configure script which
642 # will find an echo command which doesn't interpret backslashes.
643 AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
645 # Check that we are running under the correct shell.
646 SHELL=${CONFIG_SHELL-/bin/sh}
650 # Remove one level of quotation (which was required for Make).
651 ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
656 if test "X[$]1" = X--no-reexec; then
657 # Discard the --no-reexec flag, and continue.
659 elif test "X[$]1" = X--fallback-echo; then
660 # Avoid inline document here, it may be left over
662 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
663 # Yippee, $echo works!
666 # Restart under the correct shell.
667 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
670 if test "X[$]1" = X--fallback-echo; then
671 # used as fallback echo
679 # The HP-UX ksh and POSIX shell print the target directory to stdout
681 if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
683 if test -z "$ECHO"; then
684 if test "X${echo_test_string+set}" != Xset; then
685 # find a string as large as possible, as long as the shell can cope with it
686 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
687 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
688 if (echo_test_string="`eval $cmd`") 2>/dev/null &&
689 echo_test_string="`eval $cmd`" &&
690 (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
697 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
698 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
699 test "X$echo_testing_string" = "X$echo_test_string"; then
702 # The Solaris, AIX, and Digital Unix default echo programs unquote
703 # backslashes. This makes it impossible to quote backslashes using
704 # echo "$something" | sed 's/\\/\\\\/g'
706 # So, first we look for a working echo in the user's PATH.
708 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
709 for dir in $PATH /usr/ucb; do
711 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
712 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
713 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
714 test "X$echo_testing_string" = "X$echo_test_string"; then
721 if test "X$echo" = Xecho; then
722 # We didn't find a better echo, so look for alternatives.
723 if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
724 echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
725 test "X$echo_testing_string" = "X$echo_test_string"; then
726 # This shell has a builtin print -r that does the trick.
728 elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
729 test "X$CONFIG_SHELL" != X/bin/ksh; then
730 # If we have ksh, try running configure again with it.
731 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
732 export ORIGINAL_CONFIG_SHELL
733 CONFIG_SHELL=/bin/ksh
735 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
739 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
740 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
741 test "X$echo_testing_string" = "X$echo_test_string"; then
744 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
745 test "X$echo_testing_string" = 'X\t' &&
746 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
747 test "X$echo_testing_string" = "X$echo_test_string"; then
748 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
750 SHELL="$CONFIG_SHELL"
752 echo="$CONFIG_SHELL [$]0 --fallback-echo"
753 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
754 test "X$echo_testing_string" = 'X\t' &&
755 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
756 test "X$echo_testing_string" = "X$echo_test_string"; then
757 echo="$CONFIG_SHELL [$]0 --fallback-echo"
759 # maybe with a smaller string...
762 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
763 if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
770 if test "$prev" != 'sed 50q "[$]0"'; then
771 echo_test_string=`eval $prev`
772 export echo_test_string
773 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
775 # Oops. We lost completely, so just stick with echo.
784 # Copy echo and quote the copy suitably for passing to libtool from
785 # the Makefile, instead of quoting the original, which is used later.
787 if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
788 ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
792 ])])# _LT_AC_PROG_ECHO_BACKSLASH
797 AC_DEFUN([_LT_AC_LOCK],
798 [AC_ARG_ENABLE([libtool-lock],
799 [AC_HELP_STRING([--disable-libtool-lock],
800 [avoid locking (might break parallel builds)])])
801 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
803 # Some flags need to be propagated to the compiler or linker for good
807 # Find out which ABI we are using.
808 echo 'int i;' > conftest.$ac_ext
809 if AC_TRY_EVAL(ac_compile); then
810 case `/usr/bin/file conftest.$ac_objext` in
822 # Find out which ABI we are using.
823 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
824 if AC_TRY_EVAL(ac_compile); then
825 if test "$lt_cv_prog_gnu_ld" = yes; then
826 case `/usr/bin/file conftest.$ac_objext` in
828 LD="${LD-ld} -melf32bsmip"
831 LD="${LD-ld} -melf32bmipn32"
834 LD="${LD-ld} -melf64bmip"
838 case `/usr/bin/file conftest.$ac_objext` in
854 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
855 # Find out which ABI we are using.
856 echo 'int i;' > conftest.$ac_ext
857 if AC_TRY_EVAL(ac_compile); then
858 case "`/usr/bin/file conftest.o`" in
862 LD="${LD-ld} -m elf_i386"
864 ppc64-*linux*|powerpc64-*linux*)
865 LD="${LD-ld} -m elf32ppclinux"
868 LD="${LD-ld} -m elf_s390"
871 LD="${LD-ld} -m elf32_sparc"
878 LD="${LD-ld} -m elf_x86_64"
880 ppc*-*linux*|powerpc*-*linux*)
881 LD="${LD-ld} -m elf64ppc"
884 LD="${LD-ld} -m elf64_s390"
887 LD="${LD-ld} -m elf64_sparc"
897 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
898 SAVE_CFLAGS="$CFLAGS"
899 CFLAGS="$CFLAGS -belf"
900 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
902 AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
904 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
905 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
906 CFLAGS="$SAVE_CFLAGS"
909 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
910 [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
911 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
912 AC_CHECK_TOOL(AS, as, false)
913 AC_CHECK_TOOL(OBJDUMP, objdump, false)
918 need_locks="$enable_libtool_lock"
923 # AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
924 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
925 # ----------------------------------------------------------------
926 # Check whether the given compiler option works
927 AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
928 [AC_REQUIRE([LT_AC_PROG_SED])
929 AC_CACHE_CHECK([$1], [$2],
931 ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
932 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
933 lt_compiler_flag="$3"
934 # Insert the option either (1) after the last *FLAGS variable, or
935 # (2) before a word containing "conftest.", or (3) at the end.
936 # Note that $ac_compile itself does not contain backslashes and begins
937 # with a dollar sign (not a hyphen), so the echo should work correctly.
938 # The option is referenced via a variable to avoid confusing sed.
939 lt_compile=`echo "$ac_compile" | $SED \
940 -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
941 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
942 -e 's:$: $lt_compiler_flag:'`
943 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
944 (eval "$lt_compile" 2>conftest.err)
946 cat conftest.err >&AS_MESSAGE_LOG_FD
947 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
948 if (exit $ac_status) && test -s "$ac_outfile"; then
949 # The compiler can only warn and ignore the option if not recognized
950 # So say no if there are warnings
951 if test ! -s conftest.err; then
958 if test x"[$]$2" = xyes; then
959 ifelse([$5], , :, [$5])
961 ifelse([$6], , :, [$6])
963 ])# AC_LIBTOOL_COMPILER_OPTION
966 # AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
967 # [ACTION-SUCCESS], [ACTION-FAILURE])
968 # ------------------------------------------------------------
969 # Check whether the given compiler option works
970 AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
971 [AC_CACHE_CHECK([$1], [$2],
973 save_LDFLAGS="$LDFLAGS"
974 LDFLAGS="$LDFLAGS $3"
975 printf "$lt_simple_link_test_code" > conftest.$ac_ext
976 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
977 # The compiler can only warn and ignore the option if not recognized
978 # So say no if there are warnings
979 if test -s conftest.err; then
980 # Append any errors to the config.log.
981 cat conftest.err 1>&AS_MESSAGE_LOG_FD
987 LDFLAGS="$save_LDFLAGS"
990 if test x"[$]$2" = xyes; then
991 ifelse([$4], , :, [$4])
993 ifelse([$5], , :, [$5])
995 ])# AC_LIBTOOL_LINKER_OPTION
998 # AC_LIBTOOL_SYS_MAX_CMD_LEN
999 # --------------------------
1000 AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
1001 [# find the maximum length of command line arguments
1002 AC_MSG_CHECKING([the maximum length of command line arguments])
1003 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1009 # On DJGPP, this test can blow up pretty badly due to problems in libc
1010 # (any single argument exceeding 2000 bytes causes a buffer overrun
1011 # during glob expansion). Even if it were fixed, the result of this
1012 # check would be larger than it should be.
1013 lt_cv_sys_max_cmd_len=12288; # 12K is about right
1017 # Under GNU Hurd, this test is not required because there is
1018 # no limit to the length of command line arguments.
1019 # Libtool will interpret -1 as no limit whatsoever
1020 lt_cv_sys_max_cmd_len=-1;
1024 # On Win9x/ME, this test blows up -- it succeeds, but takes
1025 # about 5 minutes as the teststring grows exponentially.
1026 # Worse, since 9x/ME are not pre-emptively multitasking,
1027 # you end up with a "frozen" computer, even though with patience
1028 # the test eventually succeeds (with a max line length of 256k).
1029 # Instead, let's just punt: use the minimum linelength reported by
1030 # all of the supported platforms: 8192 (on NT/2K/XP).
1031 lt_cv_sys_max_cmd_len=8192;
1035 # On AmigaOS with pdksh, this test takes hours, literally.
1036 # So we just punt and use a minimum line length of 8192.
1037 lt_cv_sys_max_cmd_len=8192;
1041 # If test is not a shell built-in, we'll probably end up computing a
1042 # maximum length that is only half of the actual maximum length, but
1044 while (test "X"`$CONFIG_SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
1045 = "XX$teststring") >/dev/null 2>&1 &&
1046 new_result=`expr "X$teststring" : ".*" 2>&1` &&
1047 lt_cv_sys_max_cmd_len=$new_result &&
1048 test $i != 17 # 1/2 MB should be enough
1051 teststring=$teststring$teststring
1054 # Add a significant safety factor because C++ compilers can tack on massive
1055 # amounts of additional arguments before passing them to the linker.
1056 # It appears as though 1/2 is a usable value.
1057 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1061 if test -n $lt_cv_sys_max_cmd_len ; then
1062 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1066 ])# AC_LIBTOOL_SYS_MAX_CMD_LEN
1069 # _LT_AC_CHECK_DLFCN
1070 # --------------------
1071 AC_DEFUN([_LT_AC_CHECK_DLFCN],
1072 [AC_CHECK_HEADERS(dlfcn.h)dnl
1073 ])# _LT_AC_CHECK_DLFCN
1076 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1077 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1078 # ------------------------------------------------------------------
1079 AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
1080 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1081 if test "$cross_compiling" = yes; then :
1084 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1085 lt_status=$lt_dlunknown
1086 cat > conftest.$ac_ext <<EOF
1087 [#line __oline__ "configure"
1088 #include "confdefs.h"
1097 # define LT_DLGLOBAL RTLD_GLOBAL
1100 # define LT_DLGLOBAL DL_GLOBAL
1102 # define LT_DLGLOBAL 0
1106 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1107 find out it does not work in some platform. */
1108 #ifndef LT_DLLAZY_OR_NOW
1110 # define LT_DLLAZY_OR_NOW RTLD_LAZY
1113 # define LT_DLLAZY_OR_NOW DL_LAZY
1116 # define LT_DLLAZY_OR_NOW RTLD_NOW
1119 # define LT_DLLAZY_OR_NOW DL_NOW
1121 # define LT_DLLAZY_OR_NOW 0
1129 extern "C" void exit (int);
1132 void fnord() { int i=42;}
1135 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1136 int status = $lt_dlunknown;
1140 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1141 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1142 /* dlclose (self); */
1148 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1149 (./conftest; exit; ) 2>/dev/null
1152 x$lt_dlno_uscore) $1 ;;
1153 x$lt_dlneed_uscore) $2 ;;
1154 x$lt_unknown|x*) $3 ;;
1157 # compilation failed
1162 ])# _LT_AC_TRY_DLOPEN_SELF
1165 # AC_LIBTOOL_DLOPEN_SELF
1166 # -------------------
1167 AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
1168 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1169 if test "x$enable_dlopen" != xyes; then
1170 enable_dlopen=unknown
1171 enable_dlopen_self=unknown
1172 enable_dlopen_self_static=unknown
1179 lt_cv_dlopen="load_add_on"
1181 lt_cv_dlopen_self=yes
1185 lt_cv_dlopen="LoadLibrary"
1190 lt_cv_dlopen="dlopen"
1195 # if libdl is installed we need to link against it
1196 AC_CHECK_LIB([dl], [dlopen],
1197 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1200 lt_cv_dlopen_self=yes
1205 AC_CHECK_FUNC([shl_load],
1206 [lt_cv_dlopen="shl_load"],
1207 [AC_CHECK_LIB([dld], [shl_load],
1208 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
1209 [AC_CHECK_FUNC([dlopen],
1210 [lt_cv_dlopen="dlopen"],
1211 [AC_CHECK_LIB([dl], [dlopen],
1212 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1213 [AC_CHECK_LIB([svld], [dlopen],
1214 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1215 [AC_CHECK_LIB([dld], [dld_link],
1216 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
1225 if test "x$lt_cv_dlopen" != xno; then
1231 case $lt_cv_dlopen in
1233 save_CPPFLAGS="$CPPFLAGS"
1234 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1236 save_LDFLAGS="$LDFLAGS"
1237 eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1240 LIBS="$lt_cv_dlopen_libs $LIBS"
1242 AC_CACHE_CHECK([whether a program can dlopen itself],
1243 lt_cv_dlopen_self, [dnl
1244 _LT_AC_TRY_DLOPEN_SELF(
1245 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1246 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1249 if test "x$lt_cv_dlopen_self" = xyes; then
1250 LDFLAGS="$LDFLAGS $link_static_flag"
1251 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1252 lt_cv_dlopen_self_static, [dnl
1253 _LT_AC_TRY_DLOPEN_SELF(
1254 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1255 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1259 CPPFLAGS="$save_CPPFLAGS"
1260 LDFLAGS="$save_LDFLAGS"
1265 case $lt_cv_dlopen_self in
1266 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1267 *) enable_dlopen_self=unknown ;;
1270 case $lt_cv_dlopen_self_static in
1271 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1272 *) enable_dlopen_self_static=unknown ;;
1275 ])# AC_LIBTOOL_DLOPEN_SELF
1278 # AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1279 # ---------------------------------
1280 # Check to see if options -c and -o are simultaneously supported by compiler
1281 AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1282 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1283 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1284 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1285 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1286 $rm -r conftest 2>/dev/null
1290 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1292 lt_compiler_flag="-o out/conftest2.$ac_objext"
1293 # Insert the option either (1) after the last *FLAGS variable, or
1294 # (2) before a word containing "conftest.", or (3) at the end.
1295 # Note that $ac_compile itself does not contain backslashes and begins
1296 # with a dollar sign (not a hyphen), so the echo should work correctly.
1297 lt_compile=`echo "$ac_compile" | $SED \
1298 -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
1299 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1300 -e 's:$: $lt_compiler_flag:'`
1301 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1302 (eval "$lt_compile" 2>out/conftest.err)
1304 cat out/conftest.err >&AS_MESSAGE_LOG_FD
1305 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1306 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1308 # The compiler can only warn and ignore the option if not recognized
1309 # So say no if there are warnings
1310 if test ! -s out/conftest.err; then
1311 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1316 # SGI C++ compiler will create directory out/ii_files/ for
1317 # template instantiation
1318 test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
1319 $rm out/* && rmdir out
1324 ])# AC_LIBTOOL_PROG_CC_C_O
1327 # AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
1328 # -----------------------------------------
1329 # Check to see if we can do hard links to lock some files if needed
1330 AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
1331 [AC_REQUIRE([_LT_AC_LOCK])dnl
1333 hard_links="nottested"
1334 if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1335 # do not overwrite the value of need_locks provided by the user
1336 AC_MSG_CHECKING([if we can lock with hard links])
1339 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1341 ln conftest.a conftest.b 2>&5 || hard_links=no
1342 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1343 AC_MSG_RESULT([$hard_links])
1344 if test "$hard_links" = no; then
1345 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1351 ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
1356 AC_DEFUN([AC_LIBTOOL_OBJDIR],
1357 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
1358 [rm -f .libs 2>/dev/null
1359 mkdir .libs 2>/dev/null
1360 if test -d .libs; then
1363 # MS-DOS does not allow filenames that begin with a dot.
1366 rmdir .libs 2>/dev/null])
1367 objdir=$lt_cv_objdir
1368 ])# AC_LIBTOOL_OBJDIR
1371 # AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
1372 # ----------------------------------------------
1373 # Check hardcoding attributes.
1374 AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
1375 [AC_MSG_CHECKING([how to hardcode library paths into programs])
1376 _LT_AC_TAGVAR(hardcode_action, $1)=
1377 if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
1378 test -n "$_LT_AC_TAGVAR(runpath_var $1)" || \
1379 test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)"="Xyes" ; then
1381 # We can hardcode non-existant directories.
1382 if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
1383 # If the only mechanism to avoid hardcoding is shlibpath_var, we
1384 # have to relink, otherwise we might link with an installed library
1385 # when we should be linking with a yet-to-be-installed one
1386 ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
1387 test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
1388 # Linking always hardcodes the temporary library directory.
1389 _LT_AC_TAGVAR(hardcode_action, $1)=relink
1391 # We can link without hardcoding, and we can hardcode nonexisting dirs.
1392 _LT_AC_TAGVAR(hardcode_action, $1)=immediate
1395 # We cannot hardcode anything, or else we can only hardcode existing
1397 _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
1399 AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
1401 if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
1402 # Fast installation is not supported
1403 enable_fast_install=no
1404 elif test "$shlibpath_overrides_runpath" = yes ||
1405 test "$enable_shared" = no; then
1406 # Fast installation is not necessary
1407 enable_fast_install=needless
1409 ])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
1412 # AC_LIBTOOL_SYS_LIB_STRIP
1413 # ------------------------
1414 AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
1417 AC_MSG_CHECKING([whether stripping libraries is possible])
1418 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
1419 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
1420 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
1421 AC_MSG_RESULT([yes])
1423 # FIXME - insert some real tests, host_os isn't really good enough
1426 if test -n "$STRIP" ; then
1427 striplib="$STRIP -x"
1428 AC_MSG_RESULT([yes])
1438 ])# AC_LIBTOOL_SYS_LIB_STRIP
1441 # AC_LIBTOOL_SYS_DYNAMIC_LINKER
1442 # -----------------------------
1443 # PORTME Fill in your ld.so characteristics
1444 AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
1445 [AC_MSG_CHECKING([dynamic linker characteristics])
1447 libname_spec='lib$name'
1455 shlibpath_overrides_runpath=unknown
1457 dynamic_linker="$host_os ld.so"
1458 sys_lib_dlsearch_path_spec="/lib /usr/lib"
1459 if test "$GCC" = yes; then
1460 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1461 if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
1462 # if the path contains ";" then we assume it to be the separator
1463 # otherwise default to the standard path separator (i.e. ":") - it is
1464 # assumed that no part of a normal pathname contains ";" but that should
1465 # okay in the real world where ";" in dirpaths is itself problematic.
1466 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1468 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1471 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1473 need_lib_prefix=unknown
1474 hardcode_into_libs=no
1476 # when you set need_version to no, make sure it does not cause -set_version
1477 # flags to be left without arguments
1478 need_version=unknown
1483 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
1484 shlibpath_var=LIBPATH
1486 # AIX 3 has no versioning support, so we append a major version to the name.
1487 soname_spec='${libname}${release}${shared_ext}$major'
1494 hardcode_into_libs=yes
1495 if test "$host_cpu" = ia64; then
1496 # AIX 5 supports IA64
1497 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
1498 shlibpath_var=LD_LIBRARY_PATH
1500 # With GCC up to 2.95.x, collect2 would create an import file
1501 # for dependence libraries. The import file would start with
1502 # the line `#! .'. This would cause the generated library to
1503 # depend on `.', always an invalid library. This was fixed in
1504 # development snapshots of GCC prior to 3.0.
1506 aix4 | aix4.[[01]] | aix4.[[01]].*)
1507 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
1509 echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
1516 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
1517 # soname into executable. Probably we can add versioning support to
1518 # collect2, so additional links can be useful in future.
1519 if test "$aix_use_runtimelinking" = yes; then
1520 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
1521 # instead of lib<name>.a to let people know that these are not
1522 # typical AIX shared libraries.
1523 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1525 # We preserve .a as extension for shared libraries through AIX4.2
1526 # and later when we are not doing run time linking.
1527 library_names_spec='${libname}${release}.a $libname.a'
1528 soname_spec='${libname}${release}${shared_ext}$major'
1530 shlibpath_var=LIBPATH
1535 library_names_spec='$libname.ixlibrary $libname.a'
1536 # Create ${libname}_ixlibrary.a entries in /sys/libs.
1537 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'
1541 library_names_spec='${libname}${shared_ext}'
1542 dynamic_linker="$host_os ld.so"
1543 shlibpath_var=LIBRARY_PATH
1549 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1550 soname_spec='${libname}${release}${shared_ext}$major'
1551 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
1552 shlibpath_var=LD_LIBRARY_PATH
1553 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
1554 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
1555 # the default ld.so.conf also contains /usr/contrib/lib and
1556 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
1557 # libtool to hard-code these into programs
1560 cygwin* | mingw* | pw32*)
1561 version_type=windows
1566 case $GCC,$host_os in
1567 yes,cygwin* | yes,mingw* | yes,pw32*)
1568 library_names_spec='$libname.dll.a'
1569 # DLL is installed to $(libdir)/../bin by postinstall_cmds
1570 postinstall_cmds='base_file=`basename \${file}`~
1571 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
1572 dldir=$destdir/`dirname \$dlpath`~
1573 test -d \$dldir || mkdir -p \$dldir~
1574 $install_prog $dir/$dlname \$dldir/$dlname'
1575 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
1576 dlpath=$dir/\$dldll~
1578 shlibpath_overrides_runpath=yes
1582 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
1583 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1584 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
1587 # MinGW DLLs use traditional 'lib' prefix
1588 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1589 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1590 if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
1591 # It is most probably a Windows format PATH printed by
1592 # mingw gcc, but we are running on Cygwin. Gcc prints its search
1593 # path with ; separators, and with drive letters. We can handle the
1594 # drive letters (cygwin fileutils understands them), so leave them,
1595 # especially as we might pass files found there to a mingw objdump,
1596 # which wouldn't understand a cygwinified path. Ahh.
1597 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1599 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1603 # pw32 DLLs use 'pw' prefix rather than 'lib'
1604 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
1610 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
1613 dynamic_linker='Win32 ld.exe'
1614 # FIXME: first we should search . and the directory the executable is in
1618 darwin* | rhapsody*)
1619 dynamic_linker="$host_os dyld"
1623 library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
1624 soname_spec='${libname}${release}${major}$shared_ext'
1625 shlibpath_overrides_runpath=yes
1626 shlibpath_var=DYLD_LIBRARY_PATH
1627 shrext_cmds='$(test .$module = .yes && echo .so || echo .dylib)'
1628 # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
1629 if test "$GCC" = yes; then
1630 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"`
1632 sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
1634 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
1641 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
1642 soname_spec='${libname}${release}${shared_ext}$major'
1643 shlibpath_var=LD_LIBRARY_PATH
1654 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1655 soname_spec='${libname}${release}${shared_ext}$major'
1656 shlibpath_var=LD_LIBRARY_PATH
1657 shlibpath_overrides_runpath=no
1658 hardcode_into_libs=yes
1659 dynamic_linker='GNU ld.so'
1663 objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
1664 version_type=freebsd-$objformat
1665 case $version_type in
1667 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
1672 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
1676 shlibpath_var=LD_LIBRARY_PATH
1679 shlibpath_overrides_runpath=yes
1681 freebsd3.[01]* | freebsdelf3.[01]*)
1682 shlibpath_overrides_runpath=yes
1683 hardcode_into_libs=yes
1686 shlibpath_overrides_runpath=no
1687 hardcode_into_libs=yes
1696 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
1697 soname_spec='${libname}${release}${shared_ext}$major'
1698 shlibpath_var=LD_LIBRARY_PATH
1699 hardcode_into_libs=yes
1702 hpux9* | hpux10* | hpux11*)
1703 # Give a soname corresponding to the major version so that dld.sl refuses to
1704 # link against other versions.
1711 hardcode_into_libs=yes
1712 dynamic_linker="$host_os dld.so"
1713 shlibpath_var=LD_LIBRARY_PATH
1714 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
1715 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1716 soname_spec='${libname}${release}${shared_ext}$major'
1717 if test "X$HPUX_IA64_MODE" = X32; then
1718 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
1720 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
1722 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1726 hardcode_into_libs=yes
1727 dynamic_linker="$host_os dld.sl"
1728 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
1729 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
1730 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1731 soname_spec='${libname}${release}${shared_ext}$major'
1732 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
1733 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1737 dynamic_linker="$host_os dld.sl"
1738 shlibpath_var=SHLIB_PATH
1739 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
1740 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1741 soname_spec='${libname}${release}${shared_ext}$major'
1744 # HP-UX runs *really* slowly unless shared libraries are mode 555.
1745 postinstall_cmds='chmod 555 $lib'
1748 irix5* | irix6* | nonstopux*)
1750 nonstopux*) version_type=nonstopux ;;
1752 if test "$lt_cv_prog_gnu_ld" = yes; then
1760 soname_spec='${libname}${release}${shared_ext}$major'
1761 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
1763 irix5* | nonstopux*)
1767 case $LD in # libtool.m4 will add one of these switches to LD
1768 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
1769 libsuff= shlibsuff= libmagic=32-bit;;
1770 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
1771 libsuff=32 shlibsuff=N32 libmagic=N32;;
1772 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
1773 libsuff=64 shlibsuff=64 libmagic=64-bit;;
1774 *) libsuff= shlibsuff= libmagic=never-match;;
1778 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
1779 shlibpath_overrides_runpath=no
1780 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
1781 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
1782 hardcode_into_libs=yes
1785 # No shared lib support for Linux oldld, aout, or coff.
1786 linux*oldld* | linux*aout* | linux*coff*)
1790 # This must be Linux ELF.
1795 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1796 soname_spec='${libname}${release}${shared_ext}$major'
1797 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
1798 shlibpath_var=LD_LIBRARY_PATH
1799 shlibpath_overrides_runpath=no
1800 # This implies no fast_install, which is unacceptable.
1801 # Some rework will be needed to allow for fast_install
1802 # before this can be enabled.
1803 hardcode_into_libs=yes
1805 # find out which ABI we are using
1808 x86_64*|s390x*|powerpc64*)
1809 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1810 if AC_TRY_EVAL(ac_compile); then
1811 case `/usr/bin/file conftest.$ac_objext` in
1814 sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
1822 # Append ld.so.conf contents to the search path
1823 if test -f /etc/ld.so.conf; then
1824 lt_ld_extra=`$SED -e 's/[:,\t]/ /g;s/=[^=]*$//;s/=[^= ]* / /g' /etc/ld.so.conf | tr '\n' ' '`
1825 sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
1828 # We used to test for /lib/ld.so.1 and disable shared libraries on
1829 # powerpc, because MkLinux only supported shared libraries with the
1830 # GNU dynamic linker. Since this was broken with cross compilers,
1831 # most powerpc-linux boxes support dynamic linking these days and
1832 # people can always --disable-shared, the test was removed, and we
1833 # assume the GNU/Linux dynamic linker is in use.
1834 dynamic_linker='GNU/Linux ld.so'
1841 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1842 soname_spec='${libname}${release}${shared_ext}$major'
1843 shlibpath_var=LD_LIBRARY_PATH
1844 shlibpath_overrides_runpath=no
1845 hardcode_into_libs=yes
1846 dynamic_linker='GNU ld.so'
1853 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
1854 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1855 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1856 dynamic_linker='NetBSD (a.out) ld.so'
1858 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1859 soname_spec='${libname}${release}${shared_ext}$major'
1860 dynamic_linker='NetBSD ld.elf_so'
1862 shlibpath_var=LD_LIBRARY_PATH
1863 shlibpath_overrides_runpath=yes
1864 hardcode_into_libs=yes
1869 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1870 shlibpath_var=LD_LIBRARY_PATH
1871 shlibpath_overrides_runpath=yes
1878 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1879 soname_spec='${libname}${release}${shared_ext}$major'
1880 shlibpath_var=LD_LIBRARY_PATH
1881 shlibpath_overrides_runpath=yes
1888 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1889 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1890 shlibpath_var=LD_LIBRARY_PATH
1891 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
1893 openbsd2.[[89]] | openbsd2.[[89]].*)
1894 shlibpath_overrides_runpath=no
1897 shlibpath_overrides_runpath=yes
1901 shlibpath_overrides_runpath=yes
1906 libname_spec='$name'
1909 library_names_spec='$libname${shared_ext} $libname.a'
1910 dynamic_linker='OS/2 ld.exe'
1911 shlibpath_var=LIBPATH
1914 osf3* | osf4* | osf5*)
1918 soname_spec='${libname}${release}${shared_ext}$major'
1919 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1920 shlibpath_var=LD_LIBRARY_PATH
1921 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
1922 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
1927 soname_spec='${libname}${release}${shared_ext}$major'
1928 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1929 shlibpath_var=LD_LIBRARY_PATH
1936 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1937 soname_spec='${libname}${release}${shared_ext}$major'
1938 shlibpath_var=LD_LIBRARY_PATH
1939 shlibpath_overrides_runpath=yes
1940 hardcode_into_libs=yes
1941 # ldd complains unless libraries are executable
1942 postinstall_cmds='chmod +x $lib'
1947 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1948 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
1949 shlibpath_var=LD_LIBRARY_PATH
1950 shlibpath_overrides_runpath=yes
1951 if test "$with_gnu_ld" = yes; then
1957 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
1959 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1960 soname_spec='${libname}${release}${shared_ext}$major'
1961 shlibpath_var=LD_LIBRARY_PATH
1962 case $host_vendor in
1964 shlibpath_overrides_runpath=no
1966 export_dynamic_flag_spec='${wl}-Blargedynsym'
1967 runpath_var=LD_RUN_PATH
1975 shlibpath_overrides_runpath=no
1976 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
1982 if test -d /usr/nec ;then
1984 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
1985 soname_spec='$libname${shared_ext}.$major'
1986 shlibpath_var=LD_LIBRARY_PATH
1992 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1993 soname_spec='${libname}${release}${shared_ext}$major'
1994 shlibpath_var=LD_LIBRARY_PATH
2001 AC_MSG_RESULT([$dynamic_linker])
2002 test "$dynamic_linker" = no && can_build_shared=no
2003 ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2008 AC_DEFUN([_LT_AC_TAGCONFIG],
2009 [AC_ARG_WITH([tags],
2010 [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2011 [include additional configurations @<:@automatic@:>@])],
2012 [tagnames="$withval"])
2014 if test -f "$ltmain" && test -n "$tagnames"; then
2015 if test ! -f "${ofile}"; then
2016 AC_MSG_WARN([output file `$ofile' does not exist])
2019 if test -z "$LTCC"; then
2020 eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2021 if test -z "$LTCC"; then
2022 AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2024 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2028 # Extract list of available tagged configurations in $ofile.
2029 # Note that this assumes the entire list is on one line.
2030 available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2032 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2033 for tagname in $tagnames; do
2035 # Check whether tagname contains only valid characters
2036 case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2038 *) AC_MSG_ERROR([invalid tag name: $tagname])
2042 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2044 AC_MSG_ERROR([tag name \"$tagname\" already exists])
2047 # Update the list of available tags.
2048 if test -n "$tagname"; then
2049 echo appending configuration tag \"$tagname\" to $ofile
2053 if test -n "$CXX" && test "X$CXX" != "Xno"; then
2054 AC_LIBTOOL_LANG_CXX_CONFIG
2061 if test -n "$F77" && test "X$F77" != "Xno"; then
2062 AC_LIBTOOL_LANG_F77_CONFIG
2069 if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2070 AC_LIBTOOL_LANG_GCJ_CONFIG
2077 AC_LIBTOOL_LANG_RC_CONFIG
2081 AC_MSG_ERROR([Unsupported tag name: $tagname])
2085 # Append the new tag name to the list of available tags.
2086 if test -n "$tagname" ; then
2087 available_tags="$available_tags $tagname"
2093 # Now substitute the updated list of available tags.
2094 if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2095 mv "${ofile}T" "$ofile"
2099 AC_MSG_ERROR([unable to update list of available tagged configurations.])
2102 ])# _LT_AC_TAGCONFIG
2107 # enable checks for dlopen support
2108 AC_DEFUN([AC_LIBTOOL_DLOPEN],
2109 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2110 ])# AC_LIBTOOL_DLOPEN
2113 # AC_LIBTOOL_WIN32_DLL
2114 # --------------------
2115 # declare package support for building win32 dll's
2116 AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2117 [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2118 ])# AC_LIBTOOL_WIN32_DLL
2121 # AC_ENABLE_SHARED([DEFAULT])
2122 # ---------------------------
2123 # implement the --enable-shared flag
2124 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2125 AC_DEFUN([AC_ENABLE_SHARED],
2126 [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2127 AC_ARG_ENABLE([shared],
2128 [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2129 [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2130 [p=${PACKAGE-default}
2132 yes) enable_shared=yes ;;
2133 no) enable_shared=no ;;
2136 # Look at the argument we got. We use all the common list separators.
2137 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2138 for pkg in $enableval; do
2140 if test "X$pkg" = "X$p"; then
2147 [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2148 ])# AC_ENABLE_SHARED
2153 #- set the default shared flag to --disable-shared
2154 AC_DEFUN([AC_DISABLE_SHARED],
2155 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2156 AC_ENABLE_SHARED(no)
2157 ])# AC_DISABLE_SHARED
2160 # AC_ENABLE_STATIC([DEFAULT])
2161 # ---------------------------
2162 # implement the --enable-static flag
2163 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2164 AC_DEFUN([AC_ENABLE_STATIC],
2165 [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2166 AC_ARG_ENABLE([static],
2167 [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2168 [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2169 [p=${PACKAGE-default}
2171 yes) enable_static=yes ;;
2172 no) enable_static=no ;;
2175 # Look at the argument we got. We use all the common list separators.
2176 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2177 for pkg in $enableval; do
2179 if test "X$pkg" = "X$p"; then
2186 [enable_static=]AC_ENABLE_STATIC_DEFAULT)
2187 ])# AC_ENABLE_STATIC
2192 # set the default static flag to --disable-static
2193 AC_DEFUN([AC_DISABLE_STATIC],
2194 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2195 AC_ENABLE_STATIC(no)
2196 ])# AC_DISABLE_STATIC
2199 # AC_ENABLE_FAST_INSTALL([DEFAULT])
2200 # ---------------------------------
2201 # implement the --enable-fast-install flag
2202 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2203 AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2204 [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2205 AC_ARG_ENABLE([fast-install],
2206 [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2207 [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2208 [p=${PACKAGE-default}
2210 yes) enable_fast_install=yes ;;
2211 no) enable_fast_install=no ;;
2213 enable_fast_install=no
2214 # Look at the argument we got. We use all the common list separators.
2215 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2216 for pkg in $enableval; do
2218 if test "X$pkg" = "X$p"; then
2219 enable_fast_install=yes
2225 [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2226 ])# AC_ENABLE_FAST_INSTALL
2229 # AC_DISABLE_FAST_INSTALL
2230 # -----------------------
2231 # set the default to --disable-fast-install
2232 AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2233 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2234 AC_ENABLE_FAST_INSTALL(no)
2235 ])# AC_DISABLE_FAST_INSTALL
2238 # AC_LIBTOOL_PICMODE([MODE])
2239 # --------------------------
2240 # implement the --with-pic flag
2241 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
2242 AC_DEFUN([AC_LIBTOOL_PICMODE],
2243 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2244 pic_mode=ifelse($#,1,$1,default)
2245 ])# AC_LIBTOOL_PICMODE
2250 # This is predefined starting with Autoconf 2.54, so this conditional
2251 # definition can be removed once we require Autoconf 2.54 or later.
2252 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
2253 [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
2254 [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2255 then ac_cv_prog_egrep='grep -E'
2256 else ac_cv_prog_egrep='egrep'
2258 EGREP=$ac_cv_prog_egrep
2263 # AC_PATH_TOOL_PREFIX
2264 # -------------------
2265 # find a file program which can recognise shared library
2266 AC_DEFUN([AC_PATH_TOOL_PREFIX],
2267 [AC_REQUIRE([AC_PROG_EGREP])dnl
2268 AC_MSG_CHECKING([for $1])
2269 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2271 [[\\/*] | ?:[\\/]*])
2272 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2275 lt_save_MAGIC_CMD="$MAGIC_CMD"
2276 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2277 dnl $ac_dummy forces splitting on constant user-supplied paths.
2278 dnl POSIX.2 word splitting is done only on the output of word expansions,
2279 dnl not every word. This closes a longstanding sh security hole.
2280 ac_dummy="ifelse([$2], , $PATH, [$2])"
2281 for ac_dir in $ac_dummy; do
2283 test -z "$ac_dir" && ac_dir=.
2284 if test -f $ac_dir/$1; then
2285 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2286 if test -n "$file_magic_test_file"; then
2287 case $deplibs_check_method in
2289 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
2290 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2291 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2292 $EGREP "$file_magic_regex" > /dev/null; then
2297 *** Warning: the command libtool uses to detect shared libraries,
2298 *** $file_magic_cmd, produces output that libtool cannot recognize.
2299 *** The result is that libtool may fail to recognize shared libraries
2300 *** as such. This will affect the creation of libtool libraries that
2301 *** depend on shared libraries, but programs linked with such libtool
2302 *** libraries will work regardless of this problem. Nevertheless, you
2303 *** may want to report the problem to your system manager and/or to
2304 *** bug-libtool@gnu.org
2314 MAGIC_CMD="$lt_save_MAGIC_CMD"
2317 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2318 if test -n "$MAGIC_CMD"; then
2319 AC_MSG_RESULT($MAGIC_CMD)
2323 ])# AC_PATH_TOOL_PREFIX
2328 # find a file program which can recognise a shared library
2329 AC_DEFUN([AC_PATH_MAGIC],
2330 [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2331 if test -z "$lt_cv_path_MAGIC_CMD"; then
2332 if test -n "$ac_tool_prefix"; then
2333 AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2343 # find the pathname to the GNU or non-GNU linker
2344 AC_DEFUN([AC_PROG_LD],
2345 [AC_ARG_WITH([gnu-ld],
2346 [AC_HELP_STRING([--with-gnu-ld],
2347 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
2348 [test "$withval" = no || with_gnu_ld=yes],
2350 AC_REQUIRE([LT_AC_PROG_SED])dnl
2351 AC_REQUIRE([AC_PROG_CC])dnl
2352 AC_REQUIRE([AC_CANONICAL_HOST])dnl
2353 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2355 if test "$GCC" = yes; then
2356 # Check if gcc -print-prog-name=ld gives a path.
2357 AC_MSG_CHECKING([for ld used by $CC])
2360 # gcc leaves a trailing carriage return which upsets mingw
2361 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2363 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2366 # Accept absolute paths.
2367 [[\\/]]* | ?:[[\\/]]*)
2368 re_direlt='/[[^/]][[^/]]*/\.\./'
2369 # Canonicalize the pathname of ld
2370 ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
2371 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2372 ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
2374 test -z "$LD" && LD="$ac_prog"
2377 # If it fails, then pretend we aren't using GCC.
2381 # If it is relative, then search for the first ld in PATH.
2385 elif test "$with_gnu_ld" = yes; then
2386 AC_MSG_CHECKING([for GNU ld])
2388 AC_MSG_CHECKING([for non-GNU ld])
2390 AC_CACHE_VAL(lt_cv_path_LD,
2391 [if test -z "$LD"; then
2392 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2393 for ac_dir in $PATH; do
2395 test -z "$ac_dir" && ac_dir=.
2396 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2397 lt_cv_path_LD="$ac_dir/$ac_prog"
2398 # Check to see if the program is GNU ld. I'd rather use --version,
2399 # but apparently some GNU ld's only accept -v.
2400 # Break only if it was the GNU/non-GNU ld that we prefer.
2401 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
2402 *GNU* | *'with BFD'*)
2403 test "$with_gnu_ld" != no && break
2406 test "$with_gnu_ld" != yes && break
2413 lt_cv_path_LD="$LD" # Let the user override the test with a path.
2416 if test -n "$LD"; then
2421 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
2428 AC_DEFUN([AC_PROG_LD_GNU],
2429 [AC_REQUIRE([AC_PROG_EGREP])dnl
2430 AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
2431 [# I'd rather use --version here, but apparently some GNU ld's only accept -v.
2432 case `$LD -v 2>&1 </dev/null` in
2433 *GNU* | *'with BFD'*)
2434 lt_cv_prog_gnu_ld=yes
2437 lt_cv_prog_gnu_ld=no
2440 with_gnu_ld=$lt_cv_prog_gnu_ld
2444 # AC_PROG_LD_RELOAD_FLAG
2445 # ----------------------
2446 # find reload flag for linker
2447 # -- PORTME Some linkers may need a different reload flag.
2448 AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
2449 [AC_CACHE_CHECK([for $LD option to reload object files],
2450 lt_cv_ld_reload_flag,
2451 [lt_cv_ld_reload_flag='-r'])
2452 reload_flag=$lt_cv_ld_reload_flag
2453 case $reload_flag in
2455 *) reload_flag=" $reload_flag" ;;
2457 reload_cmds='$LD$reload_flag -o $output$reload_objs'
2458 ])# AC_PROG_LD_RELOAD_FLAG
2461 # AC_DEPLIBS_CHECK_METHOD
2462 # -----------------------
2463 # how to check for library dependencies
2464 # -- PORTME fill in with the dynamic library characteristics
2465 AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
2466 [AC_CACHE_CHECK([how to recognise dependent libraries],
2467 lt_cv_deplibs_check_method,
2468 [lt_cv_file_magic_cmd='$MAGIC_CMD'
2469 lt_cv_file_magic_test_file=
2470 lt_cv_deplibs_check_method='unknown'
2471 # Need to set the preceding variable on all platforms that support
2472 # interlibrary dependencies.
2473 # 'none' -- dependencies not supported.
2474 # `unknown' -- same as none, but documents that we really don't know.
2475 # 'pass_all' -- all dependencies passed with no checks.
2476 # 'test_compile' -- check by making test program.
2477 # 'file_magic [[regex]]' -- check by looking for files in library path
2478 # which responds to the $file_magic_cmd with a given extended regex.
2479 # If you have `file' or equivalent on your system and you're not sure
2480 # whether `pass_all' will *always* work, you probably want this one.
2484 lt_cv_deplibs_check_method=pass_all
2488 lt_cv_deplibs_check_method=pass_all
2492 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
2493 lt_cv_file_magic_cmd='/usr/bin/file -L'
2494 lt_cv_file_magic_test_file=/shlib/libc.so
2498 # func_win32_libid is a shell function defined in ltmain.sh
2499 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
2500 lt_cv_file_magic_cmd='func_win32_libid'
2504 # Base MSYS/MinGW do not provide the 'file' command needed by
2505 # func_win32_libid shell function, so use a weaker test based on 'objdump'.
2506 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
2507 lt_cv_file_magic_cmd='$OBJDUMP -f'
2510 darwin* | rhapsody*)
2511 lt_cv_deplibs_check_method=pass_all
2514 freebsd* | kfreebsd*-gnu)
2515 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2518 # Not sure whether the presence of OpenBSD here was a mistake.
2519 # Let's accept both of them until this is cleared up.
2520 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[[3-9]]86 (compact )?demand paged shared library'
2521 lt_cv_file_magic_cmd=/usr/bin/file
2522 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
2526 lt_cv_deplibs_check_method=pass_all
2531 lt_cv_deplibs_check_method=pass_all
2534 hpux10.20* | hpux11*)
2535 lt_cv_file_magic_cmd=/usr/bin/file
2538 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
2539 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
2542 [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]']
2543 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
2546 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
2547 lt_cv_file_magic_test_file=/usr/lib/libc.sl
2552 irix5* | irix6* | nonstopux*)
2554 *-32|*"-32 ") libmagic=32-bit;;
2555 *-n32|*"-n32 ") libmagic=N32;;
2556 *-64|*"-64 ") libmagic=64-bit;;
2557 *) libmagic=never-match;;
2559 lt_cv_deplibs_check_method=pass_all
2562 # This must be Linux ELF.
2565 alpha*|hppa*|i*86|ia64*|m68*|mips*|powerpc*|sparc*|s390*|sh*|x86_64*)
2566 lt_cv_deplibs_check_method=pass_all ;;
2568 # glibc up to 2.1.1 does not perform some relocations on ARM
2569 # this will be overridden with pass_all, but let us keep it just in case
2570 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;;
2572 lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
2573 lt_cv_deplibs_check_method=pass_all
2577 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2578 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
2580 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
2585 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
2586 lt_cv_file_magic_cmd=/usr/bin/file
2587 lt_cv_file_magic_test_file=/usr/lib/libnls.so
2591 lt_cv_deplibs_check_method=unknown
2595 lt_cv_file_magic_cmd=/usr/bin/file
2596 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
2597 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2598 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB shared object'
2600 lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library'
2604 osf3* | osf4* | osf5*)
2605 lt_cv_deplibs_check_method=pass_all
2609 lt_cv_deplibs_check_method=pass_all
2613 lt_cv_deplibs_check_method=pass_all
2616 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
2617 case $host_vendor in
2619 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]]'
2620 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
2623 lt_cv_deplibs_check_method=pass_all
2626 lt_cv_file_magic_cmd='/bin/file'
2627 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
2630 lt_cv_file_magic_cmd='/bin/file'
2631 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
2632 lt_cv_file_magic_test_file=/lib/libc.so
2635 lt_cv_deplibs_check_method=pass_all
2640 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
2641 lt_cv_deplibs_check_method=pass_all
2645 file_magic_cmd=$lt_cv_file_magic_cmd
2646 deplibs_check_method=$lt_cv_deplibs_check_method
2647 test -z "$deplibs_check_method" && deplibs_check_method=unknown
2648 ])# AC_DEPLIBS_CHECK_METHOD
2653 # find the pathname to a BSD-compatible name lister
2654 AC_DEFUN([AC_PROG_NM],
2655 [AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
2656 [if test -n "$NM"; then
2657 # Let the user override the test.
2660 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2661 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2663 test -z "$ac_dir" && ac_dir=.
2664 tmp_nm="$ac_dir/${ac_tool_prefix}nm"
2665 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
2666 # Check to see if the nm accepts a BSD-compat flag.
2667 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2668 # nm: unknown option "B" ignored
2669 # Tru64's nm complains that /dev/null is an invalid object file
2670 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
2671 */dev/null* | *'Invalid file or object type'*)
2672 lt_cv_path_NM="$tmp_nm -B"
2676 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
2678 lt_cv_path_NM="$tmp_nm -p"
2682 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
2683 continue # so that we can try to find one that supports BSD flags
2690 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
2698 # check for math library
2699 AC_DEFUN([AC_CHECK_LIBM],
2700 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2703 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
2704 # These system don't have libm, or don't need it
2707 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
2708 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
2711 AC_CHECK_LIB(m, cos, LIBM="-lm")
2717 # AC_LIBLTDL_CONVENIENCE([DIRECTORY])
2718 # -----------------------------------
2719 # sets LIBLTDL to the link flags for the libltdl convenience library and
2720 # LTDLINCL to the include flags for the libltdl header and adds
2721 # --enable-ltdl-convenience to the configure arguments. Note that LIBLTDL
2722 # and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If
2723 # DIRECTORY is not provided, it is assumed to be `libltdl'. LIBLTDL will
2724 # be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed with
2725 # '${top_srcdir}/' (note the single quotes!). If your package is not
2726 # flat and you're not using automake, define top_builddir and
2727 # top_srcdir appropriately in the Makefiles.
2728 AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
2729 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2730 case $enable_ltdl_convenience in
2731 no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
2732 "") enable_ltdl_convenience=yes
2733 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
2735 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
2736 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
2737 # For backwards non-gettext consistent compatibility...
2739 ])# AC_LIBLTDL_CONVENIENCE
2742 # AC_LIBLTDL_INSTALLABLE([DIRECTORY])
2743 # -----------------------------------
2744 # sets LIBLTDL to the link flags for the libltdl installable library and
2745 # LTDLINCL to the include flags for the libltdl header and adds
2746 # --enable-ltdl-install to the configure arguments. Note that LIBLTDL
2747 # and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If
2748 # DIRECTORY is not provided and an installed libltdl is not found, it is
2749 # assumed to be `libltdl'. LIBLTDL will be prefixed with '${top_builddir}/'
2750 # and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single
2751 # quotes!). If your package is not flat and you're not using automake,
2752 # define top_builddir and top_srcdir appropriately in the Makefiles.
2753 # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
2754 AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
2755 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2756 AC_CHECK_LIB(ltdl, lt_dlinit,
2757 [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
2758 [if test x"$enable_ltdl_install" = xno; then
2759 AC_MSG_WARN([libltdl not installed, but installation disabled])
2761 enable_ltdl_install=yes
2764 if test x"$enable_ltdl_install" = x"yes"; then
2765 ac_configure_args="$ac_configure_args --enable-ltdl-install"
2766 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
2767 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
2769 ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
2773 # For backwards non-gettext consistent compatibility...
2775 ])# AC_LIBLTDL_INSTALLABLE
2780 # enable support for C++ libraries
2781 AC_DEFUN([AC_LIBTOOL_CXX],
2782 [AC_REQUIRE([_LT_AC_LANG_CXX])
2788 AC_DEFUN([_LT_AC_LANG_CXX],
2789 [AC_REQUIRE([AC_PROG_CXX])
2790 AC_REQUIRE([AC_PROG_CXXCPP])
2791 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
2797 # enable support for Fortran 77 libraries
2798 AC_DEFUN([AC_LIBTOOL_F77],
2799 [AC_REQUIRE([_LT_AC_LANG_F77])
2805 AC_DEFUN([_LT_AC_LANG_F77],
2806 [AC_REQUIRE([AC_PROG_F77])
2807 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
2813 # enable support for GCJ libraries
2814 AC_DEFUN([AC_LIBTOOL_GCJ],
2815 [AC_REQUIRE([_LT_AC_LANG_GCJ])
2821 AC_DEFUN([_LT_AC_LANG_GCJ],
2822 [AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
2823 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
2824 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
2825 [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
2826 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
2827 [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
2828 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
2834 # enable support for Windows resource files
2835 AC_DEFUN([AC_LIBTOOL_RC],
2836 [AC_REQUIRE([LT_AC_PROG_RC])
2837 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
2841 # AC_LIBTOOL_LANG_C_CONFIG
2842 # ------------------------
2843 # Ensure that the configuration vars for the C compiler are
2844 # suitably defined. Those variables are subsequently used by
2845 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
2846 AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
2847 AC_DEFUN([_LT_AC_LANG_C_CONFIG],
2851 # Source file extension for C test sources.
2854 # Object file extension for compiled C test sources.
2856 _LT_AC_TAGVAR(objext, $1)=$objext
2858 # Code to be used in simple compile tests
2859 lt_simple_compile_test_code="int some_variable = 0;\n"
2861 # Code to be used in simple link tests
2862 lt_simple_link_test_code='int main(){return(0);}\n'
2867 # Check for any special shared library compilation flags.
2869 _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
2870 if test "$GCC" = no; then
2873 _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
2877 if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
2878 AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
2879 if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then :
2881 AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
2882 _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
2888 # Check to make sure the static flag actually works.
2890 AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
2891 _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
2892 $_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
2894 [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
2898 ## There is no encapsulation within the following macros, do not change
2899 ## the running order or otherwise move them around unless you know exactly
2900 ## what you are doing...
2901 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
2902 AC_LIBTOOL_PROG_COMPILER_PIC($1)
2903 AC_LIBTOOL_PROG_CC_C_O($1)
2904 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
2905 AC_LIBTOOL_PROG_LD_SHLIBS($1)
2906 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
2907 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
2908 AC_LIBTOOL_SYS_LIB_STRIP
2909 AC_LIBTOOL_DLOPEN_SELF($1)
2911 # Report which librarie types wil actually be built
2912 AC_MSG_CHECKING([if libtool supports shared libraries])
2913 AC_MSG_RESULT([$can_build_shared])
2915 AC_MSG_CHECKING([whether to build shared libraries])
2916 test "$can_build_shared" = "no" && enable_shared=no
2918 # On AIX, shared libraries and static libraries use the same namespace, and
2919 # are all built from PIC.
2922 test "$enable_shared" = yes && enable_static=no
2923 if test -n "$RANLIB"; then
2924 archive_cmds="$archive_cmds~\$RANLIB \$lib"
2925 postinstall_cmds='$RANLIB $lib'
2930 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
2931 test "$enable_shared" = yes && enable_static=no
2934 darwin* | rhapsody*)
2935 if test "$GCC" = yes; then
2936 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
2938 rhapsody* | darwin1.[[012]])
2939 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
2942 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
2943 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
2945 case ${MACOSX_DEPLOYMENT_TARGET} in
2947 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
2950 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup'
2956 output_verbose_link_cmd='echo'
2957 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring'
2958 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
2959 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
2960 _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}'
2961 _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}'
2962 _LT_AC_TAGVAR(hardcode_direct, $1)=no
2963 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
2964 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2965 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
2966 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
2968 _LT_AC_TAGVAR(ld_shlibs, $1)=no
2972 AC_MSG_RESULT([$enable_shared])
2974 AC_MSG_CHECKING([whether to build static libraries])
2975 # Make sure either enable_shared or enable_static is yes.
2976 test "$enable_shared" = yes || enable_static=yes
2977 AC_MSG_RESULT([$enable_static])
2979 AC_LIBTOOL_CONFIG($1)
2983 ])# AC_LIBTOOL_LANG_C_CONFIG
2986 # AC_LIBTOOL_LANG_CXX_CONFIG
2987 # --------------------------
2988 # Ensure that the configuration vars for the C compiler are
2989 # suitably defined. Those variables are subsequently used by
2990 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
2991 AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
2992 AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
2994 AC_REQUIRE([AC_PROG_CXX])
2995 AC_REQUIRE([AC_PROG_CXXCPP])
2997 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
2998 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
2999 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3000 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3001 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3002 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3003 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3004 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3005 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3006 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3007 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
3008 _LT_AC_TAGVAR(module_cmds, $1)=
3009 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
3010 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3011 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3012 _LT_AC_TAGVAR(no_undefined_flag, $1)=
3013 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3014 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3016 # Dependencies to place before and after the object being linked:
3017 _LT_AC_TAGVAR(predep_objects, $1)=
3018 _LT_AC_TAGVAR(postdep_objects, $1)=
3019 _LT_AC_TAGVAR(predeps, $1)=
3020 _LT_AC_TAGVAR(postdeps, $1)=
3021 _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3023 # Source file extension for C++ test sources.
3026 # Object file extension for compiled C++ test sources.
3028 _LT_AC_TAGVAR(objext, $1)=$objext
3030 # Code to be used in simple compile tests
3031 lt_simple_compile_test_code="int some_variable = 0;\n"
3033 # Code to be used in simple link tests
3034 lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
3036 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
3039 # Allow CC to be a program name with arguments.
3044 lt_save_with_gnu_ld=$with_gnu_ld
3045 lt_save_path_LD=$lt_cv_path_LD
3046 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3047 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3049 unset lt_cv_prog_gnu_ld
3051 if test -n "${lt_cv_path_LDCXX+set}"; then
3052 lt_cv_path_LD=$lt_cv_path_LDCXX
3056 test -z "${LDCXX+set}" || LD=$LDCXX
3059 _LT_AC_TAGVAR(compiler, $1)=$CC
3060 cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
3062 # We don't want -fno-exception wen compiling C++ code, so set the
3063 # no_builtin_flag separately
3064 if test "$GXX" = yes; then
3065 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3067 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3070 if test "$GXX" = yes; then
3071 # Set up default GNU C++ configuration
3075 # Check if GNU C++ uses GNU ld as the underlying linker, since the
3076 # archiving commands below assume that GNU ld is being used.
3077 if test "$with_gnu_ld" = yes; then
3078 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3079 _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'
3081 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3082 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3084 # If archive_cmds runs LD, not CC, wlarc should be empty
3085 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3086 # investigate it a little bit more. (MM)
3089 # ancient GNU ld didn't support --whole-archive et. al.
3090 if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3091 grep 'no-whole-archive' > /dev/null; then
3092 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3094 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3100 # A generic and very simple default shared library creation
3101 # command for GNU C++ for the case where it uses the native
3102 # linker, instead of GNU ld. If possible, this setting should
3103 # overridden to take advantage of the native linker features on
3104 # the platform it is being used on.
3105 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3108 # Commands to make compiler produce verbose output that lists
3109 # what "hidden" libraries, object files and flags are used when
3110 # linking a shared library.
3111 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3119 # PORTME: fill in a description of your system's C++ link characteristics
3120 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3121 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3124 # FIXME: insert proper C++ library support
3125 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3128 if test "$host_cpu" = ia64; then
3129 # On IA64, the linker does run time linking by default, so we don't
3130 # have to do anything special.
3131 aix_use_runtimelinking=no
3132 exp_sym_flag='-Bexport'
3135 aix_use_runtimelinking=no
3137 # Test if we are trying to use run time linking or normal
3138 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
3139 # need to do runtime linking.
3140 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
3141 for ld_flag in $LDFLAGS; do
3144 aix_use_runtimelinking=yes
3151 exp_sym_flag='-bexport'
3152 no_entry_flag='-bnoentry'
3155 # When large executables or shared objects are built, AIX ld can
3156 # have problems creating the table of contents. If linking a library
3157 # or program results in "error TOC overflow" add -mminimal-toc to
3158 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
3159 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3161 _LT_AC_TAGVAR(archive_cmds, $1)=''
3162 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3163 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3164 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3166 if test "$GXX" = yes; then
3167 case $host_os in aix4.[012]|aix4.[012].*)
3168 # We only want to do this on AIX 4.2 and lower, the check
3169 # below for broken collect2 doesn't work under 4.3+
3170 collect2name=`${CC} -print-prog-name=collect2`
3171 if test -f "$collect2name" && \
3172 strings "$collect2name" | grep resolve_lib_name >/dev/null
3174 # We have reworked collect2
3175 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3177 # We have old collect2
3178 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3179 # It fails to find uninstalled libraries when the uninstalled
3180 # path is not listed in the libpath. Setting hardcode_minus_L
3181 # to unsupported forces relinking
3182 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3183 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3184 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3187 shared_flag='-shared'
3190 if test "$host_cpu" = ia64; then
3191 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3192 # chokes on -Wl,-G. The following line is correct:
3195 if test "$aix_use_runtimelinking" = yes; then
3196 shared_flag='${wl}-G'
3198 shared_flag='${wl}-bM:SRE'
3203 # It seems that -bexpall does not export symbols beginning with
3204 # underscore (_), so it is better to generate a list of symbols to export.
3205 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3206 if test "$aix_use_runtimelinking" = yes; then
3207 # Warning - without using the other runtime loading flags (-brtl),
3208 # -berok will link without error, but may produce a broken library.
3209 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3210 # Determine the default libpath from the value encoded in an empty executable.
3211 _LT_AC_SYS_LIBPATH_AIX
3212 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3214 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3216 if test "$host_cpu" = ia64; then
3217 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3218 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3219 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
3221 # Determine the default libpath from the value encoded in an empty executable.
3222 _LT_AC_SYS_LIBPATH_AIX
3223 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3224 # Warning - without using the other run time loading flags,
3225 # -berok will link without error, but may produce a broken library.
3226 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3227 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3228 # -bexpall does not export symbols beginning with underscore (_)
3229 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3230 # Exported symbols can be pulled into shared objects from archives
3231 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
3232 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3233 # This is similar to how AIX traditionally builds it's shared libraries.
3234 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
3239 case $cc_basename in
3241 # FIXME: insert proper C++ library support
3242 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3247 cygwin* | mingw* | pw32*)
3248 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3249 # as there is no search path for DLLs.
3250 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3251 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3252 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3253 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3255 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3256 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
3257 # If the export-symbols file already is a .def file (1st line
3258 # is EXPORTS), use it as is; otherwise, prepend...
3259 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3260 cp $export_symbols $output_objdir/$soname.def;
3262 echo EXPORTS > $output_objdir/$soname.def;
3263 cat $export_symbols >> $output_objdir/$soname.def;
3265 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
3267 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3271 darwin* | rhapsody*)
3272 if test "$GXX" = yes; then
3273 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3275 rhapsody* | darwin1.[[012]])
3276 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
3279 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
3280 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
3282 case ${MACOSX_DEPLOYMENT_TARGET} in
3284 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
3287 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup'
3293 lt_int_apple_cc_single_mod=no
3294 output_verbose_link_cmd='echo'
3295 if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
3296 lt_int_apple_cc_single_mod=yes
3298 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3299 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
3301 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -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'
3303 _LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3305 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
3306 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3307 _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}'
3309 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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}'
3311 _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}'
3312 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3313 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3314 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3315 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
3316 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3318 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3323 case $cc_basename in
3325 # FIXME: insert proper C++ library support
3326 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3329 # Green Hills C++ Compiler
3330 # FIXME: insert proper C++ library support
3331 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3334 # FIXME: insert proper C++ library support
3335 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3340 # C++ shared libraries reported to be fairly broken before switch to ELF
3341 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3344 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3346 freebsd* | kfreebsd*-gnu)
3347 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3349 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3354 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3355 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3356 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3357 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3358 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3359 # but as the default
3360 # location of the library.
3362 case $cc_basename in
3364 # FIXME: insert proper C++ library support
3365 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3368 _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'
3369 # Commands to make compiler produce verbose output that lists
3370 # what "hidden" libraries, object files and flags are used when
3371 # linking a shared library.
3373 # There doesn't appear to be a way to prevent this compiler from
3374 # explicitly linking system object files so we need to strip them
3375 # from the output so that they don't get included in the library
3377 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'
3380 if test "$GXX" = yes; then
3381 _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'
3383 # FIXME: insert proper C++ library support
3384 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3390 if test $with_gnu_ld = no; then
3393 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3394 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
3395 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3398 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3401 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3402 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3403 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3409 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3410 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3413 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3414 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3415 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3416 # but as the default
3417 # location of the library.
3420 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3421 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3422 # but as the default
3423 # location of the library.
3427 case $cc_basename in
3429 # FIXME: insert proper C++ library support
3430 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3435 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
3438 _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'
3441 # Commands to make compiler produce verbose output that lists
3442 # what "hidden" libraries, object files and flags are used when
3443 # linking a shared library.
3445 # There doesn't appear to be a way to prevent this compiler from
3446 # explicitly linking system object files so we need to strip them
3447 # from the output so that they don't get included in the library
3449 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'
3452 if test "$GXX" = yes; then
3453 if test $with_gnu_ld = no; then
3456 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
3459 _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'
3464 # FIXME: insert proper C++ library support
3465 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3471 case $cc_basename in
3474 _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 ${objdir}/so_locations -o $lib'
3476 # Archives containing C++ object files must be created using
3477 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
3478 # necessary to make sure instantiated templates are included
3480 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
3483 if test "$GXX" = yes; then
3484 if test "$with_gnu_ld" = no; then
3485 _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}${objdir}/so_locations -o $lib'
3487 _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'
3490 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3493 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3494 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3497 case $cc_basename in
3499 # Kuck and Associates, Inc. (KAI) C++ Compiler
3501 # KCC will only create a shared library if the output file
3502 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3503 # to its proper name (with version) after linking.
3504 _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'
3505 _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'
3506 # Commands to make compiler produce verbose output that lists
3507 # what "hidden" libraries, object files and flags are used when
3508 # linking a shared library.
3510 # There doesn't appear to be a way to prevent this compiler from
3511 # explicitly linking system object files so we need to strip them
3512 # from the output so that they don't get included in the library
3514 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'
3516 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
3517 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3519 # Archives containing C++ object files must be created using
3520 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
3521 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
3526 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3527 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3528 _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'
3529 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3530 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3531 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
3535 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3536 _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'
3538 runpath_var=LD_RUN_PATH
3539 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
3540 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3542 # Commands to make compiler produce verbose output that lists
3543 # what "hidden" libraries, object files and flags are used when
3544 # linking a shared library.
3546 # There doesn't appear to be a way to prevent this compiler from
3547 # explicitly linking system object files so we need to strip them
3548 # from the output so that they don't get included in the library
3550 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'
3555 # FIXME: insert proper C++ library support
3556 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3559 # FIXME: insert proper C++ library support
3560 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3563 case $cc_basename in
3565 # FIXME: insert proper C++ library support
3566 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3569 # FIXME: insert proper C++ library support
3570 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3575 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
3576 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
3578 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
3579 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3580 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3582 # Workaround some broken pre-1.5 toolchains
3583 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
3586 case $cc_basename in
3588 # Kuck and Associates, Inc. (KAI) C++ Compiler
3590 # KCC will only create a shared library if the output file
3591 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3592 # to its proper name (with version) after linking.
3593 _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'
3595 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3596 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3598 # Archives containing C++ object files must be created using
3599 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
3600 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
3604 # Rational C++ 2.4.1
3605 # FIXME: insert proper C++ library support
3606 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3609 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3610 _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 ${objdir}/so_locations -o $lib'
3612 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3613 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3615 # Commands to make compiler produce verbose output that lists
3616 # what "hidden" libraries, object files and flags are used when
3617 # linking a shared library.
3619 # There doesn't appear to be a way to prevent this compiler from
3620 # explicitly linking system object files so we need to strip them
3621 # from the output so that they don't get included in the library
3623 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'
3626 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3627 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3628 _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}${objdir}/so_locations -o $lib'
3630 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3631 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3633 # Commands to make compiler produce verbose output that lists
3634 # what "hidden" libraries, object files and flags are used when
3635 # linking a shared library.
3636 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3639 # FIXME: insert proper C++ library support
3640 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3646 case $cc_basename in
3648 # Kuck and Associates, Inc. (KAI) C++ Compiler
3650 # KCC will only create a shared library if the output file
3651 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3652 # to its proper name (with version) after linking.
3653 _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'
3655 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3656 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3658 # Archives containing C++ object files must be created using
3659 # the KAI C++ compiler.
3660 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
3663 # Rational C++ 2.4.1
3664 # FIXME: insert proper C++ library support
3665 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3668 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
3669 _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 ${objdir}/so_locations -o $lib'
3670 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
3671 echo "-hidden">> $lib.exp~
3672 $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 $objdir/so_locations -o $lib~
3675 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
3676 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3678 # Commands to make compiler produce verbose output that lists
3679 # what "hidden" libraries, object files and flags are used when
3680 # linking a shared library.
3682 # There doesn't appear to be a way to prevent this compiler from
3683 # explicitly linking system object files so we need to strip them
3684 # from the output so that they don't get included in the library
3686 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'
3689 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3690 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3691 _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}${objdir}/so_locations -o $lib'
3693 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3694 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3696 # Commands to make compiler produce verbose output that lists
3697 # what "hidden" libraries, object files and flags are used when
3698 # linking a shared library.
3699 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3702 # FIXME: insert proper C++ library support
3703 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3709 # FIXME: insert proper C++ library support
3710 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3713 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3714 case $cc_basename in
3716 # FIXME: insert proper C++ library support
3717 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3720 # FIXME: insert proper C++ library support
3721 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3726 case $cc_basename in
3729 # FIXME: insert proper C++ library support
3730 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3734 # FIXME: insert proper C++ library support
3735 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3738 # FIXME: insert proper C++ library support
3739 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3744 case $cc_basename in
3746 # Sun C++ 4.2, 5.x and Centerline C++
3747 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
3748 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3749 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3750 $CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3752 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
3753 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3755 solaris2.[0-5] | solaris2.[0-5].*) ;;
3757 # The C++ compiler is used as linker so we must use $wl
3758 # flag to pass the commands to the underlying system
3760 # Supported since Solaris 2.6 (maybe 2.5.1?)
3761 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
3764 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3766 # Commands to make compiler produce verbose output that lists
3767 # what "hidden" libraries, object files and flags are used when
3768 # linking a shared library.
3770 # There doesn't appear to be a way to prevent this compiler from
3771 # explicitly linking system object files so we need to strip them
3772 # from the output so that they don't get included in the library
3774 output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3776 # Archives containing C++ object files must be created using
3777 # "CC -xar", where "CC" is the Sun C++ compiler. This is
3778 # necessary to make sure instantiated templates are included
3780 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
3783 # Green Hills C++ Compiler
3784 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3786 # The C++ compiler must be used to create the archive.
3787 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
3790 # GNU C++ compiler with Solaris linker
3791 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3792 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
3793 if $CC --version | grep -v '^2\.7' > /dev/null; then
3794 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3795 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3796 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3798 # Commands to make compiler produce verbose output that lists
3799 # what "hidden" libraries, object files and flags are used when
3800 # linking a shared library.
3801 output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
3803 # g++ 2.7 appears to require `-G' NOT `-shared' on this
3805 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3806 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3807 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3809 # Commands to make compiler produce verbose output that lists
3810 # what "hidden" libraries, object files and flags are used when
3811 # linking a shared library.
3812 output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
3815 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
3820 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
3821 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3824 case $cc_basename in
3826 # NonStop-UX NCC 3.20
3827 # FIXME: insert proper C++ library support
3828 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3831 # FIXME: insert proper C++ library support
3832 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3837 # FIXME: insert proper C++ library support
3838 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3841 # FIXME: insert proper C++ library support
3842 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3845 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
3846 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
3848 _LT_AC_TAGVAR(GCC, $1)="$GXX"
3849 _LT_AC_TAGVAR(LD, $1)="$LD"
3852 ## There is no encapsulation within the following macros, do not change
3853 ## the running order or otherwise move them around unless you know exactly
3854 ## what you are doing...
3855 AC_LIBTOOL_POSTDEP_PREDEP($1)
3856 AC_LIBTOOL_PROG_COMPILER_PIC($1)
3857 AC_LIBTOOL_PROG_CC_C_O($1)
3858 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3859 AC_LIBTOOL_PROG_LD_SHLIBS($1)
3860 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3861 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3862 AC_LIBTOOL_SYS_LIB_STRIP
3863 AC_LIBTOOL_DLOPEN_SELF($1)
3865 AC_LIBTOOL_CONFIG($1)
3872 with_gnu_ldcxx=$with_gnu_ld
3873 with_gnu_ld=$lt_save_with_gnu_ld
3874 lt_cv_path_LDCXX=$lt_cv_path_LD
3875 lt_cv_path_LD=$lt_save_path_LD
3876 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
3877 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
3878 ])# AC_LIBTOOL_LANG_CXX_CONFIG
3880 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
3881 # ------------------------
3882 # Figure out "hidden" library dependencies from verbose
3883 # compiler output when linking a shared library.
3884 # Parse the compiler output and extract the necessary
3885 # objects, libraries and library flags.
3886 AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
3887 dnl we can't use the lt_simple_compile_test_code here,
3888 dnl because it contains code intended for an executable,
3889 dnl not a library. It's possible we should let each
3890 dnl tag define a new lt_????_link_test_code variable,
3891 dnl but it's only used here...
3892 ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
3894 void foo (void) { a = 0; }
3896 ],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
3900 Foo (void) { a = 0; }
3905 ],[$1],[F77],[cat > conftest.$ac_ext <<EOF
3913 ],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
3916 public void bar (void) {
3922 dnl Parse the compiler output and extract the necessary
3923 dnl objects, libraries and library flags.
3924 if AC_TRY_EVAL(ac_compile); then
3925 # Parse the compiler output and extract the necessary
3926 # objects, libraries and library flags.
3928 # Sentinel used to keep track of whether or not we are before
3929 # the conftest object file.
3930 pre_test_object_deps_done=no
3932 # The `*' in the case matches for architectures that use `case' in
3933 # $output_verbose_cmd can trigger glob expansion during the loop
3934 # eval without this substitution.
3935 output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`"
3937 for p in `eval $output_verbose_link_cmd`; do
3941 # Some compilers place space between "-{L,R}" and the path.
3944 || test $p = "-R"; then
3951 if test "$pre_test_object_deps_done" = no; then
3954 # Internal compiler library paths should come after those
3955 # provided the user. The postdeps already come after the
3956 # user supplied libs so there is no need to process them.
3957 if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
3958 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
3960 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
3963 # The "-l" case would never come before the object being
3964 # linked, so don't bother handling this case.
3967 if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
3968 _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
3970 _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
3976 # This assumes that the test object file only shows up
3977 # once in the compiler output.
3978 if test "$p" = "conftest.$objext"; then
3979 pre_test_object_deps_done=yes
3983 if test "$pre_test_object_deps_done" = no; then
3984 if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
3985 _LT_AC_TAGVAR(predep_objects, $1)="$p"
3987 _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
3990 if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
3991 _LT_AC_TAGVAR(postdep_objects, $1)="$p"
3993 _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
3998 *) ;; # Ignore the rest.
4006 echo "libtool.m4: error: problem compiling $1 test program"
4009 $rm -f confest.$objext
4011 case " $_LT_AC_TAGVAR(postdeps, $1) " in
4012 *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4014 ])# AC_LIBTOOL_POSTDEP_PREDEP
4016 # AC_LIBTOOL_LANG_F77_CONFIG
4017 # ------------------------
4018 # Ensure that the configuration vars for the C compiler are
4019 # suitably defined. Those variables are subsequently used by
4020 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4021 AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4022 AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4023 [AC_REQUIRE([AC_PROG_F77])
4024 AC_LANG_PUSH(Fortran 77)
4026 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4027 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
4028 _LT_AC_TAGVAR(always_export_symbols, $1)=no
4029 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
4030 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
4031 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4032 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
4033 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4034 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
4035 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
4036 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
4037 _LT_AC_TAGVAR(module_cmds, $1)=
4038 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
4039 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
4040 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4041 _LT_AC_TAGVAR(no_undefined_flag, $1)=
4042 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
4043 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4045 # Source file extension for f77 test sources.
4048 # Object file extension for compiled f77 test sources.
4050 _LT_AC_TAGVAR(objext, $1)=$objext
4052 # Code to be used in simple compile tests
4053 lt_simple_compile_test_code=" subroutine t\n return\n end\n"
4055 # Code to be used in simple link tests
4056 lt_simple_link_test_code=" program t\n end\n"
4058 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4061 # Allow CC to be a program name with arguments.
4065 _LT_AC_TAGVAR(compiler, $1)=$CC
4066 cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
4068 AC_MSG_CHECKING([if libtool supports shared libraries])
4069 AC_MSG_RESULT([$can_build_shared])
4071 AC_MSG_CHECKING([whether to build shared libraries])
4072 test "$can_build_shared" = "no" && enable_shared=no
4074 # On AIX, shared libraries and static libraries use the same namespace, and
4075 # are all built from PIC.
4078 test "$enable_shared" = yes && enable_static=no
4079 if test -n "$RANLIB"; then
4080 archive_cmds="$archive_cmds~\$RANLIB \$lib"
4081 postinstall_cmds='$RANLIB $lib'
4085 test "$enable_shared" = yes && enable_static=no
4088 AC_MSG_RESULT([$enable_shared])
4090 AC_MSG_CHECKING([whether to build static libraries])
4091 # Make sure either enable_shared or enable_static is yes.
4092 test "$enable_shared" = yes || enable_static=yes
4093 AC_MSG_RESULT([$enable_static])
4095 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4097 _LT_AC_TAGVAR(GCC, $1)="$G77"
4098 _LT_AC_TAGVAR(LD, $1)="$LD"
4100 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4101 AC_LIBTOOL_PROG_CC_C_O($1)
4102 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4103 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4104 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4105 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4106 AC_LIBTOOL_SYS_LIB_STRIP
4109 AC_LIBTOOL_CONFIG($1)
4113 ])# AC_LIBTOOL_LANG_F77_CONFIG
4116 # AC_LIBTOOL_LANG_GCJ_CONFIG
4117 # --------------------------
4118 # Ensure that the configuration vars for the C compiler are
4119 # suitably defined. Those variables are subsequently used by
4120 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4121 AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4122 AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4125 # Source file extension for Java test sources.
4128 # Object file extension for compiled Java test sources.
4130 _LT_AC_TAGVAR(objext, $1)=$objext
4132 # Code to be used in simple compile tests
4133 lt_simple_compile_test_code="class foo {}\n"
4135 # Code to be used in simple link tests
4136 lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n'
4138 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4141 # Allow CC to be a program name with arguments.
4145 _LT_AC_TAGVAR(compiler, $1)=$CC
4147 # GCJ did not exist at the time GCC didn't implicitly link libc in.
4148 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4151 ## There is no encapsulation within the following macros, do not change
4152 ## the running order or otherwise move them around unless you know exactly
4153 ## what you are doing...
4154 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4155 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4156 AC_LIBTOOL_PROG_CC_C_O($1)
4157 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4158 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4159 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4160 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4161 AC_LIBTOOL_SYS_LIB_STRIP
4162 AC_LIBTOOL_DLOPEN_SELF($1)
4164 AC_LIBTOOL_CONFIG($1)
4168 ])# AC_LIBTOOL_LANG_GCJ_CONFIG
4171 # AC_LIBTOOL_LANG_RC_CONFIG
4172 # --------------------------
4173 # Ensure that the configuration vars for the Windows resource compiler are
4174 # suitably defined. Those variables are subsequently used by
4175 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4176 AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4177 AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4180 # Source file extension for RC test sources.
4183 # Object file extension for compiled RC test sources.
4185 _LT_AC_TAGVAR(objext, $1)=$objext
4187 # Code to be used in simple compile tests
4188 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
4190 # Code to be used in simple link tests
4191 lt_simple_link_test_code="$lt_simple_compile_test_code"
4193 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4196 # Allow CC to be a program name with arguments.
4200 _LT_AC_TAGVAR(compiler, $1)=$CC
4201 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4203 AC_LIBTOOL_CONFIG($1)
4207 ])# AC_LIBTOOL_LANG_RC_CONFIG
4210 # AC_LIBTOOL_CONFIG([TAGNAME])
4211 # ----------------------------
4212 # If TAGNAME is not passed, then create an initial libtool script
4213 # with a default configuration from the untagged config vars. Otherwise
4214 # add code to config.status for appending the configuration named by
4215 # TAGNAME from the matching tagged config vars.
4216 AC_DEFUN([AC_LIBTOOL_CONFIG],
4217 [# The else clause should only fire when bootstrapping the
4218 # libtool distribution, otherwise you forgot to ship ltmain.sh
4219 # with your package, and you will get complaints that there are
4220 # no rules to generate ltmain.sh.
4221 if test -f "$ltmain"; then
4222 # See if we are running on zsh, and set the options which allow our commands through
4223 # without removal of \ escapes.
4224 if test -n "${ZSH_VERSION+set}" ; then
4225 setopt NO_GLOB_SUBST
4227 # Now quote all the things that may contain metacharacters while being
4228 # careful not to overquote the AC_SUBSTed values. We take copies of the
4229 # variables and quote the copies for generation of the libtool script.
4230 for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
4232 libname_spec library_names_spec soname_spec extract_expsyms_cmds \
4233 old_striplib striplib file_magic_cmd finish_cmds finish_eval \
4234 deplibs_check_method reload_flag reload_cmds need_locks \
4235 lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
4236 lt_cv_sys_global_symbol_to_c_name_address \
4237 sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
4238 old_postinstall_cmds old_postuninstall_cmds \
4239 _LT_AC_TAGVAR(compiler, $1) \
4240 _LT_AC_TAGVAR(CC, $1) \
4241 _LT_AC_TAGVAR(LD, $1) \
4242 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
4243 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
4244 _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
4245 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
4246 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
4247 _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
4248 _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
4249 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
4250 _LT_AC_TAGVAR(old_archive_cmds, $1) \
4251 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
4252 _LT_AC_TAGVAR(predep_objects, $1) \
4253 _LT_AC_TAGVAR(postdep_objects, $1) \
4254 _LT_AC_TAGVAR(predeps, $1) \
4255 _LT_AC_TAGVAR(postdeps, $1) \
4256 _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
4257 _LT_AC_TAGVAR(archive_cmds, $1) \
4258 _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
4259 _LT_AC_TAGVAR(postinstall_cmds, $1) \
4260 _LT_AC_TAGVAR(postuninstall_cmds, $1) \
4261 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
4262 _LT_AC_TAGVAR(allow_undefined_flag, $1) \
4263 _LT_AC_TAGVAR(no_undefined_flag, $1) \
4264 _LT_AC_TAGVAR(export_symbols_cmds, $1) \
4265 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
4266 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
4267 _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
4268 _LT_AC_TAGVAR(hardcode_automatic, $1) \
4269 _LT_AC_TAGVAR(module_cmds, $1) \
4270 _LT_AC_TAGVAR(module_expsym_cmds, $1) \
4271 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
4272 _LT_AC_TAGVAR(exclude_expsyms, $1) \
4273 _LT_AC_TAGVAR(include_expsyms, $1); do
4276 _LT_AC_TAGVAR(old_archive_cmds, $1) | \
4277 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
4278 _LT_AC_TAGVAR(archive_cmds, $1) | \
4279 _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
4280 _LT_AC_TAGVAR(module_cmds, $1) | \
4281 _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
4282 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
4283 _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
4284 extract_expsyms_cmds | reload_cmds | finish_cmds | \
4285 postinstall_cmds | postuninstall_cmds | \
4286 old_postinstall_cmds | old_postuninstall_cmds | \
4287 sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
4288 # Double-quote double-evaled strings.
4289 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
4292 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
4298 *'\[$]0 --fallback-echo"')
4299 lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
4304 [cfgfile="${ofile}T"
4305 trap "$rm \"$cfgfile\"; exit 1" 1 2 15
4307 AC_MSG_NOTICE([creating $ofile])],
4310 cat <<__EOF__ >> "$cfgfile"
4314 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
4315 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
4316 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
4318 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
4319 # Free Software Foundation, Inc.
4321 # This file is part of GNU Libtool:
4322 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
4324 # This program is free software; you can redistribute it and/or modify
4325 # it under the terms of the GNU General Public License as published by
4326 # the Free Software Foundation; either version 2 of the License, or
4327 # (at your option) any later version.
4329 # This program is distributed in the hope that it will be useful, but
4330 # WITHOUT ANY WARRANTY; without even the implied warranty of
4331 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4332 # General Public License for more details.
4334 # You should have received a copy of the GNU General Public License
4335 # along with this program; if not, write to the Free Software
4336 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
4338 # As a special exception to the GNU General Public License, if you
4339 # distribute this file as part of a program that contains a
4340 # configuration script generated by Autoconf, you may include it under
4341 # the same distribution terms that you use for the rest of that program.
4343 # A sed program that does not truncate output.
4346 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
4347 Xsed="$SED -e s/^X//"
4349 # The HP-UX ksh and POSIX shell print the target directory to stdout
4351 if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
4353 # The names of the tagged configurations supported by this script.
4356 # ### BEGIN LIBTOOL CONFIG],
4357 [# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
4359 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4361 # Shell to use when invoking shell scripts.
4364 # Whether or not to build shared libraries.
4365 build_libtool_libs=$enable_shared
4367 # Whether or not to build static libraries.
4368 build_old_libs=$enable_static
4370 # Whether or not to add -lc for building shared libraries.
4371 build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
4373 # Whether or not to disallow shared libs when runtime libs are static
4374 allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
4376 # Whether or not to optimize for fast installation.
4377 fast_install=$enable_fast_install
4380 host_alias=$host_alias
4383 # An echo program that does not interpret backslashes.
4388 AR_FLAGS=$lt_AR_FLAGS
4393 # A language-specific compiler.
4394 CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
4396 # Is the compiler the GNU C compiler?
4397 with_gcc=$_LT_AC_TAGVAR(GCC, $1)
4402 # The linker used to build libraries.
4403 LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
4405 # Whether we need hard or soft links.
4408 # A BSD-compatible nm program.
4411 # A symbol stripping program
4414 # Used to examine libraries when file_magic_cmd begins "file"
4415 MAGIC_CMD=$MAGIC_CMD
4417 # Used on cygwin: DLL creation program.
4420 # Used on cygwin: object dumper.
4423 # Used on cygwin: assembler.
4426 # The name of the directory that contains temporary libtool files.
4429 # How to create reloadable object files.
4430 reload_flag=$lt_reload_flag
4431 reload_cmds=$lt_reload_cmds
4433 # How to pass a linker flag through the compiler.
4434 wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
4436 # Object file suffix (normally "o").
4439 # Old archive suffix (normally "a").
4442 # Shared library suffix (normally ".so").
4443 shrext_cmds='$shrext_cmds'
4445 # Executable file suffix (normally "").
4448 # Additional compiler flags for building library objects.
4449 pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
4452 # What is the maximum length of a command?
4453 max_cmd_len=$lt_cv_sys_max_cmd_len
4455 # Does compiler simultaneously support -c and -o options?
4456 compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
4458 # Must we lock files when doing compilation ?
4459 need_locks=$lt_need_locks
4461 # Do we need the lib prefix for modules?
4462 need_lib_prefix=$need_lib_prefix
4464 # Do we need a version for libraries?
4465 need_version=$need_version
4467 # Whether dlopen is supported.
4468 dlopen_support=$enable_dlopen
4470 # Whether dlopen of programs is supported.
4471 dlopen_self=$enable_dlopen_self
4473 # Whether dlopen of statically linked programs is supported.
4474 dlopen_self_static=$enable_dlopen_self_static
4476 # Compiler flag to prevent dynamic linking.
4477 link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
4479 # Compiler flag to turn off builtin functions.
4480 no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
4482 # Compiler flag to allow reflexive dlopens.
4483 export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
4485 # Compiler flag to generate shared objects directly from archives.
4486 whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
4488 # Compiler flag to generate thread-safe objects.
4489 thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
4491 # Library versioning type.
4492 version_type=$version_type
4494 # Format of library name prefix.
4495 libname_spec=$lt_libname_spec
4497 # List of archive names. First name is the real one, the rest are links.
4498 # The last name is the one that the linker finds with -lNAME.
4499 library_names_spec=$lt_library_names_spec
4501 # The coded name of the library, if different from the real name.
4502 soname_spec=$lt_soname_spec
4504 # Commands used to build and install an old-style archive.
4506 old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
4507 old_postinstall_cmds=$lt_old_postinstall_cmds
4508 old_postuninstall_cmds=$lt_old_postuninstall_cmds
4510 # Create an old-style archive from a shared archive.
4511 old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
4513 # Create a temporary old-style archive to link instead of a shared archive.
4514 old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
4516 # Commands used to build and install a shared archive.
4517 archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
4518 archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
4519 postinstall_cmds=$lt_postinstall_cmds
4520 postuninstall_cmds=$lt_postuninstall_cmds
4522 # Commands used to build a loadable module (assumed same as above if empty)
4523 module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
4524 module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
4526 # Commands to strip libraries.
4527 old_striplib=$lt_old_striplib
4528 striplib=$lt_striplib
4530 # Dependencies to place before the objects being linked to create a
4532 predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
4534 # Dependencies to place after the objects being linked to create a
4536 postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
4538 # Dependencies to place before the objects being linked to create a
4540 predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
4542 # Dependencies to place after the objects being linked to create a
4544 postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
4546 # The library search path used internally by the compiler when linking
4548 compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
4550 # Method to check whether dependent libraries are shared objects.
4551 deplibs_check_method=$lt_deplibs_check_method
4553 # Command to use when deplibs_check_method == file_magic.
4554 file_magic_cmd=$lt_file_magic_cmd
4556 # Flag that allows shared libraries with undefined symbols to be built.
4557 allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
4559 # Flag that forces no undefined symbols.
4560 no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
4562 # Commands used to finish a libtool library installation in a directory.
4563 finish_cmds=$lt_finish_cmds
4565 # Same as above, but a single script fragment to be evaled but not shown.
4566 finish_eval=$lt_finish_eval
4568 # Take the output of nm and produce a listing of raw symbols and C names.
4569 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
4571 # Transform the output of nm in a proper C declaration
4572 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
4574 # Transform the output of nm in a C name address pair
4575 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
4577 # This is the shared library runtime path variable.
4578 runpath_var=$runpath_var
4580 # This is the shared library path variable.
4581 shlibpath_var=$shlibpath_var
4583 # Is shlibpath searched before the hard-coded library search path?
4584 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
4586 # How to hardcode a shared library path into an executable.
4587 hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
4589 # Whether we should hardcode library paths into libraries.
4590 hardcode_into_libs=$hardcode_into_libs
4592 # Flag to hardcode \$libdir into a binary during linking.
4593 # This must work even if \$libdir does not exist.
4594 hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
4596 # If ld is used when linking, flag to hardcode \$libdir into
4597 # a binary during linking. This must work even if \$libdir does
4599 hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
4601 # Whether we need a single -rpath flag with a separated argument.
4602 hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
4604 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
4606 hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
4608 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
4610 hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
4612 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
4613 # the resulting binary.
4614 hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
4616 # Set to yes if building a shared library automatically hardcodes DIR into the library
4617 # and all subsequent libraries and executables linked against it.
4618 hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
4620 # Variables whose values should be saved in libtool wrapper scripts and
4621 # restored at relink time.
4622 variables_saved_for_relink="$variables_saved_for_relink"
4624 # Whether libtool must link a program against all its dependency libraries.
4625 link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
4627 # Compile-time system search path for libraries
4628 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
4630 # Run-time system search path for libraries
4631 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
4633 # Fix the shell variable \$srcfile for the compiler.
4634 fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
4636 # Set to yes if exported symbols are required.
4637 always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
4639 # The commands to list exported symbols.
4640 export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
4642 # The commands to extract the exported symbol list from a shared archive.
4643 extract_expsyms_cmds=$lt_extract_expsyms_cmds
4645 # Symbols that should not be listed in the preloaded symbols.
4646 exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
4648 # Symbols that must always be exported.
4649 include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
4652 [# ### END LIBTOOL CONFIG],
4653 [# ### END LIBTOOL TAG CONFIG: $tagname])
4660 cat <<\EOF >> "$cfgfile"
4662 # AIX sometimes has problems with the GCC collect2 program. For some
4663 # reason, if we set the COLLECT_NAMES environment variable, the problems
4664 # vanish in a puff of smoke.
4665 if test "X${COLLECT_NAMES+set}" != Xset; then
4667 export COLLECT_NAMES
4673 # We use sed instead of cat because bash on DJGPP gets confused if
4674 # if finds mixed CR/LF and LF-only lines. Since sed operates in
4675 # text mode, it properly converts lines to CR/LF. This bash problem
4676 # is reportedly fixed, but why not run on old versions too?
4677 sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
4679 mv -f "$cfgfile" "$ofile" || \
4680 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
4684 # If there is no Makefile yet, we rely on a make rule to execute
4685 # `config.status --recheck' to rerun these tests and create the
4686 # libtool script then.
4687 ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
4688 if test -f "$ltmain_in"; then
4689 test -f Makefile && make "$ltmain"
4692 ])# AC_LIBTOOL_CONFIG
4695 # AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
4696 # -------------------------------------------
4697 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
4698 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
4700 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4702 if test "$GCC" = yes; then
4703 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
4705 AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4706 lt_cv_prog_compiler_rtti_exceptions,
4707 [-fno-rtti -fno-exceptions], [],
4708 [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4710 ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
4713 # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
4714 # ---------------------------------
4715 AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
4716 [AC_REQUIRE([AC_CANONICAL_HOST])
4717 AC_REQUIRE([AC_PROG_NM])
4718 AC_REQUIRE([AC_OBJEXT])
4719 # Check for command to grab the raw symbol name followed by C symbol from nm.
4720 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4721 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4723 # These are sane defaults that work on at least a few old systems.
4724 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4726 # Character class describing NM global symbol codes.
4727 symcode='[[BCDEGRST]]'
4729 # Regexp to match symbols that can be accessed directly from C.
4730 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4732 # Transform the above into a raw symbol and a C symbol.
4733 symxfrm='\1 \2\3 \3'
4735 # Transform an extracted symbol line into a proper C declaration
4736 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
4738 # Transform an extracted symbol line into symbol name and symbol address
4739 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'"
4741 # Define system-specific variables.
4746 cygwin* | mingw* | pw32*)
4747 symcode='[[ABCDGISTW]]'
4749 hpux*) # Its linker distinguishes data from code symbols
4750 if test "$host_cpu" = ia64; then
4751 symcode='[[ABCDEGRST]]'
4753 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4754 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'"
4757 symcode='[[BCDEGRST]]'
4760 symcode='[[BCDEGQRST]]'
4766 symcode='[[DFNSTU]]'
4770 # Handle CRLF in mingw tool chain
4774 opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4778 # If we're using GNU nm, then use its standard symbol codes.
4779 case `$NM -V 2>&1` in
4780 *GNU* | *'with BFD'*)
4781 symcode='[[ABCDGIRSTW]]' ;;
4784 # Try without a prefix undercore, then with it.
4785 for ac_symprfx in "" "_"; do
4787 # Write the raw and C identifiers.
4788 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
4790 # Check to see that the pipe works correctly.
4794 cat > conftest.$ac_ext <<EOF
4799 void nm_test_func(){}
4803 int main(){nm_test_var='a';nm_test_func();return(0);}
4806 if AC_TRY_EVAL(ac_compile); then
4807 # Now try to grab the symbols.
4809 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
4810 # Try sorting and uniquifying the output.
4811 if sort "$nlist" | uniq > "$nlist"T; then
4812 mv -f "$nlist"T "$nlist"
4817 # Make sure that we snagged all the symbols we need.
4818 if grep ' nm_test_var$' "$nlist" >/dev/null; then
4819 if grep ' nm_test_func$' "$nlist" >/dev/null; then
4820 cat <<EOF > conftest.$ac_ext
4826 # Now generate the symbol file.
4827 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
4829 cat <<EOF >> conftest.$ac_ext
4830 #if defined (__STDC__) && __STDC__
4831 # define lt_ptr_t void *
4833 # define lt_ptr_t char *
4837 /* The mapping between symbol names and symbols. */
4842 lt_preloaded_symbols[[]] =
4845 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
4846 cat <<\EOF >> conftest.$ac_ext
4854 # Now try linking the two files.
4855 mv conftest.$ac_objext conftstm.$ac_objext
4856 lt_save_LIBS="$LIBS"
4857 lt_save_CFLAGS="$CFLAGS"
4858 LIBS="conftstm.$ac_objext"
4859 CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4860 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4863 LIBS="$lt_save_LIBS"
4864 CFLAGS="$lt_save_CFLAGS"
4866 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4869 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4872 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4875 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4876 cat conftest.$ac_ext >&5
4878 rm -f conftest* conftst*
4880 # Do not use the global_symbol_pipe unless it works.
4881 if test "$pipe_works" = yes; then
4884 lt_cv_sys_global_symbol_pipe=
4888 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4889 lt_cv_sys_global_symbol_to_cdecl=
4891 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4892 AC_MSG_RESULT(failed)
4896 ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
4899 # AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
4900 # ---------------------------------------
4901 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
4902 [_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
4903 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4904 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
4906 AC_MSG_CHECKING([for $compiler option to produce PIC])
4908 # C++ specific cases for pic, static, wl, etc.
4909 if test "$GXX" = yes; then
4910 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4911 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
4915 # All AIX code is PIC.
4916 if test "$host_cpu" = ia64; then
4917 # AIX 5 now supports IA64 processor
4918 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4922 # FIXME: we need at least 68020 code to build shared libraries, but
4923 # adding the `-m68020' flag to GCC prevents building anything better,
4925 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4927 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4928 # PIC is the default for these OSes.
4930 mingw* | os2* | pw32*)
4931 # This hack is so that the source file can tell whether it is being
4932 # built for inclusion in a dll (and should export symbols for example).
4933 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
4935 darwin* | rhapsody*)
4936 # PIC is the default on this platform
4937 # Common symbols not allowed in MH_DYLIB files
4938 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4941 # DJGPP does not support shared libraries at all
4942 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4945 if test -d /usr/nec; then
4946 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4950 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4956 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4961 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4967 # All AIX code is PIC.
4968 if test "$host_cpu" = ia64; then
4969 # AIX 5 now supports IA64 processor
4970 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4972 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4976 case $cc_basename in
4978 # Green Hills C++ Compiler
4979 # _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"
4984 case $cc_basename in
4986 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4989 # Green Hills C++ Compiler
4990 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4996 freebsd* | kfreebsd*-gnu)
4997 # FreeBSD uses GNU C++
4999 hpux9* | hpux10* | hpux11*)
5000 case $cc_basename in
5002 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5003 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
5004 if test "$host_cpu" != ia64; then
5005 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5009 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5010 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
5016 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5024 irix5* | irix6* | nonstopux*)
5025 case $cc_basename in
5027 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5028 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5029 # CC pic flag -KPIC is the default.
5036 case $cc_basename in
5039 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5040 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5044 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5045 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5046 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5050 # Make sure the PIC flag is empty. It appears that all Alpha
5051 # Linux and Compaq Tru64 Unix objects are PIC.
5052 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5053 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5064 case $cc_basename in
5066 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5074 osf3* | osf4* | osf5*)
5075 case $cc_basename in
5077 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5080 # Rational C++ 2.4.1
5081 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5084 # Digital/Compaq C++
5085 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5086 # Make sure the PIC flag is empty. It appears that all Alpha
5087 # Linux and Compaq Tru64 Unix objects are PIC.
5088 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5089 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5098 case $cc_basename in
5100 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5107 case $cc_basename in
5109 # Sun C++ 4.2, 5.x and Centerline C++
5110 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5111 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5112 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5115 # Green Hills C++ Compiler
5116 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5123 case $cc_basename in
5126 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5127 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5131 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5138 case $cc_basename in
5140 # NonStop-UX NCC 3.20
5141 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5152 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5158 if test "$GCC" = yes; then
5159 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5160 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5164 # All AIX code is PIC.
5165 if test "$host_cpu" = ia64; then
5166 # AIX 5 now supports IA64 processor
5167 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5172 # FIXME: we need at least 68020 code to build shared libraries, but
5173 # adding the `-m68020' flag to GCC prevents building anything better,
5175 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5178 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5179 # PIC is the default for these OSes.
5182 mingw* | pw32* | os2*)
5183 # This hack is so that the source file can tell whether it is being
5184 # built for inclusion in a dll (and should export symbols for example).
5185 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5188 darwin* | rhapsody*)
5189 # PIC is the default on this platform
5190 # Common symbols not allowed in MH_DYLIB files
5191 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5195 # Just because we use GCC doesn't mean we suddenly get shared libraries
5196 # on systems that don't support them.
5197 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5202 if test -d /usr/nec; then
5203 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5208 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5215 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5221 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5225 # PORTME Check for flag to pass linker flags through the system compiler.
5228 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5229 if test "$host_cpu" = ia64; then
5230 # AIX 5 now supports IA64 processor
5231 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5233 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5237 mingw* | pw32* | os2*)
5238 # This hack is so that the source file can tell whether it is being
5239 # built for inclusion in a dll (and should export symbols for example).
5240 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5243 hpux9* | hpux10* | hpux11*)
5244 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5245 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5252 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5255 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5256 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5259 irix5* | irix6* | nonstopux*)
5260 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5261 # PIC (with -KPIC) is the default.
5262 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5266 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5267 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5273 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5274 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5275 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5278 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5279 # All Alpha code is PIC.
5280 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5285 osf3* | osf4* | osf5*)
5286 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5287 # All OSF/1 code is PIC.
5288 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5292 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
5293 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
5297 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5298 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5299 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5303 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5304 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5305 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5308 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5309 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5310 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5311 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5315 if test -d /usr/nec ;then
5316 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5317 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
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],[])])"
5360 # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
5361 # ------------------------------------
5362 # See if the linker supports building shared libraries.
5363 AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
5364 [AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5366 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5369 # If we're using GNU nm, then we don't want the "-C" option.
5370 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5371 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5372 _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'
5374 _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'
5378 _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5381 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
5384 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5389 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
5390 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5391 _LT_AC_TAGVAR(archive_cmds, $1)=
5392 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
5393 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
5394 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5395 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5396 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5397 _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
5398 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5399 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5400 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5401 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5402 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
5403 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5404 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
5405 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
5406 _LT_AC_TAGVAR(module_cmds, $1)=
5407 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
5408 _LT_AC_TAGVAR(always_export_symbols, $1)=no
5409 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5410 # include_expsyms should be a list of space-separated symbols to be *always*
5411 # included in the symbol list
5412 _LT_AC_TAGVAR(include_expsyms, $1)=
5413 # exclude_expsyms can be an extended regexp of symbols to exclude
5414 # it will be wrapped by ` (' and `)$', so one must not match beginning or
5415 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5416 # as well as any symbol that contains `d'.
5417 _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
5418 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5419 # platforms (ab)use it in PIC code, but their linkers get confused if
5420 # the symbol is explicitly referenced. Since portable code cannot
5421 # rely on this symbol name, it's probably fine to never include it in
5422 # preloaded symbol tables.
5423 extract_expsyms_cmds=
5426 cygwin* | mingw* | pw32*)
5427 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5428 # When not using gcc, we currently assume that we are using
5429 # Microsoft Visual C++.
5430 if test "$GCC" != yes; then
5439 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
5440 if test "$with_gnu_ld" = yes; then
5441 # If archive_cmds runs LD, not CC, wlarc should be empty
5444 # See if GNU ld supports shared libraries.
5446 aix3* | aix4* | aix5*)
5447 # On AIX/PPC, the GNU linker is very broken
5448 if test "$host_cpu" != ia64; then
5449 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5452 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
5453 *** to be unable to reliably create shared libraries on AIX.
5454 *** Therefore, libtool is disabling shared libraries support. If you
5455 *** really care for shared libraries, you may want to modify your PATH
5456 *** so that a non-GNU linker is found, and then restart.
5463 _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)'
5464 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5465 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5467 # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
5468 # that the semantics of dynamic libraries on AmigaOS, at least up
5469 # to version 4, is to share data among multiple programs linked
5470 # with the same dynamic library. Since this doesn't match the
5471 # behavior of shared libraries on other platforms, we can't use
5473 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5477 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5478 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5479 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5480 # support --undefined. This deserves some investigation. FIXME
5481 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5483 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5487 cygwin* | mingw* | pw32*)
5488 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5489 # as there is no search path for DLLs.
5490 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5491 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5492 _LT_AC_TAGVAR(always_export_symbols, $1)=no
5493 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5494 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
5496 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
5497 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
5498 # If the export-symbols file already is a .def file (1st line
5499 # is EXPORTS), use it as is; otherwise, prepend...
5500 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5501 cp $export_symbols $output_objdir/$soname.def;
5503 echo EXPORTS > $output_objdir/$soname.def;
5504 cat $export_symbols >> $output_objdir/$soname.def;
5506 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
5513 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5514 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5517 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5518 _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'
5523 if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
5524 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5527 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5528 *** create shared libraries on Solaris systems. Therefore, libtool
5529 *** is disabling shared libraries support. We urge you to upgrade GNU
5530 *** binutils to release 2.9.1 or newer. Another option is to modify
5531 *** your PATH or compiler configuration so that the native linker is
5532 *** used, and then restart.
5535 elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5536 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5537 _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'
5539 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5544 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5546 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5547 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5551 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5552 tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5553 _LT_AC_TAGVAR(archive_cmds, $1)="$tmp_archive_cmds"
5554 supports_anon_versioning=no
5555 case `$LD -v 2>/dev/null` in
5556 *\ [01].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5557 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5558 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5559 *\ 2.11.*) ;; # other 2.11 versions
5560 *) supports_anon_versioning=yes ;;
5562 if test $supports_anon_versioning = yes; then
5563 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
5564 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5565 $echo "local: *; };" >> $output_objdir/$libname.ver~
5566 $CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5568 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="$tmp_archive_cmds"
5571 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5576 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5577 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5578 _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'
5580 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5585 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = yes; then
5586 runpath_var=LD_RUN_PATH
5587 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
5588 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5589 # ancient GNU ld didn't support --whole-archive et. al.
5590 if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
5591 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5593 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5597 # PORTME fill in a description of your system's linker (not GNU ld)
5600 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5601 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5602 _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'
5603 # Note: this linker hardcodes the directories in LIBPATH if there
5604 # are no directories specified by -L.
5605 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5606 if test "$GCC" = yes && test -z "$link_static_flag"; then
5607 # Neither direct hardcoding nor static linking is supported with a
5609 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5614 if test "$host_cpu" = ia64; then
5615 # On IA64, the linker does run time linking by default, so we don't
5616 # have to do anything special.
5617 aix_use_runtimelinking=no
5618 exp_sym_flag='-Bexport'
5621 # If we're using GNU nm, then we don't want the "-C" option.
5622 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5623 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5624 _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'
5626 _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'
5628 aix_use_runtimelinking=no
5630 # Test if we are trying to use run time linking or normal
5631 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5632 # need to do runtime linking.
5633 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
5634 for ld_flag in $LDFLAGS; do
5635 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5636 aix_use_runtimelinking=yes
5642 exp_sym_flag='-bexport'
5643 no_entry_flag='-bnoentry'
5646 # When large executables or shared objects are built, AIX ld can
5647 # have problems creating the table of contents. If linking a library
5648 # or program results in "error TOC overflow" add -mminimal-toc to
5649 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5650 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5652 _LT_AC_TAGVAR(archive_cmds, $1)=''
5653 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5654 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
5655 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5657 if test "$GCC" = yes; then
5658 case $host_os in aix4.[012]|aix4.[012].*)
5659 # We only want to do this on AIX 4.2 and lower, the check
5660 # below for broken collect2 doesn't work under 4.3+
5661 collect2name=`${CC} -print-prog-name=collect2`
5662 if test -f "$collect2name" && \
5663 strings "$collect2name" | grep resolve_lib_name >/dev/null
5665 # We have reworked collect2
5666 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5668 # We have old collect2
5669 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5670 # It fails to find uninstalled libraries when the uninstalled
5671 # path is not listed in the libpath. Setting hardcode_minus_L
5672 # to unsupported forces relinking
5673 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5674 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5675 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5678 shared_flag='-shared'
5681 if test "$host_cpu" = ia64; then
5682 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5683 # chokes on -Wl,-G. The following line is correct:
5686 if test "$aix_use_runtimelinking" = yes; then
5687 shared_flag='${wl}-G'
5689 shared_flag='${wl}-bM:SRE'
5694 # It seems that -bexpall does not export symbols beginning with
5695 # underscore (_), so it is better to generate a list of symbols to export.
5696 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5697 if test "$aix_use_runtimelinking" = yes; then
5698 # Warning - without using the other runtime loading flags (-brtl),
5699 # -berok will link without error, but may produce a broken library.
5700 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
5701 # Determine the default libpath from the value encoded in an empty executable.
5702 _LT_AC_SYS_LIBPATH_AIX
5703 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5704 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5706 if test "$host_cpu" = ia64; then
5707 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5708 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5709 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
5711 # Determine the default libpath from the value encoded in an empty executable.
5712 _LT_AC_SYS_LIBPATH_AIX
5713 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5714 # Warning - without using the other run time loading flags,
5715 # -berok will link without error, but may produce a broken library.
5716 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5717 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5718 # -bexpall does not export symbols beginning with underscore (_)
5719 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5720 # Exported symbols can be pulled into shared objects from archives
5721 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
5722 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
5723 # This is similar to how AIX traditionally builds it's shared libraries.
5724 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
5730 _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)'
5731 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5732 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5733 # see comment about different semantics on the GNU ld section
5734 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5738 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5741 cygwin* | mingw* | pw32*)
5742 # When not using gcc, we currently assume that we are using
5743 # Microsoft Visual C++.
5744 # hardcode_libdir_flag_spec is actually meaningless, as there is
5745 # no search path for DLLs.
5746 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5747 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5748 # Tell ltmain to make .lib files, not .a files.
5750 # Tell ltmain to make .dll files, not .so files.
5752 # FIXME: Setting linknames here is a bad hack.
5753 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
5754 # The linker will automatically build a .lib file if we build a DLL.
5755 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
5756 # FIXME: Should let the user specify the lib program.
5757 _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
5758 fix_srcfile_path='`cygpath -w "$srcfile"`'
5759 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5762 darwin* | rhapsody*)
5763 if test "$GXX" = yes ; then
5764 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
5766 rhapsody* | darwin1.[[012]])
5767 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
5770 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
5771 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
5773 case ${MACOSX_DEPLOYMENT_TARGET} in
5775 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
5778 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup'
5784 lt_int_apple_cc_single_mod=no
5785 output_verbose_link_cmd='echo'
5786 if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
5787 lt_int_apple_cc_single_mod=yes
5789 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
5790 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
5792 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -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'
5794 _LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
5795 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
5796 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
5797 _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}'
5799 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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}'
5801 _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}'
5802 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5803 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
5804 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5805 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
5806 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5808 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5813 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5814 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5815 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5819 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5822 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
5823 # support. Future versions do this automatically, but an explicit c++rt0.o
5824 # does not break anything, and helps significantly (at the cost of a little
5827 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
5828 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5829 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5830 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5833 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
5835 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5836 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5837 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5838 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5841 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5842 freebsd* | kfreebsd*-gnu)
5843 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
5844 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5845 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5846 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5850 if test "$GCC" = yes; then
5851 _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'
5853 _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'
5855 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5856 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5857 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5859 # hardcode_minus_L: Not really in the search PATH,
5860 # but as the default location of the library.
5861 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5862 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5866 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
5869 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5872 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5878 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
5881 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
5885 if test "$with_gnu_ld" = no; then
5888 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5889 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
5890 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5891 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5892 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5895 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5896 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5897 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5899 # hardcode_minus_L: Not really in the search PATH,
5900 # but as the default location of the library.
5901 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5904 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5905 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5906 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5907 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5909 # hardcode_minus_L: Not really in the search PATH,
5910 # but as the default location of the library.
5911 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5917 irix5* | irix6* | nonstopux*)
5918 if test "$GCC" = yes; then
5919 _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'
5921 _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'
5922 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
5924 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5925 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5926 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5930 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5931 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
5933 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
5935 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5936 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5937 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5941 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5942 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5943 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5944 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5945 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5949 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5950 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5951 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5952 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5953 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5954 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5957 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5958 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5959 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5962 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5963 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5970 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5971 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5972 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5973 _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'
5974 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
5978 if test "$GCC" = yes; then
5979 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5980 _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'
5982 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5983 _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'
5985 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5986 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5989 osf4* | osf5*) # as osf3* with the addition of -msym flag
5990 if test "$GCC" = yes; then
5991 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5992 _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'
5993 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5995 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5996 _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'
5997 _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~
5998 $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
6000 # Both c and cxx compiler support -rpath directly
6001 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6003 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6007 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6008 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6009 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6010 runpath_var=LD_RUN_PATH
6011 hardcode_runpath_var=yes
6015 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6016 if test "$GCC" = yes; then
6017 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6018 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6019 $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
6021 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6022 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6023 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6025 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6026 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6028 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6029 *) # Supported since Solaris 2.6 (maybe 2.5.1?)
6030 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
6032 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6036 if test "x$host_vendor" = xsequent; then
6037 # Use $CC to link under sequent, because it throws in some extra .o
6038 # files that make .init and .fini sections work.
6039 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6041 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6043 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6044 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6045 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6046 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6050 case $host_vendor in
6052 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6053 _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6056 ## LD is ld it makes a PLAMLIB
6057 ## CC just makes a GrossModule.
6058 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6059 _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6060 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6063 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6064 _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6067 runpath_var='LD_RUN_PATH'
6068 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6072 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6073 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6074 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6078 if test -d /usr/nec; then
6079 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6080 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6081 runpath_var=LD_RUN_PATH
6082 hardcode_runpath_var=yes
6083 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
6088 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6089 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6090 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6091 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6092 hardcode_runpath_var=yes
6093 runpath_var=LD_RUN_PATH
6096 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
6097 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
6098 if test "$GCC" = yes; then
6099 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6101 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6103 runpath_var='LD_RUN_PATH'
6104 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6108 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6109 # $CC -shared without GNU ld will not create a library from C++
6110 # object files and a static libstdc++, better avoid it by now
6111 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6112 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6113 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6114 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6115 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6116 runpath_var='LD_RUN_PATH'
6120 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6121 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6122 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6126 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6131 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
6132 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6134 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
6135 if test "$GCC" = yes; then
6136 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
6140 # Do we need to explicitly link libc?
6142 case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
6144 # Assume -lc should be added
6145 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6147 if test "$enable_shared" = yes && test "$GCC" = yes; then
6148 case $_LT_AC_TAGVAR(archive_cmds, $1) in
6150 # FIXME: we may have to deal with multi-command sequences.
6153 # Test whether the compiler implicitly links with -lc since on some
6154 # systems, -lgcc has to come before -lc. If gcc already passes -lc
6155 # to ld, don't add -lc before -lgcc.
6156 AC_MSG_CHECKING([whether -lc should be explicitly linked in])
6158 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
6160 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6163 libobjs=conftest.$ac_objext
6165 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
6171 lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
6172 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
6173 if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
6175 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6177 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6179 _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6181 cat conftest.err 1>&5
6184 AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
6190 ])# AC_LIBTOOL_PROG_LD_SHLIBS
6193 # _LT_AC_FILE_LTDLL_C
6194 # -------------------
6195 # Be careful that the start marker always follows a newline.
6196 AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
6197 # /* ltdll.c starts here */
6198 # #define WIN32_LEAN_AND_MEAN
6199 # #include <windows.h>
6200 # #undef WIN32_LEAN_AND_MEAN
6201 # #include <stdio.h>
6203 # #ifndef __CYGWIN__
6204 # # ifdef __CYGWIN32__
6205 # # define __CYGWIN__ __CYGWIN32__
6209 # #ifdef __cplusplus
6212 # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
6213 # #ifdef __cplusplus
6218 # #include <cygwin/cygwin_dll.h>
6219 # DECLARE_CYGWIN_DLL( DllMain );
6221 # HINSTANCE __hDllInstance_base;
6224 # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
6226 # __hDllInstance_base = hInst;
6229 # /* ltdll.c ends here */
6230 ])# _LT_AC_FILE_LTDLL_C
6233 # _LT_AC_TAGVAR(VARNAME, [TAGNAME])
6234 # ---------------------------------
6235 AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
6239 AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
6240 AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
6241 AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
6242 AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
6243 AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
6244 AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
6245 AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
6247 # This is just to silence aclocal about the macro not being used
6248 ifelse([AC_DISABLE_FAST_INSTALL])
6250 AC_DEFUN([LT_AC_PROG_GCJ],
6251 [AC_CHECK_TOOL(GCJ, gcj, no)
6252 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
6256 AC_DEFUN([LT_AC_PROG_RC],
6257 [AC_CHECK_TOOL(RC, windres, no)
6260 ############################################################
6261 # NOTE: This macro has been submitted for inclusion into #
6262 # GNU Autoconf as AC_PROG_SED. When it is available in #
6263 # a released version of Autoconf we should remove this #
6264 # macro and use it instead. #
6265 ############################################################
6268 # Check for a fully-functional sed program, that truncates
6269 # as few characters as possible. Prefer GNU sed if found.
6270 AC_DEFUN([LT_AC_PROG_SED],
6271 [AC_MSG_CHECKING([for a sed that does not truncate output])
6272 AC_CACHE_VAL(lt_cv_path_SED,
6273 [# Loop through the user's path and test for sed and gsed.
6274 # Then use that list of sed's as ones to test for truncation.
6275 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6279 test -z "$as_dir" && as_dir=.
6280 for lt_ac_prog in sed gsed; do
6281 for ac_exec_ext in '' $ac_executable_extensions; do
6282 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
6283 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
6290 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
6291 # along with /bin/sed that truncates output.
6292 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
6293 test ! -f $lt_ac_sed && break
6294 cat /dev/null > conftest.in
6296 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
6297 # Check for GNU sed and select it if it is found.
6298 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
6299 lt_cv_path_SED=$lt_ac_sed
6303 cat conftest.in conftest.in >conftest.tmp
6304 mv conftest.tmp conftest.in
6305 cp conftest.in conftest.nl
6307 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
6308 cmp -s conftest.out conftest.nl || break
6309 # 10000 chars as input seems more than enough
6310 test $lt_ac_count -gt 10 && break
6311 lt_ac_count=`expr $lt_ac_count + 1`
6312 if test $lt_ac_count -gt $lt_ac_max; then
6313 lt_ac_max=$lt_ac_count
6314 lt_cv_path_SED=$lt_ac_sed
6320 AC_MSG_RESULT([$SED])