1 # generated automatically by aclocal 1.15 -*- Autoconf -*-
3 # Copyright (C) 1996-2014 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_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
15 m4_ifndef([AC_AUTOCONF_VERSION],
16 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
17 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
18 [m4_warning([this file was generated for autoconf 2.69.
19 You have another version of autoconf. It may work, but is not guaranteed to.
20 If you have problems, you may need to regenerate the build system entirely.
21 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
23 # Configure paths for GLIB
24 # Owen Taylor 1997-2001
26 dnl AM_PATH_GLIB_2_0([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]])
27 dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if gmodule, gobject,
28 dnl gthread, or gio is specified in MODULES, pass to pkg-config
30 AC_DEFUN([AM_PATH_GLIB_2_0],
32 dnl Get the cflags and libraries from pkg-config
34 AC_ARG_ENABLE(glibtest, [ --disable-glibtest do not try to compile and run a test GLIB program],
35 , enable_glibtest=yes)
37 pkg_config_args=glib-2.0
42 pkg_config_args="$pkg_config_args gmodule-2.0"
45 pkg_config_args="$pkg_config_args gmodule-no-export-2.0"
48 pkg_config_args="$pkg_config_args gobject-2.0"
51 pkg_config_args="$pkg_config_args gthread-2.0"
54 pkg_config_args="$pkg_config_args $module-2.0"
59 PKG_PROG_PKG_CONFIG([0.16])
63 if test "x$PKG_CONFIG" = x ; then
68 min_glib_version=ifelse([$1], ,2.0.0,$1)
69 AC_MSG_CHECKING(for GLIB - version >= $min_glib_version)
71 if test x$PKG_CONFIG != xno ; then
72 ## don't try to run the test against uninstalled libtool libs
73 if $PKG_CONFIG --uninstalled $pkg_config_args; then
74 echo "Will use uninstalled version of GLib found in PKG_CONFIG_PATH"
78 if $PKG_CONFIG --atleast-version $min_glib_version $pkg_config_args; then
85 if test x"$no_glib" = x ; then
86 GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
87 GOBJECT_QUERY=`$PKG_CONFIG --variable=gobject_query glib-2.0`
88 GLIB_MKENUMS=`$PKG_CONFIG --variable=glib_mkenums glib-2.0`
89 GLIB_COMPILE_RESOURCES=`$PKG_CONFIG --variable=glib_compile_resources gio-2.0`
91 GLIB_CFLAGS=`$PKG_CONFIG --cflags $pkg_config_args`
92 GLIB_LIBS=`$PKG_CONFIG --libs $pkg_config_args`
93 glib_config_major_version=`$PKG_CONFIG --modversion glib-2.0 | \
94 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
95 glib_config_minor_version=`$PKG_CONFIG --modversion glib-2.0 | \
96 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
97 glib_config_micro_version=`$PKG_CONFIG --modversion glib-2.0 | \
98 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
99 if test "x$enable_glibtest" = "xyes" ; then
100 ac_save_CFLAGS="$CFLAGS"
102 CFLAGS="$CFLAGS $GLIB_CFLAGS"
103 LIBS="$GLIB_LIBS $LIBS"
105 dnl Now check if the installed GLIB is sufficiently new. (Also sanity
106 dnl checks the results of pkg-config to some extent)
117 unsigned int major, minor, micro;
119 fclose (fopen ("conf.glibtest", "w"));
121 if (sscanf("$min_glib_version", "%u.%u.%u", &major, &minor, µ) != 3) {
122 printf("%s, bad version string\n", "$min_glib_version");
126 if ((glib_major_version != $glib_config_major_version) ||
127 (glib_minor_version != $glib_config_minor_version) ||
128 (glib_micro_version != $glib_config_micro_version))
130 printf("\n*** 'pkg-config --modversion glib-2.0' returned %d.%d.%d, but GLIB (%d.%d.%d)\n",
131 $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version,
132 glib_major_version, glib_minor_version, glib_micro_version);
133 printf ("*** was found! If pkg-config was correct, then it is best\n");
134 printf ("*** to remove the old version of GLib. You may also be able to fix the error\n");
135 printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
136 printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
137 printf("*** required on your system.\n");
138 printf("*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH\n");
139 printf("*** to point to the correct configuration files\n");
141 else if ((glib_major_version != GLIB_MAJOR_VERSION) ||
142 (glib_minor_version != GLIB_MINOR_VERSION) ||
143 (glib_micro_version != GLIB_MICRO_VERSION))
145 printf("*** GLIB header files (version %d.%d.%d) do not match\n",
146 GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION);
147 printf("*** library (version %d.%d.%d)\n",
148 glib_major_version, glib_minor_version, glib_micro_version);
152 if ((glib_major_version > major) ||
153 ((glib_major_version == major) && (glib_minor_version > minor)) ||
154 ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro)))
160 printf("\n*** An old version of GLIB (%u.%u.%u) was found.\n",
161 glib_major_version, glib_minor_version, glib_micro_version);
162 printf("*** You need a version of GLIB newer than %u.%u.%u. The latest version of\n",
163 major, minor, micro);
164 printf("*** GLIB is always available from ftp://ftp.gtk.org.\n");
166 printf("*** If you have already installed a sufficiently new version, this error\n");
167 printf("*** probably means that the wrong copy of the pkg-config shell script is\n");
168 printf("*** being found. The easiest way to fix this is to remove the old version\n");
169 printf("*** of GLIB, but you can also set the PKG_CONFIG environment to point to the\n");
170 printf("*** correct copy of pkg-config. (In this case, you will have to\n");
171 printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
172 printf("*** so that the correct libraries are found at run-time))\n");
177 ],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
178 CFLAGS="$ac_save_CFLAGS"
182 if test "x$no_glib" = x ; then
183 AC_MSG_RESULT(yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version))
184 ifelse([$2], , :, [$2])
187 if test "$PKG_CONFIG" = "no" ; then
188 echo "*** A new enough version of pkg-config was not found."
189 echo "*** See http://www.freedesktop.org/software/pkgconfig/"
191 if test -f conf.glibtest ; then
194 echo "*** Could not run GLIB test program, checking why..."
195 ac_save_CFLAGS="$CFLAGS"
197 CFLAGS="$CFLAGS $GLIB_CFLAGS"
198 LIBS="$LIBS $GLIB_LIBS"
202 ], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ],
203 [ echo "*** The test program compiled, but did not run. This usually means"
204 echo "*** that the run-time linker is not finding GLIB or finding the wrong"
205 echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your"
206 echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
207 echo "*** to the installed location Also, make sure you have run ldconfig if that"
208 echo "*** is required on your system"
210 echo "*** If you have an old version installed, it is best to remove it, although"
211 echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ],
212 [ echo "*** The test program failed to compile or link. See the file config.log for the"
213 echo "*** exact error that occured. This usually means GLIB is incorrectly installed."])
214 CFLAGS="$ac_save_CFLAGS"
223 GLIB_COMPILE_RESOURCES=""
224 ifelse([$3], , :, [$3])
226 AC_SUBST(GLIB_CFLAGS)
228 AC_SUBST(GLIB_GENMARSHAL)
229 AC_SUBST(GOBJECT_QUERY)
230 AC_SUBST(GLIB_MKENUMS)
231 AC_SUBST(GLIB_COMPILE_RESOURCES)
235 # Configure paths for GTK+
236 # Owen Taylor 1997-2001
238 dnl AM_PATH_GTK_2_0([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]])
239 dnl Test for GTK+, and define GTK_CFLAGS and GTK_LIBS, if gthread is specified in MODULES,
240 dnl pass to pkg-config
242 AC_DEFUN([AM_PATH_GTK_2_0],
244 dnl Get the cflags and libraries from pkg-config
246 AC_ARG_ENABLE(gtktest, [ --disable-gtktest do not try to compile and run a test GTK+ program],
247 , enable_gtktest=yes)
249 pkg_config_args=gtk+-2.0
254 pkg_config_args="$pkg_config_args gthread-2.0"
261 AC_REQUIRE([PKG_PROG_PKG_CONFIG])
262 PKG_PROG_PKG_CONFIG([0.7])
264 min_gtk_version=ifelse([$1], ,2.0.0,$1)
265 AC_MSG_CHECKING(for GTK+ - version >= $min_gtk_version)
267 if test x$PKG_CONFIG != xno ; then
268 ## don't try to run the test against uninstalled libtool libs
269 if $PKG_CONFIG --uninstalled $pkg_config_args; then
270 echo "Will use uninstalled version of GTK+ found in PKG_CONFIG_PATH"
274 if $PKG_CONFIG --atleast-version $min_gtk_version $pkg_config_args; then
281 if test x"$no_gtk" = x ; then
282 GTK_CFLAGS=`$PKG_CONFIG $pkg_config_args --cflags`
283 GTK_LIBS=`$PKG_CONFIG $pkg_config_args --libs`
284 gtk_config_major_version=`$PKG_CONFIG --modversion gtk+-2.0 | \
285 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
286 gtk_config_minor_version=`$PKG_CONFIG --modversion gtk+-2.0 | \
287 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
288 gtk_config_micro_version=`$PKG_CONFIG --modversion gtk+-2.0 | \
289 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
290 if test "x$enable_gtktest" = "xyes" ; then
291 ac_save_CFLAGS="$CFLAGS"
293 CFLAGS="$CFLAGS $GTK_CFLAGS"
294 LIBS="$GTK_LIBS $LIBS"
296 dnl Now check if the installed GTK+ is sufficiently new. (Also sanity
297 dnl checks the results of pkg-config to some extent)
308 int major, minor, micro;
311 fclose (fopen ("conf.gtktest", "w"));
313 /* HP/UX 9 (%@#!) writes to sscanf strings */
314 tmp_version = g_strdup("$min_gtk_version");
315 if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) {
316 printf("%s, bad version string\n", "$min_gtk_version");
320 if ((gtk_major_version != $gtk_config_major_version) ||
321 (gtk_minor_version != $gtk_config_minor_version) ||
322 (gtk_micro_version != $gtk_config_micro_version))
324 printf("\n*** 'pkg-config --modversion gtk+-2.0' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n",
325 $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version,
326 gtk_major_version, gtk_minor_version, gtk_micro_version);
327 printf ("*** was found! If pkg-config was correct, then it is best\n");
328 printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n");
329 printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
330 printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
331 printf("*** required on your system.\n");
332 printf("*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH\n");
333 printf("*** to point to the correct configuration files\n");
335 else if ((gtk_major_version != GTK_MAJOR_VERSION) ||
336 (gtk_minor_version != GTK_MINOR_VERSION) ||
337 (gtk_micro_version != GTK_MICRO_VERSION))
339 printf("*** GTK+ header files (version %d.%d.%d) do not match\n",
340 GTK_MAJOR_VERSION, GTK_MINOR_VERSION, GTK_MICRO_VERSION);
341 printf("*** library (version %d.%d.%d)\n",
342 gtk_major_version, gtk_minor_version, gtk_micro_version);
346 if ((gtk_major_version > major) ||
347 ((gtk_major_version == major) && (gtk_minor_version > minor)) ||
348 ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro)))
354 printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n",
355 gtk_major_version, gtk_minor_version, gtk_micro_version);
356 printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n",
357 major, minor, micro);
358 printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n");
360 printf("*** If you have already installed a sufficiently new version, this error\n");
361 printf("*** probably means that the wrong copy of the pkg-config shell script is\n");
362 printf("*** being found. The easiest way to fix this is to remove the old version\n");
363 printf("*** of GTK+, but you can also set the PKG_CONFIG environment to point to the\n");
364 printf("*** correct copy of pkg-config. (In this case, you will have to\n");
365 printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
366 printf("*** so that the correct libraries are found at run-time))\n");
371 ],, no_gtk=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
372 CFLAGS="$ac_save_CFLAGS"
376 if test "x$no_gtk" = x ; then
377 AC_MSG_RESULT(yes (version $gtk_config_major_version.$gtk_config_minor_version.$gtk_config_micro_version))
378 ifelse([$2], , :, [$2])
381 if test "$PKG_CONFIG" = "no" ; then
382 echo "*** A new enough version of pkg-config was not found."
383 echo "*** See http://pkgconfig.sourceforge.net"
385 if test -f conf.gtktest ; then
388 echo "*** Could not run GTK+ test program, checking why..."
389 ac_save_CFLAGS="$CFLAGS"
391 CFLAGS="$CFLAGS $GTK_CFLAGS"
392 LIBS="$LIBS $GTK_LIBS"
396 ], [ return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version)); ],
397 [ echo "*** The test program compiled, but did not run. This usually means"
398 echo "*** that the run-time linker is not finding GTK+ or finding the wrong"
399 echo "*** version of GTK+. If it is not finding GTK+, you'll need to set your"
400 echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
401 echo "*** to the installed location Also, make sure you have run ldconfig if that"
402 echo "*** is required on your system"
404 echo "*** If you have an old version installed, it is best to remove it, although"
405 echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ],
406 [ echo "*** The test program failed to compile or link. See the file config.log for the"
407 echo "*** exact error that occured. This usually means GTK+ is incorrectly installed."])
408 CFLAGS="$ac_save_CFLAGS"
414 ifelse([$3], , :, [$3])
421 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
423 # Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc.
424 # Written by Gordon Matzigkeit, 1996
426 # This file is free software; the Free Software Foundation gives
427 # unlimited permission to copy and/or distribute it, with or without
428 # modifications, as long as this notice is preserved.
430 m4_define([_LT_COPYING], [dnl
431 # Copyright (C) 2014 Free Software Foundation, Inc.
432 # This is free software; see the source for copying conditions. There is NO
433 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
435 # GNU Libtool is free software; you can redistribute it and/or modify
436 # it under the terms of the GNU General Public License as published by
437 # the Free Software Foundation; either version 2 of of the License, or
438 # (at your option) any later version.
440 # As a special exception to the GNU General Public License, if you
441 # distribute this file as part of a program or library that is built
442 # using GNU Libtool, you may include this file under the same
443 # distribution terms that you use for the rest of that program.
445 # GNU Libtool is distributed in the hope that it will be useful, but
446 # WITHOUT ANY WARRANTY; without even the implied warranty of
447 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
448 # GNU General Public License for more details.
450 # You should have received a copy of the GNU General Public License
451 # along with this program. If not, see <http://www.gnu.org/licenses/>.
459 # Complain and exit if this libtool version is less that VERSION.
460 m4_defun([LT_PREREQ],
461 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
463 [m4_fatal([Libtool version $1 or higher is required],
470 # Complain if the absolute build directory name contains unusual characters
471 m4_defun([_LT_CHECK_BUILDDIR],
474 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
482 [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK
483 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
484 AC_BEFORE([$0], [LT_LANG])dnl
485 AC_BEFORE([$0], [LT_OUTPUT])dnl
486 AC_BEFORE([$0], [LTDL_INIT])dnl
487 m4_require([_LT_CHECK_BUILDDIR])dnl
489 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
490 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
491 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
492 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
493 dnl unless we require an AC_DEFUNed macro:
494 AC_REQUIRE([LTOPTIONS_VERSION])dnl
495 AC_REQUIRE([LTSUGAR_VERSION])dnl
496 AC_REQUIRE([LTVERSION_VERSION])dnl
497 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
498 m4_require([_LT_PROG_LTMAIN])dnl
500 _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
503 _LT_SET_OPTIONS([$0], [$1])
505 # This can be used to rebuild libtool when needed
508 # Always use our own libtool.
509 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
519 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
520 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
521 dnl aclocal-1.4 backwards compatibility:
522 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
523 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
526 # _LT_PREPARE_CC_BASENAME
527 # -----------------------
528 m4_defun([_LT_PREPARE_CC_BASENAME], [
529 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
532 for cc_temp in @S|@*""; do
534 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
535 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
540 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
542 ])# _LT_PREPARE_CC_BASENAME
545 # _LT_CC_BASENAME(CC)
546 # -------------------
547 # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME,
548 # but that macro is also expanded into generated libtool script, which
549 # arranges for $SED and $ECHO to be set by different means.
550 m4_defun([_LT_CC_BASENAME],
551 [m4_require([_LT_PREPARE_CC_BASENAME])dnl
552 AC_REQUIRE([_LT_DECL_SED])dnl
553 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
555 cc_basename=$func_cc_basename_result
559 # _LT_FILEUTILS_DEFAULTS
560 # ----------------------
561 # It is okay to use these file commands and assume they have been set
562 # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'.
563 m4_defun([_LT_FILEUTILS_DEFAULTS],
567 ])# _LT_FILEUTILS_DEFAULTS
572 m4_defun([_LT_SETUP],
573 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
574 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
575 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
576 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
578 _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
580 _LT_DECL([], [host_alias], [0], [The host system])dnl
581 _LT_DECL([], [host], [0])dnl
582 _LT_DECL([], [host_os], [0])dnl
584 _LT_DECL([], [build_alias], [0], [The build system])dnl
585 _LT_DECL([], [build], [0])dnl
586 _LT_DECL([], [build_os], [0])dnl
588 AC_REQUIRE([AC_PROG_CC])dnl
589 AC_REQUIRE([LT_PATH_LD])dnl
590 AC_REQUIRE([LT_PATH_NM])dnl
592 AC_REQUIRE([AC_PROG_LN_S])dnl
593 test -z "$LN_S" && LN_S="ln -s"
594 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
596 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
597 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
598 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
600 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
601 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
602 m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
603 m4_require([_LT_CMD_RELOAD])dnl
604 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
605 m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
606 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
607 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
608 m4_require([_LT_WITH_SYSROOT])dnl
609 m4_require([_LT_CMD_TRUNCATE])dnl
611 _LT_CONFIG_LIBTOOL_INIT([
612 # See if we are running on zsh, and set the options that allow our
613 # commands through without removal of \ escapes INIT.
614 if test -n "\${ZSH_VERSION+set}"; then
618 if test -n "${ZSH_VERSION+set}"; then
624 m4_require([_LT_TAG_COMPILER])dnl
628 # AIX sometimes has problems with the GCC collect2 program. For some
629 # reason, if we set the COLLECT_NAMES environment variable, the problems
630 # vanish in a puff of smoke.
631 if test set != "${COLLECT_NAMES+set}"; then
642 # All known linkers require a '.a' archive for static linking (except MSVC,
643 # which needs '.lib').
646 with_gnu_ld=$lt_cv_prog_gnu_ld
651 # Set sane defaults for various variables
652 test -z "$CC" && CC=cc
653 test -z "$LTCC" && LTCC=$CC
654 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
655 test -z "$LD" && LD=ld
656 test -z "$ac_objext" && ac_objext=o
658 _LT_CC_BASENAME([$compiler])
660 # Only perform the check for file, if the check method requires it
661 test -z "$MAGIC_CMD" && MAGIC_CMD=file
662 case $deplibs_check_method in
664 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
670 # Use C for the default configuration in the libtool script
671 LT_SUPPORTED_TAG([CC])
673 _LT_LANG_DEFAULT_CONFIG
678 # _LT_PREPARE_SED_QUOTE_VARS
679 # --------------------------
680 # Define a few sed substitution that help us do robust quoting.
681 m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
682 [# Backslashify metacharacters that are still active within
683 # double-quoted strings.
684 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
686 # Same as above, but do not quote variable references.
687 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
689 # Sed substitution to delay expansion of an escaped shell variable in a
690 # double_quote_subst'ed string.
691 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
693 # Sed substitution to delay expansion of an escaped single quote.
694 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
696 # Sed substitution to avoid accidental globbing in evaled expressions
697 no_glob_subst='s/\*/\\\*/g'
702 # Note that this code is called both from 'configure', and 'config.status'
703 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
704 # 'config.status' has no value for ac_aux_dir unless we are using Automake,
705 # so we pass a copy along to make sure it has a sensible value anyway.
706 m4_defun([_LT_PROG_LTMAIN],
707 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
708 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
709 ltmain=$ac_aux_dir/ltmain.sh
714 # So that we can recreate a full libtool script including additional
715 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
716 # in macros and then make a single call at the end using the 'libtool'
720 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
721 # ----------------------------------------
722 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
723 m4_define([_LT_CONFIG_LIBTOOL_INIT],
725 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
730 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
733 # _LT_CONFIG_LIBTOOL([COMMANDS])
734 # ------------------------------
735 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
736 m4_define([_LT_CONFIG_LIBTOOL],
738 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
743 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
746 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
747 # -----------------------------------------------------
748 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
749 [_LT_CONFIG_LIBTOOL([$1])
750 _LT_CONFIG_LIBTOOL_INIT([$2])
754 # _LT_FORMAT_COMMENT([COMMENT])
755 # -----------------------------
756 # Add leading comment marks to the start of each line, and a trailing
757 # full-stop to the whole comment if one is not present already.
758 m4_define([_LT_FORMAT_COMMENT],
760 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
761 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
768 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
769 # -------------------------------------------------------------------
770 # CONFIGNAME is the name given to the value in the libtool script.
771 # VARNAME is the (base) name used in the configure script.
772 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
773 # VARNAME. Any other value will be used directly.
774 m4_define([_LT_DECL],
775 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
776 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
777 [m4_ifval([$1], [$1], [$2])])
778 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
780 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
781 lt_dict_add_subkey([lt_decl_dict], [$2],
782 [tagged?], [m4_ifval([$5], [yes], [no])])])
786 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
787 # --------------------------------------------------------
788 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
791 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
792 # ------------------------------------------------
793 m4_define([lt_decl_tag_varnames],
794 [_lt_decl_filter([tagged?], [yes], $@)])
797 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
798 # ---------------------------------------------------------
799 m4_define([_lt_decl_filter],
801 [0], [m4_fatal([$0: too few arguments: $#])],
802 [1], [m4_fatal([$0: too few arguments: $#: $1])],
803 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
804 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
805 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
809 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
810 # --------------------------------------------------
811 m4_define([lt_decl_quote_varnames],
812 [_lt_decl_filter([value], [1], $@)])
815 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
816 # ---------------------------------------------------
817 m4_define([lt_decl_dquote_varnames],
818 [_lt_decl_filter([value], [2], $@)])
821 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
822 # ---------------------------------------------------
823 m4_define([lt_decl_varnames_tagged],
824 [m4_assert([$# <= 2])dnl
825 _$0(m4_quote(m4_default([$1], [[, ]])),
826 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
827 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
828 m4_define([_lt_decl_varnames_tagged],
829 [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
832 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
833 # ------------------------------------------------
834 m4_define([lt_decl_all_varnames],
835 [_$0(m4_quote(m4_default([$1], [[, ]])),
837 m4_quote(lt_decl_varnames),
838 m4_quote(m4_shift($@))))[]dnl
840 m4_define([_lt_decl_all_varnames],
841 [lt_join($@, lt_decl_varnames_tagged([$1],
842 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
846 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
847 # ------------------------------------
848 # Quote a variable value, and forward it to 'config.status' so that its
849 # declaration there will have the same value as in 'configure'. VARNAME
850 # must have a single quote delimited value for this to work.
851 m4_define([_LT_CONFIG_STATUS_DECLARE],
852 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
855 # _LT_CONFIG_STATUS_DECLARATIONS
856 # ------------------------------
857 # We delimit libtool config variables with single quotes, so when
858 # we write them to config.status, we have to be sure to quote all
859 # embedded single quotes properly. In configure, this macro expands
860 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
862 # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
863 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
864 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
865 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
870 # Output comment and list of tags supported by the script
871 m4_defun([_LT_LIBTOOL_TAGS],
872 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
873 available_tags='_LT_TAGS'dnl
877 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
878 # -----------------------------------
879 # Extract the dictionary values for VARNAME (optionally with TAG) and
880 # expand to a commented shell variable setting:
882 # # Some comment about what VAR is for.
883 # visible_name=$lt_internal_name
884 m4_define([_LT_LIBTOOL_DECLARE],
885 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
886 [description])))[]dnl
887 m4_pushdef([_libtool_name],
888 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
889 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
890 [0], [_libtool_name=[$]$1],
891 [1], [_libtool_name=$lt_[]$1],
892 [2], [_libtool_name=$lt_[]$1],
893 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
894 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
898 # _LT_LIBTOOL_CONFIG_VARS
899 # -----------------------
900 # Produce commented declarations of non-tagged libtool config variables
901 # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool'
902 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
903 # section) are produced by _LT_LIBTOOL_TAG_VARS.
904 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
905 [m4_foreach([_lt_var],
906 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
907 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
910 # _LT_LIBTOOL_TAG_VARS(TAG)
911 # -------------------------
912 m4_define([_LT_LIBTOOL_TAG_VARS],
913 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
914 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
917 # _LT_TAGVAR(VARNAME, [TAGNAME])
918 # ------------------------------
919 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
922 # _LT_CONFIG_COMMANDS
923 # -------------------
924 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
925 # variables for single and double quote escaping we saved from calls
926 # to _LT_DECL, we can put quote escaped variables declarations
927 # into 'config.status', and then the shell code to quote escape them in
928 # for loops in 'config.status'. Finally, any additional code accumulated
929 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
930 m4_defun([_LT_CONFIG_COMMANDS],
931 [AC_PROVIDE_IFELSE([LT_OUTPUT],
932 dnl If the libtool generation code has been placed in $CONFIG_LT,
933 dnl instead of duplicating it all over again into config.status,
934 dnl then we will have config.status run $CONFIG_LT later, so it
935 dnl needs to know what name is stored there:
936 [AC_CONFIG_COMMANDS([libtool],
937 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
938 dnl If the libtool generation code is destined for config.status,
939 dnl expand the accumulated commands and init code now:
940 [AC_CONFIG_COMMANDS([libtool],
941 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
942 ])#_LT_CONFIG_COMMANDS
946 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
949 # The HP-UX ksh and POSIX shell print the target directory to stdout
951 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
953 sed_quote_subst='$sed_quote_subst'
954 double_quote_subst='$double_quote_subst'
955 delay_variable_subst='$delay_variable_subst'
956 _LT_CONFIG_STATUS_DECLARATIONS
959 compiler='$compiler_DEFAULT'
961 # A function that is used when there is no print builtin or printf.
962 func_fallback_echo ()
964 eval 'cat <<_LTECHO_EOF
969 # Quote evaled strings.
970 for var in lt_decl_all_varnames([[ \
971 ]], lt_decl_quote_varnames); do
972 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
973 *[[\\\\\\\`\\"\\\$]]*)
974 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
977 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
982 # Double-quote double-evaled strings.
983 for var in lt_decl_all_varnames([[ \
984 ]], lt_decl_dquote_varnames); do
985 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
986 *[[\\\\\\\`\\"\\\$]]*)
987 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
990 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
995 _LT_OUTPUT_LIBTOOL_INIT
998 # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
999 # ------------------------------------
1000 # Generate a child script FILE with all initialization necessary to
1001 # reuse the environment learned by the parent script, and make the
1002 # file executable. If COMMENT is supplied, it is inserted after the
1003 # '#!' sequence but before initialization text begins. After this
1004 # macro, additional text can be appended to FILE to form the body of
1005 # the child script. The macro ends with non-zero status if the
1006 # file could not be fully written (such as if the disk is full).
1007 m4_ifdef([AS_INIT_GENERATED],
1008 [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
1009 [m4_defun([_LT_GENERATED_FILE_INIT],
1010 [m4_require([AS_PREPARE])]dnl
1011 [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
1013 cat >$1 <<_ASEOF || lt_write_fail=1
1015 # Generated by $as_me.
1017 SHELL=\${CONFIG_SHELL-$SHELL}
1020 cat >>$1 <<\_ASEOF || lt_write_fail=1
1023 exec AS_MESSAGE_FD>&1
1025 test 0 = "$lt_write_fail" && chmod +x $1[]dnl
1026 m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
1030 # This macro allows early generation of the libtool script (before
1031 # AC_OUTPUT is called), incase it is used in configure for compilation
1033 AC_DEFUN([LT_OUTPUT],
1034 [: ${CONFIG_LT=./config.lt}
1035 AC_MSG_NOTICE([creating $CONFIG_LT])
1036 _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
1037 [# Run this file to recreate a libtool stub with the current configuration.])
1039 cat >>"$CONFIG_LT" <<\_LTEOF
1041 exec AS_MESSAGE_LOG_FD>>config.log
1044 AS_BOX([Running $as_me.])
1045 } >&AS_MESSAGE_LOG_FD
1048 '$as_me' creates a local libtool stub from the current configuration,
1049 for use in further configure time tests before the real libtool is
1052 Usage: $[0] [[OPTIONS]]
1054 -h, --help print this help, then exit
1055 -V, --version print version number, then exit
1056 -q, --quiet do not print progress messages
1057 -d, --debug don't remove temporary files
1059 Report bugs to <bug-libtool@gnu.org>."
1062 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1063 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1064 configured by $[0], generated by m4_PACKAGE_STRING.
1066 Copyright (C) 2011 Free Software Foundation, Inc.
1067 This config.lt script is free software; the Free Software Foundation
1068 gives unlimited permision to copy, distribute and modify it."
1070 while test 0 != $[#]
1073 --version | --v* | -V )
1074 echo "$lt_cl_version"; exit 0 ;;
1075 --help | --h* | -h )
1076 echo "$lt_cl_help"; exit 0 ;;
1077 --debug | --d* | -d )
1079 --quiet | --q* | --silent | --s* | -q )
1082 -*) AC_MSG_ERROR([unrecognized option: $[1]
1083 Try '$[0] --help' for more information.]) ;;
1085 *) AC_MSG_ERROR([unrecognized argument: $[1]
1086 Try '$[0] --help' for more information.]) ;;
1091 if $lt_cl_silent; then
1092 exec AS_MESSAGE_FD>/dev/null
1096 cat >>"$CONFIG_LT" <<_LTEOF
1097 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1100 cat >>"$CONFIG_LT" <<\_LTEOF
1101 AC_MSG_NOTICE([creating $ofile])
1102 _LT_OUTPUT_LIBTOOL_COMMANDS
1105 chmod +x "$CONFIG_LT"
1107 # configure is writing to config.log, but config.lt does its own redirection,
1108 # appending to config.log, which fails on DOS, as config.log is still kept
1109 # open by configure. Here we exec the FD to /dev/null, effectively closing
1110 # config.log, so it can be properly (re)opened and appended to by config.lt.
1112 test yes = "$silent" &&
1113 lt_config_lt_args="$lt_config_lt_args --quiet"
1114 exec AS_MESSAGE_LOG_FD>/dev/null
1115 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
1116 exec AS_MESSAGE_LOG_FD>>config.log
1117 $lt_cl_success || AS_EXIT(1)
1123 # If TAG is the built-in tag, create an initial libtool script with a
1124 # default configuration from the untagged config vars. Otherwise add code
1125 # to config.status for appending the configuration named by TAG from the
1126 # matching tagged config vars.
1127 m4_defun([_LT_CONFIG],
1128 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1129 _LT_CONFIG_SAVE_COMMANDS([
1130 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
1131 m4_if(_LT_TAG, [C], [
1132 # See if we are running on zsh, and set the options that allow our
1133 # commands through without removal of \ escapes.
1134 if test -n "${ZSH_VERSION+set}"; then
1135 setopt NO_GLOB_SUBST
1139 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
1142 cat <<_LT_EOF >> "$cfgfile"
1144 # Generated automatically by $as_me ($PACKAGE) $VERSION
1145 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
1147 # Provide generalized library-building support services.
1148 # Written by Gordon Matzigkeit, 1996
1153 # Configured defaults for sys_lib_dlsearch_path munging.
1154 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
1156 # ### BEGIN LIBTOOL CONFIG
1157 _LT_LIBTOOL_CONFIG_VARS
1158 _LT_LIBTOOL_TAG_VARS
1159 # ### END LIBTOOL CONFIG
1163 cat <<'_LT_EOF' >> "$cfgfile"
1165 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
1167 _LT_PREPARE_MUNGE_PATH_LIST
1168 _LT_PREPARE_CC_BASENAME
1170 # ### END FUNCTIONS SHARED WITH CONFIGURE
1176 cat <<\_LT_EOF >> "$cfgfile"
1177 # AIX sometimes has problems with the GCC collect2 program. For some
1178 # reason, if we set the COLLECT_NAMES environment variable, the problems
1179 # vanish in a puff of smoke.
1180 if test set != "${COLLECT_NAMES+set}"; then
1182 export COLLECT_NAMES
1190 # We use sed instead of cat because bash on DJGPP gets confused if
1191 # if finds mixed CR/LF and LF-only lines. Since sed operates in
1192 # text mode, it properly converts lines to CR/LF. This bash problem
1193 # is reportedly fixed, but why not run on old versions too?
1194 sed '$q' "$ltmain" >> "$cfgfile" \
1195 || (rm -f "$cfgfile"; exit 1)
1197 mv -f "$cfgfile" "$ofile" ||
1198 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
1201 [cat <<_LT_EOF >> "$ofile"
1203 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
1204 dnl in a comment (ie after a #).
1205 # ### BEGIN LIBTOOL TAG CONFIG: $1
1206 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
1207 # ### END LIBTOOL TAG CONFIG: $1
1215 ofile='$ofile'], [])
1216 ])dnl /_LT_CONFIG_SAVE_COMMANDS
1220 # LT_SUPPORTED_TAG(TAG)
1221 # ---------------------
1222 # Trace this macro to discover what tags are supported by the libtool
1223 # --tag option, using:
1224 # autoconf --trace 'LT_SUPPORTED_TAG:$1'
1225 AC_DEFUN([LT_SUPPORTED_TAG], [])
1228 # C support is built-in for now
1229 m4_define([_LT_LANG_C_enabled], [])
1230 m4_define([_LT_TAGS], [])
1235 # Enable libtool support for the given language if not already enabled.
1237 [AC_BEFORE([$0], [LT_OUTPUT])dnl
1240 [C++], [_LT_LANG(CXX)],
1241 [Go], [_LT_LANG(GO)],
1242 [Java], [_LT_LANG(GCJ)],
1243 [Fortran 77], [_LT_LANG(F77)],
1244 [Fortran], [_LT_LANG(FC)],
1245 [Windows Resource], [_LT_LANG(RC)],
1246 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
1248 [m4_fatal([$0: unsupported language: "$1"])])])dnl
1252 # _LT_LANG(LANGNAME)
1253 # ------------------
1254 m4_defun([_LT_LANG],
1255 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
1256 [LT_SUPPORTED_TAG([$1])dnl
1257 m4_append([_LT_TAGS], [$1 ])dnl
1258 m4_define([_LT_LANG_]$1[_enabled], [])dnl
1259 _LT_LANG_$1_CONFIG($1)])dnl
1263 m4_ifndef([AC_PROG_GO], [
1264 # NOTE: This macro has been submitted for inclusion into #
1265 # GNU Autoconf as AC_PROG_GO. When it is available in #
1266 # a released version of Autoconf we should remove this #
1267 # macro and use it instead. #
1268 m4_defun([AC_PROG_GO],
1269 [AC_LANG_PUSH(Go)dnl
1270 AC_ARG_VAR([GOC], [Go compiler command])dnl
1271 AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
1272 _AC_ARG_VAR_LDFLAGS()dnl
1273 AC_CHECK_TOOL(GOC, gccgo)
1274 if test -z "$GOC"; then
1275 if test -n "$ac_tool_prefix"; then
1276 AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
1279 if test -z "$GOC"; then
1280 AC_CHECK_PROG(GOC, gccgo, gccgo, false)
1286 # _LT_LANG_DEFAULT_CONFIG
1287 # -----------------------
1288 m4_defun([_LT_LANG_DEFAULT_CONFIG],
1289 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
1291 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
1293 AC_PROVIDE_IFELSE([AC_PROG_F77],
1295 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
1297 AC_PROVIDE_IFELSE([AC_PROG_FC],
1299 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
1301 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
1302 dnl pulling things in needlessly.
1303 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1305 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1307 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
1309 [m4_ifdef([AC_PROG_GCJ],
1310 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
1311 m4_ifdef([A][M_PROG_GCJ],
1312 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
1313 m4_ifdef([LT_PROG_GCJ],
1314 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
1316 AC_PROVIDE_IFELSE([AC_PROG_GO],
1318 [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
1320 AC_PROVIDE_IFELSE([LT_PROG_RC],
1322 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
1323 ])# _LT_LANG_DEFAULT_CONFIG
1326 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1327 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1328 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1329 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1330 AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
1331 dnl aclocal-1.4 backwards compatibility:
1332 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1333 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1334 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1335 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1336 dnl AC_DEFUN([AC_LIBTOOL_RC], [])
1341 m4_defun([_LT_TAG_COMPILER],
1342 [AC_REQUIRE([AC_PROG_CC])dnl
1344 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1345 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1346 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1347 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1349 # If no C compiler was specified, use CC.
1352 # If no C compiler flags were specified, use CFLAGS.
1353 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1355 # Allow CC to be a program name with arguments.
1357 ])# _LT_TAG_COMPILER
1360 # _LT_COMPILER_BOILERPLATE
1361 # ------------------------
1362 # Check for compiler boilerplate output or warnings with
1363 # the simple compiler test code.
1364 m4_defun([_LT_COMPILER_BOILERPLATE],
1365 [m4_require([_LT_DECL_SED])dnl
1366 ac_outfile=conftest.$ac_objext
1367 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1368 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1369 _lt_compiler_boilerplate=`cat conftest.err`
1371 ])# _LT_COMPILER_BOILERPLATE
1374 # _LT_LINKER_BOILERPLATE
1375 # ----------------------
1376 # Check for linker boilerplate output or warnings with
1377 # the simple link test code.
1378 m4_defun([_LT_LINKER_BOILERPLATE],
1379 [m4_require([_LT_DECL_SED])dnl
1380 ac_outfile=conftest.$ac_objext
1381 echo "$lt_simple_link_test_code" >conftest.$ac_ext
1382 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1383 _lt_linker_boilerplate=`cat conftest.err`
1385 ])# _LT_LINKER_BOILERPLATE
1387 # _LT_REQUIRED_DARWIN_CHECKS
1388 # -------------------------
1389 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1391 rhapsody* | darwin*)
1392 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1393 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1394 AC_CHECK_TOOL([LIPO], [lipo], [:])
1395 AC_CHECK_TOOL([OTOOL], [otool], [:])
1396 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1397 _LT_DECL([], [DSYMUTIL], [1],
1398 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1399 _LT_DECL([], [NMEDIT], [1],
1400 [Tool to change global to local symbols on Mac OS X])
1401 _LT_DECL([], [LIPO], [1],
1402 [Tool to manipulate fat objects and archives on Mac OS X])
1403 _LT_DECL([], [OTOOL], [1],
1404 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1405 _LT_DECL([], [OTOOL64], [1],
1406 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1408 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1409 [lt_cv_apple_cc_single_mod=no
1410 if test -z "$LT_MULTI_MODULE"; then
1411 # By default we will add the -single_module flag. You can override
1412 # by either setting the environment variable LT_MULTI_MODULE
1413 # non-empty at configure time, or by adding -multi_module to the
1415 rm -rf libconftest.dylib*
1416 echo "int foo(void){return 1;}" > conftest.c
1417 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1418 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1419 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1420 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1422 # If there is a non-empty error log, and "single_module"
1423 # appears in it, assume the flag caused a linker warning
1424 if test -s conftest.err && $GREP single_module conftest.err; then
1425 cat conftest.err >&AS_MESSAGE_LOG_FD
1426 # Otherwise, if the output was created with a 0 exit code from
1427 # the compiler, it worked.
1428 elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
1429 lt_cv_apple_cc_single_mod=yes
1431 cat conftest.err >&AS_MESSAGE_LOG_FD
1433 rm -rf libconftest.dylib*
1437 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1438 [lt_cv_ld_exported_symbols_list],
1439 [lt_cv_ld_exported_symbols_list=no
1440 save_LDFLAGS=$LDFLAGS
1441 echo "_main" > conftest.sym
1442 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1443 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1444 [lt_cv_ld_exported_symbols_list=yes],
1445 [lt_cv_ld_exported_symbols_list=no])
1446 LDFLAGS=$save_LDFLAGS
1449 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
1450 [lt_cv_ld_force_load=no
1451 cat > conftest.c << _LT_EOF
1452 int forced_loaded() { return 2;}
1454 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1455 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1456 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1457 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1458 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1459 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1460 cat > conftest.c << _LT_EOF
1461 int main() { return 0;}
1463 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
1464 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
1466 if test -s conftest.err && $GREP force_load conftest.err; then
1467 cat conftest.err >&AS_MESSAGE_LOG_FD
1468 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
1469 lt_cv_ld_force_load=yes
1471 cat conftest.err >&AS_MESSAGE_LOG_FD
1473 rm -f conftest.err libconftest.a conftest conftest.c
1474 rm -rf conftest.dSYM
1477 rhapsody* | darwin1.[[012]])
1478 _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
1480 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
1481 darwin*) # darwin 5.x on
1482 # if running on 10.5 or later, the deployment target defaults
1483 # to the OS version, if on x86, and 10.4, the deployment
1484 # target defaults to 10.4. Don't you love it?
1485 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1486 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1487 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
1489 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
1491 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
1495 if test yes = "$lt_cv_apple_cc_single_mod"; then
1496 _lt_dar_single_mod='$single_module'
1498 if test yes = "$lt_cv_ld_exported_symbols_list"; then
1499 _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
1501 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
1503 if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
1504 _lt_dsymutil='~$DSYMUTIL $lib || :'
1513 # _LT_DARWIN_LINKER_FEATURES([TAG])
1514 # ---------------------------------
1515 # Checks for linker and compiler features on darwin
1516 m4_defun([_LT_DARWIN_LINKER_FEATURES],
1518 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1519 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1520 _LT_TAGVAR(hardcode_direct, $1)=no
1521 _LT_TAGVAR(hardcode_automatic, $1)=yes
1522 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1523 if test yes = "$lt_cv_ld_force_load"; then
1524 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1525 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
1526 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
1528 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1530 _LT_TAGVAR(link_all_deplibs, $1)=yes
1531 _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined
1532 case $cc_basename in
1533 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
1534 *) _lt_dar_can_shared=$GCC ;;
1536 if test yes = "$_lt_dar_can_shared"; then
1537 output_verbose_link_cmd=func_echo_all
1538 _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"
1539 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
1540 _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"
1541 _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"
1543 [ if test yes != "$lt_cv_apple_cc_single_mod"; then
1544 _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"
1545 _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"
1549 _LT_TAGVAR(ld_shlibs, $1)=no
1553 # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
1554 # ----------------------------------
1555 # Links a minimal program and checks the executable
1556 # for the system default hardcoded library path. In most cases,
1557 # this is /usr/lib:/lib, but when the MPI compilers are used
1558 # the location of the communication and MPI libs are included too.
1559 # If we don't find anything, use the default library path according
1560 # to the aix ld manual.
1561 # Store the results from the different compilers for each TAGNAME.
1562 # Allow to override them for all tags through lt_cv_aix_libpath.
1563 m4_defun([_LT_SYS_MODULE_PATH_AIX],
1564 [m4_require([_LT_DECL_SED])dnl
1565 if test set = "${lt_cv_aix_libpath+set}"; then
1566 aix_libpath=$lt_cv_aix_libpath
1568 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
1569 [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
1570 lt_aix_libpath_sed='[
1571 /Import File Strings/,/^$/ {
1573 s/^0 *\([^ ]*\) *$/\1/
1577 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1578 # Check for a 64-bit object if we didn't find anything.
1579 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1580 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1582 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1583 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib
1586 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
1588 ])# _LT_SYS_MODULE_PATH_AIX
1591 # _LT_SHELL_INIT(ARG)
1592 # -------------------
1593 m4_define([_LT_SHELL_INIT],
1594 [m4_divert_text([M4SH-INIT], [$1
1595 ])])# _LT_SHELL_INIT
1599 # _LT_PROG_ECHO_BACKSLASH
1600 # -----------------------
1601 # Find how we can fake an echo command that does not interpret backslash.
1602 # In particular, with Autoconf 2.60 or later we add some code to the start
1603 # of the generated configure script that will find a shell with a builtin
1604 # printf (that we can use as an echo command).
1605 m4_defun([_LT_PROG_ECHO_BACKSLASH],
1606 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1607 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1608 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1610 AC_MSG_CHECKING([how to print strings])
1611 # Test print first, because it will be a builtin if present.
1612 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
1613 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
1615 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
1618 # Use this function as a fallback that always works.
1619 func_fallback_echo ()
1621 eval 'cat <<_LTECHO_EOF
1625 ECHO='func_fallback_echo'
1628 # func_echo_all arg...
1629 # Invoke $ECHO with all args, space-separated.
1636 printf*) AC_MSG_RESULT([printf]) ;;
1637 print*) AC_MSG_RESULT([print -r]) ;;
1638 *) AC_MSG_RESULT([cat]) ;;
1641 m4_ifdef([_AS_DETECT_SUGGESTED],
1642 [_AS_DETECT_SUGGESTED([
1643 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
1644 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1645 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1646 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1647 PATH=/empty FPATH=/empty; export PATH FPATH
1648 test "X`printf %s $ECHO`" = "X$ECHO" \
1649 || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
1651 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1652 _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1653 ])# _LT_PROG_ECHO_BACKSLASH
1658 AC_DEFUN([_LT_WITH_SYSROOT],
1659 [AC_MSG_CHECKING([for sysroot])
1660 AC_ARG_WITH([sysroot],
1661 [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@],
1662 [Search for dependent libraries within DIR (or the compiler's sysroot
1663 if not specified).])],
1664 [], [with_sysroot=no])
1666 dnl lt_sysroot will always be passed unquoted. We quote it here
1667 dnl in case the user passed a directory name.
1669 case $with_sysroot in #(
1671 if test yes = "$GCC"; then
1672 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
1676 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
1681 AC_MSG_RESULT([$with_sysroot])
1682 AC_MSG_ERROR([The sysroot must be an absolute path.])
1686 AC_MSG_RESULT([${lt_sysroot:-no}])
1687 _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
1688 [dependent libraries, and where our libraries should be installed.])])
1692 m4_defun([_LT_ENABLE_LOCK],
1693 [AC_ARG_ENABLE([libtool-lock],
1694 [AS_HELP_STRING([--disable-libtool-lock],
1695 [avoid locking (might break parallel builds)])])
1696 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
1698 # Some flags need to be propagated to the compiler or linker for good
1702 # Find out what ABI is being produced by ac_compile, and set mode
1703 # options accordingly.
1704 echo 'int i;' > conftest.$ac_ext
1705 if AC_TRY_EVAL(ac_compile); then
1706 case `/usr/bin/file conftest.$ac_objext` in
1718 # Find out what ABI is being produced by ac_compile, and set linker
1719 # options accordingly.
1720 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1721 if AC_TRY_EVAL(ac_compile); then
1722 if test yes = "$lt_cv_prog_gnu_ld"; then
1723 case `/usr/bin/file conftest.$ac_objext` in
1725 LD="${LD-ld} -melf32bsmip"
1728 LD="${LD-ld} -melf32bmipn32"
1731 LD="${LD-ld} -melf64bmip"
1735 case `/usr/bin/file conftest.$ac_objext` in
1752 # Find out what ABI is being produced by ac_compile, and set linker
1753 # options accordingly.
1754 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1755 if AC_TRY_EVAL(ac_compile); then
1757 case `/usr/bin/file conftest.$ac_objext` in
1765 case `/usr/bin/file conftest.$ac_objext` in
1767 emul="${emul}btsmip"
1770 emul="${emul}ltsmip"
1773 case `/usr/bin/file conftest.$ac_objext` in
1778 LD="${LD-ld} -m $emul"
1783 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
1784 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1785 # Find out what ABI is being produced by ac_compile, and set linker
1786 # options accordingly. Note that the listed cases only cover the
1787 # situations where additional linker options are needed (such as when
1788 # doing 32-bit compilation for a host where ld defaults to 64-bit, or
1789 # vice versa); the common cases where no linker options are needed do
1790 # not appear in the list.
1791 echo 'int i;' > conftest.$ac_ext
1792 if AC_TRY_EVAL(ac_compile); then
1793 case `/usr/bin/file conftest.o` in
1796 x86_64-*kfreebsd*-gnu)
1797 LD="${LD-ld} -m elf_i386_fbsd"
1800 case `/usr/bin/file conftest.o` in
1802 LD="${LD-ld} -m elf32_x86_64"
1805 LD="${LD-ld} -m elf_i386"
1809 powerpc64le-*linux*)
1810 LD="${LD-ld} -m elf32lppclinux"
1813 LD="${LD-ld} -m elf32ppclinux"
1816 LD="${LD-ld} -m elf_s390"
1819 LD="${LD-ld} -m elf32_sparc"
1825 x86_64-*kfreebsd*-gnu)
1826 LD="${LD-ld} -m elf_x86_64_fbsd"
1829 LD="${LD-ld} -m elf_x86_64"
1832 LD="${LD-ld} -m elf64lppc"
1835 LD="${LD-ld} -m elf64ppc"
1837 s390*-*linux*|s390*-*tpf*)
1838 LD="${LD-ld} -m elf64_s390"
1841 LD="${LD-ld} -m elf64_sparc"
1851 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1853 CFLAGS="$CFLAGS -belf"
1854 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1856 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1858 if test yes != "$lt_cv_cc_needs_belf"; then
1859 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1864 # Find out what ABI is being produced by ac_compile, and set linker
1865 # options accordingly.
1866 echo 'int i;' > conftest.$ac_ext
1867 if AC_TRY_EVAL(ac_compile); then
1868 case `/usr/bin/file conftest.o` in
1870 case $lt_cv_prog_gnu_ld in
1873 i?86-*-solaris*|x86_64-*-solaris*)
1874 LD="${LD-ld} -m elf_x86_64"
1877 LD="${LD-ld} -m elf64_sparc"
1880 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
1881 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
1886 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1898 need_locks=$enable_libtool_lock
1904 m4_defun([_LT_PROG_AR],
1905 [AC_CHECK_TOOLS(AR, [ar], false)
1908 _LT_DECL([], [AR], [1], [The archiver])
1909 _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
1911 AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
1912 [lt_cv_ar_at_file=no
1913 AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
1914 [echo conftest.$ac_objext > conftest.lst
1915 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
1916 AC_TRY_EVAL([lt_ar_try])
1917 if test 0 -eq "$ac_status"; then
1918 # Ensure the archiver fails upon bogus file names.
1919 rm -f conftest.$ac_objext libconftest.a
1920 AC_TRY_EVAL([lt_ar_try])
1921 if test 0 -ne "$ac_status"; then
1925 rm -f conftest.* libconftest.a
1929 if test no = "$lt_cv_ar_at_file"; then
1932 archiver_list_spec=$lt_cv_ar_at_file
1934 _LT_DECL([], [archiver_list_spec], [1],
1935 [How to feed a file listing to the archiver])
1939 # _LT_CMD_OLD_ARCHIVE
1940 # -------------------
1941 m4_defun([_LT_CMD_OLD_ARCHIVE],
1944 AC_CHECK_TOOL(STRIP, strip, :)
1945 test -z "$STRIP" && STRIP=:
1946 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
1948 AC_CHECK_TOOL(RANLIB, ranlib, :)
1949 test -z "$RANLIB" && RANLIB=:
1950 _LT_DECL([], [RANLIB], [1],
1951 [Commands used to install an old-style archive])
1953 # Determine commands to create old-style static archives.
1954 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1955 old_postinstall_cmds='chmod 644 $oldlib'
1956 old_postuninstall_cmds=
1958 if test -n "$RANLIB"; then
1961 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
1964 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
1967 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
1972 lock_old_archive_extraction=yes ;;
1974 lock_old_archive_extraction=no ;;
1976 _LT_DECL([], [old_postinstall_cmds], [2])
1977 _LT_DECL([], [old_postuninstall_cmds], [2])
1978 _LT_TAGDECL([], [old_archive_cmds], [2],
1979 [Commands used to build an old-style archive])
1980 _LT_DECL([], [lock_old_archive_extraction], [0],
1981 [Whether to use a lock for old archive extraction])
1982 ])# _LT_CMD_OLD_ARCHIVE
1985 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1986 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1987 # ----------------------------------------------------------------
1988 # Check whether the given compiler option works
1989 AC_DEFUN([_LT_COMPILER_OPTION],
1990 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1991 m4_require([_LT_DECL_SED])dnl
1992 AC_CACHE_CHECK([$1], [$2],
1994 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1995 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1996 lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment
1997 # Insert the option either (1) after the last *FLAGS variable, or
1998 # (2) before a word containing "conftest.", or (3) at the end.
1999 # Note that $ac_compile itself does not contain backslashes and begins
2000 # with a dollar sign (not a hyphen), so the echo should work correctly.
2001 # The option is referenced via a variable to avoid confusing sed.
2002 lt_compile=`echo "$ac_compile" | $SED \
2003 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2004 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2005 -e 's:$: $lt_compiler_flag:'`
2006 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2007 (eval "$lt_compile" 2>conftest.err)
2009 cat conftest.err >&AS_MESSAGE_LOG_FD
2010 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2011 if (exit $ac_status) && test -s "$ac_outfile"; then
2012 # The compiler can only warn and ignore the option if not recognized
2013 # So say no if there are warnings other than the usual output.
2014 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
2015 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2016 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2023 if test yes = "[$]$2"; then
2024 m4_if([$5], , :, [$5])
2026 m4_if([$6], , :, [$6])
2028 ])# _LT_COMPILER_OPTION
2031 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2032 dnl aclocal-1.4 backwards compatibility:
2033 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2036 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2037 # [ACTION-SUCCESS], [ACTION-FAILURE])
2038 # ----------------------------------------------------
2039 # Check whether the given linker option works
2040 AC_DEFUN([_LT_LINKER_OPTION],
2041 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2042 m4_require([_LT_DECL_SED])dnl
2043 AC_CACHE_CHECK([$1], [$2],
2045 save_LDFLAGS=$LDFLAGS
2046 LDFLAGS="$LDFLAGS $3"
2047 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2048 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2049 # The linker can only warn and ignore the option if not recognized
2050 # So say no if there are warnings
2051 if test -s conftest.err; then
2052 # Append any errors to the config.log.
2053 cat conftest.err 1>&AS_MESSAGE_LOG_FD
2054 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
2055 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2056 if diff conftest.exp conftest.er2 >/dev/null; then
2064 LDFLAGS=$save_LDFLAGS
2067 if test yes = "[$]$2"; then
2068 m4_if([$4], , :, [$4])
2070 m4_if([$5], , :, [$5])
2072 ])# _LT_LINKER_OPTION
2075 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2076 dnl aclocal-1.4 backwards compatibility:
2077 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2082 AC_DEFUN([LT_CMD_MAX_LEN],
2083 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2084 # find the maximum length of command line arguments
2085 AC_MSG_CHECKING([the maximum length of command line arguments])
2086 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2092 # On DJGPP, this test can blow up pretty badly due to problems in libc
2093 # (any single argument exceeding 2000 bytes causes a buffer overrun
2094 # during glob expansion). Even if it were fixed, the result of this
2095 # check would be larger than it should be.
2096 lt_cv_sys_max_cmd_len=12288; # 12K is about right
2100 # Under GNU Hurd, this test is not required because there is
2101 # no limit to the length of command line arguments.
2102 # Libtool will interpret -1 as no limit whatsoever
2103 lt_cv_sys_max_cmd_len=-1;
2106 cygwin* | mingw* | cegcc*)
2107 # On Win9x/ME, this test blows up -- it succeeds, but takes
2108 # about 5 minutes as the teststring grows exponentially.
2109 # Worse, since 9x/ME are not pre-emptively multitasking,
2110 # you end up with a "frozen" computer, even though with patience
2111 # the test eventually succeeds (with a max line length of 256k).
2112 # Instead, let's just punt: use the minimum linelength reported by
2113 # all of the supported platforms: 8192 (on NT/2K/XP).
2114 lt_cv_sys_max_cmd_len=8192;
2118 # On MiNT this can take a long time and run out of memory.
2119 lt_cv_sys_max_cmd_len=8192;
2123 # On AmigaOS with pdksh, this test takes hours, literally.
2124 # So we just punt and use a minimum line length of 8192.
2125 lt_cv_sys_max_cmd_len=8192;
2128 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
2129 # This has been around since 386BSD, at least. Likely further.
2130 if test -x /sbin/sysctl; then
2131 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2132 elif test -x /usr/sbin/sysctl; then
2133 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2135 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
2137 # And add a safety zone
2138 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2139 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2143 # We know the value 262144 and hardcode it with a safety zone (like BSD)
2144 lt_cv_sys_max_cmd_len=196608
2148 # The test takes a long time on OS/2.
2149 lt_cv_sys_max_cmd_len=8192
2153 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2154 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2155 # nice to cause kernel panics so lets avoid the loop below.
2156 # First set a reasonable default.
2157 lt_cv_sys_max_cmd_len=16384
2159 if test -x /sbin/sysconfig; then
2160 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2161 *1*) lt_cv_sys_max_cmd_len=-1 ;;
2166 lt_cv_sys_max_cmd_len=102400
2168 sysv5* | sco5v6* | sysv4.2uw2*)
2169 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2170 if test -n "$kargmax"; then
2171 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
2173 lt_cv_sys_max_cmd_len=32768
2177 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
2178 if test -n "$lt_cv_sys_max_cmd_len" && \
2179 test undefined != "$lt_cv_sys_max_cmd_len"; then
2180 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2181 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2183 # Make teststring a little bigger before we do anything with it.
2184 # a 1K string should be a reasonable start.
2185 for i in 1 2 3 4 5 6 7 8; do
2186 teststring=$teststring$teststring
2188 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
2189 # If test is not a shell built-in, we'll probably end up computing a
2190 # maximum length that is only half of the actual maximum length, but
2192 while { test X`env echo "$teststring$teststring" 2>/dev/null` \
2193 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
2194 test 17 != "$i" # 1/2 MB should be enough
2197 teststring=$teststring$teststring
2199 # Only check the string length outside the loop.
2200 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
2202 # Add a significant safety factor because C++ compilers can tack on
2203 # massive amounts of additional arguments before passing them to the
2204 # linker. It appears as though 1/2 is a usable value.
2205 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
2210 if test -n "$lt_cv_sys_max_cmd_len"; then
2211 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
2215 max_cmd_len=$lt_cv_sys_max_cmd_len
2216 _LT_DECL([], [max_cmd_len], [0],
2217 [What is the maximum length of a command?])
2221 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
2222 dnl aclocal-1.4 backwards compatibility:
2223 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
2228 m4_defun([_LT_HEADER_DLFCN],
2229 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
2230 ])# _LT_HEADER_DLFCN
2233 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
2234 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
2235 # ----------------------------------------------------------------
2236 m4_defun([_LT_TRY_DLOPEN_SELF],
2237 [m4_require([_LT_HEADER_DLFCN])dnl
2238 if test yes = "$cross_compiling"; then :
2241 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
2242 lt_status=$lt_dlunknown
2243 cat > conftest.$ac_ext <<_LT_EOF
2244 [#line $LINENO "configure"
2245 #include "confdefs.h"
2254 # define LT_DLGLOBAL RTLD_GLOBAL
2257 # define LT_DLGLOBAL DL_GLOBAL
2259 # define LT_DLGLOBAL 0
2263 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
2264 find out it does not work in some platform. */
2265 #ifndef LT_DLLAZY_OR_NOW
2267 # define LT_DLLAZY_OR_NOW RTLD_LAZY
2270 # define LT_DLLAZY_OR_NOW DL_LAZY
2273 # define LT_DLLAZY_OR_NOW RTLD_NOW
2276 # define LT_DLLAZY_OR_NOW DL_NOW
2278 # define LT_DLLAZY_OR_NOW 0
2285 /* When -fvisibility=hidden is used, assume the code has been annotated
2286 correspondingly for the symbols needed. */
2287 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
2288 int fnord () __attribute__((visibility("default")));
2291 int fnord () { return 42; }
2294 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
2295 int status = $lt_dlunknown;
2299 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
2302 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
2303 else puts (dlerror ());
2305 /* dlclose (self); */
2313 if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then
2314 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
2317 x$lt_dlno_uscore) $1 ;;
2318 x$lt_dlneed_uscore) $2 ;;
2319 x$lt_dlunknown|x*) $3 ;;
2322 # compilation failed
2327 ])# _LT_TRY_DLOPEN_SELF
2330 # LT_SYS_DLOPEN_SELF
2331 # ------------------
2332 AC_DEFUN([LT_SYS_DLOPEN_SELF],
2333 [m4_require([_LT_HEADER_DLFCN])dnl
2334 if test yes != "$enable_dlopen"; then
2335 enable_dlopen=unknown
2336 enable_dlopen_self=unknown
2337 enable_dlopen_self_static=unknown
2344 lt_cv_dlopen=load_add_on
2346 lt_cv_dlopen_self=yes
2349 mingw* | pw32* | cegcc*)
2350 lt_cv_dlopen=LoadLibrary
2360 # if libdl is installed we need to link against it
2361 AC_CHECK_LIB([dl], [dlopen],
2362 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[
2365 lt_cv_dlopen_self=yes
2370 # Don't try to run any link tests for TPF. We know it's impossible
2371 # because TPF is a cross-compiler, and we know how we open DSOs.
2374 lt_cv_dlopen_self=no
2378 AC_CHECK_FUNC([shl_load],
2379 [lt_cv_dlopen=shl_load],
2380 [AC_CHECK_LIB([dld], [shl_load],
2381 [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld],
2382 [AC_CHECK_FUNC([dlopen],
2383 [lt_cv_dlopen=dlopen],
2384 [AC_CHECK_LIB([dl], [dlopen],
2385 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],
2386 [AC_CHECK_LIB([svld], [dlopen],
2387 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld],
2388 [AC_CHECK_LIB([dld], [dld_link],
2389 [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld])
2398 if test no = "$lt_cv_dlopen"; then
2404 case $lt_cv_dlopen in
2406 save_CPPFLAGS=$CPPFLAGS
2407 test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2409 save_LDFLAGS=$LDFLAGS
2410 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2413 LIBS="$lt_cv_dlopen_libs $LIBS"
2415 AC_CACHE_CHECK([whether a program can dlopen itself],
2416 lt_cv_dlopen_self, [dnl
2417 _LT_TRY_DLOPEN_SELF(
2418 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2419 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2422 if test yes = "$lt_cv_dlopen_self"; then
2423 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2424 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2425 lt_cv_dlopen_self_static, [dnl
2426 _LT_TRY_DLOPEN_SELF(
2427 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2428 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2432 CPPFLAGS=$save_CPPFLAGS
2433 LDFLAGS=$save_LDFLAGS
2438 case $lt_cv_dlopen_self in
2439 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2440 *) enable_dlopen_self=unknown ;;
2443 case $lt_cv_dlopen_self_static in
2444 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2445 *) enable_dlopen_self_static=unknown ;;
2448 _LT_DECL([dlopen_support], [enable_dlopen], [0],
2449 [Whether dlopen is supported])
2450 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2451 [Whether dlopen of programs is supported])
2452 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2453 [Whether dlopen of statically linked programs is supported])
2454 ])# LT_SYS_DLOPEN_SELF
2457 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2458 dnl aclocal-1.4 backwards compatibility:
2459 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2462 # _LT_COMPILER_C_O([TAGNAME])
2463 # ---------------------------
2464 # Check to see if options -c and -o are simultaneously supported by compiler.
2465 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
2466 m4_defun([_LT_COMPILER_C_O],
2467 [m4_require([_LT_DECL_SED])dnl
2468 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2469 m4_require([_LT_TAG_COMPILER])dnl
2470 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2471 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2472 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2473 $RM -r conftest 2>/dev/null
2477 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2479 lt_compiler_flag="-o out/conftest2.$ac_objext"
2480 # Insert the option either (1) after the last *FLAGS variable, or
2481 # (2) before a word containing "conftest.", or (3) at the end.
2482 # Note that $ac_compile itself does not contain backslashes and begins
2483 # with a dollar sign (not a hyphen), so the echo should work correctly.
2484 lt_compile=`echo "$ac_compile" | $SED \
2485 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2486 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2487 -e 's:$: $lt_compiler_flag:'`
2488 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2489 (eval "$lt_compile" 2>out/conftest.err)
2491 cat out/conftest.err >&AS_MESSAGE_LOG_FD
2492 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2493 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2495 # The compiler can only warn and ignore the option if not recognized
2496 # So say no if there are warnings
2497 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
2498 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2499 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2500 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2503 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2505 # SGI C++ compiler will create directory out/ii_files/ for
2506 # template instantiation
2507 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2508 $RM out/* && rmdir out
2513 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2514 [Does compiler simultaneously support -c and -o options?])
2515 ])# _LT_COMPILER_C_O
2518 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
2519 # ----------------------------------
2520 # Check to see if we can do hard links to lock some files if needed
2521 m4_defun([_LT_COMPILER_FILE_LOCKS],
2522 [m4_require([_LT_ENABLE_LOCK])dnl
2523 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2524 _LT_COMPILER_C_O([$1])
2526 hard_links=nottested
2527 if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then
2528 # do not overwrite the value of need_locks provided by the user
2529 AC_MSG_CHECKING([if we can lock with hard links])
2532 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2534 ln conftest.a conftest.b 2>&5 || hard_links=no
2535 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2536 AC_MSG_RESULT([$hard_links])
2537 if test no = "$hard_links"; then
2538 AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe])
2544 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2545 ])# _LT_COMPILER_FILE_LOCKS
2550 m4_defun([_LT_CHECK_OBJDIR],
2551 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2552 [rm -f .libs 2>/dev/null
2553 mkdir .libs 2>/dev/null
2554 if test -d .libs; then
2557 # MS-DOS does not allow filenames that begin with a dot.
2560 rmdir .libs 2>/dev/null])
2561 objdir=$lt_cv_objdir
2562 _LT_DECL([], [objdir], [0],
2563 [The name of the directory that contains temporary libtool files])dnl
2564 m4_pattern_allow([LT_OBJDIR])dnl
2565 AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/",
2566 [Define to the sub-directory where libtool stores uninstalled libraries.])
2567 ])# _LT_CHECK_OBJDIR
2570 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2571 # --------------------------------------
2572 # Check hardcoding attributes.
2573 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2574 [AC_MSG_CHECKING([how to hardcode library paths into programs])
2575 _LT_TAGVAR(hardcode_action, $1)=
2576 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2577 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2578 test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then
2580 # We can hardcode non-existent directories.
2581 if test no != "$_LT_TAGVAR(hardcode_direct, $1)" &&
2582 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2583 # have to relink, otherwise we might link with an installed library
2584 # when we should be linking with a yet-to-be-installed one
2585 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" &&
2586 test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then
2587 # Linking always hardcodes the temporary library directory.
2588 _LT_TAGVAR(hardcode_action, $1)=relink
2590 # We can link without hardcoding, and we can hardcode nonexisting dirs.
2591 _LT_TAGVAR(hardcode_action, $1)=immediate
2594 # We cannot hardcode anything, or else we can only hardcode existing
2596 _LT_TAGVAR(hardcode_action, $1)=unsupported
2598 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2600 if test relink = "$_LT_TAGVAR(hardcode_action, $1)" ||
2601 test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then
2602 # Fast installation is not supported
2603 enable_fast_install=no
2604 elif test yes = "$shlibpath_overrides_runpath" ||
2605 test no = "$enable_shared"; then
2606 # Fast installation is not necessary
2607 enable_fast_install=needless
2609 _LT_TAGDECL([], [hardcode_action], [0],
2610 [How to hardcode a shared library path into an executable])
2611 ])# _LT_LINKER_HARDCODE_LIBPATH
2616 m4_defun([_LT_CMD_STRIPLIB],
2617 [m4_require([_LT_DECL_EGREP])
2620 AC_MSG_CHECKING([whether stripping libraries is possible])
2621 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2622 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2623 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2624 AC_MSG_RESULT([yes])
2626 # FIXME - insert some real tests, host_os isn't really good enough
2629 if test -n "$STRIP"; then
2630 striplib="$STRIP -x"
2631 old_striplib="$STRIP -S"
2632 AC_MSG_RESULT([yes])
2642 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2643 _LT_DECL([], [striplib], [1])
2644 ])# _LT_CMD_STRIPLIB
2647 # _LT_PREPARE_MUNGE_PATH_LIST
2648 # ---------------------------
2649 # Make sure func_munge_path_list() is defined correctly.
2650 m4_defun([_LT_PREPARE_MUNGE_PATH_LIST],
2651 [[# func_munge_path_list VARIABLE PATH
2652 # -----------------------------------
2653 # VARIABLE is name of variable containing _space_ separated list of
2654 # directories to be munged by the contents of PATH, which is string
2657 # string "DIR[ DIR]" will be prepended to VARIABLE
2659 # string "DIR[ DIR]" will be appended to VARIABLE
2660 # "DIRP[:DIRP]::[DIRA:]DIRA"
2661 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
2662 # "DIRA[ DIRA]" will be appended to VARIABLE
2664 # VARIABLE will be replaced by "DIR[ DIR]"
2665 func_munge_path_list ()
2671 eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\"
2674 eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\"
2677 eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
2678 eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\"
2681 eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\"
2685 ]])# _LT_PREPARE_PATH_LIST
2688 # _LT_SYS_DYNAMIC_LINKER([TAG])
2689 # -----------------------------
2690 # PORTME Fill in your ld.so characteristics
2691 m4_defun([_LT_SYS_DYNAMIC_LINKER],
2692 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2693 m4_require([_LT_DECL_EGREP])dnl
2694 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2695 m4_require([_LT_DECL_OBJDUMP])dnl
2696 m4_require([_LT_DECL_SED])dnl
2697 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2698 m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl
2699 AC_MSG_CHECKING([dynamic linker characteristics])
2702 if test yes = "$GCC"; then
2704 darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
2705 *) lt_awk_arg='/^libraries:/' ;;
2708 mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;;
2709 *) lt_sed_strip_eq='s|=/|/|g' ;;
2711 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
2712 case $lt_search_path_spec in
2714 # if the path contains ";" then we assume it to be the separator
2715 # otherwise default to the standard path separator (i.e. ":") - it is
2716 # assumed that no part of a normal pathname contains ";" but that should
2717 # okay in the real world where ";" in dirpaths is itself problematic.
2718 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
2721 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
2724 # Ok, now we have the path, separated by spaces, we can step through it
2725 # and add multilib dir if necessary...
2726 lt_tmp_lt_search_path_spec=
2727 lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2728 # ...but if some path component already ends with the multilib dir we assume
2729 # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
2730 case "$lt_multi_os_dir; $lt_search_path_spec " in
2731 "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
2735 for lt_sys_path in $lt_search_path_spec; do
2736 if test -d "$lt_sys_path$lt_multi_os_dir"; then
2737 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
2738 elif test -n "$lt_multi_os_dir"; then
2739 test -d "$lt_sys_path" && \
2740 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2743 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2744 BEGIN {RS = " "; FS = "/|\n";} {
2747 for (lt_i = NF; lt_i > 0; lt_i--) {
2748 if ($lt_i != "" && $lt_i != ".") {
2749 if ($lt_i == "..") {
2752 if (lt_count == 0) {
2753 lt_foo = "/" $lt_i lt_foo;
2760 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2761 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2763 # AWK program above erroneously prepends '/' to C:/dos/paths
2766 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
2767 $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;;
2769 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
2771 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2774 libname_spec='lib$name'
2782 shlibpath_overrides_runpath=unknown
2784 dynamic_linker="$host_os ld.so"
2785 sys_lib_dlsearch_path_spec="/lib /usr/lib"
2786 need_lib_prefix=unknown
2787 hardcode_into_libs=no
2789 # when you set need_version to no, make sure it does not cause -set_version
2790 # flags to be left without arguments
2791 need_version=unknown
2793 AC_ARG_VAR([LT_SYS_LIBRARY_PATH],
2794 [User-defined run-time library search path.])
2798 version_type=linux # correct to gnu/linux during the next big refactor
2799 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
2800 shlibpath_var=LIBPATH
2802 # AIX 3 has no versioning support, so we append a major version to the name.
2803 soname_spec='$libname$release$shared_ext$major'
2807 version_type=linux # correct to gnu/linux during the next big refactor
2810 hardcode_into_libs=yes
2811 if test ia64 = "$host_cpu"; then
2812 # AIX 5 supports IA64
2813 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
2814 shlibpath_var=LD_LIBRARY_PATH
2816 # With GCC up to 2.95.x, collect2 would create an import file
2817 # for dependence libraries. The import file would start with
2818 # the line '#! .'. This would cause the generated library to
2819 # depend on '.', always an invalid library. This was fixed in
2820 # development snapshots of GCC prior to 3.0.
2822 aix4 | aix4.[[01]] | aix4.[[01]].*)
2823 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2825 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
2832 # Using Import Files as archive members, it is possible to support
2833 # filename-based versioning of shared library archives on AIX. While
2834 # this would work for both with and without runtime linking, it will
2835 # prevent static linking of such archives. So we do filename-based
2836 # shared library versioning with .so extension only, which is used
2837 # when both runtime linking and shared linking is enabled.
2838 # Unfortunately, runtime linking may impact performance, so we do
2839 # not want this to be the default eventually. Also, we use the
2840 # versioned .so libs for executables only if there is the -brtl
2841 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
2842 # To allow for filename-based versioning support, we need to create
2843 # libNAME.so.V as an archive file, containing:
2844 # *) an Import File, referring to the versioned filename of the
2845 # archive as well as the shared archive member, telling the
2846 # bitwidth (32 or 64) of that shared object, and providing the
2847 # list of exported symbols of that shared object, eventually
2848 # decorated with the 'weak' keyword
2849 # *) the shared object with the F_LOADONLY flag set, to really avoid
2850 # it being seen by the linker.
2851 # At run time we better use the real file rather than another symlink,
2852 # but for link time we create the symlink libNAME.so -> libNAME.so.V
2854 case $with_aix_soname,$aix_use_runtimelinking in
2855 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
2856 # soname into executable. Probably we can add versioning support to
2857 # collect2, so additional links can be useful in future.
2858 aix,yes) # traditional libtool
2859 dynamic_linker='AIX unversionable lib.so'
2860 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2861 # instead of lib<name>.a to let people know that these are not
2862 # typical AIX shared libraries.
2863 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2865 aix,no) # traditional AIX only
2866 dynamic_linker='AIX lib.a[(]lib.so.V[)]'
2867 # We preserve .a as extension for shared libraries through AIX4.2
2868 # and later when we are not doing run time linking.
2869 library_names_spec='$libname$release.a $libname.a'
2870 soname_spec='$libname$release$shared_ext$major'
2872 svr4,*) # full svr4 only
2873 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]"
2874 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
2875 # We do not specify a path in Import Files, so LIBPATH fires.
2876 shlibpath_overrides_runpath=yes
2878 *,yes) # both, prefer svr4
2879 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]"
2880 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
2881 # unpreferred sharedlib libNAME.a needs extra handling
2882 postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
2883 postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
2884 # We do not specify a path in Import Files, so LIBPATH fires.
2885 shlibpath_overrides_runpath=yes
2887 *,no) # both, prefer aix
2888 dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]"
2889 library_names_spec='$libname$release.a $libname.a'
2890 soname_spec='$libname$release$shared_ext$major'
2891 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
2892 postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
2893 postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
2896 shlibpath_var=LIBPATH
2903 # Since July 2007 AmigaOS4 officially supports .so libraries.
2904 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2905 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2908 library_names_spec='$libname.ixlibrary $libname.a'
2909 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2910 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $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'
2916 library_names_spec='$libname$shared_ext'
2917 dynamic_linker="$host_os ld.so"
2918 shlibpath_var=LIBRARY_PATH
2922 version_type=linux # correct to gnu/linux during the next big refactor
2924 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2925 soname_spec='$libname$release$shared_ext$major'
2926 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2927 shlibpath_var=LD_LIBRARY_PATH
2928 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2929 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2930 # the default ld.so.conf also contains /usr/contrib/lib and
2931 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2932 # libtool to hard-code these into programs
2935 cygwin* | mingw* | pw32* | cegcc*)
2936 version_type=windows
2941 case $GCC,$cc_basename in
2944 library_names_spec='$libname.dll.a'
2945 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2946 postinstall_cmds='base_file=`basename \$file`~
2947 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
2948 dldir=$destdir/`dirname \$dlpath`~
2949 test -d \$dldir || mkdir -p \$dldir~
2950 $install_prog $dir/$dlname \$dldir/$dlname~
2951 chmod a+x \$dldir/$dlname~
2952 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2953 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2955 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2956 dlpath=$dir/\$dldll~
2958 shlibpath_overrides_runpath=yes
2962 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2963 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2965 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
2968 # MinGW DLLs use traditional 'lib' prefix
2969 soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2972 # pw32 DLLs use 'pw' prefix rather than 'lib'
2973 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2976 dynamic_linker='Win32 ld.exe'
2981 libname_spec='$name'
2982 soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2983 library_names_spec='$libname.dll.lib'
2987 sys_lib_search_path_spec=
2993 # Let DOS variable expansion print the short 8.3 style file name.
2994 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
2995 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
2998 # Convert to MSYS style.
2999 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
3002 # Convert to unix form, then to dos form, then back to unix form
3003 # but this time dos style (no spaces!) so that the unix form looks
3004 # like /cygdrive/c/PROGRA~1:/cygdr...
3005 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
3006 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
3007 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3010 sys_lib_search_path_spec=$LIB
3011 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
3012 # It is most probably a Windows format PATH.
3013 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
3015 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3017 # FIXME: find the short name or the path components, as spaces are
3018 # common. (e.g. "Program Files" -> "PROGRA~1")
3022 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3023 postinstall_cmds='base_file=`basename \$file`~
3024 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
3025 dldir=$destdir/`dirname \$dlpath`~
3026 test -d \$dldir || mkdir -p \$dldir~
3027 $install_prog $dir/$dlname \$dldir/$dlname'
3028 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3029 dlpath=$dir/\$dldll~
3031 shlibpath_overrides_runpath=yes
3032 dynamic_linker='Win32 link.exe'
3036 # Assume MSVC wrapper
3037 library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib'
3038 dynamic_linker='Win32 ld.exe'
3041 # FIXME: first we should search . and the directory the executable is in
3045 darwin* | rhapsody*)
3046 dynamic_linker="$host_os dyld"
3050 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
3051 soname_spec='$libname$release$major$shared_ext'
3052 shlibpath_overrides_runpath=yes
3053 shlibpath_var=DYLD_LIBRARY_PATH
3054 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3056 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3057 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3061 version_type=linux # correct to gnu/linux during the next big refactor
3064 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3065 soname_spec='$libname$release$shared_ext$major'
3066 shlibpath_var=LD_LIBRARY_PATH
3069 freebsd* | dragonfly*)
3070 # DragonFly does not have aout. When/if they implement a new
3071 # versioning mechanism, adjust this.
3072 if test -x /usr/bin/objformat; then
3073 objformat=`/usr/bin/objformat`
3076 freebsd[[23]].*) objformat=aout ;;
3080 version_type=freebsd-$objformat
3081 case $version_type in
3083 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3084 soname_spec='$libname$release$shared_ext$major'
3089 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
3093 shlibpath_var=LD_LIBRARY_PATH
3096 shlibpath_overrides_runpath=yes
3098 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3099 shlibpath_overrides_runpath=yes
3100 hardcode_into_libs=yes
3102 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3103 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3104 shlibpath_overrides_runpath=no
3105 hardcode_into_libs=yes
3107 *) # from 4.6 on, and DragonFly
3108 shlibpath_overrides_runpath=yes
3109 hardcode_into_libs=yes
3115 version_type=linux # correct to gnu/linux during the next big refactor
3118 dynamic_linker="$host_os runtime_loader"
3119 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3120 soname_spec='$libname$release$shared_ext$major'
3121 shlibpath_var=LIBRARY_PATH
3122 shlibpath_overrides_runpath=no
3123 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
3124 hardcode_into_libs=yes
3127 hpux9* | hpux10* | hpux11*)
3128 # Give a soname corresponding to the major version so that dld.sl refuses to
3129 # link against other versions.
3136 hardcode_into_libs=yes
3137 dynamic_linker="$host_os dld.so"
3138 shlibpath_var=LD_LIBRARY_PATH
3139 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3140 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3141 soname_spec='$libname$release$shared_ext$major'
3142 if test 32 = "$HPUX_IA64_MODE"; then
3143 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3144 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
3146 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
3147 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
3152 hardcode_into_libs=yes
3153 dynamic_linker="$host_os dld.sl"
3154 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
3155 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3156 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3157 soname_spec='$libname$release$shared_ext$major'
3158 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3159 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3163 dynamic_linker="$host_os dld.sl"
3164 shlibpath_var=SHLIB_PATH
3165 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3166 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3167 soname_spec='$libname$release$shared_ext$major'
3170 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
3171 postinstall_cmds='chmod 555 $lib'
3172 # or fails outright, so override atomically:
3173 install_override_mode=555
3177 version_type=linux # correct to gnu/linux during the next big refactor
3180 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3181 soname_spec='$libname$release$shared_ext$major'
3182 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3183 shlibpath_var=LD_LIBRARY_PATH
3184 shlibpath_overrides_runpath=no
3185 hardcode_into_libs=yes
3188 irix5* | irix6* | nonstopux*)
3190 nonstopux*) version_type=nonstopux ;;
3192 if test yes = "$lt_cv_prog_gnu_ld"; then
3193 version_type=linux # correct to gnu/linux during the next big refactor
3200 soname_spec='$libname$release$shared_ext$major'
3201 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
3203 irix5* | nonstopux*)
3207 case $LD in # libtool.m4 will add one of these switches to LD
3208 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3209 libsuff= shlibsuff= libmagic=32-bit;;
3210 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3211 libsuff=32 shlibsuff=N32 libmagic=N32;;
3212 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3213 libsuff=64 shlibsuff=64 libmagic=64-bit;;
3214 *) libsuff= shlibsuff= libmagic=never-match;;
3218 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3219 shlibpath_overrides_runpath=no
3220 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
3221 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
3222 hardcode_into_libs=yes
3225 # No shared lib support for Linux oldld, aout, or coff.
3226 linux*oldld* | linux*aout* | linux*coff*)
3231 version_type=none # Android doesn't support versioned libraries.
3234 library_names_spec='$libname$release$shared_ext'
3235 soname_spec='$libname$release$shared_ext'
3237 shlibpath_var=LD_LIBRARY_PATH
3238 shlibpath_overrides_runpath=yes
3240 # This implies no fast_install, which is unacceptable.
3241 # Some rework will be needed to allow for fast_install
3242 # before this can be enabled.
3243 hardcode_into_libs=yes
3245 dynamic_linker='Android linker'
3246 # Don't embed -rpath directories since the linker doesn't support them.
3247 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3250 # This must be glibc/ELF.
3251 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3252 version_type=linux # correct to gnu/linux during the next big refactor
3255 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3256 soname_spec='$libname$release$shared_ext$major'
3257 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3258 shlibpath_var=LD_LIBRARY_PATH
3259 shlibpath_overrides_runpath=no
3261 # Some binutils ld are patched to set DT_RUNPATH
3262 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
3263 [lt_cv_shlibpath_overrides_runpath=no
3264 save_LDFLAGS=$LDFLAGS
3266 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3267 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3268 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3269 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3270 [lt_cv_shlibpath_overrides_runpath=yes])])
3271 LDFLAGS=$save_LDFLAGS
3274 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
3276 # This implies no fast_install, which is unacceptable.
3277 # Some rework will be needed to allow for fast_install
3278 # before this can be enabled.
3279 hardcode_into_libs=yes
3281 # Ideally, we could use ldconfig to report *all* directores which are
3282 # searched for libraries, however this is still not possible. Aside from not
3283 # being certain /sbin/ldconfig is available, command
3284 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
3285 # even though it is searched at run-time. Try to do the best guess by
3286 # appending ld.so.conf contents (and includes) to the search path.
3287 if test -f /etc/ld.so.conf; then
3288 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
3289 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3292 # We used to test for /lib/ld.so.1 and disable shared libraries on
3293 # powerpc, because MkLinux only supported shared libraries with the
3294 # GNU dynamic linker. Since this was broken with cross compilers,
3295 # most powerpc-linux boxes support dynamic linking these days and
3296 # people can always --disable-shared, the test was removed, and we
3297 # assume the GNU/Linux dynamic linker is in use.
3298 dynamic_linker='GNU/Linux ld.so'
3305 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3306 soname_spec='${libname}${release}${shared_ext}$major'
3307 shlibpath_var=LD_LIBRARY_PATH
3308 shlibpath_overrides_runpath=no
3309 hardcode_into_libs=yes
3310 dynamic_linker='NetBSD ld.elf_so'
3317 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
3318 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
3319 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3320 dynamic_linker='NetBSD (a.out) ld.so'
3322 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3323 soname_spec='$libname$release$shared_ext$major'
3324 dynamic_linker='NetBSD ld.elf_so'
3326 shlibpath_var=LD_LIBRARY_PATH
3327 shlibpath_overrides_runpath=yes
3328 hardcode_into_libs=yes
3332 version_type=linux # correct to gnu/linux during the next big refactor
3333 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3334 shlibpath_var=LD_LIBRARY_PATH
3335 shlibpath_overrides_runpath=yes
3342 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3343 soname_spec='$libname$release$shared_ext$major'
3344 shlibpath_var=LD_LIBRARY_PATH
3345 shlibpath_overrides_runpath=no
3346 hardcode_into_libs=yes
3347 dynamic_linker='ldqnx.so'
3352 sys_lib_dlsearch_path_spec=/usr/lib
3354 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
3359 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
3360 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3361 shlibpath_var=LD_LIBRARY_PATH
3362 shlibpath_overrides_runpath=yes
3366 libname_spec='$name'
3367 version_type=windows
3371 # OS/2 can only load a DLL with a base name of 8 characters or less.
3372 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
3373 v=$($ECHO $release$versuffix | tr -d .-);
3374 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
3375 $ECHO $n$v`$shared_ext'
3376 library_names_spec='${libname}_dll.$libext'
3377 dynamic_linker='OS/2 ld.exe'
3378 shlibpath_var=BEGINLIBPATH
3379 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
3380 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3381 postinstall_cmds='base_file=`basename \$file`~
3382 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
3383 dldir=$destdir/`dirname \$dlpath`~
3384 test -d \$dldir || mkdir -p \$dldir~
3385 $install_prog $dir/$dlname \$dldir/$dlname~
3386 chmod a+x \$dldir/$dlname~
3387 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
3388 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
3390 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
3391 dlpath=$dir/\$dldll~
3395 osf3* | osf4* | osf5*)
3399 soname_spec='$libname$release$shared_ext$major'
3400 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3401 shlibpath_var=LD_LIBRARY_PATH
3402 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
3403 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3411 version_type=linux # correct to gnu/linux during the next big refactor
3414 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3415 soname_spec='$libname$release$shared_ext$major'
3416 shlibpath_var=LD_LIBRARY_PATH
3417 shlibpath_overrides_runpath=yes
3418 hardcode_into_libs=yes
3419 # ldd complains unless libraries are executable
3420 postinstall_cmds='chmod +x $lib'
3425 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
3426 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
3427 shlibpath_var=LD_LIBRARY_PATH
3428 shlibpath_overrides_runpath=yes
3429 if test yes = "$with_gnu_ld"; then
3436 version_type=linux # correct to gnu/linux during the next big refactor
3437 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3438 soname_spec='$libname$release$shared_ext$major'
3439 shlibpath_var=LD_LIBRARY_PATH
3440 case $host_vendor in
3442 shlibpath_overrides_runpath=no
3444 runpath_var=LD_RUN_PATH
3452 shlibpath_overrides_runpath=no
3453 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
3459 if test -d /usr/nec; then
3460 version_type=linux # correct to gnu/linux during the next big refactor
3461 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
3462 soname_spec='$libname$shared_ext.$major'
3463 shlibpath_var=LD_LIBRARY_PATH
3467 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3471 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
3472 soname_spec='$libname$release$shared_ext$major'
3473 shlibpath_var=LD_LIBRARY_PATH
3474 shlibpath_overrides_runpath=yes
3475 hardcode_into_libs=yes
3476 if test yes = "$with_gnu_ld"; then
3477 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
3479 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
3482 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
3486 sys_lib_dlsearch_path_spec='/usr/lib'
3490 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
3491 version_type=linux # correct to gnu/linux during the next big refactor
3494 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3495 shlibpath_var=LD_LIBRARY_PATH
3496 shlibpath_overrides_runpath=no
3497 hardcode_into_libs=yes
3501 version_type=linux # correct to gnu/linux during the next big refactor
3502 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3503 soname_spec='$libname$release$shared_ext$major'
3504 shlibpath_var=LD_LIBRARY_PATH
3511 AC_MSG_RESULT([$dynamic_linker])
3512 test no = "$dynamic_linker" && can_build_shared=no
3514 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3515 if test yes = "$GCC"; then
3516 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3519 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
3520 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
3523 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
3524 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
3527 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
3528 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
3530 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
3531 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
3533 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
3534 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
3536 _LT_DECL([], [variables_saved_for_relink], [1],
3537 [Variables whose values should be saved in libtool wrapper scripts and
3538 restored at link time])
3539 _LT_DECL([], [need_lib_prefix], [0],
3540 [Do we need the "lib" prefix for modules?])
3541 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3542 _LT_DECL([], [version_type], [0], [Library versioning type])
3543 _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3544 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3545 _LT_DECL([], [shlibpath_overrides_runpath], [0],
3546 [Is shlibpath searched before the hard-coded library search path?])
3547 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3548 _LT_DECL([], [library_names_spec], [1],
3549 [[List of archive names. First name is the real one, the rest are links.
3550 The last name is the one that the linker finds with -lNAME]])
3551 _LT_DECL([], [soname_spec], [1],
3552 [[The coded name of the library, if different from the real name]])
3553 _LT_DECL([], [install_override_mode], [1],
3554 [Permission mode override for installation of shared libraries])
3555 _LT_DECL([], [postinstall_cmds], [2],
3556 [Command to use after installation of a shared archive])
3557 _LT_DECL([], [postuninstall_cmds], [2],
3558 [Command to use after uninstallation of a shared archive])
3559 _LT_DECL([], [finish_cmds], [2],
3560 [Commands used to finish a libtool library installation in a directory])
3561 _LT_DECL([], [finish_eval], [1],
3562 [[As "finish_cmds", except a single script fragment to be evaled but
3564 _LT_DECL([], [hardcode_into_libs], [0],
3565 [Whether we should hardcode library paths into libraries])
3566 _LT_DECL([], [sys_lib_search_path_spec], [2],
3567 [Compile-time system search path for libraries])
3568 _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2],
3569 [Detected run-time system search path for libraries])
3570 _LT_DECL([], [configure_time_lt_sys_library_path], [2],
3571 [Explicit LT_SYS_LIBRARY_PATH set during ./configure time])
3572 ])# _LT_SYS_DYNAMIC_LINKER
3575 # _LT_PATH_TOOL_PREFIX(TOOL)
3576 # --------------------------
3577 # find a file program that can recognize shared library
3578 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3579 [m4_require([_LT_DECL_EGREP])dnl
3580 AC_MSG_CHECKING([for $1])
3581 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3583 [[\\/*] | ?:[\\/]*])
3584 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
3587 lt_save_MAGIC_CMD=$MAGIC_CMD
3588 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
3589 dnl $ac_dummy forces splitting on constant user-supplied paths.
3590 dnl POSIX.2 word splitting is done only on the output of word expansions,
3591 dnl not every word. This closes a longstanding sh security hole.
3592 ac_dummy="m4_if([$2], , $PATH, [$2])"
3593 for ac_dir in $ac_dummy; do
3595 test -z "$ac_dir" && ac_dir=.
3596 if test -f "$ac_dir/$1"; then
3597 lt_cv_path_MAGIC_CMD=$ac_dir/"$1"
3598 if test -n "$file_magic_test_file"; then
3599 case $deplibs_check_method in
3601 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3602 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
3603 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3604 $EGREP "$file_magic_regex" > /dev/null; then
3609 *** Warning: the command libtool uses to detect shared libraries,
3610 *** $file_magic_cmd, produces output that libtool cannot recognize.
3611 *** The result is that libtool may fail to recognize shared libraries
3612 *** as such. This will affect the creation of libtool libraries that
3613 *** depend on shared libraries, but programs linked with such libtool
3614 *** libraries will work regardless of this problem. Nevertheless, you
3615 *** may want to report the problem to your system manager and/or to
3616 *** bug-libtool@gnu.org
3626 MAGIC_CMD=$lt_save_MAGIC_CMD
3629 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
3630 if test -n "$MAGIC_CMD"; then
3631 AC_MSG_RESULT($MAGIC_CMD)
3635 _LT_DECL([], [MAGIC_CMD], [0],
3636 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3637 ])# _LT_PATH_TOOL_PREFIX
3640 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3641 dnl aclocal-1.4 backwards compatibility:
3642 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3647 # find a file program that can recognize a shared library
3648 m4_defun([_LT_PATH_MAGIC],
3649 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3650 if test -z "$lt_cv_path_MAGIC_CMD"; then
3651 if test -n "$ac_tool_prefix"; then
3652 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3662 # find the pathname to the GNU or non-GNU linker
3663 AC_DEFUN([LT_PATH_LD],
3664 [AC_REQUIRE([AC_PROG_CC])dnl
3665 AC_REQUIRE([AC_CANONICAL_HOST])dnl
3666 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3667 m4_require([_LT_DECL_SED])dnl
3668 m4_require([_LT_DECL_EGREP])dnl
3669 m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
3671 AC_ARG_WITH([gnu-ld],
3672 [AS_HELP_STRING([--with-gnu-ld],
3673 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3674 [test no = "$withval" || with_gnu_ld=yes],
3675 [with_gnu_ld=no])dnl
3678 if test yes = "$GCC"; then
3679 # Check if gcc -print-prog-name=ld gives a path.
3680 AC_MSG_CHECKING([for ld used by $CC])
3683 # gcc leaves a trailing carriage return, which upsets mingw
3684 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3686 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3689 # Accept absolute paths.
3690 [[\\/]]* | ?:[[\\/]]*)
3691 re_direlt='/[[^/]][[^/]]*/\.\./'
3692 # Canonicalize the pathname of ld
3693 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3694 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3695 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3697 test -z "$LD" && LD=$ac_prog
3700 # If it fails, then pretend we aren't using GCC.
3704 # If it is relative, then search for the first ld in PATH.
3708 elif test yes = "$with_gnu_ld"; then
3709 AC_MSG_CHECKING([for GNU ld])
3711 AC_MSG_CHECKING([for non-GNU ld])
3713 AC_CACHE_VAL(lt_cv_path_LD,
3714 [if test -z "$LD"; then
3715 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
3716 for ac_dir in $PATH; do
3718 test -z "$ac_dir" && ac_dir=.
3719 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3720 lt_cv_path_LD=$ac_dir/$ac_prog
3721 # Check to see if the program is GNU ld. I'd rather use --version,
3722 # but apparently some variants of GNU ld only accept -v.
3723 # Break only if it was the GNU/non-GNU ld that we prefer.
3724 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3725 *GNU* | *'with BFD'*)
3726 test no != "$with_gnu_ld" && break
3729 test yes != "$with_gnu_ld" && break
3736 lt_cv_path_LD=$LD # Let the user override the test with a path.
3739 if test -n "$LD"; then
3744 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3748 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3752 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3753 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3754 dnl aclocal-1.4 backwards compatibility:
3755 dnl AC_DEFUN([AM_PROG_LD], [])
3756 dnl AC_DEFUN([AC_PROG_LD], [])
3761 m4_defun([_LT_PATH_LD_GNU],
3762 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3763 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
3764 case `$LD -v 2>&1 </dev/null` in
3765 *GNU* | *'with BFD'*)
3766 lt_cv_prog_gnu_ld=yes
3769 lt_cv_prog_gnu_ld=no
3772 with_gnu_ld=$lt_cv_prog_gnu_ld
3778 # find reload flag for linker
3779 # -- PORTME Some linkers may need a different reload flag.
3780 m4_defun([_LT_CMD_RELOAD],
3781 [AC_CACHE_CHECK([for $LD option to reload object files],
3782 lt_cv_ld_reload_flag,
3783 [lt_cv_ld_reload_flag='-r'])
3784 reload_flag=$lt_cv_ld_reload_flag
3785 case $reload_flag in
3787 *) reload_flag=" $reload_flag" ;;
3789 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3791 cygwin* | mingw* | pw32* | cegcc*)
3792 if test yes != "$GCC"; then
3797 if test yes = "$GCC"; then
3798 reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
3800 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3804 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3805 _LT_TAGDECL([], [reload_cmds], [2])dnl
3812 m4_defun([_LT_PATH_DD],
3813 [AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD],
3814 [printf 0123456789abcdef0123456789abcdef >conftest.i
3815 cat conftest.i conftest.i >conftest2.i
3817 AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd],
3818 [if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
3819 cmp -s conftest.i conftest.out \
3820 && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
3822 rm -f conftest.i conftest2.i conftest.out])
3828 # find command to truncate a binary pipe
3829 m4_defun([_LT_CMD_TRUNCATE],
3830 [m4_require([_LT_PATH_DD])
3831 AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin],
3832 [printf 0123456789abcdef0123456789abcdef >conftest.i
3833 cat conftest.i conftest.i >conftest2.i
3835 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
3836 cmp -s conftest.i conftest.out \
3837 && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
3839 rm -f conftest.i conftest2.i conftest.out
3840 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"])
3841 _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1],
3842 [Command to truncate a binary pipe])
3843 ])# _LT_CMD_TRUNCATE
3846 # _LT_CHECK_MAGIC_METHOD
3847 # ----------------------
3848 # how to check for library dependencies
3849 # -- PORTME fill in with the dynamic library characteristics
3850 m4_defun([_LT_CHECK_MAGIC_METHOD],
3851 [m4_require([_LT_DECL_EGREP])
3852 m4_require([_LT_DECL_OBJDUMP])
3853 AC_CACHE_CHECK([how to recognize dependent libraries],
3854 lt_cv_deplibs_check_method,
3855 [lt_cv_file_magic_cmd='$MAGIC_CMD'
3856 lt_cv_file_magic_test_file=
3857 lt_cv_deplibs_check_method='unknown'
3858 # Need to set the preceding variable on all platforms that support
3859 # interlibrary dependencies.
3860 # 'none' -- dependencies not supported.
3861 # 'unknown' -- same as none, but documents that we really don't know.
3862 # 'pass_all' -- all dependencies passed with no checks.
3863 # 'test_compile' -- check by making test program.
3864 # 'file_magic [[regex]]' -- check by looking for files in library path
3865 # that responds to the $file_magic_cmd with a given extended regex.
3866 # If you have 'file' or equivalent on your system and you're not sure
3867 # whether 'pass_all' will *always* work, you probably want this one.
3871 lt_cv_deplibs_check_method=pass_all
3875 lt_cv_deplibs_check_method=pass_all
3879 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3880 lt_cv_file_magic_cmd='/usr/bin/file -L'
3881 lt_cv_file_magic_test_file=/shlib/libc.so
3885 # func_win32_libid is a shell function defined in ltmain.sh
3886 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3887 lt_cv_file_magic_cmd='func_win32_libid'
3891 # Base MSYS/MinGW do not provide the 'file' command needed by
3892 # func_win32_libid shell function, so use a weaker test based on 'objdump',
3893 # unless we find 'file', for example because we are cross-compiling.
3894 if ( file / ) >/dev/null 2>&1; then
3895 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3896 lt_cv_file_magic_cmd='func_win32_libid'
3898 # Keep this pattern in sync with the one in func_win32_libid.
3899 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
3900 lt_cv_file_magic_cmd='$OBJDUMP -f'
3905 # use the weaker test based on 'objdump'. See mingw*.
3906 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3907 lt_cv_file_magic_cmd='$OBJDUMP -f'
3910 darwin* | rhapsody*)
3911 lt_cv_deplibs_check_method=pass_all
3914 freebsd* | dragonfly*)
3915 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3918 # Not sure whether the presence of OpenBSD here was a mistake.
3919 # Let's accept both of them until this is cleared up.
3920 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3921 lt_cv_file_magic_cmd=/usr/bin/file
3922 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3926 lt_cv_deplibs_check_method=pass_all
3931 lt_cv_deplibs_check_method=pass_all
3934 hpux10.20* | hpux11*)
3935 lt_cv_file_magic_cmd=/usr/bin/file
3938 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3939 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3942 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
3943 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3946 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
3947 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3953 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3954 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3957 irix5* | irix6* | nonstopux*)
3959 *-32|*"-32 ") libmagic=32-bit;;
3960 *-n32|*"-n32 ") libmagic=N32;;
3961 *-64|*"-64 ") libmagic=64-bit;;
3962 *) libmagic=never-match;;
3964 lt_cv_deplibs_check_method=pass_all
3967 # This must be glibc/ELF.
3968 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3969 lt_cv_deplibs_check_method=pass_all
3972 netbsd* | netbsdelf*-gnu)
3973 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3974 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3976 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3981 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3982 lt_cv_file_magic_cmd=/usr/bin/file
3983 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3987 lt_cv_deplibs_check_method=pass_all
3991 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
3992 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3994 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3998 osf3* | osf4* | osf5*)
3999 lt_cv_deplibs_check_method=pass_all
4003 lt_cv_deplibs_check_method=pass_all
4007 lt_cv_deplibs_check_method=pass_all
4010 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4011 lt_cv_deplibs_check_method=pass_all
4015 case $host_vendor in
4017 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]]'
4018 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
4021 lt_cv_deplibs_check_method=pass_all
4024 lt_cv_file_magic_cmd='/bin/file'
4025 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
4028 lt_cv_file_magic_cmd='/bin/file'
4029 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
4030 lt_cv_file_magic_test_file=/lib/libc.so
4033 lt_cv_deplibs_check_method=pass_all
4036 lt_cv_deplibs_check_method=pass_all
4042 lt_cv_deplibs_check_method=pass_all
4045 lt_cv_deplibs_check_method=pass_all
4052 if test "$build" = "$host"; then
4055 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
4058 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
4064 file_magic_cmd=$lt_cv_file_magic_cmd
4065 deplibs_check_method=$lt_cv_deplibs_check_method
4066 test -z "$deplibs_check_method" && deplibs_check_method=unknown
4068 _LT_DECL([], [deplibs_check_method], [1],
4069 [Method to check whether dependent libraries are shared objects])
4070 _LT_DECL([], [file_magic_cmd], [1],
4071 [Command to use when deplibs_check_method = "file_magic"])
4072 _LT_DECL([], [file_magic_glob], [1],
4073 [How to find potential files when deplibs_check_method = "file_magic"])
4074 _LT_DECL([], [want_nocaseglob], [1],
4075 [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
4076 ])# _LT_CHECK_MAGIC_METHOD
4081 # find the pathname to a BSD- or MS-compatible name lister
4082 AC_DEFUN([LT_PATH_NM],
4083 [AC_REQUIRE([AC_PROG_CC])dnl
4084 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
4085 [if test -n "$NM"; then
4086 # Let the user override the test.
4089 lt_nm_to_check=${ac_tool_prefix}nm
4090 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4091 lt_nm_to_check="$lt_nm_to_check nm"
4093 for lt_tmp_nm in $lt_nm_to_check; do
4094 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
4095 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4097 test -z "$ac_dir" && ac_dir=.
4098 tmp_nm=$ac_dir/$lt_tmp_nm
4099 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
4100 # Check to see if the nm accepts a BSD-compat flag.
4101 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
4102 # nm: unknown option "B" ignored
4103 # Tru64's nm complains that /dev/null is an invalid object file
4104 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
4106 mingw*) lt_bad_file=conftest.nm/nofile ;;
4107 *) lt_bad_file=/dev/null ;;
4109 case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
4110 *$lt_bad_file* | *'Invalid file or object type'*)
4111 lt_cv_path_NM="$tmp_nm -B"
4115 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4117 lt_cv_path_NM="$tmp_nm -p"
4121 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4122 continue # so that we can try to find one that supports BSD flags
4131 : ${lt_cv_path_NM=no}
4133 if test no != "$lt_cv_path_NM"; then
4136 # Didn't find any BSD compatible name lister, look for dumpbin.
4137 if test -n "$DUMPBIN"; then :
4138 # Let the user override the test.
4140 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
4141 case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
4143 DUMPBIN="$DUMPBIN -symbols -headers"
4151 if test : != "$DUMPBIN"; then
4155 test -z "$NM" && NM=nm
4157 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
4159 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
4160 [lt_cv_nm_interface="BSD nm"
4161 echo "int some_variable = 0;" > conftest.$ac_ext
4162 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
4163 (eval "$ac_compile" 2>conftest.err)
4164 cat conftest.err >&AS_MESSAGE_LOG_FD
4165 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
4166 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4167 cat conftest.err >&AS_MESSAGE_LOG_FD
4168 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
4169 cat conftest.out >&AS_MESSAGE_LOG_FD
4170 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4171 lt_cv_nm_interface="MS dumpbin"
4177 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
4178 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
4179 dnl aclocal-1.4 backwards compatibility:
4180 dnl AC_DEFUN([AM_PROG_NM], [])
4181 dnl AC_DEFUN([AC_PROG_NM], [])
4183 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4184 # --------------------------------
4185 # how to determine the name of the shared library
4186 # associated with a specific link library.
4187 # -- PORTME fill in with the dynamic library characteristics
4188 m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
4189 [m4_require([_LT_DECL_EGREP])
4190 m4_require([_LT_DECL_OBJDUMP])
4191 m4_require([_LT_DECL_DLLTOOL])
4192 AC_CACHE_CHECK([how to associate runtime and link libraries],
4193 lt_cv_sharedlib_from_linklib_cmd,
4194 [lt_cv_sharedlib_from_linklib_cmd='unknown'
4197 cygwin* | mingw* | pw32* | cegcc*)
4198 # two different shell functions defined in ltmain.sh;
4199 # decide which one to use based on capabilities of $DLLTOOL
4200 case `$DLLTOOL --help 2>&1` in
4201 *--identify-strict*)
4202 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
4205 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
4210 # fallback: assume linklib IS sharedlib
4211 lt_cv_sharedlib_from_linklib_cmd=$ECHO
4215 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
4216 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
4218 _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
4219 [Command to associate shared and link libraries])
4220 ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4223 # _LT_PATH_MANIFEST_TOOL
4224 # ----------------------
4225 # locate the manifest tool
4226 m4_defun([_LT_PATH_MANIFEST_TOOL],
4227 [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
4228 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
4229 AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
4230 [lt_cv_path_mainfest_tool=no
4231 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
4232 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
4233 cat conftest.err >&AS_MESSAGE_LOG_FD
4234 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
4235 lt_cv_path_mainfest_tool=yes
4238 if test yes != "$lt_cv_path_mainfest_tool"; then
4241 _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
4242 ])# _LT_PATH_MANIFEST_TOOL
4245 # _LT_DLL_DEF_P([FILE])
4246 # ---------------------
4247 # True iff FILE is a Windows DLL '.def' file.
4248 # Keep in sync with func_dll_def_p in the libtool script
4249 AC_DEFUN([_LT_DLL_DEF_P],
4251 test DEF = "`$SED -n dnl
4252 -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace
4253 -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments
4254 -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl
4255 -e q dnl Only consider the first "real" line
4262 # check for math library
4263 AC_DEFUN([LT_LIB_M],
4264 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4267 *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
4268 # These system don't have libm, or don't need it
4271 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw)
4272 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
4275 AC_CHECK_LIB(m, cos, LIBM=-lm)
4282 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
4283 dnl aclocal-1.4 backwards compatibility:
4284 dnl AC_DEFUN([AC_CHECK_LIBM], [])
4287 # _LT_COMPILER_NO_RTTI([TAGNAME])
4288 # -------------------------------
4289 m4_defun([_LT_COMPILER_NO_RTTI],
4290 [m4_require([_LT_TAG_COMPILER])dnl
4292 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4294 if test yes = "$GCC"; then
4295 case $cc_basename in
4297 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
4299 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
4302 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4303 lt_cv_prog_compiler_rtti_exceptions,
4304 [-fno-rtti -fno-exceptions], [],
4305 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4307 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
4308 [Compiler flag to turn off builtin functions])
4309 ])# _LT_COMPILER_NO_RTTI
4312 # _LT_CMD_GLOBAL_SYMBOLS
4313 # ----------------------
4314 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
4315 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4316 AC_REQUIRE([AC_PROG_CC])dnl
4317 AC_REQUIRE([AC_PROG_AWK])dnl
4318 AC_REQUIRE([LT_PATH_NM])dnl
4319 AC_REQUIRE([LT_PATH_LD])dnl
4320 m4_require([_LT_DECL_SED])dnl
4321 m4_require([_LT_DECL_EGREP])dnl
4322 m4_require([_LT_TAG_COMPILER])dnl
4324 # Check for command to grab the raw symbol name followed by C symbol from nm.
4325 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4326 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4328 # These are sane defaults that work on at least a few old systems.
4329 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4331 # Character class describing NM global symbol codes.
4332 symcode='[[BCDEGRST]]'
4334 # Regexp to match symbols that can be accessed directly from C.
4335 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4337 # Define system-specific variables.
4342 cygwin* | mingw* | pw32* | cegcc*)
4343 symcode='[[ABCDGISTW]]'
4346 if test ia64 = "$host_cpu"; then
4347 symcode='[[ABCDEGRST]]'
4351 symcode='[[BCDEGRST]]'
4354 symcode='[[BCDEGQRST]]'
4365 sysv5* | sco5v6* | unixware* | OpenUNIX*)
4369 symcode='[[DFNSTU]]'
4373 # If we're using GNU nm, then use its standard symbol codes.
4374 case `$NM -V 2>&1` in
4375 *GNU* | *'with BFD'*)
4376 symcode='[[ABCDGIRSTW]]' ;;
4379 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4380 # Gets list of data symbols to import.
4381 lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
4382 # Adjust the below global symbol transforms to fixup imported variables.
4383 lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
4384 lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
4385 lt_c_name_lib_hook="\
4386 -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
4387 -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
4389 # Disable hooks by default.
4390 lt_cv_sys_global_symbol_to_import=
4396 # Transform an extracted symbol line into a proper C declaration.
4397 # Some systems (esp. on ia64) link data and code symbols differently,
4398 # so use this general approach.
4399 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
4401 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
4402 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
4404 # Transform an extracted symbol line into symbol name and symbol address
4405 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
4407 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
4408 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
4410 # Transform an extracted symbol line into symbol name with lib prefix and
4412 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
4413 $lt_c_name_lib_hook\
4414 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
4415 " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
4416 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
4418 # Handle CRLF in mingw tool chain
4422 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4426 # Try without a prefix underscore, then with it.
4427 for ac_symprfx in "" "_"; do
4429 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4430 symxfrm="\\1 $ac_symprfx\\2 \\2"
4432 # Write the raw and C identifiers.
4433 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4434 # Fake it for dumpbin and say T for any non-static function,
4435 # D for any global variable and I for any imported variable.
4436 # Also find C++ and __fastcall symbols from MSVC++,
4437 # which start with @ or ?.
4438 lt_cv_sys_global_symbol_pipe="$AWK ['"\
4439 " {last_section=section; section=\$ 3};"\
4440 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
4441 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
4442 " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
4443 " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
4444 " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
4445 " \$ 0!~/External *\|/{next};"\
4446 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
4447 " {if(hide[section]) next};"\
4448 " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
4449 " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
4450 " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
4451 " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
4452 " ' prfx=^$ac_symprfx]"
4454 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4456 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
4458 # Check to see that the pipe works correctly.
4462 cat > conftest.$ac_ext <<_LT_EOF
4467 void nm_test_func(void);
4468 void nm_test_func(void){}
4472 int main(){nm_test_var='a';nm_test_func();return(0);}
4475 if AC_TRY_EVAL(ac_compile); then
4476 # Now try to grab the symbols.
4478 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
4479 # Try sorting and uniquifying the output.
4480 if sort "$nlist" | uniq > "$nlist"T; then
4481 mv -f "$nlist"T "$nlist"
4486 # Make sure that we snagged all the symbols we need.
4487 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
4488 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
4489 cat <<_LT_EOF > conftest.$ac_ext
4490 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
4491 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
4492 /* DATA imports from DLLs on WIN32 can't be const, because runtime
4493 relocations are performed -- see ld's documentation on pseudo-relocs. */
4494 # define LT@&t@_DLSYM_CONST
4495 #elif defined __osf__
4496 /* This system does not cope well with relocations in const data. */
4497 # define LT@&t@_DLSYM_CONST
4499 # define LT@&t@_DLSYM_CONST const
4507 # Now generate the symbol file.
4508 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
4510 cat <<_LT_EOF >> conftest.$ac_ext
4512 /* The mapping between symbol names and symbols. */
4513 LT@&t@_DLSYM_CONST struct {
4517 lt__PROGRAM__LTX_preloaded_symbols[[]] =
4519 { "@PROGRAM@", (void *) 0 },
4521 $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4522 cat <<\_LT_EOF >> conftest.$ac_ext
4526 /* This works around a problem in FreeBSD linker */
4527 #ifdef FREEBSD_WORKAROUND
4528 static const void *lt_preloaded_setup() {
4529 return lt__PROGRAM__LTX_preloaded_symbols;
4537 # Now try linking the two files.
4538 mv conftest.$ac_objext conftstm.$ac_objext
4539 lt_globsym_save_LIBS=$LIBS
4540 lt_globsym_save_CFLAGS=$CFLAGS
4541 LIBS=conftstm.$ac_objext
4542 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4543 if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then
4546 LIBS=$lt_globsym_save_LIBS
4547 CFLAGS=$lt_globsym_save_CFLAGS
4549 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4552 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4555 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4558 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4559 cat conftest.$ac_ext >&5
4561 rm -rf conftest* conftst*
4563 # Do not use the global_symbol_pipe unless it works.
4564 if test yes = "$pipe_works"; then
4567 lt_cv_sys_global_symbol_pipe=
4571 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4572 lt_cv_sys_global_symbol_to_cdecl=
4574 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4575 AC_MSG_RESULT(failed)
4580 # Response file support.
4581 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4582 nm_file_list_spec='@'
4583 elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
4584 nm_file_list_spec='@'
4587 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
4588 [Take the output of nm and produce a listing of raw symbols and C names])
4589 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
4590 [Transform the output of nm in a proper C declaration])
4591 _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1],
4592 [Transform the output of nm into a list of symbols to manually relocate])
4593 _LT_DECL([global_symbol_to_c_name_address],
4594 [lt_cv_sys_global_symbol_to_c_name_address], [1],
4595 [Transform the output of nm in a C name address pair])
4596 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
4597 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
4598 [Transform the output of nm in a C name address pair when lib prefix is needed])
4599 _LT_DECL([nm_interface], [lt_cv_nm_interface], [1],
4600 [The name lister interface])
4601 _LT_DECL([], [nm_file_list_spec], [1],
4602 [Specify filename containing input files for $NM])
4603 ]) # _LT_CMD_GLOBAL_SYMBOLS
4606 # _LT_COMPILER_PIC([TAGNAME])
4607 # ---------------------------
4608 m4_defun([_LT_COMPILER_PIC],
4609 [m4_require([_LT_TAG_COMPILER])dnl
4610 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
4611 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4612 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4614 m4_if([$1], [CXX], [
4615 # C++ specific cases for pic, static, wl, etc.
4616 if test yes = "$GXX"; then
4617 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4618 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4622 # All AIX code is PIC.
4623 if test ia64 = "$host_cpu"; then
4624 # AIX 5 now supports IA64 processor
4625 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4627 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4633 # see comment about AmigaOS4 .so support
4634 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4637 # FIXME: we need at least 68020 code to build shared libraries, but
4638 # adding the '-m68020' flag to GCC prevents building anything better,
4640 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4645 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4646 # PIC is the default for these OSes.
4648 mingw* | cygwin* | os2* | pw32* | cegcc*)
4649 # This hack is so that the source file can tell whether it is being
4650 # built for inclusion in a dll (and should export symbols for example).
4651 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4652 # (--disable-auto-import) libraries
4653 m4_if([$1], [GCJ], [],
4654 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4657 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4661 darwin* | rhapsody*)
4662 # PIC is the default on this platform
4663 # Common symbols not allowed in MH_DYLIB files
4664 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4667 # DJGPP does not support shared libraries at all
4668 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4671 # PIC is the default for Haiku.
4672 # The "-static" flag exists, but is broken.
4673 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4676 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4677 # Instead, we relocate shared libraries at runtime.
4680 if test -d /usr/nec; then
4681 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4685 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4686 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4687 # sets the default TLS model and affects inlining.
4692 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4697 # QNX uses GNU C++, but need to define -shared option too, otherwise
4699 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4702 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4708 # All AIX code is PIC.
4709 if test ia64 = "$host_cpu"; then
4710 # AIX 5 now supports IA64 processor
4711 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4713 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4717 case $cc_basename in
4719 # Green Hills C++ Compiler
4720 # _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"
4724 mingw* | cygwin* | os2* | pw32* | cegcc*)
4725 # This hack is so that the source file can tell whether it is being
4726 # built for inclusion in a dll (and should export symbols for example).
4727 m4_if([$1], [GCJ], [],
4728 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4731 case $cc_basename in
4733 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4736 # Green Hills C++ Compiler
4737 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4743 freebsd* | dragonfly*)
4744 # FreeBSD uses GNU C++
4746 hpux9* | hpux10* | hpux11*)
4747 case $cc_basename in
4749 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4750 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
4751 if test ia64 != "$host_cpu"; then
4752 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4756 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4757 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
4763 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4772 # This is c89, which is MS Visual C++ (no shared libs)
4773 # Anyone wants to do a port?
4775 irix5* | irix6* | nonstopux*)
4776 case $cc_basename in
4778 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4779 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4780 # CC pic flag -KPIC is the default.
4786 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4787 case $cc_basename in
4790 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4791 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4794 # old Intel C++ for x86_64, which still supported -KPIC.
4795 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4796 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4797 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4800 # Intel C++, used to be incompatible with GCC.
4801 # ICC 10 doesn't accept -KPIC any more.
4802 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4803 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4804 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4807 # Portland Group C++ compiler
4808 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4809 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4810 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4814 # Make sure the PIC flag is empty. It appears that all Alpha
4815 # Linux and Compaq Tru64 Unix objects are PIC.
4816 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4817 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4819 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
4820 # IBM XL 8.0, 9.0 on PPC and BlueGene
4821 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4822 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4823 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4826 case `$CC -V 2>&1 | sed 5q` in
4829 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4830 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4831 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4842 case $cc_basename in
4844 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4850 netbsd* | netbsdelf*-gnu)
4853 # QNX uses GNU C++, but need to define -shared option too, otherwise
4855 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4857 osf3* | osf4* | osf5*)
4858 case $cc_basename in
4860 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4863 # Rational C++ 2.4.1
4864 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4867 # Digital/Compaq C++
4868 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4869 # Make sure the PIC flag is empty. It appears that all Alpha
4870 # Linux and Compaq Tru64 Unix objects are PIC.
4871 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4872 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4881 case $cc_basename in
4883 # Sun C++ 4.2, 5.x and Centerline C++
4884 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4885 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4886 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4889 # Green Hills C++ Compiler
4890 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4897 case $cc_basename in
4900 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4901 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4905 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4911 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4912 case $cc_basename in
4914 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4915 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4916 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4921 case $cc_basename in
4923 # NonStop-UX NCC 3.20
4924 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4933 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4939 if test yes = "$GCC"; then
4940 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4941 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4945 # All AIX code is PIC.
4946 if test ia64 = "$host_cpu"; then
4947 # AIX 5 now supports IA64 processor
4948 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4950 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4956 # see comment about AmigaOS4 .so support
4957 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4960 # FIXME: we need at least 68020 code to build shared libraries, but
4961 # adding the '-m68020' flag to GCC prevents building anything better,
4963 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4968 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4969 # PIC is the default for these OSes.
4972 mingw* | cygwin* | pw32* | os2* | cegcc*)
4973 # This hack is so that the source file can tell whether it is being
4974 # built for inclusion in a dll (and should export symbols for example).
4975 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4976 # (--disable-auto-import) libraries
4977 m4_if([$1], [GCJ], [],
4978 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4981 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4986 darwin* | rhapsody*)
4987 # PIC is the default on this platform
4988 # Common symbols not allowed in MH_DYLIB files
4989 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4993 # PIC is the default for Haiku.
4994 # The "-static" flag exists, but is broken.
4995 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4999 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5000 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
5001 # sets the default TLS model and affects inlining.
5007 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5013 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5014 # Instead, we relocate shared libraries at runtime.
5018 # Just because we use GCC doesn't mean we suddenly get shared libraries
5019 # on systems that don't support them.
5020 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5025 # QNX uses GNU C++, but need to define -shared option too, otherwise
5027 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5031 if test -d /usr/nec; then
5032 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5037 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5041 case $cc_basename in
5042 nvcc*) # Cuda Compiler Driver 2.2
5043 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
5044 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5045 _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
5050 # PORTME Check for flag to pass linker flags through the system compiler.
5053 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5054 if test ia64 = "$host_cpu"; then
5055 # AIX 5 now supports IA64 processor
5056 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5058 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5062 darwin* | rhapsody*)
5063 # PIC is the default on this platform
5064 # Common symbols not allowed in MH_DYLIB files
5065 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5066 case $cc_basename in
5068 # NAG Fortran compiler
5069 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
5070 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5071 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5076 mingw* | cygwin* | pw32* | os2* | cegcc*)
5077 # This hack is so that the source file can tell whether it is being
5078 # built for inclusion in a dll (and should export symbols for example).
5079 m4_if([$1], [GCJ], [],
5080 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5083 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
5088 hpux9* | hpux10* | hpux11*)
5089 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5090 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5097 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5100 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5101 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
5104 irix5* | irix6* | nonstopux*)
5105 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5106 # PIC (with -KPIC) is the default.
5107 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5110 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
5111 case $cc_basename in
5112 # old Intel for x86_64, which still supported -KPIC.
5114 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5115 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5116 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5118 # icc used to be incompatible with GCC.
5119 # ICC 10 doesn't accept -KPIC any more.
5121 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5122 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5123 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5125 # Lahey Fortran 8.1.
5127 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5128 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
5129 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
5132 # NAG Fortran compiler
5133 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
5134 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5135 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5138 # Fabrice Bellard et al's Tiny C Compiler
5139 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5140 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5141 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5143 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
5144 # Portland Group compilers (*not* the Pentium gcc compiler,
5145 # which looks to be a dead project)
5146 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5147 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5148 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5151 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5152 # All Alpha code is PIC.
5153 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5155 xl* | bgxl* | bgf* | mpixl*)
5156 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
5157 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5158 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5159 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5162 case `$CC -V 2>&1 | sed 5q` in
5163 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
5164 # Sun Fortran 8.3 passes all unrecognized flags to the linker
5165 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5166 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5167 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
5169 *Sun\ F* | *Sun*Fortran*)
5170 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5171 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5172 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5176 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5177 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5178 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5180 *Intel*\ [[CF]]*Compiler*)
5181 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5182 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5183 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5186 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5187 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5188 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5196 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5197 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5201 # QNX uses GNU C++, but need to define -shared option too, otherwise
5203 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5206 osf3* | osf4* | osf5*)
5207 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5208 # All OSF/1 code is PIC.
5209 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5213 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5217 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5218 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5219 case $cc_basename in
5220 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
5221 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5223 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5228 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5229 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5230 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5233 sysv4 | sysv4.2uw2* | sysv4.3*)
5234 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5235 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5236 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5240 if test -d /usr/nec; then
5241 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5242 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5246 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5247 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5248 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5249 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5253 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5254 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5258 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5259 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5263 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5269 # For platforms that do not support PIC, -DPIC is meaningless:
5271 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5274 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
5278 AC_CACHE_CHECK([for $compiler option to produce PIC],
5279 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
5280 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
5281 _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
5284 # Check to make sure the PIC flag actually works.
5286 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5287 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
5288 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
5289 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
5290 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
5292 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5294 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
5295 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5297 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
5298 [Additional compiler flags for building library objects])
5300 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
5301 [How to pass a linker flag through the compiler])
5303 # Check to make sure the static flag actually works.
5305 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
5306 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
5307 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
5308 $lt_tmp_static_flag,
5310 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
5311 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
5312 [Compiler flag to prevent dynamic linking])
5313 ])# _LT_COMPILER_PIC
5316 # _LT_LINKER_SHLIBS([TAGNAME])
5317 # ----------------------------
5318 # See if the linker supports building shared libraries.
5319 m4_defun([_LT_LINKER_SHLIBS],
5320 [AC_REQUIRE([LT_PATH_LD])dnl
5321 AC_REQUIRE([LT_PATH_NM])dnl
5322 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5323 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5324 m4_require([_LT_DECL_EGREP])dnl
5325 m4_require([_LT_DECL_SED])dnl
5326 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
5327 m4_require([_LT_TAG_COMPILER])dnl
5328 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5329 m4_if([$1], [CXX], [
5330 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5331 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5334 # If we're using GNU nm, then we don't want the "-C" option.
5335 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
5336 # Without the "-l" option, or with the "-B" option, AIX nm treats
5337 # weak defined symbols like other global defined symbols, whereas
5338 # GNU nm marks them as "W".
5339 # While the 'weak' keyword is ignored in the Export File, we need
5340 # it in the Import File for the 'aix-soname' feature, so we have
5341 # to replace the "-B" option with "-P" for AIX nm.
5342 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5343 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
5345 _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
5349 _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds
5351 cygwin* | mingw* | cegcc*)
5352 case $cc_basename in
5354 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5357 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
5358 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5362 linux* | k*bsd*-gnu | gnu*)
5363 _LT_TAGVAR(link_all_deplibs, $1)=no
5366 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5371 _LT_TAGVAR(allow_undefined_flag, $1)=
5372 _LT_TAGVAR(always_export_symbols, $1)=no
5373 _LT_TAGVAR(archive_cmds, $1)=
5374 _LT_TAGVAR(archive_expsym_cmds, $1)=
5375 _LT_TAGVAR(compiler_needs_object, $1)=no
5376 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5377 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5378 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5379 _LT_TAGVAR(hardcode_automatic, $1)=no
5380 _LT_TAGVAR(hardcode_direct, $1)=no
5381 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5382 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5383 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5384 _LT_TAGVAR(hardcode_minus_L, $1)=no
5385 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5386 _LT_TAGVAR(inherit_rpath, $1)=no
5387 _LT_TAGVAR(link_all_deplibs, $1)=unknown
5388 _LT_TAGVAR(module_cmds, $1)=
5389 _LT_TAGVAR(module_expsym_cmds, $1)=
5390 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
5391 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5392 _LT_TAGVAR(thread_safe_flag_spec, $1)=
5393 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5394 # include_expsyms should be a list of space-separated symbols to be *always*
5395 # included in the symbol list
5396 _LT_TAGVAR(include_expsyms, $1)=
5397 # exclude_expsyms can be an extended regexp of symbols to exclude
5398 # it will be wrapped by ' (' and ')$', so one must not match beginning or
5399 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
5400 # as well as any symbol that contains 'd'.
5401 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5402 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5403 # platforms (ab)use it in PIC code, but their linkers get confused if
5404 # the symbol is explicitly referenced. Since portable code cannot
5405 # rely on this symbol name, it's probably fine to never include it in
5406 # preloaded symbol tables.
5407 # Exclude shared library initialization/finalization symbols.
5408 dnl Note also adjust exclude_expsyms for C++ above.
5409 extract_expsyms_cmds=
5412 cygwin* | mingw* | pw32* | cegcc*)
5413 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5414 # When not using gcc, we currently assume that we are using
5415 # Microsoft Visual C++.
5416 if test yes != "$GCC"; then
5421 # we just hope/assume this is gcc and not c89 (= MSVC++)
5427 linux* | k*bsd*-gnu | gnu*)
5428 _LT_TAGVAR(link_all_deplibs, $1)=no
5432 _LT_TAGVAR(ld_shlibs, $1)=yes
5434 # On some targets, GNU ld is compatible enough with the native linker
5435 # that we're better off using the native interface for both.
5436 lt_use_gnu_ld_interface=no
5437 if test yes = "$with_gnu_ld"; then
5440 # The AIX port of GNU ld has always aspired to compatibility
5441 # with the native linker. However, as the warning in the GNU ld
5442 # block says, versions before 2.19.5* couldn't really create working
5443 # shared libraries, regardless of the interface used.
5444 case `$LD -v 2>&1` in
5445 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
5446 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
5447 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
5449 lt_use_gnu_ld_interface=yes
5454 lt_use_gnu_ld_interface=yes
5459 if test yes = "$lt_use_gnu_ld_interface"; then
5460 # If archive_cmds runs LD, not CC, wlarc should be empty
5463 # Set some defaults for GNU ld with shared library support. These
5464 # are reset later if shared libraries are not supported. Putting them
5465 # here allows them to be overridden if necessary.
5466 runpath_var=LD_RUN_PATH
5467 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5468 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
5469 # ancient GNU ld didn't support --whole-archive et. al.
5470 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
5471 _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
5473 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5475 supports_anon_versioning=no
5476 case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in
5477 *GNU\ gold*) supports_anon_versioning=yes ;;
5478 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5479 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5480 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5481 *\ 2.11.*) ;; # other 2.11 versions
5482 *) supports_anon_versioning=yes ;;
5485 # See if GNU ld supports shared libraries.
5488 # On AIX/PPC, the GNU linker is very broken
5489 if test ia64 != "$host_cpu"; then
5490 _LT_TAGVAR(ld_shlibs, $1)=no
5493 *** Warning: the GNU linker, at least up to release 2.19, is reported
5494 *** to be unable to reliably create shared libraries on AIX.
5495 *** Therefore, libtool is disabling shared libraries support. If you
5496 *** really care for shared libraries, you may want to install binutils
5497 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
5498 *** You will then need to restart the configuration process.
5507 # see comment about AmigaOS4 .so support
5508 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5509 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5512 _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)'
5513 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5514 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5520 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5521 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5522 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5523 # support --undefined. This deserves some investigation. FIXME
5524 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5526 _LT_TAGVAR(ld_shlibs, $1)=no
5530 cygwin* | mingw* | pw32* | cegcc*)
5531 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5532 # as there is no search path for DLLs.
5533 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5534 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
5535 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5536 _LT_TAGVAR(always_export_symbols, $1)=no
5537 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5538 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
5539 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5541 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5542 _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'
5543 # If the export-symbols file already is a .def file, use it as
5544 # is; otherwise, prepend EXPORTS...
5545 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
5546 cp $export_symbols $output_objdir/$soname.def;
5548 echo EXPORTS > $output_objdir/$soname.def;
5549 cat $export_symbols >> $output_objdir/$soname.def;
5551 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5553 _LT_TAGVAR(ld_shlibs, $1)=no
5558 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5559 _LT_TAGVAR(link_all_deplibs, $1)=yes
5563 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5564 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5565 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5567 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5568 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5569 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5570 $ECHO EXPORTS >> $output_objdir/$libname.def~
5571 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
5572 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5573 emximp -o $lib $output_objdir/$libname.def'
5574 _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5575 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5576 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5577 $ECHO EXPORTS >> $output_objdir/$libname.def~
5579 if test EXPORTS = "`$SED 1q $export_symbols`"; then
5580 prefix_cmds="$prefix_cmds -e 1d";
5582 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
5583 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
5584 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5585 emximp -o $lib $output_objdir/$libname.def'
5586 _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
5587 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5591 _LT_TAGVAR(hardcode_direct, $1)=no
5592 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5593 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
5594 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
5595 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5596 # Instead, shared libraries are loaded at an image base (0x10000000 by
5597 # default) and relocated if they conflict, which is a slow very memory
5598 # consuming and fragmenting process. To avoid this, we pick a random,
5599 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
5600 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
5601 _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'
5602 _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'
5605 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
5607 if test linux-dietlibc = "$host_os"; then
5608 case $cc_basename in
5609 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
5612 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
5613 && test no = "$tmp_diet"
5615 tmp_addflag=' $pic_flag'
5616 tmp_sharedflag='-shared'
5617 case $cc_basename,$host_cpu in
5618 pgcc*) # Portland Group C compiler
5619 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
5620 tmp_addflag=' $pic_flag'
5622 pgf77* | pgf90* | pgf95* | pgfortran*)
5623 # Portland Group f77 and f90 compilers
5624 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
5625 tmp_addflag=' $pic_flag -Mnomain' ;;
5626 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5627 tmp_addflag=' -i_dynamic' ;;
5628 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5629 tmp_addflag=' -i_dynamic -nofor_main' ;;
5630 ifc* | ifort*) # Intel Fortran compiler
5631 tmp_addflag=' -nofor_main' ;;
5632 lf95*) # Lahey Fortran 8.1
5633 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5634 tmp_sharedflag='--shared' ;;
5635 nagfor*) # NAGFOR 5.3
5636 tmp_sharedflag='-Wl,-shared' ;;
5637 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
5638 tmp_sharedflag='-qmkshrobj'
5640 nvcc*) # Cuda Compiler Driver 2.2
5641 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
5642 _LT_TAGVAR(compiler_needs_object, $1)=yes
5645 case `$CC -V 2>&1 | sed 5q` in
5646 *Sun\ C*) # Sun C 5.9
5647 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
5648 _LT_TAGVAR(compiler_needs_object, $1)=yes
5649 tmp_sharedflag='-G' ;;
5650 *Sun\ F*) # Sun Fortran 8.3
5651 tmp_sharedflag='-G' ;;
5653 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5655 if test yes = "$supports_anon_versioning"; then
5656 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5657 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5658 echo "local: *; };" >> $output_objdir/$libname.ver~
5659 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
5662 case $cc_basename in
5664 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic'
5666 xlf* | bgf* | bgxlf* | mpixlf*)
5667 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
5668 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
5669 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5670 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
5671 if test yes = "$supports_anon_versioning"; then
5672 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5673 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5674 echo "local: *; };" >> $output_objdir/$libname.ver~
5675 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5680 _LT_TAGVAR(ld_shlibs, $1)=no
5684 netbsd* | netbsdelf*-gnu)
5685 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5686 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5689 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5690 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
5695 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
5696 _LT_TAGVAR(ld_shlibs, $1)=no
5699 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5700 *** create shared libraries on Solaris systems. Therefore, libtool
5701 *** is disabling shared libraries support. We urge you to upgrade GNU
5702 *** binutils to release 2.9.1 or newer. Another option is to modify
5703 *** your PATH or compiler configuration so that the native linker is
5704 *** used, and then restart.
5707 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5708 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5709 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
5711 _LT_TAGVAR(ld_shlibs, $1)=no
5715 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5716 case `$LD -v 2>&1` in
5717 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5718 _LT_TAGVAR(ld_shlibs, $1)=no
5721 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
5722 *** reliably create shared libraries on SCO systems. Therefore, libtool
5723 *** is disabling shared libraries support. We urge you to upgrade GNU
5724 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5725 *** your PATH or compiler configuration so that the native linker is
5726 *** used, and then restart.
5731 # For security reasons, it is highly recommended that you always
5732 # use absolute paths for naming shared libraries, and exclude the
5733 # DT_RUNPATH tag from executables and libraries. But doing so
5734 # requires that you compile everything twice, which is a pain.
5735 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5736 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5737 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5738 _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'
5740 _LT_TAGVAR(ld_shlibs, $1)=no
5747 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5749 _LT_TAGVAR(hardcode_direct, $1)=yes
5750 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5754 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5755 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5756 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
5758 _LT_TAGVAR(ld_shlibs, $1)=no
5763 if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then
5765 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5766 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5767 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5770 # PORTME fill in a description of your system's linker (not GNU ld)
5773 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5774 _LT_TAGVAR(always_export_symbols, $1)=yes
5775 _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'
5776 # Note: this linker hardcodes the directories in LIBPATH if there
5777 # are no directories specified by -L.
5778 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5779 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
5780 # Neither direct hardcoding nor static linking is supported with a
5782 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5787 if test ia64 = "$host_cpu"; then
5788 # On IA64, the linker does run time linking by default, so we don't
5789 # have to do anything special.
5790 aix_use_runtimelinking=no
5791 exp_sym_flag='-Bexport'
5794 # If we're using GNU nm, then we don't want the "-C" option.
5795 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
5796 # Without the "-l" option, or with the "-B" option, AIX nm treats
5797 # weak defined symbols like other global defined symbols, whereas
5798 # GNU nm marks them as "W".
5799 # While the 'weak' keyword is ignored in the Export File, we need
5800 # it in the Import File for the 'aix-soname' feature, so we have
5801 # to replace the "-B" option with "-P" for AIX nm.
5802 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5803 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
5805 _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
5807 aix_use_runtimelinking=no
5809 # Test if we are trying to use run time linking or normal
5810 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5811 # have runtime linking enabled, and use it for executables.
5812 # For shared libraries, we enable/disable runtime linking
5813 # depending on the kind of the shared library created -
5814 # when "with_aix_soname,aix_use_runtimelinking" is:
5815 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
5816 # "aix,yes" lib.so shared, rtl:yes, for executables
5817 # lib.a static archive
5818 # "both,no" lib.so.V(shr.o) shared, rtl:yes
5819 # lib.a(lib.so.V) shared, rtl:no, for executables
5820 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
5821 # lib.a(lib.so.V) shared, rtl:no
5822 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
5823 # lib.a static archive
5824 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5825 for ld_flag in $LDFLAGS; do
5826 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
5827 aix_use_runtimelinking=yes
5831 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
5832 # With aix-soname=svr4, we create the lib.so.V shared archives only,
5833 # so we don't have lib.a shared libs to link our executables.
5834 # We have to force runtime linking in this case.
5835 aix_use_runtimelinking=yes
5836 LDFLAGS="$LDFLAGS -Wl,-brtl"
5841 exp_sym_flag='-bexport'
5842 no_entry_flag='-bnoentry'
5845 # When large executables or shared objects are built, AIX ld can
5846 # have problems creating the table of contents. If linking a library
5847 # or program results in "error TOC overflow" add -mminimal-toc to
5848 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5849 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5851 _LT_TAGVAR(archive_cmds, $1)=''
5852 _LT_TAGVAR(hardcode_direct, $1)=yes
5853 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5854 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5855 _LT_TAGVAR(link_all_deplibs, $1)=yes
5856 _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
5857 case $with_aix_soname,$aix_use_runtimelinking in
5858 aix,*) ;; # traditional, no import file
5859 svr4,* | *,yes) # use import file
5860 # The Import File defines what to hardcode.
5861 _LT_TAGVAR(hardcode_direct, $1)=no
5862 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5866 if test yes = "$GCC"; then
5867 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5868 # We only want to do this on AIX 4.2 and lower, the check
5869 # below for broken collect2 doesn't work under 4.3+
5870 collect2name=`$CC -print-prog-name=collect2`
5871 if test -f "$collect2name" &&
5872 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5874 # We have reworked collect2
5877 # We have old collect2
5878 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5879 # It fails to find uninstalled libraries when the uninstalled
5880 # path is not listed in the libpath. Setting hardcode_minus_L
5881 # to unsupported forces relinking
5882 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5883 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5884 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5888 shared_flag='-shared'
5889 if test yes = "$aix_use_runtimelinking"; then
5890 shared_flag="$shared_flag "'$wl-G'
5892 # Need to ensure runtime linking is disabled for the traditional
5893 # shared library, or the linker may eventually find shared libraries
5894 # /with/ Import File - we do not want to mix them.
5895 shared_flag_aix='-shared'
5896 shared_flag_svr4='-shared $wl-G'
5899 if test ia64 = "$host_cpu"; then
5900 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5901 # chokes on -Wl,-G. The following line is correct:
5904 if test yes = "$aix_use_runtimelinking"; then
5907 shared_flag='$wl-bM:SRE'
5909 shared_flag_aix='$wl-bM:SRE'
5910 shared_flag_svr4='$wl-G'
5914 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
5915 # It seems that -bexpall does not export symbols beginning with
5916 # underscore (_), so it is better to generate a list of symbols to export.
5917 _LT_TAGVAR(always_export_symbols, $1)=yes
5918 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
5919 # Warning - without using the other runtime loading flags (-brtl),
5920 # -berok will link without error, but may produce a broken library.
5921 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5922 # Determine the default libpath from the value encoded in an
5924 _LT_SYS_MODULE_PATH_AIX([$1])
5925 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
5926 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
5928 if test ia64 = "$host_cpu"; then
5929 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
5930 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5931 _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"
5933 # Determine the default libpath from the value encoded in an
5935 _LT_SYS_MODULE_PATH_AIX([$1])
5936 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
5937 # Warning - without using the other run time loading flags,
5938 # -berok will link without error, but may produce a broken library.
5939 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
5940 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
5941 if test yes = "$with_gnu_ld"; then
5942 # We only use this code for GNU lds that support --whole-archive.
5943 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
5945 # Exported symbols can be pulled into shared objects from archives
5946 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5948 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5949 _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
5950 # -brtl affects multiple linker settings, -berok does not and is overridden later
5951 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
5952 if test svr4 != "$with_aix_soname"; then
5953 # This is similar to how AIX traditionally builds its shared libraries.
5954 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
5956 if test aix != "$with_aix_soname"; then
5957 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
5959 # used by -dlpreopen to get the symbols
5960 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
5962 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
5970 # see comment about AmigaOS4 .so support
5971 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5972 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5975 _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)'
5976 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5977 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5983 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5986 cygwin* | mingw* | pw32* | cegcc*)
5987 # When not using gcc, we currently assume that we are using
5988 # Microsoft Visual C++.
5989 # hardcode_libdir_flag_spec is actually meaningless, as there is
5990 # no search path for DLLs.
5991 case $cc_basename in
5994 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5995 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5996 _LT_TAGVAR(always_export_symbols, $1)=yes
5997 _LT_TAGVAR(file_list_spec, $1)='@'
5998 # Tell ltmain to make .lib files, not .a files.
6000 # Tell ltmain to make .dll files, not .so files.
6002 # FIXME: Setting linknames here is a bad hack.
6003 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
6004 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
6005 cp "$export_symbols" "$output_objdir/$soname.def";
6006 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
6008 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
6010 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6012 # The linker will not automatically build a static lib if we build a DLL.
6013 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6014 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6015 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
6016 _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'
6018 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6019 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6020 lt_tool_outputfile="@TOOL_OUTPUT@"~
6021 case $lt_outputfile in
6024 lt_outputfile=$lt_outputfile.exe
6025 lt_tool_outputfile=$lt_tool_outputfile.exe
6028 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
6029 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6030 $RM "$lt_outputfile.manifest";
6034 # Assume MSVC wrapper
6035 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6036 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6037 # Tell ltmain to make .lib files, not .a files.
6039 # Tell ltmain to make .dll files, not .so files.
6041 # FIXME: Setting linknames here is a bad hack.
6042 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
6043 # The linker will automatically build a .lib file if we build a DLL.
6044 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6045 # FIXME: Should let the user specify the lib program.
6046 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6047 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6052 darwin* | rhapsody*)
6053 _LT_DARWIN_LINKER_FEATURES($1)
6057 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6058 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6059 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6062 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6063 # support. Future versions do this automatically, but an explicit c++rt0.o
6064 # does not break anything, and helps significantly (at the cost of a little
6067 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6068 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6069 _LT_TAGVAR(hardcode_direct, $1)=yes
6070 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6073 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6075 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6076 _LT_TAGVAR(hardcode_direct, $1)=yes
6077 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6078 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6081 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6082 freebsd* | dragonfly*)
6083 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6084 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6085 _LT_TAGVAR(hardcode_direct, $1)=yes
6086 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6090 if test yes = "$GCC"; then
6091 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
6093 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
6095 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
6096 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6097 _LT_TAGVAR(hardcode_direct, $1)=yes
6099 # hardcode_minus_L: Not really in the search PATH,
6100 # but as the default location of the library.
6101 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6102 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6106 if test yes,no = "$GCC,$with_gnu_ld"; then
6107 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6109 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6111 if test no = "$with_gnu_ld"; then
6112 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
6113 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6114 _LT_TAGVAR(hardcode_direct, $1)=yes
6115 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6116 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6117 # hardcode_minus_L: Not really in the search PATH,
6118 # but as the default location of the library.
6119 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6124 if test yes,no = "$GCC,$with_gnu_ld"; then
6127 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
6130 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6133 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6139 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
6142 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6146 # Older versions of the 11.00 compiler do not understand -b yet
6147 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
6148 _LT_LINKER_OPTION([if $CC understands -b],
6149 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
6150 [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
6151 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
6152 [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
6156 if test no = "$with_gnu_ld"; then
6157 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
6158 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6162 _LT_TAGVAR(hardcode_direct, $1)=no
6163 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6166 _LT_TAGVAR(hardcode_direct, $1)=yes
6167 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6168 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6170 # hardcode_minus_L: Not really in the search PATH,
6171 # but as the default location of the library.
6172 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6178 irix5* | irix6* | nonstopux*)
6179 if test yes = "$GCC"; then
6180 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
6181 # Try to use the -exported_symbol ld option, if it does not
6182 # work, assume that -exports_file does not work either and
6183 # implicitly export all symbols.
6184 # This should be the same for all languages, so no per-tag cache variable.
6185 AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
6186 [lt_cv_irix_exported_symbol],
6187 [save_LDFLAGS=$LDFLAGS
6188 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
6191 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
6192 [C++], [[int foo (void) { return 0; }]],
6199 [lt_cv_irix_exported_symbol=yes],
6200 [lt_cv_irix_exported_symbol=no])
6201 LDFLAGS=$save_LDFLAGS])
6202 if test yes = "$lt_cv_irix_exported_symbol"; then
6203 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
6205 _LT_TAGVAR(link_all_deplibs, $1)=no
6207 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
6208 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
6210 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6211 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6212 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6213 _LT_TAGVAR(inherit_rpath, $1)=yes
6214 _LT_TAGVAR(link_all_deplibs, $1)=yes
6218 case $cc_basename in
6220 # Fabrice Bellard et al's Tiny C Compiler
6221 _LT_TAGVAR(ld_shlibs, $1)=yes
6222 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6227 netbsd* | netbsdelf*-gnu)
6228 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6229 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6231 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6233 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6234 _LT_TAGVAR(hardcode_direct, $1)=yes
6235 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6239 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6240 _LT_TAGVAR(hardcode_direct, $1)=yes
6241 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6242 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6243 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6250 if test -f /usr/libexec/ld.so; then
6251 _LT_TAGVAR(hardcode_direct, $1)=yes
6252 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6253 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6254 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
6255 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6256 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
6257 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6258 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6260 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6261 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6264 _LT_TAGVAR(ld_shlibs, $1)=no
6269 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6270 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6271 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6273 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
6274 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
6275 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
6276 $ECHO EXPORTS >> $output_objdir/$libname.def~
6277 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
6278 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
6279 emximp -o $lib $output_objdir/$libname.def'
6280 _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
6281 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
6282 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
6283 $ECHO EXPORTS >> $output_objdir/$libname.def~
6285 if test EXPORTS = "`$SED 1q $export_symbols`"; then
6286 prefix_cmds="$prefix_cmds -e 1d";
6288 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
6289 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
6290 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
6291 emximp -o $lib $output_objdir/$libname.def'
6292 _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
6293 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6297 if test yes = "$GCC"; then
6298 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
6299 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
6301 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6302 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
6304 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6305 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6306 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6309 osf4* | osf5*) # as osf3* with the addition of -msym flag
6310 if test yes = "$GCC"; then
6311 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
6312 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
6313 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6315 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6316 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
6317 _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~
6318 $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
6320 # Both c and cxx compiler support -rpath directly
6321 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6323 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6324 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6328 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
6329 if test yes = "$GCC"; then
6331 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
6332 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6333 $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6335 case `$CC -V 2>&1` in
6338 _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
6339 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6340 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
6344 _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
6345 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6346 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6350 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6351 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6353 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6355 # The compiler driver will combine and reorder linker options,
6356 # but understands '-z linker_flag'. GCC discards it without '$wl',
6357 # but is careful enough not to reorder.
6358 # Supported since Solaris 2.6 (maybe 2.5.1?)
6359 if test yes = "$GCC"; then
6360 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
6362 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6366 _LT_TAGVAR(link_all_deplibs, $1)=yes
6370 if test sequent = "$host_vendor"; then
6371 # Use $CC to link under sequent, because it throws in some extra .o
6372 # files that make .init and .fini sections work.
6373 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6375 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6377 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6378 _LT_TAGVAR(hardcode_direct, $1)=yes
6379 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6380 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6384 case $host_vendor in
6386 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6387 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6390 ## LD is ld it makes a PLAMLIB
6391 ## CC just makes a GrossModule.
6392 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6393 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6394 _LT_TAGVAR(hardcode_direct, $1)=no
6397 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6398 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6401 runpath_var='LD_RUN_PATH'
6402 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6406 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6407 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6408 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6412 if test -d /usr/nec; then
6413 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6414 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6415 runpath_var=LD_RUN_PATH
6416 hardcode_runpath_var=yes
6417 _LT_TAGVAR(ld_shlibs, $1)=yes
6421 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6422 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
6423 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6424 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6425 runpath_var='LD_RUN_PATH'
6427 if test yes = "$GCC"; then
6428 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6429 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6431 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6432 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6436 sysv5* | sco3.2v5* | sco5v6*)
6437 # Note: We CANNOT use -z defs as we might desire, because we do not
6438 # link with -lc, and that would cause any symbols used from libc to
6439 # always be unresolved, which means just about no library would
6440 # ever link correctly. If we're not using GNU ld we use -z text
6441 # though, which does catch some bad symbols but isn't as heavy-handed
6443 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
6444 _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
6445 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6446 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6447 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
6448 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6449 _LT_TAGVAR(link_all_deplibs, $1)=yes
6450 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
6451 runpath_var='LD_RUN_PATH'
6453 if test yes = "$GCC"; then
6454 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6455 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6457 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6458 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6463 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6464 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6465 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6469 _LT_TAGVAR(ld_shlibs, $1)=no
6473 if test sni = "$host_vendor"; then
6475 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6476 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym'
6482 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6483 test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
6485 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
6487 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
6488 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
6489 _LT_DECL([], [extract_expsyms_cmds], [2],
6490 [The commands to extract the exported symbol list from a shared archive])
6493 # Do we need to explicitly link libc?
6495 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
6497 # Assume -lc should be added
6498 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6500 if test yes,yes = "$GCC,$enable_shared"; then
6501 case $_LT_TAGVAR(archive_cmds, $1) in
6503 # FIXME: we may have to deal with multi-command sequences.
6506 # Test whether the compiler implicitly links with -lc since on some
6507 # systems, -lgcc has to come before -lc. If gcc already passes -lc
6508 # to ld, don't add -lc before -lgcc.
6509 AC_CACHE_CHECK([whether -lc should be explicitly linked in],
6510 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
6512 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6514 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6517 libobjs=conftest.$ac_objext
6519 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
6520 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
6526 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
6527 _LT_TAGVAR(allow_undefined_flag, $1)=
6528 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
6530 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6532 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6534 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6536 cat conftest.err 1>&5
6540 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
6547 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
6548 [Whether or not to add -lc for building shared libraries])
6549 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
6550 [enable_shared_with_static_runtimes], [0],
6551 [Whether or not to disallow shared libs when runtime libs are static])
6552 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
6553 [Compiler flag to allow reflexive dlopens])
6554 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
6555 [Compiler flag to generate shared objects directly from archives])
6556 _LT_TAGDECL([], [compiler_needs_object], [1],
6557 [Whether the compiler copes with passing no objects directly])
6558 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
6559 [Create an old-style archive from a shared archive])
6560 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
6561 [Create a temporary old-style archive to link instead of a shared archive])
6562 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
6563 _LT_TAGDECL([], [archive_expsym_cmds], [2])
6564 _LT_TAGDECL([], [module_cmds], [2],
6565 [Commands used to build a loadable module if different from building
6567 _LT_TAGDECL([], [module_expsym_cmds], [2])
6568 _LT_TAGDECL([], [with_gnu_ld], [1],
6569 [Whether we are building with GNU ld or not])
6570 _LT_TAGDECL([], [allow_undefined_flag], [1],
6571 [Flag that allows shared libraries with undefined symbols to be built])
6572 _LT_TAGDECL([], [no_undefined_flag], [1],
6573 [Flag that enforces no undefined symbols])
6574 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
6575 [Flag to hardcode $libdir into a binary during linking.
6576 This must work even if $libdir does not exist])
6577 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
6578 [Whether we need a single "-rpath" flag with a separated argument])
6579 _LT_TAGDECL([], [hardcode_direct], [0],
6580 [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
6581 DIR into the resulting binary])
6582 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
6583 [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
6584 DIR into the resulting binary and the resulting library dependency is
6585 "absolute", i.e impossible to change by setting $shlibpath_var if the
6586 library is relocated])
6587 _LT_TAGDECL([], [hardcode_minus_L], [0],
6588 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
6589 into the resulting binary])
6590 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
6591 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
6592 into the resulting binary])
6593 _LT_TAGDECL([], [hardcode_automatic], [0],
6594 [Set to "yes" if building a shared library automatically hardcodes DIR
6595 into the library and all subsequent libraries and executables linked
6597 _LT_TAGDECL([], [inherit_rpath], [0],
6598 [Set to yes if linker adds runtime paths of dependent libraries
6599 to runtime path list])
6600 _LT_TAGDECL([], [link_all_deplibs], [0],
6601 [Whether libtool must link a program against all its dependency libraries])
6602 _LT_TAGDECL([], [always_export_symbols], [0],
6603 [Set to "yes" if exported symbols are required])
6604 _LT_TAGDECL([], [export_symbols_cmds], [2],
6605 [The commands to list exported symbols])
6606 _LT_TAGDECL([], [exclude_expsyms], [1],
6607 [Symbols that should not be listed in the preloaded symbols])
6608 _LT_TAGDECL([], [include_expsyms], [1],
6609 [Symbols that must always be exported])
6610 _LT_TAGDECL([], [prelink_cmds], [2],
6611 [Commands necessary for linking programs (against libraries) with templates])
6612 _LT_TAGDECL([], [postlink_cmds], [2],
6613 [Commands necessary for finishing linking programs])
6614 _LT_TAGDECL([], [file_list_spec], [1],
6615 [Specify filename containing input files])
6616 dnl FIXME: Not yet implemented
6617 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
6618 dnl [Compiler flag to generate thread safe objects])
6619 ])# _LT_LINKER_SHLIBS
6622 # _LT_LANG_C_CONFIG([TAG])
6623 # ------------------------
6624 # Ensure that the configuration variables for a C compiler are suitably
6625 # defined. These variables are subsequently used by _LT_CONFIG to write
6626 # the compiler configuration to 'libtool'.
6627 m4_defun([_LT_LANG_C_CONFIG],
6628 [m4_require([_LT_DECL_EGREP])dnl
6632 # Source file extension for C test sources.
6635 # Object file extension for compiled C test sources.
6637 _LT_TAGVAR(objext, $1)=$objext
6639 # Code to be used in simple compile tests
6640 lt_simple_compile_test_code="int some_variable = 0;"
6642 # Code to be used in simple link tests
6643 lt_simple_link_test_code='int main(){return(0);}'
6646 # Save the default compiler, since it gets overwritten when the other
6647 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
6648 compiler_DEFAULT=$CC
6650 # save warnings/boilerplate of simple test code
6651 _LT_COMPILER_BOILERPLATE
6652 _LT_LINKER_BOILERPLATE
6654 if test -n "$compiler"; then
6655 _LT_COMPILER_NO_RTTI($1)
6656 _LT_COMPILER_PIC($1)
6657 _LT_COMPILER_C_O($1)
6658 _LT_COMPILER_FILE_LOCKS($1)
6659 _LT_LINKER_SHLIBS($1)
6660 _LT_SYS_DYNAMIC_LINKER($1)
6661 _LT_LINKER_HARDCODE_LIBPATH($1)
6665 # Report what library types will actually be built
6666 AC_MSG_CHECKING([if libtool supports shared libraries])
6667 AC_MSG_RESULT([$can_build_shared])
6669 AC_MSG_CHECKING([whether to build shared libraries])
6670 test no = "$can_build_shared" && enable_shared=no
6672 # On AIX, shared libraries and static libraries use the same namespace, and
6673 # are all built from PIC.
6676 test yes = "$enable_shared" && enable_static=no
6677 if test -n "$RANLIB"; then
6678 archive_cmds="$archive_cmds~\$RANLIB \$lib"
6679 postinstall_cmds='$RANLIB $lib'
6684 if test ia64 != "$host_cpu"; then
6685 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
6686 yes,aix,yes) ;; # shared object as lib.so file only
6687 yes,svr4,*) ;; # shared object as lib.so archive member only
6688 yes,*) enable_static=no ;; # shared object in lib.a archive as well
6693 AC_MSG_RESULT([$enable_shared])
6695 AC_MSG_CHECKING([whether to build static libraries])
6696 # Make sure either enable_shared or enable_static is yes.
6697 test yes = "$enable_shared" || enable_static=yes
6698 AC_MSG_RESULT([$enable_static])
6704 ])# _LT_LANG_C_CONFIG
6707 # _LT_LANG_CXX_CONFIG([TAG])
6708 # --------------------------
6709 # Ensure that the configuration variables for a C++ compiler are suitably
6710 # defined. These variables are subsequently used by _LT_CONFIG to write
6711 # the compiler configuration to 'libtool'.
6712 m4_defun([_LT_LANG_CXX_CONFIG],
6713 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6714 m4_require([_LT_DECL_EGREP])dnl
6715 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
6716 if test -n "$CXX" && ( test no != "$CXX" &&
6717 ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) ||
6718 (test g++ != "$CXX"))); then
6721 _lt_caught_CXX_error=yes
6725 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6726 _LT_TAGVAR(allow_undefined_flag, $1)=
6727 _LT_TAGVAR(always_export_symbols, $1)=no
6728 _LT_TAGVAR(archive_expsym_cmds, $1)=
6729 _LT_TAGVAR(compiler_needs_object, $1)=no
6730 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
6731 _LT_TAGVAR(hardcode_direct, $1)=no
6732 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6733 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6734 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6735 _LT_TAGVAR(hardcode_minus_L, $1)=no
6736 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6737 _LT_TAGVAR(hardcode_automatic, $1)=no
6738 _LT_TAGVAR(inherit_rpath, $1)=no
6739 _LT_TAGVAR(module_cmds, $1)=
6740 _LT_TAGVAR(module_expsym_cmds, $1)=
6741 _LT_TAGVAR(link_all_deplibs, $1)=unknown
6742 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
6743 _LT_TAGVAR(reload_flag, $1)=$reload_flag
6744 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6745 _LT_TAGVAR(no_undefined_flag, $1)=
6746 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6747 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6749 # Source file extension for C++ test sources.
6752 # Object file extension for compiled C++ test sources.
6754 _LT_TAGVAR(objext, $1)=$objext
6756 # No sense in running all these tests if we already determined that
6757 # the CXX compiler isn't working. Some variables (like enable_shared)
6758 # are currently assumed to apply to all compilers on this platform,
6759 # and will be corrupted by setting them based on a non-working compiler.
6760 if test yes != "$_lt_caught_CXX_error"; then
6761 # Code to be used in simple compile tests
6762 lt_simple_compile_test_code="int some_variable = 0;"
6764 # Code to be used in simple link tests
6765 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
6767 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
6770 # save warnings/boilerplate of simple test code
6771 _LT_COMPILER_BOILERPLATE
6772 _LT_LINKER_BOILERPLATE
6774 # Allow CC to be a program name with arguments.
6776 lt_save_CFLAGS=$CFLAGS
6780 lt_save_with_gnu_ld=$with_gnu_ld
6781 lt_save_path_LD=$lt_cv_path_LD
6782 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
6783 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
6785 $as_unset lt_cv_prog_gnu_ld
6787 if test -n "${lt_cv_path_LDCXX+set}"; then
6788 lt_cv_path_LD=$lt_cv_path_LDCXX
6790 $as_unset lt_cv_path_LD
6792 test -z "${LDCXX+set}" || LD=$LDCXX
6796 _LT_TAGVAR(compiler, $1)=$CC
6797 _LT_CC_BASENAME([$compiler])
6799 if test -n "$compiler"; then
6800 # We don't want -fno-exception when compiling C++ code, so set the
6801 # no_builtin_flag separately
6802 if test yes = "$GXX"; then
6803 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
6805 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
6808 if test yes = "$GXX"; then
6809 # Set up default GNU C++ configuration
6813 # Check if GNU C++ uses GNU ld as the underlying linker, since the
6814 # archiving commands below assume that GNU ld is being used.
6815 if test yes = "$with_gnu_ld"; then
6816 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6817 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
6819 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6820 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6822 # If archive_cmds runs LD, not CC, wlarc should be empty
6823 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
6824 # investigate it a little bit more. (MM)
6827 # ancient GNU ld didn't support --whole-archive et. al.
6828 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
6829 $GREP 'no-whole-archive' > /dev/null; then
6830 _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
6832 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6838 # A generic and very simple default shared library creation
6839 # command for GNU C++ for the case where it uses the native
6840 # linker, instead of GNU ld. If possible, this setting should
6841 # overridden to take advantage of the native linker features on
6842 # the platform it is being used on.
6843 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6846 # Commands to make compiler produce verbose output that lists
6847 # what "hidden" libraries, object files and flags are used when
6848 # linking a shared library.
6849 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6857 # PORTME: fill in a description of your system's C++ link characteristics
6858 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6859 _LT_TAGVAR(ld_shlibs, $1)=yes
6862 # FIXME: insert proper C++ library support
6863 _LT_TAGVAR(ld_shlibs, $1)=no
6866 if test ia64 = "$host_cpu"; then
6867 # On IA64, the linker does run time linking by default, so we don't
6868 # have to do anything special.
6869 aix_use_runtimelinking=no
6870 exp_sym_flag='-Bexport'
6873 aix_use_runtimelinking=no
6875 # Test if we are trying to use run time linking or normal
6876 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6877 # have runtime linking enabled, and use it for executables.
6878 # For shared libraries, we enable/disable runtime linking
6879 # depending on the kind of the shared library created -
6880 # when "with_aix_soname,aix_use_runtimelinking" is:
6881 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
6882 # "aix,yes" lib.so shared, rtl:yes, for executables
6883 # lib.a static archive
6884 # "both,no" lib.so.V(shr.o) shared, rtl:yes
6885 # lib.a(lib.so.V) shared, rtl:no, for executables
6886 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
6887 # lib.a(lib.so.V) shared, rtl:no
6888 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
6889 # lib.a static archive
6890 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6891 for ld_flag in $LDFLAGS; do
6894 aix_use_runtimelinking=yes
6899 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
6900 # With aix-soname=svr4, we create the lib.so.V shared archives only,
6901 # so we don't have lib.a shared libs to link our executables.
6902 # We have to force runtime linking in this case.
6903 aix_use_runtimelinking=yes
6904 LDFLAGS="$LDFLAGS -Wl,-brtl"
6909 exp_sym_flag='-bexport'
6910 no_entry_flag='-bnoentry'
6913 # When large executables or shared objects are built, AIX ld can
6914 # have problems creating the table of contents. If linking a library
6915 # or program results in "error TOC overflow" add -mminimal-toc to
6916 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6917 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6919 _LT_TAGVAR(archive_cmds, $1)=''
6920 _LT_TAGVAR(hardcode_direct, $1)=yes
6921 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6922 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6923 _LT_TAGVAR(link_all_deplibs, $1)=yes
6924 _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
6925 case $with_aix_soname,$aix_use_runtimelinking in
6926 aix,*) ;; # no import file
6927 svr4,* | *,yes) # use import file
6928 # The Import File defines what to hardcode.
6929 _LT_TAGVAR(hardcode_direct, $1)=no
6930 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6934 if test yes = "$GXX"; then
6935 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6936 # We only want to do this on AIX 4.2 and lower, the check
6937 # below for broken collect2 doesn't work under 4.3+
6938 collect2name=`$CC -print-prog-name=collect2`
6939 if test -f "$collect2name" &&
6940 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6942 # We have reworked collect2
6945 # We have old collect2
6946 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6947 # It fails to find uninstalled libraries when the uninstalled
6948 # path is not listed in the libpath. Setting hardcode_minus_L
6949 # to unsupported forces relinking
6950 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6951 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6952 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6955 shared_flag='-shared'
6956 if test yes = "$aix_use_runtimelinking"; then
6957 shared_flag=$shared_flag' $wl-G'
6959 # Need to ensure runtime linking is disabled for the traditional
6960 # shared library, or the linker may eventually find shared libraries
6961 # /with/ Import File - we do not want to mix them.
6962 shared_flag_aix='-shared'
6963 shared_flag_svr4='-shared $wl-G'
6966 if test ia64 = "$host_cpu"; then
6967 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6968 # chokes on -Wl,-G. The following line is correct:
6971 if test yes = "$aix_use_runtimelinking"; then
6974 shared_flag='$wl-bM:SRE'
6976 shared_flag_aix='$wl-bM:SRE'
6977 shared_flag_svr4='$wl-G'
6981 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
6982 # It seems that -bexpall does not export symbols beginning with
6983 # underscore (_), so it is better to generate a list of symbols to
6985 _LT_TAGVAR(always_export_symbols, $1)=yes
6986 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
6987 # Warning - without using the other runtime loading flags (-brtl),
6988 # -berok will link without error, but may produce a broken library.
6989 # The "-G" linker flag allows undefined symbols.
6990 _LT_TAGVAR(no_undefined_flag, $1)='-bernotok'
6991 # Determine the default libpath from the value encoded in an empty
6993 _LT_SYS_MODULE_PATH_AIX([$1])
6994 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
6996 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
6998 if test ia64 = "$host_cpu"; then
6999 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
7000 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7001 _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"
7003 # Determine the default libpath from the value encoded in an
7005 _LT_SYS_MODULE_PATH_AIX([$1])
7006 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
7007 # Warning - without using the other run time loading flags,
7008 # -berok will link without error, but may produce a broken library.
7009 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
7010 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
7011 if test yes = "$with_gnu_ld"; then
7012 # We only use this code for GNU lds that support --whole-archive.
7013 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
7015 # Exported symbols can be pulled into shared objects from archives
7016 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
7018 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
7019 _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
7020 # -brtl affects multiple linker settings, -berok does not and is overridden later
7021 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
7022 if test svr4 != "$with_aix_soname"; then
7023 # This is similar to how AIX traditionally builds its shared
7024 # libraries. Need -bnortl late, we may have -brtl in LDFLAGS.
7025 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
7027 if test aix != "$with_aix_soname"; then
7028 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
7030 # used by -dlpreopen to get the symbols
7031 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
7033 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
7039 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7040 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7041 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
7042 # support --undefined. This deserves some investigation. FIXME
7043 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
7045 _LT_TAGVAR(ld_shlibs, $1)=no
7050 case $cc_basename in
7052 # FIXME: insert proper C++ library support
7053 _LT_TAGVAR(ld_shlibs, $1)=no
7058 cygwin* | mingw* | pw32* | cegcc*)
7059 case $GXX,$cc_basename in
7062 # hardcode_libdir_flag_spec is actually meaningless, as there is
7063 # no search path for DLLs.
7064 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
7065 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7066 _LT_TAGVAR(always_export_symbols, $1)=yes
7067 _LT_TAGVAR(file_list_spec, $1)='@'
7068 # Tell ltmain to make .lib files, not .a files.
7070 # Tell ltmain to make .dll files, not .so files.
7072 # FIXME: Setting linknames here is a bad hack.
7073 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
7074 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
7075 cp "$export_symbols" "$output_objdir/$soname.def";
7076 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
7078 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
7080 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
7082 # The linker will not automatically build a static lib if we build a DLL.
7083 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
7084 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7086 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
7087 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
7088 lt_tool_outputfile="@TOOL_OUTPUT@"~
7089 case $lt_outputfile in
7092 lt_outputfile=$lt_outputfile.exe
7093 lt_tool_outputfile=$lt_tool_outputfile.exe
7096 func_to_tool_file "$lt_outputfile"~
7097 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
7098 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
7099 $RM "$lt_outputfile.manifest";
7104 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
7105 # as there is no search path for DLLs.
7106 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7107 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
7108 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7109 _LT_TAGVAR(always_export_symbols, $1)=no
7110 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7112 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7113 _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'
7114 # If the export-symbols file already is a .def file, use it as
7115 # is; otherwise, prepend EXPORTS...
7116 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
7117 cp $export_symbols $output_objdir/$soname.def;
7119 echo EXPORTS > $output_objdir/$soname.def;
7120 cat $export_symbols >> $output_objdir/$soname.def;
7122 $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'
7124 _LT_TAGVAR(ld_shlibs, $1)=no
7129 darwin* | rhapsody*)
7130 _LT_DARWIN_LINKER_FEATURES($1)
7134 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7135 _LT_TAGVAR(hardcode_minus_L, $1)=yes
7136 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7138 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
7139 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
7140 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
7141 $ECHO EXPORTS >> $output_objdir/$libname.def~
7142 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
7143 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
7144 emximp -o $lib $output_objdir/$libname.def'
7145 _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
7146 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
7147 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
7148 $ECHO EXPORTS >> $output_objdir/$libname.def~
7150 if test EXPORTS = "`$SED 1q $export_symbols`"; then
7151 prefix_cmds="$prefix_cmds -e 1d";
7153 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
7154 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
7155 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
7156 emximp -o $lib $output_objdir/$libname.def'
7157 _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
7158 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7162 case $cc_basename in
7164 # FIXME: insert proper C++ library support
7165 _LT_TAGVAR(ld_shlibs, $1)=no
7168 # Green Hills C++ Compiler
7169 # FIXME: insert proper C++ library support
7170 _LT_TAGVAR(ld_shlibs, $1)=no
7173 # FIXME: insert proper C++ library support
7174 _LT_TAGVAR(ld_shlibs, $1)=no
7180 # C++ shared libraries reported to be fairly broken before
7182 _LT_TAGVAR(ld_shlibs, $1)=no
7186 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7189 freebsd* | dragonfly*)
7190 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
7192 _LT_TAGVAR(ld_shlibs, $1)=yes
7196 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
7197 _LT_TAGVAR(link_all_deplibs, $1)=yes
7201 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
7202 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7203 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
7204 _LT_TAGVAR(hardcode_direct, $1)=yes
7205 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7206 # but as the default
7207 # location of the library.
7209 case $cc_basename in
7211 # FIXME: insert proper C++ library support
7212 _LT_TAGVAR(ld_shlibs, $1)=no
7215 _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 "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
7216 # Commands to make compiler produce verbose output that lists
7217 # what "hidden" libraries, object files and flags are used when
7218 # linking a shared library.
7220 # There doesn't appear to be a way to prevent this compiler from
7221 # explicitly linking system object files so we need to strip them
7222 # from the output so that they don't get included in the library
7224 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
7227 if test yes = "$GXX"; then
7228 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
7230 # FIXME: insert proper C++ library support
7231 _LT_TAGVAR(ld_shlibs, $1)=no
7238 if test no = "$with_gnu_ld"; then
7239 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
7240 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7246 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
7252 _LT_TAGVAR(hardcode_direct, $1)=no
7253 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7256 _LT_TAGVAR(hardcode_direct, $1)=yes
7257 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7258 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7259 # but as the default
7260 # location of the library.
7264 case $cc_basename in
7266 # FIXME: insert proper C++ library support
7267 _LT_TAGVAR(ld_shlibs, $1)=no
7272 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7275 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7278 _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'
7281 # Commands to make compiler produce verbose output that lists
7282 # what "hidden" libraries, object files and flags are used when
7283 # linking a shared library.
7285 # There doesn't appear to be a way to prevent this compiler from
7286 # explicitly linking system object files so we need to strip them
7287 # from the output so that they don't get included in the library
7289 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
7292 if test yes = "$GXX"; then
7293 if test no = "$with_gnu_ld"; then
7296 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7299 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7302 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7307 # FIXME: insert proper C++ library support
7308 _LT_TAGVAR(ld_shlibs, $1)=no
7315 _LT_TAGVAR(hardcode_direct, $1)=no
7316 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7317 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7318 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
7319 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
7320 # Instead, shared libraries are loaded at an image base (0x10000000 by
7321 # default) and relocated if they conflict, which is a slow very memory
7322 # consuming and fragmenting process. To avoid this, we pick a random,
7323 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
7324 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
7325 _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'
7326 _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'
7329 case $cc_basename in
7332 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
7334 # Archives containing C++ object files must be created using
7335 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
7336 # necessary to make sure instantiated templates are included
7338 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
7341 if test yes = "$GXX"; then
7342 if test no = "$with_gnu_ld"; then
7343 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
7345 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib'
7348 _LT_TAGVAR(link_all_deplibs, $1)=yes
7351 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7352 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7353 _LT_TAGVAR(inherit_rpath, $1)=yes
7356 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
7357 case $cc_basename in
7359 # Kuck and Associates, Inc. (KAI) C++ Compiler
7361 # KCC will only create a shared library if the output file
7362 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7363 # to its proper name (with version) after linking.
7364 _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'
7365 _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'
7366 # Commands to make compiler produce verbose output that lists
7367 # what "hidden" libraries, object files and flags are used when
7368 # linking a shared library.
7370 # There doesn't appear to be a way to prevent this compiler from
7371 # explicitly linking system object files so we need to strip them
7372 # from the output so that they don't get included in the library
7374 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
7376 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7377 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
7379 # Archives containing C++ object files must be created using
7380 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
7381 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
7386 # version 8.0 and above of icpc choke on multiply defined symbols
7387 # if we add $predep_objects and $postdep_objects, however 7.1 and
7388 # earlier do not add the objects themselves.
7389 case `$CC -V 2>&1` in
7391 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
7392 _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'
7394 *) # Version 8.0 or newer
7397 ia64*) tmp_idyn=' -i_dynamic';;
7399 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
7400 _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'
7403 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7404 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7405 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
7406 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
7409 # Portland Group C++ compiler
7411 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
7412 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
7414 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
7415 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
7416 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
7418 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
7419 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
7421 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
7423 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7424 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
7425 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
7427 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7428 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
7430 *) # Version 6 and above use weak symbols
7431 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
7432 _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'
7436 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir'
7437 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
7438 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
7442 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
7443 _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'
7445 runpath_var=LD_RUN_PATH
7446 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7447 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7449 # Commands to make compiler produce verbose output that lists
7450 # what "hidden" libraries, object files and flags are used when
7451 # linking a shared library.
7453 # There doesn't appear to be a way to prevent this compiler from
7454 # explicitly linking system object files so we need to strip them
7455 # from the output so that they don't get included in the library
7457 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
7459 xl* | mpixl* | bgxl*)
7460 # IBM XL 8.0 on PPC, with GNU ld
7461 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7462 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
7463 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
7464 if test yes = "$supports_anon_versioning"; then
7465 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7466 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7467 echo "local: *; };" >> $output_objdir/$libname.ver~
7468 $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
7472 case `$CC -V 2>&1 | sed 5q` in
7475 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7476 _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7477 _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'
7478 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7479 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
7480 _LT_TAGVAR(compiler_needs_object, $1)=yes
7482 # Not sure whether something based on
7483 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
7485 output_verbose_link_cmd='func_echo_all'
7487 # Archives containing C++ object files must be created using
7488 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7489 # necessary to make sure instantiated templates are included
7491 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7499 # FIXME: insert proper C++ library support
7500 _LT_TAGVAR(ld_shlibs, $1)=no
7504 # FIXME: insert proper C++ library support
7505 _LT_TAGVAR(ld_shlibs, $1)=no
7509 case $cc_basename in
7511 # FIXME: insert proper C++ library support
7512 _LT_TAGVAR(ld_shlibs, $1)=no
7515 # FIXME: insert proper C++ library support
7516 _LT_TAGVAR(ld_shlibs, $1)=no
7522 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7523 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
7525 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7526 _LT_TAGVAR(hardcode_direct, $1)=yes
7527 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7529 # Workaround some broken pre-1.5 toolchains
7530 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
7534 _LT_TAGVAR(ld_shlibs, $1)=yes
7538 if test -f /usr/libexec/ld.so; then
7539 _LT_TAGVAR(hardcode_direct, $1)=yes
7540 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7541 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7542 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7543 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7544 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then
7545 _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'
7546 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
7547 _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
7549 output_verbose_link_cmd=func_echo_all
7551 _LT_TAGVAR(ld_shlibs, $1)=no
7555 osf3* | osf4* | osf5*)
7556 case $cc_basename in
7558 # Kuck and Associates, Inc. (KAI) C++ Compiler
7560 # KCC will only create a shared library if the output file
7561 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7562 # to its proper name (with version) after linking.
7563 _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'
7565 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7566 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7568 # Archives containing C++ object files must be created using
7569 # the KAI C++ compiler.
7571 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
7572 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
7576 # Rational C++ 2.4.1
7577 # FIXME: insert proper C++ library support
7578 _LT_TAGVAR(ld_shlibs, $1)=no
7583 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
7584 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
7585 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7588 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7589 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
7590 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
7591 echo "-hidden">> $lib.exp~
7592 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~
7594 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7598 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7600 # Commands to make compiler produce verbose output that lists
7601 # what "hidden" libraries, object files and flags are used when
7602 # linking a shared library.
7604 # There doesn't appear to be a way to prevent this compiler from
7605 # explicitly linking system object files so we need to strip them
7606 # from the output so that they don't get included in the library
7608 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
7611 if test yes,no = "$GXX,$with_gnu_ld"; then
7612 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
7615 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
7618 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
7622 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7623 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7625 # Commands to make compiler produce verbose output that lists
7626 # what "hidden" libraries, object files and flags are used when
7627 # linking a shared library.
7628 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7631 # FIXME: insert proper C++ library support
7632 _LT_TAGVAR(ld_shlibs, $1)=no
7639 # FIXME: insert proper C++ library support
7640 _LT_TAGVAR(ld_shlibs, $1)=no
7644 case $cc_basename in
7647 # FIXME: insert proper C++ library support
7648 _LT_TAGVAR(ld_shlibs, $1)=no
7652 # FIXME: insert proper C++ library support
7653 _LT_TAGVAR(ld_shlibs, $1)=no
7656 # FIXME: insert proper C++ library support
7657 _LT_TAGVAR(ld_shlibs, $1)=no
7663 case $cc_basename in
7665 # Sun C++ 4.2, 5.x and Centerline C++
7666 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
7667 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7668 _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7669 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7670 $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'
7672 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7673 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7675 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7677 # The compiler driver will combine and reorder linker options,
7678 # but understands '-z linker_flag'.
7679 # Supported since Solaris 2.6 (maybe 2.5.1?)
7680 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7683 _LT_TAGVAR(link_all_deplibs, $1)=yes
7685 output_verbose_link_cmd='func_echo_all'
7687 # Archives containing C++ object files must be created using
7688 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7689 # necessary to make sure instantiated templates are included
7691 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7694 # Green Hills C++ Compiler
7695 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
7697 # The C++ compiler must be used to create the archive.
7698 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
7701 # GNU C++ compiler with Solaris linker
7702 if test yes,no = "$GXX,$with_gnu_ld"; then
7703 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs'
7704 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
7705 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
7706 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7707 $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7709 # Commands to make compiler produce verbose output that lists
7710 # what "hidden" libraries, object files and flags are used when
7711 # linking a shared library.
7712 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7714 # g++ 2.7 appears to require '-G' NOT '-shared' on this
7716 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
7717 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7718 $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7720 # Commands to make compiler produce verbose output that lists
7721 # what "hidden" libraries, object files and flags are used when
7722 # linking a shared library.
7723 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7726 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir'
7728 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7730 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
7738 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7739 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
7740 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7741 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7742 runpath_var='LD_RUN_PATH'
7744 case $cc_basename in
7746 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7747 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7750 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7751 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7756 sysv5* | sco3.2v5* | sco5v6*)
7757 # Note: We CANNOT use -z defs as we might desire, because we do not
7758 # link with -lc, and that would cause any symbols used from libc to
7759 # always be unresolved, which means just about no library would
7760 # ever link correctly. If we're not using GNU ld we use -z text
7761 # though, which does catch some bad symbols but isn't as heavy-handed
7763 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
7764 _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
7765 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7766 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7767 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
7768 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7769 _LT_TAGVAR(link_all_deplibs, $1)=yes
7770 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
7771 runpath_var='LD_RUN_PATH'
7773 case $cc_basename in
7775 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7776 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7777 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
7778 '"$_LT_TAGVAR(old_archive_cmds, $1)"
7779 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
7780 '"$_LT_TAGVAR(reload_cmds, $1)"
7783 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7784 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7790 case $cc_basename in
7792 # NonStop-UX NCC 3.20
7793 # FIXME: insert proper C++ library support
7794 _LT_TAGVAR(ld_shlibs, $1)=no
7797 # FIXME: insert proper C++ library support
7798 _LT_TAGVAR(ld_shlibs, $1)=no
7804 # FIXME: insert proper C++ library support
7805 _LT_TAGVAR(ld_shlibs, $1)=no
7809 # FIXME: insert proper C++ library support
7810 _LT_TAGVAR(ld_shlibs, $1)=no
7814 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
7815 test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
7817 _LT_TAGVAR(GCC, $1)=$GXX
7818 _LT_TAGVAR(LD, $1)=$LD
7821 ## There is no encapsulation within the following macros, do not change
7822 ## the running order or otherwise move them around unless you know exactly
7823 ## what you are doing...
7824 _LT_SYS_HIDDEN_LIBDEPS($1)
7825 _LT_COMPILER_PIC($1)
7826 _LT_COMPILER_C_O($1)
7827 _LT_COMPILER_FILE_LOCKS($1)
7828 _LT_LINKER_SHLIBS($1)
7829 _LT_SYS_DYNAMIC_LINKER($1)
7830 _LT_LINKER_HARDCODE_LIBPATH($1)
7833 fi # test -n "$compiler"
7836 CFLAGS=$lt_save_CFLAGS
7840 with_gnu_ld=$lt_save_with_gnu_ld
7841 lt_cv_path_LDCXX=$lt_cv_path_LD
7842 lt_cv_path_LD=$lt_save_path_LD
7843 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
7844 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
7845 fi # test yes != "$_lt_caught_CXX_error"
7848 ])# _LT_LANG_CXX_CONFIG
7851 # _LT_FUNC_STRIPNAME_CNF
7852 # ----------------------
7853 # func_stripname_cnf prefix suffix name
7854 # strip PREFIX and SUFFIX off of NAME.
7855 # PREFIX and SUFFIX must not contain globbing or regex special
7856 # characters, hashes, percent signs, but SUFFIX may contain a leading
7857 # dot (in which case that matches only a dot).
7859 # This function is identical to the (non-XSI) version of func_stripname,
7860 # except this one can be used by m4 code that may be executed by configure,
7861 # rather than the libtool script.
7862 m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
7863 AC_REQUIRE([_LT_DECL_SED])
7864 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
7865 func_stripname_cnf ()
7868 .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;;
7869 *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;;
7871 } # func_stripname_cnf
7872 ])# _LT_FUNC_STRIPNAME_CNF
7875 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
7876 # ---------------------------------
7877 # Figure out "hidden" library dependencies from verbose
7878 # compiler output when linking a shared library.
7879 # Parse the compiler output and extract the necessary
7880 # objects, libraries and library flags.
7881 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
7882 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7883 AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
7884 # Dependencies to place before and after the object being linked:
7885 _LT_TAGVAR(predep_objects, $1)=
7886 _LT_TAGVAR(postdep_objects, $1)=
7887 _LT_TAGVAR(predeps, $1)=
7888 _LT_TAGVAR(postdeps, $1)=
7889 _LT_TAGVAR(compiler_lib_search_path, $1)=
7891 dnl we can't use the lt_simple_compile_test_code here,
7892 dnl because it contains code intended for an executable,
7893 dnl not a library. It's possible we should let each
7894 dnl tag define a new lt_????_link_test_code variable,
7895 dnl but it's only used here...
7896 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
7898 void foo (void) { a = 0; }
7900 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
7904 Foo (void) { a = 0; }
7909 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
7917 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
7925 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
7928 public void bar (void) {
7933 ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
7940 _lt_libdeps_save_CFLAGS=$CFLAGS
7941 case "$CC $CFLAGS " in #(
7942 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
7943 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
7944 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
7947 dnl Parse the compiler output and extract the necessary
7948 dnl objects, libraries and library flags.
7949 if AC_TRY_EVAL(ac_compile); then
7950 # Parse the compiler output and extract the necessary
7951 # objects, libraries and library flags.
7953 # Sentinel used to keep track of whether or not we are before
7954 # the conftest object file.
7955 pre_test_object_deps_done=no
7957 for p in `eval "$output_verbose_link_cmd"`; do
7961 # Some compilers place space between "-{L,R}" and the path.
7963 if test x-L = "$p" ||
7964 test x-R = "$p"; then
7969 # Expand the sysroot to ease extracting the directories later.
7970 if test -z "$prev"; then
7972 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
7973 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
7974 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
7978 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
7980 if test no = "$pre_test_object_deps_done"; then
7983 # Internal compiler library paths should come after those
7984 # provided the user. The postdeps already come after the
7985 # user supplied libs so there is no need to process them.
7986 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7987 _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p
7989 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p"
7992 # The "-l" case would never come before the object being
7993 # linked, so don't bother handling this case.
7996 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7997 _LT_TAGVAR(postdeps, $1)=$prev$p
7999 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p"
8005 *.lto.$objext) ;; # Ignore GCC LTO objects
8007 # This assumes that the test object file only shows up
8008 # once in the compiler output.
8009 if test "$p" = "conftest.$objext"; then
8010 pre_test_object_deps_done=yes
8014 if test no = "$pre_test_object_deps_done"; then
8015 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
8016 _LT_TAGVAR(predep_objects, $1)=$p
8018 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
8021 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
8022 _LT_TAGVAR(postdep_objects, $1)=$p
8024 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
8029 *) ;; # Ignore the rest.
8037 echo "libtool.m4: error: problem compiling $1 test program"
8040 $RM -f confest.$objext
8041 CFLAGS=$_lt_libdeps_save_CFLAGS
8043 # PORTME: override above test on systems where it is broken
8047 # Interix 3.5 installs completely hosed .la files for C++, so rather than
8048 # hack all around it, let's just trust "g++" to DTRT.
8049 _LT_TAGVAR(predep_objects,$1)=
8050 _LT_TAGVAR(postdep_objects,$1)=
8051 _LT_TAGVAR(postdeps,$1)=
8056 case " $_LT_TAGVAR(postdeps, $1) " in
8057 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
8059 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
8060 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
8061 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'`
8063 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
8064 [The directories searched by this compiler when creating a shared library])
8065 _LT_TAGDECL([], [predep_objects], [1],
8066 [Dependencies to place before and after the objects being linked to
8067 create a shared library])
8068 _LT_TAGDECL([], [postdep_objects], [1])
8069 _LT_TAGDECL([], [predeps], [1])
8070 _LT_TAGDECL([], [postdeps], [1])
8071 _LT_TAGDECL([], [compiler_lib_search_path], [1],
8072 [The library search path used internally by the compiler when linking
8074 ])# _LT_SYS_HIDDEN_LIBDEPS
8077 # _LT_LANG_F77_CONFIG([TAG])
8078 # --------------------------
8079 # Ensure that the configuration variables for a Fortran 77 compiler are
8080 # suitably defined. These variables are subsequently used by _LT_CONFIG
8081 # to write the compiler configuration to 'libtool'.
8082 m4_defun([_LT_LANG_F77_CONFIG],
8083 [AC_LANG_PUSH(Fortran 77)
8084 if test -z "$F77" || test no = "$F77"; then
8088 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8089 _LT_TAGVAR(allow_undefined_flag, $1)=
8090 _LT_TAGVAR(always_export_symbols, $1)=no
8091 _LT_TAGVAR(archive_expsym_cmds, $1)=
8092 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8093 _LT_TAGVAR(hardcode_direct, $1)=no
8094 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8095 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8096 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8097 _LT_TAGVAR(hardcode_minus_L, $1)=no
8098 _LT_TAGVAR(hardcode_automatic, $1)=no
8099 _LT_TAGVAR(inherit_rpath, $1)=no
8100 _LT_TAGVAR(module_cmds, $1)=
8101 _LT_TAGVAR(module_expsym_cmds, $1)=
8102 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8103 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8104 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8105 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8106 _LT_TAGVAR(no_undefined_flag, $1)=
8107 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8108 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8110 # Source file extension for f77 test sources.
8113 # Object file extension for compiled f77 test sources.
8115 _LT_TAGVAR(objext, $1)=$objext
8117 # No sense in running all these tests if we already determined that
8118 # the F77 compiler isn't working. Some variables (like enable_shared)
8119 # are currently assumed to apply to all compilers on this platform,
8120 # and will be corrupted by setting them based on a non-working compiler.
8121 if test yes != "$_lt_disable_F77"; then
8122 # Code to be used in simple compile tests
8123 lt_simple_compile_test_code="\
8129 # Code to be used in simple link tests
8130 lt_simple_link_test_code="\
8135 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8138 # save warnings/boilerplate of simple test code
8139 _LT_COMPILER_BOILERPLATE
8140 _LT_LINKER_BOILERPLATE
8142 # Allow CC to be a program name with arguments.
8145 lt_save_CFLAGS=$CFLAGS
8149 _LT_TAGVAR(compiler, $1)=$CC
8150 _LT_CC_BASENAME([$compiler])
8152 if test -n "$compiler"; then
8153 AC_MSG_CHECKING([if libtool supports shared libraries])
8154 AC_MSG_RESULT([$can_build_shared])
8156 AC_MSG_CHECKING([whether to build shared libraries])
8157 test no = "$can_build_shared" && enable_shared=no
8159 # On AIX, shared libraries and static libraries use the same namespace, and
8160 # are all built from PIC.
8163 test yes = "$enable_shared" && enable_static=no
8164 if test -n "$RANLIB"; then
8165 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8166 postinstall_cmds='$RANLIB $lib'
8170 if test ia64 != "$host_cpu"; then
8171 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
8172 yes,aix,yes) ;; # shared object as lib.so file only
8173 yes,svr4,*) ;; # shared object as lib.so archive member only
8174 yes,*) enable_static=no ;; # shared object in lib.a archive as well
8179 AC_MSG_RESULT([$enable_shared])
8181 AC_MSG_CHECKING([whether to build static libraries])
8182 # Make sure either enable_shared or enable_static is yes.
8183 test yes = "$enable_shared" || enable_static=yes
8184 AC_MSG_RESULT([$enable_static])
8186 _LT_TAGVAR(GCC, $1)=$G77
8187 _LT_TAGVAR(LD, $1)=$LD
8190 ## There is no encapsulation within the following macros, do not change
8191 ## the running order or otherwise move them around unless you know exactly
8192 ## what you are doing...
8193 _LT_COMPILER_PIC($1)
8194 _LT_COMPILER_C_O($1)
8195 _LT_COMPILER_FILE_LOCKS($1)
8196 _LT_LINKER_SHLIBS($1)
8197 _LT_SYS_DYNAMIC_LINKER($1)
8198 _LT_LINKER_HARDCODE_LIBPATH($1)
8201 fi # test -n "$compiler"
8205 CFLAGS=$lt_save_CFLAGS
8206 fi # test yes != "$_lt_disable_F77"
8209 ])# _LT_LANG_F77_CONFIG
8212 # _LT_LANG_FC_CONFIG([TAG])
8213 # -------------------------
8214 # Ensure that the configuration variables for a Fortran compiler are
8215 # suitably defined. These variables are subsequently used by _LT_CONFIG
8216 # to write the compiler configuration to 'libtool'.
8217 m4_defun([_LT_LANG_FC_CONFIG],
8218 [AC_LANG_PUSH(Fortran)
8220 if test -z "$FC" || test no = "$FC"; then
8224 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8225 _LT_TAGVAR(allow_undefined_flag, $1)=
8226 _LT_TAGVAR(always_export_symbols, $1)=no
8227 _LT_TAGVAR(archive_expsym_cmds, $1)=
8228 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8229 _LT_TAGVAR(hardcode_direct, $1)=no
8230 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8231 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8232 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8233 _LT_TAGVAR(hardcode_minus_L, $1)=no
8234 _LT_TAGVAR(hardcode_automatic, $1)=no
8235 _LT_TAGVAR(inherit_rpath, $1)=no
8236 _LT_TAGVAR(module_cmds, $1)=
8237 _LT_TAGVAR(module_expsym_cmds, $1)=
8238 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8239 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8240 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8241 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8242 _LT_TAGVAR(no_undefined_flag, $1)=
8243 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8244 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8246 # Source file extension for fc test sources.
8247 ac_ext=${ac_fc_srcext-f}
8249 # Object file extension for compiled fc test sources.
8251 _LT_TAGVAR(objext, $1)=$objext
8253 # No sense in running all these tests if we already determined that
8254 # the FC compiler isn't working. Some variables (like enable_shared)
8255 # are currently assumed to apply to all compilers on this platform,
8256 # and will be corrupted by setting them based on a non-working compiler.
8257 if test yes != "$_lt_disable_FC"; then
8258 # Code to be used in simple compile tests
8259 lt_simple_compile_test_code="\
8265 # Code to be used in simple link tests
8266 lt_simple_link_test_code="\
8271 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8274 # save warnings/boilerplate of simple test code
8275 _LT_COMPILER_BOILERPLATE
8276 _LT_LINKER_BOILERPLATE
8278 # Allow CC to be a program name with arguments.
8281 lt_save_CFLAGS=$CFLAGS
8285 GCC=$ac_cv_fc_compiler_gnu
8287 _LT_TAGVAR(compiler, $1)=$CC
8288 _LT_CC_BASENAME([$compiler])
8290 if test -n "$compiler"; then
8291 AC_MSG_CHECKING([if libtool supports shared libraries])
8292 AC_MSG_RESULT([$can_build_shared])
8294 AC_MSG_CHECKING([whether to build shared libraries])
8295 test no = "$can_build_shared" && enable_shared=no
8297 # On AIX, shared libraries and static libraries use the same namespace, and
8298 # are all built from PIC.
8301 test yes = "$enable_shared" && enable_static=no
8302 if test -n "$RANLIB"; then
8303 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8304 postinstall_cmds='$RANLIB $lib'
8308 if test ia64 != "$host_cpu"; then
8309 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
8310 yes,aix,yes) ;; # shared object as lib.so file only
8311 yes,svr4,*) ;; # shared object as lib.so archive member only
8312 yes,*) enable_static=no ;; # shared object in lib.a archive as well
8317 AC_MSG_RESULT([$enable_shared])
8319 AC_MSG_CHECKING([whether to build static libraries])
8320 # Make sure either enable_shared or enable_static is yes.
8321 test yes = "$enable_shared" || enable_static=yes
8322 AC_MSG_RESULT([$enable_static])
8324 _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu
8325 _LT_TAGVAR(LD, $1)=$LD
8328 ## There is no encapsulation within the following macros, do not change
8329 ## the running order or otherwise move them around unless you know exactly
8330 ## what you are doing...
8331 _LT_SYS_HIDDEN_LIBDEPS($1)
8332 _LT_COMPILER_PIC($1)
8333 _LT_COMPILER_C_O($1)
8334 _LT_COMPILER_FILE_LOCKS($1)
8335 _LT_LINKER_SHLIBS($1)
8336 _LT_SYS_DYNAMIC_LINKER($1)
8337 _LT_LINKER_HARDCODE_LIBPATH($1)
8340 fi # test -n "$compiler"
8344 CFLAGS=$lt_save_CFLAGS
8345 fi # test yes != "$_lt_disable_FC"
8348 ])# _LT_LANG_FC_CONFIG
8351 # _LT_LANG_GCJ_CONFIG([TAG])
8352 # --------------------------
8353 # Ensure that the configuration variables for the GNU Java Compiler compiler
8354 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8355 # to write the compiler configuration to 'libtool'.
8356 m4_defun([_LT_LANG_GCJ_CONFIG],
8357 [AC_REQUIRE([LT_PROG_GCJ])dnl
8360 # Source file extension for Java test sources.
8363 # Object file extension for compiled Java test sources.
8365 _LT_TAGVAR(objext, $1)=$objext
8367 # Code to be used in simple compile tests
8368 lt_simple_compile_test_code="class foo {}"
8370 # Code to be used in simple link tests
8371 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
8373 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8376 # save warnings/boilerplate of simple test code
8377 _LT_COMPILER_BOILERPLATE
8378 _LT_LINKER_BOILERPLATE
8380 # Allow CC to be a program name with arguments.
8382 lt_save_CFLAGS=$CFLAGS
8388 _LT_TAGVAR(compiler, $1)=$CC
8389 _LT_TAGVAR(LD, $1)=$LD
8390 _LT_CC_BASENAME([$compiler])
8392 # GCJ did not exist at the time GCC didn't implicitly link libc in.
8393 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8395 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8396 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8397 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8399 if test -n "$compiler"; then
8400 _LT_COMPILER_NO_RTTI($1)
8401 _LT_COMPILER_PIC($1)
8402 _LT_COMPILER_C_O($1)
8403 _LT_COMPILER_FILE_LOCKS($1)
8404 _LT_LINKER_SHLIBS($1)
8405 _LT_LINKER_HARDCODE_LIBPATH($1)
8414 CFLAGS=$lt_save_CFLAGS
8415 ])# _LT_LANG_GCJ_CONFIG
8418 # _LT_LANG_GO_CONFIG([TAG])
8419 # --------------------------
8420 # Ensure that the configuration variables for the GNU Go compiler
8421 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8422 # to write the compiler configuration to 'libtool'.
8423 m4_defun([_LT_LANG_GO_CONFIG],
8424 [AC_REQUIRE([LT_PROG_GO])dnl
8427 # Source file extension for Go test sources.
8430 # Object file extension for compiled Go test sources.
8432 _LT_TAGVAR(objext, $1)=$objext
8434 # Code to be used in simple compile tests
8435 lt_simple_compile_test_code="package main; func main() { }"
8437 # Code to be used in simple link tests
8438 lt_simple_link_test_code='package main; func main() { }'
8440 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8443 # save warnings/boilerplate of simple test code
8444 _LT_COMPILER_BOILERPLATE
8445 _LT_LINKER_BOILERPLATE
8447 # Allow CC to be a program name with arguments.
8449 lt_save_CFLAGS=$CFLAGS
8455 _LT_TAGVAR(compiler, $1)=$CC
8456 _LT_TAGVAR(LD, $1)=$LD
8457 _LT_CC_BASENAME([$compiler])
8459 # Go did not exist at the time GCC didn't implicitly link libc in.
8460 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8462 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8463 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8464 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8466 if test -n "$compiler"; then
8467 _LT_COMPILER_NO_RTTI($1)
8468 _LT_COMPILER_PIC($1)
8469 _LT_COMPILER_C_O($1)
8470 _LT_COMPILER_FILE_LOCKS($1)
8471 _LT_LINKER_SHLIBS($1)
8472 _LT_LINKER_HARDCODE_LIBPATH($1)
8481 CFLAGS=$lt_save_CFLAGS
8482 ])# _LT_LANG_GO_CONFIG
8485 # _LT_LANG_RC_CONFIG([TAG])
8486 # -------------------------
8487 # Ensure that the configuration variables for the Windows resource compiler
8488 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8489 # to write the compiler configuration to 'libtool'.
8490 m4_defun([_LT_LANG_RC_CONFIG],
8491 [AC_REQUIRE([LT_PROG_RC])dnl
8494 # Source file extension for RC test sources.
8497 # Object file extension for compiled RC test sources.
8499 _LT_TAGVAR(objext, $1)=$objext
8501 # Code to be used in simple compile tests
8502 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8504 # Code to be used in simple link tests
8505 lt_simple_link_test_code=$lt_simple_compile_test_code
8507 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8510 # save warnings/boilerplate of simple test code
8511 _LT_COMPILER_BOILERPLATE
8512 _LT_LINKER_BOILERPLATE
8514 # Allow CC to be a program name with arguments.
8516 lt_save_CFLAGS=$CFLAGS
8522 _LT_TAGVAR(compiler, $1)=$CC
8523 _LT_CC_BASENAME([$compiler])
8524 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8526 if test -n "$compiler"; then
8534 CFLAGS=$lt_save_CFLAGS
8535 ])# _LT_LANG_RC_CONFIG
8540 AC_DEFUN([LT_PROG_GCJ],
8541 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
8542 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
8543 [AC_CHECK_TOOL(GCJ, gcj,)
8544 test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2"
8545 AC_SUBST(GCJFLAGS)])])[]dnl
8549 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
8550 dnl aclocal-1.4 backwards compatibility:
8551 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
8556 AC_DEFUN([LT_PROG_GO],
8557 [AC_CHECK_TOOL(GOC, gccgo,)
8563 AC_DEFUN([LT_PROG_RC],
8564 [AC_CHECK_TOOL(RC, windres,)
8568 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
8569 dnl aclocal-1.4 backwards compatibility:
8570 dnl AC_DEFUN([LT_AC_PROG_RC], [])
8575 # If we don't have a new enough Autoconf to choose the best grep
8576 # available, choose the one first in the user's PATH.
8577 m4_defun([_LT_DECL_EGREP],
8578 [AC_REQUIRE([AC_PROG_EGREP])dnl
8579 AC_REQUIRE([AC_PROG_FGREP])dnl
8580 test -z "$GREP" && GREP=grep
8581 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
8582 _LT_DECL([], [EGREP], [1], [An ERE matcher])
8583 _LT_DECL([], [FGREP], [1], [A literal string matcher])
8584 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
8591 # If we don't have a new enough Autoconf to choose the best objdump
8592 # available, choose the one first in the user's PATH.
8593 m4_defun([_LT_DECL_OBJDUMP],
8594 [AC_CHECK_TOOL(OBJDUMP, objdump, false)
8595 test -z "$OBJDUMP" && OBJDUMP=objdump
8596 _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
8602 # Ensure DLLTOOL variable is set.
8603 m4_defun([_LT_DECL_DLLTOOL],
8604 [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8605 test -z "$DLLTOOL" && DLLTOOL=dlltool
8606 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
8612 # Check for a fully-functional sed program, that truncates
8613 # as few characters as possible. Prefer GNU sed if found.
8614 m4_defun([_LT_DECL_SED],
8616 test -z "$SED" && SED=sed
8617 Xsed="$SED -e 1s/^X//"
8618 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
8619 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
8620 [Sed that helps us avoid accidentally triggering echo(1) options like -n])
8623 m4_ifndef([AC_PROG_SED], [
8624 # NOTE: This macro has been submitted for inclusion into #
8625 # GNU Autoconf as AC_PROG_SED. When it is available in #
8626 # a released version of Autoconf we should remove this #
8627 # macro and use it instead. #
8629 m4_defun([AC_PROG_SED],
8630 [AC_MSG_CHECKING([for a sed that does not truncate output])
8631 AC_CACHE_VAL(lt_cv_path_SED,
8632 [# Loop through the user's path and test for sed and gsed.
8633 # Then use that list of sed's as ones to test for truncation.
8634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8638 test -z "$as_dir" && as_dir=.
8639 for lt_ac_prog in sed gsed; do
8640 for ac_exec_ext in '' $ac_executable_extensions; do
8641 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
8642 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
8650 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
8651 # along with /bin/sed that truncates output.
8652 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
8653 test ! -f "$lt_ac_sed" && continue
8654 cat /dev/null > conftest.in
8656 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
8657 # Check for GNU sed and select it if it is found.
8658 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
8659 lt_cv_path_SED=$lt_ac_sed
8663 cat conftest.in conftest.in >conftest.tmp
8664 mv conftest.tmp conftest.in
8665 cp conftest.in conftest.nl
8667 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
8668 cmp -s conftest.out conftest.nl || break
8669 # 10000 chars as input seems more than enough
8670 test 10 -lt "$lt_ac_count" && break
8671 lt_ac_count=`expr $lt_ac_count + 1`
8672 if test "$lt_ac_count" -gt "$lt_ac_max"; then
8673 lt_ac_max=$lt_ac_count
8674 lt_cv_path_SED=$lt_ac_sed
8681 AC_MSG_RESULT([$SED])
8686 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
8687 dnl aclocal-1.4 backwards compatibility:
8688 dnl AC_DEFUN([LT_AC_PROG_SED], [])
8691 # _LT_CHECK_SHELL_FEATURES
8692 # ------------------------
8693 # Find out whether the shell is Bourne or XSI compatible,
8694 # or has some other useful features.
8695 m4_defun([_LT_CHECK_SHELL_FEATURES],
8696 [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8701 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
8703 # test EBCDIC or ASCII
8704 case `echo X|tr X '\101'` in
8705 A) # ASCII based system
8706 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8707 lt_SP2NL='tr \040 \012'
8708 lt_NL2SP='tr \015\012 \040\040'
8710 *) # EBCDIC based system
8711 lt_SP2NL='tr \100 \n'
8712 lt_NL2SP='tr \r\n \100\100'
8715 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
8716 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
8717 ])# _LT_CHECK_SHELL_FEATURES
8720 # _LT_PATH_CONVERSION_FUNCTIONS
8721 # -----------------------------
8722 # Determine what file name conversion functions should be used by
8723 # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
8724 # for certain cross-compile configurations and native mingw.
8725 m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
8726 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8727 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
8728 AC_MSG_CHECKING([how to convert $build file names to $host format])
8729 AC_CACHE_VAL(lt_cv_to_host_file_cmd,
8733 *-*-mingw* ) # actually msys
8734 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8737 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8739 * ) # otherwise, assume *nix
8740 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8746 *-*-mingw* ) # actually msys
8747 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8750 lt_cv_to_host_file_cmd=func_convert_file_noop
8752 * ) # otherwise, assume *nix
8753 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8757 * ) # unhandled hosts (and "normal" native builds)
8758 lt_cv_to_host_file_cmd=func_convert_file_noop
8762 to_host_file_cmd=$lt_cv_to_host_file_cmd
8763 AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
8764 _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
8765 [0], [convert $build file names to $host format])dnl
8767 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
8768 AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
8769 [#assume ordinary cross tools, or native build.
8770 lt_cv_to_tool_file_cmd=func_convert_file_noop
8774 *-*-mingw* ) # actually msys
8775 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8781 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8782 AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
8783 _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
8784 [0], [convert $build files to toolchain format])dnl
8785 ])# _LT_PATH_CONVERSION_FUNCTIONS
8787 # Helper functions for option handling. -*- Autoconf -*-
8789 # Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software
8791 # Written by Gary V. Vaughan, 2004
8793 # This file is free software; the Free Software Foundation gives
8794 # unlimited permission to copy and/or distribute it, with or without
8795 # modifications, as long as this notice is preserved.
8797 # serial 8 ltoptions.m4
8799 # This is to help aclocal find these macros, as it can't see m4_define.
8800 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
8803 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
8804 # ------------------------------------------
8805 m4_define([_LT_MANGLE_OPTION],
8806 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
8809 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
8810 # ---------------------------------------
8811 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
8812 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
8814 m4_define([_LT_SET_OPTION],
8815 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
8816 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
8817 _LT_MANGLE_DEFUN([$1], [$2]),
8818 [m4_warning([Unknown $1 option '$2'])])[]dnl
8822 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
8823 # ------------------------------------------------------------
8824 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
8825 m4_define([_LT_IF_OPTION],
8826 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
8829 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
8830 # -------------------------------------------------------
8831 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
8833 m4_define([_LT_UNLESS_OPTIONS],
8834 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8835 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
8836 [m4_define([$0_found])])])[]dnl
8837 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
8842 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
8843 # ----------------------------------------
8844 # OPTION-LIST is a space-separated list of Libtool options associated
8845 # with MACRO-NAME. If any OPTION has a matching handler declared with
8846 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
8847 # the unknown option and exit.
8848 m4_defun([_LT_SET_OPTIONS],
8850 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8851 [_LT_SET_OPTION([$1], _LT_Option)])
8853 m4_if([$1],[LT_INIT],[
8855 dnl Simply set some default values (i.e off) if boolean options were not
8857 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
8859 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
8862 dnl If no reference was made to various pairs of opposing options, then
8863 dnl we run the default mode handler for the pair. For example, if neither
8864 dnl 'shared' nor 'disable-shared' was passed, we enable building of shared
8865 dnl archives by default:
8866 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
8867 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
8868 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
8869 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
8870 [_LT_ENABLE_FAST_INSTALL])
8871 _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4],
8872 [_LT_WITH_AIX_SONAME([aix])])
8878 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
8879 # -----------------------------------------
8880 m4_define([_LT_MANGLE_DEFUN],
8881 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
8884 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
8885 # -----------------------------------------------
8886 m4_define([LT_OPTION_DEFINE],
8887 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
8888 ])# LT_OPTION_DEFINE
8893 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
8896 AU_DEFUN([AC_LIBTOOL_DLOPEN],
8897 [_LT_SET_OPTION([LT_INIT], [dlopen])
8898 AC_DIAGNOSE([obsolete],
8899 [$0: Remove this warning and the call to _LT_SET_OPTION when you
8900 put the 'dlopen' option into LT_INIT's first parameter.])
8903 dnl aclocal-1.4 backwards compatibility:
8904 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
8909 # Declare package support for building win32 dll's.
8910 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
8911 [enable_win32_dll=yes
8914 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
8915 AC_CHECK_TOOL(AS, as, false)
8916 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8917 AC_CHECK_TOOL(OBJDUMP, objdump, false)
8921 test -z "$AS" && AS=as
8922 _LT_DECL([], [AS], [1], [Assembler program])dnl
8924 test -z "$DLLTOOL" && DLLTOOL=dlltool
8925 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
8927 test -z "$OBJDUMP" && OBJDUMP=objdump
8928 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
8931 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
8932 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8933 _LT_SET_OPTION([LT_INIT], [win32-dll])
8934 AC_DIAGNOSE([obsolete],
8935 [$0: Remove this warning and the call to _LT_SET_OPTION when you
8936 put the 'win32-dll' option into LT_INIT's first parameter.])
8939 dnl aclocal-1.4 backwards compatibility:
8940 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
8943 # _LT_ENABLE_SHARED([DEFAULT])
8944 # ----------------------------
8945 # implement the --enable-shared flag, and supports the 'shared' and
8946 # 'disable-shared' LT_INIT options.
8947 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
8948 m4_define([_LT_ENABLE_SHARED],
8949 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
8950 AC_ARG_ENABLE([shared],
8951 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
8952 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
8953 [p=${PACKAGE-default}
8955 yes) enable_shared=yes ;;
8956 no) enable_shared=no ;;
8959 # Look at the argument we got. We use all the common list separators.
8960 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
8961 for pkg in $enableval; do
8963 if test "X$pkg" = "X$p"; then
8970 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
8972 _LT_DECL([build_libtool_libs], [enable_shared], [0],
8973 [Whether or not to build shared libraries])
8974 ])# _LT_ENABLE_SHARED
8976 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
8977 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
8980 AC_DEFUN([AC_ENABLE_SHARED],
8981 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
8984 AC_DEFUN([AC_DISABLE_SHARED],
8985 [_LT_SET_OPTION([LT_INIT], [disable-shared])
8988 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
8989 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
8991 dnl aclocal-1.4 backwards compatibility:
8992 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
8993 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
8997 # _LT_ENABLE_STATIC([DEFAULT])
8998 # ----------------------------
8999 # implement the --enable-static flag, and support the 'static' and
9000 # 'disable-static' LT_INIT options.
9001 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
9002 m4_define([_LT_ENABLE_STATIC],
9003 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
9004 AC_ARG_ENABLE([static],
9005 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
9006 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
9007 [p=${PACKAGE-default}
9009 yes) enable_static=yes ;;
9010 no) enable_static=no ;;
9013 # Look at the argument we got. We use all the common list separators.
9014 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
9015 for pkg in $enableval; do
9017 if test "X$pkg" = "X$p"; then
9024 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
9026 _LT_DECL([build_old_libs], [enable_static], [0],
9027 [Whether or not to build static libraries])
9028 ])# _LT_ENABLE_STATIC
9030 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
9031 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
9034 AC_DEFUN([AC_ENABLE_STATIC],
9035 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
9038 AC_DEFUN([AC_DISABLE_STATIC],
9039 [_LT_SET_OPTION([LT_INIT], [disable-static])
9042 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
9043 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
9045 dnl aclocal-1.4 backwards compatibility:
9046 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
9047 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
9051 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
9052 # ----------------------------------
9053 # implement the --enable-fast-install flag, and support the 'fast-install'
9054 # and 'disable-fast-install' LT_INIT options.
9055 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
9056 m4_define([_LT_ENABLE_FAST_INSTALL],
9057 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
9058 AC_ARG_ENABLE([fast-install],
9059 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
9060 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
9061 [p=${PACKAGE-default}
9063 yes) enable_fast_install=yes ;;
9064 no) enable_fast_install=no ;;
9066 enable_fast_install=no
9067 # Look at the argument we got. We use all the common list separators.
9068 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
9069 for pkg in $enableval; do
9071 if test "X$pkg" = "X$p"; then
9072 enable_fast_install=yes
9078 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
9080 _LT_DECL([fast_install], [enable_fast_install], [0],
9081 [Whether or not to optimize for fast installation])dnl
9082 ])# _LT_ENABLE_FAST_INSTALL
9084 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
9085 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
9088 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
9089 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
9090 AC_DIAGNOSE([obsolete],
9091 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9092 the 'fast-install' option into LT_INIT's first parameter.])
9095 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
9096 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
9097 AC_DIAGNOSE([obsolete],
9098 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9099 the 'disable-fast-install' option into LT_INIT's first parameter.])
9102 dnl aclocal-1.4 backwards compatibility:
9103 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
9104 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
9107 # _LT_WITH_AIX_SONAME([DEFAULT])
9108 # ----------------------------------
9109 # implement the --with-aix-soname flag, and support the `aix-soname=aix'
9110 # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT
9111 # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'.
9112 m4_define([_LT_WITH_AIX_SONAME],
9113 [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl
9114 shared_archive_member_spec=
9115 case $host,$enable_shared in
9116 power*-*-aix[[5-9]]*,yes)
9117 AC_MSG_CHECKING([which variant of shared library versioning to provide])
9118 AC_ARG_WITH([aix-soname],
9119 [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
9120 [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])],
9125 AC_MSG_ERROR([Unknown argument to --with-aix-soname])
9128 lt_cv_with_aix_soname=$with_aix_soname],
9129 [AC_CACHE_VAL([lt_cv_with_aix_soname],
9130 [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)
9131 with_aix_soname=$lt_cv_with_aix_soname])
9132 AC_MSG_RESULT([$with_aix_soname])
9133 if test aix != "$with_aix_soname"; then
9134 # For the AIX way of multilib, we name the shared archive member
9135 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
9136 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
9137 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
9138 # the AIX toolchain works better with OBJECT_MODE set (default 32).
9139 if test 64 = "${OBJECT_MODE-32}"; then
9140 shared_archive_member_spec=shr_64
9142 shared_archive_member_spec=shr
9151 _LT_DECL([], [shared_archive_member_spec], [0],
9152 [Shared archive member basename, for filename based shared library versioning on AIX])dnl
9153 ])# _LT_WITH_AIX_SONAME
9155 LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])])
9156 LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])])
9157 LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])])
9160 # _LT_WITH_PIC([MODE])
9161 # --------------------
9162 # implement the --with-pic flag, and support the 'pic-only' and 'no-pic'
9164 # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'.
9165 m4_define([_LT_WITH_PIC],
9167 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
9168 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
9169 [lt_p=${PACKAGE-default}
9171 yes|no) pic_mode=$withval ;;
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 lt_pkg in $withval; do
9178 if test "X$lt_pkg" = "X$lt_p"; then
9185 [pic_mode=m4_default([$1], [default])])
9187 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
9190 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
9191 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
9194 AU_DEFUN([AC_LIBTOOL_PICMODE],
9195 [_LT_SET_OPTION([LT_INIT], [pic-only])
9196 AC_DIAGNOSE([obsolete],
9197 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9198 put the 'pic-only' option into LT_INIT's first parameter.])
9201 dnl aclocal-1.4 backwards compatibility:
9202 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
9205 m4_define([_LTDL_MODE], [])
9206 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
9207 [m4_define([_LTDL_MODE], [nonrecursive])])
9208 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
9209 [m4_define([_LTDL_MODE], [recursive])])
9210 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
9211 [m4_define([_LTDL_MODE], [subproject])])
9213 m4_define([_LTDL_TYPE], [])
9214 LT_OPTION_DEFINE([LTDL_INIT], [installable],
9215 [m4_define([_LTDL_TYPE], [installable])])
9216 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
9217 [m4_define([_LTDL_TYPE], [convenience])])
9219 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
9221 # Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software
9223 # Written by Gary V. Vaughan, 2004
9225 # This file is free software; the Free Software Foundation gives
9226 # unlimited permission to copy and/or distribute it, with or without
9227 # modifications, as long as this notice is preserved.
9229 # serial 6 ltsugar.m4
9231 # This is to help aclocal find these macros, as it can't see m4_define.
9232 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
9235 # lt_join(SEP, ARG1, [ARG2...])
9236 # -----------------------------
9237 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
9238 # associated separator.
9239 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
9240 # versions in m4sugar had bugs.
9241 m4_define([lt_join],
9242 [m4_if([$#], [1], [],
9244 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
9245 m4_define([_lt_join],
9246 [m4_if([$#$2], [2], [],
9247 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
9253 # Manipulate m4 lists.
9254 # These macros are necessary as long as will still need to support
9255 # Autoconf-2.59, which quotes differently.
9256 m4_define([lt_car], [[$1]])
9258 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
9260 [m4_dquote(m4_shift($@))])])
9261 m4_define([lt_unquote], $1)
9264 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
9265 # ------------------------------------------
9266 # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'.
9267 # Note that neither SEPARATOR nor STRING are expanded; they are appended
9268 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
9269 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
9270 # than defined and empty).
9272 # This macro is needed until we can rely on Autoconf 2.62, since earlier
9273 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
9274 m4_define([lt_append],
9276 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
9280 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
9281 # ----------------------------------------------------------
9282 # Produce a SEP delimited list of all paired combinations of elements of
9283 # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
9284 # has the form PREFIXmINFIXSUFFIXn.
9285 # Needed until we can rely on m4_combine added in Autoconf 2.62.
9286 m4_define([lt_combine],
9287 [m4_if(m4_eval([$# > 3]), [1],
9288 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
9289 [[m4_foreach([_Lt_prefix], [$2],
9290 [m4_foreach([_Lt_suffix],
9291 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
9292 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
9295 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
9296 # -----------------------------------------------------------------------
9297 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
9298 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
9299 m4_define([lt_if_append_uniq],
9301 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
9302 [lt_append([$1], [$2], [$3])$4],
9304 [lt_append([$1], [$2], [$3])$4])])
9307 # lt_dict_add(DICT, KEY, VALUE)
9308 # -----------------------------
9309 m4_define([lt_dict_add],
9310 [m4_define([$1($2)], [$3])])
9313 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
9314 # --------------------------------------------
9315 m4_define([lt_dict_add_subkey],
9316 [m4_define([$1($2:$3)], [$4])])
9319 # lt_dict_fetch(DICT, KEY, [SUBKEY])
9320 # ----------------------------------
9321 m4_define([lt_dict_fetch],
9323 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
9324 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
9327 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
9328 # -----------------------------------------------------------------
9329 m4_define([lt_if_dict_fetch],
9330 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
9335 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
9336 # --------------------------------------------------------------
9337 m4_define([lt_dict_filter],
9338 [m4_if([$5], [], [],
9339 [lt_join(m4_quote(m4_default([$4], [[, ]])),
9340 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
9341 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
9344 # ltversion.m4 -- version numbers -*- Autoconf -*-
9346 # Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc.
9347 # Written by Scott James Remnant, 2004
9349 # This file is free software; the Free Software Foundation gives
9350 # unlimited permission to copy and/or distribute it, with or without
9351 # modifications, as long as this notice is preserved.
9355 # serial 4179 ltversion.m4
9356 # This file is part of GNU Libtool
9358 m4_define([LT_PACKAGE_VERSION], [2.4.6])
9359 m4_define([LT_PACKAGE_REVISION], [2.4.6])
9361 AC_DEFUN([LTVERSION_VERSION],
9362 [macro_version='2.4.6'
9363 macro_revision='2.4.6'
9364 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
9365 _LT_DECL(, macro_revision, 0)
9368 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
9370 # Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software
9372 # Written by Scott James Remnant, 2004.
9374 # This file is free software; the Free Software Foundation gives
9375 # unlimited permission to copy and/or distribute it, with or without
9376 # modifications, as long as this notice is preserved.
9378 # serial 5 lt~obsolete.m4
9380 # These exist entirely to fool aclocal when bootstrapping libtool.
9382 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN),
9383 # which have later been changed to m4_define as they aren't part of the
9384 # exported API, or moved to Autoconf or Automake where they belong.
9386 # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
9387 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
9388 # using a macro with the same name in our local m4/libtool.m4 it'll
9389 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
9390 # and doesn't know about Autoconf macros at all.)
9392 # So we provide this file, which has a silly filename so it's always
9393 # included after everything else. This provides aclocal with the
9394 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
9395 # because those macros already exist, or will be overwritten later.
9396 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
9398 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
9399 # Yes, that means every name once taken will need to remain here until
9400 # we give up compatibility with versions before 1.7, at which point
9401 # we need to keep only those names which we still refer to.
9403 # This is to help aclocal find these macros, as it can't see m4_define.
9404 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
9406 m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
9407 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
9408 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
9409 m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
9410 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
9411 m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
9412 m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
9413 m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
9414 m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
9415 m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
9416 m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
9417 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
9418 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
9419 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
9420 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
9421 m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
9422 m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
9423 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
9424 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
9425 m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
9426 m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
9427 m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
9428 m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
9429 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
9430 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
9431 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
9432 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
9433 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
9434 m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
9435 m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
9436 m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
9437 m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
9438 m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
9439 m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
9440 m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
9441 m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
9442 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
9443 m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
9444 m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
9445 m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
9446 m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
9447 m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
9448 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
9449 m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
9450 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
9451 m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
9452 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
9453 m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
9454 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
9455 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
9456 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
9457 m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
9458 m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
9459 m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
9460 m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
9461 m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
9462 m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
9463 m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
9464 m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
9465 m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
9466 m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
9468 dnl pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
9469 dnl serial 11 (pkg-config-0.29)
9471 dnl Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
9472 dnl Copyright © 2012-2015 Dan Nicholson <dbn.lists@gmail.com>
9474 dnl This program is free software; you can redistribute it and/or modify
9475 dnl it under the terms of the GNU General Public License as published by
9476 dnl the Free Software Foundation; either version 2 of the License, or
9477 dnl (at your option) any later version.
9479 dnl This program is distributed in the hope that it will be useful, but
9480 dnl WITHOUT ANY WARRANTY; without even the implied warranty of
9481 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
9482 dnl General Public License for more details.
9484 dnl You should have received a copy of the GNU General Public License
9485 dnl along with this program; if not, write to the Free Software
9486 dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
9487 dnl 02111-1307, USA.
9489 dnl As a special exception to the GNU General Public License, if you
9490 dnl distribute this file as part of a program that contains a
9491 dnl configuration script generated by Autoconf, you may include it under
9492 dnl the same distribution terms that you use for the rest of that
9495 dnl PKG_PREREQ(MIN-VERSION)
9496 dnl -----------------------
9499 dnl Verify that the version of the pkg-config macros are at least
9500 dnl MIN-VERSION. Unlike PKG_PROG_PKG_CONFIG, which checks the user's
9501 dnl installed version of pkg-config, this checks the developer's version
9502 dnl of pkg.m4 when generating configure.
9504 dnl To ensure that this macro is defined, also add:
9505 dnl m4_ifndef([PKG_PREREQ],
9506 dnl [m4_fatal([must install pkg-config 0.29 or later before running autoconf/autogen])])
9508 dnl See the "Since" comment for each macro you use to see what version
9509 dnl of the macros you require.
9510 m4_defun([PKG_PREREQ],
9511 [m4_define([PKG_MACROS_VERSION], [0.29])
9512 m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1,
9513 [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])])
9516 dnl PKG_PROG_PKG_CONFIG([MIN-VERSION])
9517 dnl ----------------------------------
9520 dnl Search for the pkg-config tool and set the PKG_CONFIG variable to
9521 dnl first found in the path. Checks that the version of pkg-config found
9522 dnl is at least MIN-VERSION. If MIN-VERSION is not specified, 0.9.0 is
9523 dnl used since that's the first version where most current features of
9524 dnl pkg-config existed.
9525 AC_DEFUN([PKG_PROG_PKG_CONFIG],
9526 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
9527 m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
9528 m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
9529 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
9530 AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
9531 AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
9533 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
9534 AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
9536 if test -n "$PKG_CONFIG"; then
9537 _pkg_min_version=m4_default([$1], [0.9.0])
9538 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
9539 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
9540 AC_MSG_RESULT([yes])
9546 ])dnl PKG_PROG_PKG_CONFIG
9548 dnl PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9549 dnl -------------------------------------------------------------------
9552 dnl Check to see whether a particular set of modules exists. Similar to
9553 dnl PKG_CHECK_MODULES(), but does not set variables or print errors.
9555 dnl Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9556 dnl only at the first occurence in configure.ac, so if the first place
9557 dnl it's called might be skipped (such as if it is within an "if", you
9558 dnl have to call PKG_CHECK_EXISTS manually
9559 AC_DEFUN([PKG_CHECK_EXISTS],
9560 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9561 if test -n "$PKG_CONFIG" && \
9562 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
9563 m4_default([$2], [:])
9564 m4_ifvaln([$3], [else
9568 dnl _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
9569 dnl ---------------------------------------------
9570 dnl Internal wrapper calling pkg-config via PKG_CONFIG and setting
9571 dnl pkg_failed based on the result.
9572 m4_define([_PKG_CONFIG],
9573 [if test -n "$$1"; then
9575 elif test -n "$PKG_CONFIG"; then
9576 PKG_CHECK_EXISTS([$3],
9577 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
9578 test "x$?" != "x0" && pkg_failed=yes ],
9585 dnl _PKG_SHORT_ERRORS_SUPPORTED
9586 dnl ---------------------------
9587 dnl Internal check to see if pkg-config supports short errors.
9588 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
9589 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9590 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
9591 _pkg_short_errors_supported=yes
9593 _pkg_short_errors_supported=no
9595 ])dnl _PKG_SHORT_ERRORS_SUPPORTED
9598 dnl PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
9599 dnl [ACTION-IF-NOT-FOUND])
9600 dnl --------------------------------------------------------------
9603 dnl Note that if there is a possibility the first call to
9604 dnl PKG_CHECK_MODULES might not happen, you should be sure to include an
9605 dnl explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
9606 AC_DEFUN([PKG_CHECK_MODULES],
9607 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9608 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
9609 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
9612 AC_MSG_CHECKING([for $1])
9614 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
9615 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
9617 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
9618 and $1[]_LIBS to avoid the need to call pkg-config.
9619 See the pkg-config man page for more details.])
9621 if test $pkg_failed = yes; then
9623 _PKG_SHORT_ERRORS_SUPPORTED
9624 if test $_pkg_short_errors_supported = yes; then
9625 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
9627 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
9629 # Put the nasty error message in config.log where it belongs
9630 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
9632 m4_default([$4], [AC_MSG_ERROR(
9633 [Package requirements ($2) were not met:
9637 Consider adjusting the PKG_CONFIG_PATH environment variable if you
9638 installed software in a non-standard prefix.
9642 elif test $pkg_failed = untried; then
9644 m4_default([$4], [AC_MSG_FAILURE(
9645 [The pkg-config script could not be found or is too old. Make sure it
9646 is in your PATH or set the PKG_CONFIG environment variable to the full
9651 To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
9654 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
9655 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
9656 AC_MSG_RESULT([yes])
9659 ])dnl PKG_CHECK_MODULES
9662 dnl PKG_CHECK_MODULES_STATIC(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
9663 dnl [ACTION-IF-NOT-FOUND])
9664 dnl ---------------------------------------------------------------------
9667 dnl Checks for existence of MODULES and gathers its build flags with
9668 dnl static libraries enabled. Sets VARIABLE-PREFIX_CFLAGS from --cflags
9669 dnl and VARIABLE-PREFIX_LIBS from --libs.
9671 dnl Note that if there is a possibility the first call to
9672 dnl PKG_CHECK_MODULES_STATIC might not happen, you should be sure to
9673 dnl include an explicit call to PKG_PROG_PKG_CONFIG in your
9675 AC_DEFUN([PKG_CHECK_MODULES_STATIC],
9676 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9677 _save_PKG_CONFIG=$PKG_CONFIG
9678 PKG_CONFIG="$PKG_CONFIG --static"
9679 PKG_CHECK_MODULES($@)
9680 PKG_CONFIG=$_save_PKG_CONFIG[]dnl
9681 ])dnl PKG_CHECK_MODULES_STATIC
9684 dnl PKG_INSTALLDIR([DIRECTORY])
9685 dnl -------------------------
9688 dnl Substitutes the variable pkgconfigdir as the location where a module
9689 dnl should install pkg-config .pc files. By default the directory is
9690 dnl $libdir/pkgconfig, but the default can be changed by passing
9691 dnl DIRECTORY. The user can override through the --with-pkgconfigdir
9693 AC_DEFUN([PKG_INSTALLDIR],
9694 [m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])])
9695 m4_pushdef([pkg_description],
9696 [pkg-config installation directory @<:@]pkg_default[@:>@])
9697 AC_ARG_WITH([pkgconfigdir],
9698 [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],,
9699 [with_pkgconfigdir=]pkg_default)
9700 AC_SUBST([pkgconfigdir], [$with_pkgconfigdir])
9701 m4_popdef([pkg_default])
9702 m4_popdef([pkg_description])
9703 ])dnl PKG_INSTALLDIR
9706 dnl PKG_NOARCH_INSTALLDIR([DIRECTORY])
9707 dnl --------------------------------
9710 dnl Substitutes the variable noarch_pkgconfigdir as the location where a
9711 dnl module should install arch-independent pkg-config .pc files. By
9712 dnl default the directory is $datadir/pkgconfig, but the default can be
9713 dnl changed by passing DIRECTORY. The user can override through the
9714 dnl --with-noarch-pkgconfigdir parameter.
9715 AC_DEFUN([PKG_NOARCH_INSTALLDIR],
9716 [m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])])
9717 m4_pushdef([pkg_description],
9718 [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@])
9719 AC_ARG_WITH([noarch-pkgconfigdir],
9720 [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],,
9721 [with_noarch_pkgconfigdir=]pkg_default)
9722 AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir])
9723 m4_popdef([pkg_default])
9724 m4_popdef([pkg_description])
9725 ])dnl PKG_NOARCH_INSTALLDIR
9728 dnl PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE,
9729 dnl [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9730 dnl -------------------------------------------
9733 dnl Retrieves the value of the pkg-config variable for the given module.
9734 AC_DEFUN([PKG_CHECK_VAR],
9735 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9736 AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl
9738 _PKG_CONFIG([$1], [variable="][$3]["], [$2])
9739 AS_VAR_COPY([$1], [pkg_cv_][$1])
9741 AS_VAR_IF([$1], [""], [$5], [$4])dnl
9744 # Copyright (C) 2002-2014 Free Software Foundation, Inc.
9746 # This file is free software; the Free Software Foundation
9747 # gives unlimited permission to copy and/or distribute it,
9748 # with or without modifications, as long as this notice is preserved.
9750 # AM_AUTOMAKE_VERSION(VERSION)
9751 # ----------------------------
9752 # Automake X.Y traces this macro to ensure aclocal.m4 has been
9753 # generated from the m4 files accompanying Automake X.Y.
9754 # (This private macro should not be called outside this file.)
9755 AC_DEFUN([AM_AUTOMAKE_VERSION],
9756 [am__api_version='1.15'
9757 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
9758 dnl require some minimum version. Point them to the right macro.
9759 m4_if([$1], [1.15], [],
9760 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
9763 # _AM_AUTOCONF_VERSION(VERSION)
9764 # -----------------------------
9765 # aclocal traces this macro to find the Autoconf version.
9766 # This is a private macro too. Using m4_define simplifies
9767 # the logic in aclocal, which can simply ignore this definition.
9768 m4_define([_AM_AUTOCONF_VERSION], [])
9770 # AM_SET_CURRENT_AUTOMAKE_VERSION
9771 # -------------------------------
9772 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
9773 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
9774 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
9775 [AM_AUTOMAKE_VERSION([1.15])dnl
9776 m4_ifndef([AC_AUTOCONF_VERSION],
9777 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
9778 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
9780 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
9782 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
9784 # This file is free software; the Free Software Foundation
9785 # gives unlimited permission to copy and/or distribute it,
9786 # with or without modifications, as long as this notice is preserved.
9788 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
9789 # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
9790 # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
9792 # Of course, Automake must honor this variable whenever it calls a
9793 # tool from the auxiliary directory. The problem is that $srcdir (and
9794 # therefore $ac_aux_dir as well) can be either absolute or relative,
9795 # depending on how configure is run. This is pretty annoying, since
9796 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
9797 # source directory, any form will work fine, but in subdirectories a
9798 # relative path needs to be adjusted first.
9800 # $ac_aux_dir/missing
9801 # fails when called from a subdirectory if $ac_aux_dir is relative
9802 # $top_srcdir/$ac_aux_dir/missing
9803 # fails if $ac_aux_dir is absolute,
9804 # fails when called from a subdirectory in a VPATH build with
9805 # a relative $ac_aux_dir
9807 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
9808 # are both prefixed by $srcdir. In an in-source build this is usually
9809 # harmless because $srcdir is '.', but things will broke when you
9810 # start a VPATH build or use an absolute $srcdir.
9812 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
9813 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
9814 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
9815 # and then we would define $MISSING as
9816 # MISSING="\${SHELL} $am_aux_dir/missing"
9817 # This will work as long as MISSING is not called from configure, because
9818 # unfortunately $(top_srcdir) has no meaning in configure.
9819 # However there are other variables, like CC, which are often used in
9820 # configure, and could therefore not use this "fixed" $ac_aux_dir.
9822 # Another solution, used here, is to always expand $ac_aux_dir to an
9823 # absolute PATH. The drawback is that using absolute paths prevent a
9824 # configured tree to be moved without reconfiguration.
9826 AC_DEFUN([AM_AUX_DIR_EXPAND],
9827 [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
9828 # Expand $ac_aux_dir to an absolute path.
9829 am_aux_dir=`cd "$ac_aux_dir" && pwd`
9832 # AM_CONDITIONAL -*- Autoconf -*-
9834 # Copyright (C) 1997-2014 Free Software Foundation, Inc.
9836 # This file is free software; the Free Software Foundation
9837 # gives unlimited permission to copy and/or distribute it,
9838 # with or without modifications, as long as this notice is preserved.
9840 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
9841 # -------------------------------------
9842 # Define a conditional.
9843 AC_DEFUN([AM_CONDITIONAL],
9844 [AC_PREREQ([2.52])dnl
9845 m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
9846 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
9847 AC_SUBST([$1_TRUE])dnl
9848 AC_SUBST([$1_FALSE])dnl
9849 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
9850 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
9851 m4_define([_AM_COND_VALUE_$1], [$2])dnl
9859 AC_CONFIG_COMMANDS_PRE(
9860 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
9861 AC_MSG_ERROR([[conditional "$1" was never defined.
9862 Usually this means the macro was only invoked conditionally.]])
9865 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
9867 # This file is free software; the Free Software Foundation
9868 # gives unlimited permission to copy and/or distribute it,
9869 # with or without modifications, as long as this notice is preserved.
9872 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
9873 # written in clear, in which case automake, when reading aclocal.m4,
9874 # will think it sees a *use*, and therefore will trigger all it's
9875 # C support machinery. Also note that it means that autoscan, seeing
9876 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
9879 # _AM_DEPENDENCIES(NAME)
9880 # ----------------------
9881 # See how the compiler implements dependency checking.
9882 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
9883 # We try a few techniques and use that to set a single cache variable.
9885 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
9886 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
9887 # dependency, and given that the user is not expected to run this macro,
9888 # just rely on AC_PROG_CC.
9889 AC_DEFUN([_AM_DEPENDENCIES],
9890 [AC_REQUIRE([AM_SET_DEPDIR])dnl
9891 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
9892 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
9893 AC_REQUIRE([AM_DEP_TRACK])dnl
9895 m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
9896 [$1], [CXX], [depcc="$CXX" am_compiler_list=],
9897 [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
9898 [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
9899 [$1], [UPC], [depcc="$UPC" am_compiler_list=],
9900 [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
9901 [depcc="$$1" am_compiler_list=])
9903 AC_CACHE_CHECK([dependency style of $depcc],
9904 [am_cv_$1_dependencies_compiler_type],
9905 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
9906 # We make a subdir and do the tests there. Otherwise we can end up
9907 # making bogus files that we don't know about and never remove. For
9908 # instance it was reported that on HP-UX the gcc test will end up
9909 # making a dummy file named 'D' -- because '-MD' means "put the output
9913 # Copy depcomp to subdir because otherwise we won't find it if we're
9914 # using a relative directory.
9915 cp "$am_depcomp" conftest.dir
9917 # We will build objects and dependencies in a subdirectory because
9918 # it helps to detect inapplicable dependency modes. For instance
9919 # both Tru64's cc and ICC support -MD to output dependencies as a
9920 # side effect of compilation, but ICC will put the dependencies in
9921 # the current directory while Tru64 will put them in the object
9925 am_cv_$1_dependencies_compiler_type=none
9926 if test "$am_compiler_list" = ""; then
9927 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
9931 [case " $depcc " in #(
9932 *\ -arch\ *\ -arch\ *) am__universal=true ;;
9935 [case " $depcc " in #(
9936 *\ -arch\ *\ -arch\ *) am__universal=true ;;
9939 for depmode in $am_compiler_list; do
9940 # Setup a source with many dependencies, because some compilers
9941 # like to wrap large dependency lists on column 80 (with \), and
9942 # we should not choose a depcomp mode which is confused by this.
9944 # We need to recreate these files for each test, as the compiler may
9945 # overwrite some of them when testing with obscure command lines.
9946 # This happens at least with the AIX C compiler.
9948 for i in 1 2 3 4 5 6; do
9949 echo '#include "conftst'$i'.h"' >> sub/conftest.c
9950 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
9951 # Solaris 10 /bin/sh.
9952 echo '/* dummy */' > sub/conftst$i.h
9954 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
9956 # We check with '-c' and '-o' for the sake of the "dashmstdout"
9957 # mode. It turns out that the SunPro C++ compiler does not properly
9958 # handle '-M -o', and we need to detect this. Also, some Intel
9959 # versions had trouble with output in subdirs.
9960 am__obj=sub/conftest.${OBJEXT-o}
9961 am__minus_obj="-o $am__obj"
9964 # This depmode causes a compiler race in universal mode.
9965 test "$am__universal" = false || continue
9968 # After this tag, mechanisms are not by side-effect, so they'll
9969 # only be used when explicitly requested.
9970 if test "x$enable_dependency_tracking" = xyes; then
9976 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
9977 # This compiler won't grok '-c -o', but also, the minuso test has
9978 # not run yet. These depmodes are late enough in the game, and
9979 # so weak that their functioning should not be impacted.
9980 am__obj=conftest.${OBJEXT-o}
9985 if depmode=$depmode \
9986 source=sub/conftest.c object=$am__obj \
9987 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
9988 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
9989 >/dev/null 2>conftest.err &&
9990 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
9991 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
9992 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
9993 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
9994 # icc doesn't choke on unknown options, it will just issue warnings
9995 # or remarks (even with -Werror). So we grep stderr for any message
9996 # that says an option was ignored or not supported.
9997 # When given -MP, icc 7.0 and 7.1 complain thusly:
9998 # icc: Command line warning: ignoring option '-M'; no argument required
9999 # The diagnosis changed in icc 8.0:
10000 # icc: Command line remark: option '-MP' not supported
10001 if (grep 'ignoring option' conftest.err ||
10002 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
10003 am_cv_$1_dependencies_compiler_type=$depmode
10010 rm -rf conftest.dir
10012 am_cv_$1_dependencies_compiler_type=none
10015 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
10016 AM_CONDITIONAL([am__fastdep$1], [
10017 test "x$enable_dependency_tracking" != xno \
10018 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
10024 # Choose a directory name for dependency files.
10025 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
10026 AC_DEFUN([AM_SET_DEPDIR],
10027 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10028 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
10034 AC_DEFUN([AM_DEP_TRACK],
10035 [AC_ARG_ENABLE([dependency-tracking], [dnl
10037 [--enable-dependency-tracking],
10038 [do not reject slow dependency extractors])
10040 [--disable-dependency-tracking],
10041 [speeds up one-time build])])
10042 if test "x$enable_dependency_tracking" != xno; then
10043 am_depcomp="$ac_aux_dir/depcomp"
10047 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
10048 AC_SUBST([AMDEPBACKSLASH])dnl
10049 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
10050 AC_SUBST([am__nodep])dnl
10051 _AM_SUBST_NOTMAKE([am__nodep])dnl
10054 # Generate code to set up dependency tracking. -*- Autoconf -*-
10056 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
10058 # This file is free software; the Free Software Foundation
10059 # gives unlimited permission to copy and/or distribute it,
10060 # with or without modifications, as long as this notice is preserved.
10063 # _AM_OUTPUT_DEPENDENCY_COMMANDS
10064 # ------------------------------
10065 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
10067 # Older Autoconf quotes --file arguments for eval, but not when files
10068 # are listed without --file. Let's play safe and only enable the eval
10069 # if we detect the quoting.
10070 case $CONFIG_FILES in
10071 *\'*) eval set x "$CONFIG_FILES" ;;
10072 *) set x $CONFIG_FILES ;;
10077 # Strip MF so we end up with the name of the file.
10078 mf=`echo "$mf" | sed -e 's/:.*$//'`
10079 # Check whether this is an Automake generated Makefile or not.
10080 # We used to match only the files named 'Makefile.in', but
10081 # some people rename them; so instead we look at the file content.
10082 # Grep'ing the first line is not enough: some people post-process
10083 # each Makefile.in and add a new line on top of each file to say so.
10084 # Grep'ing the whole file is not good either: AIX grep has a line
10085 # limit of 2048, but all sed's we know have understand at least 4000.
10086 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
10087 dirpart=`AS_DIRNAME("$mf")`
10091 # Extract the definition of DEPDIR, am__include, and am__quote
10092 # from the Makefile without running 'make'.
10093 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
10094 test -z "$DEPDIR" && continue
10095 am__include=`sed -n 's/^am__include = //p' < "$mf"`
10096 test -z "$am__include" && continue
10097 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
10098 # Find all dependency output files, they are included files with
10099 # $(DEPDIR) in their names. We invoke sed twice because it is the
10100 # simplest approach to changing $(DEPDIR) to its actual value in the
10102 for file in `sed -n "
10103 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
10104 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
10105 # Make sure the directory exists.
10106 test -f "$dirpart/$file" && continue
10107 fdir=`AS_DIRNAME(["$file"])`
10108 AS_MKDIR_P([$dirpart/$fdir])
10109 # echo "creating $dirpart/$file"
10110 echo '# dummy' > "$dirpart/$file"
10114 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
10117 # AM_OUTPUT_DEPENDENCY_COMMANDS
10118 # -----------------------------
10119 # This macro should only be invoked once -- use via AC_REQUIRE.
10121 # This code is only required when automatic dependency tracking
10122 # is enabled. FIXME. This creates each '.P' file that we will
10123 # need in order to bootstrap the dependency handling code.
10124 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
10125 [AC_CONFIG_COMMANDS([depfiles],
10126 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
10127 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
10130 # Do all the work for Automake. -*- Autoconf -*-
10132 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10134 # This file is free software; the Free Software Foundation
10135 # gives unlimited permission to copy and/or distribute it,
10136 # with or without modifications, as long as this notice is preserved.
10138 # This macro actually does too much. Some checks are only needed if
10139 # your package does certain things. But this isn't really a big deal.
10141 dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
10142 m4_define([AC_PROG_CC],
10143 m4_defn([AC_PROG_CC])
10147 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
10148 # AM_INIT_AUTOMAKE([OPTIONS])
10149 # -----------------------------------------------
10150 # The call with PACKAGE and VERSION arguments is the old style
10151 # call (pre autoconf-2.50), which is being phased out. PACKAGE
10152 # and VERSION should now be passed to AC_INIT and removed from
10153 # the call to AM_INIT_AUTOMAKE.
10154 # We support both call styles for the transition. After
10155 # the next Automake release, Autoconf can make the AC_INIT
10156 # arguments mandatory, and then we can depend on a new Autoconf
10157 # release and drop the old call support.
10158 AC_DEFUN([AM_INIT_AUTOMAKE],
10159 [AC_PREREQ([2.65])dnl
10160 dnl Autoconf wants to disallow AM_ names. We explicitly allow
10161 dnl the ones we care about.
10162 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
10163 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
10164 AC_REQUIRE([AC_PROG_INSTALL])dnl
10165 if test "`cd $srcdir && pwd`" != "`pwd`"; then
10166 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
10167 # is not polluted with repeated "-I."
10168 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
10169 # test to see if srcdir already configured
10170 if test -f $srcdir/config.status; then
10171 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
10175 # test whether we have cygpath
10176 if test -z "$CYGPATH_W"; then
10177 if (cygpath --version) >/dev/null 2>/dev/null; then
10178 CYGPATH_W='cygpath -w'
10183 AC_SUBST([CYGPATH_W])
10185 # Define the identity of the package.
10186 dnl Distinguish between old-style and new-style calls.
10188 [AC_DIAGNOSE([obsolete],
10189 [$0: two- and three-arguments forms are deprecated.])
10190 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
10191 AC_SUBST([PACKAGE], [$1])dnl
10192 AC_SUBST([VERSION], [$2])],
10193 [_AM_SET_OPTIONS([$1])dnl
10194 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
10196 m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
10198 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
10199 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
10200 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
10202 _AM_IF_OPTION([no-define],,
10203 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
10204 AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
10206 # Some tools Automake needs.
10207 AC_REQUIRE([AM_SANITY_CHECK])dnl
10208 AC_REQUIRE([AC_ARG_PROGRAM])dnl
10209 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
10210 AM_MISSING_PROG([AUTOCONF], [autoconf])
10211 AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
10212 AM_MISSING_PROG([AUTOHEADER], [autoheader])
10213 AM_MISSING_PROG([MAKEINFO], [makeinfo])
10214 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10215 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
10216 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
10217 # For better backward compatibility. To be removed once Automake 1.9.x
10218 # dies out for good. For more background, see:
10219 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
10220 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
10221 AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
10222 # We need awk for the "check" target (and possibly the TAP driver). The
10223 # system "awk" is bad on some platforms.
10224 AC_REQUIRE([AC_PROG_AWK])dnl
10225 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
10226 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10227 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
10228 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
10229 [_AM_PROG_TAR([v7])])])
10230 _AM_IF_OPTION([no-dependencies],,
10231 [AC_PROVIDE_IFELSE([AC_PROG_CC],
10232 [_AM_DEPENDENCIES([CC])],
10233 [m4_define([AC_PROG_CC],
10234 m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
10235 AC_PROVIDE_IFELSE([AC_PROG_CXX],
10236 [_AM_DEPENDENCIES([CXX])],
10237 [m4_define([AC_PROG_CXX],
10238 m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
10239 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
10240 [_AM_DEPENDENCIES([OBJC])],
10241 [m4_define([AC_PROG_OBJC],
10242 m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
10243 AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
10244 [_AM_DEPENDENCIES([OBJCXX])],
10245 [m4_define([AC_PROG_OBJCXX],
10246 m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
10248 AC_REQUIRE([AM_SILENT_RULES])dnl
10249 dnl The testsuite driver may need to know about EXEEXT, so add the
10250 dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
10251 dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
10252 AC_CONFIG_COMMANDS_PRE(dnl
10253 [m4_provide_if([_AM_COMPILER_EXEEXT],
10254 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
10256 # POSIX will say in a future version that running "rm -f" with no argument
10257 # is OK; and we want to be able to make that assumption in our Makefile
10258 # recipes. So use an aggressive probe to check that the usage we want is
10259 # actually supported "in the wild" to an acceptable degree.
10260 # See automake bug#10828.
10261 # To make any issue more visible, cause the running configure to be aborted
10262 # by default if the 'rm' program in use doesn't match our expectations; the
10263 # user can still override this though.
10264 if rm -f && rm -fr && rm -rf; then : OK; else
10268 Your 'rm' program seems unable to run without file operands specified
10269 on the command line, even when the '-f' option is present. This is contrary
10270 to the behaviour of most rm programs out there, and not conforming with
10271 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
10273 Please tell bug-automake@gnu.org about your system, including the value
10274 of your $PATH and any error possibly output before this message. This
10275 can help us improve future automake versions.
10278 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
10279 echo 'Configuration will proceed anyway, since you have set the' >&2
10280 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
10284 Aborting the configuration process, to ensure you take notice of the issue.
10286 You can download and install GNU coreutils to get an 'rm' implementation
10287 that behaves properly: <http://www.gnu.org/software/coreutils/>.
10289 If you want to complete the configuration process using your problematic
10290 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
10291 to "yes", and re-run configure.
10294 AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
10297 dnl The trailing newline in this macro's definition is deliberate, for
10298 dnl backward compatibility and to allow trailing 'dnl'-style comments
10299 dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
10302 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
10303 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
10304 dnl mangled by Autoconf and run in a shell conditional statement.
10305 m4_define([_AC_COMPILER_EXEEXT],
10306 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
10308 # When config.status generates a header, we must update the stamp-h file.
10309 # This file resides in the same directory as the config header
10310 # that is generated. The stamp files are numbered to have different names.
10312 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
10313 # loop where config.status creates the headers, so we can generate
10314 # our stamp files there.
10315 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
10316 [# Compute $1's index in $config_headers.
10319 for _am_header in $config_headers :; do
10320 case $_am_header in
10321 $_am_arg | $_am_arg:* )
10324 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
10327 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
10329 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10331 # This file is free software; the Free Software Foundation
10332 # gives unlimited permission to copy and/or distribute it,
10333 # with or without modifications, as long as this notice is preserved.
10335 # AM_PROG_INSTALL_SH
10336 # ------------------
10337 # Define $install_sh.
10338 AC_DEFUN([AM_PROG_INSTALL_SH],
10339 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10340 if test x"${install_sh+set}" != xset; then
10341 case $am_aux_dir in
10343 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
10345 install_sh="\${SHELL} $am_aux_dir/install-sh"
10348 AC_SUBST([install_sh])])
10350 # Copyright (C) 2003-2014 Free Software Foundation, Inc.
10352 # This file is free software; the Free Software Foundation
10353 # gives unlimited permission to copy and/or distribute it,
10354 # with or without modifications, as long as this notice is preserved.
10356 # Check whether the underlying file-system supports filenames
10357 # with a leading dot. For instance MS-DOS doesn't.
10358 AC_DEFUN([AM_SET_LEADING_DOT],
10359 [rm -rf .tst 2>/dev/null
10360 mkdir .tst 2>/dev/null
10361 if test -d .tst; then
10366 rmdir .tst 2>/dev/null
10367 AC_SUBST([am__leading_dot])])
10369 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
10370 # From Jim Meyering
10372 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10374 # This file is free software; the Free Software Foundation
10375 # gives unlimited permission to copy and/or distribute it,
10376 # with or without modifications, as long as this notice is preserved.
10378 # AM_MAINTAINER_MODE([DEFAULT-MODE])
10379 # ----------------------------------
10380 # Control maintainer-specific portions of Makefiles.
10381 # Default is to disable them, unless 'enable' is passed literally.
10382 # For symmetry, 'disable' may be passed as well. Anyway, the user
10383 # can override the default with the --enable/--disable switch.
10384 AC_DEFUN([AM_MAINTAINER_MODE],
10385 [m4_case(m4_default([$1], [disable]),
10386 [enable], [m4_define([am_maintainer_other], [disable])],
10387 [disable], [m4_define([am_maintainer_other], [enable])],
10388 [m4_define([am_maintainer_other], [enable])
10389 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
10390 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
10391 dnl maintainer-mode's default is 'disable' unless 'enable' is passed
10392 AC_ARG_ENABLE([maintainer-mode],
10393 [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
10394 am_maintainer_other[ make rules and dependencies not useful
10395 (and sometimes confusing) to the casual installer])],
10396 [USE_MAINTAINER_MODE=$enableval],
10397 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
10398 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
10399 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
10400 MAINT=$MAINTAINER_MODE_TRUE
10401 AC_SUBST([MAINT])dnl
10405 # Check to see how 'make' treats includes. -*- Autoconf -*-
10407 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10409 # This file is free software; the Free Software Foundation
10410 # gives unlimited permission to copy and/or distribute it,
10411 # with or without modifications, as long as this notice is preserved.
10413 # AM_MAKE_INCLUDE()
10414 # -----------------
10415 # Check to see how make treats includes.
10416 AC_DEFUN([AM_MAKE_INCLUDE],
10417 [am_make=${MAKE-make}
10418 cat > confinc << 'END'
10420 @echo this is the am__doit target
10423 # If we don't find an include directive, just comment out the code.
10424 AC_MSG_CHECKING([for style of include used by $am_make])
10428 # First try GNU make style include.
10429 echo "include confinc" > confmf
10430 # Ignore all kinds of additional output from 'make'.
10431 case `$am_make -s -f confmf 2> /dev/null` in #(
10432 *the\ am__doit\ target*)
10433 am__include=include
10438 # Now try BSD make style include.
10439 if test "$am__include" = "#"; then
10440 echo '.include "confinc"' > confmf
10441 case `$am_make -s -f confmf 2> /dev/null` in #(
10442 *the\ am__doit\ target*)
10443 am__include=.include
10449 AC_SUBST([am__include])
10450 AC_SUBST([am__quote])
10451 AC_MSG_RESULT([$_am_result])
10452 rm -f confinc confmf
10455 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
10457 # Copyright (C) 1997-2014 Free Software Foundation, Inc.
10459 # This file is free software; the Free Software Foundation
10460 # gives unlimited permission to copy and/or distribute it,
10461 # with or without modifications, as long as this notice is preserved.
10463 # AM_MISSING_PROG(NAME, PROGRAM)
10464 # ------------------------------
10465 AC_DEFUN([AM_MISSING_PROG],
10466 [AC_REQUIRE([AM_MISSING_HAS_RUN])
10467 $1=${$1-"${am_missing_run}$2"}
10470 # AM_MISSING_HAS_RUN
10471 # ------------------
10472 # Define MISSING if not defined so far and test if it is modern enough.
10473 # If it is, set am_missing_run to use it, otherwise, to nothing.
10474 AC_DEFUN([AM_MISSING_HAS_RUN],
10475 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10476 AC_REQUIRE_AUX_FILE([missing])dnl
10477 if test x"${MISSING+set}" != xset; then
10478 case $am_aux_dir in
10480 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
10482 MISSING="\${SHELL} $am_aux_dir/missing" ;;
10485 # Use eval to expand $SHELL
10486 if eval "$MISSING --is-lightweight"; then
10487 am_missing_run="$MISSING "
10490 AC_MSG_WARN(['missing' script is too old or missing])
10495 # Obsolete and "removed" macros, that must however still report explicit
10496 # error messages when used, to smooth transition.
10498 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10500 # This file is free software; the Free Software Foundation
10501 # gives unlimited permission to copy and/or distribute it,
10502 # with or without modifications, as long as this notice is preserved.
10504 AC_DEFUN([AM_CONFIG_HEADER],
10505 [AC_DIAGNOSE([obsolete],
10506 ['$0': this macro is obsolete.
10507 You should use the 'AC][_CONFIG_HEADERS' macro instead.])dnl
10508 AC_CONFIG_HEADERS($@)])
10510 AC_DEFUN([AM_PROG_CC_STDC],
10512 am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
10513 AC_DIAGNOSE([obsolete],
10514 ['$0': this macro is obsolete.
10515 You should simply use the 'AC][_PROG_CC' macro instead.
10516 Also, your code should no longer depend upon 'am_cv_prog_cc_stdc',
10517 but upon 'ac_cv_prog_cc_stdc'.])])
10519 AC_DEFUN([AM_C_PROTOTYPES],
10520 [AC_FATAL([automatic de-ANSI-fication support has been removed])])
10521 AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES])
10523 # Helper functions for option handling. -*- Autoconf -*-
10525 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10527 # This file is free software; the Free Software Foundation
10528 # gives unlimited permission to copy and/or distribute it,
10529 # with or without modifications, as long as this notice is preserved.
10531 # _AM_MANGLE_OPTION(NAME)
10532 # -----------------------
10533 AC_DEFUN([_AM_MANGLE_OPTION],
10534 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
10536 # _AM_SET_OPTION(NAME)
10537 # --------------------
10538 # Set option NAME. Presently that only means defining a flag for this option.
10539 AC_DEFUN([_AM_SET_OPTION],
10540 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
10542 # _AM_SET_OPTIONS(OPTIONS)
10543 # ------------------------
10544 # OPTIONS is a space-separated list of Automake options.
10545 AC_DEFUN([_AM_SET_OPTIONS],
10546 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
10548 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
10549 # -------------------------------------------
10550 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
10551 AC_DEFUN([_AM_IF_OPTION],
10552 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
10554 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
10556 # This file is free software; the Free Software Foundation
10557 # gives unlimited permission to copy and/or distribute it,
10558 # with or without modifications, as long as this notice is preserved.
10562 # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
10563 # to automatically call this.
10564 AC_DEFUN([_AM_PROG_CC_C_O],
10565 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10566 AC_REQUIRE_AUX_FILE([compile])dnl
10567 AC_LANG_PUSH([C])dnl
10569 [whether $CC understands -c and -o together],
10570 [am_cv_prog_cc_c_o],
10571 [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
10572 # Make sure it works both with $CC and with simple cc.
10573 # Following AC_PROG_CC_C_O, we do the test twice because some
10574 # compilers refuse to overwrite an existing .o file with -o,
10575 # though they will create one.
10576 am_cv_prog_cc_c_o=yes
10577 for am_i in 1 2; do
10578 if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
10579 && test -f conftest2.$ac_objext; then
10582 am_cv_prog_cc_c_o=no
10586 rm -f core conftest*
10588 if test "$am_cv_prog_cc_c_o" != yes; then
10589 # Losing compiler, so override with the script.
10590 # FIXME: It is wrong to rewrite CC.
10591 # But if we don't then we get into trouble of one sort or another.
10592 # A longer-term fix would be to have automake use am__CC in this case,
10593 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
10594 CC="$am_aux_dir/compile $CC"
10598 # For backward compatibility.
10599 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
10601 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10603 # This file is free software; the Free Software Foundation
10604 # gives unlimited permission to copy and/or distribute it,
10605 # with or without modifications, as long as this notice is preserved.
10607 # AM_RUN_LOG(COMMAND)
10608 # -------------------
10609 # Run COMMAND, save the exit status in ac_status, and log it.
10610 # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
10611 AC_DEFUN([AM_RUN_LOG],
10612 [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
10613 ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
10615 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
10616 (exit $ac_status); }])
10618 # Check to make sure that the build environment is sane. -*- Autoconf -*-
10620 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10622 # This file is free software; the Free Software Foundation
10623 # gives unlimited permission to copy and/or distribute it,
10624 # with or without modifications, as long as this notice is preserved.
10628 AC_DEFUN([AM_SANITY_CHECK],
10629 [AC_MSG_CHECKING([whether build environment is sane])
10630 # Reject unsafe characters in $srcdir or the absolute working directory
10631 # name. Accept space and tab only in the latter.
10635 *[[\\\"\#\$\&\'\`$am_lf]]*)
10636 AC_MSG_ERROR([unsafe absolute working directory name]);;
10639 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
10640 AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
10643 # Do 'set' in a subshell so we don't clobber the current shell's
10644 # arguments. Must try -L first in case configure is actually a
10645 # symlink; some systems play weird games with the mod time of symlinks
10646 # (eg FreeBSD returns the mod time of the symlink's containing
10650 for am_try in 1 2; do
10651 echo "timestamp, slept: $am_has_slept" > conftest.file
10652 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
10653 if test "$[*]" = "X"; then
10655 set X `ls -t "$srcdir/configure" conftest.file`
10657 if test "$[*]" != "X $srcdir/configure conftest.file" \
10658 && test "$[*]" != "X conftest.file $srcdir/configure"; then
10660 # If neither matched, then we have a broken ls. This can happen
10661 # if, for instance, CONFIG_SHELL is bash and it inherits a
10662 # broken ls alias from the environment. This has actually
10663 # happened. Such a system could not be considered "sane".
10664 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
10665 alias in your environment])
10667 if test "$[2]" = conftest.file || test $am_try -eq 2; then
10674 test "$[2]" = conftest.file
10680 AC_MSG_ERROR([newly created file is older than distributed files!
10681 Check your system clock])
10683 AC_MSG_RESULT([yes])
10684 # If we didn't sleep, we still need to ensure time stamps of config.status and
10685 # generated files are strictly newer.
10687 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
10691 AC_CONFIG_COMMANDS_PRE(
10692 [AC_MSG_CHECKING([that generated files are newer than configure])
10693 if test -n "$am_sleep_pid"; then
10694 # Hide warnings about reused PIDs.
10695 wait $am_sleep_pid 2>/dev/null
10697 AC_MSG_RESULT([done])])
10698 rm -f conftest.file
10701 # Copyright (C) 2009-2014 Free Software Foundation, Inc.
10703 # This file is free software; the Free Software Foundation
10704 # gives unlimited permission to copy and/or distribute it,
10705 # with or without modifications, as long as this notice is preserved.
10707 # AM_SILENT_RULES([DEFAULT])
10708 # --------------------------
10709 # Enable less verbose build rules; with the default set to DEFAULT
10710 # ("yes" being less verbose, "no" or empty being verbose).
10711 AC_DEFUN([AM_SILENT_RULES],
10712 [AC_ARG_ENABLE([silent-rules], [dnl
10714 [--enable-silent-rules],
10715 [less verbose build output (undo: "make V=1")])
10717 [--disable-silent-rules],
10718 [verbose build output (undo: "make V=0")])dnl
10720 case $enable_silent_rules in @%:@ (((
10721 yes) AM_DEFAULT_VERBOSITY=0;;
10722 no) AM_DEFAULT_VERBOSITY=1;;
10723 *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
10726 dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
10727 dnl do not support nested variable expansions.
10728 dnl See automake bug#9928 and bug#10237.
10729 am_make=${MAKE-make}
10730 AC_CACHE_CHECK([whether $am_make supports nested variables],
10731 [am_cv_make_support_nested_variables],
10732 [if AS_ECHO([['TRUE=$(BAR$(V))
10738 .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
10739 am_cv_make_support_nested_variables=yes
10741 am_cv_make_support_nested_variables=no
10743 if test $am_cv_make_support_nested_variables = yes; then
10744 dnl Using '$V' instead of '$(V)' breaks IRIX make.
10746 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
10748 AM_V=$AM_DEFAULT_VERBOSITY
10749 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
10751 AC_SUBST([AM_V])dnl
10752 AM_SUBST_NOTMAKE([AM_V])dnl
10753 AC_SUBST([AM_DEFAULT_V])dnl
10754 AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
10755 AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
10757 AC_SUBST([AM_BACKSLASH])dnl
10758 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
10761 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10763 # This file is free software; the Free Software Foundation
10764 # gives unlimited permission to copy and/or distribute it,
10765 # with or without modifications, as long as this notice is preserved.
10767 # AM_PROG_INSTALL_STRIP
10768 # ---------------------
10769 # One issue with vendor 'install' (even GNU) is that you can't
10770 # specify the program used to strip binaries. This is especially
10771 # annoying in cross-compiling environments, where the build's strip
10772 # is unlikely to handle the host's binaries.
10773 # Fortunately install-sh will honor a STRIPPROG variable, so we
10774 # always use install-sh in "make install-strip", and initialize
10775 # STRIPPROG with the value of the STRIP variable (set by the user).
10776 AC_DEFUN([AM_PROG_INSTALL_STRIP],
10777 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10778 # Installed binaries are usually stripped using 'strip' when the user
10779 # run "make install-strip". However 'strip' might not be the right
10780 # tool to use in cross-compilation environments, therefore Automake
10781 # will honor the 'STRIP' environment variable to overrule this program.
10782 dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
10783 if test "$cross_compiling" != no; then
10784 AC_CHECK_TOOL([STRIP], [strip], :)
10786 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
10787 AC_SUBST([INSTALL_STRIP_PROGRAM])])
10789 # Copyright (C) 2006-2014 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.
10795 # _AM_SUBST_NOTMAKE(VARIABLE)
10796 # ---------------------------
10797 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
10798 # This macro is traced by Automake.
10799 AC_DEFUN([_AM_SUBST_NOTMAKE])
10801 # AM_SUBST_NOTMAKE(VARIABLE)
10802 # --------------------------
10803 # Public sister of _AM_SUBST_NOTMAKE.
10804 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
10806 # Check how to create a tarball. -*- Autoconf -*-
10808 # Copyright (C) 2004-2014 Free Software Foundation, Inc.
10810 # This file is free software; the Free Software Foundation
10811 # gives unlimited permission to copy and/or distribute it,
10812 # with or without modifications, as long as this notice is preserved.
10814 # _AM_PROG_TAR(FORMAT)
10815 # --------------------
10816 # Check how to create a tarball in format FORMAT.
10817 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
10819 # Substitute a variable $(am__tar) that is a command
10820 # writing to stdout a FORMAT-tarball containing the directory
10822 # tardir=directory && $(am__tar) > result.tar
10824 # Substitute a variable $(am__untar) that extract such
10825 # a tarball read from stdin.
10826 # $(am__untar) < result.tar
10828 AC_DEFUN([_AM_PROG_TAR],
10829 [# Always define AMTAR for backward compatibility. Yes, it's still used
10830 # in the wild :-( We should find a proper way to deprecate it ...
10831 AC_SUBST([AMTAR], ['$${TAR-tar}'])
10833 # We'll loop over all known methods to create a tar archive until one works.
10834 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
10837 [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
10841 [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
10842 # There is notably a 21 bits limit for the UID and the GID. In fact,
10843 # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
10845 am_max_uid=2097151 # 2^21 - 1
10846 am_max_gid=$am_max_uid
10847 # The $UID and $GID variables are not portable, so we need to resort
10848 # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
10849 # below are definitely unexpected, so allow the users to see them
10850 # (that is, avoid stderr redirection).
10851 am_uid=`id -u || echo unknown`
10852 am_gid=`id -g || echo unknown`
10853 AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
10854 if test $am_uid -le $am_max_uid; then
10855 AC_MSG_RESULT([yes])
10857 AC_MSG_RESULT([no])
10860 AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
10861 if test $am_gid -le $am_max_gid; then
10862 AC_MSG_RESULT([yes])
10864 AC_MSG_RESULT([no])
10871 [m4_fatal([Unknown tar format])])
10873 AC_MSG_CHECKING([how to create a $1 tar archive])
10875 # Go ahead even if we have the value already cached. We do so because we
10876 # need to set the values for the 'am__tar' and 'am__untar' variables.
10877 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
10879 for _am_tool in $_am_tools; do
10882 for _am_tar in tar gnutar gtar; do
10883 AM_RUN_LOG([$_am_tar --version]) && break
10885 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
10886 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
10887 am__untar="$_am_tar -xf -"
10890 # Must skip GNU tar: if it does not support --format= it doesn't create
10891 # ustar tarball either.
10892 (tar --version) >/dev/null 2>&1 && continue
10893 am__tar='tar chf - "$$tardir"'
10894 am__tar_='tar chf - "$tardir"'
10895 am__untar='tar xf -'
10898 am__tar='pax -L -x $1 -w "$$tardir"'
10899 am__tar_='pax -L -x $1 -w "$tardir"'
10903 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
10904 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
10905 am__untar='cpio -i -H $1 -d'
10914 # If the value was cached, stop now. We just wanted to have am__tar
10915 # and am__untar set.
10916 test -n "${am_cv_prog_tar_$1}" && break
10918 # tar/untar a dummy directory, and stop if the command works.
10919 rm -rf conftest.dir
10921 echo GrepMe > conftest.dir/file
10922 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
10923 rm -rf conftest.dir
10924 if test -s conftest.tar; then
10925 AM_RUN_LOG([$am__untar <conftest.tar])
10926 AM_RUN_LOG([cat conftest.dir/file])
10927 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
10930 rm -rf conftest.dir
10932 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
10933 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
10935 AC_SUBST([am__tar])
10936 AC_SUBST([am__untar])