1 # generated automatically by aclocal 1.10.2 -*- Autoconf -*-
3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
4 # 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
5 # This file is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
14 m4_ifndef([AC_AUTOCONF_VERSION],
15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.63],,
17 [m4_warning([this file was generated for autoconf 2.63.
18 You have another version of autoconf. It may work, but is not guaranteed to.
19 If you have problems, you may need to regenerate the build system entirely.
20 To do so, use the procedure documented by the package, typically `autoreconf'.])])
22 # gettext.m4 serial 60 (gettext-0.17)
23 dnl Copyright (C) 1995-2007 Free Software Foundation, Inc.
24 dnl This file is free software; the Free Software Foundation
25 dnl gives unlimited permission to copy and/or distribute it,
26 dnl with or without modifications, as long as this notice is preserved.
28 dnl This file can can be used in projects which are not available under
29 dnl the GNU General Public License or the GNU Library General Public
30 dnl License but which still want to provide support for the GNU gettext
32 dnl Please note that the actual code of the GNU gettext library is covered
33 dnl by the GNU Library General Public License, and the rest of the GNU
34 dnl gettext package package is covered by the GNU General Public License.
35 dnl They are *not* in the public domain.
38 dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
39 dnl Bruno Haible <haible@clisp.cons.org>, 2000-2006.
41 dnl Macro to add for using GNU gettext.
43 dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]).
44 dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The
45 dnl default (if it is not specified or empty) is 'no-libtool'.
46 dnl INTLSYMBOL should be 'external' for packages with no intl directory,
47 dnl and 'no-libtool' or 'use-libtool' for packages with an intl directory.
48 dnl If INTLSYMBOL is 'use-libtool', then a libtool library
49 dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static,
50 dnl depending on --{enable,disable}-{shared,static} and on the presence of
51 dnl AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library
52 dnl $(top_builddir)/intl/libintl.a will be created.
53 dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext
54 dnl implementations (in libc or libintl) without the ngettext() function
55 dnl will be ignored. If NEEDSYMBOL is specified and is
56 dnl 'need-formatstring-macros', then GNU gettext implementations that don't
57 dnl support the ISO C 99 <inttypes.h> formatstring macros will be ignored.
58 dnl INTLDIR is used to find the intl libraries. If empty,
59 dnl the value `$(top_builddir)/intl/' is used.
61 dnl The result of the configuration is one of three cases:
62 dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled
64 dnl Catalog format: GNU --> install in $(datadir)
65 dnl Catalog extension: .mo after installation, .gmo in source tree
66 dnl 2) GNU gettext has been found in the system's C library.
67 dnl Catalog format: GNU --> install in $(datadir)
68 dnl Catalog extension: .mo after installation, .gmo in source tree
69 dnl 3) No internationalization, always use English msgid.
70 dnl Catalog format: none
71 dnl Catalog extension: none
72 dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur.
73 dnl The use of .gmo is historical (it was needed to avoid overwriting the
74 dnl GNU format catalogs when building on a platform with an X/Open gettext),
75 dnl but we keep it in order not to force irrelevant filename changes on the
78 AC_DEFUN([AM_GNU_GETTEXT],
80 dnl Argument checking.
81 ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], ,
82 [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT
84 ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], ,
85 [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT
87 define([gt_included_intl],
88 ifelse([$1], [external],
89 ifdef([AM_GNU_GETTEXT_][INTL_SUBDIR], [yes], [no]),
91 define([gt_libtool_suffix_prefix], ifelse([$1], [use-libtool], [l], []))
93 AM_GNU_GETTEXT_NEED([$2])
95 AC_REQUIRE([AM_PO_SUBDIRS])dnl
96 ifelse(gt_included_intl, yes, [
97 AC_REQUIRE([AM_INTL_SUBDIR])dnl
100 dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
101 AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
102 AC_REQUIRE([AC_LIB_RPATH])
104 dnl Sometimes libintl requires libiconv, so first search for libiconv.
105 dnl Ideally we would do this search only after the
106 dnl if test "$USE_NLS" = "yes"; then
107 dnl if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
108 dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT
109 dnl the configure script would need to contain the same shell code
110 dnl again, outside any 'if'. There are two solutions:
111 dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'.
112 dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE.
113 dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not
114 dnl documented, we avoid it.
115 ifelse(gt_included_intl, yes, , [
116 AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
119 dnl Sometimes, on MacOS X, libintl requires linking with CoreFoundation.
125 ifelse(gt_included_intl, yes, [
126 BUILD_INCLUDED_LIBINTL=no
127 USE_INCLUDED_LIBINTL=no
133 dnl Add a version number to the cache macros.
134 case " $gt_needs " in
135 *" need-formatstring-macros "*) gt_api_version=3 ;;
136 *" need-ngettext "*) gt_api_version=2 ;;
137 *) gt_api_version=1 ;;
139 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
140 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
142 dnl If we use NLS figure out what method
143 if test "$USE_NLS" = "yes"; then
144 gt_use_preinstalled_gnugettext=no
145 ifelse(gt_included_intl, yes, [
146 AC_MSG_CHECKING([whether included gettext is requested])
147 AC_ARG_WITH(included-gettext,
148 [ --with-included-gettext use the GNU gettext library included here],
149 nls_cv_force_use_gnu_gettext=$withval,
150 nls_cv_force_use_gnu_gettext=no)
151 AC_MSG_RESULT($nls_cv_force_use_gnu_gettext)
153 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
154 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
156 dnl User does not insist on using GNU NLS library. Figure out what
157 dnl to use. If GNU gettext is available we use this. Else we have
158 dnl to fall back to GNU NLS library.
160 if test $gt_api_version -ge 3; then
161 gt_revision_test_code='
162 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
163 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
166 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
170 gt_revision_test_code=
172 if test $gt_api_version -ge 2; then
173 gt_expression_test_code=' + * ngettext ("", "", 0)'
175 gt_expression_test_code=
178 AC_CACHE_CHECK([for GNU gettext in libc], [$gt_func_gnugettext_libc],
179 [AC_TRY_LINK([#include <libintl.h>
180 $gt_revision_test_code
181 extern int _nl_msg_cat_cntr;
182 extern int *_nl_domain_bindings;],
183 [bindtextdomain ("", "");
184 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings],
185 [eval "$gt_func_gnugettext_libc=yes"],
186 [eval "$gt_func_gnugettext_libc=no"])])
188 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
189 dnl Sometimes libintl requires libiconv, so first search for libiconv.
190 ifelse(gt_included_intl, yes, , [
193 dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL
194 dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv])
195 dnl because that would add "-liconv" to LIBINTL and LTLIBINTL
196 dnl even if libiconv doesn't exist.
197 AC_LIB_LINKFLAGS_BODY([intl])
198 AC_CACHE_CHECK([for GNU gettext in libintl],
199 [$gt_func_gnugettext_libintl],
200 [gt_save_CPPFLAGS="$CPPFLAGS"
201 CPPFLAGS="$CPPFLAGS $INCINTL"
203 LIBS="$LIBS $LIBINTL"
204 dnl Now see whether libintl exists and does not depend on libiconv.
205 AC_TRY_LINK([#include <libintl.h>
206 $gt_revision_test_code
207 extern int _nl_msg_cat_cntr;
212 const char *_nl_expand_alias (const char *);],
213 [bindtextdomain ("", "");
214 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")],
215 [eval "$gt_func_gnugettext_libintl=yes"],
216 [eval "$gt_func_gnugettext_libintl=no"])
217 dnl Now see whether libintl exists and depends on libiconv.
218 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
219 LIBS="$LIBS $LIBICONV"
220 AC_TRY_LINK([#include <libintl.h>
221 $gt_revision_test_code
222 extern int _nl_msg_cat_cntr;
227 const char *_nl_expand_alias (const char *);],
228 [bindtextdomain ("", "");
229 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")],
230 [LIBINTL="$LIBINTL $LIBICONV"
231 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
232 eval "$gt_func_gnugettext_libintl=yes"
235 CPPFLAGS="$gt_save_CPPFLAGS"
236 LIBS="$gt_save_LIBS"])
239 dnl If an already present or preinstalled GNU gettext() is found,
240 dnl use it. But if this macro is used in GNU gettext, and GNU
241 dnl gettext is already preinstalled in libintl, we update this
242 dnl libintl. (Cf. the install rule in intl/Makefile.in.)
243 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
244 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
245 && test "$PACKAGE" != gettext-runtime \
246 && test "$PACKAGE" != gettext-tools; }; then
247 gt_use_preinstalled_gnugettext=yes
249 dnl Reset the values set by searching for libintl.
255 ifelse(gt_included_intl, yes, [
256 if test "$gt_use_preinstalled_gnugettext" != "yes"; then
257 dnl GNU gettext is not found in the C library.
258 dnl Fall back on included GNU gettext library.
259 nls_cv_use_gnu_gettext=yes
263 if test "$nls_cv_use_gnu_gettext" = "yes"; then
264 dnl Mark actions used to generate GNU NLS library.
265 BUILD_INCLUDED_LIBINTL=yes
266 USE_INCLUDED_LIBINTL=yes
267 LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV $LIBTHREAD"
268 LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV $LTLIBTHREAD"
269 LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
273 if test "$gt_use_preinstalled_gnugettext" = "yes" \
274 || test "$nls_cv_use_gnu_gettext" = "yes"; then
275 dnl Mark actions to use GNU gettext tools.
280 if test -n "$INTL_MACOSX_LIBS"; then
281 if test "$gt_use_preinstalled_gnugettext" = "yes" \
282 || test "$nls_cv_use_gnu_gettext" = "yes"; then
283 dnl Some extra flags are needed during linking.
284 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
285 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
289 if test "$gt_use_preinstalled_gnugettext" = "yes" \
290 || test "$nls_cv_use_gnu_gettext" = "yes"; then
291 AC_DEFINE(ENABLE_NLS, 1,
292 [Define to 1 if translation of program messages to the user's native language
299 AC_MSG_CHECKING([whether to use NLS])
300 AC_MSG_RESULT([$USE_NLS])
301 if test "$USE_NLS" = "yes"; then
302 AC_MSG_CHECKING([where the gettext function comes from])
303 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
304 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
305 gt_source="external libintl"
310 gt_source="included intl directory"
312 AC_MSG_RESULT([$gt_source])
315 if test "$USE_NLS" = "yes"; then
317 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
318 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
319 AC_MSG_CHECKING([how to link with libintl])
320 AC_MSG_RESULT([$LIBINTL])
321 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL])
324 dnl For backward compatibility. Some packages may be using this.
325 AC_DEFINE(HAVE_GETTEXT, 1,
326 [Define if the GNU gettext() function is already present or preinstalled.])
327 AC_DEFINE(HAVE_DCGETTEXT, 1,
328 [Define if the GNU dcgettext() function is already present or preinstalled.])
331 dnl We need to process the po/ directory.
335 ifelse(gt_included_intl, yes, [
336 dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL
337 dnl to 'yes' because some of the testsuite requires it.
338 if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then
339 BUILD_INCLUDED_LIBINTL=yes
342 dnl Make all variables we use known to autoconf.
343 AC_SUBST(BUILD_INCLUDED_LIBINTL)
344 AC_SUBST(USE_INCLUDED_LIBINTL)
347 dnl For backward compatibility. Some configure.ins may be using this.
351 dnl For backward compatibility. Some Makefiles may be using this.
353 AC_SUBST(DATADIRNAME)
355 dnl For backward compatibility. Some Makefiles may be using this.
359 dnl For backward compatibility. Some Makefiles may be using this.
363 dnl For backward compatibility. Some Makefiles may be using this.
365 if test "$USE_INCLUDED_LIBINTL" = yes; then
366 INTLOBJS="\$(GETTOBJS)"
370 dnl Enable libtool support if the surrounding package wishes it.
371 INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix
372 AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX)
375 dnl For backward compatibility. Some Makefiles may be using this.
379 dnl Make all documented variables known to autoconf.
386 dnl gt_NEEDS_INIT ensures that the gt_needs variable is initialized.
387 m4_define([gt_NEEDS_INIT],
389 m4_divert_text([DEFAULTS], [gt_needs=])
390 m4_define([gt_NEEDS_INIT], [])
394 dnl Usage: AM_GNU_GETTEXT_NEED([NEEDSYMBOL])
395 AC_DEFUN([AM_GNU_GETTEXT_NEED],
397 m4_divert_text([INIT_PREPARE], [gt_needs="$gt_needs $1"])
401 dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version])
402 AC_DEFUN([AM_GNU_GETTEXT_VERSION], [])
404 # iconv.m4 serial AM6 (gettext-0.17)
405 dnl Copyright (C) 2000-2002, 2007 Free Software Foundation, Inc.
406 dnl This file is free software; the Free Software Foundation
407 dnl gives unlimited permission to copy and/or distribute it,
408 dnl with or without modifications, as long as this notice is preserved.
410 dnl From Bruno Haible.
412 AC_DEFUN([AM_ICONV_LINKFLAGS_BODY],
414 dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
415 AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
416 AC_REQUIRE([AC_LIB_RPATH])
418 dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
420 AC_LIB_LINKFLAGS_BODY([iconv])
423 AC_DEFUN([AM_ICONV_LINK],
425 dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and
426 dnl those with the standalone portable GNU libiconv installed).
427 AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
429 dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
431 AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
433 dnl Add $INCICONV to CPPFLAGS before performing the following checks,
434 dnl because if the user has installed libiconv and not disabled its use
435 dnl via --without-libiconv-prefix, he wants to use it. The first
436 dnl AC_TRY_LINK will then fail, the second AC_TRY_LINK will succeed.
437 am_save_CPPFLAGS="$CPPFLAGS"
438 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV])
440 AC_CACHE_CHECK([for iconv], am_cv_func_iconv, [
441 am_cv_func_iconv="no, consider installing GNU libiconv"
443 AC_TRY_LINK([#include <stdlib.h>
445 [iconv_t cd = iconv_open("","");
446 iconv(cd,NULL,NULL,NULL,NULL);
448 am_cv_func_iconv=yes)
449 if test "$am_cv_func_iconv" != yes; then
451 LIBS="$LIBS $LIBICONV"
452 AC_TRY_LINK([#include <stdlib.h>
454 [iconv_t cd = iconv_open("","");
455 iconv(cd,NULL,NULL,NULL,NULL);
458 am_cv_func_iconv=yes)
462 if test "$am_cv_func_iconv" = yes; then
463 AC_CACHE_CHECK([for working iconv], am_cv_func_iconv_works, [
464 dnl This tests against bugs in AIX 5.1 and HP-UX 11.11.
466 if test $am_cv_lib_iconv = yes; then
467 LIBS="$LIBS $LIBICONV"
474 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
477 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
478 if (cd_utf8_to_88591 != (iconv_t)(-1))
480 static const char input[] = "\342\202\254"; /* EURO SIGN */
482 const char *inptr = input;
483 size_t inbytesleft = strlen (input);
485 size_t outbytesleft = sizeof (buf);
486 size_t res = iconv (cd_utf8_to_88591,
487 (char **) &inptr, &inbytesleft,
488 &outptr, &outbytesleft);
493 #if 0 /* This bug could be worked around by the caller. */
494 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
496 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
497 if (cd_88591_to_utf8 != (iconv_t)(-1))
499 static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
501 const char *inptr = input;
502 size_t inbytesleft = strlen (input);
504 size_t outbytesleft = sizeof (buf);
505 size_t res = iconv (cd_88591_to_utf8,
506 (char **) &inptr, &inbytesleft,
507 &outptr, &outbytesleft);
513 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
515 if (/* Try standardized names. */
516 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
517 /* Try IRIX, OSF/1 names. */
518 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
520 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
521 /* Try HP-UX names. */
522 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
525 }], [am_cv_func_iconv_works=yes], [am_cv_func_iconv_works=no],
527 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
528 *) am_cv_func_iconv_works="guessing yes" ;;
532 case "$am_cv_func_iconv_works" in
533 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
534 *) am_func_iconv=yes ;;
537 am_func_iconv=no am_cv_lib_iconv=no
539 if test "$am_func_iconv" = yes; then
540 AC_DEFINE(HAVE_ICONV, 1,
541 [Define if you have the iconv() function and it works.])
543 if test "$am_cv_lib_iconv" = yes; then
544 AC_MSG_CHECKING([how to link with libiconv])
545 AC_MSG_RESULT([$LIBICONV])
547 dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV
549 CPPFLAGS="$am_save_CPPFLAGS"
560 if test "$am_cv_func_iconv" = yes; then
561 AC_MSG_CHECKING([for iconv declaration])
562 AC_CACHE_VAL(am_cv_proto_iconv, [
570 #if defined(__STDC__) || defined(__cplusplus)
571 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
575 ], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const")
576 am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"])
577 am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
578 AC_MSG_RESULT([$]{ac_t:-
579 }[$]am_cv_proto_iconv)
580 AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1,
581 [Define as const if the declaration of iconv() needs const.])
585 # intlmacosx.m4 serial 1 (gettext-0.17)
586 dnl Copyright (C) 2004-2007 Free Software Foundation, Inc.
587 dnl This file is free software; the Free Software Foundation
588 dnl gives unlimited permission to copy and/or distribute it,
589 dnl with or without modifications, as long as this notice is preserved.
591 dnl This file can can be used in projects which are not available under
592 dnl the GNU General Public License or the GNU Library General Public
593 dnl License but which still want to provide support for the GNU gettext
595 dnl Please note that the actual code of the GNU gettext library is covered
596 dnl by the GNU Library General Public License, and the rest of the GNU
597 dnl gettext package package is covered by the GNU General Public License.
598 dnl They are *not* in the public domain.
600 dnl Checks for special options needed on MacOS X.
601 dnl Defines INTL_MACOSX_LIBS.
602 AC_DEFUN([gt_INTL_MACOSX],
604 dnl Check for API introduced in MacOS X 10.2.
605 AC_CACHE_CHECK([for CFPreferencesCopyAppValue],
606 gt_cv_func_CFPreferencesCopyAppValue,
607 [gt_save_LIBS="$LIBS"
608 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
609 AC_TRY_LINK([#include <CoreFoundation/CFPreferences.h>],
610 [CFPreferencesCopyAppValue(NULL, NULL)],
611 [gt_cv_func_CFPreferencesCopyAppValue=yes],
612 [gt_cv_func_CFPreferencesCopyAppValue=no])
613 LIBS="$gt_save_LIBS"])
614 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
615 AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], 1,
616 [Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in the CoreFoundation framework.])
618 dnl Check for API introduced in MacOS X 10.3.
619 AC_CACHE_CHECK([for CFLocaleCopyCurrent], gt_cv_func_CFLocaleCopyCurrent,
620 [gt_save_LIBS="$LIBS"
621 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
622 AC_TRY_LINK([#include <CoreFoundation/CFLocale.h>], [CFLocaleCopyCurrent();],
623 [gt_cv_func_CFLocaleCopyCurrent=yes],
624 [gt_cv_func_CFLocaleCopyCurrent=no])
625 LIBS="$gt_save_LIBS"])
626 if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
627 AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], 1,
628 [Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the CoreFoundation framework.])
631 if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
632 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
634 AC_SUBST([INTL_MACOSX_LIBS])
637 # lib-ld.m4 serial 3 (gettext-0.13)
638 dnl Copyright (C) 1996-2003 Free Software Foundation, Inc.
639 dnl This file is free software; the Free Software Foundation
640 dnl gives unlimited permission to copy and/or distribute it,
641 dnl with or without modifications, as long as this notice is preserved.
643 dnl Subroutines of libtool.m4,
644 dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision
647 dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.
648 AC_DEFUN([AC_LIB_PROG_LD_GNU],
649 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld,
650 [# I'd rather use --version here, but apparently some GNU ld's only accept -v.
651 case `$LD -v 2>&1 </dev/null` in
652 *GNU* | *'with BFD'*)
653 acl_cv_prog_gnu_ld=yes ;;
655 acl_cv_prog_gnu_ld=no ;;
657 with_gnu_ld=$acl_cv_prog_gnu_ld
660 dnl From libtool-1.4. Sets the variable LD.
661 AC_DEFUN([AC_LIB_PROG_LD],
663 [ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
664 test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
665 AC_REQUIRE([AC_PROG_CC])dnl
666 AC_REQUIRE([AC_CANONICAL_HOST])dnl
667 # Prepare PATH_SEPARATOR.
668 # The user is always right.
669 if test "${PATH_SEPARATOR+set}" != set; then
670 echo "#! /bin/sh" >conf$$.sh
671 echo "exit 0" >>conf$$.sh
673 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
681 if test "$GCC" = yes; then
682 # Check if gcc -print-prog-name=ld gives a path.
683 AC_MSG_CHECKING([for ld used by GCC])
686 # gcc leaves a trailing carriage return which upsets mingw
687 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
689 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
692 # Accept absolute paths.
693 [[\\/]* | [A-Za-z]:[\\/]*)]
694 [re_direlt='/[^/][^/]*/\.\./']
695 # Canonicalize the path of ld
696 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
697 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
698 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
700 test -z "$LD" && LD="$ac_prog"
703 # If it fails, then pretend we aren't using GCC.
707 # If it is relative, then search for the first ld in PATH.
711 elif test "$with_gnu_ld" = yes; then
712 AC_MSG_CHECKING([for GNU ld])
714 AC_MSG_CHECKING([for non-GNU ld])
716 AC_CACHE_VAL(acl_cv_path_LD,
717 [if test -z "$LD"; then
718 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
719 for ac_dir in $PATH; do
720 test -z "$ac_dir" && ac_dir=.
721 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
722 acl_cv_path_LD="$ac_dir/$ac_prog"
723 # Check to see if the program is GNU ld. I'd rather use --version,
724 # but apparently some GNU ld's only accept -v.
725 # Break only if it was the GNU/non-GNU ld that we prefer.
726 case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in
727 *GNU* | *'with BFD'*)
728 test "$with_gnu_ld" != no && break ;;
730 test "$with_gnu_ld" != yes && break ;;
736 acl_cv_path_LD="$LD" # Let the user override the test with a path.
739 if test -n "$LD"; then
744 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
748 # lib-link.m4 serial 13 (gettext-0.17)
749 dnl Copyright (C) 2001-2007 Free Software Foundation, Inc.
750 dnl This file is free software; the Free Software Foundation
751 dnl gives unlimited permission to copy and/or distribute it,
752 dnl with or without modifications, as long as this notice is preserved.
754 dnl From Bruno Haible.
758 dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
759 dnl the libraries corresponding to explicit and implicit dependencies.
760 dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
761 dnl augments the CPPFLAGS variable.
762 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
763 dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
764 AC_DEFUN([AC_LIB_LINKFLAGS],
766 AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
767 AC_REQUIRE([AC_LIB_RPATH])
768 define([Name],[translit([$1],[./-], [___])])
769 define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
770 [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
771 AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
772 AC_LIB_LINKFLAGS_BODY([$1], [$2])
773 ac_cv_lib[]Name[]_libs="$LIB[]NAME"
774 ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
775 ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
776 ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX"
778 LIB[]NAME="$ac_cv_lib[]Name[]_libs"
779 LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
780 INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
781 LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix"
782 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
784 AC_SUBST([LTLIB]NAME)
785 AC_SUBST([LIB]NAME[_PREFIX])
786 dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
787 dnl results of this search when this library appears as a dependency.
793 dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode)
794 dnl searches for libname and the libraries corresponding to explicit and
795 dnl implicit dependencies, together with the specified include files and
796 dnl the ability to compile and link the specified testcode. If found, it
797 dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and
798 dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and
799 dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
800 dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
801 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
802 dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
803 AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
805 AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
806 AC_REQUIRE([AC_LIB_RPATH])
807 define([Name],[translit([$1],[./-], [___])])
808 define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
809 [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
811 dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
813 AC_LIB_LINKFLAGS_BODY([$1], [$2])
815 dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
816 dnl because if the user has installed lib[]Name and not disabled its use
817 dnl via --without-lib[]Name-prefix, he wants to use it.
818 ac_save_CPPFLAGS="$CPPFLAGS"
819 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
821 AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
823 LIBS="$LIBS $LIB[]NAME"
824 AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no])
827 if test "$ac_cv_lib[]Name" = yes; then
829 AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.])
830 AC_MSG_CHECKING([how to link with lib[]$1])
831 AC_MSG_RESULT([$LIB[]NAME])
834 dnl If $LIB[]NAME didn't lead to a usable library, we don't need
835 dnl $INC[]NAME either.
836 CPPFLAGS="$ac_save_CPPFLAGS"
841 AC_SUBST([HAVE_LIB]NAME)
843 AC_SUBST([LTLIB]NAME)
844 AC_SUBST([LIB]NAME[_PREFIX])
849 dnl Determine the platform dependent parameters needed to use rpath:
852 dnl acl_hardcode_libdir_flag_spec,
853 dnl acl_hardcode_libdir_separator,
854 dnl acl_hardcode_direct,
855 dnl acl_hardcode_minus_L.
856 AC_DEFUN([AC_LIB_RPATH],
858 dnl Tell automake >= 1.10 to complain if config.rpath is missing.
859 m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])])
860 AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS
861 AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld
862 AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host
863 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
864 AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [
865 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
866 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
872 acl_libext="$acl_cv_libext"
873 acl_shlibext="$acl_cv_shlibext"
874 acl_libname_spec="$acl_cv_libname_spec"
875 acl_library_names_spec="$acl_cv_library_names_spec"
876 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
877 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
878 acl_hardcode_direct="$acl_cv_hardcode_direct"
879 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
880 dnl Determine whether the user wants rpath handling at all.
882 [ --disable-rpath do not hardcode runtime library paths],
886 dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
887 dnl the libraries corresponding to explicit and implicit dependencies.
888 dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
889 dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found
890 dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
891 AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
893 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
894 define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
895 [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
896 dnl Autoconf >= 2.61 supports dots in --with options.
897 define([N_A_M_E],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit([$1],[.],[_])],[$1])])
898 dnl By default, look in $includedir and $libdir.
900 AC_LIB_WITH_FINAL_PREFIX([
901 eval additional_includedir=\"$includedir\"
902 eval additional_libdir=\"$libdir\"
904 AC_LIB_ARG_WITH([lib]N_A_M_E[-prefix],
905 [ --with-lib]N_A_M_E[-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib
906 --without-lib]N_A_M_E[-prefix don't search for lib$1 in includedir and libdir],
908 if test "X$withval" = "Xno"; then
911 if test "X$withval" = "X"; then
912 AC_LIB_WITH_FINAL_PREFIX([
913 eval additional_includedir=\"$includedir\"
914 eval additional_libdir=\"$libdir\"
917 additional_includedir="$withval/include"
918 additional_libdir="$withval/$acl_libdirstem"
922 dnl Search the library and its dependencies in $additional_libdir and
923 dnl $LDFLAGS. Using breadth-first-seach.
930 names_already_handled=
931 names_next_round='$1 $2'
932 while test -n "$names_next_round"; do
933 names_this_round="$names_next_round"
935 for name in $names_this_round; do
937 for n in $names_already_handled; do
938 if test "$n" = "$name"; then
943 if test -z "$already_handled"; then
944 names_already_handled="$names_already_handled $name"
945 dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
946 dnl or AC_LIB_HAVE_LINKFLAGS call.
947 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
948 eval value=\"\$HAVE_LIB$uppername\"
949 if test -n "$value"; then
950 if test "$value" = yes; then
951 eval value=\"\$LIB$uppername\"
952 test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
953 eval value=\"\$LTLIB$uppername\"
954 test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
956 dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
957 dnl that this library doesn't exist. So just drop it.
961 dnl Search the library lib$name in $additional_libdir and $LDFLAGS
962 dnl and the already constructed $LIBNAME/$LTLIBNAME.
967 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
968 if test -n "$acl_shlibext"; then
969 shrext=".$acl_shlibext" # typically: shrext=.so
973 if test $use_additional = yes; then
974 dir="$additional_libdir"
975 dnl The same code as in the loop below:
976 dnl First look for a shared library.
977 if test -n "$acl_shlibext"; then
978 if test -f "$dir/$libname$shrext"; then
980 found_so="$dir/$libname$shrext"
982 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
984 for f in "$libname$shrext".*; do echo "$f"; done \
985 | sed -e "s,^$libname$shrext\\\\.,," \
986 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
987 | sed 1q ) 2>/dev/null`
988 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
990 found_so="$dir/$libname$shrext.$ver"
993 eval library_names=\"$acl_library_names_spec\"
994 for f in $library_names; do
995 if test -f "$dir/$f"; then
1004 dnl Then look for a static library.
1005 if test "X$found_dir" = "X"; then
1006 if test -f "$dir/$libname.$acl_libext"; then
1008 found_a="$dir/$libname.$acl_libext"
1011 if test "X$found_dir" != "X"; then
1012 if test -f "$dir/$libname.la"; then
1013 found_la="$dir/$libname.la"
1017 if test "X$found_dir" = "X"; then
1018 for x in $LDFLAGS $LTLIB[]NAME; do
1019 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1022 dir=`echo "X$x" | sed -e 's/^X-L//'`
1023 dnl First look for a shared library.
1024 if test -n "$acl_shlibext"; then
1025 if test -f "$dir/$libname$shrext"; then
1027 found_so="$dir/$libname$shrext"
1029 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
1030 ver=`(cd "$dir" && \
1031 for f in "$libname$shrext".*; do echo "$f"; done \
1032 | sed -e "s,^$libname$shrext\\\\.,," \
1033 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
1034 | sed 1q ) 2>/dev/null`
1035 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
1037 found_so="$dir/$libname$shrext.$ver"
1040 eval library_names=\"$acl_library_names_spec\"
1041 for f in $library_names; do
1042 if test -f "$dir/$f"; then
1051 dnl Then look for a static library.
1052 if test "X$found_dir" = "X"; then
1053 if test -f "$dir/$libname.$acl_libext"; then
1055 found_a="$dir/$libname.$acl_libext"
1058 if test "X$found_dir" != "X"; then
1059 if test -f "$dir/$libname.la"; then
1060 found_la="$dir/$libname.la"
1065 if test "X$found_dir" != "X"; then
1070 if test "X$found_dir" != "X"; then
1071 dnl Found the library.
1072 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name"
1073 if test "X$found_so" != "X"; then
1074 dnl Linking with a shared library. We attempt to hardcode its
1075 dnl directory into the executable's runpath, unless it's the
1076 dnl standard /usr/lib.
1077 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then
1078 dnl No hardcoding is needed.
1079 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
1081 dnl Use an explicit option to hardcode DIR into the resulting
1083 dnl Potentially add DIR to ltrpathdirs.
1084 dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
1086 for x in $ltrpathdirs; do
1087 if test "X$x" = "X$found_dir"; then
1092 if test -z "$haveit"; then
1093 ltrpathdirs="$ltrpathdirs $found_dir"
1095 dnl The hardcoding into $LIBNAME is system dependent.
1096 if test "$acl_hardcode_direct" = yes; then
1097 dnl Using DIR/libNAME.so during linking hardcodes DIR into the
1098 dnl resulting binary.
1099 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
1101 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
1102 dnl Use an explicit option to hardcode DIR into the resulting
1104 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
1105 dnl Potentially add DIR to rpathdirs.
1106 dnl The rpathdirs will be appended to $LIBNAME at the end.
1108 for x in $rpathdirs; do
1109 if test "X$x" = "X$found_dir"; then
1114 if test -z "$haveit"; then
1115 rpathdirs="$rpathdirs $found_dir"
1118 dnl Rely on "-L$found_dir".
1119 dnl But don't add it if it's already contained in the LDFLAGS
1120 dnl or the already constructed $LIBNAME
1122 for x in $LDFLAGS $LIB[]NAME; do
1123 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1124 if test "X$x" = "X-L$found_dir"; then
1129 if test -z "$haveit"; then
1130 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir"
1132 if test "$acl_hardcode_minus_L" != no; then
1133 dnl FIXME: Not sure whether we should use
1134 dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
1136 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
1138 dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH
1139 dnl here, because this doesn't fit in flags passed to the
1140 dnl compiler. So give up. No hardcoding. This affects only
1141 dnl very old systems.
1142 dnl FIXME: Not sure whether we should use
1143 dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
1145 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
1151 if test "X$found_a" != "X"; then
1152 dnl Linking with a static library.
1153 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a"
1155 dnl We shouldn't come here, but anyway it's good to have a
1157 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name"
1160 dnl Assume the include files are nearby.
1161 additional_includedir=
1162 case "$found_dir" in
1163 */$acl_libdirstem | */$acl_libdirstem/)
1164 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
1165 LIB[]NAME[]_PREFIX="$basedir"
1166 additional_includedir="$basedir/include"
1169 if test "X$additional_includedir" != "X"; then
1170 dnl Potentially add $additional_includedir to $INCNAME.
1171 dnl But don't add it
1172 dnl 1. if it's the standard /usr/include,
1173 dnl 2. if it's /usr/local/include and we are using GCC on Linux,
1174 dnl 3. if it's already present in $CPPFLAGS or the already
1175 dnl constructed $INCNAME,
1176 dnl 4. if it doesn't exist as a directory.
1177 if test "X$additional_includedir" != "X/usr/include"; then
1179 if test "X$additional_includedir" = "X/usr/local/include"; then
1180 if test -n "$GCC"; then
1182 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
1186 if test -z "$haveit"; then
1187 for x in $CPPFLAGS $INC[]NAME; do
1188 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1189 if test "X$x" = "X-I$additional_includedir"; then
1194 if test -z "$haveit"; then
1195 if test -d "$additional_includedir"; then
1196 dnl Really add $additional_includedir to $INCNAME.
1197 INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir"
1203 dnl Look for dependencies.
1204 if test -n "$found_la"; then
1205 dnl Read the .la file. It defines the variables
1206 dnl dlname, library_names, old_library, dependency_libs, current,
1207 dnl age, revision, installed, dlopen, dlpreopen, libdir.
1208 save_libdir="$libdir"
1210 */* | *\\*) . "$found_la" ;;
1211 *) . "./$found_la" ;;
1213 libdir="$save_libdir"
1214 dnl We use only dependency_libs.
1215 for dep in $dependency_libs; do
1218 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
1219 dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME.
1220 dnl But don't add it
1221 dnl 1. if it's the standard /usr/lib,
1222 dnl 2. if it's /usr/local/lib and we are using GCC on Linux,
1223 dnl 3. if it's already present in $LDFLAGS or the already
1224 dnl constructed $LIBNAME,
1225 dnl 4. if it doesn't exist as a directory.
1226 if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
1228 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
1229 if test -n "$GCC"; then
1231 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
1235 if test -z "$haveit"; then
1237 for x in $LDFLAGS $LIB[]NAME; do
1238 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1239 if test "X$x" = "X-L$additional_libdir"; then
1244 if test -z "$haveit"; then
1245 if test -d "$additional_libdir"; then
1246 dnl Really add $additional_libdir to $LIBNAME.
1247 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir"
1251 for x in $LDFLAGS $LTLIB[]NAME; do
1252 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1253 if test "X$x" = "X-L$additional_libdir"; then
1258 if test -z "$haveit"; then
1259 if test -d "$additional_libdir"; then
1260 dnl Really add $additional_libdir to $LTLIBNAME.
1261 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir"
1268 dir=`echo "X$dep" | sed -e 's/^X-R//'`
1269 if test "$enable_rpath" != no; then
1270 dnl Potentially add DIR to rpathdirs.
1271 dnl The rpathdirs will be appended to $LIBNAME at the end.
1273 for x in $rpathdirs; do
1274 if test "X$x" = "X$dir"; then
1279 if test -z "$haveit"; then
1280 rpathdirs="$rpathdirs $dir"
1282 dnl Potentially add DIR to ltrpathdirs.
1283 dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
1285 for x in $ltrpathdirs; do
1286 if test "X$x" = "X$dir"; then
1291 if test -z "$haveit"; then
1292 ltrpathdirs="$ltrpathdirs $dir"
1297 dnl Handle this in the next round.
1298 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
1301 dnl Handle this in the next round. Throw away the .la's
1302 dnl directory; it is already contained in a preceding -L
1304 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
1307 dnl Most likely an immediate library name.
1308 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep"
1309 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep"
1315 dnl Didn't find the library; assume it is in the system directories
1316 dnl known to the linker and runtime loader. (All the system
1317 dnl directories known to the linker should also be known to the
1318 dnl runtime loader, otherwise the system is severely misconfigured.)
1319 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
1320 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name"
1326 if test "X$rpathdirs" != "X"; then
1327 if test -n "$acl_hardcode_libdir_separator"; then
1328 dnl Weird platform: only the last -rpath option counts, the user must
1329 dnl pass all path elements in one option. We can arrange that for a
1330 dnl single library, but not when more than one $LIBNAMEs are used.
1332 for found_dir in $rpathdirs; do
1333 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
1335 dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl.
1336 acl_save_libdir="$libdir"
1338 eval flag=\"$acl_hardcode_libdir_flag_spec\"
1339 libdir="$acl_save_libdir"
1340 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
1342 dnl The -rpath options are cumulative.
1343 for found_dir in $rpathdirs; do
1344 acl_save_libdir="$libdir"
1346 eval flag=\"$acl_hardcode_libdir_flag_spec\"
1347 libdir="$acl_save_libdir"
1348 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
1352 if test "X$ltrpathdirs" != "X"; then
1353 dnl When using libtool, the option that works for both libraries and
1354 dnl executables is -R. The -R options are cumulative.
1355 for found_dir in $ltrpathdirs; do
1356 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
1361 dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
1362 dnl unless already present in VAR.
1363 dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes
1364 dnl contains two or three consecutive elements that belong together.
1365 AC_DEFUN([AC_LIB_APPENDTOVAR],
1367 for element in [$2]; do
1370 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1371 if test "X$x" = "X$element"; then
1376 if test -z "$haveit"; then
1377 [$1]="${[$1]}${[$1]:+ }$element"
1382 dnl For those cases where a variable contains several -L and -l options
1383 dnl referring to unknown libraries and directories, this macro determines the
1384 dnl necessary additional linker options for the runtime path.
1385 dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL])
1386 dnl sets LDADDVAR to linker options needed together with LIBSVALUE.
1387 dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed,
1388 dnl otherwise linking without libtool is assumed.
1389 AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],
1391 AC_REQUIRE([AC_LIB_RPATH])
1392 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
1394 if test "$enable_rpath" != no; then
1395 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
1396 dnl Use an explicit option to hardcode directories into the resulting
1401 if test -n "$next"; then
1403 dnl No need to hardcode the standard /usr/lib.
1404 if test "X$dir" != "X/usr/$acl_libdirstem"; then
1405 rpathdirs="$rpathdirs $dir"
1411 -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'`
1412 dnl No need to hardcode the standard /usr/lib.
1413 if test "X$dir" != "X/usr/$acl_libdirstem"; then
1414 rpathdirs="$rpathdirs $dir"
1421 if test "X$rpathdirs" != "X"; then
1422 if test -n ""$3""; then
1423 dnl libtool is used for linking. Use -R options.
1424 for dir in $rpathdirs; do
1425 $1="${$1}${$1:+ }-R$dir"
1428 dnl The linker is used for linking directly.
1429 if test -n "$acl_hardcode_libdir_separator"; then
1430 dnl Weird platform: only the last -rpath option counts, the user
1431 dnl must pass all path elements in one option.
1433 for dir in $rpathdirs; do
1434 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir"
1436 acl_save_libdir="$libdir"
1438 eval flag=\"$acl_hardcode_libdir_flag_spec\"
1439 libdir="$acl_save_libdir"
1442 dnl The -rpath options are cumulative.
1443 for dir in $rpathdirs; do
1444 acl_save_libdir="$libdir"
1446 eval flag=\"$acl_hardcode_libdir_flag_spec\"
1447 libdir="$acl_save_libdir"
1448 $1="${$1}${$1:+ }$flag"
1458 # lib-prefix.m4 serial 5 (gettext-0.15)
1459 dnl Copyright (C) 2001-2005 Free Software Foundation, Inc.
1460 dnl This file is free software; the Free Software Foundation
1461 dnl gives unlimited permission to copy and/or distribute it,
1462 dnl with or without modifications, as long as this notice is preserved.
1464 dnl From Bruno Haible.
1466 dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and
1467 dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't
1468 dnl require excessive bracketing.
1469 ifdef([AC_HELP_STRING],
1470 [AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])],
1471 [AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])])
1473 dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed
1474 dnl to access previously installed libraries. The basic assumption is that
1475 dnl a user will want packages to use other packages he previously installed
1476 dnl with the same --prefix option.
1477 dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate
1478 dnl libraries, but is otherwise very convenient.
1479 AC_DEFUN([AC_LIB_PREFIX],
1481 AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
1482 AC_REQUIRE([AC_PROG_CC])
1483 AC_REQUIRE([AC_CANONICAL_HOST])
1484 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
1485 AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
1486 dnl By default, look in $includedir and $libdir.
1488 AC_LIB_WITH_FINAL_PREFIX([
1489 eval additional_includedir=\"$includedir\"
1490 eval additional_libdir=\"$libdir\"
1492 AC_LIB_ARG_WITH([lib-prefix],
1493 [ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib
1494 --without-lib-prefix don't search for libraries in includedir and libdir],
1496 if test "X$withval" = "Xno"; then
1499 if test "X$withval" = "X"; then
1500 AC_LIB_WITH_FINAL_PREFIX([
1501 eval additional_includedir=\"$includedir\"
1502 eval additional_libdir=\"$libdir\"
1505 additional_includedir="$withval/include"
1506 additional_libdir="$withval/$acl_libdirstem"
1510 if test $use_additional = yes; then
1511 dnl Potentially add $additional_includedir to $CPPFLAGS.
1512 dnl But don't add it
1513 dnl 1. if it's the standard /usr/include,
1514 dnl 2. if it's already present in $CPPFLAGS,
1515 dnl 3. if it's /usr/local/include and we are using GCC on Linux,
1516 dnl 4. if it doesn't exist as a directory.
1517 if test "X$additional_includedir" != "X/usr/include"; then
1519 for x in $CPPFLAGS; do
1520 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1521 if test "X$x" = "X-I$additional_includedir"; then
1526 if test -z "$haveit"; then
1527 if test "X$additional_includedir" = "X/usr/local/include"; then
1528 if test -n "$GCC"; then
1530 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
1534 if test -z "$haveit"; then
1535 if test -d "$additional_includedir"; then
1536 dnl Really add $additional_includedir to $CPPFLAGS.
1537 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir"
1542 dnl Potentially add $additional_libdir to $LDFLAGS.
1543 dnl But don't add it
1544 dnl 1. if it's the standard /usr/lib,
1545 dnl 2. if it's already present in $LDFLAGS,
1546 dnl 3. if it's /usr/local/lib and we are using GCC on Linux,
1547 dnl 4. if it doesn't exist as a directory.
1548 if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
1550 for x in $LDFLAGS; do
1551 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
1552 if test "X$x" = "X-L$additional_libdir"; then
1557 if test -z "$haveit"; then
1558 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
1559 if test -n "$GCC"; then
1561 linux*) haveit=yes;;
1565 if test -z "$haveit"; then
1566 if test -d "$additional_libdir"; then
1567 dnl Really add $additional_libdir to $LDFLAGS.
1568 LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
1576 dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix,
1577 dnl acl_final_exec_prefix, containing the values to which $prefix and
1578 dnl $exec_prefix will expand at the end of the configure script.
1579 AC_DEFUN([AC_LIB_PREPARE_PREFIX],
1581 dnl Unfortunately, prefix and exec_prefix get only finally determined
1582 dnl at the end of configure.
1583 if test "X$prefix" = "XNONE"; then
1584 acl_final_prefix="$ac_default_prefix"
1586 acl_final_prefix="$prefix"
1588 if test "X$exec_prefix" = "XNONE"; then
1589 acl_final_exec_prefix='${prefix}'
1591 acl_final_exec_prefix="$exec_prefix"
1593 acl_save_prefix="$prefix"
1594 prefix="$acl_final_prefix"
1595 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
1596 prefix="$acl_save_prefix"
1599 dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the
1600 dnl variables prefix and exec_prefix bound to the values they will have
1601 dnl at the end of the configure script.
1602 AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
1604 acl_save_prefix="$prefix"
1605 prefix="$acl_final_prefix"
1606 acl_save_exec_prefix="$exec_prefix"
1607 exec_prefix="$acl_final_exec_prefix"
1609 exec_prefix="$acl_save_exec_prefix"
1610 prefix="$acl_save_prefix"
1613 dnl AC_LIB_PREPARE_MULTILIB creates a variable acl_libdirstem, containing
1614 dnl the basename of the libdir, either "lib" or "lib64".
1615 AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
1617 dnl There is no formal standard regarding lib and lib64. The current
1618 dnl practice is that on a system supporting 32-bit and 64-bit instruction
1619 dnl sets or ABIs, 64-bit libraries go under $prefix/lib64 and 32-bit
1620 dnl libraries go under $prefix/lib. We determine the compiler's default
1621 dnl mode by looking at the compiler's library search path. If at least
1622 dnl of its elements ends in /lib64 or points to a directory whose absolute
1623 dnl pathname ends in /lib64, we assume a 64-bit ABI. Otherwise we use the
1624 dnl default, namely "lib".
1626 searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
1627 if test -n "$searchpath"; then
1628 acl_save_IFS="${IFS= }"; IFS=":"
1629 for searchdir in $searchpath; do
1630 if test -d "$searchdir"; then
1631 case "$searchdir" in
1632 */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
1633 *) searchdir=`cd "$searchdir" && pwd`
1634 case "$searchdir" in
1635 */lib64 ) acl_libdirstem=lib64 ;;
1644 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
1646 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1647 # 2006, 2007, 2008 Free Software Foundation, Inc.
1648 # Written by Gordon Matzigkeit, 1996
1650 # This file is free software; the Free Software Foundation gives
1651 # unlimited permission to copy and/or distribute it, with or without
1652 # modifications, as long as this notice is preserved.
1654 m4_define([_LT_COPYING], [dnl
1655 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1656 # 2006, 2007, 2008 Free Software Foundation, Inc.
1657 # Written by Gordon Matzigkeit, 1996
1659 # This file is part of GNU Libtool.
1661 # GNU Libtool is free software; you can redistribute it and/or
1662 # modify it under the terms of the GNU General Public License as
1663 # published by the Free Software Foundation; either version 2 of
1664 # the License, or (at your option) any later version.
1666 # As a special exception to the GNU General Public License,
1667 # if you distribute this file as part of a program or library that
1668 # is built using GNU Libtool, you may include this file under the
1669 # same distribution terms that you use for the rest of that program.
1671 # GNU Libtool is distributed in the hope that it will be useful,
1672 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1673 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1674 # GNU General Public License for more details.
1676 # You should have received a copy of the GNU General Public License
1677 # along with GNU Libtool; see the file COPYING. If not, a copy
1678 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
1679 # obtained by writing to the Free Software Foundation, Inc.,
1680 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1686 # LT_PREREQ(VERSION)
1687 # ------------------
1688 # Complain and exit if this libtool version is less that VERSION.
1689 m4_defun([LT_PREREQ],
1690 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
1692 [m4_fatal([Libtool version $1 or higher is required],
1697 # _LT_CHECK_BUILDDIR
1698 # ------------------
1699 # Complain if the absolute build directory name contains unusual characters
1700 m4_defun([_LT_CHECK_BUILDDIR],
1703 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
1708 # LT_INIT([OPTIONS])
1709 # ------------------
1711 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
1712 AC_BEFORE([$0], [LT_LANG])dnl
1713 AC_BEFORE([$0], [LT_OUTPUT])dnl
1714 AC_BEFORE([$0], [LTDL_INIT])dnl
1715 m4_require([_LT_CHECK_BUILDDIR])dnl
1717 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
1718 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
1719 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
1720 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
1721 dnl unless we require an AC_DEFUNed macro:
1722 AC_REQUIRE([LTOPTIONS_VERSION])dnl
1723 AC_REQUIRE([LTSUGAR_VERSION])dnl
1724 AC_REQUIRE([LTVERSION_VERSION])dnl
1725 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
1726 m4_require([_LT_PROG_LTMAIN])dnl
1729 _LT_SET_OPTIONS([$0], [$1])
1731 # This can be used to rebuild libtool when needed
1732 LIBTOOL_DEPS="$ltmain"
1734 # Always use our own libtool.
1735 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1736 AC_SUBST(LIBTOOL)dnl
1741 m4_define([LT_INIT])
1745 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
1746 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
1747 dnl aclocal-1.4 backwards compatibility:
1748 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
1749 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
1752 # _LT_CC_BASENAME(CC)
1753 # -------------------
1754 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
1755 m4_defun([_LT_CC_BASENAME],
1756 [for cc_temp in $1""; do
1758 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1759 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1764 cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
1768 # _LT_FILEUTILS_DEFAULTS
1769 # ----------------------
1770 # It is okay to use these file commands and assume they have been set
1771 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
1772 m4_defun([_LT_FILEUTILS_DEFAULTS],
1776 ])# _LT_FILEUTILS_DEFAULTS
1781 m4_defun([_LT_SETUP],
1782 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1783 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1784 _LT_DECL([], [host_alias], [0], [The host system])dnl
1785 _LT_DECL([], [host], [0])dnl
1786 _LT_DECL([], [host_os], [0])dnl
1788 _LT_DECL([], [build_alias], [0], [The build system])dnl
1789 _LT_DECL([], [build], [0])dnl
1790 _LT_DECL([], [build_os], [0])dnl
1792 AC_REQUIRE([AC_PROG_CC])dnl
1793 AC_REQUIRE([LT_PATH_LD])dnl
1794 AC_REQUIRE([LT_PATH_NM])dnl
1796 AC_REQUIRE([AC_PROG_LN_S])dnl
1797 test -z "$LN_S" && LN_S="ln -s"
1798 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
1800 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
1801 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
1802 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
1804 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1805 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
1806 m4_require([_LT_CMD_RELOAD])dnl
1807 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
1808 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
1809 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
1811 _LT_CONFIG_LIBTOOL_INIT([
1812 # See if we are running on zsh, and set the options which allow our
1813 # commands through without removal of \ escapes INIT.
1814 if test -n "\${ZSH_VERSION+set}" ; then
1815 setopt NO_GLOB_SUBST
1818 if test -n "${ZSH_VERSION+set}" ; then
1819 setopt NO_GLOB_SUBST
1824 m4_require([_LT_TAG_COMPILER])dnl
1825 _LT_PROG_ECHO_BACKSLASH
1829 # AIX sometimes has problems with the GCC collect2 program. For some
1830 # reason, if we set the COLLECT_NAMES environment variable, the problems
1831 # vanish in a puff of smoke.
1832 if test "X${COLLECT_NAMES+set}" != Xset; then
1834 export COLLECT_NAMES
1839 # Sed substitution that helps us do robust quoting. It backslashifies
1840 # metacharacters that are still active within double-quoted strings.
1841 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
1843 # Same as above, but do not quote variable references.
1844 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
1846 # Sed substitution to delay expansion of an escaped shell variable in a
1847 # double_quote_subst'ed string.
1848 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1850 # Sed substitution to delay expansion of an escaped single quote.
1851 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
1853 # Sed substitution to avoid accidental globbing in evaled expressions
1854 no_glob_subst='s/\*/\\\*/g'
1858 can_build_shared=yes
1860 # All known linkers require a `.a' archive for static linking (except MSVC,
1861 # which needs '.lib').
1864 with_gnu_ld="$lt_cv_prog_gnu_ld"
1867 old_CFLAGS="$CFLAGS"
1869 # Set sane defaults for various variables
1870 test -z "$CC" && CC=cc
1871 test -z "$LTCC" && LTCC=$CC
1872 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1873 test -z "$LD" && LD=ld
1874 test -z "$ac_objext" && ac_objext=o
1876 _LT_CC_BASENAME([$compiler])
1878 # Only perform the check for file, if the check method requires it
1879 test -z "$MAGIC_CMD" && MAGIC_CMD=file
1880 case $deplibs_check_method in
1882 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1888 # Use C for the default configuration in the libtool script
1889 LT_SUPPORTED_TAG([CC])
1891 _LT_LANG_DEFAULT_CONFIG
1898 # Note that this code is called both from `configure', and `config.status'
1899 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
1900 # `config.status' has no value for ac_aux_dir unless we are using Automake,
1901 # so we pass a copy along to make sure it has a sensible value anyway.
1902 m4_defun([_LT_PROG_LTMAIN],
1903 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
1904 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
1905 ltmain="$ac_aux_dir/ltmain.sh"
1910 # So that we can recreate a full libtool script including additional
1911 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
1912 # in macros and then make a single call at the end using the `libtool'
1916 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
1917 # ----------------------------------------
1918 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1919 m4_define([_LT_CONFIG_LIBTOOL_INIT],
1921 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
1926 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
1929 # _LT_CONFIG_LIBTOOL([COMMANDS])
1930 # ------------------------------
1931 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1932 m4_define([_LT_CONFIG_LIBTOOL],
1934 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
1939 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
1942 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
1943 # -----------------------------------------------------
1944 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
1945 [_LT_CONFIG_LIBTOOL([$1])
1946 _LT_CONFIG_LIBTOOL_INIT([$2])
1950 # _LT_FORMAT_COMMENT([COMMENT])
1951 # -----------------------------
1952 # Add leading comment marks to the start of each line, and a trailing
1953 # full-stop to the whole comment if one is not present already.
1954 m4_define([_LT_FORMAT_COMMENT],
1956 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
1957 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
1964 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
1965 # -------------------------------------------------------------------
1966 # CONFIGNAME is the name given to the value in the libtool script.
1967 # VARNAME is the (base) name used in the configure script.
1968 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
1969 # VARNAME. Any other value will be used directly.
1970 m4_define([_LT_DECL],
1971 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
1972 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
1973 [m4_ifval([$1], [$1], [$2])])
1974 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
1976 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
1977 lt_dict_add_subkey([lt_decl_dict], [$2],
1978 [tagged?], [m4_ifval([$5], [yes], [no])])])
1982 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
1983 # --------------------------------------------------------
1984 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
1987 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
1988 # ------------------------------------------------
1989 m4_define([lt_decl_tag_varnames],
1990 [_lt_decl_filter([tagged?], [yes], $@)])
1993 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
1994 # ---------------------------------------------------------
1995 m4_define([_lt_decl_filter],
1997 [0], [m4_fatal([$0: too few arguments: $#])],
1998 [1], [m4_fatal([$0: too few arguments: $#: $1])],
1999 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
2000 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
2001 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
2005 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
2006 # --------------------------------------------------
2007 m4_define([lt_decl_quote_varnames],
2008 [_lt_decl_filter([value], [1], $@)])
2011 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
2012 # ---------------------------------------------------
2013 m4_define([lt_decl_dquote_varnames],
2014 [_lt_decl_filter([value], [2], $@)])
2017 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
2018 # ---------------------------------------------------
2019 m4_define([lt_decl_varnames_tagged],
2020 [m4_assert([$# <= 2])dnl
2021 _$0(m4_quote(m4_default([$1], [[, ]])),
2022 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
2023 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
2024 m4_define([_lt_decl_varnames_tagged],
2025 [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
2028 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
2029 # ------------------------------------------------
2030 m4_define([lt_decl_all_varnames],
2031 [_$0(m4_quote(m4_default([$1], [[, ]])),
2033 m4_quote(lt_decl_varnames),
2034 m4_quote(m4_shift($@))))[]dnl
2036 m4_define([_lt_decl_all_varnames],
2037 [lt_join($@, lt_decl_varnames_tagged([$1],
2038 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
2042 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
2043 # ------------------------------------
2044 # Quote a variable value, and forward it to `config.status' so that its
2045 # declaration there will have the same value as in `configure'. VARNAME
2046 # must have a single quote delimited value for this to work.
2047 m4_define([_LT_CONFIG_STATUS_DECLARE],
2048 [$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
2051 # _LT_CONFIG_STATUS_DECLARATIONS
2052 # ------------------------------
2053 # We delimit libtool config variables with single quotes, so when
2054 # we write them to config.status, we have to be sure to quote all
2055 # embedded single quotes properly. In configure, this macro expands
2056 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
2058 # <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
2059 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
2060 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
2061 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
2066 # Output comment and list of tags supported by the script
2067 m4_defun([_LT_LIBTOOL_TAGS],
2068 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
2069 available_tags="_LT_TAGS"dnl
2073 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
2074 # -----------------------------------
2075 # Extract the dictionary values for VARNAME (optionally with TAG) and
2076 # expand to a commented shell variable setting:
2078 # # Some comment about what VAR is for.
2079 # visible_name=$lt_internal_name
2080 m4_define([_LT_LIBTOOL_DECLARE],
2081 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
2082 [description])))[]dnl
2083 m4_pushdef([_libtool_name],
2084 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
2085 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
2086 [0], [_libtool_name=[$]$1],
2087 [1], [_libtool_name=$lt_[]$1],
2088 [2], [_libtool_name=$lt_[]$1],
2089 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
2090 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
2094 # _LT_LIBTOOL_CONFIG_VARS
2095 # -----------------------
2096 # Produce commented declarations of non-tagged libtool config variables
2097 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
2098 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
2099 # section) are produced by _LT_LIBTOOL_TAG_VARS.
2100 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
2101 [m4_foreach([_lt_var],
2102 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
2103 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
2106 # _LT_LIBTOOL_TAG_VARS(TAG)
2107 # -------------------------
2108 m4_define([_LT_LIBTOOL_TAG_VARS],
2109 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
2110 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
2113 # _LT_TAGVAR(VARNAME, [TAGNAME])
2114 # ------------------------------
2115 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
2118 # _LT_CONFIG_COMMANDS
2119 # -------------------
2120 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
2121 # variables for single and double quote escaping we saved from calls
2122 # to _LT_DECL, we can put quote escaped variables declarations
2123 # into `config.status', and then the shell code to quote escape them in
2124 # for loops in `config.status'. Finally, any additional code accumulated
2125 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
2126 m4_defun([_LT_CONFIG_COMMANDS],
2127 [AC_PROVIDE_IFELSE([LT_OUTPUT],
2128 dnl If the libtool generation code has been placed in $CONFIG_LT,
2129 dnl instead of duplicating it all over again into config.status,
2130 dnl then we will have config.status run $CONFIG_LT later, so it
2131 dnl needs to know what name is stored there:
2132 [AC_CONFIG_COMMANDS([libtool],
2133 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
2134 dnl If the libtool generation code is destined for config.status,
2135 dnl expand the accumulated commands and init code now:
2136 [AC_CONFIG_COMMANDS([libtool],
2137 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
2138 ])#_LT_CONFIG_COMMANDS
2142 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
2145 # The HP-UX ksh and POSIX shell print the target directory to stdout
2147 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
2149 sed_quote_subst='$sed_quote_subst'
2150 double_quote_subst='$double_quote_subst'
2151 delay_variable_subst='$delay_variable_subst'
2152 _LT_CONFIG_STATUS_DECLARATIONS
2154 LTCFLAGS='$LTCFLAGS'
2155 compiler='$compiler_DEFAULT'
2157 # Quote evaled strings.
2158 for var in lt_decl_all_varnames([[ \
2159 ]], lt_decl_quote_varnames); do
2160 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
2161 *[[\\\\\\\`\\"\\\$]]*)
2162 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
2165 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
2170 # Double-quote double-evaled strings.
2171 for var in lt_decl_all_varnames([[ \
2172 ]], lt_decl_dquote_varnames); do
2173 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
2174 *[[\\\\\\\`\\"\\\$]]*)
2175 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
2178 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
2183 # Fix-up fallback echo if it was mangled by the above quoting rules.
2185 *'\\\[$]0 --fallback-echo"')dnl "
2186 lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
2190 _LT_OUTPUT_LIBTOOL_INIT
2196 # This macro allows early generation of the libtool script (before
2197 # AC_OUTPUT is called), incase it is used in configure for compilation
2199 AC_DEFUN([LT_OUTPUT],
2200 [: ${CONFIG_LT=./config.lt}
2201 AC_MSG_NOTICE([creating $CONFIG_LT])
2202 cat >"$CONFIG_LT" <<_LTEOF
2204 # Generated by $as_me.
2205 # Run this file to recreate a libtool stub with the current configuration.
2208 SHELL=\${CONFIG_SHELL-$SHELL}
2211 cat >>"$CONFIG_LT" <<\_LTEOF
2215 exec AS_MESSAGE_FD>&1
2216 exec AS_MESSAGE_LOG_FD>>config.log
2219 AS_BOX([Running $as_me.])
2220 } >&AS_MESSAGE_LOG_FD
2223 \`$as_me' creates a local libtool stub from the current configuration,
2224 for use in further configure time tests before the real libtool is
2227 Usage: $[0] [[OPTIONS]]
2229 -h, --help print this help, then exit
2230 -V, --version print version number, then exit
2231 -q, --quiet do not print progress messages
2232 -d, --debug don't remove temporary files
2234 Report bugs to <bug-libtool@gnu.org>."
2237 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
2238 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
2239 configured by $[0], generated by m4_PACKAGE_STRING.
2241 Copyright (C) 2008 Free Software Foundation, Inc.
2242 This config.lt script is free software; the Free Software Foundation
2243 gives unlimited permision to copy, distribute and modify it."
2245 while test $[#] != 0
2248 --version | --v* | -V )
2249 echo "$lt_cl_version"; exit 0 ;;
2250 --help | --h* | -h )
2251 echo "$lt_cl_help"; exit 0 ;;
2252 --debug | --d* | -d )
2254 --quiet | --q* | --silent | --s* | -q )
2257 -*) AC_MSG_ERROR([unrecognized option: $[1]
2258 Try \`$[0] --help' for more information.]) ;;
2260 *) AC_MSG_ERROR([unrecognized argument: $[1]
2261 Try \`$[0] --help' for more information.]) ;;
2266 if $lt_cl_silent; then
2267 exec AS_MESSAGE_FD>/dev/null
2271 cat >>"$CONFIG_LT" <<_LTEOF
2272 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
2275 cat >>"$CONFIG_LT" <<\_LTEOF
2276 AC_MSG_NOTICE([creating $ofile])
2277 _LT_OUTPUT_LIBTOOL_COMMANDS
2280 chmod +x "$CONFIG_LT"
2282 # configure is writing to config.log, but config.lt does its own redirection,
2283 # appending to config.log, which fails on DOS, as config.log is still kept
2284 # open by configure. Here we exec the FD to /dev/null, effectively closing
2285 # config.log, so it can be properly (re)opened and appended to by config.lt.
2286 if test "$no_create" != yes; then
2288 test "$silent" = yes &&
2289 lt_config_lt_args="$lt_config_lt_args --quiet"
2290 exec AS_MESSAGE_LOG_FD>/dev/null
2291 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
2292 exec AS_MESSAGE_LOG_FD>>config.log
2293 $lt_cl_success || AS_EXIT(1)
2300 # If TAG is the built-in tag, create an initial libtool script with a
2301 # default configuration from the untagged config vars. Otherwise add code
2302 # to config.status for appending the configuration named by TAG from the
2303 # matching tagged config vars.
2304 m4_defun([_LT_CONFIG],
2305 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2306 _LT_CONFIG_SAVE_COMMANDS([
2307 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
2308 m4_if(_LT_TAG, [C], [
2309 # See if we are running on zsh, and set the options which allow our
2310 # commands through without removal of \ escapes.
2311 if test -n "${ZSH_VERSION+set}" ; then
2312 setopt NO_GLOB_SUBST
2316 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
2319 cat <<_LT_EOF >> "$cfgfile"
2322 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
2323 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
2324 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2325 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
2330 # ### BEGIN LIBTOOL CONFIG
2331 _LT_LIBTOOL_CONFIG_VARS
2332 _LT_LIBTOOL_TAG_VARS
2333 # ### END LIBTOOL CONFIG
2339 cat <<\_LT_EOF >> "$cfgfile"
2340 # AIX sometimes has problems with the GCC collect2 program. For some
2341 # reason, if we set the COLLECT_NAMES environment variable, the problems
2342 # vanish in a puff of smoke.
2343 if test "X${COLLECT_NAMES+set}" != Xset; then
2345 export COLLECT_NAMES
2353 # We use sed instead of cat because bash on DJGPP gets confused if
2354 # if finds mixed CR/LF and LF-only lines. Since sed operates in
2355 # text mode, it properly converts lines to CR/LF. This bash problem
2356 # is reportedly fixed, but why not run on old versions too?
2357 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
2358 || (rm -f "$cfgfile"; exit 1)
2360 _LT_PROG_XSI_SHELLFNS
2362 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
2363 || (rm -f "$cfgfile"; exit 1)
2365 mv -f "$cfgfile" "$ofile" ||
2366 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
2369 [cat <<_LT_EOF >> "$ofile"
2371 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
2372 dnl in a comment (ie after a #).
2373 # ### BEGIN LIBTOOL TAG CONFIG: $1
2374 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
2375 # ### END LIBTOOL TAG CONFIG: $1
2382 TIMESTAMP='$TIMESTAMP'
2384 ofile='$ofile'], [])
2385 ])dnl /_LT_CONFIG_SAVE_COMMANDS
2389 # LT_SUPPORTED_TAG(TAG)
2390 # ---------------------
2391 # Trace this macro to discover what tags are supported by the libtool
2392 # --tag option, using:
2393 # autoconf --trace 'LT_SUPPORTED_TAG:$1'
2394 AC_DEFUN([LT_SUPPORTED_TAG], [])
2397 # C support is built-in for now
2398 m4_define([_LT_LANG_C_enabled], [])
2399 m4_define([_LT_TAGS], [])
2404 # Enable libtool support for the given language if not already enabled.
2406 [AC_BEFORE([$0], [LT_OUTPUT])dnl
2409 [C++], [_LT_LANG(CXX)],
2410 [Java], [_LT_LANG(GCJ)],
2411 [Fortran 77], [_LT_LANG(F77)],
2412 [Fortran], [_LT_LANG(FC)],
2413 [Windows Resource], [_LT_LANG(RC)],
2414 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
2416 [m4_fatal([$0: unsupported language: "$1"])])])dnl
2420 # _LT_LANG(LANGNAME)
2421 # ------------------
2422 m4_defun([_LT_LANG],
2423 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
2424 [LT_SUPPORTED_TAG([$1])dnl
2425 m4_append([_LT_TAGS], [$1 ])dnl
2426 m4_define([_LT_LANG_]$1[_enabled], [])dnl
2427 _LT_LANG_$1_CONFIG($1)])dnl
2431 # _LT_LANG_DEFAULT_CONFIG
2432 # -----------------------
2433 m4_defun([_LT_LANG_DEFAULT_CONFIG],
2434 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
2436 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
2438 AC_PROVIDE_IFELSE([AC_PROG_F77],
2440 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
2442 AC_PROVIDE_IFELSE([AC_PROG_FC],
2444 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
2446 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
2447 dnl pulling things in needlessly.
2448 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
2450 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
2452 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
2454 [m4_ifdef([AC_PROG_GCJ],
2455 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
2456 m4_ifdef([A][M_PROG_GCJ],
2457 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
2458 m4_ifdef([LT_PROG_GCJ],
2459 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
2461 AC_PROVIDE_IFELSE([LT_PROG_RC],
2463 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
2464 ])# _LT_LANG_DEFAULT_CONFIG
2467 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
2468 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
2469 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
2470 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
2471 dnl aclocal-1.4 backwards compatibility:
2472 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
2473 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
2474 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
2475 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
2480 m4_defun([_LT_TAG_COMPILER],
2481 [AC_REQUIRE([AC_PROG_CC])dnl
2483 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
2484 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
2485 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
2486 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
2488 # If no C compiler was specified, use CC.
2491 # If no C compiler flags were specified, use CFLAGS.
2492 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
2494 # Allow CC to be a program name with arguments.
2496 ])# _LT_TAG_COMPILER
2499 # _LT_COMPILER_BOILERPLATE
2500 # ------------------------
2501 # Check for compiler boilerplate output or warnings with
2502 # the simple compiler test code.
2503 m4_defun([_LT_COMPILER_BOILERPLATE],
2504 [m4_require([_LT_DECL_SED])dnl
2505 ac_outfile=conftest.$ac_objext
2506 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
2507 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
2508 _lt_compiler_boilerplate=`cat conftest.err`
2510 ])# _LT_COMPILER_BOILERPLATE
2513 # _LT_LINKER_BOILERPLATE
2514 # ----------------------
2515 # Check for linker boilerplate output or warnings with
2516 # the simple link test code.
2517 m4_defun([_LT_LINKER_BOILERPLATE],
2518 [m4_require([_LT_DECL_SED])dnl
2519 ac_outfile=conftest.$ac_objext
2520 echo "$lt_simple_link_test_code" >conftest.$ac_ext
2521 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
2522 _lt_linker_boilerplate=`cat conftest.err`
2524 ])# _LT_LINKER_BOILERPLATE
2526 # _LT_REQUIRED_DARWIN_CHECKS
2527 # -------------------------
2528 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
2530 rhapsody* | darwin*)
2531 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
2532 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
2533 AC_CHECK_TOOL([LIPO], [lipo], [:])
2534 AC_CHECK_TOOL([OTOOL], [otool], [:])
2535 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
2536 _LT_DECL([], [DSYMUTIL], [1],
2537 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
2538 _LT_DECL([], [NMEDIT], [1],
2539 [Tool to change global to local symbols on Mac OS X])
2540 _LT_DECL([], [LIPO], [1],
2541 [Tool to manipulate fat objects and archives on Mac OS X])
2542 _LT_DECL([], [OTOOL], [1],
2543 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
2544 _LT_DECL([], [OTOOL64], [1],
2545 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
2547 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
2548 [lt_cv_apple_cc_single_mod=no
2549 if test -z "${LT_MULTI_MODULE}"; then
2550 # By default we will add the -single_module flag. You can override
2551 # by either setting the environment variable LT_MULTI_MODULE
2552 # non-empty at configure time, or by adding -multi_module to the
2554 rm -rf libconftest.dylib*
2555 echo "int foo(void){return 1;}" > conftest.c
2556 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
2557 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
2558 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
2559 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
2561 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
2562 lt_cv_apple_cc_single_mod=yes
2564 cat conftest.err >&AS_MESSAGE_LOG_FD
2566 rm -rf libconftest.dylib*
2569 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
2570 [lt_cv_ld_exported_symbols_list],
2571 [lt_cv_ld_exported_symbols_list=no
2572 save_LDFLAGS=$LDFLAGS
2573 echo "_main" > conftest.sym
2574 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
2575 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2576 [lt_cv_ld_exported_symbols_list=yes],
2577 [lt_cv_ld_exported_symbols_list=no])
2578 LDFLAGS="$save_LDFLAGS"
2581 rhapsody* | darwin1.[[012]])
2582 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
2584 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2585 darwin*) # darwin 5.x on
2586 # if running on 10.5 or later, the deployment target defaults
2587 # to the OS version, if on x86, and 10.4, the deployment
2588 # target defaults to 10.4. Don't you love it?
2589 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
2590 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
2591 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2593 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2595 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2599 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
2600 _lt_dar_single_mod='$single_module'
2602 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
2603 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
2605 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
2607 if test "$DSYMUTIL" != ":"; then
2608 _lt_dsymutil='~$DSYMUTIL $lib || :'
2617 # _LT_DARWIN_LINKER_FEATURES
2618 # --------------------------
2619 # Checks for linker and compiler features on darwin
2620 m4_defun([_LT_DARWIN_LINKER_FEATURES],
2622 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
2623 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
2624 _LT_TAGVAR(hardcode_direct, $1)=no
2625 _LT_TAGVAR(hardcode_automatic, $1)=yes
2626 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2627 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
2628 _LT_TAGVAR(link_all_deplibs, $1)=yes
2629 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
2630 case $cc_basename in
2631 ifort*) _lt_dar_can_shared=yes ;;
2632 *) _lt_dar_can_shared=$GCC ;;
2634 if test "$_lt_dar_can_shared" = "yes"; then
2635 output_verbose_link_cmd=echo
2636 _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
2637 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
2638 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
2639 _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
2641 [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
2642 _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
2643 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
2647 _LT_TAGVAR(ld_shlibs, $1)=no
2651 # _LT_SYS_MODULE_PATH_AIX
2652 # -----------------------
2653 # Links a minimal program and checks the executable
2654 # for the system default hardcoded library path. In most cases,
2655 # this is /usr/lib:/lib, but when the MPI compilers are used
2656 # the location of the communication and MPI libs are included too.
2657 # If we don't find anything, use the default library path according
2658 # to the aix ld manual.
2659 m4_defun([_LT_SYS_MODULE_PATH_AIX],
2660 [m4_require([_LT_DECL_SED])dnl
2661 AC_LINK_IFELSE(AC_LANG_PROGRAM,[
2662 lt_aix_libpath_sed='
2663 /Import File Strings/,/^$/ {
2669 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2670 # Check for a 64-bit object if we didn't find anything.
2671 if test -z "$aix_libpath"; then
2672 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2674 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
2675 ])# _LT_SYS_MODULE_PATH_AIX
2678 # _LT_SHELL_INIT(ARG)
2679 # -------------------
2680 m4_define([_LT_SHELL_INIT],
2681 [ifdef([AC_DIVERSION_NOTICE],
2682 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
2683 [AC_DIVERT_PUSH(NOTICE)])
2689 # _LT_PROG_ECHO_BACKSLASH
2690 # -----------------------
2691 # Add some code to the start of the generated configure script which
2692 # will find an echo command which doesn't interpret backslashes.
2693 m4_defun([_LT_PROG_ECHO_BACKSLASH],
2695 # Check that we are running under the correct shell.
2696 SHELL=${CONFIG_SHELL-/bin/sh}
2700 # Remove one level of quotation (which was required for Make).
2701 ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
2705 ECHO=${lt_ECHO-echo}
2706 if test "X[$]1" = X--no-reexec; then
2707 # Discard the --no-reexec flag, and continue.
2709 elif test "X[$]1" = X--fallback-echo; then
2710 # Avoid inline document here, it may be left over
2712 elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
2713 # Yippee, $ECHO works!
2716 # Restart under the correct shell.
2717 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
2720 if test "X[$]1" = X--fallback-echo; then
2721 # used as fallback echo
2729 # The HP-UX ksh and POSIX shell print the target directory to stdout
2731 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
2733 if test -z "$lt_ECHO"; then
2734 if test "X${echo_test_string+set}" != Xset; then
2735 # find a string as large as possible, as long as the shell can cope with it
2736 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
2737 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
2738 if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
2739 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
2746 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
2747 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
2748 test "X$echo_testing_string" = "X$echo_test_string"; then
2751 # The Solaris, AIX, and Digital Unix default echo programs unquote
2752 # backslashes. This makes it impossible to quote backslashes using
2753 # echo "$something" | sed 's/\\/\\\\/g'
2755 # So, first we look for a working echo in the user's PATH.
2757 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2758 for dir in $PATH /usr/ucb; do
2760 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
2761 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
2762 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
2763 test "X$echo_testing_string" = "X$echo_test_string"; then
2770 if test "X$ECHO" = Xecho; then
2771 # We didn't find a better echo, so look for alternatives.
2772 if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
2773 echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
2774 test "X$echo_testing_string" = "X$echo_test_string"; then
2775 # This shell has a builtin print -r that does the trick.
2777 elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
2778 test "X$CONFIG_SHELL" != X/bin/ksh; then
2779 # If we have ksh, try running configure again with it.
2780 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
2781 export ORIGINAL_CONFIG_SHELL
2782 CONFIG_SHELL=/bin/ksh
2784 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
2788 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
2789 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
2790 test "X$echo_testing_string" = "X$echo_test_string"; then
2791 # Cool, printf works
2793 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
2794 test "X$echo_testing_string" = 'X\t' &&
2795 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
2796 test "X$echo_testing_string" = "X$echo_test_string"; then
2797 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
2799 SHELL="$CONFIG_SHELL"
2801 ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
2802 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
2803 test "X$echo_testing_string" = 'X\t' &&
2804 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
2805 test "X$echo_testing_string" = "X$echo_test_string"; then
2806 ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
2808 # maybe with a smaller string...
2811 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
2812 if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
2819 if test "$prev" != 'sed 50q "[$]0"'; then
2820 echo_test_string=`eval $prev`
2821 export echo_test_string
2822 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
2824 # Oops. We lost completely, so just stick with echo.
2833 # Copy echo and quote the copy suitably for passing to libtool from
2834 # the Makefile, instead of quoting the original, which is used later.
2836 if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
2837 lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
2842 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
2843 _LT_DECL([], [ECHO], [1],
2844 [An echo program that does not interpret backslashes])
2845 ])# _LT_PROG_ECHO_BACKSLASH
2850 m4_defun([_LT_ENABLE_LOCK],
2851 [AC_ARG_ENABLE([libtool-lock],
2852 [AS_HELP_STRING([--disable-libtool-lock],
2853 [avoid locking (might break parallel builds)])])
2854 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
2856 # Some flags need to be propagated to the compiler or linker for good
2860 # Find out which ABI we are using.
2861 echo 'int i;' > conftest.$ac_ext
2862 if AC_TRY_EVAL(ac_compile); then
2863 case `/usr/bin/file conftest.$ac_objext` in
2875 # Find out which ABI we are using.
2876 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
2877 if AC_TRY_EVAL(ac_compile); then
2878 if test "$lt_cv_prog_gnu_ld" = yes; then
2879 case `/usr/bin/file conftest.$ac_objext` in
2881 LD="${LD-ld} -melf32bsmip"
2884 LD="${LD-ld} -melf32bmipn32"
2887 LD="${LD-ld} -melf64bmip"
2891 case `/usr/bin/file conftest.$ac_objext` in
2907 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
2908 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
2909 # Find out which ABI we are using.
2910 echo 'int i;' > conftest.$ac_ext
2911 if AC_TRY_EVAL(ac_compile); then
2912 case `/usr/bin/file conftest.o` in
2915 x86_64-*kfreebsd*-gnu)
2916 LD="${LD-ld} -m elf_i386_fbsd"
2919 LD="${LD-ld} -m elf_i386"
2921 ppc64-*linux*|powerpc64-*linux*)
2922 LD="${LD-ld} -m elf32ppclinux"
2925 LD="${LD-ld} -m elf_s390"
2928 LD="${LD-ld} -m elf32_sparc"
2934 x86_64-*kfreebsd*-gnu)
2935 LD="${LD-ld} -m elf_x86_64_fbsd"
2938 LD="${LD-ld} -m elf_x86_64"
2940 ppc*-*linux*|powerpc*-*linux*)
2941 LD="${LD-ld} -m elf64ppc"
2943 s390*-*linux*|s390*-*tpf*)
2944 LD="${LD-ld} -m elf64_s390"
2947 LD="${LD-ld} -m elf64_sparc"
2957 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2958 SAVE_CFLAGS="$CFLAGS"
2959 CFLAGS="$CFLAGS -belf"
2960 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
2962 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
2964 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2965 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2966 CFLAGS="$SAVE_CFLAGS"
2970 # Find out which ABI we are using.
2971 echo 'int i;' > conftest.$ac_ext
2972 if AC_TRY_EVAL(ac_compile); then
2973 case `/usr/bin/file conftest.o` in
2975 case $lt_cv_prog_gnu_ld in
2976 yes*) LD="${LD-ld} -m elf64_sparc" ;;
2978 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
2990 need_locks="$enable_libtool_lock"
2994 # _LT_CMD_OLD_ARCHIVE
2995 # -------------------
2996 m4_defun([_LT_CMD_OLD_ARCHIVE],
2997 [AC_CHECK_TOOL(AR, ar, false)
2998 test -z "$AR" && AR=ar
2999 test -z "$AR_FLAGS" && AR_FLAGS=cru
3000 _LT_DECL([], [AR], [1], [The archiver])
3001 _LT_DECL([], [AR_FLAGS], [1])
3003 AC_CHECK_TOOL(STRIP, strip, :)
3004 test -z "$STRIP" && STRIP=:
3005 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
3007 AC_CHECK_TOOL(RANLIB, ranlib, :)
3008 test -z "$RANLIB" && RANLIB=:
3009 _LT_DECL([], [RANLIB], [1],
3010 [Commands used to install an old-style archive])
3012 # Determine commands to create old-style static archives.
3013 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
3014 old_postinstall_cmds='chmod 644 $oldlib'
3015 old_postuninstall_cmds=
3017 if test -n "$RANLIB"; then
3020 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
3023 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
3026 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
3028 _LT_DECL([], [old_postinstall_cmds], [2])
3029 _LT_DECL([], [old_postuninstall_cmds], [2])
3030 _LT_TAGDECL([], [old_archive_cmds], [2],
3031 [Commands used to build an old-style archive])
3032 ])# _LT_CMD_OLD_ARCHIVE
3035 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
3036 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
3037 # ----------------------------------------------------------------
3038 # Check whether the given compiler option works
3039 AC_DEFUN([_LT_COMPILER_OPTION],
3040 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3041 m4_require([_LT_DECL_SED])dnl
3042 AC_CACHE_CHECK([$1], [$2],
3044 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
3045 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
3046 lt_compiler_flag="$3"
3047 # Insert the option either (1) after the last *FLAGS variable, or
3048 # (2) before a word containing "conftest.", or (3) at the end.
3049 # Note that $ac_compile itself does not contain backslashes and begins
3050 # with a dollar sign (not a hyphen), so the echo should work correctly.
3051 # The option is referenced via a variable to avoid confusing sed.
3052 lt_compile=`echo "$ac_compile" | $SED \
3053 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
3054 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
3055 -e 's:$: $lt_compiler_flag:'`
3056 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
3057 (eval "$lt_compile" 2>conftest.err)
3059 cat conftest.err >&AS_MESSAGE_LOG_FD
3060 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
3061 if (exit $ac_status) && test -s "$ac_outfile"; then
3062 # The compiler can only warn and ignore the option if not recognized
3063 # So say no if there are warnings other than the usual output.
3064 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
3065 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
3066 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
3073 if test x"[$]$2" = xyes; then
3074 m4_if([$5], , :, [$5])
3076 m4_if([$6], , :, [$6])
3078 ])# _LT_COMPILER_OPTION
3081 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
3082 dnl aclocal-1.4 backwards compatibility:
3083 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
3086 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
3087 # [ACTION-SUCCESS], [ACTION-FAILURE])
3088 # ----------------------------------------------------
3089 # Check whether the given linker option works
3090 AC_DEFUN([_LT_LINKER_OPTION],
3091 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3092 m4_require([_LT_DECL_SED])dnl
3093 AC_CACHE_CHECK([$1], [$2],
3095 save_LDFLAGS="$LDFLAGS"
3096 LDFLAGS="$LDFLAGS $3"
3097 echo "$lt_simple_link_test_code" > conftest.$ac_ext
3098 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
3099 # The linker can only warn and ignore the option if not recognized
3100 # So say no if there are warnings
3101 if test -s conftest.err; then
3102 # Append any errors to the config.log.
3103 cat conftest.err 1>&AS_MESSAGE_LOG_FD
3104 $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
3105 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
3106 if diff conftest.exp conftest.er2 >/dev/null; then
3114 LDFLAGS="$save_LDFLAGS"
3117 if test x"[$]$2" = xyes; then
3118 m4_if([$4], , :, [$4])
3120 m4_if([$5], , :, [$5])
3122 ])# _LT_LINKER_OPTION
3125 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
3126 dnl aclocal-1.4 backwards compatibility:
3127 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
3132 AC_DEFUN([LT_CMD_MAX_LEN],
3133 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3134 # find the maximum length of command line arguments
3135 AC_MSG_CHECKING([the maximum length of command line arguments])
3136 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
3142 # On DJGPP, this test can blow up pretty badly due to problems in libc
3143 # (any single argument exceeding 2000 bytes causes a buffer overrun
3144 # during glob expansion). Even if it were fixed, the result of this
3145 # check would be larger than it should be.
3146 lt_cv_sys_max_cmd_len=12288; # 12K is about right
3150 # Under GNU Hurd, this test is not required because there is
3151 # no limit to the length of command line arguments.
3152 # Libtool will interpret -1 as no limit whatsoever
3153 lt_cv_sys_max_cmd_len=-1;
3156 cygwin* | mingw* | cegcc*)
3157 # On Win9x/ME, this test blows up -- it succeeds, but takes
3158 # about 5 minutes as the teststring grows exponentially.
3159 # Worse, since 9x/ME are not pre-emptively multitasking,
3160 # you end up with a "frozen" computer, even though with patience
3161 # the test eventually succeeds (with a max line length of 256k).
3162 # Instead, let's just punt: use the minimum linelength reported by
3163 # all of the supported platforms: 8192 (on NT/2K/XP).
3164 lt_cv_sys_max_cmd_len=8192;
3168 # On AmigaOS with pdksh, this test takes hours, literally.
3169 # So we just punt and use a minimum line length of 8192.
3170 lt_cv_sys_max_cmd_len=8192;
3173 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
3174 # This has been around since 386BSD, at least. Likely further.
3175 if test -x /sbin/sysctl; then
3176 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
3177 elif test -x /usr/sbin/sysctl; then
3178 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
3180 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
3182 # And add a safety zone
3183 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
3184 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
3188 # We know the value 262144 and hardcode it with a safety zone (like BSD)
3189 lt_cv_sys_max_cmd_len=196608
3193 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
3194 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
3195 # nice to cause kernel panics so lets avoid the loop below.
3196 # First set a reasonable default.
3197 lt_cv_sys_max_cmd_len=16384
3199 if test -x /sbin/sysconfig; then
3200 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
3201 *1*) lt_cv_sys_max_cmd_len=-1 ;;
3206 lt_cv_sys_max_cmd_len=102400
3208 sysv5* | sco5v6* | sysv4.2uw2*)
3209 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
3210 if test -n "$kargmax"; then
3211 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
3213 lt_cv_sys_max_cmd_len=32768
3217 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
3218 if test -n "$lt_cv_sys_max_cmd_len"; then
3219 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
3220 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
3222 # Make teststring a little bigger before we do anything with it.
3223 # a 1K string should be a reasonable start.
3224 for i in 1 2 3 4 5 6 7 8 ; do
3225 teststring=$teststring$teststring
3227 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
3228 # If test is not a shell built-in, we'll probably end up computing a
3229 # maximum length that is only half of the actual maximum length, but
3231 while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
3232 = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
3233 test $i != 17 # 1/2 MB should be enough
3236 teststring=$teststring$teststring
3238 # Only check the string length outside the loop.
3239 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
3241 # Add a significant safety factor because C++ compilers can tack on
3242 # massive amounts of additional arguments before passing them to the
3243 # linker. It appears as though 1/2 is a usable value.
3244 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
3249 if test -n $lt_cv_sys_max_cmd_len ; then
3250 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
3254 max_cmd_len=$lt_cv_sys_max_cmd_len
3255 _LT_DECL([], [max_cmd_len], [0],
3256 [What is the maximum length of a command?])
3260 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
3261 dnl aclocal-1.4 backwards compatibility:
3262 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
3267 m4_defun([_LT_HEADER_DLFCN],
3268 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
3269 ])# _LT_HEADER_DLFCN
3272 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
3273 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
3274 # ----------------------------------------------------------------
3275 m4_defun([_LT_TRY_DLOPEN_SELF],
3276 [m4_require([_LT_HEADER_DLFCN])dnl
3277 if test "$cross_compiling" = yes; then :
3280 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
3281 lt_status=$lt_dlunknown
3282 cat > conftest.$ac_ext <<_LT_EOF
3283 [#line __oline__ "configure"
3284 #include "confdefs.h"
3293 # define LT_DLGLOBAL RTLD_GLOBAL
3296 # define LT_DLGLOBAL DL_GLOBAL
3298 # define LT_DLGLOBAL 0
3302 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
3303 find out it does not work in some platform. */
3304 #ifndef LT_DLLAZY_OR_NOW
3306 # define LT_DLLAZY_OR_NOW RTLD_LAZY
3309 # define LT_DLLAZY_OR_NOW DL_LAZY
3312 # define LT_DLLAZY_OR_NOW RTLD_NOW
3315 # define LT_DLLAZY_OR_NOW DL_NOW
3317 # define LT_DLLAZY_OR_NOW 0
3324 void fnord() { int i=42;}
3327 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
3328 int status = $lt_dlunknown;
3332 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
3333 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
3334 /* dlclose (self); */
3342 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
3343 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
3346 x$lt_dlno_uscore) $1 ;;
3347 x$lt_dlneed_uscore) $2 ;;
3348 x$lt_dlunknown|x*) $3 ;;
3351 # compilation failed
3356 ])# _LT_TRY_DLOPEN_SELF
3359 # LT_SYS_DLOPEN_SELF
3360 # ------------------
3361 AC_DEFUN([LT_SYS_DLOPEN_SELF],
3362 [m4_require([_LT_HEADER_DLFCN])dnl
3363 if test "x$enable_dlopen" != xyes; then
3364 enable_dlopen=unknown
3365 enable_dlopen_self=unknown
3366 enable_dlopen_self_static=unknown
3373 lt_cv_dlopen="load_add_on"
3375 lt_cv_dlopen_self=yes
3378 mingw* | pw32* | cegcc*)
3379 lt_cv_dlopen="LoadLibrary"
3384 lt_cv_dlopen="dlopen"
3389 # if libdl is installed we need to link against it
3390 AC_CHECK_LIB([dl], [dlopen],
3391 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
3394 lt_cv_dlopen_self=yes
3399 AC_CHECK_FUNC([shl_load],
3400 [lt_cv_dlopen="shl_load"],
3401 [AC_CHECK_LIB([dld], [shl_load],
3402 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
3403 [AC_CHECK_FUNC([dlopen],
3404 [lt_cv_dlopen="dlopen"],
3405 [AC_CHECK_LIB([dl], [dlopen],
3406 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
3407 [AC_CHECK_LIB([svld], [dlopen],
3408 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
3409 [AC_CHECK_LIB([dld], [dld_link],
3410 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
3419 if test "x$lt_cv_dlopen" != xno; then
3425 case $lt_cv_dlopen in
3427 save_CPPFLAGS="$CPPFLAGS"
3428 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
3430 save_LDFLAGS="$LDFLAGS"
3431 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
3434 LIBS="$lt_cv_dlopen_libs $LIBS"
3436 AC_CACHE_CHECK([whether a program can dlopen itself],
3437 lt_cv_dlopen_self, [dnl
3438 _LT_TRY_DLOPEN_SELF(
3439 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
3440 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
3443 if test "x$lt_cv_dlopen_self" = xyes; then
3444 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
3445 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
3446 lt_cv_dlopen_self_static, [dnl
3447 _LT_TRY_DLOPEN_SELF(
3448 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
3449 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
3453 CPPFLAGS="$save_CPPFLAGS"
3454 LDFLAGS="$save_LDFLAGS"
3459 case $lt_cv_dlopen_self in
3460 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
3461 *) enable_dlopen_self=unknown ;;
3464 case $lt_cv_dlopen_self_static in
3465 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
3466 *) enable_dlopen_self_static=unknown ;;
3469 _LT_DECL([dlopen_support], [enable_dlopen], [0],
3470 [Whether dlopen is supported])
3471 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
3472 [Whether dlopen of programs is supported])
3473 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
3474 [Whether dlopen of statically linked programs is supported])
3475 ])# LT_SYS_DLOPEN_SELF
3478 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
3479 dnl aclocal-1.4 backwards compatibility:
3480 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
3483 # _LT_COMPILER_C_O([TAGNAME])
3484 # ---------------------------
3485 # Check to see if options -c and -o are simultaneously supported by compiler.
3486 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
3487 m4_defun([_LT_COMPILER_C_O],
3488 [m4_require([_LT_DECL_SED])dnl
3489 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3490 m4_require([_LT_TAG_COMPILER])dnl
3491 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
3492 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
3493 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
3494 $RM -r conftest 2>/dev/null
3498 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
3500 lt_compiler_flag="-o out/conftest2.$ac_objext"
3501 # Insert the option either (1) after the last *FLAGS variable, or
3502 # (2) before a word containing "conftest.", or (3) at the end.
3503 # Note that $ac_compile itself does not contain backslashes and begins
3504 # with a dollar sign (not a hyphen), so the echo should work correctly.
3505 lt_compile=`echo "$ac_compile" | $SED \
3506 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
3507 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
3508 -e 's:$: $lt_compiler_flag:'`
3509 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
3510 (eval "$lt_compile" 2>out/conftest.err)
3512 cat out/conftest.err >&AS_MESSAGE_LOG_FD
3513 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
3514 if (exit $ac_status) && test -s out/conftest2.$ac_objext
3516 # The compiler can only warn and ignore the option if not recognized
3517 # So say no if there are warnings
3518 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
3519 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
3520 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
3521 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
3524 chmod u+w . 2>&AS_MESSAGE_LOG_FD
3526 # SGI C++ compiler will create directory out/ii_files/ for
3527 # template instantiation
3528 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
3529 $RM out/* && rmdir out
3534 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
3535 [Does compiler simultaneously support -c and -o options?])
3536 ])# _LT_COMPILER_C_O
3539 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
3540 # ----------------------------------
3541 # Check to see if we can do hard links to lock some files if needed
3542 m4_defun([_LT_COMPILER_FILE_LOCKS],
3543 [m4_require([_LT_ENABLE_LOCK])dnl
3544 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3545 _LT_COMPILER_C_O([$1])
3547 hard_links="nottested"
3548 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
3549 # do not overwrite the value of need_locks provided by the user
3550 AC_MSG_CHECKING([if we can lock with hard links])
3553 ln conftest.a conftest.b 2>/dev/null && hard_links=no
3555 ln conftest.a conftest.b 2>&5 || hard_links=no
3556 ln conftest.a conftest.b 2>/dev/null && hard_links=no
3557 AC_MSG_RESULT([$hard_links])
3558 if test "$hard_links" = no; then
3559 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
3565 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
3566 ])# _LT_COMPILER_FILE_LOCKS
3571 m4_defun([_LT_CHECK_OBJDIR],
3572 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
3573 [rm -f .libs 2>/dev/null
3574 mkdir .libs 2>/dev/null
3575 if test -d .libs; then
3578 # MS-DOS does not allow filenames that begin with a dot.
3581 rmdir .libs 2>/dev/null])
3582 objdir=$lt_cv_objdir
3583 _LT_DECL([], [objdir], [0],
3584 [The name of the directory that contains temporary libtool files])dnl
3585 m4_pattern_allow([LT_OBJDIR])dnl
3586 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
3587 [Define to the sub-directory in which libtool stores uninstalled libraries.])
3588 ])# _LT_CHECK_OBJDIR
3591 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
3592 # --------------------------------------
3593 # Check hardcoding attributes.
3594 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
3595 [AC_MSG_CHECKING([how to hardcode library paths into programs])
3596 _LT_TAGVAR(hardcode_action, $1)=
3597 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
3598 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
3599 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
3601 # We can hardcode non-existent directories.
3602 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
3603 # If the only mechanism to avoid hardcoding is shlibpath_var, we
3604 # have to relink, otherwise we might link with an installed library
3605 # when we should be linking with a yet-to-be-installed one
3606 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
3607 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
3608 # Linking always hardcodes the temporary library directory.
3609 _LT_TAGVAR(hardcode_action, $1)=relink
3611 # We can link without hardcoding, and we can hardcode nonexisting dirs.
3612 _LT_TAGVAR(hardcode_action, $1)=immediate
3615 # We cannot hardcode anything, or else we can only hardcode existing
3617 _LT_TAGVAR(hardcode_action, $1)=unsupported
3619 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
3621 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
3622 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
3623 # Fast installation is not supported
3624 enable_fast_install=no
3625 elif test "$shlibpath_overrides_runpath" = yes ||
3626 test "$enable_shared" = no; then
3627 # Fast installation is not necessary
3628 enable_fast_install=needless
3630 _LT_TAGDECL([], [hardcode_action], [0],
3631 [How to hardcode a shared library path into an executable])
3632 ])# _LT_LINKER_HARDCODE_LIBPATH
3637 m4_defun([_LT_CMD_STRIPLIB],
3638 [m4_require([_LT_DECL_EGREP])
3641 AC_MSG_CHECKING([whether stripping libraries is possible])
3642 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
3643 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
3644 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
3645 AC_MSG_RESULT([yes])
3647 # FIXME - insert some real tests, host_os isn't really good enough
3650 if test -n "$STRIP" ; then
3651 striplib="$STRIP -x"
3652 old_striplib="$STRIP -S"
3653 AC_MSG_RESULT([yes])
3663 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
3664 _LT_DECL([], [striplib], [1])
3665 ])# _LT_CMD_STRIPLIB
3668 # _LT_SYS_DYNAMIC_LINKER([TAG])
3669 # -----------------------------
3670 # PORTME Fill in your ld.so characteristics
3671 m4_defun([_LT_SYS_DYNAMIC_LINKER],
3672 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3673 m4_require([_LT_DECL_EGREP])dnl
3674 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3675 m4_require([_LT_DECL_OBJDUMP])dnl
3676 m4_require([_LT_DECL_SED])dnl
3677 AC_MSG_CHECKING([dynamic linker characteristics])
3680 if test "$GCC" = yes; then
3682 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
3683 *) lt_awk_arg="/^libraries:/" ;;
3685 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
3686 if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
3687 # if the path contains ";" then we assume it to be the separator
3688 # otherwise default to the standard path separator (i.e. ":") - it is
3689 # assumed that no part of a normal pathname contains ";" but that should
3690 # okay in the real world where ";" in dirpaths is itself problematic.
3691 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
3693 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3695 # Ok, now we have the path, separated by spaces, we can step through it
3696 # and add multilib dir if necessary.
3697 lt_tmp_lt_search_path_spec=
3698 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
3699 for lt_sys_path in $lt_search_path_spec; do
3700 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
3701 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
3703 test -d "$lt_sys_path" && \
3704 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
3707 lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
3708 BEGIN {RS=" "; FS="/|\n";} {
3711 for (lt_i = NF; lt_i > 0; lt_i--) {
3712 if ($lt_i != "" && $lt_i != ".") {
3713 if ($lt_i == "..") {
3716 if (lt_count == 0) {
3717 lt_foo="/" $lt_i lt_foo;
3724 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
3725 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
3727 sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
3729 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
3732 libname_spec='lib$name'
3740 shlibpath_overrides_runpath=unknown
3742 dynamic_linker="$host_os ld.so"
3743 sys_lib_dlsearch_path_spec="/lib /usr/lib"
3744 need_lib_prefix=unknown
3745 hardcode_into_libs=no
3747 # when you set need_version to no, make sure it does not cause -set_version
3748 # flags to be left without arguments
3749 need_version=unknown
3754 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
3755 shlibpath_var=LIBPATH
3757 # AIX 3 has no versioning support, so we append a major version to the name.
3758 soname_spec='${libname}${release}${shared_ext}$major'
3765 hardcode_into_libs=yes
3766 if test "$host_cpu" = ia64; then
3767 # AIX 5 supports IA64
3768 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
3769 shlibpath_var=LD_LIBRARY_PATH
3771 # With GCC up to 2.95.x, collect2 would create an import file
3772 # for dependence libraries. The import file would start with
3773 # the line `#! .'. This would cause the generated library to
3774 # depend on `.', always an invalid library. This was fixed in
3775 # development snapshots of GCC prior to 3.0.
3777 aix4 | aix4.[[01]] | aix4.[[01]].*)
3778 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
3780 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
3787 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
3788 # soname into executable. Probably we can add versioning support to
3789 # collect2, so additional links can be useful in future.
3790 if test "$aix_use_runtimelinking" = yes; then
3791 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
3792 # instead of lib<name>.a to let people know that these are not
3793 # typical AIX shared libraries.
3794 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3796 # We preserve .a as extension for shared libraries through AIX4.2
3797 # and later when we are not doing run time linking.
3798 library_names_spec='${libname}${release}.a $libname.a'
3799 soname_spec='${libname}${release}${shared_ext}$major'
3801 shlibpath_var=LIBPATH
3808 # Since July 2007 AmigaOS4 officially supports .so libraries.
3809 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
3810 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3813 library_names_spec='$libname.ixlibrary $libname.a'
3814 # Create ${libname}_ixlibrary.a entries in /sys/libs.
3815 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'
3821 library_names_spec='${libname}${shared_ext}'
3822 dynamic_linker="$host_os ld.so"
3823 shlibpath_var=LIBRARY_PATH
3829 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3830 soname_spec='${libname}${release}${shared_ext}$major'
3831 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
3832 shlibpath_var=LD_LIBRARY_PATH
3833 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
3834 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
3835 # the default ld.so.conf also contains /usr/contrib/lib and
3836 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
3837 # libtool to hard-code these into programs
3840 cygwin* | mingw* | pw32* | cegcc*)
3841 version_type=windows
3846 case $GCC,$host_os in
3847 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
3848 library_names_spec='$libname.dll.a'
3849 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3850 postinstall_cmds='base_file=`basename \${file}`~
3851 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3852 dldir=$destdir/`dirname \$dlpath`~
3853 test -d \$dldir || mkdir -p \$dldir~
3854 $install_prog $dir/$dlname \$dldir/$dlname~
3855 chmod a+x \$dldir/$dlname~
3856 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
3857 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
3859 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3860 dlpath=$dir/\$dldll~
3862 shlibpath_overrides_runpath=yes
3866 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
3867 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3868 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
3871 # MinGW DLLs use traditional 'lib' prefix
3872 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3873 sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
3874 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
3875 # It is most probably a Windows format PATH printed by
3876 # mingw gcc, but we are running on Cygwin. Gcc prints its search
3877 # path with ; separators, and with drive letters. We can handle the
3878 # drive letters (cygwin fileutils understands them), so leave them,
3879 # especially as we might pass files found there to a mingw objdump,
3880 # which wouldn't understand a cygwinified path. Ahh.
3881 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
3883 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3887 # pw32 DLLs use 'pw' prefix rather than 'lib'
3888 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3894 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
3897 dynamic_linker='Win32 ld.exe'
3898 # FIXME: first we should search . and the directory the executable is in
3902 darwin* | rhapsody*)
3903 dynamic_linker="$host_os dyld"
3907 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
3908 soname_spec='${libname}${release}${major}$shared_ext'
3909 shlibpath_overrides_runpath=yes
3910 shlibpath_var=DYLD_LIBRARY_PATH
3911 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3913 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3914 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3921 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
3922 soname_spec='${libname}${release}${shared_ext}$major'
3923 shlibpath_var=LD_LIBRARY_PATH
3930 freebsd* | dragonfly*)
3931 # DragonFly does not have aout. When/if they implement a new
3932 # versioning mechanism, adjust this.
3933 if test -x /usr/bin/objformat; then
3934 objformat=`/usr/bin/objformat`
3937 freebsd[[123]]*) objformat=aout ;;
3941 version_type=freebsd-$objformat
3942 case $version_type in
3944 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3949 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
3953 shlibpath_var=LD_LIBRARY_PATH
3956 shlibpath_overrides_runpath=yes
3958 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3959 shlibpath_overrides_runpath=yes
3960 hardcode_into_libs=yes
3962 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3963 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3964 shlibpath_overrides_runpath=no
3965 hardcode_into_libs=yes
3967 *) # from 4.6 on, and DragonFly
3968 shlibpath_overrides_runpath=yes
3969 hardcode_into_libs=yes
3978 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3979 soname_spec='${libname}${release}${shared_ext}$major'
3980 shlibpath_var=LD_LIBRARY_PATH
3981 hardcode_into_libs=yes
3984 hpux9* | hpux10* | hpux11*)
3985 # Give a soname corresponding to the major version so that dld.sl refuses to
3986 # link against other versions.
3993 hardcode_into_libs=yes
3994 dynamic_linker="$host_os dld.so"
3995 shlibpath_var=LD_LIBRARY_PATH
3996 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3997 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3998 soname_spec='${libname}${release}${shared_ext}$major'
3999 if test "X$HPUX_IA64_MODE" = X32; then
4000 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
4002 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
4004 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
4008 hardcode_into_libs=yes
4009 dynamic_linker="$host_os dld.sl"
4010 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
4011 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
4012 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4013 soname_spec='${libname}${release}${shared_ext}$major'
4014 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
4015 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
4019 dynamic_linker="$host_os dld.sl"
4020 shlibpath_var=SHLIB_PATH
4021 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
4022 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4023 soname_spec='${libname}${release}${shared_ext}$major'
4026 # HP-UX runs *really* slowly unless shared libraries are mode 555.
4027 postinstall_cmds='chmod 555 $lib'
4034 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
4035 soname_spec='${libname}${release}${shared_ext}$major'
4036 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
4037 shlibpath_var=LD_LIBRARY_PATH
4038 shlibpath_overrides_runpath=no
4039 hardcode_into_libs=yes
4042 irix5* | irix6* | nonstopux*)
4044 nonstopux*) version_type=nonstopux ;;
4046 if test "$lt_cv_prog_gnu_ld" = yes; then
4054 soname_spec='${libname}${release}${shared_ext}$major'
4055 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
4057 irix5* | nonstopux*)
4061 case $LD in # libtool.m4 will add one of these switches to LD
4062 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
4063 libsuff= shlibsuff= libmagic=32-bit;;
4064 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
4065 libsuff=32 shlibsuff=N32 libmagic=N32;;
4066 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
4067 libsuff=64 shlibsuff=64 libmagic=64-bit;;
4068 *) libsuff= shlibsuff= libmagic=never-match;;
4072 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
4073 shlibpath_overrides_runpath=no
4074 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
4075 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
4076 hardcode_into_libs=yes
4079 # No shared lib support for Linux oldld, aout, or coff.
4080 linux*oldld* | linux*aout* | linux*coff*)
4084 # This must be Linux ELF.
4085 linux* | k*bsd*-gnu)
4089 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4090 soname_spec='${libname}${release}${shared_ext}$major'
4091 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
4092 shlibpath_var=LD_LIBRARY_PATH
4093 shlibpath_overrides_runpath=no
4094 # Some binutils ld are patched to set DT_RUNPATH
4095 save_LDFLAGS=$LDFLAGS
4097 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
4098 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
4099 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
4100 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
4101 [shlibpath_overrides_runpath=yes])])
4102 LDFLAGS=$save_LDFLAGS
4105 # This implies no fast_install, which is unacceptable.
4106 # Some rework will be needed to allow for fast_install
4107 # before this can be enabled.
4108 hardcode_into_libs=yes
4110 # Append ld.so.conf contents to the search path
4111 if test -f /etc/ld.so.conf; then
4112 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
4113 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
4116 # We used to test for /lib/ld.so.1 and disable shared libraries on
4117 # powerpc, because MkLinux only supported shared libraries with the
4118 # GNU dynamic linker. Since this was broken with cross compilers,
4119 # most powerpc-linux boxes support dynamic linking these days and
4120 # people can always --disable-shared, the test was removed, and we
4121 # assume the GNU/Linux dynamic linker is in use.
4122 dynamic_linker='GNU/Linux ld.so'
4129 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
4130 soname_spec='${libname}${release}${shared_ext}$major'
4131 shlibpath_var=LD_LIBRARY_PATH
4132 shlibpath_overrides_runpath=no
4133 hardcode_into_libs=yes
4134 dynamic_linker='NetBSD ld.elf_so'
4141 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4142 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
4143 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
4144 dynamic_linker='NetBSD (a.out) ld.so'
4146 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
4147 soname_spec='${libname}${release}${shared_ext}$major'
4148 dynamic_linker='NetBSD ld.elf_so'
4150 shlibpath_var=LD_LIBRARY_PATH
4151 shlibpath_overrides_runpath=yes
4152 hardcode_into_libs=yes
4157 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4158 shlibpath_var=LD_LIBRARY_PATH
4159 shlibpath_overrides_runpath=yes
4166 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4167 soname_spec='${libname}${release}${shared_ext}$major'
4168 shlibpath_var=LD_LIBRARY_PATH
4169 shlibpath_overrides_runpath=no
4170 hardcode_into_libs=yes
4171 dynamic_linker='ldqnx.so'
4176 sys_lib_dlsearch_path_spec="/usr/lib"
4178 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
4180 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
4181 *) need_version=no ;;
4183 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
4184 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
4185 shlibpath_var=LD_LIBRARY_PATH
4186 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4188 openbsd2.[[89]] | openbsd2.[[89]].*)
4189 shlibpath_overrides_runpath=no
4192 shlibpath_overrides_runpath=yes
4196 shlibpath_overrides_runpath=yes
4201 libname_spec='$name'
4204 library_names_spec='$libname${shared_ext} $libname.a'
4205 dynamic_linker='OS/2 ld.exe'
4206 shlibpath_var=LIBPATH
4209 osf3* | osf4* | osf5*)
4213 soname_spec='${libname}${release}${shared_ext}$major'
4214 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4215 shlibpath_var=LD_LIBRARY_PATH
4216 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
4217 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
4228 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4229 soname_spec='${libname}${release}${shared_ext}$major'
4230 shlibpath_var=LD_LIBRARY_PATH
4231 shlibpath_overrides_runpath=yes
4232 hardcode_into_libs=yes
4233 # ldd complains unless libraries are executable
4234 postinstall_cmds='chmod +x $lib'
4239 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
4240 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
4241 shlibpath_var=LD_LIBRARY_PATH
4242 shlibpath_overrides_runpath=yes
4243 if test "$with_gnu_ld" = yes; then
4251 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4252 soname_spec='${libname}${release}${shared_ext}$major'
4253 shlibpath_var=LD_LIBRARY_PATH
4254 case $host_vendor in
4256 shlibpath_overrides_runpath=no
4258 runpath_var=LD_RUN_PATH
4266 shlibpath_overrides_runpath=no
4267 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
4273 if test -d /usr/nec ;then
4275 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
4276 soname_spec='$libname${shared_ext}.$major'
4277 shlibpath_var=LD_LIBRARY_PATH
4281 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4282 version_type=freebsd-elf
4285 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
4286 soname_spec='${libname}${release}${shared_ext}$major'
4287 shlibpath_var=LD_LIBRARY_PATH
4288 shlibpath_overrides_runpath=yes
4289 hardcode_into_libs=yes
4290 if test "$with_gnu_ld" = yes; then
4291 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
4293 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
4296 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
4300 sys_lib_dlsearch_path_spec='/usr/lib'
4304 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
4308 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4309 shlibpath_var=LD_LIBRARY_PATH
4310 shlibpath_overrides_runpath=no
4311 hardcode_into_libs=yes
4316 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
4317 soname_spec='${libname}${release}${shared_ext}$major'
4318 shlibpath_var=LD_LIBRARY_PATH
4325 AC_MSG_RESULT([$dynamic_linker])
4326 test "$dynamic_linker" = no && can_build_shared=no
4328 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
4329 if test "$GCC" = yes; then
4330 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
4333 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
4334 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
4336 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
4337 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
4340 _LT_DECL([], [variables_saved_for_relink], [1],
4341 [Variables whose values should be saved in libtool wrapper scripts and
4342 restored at link time])
4343 _LT_DECL([], [need_lib_prefix], [0],
4344 [Do we need the "lib" prefix for modules?])
4345 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
4346 _LT_DECL([], [version_type], [0], [Library versioning type])
4347 _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
4348 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
4349 _LT_DECL([], [shlibpath_overrides_runpath], [0],
4350 [Is shlibpath searched before the hard-coded library search path?])
4351 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
4352 _LT_DECL([], [library_names_spec], [1],
4353 [[List of archive names. First name is the real one, the rest are links.
4354 The last name is the one that the linker finds with -lNAME]])
4355 _LT_DECL([], [soname_spec], [1],
4356 [[The coded name of the library, if different from the real name]])
4357 _LT_DECL([], [postinstall_cmds], [2],
4358 [Command to use after installation of a shared archive])
4359 _LT_DECL([], [postuninstall_cmds], [2],
4360 [Command to use after uninstallation of a shared archive])
4361 _LT_DECL([], [finish_cmds], [2],
4362 [Commands used to finish a libtool library installation in a directory])
4363 _LT_DECL([], [finish_eval], [1],
4364 [[As "finish_cmds", except a single script fragment to be evaled but
4366 _LT_DECL([], [hardcode_into_libs], [0],
4367 [Whether we should hardcode library paths into libraries])
4368 _LT_DECL([], [sys_lib_search_path_spec], [2],
4369 [Compile-time system search path for libraries])
4370 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
4371 [Run-time system search path for libraries])
4372 ])# _LT_SYS_DYNAMIC_LINKER
4375 # _LT_PATH_TOOL_PREFIX(TOOL)
4376 # --------------------------
4377 # find a file program which can recognize shared library
4378 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
4379 [m4_require([_LT_DECL_EGREP])dnl
4380 AC_MSG_CHECKING([for $1])
4381 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
4383 [[\\/*] | ?:[\\/]*])
4384 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
4387 lt_save_MAGIC_CMD="$MAGIC_CMD"
4388 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4389 dnl $ac_dummy forces splitting on constant user-supplied paths.
4390 dnl POSIX.2 word splitting is done only on the output of word expansions,
4391 dnl not every word. This closes a longstanding sh security hole.
4392 ac_dummy="m4_if([$2], , $PATH, [$2])"
4393 for ac_dir in $ac_dummy; do
4395 test -z "$ac_dir" && ac_dir=.
4396 if test -f $ac_dir/$1; then
4397 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
4398 if test -n "$file_magic_test_file"; then
4399 case $deplibs_check_method in
4401 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
4402 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
4403 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
4404 $EGREP "$file_magic_regex" > /dev/null; then
4409 *** Warning: the command libtool uses to detect shared libraries,
4410 *** $file_magic_cmd, produces output that libtool cannot recognize.
4411 *** The result is that libtool may fail to recognize shared libraries
4412 *** as such. This will affect the creation of libtool libraries that
4413 *** depend on shared libraries, but programs linked with such libtool
4414 *** libraries will work regardless of this problem. Nevertheless, you
4415 *** may want to report the problem to your system manager and/or to
4416 *** bug-libtool@gnu.org
4426 MAGIC_CMD="$lt_save_MAGIC_CMD"
4429 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
4430 if test -n "$MAGIC_CMD"; then
4431 AC_MSG_RESULT($MAGIC_CMD)
4435 _LT_DECL([], [MAGIC_CMD], [0],
4436 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
4437 ])# _LT_PATH_TOOL_PREFIX
4440 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
4441 dnl aclocal-1.4 backwards compatibility:
4442 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
4447 # find a file program which can recognize a shared library
4448 m4_defun([_LT_PATH_MAGIC],
4449 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
4450 if test -z "$lt_cv_path_MAGIC_CMD"; then
4451 if test -n "$ac_tool_prefix"; then
4452 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
4462 # find the pathname to the GNU or non-GNU linker
4463 AC_DEFUN([LT_PATH_LD],
4464 [AC_REQUIRE([AC_PROG_CC])dnl
4465 AC_REQUIRE([AC_CANONICAL_HOST])dnl
4466 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
4467 m4_require([_LT_DECL_SED])dnl
4468 m4_require([_LT_DECL_EGREP])dnl
4470 AC_ARG_WITH([gnu-ld],
4471 [AS_HELP_STRING([--with-gnu-ld],
4472 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
4473 [test "$withval" = no || with_gnu_ld=yes],
4474 [with_gnu_ld=no])dnl
4477 if test "$GCC" = yes; then
4478 # Check if gcc -print-prog-name=ld gives a path.
4479 AC_MSG_CHECKING([for ld used by $CC])
4482 # gcc leaves a trailing carriage return which upsets mingw
4483 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4485 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4488 # Accept absolute paths.
4489 [[\\/]]* | ?:[[\\/]]*)
4490 re_direlt='/[[^/]][[^/]]*/\.\./'
4491 # Canonicalize the pathname of ld
4492 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4493 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4494 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4496 test -z "$LD" && LD="$ac_prog"
4499 # If it fails, then pretend we aren't using GCC.
4503 # If it is relative, then search for the first ld in PATH.
4507 elif test "$with_gnu_ld" = yes; then
4508 AC_MSG_CHECKING([for GNU ld])
4510 AC_MSG_CHECKING([for non-GNU ld])
4512 AC_CACHE_VAL(lt_cv_path_LD,
4513 [if test -z "$LD"; then
4514 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4515 for ac_dir in $PATH; do
4517 test -z "$ac_dir" && ac_dir=.
4518 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4519 lt_cv_path_LD="$ac_dir/$ac_prog"
4520 # Check to see if the program is GNU ld. I'd rather use --version,
4521 # but apparently some variants of GNU ld only accept -v.
4522 # Break only if it was the GNU/non-GNU ld that we prefer.
4523 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4524 *GNU* | *'with BFD'*)
4525 test "$with_gnu_ld" != no && break
4528 test "$with_gnu_ld" != yes && break
4535 lt_cv_path_LD="$LD" # Let the user override the test with a path.
4538 if test -n "$LD"; then
4543 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
4547 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
4551 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
4552 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
4553 dnl aclocal-1.4 backwards compatibility:
4554 dnl AC_DEFUN([AM_PROG_LD], [])
4555 dnl AC_DEFUN([AC_PROG_LD], [])
4560 m4_defun([_LT_PATH_LD_GNU],
4561 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
4562 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
4563 case `$LD -v 2>&1 </dev/null` in
4564 *GNU* | *'with BFD'*)
4565 lt_cv_prog_gnu_ld=yes
4568 lt_cv_prog_gnu_ld=no
4571 with_gnu_ld=$lt_cv_prog_gnu_ld
4577 # find reload flag for linker
4578 # -- PORTME Some linkers may need a different reload flag.
4579 m4_defun([_LT_CMD_RELOAD],
4580 [AC_CACHE_CHECK([for $LD option to reload object files],
4581 lt_cv_ld_reload_flag,
4582 [lt_cv_ld_reload_flag='-r'])
4583 reload_flag=$lt_cv_ld_reload_flag
4584 case $reload_flag in
4586 *) reload_flag=" $reload_flag" ;;
4588 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4591 if test "$GCC" = yes; then
4592 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
4594 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4598 _LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
4599 _LT_DECL([], [reload_cmds], [2])dnl
4603 # _LT_CHECK_MAGIC_METHOD
4604 # ----------------------
4605 # how to check for library dependencies
4606 # -- PORTME fill in with the dynamic library characteristics
4607 m4_defun([_LT_CHECK_MAGIC_METHOD],
4608 [m4_require([_LT_DECL_EGREP])
4609 m4_require([_LT_DECL_OBJDUMP])
4610 AC_CACHE_CHECK([how to recognize dependent libraries],
4611 lt_cv_deplibs_check_method,
4612 [lt_cv_file_magic_cmd='$MAGIC_CMD'
4613 lt_cv_file_magic_test_file=
4614 lt_cv_deplibs_check_method='unknown'
4615 # Need to set the preceding variable on all platforms that support
4616 # interlibrary dependencies.
4617 # 'none' -- dependencies not supported.
4618 # `unknown' -- same as none, but documents that we really don't know.
4619 # 'pass_all' -- all dependencies passed with no checks.
4620 # 'test_compile' -- check by making test program.
4621 # 'file_magic [[regex]]' -- check by looking for files in library path
4622 # which responds to the $file_magic_cmd with a given extended regex.
4623 # If you have `file' or equivalent on your system and you're not sure
4624 # whether `pass_all' will *always* work, you probably want this one.
4628 lt_cv_deplibs_check_method=pass_all
4632 lt_cv_deplibs_check_method=pass_all
4636 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
4637 lt_cv_file_magic_cmd='/usr/bin/file -L'
4638 lt_cv_file_magic_test_file=/shlib/libc.so
4642 # func_win32_libid is a shell function defined in ltmain.sh
4643 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4644 lt_cv_file_magic_cmd='func_win32_libid'
4648 # Base MSYS/MinGW do not provide the 'file' command needed by
4649 # func_win32_libid shell function, so use a weaker test based on 'objdump',
4650 # unless we find 'file', for example because we are cross-compiling.
4651 if ( file / ) >/dev/null 2>&1; then
4652 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4653 lt_cv_file_magic_cmd='func_win32_libid'
4655 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
4656 lt_cv_file_magic_cmd='$OBJDUMP -f'
4661 # use the weaker test based on 'objdump'. See mingw*.
4662 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
4663 lt_cv_file_magic_cmd='$OBJDUMP -f'
4666 darwin* | rhapsody*)
4667 lt_cv_deplibs_check_method=pass_all
4670 freebsd* | dragonfly*)
4671 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4674 # Not sure whether the presence of OpenBSD here was a mistake.
4675 # Let's accept both of them until this is cleared up.
4676 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
4677 lt_cv_file_magic_cmd=/usr/bin/file
4678 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4682 lt_cv_deplibs_check_method=pass_all
4687 lt_cv_deplibs_check_method=pass_all
4690 hpux10.20* | hpux11*)
4691 lt_cv_file_magic_cmd=/usr/bin/file
4694 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
4695 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
4698 [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]']
4699 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
4702 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
4703 lt_cv_file_magic_test_file=/usr/lib/libc.sl
4709 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
4710 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
4713 irix5* | irix6* | nonstopux*)
4715 *-32|*"-32 ") libmagic=32-bit;;
4716 *-n32|*"-n32 ") libmagic=N32;;
4717 *-64|*"-64 ") libmagic=64-bit;;
4718 *) libmagic=never-match;;
4720 lt_cv_deplibs_check_method=pass_all
4723 # This must be Linux ELF.
4724 linux* | k*bsd*-gnu)
4725 lt_cv_deplibs_check_method=pass_all
4728 netbsd* | netbsdelf*-gnu)
4729 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4730 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4732 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
4737 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
4738 lt_cv_file_magic_cmd=/usr/bin/file
4739 lt_cv_file_magic_test_file=/usr/lib/libnls.so
4743 lt_cv_deplibs_check_method=pass_all
4747 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4748 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
4750 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4754 osf3* | osf4* | osf5*)
4755 lt_cv_deplibs_check_method=pass_all
4759 lt_cv_deplibs_check_method=pass_all
4763 lt_cv_deplibs_check_method=pass_all
4766 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4767 lt_cv_deplibs_check_method=pass_all
4771 case $host_vendor in
4773 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]]'
4774 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
4777 lt_cv_deplibs_check_method=pass_all
4780 lt_cv_file_magic_cmd='/bin/file'
4781 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
4784 lt_cv_file_magic_cmd='/bin/file'
4785 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
4786 lt_cv_file_magic_test_file=/lib/libc.so
4789 lt_cv_deplibs_check_method=pass_all
4792 lt_cv_deplibs_check_method=pass_all
4798 lt_cv_deplibs_check_method=pass_all
4802 file_magic_cmd=$lt_cv_file_magic_cmd
4803 deplibs_check_method=$lt_cv_deplibs_check_method
4804 test -z "$deplibs_check_method" && deplibs_check_method=unknown
4806 _LT_DECL([], [deplibs_check_method], [1],
4807 [Method to check whether dependent libraries are shared objects])
4808 _LT_DECL([], [file_magic_cmd], [1],
4809 [Command to use when deplibs_check_method == "file_magic"])
4810 ])# _LT_CHECK_MAGIC_METHOD
4815 # find the pathname to a BSD- or MS-compatible name lister
4816 AC_DEFUN([LT_PATH_NM],
4817 [AC_REQUIRE([AC_PROG_CC])dnl
4818 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
4819 [if test -n "$NM"; then
4820 # Let the user override the test.
4823 lt_nm_to_check="${ac_tool_prefix}nm"
4824 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4825 lt_nm_to_check="$lt_nm_to_check nm"
4827 for lt_tmp_nm in $lt_nm_to_check; do
4828 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4829 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4831 test -z "$ac_dir" && ac_dir=.
4832 tmp_nm="$ac_dir/$lt_tmp_nm"
4833 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
4834 # Check to see if the nm accepts a BSD-compat flag.
4835 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4836 # nm: unknown option "B" ignored
4837 # Tru64's nm complains that /dev/null is an invalid object file
4838 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
4839 */dev/null* | *'Invalid file or object type'*)
4840 lt_cv_path_NM="$tmp_nm -B"
4844 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4846 lt_cv_path_NM="$tmp_nm -p"
4850 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4851 continue # so that we can try to find one that supports BSD flags
4860 : ${lt_cv_path_NM=no}
4862 if test "$lt_cv_path_NM" != "no"; then
4865 # Didn't find any BSD compatible name lister, look for dumpbin.
4866 AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
4868 if test "$DUMPBIN" != ":"; then
4872 test -z "$NM" && NM=nm
4874 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
4876 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
4877 [lt_cv_nm_interface="BSD nm"
4878 echo "int some_variable = 0;" > conftest.$ac_ext
4879 (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
4880 (eval "$ac_compile" 2>conftest.err)
4881 cat conftest.err >&AS_MESSAGE_LOG_FD
4882 (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
4883 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4884 cat conftest.err >&AS_MESSAGE_LOG_FD
4885 (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
4886 cat conftest.out >&AS_MESSAGE_LOG_FD
4887 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4888 lt_cv_nm_interface="MS dumpbin"
4894 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
4895 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
4896 dnl aclocal-1.4 backwards compatibility:
4897 dnl AC_DEFUN([AM_PROG_NM], [])
4898 dnl AC_DEFUN([AC_PROG_NM], [])
4903 # check for math library
4904 AC_DEFUN([LT_LIB_M],
4905 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4908 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
4909 # These system don't have libm, or don't need it
4912 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
4913 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
4916 AC_CHECK_LIB(m, cos, LIBM="-lm")
4923 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
4924 dnl aclocal-1.4 backwards compatibility:
4925 dnl AC_DEFUN([AC_CHECK_LIBM], [])
4928 # _LT_COMPILER_NO_RTTI([TAGNAME])
4929 # -------------------------------
4930 m4_defun([_LT_COMPILER_NO_RTTI],
4931 [m4_require([_LT_TAG_COMPILER])dnl
4933 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4935 if test "$GCC" = yes; then
4936 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
4938 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4939 lt_cv_prog_compiler_rtti_exceptions,
4940 [-fno-rtti -fno-exceptions], [],
4941 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4943 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
4944 [Compiler flag to turn off builtin functions])
4945 ])# _LT_COMPILER_NO_RTTI
4948 # _LT_CMD_GLOBAL_SYMBOLS
4949 # ----------------------
4950 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
4951 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4952 AC_REQUIRE([AC_PROG_CC])dnl
4953 AC_REQUIRE([LT_PATH_NM])dnl
4954 AC_REQUIRE([LT_PATH_LD])dnl
4955 m4_require([_LT_DECL_SED])dnl
4956 m4_require([_LT_DECL_EGREP])dnl
4957 m4_require([_LT_TAG_COMPILER])dnl
4959 # Check for command to grab the raw symbol name followed by C symbol from nm.
4960 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4961 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4963 # These are sane defaults that work on at least a few old systems.
4964 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4966 # Character class describing NM global symbol codes.
4967 symcode='[[BCDEGRST]]'
4969 # Regexp to match symbols that can be accessed directly from C.
4970 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4972 # Define system-specific variables.
4977 cygwin* | mingw* | pw32* | cegcc*)
4978 symcode='[[ABCDGISTW]]'
4981 if test "$host_cpu" = ia64; then
4982 symcode='[[ABCDEGRST]]'
4986 symcode='[[BCDEGRST]]'
4989 symcode='[[BCDEGQRST]]'
5000 sysv5* | sco5v6* | unixware* | OpenUNIX*)
5004 symcode='[[DFNSTU]]'
5008 # If we're using GNU nm, then use its standard symbol codes.
5009 case `$NM -V 2>&1` in
5010 *GNU* | *'with BFD'*)
5011 symcode='[[ABCDGIRSTW]]' ;;
5014 # Transform an extracted symbol line into a proper C declaration.
5015 # Some systems (esp. on ia64) link data and code symbols differently,
5016 # so use this general approach.
5017 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5019 # Transform an extracted symbol line into symbol name and symbol address
5020 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
5021 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
5023 # Handle CRLF in mingw tool chain
5027 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5031 # Try without a prefix underscore, then with it.
5032 for ac_symprfx in "" "_"; do
5034 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5035 symxfrm="\\1 $ac_symprfx\\2 \\2"
5037 # Write the raw and C identifiers.
5038 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
5039 # Fake it for dumpbin and say T for any non-static function
5040 # and D for any global variable.
5041 # Also find C++ and __fastcall symbols from MSVC++,
5042 # which start with @ or ?.
5043 lt_cv_sys_global_symbol_pipe="$AWK ['"\
5044 " {last_section=section; section=\$ 3};"\
5045 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
5046 " \$ 0!~/External *\|/{next};"\
5047 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
5048 " {if(hide[section]) next};"\
5049 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
5050 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
5051 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
5052 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
5053 " ' prfx=^$ac_symprfx]"
5055 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5058 # Check to see that the pipe works correctly.
5062 cat > conftest.$ac_ext <<_LT_EOF
5067 void nm_test_func(void);
5068 void nm_test_func(void){}
5072 int main(){nm_test_var='a';nm_test_func();return(0);}
5075 if AC_TRY_EVAL(ac_compile); then
5076 # Now try to grab the symbols.
5078 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5079 # Try sorting and uniquifying the output.
5080 if sort "$nlist" | uniq > "$nlist"T; then
5081 mv -f "$nlist"T "$nlist"
5086 # Make sure that we snagged all the symbols we need.
5087 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
5088 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
5089 cat <<_LT_EOF > conftest.$ac_ext
5095 # Now generate the symbol file.
5096 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
5098 cat <<_LT_EOF >> conftest.$ac_ext
5100 /* The mapping between symbol names and symbols. */
5105 lt__PROGRAM__LTX_preloaded_symbols[[]] =
5107 { "@PROGRAM@", (void *) 0 },
5109 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
5110 cat <<\_LT_EOF >> conftest.$ac_ext
5114 /* This works around a problem in FreeBSD linker */
5115 #ifdef FREEBSD_WORKAROUND
5116 static const void *lt_preloaded_setup() {
5117 return lt__PROGRAM__LTX_preloaded_symbols;
5125 # Now try linking the two files.
5126 mv conftest.$ac_objext conftstm.$ac_objext
5127 lt_save_LIBS="$LIBS"
5128 lt_save_CFLAGS="$CFLAGS"
5129 LIBS="conftstm.$ac_objext"
5130 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5131 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5134 LIBS="$lt_save_LIBS"
5135 CFLAGS="$lt_save_CFLAGS"
5137 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5140 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5143 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5146 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5147 cat conftest.$ac_ext >&5
5149 rm -rf conftest* conftst*
5151 # Do not use the global_symbol_pipe unless it works.
5152 if test "$pipe_works" = yes; then
5155 lt_cv_sys_global_symbol_pipe=
5159 if test -z "$lt_cv_sys_global_symbol_pipe"; then
5160 lt_cv_sys_global_symbol_to_cdecl=
5162 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5163 AC_MSG_RESULT(failed)
5168 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
5169 [Take the output of nm and produce a listing of raw symbols and C names])
5170 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
5171 [Transform the output of nm in a proper C declaration])
5172 _LT_DECL([global_symbol_to_c_name_address],
5173 [lt_cv_sys_global_symbol_to_c_name_address], [1],
5174 [Transform the output of nm in a C name address pair])
5175 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
5176 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
5177 [Transform the output of nm in a C name address pair when lib prefix is needed])
5178 ]) # _LT_CMD_GLOBAL_SYMBOLS
5181 # _LT_COMPILER_PIC([TAGNAME])
5182 # ---------------------------
5183 m4_defun([_LT_COMPILER_PIC],
5184 [m4_require([_LT_TAG_COMPILER])dnl
5185 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
5186 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5187 _LT_TAGVAR(lt_prog_compiler_static, $1)=
5189 AC_MSG_CHECKING([for $compiler option to produce PIC])
5190 m4_if([$1], [CXX], [
5191 # C++ specific cases for pic, static, wl, etc.
5192 if test "$GXX" = yes; then
5193 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5194 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5198 # All AIX code is PIC.
5199 if test "$host_cpu" = ia64; then
5200 # AIX 5 now supports IA64 processor
5201 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5208 # see comment about AmigaOS4 .so support
5209 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5212 # FIXME: we need at least 68020 code to build shared libraries, but
5213 # adding the `-m68020' flag to GCC prevents building anything better,
5215 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5220 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5221 # PIC is the default for these OSes.
5223 mingw* | cygwin* | os2* | pw32* | cegcc*)
5224 # This hack is so that the source file can tell whether it is being
5225 # built for inclusion in a dll (and should export symbols for example).
5226 # Although the cygwin gcc ignores -fPIC, still need this for old-style
5227 # (--disable-auto-import) libraries
5228 m4_if([$1], [GCJ], [],
5229 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5231 darwin* | rhapsody*)
5232 # PIC is the default on this platform
5233 # Common symbols not allowed in MH_DYLIB files
5234 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5237 # DJGPP does not support shared libraries at all
5238 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5241 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5242 # Instead, we relocate shared libraries at runtime.
5245 if test -d /usr/nec; then
5246 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5250 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5251 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
5252 # sets the default TLS model and affects inlining.
5257 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5262 # QNX uses GNU C++, but need to define -shared option too, otherwise
5264 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5267 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5273 # All AIX code is PIC.
5274 if test "$host_cpu" = ia64; then
5275 # AIX 5 now supports IA64 processor
5276 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5278 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5282 case $cc_basename in
5284 # Green Hills C++ Compiler
5285 # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
5290 case $cc_basename in
5292 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5295 # Green Hills C++ Compiler
5296 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5302 freebsd* | dragonfly*)
5303 # FreeBSD uses GNU C++
5305 hpux9* | hpux10* | hpux11*)
5306 case $cc_basename in
5308 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5309 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5310 if test "$host_cpu" != ia64; then
5311 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5315 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5316 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5322 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5331 # This is c89, which is MS Visual C++ (no shared libs)
5332 # Anyone wants to do a port?
5334 irix5* | irix6* | nonstopux*)
5335 case $cc_basename in
5337 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5338 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5339 # CC pic flag -KPIC is the default.
5345 linux* | k*bsd*-gnu)
5346 case $cc_basename in
5349 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5350 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5353 # old Intel C++ for x86_64 which still supported -KPIC.
5354 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5355 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5356 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5359 # Intel C++, used to be incompatible with GCC.
5360 # ICC 10 doesn't accept -KPIC any more.
5361 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5362 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5363 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5366 # Portland Group C++ compiler
5367 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5368 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5369 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5373 # Make sure the PIC flag is empty. It appears that all Alpha
5374 # Linux and Compaq Tru64 Unix objects are PIC.
5375 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5376 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5380 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5381 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5382 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5385 case `$CC -V 2>&1 | sed 5q` in
5388 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5389 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5390 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5401 case $cc_basename in
5403 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5409 netbsd* | netbsdelf*-gnu)
5412 # QNX uses GNU C++, but need to define -shared option too, otherwise
5414 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5416 osf3* | osf4* | osf5*)
5417 case $cc_basename in
5419 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5422 # Rational C++ 2.4.1
5423 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5426 # Digital/Compaq C++
5427 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5428 # Make sure the PIC flag is empty. It appears that all Alpha
5429 # Linux and Compaq Tru64 Unix objects are PIC.
5430 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5431 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5440 case $cc_basename in
5442 # Sun C++ 4.2, 5.x and Centerline C++
5443 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5444 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5445 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5448 # Green Hills C++ Compiler
5449 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5456 case $cc_basename in
5459 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5460 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5464 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5470 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5471 case $cc_basename in
5473 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5474 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5475 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5480 case $cc_basename in
5482 # NonStop-UX NCC 3.20
5483 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5492 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5498 if test "$GCC" = yes; then
5499 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5500 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5504 # All AIX code is PIC.
5505 if test "$host_cpu" = ia64; then
5506 # AIX 5 now supports IA64 processor
5507 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5514 # see comment about AmigaOS4 .so support
5515 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5518 # FIXME: we need at least 68020 code to build shared libraries, but
5519 # adding the `-m68020' flag to GCC prevents building anything better,
5521 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5526 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5527 # PIC is the default for these OSes.
5530 mingw* | cygwin* | pw32* | os2* | cegcc*)
5531 # This hack is so that the source file can tell whether it is being
5532 # built for inclusion in a dll (and should export symbols for example).
5533 # Although the cygwin gcc ignores -fPIC, still need this for old-style
5534 # (--disable-auto-import) libraries
5535 m4_if([$1], [GCJ], [],
5536 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5539 darwin* | rhapsody*)
5540 # PIC is the default on this platform
5541 # Common symbols not allowed in MH_DYLIB files
5542 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5546 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5547 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
5548 # sets the default TLS model and affects inlining.
5554 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5560 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5561 # Instead, we relocate shared libraries at runtime.
5565 # Just because we use GCC doesn't mean we suddenly get shared libraries
5566 # on systems that don't support them.
5567 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5572 # QNX uses GNU C++, but need to define -shared option too, otherwise
5574 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5578 if test -d /usr/nec; then
5579 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5584 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5588 # PORTME Check for flag to pass linker flags through the system compiler.
5591 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5592 if test "$host_cpu" = ia64; then
5593 # AIX 5 now supports IA64 processor
5594 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5596 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5600 mingw* | cygwin* | pw32* | os2* | cegcc*)
5601 # This hack is so that the source file can tell whether it is being
5602 # built for inclusion in a dll (and should export symbols for example).
5603 m4_if([$1], [GCJ], [],
5604 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5607 hpux9* | hpux10* | hpux11*)
5608 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5609 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5616 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5619 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5620 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5623 irix5* | irix6* | nonstopux*)
5624 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5625 # PIC (with -KPIC) is the default.
5626 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5629 linux* | k*bsd*-gnu)
5630 case $cc_basename in
5631 # old Intel for x86_64 which still supported -KPIC.
5633 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5634 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5635 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5637 # icc used to be incompatible with GCC.
5638 # ICC 10 doesn't accept -KPIC any more.
5640 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5641 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5642 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5644 # Lahey Fortran 8.1.
5646 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5647 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
5648 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
5650 pgcc* | pgf77* | pgf90* | pgf95*)
5651 # Portland Group compilers (*not* the Pentium gcc compiler,
5652 # which looks to be a dead project)
5653 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5654 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5655 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5658 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5659 # All Alpha code is PIC.
5660 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5663 # IBM XL C 8.0/Fortran 10.1 on PPC
5664 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5665 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5666 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5669 case `$CC -V 2>&1 | sed 5q` in
5672 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5673 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5674 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5677 # Sun Fortran 8.3 passes all unrecognized flags to the linker
5678 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5679 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5680 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
5688 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5689 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5693 # QNX uses GNU C++, but need to define -shared option too, otherwise
5695 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5698 osf3* | osf4* | osf5*)
5699 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5700 # All OSF/1 code is PIC.
5701 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5705 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5709 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5710 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5711 case $cc_basename in
5713 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5715 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5720 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5721 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5722 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5725 sysv4 | sysv4.2uw2* | sysv4.3*)
5726 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5727 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5728 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5732 if test -d /usr/nec ;then
5733 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5734 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5738 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5739 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5740 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5741 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5745 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5746 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5750 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5751 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5755 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5761 # For platforms which do not support PIC, -DPIC is meaningless:
5763 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5766 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
5769 AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
5770 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
5771 [How to pass a linker flag through the compiler])
5774 # Check to make sure the PIC flag actually works.
5776 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5777 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
5778 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
5779 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
5780 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
5782 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5784 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
5785 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5787 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
5788 [Additional compiler flags for building library objects])
5791 # Check to make sure the static flag actually works.
5793 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
5794 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
5795 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
5796 $lt_tmp_static_flag,
5798 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
5799 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
5800 [Compiler flag to prevent dynamic linking])
5801 ])# _LT_COMPILER_PIC
5804 # _LT_LINKER_SHLIBS([TAGNAME])
5805 # ----------------------------
5806 # See if the linker supports building shared libraries.
5807 m4_defun([_LT_LINKER_SHLIBS],
5808 [AC_REQUIRE([LT_PATH_LD])dnl
5809 AC_REQUIRE([LT_PATH_NM])dnl
5810 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5811 m4_require([_LT_DECL_EGREP])dnl
5812 m4_require([_LT_DECL_SED])dnl
5813 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
5814 m4_require([_LT_TAG_COMPILER])dnl
5815 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5816 m4_if([$1], [CXX], [
5817 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5820 # If we're using GNU nm, then we don't want the "-C" option.
5821 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5822 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5823 _LT_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'
5825 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5829 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5831 cygwin* | mingw* | cegcc*)
5832 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
5834 linux* | k*bsd*-gnu)
5835 _LT_TAGVAR(link_all_deplibs, $1)=no
5838 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5841 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5844 _LT_TAGVAR(allow_undefined_flag, $1)=
5845 _LT_TAGVAR(always_export_symbols, $1)=no
5846 _LT_TAGVAR(archive_cmds, $1)=
5847 _LT_TAGVAR(archive_expsym_cmds, $1)=
5848 _LT_TAGVAR(compiler_needs_object, $1)=no
5849 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5850 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5851 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5852 _LT_TAGVAR(hardcode_automatic, $1)=no
5853 _LT_TAGVAR(hardcode_direct, $1)=no
5854 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5855 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5856 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5857 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5858 _LT_TAGVAR(hardcode_minus_L, $1)=no
5859 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5860 _LT_TAGVAR(inherit_rpath, $1)=no
5861 _LT_TAGVAR(link_all_deplibs, $1)=unknown
5862 _LT_TAGVAR(module_cmds, $1)=
5863 _LT_TAGVAR(module_expsym_cmds, $1)=
5864 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
5865 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5866 _LT_TAGVAR(thread_safe_flag_spec, $1)=
5867 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5868 # include_expsyms should be a list of space-separated symbols to be *always*
5869 # included in the symbol list
5870 _LT_TAGVAR(include_expsyms, $1)=
5871 # exclude_expsyms can be an extended regexp of symbols to exclude
5872 # it will be wrapped by ` (' and `)$', so one must not match beginning or
5873 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5874 # as well as any symbol that contains `d'.
5875 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5876 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5877 # platforms (ab)use it in PIC code, but their linkers get confused if
5878 # the symbol is explicitly referenced. Since portable code cannot
5879 # rely on this symbol name, it's probably fine to never include it in
5880 # preloaded symbol tables.
5881 # Exclude shared library initialization/finalization symbols.
5882 dnl Note also adjust exclude_expsyms for C++ above.
5883 extract_expsyms_cmds=
5886 cygwin* | mingw* | pw32* | cegcc*)
5887 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5888 # When not using gcc, we currently assume that we are using
5889 # Microsoft Visual C++.
5890 if test "$GCC" != yes; then
5895 # we just hope/assume this is gcc and not c89 (= MSVC++)
5901 linux* | k*bsd*-gnu)
5902 _LT_TAGVAR(link_all_deplibs, $1)=no
5906 _LT_TAGVAR(ld_shlibs, $1)=yes
5907 if test "$with_gnu_ld" = yes; then
5908 # If archive_cmds runs LD, not CC, wlarc should be empty
5911 # Set some defaults for GNU ld with shared library support. These
5912 # are reset later if shared libraries are not supported. Putting them
5913 # here allows them to be overridden if necessary.
5914 runpath_var=LD_RUN_PATH
5915 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5916 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5917 # ancient GNU ld didn't support --whole-archive et. al.
5918 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
5919 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5921 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5923 supports_anon_versioning=no
5924 case `$LD -v 2>&1` in
5925 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5926 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5927 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5928 *\ 2.11.*) ;; # other 2.11 versions
5929 *) supports_anon_versioning=yes ;;
5932 # See if GNU ld supports shared libraries.
5935 # On AIX/PPC, the GNU linker is very broken
5936 if test "$host_cpu" != ia64; then
5937 _LT_TAGVAR(ld_shlibs, $1)=no
5940 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
5941 *** to be unable to reliably create shared libraries on AIX.
5942 *** Therefore, libtool is disabling shared libraries support. If you
5943 *** really care for shared libraries, you may want to modify your PATH
5944 *** so that a non-GNU linker is found, and then restart.
5953 # see comment about AmigaOS4 .so support
5954 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5955 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5958 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
5959 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5960 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5966 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5967 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5968 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5969 # support --undefined. This deserves some investigation. FIXME
5970 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5972 _LT_TAGVAR(ld_shlibs, $1)=no
5976 cygwin* | mingw* | pw32* | cegcc*)
5977 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5978 # as there is no search path for DLLs.
5979 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5980 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5981 _LT_TAGVAR(always_export_symbols, $1)=no
5982 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5983 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
5985 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5986 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5987 # If the export-symbols file already is a .def file (1st line
5988 # is EXPORTS), use it as is; otherwise, prepend...
5989 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5990 cp $export_symbols $output_objdir/$soname.def;
5992 echo EXPORTS > $output_objdir/$soname.def;
5993 cat $export_symbols >> $output_objdir/$soname.def;
5995 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5997 _LT_TAGVAR(ld_shlibs, $1)=no
6002 _LT_TAGVAR(hardcode_direct, $1)=no
6003 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6004 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6005 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6006 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6007 # Instead, shared libraries are loaded at an image base (0x10000000 by
6008 # default) and relocated if they conflict, which is a slow very memory
6009 # consuming and fragmenting process. To avoid this, we pick a random,
6010 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6011 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6012 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6013 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6016 gnu* | linux* | tpf* | k*bsd*-gnu)
6018 if test "$host_os" = linux-dietlibc; then
6019 case $cc_basename in
6020 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
6023 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
6024 && test "$tmp_diet" = no
6027 tmp_sharedflag='-shared'
6028 case $cc_basename,$host_cpu in
6029 pgcc*) # Portland Group C compiler
6030 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6031 tmp_addflag=' $pic_flag'
6033 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
6034 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6035 tmp_addflag=' $pic_flag -Mnomain' ;;
6036 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
6037 tmp_addflag=' -i_dynamic' ;;
6038 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
6039 tmp_addflag=' -i_dynamic -nofor_main' ;;
6040 ifc* | ifort*) # Intel Fortran compiler
6041 tmp_addflag=' -nofor_main' ;;
6042 lf95*) # Lahey Fortran 8.1
6043 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6044 tmp_sharedflag='--shared' ;;
6045 xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
6046 tmp_sharedflag='-qmkshrobj'
6049 case `$CC -V 2>&1 | sed 5q` in
6050 *Sun\ C*) # Sun C 5.9
6051 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6052 _LT_TAGVAR(compiler_needs_object, $1)=yes
6053 tmp_sharedflag='-G' ;;
6054 *Sun\ F*) # Sun Fortran 8.3
6055 tmp_sharedflag='-G' ;;
6057 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6059 if test "x$supports_anon_versioning" = xyes; then
6060 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6061 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6062 echo "local: *; };" >> $output_objdir/$libname.ver~
6063 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6066 case $cc_basename in
6068 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
6069 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
6070 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6071 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6072 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
6073 if test "x$supports_anon_versioning" = xyes; then
6074 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6075 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6076 echo "local: *; };" >> $output_objdir/$libname.ver~
6077 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
6082 _LT_TAGVAR(ld_shlibs, $1)=no
6086 netbsd* | netbsdelf*-gnu)
6087 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6088 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6091 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6092 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6097 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
6098 _LT_TAGVAR(ld_shlibs, $1)=no
6101 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
6102 *** create shared libraries on Solaris systems. Therefore, libtool
6103 *** is disabling shared libraries support. We urge you to upgrade GNU
6104 *** binutils to release 2.9.1 or newer. Another option is to modify
6105 *** your PATH or compiler configuration so that the native linker is
6106 *** used, and then restart.
6109 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6110 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6111 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6113 _LT_TAGVAR(ld_shlibs, $1)=no
6117 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
6118 case `$LD -v 2>&1` in
6119 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
6120 _LT_TAGVAR(ld_shlibs, $1)=no
6123 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
6124 *** reliably create shared libraries on SCO systems. Therefore, libtool
6125 *** is disabling shared libraries support. We urge you to upgrade GNU
6126 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
6127 *** your PATH or compiler configuration so that the native linker is
6128 *** used, and then restart.
6133 # For security reasons, it is highly recommended that you always
6134 # use absolute paths for naming shared libraries, and exclude the
6135 # DT_RUNPATH tag from executables and libraries. But doing so
6136 # requires that you compile everything twice, which is a pain.
6137 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6138 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6139 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6140 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6142 _LT_TAGVAR(ld_shlibs, $1)=no
6149 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6151 _LT_TAGVAR(hardcode_direct, $1)=yes
6152 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6156 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6157 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6158 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6160 _LT_TAGVAR(ld_shlibs, $1)=no
6165 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
6167 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6168 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
6169 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6172 # PORTME fill in a description of your system's linker (not GNU ld)
6175 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6176 _LT_TAGVAR(always_export_symbols, $1)=yes
6177 _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
6178 # Note: this linker hardcodes the directories in LIBPATH if there
6179 # are no directories specified by -L.
6180 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6181 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
6182 # Neither direct hardcoding nor static linking is supported with a
6184 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6189 if test "$host_cpu" = ia64; then
6190 # On IA64, the linker does run time linking by default, so we don't
6191 # have to do anything special.
6192 aix_use_runtimelinking=no
6193 exp_sym_flag='-Bexport'
6196 # If we're using GNU nm, then we don't want the "-C" option.
6197 # -C means demangle to AIX nm, but means don't demangle with GNU nm
6198 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
6199 _LT_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'
6201 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
6203 aix_use_runtimelinking=no
6205 # Test if we are trying to use run time linking or normal
6206 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6207 # need to do runtime linking.
6208 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6209 for ld_flag in $LDFLAGS; do
6210 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6211 aix_use_runtimelinking=yes
6218 exp_sym_flag='-bexport'
6219 no_entry_flag='-bnoentry'
6222 # When large executables or shared objects are built, AIX ld can
6223 # have problems creating the table of contents. If linking a library
6224 # or program results in "error TOC overflow" add -mminimal-toc to
6225 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6226 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6228 _LT_TAGVAR(archive_cmds, $1)=''
6229 _LT_TAGVAR(hardcode_direct, $1)=yes
6230 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6231 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6232 _LT_TAGVAR(link_all_deplibs, $1)=yes
6233 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6235 if test "$GCC" = yes; then
6236 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6237 # We only want to do this on AIX 4.2 and lower, the check
6238 # below for broken collect2 doesn't work under 4.3+
6239 collect2name=`${CC} -print-prog-name=collect2`
6240 if test -f "$collect2name" &&
6241 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6243 # We have reworked collect2
6246 # We have old collect2
6247 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6248 # It fails to find uninstalled libraries when the uninstalled
6249 # path is not listed in the libpath. Setting hardcode_minus_L
6250 # to unsupported forces relinking
6251 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6252 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6253 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6257 shared_flag='-shared'
6258 if test "$aix_use_runtimelinking" = yes; then
6259 shared_flag="$shared_flag "'${wl}-G'
6261 _LT_TAGVAR(link_all_deplibs, $1)=no
6264 if test "$host_cpu" = ia64; then
6265 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6266 # chokes on -Wl,-G. The following line is correct:
6269 if test "$aix_use_runtimelinking" = yes; then
6270 shared_flag='${wl}-G'
6272 shared_flag='${wl}-bM:SRE'
6277 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6278 # It seems that -bexpall does not export symbols beginning with
6279 # underscore (_), so it is better to generate a list of symbols to export.
6280 _LT_TAGVAR(always_export_symbols, $1)=yes
6281 if test "$aix_use_runtimelinking" = yes; then
6282 # Warning - without using the other runtime loading flags (-brtl),
6283 # -berok will link without error, but may produce a broken library.
6284 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6285 # Determine the default libpath from the value encoded in an
6287 _LT_SYS_MODULE_PATH_AIX
6288 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6289 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6291 if test "$host_cpu" = ia64; then
6292 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6293 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6294 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
6296 # Determine the default libpath from the value encoded in an
6298 _LT_SYS_MODULE_PATH_AIX
6299 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6300 # Warning - without using the other run time loading flags,
6301 # -berok will link without error, but may produce a broken library.
6302 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6303 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6304 # Exported symbols can be pulled into shared objects from archives
6305 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6306 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6307 # This is similar to how AIX traditionally builds its shared libraries.
6308 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6316 # see comment about AmigaOS4 .so support
6317 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6318 _LT_TAGVAR(archive_expsym_cmds, $1)=''
6321 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
6322 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6323 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6329 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6332 cygwin* | mingw* | pw32* | cegcc*)
6333 # When not using gcc, we currently assume that we are using
6334 # Microsoft Visual C++.
6335 # hardcode_libdir_flag_spec is actually meaningless, as there is
6336 # no search path for DLLs.
6337 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6338 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6339 # Tell ltmain to make .lib files, not .a files.
6341 # Tell ltmain to make .dll files, not .so files.
6343 # FIXME: Setting linknames here is a bad hack.
6344 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
6345 # The linker will automatically build a .lib file if we build a DLL.
6346 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6347 # FIXME: Should let the user specify the lib program.
6348 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6349 _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
6350 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6353 darwin* | rhapsody*)
6354 _LT_DARWIN_LINKER_FEATURES($1)
6358 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6359 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6360 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6364 _LT_TAGVAR(ld_shlibs, $1)=no
6367 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6368 # support. Future versions do this automatically, but an explicit c++rt0.o
6369 # does not break anything, and helps significantly (at the cost of a little
6372 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6373 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6374 _LT_TAGVAR(hardcode_direct, $1)=yes
6375 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6378 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6380 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6381 _LT_TAGVAR(hardcode_direct, $1)=yes
6382 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6383 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6386 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6387 freebsd* | dragonfly*)
6388 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
6389 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6390 _LT_TAGVAR(hardcode_direct, $1)=yes
6391 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6395 if test "$GCC" = yes; then
6396 _LT_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'
6398 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6400 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6401 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6402 _LT_TAGVAR(hardcode_direct, $1)=yes
6404 # hardcode_minus_L: Not really in the search PATH,
6405 # but as the default location of the library.
6406 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6407 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6411 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6412 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6414 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6416 if test "$with_gnu_ld" = no; then
6417 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6418 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
6419 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6420 _LT_TAGVAR(hardcode_direct, $1)=yes
6421 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6422 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6423 # hardcode_minus_L: Not really in the search PATH,
6424 # but as the default location of the library.
6425 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6430 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6433 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6436 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6439 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6445 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6448 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6451 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6455 if test "$with_gnu_ld" = no; then
6456 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6457 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6461 _LT_TAGVAR(hardcode_direct, $1)=no
6462 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6465 _LT_TAGVAR(hardcode_direct, $1)=yes
6466 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6467 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6469 # hardcode_minus_L: Not really in the search PATH,
6470 # but as the default location of the library.
6471 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6477 irix5* | irix6* | nonstopux*)
6478 if test "$GCC" = yes; then
6479 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6480 # Try to use the -exported_symbol ld option, if it does not
6481 # work, assume that -exports_file does not work either and
6482 # implicitly export all symbols.
6483 save_LDFLAGS="$LDFLAGS"
6484 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
6485 AC_LINK_IFELSE(int foo(void) {},
6486 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
6488 LDFLAGS="$save_LDFLAGS"
6490 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6491 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
6493 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6494 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6495 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6496 _LT_TAGVAR(inherit_rpath, $1)=yes
6497 _LT_TAGVAR(link_all_deplibs, $1)=yes
6500 netbsd* | netbsdelf*-gnu)
6501 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6502 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6504 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6506 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6507 _LT_TAGVAR(hardcode_direct, $1)=yes
6508 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6512 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6513 _LT_TAGVAR(hardcode_direct, $1)=yes
6514 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6515 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6516 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6523 if test -f /usr/libexec/ld.so; then
6524 _LT_TAGVAR(hardcode_direct, $1)=yes
6525 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6526 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6527 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6528 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6529 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6530 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6531 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6534 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6535 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6536 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6539 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6540 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6545 _LT_TAGVAR(ld_shlibs, $1)=no
6550 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6551 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6552 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6553 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
6554 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6558 if test "$GCC" = yes; then
6559 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6560 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6562 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6563 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6565 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6566 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6567 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6570 osf4* | osf5*) # as osf3* with the addition of -msym flag
6571 if test "$GCC" = yes; then
6572 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6573 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6574 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6576 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6577 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6578 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
6579 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
6581 # Both c and cxx compiler support -rpath directly
6582 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6584 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6585 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6589 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
6590 if test "$GCC" = yes; then
6592 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6593 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6594 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6596 case `$CC -V 2>&1` in
6599 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6600 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6601 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
6605 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
6606 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6607 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6611 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6612 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6614 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6616 # The compiler driver will combine and reorder linker options,
6617 # but understands `-z linker_flag'. GCC discards it without `$wl',
6618 # but is careful enough not to reorder.
6619 # Supported since Solaris 2.6 (maybe 2.5.1?)
6620 if test "$GCC" = yes; then
6621 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6623 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6627 _LT_TAGVAR(link_all_deplibs, $1)=yes
6631 if test "x$host_vendor" = xsequent; then
6632 # Use $CC to link under sequent, because it throws in some extra .o
6633 # files that make .init and .fini sections work.
6634 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6636 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6638 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6639 _LT_TAGVAR(hardcode_direct, $1)=yes
6640 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6641 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6645 case $host_vendor in
6647 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6648 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6651 ## LD is ld it makes a PLAMLIB
6652 ## CC just makes a GrossModule.
6653 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6654 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6655 _LT_TAGVAR(hardcode_direct, $1)=no
6658 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6659 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6662 runpath_var='LD_RUN_PATH'
6663 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6667 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6668 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6669 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6673 if test -d /usr/nec; then
6674 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6675 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6676 runpath_var=LD_RUN_PATH
6677 hardcode_runpath_var=yes
6678 _LT_TAGVAR(ld_shlibs, $1)=yes
6682 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6683 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6684 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6685 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6686 runpath_var='LD_RUN_PATH'
6688 if test "$GCC" = yes; then
6689 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6690 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6692 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6693 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6697 sysv5* | sco3.2v5* | sco5v6*)
6698 # Note: We can NOT use -z defs as we might desire, because we do not
6699 # link with -lc, and that would cause any symbols used from libc to
6700 # always be unresolved, which means just about no library would
6701 # ever link correctly. If we're not using GNU ld we use -z text
6702 # though, which does catch some bad symbols but isn't as heavy-handed
6704 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6705 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6706 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6707 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6708 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6709 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6710 _LT_TAGVAR(link_all_deplibs, $1)=yes
6711 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6712 runpath_var='LD_RUN_PATH'
6714 if test "$GCC" = yes; then
6715 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6716 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6718 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6719 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6724 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6725 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6726 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6730 _LT_TAGVAR(ld_shlibs, $1)=no
6734 if test x$host_vendor = xsni; then
6736 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6737 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
6743 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6744 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6746 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
6748 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
6749 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
6750 _LT_DECL([], [extract_expsyms_cmds], [2],
6751 [The commands to extract the exported symbol list from a shared archive])
6754 # Do we need to explicitly link libc?
6756 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
6758 # Assume -lc should be added
6759 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6761 if test "$enable_shared" = yes && test "$GCC" = yes; then
6762 case $_LT_TAGVAR(archive_cmds, $1) in
6764 # FIXME: we may have to deal with multi-command sequences.
6767 # Test whether the compiler implicitly links with -lc since on some
6768 # systems, -lgcc has to come before -lc. If gcc already passes -lc
6769 # to ld, don't add -lc before -lgcc.
6770 AC_MSG_CHECKING([whether -lc should be explicitly linked in])
6772 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6774 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6777 libobjs=conftest.$ac_objext
6779 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
6780 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
6786 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
6787 _LT_TAGVAR(allow_undefined_flag, $1)=
6788 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
6790 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6792 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6794 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6796 cat conftest.err 1>&5
6799 AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
6806 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
6807 [Whether or not to add -lc for building shared libraries])
6808 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
6809 [enable_shared_with_static_runtimes], [0],
6810 [Whether or not to disallow shared libs when runtime libs are static])
6811 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
6812 [Compiler flag to allow reflexive dlopens])
6813 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
6814 [Compiler flag to generate shared objects directly from archives])
6815 _LT_TAGDECL([], [compiler_needs_object], [1],
6816 [Whether the compiler copes with passing no objects directly])
6817 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
6818 [Create an old-style archive from a shared archive])
6819 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
6820 [Create a temporary old-style archive to link instead of a shared archive])
6821 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
6822 _LT_TAGDECL([], [archive_expsym_cmds], [2])
6823 _LT_TAGDECL([], [module_cmds], [2],
6824 [Commands used to build a loadable module if different from building
6826 _LT_TAGDECL([], [module_expsym_cmds], [2])
6827 _LT_TAGDECL([], [with_gnu_ld], [1],
6828 [Whether we are building with GNU ld or not])
6829 _LT_TAGDECL([], [allow_undefined_flag], [1],
6830 [Flag that allows shared libraries with undefined symbols to be built])
6831 _LT_TAGDECL([], [no_undefined_flag], [1],
6832 [Flag that enforces no undefined symbols])
6833 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
6834 [Flag to hardcode $libdir into a binary during linking.
6835 This must work even if $libdir does not exist])
6836 _LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
6837 [[If ld is used when linking, flag to hardcode $libdir into a binary
6838 during linking. This must work even if $libdir does not exist]])
6839 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
6840 [Whether we need a single "-rpath" flag with a separated argument])
6841 _LT_TAGDECL([], [hardcode_direct], [0],
6842 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6843 DIR into the resulting binary])
6844 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
6845 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6846 DIR into the resulting binary and the resulting library dependency is
6847 "absolute", i.e impossible to change by setting ${shlibpath_var} if the
6848 library is relocated])
6849 _LT_TAGDECL([], [hardcode_minus_L], [0],
6850 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
6851 into the resulting binary])
6852 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
6853 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
6854 into the resulting binary])
6855 _LT_TAGDECL([], [hardcode_automatic], [0],
6856 [Set to "yes" if building a shared library automatically hardcodes DIR
6857 into the library and all subsequent libraries and executables linked
6859 _LT_TAGDECL([], [inherit_rpath], [0],
6860 [Set to yes if linker adds runtime paths of dependent libraries
6861 to runtime path list])
6862 _LT_TAGDECL([], [link_all_deplibs], [0],
6863 [Whether libtool must link a program against all its dependency libraries])
6864 _LT_TAGDECL([], [fix_srcfile_path], [1],
6865 [Fix the shell variable $srcfile for the compiler])
6866 _LT_TAGDECL([], [always_export_symbols], [0],
6867 [Set to "yes" if exported symbols are required])
6868 _LT_TAGDECL([], [export_symbols_cmds], [2],
6869 [The commands to list exported symbols])
6870 _LT_TAGDECL([], [exclude_expsyms], [1],
6871 [Symbols that should not be listed in the preloaded symbols])
6872 _LT_TAGDECL([], [include_expsyms], [1],
6873 [Symbols that must always be exported])
6874 _LT_TAGDECL([], [prelink_cmds], [2],
6875 [Commands necessary for linking programs (against libraries) with templates])
6876 _LT_TAGDECL([], [file_list_spec], [1],
6877 [Specify filename containing input files])
6878 dnl FIXME: Not yet implemented
6879 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
6880 dnl [Compiler flag to generate thread safe objects])
6881 ])# _LT_LINKER_SHLIBS
6884 # _LT_LANG_C_CONFIG([TAG])
6885 # ------------------------
6886 # Ensure that the configuration variables for a C compiler are suitably
6887 # defined. These variables are subsequently used by _LT_CONFIG to write
6888 # the compiler configuration to `libtool'.
6889 m4_defun([_LT_LANG_C_CONFIG],
6890 [m4_require([_LT_DECL_EGREP])dnl
6894 # Source file extension for C test sources.
6897 # Object file extension for compiled C test sources.
6899 _LT_TAGVAR(objext, $1)=$objext
6901 # Code to be used in simple compile tests
6902 lt_simple_compile_test_code="int some_variable = 0;"
6904 # Code to be used in simple link tests
6905 lt_simple_link_test_code='int main(){return(0);}'
6908 # Save the default compiler, since it gets overwritten when the other
6909 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
6910 compiler_DEFAULT=$CC
6912 # save warnings/boilerplate of simple test code
6913 _LT_COMPILER_BOILERPLATE
6914 _LT_LINKER_BOILERPLATE
6916 if test -n "$compiler"; then
6917 _LT_COMPILER_NO_RTTI($1)
6918 _LT_COMPILER_PIC($1)
6919 _LT_COMPILER_C_O($1)
6920 _LT_COMPILER_FILE_LOCKS($1)
6921 _LT_LINKER_SHLIBS($1)
6922 _LT_SYS_DYNAMIC_LINKER($1)
6923 _LT_LINKER_HARDCODE_LIBPATH($1)
6927 # Report which library types will actually be built
6928 AC_MSG_CHECKING([if libtool supports shared libraries])
6929 AC_MSG_RESULT([$can_build_shared])
6931 AC_MSG_CHECKING([whether to build shared libraries])
6932 test "$can_build_shared" = "no" && enable_shared=no
6934 # On AIX, shared libraries and static libraries use the same namespace, and
6935 # are all built from PIC.
6938 test "$enable_shared" = yes && enable_static=no
6939 if test -n "$RANLIB"; then
6940 archive_cmds="$archive_cmds~\$RANLIB \$lib"
6941 postinstall_cmds='$RANLIB $lib'
6946 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
6947 test "$enable_shared" = yes && enable_static=no
6951 AC_MSG_RESULT([$enable_shared])
6953 AC_MSG_CHECKING([whether to build static libraries])
6954 # Make sure either enable_shared or enable_static is yes.
6955 test "$enable_shared" = yes || enable_static=yes
6956 AC_MSG_RESULT([$enable_static])
6962 ])# _LT_LANG_C_CONFIG
6967 # Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
6968 # compiler, we have our own version here.
6969 m4_defun([_LT_PROG_CXX],
6971 pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
6973 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
6974 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
6975 (test "X$CXX" != "Xg++"))) ; then
6978 _lt_caught_CXX_error=yes
6980 popdef([AC_MSG_ERROR])
6983 dnl aclocal-1.4 backwards compatibility:
6984 dnl AC_DEFUN([_LT_PROG_CXX], [])
6987 # _LT_LANG_CXX_CONFIG([TAG])
6988 # --------------------------
6989 # Ensure that the configuration variables for a C++ compiler are suitably
6990 # defined. These variables are subsequently used by _LT_CONFIG to write
6991 # the compiler configuration to `libtool'.
6992 m4_defun([_LT_LANG_CXX_CONFIG],
6993 [AC_REQUIRE([_LT_PROG_CXX])dnl
6994 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6995 m4_require([_LT_DECL_EGREP])dnl
6998 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6999 _LT_TAGVAR(allow_undefined_flag, $1)=
7000 _LT_TAGVAR(always_export_symbols, $1)=no
7001 _LT_TAGVAR(archive_expsym_cmds, $1)=
7002 _LT_TAGVAR(compiler_needs_object, $1)=no
7003 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7004 _LT_TAGVAR(hardcode_direct, $1)=no
7005 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7006 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7007 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
7008 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7009 _LT_TAGVAR(hardcode_minus_L, $1)=no
7010 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
7011 _LT_TAGVAR(hardcode_automatic, $1)=no
7012 _LT_TAGVAR(inherit_rpath, $1)=no
7013 _LT_TAGVAR(module_cmds, $1)=
7014 _LT_TAGVAR(module_expsym_cmds, $1)=
7015 _LT_TAGVAR(link_all_deplibs, $1)=unknown
7016 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7017 _LT_TAGVAR(no_undefined_flag, $1)=
7018 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7019 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7021 # Source file extension for C++ test sources.
7024 # Object file extension for compiled C++ test sources.
7026 _LT_TAGVAR(objext, $1)=$objext
7028 # No sense in running all these tests if we already determined that
7029 # the CXX compiler isn't working. Some variables (like enable_shared)
7030 # are currently assumed to apply to all compilers on this platform,
7031 # and will be corrupted by setting them based on a non-working compiler.
7032 if test "$_lt_caught_CXX_error" != yes; then
7033 # Code to be used in simple compile tests
7034 lt_simple_compile_test_code="int some_variable = 0;"
7036 # Code to be used in simple link tests
7037 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
7039 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7042 # save warnings/boilerplate of simple test code
7043 _LT_COMPILER_BOILERPLATE
7044 _LT_LINKER_BOILERPLATE
7046 # Allow CC to be a program name with arguments.
7051 lt_save_with_gnu_ld=$with_gnu_ld
7052 lt_save_path_LD=$lt_cv_path_LD
7053 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
7054 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
7056 $as_unset lt_cv_prog_gnu_ld
7058 if test -n "${lt_cv_path_LDCXX+set}"; then
7059 lt_cv_path_LD=$lt_cv_path_LDCXX
7061 $as_unset lt_cv_path_LD
7063 test -z "${LDCXX+set}" || LD=$LDCXX
7066 _LT_TAGVAR(compiler, $1)=$CC
7067 _LT_CC_BASENAME([$compiler])
7069 if test -n "$compiler"; then
7070 # We don't want -fno-exception when compiling C++ code, so set the
7071 # no_builtin_flag separately
7072 if test "$GXX" = yes; then
7073 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
7075 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
7078 if test "$GXX" = yes; then
7079 # Set up default GNU C++ configuration
7083 # Check if GNU C++ uses GNU ld as the underlying linker, since the
7084 # archiving commands below assume that GNU ld is being used.
7085 if test "$with_gnu_ld" = yes; then
7086 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7087 _LT_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'
7089 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7090 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7092 # If archive_cmds runs LD, not CC, wlarc should be empty
7093 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
7094 # investigate it a little bit more. (MM)
7097 # ancient GNU ld didn't support --whole-archive et. al.
7098 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
7099 $GREP 'no-whole-archive' > /dev/null; then
7100 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7102 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7108 # A generic and very simple default shared library creation
7109 # command for GNU C++ for the case where it uses the native
7110 # linker, instead of GNU ld. If possible, this setting should
7111 # overridden to take advantage of the native linker features on
7112 # the platform it is being used on.
7113 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7116 # Commands to make compiler produce verbose output that lists
7117 # what "hidden" libraries, object files and flags are used when
7118 # linking a shared library.
7119 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
7127 # PORTME: fill in a description of your system's C++ link characteristics
7128 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
7129 _LT_TAGVAR(ld_shlibs, $1)=yes
7132 # FIXME: insert proper C++ library support
7133 _LT_TAGVAR(ld_shlibs, $1)=no
7136 if test "$host_cpu" = ia64; then
7137 # On IA64, the linker does run time linking by default, so we don't
7138 # have to do anything special.
7139 aix_use_runtimelinking=no
7140 exp_sym_flag='-Bexport'
7143 aix_use_runtimelinking=no
7145 # Test if we are trying to use run time linking or normal
7146 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
7147 # need to do runtime linking.
7148 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
7149 for ld_flag in $LDFLAGS; do
7152 aix_use_runtimelinking=yes
7160 exp_sym_flag='-bexport'
7161 no_entry_flag='-bnoentry'
7164 # When large executables or shared objects are built, AIX ld can
7165 # have problems creating the table of contents. If linking a library
7166 # or program results in "error TOC overflow" add -mminimal-toc to
7167 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
7168 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
7170 _LT_TAGVAR(archive_cmds, $1)=''
7171 _LT_TAGVAR(hardcode_direct, $1)=yes
7172 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7173 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7174 _LT_TAGVAR(link_all_deplibs, $1)=yes
7175 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
7177 if test "$GXX" = yes; then
7178 case $host_os in aix4.[[012]]|aix4.[[012]].*)
7179 # We only want to do this on AIX 4.2 and lower, the check
7180 # below for broken collect2 doesn't work under 4.3+
7181 collect2name=`${CC} -print-prog-name=collect2`
7182 if test -f "$collect2name" &&
7183 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
7185 # We have reworked collect2
7188 # We have old collect2
7189 _LT_TAGVAR(hardcode_direct, $1)=unsupported
7190 # It fails to find uninstalled libraries when the uninstalled
7191 # path is not listed in the libpath. Setting hardcode_minus_L
7192 # to unsupported forces relinking
7193 _LT_TAGVAR(hardcode_minus_L, $1)=yes
7194 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7195 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7198 shared_flag='-shared'
7199 if test "$aix_use_runtimelinking" = yes; then
7200 shared_flag="$shared_flag "'${wl}-G'
7204 if test "$host_cpu" = ia64; then
7205 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
7206 # chokes on -Wl,-G. The following line is correct:
7209 if test "$aix_use_runtimelinking" = yes; then
7210 shared_flag='${wl}-G'
7212 shared_flag='${wl}-bM:SRE'
7217 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
7218 # It seems that -bexpall does not export symbols beginning with
7219 # underscore (_), so it is better to generate a list of symbols to
7221 _LT_TAGVAR(always_export_symbols, $1)=yes
7222 if test "$aix_use_runtimelinking" = yes; then
7223 # Warning - without using the other runtime loading flags (-brtl),
7224 # -berok will link without error, but may produce a broken library.
7225 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
7226 # Determine the default libpath from the value encoded in an empty
7228 _LT_SYS_MODULE_PATH_AIX
7229 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7231 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
7233 if test "$host_cpu" = ia64; then
7234 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
7235 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7236 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
7238 # Determine the default libpath from the value encoded in an
7240 _LT_SYS_MODULE_PATH_AIX
7241 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7242 # Warning - without using the other run time loading flags,
7243 # -berok will link without error, but may produce a broken library.
7244 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
7245 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
7246 # Exported symbols can be pulled into shared objects from archives
7247 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
7248 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
7249 # This is similar to how AIX traditionally builds its shared
7251 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
7257 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7258 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7259 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
7260 # support --undefined. This deserves some investigation. FIXME
7261 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7263 _LT_TAGVAR(ld_shlibs, $1)=no
7268 case $cc_basename in
7270 # FIXME: insert proper C++ library support
7271 _LT_TAGVAR(ld_shlibs, $1)=no
7276 cygwin* | mingw* | pw32* | cegcc*)
7277 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
7278 # as there is no search path for DLLs.
7279 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7280 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7281 _LT_TAGVAR(always_export_symbols, $1)=no
7282 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7284 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7285 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
7286 # If the export-symbols file already is a .def file (1st line
7287 # is EXPORTS), use it as is; otherwise, prepend...
7288 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7289 cp $export_symbols $output_objdir/$soname.def;
7291 echo EXPORTS > $output_objdir/$soname.def;
7292 cat $export_symbols >> $output_objdir/$soname.def;
7294 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
7296 _LT_TAGVAR(ld_shlibs, $1)=no
7299 darwin* | rhapsody*)
7300 _LT_DARWIN_LINKER_FEATURES($1)
7304 case $cc_basename in
7306 # FIXME: insert proper C++ library support
7307 _LT_TAGVAR(ld_shlibs, $1)=no
7310 # Green Hills C++ Compiler
7311 # FIXME: insert proper C++ library support
7312 _LT_TAGVAR(ld_shlibs, $1)=no
7315 # FIXME: insert proper C++ library support
7316 _LT_TAGVAR(ld_shlibs, $1)=no
7322 # C++ shared libraries reported to be fairly broken before
7324 _LT_TAGVAR(ld_shlibs, $1)=no
7328 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7331 freebsd* | dragonfly*)
7332 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
7334 _LT_TAGVAR(ld_shlibs, $1)=yes
7341 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7342 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7343 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7344 _LT_TAGVAR(hardcode_direct, $1)=yes
7345 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7346 # but as the default
7347 # location of the library.
7349 case $cc_basename in
7351 # FIXME: insert proper C++ library support
7352 _LT_TAGVAR(ld_shlibs, $1)=no
7355 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
7356 # Commands to make compiler produce verbose output that lists
7357 # what "hidden" libraries, object files and flags are used when
7358 # linking a shared library.
7360 # There doesn't appear to be a way to prevent this compiler from
7361 # explicitly linking system object files so we need to strip them
7362 # from the output so that they don't get included in the library
7364 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
7367 if test "$GXX" = yes; then
7368 _LT_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'
7370 # FIXME: insert proper C++ library support
7371 _LT_TAGVAR(ld_shlibs, $1)=no
7378 if test $with_gnu_ld = no; then
7379 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7380 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7386 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7392 _LT_TAGVAR(hardcode_direct, $1)=no
7393 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7396 _LT_TAGVAR(hardcode_direct, $1)=yes
7397 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7398 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7399 # but as the default
7400 # location of the library.
7404 case $cc_basename in
7406 # FIXME: insert proper C++ library support
7407 _LT_TAGVAR(ld_shlibs, $1)=no
7412 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7415 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7418 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7421 # Commands to make compiler produce verbose output that lists
7422 # what "hidden" libraries, object files and flags are used when
7423 # linking a shared library.
7425 # There doesn't appear to be a way to prevent this compiler from
7426 # explicitly linking system object files so we need to strip them
7427 # from the output so that they don't get included in the library
7429 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 "X$list" | $Xsed'
7432 if test "$GXX" = yes; then
7433 if test $with_gnu_ld = no; then
7436 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7439 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7442 _LT_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'
7447 # FIXME: insert proper C++ library support
7448 _LT_TAGVAR(ld_shlibs, $1)=no
7455 _LT_TAGVAR(hardcode_direct, $1)=no
7456 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7457 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7458 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7459 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
7460 # Instead, shared libraries are loaded at an image base (0x10000000 by
7461 # default) and relocated if they conflict, which is a slow very memory
7462 # consuming and fragmenting process. To avoid this, we pick a random,
7463 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
7464 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
7465 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
7466 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
7469 case $cc_basename in
7472 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
7474 # Archives containing C++ object files must be created using
7475 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
7476 # necessary to make sure instantiated templates are included
7478 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
7481 if test "$GXX" = yes; then
7482 if test "$with_gnu_ld" = no; then
7483 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7485 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
7488 _LT_TAGVAR(link_all_deplibs, $1)=yes
7491 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7492 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7493 _LT_TAGVAR(inherit_rpath, $1)=yes
7496 linux* | k*bsd*-gnu)
7497 case $cc_basename in
7499 # Kuck and Associates, Inc. (KAI) C++ Compiler
7501 # KCC will only create a shared library if the output file
7502 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7503 # to its proper name (with version) after linking.
7504 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
7505 _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
7506 # Commands to make compiler produce verbose output that lists
7507 # what "hidden" libraries, object files and flags are used when
7508 # linking a shared library.
7510 # There doesn't appear to be a way to prevent this compiler from
7511 # explicitly linking system object files so we need to strip them
7512 # from the output so that they don't get included in the library
7514 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 "X$list" | $Xsed'
7516 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7517 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7519 # Archives containing C++ object files must be created using
7520 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
7521 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
7526 # version 8.0 and above of icpc choke on multiply defined symbols
7527 # if we add $predep_objects and $postdep_objects, however 7.1 and
7528 # earlier do not add the objects themselves.
7529 case `$CC -V 2>&1` in
7531 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7532 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7534 *) # Version 8.0 or newer
7537 ia64*) tmp_idyn=' -i_dynamic';;
7539 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7540 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7543 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7544 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7545 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7546 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7549 # Portland Group C++ compiler
7551 *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*)
7552 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
7554 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
7555 compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
7556 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
7558 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
7559 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
7561 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
7563 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7564 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7565 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
7567 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7568 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
7570 *) # Version 6 will use weak symbols
7571 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7572 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
7576 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
7577 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7578 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
7582 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7583 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
7585 runpath_var=LD_RUN_PATH
7586 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7587 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7589 # Commands to make compiler produce verbose output that lists
7590 # what "hidden" libraries, object files and flags are used when
7591 # linking a shared library.
7593 # There doesn't appear to be a way to prevent this compiler from
7594 # explicitly linking system object files so we need to strip them
7595 # from the output so that they don't get included in the library
7597 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "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 "X$list" | $Xsed'
7600 # IBM XL 8.0 on PPC, with GNU ld
7601 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7602 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7603 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7604 if test "x$supports_anon_versioning" = xyes; then
7605 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7606 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7607 echo "local: *; };" >> $output_objdir/$libname.ver~
7608 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
7612 case `$CC -V 2>&1 | sed 5q` in
7615 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7616 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7617 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
7618 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7619 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
7620 _LT_TAGVAR(compiler_needs_object, $1)=yes
7622 # Not sure whether something based on
7623 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
7625 output_verbose_link_cmd='echo'
7627 # Archives containing C++ object files must be created using
7628 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7629 # necessary to make sure instantiated templates are included
7631 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7639 # FIXME: insert proper C++ library support
7640 _LT_TAGVAR(ld_shlibs, $1)=no
7644 # FIXME: insert proper C++ library support
7645 _LT_TAGVAR(ld_shlibs, $1)=no
7649 case $cc_basename in
7651 # FIXME: insert proper C++ library support
7652 _LT_TAGVAR(ld_shlibs, $1)=no
7655 # FIXME: insert proper C++ library support
7656 _LT_TAGVAR(ld_shlibs, $1)=no
7662 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7663 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
7665 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7666 _LT_TAGVAR(hardcode_direct, $1)=yes
7667 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7669 # Workaround some broken pre-1.5 toolchains
7670 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
7674 _LT_TAGVAR(ld_shlibs, $1)=yes
7678 # C++ shared libraries are fairly broken
7679 _LT_TAGVAR(ld_shlibs, $1)=no
7683 if test -f /usr/libexec/ld.so; then
7684 _LT_TAGVAR(hardcode_direct, $1)=yes
7685 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7686 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7687 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7688 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7689 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7690 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
7691 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7692 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7694 output_verbose_link_cmd=echo
7696 _LT_TAGVAR(ld_shlibs, $1)=no
7700 osf3* | osf4* | osf5*)
7701 case $cc_basename in
7703 # Kuck and Associates, Inc. (KAI) C++ Compiler
7705 # KCC will only create a shared library if the output file
7706 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7707 # to its proper name (with version) after linking.
7708 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
7710 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7711 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7713 # Archives containing C++ object files must be created using
7714 # the KAI C++ compiler.
7716 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
7717 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
7721 # Rational C++ 2.4.1
7722 # FIXME: insert proper C++ library support
7723 _LT_TAGVAR(ld_shlibs, $1)=no
7728 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7729 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
7730 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7733 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7734 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
7735 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
7736 echo "-hidden">> $lib.exp~
7737 $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 "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
7739 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7743 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7745 # Commands to make compiler produce verbose output that lists
7746 # what "hidden" libraries, object files and flags are used when
7747 # linking a shared library.
7749 # There doesn't appear to be a way to prevent this compiler from
7750 # explicitly linking system object files so we need to strip them
7751 # from the output so that they don't get included in the library
7753 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "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 "X$list" | $Xsed'
7756 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7757 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7760 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7763 _LT_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" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7767 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7768 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7770 # Commands to make compiler produce verbose output that lists
7771 # what "hidden" libraries, object files and flags are used when
7772 # linking a shared library.
7773 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
7776 # FIXME: insert proper C++ library support
7777 _LT_TAGVAR(ld_shlibs, $1)=no
7784 # FIXME: insert proper C++ library support
7785 _LT_TAGVAR(ld_shlibs, $1)=no
7789 case $cc_basename in
7792 # FIXME: insert proper C++ library support
7793 _LT_TAGVAR(ld_shlibs, $1)=no
7797 # FIXME: insert proper C++ library support
7798 _LT_TAGVAR(ld_shlibs, $1)=no
7801 # FIXME: insert proper C++ library support
7802 _LT_TAGVAR(ld_shlibs, $1)=no
7808 case $cc_basename in
7810 # Sun C++ 4.2, 5.x and Centerline C++
7811 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
7812 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7813 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7814 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7815 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7817 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7818 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7820 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7822 # The compiler driver will combine and reorder linker options,
7823 # but understands `-z linker_flag'.
7824 # Supported since Solaris 2.6 (maybe 2.5.1?)
7825 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7828 _LT_TAGVAR(link_all_deplibs, $1)=yes
7830 output_verbose_link_cmd='echo'
7832 # Archives containing C++ object files must be created using
7833 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7834 # necessary to make sure instantiated templates are included
7836 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7839 # Green Hills C++ Compiler
7840 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7842 # The C++ compiler must be used to create the archive.
7843 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
7846 # GNU C++ compiler with Solaris linker
7847 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7848 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
7849 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
7850 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7851 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7852 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7854 # Commands to make compiler produce verbose output that lists
7855 # what "hidden" libraries, object files and flags are used when
7856 # linking a shared library.
7857 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
7859 # g++ 2.7 appears to require `-G' NOT `-shared' on this
7861 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7862 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7863 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7865 # Commands to make compiler produce verbose output that lists
7866 # what "hidden" libraries, object files and flags are used when
7867 # linking a shared library.
7868 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
7871 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
7873 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7875 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
7883 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7884 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7885 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7886 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7887 runpath_var='LD_RUN_PATH'
7889 case $cc_basename in
7891 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7892 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7895 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7896 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7901 sysv5* | sco3.2v5* | sco5v6*)
7902 # Note: We can NOT use -z defs as we might desire, because we do not
7903 # link with -lc, and that would cause any symbols used from libc to
7904 # always be unresolved, which means just about no library would
7905 # ever link correctly. If we're not using GNU ld we use -z text
7906 # though, which does catch some bad symbols but isn't as heavy-handed
7908 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7909 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7910 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7911 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7912 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
7913 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7914 _LT_TAGVAR(link_all_deplibs, $1)=yes
7915 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7916 runpath_var='LD_RUN_PATH'
7918 case $cc_basename in
7920 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7921 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7924 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7925 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7931 case $cc_basename in
7933 # NonStop-UX NCC 3.20
7934 # FIXME: insert proper C++ library support
7935 _LT_TAGVAR(ld_shlibs, $1)=no
7938 # FIXME: insert proper C++ library support
7939 _LT_TAGVAR(ld_shlibs, $1)=no
7945 # FIXME: insert proper C++ library support
7946 _LT_TAGVAR(ld_shlibs, $1)=no
7950 # FIXME: insert proper C++ library support
7951 _LT_TAGVAR(ld_shlibs, $1)=no
7955 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
7956 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7958 _LT_TAGVAR(GCC, $1)="$GXX"
7959 _LT_TAGVAR(LD, $1)="$LD"
7962 ## There is no encapsulation within the following macros, do not change
7963 ## the running order or otherwise move them around unless you know exactly
7964 ## what you are doing...
7965 _LT_SYS_HIDDEN_LIBDEPS($1)
7966 _LT_COMPILER_PIC($1)
7967 _LT_COMPILER_C_O($1)
7968 _LT_COMPILER_FILE_LOCKS($1)
7969 _LT_LINKER_SHLIBS($1)
7970 _LT_SYS_DYNAMIC_LINKER($1)
7971 _LT_LINKER_HARDCODE_LIBPATH($1)
7974 fi # test -n "$compiler"
7980 with_gnu_ld=$lt_save_with_gnu_ld
7981 lt_cv_path_LDCXX=$lt_cv_path_LD
7982 lt_cv_path_LD=$lt_save_path_LD
7983 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
7984 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
7985 fi # test "$_lt_caught_CXX_error" != yes
7988 ])# _LT_LANG_CXX_CONFIG
7991 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
7992 # ---------------------------------
7993 # Figure out "hidden" library dependencies from verbose
7994 # compiler output when linking a shared library.
7995 # Parse the compiler output and extract the necessary
7996 # objects, libraries and library flags.
7997 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
7998 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7999 # Dependencies to place before and after the object being linked:
8000 _LT_TAGVAR(predep_objects, $1)=
8001 _LT_TAGVAR(postdep_objects, $1)=
8002 _LT_TAGVAR(predeps, $1)=
8003 _LT_TAGVAR(postdeps, $1)=
8004 _LT_TAGVAR(compiler_lib_search_path, $1)=
8006 dnl we can't use the lt_simple_compile_test_code here,
8007 dnl because it contains code intended for an executable,
8008 dnl not a library. It's possible we should let each
8009 dnl tag define a new lt_????_link_test_code variable,
8010 dnl but it's only used here...
8011 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
8013 void foo (void) { a = 0; }
8015 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
8019 Foo (void) { a = 0; }
8024 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
8032 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
8040 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
8043 public void bar (void) {
8049 dnl Parse the compiler output and extract the necessary
8050 dnl objects, libraries and library flags.
8051 if AC_TRY_EVAL(ac_compile); then
8052 # Parse the compiler output and extract the necessary
8053 # objects, libraries and library flags.
8055 # Sentinel used to keep track of whether or not we are before
8056 # the conftest object file.
8057 pre_test_object_deps_done=no
8059 for p in `eval "$output_verbose_link_cmd"`; do
8063 # Some compilers place space between "-{L,R}" and the path.
8065 if test $p = "-L" ||
8066 test $p = "-R"; then
8073 if test "$pre_test_object_deps_done" = no; then
8076 # Internal compiler library paths should come after those
8077 # provided the user. The postdeps already come after the
8078 # user supplied libs so there is no need to process them.
8079 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
8080 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
8082 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
8085 # The "-l" case would never come before the object being
8086 # linked, so don't bother handling this case.
8089 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
8090 _LT_TAGVAR(postdeps, $1)="${prev}${p}"
8092 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
8098 # This assumes that the test object file only shows up
8099 # once in the compiler output.
8100 if test "$p" = "conftest.$objext"; then
8101 pre_test_object_deps_done=yes
8105 if test "$pre_test_object_deps_done" = no; then
8106 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
8107 _LT_TAGVAR(predep_objects, $1)="$p"
8109 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
8112 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
8113 _LT_TAGVAR(postdep_objects, $1)="$p"
8115 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
8120 *) ;; # Ignore the rest.
8128 echo "libtool.m4: error: problem compiling $1 test program"
8131 $RM -f confest.$objext
8133 # PORTME: override above test on systems where it is broken
8137 # Interix 3.5 installs completely hosed .la files for C++, so rather than
8138 # hack all around it, let's just trust "g++" to DTRT.
8139 _LT_TAGVAR(predep_objects,$1)=
8140 _LT_TAGVAR(postdep_objects,$1)=
8141 _LT_TAGVAR(postdeps,$1)=
8145 case `$CC -V 2>&1 | sed 5q` in
8149 # The more standards-conforming stlport4 library is
8150 # incompatible with the Cstd library. Avoid specifying
8151 # it if it's in CXXFLAGS. Ignore libCrun as
8152 # -library=stlport4 depends on it.
8153 case " $CXX $CXXFLAGS " in
8154 *" -library=stlport4 "*)
8155 solaris_use_stlport4=yes
8159 if test "$solaris_use_stlport4" != yes; then
8160 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8167 case $cc_basename in
8169 # The more standards-conforming stlport4 library is
8170 # incompatible with the Cstd library. Avoid specifying
8171 # it if it's in CXXFLAGS. Ignore libCrun as
8172 # -library=stlport4 depends on it.
8173 case " $CXX $CXXFLAGS " in
8174 *" -library=stlport4 "*)
8175 solaris_use_stlport4=yes
8179 # Adding this requires a known-good setup of shared libraries for
8180 # Sun compiler versions before 5.6, else PIC objects from an old
8181 # archive will be linked into the output, leading to subtle bugs.
8182 if test "$solaris_use_stlport4" != yes; then
8183 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8191 case " $_LT_TAGVAR(postdeps, $1) " in
8192 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
8194 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
8195 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
8196 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
8198 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
8199 [The directories searched by this compiler when creating a shared library])
8200 _LT_TAGDECL([], [predep_objects], [1],
8201 [Dependencies to place before and after the objects being linked to
8202 create a shared library])
8203 _LT_TAGDECL([], [postdep_objects], [1])
8204 _LT_TAGDECL([], [predeps], [1])
8205 _LT_TAGDECL([], [postdeps], [1])
8206 _LT_TAGDECL([], [compiler_lib_search_path], [1],
8207 [The library search path used internally by the compiler when linking
8209 ])# _LT_SYS_HIDDEN_LIBDEPS
8214 # Since AC_PROG_F77 is broken, in that it returns the empty string
8215 # if there is no fortran compiler, we have our own version here.
8216 m4_defun([_LT_PROG_F77],
8218 pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
8220 if test -z "$F77" || test "X$F77" = "Xno"; then
8223 popdef([AC_MSG_ERROR])
8226 dnl aclocal-1.4 backwards compatibility:
8227 dnl AC_DEFUN([_LT_PROG_F77], [])
8230 # _LT_LANG_F77_CONFIG([TAG])
8231 # --------------------------
8232 # Ensure that the configuration variables for a Fortran 77 compiler are
8233 # suitably defined. These variables are subsequently used by _LT_CONFIG
8234 # to write the compiler configuration to `libtool'.
8235 m4_defun([_LT_LANG_F77_CONFIG],
8236 [AC_REQUIRE([_LT_PROG_F77])dnl
8237 AC_LANG_PUSH(Fortran 77)
8239 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8240 _LT_TAGVAR(allow_undefined_flag, $1)=
8241 _LT_TAGVAR(always_export_symbols, $1)=no
8242 _LT_TAGVAR(archive_expsym_cmds, $1)=
8243 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8244 _LT_TAGVAR(hardcode_direct, $1)=no
8245 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8246 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8247 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
8248 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8249 _LT_TAGVAR(hardcode_minus_L, $1)=no
8250 _LT_TAGVAR(hardcode_automatic, $1)=no
8251 _LT_TAGVAR(inherit_rpath, $1)=no
8252 _LT_TAGVAR(module_cmds, $1)=
8253 _LT_TAGVAR(module_expsym_cmds, $1)=
8254 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8255 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8256 _LT_TAGVAR(no_undefined_flag, $1)=
8257 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8258 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8260 # Source file extension for f77 test sources.
8263 # Object file extension for compiled f77 test sources.
8265 _LT_TAGVAR(objext, $1)=$objext
8267 # No sense in running all these tests if we already determined that
8268 # the F77 compiler isn't working. Some variables (like enable_shared)
8269 # are currently assumed to apply to all compilers on this platform,
8270 # and will be corrupted by setting them based on a non-working compiler.
8271 if test "$_lt_disable_F77" != yes; then
8272 # Code to be used in simple compile tests
8273 lt_simple_compile_test_code="\
8279 # Code to be used in simple link tests
8280 lt_simple_link_test_code="\
8285 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8288 # save warnings/boilerplate of simple test code
8289 _LT_COMPILER_BOILERPLATE
8290 _LT_LINKER_BOILERPLATE
8292 # Allow CC to be a program name with arguments.
8297 _LT_TAGVAR(compiler, $1)=$CC
8298 _LT_CC_BASENAME([$compiler])
8300 if test -n "$compiler"; then
8301 AC_MSG_CHECKING([if libtool supports shared libraries])
8302 AC_MSG_RESULT([$can_build_shared])
8304 AC_MSG_CHECKING([whether to build shared libraries])
8305 test "$can_build_shared" = "no" && enable_shared=no
8307 # On AIX, shared libraries and static libraries use the same namespace, and
8308 # are all built from PIC.
8311 test "$enable_shared" = yes && enable_static=no
8312 if test -n "$RANLIB"; then
8313 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8314 postinstall_cmds='$RANLIB $lib'
8318 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8319 test "$enable_shared" = yes && enable_static=no
8323 AC_MSG_RESULT([$enable_shared])
8325 AC_MSG_CHECKING([whether to build static libraries])
8326 # Make sure either enable_shared or enable_static is yes.
8327 test "$enable_shared" = yes || enable_static=yes
8328 AC_MSG_RESULT([$enable_static])
8330 _LT_TAGVAR(GCC, $1)="$G77"
8331 _LT_TAGVAR(LD, $1)="$LD"
8334 ## There is no encapsulation within the following macros, do not change
8335 ## the running order or otherwise move them around unless you know exactly
8336 ## what you are doing...
8337 _LT_COMPILER_PIC($1)
8338 _LT_COMPILER_C_O($1)
8339 _LT_COMPILER_FILE_LOCKS($1)
8340 _LT_LINKER_SHLIBS($1)
8341 _LT_SYS_DYNAMIC_LINKER($1)
8342 _LT_LINKER_HARDCODE_LIBPATH($1)
8345 fi # test -n "$compiler"
8349 fi # test "$_lt_disable_F77" != yes
8352 ])# _LT_LANG_F77_CONFIG
8357 # Since AC_PROG_FC is broken, in that it returns the empty string
8358 # if there is no fortran compiler, we have our own version here.
8359 m4_defun([_LT_PROG_FC],
8361 pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
8363 if test -z "$FC" || test "X$FC" = "Xno"; then
8366 popdef([AC_MSG_ERROR])
8369 dnl aclocal-1.4 backwards compatibility:
8370 dnl AC_DEFUN([_LT_PROG_FC], [])
8373 # _LT_LANG_FC_CONFIG([TAG])
8374 # -------------------------
8375 # Ensure that the configuration variables for a Fortran compiler are
8376 # suitably defined. These variables are subsequently used by _LT_CONFIG
8377 # to write the compiler configuration to `libtool'.
8378 m4_defun([_LT_LANG_FC_CONFIG],
8379 [AC_REQUIRE([_LT_PROG_FC])dnl
8380 AC_LANG_PUSH(Fortran)
8382 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8383 _LT_TAGVAR(allow_undefined_flag, $1)=
8384 _LT_TAGVAR(always_export_symbols, $1)=no
8385 _LT_TAGVAR(archive_expsym_cmds, $1)=
8386 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8387 _LT_TAGVAR(hardcode_direct, $1)=no
8388 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8389 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8390 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
8391 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8392 _LT_TAGVAR(hardcode_minus_L, $1)=no
8393 _LT_TAGVAR(hardcode_automatic, $1)=no
8394 _LT_TAGVAR(inherit_rpath, $1)=no
8395 _LT_TAGVAR(module_cmds, $1)=
8396 _LT_TAGVAR(module_expsym_cmds, $1)=
8397 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8398 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8399 _LT_TAGVAR(no_undefined_flag, $1)=
8400 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8401 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8403 # Source file extension for fc test sources.
8404 ac_ext=${ac_fc_srcext-f}
8406 # Object file extension for compiled fc test sources.
8408 _LT_TAGVAR(objext, $1)=$objext
8410 # No sense in running all these tests if we already determined that
8411 # the FC compiler isn't working. Some variables (like enable_shared)
8412 # are currently assumed to apply to all compilers on this platform,
8413 # and will be corrupted by setting them based on a non-working compiler.
8414 if test "$_lt_disable_FC" != yes; then
8415 # Code to be used in simple compile tests
8416 lt_simple_compile_test_code="\
8422 # Code to be used in simple link tests
8423 lt_simple_link_test_code="\
8428 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8431 # save warnings/boilerplate of simple test code
8432 _LT_COMPILER_BOILERPLATE
8433 _LT_LINKER_BOILERPLATE
8435 # Allow CC to be a program name with arguments.
8440 GCC=$ac_cv_fc_compiler_gnu
8442 _LT_TAGVAR(compiler, $1)=$CC
8443 _LT_CC_BASENAME([$compiler])
8445 if test -n "$compiler"; then
8446 AC_MSG_CHECKING([if libtool supports shared libraries])
8447 AC_MSG_RESULT([$can_build_shared])
8449 AC_MSG_CHECKING([whether to build shared libraries])
8450 test "$can_build_shared" = "no" && enable_shared=no
8452 # On AIX, shared libraries and static libraries use the same namespace, and
8453 # are all built from PIC.
8456 test "$enable_shared" = yes && enable_static=no
8457 if test -n "$RANLIB"; then
8458 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8459 postinstall_cmds='$RANLIB $lib'
8463 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8464 test "$enable_shared" = yes && enable_static=no
8468 AC_MSG_RESULT([$enable_shared])
8470 AC_MSG_CHECKING([whether to build static libraries])
8471 # Make sure either enable_shared or enable_static is yes.
8472 test "$enable_shared" = yes || enable_static=yes
8473 AC_MSG_RESULT([$enable_static])
8475 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
8476 _LT_TAGVAR(LD, $1)="$LD"
8479 ## There is no encapsulation within the following macros, do not change
8480 ## the running order or otherwise move them around unless you know exactly
8481 ## what you are doing...
8482 _LT_SYS_HIDDEN_LIBDEPS($1)
8483 _LT_COMPILER_PIC($1)
8484 _LT_COMPILER_C_O($1)
8485 _LT_COMPILER_FILE_LOCKS($1)
8486 _LT_LINKER_SHLIBS($1)
8487 _LT_SYS_DYNAMIC_LINKER($1)
8488 _LT_LINKER_HARDCODE_LIBPATH($1)
8491 fi # test -n "$compiler"
8495 fi # test "$_lt_disable_FC" != yes
8498 ])# _LT_LANG_FC_CONFIG
8501 # _LT_LANG_GCJ_CONFIG([TAG])
8502 # --------------------------
8503 # Ensure that the configuration variables for the GNU Java Compiler compiler
8504 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8505 # to write the compiler configuration to `libtool'.
8506 m4_defun([_LT_LANG_GCJ_CONFIG],
8507 [AC_REQUIRE([LT_PROG_GCJ])dnl
8510 # Source file extension for Java test sources.
8513 # Object file extension for compiled Java test sources.
8515 _LT_TAGVAR(objext, $1)=$objext
8517 # Code to be used in simple compile tests
8518 lt_simple_compile_test_code="class foo {}"
8520 # Code to be used in simple link tests
8521 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
8523 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8526 # save warnings/boilerplate of simple test code
8527 _LT_COMPILER_BOILERPLATE
8528 _LT_LINKER_BOILERPLATE
8530 # Allow CC to be a program name with arguments.
8536 _LT_TAGVAR(compiler, $1)=$CC
8537 _LT_TAGVAR(LD, $1)="$LD"
8538 _LT_CC_BASENAME([$compiler])
8540 # GCJ did not exist at the time GCC didn't implicitly link libc in.
8541 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8543 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8545 if test -n "$compiler"; then
8546 _LT_COMPILER_NO_RTTI($1)
8547 _LT_COMPILER_PIC($1)
8548 _LT_COMPILER_C_O($1)
8549 _LT_COMPILER_FILE_LOCKS($1)
8550 _LT_LINKER_SHLIBS($1)
8551 _LT_LINKER_HARDCODE_LIBPATH($1)
8560 ])# _LT_LANG_GCJ_CONFIG
8563 # _LT_LANG_RC_CONFIG([TAG])
8564 # -------------------------
8565 # Ensure that the configuration variables for the Windows resource compiler
8566 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8567 # to write the compiler configuration to `libtool'.
8568 m4_defun([_LT_LANG_RC_CONFIG],
8569 [AC_REQUIRE([LT_PROG_RC])dnl
8572 # Source file extension for RC test sources.
8575 # Object file extension for compiled RC test sources.
8577 _LT_TAGVAR(objext, $1)=$objext
8579 # Code to be used in simple compile tests
8580 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8582 # Code to be used in simple link tests
8583 lt_simple_link_test_code="$lt_simple_compile_test_code"
8585 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8588 # save warnings/boilerplate of simple test code
8589 _LT_COMPILER_BOILERPLATE
8590 _LT_LINKER_BOILERPLATE
8592 # Allow CC to be a program name with arguments.
8598 _LT_TAGVAR(compiler, $1)=$CC
8599 _LT_CC_BASENAME([$compiler])
8600 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8602 if test -n "$compiler"; then
8610 ])# _LT_LANG_RC_CONFIG
8615 AC_DEFUN([LT_PROG_GCJ],
8616 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
8617 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
8618 [AC_CHECK_TOOL(GCJ, gcj,)
8619 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
8620 AC_SUBST(GCJFLAGS)])])[]dnl
8624 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
8625 dnl aclocal-1.4 backwards compatibility:
8626 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
8631 AC_DEFUN([LT_PROG_RC],
8632 [AC_CHECK_TOOL(RC, windres,)
8636 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
8637 dnl aclocal-1.4 backwards compatibility:
8638 dnl AC_DEFUN([LT_AC_PROG_RC], [])
8643 # If we don't have a new enough Autoconf to choose the best grep
8644 # available, choose the one first in the user's PATH.
8645 m4_defun([_LT_DECL_EGREP],
8646 [AC_REQUIRE([AC_PROG_EGREP])dnl
8647 AC_REQUIRE([AC_PROG_FGREP])dnl
8648 test -z "$GREP" && GREP=grep
8649 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
8650 _LT_DECL([], [EGREP], [1], [An ERE matcher])
8651 _LT_DECL([], [FGREP], [1], [A literal string matcher])
8652 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
8659 # If we don't have a new enough Autoconf to choose the best objdump
8660 # available, choose the one first in the user's PATH.
8661 m4_defun([_LT_DECL_OBJDUMP],
8662 [AC_CHECK_TOOL(OBJDUMP, objdump, false)
8663 test -z "$OBJDUMP" && OBJDUMP=objdump
8664 _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
8671 # Check for a fully-functional sed program, that truncates
8672 # as few characters as possible. Prefer GNU sed if found.
8673 m4_defun([_LT_DECL_SED],
8675 test -z "$SED" && SED=sed
8676 Xsed="$SED -e 1s/^X//"
8677 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
8678 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
8679 [Sed that helps us avoid accidentally triggering echo(1) options like -n])
8682 m4_ifndef([AC_PROG_SED], [
8683 # NOTE: This macro has been submitted for inclusion into #
8684 # GNU Autoconf as AC_PROG_SED. When it is available in #
8685 # a released version of Autoconf we should remove this #
8686 # macro and use it instead. #
8688 m4_defun([AC_PROG_SED],
8689 [AC_MSG_CHECKING([for a sed that does not truncate output])
8690 AC_CACHE_VAL(lt_cv_path_SED,
8691 [# Loop through the user's path and test for sed and gsed.
8692 # Then use that list of sed's as ones to test for truncation.
8693 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8697 test -z "$as_dir" && as_dir=.
8698 for lt_ac_prog in sed gsed; do
8699 for ac_exec_ext in '' $ac_executable_extensions; do
8700 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
8701 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
8709 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
8710 # along with /bin/sed that truncates output.
8711 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
8712 test ! -f $lt_ac_sed && continue
8713 cat /dev/null > conftest.in
8715 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
8716 # Check for GNU sed and select it if it is found.
8717 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
8718 lt_cv_path_SED=$lt_ac_sed
8722 cat conftest.in conftest.in >conftest.tmp
8723 mv conftest.tmp conftest.in
8724 cp conftest.in conftest.nl
8726 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
8727 cmp -s conftest.out conftest.nl || break
8728 # 10000 chars as input seems more than enough
8729 test $lt_ac_count -gt 10 && break
8730 lt_ac_count=`expr $lt_ac_count + 1`
8731 if test $lt_ac_count -gt $lt_ac_max; then
8732 lt_ac_max=$lt_ac_count
8733 lt_cv_path_SED=$lt_ac_sed
8740 AC_MSG_RESULT([$SED])
8745 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
8746 dnl aclocal-1.4 backwards compatibility:
8747 dnl AC_DEFUN([LT_AC_PROG_SED], [])
8750 # _LT_CHECK_SHELL_FEATURES
8751 # ------------------------
8752 # Find out whether the shell is Bourne or XSI compatible,
8753 # or has some other useful features.
8754 m4_defun([_LT_CHECK_SHELL_FEATURES],
8755 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
8756 # Try some XSI features
8759 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
8761 && eval 'test $(( 1 + 1 )) -eq 2 \
8762 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
8764 AC_MSG_RESULT([$xsi_shell])
8765 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
8767 AC_MSG_CHECKING([whether the shell understands "+="])
8769 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
8771 && lt_shell_append=yes
8772 AC_MSG_RESULT([$lt_shell_append])
8773 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
8775 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8780 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
8782 # test EBCDIC or ASCII
8783 case `echo X|tr X '\101'` in
8784 A) # ASCII based system
8785 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8786 lt_SP2NL='tr \040 \012'
8787 lt_NL2SP='tr \015\012 \040\040'
8789 *) # EBCDIC based system
8790 lt_SP2NL='tr \100 \n'
8791 lt_NL2SP='tr \r\n \100\100'
8794 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
8795 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
8796 ])# _LT_CHECK_SHELL_FEATURES
8799 # _LT_PROG_XSI_SHELLFNS
8800 # ---------------------
8801 # Bourne and XSI compatible variants of some useful shell functions.
8802 m4_defun([_LT_PROG_XSI_SHELLFNS],
8805 cat << \_LT_EOF >> "$cfgfile"
8807 # func_dirname file append nondir_replacement
8808 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
8809 # otherwise set result to NONDIR_REPLACEMENT.
8813 */*) func_dirname_result="${1%/*}${2}" ;;
8814 * ) func_dirname_result="${3}" ;;
8818 # func_basename file
8821 func_basename_result="${1##*/}"
8824 # func_dirname_and_basename file append nondir_replacement
8825 # perform func_basename and func_dirname in a single function
8827 # dirname: Compute the dirname of FILE. If nonempty,
8828 # add APPEND to the result, otherwise set result
8829 # to NONDIR_REPLACEMENT.
8830 # value returned in "$func_dirname_result"
8831 # basename: Compute filename of FILE.
8832 # value retuned in "$func_basename_result"
8833 # Implementation must be kept synchronized with func_dirname
8834 # and func_basename. For efficiency, we do not delegate to
8835 # those functions but instead duplicate the functionality here.
8836 func_dirname_and_basename ()
8839 */*) func_dirname_result="${1%/*}${2}" ;;
8840 * ) func_dirname_result="${3}" ;;
8842 func_basename_result="${1##*/}"
8845 # func_stripname prefix suffix name
8846 # strip PREFIX and SUFFIX off of NAME.
8847 # PREFIX and SUFFIX must not contain globbing or regex special
8848 # characters, hashes, percent signs, but SUFFIX may contain a leading
8849 # dot (in which case that matches only a dot).
8852 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
8853 # positional parameters, so assign one to ordinary parameter first.
8854 func_stripname_result=${3}
8855 func_stripname_result=${func_stripname_result#"${1}"}
8856 func_stripname_result=${func_stripname_result%"${2}"}
8862 func_opt_split_opt=${1%%=*}
8863 func_opt_split_arg=${1#*=}
8870 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
8871 *) func_lo2o_result=${1} ;;
8875 # func_xform libobj-or-source
8878 func_xform_result=${1%.*}.lo
8881 # func_arith arithmetic-term...
8884 func_arith_result=$(( $[*] ))
8888 # STRING may not start with a hyphen.
8891 func_len_result=${#1}
8896 *) # Bourne compatible functions.
8897 cat << \_LT_EOF >> "$cfgfile"
8899 # func_dirname file append nondir_replacement
8900 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
8901 # otherwise set result to NONDIR_REPLACEMENT.
8904 # Extract subdirectory from the argument.
8905 func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
8906 if test "X$func_dirname_result" = "X${1}"; then
8907 func_dirname_result="${3}"
8909 func_dirname_result="$func_dirname_result${2}"
8913 # func_basename file
8916 func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
8919 dnl func_dirname_and_basename
8920 dnl A portable version of this function is already defined in general.m4sh
8921 dnl so there is no need for it here.
8923 # func_stripname prefix suffix name
8924 # strip PREFIX and SUFFIX off of NAME.
8925 # PREFIX and SUFFIX must not contain globbing or regex special
8926 # characters, hashes, percent signs, but SUFFIX may contain a leading
8927 # dot (in which case that matches only a dot).
8928 # func_strip_suffix prefix name
8932 .*) func_stripname_result=`$ECHO "X${3}" \
8933 | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
8934 *) func_stripname_result=`$ECHO "X${3}" \
8935 | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
8940 my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
8941 my_sed_long_arg='1s/^-[[^=]]*=//'
8946 func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
8947 func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
8953 func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
8956 # func_xform libobj-or-source
8959 func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'`
8962 # func_arith arithmetic-term...
8965 func_arith_result=`expr "$[@]"`
8969 # STRING may not start with a hyphen.
8972 func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
8978 case $lt_shell_append in
8980 cat << \_LT_EOF >> "$cfgfile"
8982 # func_append var value
8983 # Append VALUE to the end of shell variable VAR.
8991 cat << \_LT_EOF >> "$cfgfile"
8993 # func_append var value
8994 # Append VALUE to the end of shell variable VAR.
8997 eval "$[1]=\$$[1]\$[2]"
9005 # Helper functions for option handling. -*- Autoconf -*-
9007 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
9008 # Written by Gary V. Vaughan, 2004
9010 # This file is free software; the Free Software Foundation gives
9011 # unlimited permission to copy and/or distribute it, with or without
9012 # modifications, as long as this notice is preserved.
9014 # serial 6 ltoptions.m4
9016 # This is to help aclocal find these macros, as it can't see m4_define.
9017 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
9020 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
9021 # ------------------------------------------
9022 m4_define([_LT_MANGLE_OPTION],
9023 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
9026 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
9027 # ---------------------------------------
9028 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
9029 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
9031 m4_define([_LT_SET_OPTION],
9032 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
9033 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
9034 _LT_MANGLE_DEFUN([$1], [$2]),
9035 [m4_warning([Unknown $1 option `$2'])])[]dnl
9039 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
9040 # ------------------------------------------------------------
9041 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
9042 m4_define([_LT_IF_OPTION],
9043 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
9046 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
9047 # -------------------------------------------------------
9048 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
9050 m4_define([_LT_UNLESS_OPTIONS],
9051 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9052 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
9053 [m4_define([$0_found])])])[]dnl
9054 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
9059 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
9060 # ----------------------------------------
9061 # OPTION-LIST is a space-separated list of Libtool options associated
9062 # with MACRO-NAME. If any OPTION has a matching handler declared with
9063 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
9064 # the unknown option and exit.
9065 m4_defun([_LT_SET_OPTIONS],
9067 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9068 [_LT_SET_OPTION([$1], _LT_Option)])
9070 m4_if([$1],[LT_INIT],[
9072 dnl Simply set some default values (i.e off) if boolean options were not
9074 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
9076 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
9079 dnl If no reference was made to various pairs of opposing options, then
9080 dnl we run the default mode handler for the pair. For example, if neither
9081 dnl `shared' nor `disable-shared' was passed, we enable building of shared
9082 dnl archives by default:
9083 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
9084 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
9085 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
9086 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
9087 [_LT_ENABLE_FAST_INSTALL])
9093 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
9094 # -----------------------------------------
9095 m4_define([_LT_MANGLE_DEFUN],
9096 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
9099 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
9100 # -----------------------------------------------
9101 m4_define([LT_OPTION_DEFINE],
9102 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
9103 ])# LT_OPTION_DEFINE
9108 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
9111 AU_DEFUN([AC_LIBTOOL_DLOPEN],
9112 [_LT_SET_OPTION([LT_INIT], [dlopen])
9113 AC_DIAGNOSE([obsolete],
9114 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9115 put the `dlopen' option into LT_INIT's first parameter.])
9118 dnl aclocal-1.4 backwards compatibility:
9119 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
9124 # Declare package support for building win32 dll's.
9125 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
9126 [enable_win32_dll=yes
9129 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*)
9130 AC_CHECK_TOOL(AS, as, false)
9131 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
9132 AC_CHECK_TOOL(OBJDUMP, objdump, false)
9136 test -z "$AS" && AS=as
9137 _LT_DECL([], [AS], [0], [Assembler program])dnl
9139 test -z "$DLLTOOL" && DLLTOOL=dlltool
9140 _LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl
9142 test -z "$OBJDUMP" && OBJDUMP=objdump
9143 _LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl
9146 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
9147 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
9148 _LT_SET_OPTION([LT_INIT], [win32-dll])
9149 AC_DIAGNOSE([obsolete],
9150 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9151 put the `win32-dll' option into LT_INIT's first parameter.])
9154 dnl aclocal-1.4 backwards compatibility:
9155 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
9158 # _LT_ENABLE_SHARED([DEFAULT])
9159 # ----------------------------
9160 # implement the --enable-shared flag, and supports the `shared' and
9161 # `disable-shared' LT_INIT options.
9162 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9163 m4_define([_LT_ENABLE_SHARED],
9164 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
9165 AC_ARG_ENABLE([shared],
9166 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
9167 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
9168 [p=${PACKAGE-default}
9170 yes) enable_shared=yes ;;
9171 no) enable_shared=no ;;
9174 # Look at the argument we got. We use all the common list separators.
9175 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9176 for pkg in $enableval; do
9178 if test "X$pkg" = "X$p"; then
9185 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
9187 _LT_DECL([build_libtool_libs], [enable_shared], [0],
9188 [Whether or not to build shared libraries])
9189 ])# _LT_ENABLE_SHARED
9191 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
9192 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
9195 AC_DEFUN([AC_ENABLE_SHARED],
9196 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
9199 AC_DEFUN([AC_DISABLE_SHARED],
9200 [_LT_SET_OPTION([LT_INIT], [disable-shared])
9203 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
9204 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
9206 dnl aclocal-1.4 backwards compatibility:
9207 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
9208 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
9212 # _LT_ENABLE_STATIC([DEFAULT])
9213 # ----------------------------
9214 # implement the --enable-static flag, and support the `static' and
9215 # `disable-static' LT_INIT options.
9216 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9217 m4_define([_LT_ENABLE_STATIC],
9218 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
9219 AC_ARG_ENABLE([static],
9220 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
9221 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
9222 [p=${PACKAGE-default}
9224 yes) enable_static=yes ;;
9225 no) enable_static=no ;;
9228 # Look at the argument we got. We use all the common list separators.
9229 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9230 for pkg in $enableval; do
9232 if test "X$pkg" = "X$p"; then
9239 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
9241 _LT_DECL([build_old_libs], [enable_static], [0],
9242 [Whether or not to build static libraries])
9243 ])# _LT_ENABLE_STATIC
9245 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
9246 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
9249 AC_DEFUN([AC_ENABLE_STATIC],
9250 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
9253 AC_DEFUN([AC_DISABLE_STATIC],
9254 [_LT_SET_OPTION([LT_INIT], [disable-static])
9257 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
9258 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
9260 dnl aclocal-1.4 backwards compatibility:
9261 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
9262 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
9266 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
9267 # ----------------------------------
9268 # implement the --enable-fast-install flag, and support the `fast-install'
9269 # and `disable-fast-install' LT_INIT options.
9270 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9271 m4_define([_LT_ENABLE_FAST_INSTALL],
9272 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
9273 AC_ARG_ENABLE([fast-install],
9274 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
9275 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
9276 [p=${PACKAGE-default}
9278 yes) enable_fast_install=yes ;;
9279 no) enable_fast_install=no ;;
9281 enable_fast_install=no
9282 # Look at the argument we got. We use all the common list separators.
9283 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9284 for pkg in $enableval; do
9286 if test "X$pkg" = "X$p"; then
9287 enable_fast_install=yes
9293 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
9295 _LT_DECL([fast_install], [enable_fast_install], [0],
9296 [Whether or not to optimize for fast installation])dnl
9297 ])# _LT_ENABLE_FAST_INSTALL
9299 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
9300 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
9303 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
9304 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
9305 AC_DIAGNOSE([obsolete],
9306 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9307 the `fast-install' option into LT_INIT's first parameter.])
9310 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
9311 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
9312 AC_DIAGNOSE([obsolete],
9313 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9314 the `disable-fast-install' option into LT_INIT's first parameter.])
9317 dnl aclocal-1.4 backwards compatibility:
9318 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
9319 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
9322 # _LT_WITH_PIC([MODE])
9323 # --------------------
9324 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
9326 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
9327 m4_define([_LT_WITH_PIC],
9329 [AS_HELP_STRING([--with-pic],
9330 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
9331 [pic_mode="$withval"],
9334 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
9336 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
9339 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
9340 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
9343 AU_DEFUN([AC_LIBTOOL_PICMODE],
9344 [_LT_SET_OPTION([LT_INIT], [pic-only])
9345 AC_DIAGNOSE([obsolete],
9346 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9347 put the `pic-only' option into LT_INIT's first parameter.])
9350 dnl aclocal-1.4 backwards compatibility:
9351 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
9354 m4_define([_LTDL_MODE], [])
9355 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
9356 [m4_define([_LTDL_MODE], [nonrecursive])])
9357 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
9358 [m4_define([_LTDL_MODE], [recursive])])
9359 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
9360 [m4_define([_LTDL_MODE], [subproject])])
9362 m4_define([_LTDL_TYPE], [])
9363 LT_OPTION_DEFINE([LTDL_INIT], [installable],
9364 [m4_define([_LTDL_TYPE], [installable])])
9365 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
9366 [m4_define([_LTDL_TYPE], [convenience])])
9368 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
9370 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
9371 # Written by Gary V. Vaughan, 2004
9373 # This file is free software; the Free Software Foundation gives
9374 # unlimited permission to copy and/or distribute it, with or without
9375 # modifications, as long as this notice is preserved.
9377 # serial 6 ltsugar.m4
9379 # This is to help aclocal find these macros, as it can't see m4_define.
9380 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
9383 # lt_join(SEP, ARG1, [ARG2...])
9384 # -----------------------------
9385 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
9386 # associated separator.
9387 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
9388 # versions in m4sugar had bugs.
9389 m4_define([lt_join],
9390 [m4_if([$#], [1], [],
9392 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
9393 m4_define([_lt_join],
9394 [m4_if([$#$2], [2], [],
9395 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
9401 # Manipulate m4 lists.
9402 # These macros are necessary as long as will still need to support
9403 # Autoconf-2.59 which quotes differently.
9404 m4_define([lt_car], [[$1]])
9406 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
9408 [m4_dquote(m4_shift($@))])])
9409 m4_define([lt_unquote], $1)
9412 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
9413 # ------------------------------------------
9414 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
9415 # Note that neither SEPARATOR nor STRING are expanded; they are appended
9416 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
9417 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
9418 # than defined and empty).
9420 # This macro is needed until we can rely on Autoconf 2.62, since earlier
9421 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
9422 m4_define([lt_append],
9424 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
9428 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
9429 # ----------------------------------------------------------
9430 # Produce a SEP delimited list of all paired combinations of elements of
9431 # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
9432 # has the form PREFIXmINFIXSUFFIXn.
9433 # Needed until we can rely on m4_combine added in Autoconf 2.62.
9434 m4_define([lt_combine],
9435 [m4_if(m4_eval([$# > 3]), [1],
9436 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
9437 [[m4_foreach([_Lt_prefix], [$2],
9438 [m4_foreach([_Lt_suffix],
9439 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
9440 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
9443 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
9444 # -----------------------------------------------------------------------
9445 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
9446 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
9447 m4_define([lt_if_append_uniq],
9449 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
9450 [lt_append([$1], [$2], [$3])$4],
9452 [lt_append([$1], [$2], [$3])$4])])
9455 # lt_dict_add(DICT, KEY, VALUE)
9456 # -----------------------------
9457 m4_define([lt_dict_add],
9458 [m4_define([$1($2)], [$3])])
9461 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
9462 # --------------------------------------------
9463 m4_define([lt_dict_add_subkey],
9464 [m4_define([$1($2:$3)], [$4])])
9467 # lt_dict_fetch(DICT, KEY, [SUBKEY])
9468 # ----------------------------------
9469 m4_define([lt_dict_fetch],
9471 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
9472 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
9475 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
9476 # -----------------------------------------------------------------
9477 m4_define([lt_if_dict_fetch],
9478 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
9483 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
9484 # --------------------------------------------------------------
9485 m4_define([lt_dict_filter],
9486 [m4_if([$5], [], [],
9487 [lt_join(m4_quote(m4_default([$4], [[, ]])),
9488 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
9489 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
9492 # ltversion.m4 -- version numbers -*- Autoconf -*-
9494 # Copyright (C) 2004 Free Software Foundation, Inc.
9495 # Written by Scott James Remnant, 2004
9497 # This file is free software; the Free Software Foundation gives
9498 # unlimited permission to copy and/or distribute it, with or without
9499 # modifications, as long as this notice is preserved.
9501 # Generated from ltversion.in.
9503 # serial 3012 ltversion.m4
9504 # This file is part of GNU Libtool
9506 m4_define([LT_PACKAGE_VERSION], [2.2.6])
9507 m4_define([LT_PACKAGE_REVISION], [1.3012])
9509 AC_DEFUN([LTVERSION_VERSION],
9510 [macro_version='2.2.6'
9511 macro_revision='1.3012'
9512 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
9513 _LT_DECL(, macro_revision, 0)
9516 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
9518 # Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
9519 # Written by Scott James Remnant, 2004.
9521 # This file is free software; the Free Software Foundation gives
9522 # unlimited permission to copy and/or distribute it, with or without
9523 # modifications, as long as this notice is preserved.
9525 # serial 4 lt~obsolete.m4
9527 # These exist entirely to fool aclocal when bootstrapping libtool.
9529 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
9530 # which have later been changed to m4_define as they aren't part of the
9531 # exported API, or moved to Autoconf or Automake where they belong.
9533 # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
9534 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
9535 # using a macro with the same name in our local m4/libtool.m4 it'll
9536 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
9537 # and doesn't know about Autoconf macros at all.)
9539 # So we provide this file, which has a silly filename so it's always
9540 # included after everything else. This provides aclocal with the
9541 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
9542 # because those macros already exist, or will be overwritten later.
9543 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
9545 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
9546 # Yes, that means every name once taken will need to remain here until
9547 # we give up compatibility with versions before 1.7, at which point
9548 # we need to keep only those names which we still refer to.
9550 # This is to help aclocal find these macros, as it can't see m4_define.
9551 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
9553 m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
9554 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
9555 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
9556 m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
9557 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
9558 m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
9559 m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
9560 m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
9561 m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
9562 m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
9563 m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
9564 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
9565 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
9566 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
9567 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
9568 m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
9569 m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
9570 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
9571 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
9572 m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
9573 m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
9574 m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
9575 m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
9576 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
9577 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
9578 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
9579 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
9580 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
9581 m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
9582 m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
9583 m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
9584 m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
9585 m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
9586 m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
9587 m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
9588 m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
9589 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
9590 m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
9591 m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
9592 m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
9593 m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
9594 m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
9595 m4_ifndef([AC_LIBTOOL_RC], [AC_DEFUN([AC_LIBTOOL_RC])])
9596 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
9597 m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
9598 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
9599 m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
9600 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
9601 m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
9602 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
9603 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
9604 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
9605 m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
9606 m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
9607 m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
9609 # nls.m4 serial 3 (gettext-0.15)
9610 dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc.
9611 dnl This file is free software; the Free Software Foundation
9612 dnl gives unlimited permission to copy and/or distribute it,
9613 dnl with or without modifications, as long as this notice is preserved.
9615 dnl This file can can be used in projects which are not available under
9616 dnl the GNU General Public License or the GNU Library General Public
9617 dnl License but which still want to provide support for the GNU gettext
9619 dnl Please note that the actual code of the GNU gettext library is covered
9620 dnl by the GNU Library General Public License, and the rest of the GNU
9621 dnl gettext package package is covered by the GNU General Public License.
9622 dnl They are *not* in the public domain.
9625 dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
9626 dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
9632 AC_MSG_CHECKING([whether NLS is requested])
9633 dnl Default is enabled NLS
9635 [ --disable-nls do not use Native Language Support],
9636 USE_NLS=$enableval, USE_NLS=yes)
9637 AC_MSG_RESULT($USE_NLS)
9641 # po.m4 serial 15 (gettext-0.17)
9642 dnl Copyright (C) 1995-2007 Free Software Foundation, Inc.
9643 dnl This file is free software; the Free Software Foundation
9644 dnl gives unlimited permission to copy and/or distribute it,
9645 dnl with or without modifications, as long as this notice is preserved.
9647 dnl This file can can be used in projects which are not available under
9648 dnl the GNU General Public License or the GNU Library General Public
9649 dnl License but which still want to provide support for the GNU gettext
9651 dnl Please note that the actual code of the GNU gettext library is covered
9652 dnl by the GNU Library General Public License, and the rest of the GNU
9653 dnl gettext package package is covered by the GNU General Public License.
9654 dnl They are *not* in the public domain.
9657 dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
9658 dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
9662 dnl Checks for all prerequisites of the po subdirectory.
9663 AC_DEFUN([AM_PO_SUBDIRS],
9665 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
9666 AC_REQUIRE([AC_PROG_INSTALL])dnl
9667 AC_REQUIRE([AM_PROG_MKDIR_P])dnl defined by automake
9668 AC_REQUIRE([AM_NLS])dnl
9670 dnl Release version of the gettext macros. This is used to ensure that
9671 dnl the gettext macros and po/Makefile.in.in are in sync.
9672 AC_SUBST([GETTEXT_MACRO_VERSION], [0.17])
9674 dnl Perform the following tests also if --disable-nls has been given,
9675 dnl because they are needed for "make dist" to work.
9677 dnl Search for GNU msgfmt in the PATH.
9678 dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions.
9679 dnl The second test excludes FreeBSD msgfmt.
9680 AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
9681 [$ac_dir/$ac_word --statistics /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
9682 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
9684 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
9686 dnl Test whether it is GNU msgfmt >= 0.15.
9688 case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
9689 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;;
9690 *) MSGFMT_015=$MSGFMT ;;
9693 AC_SUBST([MSGFMT_015])
9695 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
9696 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
9697 *) GMSGFMT_015=$GMSGFMT ;;
9700 AC_SUBST([GMSGFMT_015])
9702 dnl Search for GNU xgettext 0.12 or newer in the PATH.
9703 dnl The first test excludes Solaris xgettext and early GNU xgettext versions.
9704 dnl The second test excludes FreeBSD xgettext.
9705 AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
9706 [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
9707 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
9709 dnl Remove leftover from FreeBSD xgettext call.
9712 dnl Test whether it is GNU xgettext >= 0.15.
9714 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
9715 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
9716 *) XGETTEXT_015=$XGETTEXT ;;
9719 AC_SUBST([XGETTEXT_015])
9721 dnl Search for GNU msgmerge 0.11 or newer in the PATH.
9722 AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge,
9723 [$ac_dir/$ac_word --update -q /dev/null /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1], :)
9725 dnl Installation directories.
9726 dnl Autoconf >= 2.60 defines localedir. For older versions of autoconf, we
9727 dnl have to define it here, so that it can be used in po/Makefile.
9728 test -n "$localedir" || localedir='${datadir}/locale'
9729 AC_SUBST([localedir])
9731 dnl Support for AM_XGETTEXT_OPTION.
9732 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
9733 AC_SUBST([XGETTEXT_EXTRA_OPTIONS])
9735 AC_CONFIG_COMMANDS([po-directories], [[
9736 for ac_file in $CONFIG_FILES; do
9737 # Support "outfile[:infile[:infile...]]"
9739 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
9741 # PO directories have a Makefile.in generated from Makefile.in.in.
9742 case "$ac_file" in */Makefile.in)
9743 # Adjust a relative srcdir.
9744 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
9745 ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
9746 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
9747 # In autoconf-2.13 it is called $ac_given_srcdir.
9748 # In autoconf-2.50 it is called $srcdir.
9749 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
9750 case "$ac_given_srcdir" in
9751 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
9752 /*) top_srcdir="$ac_given_srcdir" ;;
9753 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
9755 # Treat a directory as a PO directory if and only if it has a
9756 # POTFILES.in file. This allows packages to have multiple PO
9757 # directories under different names or in different locations.
9758 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
9759 rm -f "$ac_dir/POTFILES"
9760 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
9761 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
9762 POMAKEFILEDEPS="POTFILES.in"
9763 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
9764 # on $ac_dir but don't depend on user-specified configuration
9766 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
9767 # The LINGUAS file contains the set of available languages.
9768 if test -n "$OBSOLETE_ALL_LINGUAS"; then
9769 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
9771 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
9772 # Hide the ALL_LINGUAS assigment from automake < 1.5.
9773 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
9774 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
9776 # The set of available languages was given in configure.in.
9777 # Hide the ALL_LINGUAS assigment from automake < 1.5.
9778 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
9781 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
9782 # Compute UPDATEPOFILES
9783 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
9784 # Compute DUMMYPOFILES
9785 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
9787 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
9788 case "$ac_given_srcdir" in
9790 *) srcdirpre='$(srcdir)/' ;;
9796 for lang in $ALL_LINGUAS; do
9797 POFILES="$POFILES $srcdirpre$lang.po"
9798 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
9799 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
9800 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
9802 # CATALOGS depends on both $ac_dir and the user's LINGUAS
9803 # environment variable.
9805 if test -n "$ALL_LINGUAS"; then
9806 for presentlang in $ALL_LINGUAS; do
9808 if test "%UNSET%" != "$LINGUAS"; then
9809 desiredlanguages="$LINGUAS"
9811 desiredlanguages="$ALL_LINGUAS"
9813 for desiredlang in $desiredlanguages; do
9814 # Use the presentlang catalog if desiredlang is
9815 # a. equal to presentlang, or
9816 # b. a variant of presentlang (because in this case,
9817 # presentlang can be used as a fallback for messages
9818 # which are not translated in the desiredlang catalog).
9819 case "$desiredlang" in
9820 "$presentlang"*) useit=yes;;
9823 if test $useit = yes; then
9824 INST_LINGUAS="$INST_LINGUAS $presentlang"
9829 if test -n "$INST_LINGUAS"; then
9830 for lang in $INST_LINGUAS; do
9831 CATALOGS="$CATALOGS $lang.gmo"
9834 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
9835 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
9836 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
9837 if test -f "$f"; then
9839 *.orig | *.bak | *~) ;;
9840 *) cat "$f" >> "$ac_dir/Makefile" ;;
9848 [# Capture the value of obsolete ALL_LINGUAS because we need it to compute
9849 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
9850 # from automake < 1.5.
9851 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
9852 # Capture the value of LINGUAS because we need it to compute CATALOGS.
9853 LINGUAS="${LINGUAS-%UNSET%}"
9857 dnl Postprocesses a Makefile in a directory containing PO files.
9858 AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE],
9860 # When this code is run, in config.status, two variables have already been
9862 # - OBSOLETE_ALL_LINGUAS is the value of LINGUAS set in configure.in,
9863 # - LINGUAS is the value of the environment variable LINGUAS at configure
9867 # Adjust a relative srcdir.
9868 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
9869 ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
9870 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
9871 # In autoconf-2.13 it is called $ac_given_srcdir.
9872 # In autoconf-2.50 it is called $srcdir.
9873 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
9874 case "$ac_given_srcdir" in
9875 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
9876 /*) top_srcdir="$ac_given_srcdir" ;;
9877 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
9880 # Find a way to echo strings without interpreting backslash.
9881 if test "X`(echo '\t') 2>/dev/null`" = 'X\t'; then
9884 if test "X`(printf '%s\n' '\t') 2>/dev/null`" = 'X\t'; then
9885 gt_echo='printf %s\n'
9896 # A sed script that extracts the value of VARIABLE from a Makefile.
9898 # Test if the hold space is empty.
9903 # Yes it was empty. Look if we have the expected variable definition.
9904 /^[ ]*VARIABLE[ ]*=/{
9905 # Seen the first line of the variable definition.
9906 s/^[ ]*VARIABLE[ ]*=//
9911 # Here we are processing a line from the variable definition.
9912 # Remove comment, more precisely replace it with a space.
9914 # See if the line ends in a backslash.
9918 # Print the line, without the trailing backslash.
9921 # There was no trailing backslash. The end of the variable definition is
9922 # reached. Clear the hold space.
9927 # A trailing backslash means that the variable definition continues in the
9928 # next line. Put a nonempty string into the hold space to indicate this.
9935 # Set POTFILES to the value of the Makefile variable POTFILES.
9936 sed_x_POTFILES=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/POTFILES/g'`
9937 POTFILES=`sed -n -e "$sed_x_POTFILES" < "$ac_file"`
9938 # Compute POTFILES_DEPS as
9939 # $(foreach file, $(POTFILES), $(top_srcdir)/$(file))
9941 for file in $POTFILES; do
9942 POTFILES_DEPS="$POTFILES_DEPS "'$(top_srcdir)/'"$file"
9946 if test -n "$OBSOLETE_ALL_LINGUAS"; then
9947 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
9949 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
9950 # The LINGUAS file contains the set of available languages.
9951 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
9952 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
9954 # Set ALL_LINGUAS to the value of the Makefile variable LINGUAS.
9955 sed_x_LINGUAS=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/LINGUAS/g'`
9956 ALL_LINGUAS_=`sed -n -e "$sed_x_LINGUAS" < "$ac_file"`
9958 # Hide the ALL_LINGUAS assigment from automake < 1.5.
9959 eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
9961 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
9962 # Compute UPDATEPOFILES
9963 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
9964 # Compute DUMMYPOFILES
9965 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
9967 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
9968 # Compute PROPERTIESFILES
9969 # as $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).properties)
9970 # Compute CLASSFILES
9971 # as $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).class)
9973 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).qm)
9975 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang)).msg)
9976 # Compute RESOURCESDLLFILES
9977 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang))/$(DOMAIN).resources.dll)
9978 case "$ac_given_srcdir" in
9980 *) srcdirpre='$(srcdir)/' ;;
9991 for lang in $ALL_LINGUAS; do
9992 POFILES="$POFILES $srcdirpre$lang.po"
9993 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
9994 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
9995 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
9996 PROPERTIESFILES="$PROPERTIESFILES \$(top_srcdir)/\$(DOMAIN)_$lang.properties"
9997 CLASSFILES="$CLASSFILES \$(top_srcdir)/\$(DOMAIN)_$lang.class"
9998 QMFILES="$QMFILES $srcdirpre$lang.qm"
9999 frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
10000 MSGFILES="$MSGFILES $srcdirpre$frobbedlang.msg"
10001 frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
10002 RESOURCESDLLFILES="$RESOURCESDLLFILES $srcdirpre$frobbedlang/\$(DOMAIN).resources.dll"
10004 # CATALOGS depends on both $ac_dir and the user's LINGUAS
10005 # environment variable.
10007 if test -n "$ALL_LINGUAS"; then
10008 for presentlang in $ALL_LINGUAS; do
10010 if test "%UNSET%" != "$LINGUAS"; then
10011 desiredlanguages="$LINGUAS"
10013 desiredlanguages="$ALL_LINGUAS"
10015 for desiredlang in $desiredlanguages; do
10016 # Use the presentlang catalog if desiredlang is
10017 # a. equal to presentlang, or
10018 # b. a variant of presentlang (because in this case,
10019 # presentlang can be used as a fallback for messages
10020 # which are not translated in the desiredlang catalog).
10021 case "$desiredlang" in
10022 "$presentlang"*) useit=yes;;
10025 if test $useit = yes; then
10026 INST_LINGUAS="$INST_LINGUAS $presentlang"
10035 if test -n "$INST_LINGUAS"; then
10036 for lang in $INST_LINGUAS; do
10037 CATALOGS="$CATALOGS $lang.gmo"
10038 JAVACATALOGS="$JAVACATALOGS \$(DOMAIN)_$lang.properties"
10039 QTCATALOGS="$QTCATALOGS $lang.qm"
10040 frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
10041 TCLCATALOGS="$TCLCATALOGS $frobbedlang.msg"
10042 frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
10043 CSHARPCATALOGS="$CSHARPCATALOGS $frobbedlang/\$(DOMAIN).resources.dll"
10047 sed -e "s|@POTFILES_DEPS@|$POTFILES_DEPS|g" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@PROPERTIESFILES@|$PROPERTIESFILES|g" -e "s|@CLASSFILES@|$CLASSFILES|g" -e "s|@QMFILES@|$QMFILES|g" -e "s|@MSGFILES@|$MSGFILES|g" -e "s|@RESOURCESDLLFILES@|$RESOURCESDLLFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@JAVACATALOGS@|$JAVACATALOGS|g" -e "s|@QTCATALOGS@|$QTCATALOGS|g" -e "s|@TCLCATALOGS@|$TCLCATALOGS|g" -e "s|@CSHARPCATALOGS@|$CSHARPCATALOGS|g" -e 's,^#distdir:,distdir:,' < "$ac_file" > "$ac_file.tmp"
10048 if grep -l '@TCLCATALOGS@' "$ac_file" > /dev/null; then
10049 # Add dependencies that cannot be formulated as a simple suffix rule.
10050 for lang in $ALL_LINGUAS; do
10051 frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
10052 cat >> "$ac_file.tmp" <<EOF
10053 $frobbedlang.msg: $lang.po
10054 @echo "\$(MSGFMT) -c --tcl -d \$(srcdir) -l $lang $srcdirpre$lang.po"; \
10055 \$(MSGFMT) -c --tcl -d "\$(srcdir)" -l $lang $srcdirpre$lang.po || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
10059 if grep -l '@CSHARPCATALOGS@' "$ac_file" > /dev/null; then
10060 # Add dependencies that cannot be formulated as a simple suffix rule.
10061 for lang in $ALL_LINGUAS; do
10062 frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
10063 cat >> "$ac_file.tmp" <<EOF
10064 $frobbedlang/\$(DOMAIN).resources.dll: $lang.po
10065 @echo "\$(MSGFMT) -c --csharp -d \$(srcdir) -l $lang $srcdirpre$lang.po -r \$(DOMAIN)"; \
10066 \$(MSGFMT) -c --csharp -d "\$(srcdir)" -l $lang $srcdirpre$lang.po -r "\$(DOMAIN)" || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
10070 if test -n "$POMAKEFILEDEPS"; then
10071 cat >> "$ac_file.tmp" <<EOF
10072 Makefile: $POMAKEFILEDEPS
10075 mv "$ac_file.tmp" "$ac_file"
10078 dnl Initializes the accumulator used by AM_XGETTEXT_OPTION.
10079 AC_DEFUN([AM_XGETTEXT_OPTION_INIT],
10081 XGETTEXT_EXTRA_OPTIONS=
10084 dnl Registers an option to be passed to xgettext in the po subdirectory.
10085 AC_DEFUN([AM_XGETTEXT_OPTION],
10087 AC_REQUIRE([AM_XGETTEXT_OPTION_INIT])
10088 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS $1"
10091 # progtest.m4 serial 4 (gettext-0.14.2)
10092 dnl Copyright (C) 1996-2003, 2005 Free Software Foundation, Inc.
10093 dnl This file is free software; the Free Software Foundation
10094 dnl gives unlimited permission to copy and/or distribute it,
10095 dnl with or without modifications, as long as this notice is preserved.
10097 dnl This file can can be used in projects which are not available under
10098 dnl the GNU General Public License or the GNU Library General Public
10099 dnl License but which still want to provide support for the GNU gettext
10101 dnl Please note that the actual code of the GNU gettext library is covered
10102 dnl by the GNU Library General Public License, and the rest of the GNU
10103 dnl gettext package package is covered by the GNU General Public License.
10104 dnl They are *not* in the public domain.
10107 dnl Ulrich Drepper <drepper@cygnus.com>, 1996.
10111 # Search path for a program which passes the given test.
10113 dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
10114 dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
10115 AC_DEFUN([AM_PATH_PROG_WITH_TEST],
10117 # Prepare PATH_SEPARATOR.
10118 # The user is always right.
10119 if test "${PATH_SEPARATOR+set}" != set; then
10120 echo "#! /bin/sh" >conf$$.sh
10121 echo "exit 0" >>conf$$.sh
10123 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
10131 # Find out how to test for executable files. Don't use a zero-byte file,
10132 # as systems may use methods other than mode bits to determine executability.
10133 cat >conf$$.file <<_ASEOF
10137 chmod +x conf$$.file
10138 if test -x conf$$.file >/dev/null 2>&1; then
10139 ac_executable_p="test -x"
10141 ac_executable_p="test -f"
10145 # Extract the first word of "$2", so it can be a program name with args.
10146 set dummy $2; ac_word=[$]2
10147 AC_MSG_CHECKING([for $ac_word])
10148 AC_CACHE_VAL(ac_cv_path_$1,
10150 [[\\/]]* | ?:[[\\/]]*)
10151 ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
10154 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
10155 for ac_dir in ifelse([$5], , $PATH, [$5]); do
10157 test -z "$ac_dir" && ac_dir=.
10158 for ac_exec_ext in '' $ac_executable_extensions; do
10159 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
10160 echo "$as_me: trying $ac_dir/$ac_word..." >&AS_MESSAGE_LOG_FD
10162 ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext"
10169 dnl If no 4th arg is given, leave the cache variable unset,
10170 dnl so AC_PATH_PROGS will keep looking.
10171 ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
10175 $1="$ac_cv_path_$1"
10176 if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
10177 AC_MSG_RESULT([$]$1)
10184 # Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
10186 # This file is free software; the Free Software Foundation
10187 # gives unlimited permission to copy and/or distribute it,
10188 # with or without modifications, as long as this notice is preserved.
10190 # AM_AUTOMAKE_VERSION(VERSION)
10191 # ----------------------------
10192 # Automake X.Y traces this macro to ensure aclocal.m4 has been
10193 # generated from the m4 files accompanying Automake X.Y.
10194 # (This private macro should not be called outside this file.)
10195 AC_DEFUN([AM_AUTOMAKE_VERSION],
10196 [am__api_version='1.10'
10197 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
10198 dnl require some minimum version. Point them to the right macro.
10199 m4_if([$1], [1.10.2], [],
10200 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
10203 # _AM_AUTOCONF_VERSION(VERSION)
10204 # -----------------------------
10205 # aclocal traces this macro to find the Autoconf version.
10206 # This is a private macro too. Using m4_define simplifies
10207 # the logic in aclocal, which can simply ignore this definition.
10208 m4_define([_AM_AUTOCONF_VERSION], [])
10210 # AM_SET_CURRENT_AUTOMAKE_VERSION
10211 # -------------------------------
10212 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
10213 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
10214 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
10215 [AM_AUTOMAKE_VERSION([1.10.2])dnl
10216 m4_ifndef([AC_AUTOCONF_VERSION],
10217 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
10218 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
10220 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
10222 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
10224 # This file is free software; the Free Software Foundation
10225 # gives unlimited permission to copy and/or distribute it,
10226 # with or without modifications, as long as this notice is preserved.
10228 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
10229 # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
10230 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
10232 # Of course, Automake must honor this variable whenever it calls a
10233 # tool from the auxiliary directory. The problem is that $srcdir (and
10234 # therefore $ac_aux_dir as well) can be either absolute or relative,
10235 # depending on how configure is run. This is pretty annoying, since
10236 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
10237 # source directory, any form will work fine, but in subdirectories a
10238 # relative path needs to be adjusted first.
10240 # $ac_aux_dir/missing
10241 # fails when called from a subdirectory if $ac_aux_dir is relative
10242 # $top_srcdir/$ac_aux_dir/missing
10243 # fails if $ac_aux_dir is absolute,
10244 # fails when called from a subdirectory in a VPATH build with
10245 # a relative $ac_aux_dir
10247 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
10248 # are both prefixed by $srcdir. In an in-source build this is usually
10249 # harmless because $srcdir is `.', but things will broke when you
10250 # start a VPATH build or use an absolute $srcdir.
10252 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
10253 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
10254 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
10255 # and then we would define $MISSING as
10256 # MISSING="\${SHELL} $am_aux_dir/missing"
10257 # This will work as long as MISSING is not called from configure, because
10258 # unfortunately $(top_srcdir) has no meaning in configure.
10259 # However there are other variables, like CC, which are often used in
10260 # configure, and could therefore not use this "fixed" $ac_aux_dir.
10262 # Another solution, used here, is to always expand $ac_aux_dir to an
10263 # absolute PATH. The drawback is that using absolute paths prevent a
10264 # configured tree to be moved without reconfiguration.
10266 AC_DEFUN([AM_AUX_DIR_EXPAND],
10267 [dnl Rely on autoconf to set up CDPATH properly.
10268 AC_PREREQ([2.50])dnl
10269 # expand $ac_aux_dir to an absolute path
10270 am_aux_dir=`cd $ac_aux_dir && pwd`
10273 # AM_CONDITIONAL -*- Autoconf -*-
10275 # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
10276 # Free Software Foundation, Inc.
10278 # This file is free software; the Free Software Foundation
10279 # gives unlimited permission to copy and/or distribute it,
10280 # with or without modifications, as long as this notice is preserved.
10284 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
10285 # -------------------------------------
10286 # Define a conditional.
10287 AC_DEFUN([AM_CONDITIONAL],
10288 [AC_PREREQ(2.52)dnl
10289 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
10290 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
10291 AC_SUBST([$1_TRUE])dnl
10292 AC_SUBST([$1_FALSE])dnl
10293 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
10294 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
10302 AC_CONFIG_COMMANDS_PRE(
10303 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
10304 AC_MSG_ERROR([[conditional "$1" was never defined.
10305 Usually this means the macro was only invoked conditionally.]])
10308 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
10309 # Free Software Foundation, Inc.
10311 # This file is free software; the Free Software Foundation
10312 # gives unlimited permission to copy and/or distribute it,
10313 # with or without modifications, as long as this notice is preserved.
10317 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
10318 # written in clear, in which case automake, when reading aclocal.m4,
10319 # will think it sees a *use*, and therefore will trigger all it's
10320 # C support machinery. Also note that it means that autoscan, seeing
10321 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
10324 # _AM_DEPENDENCIES(NAME)
10325 # ----------------------
10326 # See how the compiler implements dependency checking.
10327 # NAME is "CC", "CXX", "GCJ", or "OBJC".
10328 # We try a few techniques and use that to set a single cache variable.
10330 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
10331 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
10332 # dependency, and given that the user is not expected to run this macro,
10333 # just rely on AC_PROG_CC.
10334 AC_DEFUN([_AM_DEPENDENCIES],
10335 [AC_REQUIRE([AM_SET_DEPDIR])dnl
10336 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
10337 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
10338 AC_REQUIRE([AM_DEP_TRACK])dnl
10340 ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
10341 [$1], CXX, [depcc="$CXX" am_compiler_list=],
10342 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
10343 [$1], UPC, [depcc="$UPC" am_compiler_list=],
10344 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
10345 [depcc="$$1" am_compiler_list=])
10347 AC_CACHE_CHECK([dependency style of $depcc],
10348 [am_cv_$1_dependencies_compiler_type],
10349 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
10350 # We make a subdir and do the tests there. Otherwise we can end up
10351 # making bogus files that we don't know about and never remove. For
10352 # instance it was reported that on HP-UX the gcc test will end up
10353 # making a dummy file named `D' -- because `-MD' means `put the output
10356 # Copy depcomp to subdir because otherwise we won't find it if we're
10357 # using a relative directory.
10358 cp "$am_depcomp" conftest.dir
10360 # We will build objects and dependencies in a subdirectory because
10361 # it helps to detect inapplicable dependency modes. For instance
10362 # both Tru64's cc and ICC support -MD to output dependencies as a
10363 # side effect of compilation, but ICC will put the dependencies in
10364 # the current directory while Tru64 will put them in the object
10368 am_cv_$1_dependencies_compiler_type=none
10369 if test "$am_compiler_list" = ""; then
10370 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
10372 for depmode in $am_compiler_list; do
10373 # Setup a source with many dependencies, because some compilers
10374 # like to wrap large dependency lists on column 80 (with \), and
10375 # we should not choose a depcomp mode which is confused by this.
10377 # We need to recreate these files for each test, as the compiler may
10378 # overwrite some of them when testing with obscure command lines.
10379 # This happens at least with the AIX C compiler.
10381 for i in 1 2 3 4 5 6; do
10382 echo '#include "conftst'$i'.h"' >> sub/conftest.c
10383 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
10384 # Solaris 8's {/usr,}/bin/sh.
10385 touch sub/conftst$i.h
10387 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
10391 # after this tag, mechanisms are not by side-effect, so they'll
10392 # only be used when explicitly requested
10393 if test "x$enable_dependency_tracking" = xyes; then
10401 # We check with `-c' and `-o' for the sake of the "dashmstdout"
10402 # mode. It turns out that the SunPro C++ compiler does not properly
10403 # handle `-M -o', and we need to detect this.
10404 if depmode=$depmode \
10405 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
10406 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
10407 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
10408 >/dev/null 2>conftest.err &&
10409 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
10410 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
10411 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
10412 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
10413 # icc doesn't choke on unknown options, it will just issue warnings
10414 # or remarks (even with -Werror). So we grep stderr for any message
10415 # that says an option was ignored or not supported.
10416 # When given -MP, icc 7.0 and 7.1 complain thusly:
10417 # icc: Command line warning: ignoring option '-M'; no argument required
10418 # The diagnosis changed in icc 8.0:
10419 # icc: Command line remark: option '-MP' not supported
10420 if (grep 'ignoring option' conftest.err ||
10421 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
10422 am_cv_$1_dependencies_compiler_type=$depmode
10429 rm -rf conftest.dir
10431 am_cv_$1_dependencies_compiler_type=none
10434 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
10435 AM_CONDITIONAL([am__fastdep$1], [
10436 test "x$enable_dependency_tracking" != xno \
10437 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
10443 # Choose a directory name for dependency files.
10444 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
10445 AC_DEFUN([AM_SET_DEPDIR],
10446 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10447 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
10453 AC_DEFUN([AM_DEP_TRACK],
10454 [AC_ARG_ENABLE(dependency-tracking,
10455 [ --disable-dependency-tracking speeds up one-time build
10456 --enable-dependency-tracking do not reject slow dependency extractors])
10457 if test "x$enable_dependency_tracking" != xno; then
10458 am_depcomp="$ac_aux_dir/depcomp"
10461 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
10462 AC_SUBST([AMDEPBACKSLASH])dnl
10463 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
10466 # Generate code to set up dependency tracking. -*- Autoconf -*-
10468 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
10469 # Free Software Foundation, Inc.
10471 # This file is free software; the Free Software Foundation
10472 # gives unlimited permission to copy and/or distribute it,
10473 # with or without modifications, as long as this notice is preserved.
10477 # _AM_OUTPUT_DEPENDENCY_COMMANDS
10478 # ------------------------------
10479 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
10480 [# Autoconf 2.62 quotes --file arguments for eval, but not when files
10481 # are listed without --file. Let's play safe and only enable the eval
10482 # if we detect the quoting.
10483 case $CONFIG_FILES in
10484 *\'*) eval set x "$CONFIG_FILES" ;;
10485 *) set x $CONFIG_FILES ;;
10490 # Strip MF so we end up with the name of the file.
10491 mf=`echo "$mf" | sed -e 's/:.*$//'`
10492 # Check whether this is an Automake generated Makefile or not.
10493 # We used to match only the files named `Makefile.in', but
10494 # some people rename them; so instead we look at the file content.
10495 # Grep'ing the first line is not enough: some people post-process
10496 # each Makefile.in and add a new line on top of each file to say so.
10497 # Grep'ing the whole file is not good either: AIX grep has a line
10498 # limit of 2048, but all sed's we know have understand at least 4000.
10499 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
10500 dirpart=`AS_DIRNAME("$mf")`
10504 # Extract the definition of DEPDIR, am__include, and am__quote
10505 # from the Makefile without running `make'.
10506 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
10507 test -z "$DEPDIR" && continue
10508 am__include=`sed -n 's/^am__include = //p' < "$mf"`
10509 test -z "am__include" && continue
10510 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
10511 # When using ansi2knr, U may be empty or an underscore; expand it
10512 U=`sed -n 's/^U = //p' < "$mf"`
10513 # Find all dependency output files, they are included files with
10514 # $(DEPDIR) in their names. We invoke sed twice because it is the
10515 # simplest approach to changing $(DEPDIR) to its actual value in the
10517 for file in `sed -n "
10518 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
10519 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
10520 # Make sure the directory exists.
10521 test -f "$dirpart/$file" && continue
10522 fdir=`AS_DIRNAME(["$file"])`
10523 AS_MKDIR_P([$dirpart/$fdir])
10524 # echo "creating $dirpart/$file"
10525 echo '# dummy' > "$dirpart/$file"
10528 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
10531 # AM_OUTPUT_DEPENDENCY_COMMANDS
10532 # -----------------------------
10533 # This macro should only be invoked once -- use via AC_REQUIRE.
10535 # This code is only required when automatic dependency tracking
10536 # is enabled. FIXME. This creates each `.P' file that we will
10537 # need in order to bootstrap the dependency handling code.
10538 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
10539 [AC_CONFIG_COMMANDS([depfiles],
10540 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
10541 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
10544 # Do all the work for Automake. -*- Autoconf -*-
10546 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
10547 # 2005, 2006, 2008 Free Software Foundation, Inc.
10549 # This file is free software; the Free Software Foundation
10550 # gives unlimited permission to copy and/or distribute it,
10551 # with or without modifications, as long as this notice is preserved.
10555 # This macro actually does too much. Some checks are only needed if
10556 # your package does certain things. But this isn't really a big deal.
10558 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
10559 # AM_INIT_AUTOMAKE([OPTIONS])
10560 # -----------------------------------------------
10561 # The call with PACKAGE and VERSION arguments is the old style
10562 # call (pre autoconf-2.50), which is being phased out. PACKAGE
10563 # and VERSION should now be passed to AC_INIT and removed from
10564 # the call to AM_INIT_AUTOMAKE.
10565 # We support both call styles for the transition. After
10566 # the next Automake release, Autoconf can make the AC_INIT
10567 # arguments mandatory, and then we can depend on a new Autoconf
10568 # release and drop the old call support.
10569 AC_DEFUN([AM_INIT_AUTOMAKE],
10570 [AC_PREREQ([2.60])dnl
10571 dnl Autoconf wants to disallow AM_ names. We explicitly allow
10572 dnl the ones we care about.
10573 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
10574 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
10575 AC_REQUIRE([AC_PROG_INSTALL])dnl
10576 if test "`cd $srcdir && pwd`" != "`pwd`"; then
10577 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
10578 # is not polluted with repeated "-I."
10579 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
10580 # test to see if srcdir already configured
10581 if test -f $srcdir/config.status; then
10582 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
10586 # test whether we have cygpath
10587 if test -z "$CYGPATH_W"; then
10588 if (cygpath --version) >/dev/null 2>/dev/null; then
10589 CYGPATH_W='cygpath -w'
10594 AC_SUBST([CYGPATH_W])
10596 # Define the identity of the package.
10597 dnl Distinguish between old-style and new-style calls.
10599 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
10600 AC_SUBST([PACKAGE], [$1])dnl
10601 AC_SUBST([VERSION], [$2])],
10602 [_AM_SET_OPTIONS([$1])dnl
10603 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
10604 m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
10605 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
10606 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
10607 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
10609 _AM_IF_OPTION([no-define],,
10610 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
10611 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
10613 # Some tools Automake needs.
10614 AC_REQUIRE([AM_SANITY_CHECK])dnl
10615 AC_REQUIRE([AC_ARG_PROGRAM])dnl
10616 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
10617 AM_MISSING_PROG(AUTOCONF, autoconf)
10618 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
10619 AM_MISSING_PROG(AUTOHEADER, autoheader)
10620 AM_MISSING_PROG(MAKEINFO, makeinfo)
10622 AM_PROG_INSTALL_STRIP
10623 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
10624 # We need awk for the "check" target. The system "awk" is bad on
10626 AC_REQUIRE([AC_PROG_AWK])dnl
10627 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
10628 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10629 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
10630 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
10631 [_AM_PROG_TAR([v7])])])
10632 _AM_IF_OPTION([no-dependencies],,
10633 [AC_PROVIDE_IFELSE([AC_PROG_CC],
10634 [_AM_DEPENDENCIES(CC)],
10635 [define([AC_PROG_CC],
10636 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
10637 AC_PROVIDE_IFELSE([AC_PROG_CXX],
10638 [_AM_DEPENDENCIES(CXX)],
10639 [define([AC_PROG_CXX],
10640 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
10641 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
10642 [_AM_DEPENDENCIES(OBJC)],
10643 [define([AC_PROG_OBJC],
10644 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
10649 # When config.status generates a header, we must update the stamp-h file.
10650 # This file resides in the same directory as the config header
10651 # that is generated. The stamp files are numbered to have different names.
10653 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
10654 # loop where config.status creates the headers, so we can generate
10655 # our stamp files there.
10656 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
10657 [# Compute $1's index in $config_headers.
10660 for _am_header in $config_headers :; do
10661 case $_am_header in
10662 $_am_arg | $_am_arg:* )
10665 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
10668 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
10670 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
10672 # This file is free software; the Free Software Foundation
10673 # gives unlimited permission to copy and/or distribute it,
10674 # with or without modifications, as long as this notice is preserved.
10676 # AM_PROG_INSTALL_SH
10677 # ------------------
10678 # Define $install_sh.
10679 AC_DEFUN([AM_PROG_INSTALL_SH],
10680 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10681 install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
10682 AC_SUBST(install_sh)])
10684 # Copyright (C) 2003, 2005 Free Software Foundation, Inc.
10686 # This file is free software; the Free Software Foundation
10687 # gives unlimited permission to copy and/or distribute it,
10688 # with or without modifications, as long as this notice is preserved.
10692 # Check whether the underlying file-system supports filenames
10693 # with a leading dot. For instance MS-DOS doesn't.
10694 AC_DEFUN([AM_SET_LEADING_DOT],
10695 [rm -rf .tst 2>/dev/null
10696 mkdir .tst 2>/dev/null
10697 if test -d .tst; then
10702 rmdir .tst 2>/dev/null
10703 AC_SUBST([am__leading_dot])])
10705 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
10706 # From Jim Meyering
10708 # Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005
10709 # Free Software Foundation, Inc.
10711 # This file is free software; the Free Software Foundation
10712 # gives unlimited permission to copy and/or distribute it,
10713 # with or without modifications, as long as this notice is preserved.
10717 AC_DEFUN([AM_MAINTAINER_MODE],
10718 [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
10719 dnl maintainer-mode is disabled by default
10720 AC_ARG_ENABLE(maintainer-mode,
10721 [ --enable-maintainer-mode enable make rules and dependencies not useful
10722 (and sometimes confusing) to the casual installer],
10723 USE_MAINTAINER_MODE=$enableval,
10724 USE_MAINTAINER_MODE=no)
10725 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
10726 AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
10727 MAINT=$MAINTAINER_MODE_TRUE
10732 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
10734 # Check to see how 'make' treats includes. -*- Autoconf -*-
10736 # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
10738 # This file is free software; the Free Software Foundation
10739 # gives unlimited permission to copy and/or distribute it,
10740 # with or without modifications, as long as this notice is preserved.
10744 # AM_MAKE_INCLUDE()
10745 # -----------------
10746 # Check to see how make treats includes.
10747 AC_DEFUN([AM_MAKE_INCLUDE],
10748 [am_make=${MAKE-make}
10749 cat > confinc << 'END'
10754 # If we don't find an include directive, just comment out the code.
10755 AC_MSG_CHECKING([for style of include used by $am_make])
10759 # First try GNU make style include.
10760 echo "include confinc" > confmf
10761 # We grep out `Entering directory' and `Leaving directory'
10762 # messages which can occur if `w' ends up in MAKEFLAGS.
10763 # In particular we don't look at `^make:' because GNU make might
10764 # be invoked under some other name (usually "gmake"), in which
10765 # case it prints its new name instead of `make'.
10766 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
10767 am__include=include
10771 # Now try BSD make style include.
10772 if test "$am__include" = "#"; then
10773 echo '.include "confinc"' > confmf
10774 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
10775 am__include=.include
10780 AC_SUBST([am__include])
10781 AC_SUBST([am__quote])
10782 AC_MSG_RESULT([$_am_result])
10783 rm -f confinc confmf
10786 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
10788 # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
10789 # Free Software Foundation, Inc.
10791 # This file is free software; the Free Software Foundation
10792 # gives unlimited permission to copy and/or distribute it,
10793 # with or without modifications, as long as this notice is preserved.
10797 # AM_MISSING_PROG(NAME, PROGRAM)
10798 # ------------------------------
10799 AC_DEFUN([AM_MISSING_PROG],
10800 [AC_REQUIRE([AM_MISSING_HAS_RUN])
10801 $1=${$1-"${am_missing_run}$2"}
10805 # AM_MISSING_HAS_RUN
10806 # ------------------
10807 # Define MISSING if not defined so far and test if it supports --run.
10808 # If it does, set am_missing_run to use it, otherwise, to nothing.
10809 AC_DEFUN([AM_MISSING_HAS_RUN],
10810 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10811 AC_REQUIRE_AUX_FILE([missing])dnl
10812 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
10813 # Use eval to expand $SHELL
10814 if eval "$MISSING --run true"; then
10815 am_missing_run="$MISSING --run "
10818 AC_MSG_WARN([`missing' script is too old or missing])
10822 # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
10824 # This file is free software; the Free Software Foundation
10825 # gives unlimited permission to copy and/or distribute it,
10826 # with or without modifications, as long as this notice is preserved.
10830 # Check for `mkdir -p'.
10831 AC_DEFUN([AM_PROG_MKDIR_P],
10832 [AC_PREREQ([2.60])dnl
10833 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
10834 dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
10835 dnl while keeping a definition of mkdir_p for backward compatibility.
10836 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
10837 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
10838 dnl Makefile.ins that do not define MKDIR_P, so we do our own
10839 dnl adjustment using top_builddir (which is defined more often than
10841 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
10843 [[\\/$]]* | ?:[[\\/]]*) ;;
10844 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
10848 # Helper functions for option handling. -*- Autoconf -*-
10850 # Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc.
10852 # This file is free software; the Free Software Foundation
10853 # gives unlimited permission to copy and/or distribute it,
10854 # with or without modifications, as long as this notice is preserved.
10858 # _AM_MANGLE_OPTION(NAME)
10859 # -----------------------
10860 AC_DEFUN([_AM_MANGLE_OPTION],
10861 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
10863 # _AM_SET_OPTION(NAME)
10864 # ------------------------------
10865 # Set option NAME. Presently that only means defining a flag for this option.
10866 AC_DEFUN([_AM_SET_OPTION],
10867 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
10869 # _AM_SET_OPTIONS(OPTIONS)
10870 # ----------------------------------
10871 # OPTIONS is a space-separated list of Automake options.
10872 AC_DEFUN([_AM_SET_OPTIONS],
10873 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
10875 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
10876 # -------------------------------------------
10877 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
10878 AC_DEFUN([_AM_IF_OPTION],
10879 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
10881 # Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2005, 2006
10882 # Free Software Foundation, Inc.
10884 # This file is free software; the Free Software Foundation
10885 # gives unlimited permission to copy and/or distribute it,
10886 # with or without modifications, as long as this notice is preserved.
10890 AC_DEFUN([AM_C_PROTOTYPES],
10891 [AC_REQUIRE([AC_C_PROTOTYPES])
10892 if test "$ac_cv_prog_cc_stdc" != no; then
10895 U=_ ANSI2KNR=./ansi2knr
10897 # Ensure some checks needed by ansi2knr itself.
10898 AC_REQUIRE([AC_HEADER_STDC])
10899 AC_CHECK_HEADERS([string.h])
10901 AC_SUBST([ANSI2KNR])dnl
10902 _AM_SUBST_NOTMAKE([ANSI2KNR])dnl
10905 AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES])
10907 # Check to make sure that the build environment is sane. -*- Autoconf -*-
10909 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
10910 # Free Software Foundation, Inc.
10912 # This file is free software; the Free Software Foundation
10913 # gives unlimited permission to copy and/or distribute it,
10914 # with or without modifications, as long as this notice is preserved.
10920 AC_DEFUN([AM_SANITY_CHECK],
10921 [AC_MSG_CHECKING([whether build environment is sane])
10924 echo timestamp > conftest.file
10925 # Do `set' in a subshell so we don't clobber the current shell's
10926 # arguments. Must try -L first in case configure is actually a
10927 # symlink; some systems play weird games with the mod time of symlinks
10928 # (eg FreeBSD returns the mod time of the symlink's containing
10931 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
10932 if test "$[*]" = "X"; then
10934 set X `ls -t $srcdir/configure conftest.file`
10936 rm -f conftest.file
10937 if test "$[*]" != "X $srcdir/configure conftest.file" \
10938 && test "$[*]" != "X conftest.file $srcdir/configure"; then
10940 # If neither matched, then we have a broken ls. This can happen
10941 # if, for instance, CONFIG_SHELL is bash and it inherits a
10942 # broken ls alias from the environment. This has actually
10943 # happened. Such a system could not be considered "sane".
10944 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
10945 alias in your environment])
10948 test "$[2]" = conftest.file
10954 AC_MSG_ERROR([newly created file is older than distributed files!
10955 Check your system clock])
10957 AC_MSG_RESULT(yes)])
10959 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
10961 # This file is free software; the Free Software Foundation
10962 # gives unlimited permission to copy and/or distribute it,
10963 # with or without modifications, as long as this notice is preserved.
10965 # AM_PROG_INSTALL_STRIP
10966 # ---------------------
10967 # One issue with vendor `install' (even GNU) is that you can't
10968 # specify the program used to strip binaries. This is especially
10969 # annoying in cross-compiling environments, where the build's strip
10970 # is unlikely to handle the host's binaries.
10971 # Fortunately install-sh will honor a STRIPPROG variable, so we
10972 # always use install-sh in `make install-strip', and initialize
10973 # STRIPPROG with the value of the STRIP variable (set by the user).
10974 AC_DEFUN([AM_PROG_INSTALL_STRIP],
10975 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10976 # Installed binaries are usually stripped using `strip' when the user
10977 # run `make install-strip'. However `strip' might not be the right
10978 # tool to use in cross-compilation environments, therefore Automake
10979 # will honor the `STRIP' environment variable to overrule this program.
10980 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
10981 if test "$cross_compiling" != no; then
10982 AC_CHECK_TOOL([STRIP], [strip], :)
10984 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
10985 AC_SUBST([INSTALL_STRIP_PROGRAM])])
10987 # Copyright (C) 2006 Free Software Foundation, Inc.
10989 # This file is free software; the Free Software Foundation
10990 # gives unlimited permission to copy and/or distribute it,
10991 # with or without modifications, as long as this notice is preserved.
10993 # _AM_SUBST_NOTMAKE(VARIABLE)
10994 # ---------------------------
10995 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
10996 # This macro is traced by Automake.
10997 AC_DEFUN([_AM_SUBST_NOTMAKE])
10999 # Check how to create a tarball. -*- Autoconf -*-
11001 # Copyright (C) 2004, 2005 Free Software Foundation, Inc.
11003 # This file is free software; the Free Software Foundation
11004 # gives unlimited permission to copy and/or distribute it,
11005 # with or without modifications, as long as this notice is preserved.
11009 # _AM_PROG_TAR(FORMAT)
11010 # --------------------
11011 # Check how to create a tarball in format FORMAT.
11012 # FORMAT should be one of `v7', `ustar', or `pax'.
11014 # Substitute a variable $(am__tar) that is a command
11015 # writing to stdout a FORMAT-tarball containing the directory
11017 # tardir=directory && $(am__tar) > result.tar
11019 # Substitute a variable $(am__untar) that extract such
11020 # a tarball read from stdin.
11021 # $(am__untar) < result.tar
11022 AC_DEFUN([_AM_PROG_TAR],
11023 [# Always define AMTAR for backward compatibility.
11024 AM_MISSING_PROG([AMTAR], [tar])
11026 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
11027 [m4_case([$1], [ustar],, [pax],,
11028 [m4_fatal([Unknown tar format])])
11029 AC_MSG_CHECKING([how to create a $1 tar archive])
11030 # Loop over all known methods to create a tar archive until one works.
11031 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
11032 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
11033 # Do not fold the above two line into one, because Tru64 sh and
11034 # Solaris sh will not grok spaces in the rhs of `-'.
11035 for _am_tool in $_am_tools
11039 for _am_tar in tar gnutar gtar;
11041 AM_RUN_LOG([$_am_tar --version]) && break
11043 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
11044 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
11045 am__untar="$_am_tar -xf -"
11048 # Must skip GNU tar: if it does not support --format= it doesn't create
11049 # ustar tarball either.
11050 (tar --version) >/dev/null 2>&1 && continue
11051 am__tar='tar chf - "$$tardir"'
11052 am__tar_='tar chf - "$tardir"'
11053 am__untar='tar xf -'
11056 am__tar='pax -L -x $1 -w "$$tardir"'
11057 am__tar_='pax -L -x $1 -w "$tardir"'
11061 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
11062 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
11063 am__untar='cpio -i -H $1 -d'
11072 # If the value was cached, stop now. We just wanted to have am__tar
11073 # and am__untar set.
11074 test -n "${am_cv_prog_tar_$1}" && break
11076 # tar/untar a dummy directory, and stop if the command works
11077 rm -rf conftest.dir
11079 echo GrepMe > conftest.dir/file
11080 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
11081 rm -rf conftest.dir
11082 if test -s conftest.tar; then
11083 AM_RUN_LOG([$am__untar <conftest.tar])
11084 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
11087 rm -rf conftest.dir
11089 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
11090 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
11091 AC_SUBST([am__tar])
11092 AC_SUBST([am__untar])
11095 m4_include([acinclude.m4])