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 # Copyright (C) 1995-2002 Free Software Foundation, Inc.
24 # Copyright (C) 2001-2003,2004 Red Hat, Inc.
26 # This file is free software, distributed under the terms of the GNU
27 # General Public License. As a special exception to the GNU General
28 # Public License, this file may be distributed as part of a program
29 # that contains a configuration script generated by Autoconf, under
30 # the same distribution terms as the rest of that program.
32 # This file can be copied and used freely without restrictions. It can
33 # be used in projects which are not available under the GNU Public License
34 # but which still want to provide support for the GNU gettext functionality.
36 # Macro to add for using GNU gettext.
37 # Ulrich Drepper <drepper@cygnus.com>, 1995, 1996
39 # Modified to never use included libintl.
40 # Owen Taylor <otaylor@redhat.com>, 12/15/1998
42 # Major rework to remove unused code
43 # Owen Taylor <otaylor@redhat.com>, 12/11/2002
45 # Added better handling of ALL_LINGUAS from GNU gettext version
46 # written by Bruno Haible, Owen Taylor <otaylor.redhat.com> 5/30/3002
48 # Modified to require ngettext
49 # Matthias Clasen <mclasen@redhat.com> 08/06/2004
51 # We need this here as well, since someone might use autoconf-2.5x
52 # to configure GLib then an older version to configure a package
53 # using AM_GLIB_GNU_GETTEXT
57 dnl We go to great lengths to make sure that aclocal won't
58 dnl try to pull in the installed version of these macros
59 dnl when running aclocal in the glib directory.
61 m4_copy([AC_DEFUN],[glib_DEFUN])
62 m4_copy([AC_REQUIRE],[glib_REQUIRE])
64 dnl At the end, if we're not within glib, we'll define the public
65 dnl definitions in terms of our private definitions.
70 glib_DEFUN([GLIB_LC_MESSAGES],
71 [AC_CHECK_HEADERS([locale.h])
72 if test $ac_cv_header_locale_h = yes; then
73 AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
74 [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
75 am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
76 if test $am_cv_val_LC_MESSAGES = yes; then
77 AC_DEFINE(HAVE_LC_MESSAGES, 1,
78 [Define if your <locale.h> file defines LC_MESSAGES.])
82 # GLIB_PATH_PROG_WITH_TEST
83 #----------------------------
84 dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
85 dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
86 glib_DEFUN([GLIB_PATH_PROG_WITH_TEST],
87 [# Extract the first word of "$2", so it can be a program name with args.
88 set dummy $2; ac_word=[$]2
89 AC_MSG_CHECKING([for $ac_word])
90 AC_CACHE_VAL(ac_cv_path_$1,
93 ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
96 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
97 for ac_dir in ifelse([$5], , $PATH, [$5]); do
98 test -z "$ac_dir" && ac_dir=.
99 if test -f $ac_dir/$ac_word; then
101 ac_cv_path_$1="$ac_dir/$ac_word"
107 dnl If no 4th arg is given, leave the cache variable unset,
108 dnl so AC_PATH_PROGS will keep looking.
109 ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
114 if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
124 glib_DEFUN([GLIB_WITH_NLS],
125 dnl NLS is obligatory
129 gt_cv_have_gettext=no
135 AC_CHECK_HEADER(libintl.h,
136 [gt_cv_func_dgettext_libintl="no"
137 libintl_extra_libs=""
140 # First check in libc
142 AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc,
146 [return !ngettext ("","", 1)],
147 gt_cv_func_ngettext_libc=yes,
148 gt_cv_func_ngettext_libc=no)
151 if test "$gt_cv_func_ngettext_libc" = "yes" ; then
152 AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc,
156 [return !dgettext ("","")],
157 gt_cv_func_dgettext_libc=yes,
158 gt_cv_func_dgettext_libc=no)
162 if test "$gt_cv_func_ngettext_libc" = "yes" ; then
163 AC_CHECK_FUNCS(bind_textdomain_codeset)
167 # If we don't have everything we want, check in libintl
169 if test "$gt_cv_func_dgettext_libc" != "yes" \
170 || test "$gt_cv_func_ngettext_libc" != "yes" \
171 || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then
173 AC_CHECK_LIB(intl, bindtextdomain,
174 [AC_CHECK_LIB(intl, ngettext,
175 [AC_CHECK_LIB(intl, dgettext,
176 gt_cv_func_dgettext_libintl=yes)])])
178 if test "$gt_cv_func_dgettext_libintl" != "yes" ; then
179 AC_MSG_CHECKING([if -liconv is needed to use gettext])
181 AC_CHECK_LIB(intl, ngettext,
182 [AC_CHECK_LIB(intl, dcgettext,
183 [gt_cv_func_dgettext_libintl=yes
184 libintl_extra_libs=-liconv],
190 # If we found libintl, then check in it for bind_textdomain_codeset();
191 # we'll prefer libc if neither have bind_textdomain_codeset(),
192 # and both have dgettext and ngettext
194 if test "$gt_cv_func_dgettext_libintl" = "yes" ; then
195 glib_save_LIBS="$LIBS"
196 LIBS="$LIBS -lintl $libintl_extra_libs"
197 unset ac_cv_func_bind_textdomain_codeset
198 AC_CHECK_FUNCS(bind_textdomain_codeset)
199 LIBS="$glib_save_LIBS"
201 if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then
202 gt_cv_func_dgettext_libc=no
204 if test "$gt_cv_func_dgettext_libc" = "yes" \
205 && test "$gt_cv_func_ngettext_libc" = "yes"; then
206 gt_cv_func_dgettext_libintl=no
212 if test "$gt_cv_func_dgettext_libc" = "yes" \
213 || test "$gt_cv_func_dgettext_libintl" = "yes"; then
214 gt_cv_have_gettext=yes
217 if test "$gt_cv_func_dgettext_libintl" = "yes"; then
218 INTLLIBS="-lintl $libintl_extra_libs"
221 if test "$gt_cv_have_gettext" = "yes"; then
222 AC_DEFINE(HAVE_GETTEXT,1,
223 [Define if the GNU gettext() function is already present or preinstalled.])
224 GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
225 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
226 if test "$MSGFMT" != "no"; then
227 glib_save_LIBS="$LIBS"
228 LIBS="$LIBS $INTLLIBS"
229 AC_CHECK_FUNCS(dcgettext)
231 AC_MSG_CHECKING([if msgfmt accepts -c])
232 GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[
235 "Content-Type: text/plain; charset=UTF-8\n"
236 "Project-Id-Version: test 1.0\n"
237 "PO-Revision-Date: 2007-02-15 12:01+0100\n"
238 "Last-Translator: test <foo@bar.xx>\n"
239 "Language-Team: C <LL@li.org>\n"
240 "MIME-Version: 1.0\n"
241 "Content-Transfer-Encoding: 8bit\n"
242 ], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])])
243 AC_SUBST(MSGFMT_OPTS)
244 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
245 GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
246 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
247 AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
248 return _nl_msg_cat_cntr],
253 dnl On Solaris, if bind_textdomain_codeset is in libc,
254 dnl GNU format message catalog is always supported,
255 dnl since both are added to the libc all together.
256 dnl Hence, we'd like to go with DATADIRNAME=share and
257 dnl and CATOBJEXT=.gmo in this case.
258 AC_CHECK_FUNC(bind_textdomain_codeset,
273 LIBS="$glib_save_LIBS"
276 gt_cv_have_gettext=no
281 if test "$gt_cv_have_gettext" = "yes" ; then
282 AC_DEFINE(ENABLE_NLS, 1,
283 [always defined to indicate that i18n is enabled])
286 dnl Test whether we really found GNU xgettext.
287 if test "$XGETTEXT" != ":"; then
288 dnl If it is not GNU xgettext we define it as : so that the
289 dnl Makefiles still can work.
290 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
294 [found xgettext program is not GNU xgettext; ignore it])
299 # We need to process the po/ directory.
303 [case "$CONFIG_FILES" in *po/Makefile.in*)
304 sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
307 dnl These rules are solely for the distribution goal. While doing this
308 dnl we only have to keep exactly one list of the available catalogs
310 for lang in $ALL_LINGUAS; do
311 GMOFILES="$GMOFILES $lang.gmo"
312 POFILES="$POFILES $lang.po"
315 dnl Make all variables we use known to autoconf.
318 AC_SUBST(DATADIRNAME)
322 AC_SUBST(PO_IN_DATADIR_TRUE)
323 AC_SUBST(PO_IN_DATADIR_FALSE)
328 # AM_GLIB_GNU_GETTEXT
329 # -------------------
330 # Do checks necessary for use of gettext. If a suitable implementation
331 # of gettext is found in either in libintl or in the C library,
332 # it will set INTLLIBS to the libraries needed for use of gettext
333 # and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable
334 # gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST()
335 # on various variables needed by the Makefile.in.in installed by
338 glib_DEFUN([GLIB_GNU_GETTEXT],
339 [AC_REQUIRE([AC_PROG_CC])dnl
344 if test "$gt_cv_have_gettext" = "yes"; then
345 if test "x$ALL_LINGUAS" = "x"; then
348 AC_MSG_CHECKING(for catalogs to be installed)
350 for presentlang in $ALL_LINGUAS; do
352 if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then
353 desiredlanguages="$LINGUAS"
355 desiredlanguages="$ALL_LINGUAS"
357 for desiredlang in $desiredlanguages; do
358 # Use the presentlang catalog if desiredlang is
359 # a. equal to presentlang, or
360 # b. a variant of presentlang (because in this case,
361 # presentlang can be used as a fallback for messages
362 # which are not translated in the desiredlang catalog).
363 case "$desiredlang" in
364 "$presentlang"*) useit=yes;;
367 if test $useit = yes; then
368 NEW_LINGUAS="$NEW_LINGUAS $presentlang"
372 AC_MSG_RESULT($LINGUAS)
375 dnl Construct list of names of catalog files to be constructed.
376 if test -n "$LINGUAS"; then
377 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
381 dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
382 dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
383 dnl Try to locate is.
385 if test -n "$ac_aux_dir"; then
386 MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
388 if test -z "$MKINSTALLDIRS"; then
389 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
391 AC_SUBST(MKINSTALLDIRS)
393 dnl Generate list of files to be processed by xgettext which will
394 dnl be included in po/Makefile.
395 test -d po || mkdir po
396 if test "x$srcdir" != "x."; then
397 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
398 posrcprefix="$srcdir/"
400 posrcprefix="../$srcdir/"
406 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
407 < $srcdir/po/POTFILES.in > po/POTFILES
410 # AM_GLIB_DEFINE_LOCALEDIR(VARIABLE)
411 # -------------------------------
412 # Define VARIABLE to the location where catalog files will
413 # be installed by po/Makefile.
414 glib_DEFUN([GLIB_DEFINE_LOCALEDIR],
415 [glib_REQUIRE([GLIB_GNU_GETTEXT])dnl
416 glib_save_prefix="$prefix"
417 glib_save_exec_prefix="$exec_prefix"
418 glib_save_datarootdir="$datarootdir"
419 test "x$prefix" = xNONE && prefix=$ac_default_prefix
420 test "x$exec_prefix" = xNONE && exec_prefix=$prefix
421 datarootdir=`eval echo "${datarootdir}"`
422 if test "x$CATOBJEXT" = "x.mo" ; then
423 localedir=`eval echo "${libdir}/locale"`
425 localedir=`eval echo "${datadir}/locale"`
427 prefix="$glib_save_prefix"
428 exec_prefix="$glib_save_exec_prefix"
429 datarootdir="$glib_save_datarootdir"
430 AC_DEFINE_UNQUOTED($1, "$localedir",
431 [Define the location where the catalogs will be installed])
435 dnl Now the definitions that aclocal will find
437 ifdef(glib_configure_ac,[],[
438 AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)])
439 AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)])
442 # GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL])
444 # Create a temporary file with TEST-FILE as its contents and pass the
445 # file name to PROGRAM. Perform ACTION-IF-PASS if PROGRAM exits with
446 # 0 and perform ACTION-IF-FAIL for any other exit status.
447 AC_DEFUN([GLIB_RUN_PROG],
448 [cat >conftest.foo <<_ACEOF
451 if AC_RUN_LOG([$1 conftest.foo]); then
452 m4_ifval([$3], [$3], [:])
453 m4_ifvaln([$4], [else $4])dnl
454 echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD
455 sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
459 # gnome-compiler-flags.m4
464 dnl GNOME_COMPILE_WARNINGS
465 dnl Turn on many useful compiler warnings and substitute the result into
467 dnl For now, only works on GCC
468 dnl Pass the default value of the --enable-compile-warnings configure option as
469 dnl the first argument to the macro, defaulting to 'yes'.
470 dnl Additional warning/error flags can be passed as an optional second argument.
472 dnl For example: GNOME_COMPILE_WARNINGS([maximum],[-Werror=some-flag -Wfoobar])
473 AC_DEFUN([GNOME_COMPILE_WARNINGS],[
474 dnl ******************************
475 dnl More compiler warnings
476 dnl ******************************
478 AC_ARG_ENABLE(compile-warnings,
479 AS_HELP_STRING([--enable-compile-warnings=@<:@no/minimum/yes/maximum/error@:>@],
480 [Turn on compiler warnings]),,
481 [enable_compile_warnings="m4_default([$1],[yes])"])
483 if test "x$GCC" != xyes; then
484 enable_compile_warnings=no
488 realsave_CFLAGS="$CFLAGS"
490 dnl These are warning flags that aren't marked as fatal. Can be
491 dnl overridden on a per-project basis with -Wno-foo.
494 -Wstrict-prototypes \
498 dnl These compiler flags typically indicate very broken or suspicious
499 dnl code. Some of them such as implicit-function-declaration are
500 dnl just not default because gcc compiles a lot of legacy code.
501 dnl We choose to make this set into explicit errors.
503 -Werror=missing-prototypes \
504 -Werror=implicit-function-declaration \
505 -Werror=pointer-arith \
507 -Werror=format-security \
509 -Werror=missing-include-dirs \
512 dnl Additional warning or error flags provided by the module author to
513 dnl allow stricter standards to be imposed on a per-module basis.
514 dnl The author can pass -W or -Werror flags here as they see fit.
515 additional_flags="m4_default([$2],[])"
517 case "$enable_compile_warnings" in
522 warning_flags="-Wall"
525 warning_flags="$base_warn_flags $base_error_flags $additional_flags"
528 AC_MSG_ERROR(Unknown argument '$enable_compile_warnings' to --enable-compile-warnings)
532 if test "$enable_compile_warnings" = "error" ; then
533 warning_flags="$warning_flags -Werror"
536 dnl Check whether GCC supports the warning options
537 for option in $warning_flags; do
538 save_CFLAGS="$CFLAGS"
539 CFLAGS="$CFLAGS $option"
540 AC_MSG_CHECKING([whether gcc understands $option])
541 AC_TRY_COMPILE([], [],
544 CFLAGS="$save_CFLAGS"
545 AC_MSG_RESULT([$has_option])
546 if test $has_option = yes; then
547 tested_warning_flags="$tested_warning_flags $option"
553 CFLAGS="$realsave_CFLAGS"
554 AC_MSG_CHECKING(what warning flags to pass to the C compiler)
555 AC_MSG_RESULT($tested_warning_flags)
558 AS_HELP_STRING([--enable-iso-c],
559 [Try to warn if code is not ISO C ]),,
562 AC_MSG_CHECKING(what language compliance flags to pass to the C compiler)
564 if test "x$enable_iso_c" != "xno"; then
565 if test "x$GCC" = "xyes"; then
567 *[\ \ ]-ansi[\ \ ]*) ;;
568 *) complCFLAGS="$complCFLAGS -ansi" ;;
571 *[\ \ ]-pedantic[\ \ ]*) ;;
572 *) complCFLAGS="$complCFLAGS -pedantic" ;;
576 AC_MSG_RESULT($complCFLAGS)
578 WARN_CFLAGS="$tested_warning_flags $complCFLAGS"
579 AC_SUBST(WARN_CFLAGS)
582 dnl For C++, do basically the same thing.
584 AC_DEFUN([GNOME_CXX_WARNINGS],[
585 AC_ARG_ENABLE(cxx-warnings,
586 AS_HELP_STRING([--enable-cxx-warnings=@<:@no/minimum/yes@:>@]
587 [Turn on compiler warnings.]),,
588 [enable_cxx_warnings="m4_default([$1],[minimum])"])
590 AC_MSG_CHECKING(what warning flags to pass to the C++ compiler)
592 if test "x$GXX" != xyes; then
593 enable_cxx_warnings=no
595 if test "x$enable_cxx_warnings" != "xno"; then
596 if test "x$GXX" = "xyes"; then
597 case " $CXXFLAGS " in
598 *[\ \ ]-Wall[\ \ ]*) ;;
599 *) warnCXXFLAGS="-Wall -Wno-unused" ;;
602 ## -W is not all that useful. And it cannot be controlled
603 ## with individual -Wno-xxx flags, unlike -Wall
604 if test "x$enable_cxx_warnings" = "xyes"; then
605 warnCXXFLAGS="$warnCXXFLAGS -Wshadow -Woverloaded-virtual"
609 AC_MSG_RESULT($warnCXXFLAGS)
611 AC_ARG_ENABLE(iso-cxx,
612 AS_HELP_STRING([--enable-iso-cxx],
613 [Try to warn if code is not ISO C++ ]),,
616 AC_MSG_CHECKING(what language compliance flags to pass to the C++ compiler)
618 if test "x$enable_iso_cxx" != "xno"; then
619 if test "x$GXX" = "xyes"; then
620 case " $CXXFLAGS " in
621 *[\ \ ]-ansi[\ \ ]*) ;;
622 *) complCXXFLAGS="$complCXXFLAGS -ansi" ;;
625 case " $CXXFLAGS " in
626 *[\ \ ]-pedantic[\ \ ]*) ;;
627 *) complCXXFLAGS="$complCXXFLAGS -pedantic" ;;
631 AC_MSG_RESULT($complCXXFLAGS)
633 WARN_CXXFLAGS="$CXXFLAGS $warnCXXFLAGS $complCXXFLAGS"
634 AC_SUBST(WARN_CXXFLAGS)
638 dnl Defines GSETTINGS_SCHEMAS_INSTALL which controls whether
639 dnl the schema should be compiled
642 AC_DEFUN([GLIB_GSETTINGS],
644 m4_pattern_allow([AM_V_GEN])
645 AC_ARG_ENABLE(schemas-compile,
646 AS_HELP_STRING([--disable-schemas-compile],
647 [Disable regeneration of gschemas.compiled on install]),
648 [case ${enableval} in
649 yes) GSETTINGS_DISABLE_SCHEMAS_COMPILE="" ;;
650 no) GSETTINGS_DISABLE_SCHEMAS_COMPILE="1" ;;
651 *) AC_MSG_ERROR([bad value ${enableval} for --enable-schemas-compile]) ;;
653 AC_SUBST([GSETTINGS_DISABLE_SCHEMAS_COMPILE])
654 PKG_PROG_PKG_CONFIG([0.16])
655 AC_SUBST(gsettingsschemadir, [${datadir}/glib-2.0/schemas])
656 if test x$cross_compiling != xyes; then
657 GLIB_COMPILE_SCHEMAS=`$PKG_CONFIG --variable glib_compile_schemas gio-2.0`
659 AC_PATH_PROG(GLIB_COMPILE_SCHEMAS, glib-compile-schemas)
661 AC_SUBST(GLIB_COMPILE_SCHEMAS)
662 if test "x$GLIB_COMPILE_SCHEMAS" = "x"; then
663 ifelse([$2],,[AC_MSG_ERROR([glib-compile-schemas not found.])],[$2])
665 ifelse([$1],,[:],[$1])
669 .PHONY : uninstall-gsettings-schemas install-gsettings-schemas clean-gsettings-schemas
671 mostlyclean-am: clean-gsettings-schemas
673 gsettings__enum_file = $(addsuffix .enums.xml,$(gsettings_ENUM_NAMESPACE))
675 %.gschema.valid: %.gschema.xml $(gsettings__enum_file)
676 $(AM_V_GEN) $(GLIB_COMPILE_SCHEMAS) --strict --dry-run $(addprefix --schema-file=,$(gsettings__enum_file)) --schema-file=$< && mkdir -p [$](@D) && touch [$]@
678 all-am: $(gsettings_SCHEMAS:.xml=.valid)
679 uninstall-am: uninstall-gsettings-schemas
680 install-data-am: install-gsettings-schemas
682 .SECONDARY: $(gsettings_SCHEMAS)
684 install-gsettings-schemas: $(gsettings_SCHEMAS) $(gsettings__enum_file)
686 if test -n "$^"; then \
687 test -z "$(gsettingsschemadir)" || $(MKDIR_P) "$(DESTDIR)$(gsettingsschemadir)"; \
688 $(INSTALL_DATA) $^ "$(DESTDIR)$(gsettingsschemadir)"; \
689 test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir); \
692 uninstall-gsettings-schemas:
694 @list='\''$(gsettings_SCHEMAS) $(gsettings__enum_file)'\''; test -n "$(gsettingsschemadir)" || list=; \
695 files=`for p in $$list; do echo $$p; done | sed -e '\''s|^.*/||'\''`; \
696 test -n "$$files" || exit 0; \
697 echo " ( cd '\''$(DESTDIR)$(gsettingsschemadir)'\'' && rm -f" $$files ")"; \
698 cd "$(DESTDIR)$(gsettingsschemadir)" && rm -f $$files
699 test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir)
701 clean-gsettings-schemas:
702 rm -f $(gsettings_SCHEMAS:.xml=.valid) $(gsettings__enum_file)
704 ifdef gsettings_ENUM_NAMESPACE
705 $(gsettings__enum_file): $(gsettings_ENUM_FILES)
706 $(AM_V_GEN) glib-mkenums --comments '\''<!-- @comment@ -->'\'' --fhead "<schemalist>" --vhead " <@type@ id='\''$(gsettings_ENUM_NAMESPACE).@EnumName@'\''>" --vprod " <value nick='\''@valuenick@'\'' value='\''@valuenum@'\''/>" --vtail " </@type@>" --ftail "</schemalist>" [$]^ > [$]@.tmp && mv [$]@.tmp [$]@
709 _GSETTINGS_SUBST(GSETTINGS_RULES)
712 dnl _GSETTINGS_SUBST(VARIABLE)
713 dnl Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
714 AC_DEFUN([_GSETTINGS_SUBST],
717 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
721 dnl -*- mode: autoconf -*-
726 dnl GTK_DOC_CHECK([minimum-gtk-doc-version])
727 AC_DEFUN([GTK_DOC_CHECK],
729 AC_REQUIRE([PKG_PROG_PKG_CONFIG])
730 AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
731 AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
733 ifelse([$1],[],[gtk_doc_requires="gtk-doc"],[gtk_doc_requires="gtk-doc >= $1"])
734 AC_MSG_CHECKING([for gtk-doc])
735 PKG_CHECK_EXISTS([$gtk_doc_requires],[have_gtk_doc=yes],[have_gtk_doc=no])
736 AC_MSG_RESULT($have_gtk_doc)
738 if test "$have_gtk_doc" = "no"; then
740 You will not be able to create source packages with 'make dist'
741 because $gtk_doc_requires is not found.])
744 dnl check for tools we added during development
745 dnl Use AC_CHECK_PROG to avoid the check target using an absolute path that
746 dnl may not be writable by the user. Currently, automake requires that the
747 dnl test name must end in '.test'.
748 dnl https://bugzilla.gnome.org/show_bug.cgi?id=701638
749 AC_CHECK_PROG([GTKDOC_CHECK],[gtkdoc-check],[gtkdoc-check.test])
750 AC_PATH_PROG([GTKDOC_CHECK_PATH],[gtkdoc-check])
751 AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true])
752 AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf])
754 dnl for overriding the documentation installation directory
755 AC_ARG_WITH([html-dir],
756 AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
757 [with_html_dir='${datadir}/gtk-doc/html'])
758 HTML_DIR="$with_html_dir"
761 dnl enable/disable documentation building
762 AC_ARG_ENABLE([gtk-doc],
763 AS_HELP_STRING([--enable-gtk-doc],
764 [use gtk-doc to build documentation [[default=no]]]),,
767 AC_MSG_CHECKING([whether to build gtk-doc documentation])
768 AC_MSG_RESULT($enable_gtk_doc)
770 if test "x$enable_gtk_doc" = "xyes" && test "$have_gtk_doc" = "no"; then
772 You must have $gtk_doc_requires installed to build documentation for
773 $PACKAGE_NAME. Please install gtk-doc or disable building the
774 documentation by adding '--disable-gtk-doc' to '[$]0'.])
777 dnl don't check for glib if we build glib
778 if test "x$PACKAGE_NAME" != "xglib"; then
779 dnl don't fail if someone does not have glib
780 PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0,,[:])
783 dnl enable/disable output formats
784 AC_ARG_ENABLE([gtk-doc-html],
785 AS_HELP_STRING([--enable-gtk-doc-html],
786 [build documentation in html format [[default=yes]]]),,
787 [enable_gtk_doc_html=yes])
788 AC_ARG_ENABLE([gtk-doc-pdf],
789 AS_HELP_STRING([--enable-gtk-doc-pdf],
790 [build documentation in pdf format [[default=no]]]),,
791 [enable_gtk_doc_pdf=no])
793 if test -z "$GTKDOC_MKPDF"; then
794 enable_gtk_doc_pdf=no
797 if test -z "$AM_DEFAULT_VERBOSITY"; then
798 AM_DEFAULT_VERBOSITY=1
800 AC_SUBST([AM_DEFAULT_VERBOSITY])
802 AM_CONDITIONAL([HAVE_GTK_DOC], [test x$have_gtk_doc = xyes])
803 AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
804 AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
805 AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])
806 AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"])
807 AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"])
811 dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
812 # serial 42 IT_PROG_INTLTOOL
813 AC_DEFUN([IT_PROG_INTLTOOL], [
815 AC_REQUIRE([AM_NLS])dnl
817 case "$am__api_version" in
819 AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
825 INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
826 INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
827 INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
828 if test -n "$1"; then
829 AC_MSG_CHECKING([for intltool >= $1])
830 AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
831 test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
832 AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.])
835 AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
836 AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
837 AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
838 if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
839 AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
842 if test -z "$AM_DEFAULT_VERBOSITY"; then
843 AM_DEFAULT_VERBOSITY=1
845 AC_SUBST([AM_DEFAULT_VERBOSITY])
847 INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
848 INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
849 INTLTOOL__v_MERGE_0='@echo " ITMRG " [$]@;'
850 AC_SUBST(INTLTOOL_V_MERGE)
851 AC_SUBST(INTLTOOL__v_MERGE_)
852 AC_SUBST(INTLTOOL__v_MERGE_0)
854 INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
855 intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
856 intltool__v_merge_options_0='-q'
857 AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
858 AC_SUBST(intltool__v_merge_options_)
859 AC_SUBST(intltool__v_merge_options_0)
861 INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
862 INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
863 INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
864 INTLTOOL_PROP_RULE='%.prop: %.prop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
865 INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -p $(top_srcdir)/po $< [$]@'
866 INTLTOOL_PONG_RULE='%.pong: %.pong.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
867 INTLTOOL_SERVER_RULE='%.server: %.server.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
868 INTLTOOL_SHEET_RULE='%.sheet: %.sheet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
869 INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
870 INTLTOOL_UI_RULE='%.ui: %.ui.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
871 INTLTOOL_XML_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
872 if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
873 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u --no-translations $< [$]@'
875 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)_it_tmp_dir=tmp.intltool.[$][$]RANDOM && mkdir [$][$]_it_tmp_dir && LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u [$][$]_it_tmp_dir $< [$]@ && rmdir [$][$]_it_tmp_dir'
877 INTLTOOL_XAM_RULE='%.xam: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
878 INTLTOOL_KBD_RULE='%.kbd: %.kbd.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
879 INTLTOOL_CAVES_RULE='%.caves: %.caves.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
880 INTLTOOL_SCHEMAS_RULE='%.schemas: %.schemas.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
881 INTLTOOL_THEME_RULE='%.theme: %.theme.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
882 INTLTOOL_SERVICE_RULE='%.service: %.service.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
883 INTLTOOL_POLICY_RULE='%.policy: %.policy.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
885 _IT_SUBST(INTLTOOL_DESKTOP_RULE)
886 _IT_SUBST(INTLTOOL_DIRECTORY_RULE)
887 _IT_SUBST(INTLTOOL_KEYS_RULE)
888 _IT_SUBST(INTLTOOL_PROP_RULE)
889 _IT_SUBST(INTLTOOL_OAF_RULE)
890 _IT_SUBST(INTLTOOL_PONG_RULE)
891 _IT_SUBST(INTLTOOL_SERVER_RULE)
892 _IT_SUBST(INTLTOOL_SHEET_RULE)
893 _IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
894 _IT_SUBST(INTLTOOL_UI_RULE)
895 _IT_SUBST(INTLTOOL_XAM_RULE)
896 _IT_SUBST(INTLTOOL_KBD_RULE)
897 _IT_SUBST(INTLTOOL_XML_RULE)
898 _IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
899 _IT_SUBST(INTLTOOL_CAVES_RULE)
900 _IT_SUBST(INTLTOOL_SCHEMAS_RULE)
901 _IT_SUBST(INTLTOOL_THEME_RULE)
902 _IT_SUBST(INTLTOOL_SERVICE_RULE)
903 _IT_SUBST(INTLTOOL_POLICY_RULE)
905 # Check the gettext tools to make sure they are GNU
906 AC_PATH_PROG(XGETTEXT, xgettext)
907 AC_PATH_PROG(MSGMERGE, msgmerge)
908 AC_PATH_PROG(MSGFMT, msgfmt)
909 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
910 if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
911 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
913 xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
914 mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
915 mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
916 if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
917 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
920 AC_PATH_PROG(INTLTOOL_PERL, perl)
921 if test -z "$INTLTOOL_PERL"; then
922 AC_MSG_ERROR([perl not found])
924 AC_MSG_CHECKING([for perl >= 5.8.1])
925 $INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
926 if test $? -ne 0; then
927 AC_MSG_ERROR([perl 5.8.1 is required for intltool])
929 IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
930 AC_MSG_RESULT([$IT_PERL_VERSION])
932 if test "x$2" != "xno-xml"; then
933 AC_MSG_CHECKING([for XML::Parser])
934 if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
937 AC_MSG_ERROR([XML::Parser perl module is required for intltool])
941 # Substitute ALL_LINGUAS so we can use it in po/Makefile
942 AC_SUBST(ALL_LINGUAS)
949 # IT_PO_SUBDIR(DIRNAME)
950 # ---------------------
951 # All po subdirs have to be declared with this macro; the subdir "po" is
952 # declared by IT_PROG_INTLTOOL.
954 AC_DEFUN([IT_PO_SUBDIR],
955 [AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
957 dnl The following CONFIG_COMMANDS should be executed at the very end
958 dnl of config.status.
959 AC_CONFIG_COMMANDS_PRE([
960 AC_CONFIG_COMMANDS([$1/stamp-it], [
961 if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
962 AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
964 rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
969 '"s|^| $ac_top_srcdir/|" \
970 "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
972 [sed '/^POTFILES =/,/[^\\]$/ {
976 ' "$1/Makefile.in" >"$1/Makefile"]
977 rm -f "$1/Makefile.tmp"
978 mv "$1/stamp-it.tmp" "$1/stamp-it"
983 # _IT_SUBST(VARIABLE)
984 # -------------------
985 # Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
987 AC_DEFUN([_IT_SUBST],
990 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
995 AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
996 # A hint is needed for aclocal from Automake <= 1.9.4:
997 # AC_DEFUN([AC_PROG_INTLTOOL], ...)
1000 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
1002 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1003 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
1005 # Written by Gordon Matzigkeit, 1996
1007 # This file is free software; the Free Software Foundation gives
1008 # unlimited permission to copy and/or distribute it, with or without
1009 # modifications, as long as this notice is preserved.
1011 m4_define([_LT_COPYING], [dnl
1012 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
1013 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
1015 # Written by Gordon Matzigkeit, 1996
1017 # This file is part of GNU Libtool.
1019 # GNU Libtool is free software; you can redistribute it and/or
1020 # modify it under the terms of the GNU General Public License as
1021 # published by the Free Software Foundation; either version 2 of
1022 # the License, or (at your option) any later version.
1024 # As a special exception to the GNU General Public License,
1025 # if you distribute this file as part of a program or library that
1026 # is built using GNU Libtool, you may include this file under the
1027 # same distribution terms that you use for the rest of that program.
1029 # GNU Libtool is distributed in the hope that it will be useful,
1030 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1031 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1032 # GNU General Public License for more details.
1034 # You should have received a copy of the GNU General Public License
1035 # along with GNU Libtool; see the file COPYING. If not, a copy
1036 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
1037 # obtained by writing to the Free Software Foundation, Inc.,
1038 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1044 # LT_PREREQ(VERSION)
1045 # ------------------
1046 # Complain and exit if this libtool version is less that VERSION.
1047 m4_defun([LT_PREREQ],
1048 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
1050 [m4_fatal([Libtool version $1 or higher is required],
1055 # _LT_CHECK_BUILDDIR
1056 # ------------------
1057 # Complain if the absolute build directory name contains unusual characters
1058 m4_defun([_LT_CHECK_BUILDDIR],
1061 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
1066 # LT_INIT([OPTIONS])
1067 # ------------------
1069 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
1070 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
1071 AC_BEFORE([$0], [LT_LANG])dnl
1072 AC_BEFORE([$0], [LT_OUTPUT])dnl
1073 AC_BEFORE([$0], [LTDL_INIT])dnl
1074 m4_require([_LT_CHECK_BUILDDIR])dnl
1076 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
1077 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
1078 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
1079 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
1080 dnl unless we require an AC_DEFUNed macro:
1081 AC_REQUIRE([LTOPTIONS_VERSION])dnl
1082 AC_REQUIRE([LTSUGAR_VERSION])dnl
1083 AC_REQUIRE([LTVERSION_VERSION])dnl
1084 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
1085 m4_require([_LT_PROG_LTMAIN])dnl
1087 _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
1090 _LT_SET_OPTIONS([$0], [$1])
1092 # This can be used to rebuild libtool when needed
1093 LIBTOOL_DEPS="$ltmain"
1095 # Always use our own libtool.
1096 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1097 AC_SUBST(LIBTOOL)dnl
1102 m4_define([LT_INIT])
1106 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
1107 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
1108 dnl aclocal-1.4 backwards compatibility:
1109 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
1110 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
1113 # _LT_CC_BASENAME(CC)
1114 # -------------------
1115 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
1116 m4_defun([_LT_CC_BASENAME],
1117 [for cc_temp in $1""; do
1119 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1120 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1125 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
1129 # _LT_FILEUTILS_DEFAULTS
1130 # ----------------------
1131 # It is okay to use these file commands and assume they have been set
1132 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
1133 m4_defun([_LT_FILEUTILS_DEFAULTS],
1137 ])# _LT_FILEUTILS_DEFAULTS
1142 m4_defun([_LT_SETUP],
1143 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1144 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1145 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
1146 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
1148 _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
1150 _LT_DECL([], [host_alias], [0], [The host system])dnl
1151 _LT_DECL([], [host], [0])dnl
1152 _LT_DECL([], [host_os], [0])dnl
1154 _LT_DECL([], [build_alias], [0], [The build system])dnl
1155 _LT_DECL([], [build], [0])dnl
1156 _LT_DECL([], [build_os], [0])dnl
1158 AC_REQUIRE([AC_PROG_CC])dnl
1159 AC_REQUIRE([LT_PATH_LD])dnl
1160 AC_REQUIRE([LT_PATH_NM])dnl
1162 AC_REQUIRE([AC_PROG_LN_S])dnl
1163 test -z "$LN_S" && LN_S="ln -s"
1164 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
1166 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
1167 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
1168 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
1170 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1171 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
1172 m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
1173 m4_require([_LT_CMD_RELOAD])dnl
1174 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
1175 m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
1176 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
1177 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
1178 m4_require([_LT_WITH_SYSROOT])dnl
1180 _LT_CONFIG_LIBTOOL_INIT([
1181 # See if we are running on zsh, and set the options which allow our
1182 # commands through without removal of \ escapes INIT.
1183 if test -n "\${ZSH_VERSION+set}" ; then
1184 setopt NO_GLOB_SUBST
1187 if test -n "${ZSH_VERSION+set}" ; then
1188 setopt NO_GLOB_SUBST
1193 m4_require([_LT_TAG_COMPILER])dnl
1197 # AIX sometimes has problems with the GCC collect2 program. For some
1198 # reason, if we set the COLLECT_NAMES environment variable, the problems
1199 # vanish in a puff of smoke.
1200 if test "X${COLLECT_NAMES+set}" != Xset; then
1202 export COLLECT_NAMES
1209 can_build_shared=yes
1211 # All known linkers require a `.a' archive for static linking (except MSVC,
1212 # which needs '.lib').
1215 with_gnu_ld="$lt_cv_prog_gnu_ld"
1218 old_CFLAGS="$CFLAGS"
1220 # Set sane defaults for various variables
1221 test -z "$CC" && CC=cc
1222 test -z "$LTCC" && LTCC=$CC
1223 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1224 test -z "$LD" && LD=ld
1225 test -z "$ac_objext" && ac_objext=o
1227 _LT_CC_BASENAME([$compiler])
1229 # Only perform the check for file, if the check method requires it
1230 test -z "$MAGIC_CMD" && MAGIC_CMD=file
1231 case $deplibs_check_method in
1233 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1239 # Use C for the default configuration in the libtool script
1240 LT_SUPPORTED_TAG([CC])
1242 _LT_LANG_DEFAULT_CONFIG
1247 # _LT_PREPARE_SED_QUOTE_VARS
1248 # --------------------------
1249 # Define a few sed substitution that help us do robust quoting.
1250 m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
1251 [# Backslashify metacharacters that are still active within
1252 # double-quoted strings.
1253 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
1255 # Same as above, but do not quote variable references.
1256 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
1258 # Sed substitution to delay expansion of an escaped shell variable in a
1259 # double_quote_subst'ed string.
1260 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1262 # Sed substitution to delay expansion of an escaped single quote.
1263 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
1265 # Sed substitution to avoid accidental globbing in evaled expressions
1266 no_glob_subst='s/\*/\\\*/g'
1271 # Note that this code is called both from `configure', and `config.status'
1272 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
1273 # `config.status' has no value for ac_aux_dir unless we are using Automake,
1274 # so we pass a copy along to make sure it has a sensible value anyway.
1275 m4_defun([_LT_PROG_LTMAIN],
1276 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
1277 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
1278 ltmain="$ac_aux_dir/ltmain.sh"
1283 # So that we can recreate a full libtool script including additional
1284 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
1285 # in macros and then make a single call at the end using the `libtool'
1289 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
1290 # ----------------------------------------
1291 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1292 m4_define([_LT_CONFIG_LIBTOOL_INIT],
1294 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
1299 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
1302 # _LT_CONFIG_LIBTOOL([COMMANDS])
1303 # ------------------------------
1304 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1305 m4_define([_LT_CONFIG_LIBTOOL],
1307 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
1312 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
1315 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
1316 # -----------------------------------------------------
1317 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
1318 [_LT_CONFIG_LIBTOOL([$1])
1319 _LT_CONFIG_LIBTOOL_INIT([$2])
1323 # _LT_FORMAT_COMMENT([COMMENT])
1324 # -----------------------------
1325 # Add leading comment marks to the start of each line, and a trailing
1326 # full-stop to the whole comment if one is not present already.
1327 m4_define([_LT_FORMAT_COMMENT],
1329 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
1330 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
1337 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
1338 # -------------------------------------------------------------------
1339 # CONFIGNAME is the name given to the value in the libtool script.
1340 # VARNAME is the (base) name used in the configure script.
1341 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
1342 # VARNAME. Any other value will be used directly.
1343 m4_define([_LT_DECL],
1344 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
1345 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
1346 [m4_ifval([$1], [$1], [$2])])
1347 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
1349 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
1350 lt_dict_add_subkey([lt_decl_dict], [$2],
1351 [tagged?], [m4_ifval([$5], [yes], [no])])])
1355 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
1356 # --------------------------------------------------------
1357 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
1360 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
1361 # ------------------------------------------------
1362 m4_define([lt_decl_tag_varnames],
1363 [_lt_decl_filter([tagged?], [yes], $@)])
1366 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
1367 # ---------------------------------------------------------
1368 m4_define([_lt_decl_filter],
1370 [0], [m4_fatal([$0: too few arguments: $#])],
1371 [1], [m4_fatal([$0: too few arguments: $#: $1])],
1372 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
1373 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
1374 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
1378 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
1379 # --------------------------------------------------
1380 m4_define([lt_decl_quote_varnames],
1381 [_lt_decl_filter([value], [1], $@)])
1384 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
1385 # ---------------------------------------------------
1386 m4_define([lt_decl_dquote_varnames],
1387 [_lt_decl_filter([value], [2], $@)])
1390 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
1391 # ---------------------------------------------------
1392 m4_define([lt_decl_varnames_tagged],
1393 [m4_assert([$# <= 2])dnl
1394 _$0(m4_quote(m4_default([$1], [[, ]])),
1395 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
1396 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
1397 m4_define([_lt_decl_varnames_tagged],
1398 [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
1401 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
1402 # ------------------------------------------------
1403 m4_define([lt_decl_all_varnames],
1404 [_$0(m4_quote(m4_default([$1], [[, ]])),
1406 m4_quote(lt_decl_varnames),
1407 m4_quote(m4_shift($@))))[]dnl
1409 m4_define([_lt_decl_all_varnames],
1410 [lt_join($@, lt_decl_varnames_tagged([$1],
1411 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
1415 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
1416 # ------------------------------------
1417 # Quote a variable value, and forward it to `config.status' so that its
1418 # declaration there will have the same value as in `configure'. VARNAME
1419 # must have a single quote delimited value for this to work.
1420 m4_define([_LT_CONFIG_STATUS_DECLARE],
1421 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
1424 # _LT_CONFIG_STATUS_DECLARATIONS
1425 # ------------------------------
1426 # We delimit libtool config variables with single quotes, so when
1427 # we write them to config.status, we have to be sure to quote all
1428 # embedded single quotes properly. In configure, this macro expands
1429 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
1431 # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
1432 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
1433 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
1434 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
1439 # Output comment and list of tags supported by the script
1440 m4_defun([_LT_LIBTOOL_TAGS],
1441 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
1442 available_tags="_LT_TAGS"dnl
1446 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
1447 # -----------------------------------
1448 # Extract the dictionary values for VARNAME (optionally with TAG) and
1449 # expand to a commented shell variable setting:
1451 # # Some comment about what VAR is for.
1452 # visible_name=$lt_internal_name
1453 m4_define([_LT_LIBTOOL_DECLARE],
1454 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
1455 [description])))[]dnl
1456 m4_pushdef([_libtool_name],
1457 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
1458 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
1459 [0], [_libtool_name=[$]$1],
1460 [1], [_libtool_name=$lt_[]$1],
1461 [2], [_libtool_name=$lt_[]$1],
1462 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
1463 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
1467 # _LT_LIBTOOL_CONFIG_VARS
1468 # -----------------------
1469 # Produce commented declarations of non-tagged libtool config variables
1470 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
1471 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
1472 # section) are produced by _LT_LIBTOOL_TAG_VARS.
1473 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
1474 [m4_foreach([_lt_var],
1475 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
1476 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
1479 # _LT_LIBTOOL_TAG_VARS(TAG)
1480 # -------------------------
1481 m4_define([_LT_LIBTOOL_TAG_VARS],
1482 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
1483 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
1486 # _LT_TAGVAR(VARNAME, [TAGNAME])
1487 # ------------------------------
1488 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
1491 # _LT_CONFIG_COMMANDS
1492 # -------------------
1493 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
1494 # variables for single and double quote escaping we saved from calls
1495 # to _LT_DECL, we can put quote escaped variables declarations
1496 # into `config.status', and then the shell code to quote escape them in
1497 # for loops in `config.status'. Finally, any additional code accumulated
1498 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
1499 m4_defun([_LT_CONFIG_COMMANDS],
1500 [AC_PROVIDE_IFELSE([LT_OUTPUT],
1501 dnl If the libtool generation code has been placed in $CONFIG_LT,
1502 dnl instead of duplicating it all over again into config.status,
1503 dnl then we will have config.status run $CONFIG_LT later, so it
1504 dnl needs to know what name is stored there:
1505 [AC_CONFIG_COMMANDS([libtool],
1506 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
1507 dnl If the libtool generation code is destined for config.status,
1508 dnl expand the accumulated commands and init code now:
1509 [AC_CONFIG_COMMANDS([libtool],
1510 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
1511 ])#_LT_CONFIG_COMMANDS
1515 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
1518 # The HP-UX ksh and POSIX shell print the target directory to stdout
1520 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1522 sed_quote_subst='$sed_quote_subst'
1523 double_quote_subst='$double_quote_subst'
1524 delay_variable_subst='$delay_variable_subst'
1525 _LT_CONFIG_STATUS_DECLARATIONS
1527 LTCFLAGS='$LTCFLAGS'
1528 compiler='$compiler_DEFAULT'
1530 # A function that is used when there is no print builtin or printf.
1531 func_fallback_echo ()
1533 eval 'cat <<_LTECHO_EOF
1538 # Quote evaled strings.
1539 for var in lt_decl_all_varnames([[ \
1540 ]], lt_decl_quote_varnames); do
1541 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1542 *[[\\\\\\\`\\"\\\$]]*)
1543 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1546 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1551 # Double-quote double-evaled strings.
1552 for var in lt_decl_all_varnames([[ \
1553 ]], lt_decl_dquote_varnames); do
1554 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1555 *[[\\\\\\\`\\"\\\$]]*)
1556 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1559 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1564 _LT_OUTPUT_LIBTOOL_INIT
1567 # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
1568 # ------------------------------------
1569 # Generate a child script FILE with all initialization necessary to
1570 # reuse the environment learned by the parent script, and make the
1571 # file executable. If COMMENT is supplied, it is inserted after the
1572 # `#!' sequence but before initialization text begins. After this
1573 # macro, additional text can be appended to FILE to form the body of
1574 # the child script. The macro ends with non-zero status if the
1575 # file could not be fully written (such as if the disk is full).
1576 m4_ifdef([AS_INIT_GENERATED],
1577 [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
1578 [m4_defun([_LT_GENERATED_FILE_INIT],
1579 [m4_require([AS_PREPARE])]dnl
1580 [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
1582 cat >$1 <<_ASEOF || lt_write_fail=1
1584 # Generated by $as_me.
1586 SHELL=\${CONFIG_SHELL-$SHELL}
1589 cat >>$1 <<\_ASEOF || lt_write_fail=1
1592 exec AS_MESSAGE_FD>&1
1594 test $lt_write_fail = 0 && chmod +x $1[]dnl
1595 m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
1599 # This macro allows early generation of the libtool script (before
1600 # AC_OUTPUT is called), incase it is used in configure for compilation
1602 AC_DEFUN([LT_OUTPUT],
1603 [: ${CONFIG_LT=./config.lt}
1604 AC_MSG_NOTICE([creating $CONFIG_LT])
1605 _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
1606 [# Run this file to recreate a libtool stub with the current configuration.])
1608 cat >>"$CONFIG_LT" <<\_LTEOF
1610 exec AS_MESSAGE_LOG_FD>>config.log
1613 AS_BOX([Running $as_me.])
1614 } >&AS_MESSAGE_LOG_FD
1617 \`$as_me' creates a local libtool stub from the current configuration,
1618 for use in further configure time tests before the real libtool is
1621 Usage: $[0] [[OPTIONS]]
1623 -h, --help print this help, then exit
1624 -V, --version print version number, then exit
1625 -q, --quiet do not print progress messages
1626 -d, --debug don't remove temporary files
1628 Report bugs to <bug-libtool@gnu.org>."
1631 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1632 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1633 configured by $[0], generated by m4_PACKAGE_STRING.
1635 Copyright (C) 2011 Free Software Foundation, Inc.
1636 This config.lt script is free software; the Free Software Foundation
1637 gives unlimited permision to copy, distribute and modify it."
1639 while test $[#] != 0
1642 --version | --v* | -V )
1643 echo "$lt_cl_version"; exit 0 ;;
1644 --help | --h* | -h )
1645 echo "$lt_cl_help"; exit 0 ;;
1646 --debug | --d* | -d )
1648 --quiet | --q* | --silent | --s* | -q )
1651 -*) AC_MSG_ERROR([unrecognized option: $[1]
1652 Try \`$[0] --help' for more information.]) ;;
1654 *) AC_MSG_ERROR([unrecognized argument: $[1]
1655 Try \`$[0] --help' for more information.]) ;;
1660 if $lt_cl_silent; then
1661 exec AS_MESSAGE_FD>/dev/null
1665 cat >>"$CONFIG_LT" <<_LTEOF
1666 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1669 cat >>"$CONFIG_LT" <<\_LTEOF
1670 AC_MSG_NOTICE([creating $ofile])
1671 _LT_OUTPUT_LIBTOOL_COMMANDS
1674 chmod +x "$CONFIG_LT"
1676 # configure is writing to config.log, but config.lt does its own redirection,
1677 # appending to config.log, which fails on DOS, as config.log is still kept
1678 # open by configure. Here we exec the FD to /dev/null, effectively closing
1679 # config.log, so it can be properly (re)opened and appended to by config.lt.
1681 test "$silent" = yes &&
1682 lt_config_lt_args="$lt_config_lt_args --quiet"
1683 exec AS_MESSAGE_LOG_FD>/dev/null
1684 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
1685 exec AS_MESSAGE_LOG_FD>>config.log
1686 $lt_cl_success || AS_EXIT(1)
1692 # If TAG is the built-in tag, create an initial libtool script with a
1693 # default configuration from the untagged config vars. Otherwise add code
1694 # to config.status for appending the configuration named by TAG from the
1695 # matching tagged config vars.
1696 m4_defun([_LT_CONFIG],
1697 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1698 _LT_CONFIG_SAVE_COMMANDS([
1699 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
1700 m4_if(_LT_TAG, [C], [
1701 # See if we are running on zsh, and set the options which allow our
1702 # commands through without removal of \ escapes.
1703 if test -n "${ZSH_VERSION+set}" ; then
1704 setopt NO_GLOB_SUBST
1708 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
1711 cat <<_LT_EOF >> "$cfgfile"
1714 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
1715 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
1716 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1717 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
1722 # ### BEGIN LIBTOOL CONFIG
1723 _LT_LIBTOOL_CONFIG_VARS
1724 _LT_LIBTOOL_TAG_VARS
1725 # ### END LIBTOOL CONFIG
1731 cat <<\_LT_EOF >> "$cfgfile"
1732 # AIX sometimes has problems with the GCC collect2 program. For some
1733 # reason, if we set the COLLECT_NAMES environment variable, the problems
1734 # vanish in a puff of smoke.
1735 if test "X${COLLECT_NAMES+set}" != Xset; then
1737 export COLLECT_NAMES
1745 # We use sed instead of cat because bash on DJGPP gets confused if
1746 # if finds mixed CR/LF and LF-only lines. Since sed operates in
1747 # text mode, it properly converts lines to CR/LF. This bash problem
1748 # is reportedly fixed, but why not run on old versions too?
1749 sed '$q' "$ltmain" >> "$cfgfile" \
1750 || (rm -f "$cfgfile"; exit 1)
1752 _LT_PROG_REPLACE_SHELLFNS
1754 mv -f "$cfgfile" "$ofile" ||
1755 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
1758 [cat <<_LT_EOF >> "$ofile"
1760 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
1761 dnl in a comment (ie after a #).
1762 # ### BEGIN LIBTOOL TAG CONFIG: $1
1763 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
1764 # ### END LIBTOOL TAG CONFIG: $1
1771 TIMESTAMP='$TIMESTAMP'
1773 ofile='$ofile'], [])
1774 ])dnl /_LT_CONFIG_SAVE_COMMANDS
1778 # LT_SUPPORTED_TAG(TAG)
1779 # ---------------------
1780 # Trace this macro to discover what tags are supported by the libtool
1781 # --tag option, using:
1782 # autoconf --trace 'LT_SUPPORTED_TAG:$1'
1783 AC_DEFUN([LT_SUPPORTED_TAG], [])
1786 # C support is built-in for now
1787 m4_define([_LT_LANG_C_enabled], [])
1788 m4_define([_LT_TAGS], [])
1793 # Enable libtool support for the given language if not already enabled.
1795 [AC_BEFORE([$0], [LT_OUTPUT])dnl
1798 [C++], [_LT_LANG(CXX)],
1799 [Go], [_LT_LANG(GO)],
1800 [Java], [_LT_LANG(GCJ)],
1801 [Fortran 77], [_LT_LANG(F77)],
1802 [Fortran], [_LT_LANG(FC)],
1803 [Windows Resource], [_LT_LANG(RC)],
1804 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
1806 [m4_fatal([$0: unsupported language: "$1"])])])dnl
1810 # _LT_LANG(LANGNAME)
1811 # ------------------
1812 m4_defun([_LT_LANG],
1813 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
1814 [LT_SUPPORTED_TAG([$1])dnl
1815 m4_append([_LT_TAGS], [$1 ])dnl
1816 m4_define([_LT_LANG_]$1[_enabled], [])dnl
1817 _LT_LANG_$1_CONFIG($1)])dnl
1821 m4_ifndef([AC_PROG_GO], [
1822 # NOTE: This macro has been submitted for inclusion into #
1823 # GNU Autoconf as AC_PROG_GO. When it is available in #
1824 # a released version of Autoconf we should remove this #
1825 # macro and use it instead. #
1826 m4_defun([AC_PROG_GO],
1827 [AC_LANG_PUSH(Go)dnl
1828 AC_ARG_VAR([GOC], [Go compiler command])dnl
1829 AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
1830 _AC_ARG_VAR_LDFLAGS()dnl
1831 AC_CHECK_TOOL(GOC, gccgo)
1832 if test -z "$GOC"; then
1833 if test -n "$ac_tool_prefix"; then
1834 AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
1837 if test -z "$GOC"; then
1838 AC_CHECK_PROG(GOC, gccgo, gccgo, false)
1844 # _LT_LANG_DEFAULT_CONFIG
1845 # -----------------------
1846 m4_defun([_LT_LANG_DEFAULT_CONFIG],
1847 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
1849 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
1851 AC_PROVIDE_IFELSE([AC_PROG_F77],
1853 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
1855 AC_PROVIDE_IFELSE([AC_PROG_FC],
1857 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
1859 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
1860 dnl pulling things in needlessly.
1861 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1863 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1865 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
1867 [m4_ifdef([AC_PROG_GCJ],
1868 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
1869 m4_ifdef([A][M_PROG_GCJ],
1870 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
1871 m4_ifdef([LT_PROG_GCJ],
1872 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
1874 AC_PROVIDE_IFELSE([AC_PROG_GO],
1876 [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
1878 AC_PROVIDE_IFELSE([LT_PROG_RC],
1880 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
1881 ])# _LT_LANG_DEFAULT_CONFIG
1884 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1885 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1886 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1887 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1888 AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
1889 dnl aclocal-1.4 backwards compatibility:
1890 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1891 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1892 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1893 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1894 dnl AC_DEFUN([AC_LIBTOOL_RC], [])
1899 m4_defun([_LT_TAG_COMPILER],
1900 [AC_REQUIRE([AC_PROG_CC])dnl
1902 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1903 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1904 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1905 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1907 # If no C compiler was specified, use CC.
1910 # If no C compiler flags were specified, use CFLAGS.
1911 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1913 # Allow CC to be a program name with arguments.
1915 ])# _LT_TAG_COMPILER
1918 # _LT_COMPILER_BOILERPLATE
1919 # ------------------------
1920 # Check for compiler boilerplate output or warnings with
1921 # the simple compiler test code.
1922 m4_defun([_LT_COMPILER_BOILERPLATE],
1923 [m4_require([_LT_DECL_SED])dnl
1924 ac_outfile=conftest.$ac_objext
1925 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1926 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1927 _lt_compiler_boilerplate=`cat conftest.err`
1929 ])# _LT_COMPILER_BOILERPLATE
1932 # _LT_LINKER_BOILERPLATE
1933 # ----------------------
1934 # Check for linker boilerplate output or warnings with
1935 # the simple link test code.
1936 m4_defun([_LT_LINKER_BOILERPLATE],
1937 [m4_require([_LT_DECL_SED])dnl
1938 ac_outfile=conftest.$ac_objext
1939 echo "$lt_simple_link_test_code" >conftest.$ac_ext
1940 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1941 _lt_linker_boilerplate=`cat conftest.err`
1943 ])# _LT_LINKER_BOILERPLATE
1945 # _LT_REQUIRED_DARWIN_CHECKS
1946 # -------------------------
1947 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1949 rhapsody* | darwin*)
1950 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1951 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1952 AC_CHECK_TOOL([LIPO], [lipo], [:])
1953 AC_CHECK_TOOL([OTOOL], [otool], [:])
1954 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1955 _LT_DECL([], [DSYMUTIL], [1],
1956 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1957 _LT_DECL([], [NMEDIT], [1],
1958 [Tool to change global to local symbols on Mac OS X])
1959 _LT_DECL([], [LIPO], [1],
1960 [Tool to manipulate fat objects and archives on Mac OS X])
1961 _LT_DECL([], [OTOOL], [1],
1962 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1963 _LT_DECL([], [OTOOL64], [1],
1964 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1966 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1967 [lt_cv_apple_cc_single_mod=no
1968 if test -z "${LT_MULTI_MODULE}"; then
1969 # By default we will add the -single_module flag. You can override
1970 # by either setting the environment variable LT_MULTI_MODULE
1971 # non-empty at configure time, or by adding -multi_module to the
1973 rm -rf libconftest.dylib*
1974 echo "int foo(void){return 1;}" > conftest.c
1975 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1976 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1977 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1978 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1980 # If there is a non-empty error log, and "single_module"
1981 # appears in it, assume the flag caused a linker warning
1982 if test -s conftest.err && $GREP single_module conftest.err; then
1983 cat conftest.err >&AS_MESSAGE_LOG_FD
1984 # Otherwise, if the output was created with a 0 exit code from
1985 # the compiler, it worked.
1986 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
1987 lt_cv_apple_cc_single_mod=yes
1989 cat conftest.err >&AS_MESSAGE_LOG_FD
1991 rm -rf libconftest.dylib*
1995 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1996 [lt_cv_ld_exported_symbols_list],
1997 [lt_cv_ld_exported_symbols_list=no
1998 save_LDFLAGS=$LDFLAGS
1999 echo "_main" > conftest.sym
2000 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
2001 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2002 [lt_cv_ld_exported_symbols_list=yes],
2003 [lt_cv_ld_exported_symbols_list=no])
2004 LDFLAGS="$save_LDFLAGS"
2007 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
2008 [lt_cv_ld_force_load=no
2009 cat > conftest.c << _LT_EOF
2010 int forced_loaded() { return 2;}
2012 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
2013 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
2014 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
2015 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
2016 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
2017 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
2018 cat > conftest.c << _LT_EOF
2019 int main() { return 0;}
2021 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
2022 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
2024 if test -s conftest.err && $GREP force_load conftest.err; then
2025 cat conftest.err >&AS_MESSAGE_LOG_FD
2026 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
2027 lt_cv_ld_force_load=yes
2029 cat conftest.err >&AS_MESSAGE_LOG_FD
2031 rm -f conftest.err libconftest.a conftest conftest.c
2032 rm -rf conftest.dSYM
2035 rhapsody* | darwin1.[[012]])
2036 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
2038 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2039 darwin*) # darwin 5.x on
2040 # if running on 10.5 or later, the deployment target defaults
2041 # to the OS version, if on x86, and 10.4, the deployment
2042 # target defaults to 10.4. Don't you love it?
2043 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
2044 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
2045 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2047 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2049 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2053 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
2054 _lt_dar_single_mod='$single_module'
2056 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
2057 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
2059 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
2061 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
2062 _lt_dsymutil='~$DSYMUTIL $lib || :'
2071 # _LT_DARWIN_LINKER_FEATURES([TAG])
2072 # ---------------------------------
2073 # Checks for linker and compiler features on darwin
2074 m4_defun([_LT_DARWIN_LINKER_FEATURES],
2076 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
2077 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
2078 _LT_TAGVAR(hardcode_direct, $1)=no
2079 _LT_TAGVAR(hardcode_automatic, $1)=yes
2080 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2081 if test "$lt_cv_ld_force_load" = "yes"; then
2082 _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\"`'
2083 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
2084 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
2086 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
2088 _LT_TAGVAR(link_all_deplibs, $1)=yes
2089 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
2090 case $cc_basename in
2091 ifort*) _lt_dar_can_shared=yes ;;
2092 *) _lt_dar_can_shared=$GCC ;;
2094 if test "$_lt_dar_can_shared" = "yes"; then
2095 output_verbose_link_cmd=func_echo_all
2096 _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}"
2097 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
2098 _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}"
2099 _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}"
2101 [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
2102 _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}"
2103 _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}"
2107 _LT_TAGVAR(ld_shlibs, $1)=no
2111 # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
2112 # ----------------------------------
2113 # Links a minimal program and checks the executable
2114 # for the system default hardcoded library path. In most cases,
2115 # this is /usr/lib:/lib, but when the MPI compilers are used
2116 # the location of the communication and MPI libs are included too.
2117 # If we don't find anything, use the default library path according
2118 # to the aix ld manual.
2119 # Store the results from the different compilers for each TAGNAME.
2120 # Allow to override them for all tags through lt_cv_aix_libpath.
2121 m4_defun([_LT_SYS_MODULE_PATH_AIX],
2122 [m4_require([_LT_DECL_SED])dnl
2123 if test "${lt_cv_aix_libpath+set}" = set; then
2124 aix_libpath=$lt_cv_aix_libpath
2126 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
2127 [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
2128 lt_aix_libpath_sed='[
2129 /Import File Strings/,/^$/ {
2131 s/^0 *\([^ ]*\) *$/\1/
2135 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2136 # Check for a 64-bit object if we didn't find anything.
2137 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
2138 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2140 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
2141 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
2144 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
2146 ])# _LT_SYS_MODULE_PATH_AIX
2149 # _LT_SHELL_INIT(ARG)
2150 # -------------------
2151 m4_define([_LT_SHELL_INIT],
2152 [m4_divert_text([M4SH-INIT], [$1
2153 ])])# _LT_SHELL_INIT
2157 # _LT_PROG_ECHO_BACKSLASH
2158 # -----------------------
2159 # Find how we can fake an echo command that does not interpret backslash.
2160 # In particular, with Autoconf 2.60 or later we add some code to the start
2161 # of the generated configure script which will find a shell with a builtin
2162 # printf (which we can use as an echo command).
2163 m4_defun([_LT_PROG_ECHO_BACKSLASH],
2164 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
2165 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
2166 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
2168 AC_MSG_CHECKING([how to print strings])
2169 # Test print first, because it will be a builtin if present.
2170 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
2171 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
2173 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
2176 # Use this function as a fallback that always works.
2177 func_fallback_echo ()
2179 eval 'cat <<_LTECHO_EOF
2183 ECHO='func_fallback_echo'
2186 # func_echo_all arg...
2187 # Invoke $ECHO with all args, space-separated.
2194 printf*) AC_MSG_RESULT([printf]) ;;
2195 print*) AC_MSG_RESULT([print -r]) ;;
2196 *) AC_MSG_RESULT([cat]) ;;
2199 m4_ifdef([_AS_DETECT_SUGGESTED],
2200 [_AS_DETECT_SUGGESTED([
2201 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
2202 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
2203 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
2204 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
2205 PATH=/empty FPATH=/empty; export PATH FPATH
2206 test "X`printf %s $ECHO`" = "X$ECHO" \
2207 || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
2209 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
2210 _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
2211 ])# _LT_PROG_ECHO_BACKSLASH
2216 AC_DEFUN([_LT_WITH_SYSROOT],
2217 [AC_MSG_CHECKING([for sysroot])
2218 AC_ARG_WITH([sysroot],
2219 [ --with-sysroot[=DIR] Search for dependent libraries within DIR
2220 (or the compiler's sysroot if not specified).],
2221 [], [with_sysroot=no])
2223 dnl lt_sysroot will always be passed unquoted. We quote it here
2224 dnl in case the user passed a directory name.
2226 case ${with_sysroot} in #(
2228 if test "$GCC" = yes; then
2229 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
2233 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
2238 AC_MSG_RESULT([${with_sysroot}])
2239 AC_MSG_ERROR([The sysroot must be an absolute path.])
2243 AC_MSG_RESULT([${lt_sysroot:-no}])
2244 _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
2245 [dependent libraries, and in which our libraries should be installed.])])
2249 m4_defun([_LT_ENABLE_LOCK],
2250 [AC_ARG_ENABLE([libtool-lock],
2251 [AS_HELP_STRING([--disable-libtool-lock],
2252 [avoid locking (might break parallel builds)])])
2253 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
2255 # Some flags need to be propagated to the compiler or linker for good
2259 # Find out which ABI we are using.
2260 echo 'int i;' > conftest.$ac_ext
2261 if AC_TRY_EVAL(ac_compile); then
2262 case `/usr/bin/file conftest.$ac_objext` in
2274 # Find out which ABI we are using.
2275 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
2276 if AC_TRY_EVAL(ac_compile); then
2277 if test "$lt_cv_prog_gnu_ld" = yes; then
2278 case `/usr/bin/file conftest.$ac_objext` in
2280 LD="${LD-ld} -melf32bsmip"
2283 LD="${LD-ld} -melf32bmipn32"
2286 LD="${LD-ld} -melf64bmip"
2290 case `/usr/bin/file conftest.$ac_objext` in
2306 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
2307 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
2308 # Find out which ABI we are using.
2309 echo 'int i;' > conftest.$ac_ext
2310 if AC_TRY_EVAL(ac_compile); then
2311 case `/usr/bin/file conftest.o` in
2314 x86_64-*kfreebsd*-gnu)
2315 LD="${LD-ld} -m elf_i386_fbsd"
2318 case `/usr/bin/file conftest.o` in
2320 LD="${LD-ld} -m elf32_x86_64"
2323 LD="${LD-ld} -m elf_i386"
2328 LD="${LD-ld} -m elf32lppclinux"
2331 LD="${LD-ld} -m elf32ppclinux"
2334 LD="${LD-ld} -m elf_s390"
2337 LD="${LD-ld} -m elf32_sparc"
2343 x86_64-*kfreebsd*-gnu)
2344 LD="${LD-ld} -m elf_x86_64_fbsd"
2347 LD="${LD-ld} -m elf_x86_64"
2350 LD="${LD-ld} -m elf64lppc"
2353 LD="${LD-ld} -m elf64ppc"
2355 s390*-*linux*|s390*-*tpf*)
2356 LD="${LD-ld} -m elf64_s390"
2359 LD="${LD-ld} -m elf64_sparc"
2369 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2370 SAVE_CFLAGS="$CFLAGS"
2371 CFLAGS="$CFLAGS -belf"
2372 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
2374 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
2376 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2377 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2378 CFLAGS="$SAVE_CFLAGS"
2382 # Find out which ABI we are using.
2383 echo 'int i;' > conftest.$ac_ext
2384 if AC_TRY_EVAL(ac_compile); then
2385 case `/usr/bin/file conftest.o` in
2387 case $lt_cv_prog_gnu_ld in
2391 LD="${LD-ld} -m elf_x86_64"
2394 LD="${LD-ld} -m elf64_sparc"
2397 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
2398 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
2403 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
2415 need_locks="$enable_libtool_lock"
2421 m4_defun([_LT_PROG_AR],
2422 [AC_CHECK_TOOLS(AR, [ar], false)
2425 _LT_DECL([], [AR], [1], [The archiver])
2426 _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
2428 AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
2429 [lt_cv_ar_at_file=no
2430 AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
2431 [echo conftest.$ac_objext > conftest.lst
2432 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
2433 AC_TRY_EVAL([lt_ar_try])
2434 if test "$ac_status" -eq 0; then
2435 # Ensure the archiver fails upon bogus file names.
2436 rm -f conftest.$ac_objext libconftest.a
2437 AC_TRY_EVAL([lt_ar_try])
2438 if test "$ac_status" -ne 0; then
2442 rm -f conftest.* libconftest.a
2446 if test "x$lt_cv_ar_at_file" = xno; then
2449 archiver_list_spec=$lt_cv_ar_at_file
2451 _LT_DECL([], [archiver_list_spec], [1],
2452 [How to feed a file listing to the archiver])
2456 # _LT_CMD_OLD_ARCHIVE
2457 # -------------------
2458 m4_defun([_LT_CMD_OLD_ARCHIVE],
2461 AC_CHECK_TOOL(STRIP, strip, :)
2462 test -z "$STRIP" && STRIP=:
2463 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
2465 AC_CHECK_TOOL(RANLIB, ranlib, :)
2466 test -z "$RANLIB" && RANLIB=:
2467 _LT_DECL([], [RANLIB], [1],
2468 [Commands used to install an old-style archive])
2470 # Determine commands to create old-style static archives.
2471 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
2472 old_postinstall_cmds='chmod 644 $oldlib'
2473 old_postuninstall_cmds=
2475 if test -n "$RANLIB"; then
2478 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
2481 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
2484 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
2489 lock_old_archive_extraction=yes ;;
2491 lock_old_archive_extraction=no ;;
2493 _LT_DECL([], [old_postinstall_cmds], [2])
2494 _LT_DECL([], [old_postuninstall_cmds], [2])
2495 _LT_TAGDECL([], [old_archive_cmds], [2],
2496 [Commands used to build an old-style archive])
2497 _LT_DECL([], [lock_old_archive_extraction], [0],
2498 [Whether to use a lock for old archive extraction])
2499 ])# _LT_CMD_OLD_ARCHIVE
2502 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2503 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
2504 # ----------------------------------------------------------------
2505 # Check whether the given compiler option works
2506 AC_DEFUN([_LT_COMPILER_OPTION],
2507 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2508 m4_require([_LT_DECL_SED])dnl
2509 AC_CACHE_CHECK([$1], [$2],
2511 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
2512 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2513 lt_compiler_flag="$3"
2514 # Insert the option either (1) after the last *FLAGS variable, or
2515 # (2) before a word containing "conftest.", or (3) at the end.
2516 # Note that $ac_compile itself does not contain backslashes and begins
2517 # with a dollar sign (not a hyphen), so the echo should work correctly.
2518 # The option is referenced via a variable to avoid confusing sed.
2519 lt_compile=`echo "$ac_compile" | $SED \
2520 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2521 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2522 -e 's:$: $lt_compiler_flag:'`
2523 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2524 (eval "$lt_compile" 2>conftest.err)
2526 cat conftest.err >&AS_MESSAGE_LOG_FD
2527 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2528 if (exit $ac_status) && test -s "$ac_outfile"; then
2529 # The compiler can only warn and ignore the option if not recognized
2530 # So say no if there are warnings other than the usual output.
2531 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
2532 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2533 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2540 if test x"[$]$2" = xyes; then
2541 m4_if([$5], , :, [$5])
2543 m4_if([$6], , :, [$6])
2545 ])# _LT_COMPILER_OPTION
2548 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2549 dnl aclocal-1.4 backwards compatibility:
2550 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2553 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2554 # [ACTION-SUCCESS], [ACTION-FAILURE])
2555 # ----------------------------------------------------
2556 # Check whether the given linker option works
2557 AC_DEFUN([_LT_LINKER_OPTION],
2558 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2559 m4_require([_LT_DECL_SED])dnl
2560 AC_CACHE_CHECK([$1], [$2],
2562 save_LDFLAGS="$LDFLAGS"
2563 LDFLAGS="$LDFLAGS $3"
2564 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2565 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2566 # The linker can only warn and ignore the option if not recognized
2567 # So say no if there are warnings
2568 if test -s conftest.err; then
2569 # Append any errors to the config.log.
2570 cat conftest.err 1>&AS_MESSAGE_LOG_FD
2571 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
2572 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2573 if diff conftest.exp conftest.er2 >/dev/null; then
2581 LDFLAGS="$save_LDFLAGS"
2584 if test x"[$]$2" = xyes; then
2585 m4_if([$4], , :, [$4])
2587 m4_if([$5], , :, [$5])
2589 ])# _LT_LINKER_OPTION
2592 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2593 dnl aclocal-1.4 backwards compatibility:
2594 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2599 AC_DEFUN([LT_CMD_MAX_LEN],
2600 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2601 # find the maximum length of command line arguments
2602 AC_MSG_CHECKING([the maximum length of command line arguments])
2603 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2609 # On DJGPP, this test can blow up pretty badly due to problems in libc
2610 # (any single argument exceeding 2000 bytes causes a buffer overrun
2611 # during glob expansion). Even if it were fixed, the result of this
2612 # check would be larger than it should be.
2613 lt_cv_sys_max_cmd_len=12288; # 12K is about right
2617 # Under GNU Hurd, this test is not required because there is
2618 # no limit to the length of command line arguments.
2619 # Libtool will interpret -1 as no limit whatsoever
2620 lt_cv_sys_max_cmd_len=-1;
2623 cygwin* | mingw* | cegcc*)
2624 # On Win9x/ME, this test blows up -- it succeeds, but takes
2625 # about 5 minutes as the teststring grows exponentially.
2626 # Worse, since 9x/ME are not pre-emptively multitasking,
2627 # you end up with a "frozen" computer, even though with patience
2628 # the test eventually succeeds (with a max line length of 256k).
2629 # Instead, let's just punt: use the minimum linelength reported by
2630 # all of the supported platforms: 8192 (on NT/2K/XP).
2631 lt_cv_sys_max_cmd_len=8192;
2635 # On MiNT this can take a long time and run out of memory.
2636 lt_cv_sys_max_cmd_len=8192;
2640 # On AmigaOS with pdksh, this test takes hours, literally.
2641 # So we just punt and use a minimum line length of 8192.
2642 lt_cv_sys_max_cmd_len=8192;
2645 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
2646 # This has been around since 386BSD, at least. Likely further.
2647 if test -x /sbin/sysctl; then
2648 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2649 elif test -x /usr/sbin/sysctl; then
2650 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2652 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
2654 # And add a safety zone
2655 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2656 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2660 # We know the value 262144 and hardcode it with a safety zone (like BSD)
2661 lt_cv_sys_max_cmd_len=196608
2665 # The test takes a long time on OS/2.
2666 lt_cv_sys_max_cmd_len=8192
2670 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2671 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2672 # nice to cause kernel panics so lets avoid the loop below.
2673 # First set a reasonable default.
2674 lt_cv_sys_max_cmd_len=16384
2676 if test -x /sbin/sysconfig; then
2677 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2678 *1*) lt_cv_sys_max_cmd_len=-1 ;;
2683 lt_cv_sys_max_cmd_len=102400
2685 sysv5* | sco5v6* | sysv4.2uw2*)
2686 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2687 if test -n "$kargmax"; then
2688 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
2690 lt_cv_sys_max_cmd_len=32768
2694 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
2695 if test -n "$lt_cv_sys_max_cmd_len" && \
2696 test undefined != "$lt_cv_sys_max_cmd_len"; then
2697 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2698 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2700 # Make teststring a little bigger before we do anything with it.
2701 # a 1K string should be a reasonable start.
2702 for i in 1 2 3 4 5 6 7 8 ; do
2703 teststring=$teststring$teststring
2705 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
2706 # If test is not a shell built-in, we'll probably end up computing a
2707 # maximum length that is only half of the actual maximum length, but
2709 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
2710 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
2711 test $i != 17 # 1/2 MB should be enough
2714 teststring=$teststring$teststring
2716 # Only check the string length outside the loop.
2717 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
2719 # Add a significant safety factor because C++ compilers can tack on
2720 # massive amounts of additional arguments before passing them to the
2721 # linker. It appears as though 1/2 is a usable value.
2722 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
2727 if test -n $lt_cv_sys_max_cmd_len ; then
2728 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
2732 max_cmd_len=$lt_cv_sys_max_cmd_len
2733 _LT_DECL([], [max_cmd_len], [0],
2734 [What is the maximum length of a command?])
2738 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
2739 dnl aclocal-1.4 backwards compatibility:
2740 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
2745 m4_defun([_LT_HEADER_DLFCN],
2746 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
2747 ])# _LT_HEADER_DLFCN
2750 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
2751 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
2752 # ----------------------------------------------------------------
2753 m4_defun([_LT_TRY_DLOPEN_SELF],
2754 [m4_require([_LT_HEADER_DLFCN])dnl
2755 if test "$cross_compiling" = yes; then :
2758 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
2759 lt_status=$lt_dlunknown
2760 cat > conftest.$ac_ext <<_LT_EOF
2761 [#line $LINENO "configure"
2762 #include "confdefs.h"
2771 # define LT_DLGLOBAL RTLD_GLOBAL
2774 # define LT_DLGLOBAL DL_GLOBAL
2776 # define LT_DLGLOBAL 0
2780 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
2781 find out it does not work in some platform. */
2782 #ifndef LT_DLLAZY_OR_NOW
2784 # define LT_DLLAZY_OR_NOW RTLD_LAZY
2787 # define LT_DLLAZY_OR_NOW DL_LAZY
2790 # define LT_DLLAZY_OR_NOW RTLD_NOW
2793 # define LT_DLLAZY_OR_NOW DL_NOW
2795 # define LT_DLLAZY_OR_NOW 0
2802 /* When -fvisbility=hidden is used, assume the code has been annotated
2803 correspondingly for the symbols needed. */
2804 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
2805 int fnord () __attribute__((visibility("default")));
2808 int fnord () { return 42; }
2811 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
2812 int status = $lt_dlunknown;
2816 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
2819 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
2820 else puts (dlerror ());
2822 /* dlclose (self); */
2830 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
2831 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
2834 x$lt_dlno_uscore) $1 ;;
2835 x$lt_dlneed_uscore) $2 ;;
2836 x$lt_dlunknown|x*) $3 ;;
2839 # compilation failed
2844 ])# _LT_TRY_DLOPEN_SELF
2847 # LT_SYS_DLOPEN_SELF
2848 # ------------------
2849 AC_DEFUN([LT_SYS_DLOPEN_SELF],
2850 [m4_require([_LT_HEADER_DLFCN])dnl
2851 if test "x$enable_dlopen" != xyes; then
2852 enable_dlopen=unknown
2853 enable_dlopen_self=unknown
2854 enable_dlopen_self_static=unknown
2861 lt_cv_dlopen="load_add_on"
2863 lt_cv_dlopen_self=yes
2866 mingw* | pw32* | cegcc*)
2867 lt_cv_dlopen="LoadLibrary"
2872 lt_cv_dlopen="dlopen"
2877 # if libdl is installed we need to link against it
2878 AC_CHECK_LIB([dl], [dlopen],
2879 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
2882 lt_cv_dlopen_self=yes
2887 AC_CHECK_FUNC([shl_load],
2888 [lt_cv_dlopen="shl_load"],
2889 [AC_CHECK_LIB([dld], [shl_load],
2890 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
2891 [AC_CHECK_FUNC([dlopen],
2892 [lt_cv_dlopen="dlopen"],
2893 [AC_CHECK_LIB([dl], [dlopen],
2894 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
2895 [AC_CHECK_LIB([svld], [dlopen],
2896 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
2897 [AC_CHECK_LIB([dld], [dld_link],
2898 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
2907 if test "x$lt_cv_dlopen" != xno; then
2913 case $lt_cv_dlopen in
2915 save_CPPFLAGS="$CPPFLAGS"
2916 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2918 save_LDFLAGS="$LDFLAGS"
2919 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2922 LIBS="$lt_cv_dlopen_libs $LIBS"
2924 AC_CACHE_CHECK([whether a program can dlopen itself],
2925 lt_cv_dlopen_self, [dnl
2926 _LT_TRY_DLOPEN_SELF(
2927 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2928 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2931 if test "x$lt_cv_dlopen_self" = xyes; then
2932 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2933 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2934 lt_cv_dlopen_self_static, [dnl
2935 _LT_TRY_DLOPEN_SELF(
2936 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2937 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2941 CPPFLAGS="$save_CPPFLAGS"
2942 LDFLAGS="$save_LDFLAGS"
2947 case $lt_cv_dlopen_self in
2948 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2949 *) enable_dlopen_self=unknown ;;
2952 case $lt_cv_dlopen_self_static in
2953 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2954 *) enable_dlopen_self_static=unknown ;;
2957 _LT_DECL([dlopen_support], [enable_dlopen], [0],
2958 [Whether dlopen is supported])
2959 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2960 [Whether dlopen of programs is supported])
2961 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2962 [Whether dlopen of statically linked programs is supported])
2963 ])# LT_SYS_DLOPEN_SELF
2966 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2967 dnl aclocal-1.4 backwards compatibility:
2968 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2971 # _LT_COMPILER_C_O([TAGNAME])
2972 # ---------------------------
2973 # Check to see if options -c and -o are simultaneously supported by compiler.
2974 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
2975 m4_defun([_LT_COMPILER_C_O],
2976 [m4_require([_LT_DECL_SED])dnl
2977 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2978 m4_require([_LT_TAG_COMPILER])dnl
2979 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2980 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2981 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2982 $RM -r conftest 2>/dev/null
2986 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2988 lt_compiler_flag="-o out/conftest2.$ac_objext"
2989 # Insert the option either (1) after the last *FLAGS variable, or
2990 # (2) before a word containing "conftest.", or (3) at the end.
2991 # Note that $ac_compile itself does not contain backslashes and begins
2992 # with a dollar sign (not a hyphen), so the echo should work correctly.
2993 lt_compile=`echo "$ac_compile" | $SED \
2994 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2995 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2996 -e 's:$: $lt_compiler_flag:'`
2997 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2998 (eval "$lt_compile" 2>out/conftest.err)
3000 cat out/conftest.err >&AS_MESSAGE_LOG_FD
3001 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
3002 if (exit $ac_status) && test -s out/conftest2.$ac_objext
3004 # The compiler can only warn and ignore the option if not recognized
3005 # So say no if there are warnings
3006 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
3007 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
3008 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
3009 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
3012 chmod u+w . 2>&AS_MESSAGE_LOG_FD
3014 # SGI C++ compiler will create directory out/ii_files/ for
3015 # template instantiation
3016 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
3017 $RM out/* && rmdir out
3022 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
3023 [Does compiler simultaneously support -c and -o options?])
3024 ])# _LT_COMPILER_C_O
3027 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
3028 # ----------------------------------
3029 # Check to see if we can do hard links to lock some files if needed
3030 m4_defun([_LT_COMPILER_FILE_LOCKS],
3031 [m4_require([_LT_ENABLE_LOCK])dnl
3032 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3033 _LT_COMPILER_C_O([$1])
3035 hard_links="nottested"
3036 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
3037 # do not overwrite the value of need_locks provided by the user
3038 AC_MSG_CHECKING([if we can lock with hard links])
3041 ln conftest.a conftest.b 2>/dev/null && hard_links=no
3043 ln conftest.a conftest.b 2>&5 || hard_links=no
3044 ln conftest.a conftest.b 2>/dev/null && hard_links=no
3045 AC_MSG_RESULT([$hard_links])
3046 if test "$hard_links" = no; then
3047 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
3053 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
3054 ])# _LT_COMPILER_FILE_LOCKS
3059 m4_defun([_LT_CHECK_OBJDIR],
3060 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
3061 [rm -f .libs 2>/dev/null
3062 mkdir .libs 2>/dev/null
3063 if test -d .libs; then
3066 # MS-DOS does not allow filenames that begin with a dot.
3069 rmdir .libs 2>/dev/null])
3070 objdir=$lt_cv_objdir
3071 _LT_DECL([], [objdir], [0],
3072 [The name of the directory that contains temporary libtool files])dnl
3073 m4_pattern_allow([LT_OBJDIR])dnl
3074 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
3075 [Define to the sub-directory in which libtool stores uninstalled libraries.])
3076 ])# _LT_CHECK_OBJDIR
3079 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
3080 # --------------------------------------
3081 # Check hardcoding attributes.
3082 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
3083 [AC_MSG_CHECKING([how to hardcode library paths into programs])
3084 _LT_TAGVAR(hardcode_action, $1)=
3085 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
3086 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
3087 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
3089 # We can hardcode non-existent directories.
3090 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
3091 # If the only mechanism to avoid hardcoding is shlibpath_var, we
3092 # have to relink, otherwise we might link with an installed library
3093 # when we should be linking with a yet-to-be-installed one
3094 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
3095 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
3096 # Linking always hardcodes the temporary library directory.
3097 _LT_TAGVAR(hardcode_action, $1)=relink
3099 # We can link without hardcoding, and we can hardcode nonexisting dirs.
3100 _LT_TAGVAR(hardcode_action, $1)=immediate
3103 # We cannot hardcode anything, or else we can only hardcode existing
3105 _LT_TAGVAR(hardcode_action, $1)=unsupported
3107 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
3109 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
3110 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
3111 # Fast installation is not supported
3112 enable_fast_install=no
3113 elif test "$shlibpath_overrides_runpath" = yes ||
3114 test "$enable_shared" = no; then
3115 # Fast installation is not necessary
3116 enable_fast_install=needless
3118 _LT_TAGDECL([], [hardcode_action], [0],
3119 [How to hardcode a shared library path into an executable])
3120 ])# _LT_LINKER_HARDCODE_LIBPATH
3125 m4_defun([_LT_CMD_STRIPLIB],
3126 [m4_require([_LT_DECL_EGREP])
3129 AC_MSG_CHECKING([whether stripping libraries is possible])
3130 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
3131 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
3132 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
3133 AC_MSG_RESULT([yes])
3135 # FIXME - insert some real tests, host_os isn't really good enough
3138 if test -n "$STRIP" ; then
3139 striplib="$STRIP -x"
3140 old_striplib="$STRIP -S"
3141 AC_MSG_RESULT([yes])
3151 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
3152 _LT_DECL([], [striplib], [1])
3153 ])# _LT_CMD_STRIPLIB
3156 # _LT_SYS_DYNAMIC_LINKER([TAG])
3157 # -----------------------------
3158 # PORTME Fill in your ld.so characteristics
3159 m4_defun([_LT_SYS_DYNAMIC_LINKER],
3160 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3161 m4_require([_LT_DECL_EGREP])dnl
3162 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3163 m4_require([_LT_DECL_OBJDUMP])dnl
3164 m4_require([_LT_DECL_SED])dnl
3165 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
3166 AC_MSG_CHECKING([dynamic linker characteristics])
3169 if test "$GCC" = yes; then
3171 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
3172 *) lt_awk_arg="/^libraries:/" ;;
3175 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
3176 *) lt_sed_strip_eq="s,=/,/,g" ;;
3178 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
3179 case $lt_search_path_spec in
3181 # if the path contains ";" then we assume it to be the separator
3182 # otherwise default to the standard path separator (i.e. ":") - it is
3183 # assumed that no part of a normal pathname contains ";" but that should
3184 # okay in the real world where ";" in dirpaths is itself problematic.
3185 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
3188 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
3191 # Ok, now we have the path, separated by spaces, we can step through it
3192 # and add multilib dir if necessary.
3193 lt_tmp_lt_search_path_spec=
3194 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
3195 for lt_sys_path in $lt_search_path_spec; do
3196 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
3197 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
3199 test -d "$lt_sys_path" && \
3200 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
3203 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
3204 BEGIN {RS=" "; FS="/|\n";} {
3207 for (lt_i = NF; lt_i > 0; lt_i--) {
3208 if ($lt_i != "" && $lt_i != ".") {
3209 if ($lt_i == "..") {
3212 if (lt_count == 0) {
3213 lt_foo="/" $lt_i lt_foo;
3220 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
3221 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
3223 # AWK program above erroneously prepends '/' to C:/dos/paths
3226 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
3227 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
3229 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
3231 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
3234 libname_spec='lib$name'
3242 shlibpath_overrides_runpath=unknown
3244 dynamic_linker="$host_os ld.so"
3245 sys_lib_dlsearch_path_spec="/lib /usr/lib"
3246 need_lib_prefix=unknown
3247 hardcode_into_libs=no
3249 # when you set need_version to no, make sure it does not cause -set_version
3250 # flags to be left without arguments
3251 need_version=unknown
3255 version_type=linux # correct to gnu/linux during the next big refactor
3256 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
3257 shlibpath_var=LIBPATH
3259 # AIX 3 has no versioning support, so we append a major version to the name.
3260 soname_spec='${libname}${release}${shared_ext}$major'
3264 version_type=linux # correct to gnu/linux during the next big refactor
3267 hardcode_into_libs=yes
3268 if test "$host_cpu" = ia64; then
3269 # AIX 5 supports IA64
3270 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
3271 shlibpath_var=LD_LIBRARY_PATH
3273 # With GCC up to 2.95.x, collect2 would create an import file
3274 # for dependence libraries. The import file would start with
3275 # the line `#! .'. This would cause the generated library to
3276 # depend on `.', always an invalid library. This was fixed in
3277 # development snapshots of GCC prior to 3.0.
3279 aix4 | aix4.[[01]] | aix4.[[01]].*)
3280 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
3282 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
3289 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
3290 # soname into executable. Probably we can add versioning support to
3291 # collect2, so additional links can be useful in future.
3292 if test "$aix_use_runtimelinking" = yes; then
3293 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
3294 # instead of lib<name>.a to let people know that these are not
3295 # typical AIX shared libraries.
3296 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3298 # We preserve .a as extension for shared libraries through AIX4.2
3299 # and later when we are not doing run time linking.
3300 library_names_spec='${libname}${release}.a $libname.a'
3301 soname_spec='${libname}${release}${shared_ext}$major'
3303 shlibpath_var=LIBPATH
3310 # Since July 2007 AmigaOS4 officially supports .so libraries.
3311 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
3312 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3315 library_names_spec='$libname.ixlibrary $libname.a'
3316 # Create ${libname}_ixlibrary.a entries in /sys/libs.
3317 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
3323 library_names_spec='${libname}${shared_ext}'
3324 dynamic_linker="$host_os ld.so"
3325 shlibpath_var=LIBRARY_PATH
3329 version_type=linux # correct to gnu/linux during the next big refactor
3331 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3332 soname_spec='${libname}${release}${shared_ext}$major'
3333 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
3334 shlibpath_var=LD_LIBRARY_PATH
3335 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
3336 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
3337 # the default ld.so.conf also contains /usr/contrib/lib and
3338 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
3339 # libtool to hard-code these into programs
3342 cygwin* | mingw* | pw32* | cegcc*)
3343 version_type=windows
3348 case $GCC,$cc_basename in
3351 library_names_spec='$libname.dll.a'
3352 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3353 postinstall_cmds='base_file=`basename \${file}`~
3354 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3355 dldir=$destdir/`dirname \$dlpath`~
3356 test -d \$dldir || mkdir -p \$dldir~
3357 $install_prog $dir/$dlname \$dldir/$dlname~
3358 chmod a+x \$dldir/$dlname~
3359 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
3360 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
3362 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3363 dlpath=$dir/\$dldll~
3365 shlibpath_overrides_runpath=yes
3369 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
3370 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3372 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
3375 # MinGW DLLs use traditional 'lib' prefix
3376 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3379 # pw32 DLLs use 'pw' prefix rather than 'lib'
3380 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3383 dynamic_linker='Win32 ld.exe'
3388 libname_spec='$name'
3389 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3390 library_names_spec='${libname}.dll.lib'
3394 sys_lib_search_path_spec=
3400 # Let DOS variable expansion print the short 8.3 style file name.
3401 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
3402 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
3405 # Convert to MSYS style.
3406 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
3409 # Convert to unix form, then to dos form, then back to unix form
3410 # but this time dos style (no spaces!) so that the unix form looks
3411 # like /cygdrive/c/PROGRA~1:/cygdr...
3412 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
3413 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
3414 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3417 sys_lib_search_path_spec="$LIB"
3418 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
3419 # It is most probably a Windows format PATH.
3420 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
3422 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3424 # FIXME: find the short name or the path components, as spaces are
3425 # common. (e.g. "Program Files" -> "PROGRA~1")
3429 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3430 postinstall_cmds='base_file=`basename \${file}`~
3431 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3432 dldir=$destdir/`dirname \$dlpath`~
3433 test -d \$dldir || mkdir -p \$dldir~
3434 $install_prog $dir/$dlname \$dldir/$dlname'
3435 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3436 dlpath=$dir/\$dldll~
3438 shlibpath_overrides_runpath=yes
3439 dynamic_linker='Win32 link.exe'
3443 # Assume MSVC wrapper
3444 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
3445 dynamic_linker='Win32 ld.exe'
3448 # FIXME: first we should search . and the directory the executable is in
3452 darwin* | rhapsody*)
3453 dynamic_linker="$host_os dyld"
3457 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
3458 soname_spec='${libname}${release}${major}$shared_ext'
3459 shlibpath_overrides_runpath=yes
3460 shlibpath_var=DYLD_LIBRARY_PATH
3461 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3463 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3464 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3468 version_type=linux # correct to gnu/linux during the next big refactor
3471 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
3472 soname_spec='${libname}${release}${shared_ext}$major'
3473 shlibpath_var=LD_LIBRARY_PATH
3476 freebsd* | dragonfly*)
3477 # DragonFly does not have aout. When/if they implement a new
3478 # versioning mechanism, adjust this.
3479 if test -x /usr/bin/objformat; then
3480 objformat=`/usr/bin/objformat`
3483 freebsd[[23]].*) objformat=aout ;;
3487 version_type=freebsd-$objformat
3488 case $version_type in
3490 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3495 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
3499 shlibpath_var=LD_LIBRARY_PATH
3502 shlibpath_overrides_runpath=yes
3504 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3505 shlibpath_overrides_runpath=yes
3506 hardcode_into_libs=yes
3508 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3509 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3510 shlibpath_overrides_runpath=no
3511 hardcode_into_libs=yes
3513 *) # from 4.6 on, and DragonFly
3514 shlibpath_overrides_runpath=yes
3515 hardcode_into_libs=yes
3521 version_type=linux # correct to gnu/linux during the next big refactor
3524 dynamic_linker="$host_os runtime_loader"
3525 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3526 soname_spec='${libname}${release}${shared_ext}$major'
3527 shlibpath_var=LIBRARY_PATH
3528 shlibpath_overrides_runpath=yes
3529 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
3530 hardcode_into_libs=yes
3533 hpux9* | hpux10* | hpux11*)
3534 # Give a soname corresponding to the major version so that dld.sl refuses to
3535 # link against other versions.
3542 hardcode_into_libs=yes
3543 dynamic_linker="$host_os dld.so"
3544 shlibpath_var=LD_LIBRARY_PATH
3545 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3546 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3547 soname_spec='${libname}${release}${shared_ext}$major'
3548 if test "X$HPUX_IA64_MODE" = X32; then
3549 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3551 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
3553 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3557 hardcode_into_libs=yes
3558 dynamic_linker="$host_os dld.sl"
3559 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
3560 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3561 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3562 soname_spec='${libname}${release}${shared_ext}$major'
3563 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3564 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3568 dynamic_linker="$host_os dld.sl"
3569 shlibpath_var=SHLIB_PATH
3570 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3571 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3572 soname_spec='${libname}${release}${shared_ext}$major'
3575 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
3576 postinstall_cmds='chmod 555 $lib'
3577 # or fails outright, so override atomically:
3578 install_override_mode=555
3582 version_type=linux # correct to gnu/linux during the next big refactor
3585 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3586 soname_spec='${libname}${release}${shared_ext}$major'
3587 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3588 shlibpath_var=LD_LIBRARY_PATH
3589 shlibpath_overrides_runpath=no
3590 hardcode_into_libs=yes
3593 irix5* | irix6* | nonstopux*)
3595 nonstopux*) version_type=nonstopux ;;
3597 if test "$lt_cv_prog_gnu_ld" = yes; then
3598 version_type=linux # correct to gnu/linux during the next big refactor
3605 soname_spec='${libname}${release}${shared_ext}$major'
3606 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
3608 irix5* | nonstopux*)
3612 case $LD in # libtool.m4 will add one of these switches to LD
3613 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3614 libsuff= shlibsuff= libmagic=32-bit;;
3615 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3616 libsuff=32 shlibsuff=N32 libmagic=N32;;
3617 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3618 libsuff=64 shlibsuff=64 libmagic=64-bit;;
3619 *) libsuff= shlibsuff= libmagic=never-match;;
3623 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3624 shlibpath_overrides_runpath=no
3625 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
3626 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
3627 hardcode_into_libs=yes
3630 # No shared lib support for Linux oldld, aout, or coff.
3631 linux*oldld* | linux*aout* | linux*coff*)
3635 # This must be glibc/ELF.
3636 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3637 version_type=linux # correct to gnu/linux during the next big refactor
3640 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3641 soname_spec='${libname}${release}${shared_ext}$major'
3642 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3643 shlibpath_var=LD_LIBRARY_PATH
3644 shlibpath_overrides_runpath=no
3646 # Some binutils ld are patched to set DT_RUNPATH
3647 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
3648 [lt_cv_shlibpath_overrides_runpath=no
3649 save_LDFLAGS=$LDFLAGS
3651 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3652 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3653 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3654 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3655 [lt_cv_shlibpath_overrides_runpath=yes])])
3656 LDFLAGS=$save_LDFLAGS
3659 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
3661 # This implies no fast_install, which is unacceptable.
3662 # Some rework will be needed to allow for fast_install
3663 # before this can be enabled.
3664 hardcode_into_libs=yes
3666 # Append ld.so.conf contents to the search path
3667 if test -f /etc/ld.so.conf; then
3668 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' ' '`
3669 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3672 # We used to test for /lib/ld.so.1 and disable shared libraries on
3673 # powerpc, because MkLinux only supported shared libraries with the
3674 # GNU dynamic linker. Since this was broken with cross compilers,
3675 # most powerpc-linux boxes support dynamic linking these days and
3676 # people can always --disable-shared, the test was removed, and we
3677 # assume the GNU/Linux dynamic linker is in use.
3678 dynamic_linker='GNU/Linux ld.so'
3685 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3686 soname_spec='${libname}${release}${shared_ext}$major'
3687 shlibpath_var=LD_LIBRARY_PATH
3688 shlibpath_overrides_runpath=no
3689 hardcode_into_libs=yes
3690 dynamic_linker='NetBSD ld.elf_so'
3697 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
3698 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3699 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3700 dynamic_linker='NetBSD (a.out) ld.so'
3702 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3703 soname_spec='${libname}${release}${shared_ext}$major'
3704 dynamic_linker='NetBSD ld.elf_so'
3706 shlibpath_var=LD_LIBRARY_PATH
3707 shlibpath_overrides_runpath=yes
3708 hardcode_into_libs=yes
3712 version_type=linux # correct to gnu/linux during the next big refactor
3713 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3714 shlibpath_var=LD_LIBRARY_PATH
3715 shlibpath_overrides_runpath=yes
3722 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3723 soname_spec='${libname}${release}${shared_ext}$major'
3724 shlibpath_var=LD_LIBRARY_PATH
3725 shlibpath_overrides_runpath=no
3726 hardcode_into_libs=yes
3727 dynamic_linker='ldqnx.so'
3732 sys_lib_dlsearch_path_spec="/usr/lib"
3734 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
3736 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
3737 *) need_version=no ;;
3739 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3740 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3741 shlibpath_var=LD_LIBRARY_PATH
3742 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3744 openbsd2.[[89]] | openbsd2.[[89]].*)
3745 shlibpath_overrides_runpath=no
3748 shlibpath_overrides_runpath=yes
3752 shlibpath_overrides_runpath=yes
3757 libname_spec='$name'
3760 library_names_spec='$libname${shared_ext} $libname.a'
3761 dynamic_linker='OS/2 ld.exe'
3762 shlibpath_var=LIBPATH
3765 osf3* | osf4* | osf5*)
3769 soname_spec='${libname}${release}${shared_ext}$major'
3770 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3771 shlibpath_var=LD_LIBRARY_PATH
3772 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
3773 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
3781 version_type=linux # correct to gnu/linux during the next big refactor
3784 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3785 soname_spec='${libname}${release}${shared_ext}$major'
3786 shlibpath_var=LD_LIBRARY_PATH
3787 shlibpath_overrides_runpath=yes
3788 hardcode_into_libs=yes
3789 # ldd complains unless libraries are executable
3790 postinstall_cmds='chmod +x $lib'
3795 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3796 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
3797 shlibpath_var=LD_LIBRARY_PATH
3798 shlibpath_overrides_runpath=yes
3799 if test "$with_gnu_ld" = yes; then
3806 version_type=linux # correct to gnu/linux during the next big refactor
3807 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3808 soname_spec='${libname}${release}${shared_ext}$major'
3809 shlibpath_var=LD_LIBRARY_PATH
3810 case $host_vendor in
3812 shlibpath_overrides_runpath=no
3814 runpath_var=LD_RUN_PATH
3822 shlibpath_overrides_runpath=no
3823 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
3829 if test -d /usr/nec ;then
3830 version_type=linux # correct to gnu/linux during the next big refactor
3831 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
3832 soname_spec='$libname${shared_ext}.$major'
3833 shlibpath_var=LD_LIBRARY_PATH
3837 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3838 version_type=freebsd-elf
3841 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3842 soname_spec='${libname}${release}${shared_ext}$major'
3843 shlibpath_var=LD_LIBRARY_PATH
3844 shlibpath_overrides_runpath=yes
3845 hardcode_into_libs=yes
3846 if test "$with_gnu_ld" = yes; then
3847 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
3849 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
3852 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
3856 sys_lib_dlsearch_path_spec='/usr/lib'
3860 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
3861 version_type=linux # correct to gnu/linux during the next big refactor
3864 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3865 shlibpath_var=LD_LIBRARY_PATH
3866 shlibpath_overrides_runpath=no
3867 hardcode_into_libs=yes
3871 version_type=linux # correct to gnu/linux during the next big refactor
3872 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3873 soname_spec='${libname}${release}${shared_ext}$major'
3874 shlibpath_var=LD_LIBRARY_PATH
3881 AC_MSG_RESULT([$dynamic_linker])
3882 test "$dynamic_linker" = no && can_build_shared=no
3884 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3885 if test "$GCC" = yes; then
3886 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3889 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
3890 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
3892 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
3893 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
3896 _LT_DECL([], [variables_saved_for_relink], [1],
3897 [Variables whose values should be saved in libtool wrapper scripts and
3898 restored at link time])
3899 _LT_DECL([], [need_lib_prefix], [0],
3900 [Do we need the "lib" prefix for modules?])
3901 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3902 _LT_DECL([], [version_type], [0], [Library versioning type])
3903 _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3904 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3905 _LT_DECL([], [shlibpath_overrides_runpath], [0],
3906 [Is shlibpath searched before the hard-coded library search path?])
3907 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3908 _LT_DECL([], [library_names_spec], [1],
3909 [[List of archive names. First name is the real one, the rest are links.
3910 The last name is the one that the linker finds with -lNAME]])
3911 _LT_DECL([], [soname_spec], [1],
3912 [[The coded name of the library, if different from the real name]])
3913 _LT_DECL([], [install_override_mode], [1],
3914 [Permission mode override for installation of shared libraries])
3915 _LT_DECL([], [postinstall_cmds], [2],
3916 [Command to use after installation of a shared archive])
3917 _LT_DECL([], [postuninstall_cmds], [2],
3918 [Command to use after uninstallation of a shared archive])
3919 _LT_DECL([], [finish_cmds], [2],
3920 [Commands used to finish a libtool library installation in a directory])
3921 _LT_DECL([], [finish_eval], [1],
3922 [[As "finish_cmds", except a single script fragment to be evaled but
3924 _LT_DECL([], [hardcode_into_libs], [0],
3925 [Whether we should hardcode library paths into libraries])
3926 _LT_DECL([], [sys_lib_search_path_spec], [2],
3927 [Compile-time system search path for libraries])
3928 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3929 [Run-time system search path for libraries])
3930 ])# _LT_SYS_DYNAMIC_LINKER
3933 # _LT_PATH_TOOL_PREFIX(TOOL)
3934 # --------------------------
3935 # find a file program which can recognize shared library
3936 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3937 [m4_require([_LT_DECL_EGREP])dnl
3938 AC_MSG_CHECKING([for $1])
3939 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3941 [[\\/*] | ?:[\\/]*])
3942 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3945 lt_save_MAGIC_CMD="$MAGIC_CMD"
3946 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3947 dnl $ac_dummy forces splitting on constant user-supplied paths.
3948 dnl POSIX.2 word splitting is done only on the output of word expansions,
3949 dnl not every word. This closes a longstanding sh security hole.
3950 ac_dummy="m4_if([$2], , $PATH, [$2])"
3951 for ac_dir in $ac_dummy; do
3953 test -z "$ac_dir" && ac_dir=.
3954 if test -f $ac_dir/$1; then
3955 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3956 if test -n "$file_magic_test_file"; then
3957 case $deplibs_check_method in
3959 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3960 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3961 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3962 $EGREP "$file_magic_regex" > /dev/null; then
3967 *** Warning: the command libtool uses to detect shared libraries,
3968 *** $file_magic_cmd, produces output that libtool cannot recognize.
3969 *** The result is that libtool may fail to recognize shared libraries
3970 *** as such. This will affect the creation of libtool libraries that
3971 *** depend on shared libraries, but programs linked with such libtool
3972 *** libraries will work regardless of this problem. Nevertheless, you
3973 *** may want to report the problem to your system manager and/or to
3974 *** bug-libtool@gnu.org
3984 MAGIC_CMD="$lt_save_MAGIC_CMD"
3987 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3988 if test -n "$MAGIC_CMD"; then
3989 AC_MSG_RESULT($MAGIC_CMD)
3993 _LT_DECL([], [MAGIC_CMD], [0],
3994 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3995 ])# _LT_PATH_TOOL_PREFIX
3998 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3999 dnl aclocal-1.4 backwards compatibility:
4000 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
4005 # find a file program which can recognize a shared library
4006 m4_defun([_LT_PATH_MAGIC],
4007 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
4008 if test -z "$lt_cv_path_MAGIC_CMD"; then
4009 if test -n "$ac_tool_prefix"; then
4010 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
4020 # find the pathname to the GNU or non-GNU linker
4021 AC_DEFUN([LT_PATH_LD],
4022 [AC_REQUIRE([AC_PROG_CC])dnl
4023 AC_REQUIRE([AC_CANONICAL_HOST])dnl
4024 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
4025 m4_require([_LT_DECL_SED])dnl
4026 m4_require([_LT_DECL_EGREP])dnl
4027 m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
4029 AC_ARG_WITH([gnu-ld],
4030 [AS_HELP_STRING([--with-gnu-ld],
4031 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
4032 [test "$withval" = no || with_gnu_ld=yes],
4033 [with_gnu_ld=no])dnl
4036 if test "$GCC" = yes; then
4037 # Check if gcc -print-prog-name=ld gives a path.
4038 AC_MSG_CHECKING([for ld used by $CC])
4041 # gcc leaves a trailing carriage return which upsets mingw
4042 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4044 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4047 # Accept absolute paths.
4048 [[\\/]]* | ?:[[\\/]]*)
4049 re_direlt='/[[^/]][[^/]]*/\.\./'
4050 # Canonicalize the pathname of ld
4051 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4052 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4053 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4055 test -z "$LD" && LD="$ac_prog"
4058 # If it fails, then pretend we aren't using GCC.
4062 # If it is relative, then search for the first ld in PATH.
4066 elif test "$with_gnu_ld" = yes; then
4067 AC_MSG_CHECKING([for GNU ld])
4069 AC_MSG_CHECKING([for non-GNU ld])
4071 AC_CACHE_VAL(lt_cv_path_LD,
4072 [if test -z "$LD"; then
4073 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4074 for ac_dir in $PATH; do
4076 test -z "$ac_dir" && ac_dir=.
4077 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4078 lt_cv_path_LD="$ac_dir/$ac_prog"
4079 # Check to see if the program is GNU ld. I'd rather use --version,
4080 # but apparently some variants of GNU ld only accept -v.
4081 # Break only if it was the GNU/non-GNU ld that we prefer.
4082 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4083 *GNU* | *'with BFD'*)
4084 test "$with_gnu_ld" != no && break
4087 test "$with_gnu_ld" != yes && break
4094 lt_cv_path_LD="$LD" # Let the user override the test with a path.
4097 if test -n "$LD"; then
4102 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
4106 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
4110 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
4111 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
4112 dnl aclocal-1.4 backwards compatibility:
4113 dnl AC_DEFUN([AM_PROG_LD], [])
4114 dnl AC_DEFUN([AC_PROG_LD], [])
4119 m4_defun([_LT_PATH_LD_GNU],
4120 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
4121 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
4122 case `$LD -v 2>&1 </dev/null` in
4123 *GNU* | *'with BFD'*)
4124 lt_cv_prog_gnu_ld=yes
4127 lt_cv_prog_gnu_ld=no
4130 with_gnu_ld=$lt_cv_prog_gnu_ld
4136 # find reload flag for linker
4137 # -- PORTME Some linkers may need a different reload flag.
4138 m4_defun([_LT_CMD_RELOAD],
4139 [AC_CACHE_CHECK([for $LD option to reload object files],
4140 lt_cv_ld_reload_flag,
4141 [lt_cv_ld_reload_flag='-r'])
4142 reload_flag=$lt_cv_ld_reload_flag
4143 case $reload_flag in
4145 *) reload_flag=" $reload_flag" ;;
4147 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4149 cygwin* | mingw* | pw32* | cegcc*)
4150 if test "$GCC" != yes; then
4155 if test "$GCC" = yes; then
4156 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
4158 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4162 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
4163 _LT_TAGDECL([], [reload_cmds], [2])dnl
4167 # _LT_CHECK_MAGIC_METHOD
4168 # ----------------------
4169 # how to check for library dependencies
4170 # -- PORTME fill in with the dynamic library characteristics
4171 m4_defun([_LT_CHECK_MAGIC_METHOD],
4172 [m4_require([_LT_DECL_EGREP])
4173 m4_require([_LT_DECL_OBJDUMP])
4174 AC_CACHE_CHECK([how to recognize dependent libraries],
4175 lt_cv_deplibs_check_method,
4176 [lt_cv_file_magic_cmd='$MAGIC_CMD'
4177 lt_cv_file_magic_test_file=
4178 lt_cv_deplibs_check_method='unknown'
4179 # Need to set the preceding variable on all platforms that support
4180 # interlibrary dependencies.
4181 # 'none' -- dependencies not supported.
4182 # `unknown' -- same as none, but documents that we really don't know.
4183 # 'pass_all' -- all dependencies passed with no checks.
4184 # 'test_compile' -- check by making test program.
4185 # 'file_magic [[regex]]' -- check by looking for files in library path
4186 # which responds to the $file_magic_cmd with a given extended regex.
4187 # If you have `file' or equivalent on your system and you're not sure
4188 # whether `pass_all' will *always* work, you probably want this one.
4192 lt_cv_deplibs_check_method=pass_all
4196 lt_cv_deplibs_check_method=pass_all
4200 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
4201 lt_cv_file_magic_cmd='/usr/bin/file -L'
4202 lt_cv_file_magic_test_file=/shlib/libc.so
4206 # func_win32_libid is a shell function defined in ltmain.sh
4207 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4208 lt_cv_file_magic_cmd='func_win32_libid'
4212 # Base MSYS/MinGW do not provide the 'file' command needed by
4213 # func_win32_libid shell function, so use a weaker test based on 'objdump',
4214 # unless we find 'file', for example because we are cross-compiling.
4215 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
4216 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
4217 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4218 lt_cv_file_magic_cmd='func_win32_libid'
4220 # Keep this pattern in sync with the one in func_win32_libid.
4221 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
4222 lt_cv_file_magic_cmd='$OBJDUMP -f'
4227 # use the weaker test based on 'objdump'. See mingw*.
4228 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
4229 lt_cv_file_magic_cmd='$OBJDUMP -f'
4232 darwin* | rhapsody*)
4233 lt_cv_deplibs_check_method=pass_all
4236 freebsd* | dragonfly*)
4237 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4240 # Not sure whether the presence of OpenBSD here was a mistake.
4241 # Let's accept both of them until this is cleared up.
4242 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
4243 lt_cv_file_magic_cmd=/usr/bin/file
4244 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4248 lt_cv_deplibs_check_method=pass_all
4253 lt_cv_deplibs_check_method=pass_all
4256 hpux10.20* | hpux11*)
4257 lt_cv_file_magic_cmd=/usr/bin/file
4260 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
4261 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
4264 [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]']
4265 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
4268 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
4269 lt_cv_file_magic_test_file=/usr/lib/libc.sl
4275 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
4276 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
4279 irix5* | irix6* | nonstopux*)
4281 *-32|*"-32 ") libmagic=32-bit;;
4282 *-n32|*"-n32 ") libmagic=N32;;
4283 *-64|*"-64 ") libmagic=64-bit;;
4284 *) libmagic=never-match;;
4286 lt_cv_deplibs_check_method=pass_all
4289 # This must be glibc/ELF.
4290 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4291 lt_cv_deplibs_check_method=pass_all
4294 netbsd* | netbsdelf*-gnu)
4295 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4296 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4298 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
4303 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
4304 lt_cv_file_magic_cmd=/usr/bin/file
4305 lt_cv_file_magic_test_file=/usr/lib/libnls.so
4309 lt_cv_deplibs_check_method=pass_all
4313 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4314 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
4316 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4320 osf3* | osf4* | osf5*)
4321 lt_cv_deplibs_check_method=pass_all
4325 lt_cv_deplibs_check_method=pass_all
4329 lt_cv_deplibs_check_method=pass_all
4332 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4333 lt_cv_deplibs_check_method=pass_all
4337 case $host_vendor in
4339 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]]'
4340 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
4343 lt_cv_deplibs_check_method=pass_all
4346 lt_cv_file_magic_cmd='/bin/file'
4347 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
4350 lt_cv_file_magic_cmd='/bin/file'
4351 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
4352 lt_cv_file_magic_test_file=/lib/libc.so
4355 lt_cv_deplibs_check_method=pass_all
4358 lt_cv_deplibs_check_method=pass_all
4364 lt_cv_deplibs_check_method=pass_all
4371 if test "$build" = "$host"; then
4374 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
4377 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
4383 file_magic_cmd=$lt_cv_file_magic_cmd
4384 deplibs_check_method=$lt_cv_deplibs_check_method
4385 test -z "$deplibs_check_method" && deplibs_check_method=unknown
4387 _LT_DECL([], [deplibs_check_method], [1],
4388 [Method to check whether dependent libraries are shared objects])
4389 _LT_DECL([], [file_magic_cmd], [1],
4390 [Command to use when deplibs_check_method = "file_magic"])
4391 _LT_DECL([], [file_magic_glob], [1],
4392 [How to find potential files when deplibs_check_method = "file_magic"])
4393 _LT_DECL([], [want_nocaseglob], [1],
4394 [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
4395 ])# _LT_CHECK_MAGIC_METHOD
4400 # find the pathname to a BSD- or MS-compatible name lister
4401 AC_DEFUN([LT_PATH_NM],
4402 [AC_REQUIRE([AC_PROG_CC])dnl
4403 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
4404 [if test -n "$NM"; then
4405 # Let the user override the test.
4408 lt_nm_to_check="${ac_tool_prefix}nm"
4409 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4410 lt_nm_to_check="$lt_nm_to_check nm"
4412 for lt_tmp_nm in $lt_nm_to_check; do
4413 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4414 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4416 test -z "$ac_dir" && ac_dir=.
4417 tmp_nm="$ac_dir/$lt_tmp_nm"
4418 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
4419 # Check to see if the nm accepts a BSD-compat flag.
4420 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4421 # nm: unknown option "B" ignored
4422 # Tru64's nm complains that /dev/null is an invalid object file
4423 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
4424 */dev/null* | *'Invalid file or object type'*)
4425 lt_cv_path_NM="$tmp_nm -B"
4429 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4431 lt_cv_path_NM="$tmp_nm -p"
4435 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4436 continue # so that we can try to find one that supports BSD flags
4445 : ${lt_cv_path_NM=no}
4447 if test "$lt_cv_path_NM" != "no"; then
4450 # Didn't find any BSD compatible name lister, look for dumpbin.
4451 if test -n "$DUMPBIN"; then :
4452 # Let the user override the test.
4454 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
4455 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
4457 DUMPBIN="$DUMPBIN -symbols"
4465 if test "$DUMPBIN" != ":"; then
4469 test -z "$NM" && NM=nm
4471 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
4473 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
4474 [lt_cv_nm_interface="BSD nm"
4475 echo "int some_variable = 0;" > conftest.$ac_ext
4476 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
4477 (eval "$ac_compile" 2>conftest.err)
4478 cat conftest.err >&AS_MESSAGE_LOG_FD
4479 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
4480 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4481 cat conftest.err >&AS_MESSAGE_LOG_FD
4482 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
4483 cat conftest.out >&AS_MESSAGE_LOG_FD
4484 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4485 lt_cv_nm_interface="MS dumpbin"
4491 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
4492 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
4493 dnl aclocal-1.4 backwards compatibility:
4494 dnl AC_DEFUN([AM_PROG_NM], [])
4495 dnl AC_DEFUN([AC_PROG_NM], [])
4497 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4498 # --------------------------------
4499 # how to determine the name of the shared library
4500 # associated with a specific link library.
4501 # -- PORTME fill in with the dynamic library characteristics
4502 m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
4503 [m4_require([_LT_DECL_EGREP])
4504 m4_require([_LT_DECL_OBJDUMP])
4505 m4_require([_LT_DECL_DLLTOOL])
4506 AC_CACHE_CHECK([how to associate runtime and link libraries],
4507 lt_cv_sharedlib_from_linklib_cmd,
4508 [lt_cv_sharedlib_from_linklib_cmd='unknown'
4511 cygwin* | mingw* | pw32* | cegcc*)
4512 # two different shell functions defined in ltmain.sh
4513 # decide which to use based on capabilities of $DLLTOOL
4514 case `$DLLTOOL --help 2>&1` in
4515 *--identify-strict*)
4516 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
4519 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
4524 # fallback: assume linklib IS sharedlib
4525 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
4529 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
4530 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
4532 _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
4533 [Command to associate shared and link libraries])
4534 ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4537 # _LT_PATH_MANIFEST_TOOL
4538 # ----------------------
4539 # locate the manifest tool
4540 m4_defun([_LT_PATH_MANIFEST_TOOL],
4541 [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
4542 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
4543 AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
4544 [lt_cv_path_mainfest_tool=no
4545 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
4546 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
4547 cat conftest.err >&AS_MESSAGE_LOG_FD
4548 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
4549 lt_cv_path_mainfest_tool=yes
4552 if test "x$lt_cv_path_mainfest_tool" != xyes; then
4555 _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
4556 ])# _LT_PATH_MANIFEST_TOOL
4561 # check for math library
4562 AC_DEFUN([LT_LIB_M],
4563 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4566 *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
4567 # These system don't have libm, or don't need it
4570 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
4571 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
4574 AC_CHECK_LIB(m, cos, LIBM="-lm")
4581 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
4582 dnl aclocal-1.4 backwards compatibility:
4583 dnl AC_DEFUN([AC_CHECK_LIBM], [])
4586 # _LT_COMPILER_NO_RTTI([TAGNAME])
4587 # -------------------------------
4588 m4_defun([_LT_COMPILER_NO_RTTI],
4589 [m4_require([_LT_TAG_COMPILER])dnl
4591 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4593 if test "$GCC" = yes; then
4594 case $cc_basename in
4596 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
4598 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
4601 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4602 lt_cv_prog_compiler_rtti_exceptions,
4603 [-fno-rtti -fno-exceptions], [],
4604 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4606 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
4607 [Compiler flag to turn off builtin functions])
4608 ])# _LT_COMPILER_NO_RTTI
4611 # _LT_CMD_GLOBAL_SYMBOLS
4612 # ----------------------
4613 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
4614 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4615 AC_REQUIRE([AC_PROG_CC])dnl
4616 AC_REQUIRE([AC_PROG_AWK])dnl
4617 AC_REQUIRE([LT_PATH_NM])dnl
4618 AC_REQUIRE([LT_PATH_LD])dnl
4619 m4_require([_LT_DECL_SED])dnl
4620 m4_require([_LT_DECL_EGREP])dnl
4621 m4_require([_LT_TAG_COMPILER])dnl
4623 # Check for command to grab the raw symbol name followed by C symbol from nm.
4624 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4625 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4627 # These are sane defaults that work on at least a few old systems.
4628 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4630 # Character class describing NM global symbol codes.
4631 symcode='[[BCDEGRST]]'
4633 # Regexp to match symbols that can be accessed directly from C.
4634 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4636 # Define system-specific variables.
4641 cygwin* | mingw* | pw32* | cegcc*)
4642 symcode='[[ABCDGISTW]]'
4645 if test "$host_cpu" = ia64; then
4646 symcode='[[ABCDEGRST]]'
4650 symcode='[[BCDEGRST]]'
4653 symcode='[[BCDEGQRST]]'
4664 sysv5* | sco5v6* | unixware* | OpenUNIX*)
4668 symcode='[[DFNSTU]]'
4672 # If we're using GNU nm, then use its standard symbol codes.
4673 case `$NM -V 2>&1` in
4674 *GNU* | *'with BFD'*)
4675 symcode='[[ABCDGIRSTW]]' ;;
4678 # Transform an extracted symbol line into a proper C declaration.
4679 # Some systems (esp. on ia64) link data and code symbols differently,
4680 # so use this general approach.
4681 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4683 # Transform an extracted symbol line into symbol name and symbol address
4684 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
4685 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
4687 # Handle CRLF in mingw tool chain
4691 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4695 # Try without a prefix underscore, then with it.
4696 for ac_symprfx in "" "_"; do
4698 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4699 symxfrm="\\1 $ac_symprfx\\2 \\2"
4701 # Write the raw and C identifiers.
4702 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4703 # Fake it for dumpbin and say T for any non-static function
4704 # and D for any global variable.
4705 # Also find C++ and __fastcall symbols from MSVC++,
4706 # which start with @ or ?.
4707 lt_cv_sys_global_symbol_pipe="$AWK ['"\
4708 " {last_section=section; section=\$ 3};"\
4709 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
4710 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
4711 " \$ 0!~/External *\|/{next};"\
4712 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
4713 " {if(hide[section]) next};"\
4714 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
4715 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
4716 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
4717 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
4718 " ' prfx=^$ac_symprfx]"
4720 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4722 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
4724 # Check to see that the pipe works correctly.
4728 cat > conftest.$ac_ext <<_LT_EOF
4733 void nm_test_func(void);
4734 void nm_test_func(void){}
4738 int main(){nm_test_var='a';nm_test_func();return(0);}
4741 if AC_TRY_EVAL(ac_compile); then
4742 # Now try to grab the symbols.
4744 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
4745 # Try sorting and uniquifying the output.
4746 if sort "$nlist" | uniq > "$nlist"T; then
4747 mv -f "$nlist"T "$nlist"
4752 # Make sure that we snagged all the symbols we need.
4753 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
4754 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
4755 cat <<_LT_EOF > conftest.$ac_ext
4756 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
4757 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
4758 /* DATA imports from DLLs on WIN32 con't be const, because runtime
4759 relocations are performed -- see ld's documentation on pseudo-relocs. */
4760 # define LT@&t@_DLSYM_CONST
4761 #elif defined(__osf__)
4762 /* This system does not cope well with relocations in const data. */
4763 # define LT@&t@_DLSYM_CONST
4765 # define LT@&t@_DLSYM_CONST const
4773 # Now generate the symbol file.
4774 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
4776 cat <<_LT_EOF >> conftest.$ac_ext
4778 /* The mapping between symbol names and symbols. */
4779 LT@&t@_DLSYM_CONST struct {
4783 lt__PROGRAM__LTX_preloaded_symbols[[]] =
4785 { "@PROGRAM@", (void *) 0 },
4787 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4788 cat <<\_LT_EOF >> conftest.$ac_ext
4792 /* This works around a problem in FreeBSD linker */
4793 #ifdef FREEBSD_WORKAROUND
4794 static const void *lt_preloaded_setup() {
4795 return lt__PROGRAM__LTX_preloaded_symbols;
4803 # Now try linking the two files.
4804 mv conftest.$ac_objext conftstm.$ac_objext
4805 lt_globsym_save_LIBS=$LIBS
4806 lt_globsym_save_CFLAGS=$CFLAGS
4807 LIBS="conftstm.$ac_objext"
4808 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4809 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4812 LIBS=$lt_globsym_save_LIBS
4813 CFLAGS=$lt_globsym_save_CFLAGS
4815 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4818 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4821 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4824 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4825 cat conftest.$ac_ext >&5
4827 rm -rf conftest* conftst*
4829 # Do not use the global_symbol_pipe unless it works.
4830 if test "$pipe_works" = yes; then
4833 lt_cv_sys_global_symbol_pipe=
4837 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4838 lt_cv_sys_global_symbol_to_cdecl=
4840 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4841 AC_MSG_RESULT(failed)
4846 # Response file support.
4847 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4848 nm_file_list_spec='@'
4849 elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
4850 nm_file_list_spec='@'
4853 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
4854 [Take the output of nm and produce a listing of raw symbols and C names])
4855 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
4856 [Transform the output of nm in a proper C declaration])
4857 _LT_DECL([global_symbol_to_c_name_address],
4858 [lt_cv_sys_global_symbol_to_c_name_address], [1],
4859 [Transform the output of nm in a C name address pair])
4860 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
4861 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
4862 [Transform the output of nm in a C name address pair when lib prefix is needed])
4863 _LT_DECL([], [nm_file_list_spec], [1],
4864 [Specify filename containing input files for $NM])
4865 ]) # _LT_CMD_GLOBAL_SYMBOLS
4868 # _LT_COMPILER_PIC([TAGNAME])
4869 # ---------------------------
4870 m4_defun([_LT_COMPILER_PIC],
4871 [m4_require([_LT_TAG_COMPILER])dnl
4872 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
4873 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4874 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4876 m4_if([$1], [CXX], [
4877 # C++ specific cases for pic, static, wl, etc.
4878 if test "$GXX" = yes; then
4879 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4880 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4884 # All AIX code is PIC.
4885 if test "$host_cpu" = ia64; then
4886 # AIX 5 now supports IA64 processor
4887 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4894 # see comment about AmigaOS4 .so support
4895 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4898 # FIXME: we need at least 68020 code to build shared libraries, but
4899 # adding the `-m68020' flag to GCC prevents building anything better,
4901 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4906 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4907 # PIC is the default for these OSes.
4909 mingw* | cygwin* | os2* | pw32* | cegcc*)
4910 # This hack is so that the source file can tell whether it is being
4911 # built for inclusion in a dll (and should export symbols for example).
4912 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4913 # (--disable-auto-import) libraries
4914 m4_if([$1], [GCJ], [],
4915 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4917 darwin* | rhapsody*)
4918 # PIC is the default on this platform
4919 # Common symbols not allowed in MH_DYLIB files
4920 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4923 # DJGPP does not support shared libraries at all
4924 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4927 # PIC is the default for Haiku.
4928 # The "-static" flag exists, but is broken.
4929 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4932 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4933 # Instead, we relocate shared libraries at runtime.
4936 if test -d /usr/nec; then
4937 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4941 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4942 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4943 # sets the default TLS model and affects inlining.
4948 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4953 # QNX uses GNU C++, but need to define -shared option too, otherwise
4955 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4958 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4964 # All AIX code is PIC.
4965 if test "$host_cpu" = ia64; then
4966 # AIX 5 now supports IA64 processor
4967 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4969 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4973 case $cc_basename in
4975 # Green Hills C++ Compiler
4976 # _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"
4980 mingw* | cygwin* | os2* | pw32* | cegcc*)
4981 # This hack is so that the source file can tell whether it is being
4982 # built for inclusion in a dll (and should export symbols for example).
4983 m4_if([$1], [GCJ], [],
4984 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4987 case $cc_basename in
4989 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4992 # Green Hills C++ Compiler
4993 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4999 freebsd* | dragonfly*)
5000 # FreeBSD uses GNU C++
5002 hpux9* | hpux10* | hpux11*)
5003 case $cc_basename in
5005 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5006 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5007 if test "$host_cpu" != ia64; then
5008 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5012 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5013 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5019 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5028 # This is c89, which is MS Visual C++ (no shared libs)
5029 # Anyone wants to do a port?
5031 irix5* | irix6* | nonstopux*)
5032 case $cc_basename in
5034 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5035 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5036 # CC pic flag -KPIC is the default.
5042 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
5043 case $cc_basename in
5046 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5047 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5050 # old Intel C++ for x86_64 which still supported -KPIC.
5051 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5052 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5053 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5056 # Intel C++, used to be incompatible with GCC.
5057 # ICC 10 doesn't accept -KPIC any more.
5058 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5060 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5063 # Portland Group C++ compiler
5064 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5065 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5066 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5070 # Make sure the PIC flag is empty. It appears that all Alpha
5071 # Linux and Compaq Tru64 Unix objects are PIC.
5072 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5073 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5075 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
5076 # IBM XL 8.0, 9.0 on PPC and BlueGene
5077 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5078 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5079 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5082 case `$CC -V 2>&1 | sed 5q` in
5085 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5086 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5087 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5098 case $cc_basename in
5100 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5106 netbsd* | netbsdelf*-gnu)
5109 # QNX uses GNU C++, but need to define -shared option too, otherwise
5111 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5113 osf3* | osf4* | osf5*)
5114 case $cc_basename in
5116 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5119 # Rational C++ 2.4.1
5120 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5123 # Digital/Compaq C++
5124 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5125 # Make sure the PIC flag is empty. It appears that all Alpha
5126 # Linux and Compaq Tru64 Unix objects are PIC.
5127 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5128 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5137 case $cc_basename in
5139 # Sun C++ 4.2, 5.x and Centerline C++
5140 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5141 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5142 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5145 # Green Hills C++ Compiler
5146 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5153 case $cc_basename in
5156 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5157 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5161 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5167 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5168 case $cc_basename in
5170 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5171 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5172 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5177 case $cc_basename in
5179 # NonStop-UX NCC 3.20
5180 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5189 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5195 if test "$GCC" = yes; then
5196 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5197 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5201 # All AIX code is PIC.
5202 if test "$host_cpu" = ia64; then
5203 # AIX 5 now supports IA64 processor
5204 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5211 # see comment about AmigaOS4 .so support
5212 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5215 # FIXME: we need at least 68020 code to build shared libraries, but
5216 # adding the `-m68020' flag to GCC prevents building anything better,
5218 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5223 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5224 # PIC is the default for these OSes.
5227 mingw* | cygwin* | pw32* | os2* | cegcc*)
5228 # This hack is so that the source file can tell whether it is being
5229 # built for inclusion in a dll (and should export symbols for example).
5230 # Although the cygwin gcc ignores -fPIC, still need this for old-style
5231 # (--disable-auto-import) libraries
5232 m4_if([$1], [GCJ], [],
5233 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5236 darwin* | rhapsody*)
5237 # PIC is the default on this platform
5238 # Common symbols not allowed in MH_DYLIB files
5239 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5243 # PIC is the default for Haiku.
5244 # The "-static" flag exists, but is broken.
5245 _LT_TAGVAR(lt_prog_compiler_static, $1)=
5249 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5250 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
5251 # sets the default TLS model and affects inlining.
5257 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5263 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5264 # Instead, we relocate shared libraries at runtime.
5268 # Just because we use GCC doesn't mean we suddenly get shared libraries
5269 # on systems that don't support them.
5270 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5275 # QNX uses GNU C++, but need to define -shared option too, otherwise
5277 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5281 if test -d /usr/nec; then
5282 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5287 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5291 case $cc_basename in
5292 nvcc*) # Cuda Compiler Driver 2.2
5293 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
5294 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5295 _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
5300 # PORTME Check for flag to pass linker flags through the system compiler.
5303 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5304 if test "$host_cpu" = ia64; then
5305 # AIX 5 now supports IA64 processor
5306 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5308 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5312 mingw* | cygwin* | pw32* | os2* | cegcc*)
5313 # This hack is so that the source file can tell whether it is being
5314 # built for inclusion in a dll (and should export symbols for example).
5315 m4_if([$1], [GCJ], [],
5316 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5319 hpux9* | hpux10* | hpux11*)
5320 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5321 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5328 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5331 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5332 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5335 irix5* | irix6* | nonstopux*)
5336 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5337 # PIC (with -KPIC) is the default.
5338 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5341 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
5342 case $cc_basename in
5343 # old Intel for x86_64 which still supported -KPIC.
5345 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5346 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5347 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5349 # icc used to be incompatible with GCC.
5350 # ICC 10 doesn't accept -KPIC any more.
5352 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5353 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5354 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5356 # Lahey Fortran 8.1.
5358 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5359 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
5360 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
5363 # NAG Fortran compiler
5364 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
5365 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5366 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5368 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
5369 # Portland Group compilers (*not* the Pentium gcc compiler,
5370 # which looks to be a dead project)
5371 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5372 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5373 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5376 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5377 # All Alpha code is PIC.
5378 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5380 xl* | bgxl* | bgf* | mpixl*)
5381 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
5382 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5383 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5384 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5387 case `$CC -V 2>&1 | sed 5q` in
5388 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
5389 # Sun Fortran 8.3 passes all unrecognized flags to the linker
5390 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5391 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5392 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
5394 *Sun\ F* | *Sun*Fortran*)
5395 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5396 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5397 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5401 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5402 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5403 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5405 *Intel*\ [[CF]]*Compiler*)
5406 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5407 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5408 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5411 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5412 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5413 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5421 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5422 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5426 # QNX uses GNU C++, but need to define -shared option too, otherwise
5428 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5431 osf3* | osf4* | osf5*)
5432 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5433 # All OSF/1 code is PIC.
5434 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5438 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5442 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5443 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5444 case $cc_basename in
5445 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
5446 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5448 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5453 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5454 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5455 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5458 sysv4 | sysv4.2uw2* | sysv4.3*)
5459 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5460 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5461 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5465 if test -d /usr/nec ;then
5466 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5467 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5471 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5472 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5473 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5474 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5478 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5479 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5483 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5484 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5488 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5494 # For platforms which do not support PIC, -DPIC is meaningless:
5496 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5499 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
5503 AC_CACHE_CHECK([for $compiler option to produce PIC],
5504 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
5505 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
5506 _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
5509 # Check to make sure the PIC flag actually works.
5511 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5512 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
5513 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
5514 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
5515 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
5517 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5519 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
5520 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5522 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
5523 [Additional compiler flags for building library objects])
5525 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
5526 [How to pass a linker flag through the compiler])
5528 # Check to make sure the static flag actually works.
5530 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
5531 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
5532 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
5533 $lt_tmp_static_flag,
5535 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
5536 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
5537 [Compiler flag to prevent dynamic linking])
5538 ])# _LT_COMPILER_PIC
5541 # _LT_LINKER_SHLIBS([TAGNAME])
5542 # ----------------------------
5543 # See if the linker supports building shared libraries.
5544 m4_defun([_LT_LINKER_SHLIBS],
5545 [AC_REQUIRE([LT_PATH_LD])dnl
5546 AC_REQUIRE([LT_PATH_NM])dnl
5547 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5548 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5549 m4_require([_LT_DECL_EGREP])dnl
5550 m4_require([_LT_DECL_SED])dnl
5551 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
5552 m4_require([_LT_TAG_COMPILER])dnl
5553 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5554 m4_if([$1], [CXX], [
5555 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5556 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5559 # If we're using GNU nm, then we don't want the "-C" option.
5560 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5561 # Also, AIX nm treats weak defined symbols like other global defined
5562 # symbols, whereas GNU nm marks them as "W".
5563 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5564 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5566 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5570 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5572 cygwin* | mingw* | cegcc*)
5573 case $cc_basename in
5575 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5578 _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'
5579 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5583 linux* | k*bsd*-gnu | gnu*)
5584 _LT_TAGVAR(link_all_deplibs, $1)=no
5587 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5592 _LT_TAGVAR(allow_undefined_flag, $1)=
5593 _LT_TAGVAR(always_export_symbols, $1)=no
5594 _LT_TAGVAR(archive_cmds, $1)=
5595 _LT_TAGVAR(archive_expsym_cmds, $1)=
5596 _LT_TAGVAR(compiler_needs_object, $1)=no
5597 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5598 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5599 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5600 _LT_TAGVAR(hardcode_automatic, $1)=no
5601 _LT_TAGVAR(hardcode_direct, $1)=no
5602 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5603 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5604 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5605 _LT_TAGVAR(hardcode_minus_L, $1)=no
5606 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5607 _LT_TAGVAR(inherit_rpath, $1)=no
5608 _LT_TAGVAR(link_all_deplibs, $1)=unknown
5609 _LT_TAGVAR(module_cmds, $1)=
5610 _LT_TAGVAR(module_expsym_cmds, $1)=
5611 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
5612 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5613 _LT_TAGVAR(thread_safe_flag_spec, $1)=
5614 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5615 # include_expsyms should be a list of space-separated symbols to be *always*
5616 # included in the symbol list
5617 _LT_TAGVAR(include_expsyms, $1)=
5618 # exclude_expsyms can be an extended regexp of symbols to exclude
5619 # it will be wrapped by ` (' and `)$', so one must not match beginning or
5620 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5621 # as well as any symbol that contains `d'.
5622 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5623 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5624 # platforms (ab)use it in PIC code, but their linkers get confused if
5625 # the symbol is explicitly referenced. Since portable code cannot
5626 # rely on this symbol name, it's probably fine to never include it in
5627 # preloaded symbol tables.
5628 # Exclude shared library initialization/finalization symbols.
5629 dnl Note also adjust exclude_expsyms for C++ above.
5630 extract_expsyms_cmds=
5633 cygwin* | mingw* | pw32* | cegcc*)
5634 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5635 # When not using gcc, we currently assume that we are using
5636 # Microsoft Visual C++.
5637 if test "$GCC" != yes; then
5642 # we just hope/assume this is gcc and not c89 (= MSVC++)
5648 linux* | k*bsd*-gnu | gnu*)
5649 _LT_TAGVAR(link_all_deplibs, $1)=no
5653 _LT_TAGVAR(ld_shlibs, $1)=yes
5655 # On some targets, GNU ld is compatible enough with the native linker
5656 # that we're better off using the native interface for both.
5657 lt_use_gnu_ld_interface=no
5658 if test "$with_gnu_ld" = yes; then
5661 # The AIX port of GNU ld has always aspired to compatibility
5662 # with the native linker. However, as the warning in the GNU ld
5663 # block says, versions before 2.19.5* couldn't really create working
5664 # shared libraries, regardless of the interface used.
5665 case `$LD -v 2>&1` in
5666 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
5667 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
5668 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
5670 lt_use_gnu_ld_interface=yes
5675 lt_use_gnu_ld_interface=yes
5680 if test "$lt_use_gnu_ld_interface" = yes; then
5681 # If archive_cmds runs LD, not CC, wlarc should be empty
5684 # Set some defaults for GNU ld with shared library support. These
5685 # are reset later if shared libraries are not supported. Putting them
5686 # here allows them to be overridden if necessary.
5687 runpath_var=LD_RUN_PATH
5688 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5689 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5690 # ancient GNU ld didn't support --whole-archive et. al.
5691 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
5692 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5694 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5696 supports_anon_versioning=no
5697 case `$LD -v 2>&1` in
5698 *GNU\ gold*) supports_anon_versioning=yes ;;
5699 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5700 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5701 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5702 *\ 2.11.*) ;; # other 2.11 versions
5703 *) supports_anon_versioning=yes ;;
5706 # See if GNU ld supports shared libraries.
5709 # On AIX/PPC, the GNU linker is very broken
5710 if test "$host_cpu" != ia64; then
5711 _LT_TAGVAR(ld_shlibs, $1)=no
5714 *** Warning: the GNU linker, at least up to release 2.19, is reported
5715 *** to be unable to reliably create shared libraries on AIX.
5716 *** Therefore, libtool is disabling shared libraries support. If you
5717 *** really care for shared libraries, you may want to install binutils
5718 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
5719 *** You will then need to restart the configuration process.
5728 # see comment about AmigaOS4 .so support
5729 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5730 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5733 _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)'
5734 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5735 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5741 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5742 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5743 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5744 # support --undefined. This deserves some investigation. FIXME
5745 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5747 _LT_TAGVAR(ld_shlibs, $1)=no
5751 cygwin* | mingw* | pw32* | cegcc*)
5752 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5753 # as there is no search path for DLLs.
5754 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5755 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
5756 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5757 _LT_TAGVAR(always_export_symbols, $1)=no
5758 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5759 _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'
5760 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5762 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5763 _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'
5764 # If the export-symbols file already is a .def file (1st line
5765 # is EXPORTS), use it as is; otherwise, prepend...
5766 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5767 cp $export_symbols $output_objdir/$soname.def;
5769 echo EXPORTS > $output_objdir/$soname.def;
5770 cat $export_symbols >> $output_objdir/$soname.def;
5772 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5774 _LT_TAGVAR(ld_shlibs, $1)=no
5779 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5780 _LT_TAGVAR(link_all_deplibs, $1)=yes
5784 _LT_TAGVAR(hardcode_direct, $1)=no
5785 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5786 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5787 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5788 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5789 # Instead, shared libraries are loaded at an image base (0x10000000 by
5790 # default) and relocated if they conflict, which is a slow very memory
5791 # consuming and fragmenting process. To avoid this, we pick a random,
5792 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
5793 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
5794 _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'
5795 _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'
5798 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
5800 if test "$host_os" = linux-dietlibc; then
5801 case $cc_basename in
5802 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
5805 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
5806 && test "$tmp_diet" = no
5808 tmp_addflag=' $pic_flag'
5809 tmp_sharedflag='-shared'
5810 case $cc_basename,$host_cpu in
5811 pgcc*) # Portland Group C compiler
5812 _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'
5813 tmp_addflag=' $pic_flag'
5815 pgf77* | pgf90* | pgf95* | pgfortran*)
5816 # Portland Group f77 and f90 compilers
5817 _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'
5818 tmp_addflag=' $pic_flag -Mnomain' ;;
5819 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5820 tmp_addflag=' -i_dynamic' ;;
5821 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5822 tmp_addflag=' -i_dynamic -nofor_main' ;;
5823 ifc* | ifort*) # Intel Fortran compiler
5824 tmp_addflag=' -nofor_main' ;;
5825 lf95*) # Lahey Fortran 8.1
5826 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5827 tmp_sharedflag='--shared' ;;
5828 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
5829 tmp_sharedflag='-qmkshrobj'
5831 nvcc*) # Cuda Compiler Driver 2.2
5832 _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'
5833 _LT_TAGVAR(compiler_needs_object, $1)=yes
5836 case `$CC -V 2>&1 | sed 5q` in
5837 *Sun\ C*) # Sun C 5.9
5838 _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'
5839 _LT_TAGVAR(compiler_needs_object, $1)=yes
5840 tmp_sharedflag='-G' ;;
5841 *Sun\ F*) # Sun Fortran 8.3
5842 tmp_sharedflag='-G' ;;
5844 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5846 if test "x$supports_anon_versioning" = xyes; then
5847 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5848 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5849 echo "local: *; };" >> $output_objdir/$libname.ver~
5850 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5853 case $cc_basename in
5854 xlf* | bgf* | bgxlf* | mpixlf*)
5855 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
5856 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
5857 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5858 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
5859 if test "x$supports_anon_versioning" = xyes; then
5860 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5861 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5862 echo "local: *; };" >> $output_objdir/$libname.ver~
5863 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5868 _LT_TAGVAR(ld_shlibs, $1)=no
5872 netbsd* | netbsdelf*-gnu)
5873 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5874 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5877 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5878 _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'
5883 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
5884 _LT_TAGVAR(ld_shlibs, $1)=no
5887 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5888 *** create shared libraries on Solaris systems. Therefore, libtool
5889 *** is disabling shared libraries support. We urge you to upgrade GNU
5890 *** binutils to release 2.9.1 or newer. Another option is to modify
5891 *** your PATH or compiler configuration so that the native linker is
5892 *** used, and then restart.
5895 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5896 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5897 _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'
5899 _LT_TAGVAR(ld_shlibs, $1)=no
5903 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5904 case `$LD -v 2>&1` in
5905 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5906 _LT_TAGVAR(ld_shlibs, $1)=no
5909 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
5910 *** reliably create shared libraries on SCO systems. Therefore, libtool
5911 *** is disabling shared libraries support. We urge you to upgrade GNU
5912 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5913 *** your PATH or compiler configuration so that the native linker is
5914 *** used, and then restart.
5919 # For security reasons, it is highly recommended that you always
5920 # use absolute paths for naming shared libraries, and exclude the
5921 # DT_RUNPATH tag from executables and libraries. But doing so
5922 # requires that you compile everything twice, which is a pain.
5923 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5924 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5925 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5926 _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'
5928 _LT_TAGVAR(ld_shlibs, $1)=no
5935 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5937 _LT_TAGVAR(hardcode_direct, $1)=yes
5938 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5942 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5943 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5944 _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'
5946 _LT_TAGVAR(ld_shlibs, $1)=no
5951 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
5953 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5954 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5955 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5958 # PORTME fill in a description of your system's linker (not GNU ld)
5961 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5962 _LT_TAGVAR(always_export_symbols, $1)=yes
5963 _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'
5964 # Note: this linker hardcodes the directories in LIBPATH if there
5965 # are no directories specified by -L.
5966 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5967 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5968 # Neither direct hardcoding nor static linking is supported with a
5970 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5975 if test "$host_cpu" = ia64; then
5976 # On IA64, the linker does run time linking by default, so we don't
5977 # have to do anything special.
5978 aix_use_runtimelinking=no
5979 exp_sym_flag='-Bexport'
5982 # If we're using GNU nm, then we don't want the "-C" option.
5983 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5984 # Also, AIX nm treats weak defined symbols like other global
5985 # defined symbols, whereas GNU nm marks them as "W".
5986 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5987 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5989 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5991 aix_use_runtimelinking=no
5993 # Test if we are trying to use run time linking or normal
5994 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5995 # need to do runtime linking.
5996 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5997 for ld_flag in $LDFLAGS; do
5998 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5999 aix_use_runtimelinking=yes
6006 exp_sym_flag='-bexport'
6007 no_entry_flag='-bnoentry'
6010 # When large executables or shared objects are built, AIX ld can
6011 # have problems creating the table of contents. If linking a library
6012 # or program results in "error TOC overflow" add -mminimal-toc to
6013 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6014 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6016 _LT_TAGVAR(archive_cmds, $1)=''
6017 _LT_TAGVAR(hardcode_direct, $1)=yes
6018 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6019 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6020 _LT_TAGVAR(link_all_deplibs, $1)=yes
6021 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6023 if test "$GCC" = yes; then
6024 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6025 # We only want to do this on AIX 4.2 and lower, the check
6026 # below for broken collect2 doesn't work under 4.3+
6027 collect2name=`${CC} -print-prog-name=collect2`
6028 if test -f "$collect2name" &&
6029 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6031 # We have reworked collect2
6034 # We have old collect2
6035 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6036 # It fails to find uninstalled libraries when the uninstalled
6037 # path is not listed in the libpath. Setting hardcode_minus_L
6038 # to unsupported forces relinking
6039 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6040 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6041 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6045 shared_flag='-shared'
6046 if test "$aix_use_runtimelinking" = yes; then
6047 shared_flag="$shared_flag "'${wl}-G'
6049 _LT_TAGVAR(link_all_deplibs, $1)=no
6052 if test "$host_cpu" = ia64; then
6053 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6054 # chokes on -Wl,-G. The following line is correct:
6057 if test "$aix_use_runtimelinking" = yes; then
6058 shared_flag='${wl}-G'
6060 shared_flag='${wl}-bM:SRE'
6065 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6066 # It seems that -bexpall does not export symbols beginning with
6067 # underscore (_), so it is better to generate a list of symbols to export.
6068 _LT_TAGVAR(always_export_symbols, $1)=yes
6069 if test "$aix_use_runtimelinking" = yes; then
6070 # Warning - without using the other runtime loading flags (-brtl),
6071 # -berok will link without error, but may produce a broken library.
6072 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6073 # Determine the default libpath from the value encoded in an
6075 _LT_SYS_MODULE_PATH_AIX([$1])
6076 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6077 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6079 if test "$host_cpu" = ia64; then
6080 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6081 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6082 _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"
6084 # Determine the default libpath from the value encoded in an
6086 _LT_SYS_MODULE_PATH_AIX([$1])
6087 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6088 # Warning - without using the other run time loading flags,
6089 # -berok will link without error, but may produce a broken library.
6090 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6091 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6092 if test "$with_gnu_ld" = yes; then
6093 # We only use this code for GNU lds that support --whole-archive.
6094 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6096 # Exported symbols can be pulled into shared objects from archives
6097 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6099 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6100 # This is similar to how AIX traditionally builds its shared libraries.
6101 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6109 # see comment about AmigaOS4 .so support
6110 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6111 _LT_TAGVAR(archive_expsym_cmds, $1)=''
6114 _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)'
6115 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6116 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6122 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6125 cygwin* | mingw* | pw32* | cegcc*)
6126 # When not using gcc, we currently assume that we are using
6127 # Microsoft Visual C++.
6128 # hardcode_libdir_flag_spec is actually meaningless, as there is
6129 # no search path for DLLs.
6130 case $cc_basename in
6133 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6134 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6135 _LT_TAGVAR(always_export_symbols, $1)=yes
6136 _LT_TAGVAR(file_list_spec, $1)='@'
6137 # Tell ltmain to make .lib files, not .a files.
6139 # Tell ltmain to make .dll files, not .so files.
6141 # FIXME: Setting linknames here is a bad hack.
6142 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
6143 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6144 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
6146 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
6148 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6150 # The linker will not automatically build a static lib if we build a DLL.
6151 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6152 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6153 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
6154 _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'
6156 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6157 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6158 lt_tool_outputfile="@TOOL_OUTPUT@"~
6159 case $lt_outputfile in
6162 lt_outputfile="$lt_outputfile.exe"
6163 lt_tool_outputfile="$lt_tool_outputfile.exe"
6166 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
6167 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6168 $RM "$lt_outputfile.manifest";
6172 # Assume MSVC wrapper
6173 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6174 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6175 # Tell ltmain to make .lib files, not .a files.
6177 # Tell ltmain to make .dll files, not .so files.
6179 # FIXME: Setting linknames here is a bad hack.
6180 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
6181 # The linker will automatically build a .lib file if we build a DLL.
6182 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6183 # FIXME: Should let the user specify the lib program.
6184 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6185 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6190 darwin* | rhapsody*)
6191 _LT_DARWIN_LINKER_FEATURES($1)
6195 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6196 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6197 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6200 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6201 # support. Future versions do this automatically, but an explicit c++rt0.o
6202 # does not break anything, and helps significantly (at the cost of a little
6205 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6206 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6207 _LT_TAGVAR(hardcode_direct, $1)=yes
6208 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6211 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6213 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6214 _LT_TAGVAR(hardcode_direct, $1)=yes
6215 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6216 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6219 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6220 freebsd* | dragonfly*)
6221 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6222 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6223 _LT_TAGVAR(hardcode_direct, $1)=yes
6224 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6228 if test "$GCC" = yes; then
6229 _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 $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6231 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6233 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6234 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6235 _LT_TAGVAR(hardcode_direct, $1)=yes
6237 # hardcode_minus_L: Not really in the search PATH,
6238 # but as the default location of the library.
6239 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6240 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6244 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
6245 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6247 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6249 if test "$with_gnu_ld" = no; then
6250 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6251 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6252 _LT_TAGVAR(hardcode_direct, $1)=yes
6253 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6254 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6255 # hardcode_minus_L: Not really in the search PATH,
6256 # but as the default location of the library.
6257 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6262 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
6265 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6268 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6271 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6277 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6280 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6284 # Older versions of the 11.00 compiler do not understand -b yet
6285 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
6286 _LT_LINKER_OPTION([if $CC understands -b],
6287 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
6288 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
6289 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
6290 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
6294 if test "$with_gnu_ld" = no; then
6295 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6296 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6300 _LT_TAGVAR(hardcode_direct, $1)=no
6301 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6304 _LT_TAGVAR(hardcode_direct, $1)=yes
6305 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6306 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6308 # hardcode_minus_L: Not really in the search PATH,
6309 # but as the default location of the library.
6310 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6316 irix5* | irix6* | nonstopux*)
6317 if test "$GCC" = yes; then
6318 _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'
6319 # Try to use the -exported_symbol ld option, if it does not
6320 # work, assume that -exports_file does not work either and
6321 # implicitly export all symbols.
6322 # This should be the same for all languages, so no per-tag cache variable.
6323 AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
6324 [lt_cv_irix_exported_symbol],
6325 [save_LDFLAGS="$LDFLAGS"
6326 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
6329 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
6330 [C++], [[int foo (void) { return 0; }]],
6337 [lt_cv_irix_exported_symbol=yes],
6338 [lt_cv_irix_exported_symbol=no])
6339 LDFLAGS="$save_LDFLAGS"])
6340 if test "$lt_cv_irix_exported_symbol" = yes; then
6341 _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'
6344 _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'
6345 _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'
6347 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6348 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6349 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6350 _LT_TAGVAR(inherit_rpath, $1)=yes
6351 _LT_TAGVAR(link_all_deplibs, $1)=yes
6354 netbsd* | netbsdelf*-gnu)
6355 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6356 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6358 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6360 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6361 _LT_TAGVAR(hardcode_direct, $1)=yes
6362 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6366 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6367 _LT_TAGVAR(hardcode_direct, $1)=yes
6368 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6369 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6370 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6377 if test -f /usr/libexec/ld.so; then
6378 _LT_TAGVAR(hardcode_direct, $1)=yes
6379 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6380 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6381 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6382 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6383 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6384 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6385 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6388 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6389 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6390 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6393 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6394 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6399 _LT_TAGVAR(ld_shlibs, $1)=no
6404 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6405 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6406 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6407 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
6408 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6412 if test "$GCC" = yes; then
6413 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6414 _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'
6416 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6417 _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'
6419 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6420 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6421 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6424 osf4* | osf5*) # as osf3* with the addition of -msym flag
6425 if test "$GCC" = yes; then
6426 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6427 _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'
6428 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6430 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6431 _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'
6432 _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~
6433 $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'
6435 # Both c and cxx compiler support -rpath directly
6436 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6438 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6439 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6443 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
6444 if test "$GCC" = yes; then
6446 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6447 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6448 $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'
6450 case `$CC -V 2>&1` in
6453 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6454 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6455 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
6459 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
6460 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6461 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6465 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6466 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6468 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6470 # The compiler driver will combine and reorder linker options,
6471 # but understands `-z linker_flag'. GCC discards it without `$wl',
6472 # but is careful enough not to reorder.
6473 # Supported since Solaris 2.6 (maybe 2.5.1?)
6474 if test "$GCC" = yes; then
6475 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6477 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6481 _LT_TAGVAR(link_all_deplibs, $1)=yes
6485 if test "x$host_vendor" = xsequent; then
6486 # Use $CC to link under sequent, because it throws in some extra .o
6487 # files that make .init and .fini sections work.
6488 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6490 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6492 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6493 _LT_TAGVAR(hardcode_direct, $1)=yes
6494 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6495 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6499 case $host_vendor in
6501 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6502 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6505 ## LD is ld it makes a PLAMLIB
6506 ## CC just makes a GrossModule.
6507 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6508 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6509 _LT_TAGVAR(hardcode_direct, $1)=no
6512 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6513 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6516 runpath_var='LD_RUN_PATH'
6517 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6521 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6522 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6523 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6527 if test -d /usr/nec; then
6528 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6529 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6530 runpath_var=LD_RUN_PATH
6531 hardcode_runpath_var=yes
6532 _LT_TAGVAR(ld_shlibs, $1)=yes
6536 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6537 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6538 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6539 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6540 runpath_var='LD_RUN_PATH'
6542 if test "$GCC" = yes; then
6543 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6544 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6546 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6547 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6551 sysv5* | sco3.2v5* | sco5v6*)
6552 # Note: We can NOT use -z defs as we might desire, because we do not
6553 # link with -lc, and that would cause any symbols used from libc to
6554 # always be unresolved, which means just about no library would
6555 # ever link correctly. If we're not using GNU ld we use -z text
6556 # though, which does catch some bad symbols but isn't as heavy-handed
6558 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6559 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6560 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6561 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6562 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6563 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6564 _LT_TAGVAR(link_all_deplibs, $1)=yes
6565 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6566 runpath_var='LD_RUN_PATH'
6568 if test "$GCC" = yes; then
6569 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6570 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6572 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6573 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6578 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6579 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6580 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6584 _LT_TAGVAR(ld_shlibs, $1)=no
6588 if test x$host_vendor = xsni; then
6590 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6591 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
6597 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6598 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6600 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
6602 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
6603 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
6604 _LT_DECL([], [extract_expsyms_cmds], [2],
6605 [The commands to extract the exported symbol list from a shared archive])
6608 # Do we need to explicitly link libc?
6610 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
6612 # Assume -lc should be added
6613 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6615 if test "$enable_shared" = yes && test "$GCC" = yes; then
6616 case $_LT_TAGVAR(archive_cmds, $1) in
6618 # FIXME: we may have to deal with multi-command sequences.
6621 # Test whether the compiler implicitly links with -lc since on some
6622 # systems, -lgcc has to come before -lc. If gcc already passes -lc
6623 # to ld, don't add -lc before -lgcc.
6624 AC_CACHE_CHECK([whether -lc should be explicitly linked in],
6625 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
6627 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6629 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6632 libobjs=conftest.$ac_objext
6634 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
6635 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
6641 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
6642 _LT_TAGVAR(allow_undefined_flag, $1)=
6643 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
6645 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6647 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6649 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6651 cat conftest.err 1>&5
6655 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
6662 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
6663 [Whether or not to add -lc for building shared libraries])
6664 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
6665 [enable_shared_with_static_runtimes], [0],
6666 [Whether or not to disallow shared libs when runtime libs are static])
6667 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
6668 [Compiler flag to allow reflexive dlopens])
6669 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
6670 [Compiler flag to generate shared objects directly from archives])
6671 _LT_TAGDECL([], [compiler_needs_object], [1],
6672 [Whether the compiler copes with passing no objects directly])
6673 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
6674 [Create an old-style archive from a shared archive])
6675 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
6676 [Create a temporary old-style archive to link instead of a shared archive])
6677 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
6678 _LT_TAGDECL([], [archive_expsym_cmds], [2])
6679 _LT_TAGDECL([], [module_cmds], [2],
6680 [Commands used to build a loadable module if different from building
6682 _LT_TAGDECL([], [module_expsym_cmds], [2])
6683 _LT_TAGDECL([], [with_gnu_ld], [1],
6684 [Whether we are building with GNU ld or not])
6685 _LT_TAGDECL([], [allow_undefined_flag], [1],
6686 [Flag that allows shared libraries with undefined symbols to be built])
6687 _LT_TAGDECL([], [no_undefined_flag], [1],
6688 [Flag that enforces no undefined symbols])
6689 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
6690 [Flag to hardcode $libdir into a binary during linking.
6691 This must work even if $libdir does not exist])
6692 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
6693 [Whether we need a single "-rpath" flag with a separated argument])
6694 _LT_TAGDECL([], [hardcode_direct], [0],
6695 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6696 DIR into the resulting binary])
6697 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
6698 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6699 DIR into the resulting binary and the resulting library dependency is
6700 "absolute", i.e impossible to change by setting ${shlibpath_var} if the
6701 library is relocated])
6702 _LT_TAGDECL([], [hardcode_minus_L], [0],
6703 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
6704 into the resulting binary])
6705 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
6706 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
6707 into the resulting binary])
6708 _LT_TAGDECL([], [hardcode_automatic], [0],
6709 [Set to "yes" if building a shared library automatically hardcodes DIR
6710 into the library and all subsequent libraries and executables linked
6712 _LT_TAGDECL([], [inherit_rpath], [0],
6713 [Set to yes if linker adds runtime paths of dependent libraries
6714 to runtime path list])
6715 _LT_TAGDECL([], [link_all_deplibs], [0],
6716 [Whether libtool must link a program against all its dependency libraries])
6717 _LT_TAGDECL([], [always_export_symbols], [0],
6718 [Set to "yes" if exported symbols are required])
6719 _LT_TAGDECL([], [export_symbols_cmds], [2],
6720 [The commands to list exported symbols])
6721 _LT_TAGDECL([], [exclude_expsyms], [1],
6722 [Symbols that should not be listed in the preloaded symbols])
6723 _LT_TAGDECL([], [include_expsyms], [1],
6724 [Symbols that must always be exported])
6725 _LT_TAGDECL([], [prelink_cmds], [2],
6726 [Commands necessary for linking programs (against libraries) with templates])
6727 _LT_TAGDECL([], [postlink_cmds], [2],
6728 [Commands necessary for finishing linking programs])
6729 _LT_TAGDECL([], [file_list_spec], [1],
6730 [Specify filename containing input files])
6731 dnl FIXME: Not yet implemented
6732 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
6733 dnl [Compiler flag to generate thread safe objects])
6734 ])# _LT_LINKER_SHLIBS
6737 # _LT_LANG_C_CONFIG([TAG])
6738 # ------------------------
6739 # Ensure that the configuration variables for a C compiler are suitably
6740 # defined. These variables are subsequently used by _LT_CONFIG to write
6741 # the compiler configuration to `libtool'.
6742 m4_defun([_LT_LANG_C_CONFIG],
6743 [m4_require([_LT_DECL_EGREP])dnl
6747 # Source file extension for C test sources.
6750 # Object file extension for compiled C test sources.
6752 _LT_TAGVAR(objext, $1)=$objext
6754 # Code to be used in simple compile tests
6755 lt_simple_compile_test_code="int some_variable = 0;"
6757 # Code to be used in simple link tests
6758 lt_simple_link_test_code='int main(){return(0);}'
6761 # Save the default compiler, since it gets overwritten when the other
6762 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
6763 compiler_DEFAULT=$CC
6765 # save warnings/boilerplate of simple test code
6766 _LT_COMPILER_BOILERPLATE
6767 _LT_LINKER_BOILERPLATE
6769 if test -n "$compiler"; then
6770 _LT_COMPILER_NO_RTTI($1)
6771 _LT_COMPILER_PIC($1)
6772 _LT_COMPILER_C_O($1)
6773 _LT_COMPILER_FILE_LOCKS($1)
6774 _LT_LINKER_SHLIBS($1)
6775 _LT_SYS_DYNAMIC_LINKER($1)
6776 _LT_LINKER_HARDCODE_LIBPATH($1)
6780 # Report which library types will actually be built
6781 AC_MSG_CHECKING([if libtool supports shared libraries])
6782 AC_MSG_RESULT([$can_build_shared])
6784 AC_MSG_CHECKING([whether to build shared libraries])
6785 test "$can_build_shared" = "no" && enable_shared=no
6787 # On AIX, shared libraries and static libraries use the same namespace, and
6788 # are all built from PIC.
6791 test "$enable_shared" = yes && enable_static=no
6792 if test -n "$RANLIB"; then
6793 archive_cmds="$archive_cmds~\$RANLIB \$lib"
6794 postinstall_cmds='$RANLIB $lib'
6799 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
6800 test "$enable_shared" = yes && enable_static=no
6804 AC_MSG_RESULT([$enable_shared])
6806 AC_MSG_CHECKING([whether to build static libraries])
6807 # Make sure either enable_shared or enable_static is yes.
6808 test "$enable_shared" = yes || enable_static=yes
6809 AC_MSG_RESULT([$enable_static])
6815 ])# _LT_LANG_C_CONFIG
6818 # _LT_LANG_CXX_CONFIG([TAG])
6819 # --------------------------
6820 # Ensure that the configuration variables for a C++ compiler are suitably
6821 # defined. These variables are subsequently used by _LT_CONFIG to write
6822 # the compiler configuration to `libtool'.
6823 m4_defun([_LT_LANG_CXX_CONFIG],
6824 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6825 m4_require([_LT_DECL_EGREP])dnl
6826 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
6827 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
6828 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
6829 (test "X$CXX" != "Xg++"))) ; then
6832 _lt_caught_CXX_error=yes
6836 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6837 _LT_TAGVAR(allow_undefined_flag, $1)=
6838 _LT_TAGVAR(always_export_symbols, $1)=no
6839 _LT_TAGVAR(archive_expsym_cmds, $1)=
6840 _LT_TAGVAR(compiler_needs_object, $1)=no
6841 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
6842 _LT_TAGVAR(hardcode_direct, $1)=no
6843 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6844 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6845 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6846 _LT_TAGVAR(hardcode_minus_L, $1)=no
6847 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6848 _LT_TAGVAR(hardcode_automatic, $1)=no
6849 _LT_TAGVAR(inherit_rpath, $1)=no
6850 _LT_TAGVAR(module_cmds, $1)=
6851 _LT_TAGVAR(module_expsym_cmds, $1)=
6852 _LT_TAGVAR(link_all_deplibs, $1)=unknown
6853 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
6854 _LT_TAGVAR(reload_flag, $1)=$reload_flag
6855 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6856 _LT_TAGVAR(no_undefined_flag, $1)=
6857 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6858 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6860 # Source file extension for C++ test sources.
6863 # Object file extension for compiled C++ test sources.
6865 _LT_TAGVAR(objext, $1)=$objext
6867 # No sense in running all these tests if we already determined that
6868 # the CXX compiler isn't working. Some variables (like enable_shared)
6869 # are currently assumed to apply to all compilers on this platform,
6870 # and will be corrupted by setting them based on a non-working compiler.
6871 if test "$_lt_caught_CXX_error" != yes; then
6872 # Code to be used in simple compile tests
6873 lt_simple_compile_test_code="int some_variable = 0;"
6875 # Code to be used in simple link tests
6876 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
6878 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
6881 # save warnings/boilerplate of simple test code
6882 _LT_COMPILER_BOILERPLATE
6883 _LT_LINKER_BOILERPLATE
6885 # Allow CC to be a program name with arguments.
6887 lt_save_CFLAGS=$CFLAGS
6891 lt_save_with_gnu_ld=$with_gnu_ld
6892 lt_save_path_LD=$lt_cv_path_LD
6893 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
6894 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
6896 $as_unset lt_cv_prog_gnu_ld
6898 if test -n "${lt_cv_path_LDCXX+set}"; then
6899 lt_cv_path_LD=$lt_cv_path_LDCXX
6901 $as_unset lt_cv_path_LD
6903 test -z "${LDCXX+set}" || LD=$LDCXX
6907 _LT_TAGVAR(compiler, $1)=$CC
6908 _LT_CC_BASENAME([$compiler])
6910 if test -n "$compiler"; then
6911 # We don't want -fno-exception when compiling C++ code, so set the
6912 # no_builtin_flag separately
6913 if test "$GXX" = yes; then
6914 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
6916 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
6919 if test "$GXX" = yes; then
6920 # Set up default GNU C++ configuration
6924 # Check if GNU C++ uses GNU ld as the underlying linker, since the
6925 # archiving commands below assume that GNU ld is being used.
6926 if test "$with_gnu_ld" = yes; then
6927 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6928 _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'
6930 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6931 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6933 # If archive_cmds runs LD, not CC, wlarc should be empty
6934 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
6935 # investigate it a little bit more. (MM)
6938 # ancient GNU ld didn't support --whole-archive et. al.
6939 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
6940 $GREP 'no-whole-archive' > /dev/null; then
6941 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6943 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6949 # A generic and very simple default shared library creation
6950 # command for GNU C++ for the case where it uses the native
6951 # linker, instead of GNU ld. If possible, this setting should
6952 # overridden to take advantage of the native linker features on
6953 # the platform it is being used on.
6954 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6957 # Commands to make compiler produce verbose output that lists
6958 # what "hidden" libraries, object files and flags are used when
6959 # linking a shared library.
6960 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6968 # PORTME: fill in a description of your system's C++ link characteristics
6969 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6970 _LT_TAGVAR(ld_shlibs, $1)=yes
6973 # FIXME: insert proper C++ library support
6974 _LT_TAGVAR(ld_shlibs, $1)=no
6977 if test "$host_cpu" = ia64; then
6978 # On IA64, the linker does run time linking by default, so we don't
6979 # have to do anything special.
6980 aix_use_runtimelinking=no
6981 exp_sym_flag='-Bexport'
6984 aix_use_runtimelinking=no
6986 # Test if we are trying to use run time linking or normal
6987 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6988 # need to do runtime linking.
6989 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6990 for ld_flag in $LDFLAGS; do
6993 aix_use_runtimelinking=yes
7001 exp_sym_flag='-bexport'
7002 no_entry_flag='-bnoentry'
7005 # When large executables or shared objects are built, AIX ld can
7006 # have problems creating the table of contents. If linking a library
7007 # or program results in "error TOC overflow" add -mminimal-toc to
7008 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
7009 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
7011 _LT_TAGVAR(archive_cmds, $1)=''
7012 _LT_TAGVAR(hardcode_direct, $1)=yes
7013 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7014 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7015 _LT_TAGVAR(link_all_deplibs, $1)=yes
7016 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
7018 if test "$GXX" = yes; then
7019 case $host_os in aix4.[[012]]|aix4.[[012]].*)
7020 # We only want to do this on AIX 4.2 and lower, the check
7021 # below for broken collect2 doesn't work under 4.3+
7022 collect2name=`${CC} -print-prog-name=collect2`
7023 if test -f "$collect2name" &&
7024 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
7026 # We have reworked collect2
7029 # We have old collect2
7030 _LT_TAGVAR(hardcode_direct, $1)=unsupported
7031 # It fails to find uninstalled libraries when the uninstalled
7032 # path is not listed in the libpath. Setting hardcode_minus_L
7033 # to unsupported forces relinking
7034 _LT_TAGVAR(hardcode_minus_L, $1)=yes
7035 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7036 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7039 shared_flag='-shared'
7040 if test "$aix_use_runtimelinking" = yes; then
7041 shared_flag="$shared_flag "'${wl}-G'
7045 if test "$host_cpu" = ia64; then
7046 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
7047 # chokes on -Wl,-G. The following line is correct:
7050 if test "$aix_use_runtimelinking" = yes; then
7051 shared_flag='${wl}-G'
7053 shared_flag='${wl}-bM:SRE'
7058 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
7059 # It seems that -bexpall does not export symbols beginning with
7060 # underscore (_), so it is better to generate a list of symbols to
7062 _LT_TAGVAR(always_export_symbols, $1)=yes
7063 if test "$aix_use_runtimelinking" = yes; then
7064 # Warning - without using the other runtime loading flags (-brtl),
7065 # -berok will link without error, but may produce a broken library.
7066 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
7067 # Determine the default libpath from the value encoded in an empty
7069 _LT_SYS_MODULE_PATH_AIX([$1])
7070 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7072 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
7074 if test "$host_cpu" = ia64; then
7075 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
7076 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7077 _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"
7079 # Determine the default libpath from the value encoded in an
7081 _LT_SYS_MODULE_PATH_AIX([$1])
7082 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7083 # Warning - without using the other run time loading flags,
7084 # -berok will link without error, but may produce a broken library.
7085 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
7086 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
7087 if test "$with_gnu_ld" = yes; then
7088 # We only use this code for GNU lds that support --whole-archive.
7089 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7091 # Exported symbols can be pulled into shared objects from archives
7092 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
7094 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
7095 # This is similar to how AIX traditionally builds its shared
7097 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
7103 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7104 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7105 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
7106 # support --undefined. This deserves some investigation. FIXME
7107 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7109 _LT_TAGVAR(ld_shlibs, $1)=no
7114 case $cc_basename in
7116 # FIXME: insert proper C++ library support
7117 _LT_TAGVAR(ld_shlibs, $1)=no
7122 cygwin* | mingw* | pw32* | cegcc*)
7123 case $GXX,$cc_basename in
7126 # hardcode_libdir_flag_spec is actually meaningless, as there is
7127 # no search path for DLLs.
7128 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
7129 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7130 _LT_TAGVAR(always_export_symbols, $1)=yes
7131 _LT_TAGVAR(file_list_spec, $1)='@'
7132 # Tell ltmain to make .lib files, not .a files.
7134 # Tell ltmain to make .dll files, not .so files.
7136 # FIXME: Setting linknames here is a bad hack.
7137 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
7138 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7139 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
7141 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
7143 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
7145 # The linker will not automatically build a static lib if we build a DLL.
7146 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
7147 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7149 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
7150 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
7151 lt_tool_outputfile="@TOOL_OUTPUT@"~
7152 case $lt_outputfile in
7155 lt_outputfile="$lt_outputfile.exe"
7156 lt_tool_outputfile="$lt_tool_outputfile.exe"
7159 func_to_tool_file "$lt_outputfile"~
7160 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
7161 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
7162 $RM "$lt_outputfile.manifest";
7167 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
7168 # as there is no search path for DLLs.
7169 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7170 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
7171 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7172 _LT_TAGVAR(always_export_symbols, $1)=no
7173 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7175 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7176 _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'
7177 # If the export-symbols file already is a .def file (1st line
7178 # is EXPORTS), use it as is; otherwise, prepend...
7179 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7180 cp $export_symbols $output_objdir/$soname.def;
7182 echo EXPORTS > $output_objdir/$soname.def;
7183 cat $export_symbols >> $output_objdir/$soname.def;
7185 $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'
7187 _LT_TAGVAR(ld_shlibs, $1)=no
7192 darwin* | rhapsody*)
7193 _LT_DARWIN_LINKER_FEATURES($1)
7197 case $cc_basename in
7199 # FIXME: insert proper C++ library support
7200 _LT_TAGVAR(ld_shlibs, $1)=no
7203 # Green Hills C++ Compiler
7204 # FIXME: insert proper C++ library support
7205 _LT_TAGVAR(ld_shlibs, $1)=no
7208 # FIXME: insert proper C++ library support
7209 _LT_TAGVAR(ld_shlibs, $1)=no
7215 # C++ shared libraries reported to be fairly broken before
7217 _LT_TAGVAR(ld_shlibs, $1)=no
7221 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7224 freebsd* | dragonfly*)
7225 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
7227 _LT_TAGVAR(ld_shlibs, $1)=yes
7231 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7232 _LT_TAGVAR(link_all_deplibs, $1)=yes
7236 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7237 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7238 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7239 _LT_TAGVAR(hardcode_direct, $1)=yes
7240 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7241 # but as the default
7242 # location of the library.
7244 case $cc_basename in
7246 # FIXME: insert proper C++ library support
7247 _LT_TAGVAR(ld_shlibs, $1)=no
7250 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
7251 # Commands to make compiler produce verbose output that lists
7252 # what "hidden" libraries, object files and flags are used when
7253 # linking a shared library.
7255 # There doesn't appear to be a way to prevent this compiler from
7256 # explicitly linking system object files so we need to strip them
7257 # from the output so that they don't get included in the library
7259 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"'
7262 if test "$GXX" = yes; then
7263 _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 $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
7265 # FIXME: insert proper C++ library support
7266 _LT_TAGVAR(ld_shlibs, $1)=no
7273 if test $with_gnu_ld = no; then
7274 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7275 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7281 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7287 _LT_TAGVAR(hardcode_direct, $1)=no
7288 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7291 _LT_TAGVAR(hardcode_direct, $1)=yes
7292 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7293 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7294 # but as the default
7295 # location of the library.
7299 case $cc_basename in
7301 # FIXME: insert proper C++ library support
7302 _LT_TAGVAR(ld_shlibs, $1)=no
7307 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7310 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7313 _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'
7316 # Commands to make compiler produce verbose output that lists
7317 # what "hidden" libraries, object files and flags are used when
7318 # linking a shared library.
7320 # There doesn't appear to be a way to prevent this compiler from
7321 # explicitly linking system object files so we need to strip them
7322 # from the output so that they don't get included in the library
7324 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"'
7327 if test "$GXX" = yes; then
7328 if test $with_gnu_ld = no; then
7331 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7334 _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'
7337 _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'
7342 # FIXME: insert proper C++ library support
7343 _LT_TAGVAR(ld_shlibs, $1)=no
7350 _LT_TAGVAR(hardcode_direct, $1)=no
7351 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7352 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7353 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7354 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
7355 # Instead, shared libraries are loaded at an image base (0x10000000 by
7356 # default) and relocated if they conflict, which is a slow very memory
7357 # consuming and fragmenting process. To avoid this, we pick a random,
7358 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
7359 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
7360 _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'
7361 _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'
7364 case $cc_basename in
7367 _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'
7369 # Archives containing C++ object files must be created using
7370 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
7371 # necessary to make sure instantiated templates are included
7373 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
7376 if test "$GXX" = yes; then
7377 if test "$with_gnu_ld" = no; then
7378 _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'
7380 _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'
7383 _LT_TAGVAR(link_all_deplibs, $1)=yes
7386 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7387 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7388 _LT_TAGVAR(inherit_rpath, $1)=yes
7391 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
7392 case $cc_basename in
7394 # Kuck and Associates, Inc. (KAI) C++ Compiler
7396 # KCC will only create a shared library if the output file
7397 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7398 # to its proper name (with version) after linking.
7399 _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'
7400 _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'
7401 # Commands to make compiler produce verbose output that lists
7402 # what "hidden" libraries, object files and flags are used when
7403 # linking a shared library.
7405 # There doesn't appear to be a way to prevent this compiler from
7406 # explicitly linking system object files so we need to strip them
7407 # from the output so that they don't get included in the library
7409 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"'
7411 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7412 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7414 # Archives containing C++ object files must be created using
7415 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
7416 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
7421 # version 8.0 and above of icpc choke on multiply defined symbols
7422 # if we add $predep_objects and $postdep_objects, however 7.1 and
7423 # earlier do not add the objects themselves.
7424 case `$CC -V 2>&1` in
7426 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7427 _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'
7429 *) # Version 8.0 or newer
7432 ia64*) tmp_idyn=' -i_dynamic';;
7434 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7435 _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'
7438 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7439 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7440 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7441 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7444 # Portland Group C++ compiler
7446 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
7447 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
7449 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
7450 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
7451 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
7453 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
7454 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
7456 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
7458 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7459 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7460 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
7462 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7463 $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'
7465 *) # Version 6 and above use weak symbols
7466 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7467 _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'
7471 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
7472 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7473 _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'
7477 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7478 _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'
7480 runpath_var=LD_RUN_PATH
7481 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7482 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7484 # Commands to make compiler produce verbose output that lists
7485 # what "hidden" libraries, object files and flags are used when
7486 # linking a shared library.
7488 # There doesn't appear to be a way to prevent this compiler from
7489 # explicitly linking system object files so we need to strip them
7490 # from the output so that they don't get included in the library
7492 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'
7494 xl* | mpixl* | bgxl*)
7495 # IBM XL 8.0 on PPC, with GNU ld
7496 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7497 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7498 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7499 if test "x$supports_anon_versioning" = xyes; then
7500 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7501 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7502 echo "local: *; };" >> $output_objdir/$libname.ver~
7503 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
7507 case `$CC -V 2>&1 | sed 5q` in
7510 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7511 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7512 _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'
7513 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7514 _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'
7515 _LT_TAGVAR(compiler_needs_object, $1)=yes
7517 # Not sure whether something based on
7518 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
7520 output_verbose_link_cmd='func_echo_all'
7522 # Archives containing C++ object files must be created using
7523 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7524 # necessary to make sure instantiated templates are included
7526 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7534 # FIXME: insert proper C++ library support
7535 _LT_TAGVAR(ld_shlibs, $1)=no
7539 # FIXME: insert proper C++ library support
7540 _LT_TAGVAR(ld_shlibs, $1)=no
7544 case $cc_basename in
7546 # FIXME: insert proper C++ library support
7547 _LT_TAGVAR(ld_shlibs, $1)=no
7550 # FIXME: insert proper C++ library support
7551 _LT_TAGVAR(ld_shlibs, $1)=no
7557 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7558 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
7560 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7561 _LT_TAGVAR(hardcode_direct, $1)=yes
7562 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7564 # Workaround some broken pre-1.5 toolchains
7565 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
7569 _LT_TAGVAR(ld_shlibs, $1)=yes
7573 # C++ shared libraries are fairly broken
7574 _LT_TAGVAR(ld_shlibs, $1)=no
7578 if test -f /usr/libexec/ld.so; then
7579 _LT_TAGVAR(hardcode_direct, $1)=yes
7580 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7581 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7582 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7583 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7584 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7585 _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'
7586 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7587 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7589 output_verbose_link_cmd=func_echo_all
7591 _LT_TAGVAR(ld_shlibs, $1)=no
7595 osf3* | osf4* | osf5*)
7596 case $cc_basename in
7598 # Kuck and Associates, Inc. (KAI) C++ Compiler
7600 # KCC will only create a shared library if the output file
7601 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7602 # to its proper name (with version) after linking.
7603 _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'
7605 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7606 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7608 # Archives containing C++ object files must be created using
7609 # the KAI C++ compiler.
7611 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
7612 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
7616 # Rational C++ 2.4.1
7617 # FIXME: insert proper C++ library support
7618 _LT_TAGVAR(ld_shlibs, $1)=no
7623 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7624 _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'
7625 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7628 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7629 _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'
7630 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
7631 echo "-hidden">> $lib.exp~
7632 $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~
7634 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7638 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7640 # Commands to make compiler produce verbose output that lists
7641 # what "hidden" libraries, object files and flags are used when
7642 # linking a shared library.
7644 # There doesn't appear to be a way to prevent this compiler from
7645 # explicitly linking system object files so we need to strip them
7646 # from the output so that they don't get included in the library
7648 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"'
7651 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7652 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7655 _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'
7658 _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'
7662 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7663 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7665 # Commands to make compiler produce verbose output that lists
7666 # what "hidden" libraries, object files and flags are used when
7667 # linking a shared library.
7668 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7671 # FIXME: insert proper C++ library support
7672 _LT_TAGVAR(ld_shlibs, $1)=no
7679 # FIXME: insert proper C++ library support
7680 _LT_TAGVAR(ld_shlibs, $1)=no
7684 case $cc_basename in
7687 # FIXME: insert proper C++ library support
7688 _LT_TAGVAR(ld_shlibs, $1)=no
7692 # FIXME: insert proper C++ library support
7693 _LT_TAGVAR(ld_shlibs, $1)=no
7696 # FIXME: insert proper C++ library support
7697 _LT_TAGVAR(ld_shlibs, $1)=no
7703 case $cc_basename in
7705 # Sun C++ 4.2, 5.x and Centerline C++
7706 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
7707 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7708 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7709 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7710 $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'
7712 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7713 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7715 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7717 # The compiler driver will combine and reorder linker options,
7718 # but understands `-z linker_flag'.
7719 # Supported since Solaris 2.6 (maybe 2.5.1?)
7720 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7723 _LT_TAGVAR(link_all_deplibs, $1)=yes
7725 output_verbose_link_cmd='func_echo_all'
7727 # Archives containing C++ object files must be created using
7728 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7729 # necessary to make sure instantiated templates are included
7731 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7734 # Green Hills C++ Compiler
7735 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7737 # The C++ compiler must be used to create the archive.
7738 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
7741 # GNU C++ compiler with Solaris linker
7742 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7743 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
7744 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
7745 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7746 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7747 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7749 # Commands to make compiler produce verbose output that lists
7750 # what "hidden" libraries, object files and flags are used when
7751 # linking a shared library.
7752 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7754 # g++ 2.7 appears to require `-G' NOT `-shared' on this
7756 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7757 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7758 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7760 # Commands to make compiler produce verbose output that lists
7761 # what "hidden" libraries, object files and flags are used when
7762 # linking a shared library.
7763 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7766 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
7768 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7770 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
7778 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7779 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7780 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7781 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7782 runpath_var='LD_RUN_PATH'
7784 case $cc_basename in
7786 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7787 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7790 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7791 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7796 sysv5* | sco3.2v5* | sco5v6*)
7797 # Note: We can NOT use -z defs as we might desire, because we do not
7798 # link with -lc, and that would cause any symbols used from libc to
7799 # always be unresolved, which means just about no library would
7800 # ever link correctly. If we're not using GNU ld we use -z text
7801 # though, which does catch some bad symbols but isn't as heavy-handed
7803 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7804 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7805 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7806 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7807 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
7808 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7809 _LT_TAGVAR(link_all_deplibs, $1)=yes
7810 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7811 runpath_var='LD_RUN_PATH'
7813 case $cc_basename in
7815 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7816 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7817 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
7818 '"$_LT_TAGVAR(old_archive_cmds, $1)"
7819 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
7820 '"$_LT_TAGVAR(reload_cmds, $1)"
7823 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7824 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7830 case $cc_basename in
7832 # NonStop-UX NCC 3.20
7833 # FIXME: insert proper C++ library support
7834 _LT_TAGVAR(ld_shlibs, $1)=no
7837 # FIXME: insert proper C++ library support
7838 _LT_TAGVAR(ld_shlibs, $1)=no
7844 # FIXME: insert proper C++ library support
7845 _LT_TAGVAR(ld_shlibs, $1)=no
7849 # FIXME: insert proper C++ library support
7850 _LT_TAGVAR(ld_shlibs, $1)=no
7854 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
7855 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7857 _LT_TAGVAR(GCC, $1)="$GXX"
7858 _LT_TAGVAR(LD, $1)="$LD"
7861 ## There is no encapsulation within the following macros, do not change
7862 ## the running order or otherwise move them around unless you know exactly
7863 ## what you are doing...
7864 _LT_SYS_HIDDEN_LIBDEPS($1)
7865 _LT_COMPILER_PIC($1)
7866 _LT_COMPILER_C_O($1)
7867 _LT_COMPILER_FILE_LOCKS($1)
7868 _LT_LINKER_SHLIBS($1)
7869 _LT_SYS_DYNAMIC_LINKER($1)
7870 _LT_LINKER_HARDCODE_LIBPATH($1)
7873 fi # test -n "$compiler"
7876 CFLAGS=$lt_save_CFLAGS
7880 with_gnu_ld=$lt_save_with_gnu_ld
7881 lt_cv_path_LDCXX=$lt_cv_path_LD
7882 lt_cv_path_LD=$lt_save_path_LD
7883 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
7884 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
7885 fi # test "$_lt_caught_CXX_error" != yes
7888 ])# _LT_LANG_CXX_CONFIG
7891 # _LT_FUNC_STRIPNAME_CNF
7892 # ----------------------
7893 # func_stripname_cnf prefix suffix name
7894 # strip PREFIX and SUFFIX off of NAME.
7895 # PREFIX and SUFFIX must not contain globbing or regex special
7896 # characters, hashes, percent signs, but SUFFIX may contain a leading
7897 # dot (in which case that matches only a dot).
7899 # This function is identical to the (non-XSI) version of func_stripname,
7900 # except this one can be used by m4 code that may be executed by configure,
7901 # rather than the libtool script.
7902 m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
7903 AC_REQUIRE([_LT_DECL_SED])
7904 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
7905 func_stripname_cnf ()
7908 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
7909 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
7911 } # func_stripname_cnf
7912 ])# _LT_FUNC_STRIPNAME_CNF
7914 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
7915 # ---------------------------------
7916 # Figure out "hidden" library dependencies from verbose
7917 # compiler output when linking a shared library.
7918 # Parse the compiler output and extract the necessary
7919 # objects, libraries and library flags.
7920 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
7921 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7922 AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
7923 # Dependencies to place before and after the object being linked:
7924 _LT_TAGVAR(predep_objects, $1)=
7925 _LT_TAGVAR(postdep_objects, $1)=
7926 _LT_TAGVAR(predeps, $1)=
7927 _LT_TAGVAR(postdeps, $1)=
7928 _LT_TAGVAR(compiler_lib_search_path, $1)=
7930 dnl we can't use the lt_simple_compile_test_code here,
7931 dnl because it contains code intended for an executable,
7932 dnl not a library. It's possible we should let each
7933 dnl tag define a new lt_????_link_test_code variable,
7934 dnl but it's only used here...
7935 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
7937 void foo (void) { a = 0; }
7939 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
7943 Foo (void) { a = 0; }
7948 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
7956 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
7964 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
7967 public void bar (void) {
7972 ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
7979 _lt_libdeps_save_CFLAGS=$CFLAGS
7980 case "$CC $CFLAGS " in #(
7981 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
7982 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
7983 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
7986 dnl Parse the compiler output and extract the necessary
7987 dnl objects, libraries and library flags.
7988 if AC_TRY_EVAL(ac_compile); then
7989 # Parse the compiler output and extract the necessary
7990 # objects, libraries and library flags.
7992 # Sentinel used to keep track of whether or not we are before
7993 # the conftest object file.
7994 pre_test_object_deps_done=no
7996 for p in `eval "$output_verbose_link_cmd"`; do
8000 # Some compilers place space between "-{L,R}" and the path.
8002 if test $p = "-L" ||
8003 test $p = "-R"; then
8008 # Expand the sysroot to ease extracting the directories later.
8009 if test -z "$prev"; then
8011 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
8012 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
8013 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
8017 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
8019 if test "$pre_test_object_deps_done" = no; then
8022 # Internal compiler library paths should come after those
8023 # provided the user. The postdeps already come after the
8024 # user supplied libs so there is no need to process them.
8025 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
8026 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
8028 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
8031 # The "-l" case would never come before the object being
8032 # linked, so don't bother handling this case.
8035 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
8036 _LT_TAGVAR(postdeps, $1)="${prev}${p}"
8038 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
8044 *.lto.$objext) ;; # Ignore GCC LTO objects
8046 # This assumes that the test object file only shows up
8047 # once in the compiler output.
8048 if test "$p" = "conftest.$objext"; then
8049 pre_test_object_deps_done=yes
8053 if test "$pre_test_object_deps_done" = no; then
8054 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
8055 _LT_TAGVAR(predep_objects, $1)="$p"
8057 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
8060 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
8061 _LT_TAGVAR(postdep_objects, $1)="$p"
8063 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
8068 *) ;; # Ignore the rest.
8076 echo "libtool.m4: error: problem compiling $1 test program"
8079 $RM -f confest.$objext
8080 CFLAGS=$_lt_libdeps_save_CFLAGS
8082 # PORTME: override above test on systems where it is broken
8086 # Interix 3.5 installs completely hosed .la files for C++, so rather than
8087 # hack all around it, let's just trust "g++" to DTRT.
8088 _LT_TAGVAR(predep_objects,$1)=
8089 _LT_TAGVAR(postdep_objects,$1)=
8090 _LT_TAGVAR(postdeps,$1)=
8094 case `$CC -V 2>&1 | sed 5q` in
8098 # The more standards-conforming stlport4 library is
8099 # incompatible with the Cstd library. Avoid specifying
8100 # it if it's in CXXFLAGS. Ignore libCrun as
8101 # -library=stlport4 depends on it.
8102 case " $CXX $CXXFLAGS " in
8103 *" -library=stlport4 "*)
8104 solaris_use_stlport4=yes
8108 if test "$solaris_use_stlport4" != yes; then
8109 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8116 case $cc_basename in
8118 # The more standards-conforming stlport4 library is
8119 # incompatible with the Cstd library. Avoid specifying
8120 # it if it's in CXXFLAGS. Ignore libCrun as
8121 # -library=stlport4 depends on it.
8122 case " $CXX $CXXFLAGS " in
8123 *" -library=stlport4 "*)
8124 solaris_use_stlport4=yes
8128 # Adding this requires a known-good setup of shared libraries for
8129 # Sun compiler versions before 5.6, else PIC objects from an old
8130 # archive will be linked into the output, leading to subtle bugs.
8131 if test "$solaris_use_stlport4" != yes; then
8132 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8140 case " $_LT_TAGVAR(postdeps, $1) " in
8141 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
8143 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
8144 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
8145 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
8147 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
8148 [The directories searched by this compiler when creating a shared library])
8149 _LT_TAGDECL([], [predep_objects], [1],
8150 [Dependencies to place before and after the objects being linked to
8151 create a shared library])
8152 _LT_TAGDECL([], [postdep_objects], [1])
8153 _LT_TAGDECL([], [predeps], [1])
8154 _LT_TAGDECL([], [postdeps], [1])
8155 _LT_TAGDECL([], [compiler_lib_search_path], [1],
8156 [The library search path used internally by the compiler when linking
8158 ])# _LT_SYS_HIDDEN_LIBDEPS
8161 # _LT_LANG_F77_CONFIG([TAG])
8162 # --------------------------
8163 # Ensure that the configuration variables for a Fortran 77 compiler are
8164 # suitably defined. These variables are subsequently used by _LT_CONFIG
8165 # to write the compiler configuration to `libtool'.
8166 m4_defun([_LT_LANG_F77_CONFIG],
8167 [AC_LANG_PUSH(Fortran 77)
8168 if test -z "$F77" || test "X$F77" = "Xno"; then
8172 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8173 _LT_TAGVAR(allow_undefined_flag, $1)=
8174 _LT_TAGVAR(always_export_symbols, $1)=no
8175 _LT_TAGVAR(archive_expsym_cmds, $1)=
8176 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8177 _LT_TAGVAR(hardcode_direct, $1)=no
8178 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8179 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8180 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8181 _LT_TAGVAR(hardcode_minus_L, $1)=no
8182 _LT_TAGVAR(hardcode_automatic, $1)=no
8183 _LT_TAGVAR(inherit_rpath, $1)=no
8184 _LT_TAGVAR(module_cmds, $1)=
8185 _LT_TAGVAR(module_expsym_cmds, $1)=
8186 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8187 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8188 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8189 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8190 _LT_TAGVAR(no_undefined_flag, $1)=
8191 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8192 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8194 # Source file extension for f77 test sources.
8197 # Object file extension for compiled f77 test sources.
8199 _LT_TAGVAR(objext, $1)=$objext
8201 # No sense in running all these tests if we already determined that
8202 # the F77 compiler isn't working. Some variables (like enable_shared)
8203 # are currently assumed to apply to all compilers on this platform,
8204 # and will be corrupted by setting them based on a non-working compiler.
8205 if test "$_lt_disable_F77" != yes; then
8206 # Code to be used in simple compile tests
8207 lt_simple_compile_test_code="\
8213 # Code to be used in simple link tests
8214 lt_simple_link_test_code="\
8219 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8222 # save warnings/boilerplate of simple test code
8223 _LT_COMPILER_BOILERPLATE
8224 _LT_LINKER_BOILERPLATE
8226 # Allow CC to be a program name with arguments.
8229 lt_save_CFLAGS=$CFLAGS
8233 _LT_TAGVAR(compiler, $1)=$CC
8234 _LT_CC_BASENAME([$compiler])
8236 if test -n "$compiler"; then
8237 AC_MSG_CHECKING([if libtool supports shared libraries])
8238 AC_MSG_RESULT([$can_build_shared])
8240 AC_MSG_CHECKING([whether to build shared libraries])
8241 test "$can_build_shared" = "no" && enable_shared=no
8243 # On AIX, shared libraries and static libraries use the same namespace, and
8244 # are all built from PIC.
8247 test "$enable_shared" = yes && enable_static=no
8248 if test -n "$RANLIB"; then
8249 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8250 postinstall_cmds='$RANLIB $lib'
8254 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8255 test "$enable_shared" = yes && enable_static=no
8259 AC_MSG_RESULT([$enable_shared])
8261 AC_MSG_CHECKING([whether to build static libraries])
8262 # Make sure either enable_shared or enable_static is yes.
8263 test "$enable_shared" = yes || enable_static=yes
8264 AC_MSG_RESULT([$enable_static])
8266 _LT_TAGVAR(GCC, $1)="$G77"
8267 _LT_TAGVAR(LD, $1)="$LD"
8270 ## There is no encapsulation within the following macros, do not change
8271 ## the running order or otherwise move them around unless you know exactly
8272 ## what you are doing...
8273 _LT_COMPILER_PIC($1)
8274 _LT_COMPILER_C_O($1)
8275 _LT_COMPILER_FILE_LOCKS($1)
8276 _LT_LINKER_SHLIBS($1)
8277 _LT_SYS_DYNAMIC_LINKER($1)
8278 _LT_LINKER_HARDCODE_LIBPATH($1)
8281 fi # test -n "$compiler"
8285 CFLAGS="$lt_save_CFLAGS"
8286 fi # test "$_lt_disable_F77" != yes
8289 ])# _LT_LANG_F77_CONFIG
8292 # _LT_LANG_FC_CONFIG([TAG])
8293 # -------------------------
8294 # Ensure that the configuration variables for a Fortran compiler are
8295 # suitably defined. These variables are subsequently used by _LT_CONFIG
8296 # to write the compiler configuration to `libtool'.
8297 m4_defun([_LT_LANG_FC_CONFIG],
8298 [AC_LANG_PUSH(Fortran)
8300 if test -z "$FC" || test "X$FC" = "Xno"; then
8304 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8305 _LT_TAGVAR(allow_undefined_flag, $1)=
8306 _LT_TAGVAR(always_export_symbols, $1)=no
8307 _LT_TAGVAR(archive_expsym_cmds, $1)=
8308 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8309 _LT_TAGVAR(hardcode_direct, $1)=no
8310 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8311 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8312 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8313 _LT_TAGVAR(hardcode_minus_L, $1)=no
8314 _LT_TAGVAR(hardcode_automatic, $1)=no
8315 _LT_TAGVAR(inherit_rpath, $1)=no
8316 _LT_TAGVAR(module_cmds, $1)=
8317 _LT_TAGVAR(module_expsym_cmds, $1)=
8318 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8319 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8320 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8321 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8322 _LT_TAGVAR(no_undefined_flag, $1)=
8323 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8324 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8326 # Source file extension for fc test sources.
8327 ac_ext=${ac_fc_srcext-f}
8329 # Object file extension for compiled fc test sources.
8331 _LT_TAGVAR(objext, $1)=$objext
8333 # No sense in running all these tests if we already determined that
8334 # the FC compiler isn't working. Some variables (like enable_shared)
8335 # are currently assumed to apply to all compilers on this platform,
8336 # and will be corrupted by setting them based on a non-working compiler.
8337 if test "$_lt_disable_FC" != yes; then
8338 # Code to be used in simple compile tests
8339 lt_simple_compile_test_code="\
8345 # Code to be used in simple link tests
8346 lt_simple_link_test_code="\
8351 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8354 # save warnings/boilerplate of simple test code
8355 _LT_COMPILER_BOILERPLATE
8356 _LT_LINKER_BOILERPLATE
8358 # Allow CC to be a program name with arguments.
8361 lt_save_CFLAGS=$CFLAGS
8365 GCC=$ac_cv_fc_compiler_gnu
8367 _LT_TAGVAR(compiler, $1)=$CC
8368 _LT_CC_BASENAME([$compiler])
8370 if test -n "$compiler"; then
8371 AC_MSG_CHECKING([if libtool supports shared libraries])
8372 AC_MSG_RESULT([$can_build_shared])
8374 AC_MSG_CHECKING([whether to build shared libraries])
8375 test "$can_build_shared" = "no" && enable_shared=no
8377 # On AIX, shared libraries and static libraries use the same namespace, and
8378 # are all built from PIC.
8381 test "$enable_shared" = yes && enable_static=no
8382 if test -n "$RANLIB"; then
8383 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8384 postinstall_cmds='$RANLIB $lib'
8388 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8389 test "$enable_shared" = yes && enable_static=no
8393 AC_MSG_RESULT([$enable_shared])
8395 AC_MSG_CHECKING([whether to build static libraries])
8396 # Make sure either enable_shared or enable_static is yes.
8397 test "$enable_shared" = yes || enable_static=yes
8398 AC_MSG_RESULT([$enable_static])
8400 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
8401 _LT_TAGVAR(LD, $1)="$LD"
8404 ## There is no encapsulation within the following macros, do not change
8405 ## the running order or otherwise move them around unless you know exactly
8406 ## what you are doing...
8407 _LT_SYS_HIDDEN_LIBDEPS($1)
8408 _LT_COMPILER_PIC($1)
8409 _LT_COMPILER_C_O($1)
8410 _LT_COMPILER_FILE_LOCKS($1)
8411 _LT_LINKER_SHLIBS($1)
8412 _LT_SYS_DYNAMIC_LINKER($1)
8413 _LT_LINKER_HARDCODE_LIBPATH($1)
8416 fi # test -n "$compiler"
8420 CFLAGS=$lt_save_CFLAGS
8421 fi # test "$_lt_disable_FC" != yes
8424 ])# _LT_LANG_FC_CONFIG
8427 # _LT_LANG_GCJ_CONFIG([TAG])
8428 # --------------------------
8429 # Ensure that the configuration variables for the GNU Java Compiler compiler
8430 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8431 # to write the compiler configuration to `libtool'.
8432 m4_defun([_LT_LANG_GCJ_CONFIG],
8433 [AC_REQUIRE([LT_PROG_GCJ])dnl
8436 # Source file extension for Java test sources.
8439 # Object file extension for compiled Java test sources.
8441 _LT_TAGVAR(objext, $1)=$objext
8443 # Code to be used in simple compile tests
8444 lt_simple_compile_test_code="class foo {}"
8446 # Code to be used in simple link tests
8447 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
8449 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8452 # save warnings/boilerplate of simple test code
8453 _LT_COMPILER_BOILERPLATE
8454 _LT_LINKER_BOILERPLATE
8456 # Allow CC to be a program name with arguments.
8458 lt_save_CFLAGS=$CFLAGS
8464 _LT_TAGVAR(compiler, $1)=$CC
8465 _LT_TAGVAR(LD, $1)="$LD"
8466 _LT_CC_BASENAME([$compiler])
8468 # GCJ did not exist at the time GCC didn't implicitly link libc in.
8469 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8471 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8472 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8473 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8475 if test -n "$compiler"; then
8476 _LT_COMPILER_NO_RTTI($1)
8477 _LT_COMPILER_PIC($1)
8478 _LT_COMPILER_C_O($1)
8479 _LT_COMPILER_FILE_LOCKS($1)
8480 _LT_LINKER_SHLIBS($1)
8481 _LT_LINKER_HARDCODE_LIBPATH($1)
8490 CFLAGS=$lt_save_CFLAGS
8491 ])# _LT_LANG_GCJ_CONFIG
8494 # _LT_LANG_GO_CONFIG([TAG])
8495 # --------------------------
8496 # Ensure that the configuration variables for the GNU Go compiler
8497 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8498 # to write the compiler configuration to `libtool'.
8499 m4_defun([_LT_LANG_GO_CONFIG],
8500 [AC_REQUIRE([LT_PROG_GO])dnl
8503 # Source file extension for Go test sources.
8506 # Object file extension for compiled Go test sources.
8508 _LT_TAGVAR(objext, $1)=$objext
8510 # Code to be used in simple compile tests
8511 lt_simple_compile_test_code="package main; func main() { }"
8513 # Code to be used in simple link tests
8514 lt_simple_link_test_code='package main; func main() { }'
8516 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8519 # save warnings/boilerplate of simple test code
8520 _LT_COMPILER_BOILERPLATE
8521 _LT_LINKER_BOILERPLATE
8523 # Allow CC to be a program name with arguments.
8525 lt_save_CFLAGS=$CFLAGS
8531 _LT_TAGVAR(compiler, $1)=$CC
8532 _LT_TAGVAR(LD, $1)="$LD"
8533 _LT_CC_BASENAME([$compiler])
8535 # Go did not exist at the time GCC didn't implicitly link libc in.
8536 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8538 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8539 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8540 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8542 if test -n "$compiler"; then
8543 _LT_COMPILER_NO_RTTI($1)
8544 _LT_COMPILER_PIC($1)
8545 _LT_COMPILER_C_O($1)
8546 _LT_COMPILER_FILE_LOCKS($1)
8547 _LT_LINKER_SHLIBS($1)
8548 _LT_LINKER_HARDCODE_LIBPATH($1)
8557 CFLAGS=$lt_save_CFLAGS
8558 ])# _LT_LANG_GO_CONFIG
8561 # _LT_LANG_RC_CONFIG([TAG])
8562 # -------------------------
8563 # Ensure that the configuration variables for the Windows resource compiler
8564 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8565 # to write the compiler configuration to `libtool'.
8566 m4_defun([_LT_LANG_RC_CONFIG],
8567 [AC_REQUIRE([LT_PROG_RC])dnl
8570 # Source file extension for RC test sources.
8573 # Object file extension for compiled RC test sources.
8575 _LT_TAGVAR(objext, $1)=$objext
8577 # Code to be used in simple compile tests
8578 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8580 # Code to be used in simple link tests
8581 lt_simple_link_test_code="$lt_simple_compile_test_code"
8583 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8586 # save warnings/boilerplate of simple test code
8587 _LT_COMPILER_BOILERPLATE
8588 _LT_LINKER_BOILERPLATE
8590 # Allow CC to be a program name with arguments.
8592 lt_save_CFLAGS=$CFLAGS
8598 _LT_TAGVAR(compiler, $1)=$CC
8599 _LT_CC_BASENAME([$compiler])
8600 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8602 if test -n "$compiler"; then
8610 CFLAGS=$lt_save_CFLAGS
8611 ])# _LT_LANG_RC_CONFIG
8616 AC_DEFUN([LT_PROG_GCJ],
8617 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
8618 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
8619 [AC_CHECK_TOOL(GCJ, gcj,)
8620 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
8621 AC_SUBST(GCJFLAGS)])])[]dnl
8625 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
8626 dnl aclocal-1.4 backwards compatibility:
8627 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
8632 AC_DEFUN([LT_PROG_GO],
8633 [AC_CHECK_TOOL(GOC, gccgo,)
8639 AC_DEFUN([LT_PROG_RC],
8640 [AC_CHECK_TOOL(RC, windres,)
8644 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
8645 dnl aclocal-1.4 backwards compatibility:
8646 dnl AC_DEFUN([LT_AC_PROG_RC], [])
8651 # If we don't have a new enough Autoconf to choose the best grep
8652 # available, choose the one first in the user's PATH.
8653 m4_defun([_LT_DECL_EGREP],
8654 [AC_REQUIRE([AC_PROG_EGREP])dnl
8655 AC_REQUIRE([AC_PROG_FGREP])dnl
8656 test -z "$GREP" && GREP=grep
8657 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
8658 _LT_DECL([], [EGREP], [1], [An ERE matcher])
8659 _LT_DECL([], [FGREP], [1], [A literal string matcher])
8660 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
8667 # If we don't have a new enough Autoconf to choose the best objdump
8668 # available, choose the one first in the user's PATH.
8669 m4_defun([_LT_DECL_OBJDUMP],
8670 [AC_CHECK_TOOL(OBJDUMP, objdump, false)
8671 test -z "$OBJDUMP" && OBJDUMP=objdump
8672 _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
8678 # Ensure DLLTOOL variable is set.
8679 m4_defun([_LT_DECL_DLLTOOL],
8680 [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8681 test -z "$DLLTOOL" && DLLTOOL=dlltool
8682 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
8688 # Check for a fully-functional sed program, that truncates
8689 # as few characters as possible. Prefer GNU sed if found.
8690 m4_defun([_LT_DECL_SED],
8692 test -z "$SED" && SED=sed
8693 Xsed="$SED -e 1s/^X//"
8694 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
8695 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
8696 [Sed that helps us avoid accidentally triggering echo(1) options like -n])
8699 m4_ifndef([AC_PROG_SED], [
8700 # NOTE: This macro has been submitted for inclusion into #
8701 # GNU Autoconf as AC_PROG_SED. When it is available in #
8702 # a released version of Autoconf we should remove this #
8703 # macro and use it instead. #
8705 m4_defun([AC_PROG_SED],
8706 [AC_MSG_CHECKING([for a sed that does not truncate output])
8707 AC_CACHE_VAL(lt_cv_path_SED,
8708 [# Loop through the user's path and test for sed and gsed.
8709 # Then use that list of sed's as ones to test for truncation.
8710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8714 test -z "$as_dir" && as_dir=.
8715 for lt_ac_prog in sed gsed; do
8716 for ac_exec_ext in '' $ac_executable_extensions; do
8717 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
8718 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
8726 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
8727 # along with /bin/sed that truncates output.
8728 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
8729 test ! -f $lt_ac_sed && continue
8730 cat /dev/null > conftest.in
8732 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
8733 # Check for GNU sed and select it if it is found.
8734 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
8735 lt_cv_path_SED=$lt_ac_sed
8739 cat conftest.in conftest.in >conftest.tmp
8740 mv conftest.tmp conftest.in
8741 cp conftest.in conftest.nl
8743 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
8744 cmp -s conftest.out conftest.nl || break
8745 # 10000 chars as input seems more than enough
8746 test $lt_ac_count -gt 10 && break
8747 lt_ac_count=`expr $lt_ac_count + 1`
8748 if test $lt_ac_count -gt $lt_ac_max; then
8749 lt_ac_max=$lt_ac_count
8750 lt_cv_path_SED=$lt_ac_sed
8757 AC_MSG_RESULT([$SED])
8762 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
8763 dnl aclocal-1.4 backwards compatibility:
8764 dnl AC_DEFUN([LT_AC_PROG_SED], [])
8767 # _LT_CHECK_SHELL_FEATURES
8768 # ------------------------
8769 # Find out whether the shell is Bourne or XSI compatible,
8770 # or has some other useful features.
8771 m4_defun([_LT_CHECK_SHELL_FEATURES],
8772 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
8773 # Try some XSI features
8776 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
8778 && eval 'test $(( 1 + 1 )) -eq 2 \
8779 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
8781 AC_MSG_RESULT([$xsi_shell])
8782 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
8784 AC_MSG_CHECKING([whether the shell understands "+="])
8786 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
8788 && lt_shell_append=yes
8789 AC_MSG_RESULT([$lt_shell_append])
8790 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
8792 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8797 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
8799 # test EBCDIC or ASCII
8800 case `echo X|tr X '\101'` in
8801 A) # ASCII based system
8802 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8803 lt_SP2NL='tr \040 \012'
8804 lt_NL2SP='tr \015\012 \040\040'
8806 *) # EBCDIC based system
8807 lt_SP2NL='tr \100 \n'
8808 lt_NL2SP='tr \r\n \100\100'
8811 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
8812 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
8813 ])# _LT_CHECK_SHELL_FEATURES
8816 # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
8817 # ------------------------------------------------------
8818 # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
8819 # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
8820 m4_defun([_LT_PROG_FUNCTION_REPLACE],
8822 sed -e '/^$1 ()$/,/^} # $1 /c\
8825 m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
8826 } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
8827 && mv -f "$cfgfile.tmp" "$cfgfile" \
8828 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8829 test 0 -eq $? || _lt_function_replace_fail=:
8833 # _LT_PROG_REPLACE_SHELLFNS
8834 # -------------------------
8835 # Replace existing portable implementations of several shell functions with
8836 # equivalent extended shell implementations where those features are available..
8837 m4_defun([_LT_PROG_REPLACE_SHELLFNS],
8838 [if test x"$xsi_shell" = xyes; then
8839 _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
8841 */*) func_dirname_result="${1%/*}${2}" ;;
8842 * ) func_dirname_result="${3}" ;;
8845 _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
8846 func_basename_result="${1##*/}"])
8848 _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
8850 */*) func_dirname_result="${1%/*}${2}" ;;
8851 * ) func_dirname_result="${3}" ;;
8853 func_basename_result="${1##*/}"])
8855 _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
8856 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
8857 # positional parameters, so assign one to ordinary parameter first.
8858 func_stripname_result=${3}
8859 func_stripname_result=${func_stripname_result#"${1}"}
8860 func_stripname_result=${func_stripname_result%"${2}"}])
8862 _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
8863 func_split_long_opt_name=${1%%=*}
8864 func_split_long_opt_arg=${1#*=}])
8866 _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
8867 func_split_short_opt_arg=${1#??}
8868 func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
8870 _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
8872 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
8873 *) func_lo2o_result=${1} ;;
8876 _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
8878 _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
8880 _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
8883 if test x"$lt_shell_append" = xyes; then
8884 _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
8886 _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
8887 func_quote_for_eval "${2}"
8888 dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
8889 eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
8891 # Save a `func_append' function call where possible by direct use of '+='
8892 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
8893 && mv -f "$cfgfile.tmp" "$cfgfile" \
8894 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8895 test 0 -eq $? || _lt_function_replace_fail=:
8897 # Save a `func_append' function call even when '+=' is not available
8898 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
8899 && mv -f "$cfgfile.tmp" "$cfgfile" \
8900 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8901 test 0 -eq $? || _lt_function_replace_fail=:
8904 if test x"$_lt_function_replace_fail" = x":"; then
8905 AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
8909 # _LT_PATH_CONVERSION_FUNCTIONS
8910 # -----------------------------
8911 # Determine which file name conversion functions should be used by
8912 # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
8913 # for certain cross-compile configurations and native mingw.
8914 m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
8915 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8916 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
8917 AC_MSG_CHECKING([how to convert $build file names to $host format])
8918 AC_CACHE_VAL(lt_cv_to_host_file_cmd,
8922 *-*-mingw* ) # actually msys
8923 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8926 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8928 * ) # otherwise, assume *nix
8929 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8935 *-*-mingw* ) # actually msys
8936 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8939 lt_cv_to_host_file_cmd=func_convert_file_noop
8941 * ) # otherwise, assume *nix
8942 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8946 * ) # unhandled hosts (and "normal" native builds)
8947 lt_cv_to_host_file_cmd=func_convert_file_noop
8951 to_host_file_cmd=$lt_cv_to_host_file_cmd
8952 AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
8953 _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
8954 [0], [convert $build file names to $host format])dnl
8956 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
8957 AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
8958 [#assume ordinary cross tools, or native build.
8959 lt_cv_to_tool_file_cmd=func_convert_file_noop
8963 *-*-mingw* ) # actually msys
8964 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8970 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8971 AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
8972 _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
8973 [0], [convert $build files to toolchain format])dnl
8974 ])# _LT_PATH_CONVERSION_FUNCTIONS
8976 # Helper functions for option handling. -*- Autoconf -*-
8978 # Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
8980 # Written by Gary V. Vaughan, 2004
8982 # This file is free software; the Free Software Foundation gives
8983 # unlimited permission to copy and/or distribute it, with or without
8984 # modifications, as long as this notice is preserved.
8986 # serial 7 ltoptions.m4
8988 # This is to help aclocal find these macros, as it can't see m4_define.
8989 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
8992 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
8993 # ------------------------------------------
8994 m4_define([_LT_MANGLE_OPTION],
8995 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
8998 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
8999 # ---------------------------------------
9000 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
9001 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
9003 m4_define([_LT_SET_OPTION],
9004 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
9005 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
9006 _LT_MANGLE_DEFUN([$1], [$2]),
9007 [m4_warning([Unknown $1 option `$2'])])[]dnl
9011 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
9012 # ------------------------------------------------------------
9013 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
9014 m4_define([_LT_IF_OPTION],
9015 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
9018 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
9019 # -------------------------------------------------------
9020 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
9022 m4_define([_LT_UNLESS_OPTIONS],
9023 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9024 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
9025 [m4_define([$0_found])])])[]dnl
9026 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
9031 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
9032 # ----------------------------------------
9033 # OPTION-LIST is a space-separated list of Libtool options associated
9034 # with MACRO-NAME. If any OPTION has a matching handler declared with
9035 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
9036 # the unknown option and exit.
9037 m4_defun([_LT_SET_OPTIONS],
9039 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9040 [_LT_SET_OPTION([$1], _LT_Option)])
9042 m4_if([$1],[LT_INIT],[
9044 dnl Simply set some default values (i.e off) if boolean options were not
9046 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
9048 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
9051 dnl If no reference was made to various pairs of opposing options, then
9052 dnl we run the default mode handler for the pair. For example, if neither
9053 dnl `shared' nor `disable-shared' was passed, we enable building of shared
9054 dnl archives by default:
9055 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
9056 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
9057 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
9058 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
9059 [_LT_ENABLE_FAST_INSTALL])
9065 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
9066 # -----------------------------------------
9067 m4_define([_LT_MANGLE_DEFUN],
9068 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
9071 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
9072 # -----------------------------------------------
9073 m4_define([LT_OPTION_DEFINE],
9074 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
9075 ])# LT_OPTION_DEFINE
9080 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
9083 AU_DEFUN([AC_LIBTOOL_DLOPEN],
9084 [_LT_SET_OPTION([LT_INIT], [dlopen])
9085 AC_DIAGNOSE([obsolete],
9086 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9087 put the `dlopen' option into LT_INIT's first parameter.])
9090 dnl aclocal-1.4 backwards compatibility:
9091 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
9096 # Declare package support for building win32 dll's.
9097 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
9098 [enable_win32_dll=yes
9101 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
9102 AC_CHECK_TOOL(AS, as, false)
9103 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
9104 AC_CHECK_TOOL(OBJDUMP, objdump, false)
9108 test -z "$AS" && AS=as
9109 _LT_DECL([], [AS], [1], [Assembler program])dnl
9111 test -z "$DLLTOOL" && DLLTOOL=dlltool
9112 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
9114 test -z "$OBJDUMP" && OBJDUMP=objdump
9115 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
9118 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
9119 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
9120 _LT_SET_OPTION([LT_INIT], [win32-dll])
9121 AC_DIAGNOSE([obsolete],
9122 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9123 put the `win32-dll' option into LT_INIT's first parameter.])
9126 dnl aclocal-1.4 backwards compatibility:
9127 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
9130 # _LT_ENABLE_SHARED([DEFAULT])
9131 # ----------------------------
9132 # implement the --enable-shared flag, and supports the `shared' and
9133 # `disable-shared' LT_INIT options.
9134 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9135 m4_define([_LT_ENABLE_SHARED],
9136 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
9137 AC_ARG_ENABLE([shared],
9138 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
9139 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
9140 [p=${PACKAGE-default}
9142 yes) enable_shared=yes ;;
9143 no) enable_shared=no ;;
9146 # Look at the argument we got. We use all the common list separators.
9147 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9148 for pkg in $enableval; do
9150 if test "X$pkg" = "X$p"; then
9157 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
9159 _LT_DECL([build_libtool_libs], [enable_shared], [0],
9160 [Whether or not to build shared libraries])
9161 ])# _LT_ENABLE_SHARED
9163 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
9164 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
9167 AC_DEFUN([AC_ENABLE_SHARED],
9168 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
9171 AC_DEFUN([AC_DISABLE_SHARED],
9172 [_LT_SET_OPTION([LT_INIT], [disable-shared])
9175 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
9176 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
9178 dnl aclocal-1.4 backwards compatibility:
9179 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
9180 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
9184 # _LT_ENABLE_STATIC([DEFAULT])
9185 # ----------------------------
9186 # implement the --enable-static flag, and support the `static' and
9187 # `disable-static' LT_INIT options.
9188 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9189 m4_define([_LT_ENABLE_STATIC],
9190 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
9191 AC_ARG_ENABLE([static],
9192 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
9193 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
9194 [p=${PACKAGE-default}
9196 yes) enable_static=yes ;;
9197 no) enable_static=no ;;
9200 # Look at the argument we got. We use all the common list separators.
9201 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9202 for pkg in $enableval; do
9204 if test "X$pkg" = "X$p"; then
9211 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
9213 _LT_DECL([build_old_libs], [enable_static], [0],
9214 [Whether or not to build static libraries])
9215 ])# _LT_ENABLE_STATIC
9217 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
9218 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
9221 AC_DEFUN([AC_ENABLE_STATIC],
9222 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
9225 AC_DEFUN([AC_DISABLE_STATIC],
9226 [_LT_SET_OPTION([LT_INIT], [disable-static])
9229 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
9230 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
9232 dnl aclocal-1.4 backwards compatibility:
9233 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
9234 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
9238 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
9239 # ----------------------------------
9240 # implement the --enable-fast-install flag, and support the `fast-install'
9241 # and `disable-fast-install' LT_INIT options.
9242 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9243 m4_define([_LT_ENABLE_FAST_INSTALL],
9244 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
9245 AC_ARG_ENABLE([fast-install],
9246 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
9247 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
9248 [p=${PACKAGE-default}
9250 yes) enable_fast_install=yes ;;
9251 no) enable_fast_install=no ;;
9253 enable_fast_install=no
9254 # Look at the argument we got. We use all the common list separators.
9255 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9256 for pkg in $enableval; do
9258 if test "X$pkg" = "X$p"; then
9259 enable_fast_install=yes
9265 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
9267 _LT_DECL([fast_install], [enable_fast_install], [0],
9268 [Whether or not to optimize for fast installation])dnl
9269 ])# _LT_ENABLE_FAST_INSTALL
9271 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
9272 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
9275 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
9276 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
9277 AC_DIAGNOSE([obsolete],
9278 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9279 the `fast-install' option into LT_INIT's first parameter.])
9282 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
9283 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
9284 AC_DIAGNOSE([obsolete],
9285 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9286 the `disable-fast-install' option into LT_INIT's first parameter.])
9289 dnl aclocal-1.4 backwards compatibility:
9290 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
9291 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
9294 # _LT_WITH_PIC([MODE])
9295 # --------------------
9296 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
9298 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
9299 m4_define([_LT_WITH_PIC],
9301 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
9302 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
9303 [lt_p=${PACKAGE-default}
9305 yes|no) pic_mode=$withval ;;
9308 # Look at the argument we got. We use all the common list separators.
9309 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9310 for lt_pkg in $withval; do
9312 if test "X$lt_pkg" = "X$lt_p"; then
9321 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
9323 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
9326 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
9327 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
9330 AU_DEFUN([AC_LIBTOOL_PICMODE],
9331 [_LT_SET_OPTION([LT_INIT], [pic-only])
9332 AC_DIAGNOSE([obsolete],
9333 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9334 put the `pic-only' option into LT_INIT's first parameter.])
9337 dnl aclocal-1.4 backwards compatibility:
9338 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
9341 m4_define([_LTDL_MODE], [])
9342 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
9343 [m4_define([_LTDL_MODE], [nonrecursive])])
9344 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
9345 [m4_define([_LTDL_MODE], [recursive])])
9346 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
9347 [m4_define([_LTDL_MODE], [subproject])])
9349 m4_define([_LTDL_TYPE], [])
9350 LT_OPTION_DEFINE([LTDL_INIT], [installable],
9351 [m4_define([_LTDL_TYPE], [installable])])
9352 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
9353 [m4_define([_LTDL_TYPE], [convenience])])
9355 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
9357 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
9358 # Written by Gary V. Vaughan, 2004
9360 # This file is free software; the Free Software Foundation gives
9361 # unlimited permission to copy and/or distribute it, with or without
9362 # modifications, as long as this notice is preserved.
9364 # serial 6 ltsugar.m4
9366 # This is to help aclocal find these macros, as it can't see m4_define.
9367 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
9370 # lt_join(SEP, ARG1, [ARG2...])
9371 # -----------------------------
9372 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
9373 # associated separator.
9374 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
9375 # versions in m4sugar had bugs.
9376 m4_define([lt_join],
9377 [m4_if([$#], [1], [],
9379 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
9380 m4_define([_lt_join],
9381 [m4_if([$#$2], [2], [],
9382 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
9388 # Manipulate m4 lists.
9389 # These macros are necessary as long as will still need to support
9390 # Autoconf-2.59 which quotes differently.
9391 m4_define([lt_car], [[$1]])
9393 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
9395 [m4_dquote(m4_shift($@))])])
9396 m4_define([lt_unquote], $1)
9399 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
9400 # ------------------------------------------
9401 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
9402 # Note that neither SEPARATOR nor STRING are expanded; they are appended
9403 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
9404 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
9405 # than defined and empty).
9407 # This macro is needed until we can rely on Autoconf 2.62, since earlier
9408 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
9409 m4_define([lt_append],
9411 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
9415 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
9416 # ----------------------------------------------------------
9417 # Produce a SEP delimited list of all paired combinations of elements of
9418 # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
9419 # has the form PREFIXmINFIXSUFFIXn.
9420 # Needed until we can rely on m4_combine added in Autoconf 2.62.
9421 m4_define([lt_combine],
9422 [m4_if(m4_eval([$# > 3]), [1],
9423 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
9424 [[m4_foreach([_Lt_prefix], [$2],
9425 [m4_foreach([_Lt_suffix],
9426 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
9427 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
9430 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
9431 # -----------------------------------------------------------------------
9432 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
9433 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
9434 m4_define([lt_if_append_uniq],
9436 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
9437 [lt_append([$1], [$2], [$3])$4],
9439 [lt_append([$1], [$2], [$3])$4])])
9442 # lt_dict_add(DICT, KEY, VALUE)
9443 # -----------------------------
9444 m4_define([lt_dict_add],
9445 [m4_define([$1($2)], [$3])])
9448 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
9449 # --------------------------------------------
9450 m4_define([lt_dict_add_subkey],
9451 [m4_define([$1($2:$3)], [$4])])
9454 # lt_dict_fetch(DICT, KEY, [SUBKEY])
9455 # ----------------------------------
9456 m4_define([lt_dict_fetch],
9458 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
9459 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
9462 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
9463 # -----------------------------------------------------------------
9464 m4_define([lt_if_dict_fetch],
9465 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
9470 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
9471 # --------------------------------------------------------------
9472 m4_define([lt_dict_filter],
9473 [m4_if([$5], [], [],
9474 [lt_join(m4_quote(m4_default([$4], [[, ]])),
9475 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
9476 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
9479 # ltversion.m4 -- version numbers -*- Autoconf -*-
9481 # Copyright (C) 2004 Free Software Foundation, Inc.
9482 # Written by Scott James Remnant, 2004
9484 # This file is free software; the Free Software Foundation gives
9485 # unlimited permission to copy and/or distribute it, with or without
9486 # modifications, as long as this notice is preserved.
9490 # serial 3337 ltversion.m4
9491 # This file is part of GNU Libtool
9493 m4_define([LT_PACKAGE_VERSION], [2.4.2])
9494 m4_define([LT_PACKAGE_REVISION], [1.3337])
9496 AC_DEFUN([LTVERSION_VERSION],
9497 [macro_version='2.4.2'
9498 macro_revision='1.3337'
9499 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
9500 _LT_DECL(, macro_revision, 0)
9503 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
9505 # Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
9506 # Written by Scott James Remnant, 2004.
9508 # This file is free software; the Free Software Foundation gives
9509 # unlimited permission to copy and/or distribute it, with or without
9510 # modifications, as long as this notice is preserved.
9512 # serial 5 lt~obsolete.m4
9514 # These exist entirely to fool aclocal when bootstrapping libtool.
9516 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
9517 # which have later been changed to m4_define as they aren't part of the
9518 # exported API, or moved to Autoconf or Automake where they belong.
9520 # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
9521 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
9522 # using a macro with the same name in our local m4/libtool.m4 it'll
9523 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
9524 # and doesn't know about Autoconf macros at all.)
9526 # So we provide this file, which has a silly filename so it's always
9527 # included after everything else. This provides aclocal with the
9528 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
9529 # because those macros already exist, or will be overwritten later.
9530 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
9532 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
9533 # Yes, that means every name once taken will need to remain here until
9534 # we give up compatibility with versions before 1.7, at which point
9535 # we need to keep only those names which we still refer to.
9537 # This is to help aclocal find these macros, as it can't see m4_define.
9538 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
9540 m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
9541 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
9542 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
9543 m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
9544 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
9545 m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
9546 m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
9547 m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
9548 m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
9549 m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
9550 m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
9551 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
9552 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
9553 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
9554 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
9555 m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
9556 m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
9557 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
9558 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
9559 m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
9560 m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
9561 m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
9562 m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
9563 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
9564 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
9565 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
9566 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
9567 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
9568 m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
9569 m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
9570 m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
9571 m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
9572 m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
9573 m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
9574 m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
9575 m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
9576 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
9577 m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
9578 m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
9579 m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
9580 m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
9581 m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
9582 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
9583 m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
9584 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
9585 m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
9586 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
9587 m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
9588 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
9589 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
9590 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
9591 m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
9592 m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
9593 m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
9594 m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
9595 m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
9596 m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
9597 m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
9598 m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
9599 m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
9600 m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
9602 # nls.m4 serial 5 (gettext-0.18)
9603 dnl Copyright (C) 1995-2003, 2005-2006, 2008-2014 Free Software Foundation,
9605 dnl This file is free software; the Free Software Foundation
9606 dnl gives unlimited permission to copy and/or distribute it,
9607 dnl with or without modifications, as long as this notice is preserved.
9609 dnl This file can can be used in projects which are not available under
9610 dnl the GNU General Public License or the GNU Library General Public
9611 dnl License but which still want to provide support for the GNU gettext
9613 dnl Please note that the actual code of the GNU gettext library is covered
9614 dnl by the GNU Library General Public License, and the rest of the GNU
9615 dnl gettext package package is covered by the GNU General Public License.
9616 dnl They are *not* in the public domain.
9619 dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
9620 dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
9626 AC_MSG_CHECKING([whether NLS is requested])
9627 dnl Default is enabled NLS
9628 AC_ARG_ENABLE([nls],
9629 [ --disable-nls do not use Native Language Support],
9630 USE_NLS=$enableval, USE_NLS=yes)
9631 AC_MSG_RESULT([$USE_NLS])
9635 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
9636 # serial 1 (pkg-config-0.24)
9638 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
9640 # This program is free software; you can redistribute it and/or modify
9641 # it under the terms of the GNU General Public License as published by
9642 # the Free Software Foundation; either version 2 of the License, or
9643 # (at your option) any later version.
9645 # This program is distributed in the hope that it will be useful, but
9646 # WITHOUT ANY WARRANTY; without even the implied warranty of
9647 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
9648 # General Public License for more details.
9650 # You should have received a copy of the GNU General Public License
9651 # along with this program; if not, write to the Free Software
9652 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
9654 # As a special exception to the GNU General Public License, if you
9655 # distribute this file as part of a program that contains a
9656 # configuration script generated by Autoconf, you may include it under
9657 # the same distribution terms that you use for the rest of that program.
9659 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
9660 # ----------------------------------
9661 AC_DEFUN([PKG_PROG_PKG_CONFIG],
9662 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
9663 m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
9664 m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
9665 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
9666 AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
9667 AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
9669 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
9670 AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
9672 if test -n "$PKG_CONFIG"; then
9673 _pkg_min_version=m4_default([$1], [0.9.0])
9674 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
9675 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
9676 AC_MSG_RESULT([yes])
9682 ])# PKG_PROG_PKG_CONFIG
9684 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9686 # Check to see whether a particular set of modules exists. Similar
9687 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
9689 # Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9690 # only at the first occurence in configure.ac, so if the first place
9691 # it's called might be skipped (such as if it is within an "if", you
9692 # have to call PKG_CHECK_EXISTS manually
9693 # --------------------------------------------------------------
9694 AC_DEFUN([PKG_CHECK_EXISTS],
9695 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9696 if test -n "$PKG_CONFIG" && \
9697 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
9698 m4_default([$2], [:])
9699 m4_ifvaln([$3], [else
9703 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
9704 # ---------------------------------------------
9705 m4_define([_PKG_CONFIG],
9706 [if test -n "$$1"; then
9708 elif test -n "$PKG_CONFIG"; then
9709 PKG_CHECK_EXISTS([$3],
9710 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
9711 test "x$?" != "x0" && pkg_failed=yes ],
9718 # _PKG_SHORT_ERRORS_SUPPORTED
9719 # -----------------------------
9720 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
9721 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9722 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
9723 _pkg_short_errors_supported=yes
9725 _pkg_short_errors_supported=no
9727 ])# _PKG_SHORT_ERRORS_SUPPORTED
9730 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
9731 # [ACTION-IF-NOT-FOUND])
9734 # Note that if there is a possibility the first call to
9735 # PKG_CHECK_MODULES might not happen, you should be sure to include an
9736 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
9739 # --------------------------------------------------------------
9740 AC_DEFUN([PKG_CHECK_MODULES],
9741 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9742 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
9743 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
9746 AC_MSG_CHECKING([for $1])
9748 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
9749 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
9751 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
9752 and $1[]_LIBS to avoid the need to call pkg-config.
9753 See the pkg-config man page for more details.])
9755 if test $pkg_failed = yes; then
9757 _PKG_SHORT_ERRORS_SUPPORTED
9758 if test $_pkg_short_errors_supported = yes; then
9759 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
9761 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
9763 # Put the nasty error message in config.log where it belongs
9764 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
9766 m4_default([$4], [AC_MSG_ERROR(
9767 [Package requirements ($2) were not met:
9771 Consider adjusting the PKG_CONFIG_PATH environment variable if you
9772 installed software in a non-standard prefix.
9776 elif test $pkg_failed = untried; then
9778 m4_default([$4], [AC_MSG_FAILURE(
9779 [The pkg-config script could not be found or is too old. Make sure it
9780 is in your PATH or set the PKG_CONFIG environment variable to the full
9785 To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
9788 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
9789 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
9790 AC_MSG_RESULT([yes])
9793 ])# PKG_CHECK_MODULES
9796 # PKG_INSTALLDIR(DIRECTORY)
9797 # -------------------------
9798 # Substitutes the variable pkgconfigdir as the location where a module
9799 # should install pkg-config .pc files. By default the directory is
9800 # $libdir/pkgconfig, but the default can be changed by passing
9801 # DIRECTORY. The user can override through the --with-pkgconfigdir
9803 AC_DEFUN([PKG_INSTALLDIR],
9804 [m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])])
9805 m4_pushdef([pkg_description],
9806 [pkg-config installation directory @<:@]pkg_default[@:>@])
9807 AC_ARG_WITH([pkgconfigdir],
9808 [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],,
9809 [with_pkgconfigdir=]pkg_default)
9810 AC_SUBST([pkgconfigdir], [$with_pkgconfigdir])
9811 m4_popdef([pkg_default])
9812 m4_popdef([pkg_description])
9813 ]) dnl PKG_INSTALLDIR
9816 # PKG_NOARCH_INSTALLDIR(DIRECTORY)
9817 # -------------------------
9818 # Substitutes the variable noarch_pkgconfigdir as the location where a
9819 # module should install arch-independent pkg-config .pc files. By
9820 # default the directory is $datadir/pkgconfig, but the default can be
9821 # changed by passing DIRECTORY. The user can override through the
9822 # --with-noarch-pkgconfigdir parameter.
9823 AC_DEFUN([PKG_NOARCH_INSTALLDIR],
9824 [m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])])
9825 m4_pushdef([pkg_description],
9826 [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@])
9827 AC_ARG_WITH([noarch-pkgconfigdir],
9828 [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],,
9829 [with_noarch_pkgconfigdir=]pkg_default)
9830 AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir])
9831 m4_popdef([pkg_default])
9832 m4_popdef([pkg_description])
9833 ]) dnl PKG_NOARCH_INSTALLDIR
9836 # PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE,
9837 # [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9838 # -------------------------------------------
9839 # Retrieves the value of the pkg-config variable for the given module.
9840 AC_DEFUN([PKG_CHECK_VAR],
9841 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9842 AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl
9844 _PKG_CONFIG([$1], [variable="][$3]["], [$2])
9845 AS_VAR_COPY([$1], [pkg_cv_][$1])
9847 AS_VAR_IF([$1], [""], [$5], [$4])dnl
9850 AC_DEFUN([YELP_HELP_INIT],
9852 AC_REQUIRE([AC_PROG_LN_S])
9853 m4_pattern_allow([AM_V_at])
9854 m4_pattern_allow([AM_V_GEN])
9855 m4_pattern_allow([AM_DEFAULT_VERBOSITY])
9857 YELP_LC_MEDIA_LINKS=true
9860 for yelpopt in [$1]; do
9862 lc-media-links) YELP_LC_MEDIA_LINKS=true ;;
9863 no-lc-media-links) YELP_LC_MEDIA_LINKS= ;;
9864 lc-dist) YELP_LC_DIST=true ;;
9865 no-lc-dist) YELP_LC_DIST= ;;
9866 *) AC_MSG_ERROR([Unrecognized [YELP_HELP_INIT] option $yelpopt"]) ;;
9869 AC_SUBST([YELP_LC_MEDIA_LINKS])
9870 AC_SUBST([YELP_LC_DIST])
9872 AC_ARG_WITH([help-dir],
9873 AS_HELP_STRING([--with-help-dir=DIR],
9874 [path where help files are installed]),,
9875 [with_help_dir='${datadir}/help'])
9876 HELP_DIR="$with_help_dir"
9879 AC_ARG_VAR([ITSTOOL], [Path to the `itstool` command])
9880 AC_CHECK_PROG([ITSTOOL], [itstool], [itstool])
9881 if test x"$ITSTOOL" = x; then
9882 AC_MSG_ERROR([itstool not found])
9885 AC_ARG_VAR([XMLLINT], [Path to the `xmllint` command])
9886 AC_CHECK_PROG([XMLLINT], [xmllint], [xmllint])
9887 if test x"$XMLLINT" = x; then
9888 AC_MSG_ERROR([xmllint not found])
9899 _HELP_LINGUAS = $(if $(filter environment,$(origin LINGUAS)),$(filter $(LINGUAS),$(HELP_LINGUAS)),$(HELP_LINGUAS))
9900 _HELP_POTFILE = $(if $(HELP_POT),$(HELP_POT),$(if $(HELP_ID),$(HELP_ID).pot))
9901 _HELP_POFILES = $(if $(HELP_ID),$(foreach lc,$(_HELP_LINGUAS),$(lc)/$(lc).po))
9902 _HELP_MOFILES = $(patsubst %.po,%.mo,$(_HELP_POFILES))
9903 _HELP_C_FILES = $(foreach f,$(HELP_FILES),C/$(f))
9904 _HELP_C_EXTRA = $(foreach f,$(HELP_EXTRA),C/$(f))
9905 _HELP_C_MEDIA = $(foreach f,$(HELP_MEDIA),C/$(f))
9906 _HELP_LC_FILES = $(foreach lc,$(_HELP_LINGUAS),$(foreach f,$(HELP_FILES),$(lc)/$(f)))
9907 _HELP_LC_STAMPS = $(foreach lc,$(_HELP_LINGUAS),$(lc)/$(lc).stamp)
9909 _HELP_DEFAULT_V = $(if $(AM_DEFAULT_VERBOSITY),$(AM_DEFAULT_VERBOSITY),1)
9910 _HELP_V = $(if $(V),$(V),$(_HELP_DEFAULT_V))
9911 _HELP_LC_VERBOSE = $(_HELP_LC_VERBOSE_$(_HELP_V))
9912 _HELP_LC_VERBOSE_ = $(_HELP_LC_VERBOSE_$(_HELP_DEFAULT_V))
9913 _HELP_LC_VERBOSE_0 = @echo " GEN "$(dir [$]@);
9915 all: $(_HELP_C_FILES) $(_HELP_C_EXTRA) $(_HELP_C_MEDIA) $(_HELP_LC_FILES) $(_HELP_POFILES)
9918 pot: $(_HELP_POTFILE)
9919 $(_HELP_POTFILE): $(_HELP_C_FILES) $(_HELP_C_EXTRA) $(_HELP_C_MEDIA)
9920 $(AM_V_GEN)if test -d "C"; then d=; else d="$(srcdir)/"; fi; \
9921 $(ITSTOOL) -o "[$]@" $(foreach f,$(_HELP_C_FILES),"$${d}$(f)")
9924 repo: $(_HELP_POTFILE)
9925 $(AM_V_at)for po in $(_HELP_POFILES); do \
9926 if test "x[$](_HELP_V)" = "x0"; then echo " GEN $${po}"; fi; \
9927 msgmerge -q -o "$${po}" "$${po}" "$(_HELP_POTFILE)"; \
9931 $(AM_V_at)if ! test -d "$(dir [$]@)"; then mkdir "$(dir [$]@)"; fi
9932 $(AM_V_at)if test ! -f "[$]@" -a -f "$(srcdir)/[$]@"; then cp "$(srcdir)/[$]@" "[$]@"; fi
9933 $(AM_V_GEN)if ! test -f "[$]@"; then \
9934 (cd "$(dir [$]@)" && \
9935 $(ITSTOOL) -o "$(notdir [$]@).tmp" $(_HELP_C_FILES) && \
9936 mv "$(notdir [$]@).tmp" "$(notdir [$]@)"); \
9938 (cd "$(dir [$]@)" && \
9939 $(ITSTOOL) -o "$(notdir [$]@).tmp" $(_HELP_C_FILES) && \
9940 msgmerge -o "$(notdir [$]@)" "$(notdir [$]@)" "$(notdir [$]@).tmp" && \
9941 rm "$(notdir [$]@).tmp"); \
9944 $(_HELP_MOFILES): %.mo: %.po
9945 $(AM_V_at)if ! test -d "$(dir [$]@)"; then mkdir "$(dir [$]@)"; fi
9946 $(AM_V_GEN)msgfmt -o "[$]@" "$<"
9948 $(_HELP_LC_FILES): $(_HELP_LINGUAS)
9949 $(_HELP_LINGUAS): $(_HELP_LC_STAMPS)
9950 $(_HELP_LC_STAMPS): %.stamp: %.mo
9951 $(_HELP_LC_STAMPS): $(_HELP_C_FILES) $(_HELP_C_EXTRA)
9952 $(AM_V_at)if ! test -d "$(dir [$]@)"; then mkdir "$(dir [$]@)"; fi
9953 $(_HELP_LC_VERBOSE)if test -d "C"; then d="../"; else d="$(abs_srcdir)/"; fi; \
9954 mo="$(dir [$]@)$(patsubst %/$(notdir [$]@),%,[$]@).mo"; \
9955 if test -f "$${mo}"; then mo="../$${mo}"; else mo="$(abs_srcdir)/$${mo}"; fi; \
9956 (cd "$(dir [$]@)" && $(ITSTOOL) -m "$${mo}" $(foreach f,$(_HELP_C_FILES),$${d}/$(f))) && \
9960 mostlyclean-am: $(if $(HELP_ID),clean-help)
9962 rm -f $(_HELP_LC_FILES) $(_HELP_LC_STAMPS) $(_HELP_MOFILES)
9965 EXTRA_DIST += $(_HELP_C_EXTRA) $(_HELP_C_MEDIA)
9966 EXTRA_DIST += $(if $(YELP_LC_DIST),$(foreach lc,$(HELP_LINGUAS),$(lc)/$(lc).stamp))
9967 EXTRA_DIST += $(foreach lc,$(HELP_LINGUAS),$(lc)/$(lc).po)
9968 EXTRA_DIST += $(foreach f,$(HELP_MEDIA),$(foreach lc,$(HELP_LINGUAS),$(wildcard $(lc)/$(f))))
9970 distdir: distdir-help-files
9971 distdir-help-files: $(_HELP_LC_FILES)
9972 @for lc in C $(if $(YELP_LC_DIST),$(HELP_LINGUAS)) ; do \
9973 $(MKDIR_P) "$(distdir)/$$lc"; \
9974 for file in $(HELP_FILES); do \
9975 if test -f "$$lc/$$file"; then d=./; else d=$(srcdir)/; fi; \
9976 cp -p "$$d$$lc/$$file" "$(distdir)/$$lc/" || exit 1; \
9983 for lc in C $(_HELP_LINGUAS); do \
9984 if test -d "$$lc"; \
9989 xmlpath="$$lc:$(srcdir)/$$lc"; \
9991 for page in $(HELP_FILES); do \
9992 echo "$(XMLLINT) --noout --noent --path $$xmlpath --xinclude $$d$$lc/$$page"; \
9993 $(XMLLINT) --noout --noent --path "$$xmlpath" --xinclude "$$d$$lc/$$page"; \
9998 .PHONY: install-help
9999 install-data-am: $(if $(HELP_ID),install-help)
10000 install-help: $(_HELP_LC_FILES)
10001 @for lc in C $(_HELP_LINGUAS); do \
10002 $(mkinstalldirs) "$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)" || exit 1; \
10004 @for lc in C $(_HELP_LINGUAS); do for f in $(HELP_FILES); do \
10005 if test -f "$$lc/$$f"; then d=; else d="$(srcdir)/"; fi; \
10006 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
10007 if ! test -d "$$helpdir"; then $(mkinstalldirs) "$$helpdir"; fi; \
10008 echo "$(INSTALL_DATA) $$d$$lc/$$f $$helpdir`basename $$f`"; \
10009 $(INSTALL_DATA) "$$d$$lc/$$f" "$$helpdir`basename $$f`" || exit 1; \
10011 @for f in $(_HELP_C_EXTRA); do \
10012 lc=`dirname "$$f"`; lc=`basename "$$lc"`; \
10013 if test -f "$$f"; then d=; else d="$(srcdir)/"; fi; \
10014 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
10015 if ! test -d "$$helpdir"; then $(mkinstalldirs) "$$helpdir"; fi; \
10016 echo "$(INSTALL_DATA) $$d$$f $$helpdir`basename $$f`"; \
10017 $(INSTALL_DATA) "$$d$$f" "$$helpdir`basename $$f`" || exit 1; \
10019 @for f in $(HELP_MEDIA); do \
10020 for lc in C $(_HELP_LINGUAS); do \
10021 if test -f "$$lc$$f"; then d=; else d="$(srcdir)/"; fi; \
10022 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
10023 mdir=`dirname "$$f"`; \
10024 if test "x$mdir" = "x."; then mdir=""; fi; \
10025 if ! test -d "$$helpdir$$mdir"; then $(mkinstalldirs) "$$helpdir$$mdir"; fi; \
10026 if test -f "$$d$$lc/$$f"; then \
10027 echo "$(INSTALL_DATA) $$d$$lc/$$f $$helpdir$$f"; \
10028 $(INSTALL_DATA) "$$d$$lc/$$f" "$$helpdir$$f" || exit 1; \
10029 elif test "x$$lc" != "xC"; then \
10030 if test "x$(YELP_LC_MEDIA_LINKS)" != "x"; then \
10031 echo "$(LN_S) -f $(HELP_DIR)/C/$(HELP_ID)/$$f $$helpdir$$f"; \
10032 $(LN_S) -f "$(HELP_DIR)/C/$(HELP_ID)/$$f" "$$helpdir$$f" || exit 1; \
10038 .PHONY: uninstall-help
10039 uninstall-am: $(if $(HELP_ID),uninstall-help)
10041 for lc in C $(_HELP_LINGUAS); do for f in $(HELP_FILES); do \
10042 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
10043 echo "rm -f $$helpdir`basename $$f`"; \
10044 rm -f "$$helpdir`basename $$f`"; \
10046 @for f in $(_HELP_C_EXTRA); do \
10047 lc=`dirname "$$f"`; lc=`basename "$$lc"`; \
10048 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
10049 echo "rm -f $$helpdir`basename $$f`"; \
10050 rm -f "$$helpdir`basename $$f`"; \
10052 @for f in $(HELP_MEDIA); do \
10053 for lc in C $(_HELP_LINGUAS); do \
10054 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
10055 echo "rm -f $$helpdir$$f"; \
10056 rm -f "$$helpdir$$f"; \
10060 AC_SUBST([YELP_HELP_RULES])
10061 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([YELP_HELP_RULES])])
10064 # Copyright (C) 2002-2014 Free Software Foundation, Inc.
10066 # This file is free software; the Free Software Foundation
10067 # gives unlimited permission to copy and/or distribute it,
10068 # with or without modifications, as long as this notice is preserved.
10070 # AM_AUTOMAKE_VERSION(VERSION)
10071 # ----------------------------
10072 # Automake X.Y traces this macro to ensure aclocal.m4 has been
10073 # generated from the m4 files accompanying Automake X.Y.
10074 # (This private macro should not be called outside this file.)
10075 AC_DEFUN([AM_AUTOMAKE_VERSION],
10076 [am__api_version='1.15'
10077 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
10078 dnl require some minimum version. Point them to the right macro.
10079 m4_if([$1], [1.15], [],
10080 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
10083 # _AM_AUTOCONF_VERSION(VERSION)
10084 # -----------------------------
10085 # aclocal traces this macro to find the Autoconf version.
10086 # This is a private macro too. Using m4_define simplifies
10087 # the logic in aclocal, which can simply ignore this definition.
10088 m4_define([_AM_AUTOCONF_VERSION], [])
10090 # AM_SET_CURRENT_AUTOMAKE_VERSION
10091 # -------------------------------
10092 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
10093 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
10094 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
10095 [AM_AUTOMAKE_VERSION([1.15])dnl
10096 m4_ifndef([AC_AUTOCONF_VERSION],
10097 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
10098 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
10100 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
10102 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10104 # This file is free software; the Free Software Foundation
10105 # gives unlimited permission to copy and/or distribute it,
10106 # with or without modifications, as long as this notice is preserved.
10108 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
10109 # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
10110 # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
10112 # Of course, Automake must honor this variable whenever it calls a
10113 # tool from the auxiliary directory. The problem is that $srcdir (and
10114 # therefore $ac_aux_dir as well) can be either absolute or relative,
10115 # depending on how configure is run. This is pretty annoying, since
10116 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
10117 # source directory, any form will work fine, but in subdirectories a
10118 # relative path needs to be adjusted first.
10120 # $ac_aux_dir/missing
10121 # fails when called from a subdirectory if $ac_aux_dir is relative
10122 # $top_srcdir/$ac_aux_dir/missing
10123 # fails if $ac_aux_dir is absolute,
10124 # fails when called from a subdirectory in a VPATH build with
10125 # a relative $ac_aux_dir
10127 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
10128 # are both prefixed by $srcdir. In an in-source build this is usually
10129 # harmless because $srcdir is '.', but things will broke when you
10130 # start a VPATH build or use an absolute $srcdir.
10132 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
10133 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
10134 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
10135 # and then we would define $MISSING as
10136 # MISSING="\${SHELL} $am_aux_dir/missing"
10137 # This will work as long as MISSING is not called from configure, because
10138 # unfortunately $(top_srcdir) has no meaning in configure.
10139 # However there are other variables, like CC, which are often used in
10140 # configure, and could therefore not use this "fixed" $ac_aux_dir.
10142 # Another solution, used here, is to always expand $ac_aux_dir to an
10143 # absolute PATH. The drawback is that using absolute paths prevent a
10144 # configured tree to be moved without reconfiguration.
10146 AC_DEFUN([AM_AUX_DIR_EXPAND],
10147 [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
10148 # Expand $ac_aux_dir to an absolute path.
10149 am_aux_dir=`cd "$ac_aux_dir" && pwd`
10152 # AM_CONDITIONAL -*- Autoconf -*-
10154 # Copyright (C) 1997-2014 Free Software Foundation, Inc.
10156 # This file is free software; the Free Software Foundation
10157 # gives unlimited permission to copy and/or distribute it,
10158 # with or without modifications, as long as this notice is preserved.
10160 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
10161 # -------------------------------------
10162 # Define a conditional.
10163 AC_DEFUN([AM_CONDITIONAL],
10164 [AC_PREREQ([2.52])dnl
10165 m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
10166 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
10167 AC_SUBST([$1_TRUE])dnl
10168 AC_SUBST([$1_FALSE])dnl
10169 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
10170 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
10171 m4_define([_AM_COND_VALUE_$1], [$2])dnl
10179 AC_CONFIG_COMMANDS_PRE(
10180 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
10181 AC_MSG_ERROR([[conditional "$1" was never defined.
10182 Usually this means the macro was only invoked conditionally.]])
10185 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
10187 # This file is free software; the Free Software Foundation
10188 # gives unlimited permission to copy and/or distribute it,
10189 # with or without modifications, as long as this notice is preserved.
10192 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
10193 # written in clear, in which case automake, when reading aclocal.m4,
10194 # will think it sees a *use*, and therefore will trigger all it's
10195 # C support machinery. Also note that it means that autoscan, seeing
10196 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
10199 # _AM_DEPENDENCIES(NAME)
10200 # ----------------------
10201 # See how the compiler implements dependency checking.
10202 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
10203 # We try a few techniques and use that to set a single cache variable.
10205 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
10206 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
10207 # dependency, and given that the user is not expected to run this macro,
10208 # just rely on AC_PROG_CC.
10209 AC_DEFUN([_AM_DEPENDENCIES],
10210 [AC_REQUIRE([AM_SET_DEPDIR])dnl
10211 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
10212 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
10213 AC_REQUIRE([AM_DEP_TRACK])dnl
10215 m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
10216 [$1], [CXX], [depcc="$CXX" am_compiler_list=],
10217 [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
10218 [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
10219 [$1], [UPC], [depcc="$UPC" am_compiler_list=],
10220 [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
10221 [depcc="$$1" am_compiler_list=])
10223 AC_CACHE_CHECK([dependency style of $depcc],
10224 [am_cv_$1_dependencies_compiler_type],
10225 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
10226 # We make a subdir and do the tests there. Otherwise we can end up
10227 # making bogus files that we don't know about and never remove. For
10228 # instance it was reported that on HP-UX the gcc test will end up
10229 # making a dummy file named 'D' -- because '-MD' means "put the output
10231 rm -rf conftest.dir
10233 # Copy depcomp to subdir because otherwise we won't find it if we're
10234 # using a relative directory.
10235 cp "$am_depcomp" conftest.dir
10237 # We will build objects and dependencies in a subdirectory because
10238 # it helps to detect inapplicable dependency modes. For instance
10239 # both Tru64's cc and ICC support -MD to output dependencies as a
10240 # side effect of compilation, but ICC will put the dependencies in
10241 # the current directory while Tru64 will put them in the object
10245 am_cv_$1_dependencies_compiler_type=none
10246 if test "$am_compiler_list" = ""; then
10247 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
10249 am__universal=false
10250 m4_case([$1], [CC],
10251 [case " $depcc " in #(
10252 *\ -arch\ *\ -arch\ *) am__universal=true ;;
10255 [case " $depcc " in #(
10256 *\ -arch\ *\ -arch\ *) am__universal=true ;;
10259 for depmode in $am_compiler_list; do
10260 # Setup a source with many dependencies, because some compilers
10261 # like to wrap large dependency lists on column 80 (with \), and
10262 # we should not choose a depcomp mode which is confused by this.
10264 # We need to recreate these files for each test, as the compiler may
10265 # overwrite some of them when testing with obscure command lines.
10266 # This happens at least with the AIX C compiler.
10268 for i in 1 2 3 4 5 6; do
10269 echo '#include "conftst'$i'.h"' >> sub/conftest.c
10270 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
10271 # Solaris 10 /bin/sh.
10272 echo '/* dummy */' > sub/conftst$i.h
10274 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
10276 # We check with '-c' and '-o' for the sake of the "dashmstdout"
10277 # mode. It turns out that the SunPro C++ compiler does not properly
10278 # handle '-M -o', and we need to detect this. Also, some Intel
10279 # versions had trouble with output in subdirs.
10280 am__obj=sub/conftest.${OBJEXT-o}
10281 am__minus_obj="-o $am__obj"
10284 # This depmode causes a compiler race in universal mode.
10285 test "$am__universal" = false || continue
10288 # After this tag, mechanisms are not by side-effect, so they'll
10289 # only be used when explicitly requested.
10290 if test "x$enable_dependency_tracking" = xyes; then
10296 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
10297 # This compiler won't grok '-c -o', but also, the minuso test has
10298 # not run yet. These depmodes are late enough in the game, and
10299 # so weak that their functioning should not be impacted.
10300 am__obj=conftest.${OBJEXT-o}
10305 if depmode=$depmode \
10306 source=sub/conftest.c object=$am__obj \
10307 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
10308 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
10309 >/dev/null 2>conftest.err &&
10310 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
10311 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
10312 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
10313 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
10314 # icc doesn't choke on unknown options, it will just issue warnings
10315 # or remarks (even with -Werror). So we grep stderr for any message
10316 # that says an option was ignored or not supported.
10317 # When given -MP, icc 7.0 and 7.1 complain thusly:
10318 # icc: Command line warning: ignoring option '-M'; no argument required
10319 # The diagnosis changed in icc 8.0:
10320 # icc: Command line remark: option '-MP' not supported
10321 if (grep 'ignoring option' conftest.err ||
10322 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
10323 am_cv_$1_dependencies_compiler_type=$depmode
10330 rm -rf conftest.dir
10332 am_cv_$1_dependencies_compiler_type=none
10335 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
10336 AM_CONDITIONAL([am__fastdep$1], [
10337 test "x$enable_dependency_tracking" != xno \
10338 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
10344 # Choose a directory name for dependency files.
10345 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
10346 AC_DEFUN([AM_SET_DEPDIR],
10347 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10348 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
10354 AC_DEFUN([AM_DEP_TRACK],
10355 [AC_ARG_ENABLE([dependency-tracking], [dnl
10357 [--enable-dependency-tracking],
10358 [do not reject slow dependency extractors])
10360 [--disable-dependency-tracking],
10361 [speeds up one-time build])])
10362 if test "x$enable_dependency_tracking" != xno; then
10363 am_depcomp="$ac_aux_dir/depcomp"
10367 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
10368 AC_SUBST([AMDEPBACKSLASH])dnl
10369 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
10370 AC_SUBST([am__nodep])dnl
10371 _AM_SUBST_NOTMAKE([am__nodep])dnl
10374 # Generate code to set up dependency tracking. -*- Autoconf -*-
10376 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
10378 # This file is free software; the Free Software Foundation
10379 # gives unlimited permission to copy and/or distribute it,
10380 # with or without modifications, as long as this notice is preserved.
10383 # _AM_OUTPUT_DEPENDENCY_COMMANDS
10384 # ------------------------------
10385 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
10387 # Older Autoconf quotes --file arguments for eval, but not when files
10388 # are listed without --file. Let's play safe and only enable the eval
10389 # if we detect the quoting.
10390 case $CONFIG_FILES in
10391 *\'*) eval set x "$CONFIG_FILES" ;;
10392 *) set x $CONFIG_FILES ;;
10397 # Strip MF so we end up with the name of the file.
10398 mf=`echo "$mf" | sed -e 's/:.*$//'`
10399 # Check whether this is an Automake generated Makefile or not.
10400 # We used to match only the files named 'Makefile.in', but
10401 # some people rename them; so instead we look at the file content.
10402 # Grep'ing the first line is not enough: some people post-process
10403 # each Makefile.in and add a new line on top of each file to say so.
10404 # Grep'ing the whole file is not good either: AIX grep has a line
10405 # limit of 2048, but all sed's we know have understand at least 4000.
10406 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
10407 dirpart=`AS_DIRNAME("$mf")`
10411 # Extract the definition of DEPDIR, am__include, and am__quote
10412 # from the Makefile without running 'make'.
10413 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
10414 test -z "$DEPDIR" && continue
10415 am__include=`sed -n 's/^am__include = //p' < "$mf"`
10416 test -z "$am__include" && continue
10417 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
10418 # Find all dependency output files, they are included files with
10419 # $(DEPDIR) in their names. We invoke sed twice because it is the
10420 # simplest approach to changing $(DEPDIR) to its actual value in the
10422 for file in `sed -n "
10423 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
10424 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
10425 # Make sure the directory exists.
10426 test -f "$dirpart/$file" && continue
10427 fdir=`AS_DIRNAME(["$file"])`
10428 AS_MKDIR_P([$dirpart/$fdir])
10429 # echo "creating $dirpart/$file"
10430 echo '# dummy' > "$dirpart/$file"
10434 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
10437 # AM_OUTPUT_DEPENDENCY_COMMANDS
10438 # -----------------------------
10439 # This macro should only be invoked once -- use via AC_REQUIRE.
10441 # This code is only required when automatic dependency tracking
10442 # is enabled. FIXME. This creates each '.P' file that we will
10443 # need in order to bootstrap the dependency handling code.
10444 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
10445 [AC_CONFIG_COMMANDS([depfiles],
10446 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
10447 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
10450 # Do all the work for Automake. -*- Autoconf -*-
10452 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10454 # This file is free software; the Free Software Foundation
10455 # gives unlimited permission to copy and/or distribute it,
10456 # with or without modifications, as long as this notice is preserved.
10458 # This macro actually does too much. Some checks are only needed if
10459 # your package does certain things. But this isn't really a big deal.
10461 dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
10462 m4_define([AC_PROG_CC],
10463 m4_defn([AC_PROG_CC])
10467 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
10468 # AM_INIT_AUTOMAKE([OPTIONS])
10469 # -----------------------------------------------
10470 # The call with PACKAGE and VERSION arguments is the old style
10471 # call (pre autoconf-2.50), which is being phased out. PACKAGE
10472 # and VERSION should now be passed to AC_INIT and removed from
10473 # the call to AM_INIT_AUTOMAKE.
10474 # We support both call styles for the transition. After
10475 # the next Automake release, Autoconf can make the AC_INIT
10476 # arguments mandatory, and then we can depend on a new Autoconf
10477 # release and drop the old call support.
10478 AC_DEFUN([AM_INIT_AUTOMAKE],
10479 [AC_PREREQ([2.65])dnl
10480 dnl Autoconf wants to disallow AM_ names. We explicitly allow
10481 dnl the ones we care about.
10482 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
10483 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
10484 AC_REQUIRE([AC_PROG_INSTALL])dnl
10485 if test "`cd $srcdir && pwd`" != "`pwd`"; then
10486 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
10487 # is not polluted with repeated "-I."
10488 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
10489 # test to see if srcdir already configured
10490 if test -f $srcdir/config.status; then
10491 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
10495 # test whether we have cygpath
10496 if test -z "$CYGPATH_W"; then
10497 if (cygpath --version) >/dev/null 2>/dev/null; then
10498 CYGPATH_W='cygpath -w'
10503 AC_SUBST([CYGPATH_W])
10505 # Define the identity of the package.
10506 dnl Distinguish between old-style and new-style calls.
10508 [AC_DIAGNOSE([obsolete],
10509 [$0: two- and three-arguments forms are deprecated.])
10510 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
10511 AC_SUBST([PACKAGE], [$1])dnl
10512 AC_SUBST([VERSION], [$2])],
10513 [_AM_SET_OPTIONS([$1])dnl
10514 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
10516 m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
10518 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
10519 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
10520 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
10522 _AM_IF_OPTION([no-define],,
10523 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
10524 AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
10526 # Some tools Automake needs.
10527 AC_REQUIRE([AM_SANITY_CHECK])dnl
10528 AC_REQUIRE([AC_ARG_PROGRAM])dnl
10529 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
10530 AM_MISSING_PROG([AUTOCONF], [autoconf])
10531 AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
10532 AM_MISSING_PROG([AUTOHEADER], [autoheader])
10533 AM_MISSING_PROG([MAKEINFO], [makeinfo])
10534 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10535 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
10536 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
10537 # For better backward compatibility. To be removed once Automake 1.9.x
10538 # dies out for good. For more background, see:
10539 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
10540 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
10541 AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
10542 # We need awk for the "check" target (and possibly the TAP driver). The
10543 # system "awk" is bad on some platforms.
10544 AC_REQUIRE([AC_PROG_AWK])dnl
10545 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
10546 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10547 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
10548 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
10549 [_AM_PROG_TAR([v7])])])
10550 _AM_IF_OPTION([no-dependencies],,
10551 [AC_PROVIDE_IFELSE([AC_PROG_CC],
10552 [_AM_DEPENDENCIES([CC])],
10553 [m4_define([AC_PROG_CC],
10554 m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
10555 AC_PROVIDE_IFELSE([AC_PROG_CXX],
10556 [_AM_DEPENDENCIES([CXX])],
10557 [m4_define([AC_PROG_CXX],
10558 m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
10559 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
10560 [_AM_DEPENDENCIES([OBJC])],
10561 [m4_define([AC_PROG_OBJC],
10562 m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
10563 AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
10564 [_AM_DEPENDENCIES([OBJCXX])],
10565 [m4_define([AC_PROG_OBJCXX],
10566 m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
10568 AC_REQUIRE([AM_SILENT_RULES])dnl
10569 dnl The testsuite driver may need to know about EXEEXT, so add the
10570 dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
10571 dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
10572 AC_CONFIG_COMMANDS_PRE(dnl
10573 [m4_provide_if([_AM_COMPILER_EXEEXT],
10574 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
10576 # POSIX will say in a future version that running "rm -f" with no argument
10577 # is OK; and we want to be able to make that assumption in our Makefile
10578 # recipes. So use an aggressive probe to check that the usage we want is
10579 # actually supported "in the wild" to an acceptable degree.
10580 # See automake bug#10828.
10581 # To make any issue more visible, cause the running configure to be aborted
10582 # by default if the 'rm' program in use doesn't match our expectations; the
10583 # user can still override this though.
10584 if rm -f && rm -fr && rm -rf; then : OK; else
10588 Your 'rm' program seems unable to run without file operands specified
10589 on the command line, even when the '-f' option is present. This is contrary
10590 to the behaviour of most rm programs out there, and not conforming with
10591 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
10593 Please tell bug-automake@gnu.org about your system, including the value
10594 of your $PATH and any error possibly output before this message. This
10595 can help us improve future automake versions.
10598 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
10599 echo 'Configuration will proceed anyway, since you have set the' >&2
10600 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
10604 Aborting the configuration process, to ensure you take notice of the issue.
10606 You can download and install GNU coreutils to get an 'rm' implementation
10607 that behaves properly: <http://www.gnu.org/software/coreutils/>.
10609 If you want to complete the configuration process using your problematic
10610 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
10611 to "yes", and re-run configure.
10614 AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
10617 dnl The trailing newline in this macro's definition is deliberate, for
10618 dnl backward compatibility and to allow trailing 'dnl'-style comments
10619 dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
10622 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
10623 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
10624 dnl mangled by Autoconf and run in a shell conditional statement.
10625 m4_define([_AC_COMPILER_EXEEXT],
10626 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
10628 # When config.status generates a header, we must update the stamp-h file.
10629 # This file resides in the same directory as the config header
10630 # that is generated. The stamp files are numbered to have different names.
10632 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
10633 # loop where config.status creates the headers, so we can generate
10634 # our stamp files there.
10635 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
10636 [# Compute $1's index in $config_headers.
10639 for _am_header in $config_headers :; do
10640 case $_am_header in
10641 $_am_arg | $_am_arg:* )
10644 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
10647 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
10649 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10651 # This file is free software; the Free Software Foundation
10652 # gives unlimited permission to copy and/or distribute it,
10653 # with or without modifications, as long as this notice is preserved.
10655 # AM_PROG_INSTALL_SH
10656 # ------------------
10657 # Define $install_sh.
10658 AC_DEFUN([AM_PROG_INSTALL_SH],
10659 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10660 if test x"${install_sh+set}" != xset; then
10661 case $am_aux_dir in
10663 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
10665 install_sh="\${SHELL} $am_aux_dir/install-sh"
10668 AC_SUBST([install_sh])])
10670 # Copyright (C) 2003-2014 Free Software Foundation, Inc.
10672 # This file is free software; the Free Software Foundation
10673 # gives unlimited permission to copy and/or distribute it,
10674 # with or without modifications, as long as this notice is preserved.
10676 # Check whether the underlying file-system supports filenames
10677 # with a leading dot. For instance MS-DOS doesn't.
10678 AC_DEFUN([AM_SET_LEADING_DOT],
10679 [rm -rf .tst 2>/dev/null
10680 mkdir .tst 2>/dev/null
10681 if test -d .tst; then
10686 rmdir .tst 2>/dev/null
10687 AC_SUBST([am__leading_dot])])
10689 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
10690 # From Jim Meyering
10692 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10694 # This file is free software; the Free Software Foundation
10695 # gives unlimited permission to copy and/or distribute it,
10696 # with or without modifications, as long as this notice is preserved.
10698 # AM_MAINTAINER_MODE([DEFAULT-MODE])
10699 # ----------------------------------
10700 # Control maintainer-specific portions of Makefiles.
10701 # Default is to disable them, unless 'enable' is passed literally.
10702 # For symmetry, 'disable' may be passed as well. Anyway, the user
10703 # can override the default with the --enable/--disable switch.
10704 AC_DEFUN([AM_MAINTAINER_MODE],
10705 [m4_case(m4_default([$1], [disable]),
10706 [enable], [m4_define([am_maintainer_other], [disable])],
10707 [disable], [m4_define([am_maintainer_other], [enable])],
10708 [m4_define([am_maintainer_other], [enable])
10709 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
10710 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
10711 dnl maintainer-mode's default is 'disable' unless 'enable' is passed
10712 AC_ARG_ENABLE([maintainer-mode],
10713 [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
10714 am_maintainer_other[ make rules and dependencies not useful
10715 (and sometimes confusing) to the casual installer])],
10716 [USE_MAINTAINER_MODE=$enableval],
10717 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
10718 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
10719 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
10720 MAINT=$MAINTAINER_MODE_TRUE
10721 AC_SUBST([MAINT])dnl
10725 # Check to see how 'make' treats includes. -*- Autoconf -*-
10727 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10729 # This file is free software; the Free Software Foundation
10730 # gives unlimited permission to copy and/or distribute it,
10731 # with or without modifications, as long as this notice is preserved.
10733 # AM_MAKE_INCLUDE()
10734 # -----------------
10735 # Check to see how make treats includes.
10736 AC_DEFUN([AM_MAKE_INCLUDE],
10737 [am_make=${MAKE-make}
10738 cat > confinc << 'END'
10740 @echo this is the am__doit target
10743 # If we don't find an include directive, just comment out the code.
10744 AC_MSG_CHECKING([for style of include used by $am_make])
10748 # First try GNU make style include.
10749 echo "include confinc" > confmf
10750 # Ignore all kinds of additional output from 'make'.
10751 case `$am_make -s -f confmf 2> /dev/null` in #(
10752 *the\ am__doit\ target*)
10753 am__include=include
10758 # Now try BSD make style include.
10759 if test "$am__include" = "#"; then
10760 echo '.include "confinc"' > confmf
10761 case `$am_make -s -f confmf 2> /dev/null` in #(
10762 *the\ am__doit\ target*)
10763 am__include=.include
10769 AC_SUBST([am__include])
10770 AC_SUBST([am__quote])
10771 AC_MSG_RESULT([$_am_result])
10772 rm -f confinc confmf
10775 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
10777 # Copyright (C) 1997-2014 Free Software Foundation, Inc.
10779 # This file is free software; the Free Software Foundation
10780 # gives unlimited permission to copy and/or distribute it,
10781 # with or without modifications, as long as this notice is preserved.
10783 # AM_MISSING_PROG(NAME, PROGRAM)
10784 # ------------------------------
10785 AC_DEFUN([AM_MISSING_PROG],
10786 [AC_REQUIRE([AM_MISSING_HAS_RUN])
10787 $1=${$1-"${am_missing_run}$2"}
10790 # AM_MISSING_HAS_RUN
10791 # ------------------
10792 # Define MISSING if not defined so far and test if it is modern enough.
10793 # If it is, set am_missing_run to use it, otherwise, to nothing.
10794 AC_DEFUN([AM_MISSING_HAS_RUN],
10795 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10796 AC_REQUIRE_AUX_FILE([missing])dnl
10797 if test x"${MISSING+set}" != xset; then
10798 case $am_aux_dir in
10800 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
10802 MISSING="\${SHELL} $am_aux_dir/missing" ;;
10805 # Use eval to expand $SHELL
10806 if eval "$MISSING --is-lightweight"; then
10807 am_missing_run="$MISSING "
10810 AC_MSG_WARN(['missing' script is too old or missing])
10814 # Helper functions for option handling. -*- Autoconf -*-
10816 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10818 # This file is free software; the Free Software Foundation
10819 # gives unlimited permission to copy and/or distribute it,
10820 # with or without modifications, as long as this notice is preserved.
10822 # _AM_MANGLE_OPTION(NAME)
10823 # -----------------------
10824 AC_DEFUN([_AM_MANGLE_OPTION],
10825 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
10827 # _AM_SET_OPTION(NAME)
10828 # --------------------
10829 # Set option NAME. Presently that only means defining a flag for this option.
10830 AC_DEFUN([_AM_SET_OPTION],
10831 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
10833 # _AM_SET_OPTIONS(OPTIONS)
10834 # ------------------------
10835 # OPTIONS is a space-separated list of Automake options.
10836 AC_DEFUN([_AM_SET_OPTIONS],
10837 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
10839 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
10840 # -------------------------------------------
10841 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
10842 AC_DEFUN([_AM_IF_OPTION],
10843 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
10845 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
10847 # This file is free software; the Free Software Foundation
10848 # gives unlimited permission to copy and/or distribute it,
10849 # with or without modifications, as long as this notice is preserved.
10853 # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
10854 # to automatically call this.
10855 AC_DEFUN([_AM_PROG_CC_C_O],
10856 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10857 AC_REQUIRE_AUX_FILE([compile])dnl
10858 AC_LANG_PUSH([C])dnl
10860 [whether $CC understands -c and -o together],
10861 [am_cv_prog_cc_c_o],
10862 [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
10863 # Make sure it works both with $CC and with simple cc.
10864 # Following AC_PROG_CC_C_O, we do the test twice because some
10865 # compilers refuse to overwrite an existing .o file with -o,
10866 # though they will create one.
10867 am_cv_prog_cc_c_o=yes
10868 for am_i in 1 2; do
10869 if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
10870 && test -f conftest2.$ac_objext; then
10873 am_cv_prog_cc_c_o=no
10877 rm -f core conftest*
10879 if test "$am_cv_prog_cc_c_o" != yes; then
10880 # Losing compiler, so override with the script.
10881 # FIXME: It is wrong to rewrite CC.
10882 # But if we don't then we get into trouble of one sort or another.
10883 # A longer-term fix would be to have automake use am__CC in this case,
10884 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
10885 CC="$am_aux_dir/compile $CC"
10889 # For backward compatibility.
10890 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
10892 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10894 # This file is free software; the Free Software Foundation
10895 # gives unlimited permission to copy and/or distribute it,
10896 # with or without modifications, as long as this notice is preserved.
10898 # AM_RUN_LOG(COMMAND)
10899 # -------------------
10900 # Run COMMAND, save the exit status in ac_status, and log it.
10901 # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
10902 AC_DEFUN([AM_RUN_LOG],
10903 [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
10904 ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
10906 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
10907 (exit $ac_status); }])
10909 # Check to make sure that the build environment is sane. -*- Autoconf -*-
10911 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
10913 # This file is free software; the Free Software Foundation
10914 # gives unlimited permission to copy and/or distribute it,
10915 # with or without modifications, as long as this notice is preserved.
10919 AC_DEFUN([AM_SANITY_CHECK],
10920 [AC_MSG_CHECKING([whether build environment is sane])
10921 # Reject unsafe characters in $srcdir or the absolute working directory
10922 # name. Accept space and tab only in the latter.
10926 *[[\\\"\#\$\&\'\`$am_lf]]*)
10927 AC_MSG_ERROR([unsafe absolute working directory name]);;
10930 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
10931 AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
10934 # Do 'set' in a subshell so we don't clobber the current shell's
10935 # arguments. Must try -L first in case configure is actually a
10936 # symlink; some systems play weird games with the mod time of symlinks
10937 # (eg FreeBSD returns the mod time of the symlink's containing
10941 for am_try in 1 2; do
10942 echo "timestamp, slept: $am_has_slept" > conftest.file
10943 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
10944 if test "$[*]" = "X"; then
10946 set X `ls -t "$srcdir/configure" conftest.file`
10948 if test "$[*]" != "X $srcdir/configure conftest.file" \
10949 && test "$[*]" != "X conftest.file $srcdir/configure"; then
10951 # If neither matched, then we have a broken ls. This can happen
10952 # if, for instance, CONFIG_SHELL is bash and it inherits a
10953 # broken ls alias from the environment. This has actually
10954 # happened. Such a system could not be considered "sane".
10955 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
10956 alias in your environment])
10958 if test "$[2]" = conftest.file || test $am_try -eq 2; then
10965 test "$[2]" = conftest.file
10971 AC_MSG_ERROR([newly created file is older than distributed files!
10972 Check your system clock])
10974 AC_MSG_RESULT([yes])
10975 # If we didn't sleep, we still need to ensure time stamps of config.status and
10976 # generated files are strictly newer.
10978 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
10982 AC_CONFIG_COMMANDS_PRE(
10983 [AC_MSG_CHECKING([that generated files are newer than configure])
10984 if test -n "$am_sleep_pid"; then
10985 # Hide warnings about reused PIDs.
10986 wait $am_sleep_pid 2>/dev/null
10988 AC_MSG_RESULT([done])])
10989 rm -f conftest.file
10992 # Copyright (C) 2009-2014 Free Software Foundation, Inc.
10994 # This file is free software; the Free Software Foundation
10995 # gives unlimited permission to copy and/or distribute it,
10996 # with or without modifications, as long as this notice is preserved.
10998 # AM_SILENT_RULES([DEFAULT])
10999 # --------------------------
11000 # Enable less verbose build rules; with the default set to DEFAULT
11001 # ("yes" being less verbose, "no" or empty being verbose).
11002 AC_DEFUN([AM_SILENT_RULES],
11003 [AC_ARG_ENABLE([silent-rules], [dnl
11005 [--enable-silent-rules],
11006 [less verbose build output (undo: "make V=1")])
11008 [--disable-silent-rules],
11009 [verbose build output (undo: "make V=0")])dnl
11011 case $enable_silent_rules in @%:@ (((
11012 yes) AM_DEFAULT_VERBOSITY=0;;
11013 no) AM_DEFAULT_VERBOSITY=1;;
11014 *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
11017 dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
11018 dnl do not support nested variable expansions.
11019 dnl See automake bug#9928 and bug#10237.
11020 am_make=${MAKE-make}
11021 AC_CACHE_CHECK([whether $am_make supports nested variables],
11022 [am_cv_make_support_nested_variables],
11023 [if AS_ECHO([['TRUE=$(BAR$(V))
11029 .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
11030 am_cv_make_support_nested_variables=yes
11032 am_cv_make_support_nested_variables=no
11034 if test $am_cv_make_support_nested_variables = yes; then
11035 dnl Using '$V' instead of '$(V)' breaks IRIX make.
11037 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
11039 AM_V=$AM_DEFAULT_VERBOSITY
11040 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
11042 AC_SUBST([AM_V])dnl
11043 AM_SUBST_NOTMAKE([AM_V])dnl
11044 AC_SUBST([AM_DEFAULT_V])dnl
11045 AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
11046 AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
11048 AC_SUBST([AM_BACKSLASH])dnl
11049 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
11052 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
11054 # This file is free software; the Free Software Foundation
11055 # gives unlimited permission to copy and/or distribute it,
11056 # with or without modifications, as long as this notice is preserved.
11058 # AM_PROG_INSTALL_STRIP
11059 # ---------------------
11060 # One issue with vendor 'install' (even GNU) is that you can't
11061 # specify the program used to strip binaries. This is especially
11062 # annoying in cross-compiling environments, where the build's strip
11063 # is unlikely to handle the host's binaries.
11064 # Fortunately install-sh will honor a STRIPPROG variable, so we
11065 # always use install-sh in "make install-strip", and initialize
11066 # STRIPPROG with the value of the STRIP variable (set by the user).
11067 AC_DEFUN([AM_PROG_INSTALL_STRIP],
11068 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
11069 # Installed binaries are usually stripped using 'strip' when the user
11070 # run "make install-strip". However 'strip' might not be the right
11071 # tool to use in cross-compilation environments, therefore Automake
11072 # will honor the 'STRIP' environment variable to overrule this program.
11073 dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
11074 if test "$cross_compiling" != no; then
11075 AC_CHECK_TOOL([STRIP], [strip], :)
11077 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
11078 AC_SUBST([INSTALL_STRIP_PROGRAM])])
11080 # Copyright (C) 2006-2014 Free Software Foundation, Inc.
11082 # This file is free software; the Free Software Foundation
11083 # gives unlimited permission to copy and/or distribute it,
11084 # with or without modifications, as long as this notice is preserved.
11086 # _AM_SUBST_NOTMAKE(VARIABLE)
11087 # ---------------------------
11088 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
11089 # This macro is traced by Automake.
11090 AC_DEFUN([_AM_SUBST_NOTMAKE])
11092 # AM_SUBST_NOTMAKE(VARIABLE)
11093 # --------------------------
11094 # Public sister of _AM_SUBST_NOTMAKE.
11095 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
11097 # Check how to create a tarball. -*- Autoconf -*-
11099 # Copyright (C) 2004-2014 Free Software Foundation, Inc.
11101 # This file is free software; the Free Software Foundation
11102 # gives unlimited permission to copy and/or distribute it,
11103 # with or without modifications, as long as this notice is preserved.
11105 # _AM_PROG_TAR(FORMAT)
11106 # --------------------
11107 # Check how to create a tarball in format FORMAT.
11108 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
11110 # Substitute a variable $(am__tar) that is a command
11111 # writing to stdout a FORMAT-tarball containing the directory
11113 # tardir=directory && $(am__tar) > result.tar
11115 # Substitute a variable $(am__untar) that extract such
11116 # a tarball read from stdin.
11117 # $(am__untar) < result.tar
11119 AC_DEFUN([_AM_PROG_TAR],
11120 [# Always define AMTAR for backward compatibility. Yes, it's still used
11121 # in the wild :-( We should find a proper way to deprecate it ...
11122 AC_SUBST([AMTAR], ['$${TAR-tar}'])
11124 # We'll loop over all known methods to create a tar archive until one works.
11125 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
11128 [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
11132 [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
11133 # There is notably a 21 bits limit for the UID and the GID. In fact,
11134 # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
11136 am_max_uid=2097151 # 2^21 - 1
11137 am_max_gid=$am_max_uid
11138 # The $UID and $GID variables are not portable, so we need to resort
11139 # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
11140 # below are definitely unexpected, so allow the users to see them
11141 # (that is, avoid stderr redirection).
11142 am_uid=`id -u || echo unknown`
11143 am_gid=`id -g || echo unknown`
11144 AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
11145 if test $am_uid -le $am_max_uid; then
11146 AC_MSG_RESULT([yes])
11148 AC_MSG_RESULT([no])
11151 AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
11152 if test $am_gid -le $am_max_gid; then
11153 AC_MSG_RESULT([yes])
11155 AC_MSG_RESULT([no])
11162 [m4_fatal([Unknown tar format])])
11164 AC_MSG_CHECKING([how to create a $1 tar archive])
11166 # Go ahead even if we have the value already cached. We do so because we
11167 # need to set the values for the 'am__tar' and 'am__untar' variables.
11168 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
11170 for _am_tool in $_am_tools; do
11173 for _am_tar in tar gnutar gtar; do
11174 AM_RUN_LOG([$_am_tar --version]) && break
11176 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
11177 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
11178 am__untar="$_am_tar -xf -"
11181 # Must skip GNU tar: if it does not support --format= it doesn't create
11182 # ustar tarball either.
11183 (tar --version) >/dev/null 2>&1 && continue
11184 am__tar='tar chf - "$$tardir"'
11185 am__tar_='tar chf - "$tardir"'
11186 am__untar='tar xf -'
11189 am__tar='pax -L -x $1 -w "$$tardir"'
11190 am__tar_='pax -L -x $1 -w "$tardir"'
11194 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
11195 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
11196 am__untar='cpio -i -H $1 -d'
11205 # If the value was cached, stop now. We just wanted to have am__tar
11206 # and am__untar set.
11207 test -n "${am_cv_prog_tar_$1}" && break
11209 # tar/untar a dummy directory, and stop if the command works.
11210 rm -rf conftest.dir
11212 echo GrepMe > conftest.dir/file
11213 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
11214 rm -rf conftest.dir
11215 if test -s conftest.tar; then
11216 AM_RUN_LOG([$am__untar <conftest.tar])
11217 AM_RUN_LOG([cat conftest.dir/file])
11218 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
11221 rm -rf conftest.dir
11223 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
11224 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
11226 AC_SUBST([am__tar])
11227 AC_SUBST([am__untar])