1 # generated automatically by aclocal 1.11.6 -*- Autoconf -*-
3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
4 # 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation,
6 # This file is free software; the Free Software Foundation
7 # gives unlimited permission to copy and/or distribute it,
8 # with or without modifications, as long as this notice is preserved.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
12 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
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
340 AC_REQUIRE([AC_HEADER_STDC])dnl
345 if test "$gt_cv_have_gettext" = "yes"; then
346 if test "x$ALL_LINGUAS" = "x"; then
349 AC_MSG_CHECKING(for catalogs to be installed)
351 for presentlang in $ALL_LINGUAS; do
353 if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then
354 desiredlanguages="$LINGUAS"
356 desiredlanguages="$ALL_LINGUAS"
358 for desiredlang in $desiredlanguages; do
359 # Use the presentlang catalog if desiredlang is
360 # a. equal to presentlang, or
361 # b. a variant of presentlang (because in this case,
362 # presentlang can be used as a fallback for messages
363 # which are not translated in the desiredlang catalog).
364 case "$desiredlang" in
365 "$presentlang"*) useit=yes;;
368 if test $useit = yes; then
369 NEW_LINGUAS="$NEW_LINGUAS $presentlang"
373 AC_MSG_RESULT($LINGUAS)
376 dnl Construct list of names of catalog files to be constructed.
377 if test -n "$LINGUAS"; then
378 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
382 dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
383 dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
384 dnl Try to locate is.
386 if test -n "$ac_aux_dir"; then
387 MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
389 if test -z "$MKINSTALLDIRS"; then
390 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
392 AC_SUBST(MKINSTALLDIRS)
394 dnl Generate list of files to be processed by xgettext which will
395 dnl be included in po/Makefile.
396 test -d po || mkdir po
397 if test "x$srcdir" != "x."; then
398 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
399 posrcprefix="$srcdir/"
401 posrcprefix="../$srcdir/"
407 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
408 < $srcdir/po/POTFILES.in > po/POTFILES
411 # AM_GLIB_DEFINE_LOCALEDIR(VARIABLE)
412 # -------------------------------
413 # Define VARIABLE to the location where catalog files will
414 # be installed by po/Makefile.
415 glib_DEFUN([GLIB_DEFINE_LOCALEDIR],
416 [glib_REQUIRE([GLIB_GNU_GETTEXT])dnl
417 glib_save_prefix="$prefix"
418 glib_save_exec_prefix="$exec_prefix"
419 glib_save_datarootdir="$datarootdir"
420 test "x$prefix" = xNONE && prefix=$ac_default_prefix
421 test "x$exec_prefix" = xNONE && exec_prefix=$prefix
422 datarootdir=`eval echo "${datarootdir}"`
423 if test "x$CATOBJEXT" = "x.mo" ; then
424 localedir=`eval echo "${libdir}/locale"`
426 localedir=`eval echo "${datadir}/locale"`
428 prefix="$glib_save_prefix"
429 exec_prefix="$glib_save_exec_prefix"
430 datarootdir="$glib_save_datarootdir"
431 AC_DEFINE_UNQUOTED($1, "$localedir",
432 [Define the location where the catalogs will be installed])
436 dnl Now the definitions that aclocal will find
438 ifdef(glib_configure_ac,[],[
439 AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)])
440 AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)])
443 # GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL])
445 # Create a temporary file with TEST-FILE as its contents and pass the
446 # file name to PROGRAM. Perform ACTION-IF-PASS if PROGRAM exits with
447 # 0 and perform ACTION-IF-FAIL for any other exit status.
448 AC_DEFUN([GLIB_RUN_PROG],
449 [cat >conftest.foo <<_ACEOF
452 if AC_RUN_LOG([$1 conftest.foo]); then
453 m4_ifval([$3], [$3], [:])
454 m4_ifvaln([$4], [else $4])dnl
455 echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD
456 sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
460 dnl GNOME_COMPILE_WARNINGS
461 dnl Turn on many useful compiler warnings
462 dnl For now, only works on GCC
463 AC_DEFUN([GNOME_COMPILE_WARNINGS],[
464 dnl ******************************
465 dnl More compiler warnings
466 dnl ******************************
468 AC_ARG_ENABLE(compile-warnings,
469 AC_HELP_STRING([--enable-compile-warnings=@<:@no/minimum/yes/maximum/error@:>@],
470 [Turn on compiler warnings]),,
471 [enable_compile_warnings="m4_default([$1],[yes])"])
474 if test "x$GCC" != xyes; then
475 enable_compile_warnings=no
479 realsave_CFLAGS="$CFLAGS"
481 case "$enable_compile_warnings" in
486 warning_flags="-Wall"
489 warning_flags="-Wall -Wmissing-prototypes"
492 warning_flags="-Wall -Wmissing-prototypes -Wnested-externs -Wpointer-arith"
493 CFLAGS="$warning_flags $CFLAGS"
494 for option in -Wno-sign-compare; do
495 SAVE_CFLAGS="$CFLAGS"
496 CFLAGS="$CFLAGS $option"
497 AC_MSG_CHECKING([whether gcc understands $option])
498 AC_TRY_COMPILE([], [],
501 CFLAGS="$SAVE_CFLAGS"
502 AC_MSG_RESULT($has_option)
503 if test $has_option = yes; then
504 warning_flags="$warning_flags $option"
510 if test "$enable_compile_warnings" = "error" ; then
511 warning_flags="$warning_flags -Werror"
515 AC_MSG_ERROR(Unknown argument '$enable_compile_warnings' to --enable-compile-warnings)
518 CFLAGS="$realsave_CFLAGS"
519 AC_MSG_CHECKING(what warning flags to pass to the C compiler)
520 AC_MSG_RESULT($warning_flags)
523 AC_HELP_STRING([--enable-iso-c],
524 [Try to warn if code is not ISO C ]),,
527 AC_MSG_CHECKING(what language compliance flags to pass to the C compiler)
529 if test "x$enable_iso_c" != "xno"; then
530 if test "x$GCC" = "xyes"; then
532 *[\ \ ]-ansi[\ \ ]*) ;;
533 *) complCFLAGS="$complCFLAGS -ansi" ;;
536 *[\ \ ]-pedantic[\ \ ]*) ;;
537 *) complCFLAGS="$complCFLAGS -pedantic" ;;
541 AC_MSG_RESULT($complCFLAGS)
543 WARN_CFLAGS="$warning_flags $complCFLAGS"
544 AC_SUBST(WARN_CFLAGS)
547 dnl For C++, do basically the same thing.
549 AC_DEFUN([GNOME_CXX_WARNINGS],[
550 AC_ARG_ENABLE(cxx-warnings,
551 AC_HELP_STRING([--enable-cxx-warnings=@<:@no/minimum/yes@:>@]
552 [Turn on compiler warnings.]),,
553 [enable_cxx_warnings="m4_default([$1],[minimum])"])
555 AC_MSG_CHECKING(what warning flags to pass to the C++ compiler)
557 if test "x$GXX" != xyes; then
558 enable_cxx_warnings=no
560 if test "x$enable_cxx_warnings" != "xno"; then
561 if test "x$GXX" = "xyes"; then
562 case " $CXXFLAGS " in
563 *[\ \ ]-Wall[\ \ ]*) ;;
564 *) warnCXXFLAGS="-Wall -Wno-unused" ;;
567 ## -W is not all that useful. And it cannot be controlled
568 ## with individual -Wno-xxx flags, unlike -Wall
569 if test "x$enable_cxx_warnings" = "xyes"; then
570 warnCXXFLAGS="$warnCXXFLAGS -Wshadow -Woverloaded-virtual"
574 AC_MSG_RESULT($warnCXXFLAGS)
576 AC_ARG_ENABLE(iso-cxx,
577 AC_HELP_STRING([--enable-iso-cxx],
578 [Try to warn if code is not ISO C++ ]),,
581 AC_MSG_CHECKING(what language compliance flags to pass to the C++ compiler)
583 if test "x$enable_iso_cxx" != "xno"; then
584 if test "x$GXX" = "xyes"; then
585 case " $CXXFLAGS " in
586 *[\ \ ]-ansi[\ \ ]*) ;;
587 *) complCXXFLAGS="$complCXXFLAGS -ansi" ;;
590 case " $CXXFLAGS " in
591 *[\ \ ]-pedantic[\ \ ]*) ;;
592 *) complCXXFLAGS="$complCXXFLAGS -pedantic" ;;
596 AC_MSG_RESULT($complCXXFLAGS)
598 WARN_CXXFLAGS="$CXXFLAGS $warnCXXFLAGS $complCXXFLAGS"
599 AC_SUBST(WARN_CXXFLAGS)
603 dnl Defines GSETTINGS_SCHEMAS_INSTALL which controls whether
604 dnl the schema should be compiled
607 AC_DEFUN([GLIB_GSETTINGS],
609 m4_pattern_allow([AM_V_GEN])
610 AC_ARG_ENABLE(schemas-compile,
611 AS_HELP_STRING([--disable-schemas-compile],
612 [Disable regeneration of gschemas.compiled on install]),
613 [case ${enableval} in
614 yes) GSETTINGS_DISABLE_SCHEMAS_COMPILE="" ;;
615 no) GSETTINGS_DISABLE_SCHEMAS_COMPILE="1" ;;
616 *) AC_MSG_ERROR([bad value ${enableval} for --enable-schemas-compile]) ;;
618 AC_SUBST([GSETTINGS_DISABLE_SCHEMAS_COMPILE])
619 PKG_PROG_PKG_CONFIG([0.16])
620 AC_SUBST(gsettingsschemadir, [${datadir}/glib-2.0/schemas])
621 if test x$cross_compiling != xyes; then
622 GLIB_COMPILE_SCHEMAS=`$PKG_CONFIG --variable glib_compile_schemas gio-2.0`
624 AC_PATH_PROG(GLIB_COMPILE_SCHEMAS, glib-compile-schemas)
626 AC_SUBST(GLIB_COMPILE_SCHEMAS)
627 if test "x$GLIB_COMPILE_SCHEMAS" = "x"; then
628 ifelse([$2],,[AC_MSG_ERROR([glib-compile-schemas not found.])],[$2])
630 ifelse([$1],,[:],[$1])
634 .PHONY : uninstall-gsettings-schemas install-gsettings-schemas clean-gsettings-schemas
636 mostlyclean-am: clean-gsettings-schemas
638 gsettings__enum_file = $(addsuffix .enums.xml,$(gsettings_ENUM_NAMESPACE))
640 %.gschema.valid: %.gschema.xml $(gsettings__enum_file)
641 $(AM_V_GEN) if test -f "$<"; then d=; else d="$(srcdir)/"; fi; $(GLIB_COMPILE_SCHEMAS) --strict --dry-run $(addprefix --schema-file=,$(gsettings__enum_file)) --schema-file=$${d}$< && touch [$]@
643 all-am: $(gsettings_SCHEMAS:.xml=.valid)
644 uninstall-am: uninstall-gsettings-schemas
645 install-data-am: install-gsettings-schemas
647 .SECONDARY: $(gsettings_SCHEMAS)
649 install-gsettings-schemas: $(gsettings_SCHEMAS) $(gsettings__enum_file)
651 if test -n "$^"; then \
652 test -z "$(gsettingsschemadir)" || $(MKDIR_P) "$(DESTDIR)$(gsettingsschemadir)"; \
653 $(INSTALL_DATA) $^ "$(DESTDIR)$(gsettingsschemadir)"; \
654 test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir); \
657 uninstall-gsettings-schemas:
659 @list='\''$(gsettings_SCHEMAS) $(gsettings__enum_file)'\''; test -n "$(gsettingsschemadir)" || list=; \
660 files=`for p in $$list; do echo $$p; done | sed -e '\''s|^.*/||'\''`; \
661 test -n "$$files" || exit 0; \
662 echo " ( cd '\''$(DESTDIR)$(gsettingsschemadir)'\'' && rm -f" $$files ")"; \
663 cd "$(DESTDIR)$(gsettingsschemadir)" && rm -f $$files
664 test -n "$(GSETTINGS_DISABLE_SCHEMAS_COMPILE)$(DESTDIR)" || $(GLIB_COMPILE_SCHEMAS) $(gsettingsschemadir)
666 clean-gsettings-schemas:
667 rm -f $(gsettings_SCHEMAS:.xml=.valid) $(gsettings__enum_file)
669 ifdef gsettings_ENUM_NAMESPACE
670 $(gsettings__enum_file): $(gsettings_ENUM_FILES)
671 $(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 [$]@
674 _GSETTINGS_SUBST(GSETTINGS_RULES)
677 dnl _GSETTINGS_SUBST(VARIABLE)
678 dnl Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
679 AC_DEFUN([_GSETTINGS_SUBST],
682 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
686 dnl -*- mode: autoconf -*-
691 dnl GTK_DOC_CHECK([minimum-gtk-doc-version])
692 AC_DEFUN([GTK_DOC_CHECK],
694 AC_REQUIRE([PKG_PROG_PKG_CONFIG])
695 AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
696 AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
698 dnl check for tools we added during development
699 AC_PATH_PROG([GTKDOC_CHECK],[gtkdoc-check])
700 AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true])
701 AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf])
703 dnl for overriding the documentation installation directory
704 AC_ARG_WITH([html-dir],
705 AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
706 [with_html_dir='${datadir}/gtk-doc/html'])
707 HTML_DIR="$with_html_dir"
710 dnl enable/disable documentation building
711 AC_ARG_ENABLE([gtk-doc],
712 AS_HELP_STRING([--enable-gtk-doc],
713 [use gtk-doc to build documentation [[default=no]]]),,
716 if test x$enable_gtk_doc = xyes; then
718 [PKG_CHECK_EXISTS([gtk-doc],,
719 AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))],
720 [PKG_CHECK_EXISTS([gtk-doc >= $1],,
721 AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build $PACKAGE_NAME]))])
722 dnl don't check for glib if we build glib
723 if test "x$PACKAGE_NAME" != "xglib"; then
724 dnl don't fail if someone does not have glib
725 PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0,,)
729 AC_MSG_CHECKING([whether to build gtk-doc documentation])
730 AC_MSG_RESULT($enable_gtk_doc)
732 dnl enable/disable output formats
733 AC_ARG_ENABLE([gtk-doc-html],
734 AS_HELP_STRING([--enable-gtk-doc-html],
735 [build documentation in html format [[default=yes]]]),,
736 [enable_gtk_doc_html=yes])
737 AC_ARG_ENABLE([gtk-doc-pdf],
738 AS_HELP_STRING([--enable-gtk-doc-pdf],
739 [build documentation in pdf format [[default=no]]]),,
740 [enable_gtk_doc_pdf=no])
742 if test -z "$GTKDOC_MKPDF"; then
743 enable_gtk_doc_pdf=no
747 AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
748 AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
749 AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])
750 AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"])
751 AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"])
755 dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
756 # serial 42 IT_PROG_INTLTOOL
757 AC_DEFUN([IT_PROG_INTLTOOL], [
759 AC_REQUIRE([AM_NLS])dnl
761 case "$am__api_version" in
763 AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
769 INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
770 INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
771 INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
772 if test -n "$1"; then
773 AC_MSG_CHECKING([for intltool >= $1])
774 AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
775 test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
776 AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.])
779 AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
780 AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
781 AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
782 if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
783 AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
786 if test -z "$AM_DEFAULT_VERBOSITY"; then
787 AM_DEFAULT_VERBOSITY=1
789 AC_SUBST([AM_DEFAULT_VERBOSITY])
791 INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
792 INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
793 INTLTOOL__v_MERGE_0='@echo " ITMRG " [$]@;'
794 AC_SUBST(INTLTOOL_V_MERGE)
795 AC_SUBST(INTLTOOL__v_MERGE_)
796 AC_SUBST(INTLTOOL__v_MERGE_0)
798 INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
799 intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
800 intltool__v_merge_options_0='-q'
801 AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
802 AC_SUBST(intltool__v_merge_options_)
803 AC_SUBST(intltool__v_merge_options_0)
805 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 $< [$]@'
806 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 $< [$]@'
807 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 $< [$]@'
808 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 $< [$]@'
809 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 $< [$]@'
810 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 $< [$]@'
811 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 $< [$]@'
812 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 $< [$]@'
813 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 $< [$]@'
814 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 $< [$]@'
815 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 $< [$]@'
816 if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
817 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 $< [$]@'
819 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'
821 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 $< [$]@'
822 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 $< [$]@'
823 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 $< [$]@'
824 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 $< [$]@'
825 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 $< [$]@'
826 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 $< [$]@'
827 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 $< [$]@'
829 _IT_SUBST(INTLTOOL_DESKTOP_RULE)
830 _IT_SUBST(INTLTOOL_DIRECTORY_RULE)
831 _IT_SUBST(INTLTOOL_KEYS_RULE)
832 _IT_SUBST(INTLTOOL_PROP_RULE)
833 _IT_SUBST(INTLTOOL_OAF_RULE)
834 _IT_SUBST(INTLTOOL_PONG_RULE)
835 _IT_SUBST(INTLTOOL_SERVER_RULE)
836 _IT_SUBST(INTLTOOL_SHEET_RULE)
837 _IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
838 _IT_SUBST(INTLTOOL_UI_RULE)
839 _IT_SUBST(INTLTOOL_XAM_RULE)
840 _IT_SUBST(INTLTOOL_KBD_RULE)
841 _IT_SUBST(INTLTOOL_XML_RULE)
842 _IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
843 _IT_SUBST(INTLTOOL_CAVES_RULE)
844 _IT_SUBST(INTLTOOL_SCHEMAS_RULE)
845 _IT_SUBST(INTLTOOL_THEME_RULE)
846 _IT_SUBST(INTLTOOL_SERVICE_RULE)
847 _IT_SUBST(INTLTOOL_POLICY_RULE)
849 # Check the gettext tools to make sure they are GNU
850 AC_PATH_PROG(XGETTEXT, xgettext)
851 AC_PATH_PROG(MSGMERGE, msgmerge)
852 AC_PATH_PROG(MSGFMT, msgfmt)
853 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
854 if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
855 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
857 xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
858 mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
859 mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
860 if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
861 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
864 AC_PATH_PROG(INTLTOOL_PERL, perl)
865 if test -z "$INTLTOOL_PERL"; then
866 AC_MSG_ERROR([perl not found])
868 AC_MSG_CHECKING([for perl >= 5.8.1])
869 $INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
870 if test $? -ne 0; then
871 AC_MSG_ERROR([perl 5.8.1 is required for intltool])
873 IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
874 AC_MSG_RESULT([$IT_PERL_VERSION])
876 if test "x$2" != "xno-xml"; then
877 AC_MSG_CHECKING([for XML::Parser])
878 if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
881 AC_MSG_ERROR([XML::Parser perl module is required for intltool])
885 # Substitute ALL_LINGUAS so we can use it in po/Makefile
886 AC_SUBST(ALL_LINGUAS)
888 # Set DATADIRNAME correctly if it is not set yet
889 # (copied from glib-gettext.m4)
890 if test -z "$DATADIRNAME"; then
892 [AC_LANG_PROGRAM([[]],
893 [[extern int _nl_msg_cat_cntr;
894 return _nl_msg_cat_cntr]])],
898 dnl On Solaris, if bind_textdomain_codeset is in libc,
899 dnl GNU format message catalog is always supported,
900 dnl since both are added to the libc all together.
901 dnl Hence, we'd like to go with DATADIRNAME=share
903 AC_CHECK_FUNC(bind_textdomain_codeset,
904 [DATADIRNAME=share], [DATADIRNAME=lib])
911 AC_SUBST(DATADIRNAME)
918 # IT_PO_SUBDIR(DIRNAME)
919 # ---------------------
920 # All po subdirs have to be declared with this macro; the subdir "po" is
921 # declared by IT_PROG_INTLTOOL.
923 AC_DEFUN([IT_PO_SUBDIR],
924 [AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
926 dnl The following CONFIG_COMMANDS should be executed at the very end
927 dnl of config.status.
928 AC_CONFIG_COMMANDS_PRE([
929 AC_CONFIG_COMMANDS([$1/stamp-it], [
930 if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
931 AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
933 rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
938 '"s|^| $ac_top_srcdir/|" \
939 "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
941 [sed '/^POTFILES =/,/[^\\]$/ {
945 ' "$1/Makefile.in" >"$1/Makefile"]
946 rm -f "$1/Makefile.tmp"
947 mv "$1/stamp-it.tmp" "$1/stamp-it"
952 # _IT_SUBST(VARIABLE)
953 # -------------------
954 # Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
956 AC_DEFUN([_IT_SUBST],
959 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
964 AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
965 # A hint is needed for aclocal from Automake <= 1.9.4:
966 # AC_DEFUN([AC_PROG_INTLTOOL], ...)
969 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
971 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
972 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
974 # Written by Gordon Matzigkeit, 1996
976 # This file is free software; the Free Software Foundation gives
977 # unlimited permission to copy and/or distribute it, with or without
978 # modifications, as long as this notice is preserved.
980 m4_define([_LT_COPYING], [dnl
981 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
982 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
984 # Written by Gordon Matzigkeit, 1996
986 # This file is part of GNU Libtool.
988 # GNU Libtool is free software; you can redistribute it and/or
989 # modify it under the terms of the GNU General Public License as
990 # published by the Free Software Foundation; either version 2 of
991 # the License, or (at your option) any later version.
993 # As a special exception to the GNU General Public License,
994 # if you distribute this file as part of a program or library that
995 # is built using GNU Libtool, you may include this file under the
996 # same distribution terms that you use for the rest of that program.
998 # GNU Libtool is distributed in the hope that it will be useful,
999 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1000 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1001 # GNU General Public License for more details.
1003 # You should have received a copy of the GNU General Public License
1004 # along with GNU Libtool; see the file COPYING. If not, a copy
1005 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
1006 # obtained by writing to the Free Software Foundation, Inc.,
1007 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1013 # LT_PREREQ(VERSION)
1014 # ------------------
1015 # Complain and exit if this libtool version is less that VERSION.
1016 m4_defun([LT_PREREQ],
1017 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
1019 [m4_fatal([Libtool version $1 or higher is required],
1024 # _LT_CHECK_BUILDDIR
1025 # ------------------
1026 # Complain if the absolute build directory name contains unusual characters
1027 m4_defun([_LT_CHECK_BUILDDIR],
1030 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
1035 # LT_INIT([OPTIONS])
1036 # ------------------
1038 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
1039 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
1040 AC_BEFORE([$0], [LT_LANG])dnl
1041 AC_BEFORE([$0], [LT_OUTPUT])dnl
1042 AC_BEFORE([$0], [LTDL_INIT])dnl
1043 m4_require([_LT_CHECK_BUILDDIR])dnl
1045 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
1046 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
1047 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
1048 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
1049 dnl unless we require an AC_DEFUNed macro:
1050 AC_REQUIRE([LTOPTIONS_VERSION])dnl
1051 AC_REQUIRE([LTSUGAR_VERSION])dnl
1052 AC_REQUIRE([LTVERSION_VERSION])dnl
1053 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
1054 m4_require([_LT_PROG_LTMAIN])dnl
1056 _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
1059 _LT_SET_OPTIONS([$0], [$1])
1061 # This can be used to rebuild libtool when needed
1062 LIBTOOL_DEPS="$ltmain"
1064 # Always use our own libtool.
1065 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1066 AC_SUBST(LIBTOOL)dnl
1071 m4_define([LT_INIT])
1075 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
1076 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
1077 dnl aclocal-1.4 backwards compatibility:
1078 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
1079 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
1082 # _LT_CC_BASENAME(CC)
1083 # -------------------
1084 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
1085 m4_defun([_LT_CC_BASENAME],
1086 [for cc_temp in $1""; do
1088 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1089 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1094 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
1098 # _LT_FILEUTILS_DEFAULTS
1099 # ----------------------
1100 # It is okay to use these file commands and assume they have been set
1101 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
1102 m4_defun([_LT_FILEUTILS_DEFAULTS],
1106 ])# _LT_FILEUTILS_DEFAULTS
1111 m4_defun([_LT_SETUP],
1112 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1113 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1114 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
1115 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
1117 _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
1119 _LT_DECL([], [host_alias], [0], [The host system])dnl
1120 _LT_DECL([], [host], [0])dnl
1121 _LT_DECL([], [host_os], [0])dnl
1123 _LT_DECL([], [build_alias], [0], [The build system])dnl
1124 _LT_DECL([], [build], [0])dnl
1125 _LT_DECL([], [build_os], [0])dnl
1127 AC_REQUIRE([AC_PROG_CC])dnl
1128 AC_REQUIRE([LT_PATH_LD])dnl
1129 AC_REQUIRE([LT_PATH_NM])dnl
1131 AC_REQUIRE([AC_PROG_LN_S])dnl
1132 test -z "$LN_S" && LN_S="ln -s"
1133 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
1135 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
1136 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
1137 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
1139 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1140 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
1141 m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
1142 m4_require([_LT_CMD_RELOAD])dnl
1143 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
1144 m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
1145 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
1146 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
1147 m4_require([_LT_WITH_SYSROOT])dnl
1149 _LT_CONFIG_LIBTOOL_INIT([
1150 # See if we are running on zsh, and set the options which allow our
1151 # commands through without removal of \ escapes INIT.
1152 if test -n "\${ZSH_VERSION+set}" ; then
1153 setopt NO_GLOB_SUBST
1156 if test -n "${ZSH_VERSION+set}" ; then
1157 setopt NO_GLOB_SUBST
1162 m4_require([_LT_TAG_COMPILER])dnl
1166 # AIX sometimes has problems with the GCC collect2 program. For some
1167 # reason, if we set the COLLECT_NAMES environment variable, the problems
1168 # vanish in a puff of smoke.
1169 if test "X${COLLECT_NAMES+set}" != Xset; then
1171 export COLLECT_NAMES
1178 can_build_shared=yes
1180 # All known linkers require a `.a' archive for static linking (except MSVC,
1181 # which needs '.lib').
1184 with_gnu_ld="$lt_cv_prog_gnu_ld"
1187 old_CFLAGS="$CFLAGS"
1189 # Set sane defaults for various variables
1190 test -z "$CC" && CC=cc
1191 test -z "$LTCC" && LTCC=$CC
1192 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1193 test -z "$LD" && LD=ld
1194 test -z "$ac_objext" && ac_objext=o
1196 _LT_CC_BASENAME([$compiler])
1198 # Only perform the check for file, if the check method requires it
1199 test -z "$MAGIC_CMD" && MAGIC_CMD=file
1200 case $deplibs_check_method in
1202 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1208 # Use C for the default configuration in the libtool script
1209 LT_SUPPORTED_TAG([CC])
1211 _LT_LANG_DEFAULT_CONFIG
1216 # _LT_PREPARE_SED_QUOTE_VARS
1217 # --------------------------
1218 # Define a few sed substitution that help us do robust quoting.
1219 m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
1220 [# Backslashify metacharacters that are still active within
1221 # double-quoted strings.
1222 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
1224 # Same as above, but do not quote variable references.
1225 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
1227 # Sed substitution to delay expansion of an escaped shell variable in a
1228 # double_quote_subst'ed string.
1229 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1231 # Sed substitution to delay expansion of an escaped single quote.
1232 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
1234 # Sed substitution to avoid accidental globbing in evaled expressions
1235 no_glob_subst='s/\*/\\\*/g'
1240 # Note that this code is called both from `configure', and `config.status'
1241 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
1242 # `config.status' has no value for ac_aux_dir unless we are using Automake,
1243 # so we pass a copy along to make sure it has a sensible value anyway.
1244 m4_defun([_LT_PROG_LTMAIN],
1245 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
1246 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
1247 ltmain="$ac_aux_dir/ltmain.sh"
1252 # So that we can recreate a full libtool script including additional
1253 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
1254 # in macros and then make a single call at the end using the `libtool'
1258 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
1259 # ----------------------------------------
1260 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1261 m4_define([_LT_CONFIG_LIBTOOL_INIT],
1263 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
1268 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
1271 # _LT_CONFIG_LIBTOOL([COMMANDS])
1272 # ------------------------------
1273 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1274 m4_define([_LT_CONFIG_LIBTOOL],
1276 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
1281 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
1284 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
1285 # -----------------------------------------------------
1286 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
1287 [_LT_CONFIG_LIBTOOL([$1])
1288 _LT_CONFIG_LIBTOOL_INIT([$2])
1292 # _LT_FORMAT_COMMENT([COMMENT])
1293 # -----------------------------
1294 # Add leading comment marks to the start of each line, and a trailing
1295 # full-stop to the whole comment if one is not present already.
1296 m4_define([_LT_FORMAT_COMMENT],
1298 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
1299 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
1306 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
1307 # -------------------------------------------------------------------
1308 # CONFIGNAME is the name given to the value in the libtool script.
1309 # VARNAME is the (base) name used in the configure script.
1310 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
1311 # VARNAME. Any other value will be used directly.
1312 m4_define([_LT_DECL],
1313 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
1314 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
1315 [m4_ifval([$1], [$1], [$2])])
1316 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
1318 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
1319 lt_dict_add_subkey([lt_decl_dict], [$2],
1320 [tagged?], [m4_ifval([$5], [yes], [no])])])
1324 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
1325 # --------------------------------------------------------
1326 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
1329 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
1330 # ------------------------------------------------
1331 m4_define([lt_decl_tag_varnames],
1332 [_lt_decl_filter([tagged?], [yes], $@)])
1335 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
1336 # ---------------------------------------------------------
1337 m4_define([_lt_decl_filter],
1339 [0], [m4_fatal([$0: too few arguments: $#])],
1340 [1], [m4_fatal([$0: too few arguments: $#: $1])],
1341 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
1342 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
1343 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
1347 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
1348 # --------------------------------------------------
1349 m4_define([lt_decl_quote_varnames],
1350 [_lt_decl_filter([value], [1], $@)])
1353 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
1354 # ---------------------------------------------------
1355 m4_define([lt_decl_dquote_varnames],
1356 [_lt_decl_filter([value], [2], $@)])
1359 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
1360 # ---------------------------------------------------
1361 m4_define([lt_decl_varnames_tagged],
1362 [m4_assert([$# <= 2])dnl
1363 _$0(m4_quote(m4_default([$1], [[, ]])),
1364 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
1365 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
1366 m4_define([_lt_decl_varnames_tagged],
1367 [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
1370 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
1371 # ------------------------------------------------
1372 m4_define([lt_decl_all_varnames],
1373 [_$0(m4_quote(m4_default([$1], [[, ]])),
1375 m4_quote(lt_decl_varnames),
1376 m4_quote(m4_shift($@))))[]dnl
1378 m4_define([_lt_decl_all_varnames],
1379 [lt_join($@, lt_decl_varnames_tagged([$1],
1380 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
1384 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
1385 # ------------------------------------
1386 # Quote a variable value, and forward it to `config.status' so that its
1387 # declaration there will have the same value as in `configure'. VARNAME
1388 # must have a single quote delimited value for this to work.
1389 m4_define([_LT_CONFIG_STATUS_DECLARE],
1390 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
1393 # _LT_CONFIG_STATUS_DECLARATIONS
1394 # ------------------------------
1395 # We delimit libtool config variables with single quotes, so when
1396 # we write them to config.status, we have to be sure to quote all
1397 # embedded single quotes properly. In configure, this macro expands
1398 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
1400 # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
1401 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
1402 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
1403 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
1408 # Output comment and list of tags supported by the script
1409 m4_defun([_LT_LIBTOOL_TAGS],
1410 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
1411 available_tags="_LT_TAGS"dnl
1415 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
1416 # -----------------------------------
1417 # Extract the dictionary values for VARNAME (optionally with TAG) and
1418 # expand to a commented shell variable setting:
1420 # # Some comment about what VAR is for.
1421 # visible_name=$lt_internal_name
1422 m4_define([_LT_LIBTOOL_DECLARE],
1423 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
1424 [description])))[]dnl
1425 m4_pushdef([_libtool_name],
1426 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
1427 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
1428 [0], [_libtool_name=[$]$1],
1429 [1], [_libtool_name=$lt_[]$1],
1430 [2], [_libtool_name=$lt_[]$1],
1431 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
1432 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
1436 # _LT_LIBTOOL_CONFIG_VARS
1437 # -----------------------
1438 # Produce commented declarations of non-tagged libtool config variables
1439 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
1440 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
1441 # section) are produced by _LT_LIBTOOL_TAG_VARS.
1442 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
1443 [m4_foreach([_lt_var],
1444 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
1445 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
1448 # _LT_LIBTOOL_TAG_VARS(TAG)
1449 # -------------------------
1450 m4_define([_LT_LIBTOOL_TAG_VARS],
1451 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
1452 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
1455 # _LT_TAGVAR(VARNAME, [TAGNAME])
1456 # ------------------------------
1457 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
1460 # _LT_CONFIG_COMMANDS
1461 # -------------------
1462 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
1463 # variables for single and double quote escaping we saved from calls
1464 # to _LT_DECL, we can put quote escaped variables declarations
1465 # into `config.status', and then the shell code to quote escape them in
1466 # for loops in `config.status'. Finally, any additional code accumulated
1467 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
1468 m4_defun([_LT_CONFIG_COMMANDS],
1469 [AC_PROVIDE_IFELSE([LT_OUTPUT],
1470 dnl If the libtool generation code has been placed in $CONFIG_LT,
1471 dnl instead of duplicating it all over again into config.status,
1472 dnl then we will have config.status run $CONFIG_LT later, so it
1473 dnl needs to know what name is stored there:
1474 [AC_CONFIG_COMMANDS([libtool],
1475 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
1476 dnl If the libtool generation code is destined for config.status,
1477 dnl expand the accumulated commands and init code now:
1478 [AC_CONFIG_COMMANDS([libtool],
1479 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
1480 ])#_LT_CONFIG_COMMANDS
1484 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
1487 # The HP-UX ksh and POSIX shell print the target directory to stdout
1489 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1491 sed_quote_subst='$sed_quote_subst'
1492 double_quote_subst='$double_quote_subst'
1493 delay_variable_subst='$delay_variable_subst'
1494 _LT_CONFIG_STATUS_DECLARATIONS
1496 LTCFLAGS='$LTCFLAGS'
1497 compiler='$compiler_DEFAULT'
1499 # A function that is used when there is no print builtin or printf.
1500 func_fallback_echo ()
1502 eval 'cat <<_LTECHO_EOF
1507 # Quote evaled strings.
1508 for var in lt_decl_all_varnames([[ \
1509 ]], lt_decl_quote_varnames); do
1510 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1511 *[[\\\\\\\`\\"\\\$]]*)
1512 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1515 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1520 # Double-quote double-evaled strings.
1521 for var in lt_decl_all_varnames([[ \
1522 ]], lt_decl_dquote_varnames); do
1523 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1524 *[[\\\\\\\`\\"\\\$]]*)
1525 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1528 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1533 _LT_OUTPUT_LIBTOOL_INIT
1536 # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
1537 # ------------------------------------
1538 # Generate a child script FILE with all initialization necessary to
1539 # reuse the environment learned by the parent script, and make the
1540 # file executable. If COMMENT is supplied, it is inserted after the
1541 # `#!' sequence but before initialization text begins. After this
1542 # macro, additional text can be appended to FILE to form the body of
1543 # the child script. The macro ends with non-zero status if the
1544 # file could not be fully written (such as if the disk is full).
1545 m4_ifdef([AS_INIT_GENERATED],
1546 [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
1547 [m4_defun([_LT_GENERATED_FILE_INIT],
1548 [m4_require([AS_PREPARE])]dnl
1549 [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
1551 cat >$1 <<_ASEOF || lt_write_fail=1
1553 # Generated by $as_me.
1555 SHELL=\${CONFIG_SHELL-$SHELL}
1558 cat >>$1 <<\_ASEOF || lt_write_fail=1
1561 exec AS_MESSAGE_FD>&1
1563 test $lt_write_fail = 0 && chmod +x $1[]dnl
1564 m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
1568 # This macro allows early generation of the libtool script (before
1569 # AC_OUTPUT is called), incase it is used in configure for compilation
1571 AC_DEFUN([LT_OUTPUT],
1572 [: ${CONFIG_LT=./config.lt}
1573 AC_MSG_NOTICE([creating $CONFIG_LT])
1574 _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
1575 [# Run this file to recreate a libtool stub with the current configuration.])
1577 cat >>"$CONFIG_LT" <<\_LTEOF
1579 exec AS_MESSAGE_LOG_FD>>config.log
1582 AS_BOX([Running $as_me.])
1583 } >&AS_MESSAGE_LOG_FD
1586 \`$as_me' creates a local libtool stub from the current configuration,
1587 for use in further configure time tests before the real libtool is
1590 Usage: $[0] [[OPTIONS]]
1592 -h, --help print this help, then exit
1593 -V, --version print version number, then exit
1594 -q, --quiet do not print progress messages
1595 -d, --debug don't remove temporary files
1597 Report bugs to <bug-libtool@gnu.org>."
1600 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1601 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1602 configured by $[0], generated by m4_PACKAGE_STRING.
1604 Copyright (C) 2011 Free Software Foundation, Inc.
1605 This config.lt script is free software; the Free Software Foundation
1606 gives unlimited permision to copy, distribute and modify it."
1608 while test $[#] != 0
1611 --version | --v* | -V )
1612 echo "$lt_cl_version"; exit 0 ;;
1613 --help | --h* | -h )
1614 echo "$lt_cl_help"; exit 0 ;;
1615 --debug | --d* | -d )
1617 --quiet | --q* | --silent | --s* | -q )
1620 -*) AC_MSG_ERROR([unrecognized option: $[1]
1621 Try \`$[0] --help' for more information.]) ;;
1623 *) AC_MSG_ERROR([unrecognized argument: $[1]
1624 Try \`$[0] --help' for more information.]) ;;
1629 if $lt_cl_silent; then
1630 exec AS_MESSAGE_FD>/dev/null
1634 cat >>"$CONFIG_LT" <<_LTEOF
1635 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1638 cat >>"$CONFIG_LT" <<\_LTEOF
1639 AC_MSG_NOTICE([creating $ofile])
1640 _LT_OUTPUT_LIBTOOL_COMMANDS
1643 chmod +x "$CONFIG_LT"
1645 # configure is writing to config.log, but config.lt does its own redirection,
1646 # appending to config.log, which fails on DOS, as config.log is still kept
1647 # open by configure. Here we exec the FD to /dev/null, effectively closing
1648 # config.log, so it can be properly (re)opened and appended to by config.lt.
1650 test "$silent" = yes &&
1651 lt_config_lt_args="$lt_config_lt_args --quiet"
1652 exec AS_MESSAGE_LOG_FD>/dev/null
1653 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
1654 exec AS_MESSAGE_LOG_FD>>config.log
1655 $lt_cl_success || AS_EXIT(1)
1661 # If TAG is the built-in tag, create an initial libtool script with a
1662 # default configuration from the untagged config vars. Otherwise add code
1663 # to config.status for appending the configuration named by TAG from the
1664 # matching tagged config vars.
1665 m4_defun([_LT_CONFIG],
1666 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1667 _LT_CONFIG_SAVE_COMMANDS([
1668 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
1669 m4_if(_LT_TAG, [C], [
1670 # See if we are running on zsh, and set the options which allow our
1671 # commands through without removal of \ escapes.
1672 if test -n "${ZSH_VERSION+set}" ; then
1673 setopt NO_GLOB_SUBST
1677 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
1680 cat <<_LT_EOF >> "$cfgfile"
1683 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
1684 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
1685 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1686 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
1691 # ### BEGIN LIBTOOL CONFIG
1692 _LT_LIBTOOL_CONFIG_VARS
1693 _LT_LIBTOOL_TAG_VARS
1694 # ### END LIBTOOL CONFIG
1700 cat <<\_LT_EOF >> "$cfgfile"
1701 # AIX sometimes has problems with the GCC collect2 program. For some
1702 # reason, if we set the COLLECT_NAMES environment variable, the problems
1703 # vanish in a puff of smoke.
1704 if test "X${COLLECT_NAMES+set}" != Xset; then
1706 export COLLECT_NAMES
1714 # We use sed instead of cat because bash on DJGPP gets confused if
1715 # if finds mixed CR/LF and LF-only lines. Since sed operates in
1716 # text mode, it properly converts lines to CR/LF. This bash problem
1717 # is reportedly fixed, but why not run on old versions too?
1718 sed '$q' "$ltmain" >> "$cfgfile" \
1719 || (rm -f "$cfgfile"; exit 1)
1721 _LT_PROG_REPLACE_SHELLFNS
1723 mv -f "$cfgfile" "$ofile" ||
1724 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
1727 [cat <<_LT_EOF >> "$ofile"
1729 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
1730 dnl in a comment (ie after a #).
1731 # ### BEGIN LIBTOOL TAG CONFIG: $1
1732 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
1733 # ### END LIBTOOL TAG CONFIG: $1
1740 TIMESTAMP='$TIMESTAMP'
1742 ofile='$ofile'], [])
1743 ])dnl /_LT_CONFIG_SAVE_COMMANDS
1747 # LT_SUPPORTED_TAG(TAG)
1748 # ---------------------
1749 # Trace this macro to discover what tags are supported by the libtool
1750 # --tag option, using:
1751 # autoconf --trace 'LT_SUPPORTED_TAG:$1'
1752 AC_DEFUN([LT_SUPPORTED_TAG], [])
1755 # C support is built-in for now
1756 m4_define([_LT_LANG_C_enabled], [])
1757 m4_define([_LT_TAGS], [])
1762 # Enable libtool support for the given language if not already enabled.
1764 [AC_BEFORE([$0], [LT_OUTPUT])dnl
1767 [C++], [_LT_LANG(CXX)],
1768 [Go], [_LT_LANG(GO)],
1769 [Java], [_LT_LANG(GCJ)],
1770 [Fortran 77], [_LT_LANG(F77)],
1771 [Fortran], [_LT_LANG(FC)],
1772 [Windows Resource], [_LT_LANG(RC)],
1773 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
1775 [m4_fatal([$0: unsupported language: "$1"])])])dnl
1779 # _LT_LANG(LANGNAME)
1780 # ------------------
1781 m4_defun([_LT_LANG],
1782 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
1783 [LT_SUPPORTED_TAG([$1])dnl
1784 m4_append([_LT_TAGS], [$1 ])dnl
1785 m4_define([_LT_LANG_]$1[_enabled], [])dnl
1786 _LT_LANG_$1_CONFIG($1)])dnl
1790 m4_ifndef([AC_PROG_GO], [
1791 # NOTE: This macro has been submitted for inclusion into #
1792 # GNU Autoconf as AC_PROG_GO. When it is available in #
1793 # a released version of Autoconf we should remove this #
1794 # macro and use it instead. #
1795 m4_defun([AC_PROG_GO],
1796 [AC_LANG_PUSH(Go)dnl
1797 AC_ARG_VAR([GOC], [Go compiler command])dnl
1798 AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
1799 _AC_ARG_VAR_LDFLAGS()dnl
1800 AC_CHECK_TOOL(GOC, gccgo)
1801 if test -z "$GOC"; then
1802 if test -n "$ac_tool_prefix"; then
1803 AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
1806 if test -z "$GOC"; then
1807 AC_CHECK_PROG(GOC, gccgo, gccgo, false)
1813 # _LT_LANG_DEFAULT_CONFIG
1814 # -----------------------
1815 m4_defun([_LT_LANG_DEFAULT_CONFIG],
1816 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
1818 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
1820 AC_PROVIDE_IFELSE([AC_PROG_F77],
1822 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
1824 AC_PROVIDE_IFELSE([AC_PROG_FC],
1826 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
1828 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
1829 dnl pulling things in needlessly.
1830 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1832 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1834 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
1836 [m4_ifdef([AC_PROG_GCJ],
1837 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
1838 m4_ifdef([A][M_PROG_GCJ],
1839 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
1840 m4_ifdef([LT_PROG_GCJ],
1841 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
1843 AC_PROVIDE_IFELSE([AC_PROG_GO],
1845 [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
1847 AC_PROVIDE_IFELSE([LT_PROG_RC],
1849 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
1850 ])# _LT_LANG_DEFAULT_CONFIG
1853 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1854 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1855 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1856 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1857 AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
1858 dnl aclocal-1.4 backwards compatibility:
1859 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1860 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1861 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1862 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1863 dnl AC_DEFUN([AC_LIBTOOL_RC], [])
1868 m4_defun([_LT_TAG_COMPILER],
1869 [AC_REQUIRE([AC_PROG_CC])dnl
1871 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1872 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1873 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1874 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1876 # If no C compiler was specified, use CC.
1879 # If no C compiler flags were specified, use CFLAGS.
1880 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1882 # Allow CC to be a program name with arguments.
1884 ])# _LT_TAG_COMPILER
1887 # _LT_COMPILER_BOILERPLATE
1888 # ------------------------
1889 # Check for compiler boilerplate output or warnings with
1890 # the simple compiler test code.
1891 m4_defun([_LT_COMPILER_BOILERPLATE],
1892 [m4_require([_LT_DECL_SED])dnl
1893 ac_outfile=conftest.$ac_objext
1894 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1895 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1896 _lt_compiler_boilerplate=`cat conftest.err`
1898 ])# _LT_COMPILER_BOILERPLATE
1901 # _LT_LINKER_BOILERPLATE
1902 # ----------------------
1903 # Check for linker boilerplate output or warnings with
1904 # the simple link test code.
1905 m4_defun([_LT_LINKER_BOILERPLATE],
1906 [m4_require([_LT_DECL_SED])dnl
1907 ac_outfile=conftest.$ac_objext
1908 echo "$lt_simple_link_test_code" >conftest.$ac_ext
1909 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1910 _lt_linker_boilerplate=`cat conftest.err`
1912 ])# _LT_LINKER_BOILERPLATE
1914 # _LT_REQUIRED_DARWIN_CHECKS
1915 # -------------------------
1916 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1918 rhapsody* | darwin*)
1919 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1920 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1921 AC_CHECK_TOOL([LIPO], [lipo], [:])
1922 AC_CHECK_TOOL([OTOOL], [otool], [:])
1923 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1924 _LT_DECL([], [DSYMUTIL], [1],
1925 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1926 _LT_DECL([], [NMEDIT], [1],
1927 [Tool to change global to local symbols on Mac OS X])
1928 _LT_DECL([], [LIPO], [1],
1929 [Tool to manipulate fat objects and archives on Mac OS X])
1930 _LT_DECL([], [OTOOL], [1],
1931 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1932 _LT_DECL([], [OTOOL64], [1],
1933 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1935 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1936 [lt_cv_apple_cc_single_mod=no
1937 if test -z "${LT_MULTI_MODULE}"; then
1938 # By default we will add the -single_module flag. You can override
1939 # by either setting the environment variable LT_MULTI_MODULE
1940 # non-empty at configure time, or by adding -multi_module to the
1942 rm -rf libconftest.dylib*
1943 echo "int foo(void){return 1;}" > conftest.c
1944 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1945 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1946 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1947 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1949 # If there is a non-empty error log, and "single_module"
1950 # appears in it, assume the flag caused a linker warning
1951 if test -s conftest.err && $GREP single_module conftest.err; then
1952 cat conftest.err >&AS_MESSAGE_LOG_FD
1953 # Otherwise, if the output was created with a 0 exit code from
1954 # the compiler, it worked.
1955 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
1956 lt_cv_apple_cc_single_mod=yes
1958 cat conftest.err >&AS_MESSAGE_LOG_FD
1960 rm -rf libconftest.dylib*
1964 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1965 [lt_cv_ld_exported_symbols_list],
1966 [lt_cv_ld_exported_symbols_list=no
1967 save_LDFLAGS=$LDFLAGS
1968 echo "_main" > conftest.sym
1969 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1970 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1971 [lt_cv_ld_exported_symbols_list=yes],
1972 [lt_cv_ld_exported_symbols_list=no])
1973 LDFLAGS="$save_LDFLAGS"
1976 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
1977 [lt_cv_ld_force_load=no
1978 cat > conftest.c << _LT_EOF
1979 int forced_loaded() { return 2;}
1981 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1982 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1983 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1984 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1985 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1986 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1987 cat > conftest.c << _LT_EOF
1988 int main() { return 0;}
1990 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
1991 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
1993 if test -s conftest.err && $GREP force_load conftest.err; then
1994 cat conftest.err >&AS_MESSAGE_LOG_FD
1995 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
1996 lt_cv_ld_force_load=yes
1998 cat conftest.err >&AS_MESSAGE_LOG_FD
2000 rm -f conftest.err libconftest.a conftest conftest.c
2001 rm -rf conftest.dSYM
2004 rhapsody* | darwin1.[[012]])
2005 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
2007 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2008 darwin*) # darwin 5.x on
2009 # if running on 10.5 or later, the deployment target defaults
2010 # to the OS version, if on x86, and 10.4, the deployment
2011 # target defaults to 10.4. Don't you love it?
2012 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
2013 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
2014 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2016 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
2018 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
2022 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
2023 _lt_dar_single_mod='$single_module'
2025 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
2026 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
2028 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
2030 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
2031 _lt_dsymutil='~$DSYMUTIL $lib || :'
2040 # _LT_DARWIN_LINKER_FEATURES([TAG])
2041 # ---------------------------------
2042 # Checks for linker and compiler features on darwin
2043 m4_defun([_LT_DARWIN_LINKER_FEATURES],
2045 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
2046 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
2047 _LT_TAGVAR(hardcode_direct, $1)=no
2048 _LT_TAGVAR(hardcode_automatic, $1)=yes
2049 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2050 if test "$lt_cv_ld_force_load" = "yes"; then
2051 _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\"`'
2052 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
2053 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
2055 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
2057 _LT_TAGVAR(link_all_deplibs, $1)=yes
2058 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
2059 case $cc_basename in
2060 ifort*) _lt_dar_can_shared=yes ;;
2061 *) _lt_dar_can_shared=$GCC ;;
2063 if test "$_lt_dar_can_shared" = "yes"; then
2064 output_verbose_link_cmd=func_echo_all
2065 _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}"
2066 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
2067 _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}"
2068 _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}"
2070 [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
2071 _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}"
2072 _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}"
2076 _LT_TAGVAR(ld_shlibs, $1)=no
2080 # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
2081 # ----------------------------------
2082 # Links a minimal program and checks the executable
2083 # for the system default hardcoded library path. In most cases,
2084 # this is /usr/lib:/lib, but when the MPI compilers are used
2085 # the location of the communication and MPI libs are included too.
2086 # If we don't find anything, use the default library path according
2087 # to the aix ld manual.
2088 # Store the results from the different compilers for each TAGNAME.
2089 # Allow to override them for all tags through lt_cv_aix_libpath.
2090 m4_defun([_LT_SYS_MODULE_PATH_AIX],
2091 [m4_require([_LT_DECL_SED])dnl
2092 if test "${lt_cv_aix_libpath+set}" = set; then
2093 aix_libpath=$lt_cv_aix_libpath
2095 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
2096 [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
2097 lt_aix_libpath_sed='[
2098 /Import File Strings/,/^$/ {
2100 s/^0 *\([^ ]*\) *$/\1/
2104 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2105 # Check for a 64-bit object if we didn't find anything.
2106 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
2107 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
2109 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
2110 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
2113 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
2115 ])# _LT_SYS_MODULE_PATH_AIX
2118 # _LT_SHELL_INIT(ARG)
2119 # -------------------
2120 m4_define([_LT_SHELL_INIT],
2121 [m4_divert_text([M4SH-INIT], [$1
2122 ])])# _LT_SHELL_INIT
2126 # _LT_PROG_ECHO_BACKSLASH
2127 # -----------------------
2128 # Find how we can fake an echo command that does not interpret backslash.
2129 # In particular, with Autoconf 2.60 or later we add some code to the start
2130 # of the generated configure script which will find a shell with a builtin
2131 # printf (which we can use as an echo command).
2132 m4_defun([_LT_PROG_ECHO_BACKSLASH],
2133 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
2134 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
2135 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
2137 AC_MSG_CHECKING([how to print strings])
2138 # Test print first, because it will be a builtin if present.
2139 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
2140 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
2142 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
2145 # Use this function as a fallback that always works.
2146 func_fallback_echo ()
2148 eval 'cat <<_LTECHO_EOF
2152 ECHO='func_fallback_echo'
2155 # func_echo_all arg...
2156 # Invoke $ECHO with all args, space-separated.
2163 printf*) AC_MSG_RESULT([printf]) ;;
2164 print*) AC_MSG_RESULT([print -r]) ;;
2165 *) AC_MSG_RESULT([cat]) ;;
2168 m4_ifdef([_AS_DETECT_SUGGESTED],
2169 [_AS_DETECT_SUGGESTED([
2170 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
2171 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
2172 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
2173 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
2174 PATH=/empty FPATH=/empty; export PATH FPATH
2175 test "X`printf %s $ECHO`" = "X$ECHO" \
2176 || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
2178 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
2179 _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
2180 ])# _LT_PROG_ECHO_BACKSLASH
2185 AC_DEFUN([_LT_WITH_SYSROOT],
2186 [AC_MSG_CHECKING([for sysroot])
2187 AC_ARG_WITH([sysroot],
2188 [ --with-sysroot[=DIR] Search for dependent libraries within DIR
2189 (or the compiler's sysroot if not specified).],
2190 [], [with_sysroot=no])
2192 dnl lt_sysroot will always be passed unquoted. We quote it here
2193 dnl in case the user passed a directory name.
2195 case ${with_sysroot} in #(
2197 if test "$GCC" = yes; then
2198 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
2202 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
2207 AC_MSG_RESULT([${with_sysroot}])
2208 AC_MSG_ERROR([The sysroot must be an absolute path.])
2212 AC_MSG_RESULT([${lt_sysroot:-no}])
2213 _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
2214 [dependent libraries, and in which our libraries should be installed.])])
2218 m4_defun([_LT_ENABLE_LOCK],
2219 [AC_ARG_ENABLE([libtool-lock],
2220 [AS_HELP_STRING([--disable-libtool-lock],
2221 [avoid locking (might break parallel builds)])])
2222 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
2224 # Some flags need to be propagated to the compiler or linker for good
2228 # Find out which ABI we are using.
2229 echo 'int i;' > conftest.$ac_ext
2230 if AC_TRY_EVAL(ac_compile); then
2231 case `/usr/bin/file conftest.$ac_objext` in
2243 # Find out which ABI we are using.
2244 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
2245 if AC_TRY_EVAL(ac_compile); then
2246 if test "$lt_cv_prog_gnu_ld" = yes; then
2247 case `/usr/bin/file conftest.$ac_objext` in
2249 LD="${LD-ld} -melf32bsmip"
2252 LD="${LD-ld} -melf32bmipn32"
2255 LD="${LD-ld} -melf64bmip"
2259 case `/usr/bin/file conftest.$ac_objext` in
2275 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
2276 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
2277 # Find out which ABI we are using.
2278 echo 'int i;' > conftest.$ac_ext
2279 if AC_TRY_EVAL(ac_compile); then
2280 case `/usr/bin/file conftest.o` in
2283 x86_64-*kfreebsd*-gnu)
2284 LD="${LD-ld} -m elf_i386_fbsd"
2287 case `/usr/bin/file conftest.o` in
2289 LD="${LD-ld} -m elf32_x86_64"
2292 LD="${LD-ld} -m elf_i386"
2296 ppc64-*linux*|powerpc64-*linux*)
2297 LD="${LD-ld} -m elf32ppclinux"
2300 LD="${LD-ld} -m elf_s390"
2303 LD="${LD-ld} -m elf32_sparc"
2309 x86_64-*kfreebsd*-gnu)
2310 LD="${LD-ld} -m elf_x86_64_fbsd"
2313 LD="${LD-ld} -m elf_x86_64"
2315 ppc*-*linux*|powerpc*-*linux*)
2316 LD="${LD-ld} -m elf64ppc"
2318 s390*-*linux*|s390*-*tpf*)
2319 LD="${LD-ld} -m elf64_s390"
2322 LD="${LD-ld} -m elf64_sparc"
2332 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2333 SAVE_CFLAGS="$CFLAGS"
2334 CFLAGS="$CFLAGS -belf"
2335 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
2337 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
2339 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2340 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2341 CFLAGS="$SAVE_CFLAGS"
2345 # Find out which ABI we are using.
2346 echo 'int i;' > conftest.$ac_ext
2347 if AC_TRY_EVAL(ac_compile); then
2348 case `/usr/bin/file conftest.o` in
2350 case $lt_cv_prog_gnu_ld in
2354 LD="${LD-ld} -m elf_x86_64"
2357 LD="${LD-ld} -m elf64_sparc"
2360 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
2361 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
2366 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
2378 need_locks="$enable_libtool_lock"
2384 m4_defun([_LT_PROG_AR],
2385 [AC_CHECK_TOOLS(AR, [ar], false)
2388 _LT_DECL([], [AR], [1], [The archiver])
2389 _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
2391 AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
2392 [lt_cv_ar_at_file=no
2393 AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
2394 [echo conftest.$ac_objext > conftest.lst
2395 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
2396 AC_TRY_EVAL([lt_ar_try])
2397 if test "$ac_status" -eq 0; then
2398 # Ensure the archiver fails upon bogus file names.
2399 rm -f conftest.$ac_objext libconftest.a
2400 AC_TRY_EVAL([lt_ar_try])
2401 if test "$ac_status" -ne 0; then
2405 rm -f conftest.* libconftest.a
2409 if test "x$lt_cv_ar_at_file" = xno; then
2412 archiver_list_spec=$lt_cv_ar_at_file
2414 _LT_DECL([], [archiver_list_spec], [1],
2415 [How to feed a file listing to the archiver])
2419 # _LT_CMD_OLD_ARCHIVE
2420 # -------------------
2421 m4_defun([_LT_CMD_OLD_ARCHIVE],
2424 AC_CHECK_TOOL(STRIP, strip, :)
2425 test -z "$STRIP" && STRIP=:
2426 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
2428 AC_CHECK_TOOL(RANLIB, ranlib, :)
2429 test -z "$RANLIB" && RANLIB=:
2430 _LT_DECL([], [RANLIB], [1],
2431 [Commands used to install an old-style archive])
2433 # Determine commands to create old-style static archives.
2434 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
2435 old_postinstall_cmds='chmod 644 $oldlib'
2436 old_postuninstall_cmds=
2438 if test -n "$RANLIB"; then
2441 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
2444 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
2447 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
2452 lock_old_archive_extraction=yes ;;
2454 lock_old_archive_extraction=no ;;
2456 _LT_DECL([], [old_postinstall_cmds], [2])
2457 _LT_DECL([], [old_postuninstall_cmds], [2])
2458 _LT_TAGDECL([], [old_archive_cmds], [2],
2459 [Commands used to build an old-style archive])
2460 _LT_DECL([], [lock_old_archive_extraction], [0],
2461 [Whether to use a lock for old archive extraction])
2462 ])# _LT_CMD_OLD_ARCHIVE
2465 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2466 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
2467 # ----------------------------------------------------------------
2468 # Check whether the given compiler option works
2469 AC_DEFUN([_LT_COMPILER_OPTION],
2470 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2471 m4_require([_LT_DECL_SED])dnl
2472 AC_CACHE_CHECK([$1], [$2],
2474 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
2475 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2476 lt_compiler_flag="$3"
2477 # Insert the option either (1) after the last *FLAGS variable, or
2478 # (2) before a word containing "conftest.", or (3) at the end.
2479 # Note that $ac_compile itself does not contain backslashes and begins
2480 # with a dollar sign (not a hyphen), so the echo should work correctly.
2481 # The option is referenced via a variable to avoid confusing sed.
2482 lt_compile=`echo "$ac_compile" | $SED \
2483 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2484 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2485 -e 's:$: $lt_compiler_flag:'`
2486 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2487 (eval "$lt_compile" 2>conftest.err)
2489 cat conftest.err >&AS_MESSAGE_LOG_FD
2490 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2491 if (exit $ac_status) && test -s "$ac_outfile"; then
2492 # The compiler can only warn and ignore the option if not recognized
2493 # So say no if there are warnings other than the usual output.
2494 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
2495 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2496 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2503 if test x"[$]$2" = xyes; then
2504 m4_if([$5], , :, [$5])
2506 m4_if([$6], , :, [$6])
2508 ])# _LT_COMPILER_OPTION
2511 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2512 dnl aclocal-1.4 backwards compatibility:
2513 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2516 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2517 # [ACTION-SUCCESS], [ACTION-FAILURE])
2518 # ----------------------------------------------------
2519 # Check whether the given linker option works
2520 AC_DEFUN([_LT_LINKER_OPTION],
2521 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2522 m4_require([_LT_DECL_SED])dnl
2523 AC_CACHE_CHECK([$1], [$2],
2525 save_LDFLAGS="$LDFLAGS"
2526 LDFLAGS="$LDFLAGS $3"
2527 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2528 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2529 # The linker can only warn and ignore the option if not recognized
2530 # So say no if there are warnings
2531 if test -s conftest.err; then
2532 # Append any errors to the config.log.
2533 cat conftest.err 1>&AS_MESSAGE_LOG_FD
2534 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
2535 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2536 if diff conftest.exp conftest.er2 >/dev/null; then
2544 LDFLAGS="$save_LDFLAGS"
2547 if test x"[$]$2" = xyes; then
2548 m4_if([$4], , :, [$4])
2550 m4_if([$5], , :, [$5])
2552 ])# _LT_LINKER_OPTION
2555 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2556 dnl aclocal-1.4 backwards compatibility:
2557 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2562 AC_DEFUN([LT_CMD_MAX_LEN],
2563 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2564 # find the maximum length of command line arguments
2565 AC_MSG_CHECKING([the maximum length of command line arguments])
2566 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2572 # On DJGPP, this test can blow up pretty badly due to problems in libc
2573 # (any single argument exceeding 2000 bytes causes a buffer overrun
2574 # during glob expansion). Even if it were fixed, the result of this
2575 # check would be larger than it should be.
2576 lt_cv_sys_max_cmd_len=12288; # 12K is about right
2580 # Under GNU Hurd, this test is not required because there is
2581 # no limit to the length of command line arguments.
2582 # Libtool will interpret -1 as no limit whatsoever
2583 lt_cv_sys_max_cmd_len=-1;
2586 cygwin* | mingw* | cegcc*)
2587 # On Win9x/ME, this test blows up -- it succeeds, but takes
2588 # about 5 minutes as the teststring grows exponentially.
2589 # Worse, since 9x/ME are not pre-emptively multitasking,
2590 # you end up with a "frozen" computer, even though with patience
2591 # the test eventually succeeds (with a max line length of 256k).
2592 # Instead, let's just punt: use the minimum linelength reported by
2593 # all of the supported platforms: 8192 (on NT/2K/XP).
2594 lt_cv_sys_max_cmd_len=8192;
2598 # On MiNT this can take a long time and run out of memory.
2599 lt_cv_sys_max_cmd_len=8192;
2603 # On AmigaOS with pdksh, this test takes hours, literally.
2604 # So we just punt and use a minimum line length of 8192.
2605 lt_cv_sys_max_cmd_len=8192;
2608 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
2609 # This has been around since 386BSD, at least. Likely further.
2610 if test -x /sbin/sysctl; then
2611 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2612 elif test -x /usr/sbin/sysctl; then
2613 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2615 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
2617 # And add a safety zone
2618 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2619 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2623 # We know the value 262144 and hardcode it with a safety zone (like BSD)
2624 lt_cv_sys_max_cmd_len=196608
2628 # The test takes a long time on OS/2.
2629 lt_cv_sys_max_cmd_len=8192
2633 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2634 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2635 # nice to cause kernel panics so lets avoid the loop below.
2636 # First set a reasonable default.
2637 lt_cv_sys_max_cmd_len=16384
2639 if test -x /sbin/sysconfig; then
2640 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2641 *1*) lt_cv_sys_max_cmd_len=-1 ;;
2646 lt_cv_sys_max_cmd_len=102400
2648 sysv5* | sco5v6* | sysv4.2uw2*)
2649 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2650 if test -n "$kargmax"; then
2651 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
2653 lt_cv_sys_max_cmd_len=32768
2657 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
2658 if test -n "$lt_cv_sys_max_cmd_len" && \
2659 test undefined != "$lt_cv_sys_max_cmd_len"; then
2660 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2661 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2663 # Make teststring a little bigger before we do anything with it.
2664 # a 1K string should be a reasonable start.
2665 for i in 1 2 3 4 5 6 7 8 ; do
2666 teststring=$teststring$teststring
2668 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
2669 # If test is not a shell built-in, we'll probably end up computing a
2670 # maximum length that is only half of the actual maximum length, but
2672 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
2673 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
2674 test $i != 17 # 1/2 MB should be enough
2677 teststring=$teststring$teststring
2679 # Only check the string length outside the loop.
2680 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
2682 # Add a significant safety factor because C++ compilers can tack on
2683 # massive amounts of additional arguments before passing them to the
2684 # linker. It appears as though 1/2 is a usable value.
2685 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
2690 if test -n $lt_cv_sys_max_cmd_len ; then
2691 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
2695 max_cmd_len=$lt_cv_sys_max_cmd_len
2696 _LT_DECL([], [max_cmd_len], [0],
2697 [What is the maximum length of a command?])
2701 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
2702 dnl aclocal-1.4 backwards compatibility:
2703 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
2708 m4_defun([_LT_HEADER_DLFCN],
2709 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
2710 ])# _LT_HEADER_DLFCN
2713 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
2714 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
2715 # ----------------------------------------------------------------
2716 m4_defun([_LT_TRY_DLOPEN_SELF],
2717 [m4_require([_LT_HEADER_DLFCN])dnl
2718 if test "$cross_compiling" = yes; then :
2721 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
2722 lt_status=$lt_dlunknown
2723 cat > conftest.$ac_ext <<_LT_EOF
2724 [#line $LINENO "configure"
2725 #include "confdefs.h"
2734 # define LT_DLGLOBAL RTLD_GLOBAL
2737 # define LT_DLGLOBAL DL_GLOBAL
2739 # define LT_DLGLOBAL 0
2743 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
2744 find out it does not work in some platform. */
2745 #ifndef LT_DLLAZY_OR_NOW
2747 # define LT_DLLAZY_OR_NOW RTLD_LAZY
2750 # define LT_DLLAZY_OR_NOW DL_LAZY
2753 # define LT_DLLAZY_OR_NOW RTLD_NOW
2756 # define LT_DLLAZY_OR_NOW DL_NOW
2758 # define LT_DLLAZY_OR_NOW 0
2765 /* When -fvisbility=hidden is used, assume the code has been annotated
2766 correspondingly for the symbols needed. */
2767 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
2768 int fnord () __attribute__((visibility("default")));
2771 int fnord () { return 42; }
2774 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
2775 int status = $lt_dlunknown;
2779 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
2782 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
2783 else puts (dlerror ());
2785 /* dlclose (self); */
2793 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
2794 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
2797 x$lt_dlno_uscore) $1 ;;
2798 x$lt_dlneed_uscore) $2 ;;
2799 x$lt_dlunknown|x*) $3 ;;
2802 # compilation failed
2807 ])# _LT_TRY_DLOPEN_SELF
2810 # LT_SYS_DLOPEN_SELF
2811 # ------------------
2812 AC_DEFUN([LT_SYS_DLOPEN_SELF],
2813 [m4_require([_LT_HEADER_DLFCN])dnl
2814 if test "x$enable_dlopen" != xyes; then
2815 enable_dlopen=unknown
2816 enable_dlopen_self=unknown
2817 enable_dlopen_self_static=unknown
2824 lt_cv_dlopen="load_add_on"
2826 lt_cv_dlopen_self=yes
2829 mingw* | pw32* | cegcc*)
2830 lt_cv_dlopen="LoadLibrary"
2835 lt_cv_dlopen="dlopen"
2840 # if libdl is installed we need to link against it
2841 AC_CHECK_LIB([dl], [dlopen],
2842 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
2845 lt_cv_dlopen_self=yes
2850 AC_CHECK_FUNC([shl_load],
2851 [lt_cv_dlopen="shl_load"],
2852 [AC_CHECK_LIB([dld], [shl_load],
2853 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
2854 [AC_CHECK_FUNC([dlopen],
2855 [lt_cv_dlopen="dlopen"],
2856 [AC_CHECK_LIB([dl], [dlopen],
2857 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
2858 [AC_CHECK_LIB([svld], [dlopen],
2859 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
2860 [AC_CHECK_LIB([dld], [dld_link],
2861 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
2870 if test "x$lt_cv_dlopen" != xno; then
2876 case $lt_cv_dlopen in
2878 save_CPPFLAGS="$CPPFLAGS"
2879 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2881 save_LDFLAGS="$LDFLAGS"
2882 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2885 LIBS="$lt_cv_dlopen_libs $LIBS"
2887 AC_CACHE_CHECK([whether a program can dlopen itself],
2888 lt_cv_dlopen_self, [dnl
2889 _LT_TRY_DLOPEN_SELF(
2890 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2891 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2894 if test "x$lt_cv_dlopen_self" = xyes; then
2895 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2896 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2897 lt_cv_dlopen_self_static, [dnl
2898 _LT_TRY_DLOPEN_SELF(
2899 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2900 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2904 CPPFLAGS="$save_CPPFLAGS"
2905 LDFLAGS="$save_LDFLAGS"
2910 case $lt_cv_dlopen_self in
2911 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2912 *) enable_dlopen_self=unknown ;;
2915 case $lt_cv_dlopen_self_static in
2916 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2917 *) enable_dlopen_self_static=unknown ;;
2920 _LT_DECL([dlopen_support], [enable_dlopen], [0],
2921 [Whether dlopen is supported])
2922 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2923 [Whether dlopen of programs is supported])
2924 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2925 [Whether dlopen of statically linked programs is supported])
2926 ])# LT_SYS_DLOPEN_SELF
2929 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2930 dnl aclocal-1.4 backwards compatibility:
2931 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2934 # _LT_COMPILER_C_O([TAGNAME])
2935 # ---------------------------
2936 # Check to see if options -c and -o are simultaneously supported by compiler.
2937 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
2938 m4_defun([_LT_COMPILER_C_O],
2939 [m4_require([_LT_DECL_SED])dnl
2940 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2941 m4_require([_LT_TAG_COMPILER])dnl
2942 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2943 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2944 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2945 $RM -r conftest 2>/dev/null
2949 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2951 lt_compiler_flag="-o out/conftest2.$ac_objext"
2952 # Insert the option either (1) after the last *FLAGS variable, or
2953 # (2) before a word containing "conftest.", or (3) at the end.
2954 # Note that $ac_compile itself does not contain backslashes and begins
2955 # with a dollar sign (not a hyphen), so the echo should work correctly.
2956 lt_compile=`echo "$ac_compile" | $SED \
2957 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2958 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2959 -e 's:$: $lt_compiler_flag:'`
2960 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2961 (eval "$lt_compile" 2>out/conftest.err)
2963 cat out/conftest.err >&AS_MESSAGE_LOG_FD
2964 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2965 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2967 # The compiler can only warn and ignore the option if not recognized
2968 # So say no if there are warnings
2969 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
2970 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2971 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2972 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2975 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2977 # SGI C++ compiler will create directory out/ii_files/ for
2978 # template instantiation
2979 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2980 $RM out/* && rmdir out
2985 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2986 [Does compiler simultaneously support -c and -o options?])
2987 ])# _LT_COMPILER_C_O
2990 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
2991 # ----------------------------------
2992 # Check to see if we can do hard links to lock some files if needed
2993 m4_defun([_LT_COMPILER_FILE_LOCKS],
2994 [m4_require([_LT_ENABLE_LOCK])dnl
2995 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2996 _LT_COMPILER_C_O([$1])
2998 hard_links="nottested"
2999 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
3000 # do not overwrite the value of need_locks provided by the user
3001 AC_MSG_CHECKING([if we can lock with hard links])
3004 ln conftest.a conftest.b 2>/dev/null && hard_links=no
3006 ln conftest.a conftest.b 2>&5 || hard_links=no
3007 ln conftest.a conftest.b 2>/dev/null && hard_links=no
3008 AC_MSG_RESULT([$hard_links])
3009 if test "$hard_links" = no; then
3010 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
3016 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
3017 ])# _LT_COMPILER_FILE_LOCKS
3022 m4_defun([_LT_CHECK_OBJDIR],
3023 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
3024 [rm -f .libs 2>/dev/null
3025 mkdir .libs 2>/dev/null
3026 if test -d .libs; then
3029 # MS-DOS does not allow filenames that begin with a dot.
3032 rmdir .libs 2>/dev/null])
3033 objdir=$lt_cv_objdir
3034 _LT_DECL([], [objdir], [0],
3035 [The name of the directory that contains temporary libtool files])dnl
3036 m4_pattern_allow([LT_OBJDIR])dnl
3037 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
3038 [Define to the sub-directory in which libtool stores uninstalled libraries.])
3039 ])# _LT_CHECK_OBJDIR
3042 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
3043 # --------------------------------------
3044 # Check hardcoding attributes.
3045 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
3046 [AC_MSG_CHECKING([how to hardcode library paths into programs])
3047 _LT_TAGVAR(hardcode_action, $1)=
3048 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
3049 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
3050 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
3052 # We can hardcode non-existent directories.
3053 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
3054 # If the only mechanism to avoid hardcoding is shlibpath_var, we
3055 # have to relink, otherwise we might link with an installed library
3056 # when we should be linking with a yet-to-be-installed one
3057 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
3058 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
3059 # Linking always hardcodes the temporary library directory.
3060 _LT_TAGVAR(hardcode_action, $1)=relink
3062 # We can link without hardcoding, and we can hardcode nonexisting dirs.
3063 _LT_TAGVAR(hardcode_action, $1)=immediate
3066 # We cannot hardcode anything, or else we can only hardcode existing
3068 _LT_TAGVAR(hardcode_action, $1)=unsupported
3070 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
3072 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
3073 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
3074 # Fast installation is not supported
3075 enable_fast_install=no
3076 elif test "$shlibpath_overrides_runpath" = yes ||
3077 test "$enable_shared" = no; then
3078 # Fast installation is not necessary
3079 enable_fast_install=needless
3081 _LT_TAGDECL([], [hardcode_action], [0],
3082 [How to hardcode a shared library path into an executable])
3083 ])# _LT_LINKER_HARDCODE_LIBPATH
3088 m4_defun([_LT_CMD_STRIPLIB],
3089 [m4_require([_LT_DECL_EGREP])
3092 AC_MSG_CHECKING([whether stripping libraries is possible])
3093 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
3094 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
3095 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
3096 AC_MSG_RESULT([yes])
3098 # FIXME - insert some real tests, host_os isn't really good enough
3101 if test -n "$STRIP" ; then
3102 striplib="$STRIP -x"
3103 old_striplib="$STRIP -S"
3104 AC_MSG_RESULT([yes])
3114 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
3115 _LT_DECL([], [striplib], [1])
3116 ])# _LT_CMD_STRIPLIB
3119 # _LT_SYS_DYNAMIC_LINKER([TAG])
3120 # -----------------------------
3121 # PORTME Fill in your ld.so characteristics
3122 m4_defun([_LT_SYS_DYNAMIC_LINKER],
3123 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3124 m4_require([_LT_DECL_EGREP])dnl
3125 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
3126 m4_require([_LT_DECL_OBJDUMP])dnl
3127 m4_require([_LT_DECL_SED])dnl
3128 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
3129 AC_MSG_CHECKING([dynamic linker characteristics])
3132 if test "$GCC" = yes; then
3134 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
3135 *) lt_awk_arg="/^libraries:/" ;;
3138 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
3139 *) lt_sed_strip_eq="s,=/,/,g" ;;
3141 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
3142 case $lt_search_path_spec in
3144 # if the path contains ";" then we assume it to be the separator
3145 # otherwise default to the standard path separator (i.e. ":") - it is
3146 # assumed that no part of a normal pathname contains ";" but that should
3147 # okay in the real world where ";" in dirpaths is itself problematic.
3148 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
3151 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
3154 # Ok, now we have the path, separated by spaces, we can step through it
3155 # and add multilib dir if necessary.
3156 lt_tmp_lt_search_path_spec=
3157 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
3158 for lt_sys_path in $lt_search_path_spec; do
3159 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
3160 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
3162 test -d "$lt_sys_path" && \
3163 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
3166 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
3167 BEGIN {RS=" "; FS="/|\n";} {
3170 for (lt_i = NF; lt_i > 0; lt_i--) {
3171 if ($lt_i != "" && $lt_i != ".") {
3172 if ($lt_i == "..") {
3175 if (lt_count == 0) {
3176 lt_foo="/" $lt_i lt_foo;
3183 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
3184 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
3186 # AWK program above erroneously prepends '/' to C:/dos/paths
3189 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
3190 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
3192 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
3194 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
3197 libname_spec='lib$name'
3205 shlibpath_overrides_runpath=unknown
3207 dynamic_linker="$host_os ld.so"
3208 sys_lib_dlsearch_path_spec="/lib /usr/lib"
3209 need_lib_prefix=unknown
3210 hardcode_into_libs=no
3212 # when you set need_version to no, make sure it does not cause -set_version
3213 # flags to be left without arguments
3214 need_version=unknown
3218 version_type=linux # correct to gnu/linux during the next big refactor
3219 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
3220 shlibpath_var=LIBPATH
3222 # AIX 3 has no versioning support, so we append a major version to the name.
3223 soname_spec='${libname}${release}${shared_ext}$major'
3227 version_type=linux # correct to gnu/linux during the next big refactor
3230 hardcode_into_libs=yes
3231 if test "$host_cpu" = ia64; then
3232 # AIX 5 supports IA64
3233 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
3234 shlibpath_var=LD_LIBRARY_PATH
3236 # With GCC up to 2.95.x, collect2 would create an import file
3237 # for dependence libraries. The import file would start with
3238 # the line `#! .'. This would cause the generated library to
3239 # depend on `.', always an invalid library. This was fixed in
3240 # development snapshots of GCC prior to 3.0.
3242 aix4 | aix4.[[01]] | aix4.[[01]].*)
3243 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
3245 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
3252 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
3253 # soname into executable. Probably we can add versioning support to
3254 # collect2, so additional links can be useful in future.
3255 if test "$aix_use_runtimelinking" = yes; then
3256 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
3257 # instead of lib<name>.a to let people know that these are not
3258 # typical AIX shared libraries.
3259 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3261 # We preserve .a as extension for shared libraries through AIX4.2
3262 # and later when we are not doing run time linking.
3263 library_names_spec='${libname}${release}.a $libname.a'
3264 soname_spec='${libname}${release}${shared_ext}$major'
3266 shlibpath_var=LIBPATH
3273 # Since July 2007 AmigaOS4 officially supports .so libraries.
3274 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
3275 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3278 library_names_spec='$libname.ixlibrary $libname.a'
3279 # Create ${libname}_ixlibrary.a entries in /sys/libs.
3280 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'
3286 library_names_spec='${libname}${shared_ext}'
3287 dynamic_linker="$host_os ld.so"
3288 shlibpath_var=LIBRARY_PATH
3292 version_type=linux # correct to gnu/linux during the next big refactor
3294 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3295 soname_spec='${libname}${release}${shared_ext}$major'
3296 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
3297 shlibpath_var=LD_LIBRARY_PATH
3298 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
3299 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
3300 # the default ld.so.conf also contains /usr/contrib/lib and
3301 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
3302 # libtool to hard-code these into programs
3305 cygwin* | mingw* | pw32* | cegcc*)
3306 version_type=windows
3311 case $GCC,$cc_basename in
3314 library_names_spec='$libname.dll.a'
3315 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3316 postinstall_cmds='base_file=`basename \${file}`~
3317 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3318 dldir=$destdir/`dirname \$dlpath`~
3319 test -d \$dldir || mkdir -p \$dldir~
3320 $install_prog $dir/$dlname \$dldir/$dlname~
3321 chmod a+x \$dldir/$dlname~
3322 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
3323 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
3325 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3326 dlpath=$dir/\$dldll~
3328 shlibpath_overrides_runpath=yes
3332 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
3333 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3335 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
3338 # MinGW DLLs use traditional 'lib' prefix
3339 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3342 # pw32 DLLs use 'pw' prefix rather than 'lib'
3343 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3346 dynamic_linker='Win32 ld.exe'
3351 libname_spec='$name'
3352 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3353 library_names_spec='${libname}.dll.lib'
3357 sys_lib_search_path_spec=
3363 # Let DOS variable expansion print the short 8.3 style file name.
3364 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
3365 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
3368 # Convert to MSYS style.
3369 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
3372 # Convert to unix form, then to dos form, then back to unix form
3373 # but this time dos style (no spaces!) so that the unix form looks
3374 # like /cygdrive/c/PROGRA~1:/cygdr...
3375 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
3376 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
3377 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3380 sys_lib_search_path_spec="$LIB"
3381 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
3382 # It is most probably a Windows format PATH.
3383 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
3385 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3387 # FIXME: find the short name or the path components, as spaces are
3388 # common. (e.g. "Program Files" -> "PROGRA~1")
3392 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3393 postinstall_cmds='base_file=`basename \${file}`~
3394 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3395 dldir=$destdir/`dirname \$dlpath`~
3396 test -d \$dldir || mkdir -p \$dldir~
3397 $install_prog $dir/$dlname \$dldir/$dlname'
3398 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3399 dlpath=$dir/\$dldll~
3401 shlibpath_overrides_runpath=yes
3402 dynamic_linker='Win32 link.exe'
3406 # Assume MSVC wrapper
3407 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
3408 dynamic_linker='Win32 ld.exe'
3411 # FIXME: first we should search . and the directory the executable is in
3415 darwin* | rhapsody*)
3416 dynamic_linker="$host_os dyld"
3420 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
3421 soname_spec='${libname}${release}${major}$shared_ext'
3422 shlibpath_overrides_runpath=yes
3423 shlibpath_var=DYLD_LIBRARY_PATH
3424 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3426 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3427 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3431 version_type=linux # correct to gnu/linux during the next big refactor
3434 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
3435 soname_spec='${libname}${release}${shared_ext}$major'
3436 shlibpath_var=LD_LIBRARY_PATH
3439 freebsd* | dragonfly*)
3440 # DragonFly does not have aout. When/if they implement a new
3441 # versioning mechanism, adjust this.
3442 if test -x /usr/bin/objformat; then
3443 objformat=`/usr/bin/objformat`
3446 freebsd[[23]].*) objformat=aout ;;
3450 version_type=freebsd-$objformat
3451 case $version_type in
3453 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3458 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
3462 shlibpath_var=LD_LIBRARY_PATH
3465 shlibpath_overrides_runpath=yes
3467 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3468 shlibpath_overrides_runpath=yes
3469 hardcode_into_libs=yes
3471 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3472 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3473 shlibpath_overrides_runpath=no
3474 hardcode_into_libs=yes
3476 *) # from 4.6 on, and DragonFly
3477 shlibpath_overrides_runpath=yes
3478 hardcode_into_libs=yes
3484 version_type=linux # correct to gnu/linux during the next big refactor
3487 dynamic_linker="$host_os runtime_loader"
3488 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3489 soname_spec='${libname}${release}${shared_ext}$major'
3490 shlibpath_var=LIBRARY_PATH
3491 shlibpath_overrides_runpath=yes
3492 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
3493 hardcode_into_libs=yes
3496 hpux9* | hpux10* | hpux11*)
3497 # Give a soname corresponding to the major version so that dld.sl refuses to
3498 # link against other versions.
3505 hardcode_into_libs=yes
3506 dynamic_linker="$host_os dld.so"
3507 shlibpath_var=LD_LIBRARY_PATH
3508 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3509 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3510 soname_spec='${libname}${release}${shared_ext}$major'
3511 if test "X$HPUX_IA64_MODE" = X32; then
3512 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3514 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
3516 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3520 hardcode_into_libs=yes
3521 dynamic_linker="$host_os dld.sl"
3522 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
3523 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3524 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3525 soname_spec='${libname}${release}${shared_ext}$major'
3526 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3527 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3531 dynamic_linker="$host_os dld.sl"
3532 shlibpath_var=SHLIB_PATH
3533 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3534 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3535 soname_spec='${libname}${release}${shared_ext}$major'
3538 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
3539 postinstall_cmds='chmod 555 $lib'
3540 # or fails outright, so override atomically:
3541 install_override_mode=555
3545 version_type=linux # correct to gnu/linux during the next big refactor
3548 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3549 soname_spec='${libname}${release}${shared_ext}$major'
3550 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3551 shlibpath_var=LD_LIBRARY_PATH
3552 shlibpath_overrides_runpath=no
3553 hardcode_into_libs=yes
3556 irix5* | irix6* | nonstopux*)
3558 nonstopux*) version_type=nonstopux ;;
3560 if test "$lt_cv_prog_gnu_ld" = yes; then
3561 version_type=linux # correct to gnu/linux during the next big refactor
3568 soname_spec='${libname}${release}${shared_ext}$major'
3569 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
3571 irix5* | nonstopux*)
3575 case $LD in # libtool.m4 will add one of these switches to LD
3576 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3577 libsuff= shlibsuff= libmagic=32-bit;;
3578 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3579 libsuff=32 shlibsuff=N32 libmagic=N32;;
3580 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3581 libsuff=64 shlibsuff=64 libmagic=64-bit;;
3582 *) libsuff= shlibsuff= libmagic=never-match;;
3586 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3587 shlibpath_overrides_runpath=no
3588 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
3589 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
3590 hardcode_into_libs=yes
3593 # No shared lib support for Linux oldld, aout, or coff.
3594 linux*oldld* | linux*aout* | linux*coff*)
3598 # This must be glibc/ELF.
3599 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3600 version_type=linux # correct to gnu/linux during the next big refactor
3603 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3604 soname_spec='${libname}${release}${shared_ext}$major'
3605 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3606 shlibpath_var=LD_LIBRARY_PATH
3607 shlibpath_overrides_runpath=no
3609 # Some binutils ld are patched to set DT_RUNPATH
3610 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
3611 [lt_cv_shlibpath_overrides_runpath=no
3612 save_LDFLAGS=$LDFLAGS
3614 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3615 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3616 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3617 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3618 [lt_cv_shlibpath_overrides_runpath=yes])])
3619 LDFLAGS=$save_LDFLAGS
3622 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
3624 # This implies no fast_install, which is unacceptable.
3625 # Some rework will be needed to allow for fast_install
3626 # before this can be enabled.
3627 hardcode_into_libs=yes
3629 # Append ld.so.conf contents to the search path
3630 if test -f /etc/ld.so.conf; then
3631 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' ' '`
3632 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3635 # We used to test for /lib/ld.so.1 and disable shared libraries on
3636 # powerpc, because MkLinux only supported shared libraries with the
3637 # GNU dynamic linker. Since this was broken with cross compilers,
3638 # most powerpc-linux boxes support dynamic linking these days and
3639 # people can always --disable-shared, the test was removed, and we
3640 # assume the GNU/Linux dynamic linker is in use.
3641 dynamic_linker='GNU/Linux ld.so'
3648 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3649 soname_spec='${libname}${release}${shared_ext}$major'
3650 shlibpath_var=LD_LIBRARY_PATH
3651 shlibpath_overrides_runpath=no
3652 hardcode_into_libs=yes
3653 dynamic_linker='NetBSD ld.elf_so'
3660 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
3661 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3662 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3663 dynamic_linker='NetBSD (a.out) ld.so'
3665 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3666 soname_spec='${libname}${release}${shared_ext}$major'
3667 dynamic_linker='NetBSD ld.elf_so'
3669 shlibpath_var=LD_LIBRARY_PATH
3670 shlibpath_overrides_runpath=yes
3671 hardcode_into_libs=yes
3675 version_type=linux # correct to gnu/linux during the next big refactor
3676 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3677 shlibpath_var=LD_LIBRARY_PATH
3678 shlibpath_overrides_runpath=yes
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='ldqnx.so'
3695 sys_lib_dlsearch_path_spec="/usr/lib"
3697 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
3699 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
3700 *) need_version=no ;;
3702 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3703 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3704 shlibpath_var=LD_LIBRARY_PATH
3705 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3707 openbsd2.[[89]] | openbsd2.[[89]].*)
3708 shlibpath_overrides_runpath=no
3711 shlibpath_overrides_runpath=yes
3715 shlibpath_overrides_runpath=yes
3720 libname_spec='$name'
3723 library_names_spec='$libname${shared_ext} $libname.a'
3724 dynamic_linker='OS/2 ld.exe'
3725 shlibpath_var=LIBPATH
3728 osf3* | osf4* | osf5*)
3732 soname_spec='${libname}${release}${shared_ext}$major'
3733 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3734 shlibpath_var=LD_LIBRARY_PATH
3735 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
3736 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
3744 version_type=linux # correct to gnu/linux during the next big refactor
3747 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3748 soname_spec='${libname}${release}${shared_ext}$major'
3749 shlibpath_var=LD_LIBRARY_PATH
3750 shlibpath_overrides_runpath=yes
3751 hardcode_into_libs=yes
3752 # ldd complains unless libraries are executable
3753 postinstall_cmds='chmod +x $lib'
3758 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3759 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
3760 shlibpath_var=LD_LIBRARY_PATH
3761 shlibpath_overrides_runpath=yes
3762 if test "$with_gnu_ld" = yes; then
3769 version_type=linux # correct to gnu/linux during the next big refactor
3770 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3771 soname_spec='${libname}${release}${shared_ext}$major'
3772 shlibpath_var=LD_LIBRARY_PATH
3773 case $host_vendor in
3775 shlibpath_overrides_runpath=no
3777 runpath_var=LD_RUN_PATH
3785 shlibpath_overrides_runpath=no
3786 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
3792 if test -d /usr/nec ;then
3793 version_type=linux # correct to gnu/linux during the next big refactor
3794 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
3795 soname_spec='$libname${shared_ext}.$major'
3796 shlibpath_var=LD_LIBRARY_PATH
3800 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3801 version_type=freebsd-elf
3804 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3805 soname_spec='${libname}${release}${shared_ext}$major'
3806 shlibpath_var=LD_LIBRARY_PATH
3807 shlibpath_overrides_runpath=yes
3808 hardcode_into_libs=yes
3809 if test "$with_gnu_ld" = yes; then
3810 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
3812 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
3815 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
3819 sys_lib_dlsearch_path_spec='/usr/lib'
3823 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
3824 version_type=linux # correct to gnu/linux during the next big refactor
3827 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3828 shlibpath_var=LD_LIBRARY_PATH
3829 shlibpath_overrides_runpath=no
3830 hardcode_into_libs=yes
3834 version_type=linux # correct to gnu/linux during the next big refactor
3835 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3836 soname_spec='${libname}${release}${shared_ext}$major'
3837 shlibpath_var=LD_LIBRARY_PATH
3844 AC_MSG_RESULT([$dynamic_linker])
3845 test "$dynamic_linker" = no && can_build_shared=no
3847 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3848 if test "$GCC" = yes; then
3849 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3852 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
3853 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
3855 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
3856 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
3859 _LT_DECL([], [variables_saved_for_relink], [1],
3860 [Variables whose values should be saved in libtool wrapper scripts and
3861 restored at link time])
3862 _LT_DECL([], [need_lib_prefix], [0],
3863 [Do we need the "lib" prefix for modules?])
3864 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3865 _LT_DECL([], [version_type], [0], [Library versioning type])
3866 _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3867 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3868 _LT_DECL([], [shlibpath_overrides_runpath], [0],
3869 [Is shlibpath searched before the hard-coded library search path?])
3870 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3871 _LT_DECL([], [library_names_spec], [1],
3872 [[List of archive names. First name is the real one, the rest are links.
3873 The last name is the one that the linker finds with -lNAME]])
3874 _LT_DECL([], [soname_spec], [1],
3875 [[The coded name of the library, if different from the real name]])
3876 _LT_DECL([], [install_override_mode], [1],
3877 [Permission mode override for installation of shared libraries])
3878 _LT_DECL([], [postinstall_cmds], [2],
3879 [Command to use after installation of a shared archive])
3880 _LT_DECL([], [postuninstall_cmds], [2],
3881 [Command to use after uninstallation of a shared archive])
3882 _LT_DECL([], [finish_cmds], [2],
3883 [Commands used to finish a libtool library installation in a directory])
3884 _LT_DECL([], [finish_eval], [1],
3885 [[As "finish_cmds", except a single script fragment to be evaled but
3887 _LT_DECL([], [hardcode_into_libs], [0],
3888 [Whether we should hardcode library paths into libraries])
3889 _LT_DECL([], [sys_lib_search_path_spec], [2],
3890 [Compile-time system search path for libraries])
3891 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3892 [Run-time system search path for libraries])
3893 ])# _LT_SYS_DYNAMIC_LINKER
3896 # _LT_PATH_TOOL_PREFIX(TOOL)
3897 # --------------------------
3898 # find a file program which can recognize shared library
3899 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3900 [m4_require([_LT_DECL_EGREP])dnl
3901 AC_MSG_CHECKING([for $1])
3902 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3904 [[\\/*] | ?:[\\/]*])
3905 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3908 lt_save_MAGIC_CMD="$MAGIC_CMD"
3909 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3910 dnl $ac_dummy forces splitting on constant user-supplied paths.
3911 dnl POSIX.2 word splitting is done only on the output of word expansions,
3912 dnl not every word. This closes a longstanding sh security hole.
3913 ac_dummy="m4_if([$2], , $PATH, [$2])"
3914 for ac_dir in $ac_dummy; do
3916 test -z "$ac_dir" && ac_dir=.
3917 if test -f $ac_dir/$1; then
3918 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3919 if test -n "$file_magic_test_file"; then
3920 case $deplibs_check_method in
3922 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3923 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3924 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3925 $EGREP "$file_magic_regex" > /dev/null; then
3930 *** Warning: the command libtool uses to detect shared libraries,
3931 *** $file_magic_cmd, produces output that libtool cannot recognize.
3932 *** The result is that libtool may fail to recognize shared libraries
3933 *** as such. This will affect the creation of libtool libraries that
3934 *** depend on shared libraries, but programs linked with such libtool
3935 *** libraries will work regardless of this problem. Nevertheless, you
3936 *** may want to report the problem to your system manager and/or to
3937 *** bug-libtool@gnu.org
3947 MAGIC_CMD="$lt_save_MAGIC_CMD"
3950 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3951 if test -n "$MAGIC_CMD"; then
3952 AC_MSG_RESULT($MAGIC_CMD)
3956 _LT_DECL([], [MAGIC_CMD], [0],
3957 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3958 ])# _LT_PATH_TOOL_PREFIX
3961 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3962 dnl aclocal-1.4 backwards compatibility:
3963 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3968 # find a file program which can recognize a shared library
3969 m4_defun([_LT_PATH_MAGIC],
3970 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3971 if test -z "$lt_cv_path_MAGIC_CMD"; then
3972 if test -n "$ac_tool_prefix"; then
3973 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3983 # find the pathname to the GNU or non-GNU linker
3984 AC_DEFUN([LT_PATH_LD],
3985 [AC_REQUIRE([AC_PROG_CC])dnl
3986 AC_REQUIRE([AC_CANONICAL_HOST])dnl
3987 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3988 m4_require([_LT_DECL_SED])dnl
3989 m4_require([_LT_DECL_EGREP])dnl
3990 m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
3992 AC_ARG_WITH([gnu-ld],
3993 [AS_HELP_STRING([--with-gnu-ld],
3994 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3995 [test "$withval" = no || with_gnu_ld=yes],
3996 [with_gnu_ld=no])dnl
3999 if test "$GCC" = yes; then
4000 # Check if gcc -print-prog-name=ld gives a path.
4001 AC_MSG_CHECKING([for ld used by $CC])
4004 # gcc leaves a trailing carriage return which upsets mingw
4005 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4007 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4010 # Accept absolute paths.
4011 [[\\/]]* | ?:[[\\/]]*)
4012 re_direlt='/[[^/]][[^/]]*/\.\./'
4013 # Canonicalize the pathname of ld
4014 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4015 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4016 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4018 test -z "$LD" && LD="$ac_prog"
4021 # If it fails, then pretend we aren't using GCC.
4025 # If it is relative, then search for the first ld in PATH.
4029 elif test "$with_gnu_ld" = yes; then
4030 AC_MSG_CHECKING([for GNU ld])
4032 AC_MSG_CHECKING([for non-GNU ld])
4034 AC_CACHE_VAL(lt_cv_path_LD,
4035 [if test -z "$LD"; then
4036 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4037 for ac_dir in $PATH; do
4039 test -z "$ac_dir" && ac_dir=.
4040 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4041 lt_cv_path_LD="$ac_dir/$ac_prog"
4042 # Check to see if the program is GNU ld. I'd rather use --version,
4043 # but apparently some variants of GNU ld only accept -v.
4044 # Break only if it was the GNU/non-GNU ld that we prefer.
4045 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4046 *GNU* | *'with BFD'*)
4047 test "$with_gnu_ld" != no && break
4050 test "$with_gnu_ld" != yes && break
4057 lt_cv_path_LD="$LD" # Let the user override the test with a path.
4060 if test -n "$LD"; then
4065 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
4069 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
4073 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
4074 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
4075 dnl aclocal-1.4 backwards compatibility:
4076 dnl AC_DEFUN([AM_PROG_LD], [])
4077 dnl AC_DEFUN([AC_PROG_LD], [])
4082 m4_defun([_LT_PATH_LD_GNU],
4083 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
4084 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
4085 case `$LD -v 2>&1 </dev/null` in
4086 *GNU* | *'with BFD'*)
4087 lt_cv_prog_gnu_ld=yes
4090 lt_cv_prog_gnu_ld=no
4093 with_gnu_ld=$lt_cv_prog_gnu_ld
4099 # find reload flag for linker
4100 # -- PORTME Some linkers may need a different reload flag.
4101 m4_defun([_LT_CMD_RELOAD],
4102 [AC_CACHE_CHECK([for $LD option to reload object files],
4103 lt_cv_ld_reload_flag,
4104 [lt_cv_ld_reload_flag='-r'])
4105 reload_flag=$lt_cv_ld_reload_flag
4106 case $reload_flag in
4108 *) reload_flag=" $reload_flag" ;;
4110 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4112 cygwin* | mingw* | pw32* | cegcc*)
4113 if test "$GCC" != yes; then
4118 if test "$GCC" = yes; then
4119 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
4121 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4125 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
4126 _LT_TAGDECL([], [reload_cmds], [2])dnl
4130 # _LT_CHECK_MAGIC_METHOD
4131 # ----------------------
4132 # how to check for library dependencies
4133 # -- PORTME fill in with the dynamic library characteristics
4134 m4_defun([_LT_CHECK_MAGIC_METHOD],
4135 [m4_require([_LT_DECL_EGREP])
4136 m4_require([_LT_DECL_OBJDUMP])
4137 AC_CACHE_CHECK([how to recognize dependent libraries],
4138 lt_cv_deplibs_check_method,
4139 [lt_cv_file_magic_cmd='$MAGIC_CMD'
4140 lt_cv_file_magic_test_file=
4141 lt_cv_deplibs_check_method='unknown'
4142 # Need to set the preceding variable on all platforms that support
4143 # interlibrary dependencies.
4144 # 'none' -- dependencies not supported.
4145 # `unknown' -- same as none, but documents that we really don't know.
4146 # 'pass_all' -- all dependencies passed with no checks.
4147 # 'test_compile' -- check by making test program.
4148 # 'file_magic [[regex]]' -- check by looking for files in library path
4149 # which responds to the $file_magic_cmd with a given extended regex.
4150 # If you have `file' or equivalent on your system and you're not sure
4151 # whether `pass_all' will *always* work, you probably want this one.
4155 lt_cv_deplibs_check_method=pass_all
4159 lt_cv_deplibs_check_method=pass_all
4163 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
4164 lt_cv_file_magic_cmd='/usr/bin/file -L'
4165 lt_cv_file_magic_test_file=/shlib/libc.so
4169 # func_win32_libid is a shell function defined in ltmain.sh
4170 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4171 lt_cv_file_magic_cmd='func_win32_libid'
4175 # Base MSYS/MinGW do not provide the 'file' command needed by
4176 # func_win32_libid shell function, so use a weaker test based on 'objdump',
4177 # unless we find 'file', for example because we are cross-compiling.
4178 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
4179 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
4180 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
4181 lt_cv_file_magic_cmd='func_win32_libid'
4183 # Keep this pattern in sync with the one in func_win32_libid.
4184 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
4185 lt_cv_file_magic_cmd='$OBJDUMP -f'
4190 # use the weaker test based on 'objdump'. See mingw*.
4191 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
4192 lt_cv_file_magic_cmd='$OBJDUMP -f'
4195 darwin* | rhapsody*)
4196 lt_cv_deplibs_check_method=pass_all
4199 freebsd* | dragonfly*)
4200 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4203 # Not sure whether the presence of OpenBSD here was a mistake.
4204 # Let's accept both of them until this is cleared up.
4205 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
4206 lt_cv_file_magic_cmd=/usr/bin/file
4207 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4211 lt_cv_deplibs_check_method=pass_all
4216 lt_cv_deplibs_check_method=pass_all
4219 hpux10.20* | hpux11*)
4220 lt_cv_file_magic_cmd=/usr/bin/file
4223 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
4224 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
4227 [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]']
4228 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
4231 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
4232 lt_cv_file_magic_test_file=/usr/lib/libc.sl
4238 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
4239 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
4242 irix5* | irix6* | nonstopux*)
4244 *-32|*"-32 ") libmagic=32-bit;;
4245 *-n32|*"-n32 ") libmagic=N32;;
4246 *-64|*"-64 ") libmagic=64-bit;;
4247 *) libmagic=never-match;;
4249 lt_cv_deplibs_check_method=pass_all
4252 # This must be glibc/ELF.
4253 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4254 lt_cv_deplibs_check_method=pass_all
4257 netbsd* | netbsdelf*-gnu)
4258 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4259 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4261 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
4266 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
4267 lt_cv_file_magic_cmd=/usr/bin/file
4268 lt_cv_file_magic_test_file=/usr/lib/libnls.so
4272 lt_cv_deplibs_check_method=pass_all
4276 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4277 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
4279 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4283 osf3* | osf4* | osf5*)
4284 lt_cv_deplibs_check_method=pass_all
4288 lt_cv_deplibs_check_method=pass_all
4292 lt_cv_deplibs_check_method=pass_all
4295 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4296 lt_cv_deplibs_check_method=pass_all
4300 case $host_vendor in
4302 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]]'
4303 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
4306 lt_cv_deplibs_check_method=pass_all
4309 lt_cv_file_magic_cmd='/bin/file'
4310 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
4313 lt_cv_file_magic_cmd='/bin/file'
4314 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
4315 lt_cv_file_magic_test_file=/lib/libc.so
4318 lt_cv_deplibs_check_method=pass_all
4321 lt_cv_deplibs_check_method=pass_all
4327 lt_cv_deplibs_check_method=pass_all
4334 if test "$build" = "$host"; then
4337 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
4340 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
4346 file_magic_cmd=$lt_cv_file_magic_cmd
4347 deplibs_check_method=$lt_cv_deplibs_check_method
4348 test -z "$deplibs_check_method" && deplibs_check_method=unknown
4350 _LT_DECL([], [deplibs_check_method], [1],
4351 [Method to check whether dependent libraries are shared objects])
4352 _LT_DECL([], [file_magic_cmd], [1],
4353 [Command to use when deplibs_check_method = "file_magic"])
4354 _LT_DECL([], [file_magic_glob], [1],
4355 [How to find potential files when deplibs_check_method = "file_magic"])
4356 _LT_DECL([], [want_nocaseglob], [1],
4357 [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
4358 ])# _LT_CHECK_MAGIC_METHOD
4363 # find the pathname to a BSD- or MS-compatible name lister
4364 AC_DEFUN([LT_PATH_NM],
4365 [AC_REQUIRE([AC_PROG_CC])dnl
4366 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
4367 [if test -n "$NM"; then
4368 # Let the user override the test.
4371 lt_nm_to_check="${ac_tool_prefix}nm"
4372 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4373 lt_nm_to_check="$lt_nm_to_check nm"
4375 for lt_tmp_nm in $lt_nm_to_check; do
4376 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4377 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4379 test -z "$ac_dir" && ac_dir=.
4380 tmp_nm="$ac_dir/$lt_tmp_nm"
4381 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
4382 # Check to see if the nm accepts a BSD-compat flag.
4383 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4384 # nm: unknown option "B" ignored
4385 # Tru64's nm complains that /dev/null is an invalid object file
4386 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
4387 */dev/null* | *'Invalid file or object type'*)
4388 lt_cv_path_NM="$tmp_nm -B"
4392 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4394 lt_cv_path_NM="$tmp_nm -p"
4398 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4399 continue # so that we can try to find one that supports BSD flags
4408 : ${lt_cv_path_NM=no}
4410 if test "$lt_cv_path_NM" != "no"; then
4413 # Didn't find any BSD compatible name lister, look for dumpbin.
4414 if test -n "$DUMPBIN"; then :
4415 # Let the user override the test.
4417 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
4418 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
4420 DUMPBIN="$DUMPBIN -symbols"
4428 if test "$DUMPBIN" != ":"; then
4432 test -z "$NM" && NM=nm
4434 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
4436 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
4437 [lt_cv_nm_interface="BSD nm"
4438 echo "int some_variable = 0;" > conftest.$ac_ext
4439 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
4440 (eval "$ac_compile" 2>conftest.err)
4441 cat conftest.err >&AS_MESSAGE_LOG_FD
4442 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
4443 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4444 cat conftest.err >&AS_MESSAGE_LOG_FD
4445 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
4446 cat conftest.out >&AS_MESSAGE_LOG_FD
4447 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4448 lt_cv_nm_interface="MS dumpbin"
4454 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
4455 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
4456 dnl aclocal-1.4 backwards compatibility:
4457 dnl AC_DEFUN([AM_PROG_NM], [])
4458 dnl AC_DEFUN([AC_PROG_NM], [])
4460 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4461 # --------------------------------
4462 # how to determine the name of the shared library
4463 # associated with a specific link library.
4464 # -- PORTME fill in with the dynamic library characteristics
4465 m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
4466 [m4_require([_LT_DECL_EGREP])
4467 m4_require([_LT_DECL_OBJDUMP])
4468 m4_require([_LT_DECL_DLLTOOL])
4469 AC_CACHE_CHECK([how to associate runtime and link libraries],
4470 lt_cv_sharedlib_from_linklib_cmd,
4471 [lt_cv_sharedlib_from_linklib_cmd='unknown'
4474 cygwin* | mingw* | pw32* | cegcc*)
4475 # two different shell functions defined in ltmain.sh
4476 # decide which to use based on capabilities of $DLLTOOL
4477 case `$DLLTOOL --help 2>&1` in
4478 *--identify-strict*)
4479 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
4482 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
4487 # fallback: assume linklib IS sharedlib
4488 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
4492 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
4493 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
4495 _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
4496 [Command to associate shared and link libraries])
4497 ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
4500 # _LT_PATH_MANIFEST_TOOL
4501 # ----------------------
4502 # locate the manifest tool
4503 m4_defun([_LT_PATH_MANIFEST_TOOL],
4504 [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
4505 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
4506 AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
4507 [lt_cv_path_mainfest_tool=no
4508 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
4509 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
4510 cat conftest.err >&AS_MESSAGE_LOG_FD
4511 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
4512 lt_cv_path_mainfest_tool=yes
4515 if test "x$lt_cv_path_mainfest_tool" != xyes; then
4518 _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
4519 ])# _LT_PATH_MANIFEST_TOOL
4524 # check for math library
4525 AC_DEFUN([LT_LIB_M],
4526 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4529 *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
4530 # These system don't have libm, or don't need it
4533 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
4534 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
4537 AC_CHECK_LIB(m, cos, LIBM="-lm")
4544 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
4545 dnl aclocal-1.4 backwards compatibility:
4546 dnl AC_DEFUN([AC_CHECK_LIBM], [])
4549 # _LT_COMPILER_NO_RTTI([TAGNAME])
4550 # -------------------------------
4551 m4_defun([_LT_COMPILER_NO_RTTI],
4552 [m4_require([_LT_TAG_COMPILER])dnl
4554 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4556 if test "$GCC" = yes; then
4557 case $cc_basename in
4559 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
4561 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
4564 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4565 lt_cv_prog_compiler_rtti_exceptions,
4566 [-fno-rtti -fno-exceptions], [],
4567 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4569 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
4570 [Compiler flag to turn off builtin functions])
4571 ])# _LT_COMPILER_NO_RTTI
4574 # _LT_CMD_GLOBAL_SYMBOLS
4575 # ----------------------
4576 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
4577 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
4578 AC_REQUIRE([AC_PROG_CC])dnl
4579 AC_REQUIRE([AC_PROG_AWK])dnl
4580 AC_REQUIRE([LT_PATH_NM])dnl
4581 AC_REQUIRE([LT_PATH_LD])dnl
4582 m4_require([_LT_DECL_SED])dnl
4583 m4_require([_LT_DECL_EGREP])dnl
4584 m4_require([_LT_TAG_COMPILER])dnl
4586 # Check for command to grab the raw symbol name followed by C symbol from nm.
4587 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4588 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4590 # These are sane defaults that work on at least a few old systems.
4591 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4593 # Character class describing NM global symbol codes.
4594 symcode='[[BCDEGRST]]'
4596 # Regexp to match symbols that can be accessed directly from C.
4597 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4599 # Define system-specific variables.
4604 cygwin* | mingw* | pw32* | cegcc*)
4605 symcode='[[ABCDGISTW]]'
4608 if test "$host_cpu" = ia64; then
4609 symcode='[[ABCDEGRST]]'
4613 symcode='[[BCDEGRST]]'
4616 symcode='[[BCDEGQRST]]'
4627 sysv5* | sco5v6* | unixware* | OpenUNIX*)
4631 symcode='[[DFNSTU]]'
4635 # If we're using GNU nm, then use its standard symbol codes.
4636 case `$NM -V 2>&1` in
4637 *GNU* | *'with BFD'*)
4638 symcode='[[ABCDGIRSTW]]' ;;
4641 # Transform an extracted symbol line into a proper C declaration.
4642 # Some systems (esp. on ia64) link data and code symbols differently,
4643 # so use this general approach.
4644 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4646 # Transform an extracted symbol line into symbol name and symbol address
4647 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
4648 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'"
4650 # Handle CRLF in mingw tool chain
4654 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4658 # Try without a prefix underscore, then with it.
4659 for ac_symprfx in "" "_"; do
4661 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4662 symxfrm="\\1 $ac_symprfx\\2 \\2"
4664 # Write the raw and C identifiers.
4665 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4666 # Fake it for dumpbin and say T for any non-static function
4667 # and D for any global variable.
4668 # Also find C++ and __fastcall symbols from MSVC++,
4669 # which start with @ or ?.
4670 lt_cv_sys_global_symbol_pipe="$AWK ['"\
4671 " {last_section=section; section=\$ 3};"\
4672 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
4673 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
4674 " \$ 0!~/External *\|/{next};"\
4675 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
4676 " {if(hide[section]) next};"\
4677 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
4678 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
4679 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
4680 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
4681 " ' prfx=^$ac_symprfx]"
4683 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4685 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
4687 # Check to see that the pipe works correctly.
4691 cat > conftest.$ac_ext <<_LT_EOF
4696 void nm_test_func(void);
4697 void nm_test_func(void){}
4701 int main(){nm_test_var='a';nm_test_func();return(0);}
4704 if AC_TRY_EVAL(ac_compile); then
4705 # Now try to grab the symbols.
4707 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
4708 # Try sorting and uniquifying the output.
4709 if sort "$nlist" | uniq > "$nlist"T; then
4710 mv -f "$nlist"T "$nlist"
4715 # Make sure that we snagged all the symbols we need.
4716 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
4717 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
4718 cat <<_LT_EOF > conftest.$ac_ext
4719 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
4720 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
4721 /* DATA imports from DLLs on WIN32 con't be const, because runtime
4722 relocations are performed -- see ld's documentation on pseudo-relocs. */
4723 # define LT@&t@_DLSYM_CONST
4724 #elif defined(__osf__)
4725 /* This system does not cope well with relocations in const data. */
4726 # define LT@&t@_DLSYM_CONST
4728 # define LT@&t@_DLSYM_CONST const
4736 # Now generate the symbol file.
4737 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
4739 cat <<_LT_EOF >> conftest.$ac_ext
4741 /* The mapping between symbol names and symbols. */
4742 LT@&t@_DLSYM_CONST struct {
4746 lt__PROGRAM__LTX_preloaded_symbols[[]] =
4748 { "@PROGRAM@", (void *) 0 },
4750 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4751 cat <<\_LT_EOF >> conftest.$ac_ext
4755 /* This works around a problem in FreeBSD linker */
4756 #ifdef FREEBSD_WORKAROUND
4757 static const void *lt_preloaded_setup() {
4758 return lt__PROGRAM__LTX_preloaded_symbols;
4766 # Now try linking the two files.
4767 mv conftest.$ac_objext conftstm.$ac_objext
4768 lt_globsym_save_LIBS=$LIBS
4769 lt_globsym_save_CFLAGS=$CFLAGS
4770 LIBS="conftstm.$ac_objext"
4771 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4772 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4775 LIBS=$lt_globsym_save_LIBS
4776 CFLAGS=$lt_globsym_save_CFLAGS
4778 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4781 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4784 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4787 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4788 cat conftest.$ac_ext >&5
4790 rm -rf conftest* conftst*
4792 # Do not use the global_symbol_pipe unless it works.
4793 if test "$pipe_works" = yes; then
4796 lt_cv_sys_global_symbol_pipe=
4800 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4801 lt_cv_sys_global_symbol_to_cdecl=
4803 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4804 AC_MSG_RESULT(failed)
4809 # Response file support.
4810 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4811 nm_file_list_spec='@'
4812 elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
4813 nm_file_list_spec='@'
4816 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
4817 [Take the output of nm and produce a listing of raw symbols and C names])
4818 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
4819 [Transform the output of nm in a proper C declaration])
4820 _LT_DECL([global_symbol_to_c_name_address],
4821 [lt_cv_sys_global_symbol_to_c_name_address], [1],
4822 [Transform the output of nm in a C name address pair])
4823 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
4824 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
4825 [Transform the output of nm in a C name address pair when lib prefix is needed])
4826 _LT_DECL([], [nm_file_list_spec], [1],
4827 [Specify filename containing input files for $NM])
4828 ]) # _LT_CMD_GLOBAL_SYMBOLS
4831 # _LT_COMPILER_PIC([TAGNAME])
4832 # ---------------------------
4833 m4_defun([_LT_COMPILER_PIC],
4834 [m4_require([_LT_TAG_COMPILER])dnl
4835 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
4836 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4837 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4839 m4_if([$1], [CXX], [
4840 # C++ specific cases for pic, static, wl, etc.
4841 if test "$GXX" = yes; then
4842 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4843 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4847 # All AIX code is PIC.
4848 if test "$host_cpu" = ia64; then
4849 # AIX 5 now supports IA64 processor
4850 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4857 # see comment about AmigaOS4 .so support
4858 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4861 # FIXME: we need at least 68020 code to build shared libraries, but
4862 # adding the `-m68020' flag to GCC prevents building anything better,
4864 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4869 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4870 # PIC is the default for these OSes.
4872 mingw* | cygwin* | os2* | pw32* | cegcc*)
4873 # This hack is so that the source file can tell whether it is being
4874 # built for inclusion in a dll (and should export symbols for example).
4875 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4876 # (--disable-auto-import) libraries
4877 m4_if([$1], [GCJ], [],
4878 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4880 darwin* | rhapsody*)
4881 # PIC is the default on this platform
4882 # Common symbols not allowed in MH_DYLIB files
4883 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4886 # DJGPP does not support shared libraries at all
4887 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4890 # PIC is the default for Haiku.
4891 # The "-static" flag exists, but is broken.
4892 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4895 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4896 # Instead, we relocate shared libraries at runtime.
4899 if test -d /usr/nec; then
4900 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4904 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4905 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4906 # sets the default TLS model and affects inlining.
4911 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4916 # QNX uses GNU C++, but need to define -shared option too, otherwise
4918 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4921 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4927 # All AIX code is PIC.
4928 if test "$host_cpu" = ia64; then
4929 # AIX 5 now supports IA64 processor
4930 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4932 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4936 case $cc_basename in
4938 # Green Hills C++ Compiler
4939 # _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"
4943 mingw* | cygwin* | os2* | pw32* | cegcc*)
4944 # This hack is so that the source file can tell whether it is being
4945 # built for inclusion in a dll (and should export symbols for example).
4946 m4_if([$1], [GCJ], [],
4947 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4950 case $cc_basename in
4952 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4955 # Green Hills C++ Compiler
4956 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4962 freebsd* | dragonfly*)
4963 # FreeBSD uses GNU C++
4965 hpux9* | hpux10* | hpux11*)
4966 case $cc_basename in
4968 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4969 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4970 if test "$host_cpu" != ia64; then
4971 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4975 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4976 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4982 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4991 # This is c89, which is MS Visual C++ (no shared libs)
4992 # Anyone wants to do a port?
4994 irix5* | irix6* | nonstopux*)
4995 case $cc_basename in
4997 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4998 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4999 # CC pic flag -KPIC is the default.
5005 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
5006 case $cc_basename in
5009 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5010 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5013 # old Intel C++ for x86_64 which still supported -KPIC.
5014 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5015 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5016 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5019 # Intel C++, used to be incompatible with GCC.
5020 # ICC 10 doesn't accept -KPIC any more.
5021 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5022 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5023 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5026 # Portland Group C++ compiler
5027 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5028 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5029 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5033 # Make sure the PIC flag is empty. It appears that all Alpha
5034 # Linux and Compaq Tru64 Unix objects are PIC.
5035 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5036 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5038 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
5039 # IBM XL 8.0, 9.0 on PPC and BlueGene
5040 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5041 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5042 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5045 case `$CC -V 2>&1 | sed 5q` in
5048 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5049 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5050 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5061 case $cc_basename in
5063 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5069 netbsd* | netbsdelf*-gnu)
5072 # QNX uses GNU C++, but need to define -shared option too, otherwise
5074 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5076 osf3* | osf4* | osf5*)
5077 case $cc_basename in
5079 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5082 # Rational C++ 2.4.1
5083 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5086 # Digital/Compaq C++
5087 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5088 # Make sure the PIC flag is empty. It appears that all Alpha
5089 # Linux and Compaq Tru64 Unix objects are PIC.
5090 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5091 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5100 case $cc_basename in
5102 # Sun C++ 4.2, 5.x and Centerline C++
5103 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5104 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5105 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5108 # Green Hills C++ Compiler
5109 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5116 case $cc_basename in
5119 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5120 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5124 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5130 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5131 case $cc_basename in
5133 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5134 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5135 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5140 case $cc_basename in
5142 # NonStop-UX NCC 3.20
5143 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5152 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5158 if test "$GCC" = yes; then
5159 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5160 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5164 # All AIX code is PIC.
5165 if test "$host_cpu" = ia64; then
5166 # AIX 5 now supports IA64 processor
5167 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5174 # see comment about AmigaOS4 .so support
5175 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5178 # FIXME: we need at least 68020 code to build shared libraries, but
5179 # adding the `-m68020' flag to GCC prevents building anything better,
5181 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5186 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5187 # PIC is the default for these OSes.
5190 mingw* | cygwin* | pw32* | os2* | cegcc*)
5191 # This hack is so that the source file can tell whether it is being
5192 # built for inclusion in a dll (and should export symbols for example).
5193 # Although the cygwin gcc ignores -fPIC, still need this for old-style
5194 # (--disable-auto-import) libraries
5195 m4_if([$1], [GCJ], [],
5196 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5199 darwin* | rhapsody*)
5200 # PIC is the default on this platform
5201 # Common symbols not allowed in MH_DYLIB files
5202 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5206 # PIC is the default for Haiku.
5207 # The "-static" flag exists, but is broken.
5208 _LT_TAGVAR(lt_prog_compiler_static, $1)=
5212 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
5213 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
5214 # sets the default TLS model and affects inlining.
5220 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5226 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5227 # Instead, we relocate shared libraries at runtime.
5231 # Just because we use GCC doesn't mean we suddenly get shared libraries
5232 # on systems that don't support them.
5233 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5238 # QNX uses GNU C++, but need to define -shared option too, otherwise
5240 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5244 if test -d /usr/nec; then
5245 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5250 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5254 case $cc_basename in
5255 nvcc*) # Cuda Compiler Driver 2.2
5256 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
5257 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5258 _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
5263 # PORTME Check for flag to pass linker flags through the system compiler.
5266 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5267 if test "$host_cpu" = ia64; then
5268 # AIX 5 now supports IA64 processor
5269 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5271 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5275 mingw* | cygwin* | pw32* | os2* | cegcc*)
5276 # This hack is so that the source file can tell whether it is being
5277 # built for inclusion in a dll (and should export symbols for example).
5278 m4_if([$1], [GCJ], [],
5279 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5282 hpux9* | hpux10* | hpux11*)
5283 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5284 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5291 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5294 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5295 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5298 irix5* | irix6* | nonstopux*)
5299 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5300 # PIC (with -KPIC) is the default.
5301 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5304 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
5305 case $cc_basename in
5306 # old Intel for x86_64 which still supported -KPIC.
5308 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5309 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5310 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5312 # icc used to be incompatible with GCC.
5313 # ICC 10 doesn't accept -KPIC any more.
5315 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5316 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5317 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5319 # Lahey Fortran 8.1.
5321 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5322 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
5323 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
5326 # NAG Fortran compiler
5327 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
5328 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5329 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5331 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
5332 # Portland Group compilers (*not* the Pentium gcc compiler,
5333 # which looks to be a dead project)
5334 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5335 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5336 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5339 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5340 # All Alpha code is PIC.
5341 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5343 xl* | bgxl* | bgf* | mpixl*)
5344 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
5345 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5346 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
5347 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
5350 case `$CC -V 2>&1 | sed 5q` in
5351 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
5352 # Sun Fortran 8.3 passes all unrecognized flags to the linker
5353 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5354 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5355 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
5357 *Sun\ F* | *Sun*Fortran*)
5358 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5359 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5360 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5364 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5365 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5366 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5368 *Intel*\ [[CF]]*Compiler*)
5369 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5370 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5371 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
5374 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5375 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5376 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5384 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5385 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5389 # QNX uses GNU C++, but need to define -shared option too, otherwise
5391 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
5394 osf3* | osf4* | osf5*)
5395 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5396 # All OSF/1 code is PIC.
5397 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5401 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5405 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5406 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5407 case $cc_basename in
5408 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
5409 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5411 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5416 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5417 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5418 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5421 sysv4 | sysv4.2uw2* | sysv4.3*)
5422 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5423 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5424 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5428 if test -d /usr/nec ;then
5429 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5430 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5434 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5435 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5436 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5437 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5441 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5442 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5446 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5447 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5451 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5457 # For platforms which do not support PIC, -DPIC is meaningless:
5459 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
5462 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
5466 AC_CACHE_CHECK([for $compiler option to produce PIC],
5467 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
5468 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
5469 _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
5472 # Check to make sure the PIC flag actually works.
5474 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
5475 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
5476 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
5477 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
5478 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
5480 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5482 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
5483 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5485 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
5486 [Additional compiler flags for building library objects])
5488 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
5489 [How to pass a linker flag through the compiler])
5491 # Check to make sure the static flag actually works.
5493 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
5494 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
5495 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
5496 $lt_tmp_static_flag,
5498 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
5499 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
5500 [Compiler flag to prevent dynamic linking])
5501 ])# _LT_COMPILER_PIC
5504 # _LT_LINKER_SHLIBS([TAGNAME])
5505 # ----------------------------
5506 # See if the linker supports building shared libraries.
5507 m4_defun([_LT_LINKER_SHLIBS],
5508 [AC_REQUIRE([LT_PATH_LD])dnl
5509 AC_REQUIRE([LT_PATH_NM])dnl
5510 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5511 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5512 m4_require([_LT_DECL_EGREP])dnl
5513 m4_require([_LT_DECL_SED])dnl
5514 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
5515 m4_require([_LT_TAG_COMPILER])dnl
5516 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5517 m4_if([$1], [CXX], [
5518 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5519 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5522 # If we're using GNU nm, then we don't want the "-C" option.
5523 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5524 # Also, AIX nm treats weak defined symbols like other global defined
5525 # symbols, whereas GNU nm marks them as "W".
5526 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5527 _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'
5529 _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'
5533 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5535 cygwin* | mingw* | cegcc*)
5536 case $cc_basename in
5538 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5541 _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'
5542 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5546 linux* | k*bsd*-gnu | gnu*)
5547 _LT_TAGVAR(link_all_deplibs, $1)=no
5550 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5555 _LT_TAGVAR(allow_undefined_flag, $1)=
5556 _LT_TAGVAR(always_export_symbols, $1)=no
5557 _LT_TAGVAR(archive_cmds, $1)=
5558 _LT_TAGVAR(archive_expsym_cmds, $1)=
5559 _LT_TAGVAR(compiler_needs_object, $1)=no
5560 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5561 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5562 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5563 _LT_TAGVAR(hardcode_automatic, $1)=no
5564 _LT_TAGVAR(hardcode_direct, $1)=no
5565 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5566 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5567 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5568 _LT_TAGVAR(hardcode_minus_L, $1)=no
5569 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5570 _LT_TAGVAR(inherit_rpath, $1)=no
5571 _LT_TAGVAR(link_all_deplibs, $1)=unknown
5572 _LT_TAGVAR(module_cmds, $1)=
5573 _LT_TAGVAR(module_expsym_cmds, $1)=
5574 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
5575 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5576 _LT_TAGVAR(thread_safe_flag_spec, $1)=
5577 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5578 # include_expsyms should be a list of space-separated symbols to be *always*
5579 # included in the symbol list
5580 _LT_TAGVAR(include_expsyms, $1)=
5581 # exclude_expsyms can be an extended regexp of symbols to exclude
5582 # it will be wrapped by ` (' and `)$', so one must not match beginning or
5583 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5584 # as well as any symbol that contains `d'.
5585 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
5586 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5587 # platforms (ab)use it in PIC code, but their linkers get confused if
5588 # the symbol is explicitly referenced. Since portable code cannot
5589 # rely on this symbol name, it's probably fine to never include it in
5590 # preloaded symbol tables.
5591 # Exclude shared library initialization/finalization symbols.
5592 dnl Note also adjust exclude_expsyms for C++ above.
5593 extract_expsyms_cmds=
5596 cygwin* | mingw* | pw32* | cegcc*)
5597 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5598 # When not using gcc, we currently assume that we are using
5599 # Microsoft Visual C++.
5600 if test "$GCC" != yes; then
5605 # we just hope/assume this is gcc and not c89 (= MSVC++)
5611 linux* | k*bsd*-gnu | gnu*)
5612 _LT_TAGVAR(link_all_deplibs, $1)=no
5616 _LT_TAGVAR(ld_shlibs, $1)=yes
5618 # On some targets, GNU ld is compatible enough with the native linker
5619 # that we're better off using the native interface for both.
5620 lt_use_gnu_ld_interface=no
5621 if test "$with_gnu_ld" = yes; then
5624 # The AIX port of GNU ld has always aspired to compatibility
5625 # with the native linker. However, as the warning in the GNU ld
5626 # block says, versions before 2.19.5* couldn't really create working
5627 # shared libraries, regardless of the interface used.
5628 case `$LD -v 2>&1` in
5629 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
5630 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
5631 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
5633 lt_use_gnu_ld_interface=yes
5638 lt_use_gnu_ld_interface=yes
5643 if test "$lt_use_gnu_ld_interface" = yes; then
5644 # If archive_cmds runs LD, not CC, wlarc should be empty
5647 # Set some defaults for GNU ld with shared library support. These
5648 # are reset later if shared libraries are not supported. Putting them
5649 # here allows them to be overridden if necessary.
5650 runpath_var=LD_RUN_PATH
5651 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5652 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5653 # ancient GNU ld didn't support --whole-archive et. al.
5654 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
5655 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5657 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5659 supports_anon_versioning=no
5660 case `$LD -v 2>&1` in
5661 *GNU\ gold*) supports_anon_versioning=yes ;;
5662 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5663 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5664 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5665 *\ 2.11.*) ;; # other 2.11 versions
5666 *) supports_anon_versioning=yes ;;
5669 # See if GNU ld supports shared libraries.
5672 # On AIX/PPC, the GNU linker is very broken
5673 if test "$host_cpu" != ia64; then
5674 _LT_TAGVAR(ld_shlibs, $1)=no
5677 *** Warning: the GNU linker, at least up to release 2.19, is reported
5678 *** to be unable to reliably create shared libraries on AIX.
5679 *** Therefore, libtool is disabling shared libraries support. If you
5680 *** really care for shared libraries, you may want to install binutils
5681 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
5682 *** You will then need to restart the configuration process.
5691 # see comment about AmigaOS4 .so support
5692 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5693 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5696 _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)'
5697 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5698 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5704 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5705 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5706 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5707 # support --undefined. This deserves some investigation. FIXME
5708 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5710 _LT_TAGVAR(ld_shlibs, $1)=no
5714 cygwin* | mingw* | pw32* | cegcc*)
5715 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5716 # as there is no search path for DLLs.
5717 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5718 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
5719 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5720 _LT_TAGVAR(always_export_symbols, $1)=no
5721 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5722 _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'
5723 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5725 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5726 _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'
5727 # If the export-symbols file already is a .def file (1st line
5728 # is EXPORTS), use it as is; otherwise, prepend...
5729 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5730 cp $export_symbols $output_objdir/$soname.def;
5732 echo EXPORTS > $output_objdir/$soname.def;
5733 cat $export_symbols >> $output_objdir/$soname.def;
5735 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5737 _LT_TAGVAR(ld_shlibs, $1)=no
5742 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5743 _LT_TAGVAR(link_all_deplibs, $1)=yes
5747 _LT_TAGVAR(hardcode_direct, $1)=no
5748 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5749 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5750 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5751 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5752 # Instead, shared libraries are loaded at an image base (0x10000000 by
5753 # default) and relocated if they conflict, which is a slow very memory
5754 # consuming and fragmenting process. To avoid this, we pick a random,
5755 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
5756 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
5757 _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'
5758 _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'
5761 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
5763 if test "$host_os" = linux-dietlibc; then
5764 case $cc_basename in
5765 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
5768 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
5769 && test "$tmp_diet" = no
5771 tmp_addflag=' $pic_flag'
5772 tmp_sharedflag='-shared'
5773 case $cc_basename,$host_cpu in
5774 pgcc*) # Portland Group C compiler
5775 _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'
5776 tmp_addflag=' $pic_flag'
5778 pgf77* | pgf90* | pgf95* | pgfortran*)
5779 # Portland Group f77 and f90 compilers
5780 _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'
5781 tmp_addflag=' $pic_flag -Mnomain' ;;
5782 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5783 tmp_addflag=' -i_dynamic' ;;
5784 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5785 tmp_addflag=' -i_dynamic -nofor_main' ;;
5786 ifc* | ifort*) # Intel Fortran compiler
5787 tmp_addflag=' -nofor_main' ;;
5788 lf95*) # Lahey Fortran 8.1
5789 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5790 tmp_sharedflag='--shared' ;;
5791 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
5792 tmp_sharedflag='-qmkshrobj'
5794 nvcc*) # Cuda Compiler Driver 2.2
5795 _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'
5796 _LT_TAGVAR(compiler_needs_object, $1)=yes
5799 case `$CC -V 2>&1 | sed 5q` in
5800 *Sun\ C*) # Sun C 5.9
5801 _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'
5802 _LT_TAGVAR(compiler_needs_object, $1)=yes
5803 tmp_sharedflag='-G' ;;
5804 *Sun\ F*) # Sun Fortran 8.3
5805 tmp_sharedflag='-G' ;;
5807 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5809 if test "x$supports_anon_versioning" = xyes; then
5810 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5811 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5812 echo "local: *; };" >> $output_objdir/$libname.ver~
5813 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5816 case $cc_basename in
5817 xlf* | bgf* | bgxlf* | mpixlf*)
5818 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
5819 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
5820 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5821 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
5822 if test "x$supports_anon_versioning" = xyes; then
5823 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5824 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5825 echo "local: *; };" >> $output_objdir/$libname.ver~
5826 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5831 _LT_TAGVAR(ld_shlibs, $1)=no
5835 netbsd* | netbsdelf*-gnu)
5836 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5837 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5840 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5841 _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'
5846 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
5847 _LT_TAGVAR(ld_shlibs, $1)=no
5850 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5851 *** create shared libraries on Solaris systems. Therefore, libtool
5852 *** is disabling shared libraries support. We urge you to upgrade GNU
5853 *** binutils to release 2.9.1 or newer. Another option is to modify
5854 *** your PATH or compiler configuration so that the native linker is
5855 *** used, and then restart.
5858 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5859 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5860 _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'
5862 _LT_TAGVAR(ld_shlibs, $1)=no
5866 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5867 case `$LD -v 2>&1` in
5868 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5869 _LT_TAGVAR(ld_shlibs, $1)=no
5872 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
5873 *** reliably create shared libraries on SCO systems. Therefore, libtool
5874 *** is disabling shared libraries support. We urge you to upgrade GNU
5875 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5876 *** your PATH or compiler configuration so that the native linker is
5877 *** used, and then restart.
5882 # For security reasons, it is highly recommended that you always
5883 # use absolute paths for naming shared libraries, and exclude the
5884 # DT_RUNPATH tag from executables and libraries. But doing so
5885 # requires that you compile everything twice, which is a pain.
5886 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5887 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5888 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5889 _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'
5891 _LT_TAGVAR(ld_shlibs, $1)=no
5898 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5900 _LT_TAGVAR(hardcode_direct, $1)=yes
5901 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5905 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5906 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5907 _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'
5909 _LT_TAGVAR(ld_shlibs, $1)=no
5914 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
5916 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5917 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5918 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5921 # PORTME fill in a description of your system's linker (not GNU ld)
5924 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5925 _LT_TAGVAR(always_export_symbols, $1)=yes
5926 _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'
5927 # Note: this linker hardcodes the directories in LIBPATH if there
5928 # are no directories specified by -L.
5929 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5930 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5931 # Neither direct hardcoding nor static linking is supported with a
5933 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5938 if test "$host_cpu" = ia64; then
5939 # On IA64, the linker does run time linking by default, so we don't
5940 # have to do anything special.
5941 aix_use_runtimelinking=no
5942 exp_sym_flag='-Bexport'
5945 # If we're using GNU nm, then we don't want the "-C" option.
5946 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5947 # Also, AIX nm treats weak defined symbols like other global
5948 # defined symbols, whereas GNU nm marks them as "W".
5949 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5950 _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'
5952 _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'
5954 aix_use_runtimelinking=no
5956 # Test if we are trying to use run time linking or normal
5957 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5958 # need to do runtime linking.
5959 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5960 for ld_flag in $LDFLAGS; do
5961 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5962 aix_use_runtimelinking=yes
5969 exp_sym_flag='-bexport'
5970 no_entry_flag='-bnoentry'
5973 # When large executables or shared objects are built, AIX ld can
5974 # have problems creating the table of contents. If linking a library
5975 # or program results in "error TOC overflow" add -mminimal-toc to
5976 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5977 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5979 _LT_TAGVAR(archive_cmds, $1)=''
5980 _LT_TAGVAR(hardcode_direct, $1)=yes
5981 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5982 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5983 _LT_TAGVAR(link_all_deplibs, $1)=yes
5984 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5986 if test "$GCC" = yes; then
5987 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5988 # We only want to do this on AIX 4.2 and lower, the check
5989 # below for broken collect2 doesn't work under 4.3+
5990 collect2name=`${CC} -print-prog-name=collect2`
5991 if test -f "$collect2name" &&
5992 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5994 # We have reworked collect2
5997 # We have old collect2
5998 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5999 # It fails to find uninstalled libraries when the uninstalled
6000 # path is not listed in the libpath. Setting hardcode_minus_L
6001 # to unsupported forces relinking
6002 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6003 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6004 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6008 shared_flag='-shared'
6009 if test "$aix_use_runtimelinking" = yes; then
6010 shared_flag="$shared_flag "'${wl}-G'
6012 _LT_TAGVAR(link_all_deplibs, $1)=no
6015 if test "$host_cpu" = ia64; then
6016 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6017 # chokes on -Wl,-G. The following line is correct:
6020 if test "$aix_use_runtimelinking" = yes; then
6021 shared_flag='${wl}-G'
6023 shared_flag='${wl}-bM:SRE'
6028 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6029 # It seems that -bexpall does not export symbols beginning with
6030 # underscore (_), so it is better to generate a list of symbols to export.
6031 _LT_TAGVAR(always_export_symbols, $1)=yes
6032 if test "$aix_use_runtimelinking" = yes; then
6033 # Warning - without using the other runtime loading flags (-brtl),
6034 # -berok will link without error, but may produce a broken library.
6035 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6036 # Determine the default libpath from the value encoded in an
6038 _LT_SYS_MODULE_PATH_AIX([$1])
6039 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6040 _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"
6042 if test "$host_cpu" = ia64; then
6043 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6044 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6045 _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"
6047 # Determine the default libpath from the value encoded in an
6049 _LT_SYS_MODULE_PATH_AIX([$1])
6050 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6051 # Warning - without using the other run time loading flags,
6052 # -berok will link without error, but may produce a broken library.
6053 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6054 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6055 if test "$with_gnu_ld" = yes; then
6056 # We only use this code for GNU lds that support --whole-archive.
6057 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6059 # Exported symbols can be pulled into shared objects from archives
6060 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6062 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6063 # This is similar to how AIX traditionally builds its shared libraries.
6064 _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'
6072 # see comment about AmigaOS4 .so support
6073 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6074 _LT_TAGVAR(archive_expsym_cmds, $1)=''
6077 _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)'
6078 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6079 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6085 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6088 cygwin* | mingw* | pw32* | cegcc*)
6089 # When not using gcc, we currently assume that we are using
6090 # Microsoft Visual C++.
6091 # hardcode_libdir_flag_spec is actually meaningless, as there is
6092 # no search path for DLLs.
6093 case $cc_basename in
6096 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6097 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6098 _LT_TAGVAR(always_export_symbols, $1)=yes
6099 _LT_TAGVAR(file_list_spec, $1)='@'
6100 # Tell ltmain to make .lib files, not .a files.
6102 # Tell ltmain to make .dll files, not .so files.
6104 # FIXME: Setting linknames here is a bad hack.
6105 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
6106 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6107 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
6109 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
6111 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6113 # The linker will not automatically build a static lib if we build a DLL.
6114 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6115 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6116 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
6117 _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'
6119 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6120 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6121 lt_tool_outputfile="@TOOL_OUTPUT@"~
6122 case $lt_outputfile in
6125 lt_outputfile="$lt_outputfile.exe"
6126 lt_tool_outputfile="$lt_tool_outputfile.exe"
6129 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
6130 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6131 $RM "$lt_outputfile.manifest";
6135 # Assume MSVC wrapper
6136 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6137 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6138 # Tell ltmain to make .lib files, not .a files.
6140 # Tell ltmain to make .dll files, not .so files.
6142 # FIXME: Setting linknames here is a bad hack.
6143 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
6144 # The linker will automatically build a .lib file if we build a DLL.
6145 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6146 # FIXME: Should let the user specify the lib program.
6147 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6148 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6153 darwin* | rhapsody*)
6154 _LT_DARWIN_LINKER_FEATURES($1)
6158 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6159 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6160 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6163 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6164 # support. Future versions do this automatically, but an explicit c++rt0.o
6165 # does not break anything, and helps significantly (at the cost of a little
6168 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6169 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6170 _LT_TAGVAR(hardcode_direct, $1)=yes
6171 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6174 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6176 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6177 _LT_TAGVAR(hardcode_direct, $1)=yes
6178 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6179 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6182 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6183 freebsd* | dragonfly*)
6184 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6185 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6186 _LT_TAGVAR(hardcode_direct, $1)=yes
6187 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6191 if test "$GCC" = yes; then
6192 _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'
6194 _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'
6196 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6197 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6198 _LT_TAGVAR(hardcode_direct, $1)=yes
6200 # hardcode_minus_L: Not really in the search PATH,
6201 # but as the default location of the library.
6202 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6203 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6207 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
6208 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6210 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6212 if test "$with_gnu_ld" = no; then
6213 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6214 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6215 _LT_TAGVAR(hardcode_direct, $1)=yes
6216 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6217 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6218 # hardcode_minus_L: Not really in the search PATH,
6219 # but as the default location of the library.
6220 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6225 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
6228 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6231 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6234 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6240 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6243 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6247 # Older versions of the 11.00 compiler do not understand -b yet
6248 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
6249 _LT_LINKER_OPTION([if $CC understands -b],
6250 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
6251 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
6252 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
6253 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
6257 if test "$with_gnu_ld" = no; then
6258 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6259 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6263 _LT_TAGVAR(hardcode_direct, $1)=no
6264 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6267 _LT_TAGVAR(hardcode_direct, $1)=yes
6268 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6269 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6271 # hardcode_minus_L: Not really in the search PATH,
6272 # but as the default location of the library.
6273 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6279 irix5* | irix6* | nonstopux*)
6280 if test "$GCC" = yes; then
6281 _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'
6282 # Try to use the -exported_symbol ld option, if it does not
6283 # work, assume that -exports_file does not work either and
6284 # implicitly export all symbols.
6285 # This should be the same for all languages, so no per-tag cache variable.
6286 AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
6287 [lt_cv_irix_exported_symbol],
6288 [save_LDFLAGS="$LDFLAGS"
6289 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
6292 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
6293 [C++], [[int foo (void) { return 0; }]],
6300 [lt_cv_irix_exported_symbol=yes],
6301 [lt_cv_irix_exported_symbol=no])
6302 LDFLAGS="$save_LDFLAGS"])
6303 if test "$lt_cv_irix_exported_symbol" = yes; then
6304 _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'
6307 _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'
6308 _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'
6310 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6311 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6312 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6313 _LT_TAGVAR(inherit_rpath, $1)=yes
6314 _LT_TAGVAR(link_all_deplibs, $1)=yes
6317 netbsd* | netbsdelf*-gnu)
6318 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6319 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6321 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6323 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6324 _LT_TAGVAR(hardcode_direct, $1)=yes
6325 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6329 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6330 _LT_TAGVAR(hardcode_direct, $1)=yes
6331 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6332 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6333 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6340 if test -f /usr/libexec/ld.so; then
6341 _LT_TAGVAR(hardcode_direct, $1)=yes
6342 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6343 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6344 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6345 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6346 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6347 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6348 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6351 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6352 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6353 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6356 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6357 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6362 _LT_TAGVAR(ld_shlibs, $1)=no
6367 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6368 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6369 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6370 _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'
6371 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6375 if test "$GCC" = yes; then
6376 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6377 _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'
6379 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6380 _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'
6382 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6383 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6384 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6387 osf4* | osf5*) # as osf3* with the addition of -msym flag
6388 if test "$GCC" = yes; then
6389 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6390 _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'
6391 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6393 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6394 _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'
6395 _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~
6396 $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'
6398 # Both c and cxx compiler support -rpath directly
6399 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6401 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
6402 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6406 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
6407 if test "$GCC" = yes; then
6409 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6410 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6411 $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'
6413 case `$CC -V 2>&1` in
6416 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6417 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6418 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
6422 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
6423 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6424 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
6428 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6429 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6431 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6433 # The compiler driver will combine and reorder linker options,
6434 # but understands `-z linker_flag'. GCC discards it without `$wl',
6435 # but is careful enough not to reorder.
6436 # Supported since Solaris 2.6 (maybe 2.5.1?)
6437 if test "$GCC" = yes; then
6438 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6440 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6444 _LT_TAGVAR(link_all_deplibs, $1)=yes
6448 if test "x$host_vendor" = xsequent; then
6449 # Use $CC to link under sequent, because it throws in some extra .o
6450 # files that make .init and .fini sections work.
6451 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6453 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6455 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6456 _LT_TAGVAR(hardcode_direct, $1)=yes
6457 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6458 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6462 case $host_vendor in
6464 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6465 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6468 ## LD is ld it makes a PLAMLIB
6469 ## CC just makes a GrossModule.
6470 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6471 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6472 _LT_TAGVAR(hardcode_direct, $1)=no
6475 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6476 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6479 runpath_var='LD_RUN_PATH'
6480 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6484 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6485 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6486 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6490 if test -d /usr/nec; then
6491 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6492 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6493 runpath_var=LD_RUN_PATH
6494 hardcode_runpath_var=yes
6495 _LT_TAGVAR(ld_shlibs, $1)=yes
6499 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6500 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6501 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6502 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6503 runpath_var='LD_RUN_PATH'
6505 if test "$GCC" = yes; then
6506 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6507 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6509 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6510 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6514 sysv5* | sco3.2v5* | sco5v6*)
6515 # Note: We can NOT use -z defs as we might desire, because we do not
6516 # link with -lc, and that would cause any symbols used from libc to
6517 # always be unresolved, which means just about no library would
6518 # ever link correctly. If we're not using GNU ld we use -z text
6519 # though, which does catch some bad symbols but isn't as heavy-handed
6521 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6522 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6523 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6524 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6525 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6526 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6527 _LT_TAGVAR(link_all_deplibs, $1)=yes
6528 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6529 runpath_var='LD_RUN_PATH'
6531 if test "$GCC" = yes; then
6532 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6533 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6535 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6536 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6541 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6542 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6543 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6547 _LT_TAGVAR(ld_shlibs, $1)=no
6551 if test x$host_vendor = xsni; then
6553 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6554 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
6560 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6561 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6563 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
6565 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
6566 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
6567 _LT_DECL([], [extract_expsyms_cmds], [2],
6568 [The commands to extract the exported symbol list from a shared archive])
6571 # Do we need to explicitly link libc?
6573 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
6575 # Assume -lc should be added
6576 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6578 if test "$enable_shared" = yes && test "$GCC" = yes; then
6579 case $_LT_TAGVAR(archive_cmds, $1) in
6581 # FIXME: we may have to deal with multi-command sequences.
6584 # Test whether the compiler implicitly links with -lc since on some
6585 # systems, -lgcc has to come before -lc. If gcc already passes -lc
6586 # to ld, don't add -lc before -lgcc.
6587 AC_CACHE_CHECK([whether -lc should be explicitly linked in],
6588 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
6590 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6592 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6595 libobjs=conftest.$ac_objext
6597 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
6598 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
6604 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
6605 _LT_TAGVAR(allow_undefined_flag, $1)=
6606 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
6608 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6610 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6612 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6614 cat conftest.err 1>&5
6618 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
6625 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
6626 [Whether or not to add -lc for building shared libraries])
6627 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
6628 [enable_shared_with_static_runtimes], [0],
6629 [Whether or not to disallow shared libs when runtime libs are static])
6630 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
6631 [Compiler flag to allow reflexive dlopens])
6632 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
6633 [Compiler flag to generate shared objects directly from archives])
6634 _LT_TAGDECL([], [compiler_needs_object], [1],
6635 [Whether the compiler copes with passing no objects directly])
6636 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
6637 [Create an old-style archive from a shared archive])
6638 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
6639 [Create a temporary old-style archive to link instead of a shared archive])
6640 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
6641 _LT_TAGDECL([], [archive_expsym_cmds], [2])
6642 _LT_TAGDECL([], [module_cmds], [2],
6643 [Commands used to build a loadable module if different from building
6645 _LT_TAGDECL([], [module_expsym_cmds], [2])
6646 _LT_TAGDECL([], [with_gnu_ld], [1],
6647 [Whether we are building with GNU ld or not])
6648 _LT_TAGDECL([], [allow_undefined_flag], [1],
6649 [Flag that allows shared libraries with undefined symbols to be built])
6650 _LT_TAGDECL([], [no_undefined_flag], [1],
6651 [Flag that enforces no undefined symbols])
6652 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
6653 [Flag to hardcode $libdir into a binary during linking.
6654 This must work even if $libdir does not exist])
6655 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
6656 [Whether we need a single "-rpath" flag with a separated argument])
6657 _LT_TAGDECL([], [hardcode_direct], [0],
6658 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6659 DIR into the resulting binary])
6660 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
6661 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6662 DIR into the resulting binary and the resulting library dependency is
6663 "absolute", i.e impossible to change by setting ${shlibpath_var} if the
6664 library is relocated])
6665 _LT_TAGDECL([], [hardcode_minus_L], [0],
6666 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
6667 into the resulting binary])
6668 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
6669 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
6670 into the resulting binary])
6671 _LT_TAGDECL([], [hardcode_automatic], [0],
6672 [Set to "yes" if building a shared library automatically hardcodes DIR
6673 into the library and all subsequent libraries and executables linked
6675 _LT_TAGDECL([], [inherit_rpath], [0],
6676 [Set to yes if linker adds runtime paths of dependent libraries
6677 to runtime path list])
6678 _LT_TAGDECL([], [link_all_deplibs], [0],
6679 [Whether libtool must link a program against all its dependency libraries])
6680 _LT_TAGDECL([], [always_export_symbols], [0],
6681 [Set to "yes" if exported symbols are required])
6682 _LT_TAGDECL([], [export_symbols_cmds], [2],
6683 [The commands to list exported symbols])
6684 _LT_TAGDECL([], [exclude_expsyms], [1],
6685 [Symbols that should not be listed in the preloaded symbols])
6686 _LT_TAGDECL([], [include_expsyms], [1],
6687 [Symbols that must always be exported])
6688 _LT_TAGDECL([], [prelink_cmds], [2],
6689 [Commands necessary for linking programs (against libraries) with templates])
6690 _LT_TAGDECL([], [postlink_cmds], [2],
6691 [Commands necessary for finishing linking programs])
6692 _LT_TAGDECL([], [file_list_spec], [1],
6693 [Specify filename containing input files])
6694 dnl FIXME: Not yet implemented
6695 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
6696 dnl [Compiler flag to generate thread safe objects])
6697 ])# _LT_LINKER_SHLIBS
6700 # _LT_LANG_C_CONFIG([TAG])
6701 # ------------------------
6702 # Ensure that the configuration variables for a C compiler are suitably
6703 # defined. These variables are subsequently used by _LT_CONFIG to write
6704 # the compiler configuration to `libtool'.
6705 m4_defun([_LT_LANG_C_CONFIG],
6706 [m4_require([_LT_DECL_EGREP])dnl
6710 # Source file extension for C test sources.
6713 # Object file extension for compiled C test sources.
6715 _LT_TAGVAR(objext, $1)=$objext
6717 # Code to be used in simple compile tests
6718 lt_simple_compile_test_code="int some_variable = 0;"
6720 # Code to be used in simple link tests
6721 lt_simple_link_test_code='int main(){return(0);}'
6724 # Save the default compiler, since it gets overwritten when the other
6725 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
6726 compiler_DEFAULT=$CC
6728 # save warnings/boilerplate of simple test code
6729 _LT_COMPILER_BOILERPLATE
6730 _LT_LINKER_BOILERPLATE
6732 if test -n "$compiler"; then
6733 _LT_COMPILER_NO_RTTI($1)
6734 _LT_COMPILER_PIC($1)
6735 _LT_COMPILER_C_O($1)
6736 _LT_COMPILER_FILE_LOCKS($1)
6737 _LT_LINKER_SHLIBS($1)
6738 _LT_SYS_DYNAMIC_LINKER($1)
6739 _LT_LINKER_HARDCODE_LIBPATH($1)
6743 # Report which library types will actually be built
6744 AC_MSG_CHECKING([if libtool supports shared libraries])
6745 AC_MSG_RESULT([$can_build_shared])
6747 AC_MSG_CHECKING([whether to build shared libraries])
6748 test "$can_build_shared" = "no" && enable_shared=no
6750 # On AIX, shared libraries and static libraries use the same namespace, and
6751 # are all built from PIC.
6754 test "$enable_shared" = yes && enable_static=no
6755 if test -n "$RANLIB"; then
6756 archive_cmds="$archive_cmds~\$RANLIB \$lib"
6757 postinstall_cmds='$RANLIB $lib'
6762 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
6763 test "$enable_shared" = yes && enable_static=no
6767 AC_MSG_RESULT([$enable_shared])
6769 AC_MSG_CHECKING([whether to build static libraries])
6770 # Make sure either enable_shared or enable_static is yes.
6771 test "$enable_shared" = yes || enable_static=yes
6772 AC_MSG_RESULT([$enable_static])
6778 ])# _LT_LANG_C_CONFIG
6781 # _LT_LANG_CXX_CONFIG([TAG])
6782 # --------------------------
6783 # Ensure that the configuration variables for a C++ compiler are suitably
6784 # defined. These variables are subsequently used by _LT_CONFIG to write
6785 # the compiler configuration to `libtool'.
6786 m4_defun([_LT_LANG_CXX_CONFIG],
6787 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6788 m4_require([_LT_DECL_EGREP])dnl
6789 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
6790 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
6791 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
6792 (test "X$CXX" != "Xg++"))) ; then
6795 _lt_caught_CXX_error=yes
6799 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6800 _LT_TAGVAR(allow_undefined_flag, $1)=
6801 _LT_TAGVAR(always_export_symbols, $1)=no
6802 _LT_TAGVAR(archive_expsym_cmds, $1)=
6803 _LT_TAGVAR(compiler_needs_object, $1)=no
6804 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
6805 _LT_TAGVAR(hardcode_direct, $1)=no
6806 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6807 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6808 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6809 _LT_TAGVAR(hardcode_minus_L, $1)=no
6810 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6811 _LT_TAGVAR(hardcode_automatic, $1)=no
6812 _LT_TAGVAR(inherit_rpath, $1)=no
6813 _LT_TAGVAR(module_cmds, $1)=
6814 _LT_TAGVAR(module_expsym_cmds, $1)=
6815 _LT_TAGVAR(link_all_deplibs, $1)=unknown
6816 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
6817 _LT_TAGVAR(reload_flag, $1)=$reload_flag
6818 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6819 _LT_TAGVAR(no_undefined_flag, $1)=
6820 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6821 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6823 # Source file extension for C++ test sources.
6826 # Object file extension for compiled C++ test sources.
6828 _LT_TAGVAR(objext, $1)=$objext
6830 # No sense in running all these tests if we already determined that
6831 # the CXX compiler isn't working. Some variables (like enable_shared)
6832 # are currently assumed to apply to all compilers on this platform,
6833 # and will be corrupted by setting them based on a non-working compiler.
6834 if test "$_lt_caught_CXX_error" != yes; then
6835 # Code to be used in simple compile tests
6836 lt_simple_compile_test_code="int some_variable = 0;"
6838 # Code to be used in simple link tests
6839 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
6841 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
6844 # save warnings/boilerplate of simple test code
6845 _LT_COMPILER_BOILERPLATE
6846 _LT_LINKER_BOILERPLATE
6848 # Allow CC to be a program name with arguments.
6850 lt_save_CFLAGS=$CFLAGS
6854 lt_save_with_gnu_ld=$with_gnu_ld
6855 lt_save_path_LD=$lt_cv_path_LD
6856 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
6857 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
6859 $as_unset lt_cv_prog_gnu_ld
6861 if test -n "${lt_cv_path_LDCXX+set}"; then
6862 lt_cv_path_LD=$lt_cv_path_LDCXX
6864 $as_unset lt_cv_path_LD
6866 test -z "${LDCXX+set}" || LD=$LDCXX
6870 _LT_TAGVAR(compiler, $1)=$CC
6871 _LT_CC_BASENAME([$compiler])
6873 if test -n "$compiler"; then
6874 # We don't want -fno-exception when compiling C++ code, so set the
6875 # no_builtin_flag separately
6876 if test "$GXX" = yes; then
6877 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
6879 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
6882 if test "$GXX" = yes; then
6883 # Set up default GNU C++ configuration
6887 # Check if GNU C++ uses GNU ld as the underlying linker, since the
6888 # archiving commands below assume that GNU ld is being used.
6889 if test "$with_gnu_ld" = yes; then
6890 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6891 _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'
6893 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6894 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6896 # If archive_cmds runs LD, not CC, wlarc should be empty
6897 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
6898 # investigate it a little bit more. (MM)
6901 # ancient GNU ld didn't support --whole-archive et. al.
6902 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
6903 $GREP 'no-whole-archive' > /dev/null; then
6904 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6906 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6912 # A generic and very simple default shared library creation
6913 # command for GNU C++ for the case where it uses the native
6914 # linker, instead of GNU ld. If possible, this setting should
6915 # overridden to take advantage of the native linker features on
6916 # the platform it is being used on.
6917 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6920 # Commands to make compiler produce verbose output that lists
6921 # what "hidden" libraries, object files and flags are used when
6922 # linking a shared library.
6923 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6931 # PORTME: fill in a description of your system's C++ link characteristics
6932 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6933 _LT_TAGVAR(ld_shlibs, $1)=yes
6936 # FIXME: insert proper C++ library support
6937 _LT_TAGVAR(ld_shlibs, $1)=no
6940 if test "$host_cpu" = ia64; then
6941 # On IA64, the linker does run time linking by default, so we don't
6942 # have to do anything special.
6943 aix_use_runtimelinking=no
6944 exp_sym_flag='-Bexport'
6947 aix_use_runtimelinking=no
6949 # Test if we are trying to use run time linking or normal
6950 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6951 # need to do runtime linking.
6952 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6953 for ld_flag in $LDFLAGS; do
6956 aix_use_runtimelinking=yes
6964 exp_sym_flag='-bexport'
6965 no_entry_flag='-bnoentry'
6968 # When large executables or shared objects are built, AIX ld can
6969 # have problems creating the table of contents. If linking a library
6970 # or program results in "error TOC overflow" add -mminimal-toc to
6971 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6972 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6974 _LT_TAGVAR(archive_cmds, $1)=''
6975 _LT_TAGVAR(hardcode_direct, $1)=yes
6976 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6977 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6978 _LT_TAGVAR(link_all_deplibs, $1)=yes
6979 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6981 if test "$GXX" = yes; then
6982 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6983 # We only want to do this on AIX 4.2 and lower, the check
6984 # below for broken collect2 doesn't work under 4.3+
6985 collect2name=`${CC} -print-prog-name=collect2`
6986 if test -f "$collect2name" &&
6987 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6989 # We have reworked collect2
6992 # We have old collect2
6993 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6994 # It fails to find uninstalled libraries when the uninstalled
6995 # path is not listed in the libpath. Setting hardcode_minus_L
6996 # to unsupported forces relinking
6997 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6998 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6999 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7002 shared_flag='-shared'
7003 if test "$aix_use_runtimelinking" = yes; then
7004 shared_flag="$shared_flag "'${wl}-G'
7008 if test "$host_cpu" = ia64; then
7009 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
7010 # chokes on -Wl,-G. The following line is correct:
7013 if test "$aix_use_runtimelinking" = yes; then
7014 shared_flag='${wl}-G'
7016 shared_flag='${wl}-bM:SRE'
7021 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
7022 # It seems that -bexpall does not export symbols beginning with
7023 # underscore (_), so it is better to generate a list of symbols to
7025 _LT_TAGVAR(always_export_symbols, $1)=yes
7026 if test "$aix_use_runtimelinking" = yes; then
7027 # Warning - without using the other runtime loading flags (-brtl),
7028 # -berok will link without error, but may produce a broken library.
7029 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
7030 # Determine the default libpath from the value encoded in an empty
7032 _LT_SYS_MODULE_PATH_AIX([$1])
7033 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7035 _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"
7037 if test "$host_cpu" = ia64; then
7038 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
7039 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7040 _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"
7042 # Determine the default libpath from the value encoded in an
7044 _LT_SYS_MODULE_PATH_AIX([$1])
7045 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7046 # Warning - without using the other run time loading flags,
7047 # -berok will link without error, but may produce a broken library.
7048 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
7049 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
7050 if test "$with_gnu_ld" = yes; then
7051 # We only use this code for GNU lds that support --whole-archive.
7052 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7054 # Exported symbols can be pulled into shared objects from archives
7055 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
7057 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
7058 # This is similar to how AIX traditionally builds its shared
7060 _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'
7066 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
7067 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7068 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
7069 # support --undefined. This deserves some investigation. FIXME
7070 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7072 _LT_TAGVAR(ld_shlibs, $1)=no
7077 case $cc_basename in
7079 # FIXME: insert proper C++ library support
7080 _LT_TAGVAR(ld_shlibs, $1)=no
7085 cygwin* | mingw* | pw32* | cegcc*)
7086 case $GXX,$cc_basename in
7089 # hardcode_libdir_flag_spec is actually meaningless, as there is
7090 # no search path for DLLs.
7091 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
7092 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7093 _LT_TAGVAR(always_export_symbols, $1)=yes
7094 _LT_TAGVAR(file_list_spec, $1)='@'
7095 # Tell ltmain to make .lib files, not .a files.
7097 # Tell ltmain to make .dll files, not .so files.
7099 # FIXME: Setting linknames here is a bad hack.
7100 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
7101 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7102 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
7104 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
7106 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
7108 # The linker will not automatically build a static lib if we build a DLL.
7109 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
7110 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7112 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
7113 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
7114 lt_tool_outputfile="@TOOL_OUTPUT@"~
7115 case $lt_outputfile in
7118 lt_outputfile="$lt_outputfile.exe"
7119 lt_tool_outputfile="$lt_tool_outputfile.exe"
7122 func_to_tool_file "$lt_outputfile"~
7123 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
7124 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
7125 $RM "$lt_outputfile.manifest";
7130 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
7131 # as there is no search path for DLLs.
7132 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7133 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
7134 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
7135 _LT_TAGVAR(always_export_symbols, $1)=no
7136 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
7138 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
7139 _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'
7140 # If the export-symbols file already is a .def file (1st line
7141 # is EXPORTS), use it as is; otherwise, prepend...
7142 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
7143 cp $export_symbols $output_objdir/$soname.def;
7145 echo EXPORTS > $output_objdir/$soname.def;
7146 cat $export_symbols >> $output_objdir/$soname.def;
7148 $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'
7150 _LT_TAGVAR(ld_shlibs, $1)=no
7155 darwin* | rhapsody*)
7156 _LT_DARWIN_LINKER_FEATURES($1)
7160 case $cc_basename in
7162 # FIXME: insert proper C++ library support
7163 _LT_TAGVAR(ld_shlibs, $1)=no
7166 # Green Hills C++ Compiler
7167 # FIXME: insert proper C++ library support
7168 _LT_TAGVAR(ld_shlibs, $1)=no
7171 # FIXME: insert proper C++ library support
7172 _LT_TAGVAR(ld_shlibs, $1)=no
7178 # C++ shared libraries reported to be fairly broken before
7180 _LT_TAGVAR(ld_shlibs, $1)=no
7184 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7187 freebsd* | dragonfly*)
7188 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
7190 _LT_TAGVAR(ld_shlibs, $1)=yes
7194 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7195 _LT_TAGVAR(link_all_deplibs, $1)=yes
7199 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7200 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7201 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7202 _LT_TAGVAR(hardcode_direct, $1)=yes
7203 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7204 # but as the default
7205 # location of the library.
7207 case $cc_basename in
7209 # FIXME: insert proper C++ library support
7210 _LT_TAGVAR(ld_shlibs, $1)=no
7213 _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'
7214 # Commands to make compiler produce verbose output that lists
7215 # what "hidden" libraries, object files and flags are used when
7216 # linking a shared library.
7218 # There doesn't appear to be a way to prevent this compiler from
7219 # explicitly linking system object files so we need to strip them
7220 # from the output so that they don't get included in the library
7222 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"'
7225 if test "$GXX" = yes; then
7226 _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'
7228 # FIXME: insert proper C++ library support
7229 _LT_TAGVAR(ld_shlibs, $1)=no
7236 if test $with_gnu_ld = no; then
7237 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7238 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7244 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7250 _LT_TAGVAR(hardcode_direct, $1)=no
7251 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7254 _LT_TAGVAR(hardcode_direct, $1)=yes
7255 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7256 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
7257 # but as the default
7258 # location of the library.
7262 case $cc_basename in
7264 # FIXME: insert proper C++ library support
7265 _LT_TAGVAR(ld_shlibs, $1)=no
7270 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7273 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7276 _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'
7279 # Commands to make compiler produce verbose output that lists
7280 # what "hidden" libraries, object files and flags are used when
7281 # linking a shared library.
7283 # There doesn't appear to be a way to prevent this compiler from
7284 # explicitly linking system object files so we need to strip them
7285 # from the output so that they don't get included in the library
7287 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"'
7290 if test "$GXX" = yes; then
7291 if test $with_gnu_ld = no; then
7294 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7297 _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'
7300 _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'
7305 # FIXME: insert proper C++ library support
7306 _LT_TAGVAR(ld_shlibs, $1)=no
7313 _LT_TAGVAR(hardcode_direct, $1)=no
7314 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7315 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7316 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7317 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
7318 # Instead, shared libraries are loaded at an image base (0x10000000 by
7319 # default) and relocated if they conflict, which is a slow very memory
7320 # consuming and fragmenting process. To avoid this, we pick a random,
7321 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
7322 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
7323 _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'
7324 _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'
7327 case $cc_basename in
7330 _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'
7332 # Archives containing C++ object files must be created using
7333 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
7334 # necessary to make sure instantiated templates are included
7336 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
7339 if test "$GXX" = yes; then
7340 if test "$with_gnu_ld" = no; then
7341 _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'
7343 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
7346 _LT_TAGVAR(link_all_deplibs, $1)=yes
7349 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7350 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7351 _LT_TAGVAR(inherit_rpath, $1)=yes
7354 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
7355 case $cc_basename in
7357 # Kuck and Associates, Inc. (KAI) C++ Compiler
7359 # KCC will only create a shared library if the output file
7360 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7361 # to its proper name (with version) after linking.
7362 _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'
7363 _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'
7364 # Commands to make compiler produce verbose output that lists
7365 # what "hidden" libraries, object files and flags are used when
7366 # linking a shared library.
7368 # There doesn't appear to be a way to prevent this compiler from
7369 # explicitly linking system object files so we need to strip them
7370 # from the output so that they don't get included in the library
7372 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"'
7374 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7375 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7377 # Archives containing C++ object files must be created using
7378 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
7379 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
7384 # version 8.0 and above of icpc choke on multiply defined symbols
7385 # if we add $predep_objects and $postdep_objects, however 7.1 and
7386 # earlier do not add the objects themselves.
7387 case `$CC -V 2>&1` in
7389 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7390 _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'
7392 *) # Version 8.0 or newer
7395 ia64*) tmp_idyn=' -i_dynamic';;
7397 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7398 _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'
7401 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7402 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7403 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7404 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
7407 # Portland Group C++ compiler
7409 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
7410 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
7412 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
7413 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
7414 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
7416 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
7417 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
7419 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
7421 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7422 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7423 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
7425 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7426 $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'
7428 *) # Version 6 and above use weak symbols
7429 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
7430 _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'
7434 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
7435 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7436 _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'
7440 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7441 _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'
7443 runpath_var=LD_RUN_PATH
7444 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7445 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7447 # Commands to make compiler produce verbose output that lists
7448 # what "hidden" libraries, object files and flags are used when
7449 # linking a shared library.
7451 # There doesn't appear to be a way to prevent this compiler from
7452 # explicitly linking system object files so we need to strip them
7453 # from the output so that they don't get included in the library
7455 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'
7457 xl* | mpixl* | bgxl*)
7458 # IBM XL 8.0 on PPC, with GNU ld
7459 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7460 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7461 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7462 if test "x$supports_anon_versioning" = xyes; then
7463 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
7464 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7465 echo "local: *; };" >> $output_objdir/$libname.ver~
7466 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
7470 case `$CC -V 2>&1 | sed 5q` in
7473 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7474 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7475 _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'
7476 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7477 _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'
7478 _LT_TAGVAR(compiler_needs_object, $1)=yes
7480 # Not sure whether something based on
7481 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
7483 output_verbose_link_cmd='func_echo_all'
7485 # Archives containing C++ object files must be created using
7486 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7487 # necessary to make sure instantiated templates are included
7489 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7497 # FIXME: insert proper C++ library support
7498 _LT_TAGVAR(ld_shlibs, $1)=no
7502 # FIXME: insert proper C++ library support
7503 _LT_TAGVAR(ld_shlibs, $1)=no
7507 case $cc_basename in
7509 # FIXME: insert proper C++ library support
7510 _LT_TAGVAR(ld_shlibs, $1)=no
7513 # FIXME: insert proper C++ library support
7514 _LT_TAGVAR(ld_shlibs, $1)=no
7520 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7521 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
7523 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7524 _LT_TAGVAR(hardcode_direct, $1)=yes
7525 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7527 # Workaround some broken pre-1.5 toolchains
7528 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
7532 _LT_TAGVAR(ld_shlibs, $1)=yes
7536 # C++ shared libraries are fairly broken
7537 _LT_TAGVAR(ld_shlibs, $1)=no
7541 if test -f /usr/libexec/ld.so; then
7542 _LT_TAGVAR(hardcode_direct, $1)=yes
7543 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7544 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7545 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7546 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7547 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7548 _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'
7549 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7550 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7552 output_verbose_link_cmd=func_echo_all
7554 _LT_TAGVAR(ld_shlibs, $1)=no
7558 osf3* | osf4* | osf5*)
7559 case $cc_basename in
7561 # Kuck and Associates, Inc. (KAI) C++ Compiler
7563 # KCC will only create a shared library if the output file
7564 # ends with ".so" (or ".sl" for HP-UX), so rename the library
7565 # to its proper name (with version) after linking.
7566 _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'
7568 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7569 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7571 # Archives containing C++ object files must be created using
7572 # the KAI C++ compiler.
7574 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
7575 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
7579 # Rational C++ 2.4.1
7580 # FIXME: insert proper C++ library support
7581 _LT_TAGVAR(ld_shlibs, $1)=no
7586 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7587 _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'
7588 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7591 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7592 _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'
7593 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
7594 echo "-hidden">> $lib.exp~
7595 $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~
7597 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7601 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7603 # Commands to make compiler produce verbose output that lists
7604 # what "hidden" libraries, object files and flags are used when
7605 # linking a shared library.
7607 # There doesn't appear to be a way to prevent this compiler from
7608 # explicitly linking system object files so we need to strip them
7609 # from the output so that they don't get included in the library
7611 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"'
7614 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7615 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7618 _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'
7621 _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'
7625 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7626 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7628 # Commands to make compiler produce verbose output that lists
7629 # what "hidden" libraries, object files and flags are used when
7630 # linking a shared library.
7631 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7634 # FIXME: insert proper C++ library support
7635 _LT_TAGVAR(ld_shlibs, $1)=no
7642 # FIXME: insert proper C++ library support
7643 _LT_TAGVAR(ld_shlibs, $1)=no
7647 case $cc_basename in
7650 # FIXME: insert proper C++ library support
7651 _LT_TAGVAR(ld_shlibs, $1)=no
7655 # FIXME: insert proper C++ library support
7656 _LT_TAGVAR(ld_shlibs, $1)=no
7659 # FIXME: insert proper C++ library support
7660 _LT_TAGVAR(ld_shlibs, $1)=no
7666 case $cc_basename in
7668 # Sun C++ 4.2, 5.x and Centerline C++
7669 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
7670 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7671 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7672 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7673 $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'
7675 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7676 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7678 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7680 # The compiler driver will combine and reorder linker options,
7681 # but understands `-z linker_flag'.
7682 # Supported since Solaris 2.6 (maybe 2.5.1?)
7683 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7686 _LT_TAGVAR(link_all_deplibs, $1)=yes
7688 output_verbose_link_cmd='func_echo_all'
7690 # Archives containing C++ object files must be created using
7691 # "CC -xar", where "CC" is the Sun C++ compiler. This is
7692 # necessary to make sure instantiated templates are included
7694 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7697 # Green Hills C++ Compiler
7698 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7700 # The C++ compiler must be used to create the archive.
7701 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
7704 # GNU C++ compiler with Solaris linker
7705 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
7706 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
7707 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
7708 _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'
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 -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7712 # Commands to make compiler produce verbose output that lists
7713 # what "hidden" libraries, object files and flags are used when
7714 # linking a shared library.
7715 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7717 # g++ 2.7 appears to require `-G' NOT `-shared' on this
7719 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7720 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7721 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7723 # Commands to make compiler produce verbose output that lists
7724 # what "hidden" libraries, object files and flags are used when
7725 # linking a shared library.
7726 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7729 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
7731 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7733 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
7741 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7742 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7743 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7744 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7745 runpath_var='LD_RUN_PATH'
7747 case $cc_basename in
7749 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7750 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7753 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7754 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7759 sysv5* | sco3.2v5* | sco5v6*)
7760 # Note: We can NOT use -z defs as we might desire, because we do not
7761 # link with -lc, and that would cause any symbols used from libc to
7762 # always be unresolved, which means just about no library would
7763 # ever link correctly. If we're not using GNU ld we use -z text
7764 # though, which does catch some bad symbols but isn't as heavy-handed
7766 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7767 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7768 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7769 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7770 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
7771 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7772 _LT_TAGVAR(link_all_deplibs, $1)=yes
7773 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7774 runpath_var='LD_RUN_PATH'
7776 case $cc_basename in
7778 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7779 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7780 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
7781 '"$_LT_TAGVAR(old_archive_cmds, $1)"
7782 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
7783 '"$_LT_TAGVAR(reload_cmds, $1)"
7786 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7787 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7793 case $cc_basename in
7795 # NonStop-UX NCC 3.20
7796 # FIXME: insert proper C++ library support
7797 _LT_TAGVAR(ld_shlibs, $1)=no
7800 # FIXME: insert proper C++ library support
7801 _LT_TAGVAR(ld_shlibs, $1)=no
7807 # FIXME: insert proper C++ library support
7808 _LT_TAGVAR(ld_shlibs, $1)=no
7812 # FIXME: insert proper C++ library support
7813 _LT_TAGVAR(ld_shlibs, $1)=no
7817 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
7818 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7820 _LT_TAGVAR(GCC, $1)="$GXX"
7821 _LT_TAGVAR(LD, $1)="$LD"
7824 ## There is no encapsulation within the following macros, do not change
7825 ## the running order or otherwise move them around unless you know exactly
7826 ## what you are doing...
7827 _LT_SYS_HIDDEN_LIBDEPS($1)
7828 _LT_COMPILER_PIC($1)
7829 _LT_COMPILER_C_O($1)
7830 _LT_COMPILER_FILE_LOCKS($1)
7831 _LT_LINKER_SHLIBS($1)
7832 _LT_SYS_DYNAMIC_LINKER($1)
7833 _LT_LINKER_HARDCODE_LIBPATH($1)
7836 fi # test -n "$compiler"
7839 CFLAGS=$lt_save_CFLAGS
7843 with_gnu_ld=$lt_save_with_gnu_ld
7844 lt_cv_path_LDCXX=$lt_cv_path_LD
7845 lt_cv_path_LD=$lt_save_path_LD
7846 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
7847 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
7848 fi # test "$_lt_caught_CXX_error" != yes
7851 ])# _LT_LANG_CXX_CONFIG
7854 # _LT_FUNC_STRIPNAME_CNF
7855 # ----------------------
7856 # func_stripname_cnf prefix suffix name
7857 # strip PREFIX and SUFFIX off of NAME.
7858 # PREFIX and SUFFIX must not contain globbing or regex special
7859 # characters, hashes, percent signs, but SUFFIX may contain a leading
7860 # dot (in which case that matches only a dot).
7862 # This function is identical to the (non-XSI) version of func_stripname,
7863 # except this one can be used by m4 code that may be executed by configure,
7864 # rather than the libtool script.
7865 m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
7866 AC_REQUIRE([_LT_DECL_SED])
7867 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
7868 func_stripname_cnf ()
7871 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
7872 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
7874 } # func_stripname_cnf
7875 ])# _LT_FUNC_STRIPNAME_CNF
7877 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
7878 # ---------------------------------
7879 # Figure out "hidden" library dependencies from verbose
7880 # compiler output when linking a shared library.
7881 # Parse the compiler output and extract the necessary
7882 # objects, libraries and library flags.
7883 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
7884 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7885 AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
7886 # Dependencies to place before and after the object being linked:
7887 _LT_TAGVAR(predep_objects, $1)=
7888 _LT_TAGVAR(postdep_objects, $1)=
7889 _LT_TAGVAR(predeps, $1)=
7890 _LT_TAGVAR(postdeps, $1)=
7891 _LT_TAGVAR(compiler_lib_search_path, $1)=
7893 dnl we can't use the lt_simple_compile_test_code here,
7894 dnl because it contains code intended for an executable,
7895 dnl not a library. It's possible we should let each
7896 dnl tag define a new lt_????_link_test_code variable,
7897 dnl but it's only used here...
7898 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
7900 void foo (void) { a = 0; }
7902 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
7906 Foo (void) { a = 0; }
7911 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
7919 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
7927 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
7930 public void bar (void) {
7935 ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
7942 _lt_libdeps_save_CFLAGS=$CFLAGS
7943 case "$CC $CFLAGS " in #(
7944 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
7945 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
7946 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
7949 dnl Parse the compiler output and extract the necessary
7950 dnl objects, libraries and library flags.
7951 if AC_TRY_EVAL(ac_compile); then
7952 # Parse the compiler output and extract the necessary
7953 # objects, libraries and library flags.
7955 # Sentinel used to keep track of whether or not we are before
7956 # the conftest object file.
7957 pre_test_object_deps_done=no
7959 for p in `eval "$output_verbose_link_cmd"`; do
7963 # Some compilers place space between "-{L,R}" and the path.
7965 if test $p = "-L" ||
7966 test $p = "-R"; then
7971 # Expand the sysroot to ease extracting the directories later.
7972 if test -z "$prev"; then
7974 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
7975 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
7976 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
7980 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
7982 if test "$pre_test_object_deps_done" = no; then
7985 # Internal compiler library paths should come after those
7986 # provided the user. The postdeps already come after the
7987 # user supplied libs so there is no need to process them.
7988 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7989 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
7991 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
7994 # The "-l" case would never come before the object being
7995 # linked, so don't bother handling this case.
7998 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7999 _LT_TAGVAR(postdeps, $1)="${prev}${p}"
8001 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
8007 *.lto.$objext) ;; # Ignore GCC LTO objects
8009 # This assumes that the test object file only shows up
8010 # once in the compiler output.
8011 if test "$p" = "conftest.$objext"; then
8012 pre_test_object_deps_done=yes
8016 if test "$pre_test_object_deps_done" = no; then
8017 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
8018 _LT_TAGVAR(predep_objects, $1)="$p"
8020 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
8023 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
8024 _LT_TAGVAR(postdep_objects, $1)="$p"
8026 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
8031 *) ;; # Ignore the rest.
8039 echo "libtool.m4: error: problem compiling $1 test program"
8042 $RM -f confest.$objext
8043 CFLAGS=$_lt_libdeps_save_CFLAGS
8045 # PORTME: override above test on systems where it is broken
8049 # Interix 3.5 installs completely hosed .la files for C++, so rather than
8050 # hack all around it, let's just trust "g++" to DTRT.
8051 _LT_TAGVAR(predep_objects,$1)=
8052 _LT_TAGVAR(postdep_objects,$1)=
8053 _LT_TAGVAR(postdeps,$1)=
8057 case `$CC -V 2>&1 | sed 5q` in
8061 # The more standards-conforming stlport4 library is
8062 # incompatible with the Cstd library. Avoid specifying
8063 # it if it's in CXXFLAGS. Ignore libCrun as
8064 # -library=stlport4 depends on it.
8065 case " $CXX $CXXFLAGS " in
8066 *" -library=stlport4 "*)
8067 solaris_use_stlport4=yes
8071 if test "$solaris_use_stlport4" != yes; then
8072 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8079 case $cc_basename in
8081 # The more standards-conforming stlport4 library is
8082 # incompatible with the Cstd library. Avoid specifying
8083 # it if it's in CXXFLAGS. Ignore libCrun as
8084 # -library=stlport4 depends on it.
8085 case " $CXX $CXXFLAGS " in
8086 *" -library=stlport4 "*)
8087 solaris_use_stlport4=yes
8091 # Adding this requires a known-good setup of shared libraries for
8092 # Sun compiler versions before 5.6, else PIC objects from an old
8093 # archive will be linked into the output, leading to subtle bugs.
8094 if test "$solaris_use_stlport4" != yes; then
8095 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
8103 case " $_LT_TAGVAR(postdeps, $1) " in
8104 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
8106 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
8107 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
8108 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
8110 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
8111 [The directories searched by this compiler when creating a shared library])
8112 _LT_TAGDECL([], [predep_objects], [1],
8113 [Dependencies to place before and after the objects being linked to
8114 create a shared library])
8115 _LT_TAGDECL([], [postdep_objects], [1])
8116 _LT_TAGDECL([], [predeps], [1])
8117 _LT_TAGDECL([], [postdeps], [1])
8118 _LT_TAGDECL([], [compiler_lib_search_path], [1],
8119 [The library search path used internally by the compiler when linking
8121 ])# _LT_SYS_HIDDEN_LIBDEPS
8124 # _LT_LANG_F77_CONFIG([TAG])
8125 # --------------------------
8126 # Ensure that the configuration variables for a Fortran 77 compiler are
8127 # suitably defined. These variables are subsequently used by _LT_CONFIG
8128 # to write the compiler configuration to `libtool'.
8129 m4_defun([_LT_LANG_F77_CONFIG],
8130 [AC_LANG_PUSH(Fortran 77)
8131 if test -z "$F77" || test "X$F77" = "Xno"; then
8135 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8136 _LT_TAGVAR(allow_undefined_flag, $1)=
8137 _LT_TAGVAR(always_export_symbols, $1)=no
8138 _LT_TAGVAR(archive_expsym_cmds, $1)=
8139 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8140 _LT_TAGVAR(hardcode_direct, $1)=no
8141 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8142 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8143 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8144 _LT_TAGVAR(hardcode_minus_L, $1)=no
8145 _LT_TAGVAR(hardcode_automatic, $1)=no
8146 _LT_TAGVAR(inherit_rpath, $1)=no
8147 _LT_TAGVAR(module_cmds, $1)=
8148 _LT_TAGVAR(module_expsym_cmds, $1)=
8149 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8150 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8151 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8152 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8153 _LT_TAGVAR(no_undefined_flag, $1)=
8154 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8155 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8157 # Source file extension for f77 test sources.
8160 # Object file extension for compiled f77 test sources.
8162 _LT_TAGVAR(objext, $1)=$objext
8164 # No sense in running all these tests if we already determined that
8165 # the F77 compiler isn't working. Some variables (like enable_shared)
8166 # are currently assumed to apply to all compilers on this platform,
8167 # and will be corrupted by setting them based on a non-working compiler.
8168 if test "$_lt_disable_F77" != yes; then
8169 # Code to be used in simple compile tests
8170 lt_simple_compile_test_code="\
8176 # Code to be used in simple link tests
8177 lt_simple_link_test_code="\
8182 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8185 # save warnings/boilerplate of simple test code
8186 _LT_COMPILER_BOILERPLATE
8187 _LT_LINKER_BOILERPLATE
8189 # Allow CC to be a program name with arguments.
8192 lt_save_CFLAGS=$CFLAGS
8196 _LT_TAGVAR(compiler, $1)=$CC
8197 _LT_CC_BASENAME([$compiler])
8199 if test -n "$compiler"; then
8200 AC_MSG_CHECKING([if libtool supports shared libraries])
8201 AC_MSG_RESULT([$can_build_shared])
8203 AC_MSG_CHECKING([whether to build shared libraries])
8204 test "$can_build_shared" = "no" && enable_shared=no
8206 # On AIX, shared libraries and static libraries use the same namespace, and
8207 # are all built from PIC.
8210 test "$enable_shared" = yes && enable_static=no
8211 if test -n "$RANLIB"; then
8212 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8213 postinstall_cmds='$RANLIB $lib'
8217 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8218 test "$enable_shared" = yes && enable_static=no
8222 AC_MSG_RESULT([$enable_shared])
8224 AC_MSG_CHECKING([whether to build static libraries])
8225 # Make sure either enable_shared or enable_static is yes.
8226 test "$enable_shared" = yes || enable_static=yes
8227 AC_MSG_RESULT([$enable_static])
8229 _LT_TAGVAR(GCC, $1)="$G77"
8230 _LT_TAGVAR(LD, $1)="$LD"
8233 ## There is no encapsulation within the following macros, do not change
8234 ## the running order or otherwise move them around unless you know exactly
8235 ## what you are doing...
8236 _LT_COMPILER_PIC($1)
8237 _LT_COMPILER_C_O($1)
8238 _LT_COMPILER_FILE_LOCKS($1)
8239 _LT_LINKER_SHLIBS($1)
8240 _LT_SYS_DYNAMIC_LINKER($1)
8241 _LT_LINKER_HARDCODE_LIBPATH($1)
8244 fi # test -n "$compiler"
8248 CFLAGS="$lt_save_CFLAGS"
8249 fi # test "$_lt_disable_F77" != yes
8252 ])# _LT_LANG_F77_CONFIG
8255 # _LT_LANG_FC_CONFIG([TAG])
8256 # -------------------------
8257 # Ensure that the configuration variables for a Fortran compiler are
8258 # suitably defined. These variables are subsequently used by _LT_CONFIG
8259 # to write the compiler configuration to `libtool'.
8260 m4_defun([_LT_LANG_FC_CONFIG],
8261 [AC_LANG_PUSH(Fortran)
8263 if test -z "$FC" || test "X$FC" = "Xno"; then
8267 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8268 _LT_TAGVAR(allow_undefined_flag, $1)=
8269 _LT_TAGVAR(always_export_symbols, $1)=no
8270 _LT_TAGVAR(archive_expsym_cmds, $1)=
8271 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
8272 _LT_TAGVAR(hardcode_direct, $1)=no
8273 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
8274 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
8275 _LT_TAGVAR(hardcode_libdir_separator, $1)=
8276 _LT_TAGVAR(hardcode_minus_L, $1)=no
8277 _LT_TAGVAR(hardcode_automatic, $1)=no
8278 _LT_TAGVAR(inherit_rpath, $1)=no
8279 _LT_TAGVAR(module_cmds, $1)=
8280 _LT_TAGVAR(module_expsym_cmds, $1)=
8281 _LT_TAGVAR(link_all_deplibs, $1)=unknown
8282 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8283 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8284 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8285 _LT_TAGVAR(no_undefined_flag, $1)=
8286 _LT_TAGVAR(whole_archive_flag_spec, $1)=
8287 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
8289 # Source file extension for fc test sources.
8290 ac_ext=${ac_fc_srcext-f}
8292 # Object file extension for compiled fc test sources.
8294 _LT_TAGVAR(objext, $1)=$objext
8296 # No sense in running all these tests if we already determined that
8297 # the FC compiler isn't working. Some variables (like enable_shared)
8298 # are currently assumed to apply to all compilers on this platform,
8299 # and will be corrupted by setting them based on a non-working compiler.
8300 if test "$_lt_disable_FC" != yes; then
8301 # Code to be used in simple compile tests
8302 lt_simple_compile_test_code="\
8308 # Code to be used in simple link tests
8309 lt_simple_link_test_code="\
8314 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8317 # save warnings/boilerplate of simple test code
8318 _LT_COMPILER_BOILERPLATE
8319 _LT_LINKER_BOILERPLATE
8321 # Allow CC to be a program name with arguments.
8324 lt_save_CFLAGS=$CFLAGS
8328 GCC=$ac_cv_fc_compiler_gnu
8330 _LT_TAGVAR(compiler, $1)=$CC
8331 _LT_CC_BASENAME([$compiler])
8333 if test -n "$compiler"; then
8334 AC_MSG_CHECKING([if libtool supports shared libraries])
8335 AC_MSG_RESULT([$can_build_shared])
8337 AC_MSG_CHECKING([whether to build shared libraries])
8338 test "$can_build_shared" = "no" && enable_shared=no
8340 # On AIX, shared libraries and static libraries use the same namespace, and
8341 # are all built from PIC.
8344 test "$enable_shared" = yes && enable_static=no
8345 if test -n "$RANLIB"; then
8346 archive_cmds="$archive_cmds~\$RANLIB \$lib"
8347 postinstall_cmds='$RANLIB $lib'
8351 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8352 test "$enable_shared" = yes && enable_static=no
8356 AC_MSG_RESULT([$enable_shared])
8358 AC_MSG_CHECKING([whether to build static libraries])
8359 # Make sure either enable_shared or enable_static is yes.
8360 test "$enable_shared" = yes || enable_static=yes
8361 AC_MSG_RESULT([$enable_static])
8363 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
8364 _LT_TAGVAR(LD, $1)="$LD"
8367 ## There is no encapsulation within the following macros, do not change
8368 ## the running order or otherwise move them around unless you know exactly
8369 ## what you are doing...
8370 _LT_SYS_HIDDEN_LIBDEPS($1)
8371 _LT_COMPILER_PIC($1)
8372 _LT_COMPILER_C_O($1)
8373 _LT_COMPILER_FILE_LOCKS($1)
8374 _LT_LINKER_SHLIBS($1)
8375 _LT_SYS_DYNAMIC_LINKER($1)
8376 _LT_LINKER_HARDCODE_LIBPATH($1)
8379 fi # test -n "$compiler"
8383 CFLAGS=$lt_save_CFLAGS
8384 fi # test "$_lt_disable_FC" != yes
8387 ])# _LT_LANG_FC_CONFIG
8390 # _LT_LANG_GCJ_CONFIG([TAG])
8391 # --------------------------
8392 # Ensure that the configuration variables for the GNU Java Compiler compiler
8393 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8394 # to write the compiler configuration to `libtool'.
8395 m4_defun([_LT_LANG_GCJ_CONFIG],
8396 [AC_REQUIRE([LT_PROG_GCJ])dnl
8399 # Source file extension for Java test sources.
8402 # Object file extension for compiled Java test sources.
8404 _LT_TAGVAR(objext, $1)=$objext
8406 # Code to be used in simple compile tests
8407 lt_simple_compile_test_code="class foo {}"
8409 # Code to be used in simple link tests
8410 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
8412 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8415 # save warnings/boilerplate of simple test code
8416 _LT_COMPILER_BOILERPLATE
8417 _LT_LINKER_BOILERPLATE
8419 # Allow CC to be a program name with arguments.
8421 lt_save_CFLAGS=$CFLAGS
8427 _LT_TAGVAR(compiler, $1)=$CC
8428 _LT_TAGVAR(LD, $1)="$LD"
8429 _LT_CC_BASENAME([$compiler])
8431 # GCJ did not exist at the time GCC didn't implicitly link libc in.
8432 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8434 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8435 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8436 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8438 if test -n "$compiler"; then
8439 _LT_COMPILER_NO_RTTI($1)
8440 _LT_COMPILER_PIC($1)
8441 _LT_COMPILER_C_O($1)
8442 _LT_COMPILER_FILE_LOCKS($1)
8443 _LT_LINKER_SHLIBS($1)
8444 _LT_LINKER_HARDCODE_LIBPATH($1)
8453 CFLAGS=$lt_save_CFLAGS
8454 ])# _LT_LANG_GCJ_CONFIG
8457 # _LT_LANG_GO_CONFIG([TAG])
8458 # --------------------------
8459 # Ensure that the configuration variables for the GNU Go compiler
8460 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8461 # to write the compiler configuration to `libtool'.
8462 m4_defun([_LT_LANG_GO_CONFIG],
8463 [AC_REQUIRE([LT_PROG_GO])dnl
8466 # Source file extension for Go test sources.
8469 # Object file extension for compiled Go test sources.
8471 _LT_TAGVAR(objext, $1)=$objext
8473 # Code to be used in simple compile tests
8474 lt_simple_compile_test_code="package main; func main() { }"
8476 # Code to be used in simple link tests
8477 lt_simple_link_test_code='package main; func main() { }'
8479 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8482 # save warnings/boilerplate of simple test code
8483 _LT_COMPILER_BOILERPLATE
8484 _LT_LINKER_BOILERPLATE
8486 # Allow CC to be a program name with arguments.
8488 lt_save_CFLAGS=$CFLAGS
8494 _LT_TAGVAR(compiler, $1)=$CC
8495 _LT_TAGVAR(LD, $1)="$LD"
8496 _LT_CC_BASENAME([$compiler])
8498 # Go did not exist at the time GCC didn't implicitly link libc in.
8499 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
8501 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
8502 _LT_TAGVAR(reload_flag, $1)=$reload_flag
8503 _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
8505 if test -n "$compiler"; then
8506 _LT_COMPILER_NO_RTTI($1)
8507 _LT_COMPILER_PIC($1)
8508 _LT_COMPILER_C_O($1)
8509 _LT_COMPILER_FILE_LOCKS($1)
8510 _LT_LINKER_SHLIBS($1)
8511 _LT_LINKER_HARDCODE_LIBPATH($1)
8520 CFLAGS=$lt_save_CFLAGS
8521 ])# _LT_LANG_GO_CONFIG
8524 # _LT_LANG_RC_CONFIG([TAG])
8525 # -------------------------
8526 # Ensure that the configuration variables for the Windows resource compiler
8527 # are suitably defined. These variables are subsequently used by _LT_CONFIG
8528 # to write the compiler configuration to `libtool'.
8529 m4_defun([_LT_LANG_RC_CONFIG],
8530 [AC_REQUIRE([LT_PROG_RC])dnl
8533 # Source file extension for RC test sources.
8536 # Object file extension for compiled RC test sources.
8538 _LT_TAGVAR(objext, $1)=$objext
8540 # Code to be used in simple compile tests
8541 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8543 # Code to be used in simple link tests
8544 lt_simple_link_test_code="$lt_simple_compile_test_code"
8546 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8549 # save warnings/boilerplate of simple test code
8550 _LT_COMPILER_BOILERPLATE
8551 _LT_LINKER_BOILERPLATE
8553 # Allow CC to be a program name with arguments.
8555 lt_save_CFLAGS=$CFLAGS
8561 _LT_TAGVAR(compiler, $1)=$CC
8562 _LT_CC_BASENAME([$compiler])
8563 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8565 if test -n "$compiler"; then
8573 CFLAGS=$lt_save_CFLAGS
8574 ])# _LT_LANG_RC_CONFIG
8579 AC_DEFUN([LT_PROG_GCJ],
8580 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
8581 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
8582 [AC_CHECK_TOOL(GCJ, gcj,)
8583 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
8584 AC_SUBST(GCJFLAGS)])])[]dnl
8588 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
8589 dnl aclocal-1.4 backwards compatibility:
8590 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
8595 AC_DEFUN([LT_PROG_GO],
8596 [AC_CHECK_TOOL(GOC, gccgo,)
8602 AC_DEFUN([LT_PROG_RC],
8603 [AC_CHECK_TOOL(RC, windres,)
8607 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
8608 dnl aclocal-1.4 backwards compatibility:
8609 dnl AC_DEFUN([LT_AC_PROG_RC], [])
8614 # If we don't have a new enough Autoconf to choose the best grep
8615 # available, choose the one first in the user's PATH.
8616 m4_defun([_LT_DECL_EGREP],
8617 [AC_REQUIRE([AC_PROG_EGREP])dnl
8618 AC_REQUIRE([AC_PROG_FGREP])dnl
8619 test -z "$GREP" && GREP=grep
8620 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
8621 _LT_DECL([], [EGREP], [1], [An ERE matcher])
8622 _LT_DECL([], [FGREP], [1], [A literal string matcher])
8623 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
8630 # If we don't have a new enough Autoconf to choose the best objdump
8631 # available, choose the one first in the user's PATH.
8632 m4_defun([_LT_DECL_OBJDUMP],
8633 [AC_CHECK_TOOL(OBJDUMP, objdump, false)
8634 test -z "$OBJDUMP" && OBJDUMP=objdump
8635 _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
8641 # Ensure DLLTOOL variable is set.
8642 m4_defun([_LT_DECL_DLLTOOL],
8643 [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8644 test -z "$DLLTOOL" && DLLTOOL=dlltool
8645 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
8651 # Check for a fully-functional sed program, that truncates
8652 # as few characters as possible. Prefer GNU sed if found.
8653 m4_defun([_LT_DECL_SED],
8655 test -z "$SED" && SED=sed
8656 Xsed="$SED -e 1s/^X//"
8657 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
8658 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
8659 [Sed that helps us avoid accidentally triggering echo(1) options like -n])
8662 m4_ifndef([AC_PROG_SED], [
8663 # NOTE: This macro has been submitted for inclusion into #
8664 # GNU Autoconf as AC_PROG_SED. When it is available in #
8665 # a released version of Autoconf we should remove this #
8666 # macro and use it instead. #
8668 m4_defun([AC_PROG_SED],
8669 [AC_MSG_CHECKING([for a sed that does not truncate output])
8670 AC_CACHE_VAL(lt_cv_path_SED,
8671 [# Loop through the user's path and test for sed and gsed.
8672 # Then use that list of sed's as ones to test for truncation.
8673 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8677 test -z "$as_dir" && as_dir=.
8678 for lt_ac_prog in sed gsed; do
8679 for ac_exec_ext in '' $ac_executable_extensions; do
8680 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
8681 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
8689 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
8690 # along with /bin/sed that truncates output.
8691 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
8692 test ! -f $lt_ac_sed && continue
8693 cat /dev/null > conftest.in
8695 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
8696 # Check for GNU sed and select it if it is found.
8697 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
8698 lt_cv_path_SED=$lt_ac_sed
8702 cat conftest.in conftest.in >conftest.tmp
8703 mv conftest.tmp conftest.in
8704 cp conftest.in conftest.nl
8706 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
8707 cmp -s conftest.out conftest.nl || break
8708 # 10000 chars as input seems more than enough
8709 test $lt_ac_count -gt 10 && break
8710 lt_ac_count=`expr $lt_ac_count + 1`
8711 if test $lt_ac_count -gt $lt_ac_max; then
8712 lt_ac_max=$lt_ac_count
8713 lt_cv_path_SED=$lt_ac_sed
8720 AC_MSG_RESULT([$SED])
8725 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
8726 dnl aclocal-1.4 backwards compatibility:
8727 dnl AC_DEFUN([LT_AC_PROG_SED], [])
8730 # _LT_CHECK_SHELL_FEATURES
8731 # ------------------------
8732 # Find out whether the shell is Bourne or XSI compatible,
8733 # or has some other useful features.
8734 m4_defun([_LT_CHECK_SHELL_FEATURES],
8735 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
8736 # Try some XSI features
8739 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
8741 && eval 'test $(( 1 + 1 )) -eq 2 \
8742 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
8744 AC_MSG_RESULT([$xsi_shell])
8745 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
8747 AC_MSG_CHECKING([whether the shell understands "+="])
8749 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
8751 && lt_shell_append=yes
8752 AC_MSG_RESULT([$lt_shell_append])
8753 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
8755 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8760 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
8762 # test EBCDIC or ASCII
8763 case `echo X|tr X '\101'` in
8764 A) # ASCII based system
8765 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8766 lt_SP2NL='tr \040 \012'
8767 lt_NL2SP='tr \015\012 \040\040'
8769 *) # EBCDIC based system
8770 lt_SP2NL='tr \100 \n'
8771 lt_NL2SP='tr \r\n \100\100'
8774 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
8775 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
8776 ])# _LT_CHECK_SHELL_FEATURES
8779 # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
8780 # ------------------------------------------------------
8781 # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
8782 # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
8783 m4_defun([_LT_PROG_FUNCTION_REPLACE],
8785 sed -e '/^$1 ()$/,/^} # $1 /c\
8788 m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
8789 } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
8790 && mv -f "$cfgfile.tmp" "$cfgfile" \
8791 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8792 test 0 -eq $? || _lt_function_replace_fail=:
8796 # _LT_PROG_REPLACE_SHELLFNS
8797 # -------------------------
8798 # Replace existing portable implementations of several shell functions with
8799 # equivalent extended shell implementations where those features are available..
8800 m4_defun([_LT_PROG_REPLACE_SHELLFNS],
8801 [if test x"$xsi_shell" = xyes; then
8802 _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
8804 */*) func_dirname_result="${1%/*}${2}" ;;
8805 * ) func_dirname_result="${3}" ;;
8808 _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
8809 func_basename_result="${1##*/}"])
8811 _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
8813 */*) func_dirname_result="${1%/*}${2}" ;;
8814 * ) func_dirname_result="${3}" ;;
8816 func_basename_result="${1##*/}"])
8818 _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
8819 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
8820 # positional parameters, so assign one to ordinary parameter first.
8821 func_stripname_result=${3}
8822 func_stripname_result=${func_stripname_result#"${1}"}
8823 func_stripname_result=${func_stripname_result%"${2}"}])
8825 _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
8826 func_split_long_opt_name=${1%%=*}
8827 func_split_long_opt_arg=${1#*=}])
8829 _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
8830 func_split_short_opt_arg=${1#??}
8831 func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
8833 _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
8835 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
8836 *) func_lo2o_result=${1} ;;
8839 _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
8841 _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
8843 _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
8846 if test x"$lt_shell_append" = xyes; then
8847 _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
8849 _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
8850 func_quote_for_eval "${2}"
8851 dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
8852 eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
8854 # Save a `func_append' function call where possible by direct use of '+='
8855 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
8856 && mv -f "$cfgfile.tmp" "$cfgfile" \
8857 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8858 test 0 -eq $? || _lt_function_replace_fail=:
8860 # Save a `func_append' function call even when '+=' is not available
8861 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
8862 && mv -f "$cfgfile.tmp" "$cfgfile" \
8863 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
8864 test 0 -eq $? || _lt_function_replace_fail=:
8867 if test x"$_lt_function_replace_fail" = x":"; then
8868 AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
8872 # _LT_PATH_CONVERSION_FUNCTIONS
8873 # -----------------------------
8874 # Determine which file name conversion functions should be used by
8875 # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
8876 # for certain cross-compile configurations and native mingw.
8877 m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
8878 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8879 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
8880 AC_MSG_CHECKING([how to convert $build file names to $host format])
8881 AC_CACHE_VAL(lt_cv_to_host_file_cmd,
8885 *-*-mingw* ) # actually msys
8886 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8889 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8891 * ) # otherwise, assume *nix
8892 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8898 *-*-mingw* ) # actually msys
8899 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8902 lt_cv_to_host_file_cmd=func_convert_file_noop
8904 * ) # otherwise, assume *nix
8905 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8909 * ) # unhandled hosts (and "normal" native builds)
8910 lt_cv_to_host_file_cmd=func_convert_file_noop
8914 to_host_file_cmd=$lt_cv_to_host_file_cmd
8915 AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
8916 _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
8917 [0], [convert $build file names to $host format])dnl
8919 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
8920 AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
8921 [#assume ordinary cross tools, or native build.
8922 lt_cv_to_tool_file_cmd=func_convert_file_noop
8926 *-*-mingw* ) # actually msys
8927 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8933 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8934 AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
8935 _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
8936 [0], [convert $build files to toolchain format])dnl
8937 ])# _LT_PATH_CONVERSION_FUNCTIONS
8939 # Helper functions for option handling. -*- Autoconf -*-
8941 # Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
8943 # Written by Gary V. Vaughan, 2004
8945 # This file is free software; the Free Software Foundation gives
8946 # unlimited permission to copy and/or distribute it, with or without
8947 # modifications, as long as this notice is preserved.
8949 # serial 7 ltoptions.m4
8951 # This is to help aclocal find these macros, as it can't see m4_define.
8952 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
8955 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
8956 # ------------------------------------------
8957 m4_define([_LT_MANGLE_OPTION],
8958 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
8961 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
8962 # ---------------------------------------
8963 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
8964 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
8966 m4_define([_LT_SET_OPTION],
8967 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
8968 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
8969 _LT_MANGLE_DEFUN([$1], [$2]),
8970 [m4_warning([Unknown $1 option `$2'])])[]dnl
8974 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
8975 # ------------------------------------------------------------
8976 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
8977 m4_define([_LT_IF_OPTION],
8978 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
8981 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
8982 # -------------------------------------------------------
8983 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
8985 m4_define([_LT_UNLESS_OPTIONS],
8986 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8987 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
8988 [m4_define([$0_found])])])[]dnl
8989 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
8994 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
8995 # ----------------------------------------
8996 # OPTION-LIST is a space-separated list of Libtool options associated
8997 # with MACRO-NAME. If any OPTION has a matching handler declared with
8998 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
8999 # the unknown option and exit.
9000 m4_defun([_LT_SET_OPTIONS],
9002 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
9003 [_LT_SET_OPTION([$1], _LT_Option)])
9005 m4_if([$1],[LT_INIT],[
9007 dnl Simply set some default values (i.e off) if boolean options were not
9009 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
9011 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
9014 dnl If no reference was made to various pairs of opposing options, then
9015 dnl we run the default mode handler for the pair. For example, if neither
9016 dnl `shared' nor `disable-shared' was passed, we enable building of shared
9017 dnl archives by default:
9018 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
9019 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
9020 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
9021 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
9022 [_LT_ENABLE_FAST_INSTALL])
9028 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
9029 # -----------------------------------------
9030 m4_define([_LT_MANGLE_DEFUN],
9031 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
9034 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
9035 # -----------------------------------------------
9036 m4_define([LT_OPTION_DEFINE],
9037 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
9038 ])# LT_OPTION_DEFINE
9043 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
9046 AU_DEFUN([AC_LIBTOOL_DLOPEN],
9047 [_LT_SET_OPTION([LT_INIT], [dlopen])
9048 AC_DIAGNOSE([obsolete],
9049 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9050 put the `dlopen' option into LT_INIT's first parameter.])
9053 dnl aclocal-1.4 backwards compatibility:
9054 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
9059 # Declare package support for building win32 dll's.
9060 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
9061 [enable_win32_dll=yes
9064 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
9065 AC_CHECK_TOOL(AS, as, false)
9066 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
9067 AC_CHECK_TOOL(OBJDUMP, objdump, false)
9071 test -z "$AS" && AS=as
9072 _LT_DECL([], [AS], [1], [Assembler program])dnl
9074 test -z "$DLLTOOL" && DLLTOOL=dlltool
9075 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
9077 test -z "$OBJDUMP" && OBJDUMP=objdump
9078 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
9081 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
9082 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
9083 _LT_SET_OPTION([LT_INIT], [win32-dll])
9084 AC_DIAGNOSE([obsolete],
9085 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9086 put the `win32-dll' option into LT_INIT's first parameter.])
9089 dnl aclocal-1.4 backwards compatibility:
9090 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
9093 # _LT_ENABLE_SHARED([DEFAULT])
9094 # ----------------------------
9095 # implement the --enable-shared flag, and supports the `shared' and
9096 # `disable-shared' LT_INIT options.
9097 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9098 m4_define([_LT_ENABLE_SHARED],
9099 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
9100 AC_ARG_ENABLE([shared],
9101 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
9102 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
9103 [p=${PACKAGE-default}
9105 yes) enable_shared=yes ;;
9106 no) enable_shared=no ;;
9109 # Look at the argument we got. We use all the common list separators.
9110 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9111 for pkg in $enableval; do
9113 if test "X$pkg" = "X$p"; then
9120 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
9122 _LT_DECL([build_libtool_libs], [enable_shared], [0],
9123 [Whether or not to build shared libraries])
9124 ])# _LT_ENABLE_SHARED
9126 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
9127 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
9130 AC_DEFUN([AC_ENABLE_SHARED],
9131 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
9134 AC_DEFUN([AC_DISABLE_SHARED],
9135 [_LT_SET_OPTION([LT_INIT], [disable-shared])
9138 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
9139 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
9141 dnl aclocal-1.4 backwards compatibility:
9142 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
9143 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
9147 # _LT_ENABLE_STATIC([DEFAULT])
9148 # ----------------------------
9149 # implement the --enable-static flag, and support the `static' and
9150 # `disable-static' LT_INIT options.
9151 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9152 m4_define([_LT_ENABLE_STATIC],
9153 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
9154 AC_ARG_ENABLE([static],
9155 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
9156 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
9157 [p=${PACKAGE-default}
9159 yes) enable_static=yes ;;
9160 no) enable_static=no ;;
9163 # Look at the argument we got. We use all the common list separators.
9164 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9165 for pkg in $enableval; do
9167 if test "X$pkg" = "X$p"; then
9174 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
9176 _LT_DECL([build_old_libs], [enable_static], [0],
9177 [Whether or not to build static libraries])
9178 ])# _LT_ENABLE_STATIC
9180 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
9181 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
9184 AC_DEFUN([AC_ENABLE_STATIC],
9185 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
9188 AC_DEFUN([AC_DISABLE_STATIC],
9189 [_LT_SET_OPTION([LT_INIT], [disable-static])
9192 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
9193 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
9195 dnl aclocal-1.4 backwards compatibility:
9196 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
9197 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
9201 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
9202 # ----------------------------------
9203 # implement the --enable-fast-install flag, and support the `fast-install'
9204 # and `disable-fast-install' LT_INIT options.
9205 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9206 m4_define([_LT_ENABLE_FAST_INSTALL],
9207 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
9208 AC_ARG_ENABLE([fast-install],
9209 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
9210 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
9211 [p=${PACKAGE-default}
9213 yes) enable_fast_install=yes ;;
9214 no) enable_fast_install=no ;;
9216 enable_fast_install=no
9217 # Look at the argument we got. We use all the common list separators.
9218 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9219 for pkg in $enableval; do
9221 if test "X$pkg" = "X$p"; then
9222 enable_fast_install=yes
9228 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
9230 _LT_DECL([fast_install], [enable_fast_install], [0],
9231 [Whether or not to optimize for fast installation])dnl
9232 ])# _LT_ENABLE_FAST_INSTALL
9234 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
9235 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
9238 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
9239 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
9240 AC_DIAGNOSE([obsolete],
9241 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9242 the `fast-install' option into LT_INIT's first parameter.])
9245 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
9246 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
9247 AC_DIAGNOSE([obsolete],
9248 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9249 the `disable-fast-install' option into LT_INIT's first parameter.])
9252 dnl aclocal-1.4 backwards compatibility:
9253 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
9254 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
9257 # _LT_WITH_PIC([MODE])
9258 # --------------------
9259 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
9261 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
9262 m4_define([_LT_WITH_PIC],
9264 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
9265 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
9266 [lt_p=${PACKAGE-default}
9268 yes|no) pic_mode=$withval ;;
9271 # Look at the argument we got. We use all the common list separators.
9272 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9273 for lt_pkg in $withval; do
9275 if test "X$lt_pkg" = "X$lt_p"; then
9284 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
9286 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
9289 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
9290 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
9293 AU_DEFUN([AC_LIBTOOL_PICMODE],
9294 [_LT_SET_OPTION([LT_INIT], [pic-only])
9295 AC_DIAGNOSE([obsolete],
9296 [$0: Remove this warning and the call to _LT_SET_OPTION when you
9297 put the `pic-only' option into LT_INIT's first parameter.])
9300 dnl aclocal-1.4 backwards compatibility:
9301 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
9304 m4_define([_LTDL_MODE], [])
9305 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
9306 [m4_define([_LTDL_MODE], [nonrecursive])])
9307 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
9308 [m4_define([_LTDL_MODE], [recursive])])
9309 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
9310 [m4_define([_LTDL_MODE], [subproject])])
9312 m4_define([_LTDL_TYPE], [])
9313 LT_OPTION_DEFINE([LTDL_INIT], [installable],
9314 [m4_define([_LTDL_TYPE], [installable])])
9315 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
9316 [m4_define([_LTDL_TYPE], [convenience])])
9318 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
9320 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
9321 # Written by Gary V. Vaughan, 2004
9323 # This file is free software; the Free Software Foundation gives
9324 # unlimited permission to copy and/or distribute it, with or without
9325 # modifications, as long as this notice is preserved.
9327 # serial 6 ltsugar.m4
9329 # This is to help aclocal find these macros, as it can't see m4_define.
9330 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
9333 # lt_join(SEP, ARG1, [ARG2...])
9334 # -----------------------------
9335 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
9336 # associated separator.
9337 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
9338 # versions in m4sugar had bugs.
9339 m4_define([lt_join],
9340 [m4_if([$#], [1], [],
9342 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
9343 m4_define([_lt_join],
9344 [m4_if([$#$2], [2], [],
9345 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
9351 # Manipulate m4 lists.
9352 # These macros are necessary as long as will still need to support
9353 # Autoconf-2.59 which quotes differently.
9354 m4_define([lt_car], [[$1]])
9356 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
9358 [m4_dquote(m4_shift($@))])])
9359 m4_define([lt_unquote], $1)
9362 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
9363 # ------------------------------------------
9364 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
9365 # Note that neither SEPARATOR nor STRING are expanded; they are appended
9366 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
9367 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
9368 # than defined and empty).
9370 # This macro is needed until we can rely on Autoconf 2.62, since earlier
9371 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
9372 m4_define([lt_append],
9374 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
9378 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
9379 # ----------------------------------------------------------
9380 # Produce a SEP delimited list of all paired combinations of elements of
9381 # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
9382 # has the form PREFIXmINFIXSUFFIXn.
9383 # Needed until we can rely on m4_combine added in Autoconf 2.62.
9384 m4_define([lt_combine],
9385 [m4_if(m4_eval([$# > 3]), [1],
9386 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
9387 [[m4_foreach([_Lt_prefix], [$2],
9388 [m4_foreach([_Lt_suffix],
9389 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
9390 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
9393 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
9394 # -----------------------------------------------------------------------
9395 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
9396 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
9397 m4_define([lt_if_append_uniq],
9399 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
9400 [lt_append([$1], [$2], [$3])$4],
9402 [lt_append([$1], [$2], [$3])$4])])
9405 # lt_dict_add(DICT, KEY, VALUE)
9406 # -----------------------------
9407 m4_define([lt_dict_add],
9408 [m4_define([$1($2)], [$3])])
9411 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
9412 # --------------------------------------------
9413 m4_define([lt_dict_add_subkey],
9414 [m4_define([$1($2:$3)], [$4])])
9417 # lt_dict_fetch(DICT, KEY, [SUBKEY])
9418 # ----------------------------------
9419 m4_define([lt_dict_fetch],
9421 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
9422 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
9425 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
9426 # -----------------------------------------------------------------
9427 m4_define([lt_if_dict_fetch],
9428 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
9433 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
9434 # --------------------------------------------------------------
9435 m4_define([lt_dict_filter],
9436 [m4_if([$5], [], [],
9437 [lt_join(m4_quote(m4_default([$4], [[, ]])),
9438 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
9439 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
9442 # ltversion.m4 -- version numbers -*- Autoconf -*-
9444 # Copyright (C) 2004 Free Software Foundation, Inc.
9445 # Written by Scott James Remnant, 2004
9447 # This file is free software; the Free Software Foundation gives
9448 # unlimited permission to copy and/or distribute it, with or without
9449 # modifications, as long as this notice is preserved.
9453 # serial 3337 ltversion.m4
9454 # This file is part of GNU Libtool
9456 m4_define([LT_PACKAGE_VERSION], [2.4.2])
9457 m4_define([LT_PACKAGE_REVISION], [1.3337])
9459 AC_DEFUN([LTVERSION_VERSION],
9460 [macro_version='2.4.2'
9461 macro_revision='1.3337'
9462 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
9463 _LT_DECL(, macro_revision, 0)
9466 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
9468 # Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
9469 # Written by Scott James Remnant, 2004.
9471 # This file is free software; the Free Software Foundation gives
9472 # unlimited permission to copy and/or distribute it, with or without
9473 # modifications, as long as this notice is preserved.
9475 # serial 5 lt~obsolete.m4
9477 # These exist entirely to fool aclocal when bootstrapping libtool.
9479 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
9480 # which have later been changed to m4_define as they aren't part of the
9481 # exported API, or moved to Autoconf or Automake where they belong.
9483 # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
9484 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
9485 # using a macro with the same name in our local m4/libtool.m4 it'll
9486 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
9487 # and doesn't know about Autoconf macros at all.)
9489 # So we provide this file, which has a silly filename so it's always
9490 # included after everything else. This provides aclocal with the
9491 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
9492 # because those macros already exist, or will be overwritten later.
9493 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
9495 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
9496 # Yes, that means every name once taken will need to remain here until
9497 # we give up compatibility with versions before 1.7, at which point
9498 # we need to keep only those names which we still refer to.
9500 # This is to help aclocal find these macros, as it can't see m4_define.
9501 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
9503 m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
9504 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
9505 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
9506 m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
9507 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
9508 m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
9509 m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
9510 m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
9511 m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
9512 m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
9513 m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
9514 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
9515 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
9516 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
9517 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
9518 m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
9519 m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
9520 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
9521 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
9522 m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
9523 m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
9524 m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
9525 m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
9526 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
9527 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
9528 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
9529 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
9530 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
9531 m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
9532 m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
9533 m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
9534 m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
9535 m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
9536 m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
9537 m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
9538 m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
9539 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
9540 m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
9541 m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
9542 m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
9543 m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
9544 m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
9545 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
9546 m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
9547 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
9548 m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
9549 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
9550 m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
9551 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
9552 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
9553 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
9554 m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
9555 m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
9556 m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
9557 m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
9558 m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
9559 m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
9560 m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
9561 m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
9562 m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
9563 m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
9565 # nls.m4 serial 5 (gettext-0.18)
9566 dnl Copyright (C) 1995-2003, 2005-2006, 2008-2010 Free Software Foundation,
9568 dnl This file is free software; the Free Software Foundation
9569 dnl gives unlimited permission to copy and/or distribute it,
9570 dnl with or without modifications, as long as this notice is preserved.
9572 dnl This file can can be used in projects which are not available under
9573 dnl the GNU General Public License or the GNU Library General Public
9574 dnl License but which still want to provide support for the GNU gettext
9576 dnl Please note that the actual code of the GNU gettext library is covered
9577 dnl by the GNU Library General Public License, and the rest of the GNU
9578 dnl gettext package package is covered by the GNU General Public License.
9579 dnl They are *not* in the public domain.
9582 dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
9583 dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
9589 AC_MSG_CHECKING([whether NLS is requested])
9590 dnl Default is enabled NLS
9591 AC_ARG_ENABLE([nls],
9592 [ --disable-nls do not use Native Language Support],
9593 USE_NLS=$enableval, USE_NLS=yes)
9594 AC_MSG_RESULT([$USE_NLS])
9598 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
9599 # serial 1 (pkg-config-0.24)
9601 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
9603 # This program is free software; you can redistribute it and/or modify
9604 # it under the terms of the GNU General Public License as published by
9605 # the Free Software Foundation; either version 2 of the License, or
9606 # (at your option) any later version.
9608 # This program is distributed in the hope that it will be useful, but
9609 # WITHOUT ANY WARRANTY; without even the implied warranty of
9610 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
9611 # General Public License for more details.
9613 # You should have received a copy of the GNU General Public License
9614 # along with this program; if not, write to the Free Software
9615 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
9617 # As a special exception to the GNU General Public License, if you
9618 # distribute this file as part of a program that contains a
9619 # configuration script generated by Autoconf, you may include it under
9620 # the same distribution terms that you use for the rest of that program.
9622 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
9623 # ----------------------------------
9624 AC_DEFUN([PKG_PROG_PKG_CONFIG],
9625 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
9626 m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
9627 m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
9628 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
9629 AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
9630 AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
9632 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
9633 AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
9635 if test -n "$PKG_CONFIG"; then
9636 _pkg_min_version=m4_default([$1], [0.9.0])
9637 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
9638 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
9639 AC_MSG_RESULT([yes])
9645 ])# PKG_PROG_PKG_CONFIG
9647 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9649 # Check to see whether a particular set of modules exists. Similar
9650 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
9652 # Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9653 # only at the first occurence in configure.ac, so if the first place
9654 # it's called might be skipped (such as if it is within an "if", you
9655 # have to call PKG_CHECK_EXISTS manually
9656 # --------------------------------------------------------------
9657 AC_DEFUN([PKG_CHECK_EXISTS],
9658 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9659 if test -n "$PKG_CONFIG" && \
9660 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
9661 m4_default([$2], [:])
9662 m4_ifvaln([$3], [else
9666 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
9667 # ---------------------------------------------
9668 m4_define([_PKG_CONFIG],
9669 [if test -n "$$1"; then
9671 elif test -n "$PKG_CONFIG"; then
9672 PKG_CHECK_EXISTS([$3],
9673 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
9674 test "x$?" != "x0" && pkg_failed=yes ],
9681 # _PKG_SHORT_ERRORS_SUPPORTED
9682 # -----------------------------
9683 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
9684 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
9685 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
9686 _pkg_short_errors_supported=yes
9688 _pkg_short_errors_supported=no
9690 ])# _PKG_SHORT_ERRORS_SUPPORTED
9693 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
9694 # [ACTION-IF-NOT-FOUND])
9697 # Note that if there is a possibility the first call to
9698 # PKG_CHECK_MODULES might not happen, you should be sure to include an
9699 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
9702 # --------------------------------------------------------------
9703 AC_DEFUN([PKG_CHECK_MODULES],
9704 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9705 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
9706 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
9709 AC_MSG_CHECKING([for $1])
9711 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
9712 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
9714 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
9715 and $1[]_LIBS to avoid the need to call pkg-config.
9716 See the pkg-config man page for more details.])
9718 if test $pkg_failed = yes; then
9720 _PKG_SHORT_ERRORS_SUPPORTED
9721 if test $_pkg_short_errors_supported = yes; then
9722 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
9724 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
9726 # Put the nasty error message in config.log where it belongs
9727 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
9729 m4_default([$4], [AC_MSG_ERROR(
9730 [Package requirements ($2) were not met:
9734 Consider adjusting the PKG_CONFIG_PATH environment variable if you
9735 installed software in a non-standard prefix.
9739 elif test $pkg_failed = untried; then
9741 m4_default([$4], [AC_MSG_FAILURE(
9742 [The pkg-config script could not be found or is too old. Make sure it
9743 is in your PATH or set the PKG_CONFIG environment variable to the full
9748 To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
9751 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
9752 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
9753 AC_MSG_RESULT([yes])
9756 ])# PKG_CHECK_MODULES
9758 AC_DEFUN([YELP_HELP_INIT],
9760 AC_REQUIRE([AC_PROG_LN_S])
9761 m4_pattern_allow([AM_V_at])
9762 m4_pattern_allow([AM_V_GEN])
9763 m4_pattern_allow([AM_DEFAULT_VERBOSITY])
9764 AC_ARG_WITH([help-dir],
9765 AC_HELP_STRING([--with-help-dir=DIR],
9766 [path where help files are installed]),,
9767 [with_help_dir='${datadir}/help'])
9768 HELP_DIR="$with_help_dir"
9771 AC_ARG_VAR([ITSTOOL], [Path to the `itstool` command])
9772 AC_CHECK_PROG([ITSTOOL], [itstool], [itstool])
9773 if test x"$ITSTOOL" = x; then
9774 AC_MSG_ERROR([itstool not found])
9777 AC_ARG_VAR([XMLLINT], [Path to the `xmllint` command])
9778 AC_CHECK_PROG([XMLLINT], [xmllint], [xmllint])
9779 if test x"$XMLLINT" = x; then
9780 AC_MSG_ERROR([xmllint not found])
9791 _HELP_LINGUAS = $(if $(filter environment,$(origin LINGUAS)),$(filter $(LINGUAS),$(HELP_LINGUAS)),$(HELP_LINGUAS))
9792 _HELP_POTFILE = $(if $(HELP_POT),$(HELP_POT),$(if $(HELP_ID),$(HELP_ID).pot))
9793 _HELP_POFILES = $(if $(HELP_ID),$(foreach lc,$(_HELP_LINGUAS),$(lc)/$(lc).po))
9794 _HELP_MOFILES = $(patsubst %.po,%.mo,$(_HELP_POFILES))
9795 _HELP_C_FILES = $(foreach f,$(HELP_FILES),C/$(f))
9796 _HELP_C_EXTRA = $(foreach f,$(HELP_EXTRA),C/$(f))
9797 _HELP_C_MEDIA = $(foreach f,$(HELP_MEDIA),C/$(f))
9798 _HELP_LC_FILES = $(foreach lc,$(_HELP_LINGUAS),$(foreach f,$(HELP_FILES),$(lc)/$(f)))
9799 _HELP_LC_STAMPS = $(foreach lc,$(_HELP_LINGUAS),$(lc)/$(lc).stamp)
9801 _HELP_DEFAULT_V = $(if $(AM_DEFAULT_VERBOSITY),$(AM_DEFAULT_VERBOSITY),1)
9802 _HELP_V = $(if $(V),$(V),$(_HELP_DEFAULT_V))
9803 _HELP_LC_VERBOSE = $(_HELP_LC_VERBOSE_$(_HELP_V))
9804 _HELP_LC_VERBOSE_ = $(_HELP_LC_VERBOSE_$(_HELP_DEFAULT_V))
9805 _HELP_LC_VERBOSE_0 = @echo " GEN "$(dir [$]@);
9807 all: $(_HELP_C_FILES) $(_HELP_C_EXTRA) $(_HELP_C_MEDIA) $(_HELP_LC_FILES) $(_HELP_POFILES)
9810 pot: $(_HELP_POTFILE)
9811 $(_HELP_POTFILE): $(_HELP_C_FILES) $(_HELP_C_EXTRA) $(_HELP_C_MEDIA)
9812 $(AM_V_GEN)$(ITSTOOL) -o "[$]@" $(_HELP_C_FILES)
9815 repo: $(_HELP_POTFILE)
9816 $(AM_V_at)for po in $(_HELP_POFILES); do \
9817 if test "x[$](_HELP_V)" = "x0"; then echo " GEN $${po}"; fi; \
9818 msgmerge -q -o "$${po}" "$${po}" "$(_HELP_POTFILE)"; \
9822 $(AM_V_at)if ! test -d "$(dir [$]@)"; then mkdir "$(dir [$]@)"; fi
9823 $(AM_V_at)if test ! -f "[$]@" -a -f "$(srcdir)/[$]@"; then cp "$(srcdir)/[$]@" "[$]@"; fi
9824 $(AM_V_GEN)if ! test -f "[$]@"; then \
9825 (cd "$(dir [$]@)" && \
9826 $(ITSTOOL) -o "$(notdir [$]@).tmp" $(_HELP_C_FILES) && \
9827 mv "$(notdir [$]@).tmp" "$(notdir [$]@)"); \
9829 (cd "$(dir [$]@)" && \
9830 $(ITSTOOL) -o "$(notdir [$]@).tmp" $(_HELP_C_FILES) && \
9831 msgmerge -o "$(notdir [$]@)" "$(notdir [$]@)" "$(notdir [$]@).tmp" && \
9832 rm "$(notdir [$]@).tmp"); \
9835 $(_HELP_MOFILES): %.mo: %.po
9836 $(AM_V_at)if ! test -d "$(dir [$]@)"; then mkdir "$(dir [$]@)"; fi
9837 $(AM_V_GEN)msgfmt -o "[$]@" "$<"
9839 $(_HELP_LC_FILES): $(_HELP_LINGUAS)
9840 $(_HELP_LINGUAS): $(_HELP_LC_STAMPS)
9841 $(_HELP_LC_STAMPS): %.stamp: %.mo
9842 $(_HELP_LC_STAMPS): $(_HELP_C_FILES) $(_HELP_C_EXTRA)
9843 $(AM_V_at)if ! test -d "$(dir [$]@)"; then mkdir "$(dir [$]@)"; fi
9844 $(_HELP_LC_VERBOSE)if test -d "C"; then d="../"; else d="$(abs_srcdir)/"; fi; \
9845 mo="$(dir [$]@)$(patsubst %/$(notdir [$]@),%,[$]@).mo"; \
9846 if test -f "$${mo}"; then mo="../$${mo}"; else mo="$(abs_srcdir)/$${mo}"; fi; \
9847 (cd "$(dir [$]@)" && $(ITSTOOL) -m "$${mo}" $(foreach f,$(_HELP_C_FILES),$${d}/$(f))) && \
9851 mostlyclean-am: $(if $(HELP_ID),clean-help)
9853 rm -f $(_HELP_LC_FILES) $(_HELP_LC_STAMPS) $(_HELP_MOFILES)
9856 EXTRA_DIST += $(_HELP_C_EXTRA) $(_HELP_C_MEDIA)
9857 EXTRA_DIST += $(foreach lc,$(HELP_LINGUAS),$(lc)/$(lc).stamp)
9858 EXTRA_DIST += $(foreach lc,$(HELP_LINGUAS),$(lc)/$(lc).po)
9859 EXTRA_DIST += $(foreach f,$(HELP_MEDIA),$(foreach lc,$(HELP_LINGUAS),$(wildcard $(lc)/$(f))))
9861 distdir: distdir-help-files
9863 @for lc in C $(HELP_LINGUAS); do \
9864 $(MKDIR_P) "$(distdir)/$$lc"; \
9865 for file in $(HELP_FILES); do \
9866 if test -f "$$lc/$$file"; then d=./; else d=$(srcdir)/; fi; \
9867 cp -p "$$d$$lc/$$file" "$(distdir)/$$lc/" || exit 1; \
9874 for lc in C $(_HELP_LINGUAS); do \
9875 if test -d "$$lc"; \
9880 xmlpath="$$lc:$(srcdir)/$$lc"; \
9882 for page in $(HELP_FILES); do \
9883 echo "$(XMLLINT) --noout --noent --path $$xmlpath --xinclude $$d$$lc/$$page"; \
9884 $(XMLLINT) --noout --noent --path "$$xmlpath" --xinclude "$$d$$lc/$$page"; \
9889 .PHONY: install-help
9890 install-data-am: $(if $(HELP_ID),install-help)
9892 @for lc in C $(_HELP_LINGUAS); do \
9893 $(mkinstalldirs) "$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)" || exit 1; \
9895 @for lc in C $(_HELP_LINGUAS); do for f in $(HELP_FILES); do \
9896 if test -f "$$lc/$$f"; then d=; else d="$(srcdir)/"; fi; \
9897 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
9898 if ! test -d "$$helpdir"; then $(mkinstalldirs) "$$helpdir"; fi; \
9899 echo "$(INSTALL_DATA) $$d$$lc/$$f $$helpdir`basename $$f`"; \
9900 $(INSTALL_DATA) "$$d$$lc/$$f" "$$helpdir`basename $$f`" || exit 1; \
9902 @for f in $(_HELP_C_EXTRA); do \
9903 lc=`dirname "$$f"`; lc=`basename "$$lc"`; \
9904 if test -f "$$f"; then d=; else d="$(srcdir)/"; fi; \
9905 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
9906 if ! test -d "$$helpdir"; then $(mkinstalldirs) "$$helpdir"; fi; \
9907 echo "$(INSTALL_DATA) $$d$$f $$helpdir`basename $$f`"; \
9908 $(INSTALL_DATA) "$$d$$f" "$$helpdir`basename $$f`" || exit 1; \
9910 @for f in $(HELP_MEDIA); do \
9911 for lc in C $(_HELP_LINGUAS); do \
9912 if test -f "$$lc$$f"; then d=; else d="$(srcdir)/"; fi; \
9913 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
9914 mdir=`dirname "$$f"`; \
9915 if test "x$mdir" = "x."; then mdir=""; fi; \
9916 if ! test -d "$$helpdir$$mdir"; then $(mkinstalldirs) "$$helpdir$$mdir"; fi; \
9917 if test -f "$$d$$lc/$$f"; then \
9918 echo "$(INSTALL_DATA) $$d$$lc/$$f $$helpdir$$f"; \
9919 $(INSTALL_DATA) "$$d$$lc/$$f" "$$helpdir$$f" || exit 1; \
9920 elif test "x$$lc" != "xC"; then \
9921 echo "$(LN_S) -f $(HELP_DIR)/C/$(HELP_ID)/$$f $$helpdir$$f"; \
9922 $(LN_S) -f "$(HELP_DIR)/C/$(HELP_ID)/$$f" "$$helpdir$$f" || exit 1; \
9927 .PHONY: uninstall-help
9928 uninstall-am: $(if $(HELP_ID),uninstall-help)
9930 for lc in C $(_HELP_LINGUAS); do for f in $(HELP_FILES); do \
9931 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
9932 echo "rm -f $$helpdir`basename $$f`"; \
9933 rm -f "$$helpdir`basename $$f`"; \
9935 @for f in $(_HELP_C_EXTRA); do \
9936 lc=`dirname "$$f"`; lc=`basename "$$lc"`; \
9937 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
9938 echo "rm -f $$helpdir`basename $$f`"; \
9939 rm -f "$$helpdir`basename $$f`"; \
9941 @for f in $(HELP_MEDIA); do \
9942 for lc in C $(_HELP_LINGUAS); do \
9943 helpdir="$(DESTDIR)$(HELP_DIR)/$$lc/$(HELP_ID)/"; \
9944 echo "rm -f $$helpdir$$f"; \
9945 rm -f "$$helpdir$$f"; \
9949 AC_SUBST([YELP_HELP_RULES])
9950 m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([YELP_HELP_RULES])])
9953 # Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008, 2011 Free Software
9956 # This file is free software; the Free Software Foundation
9957 # gives unlimited permission to copy and/or distribute it,
9958 # with or without modifications, as long as this notice is preserved.
9962 # AM_AUTOMAKE_VERSION(VERSION)
9963 # ----------------------------
9964 # Automake X.Y traces this macro to ensure aclocal.m4 has been
9965 # generated from the m4 files accompanying Automake X.Y.
9966 # (This private macro should not be called outside this file.)
9967 AC_DEFUN([AM_AUTOMAKE_VERSION],
9968 [am__api_version='1.11'
9969 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
9970 dnl require some minimum version. Point them to the right macro.
9971 m4_if([$1], [1.11.6], [],
9972 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
9975 # _AM_AUTOCONF_VERSION(VERSION)
9976 # -----------------------------
9977 # aclocal traces this macro to find the Autoconf version.
9978 # This is a private macro too. Using m4_define simplifies
9979 # the logic in aclocal, which can simply ignore this definition.
9980 m4_define([_AM_AUTOCONF_VERSION], [])
9982 # AM_SET_CURRENT_AUTOMAKE_VERSION
9983 # -------------------------------
9984 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
9985 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
9986 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
9987 [AM_AUTOMAKE_VERSION([1.11.6])dnl
9988 m4_ifndef([AC_AUTOCONF_VERSION],
9989 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
9990 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
9992 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
9994 # Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
9996 # This file is free software; the Free Software Foundation
9997 # gives unlimited permission to copy and/or distribute it,
9998 # with or without modifications, as long as this notice is preserved.
10002 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
10003 # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
10004 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
10006 # Of course, Automake must honor this variable whenever it calls a
10007 # tool from the auxiliary directory. The problem is that $srcdir (and
10008 # therefore $ac_aux_dir as well) can be either absolute or relative,
10009 # depending on how configure is run. This is pretty annoying, since
10010 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
10011 # source directory, any form will work fine, but in subdirectories a
10012 # relative path needs to be adjusted first.
10014 # $ac_aux_dir/missing
10015 # fails when called from a subdirectory if $ac_aux_dir is relative
10016 # $top_srcdir/$ac_aux_dir/missing
10017 # fails if $ac_aux_dir is absolute,
10018 # fails when called from a subdirectory in a VPATH build with
10019 # a relative $ac_aux_dir
10021 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
10022 # are both prefixed by $srcdir. In an in-source build this is usually
10023 # harmless because $srcdir is `.', but things will broke when you
10024 # start a VPATH build or use an absolute $srcdir.
10026 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
10027 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
10028 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
10029 # and then we would define $MISSING as
10030 # MISSING="\${SHELL} $am_aux_dir/missing"
10031 # This will work as long as MISSING is not called from configure, because
10032 # unfortunately $(top_srcdir) has no meaning in configure.
10033 # However there are other variables, like CC, which are often used in
10034 # configure, and could therefore not use this "fixed" $ac_aux_dir.
10036 # Another solution, used here, is to always expand $ac_aux_dir to an
10037 # absolute PATH. The drawback is that using absolute paths prevent a
10038 # configured tree to be moved without reconfiguration.
10040 AC_DEFUN([AM_AUX_DIR_EXPAND],
10041 [dnl Rely on autoconf to set up CDPATH properly.
10042 AC_PREREQ([2.50])dnl
10043 # expand $ac_aux_dir to an absolute path
10044 am_aux_dir=`cd $ac_aux_dir && pwd`
10047 # AM_CONDITIONAL -*- Autoconf -*-
10049 # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
10050 # Free Software Foundation, Inc.
10052 # This file is free software; the Free Software Foundation
10053 # gives unlimited permission to copy and/or distribute it,
10054 # with or without modifications, as long as this notice is preserved.
10058 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
10059 # -------------------------------------
10060 # Define a conditional.
10061 AC_DEFUN([AM_CONDITIONAL],
10062 [AC_PREREQ(2.52)dnl
10063 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
10064 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
10065 AC_SUBST([$1_TRUE])dnl
10066 AC_SUBST([$1_FALSE])dnl
10067 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
10068 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
10069 m4_define([_AM_COND_VALUE_$1], [$2])dnl
10077 AC_CONFIG_COMMANDS_PRE(
10078 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
10079 AC_MSG_ERROR([[conditional "$1" was never defined.
10080 Usually this means the macro was only invoked conditionally.]])
10083 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009,
10084 # 2010, 2011 Free Software Foundation, Inc.
10086 # This file is free software; the Free Software Foundation
10087 # gives unlimited permission to copy and/or distribute it,
10088 # with or without modifications, as long as this notice is preserved.
10092 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
10093 # written in clear, in which case automake, when reading aclocal.m4,
10094 # will think it sees a *use*, and therefore will trigger all it's
10095 # C support machinery. Also note that it means that autoscan, seeing
10096 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
10099 # _AM_DEPENDENCIES(NAME)
10100 # ----------------------
10101 # See how the compiler implements dependency checking.
10102 # NAME is "CC", "CXX", "GCJ", or "OBJC".
10103 # We try a few techniques and use that to set a single cache variable.
10105 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
10106 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
10107 # dependency, and given that the user is not expected to run this macro,
10108 # just rely on AC_PROG_CC.
10109 AC_DEFUN([_AM_DEPENDENCIES],
10110 [AC_REQUIRE([AM_SET_DEPDIR])dnl
10111 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
10112 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
10113 AC_REQUIRE([AM_DEP_TRACK])dnl
10115 ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
10116 [$1], CXX, [depcc="$CXX" am_compiler_list=],
10117 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
10118 [$1], UPC, [depcc="$UPC" am_compiler_list=],
10119 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
10120 [depcc="$$1" am_compiler_list=])
10122 AC_CACHE_CHECK([dependency style of $depcc],
10123 [am_cv_$1_dependencies_compiler_type],
10124 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
10125 # We make a subdir and do the tests there. Otherwise we can end up
10126 # making bogus files that we don't know about and never remove. For
10127 # instance it was reported that on HP-UX the gcc test will end up
10128 # making a dummy file named `D' -- because `-MD' means `put the output
10130 rm -rf conftest.dir
10132 # Copy depcomp to subdir because otherwise we won't find it if we're
10133 # using a relative directory.
10134 cp "$am_depcomp" conftest.dir
10136 # We will build objects and dependencies in a subdirectory because
10137 # it helps to detect inapplicable dependency modes. For instance
10138 # both Tru64's cc and ICC support -MD to output dependencies as a
10139 # side effect of compilation, but ICC will put the dependencies in
10140 # the current directory while Tru64 will put them in the object
10144 am_cv_$1_dependencies_compiler_type=none
10145 if test "$am_compiler_list" = ""; then
10146 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
10148 am__universal=false
10149 m4_case([$1], [CC],
10150 [case " $depcc " in #(
10151 *\ -arch\ *\ -arch\ *) am__universal=true ;;
10154 [case " $depcc " in #(
10155 *\ -arch\ *\ -arch\ *) am__universal=true ;;
10158 for depmode in $am_compiler_list; do
10159 # Setup a source with many dependencies, because some compilers
10160 # like to wrap large dependency lists on column 80 (with \), and
10161 # we should not choose a depcomp mode which is confused by this.
10163 # We need to recreate these files for each test, as the compiler may
10164 # overwrite some of them when testing with obscure command lines.
10165 # This happens at least with the AIX C compiler.
10167 for i in 1 2 3 4 5 6; do
10168 echo '#include "conftst'$i'.h"' >> sub/conftest.c
10169 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
10170 # Solaris 8's {/usr,}/bin/sh.
10171 touch sub/conftst$i.h
10173 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
10175 # We check with `-c' and `-o' for the sake of the "dashmstdout"
10176 # mode. It turns out that the SunPro C++ compiler does not properly
10177 # handle `-M -o', and we need to detect this. Also, some Intel
10178 # versions had trouble with output in subdirs
10179 am__obj=sub/conftest.${OBJEXT-o}
10180 am__minus_obj="-o $am__obj"
10183 # This depmode causes a compiler race in universal mode.
10184 test "$am__universal" = false || continue
10187 # after this tag, mechanisms are not by side-effect, so they'll
10188 # only be used when explicitly requested
10189 if test "x$enable_dependency_tracking" = xyes; then
10195 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
10196 # This compiler won't grok `-c -o', but also, the minuso test has
10197 # not run yet. These depmodes are late enough in the game, and
10198 # so weak that their functioning should not be impacted.
10199 am__obj=conftest.${OBJEXT-o}
10204 if depmode=$depmode \
10205 source=sub/conftest.c object=$am__obj \
10206 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
10207 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
10208 >/dev/null 2>conftest.err &&
10209 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
10210 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
10211 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
10212 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
10213 # icc doesn't choke on unknown options, it will just issue warnings
10214 # or remarks (even with -Werror). So we grep stderr for any message
10215 # that says an option was ignored or not supported.
10216 # When given -MP, icc 7.0 and 7.1 complain thusly:
10217 # icc: Command line warning: ignoring option '-M'; no argument required
10218 # The diagnosis changed in icc 8.0:
10219 # icc: Command line remark: option '-MP' not supported
10220 if (grep 'ignoring option' conftest.err ||
10221 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
10222 am_cv_$1_dependencies_compiler_type=$depmode
10229 rm -rf conftest.dir
10231 am_cv_$1_dependencies_compiler_type=none
10234 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
10235 AM_CONDITIONAL([am__fastdep$1], [
10236 test "x$enable_dependency_tracking" != xno \
10237 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
10243 # Choose a directory name for dependency files.
10244 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
10245 AC_DEFUN([AM_SET_DEPDIR],
10246 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10247 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
10253 AC_DEFUN([AM_DEP_TRACK],
10254 [AC_ARG_ENABLE(dependency-tracking,
10255 [ --disable-dependency-tracking speeds up one-time build
10256 --enable-dependency-tracking do not reject slow dependency extractors])
10257 if test "x$enable_dependency_tracking" != xno; then
10258 am_depcomp="$ac_aux_dir/depcomp"
10262 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
10263 AC_SUBST([AMDEPBACKSLASH])dnl
10264 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
10265 AC_SUBST([am__nodep])dnl
10266 _AM_SUBST_NOTMAKE([am__nodep])dnl
10269 # Generate code to set up dependency tracking. -*- Autoconf -*-
10271 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
10272 # Free Software Foundation, Inc.
10274 # This file is free software; the Free Software Foundation
10275 # gives unlimited permission to copy and/or distribute it,
10276 # with or without modifications, as long as this notice is preserved.
10280 # _AM_OUTPUT_DEPENDENCY_COMMANDS
10281 # ------------------------------
10282 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
10284 # Autoconf 2.62 quotes --file arguments for eval, but not when files
10285 # are listed without --file. Let's play safe and only enable the eval
10286 # if we detect the quoting.
10287 case $CONFIG_FILES in
10288 *\'*) eval set x "$CONFIG_FILES" ;;
10289 *) set x $CONFIG_FILES ;;
10294 # Strip MF so we end up with the name of the file.
10295 mf=`echo "$mf" | sed -e 's/:.*$//'`
10296 # Check whether this is an Automake generated Makefile or not.
10297 # We used to match only the files named `Makefile.in', but
10298 # some people rename them; so instead we look at the file content.
10299 # Grep'ing the first line is not enough: some people post-process
10300 # each Makefile.in and add a new line on top of each file to say so.
10301 # Grep'ing the whole file is not good either: AIX grep has a line
10302 # limit of 2048, but all sed's we know have understand at least 4000.
10303 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
10304 dirpart=`AS_DIRNAME("$mf")`
10308 # Extract the definition of DEPDIR, am__include, and am__quote
10309 # from the Makefile without running `make'.
10310 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
10311 test -z "$DEPDIR" && continue
10312 am__include=`sed -n 's/^am__include = //p' < "$mf"`
10313 test -z "am__include" && continue
10314 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
10315 # When using ansi2knr, U may be empty or an underscore; expand it
10316 U=`sed -n 's/^U = //p' < "$mf"`
10317 # Find all dependency output files, they are included files with
10318 # $(DEPDIR) in their names. We invoke sed twice because it is the
10319 # simplest approach to changing $(DEPDIR) to its actual value in the
10321 for file in `sed -n "
10322 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
10323 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
10324 # Make sure the directory exists.
10325 test -f "$dirpart/$file" && continue
10326 fdir=`AS_DIRNAME(["$file"])`
10327 AS_MKDIR_P([$dirpart/$fdir])
10328 # echo "creating $dirpart/$file"
10329 echo '# dummy' > "$dirpart/$file"
10333 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
10336 # AM_OUTPUT_DEPENDENCY_COMMANDS
10337 # -----------------------------
10338 # This macro should only be invoked once -- use via AC_REQUIRE.
10340 # This code is only required when automatic dependency tracking
10341 # is enabled. FIXME. This creates each `.P' file that we will
10342 # need in order to bootstrap the dependency handling code.
10343 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
10344 [AC_CONFIG_COMMANDS([depfiles],
10345 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
10346 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
10349 # Do all the work for Automake. -*- Autoconf -*-
10351 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
10352 # 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
10354 # This file is free software; the Free Software Foundation
10355 # gives unlimited permission to copy and/or distribute it,
10356 # with or without modifications, as long as this notice is preserved.
10360 # This macro actually does too much. Some checks are only needed if
10361 # your package does certain things. But this isn't really a big deal.
10363 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
10364 # AM_INIT_AUTOMAKE([OPTIONS])
10365 # -----------------------------------------------
10366 # The call with PACKAGE and VERSION arguments is the old style
10367 # call (pre autoconf-2.50), which is being phased out. PACKAGE
10368 # and VERSION should now be passed to AC_INIT and removed from
10369 # the call to AM_INIT_AUTOMAKE.
10370 # We support both call styles for the transition. After
10371 # the next Automake release, Autoconf can make the AC_INIT
10372 # arguments mandatory, and then we can depend on a new Autoconf
10373 # release and drop the old call support.
10374 AC_DEFUN([AM_INIT_AUTOMAKE],
10375 [AC_PREREQ([2.62])dnl
10376 dnl Autoconf wants to disallow AM_ names. We explicitly allow
10377 dnl the ones we care about.
10378 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
10379 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
10380 AC_REQUIRE([AC_PROG_INSTALL])dnl
10381 if test "`cd $srcdir && pwd`" != "`pwd`"; then
10382 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
10383 # is not polluted with repeated "-I."
10384 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
10385 # test to see if srcdir already configured
10386 if test -f $srcdir/config.status; then
10387 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
10391 # test whether we have cygpath
10392 if test -z "$CYGPATH_W"; then
10393 if (cygpath --version) >/dev/null 2>/dev/null; then
10394 CYGPATH_W='cygpath -w'
10399 AC_SUBST([CYGPATH_W])
10401 # Define the identity of the package.
10402 dnl Distinguish between old-style and new-style calls.
10404 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
10405 AC_SUBST([PACKAGE], [$1])dnl
10406 AC_SUBST([VERSION], [$2])],
10407 [_AM_SET_OPTIONS([$1])dnl
10408 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
10409 m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
10410 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
10411 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
10412 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
10414 _AM_IF_OPTION([no-define],,
10415 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
10416 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
10418 # Some tools Automake needs.
10419 AC_REQUIRE([AM_SANITY_CHECK])dnl
10420 AC_REQUIRE([AC_ARG_PROGRAM])dnl
10421 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
10422 AM_MISSING_PROG(AUTOCONF, autoconf)
10423 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
10424 AM_MISSING_PROG(AUTOHEADER, autoheader)
10425 AM_MISSING_PROG(MAKEINFO, makeinfo)
10426 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10427 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
10428 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
10429 # We need awk for the "check" target. The system "awk" is bad on
10431 AC_REQUIRE([AC_PROG_AWK])dnl
10432 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
10433 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
10434 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
10435 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
10436 [_AM_PROG_TAR([v7])])])
10437 _AM_IF_OPTION([no-dependencies],,
10438 [AC_PROVIDE_IFELSE([AC_PROG_CC],
10439 [_AM_DEPENDENCIES(CC)],
10440 [define([AC_PROG_CC],
10441 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
10442 AC_PROVIDE_IFELSE([AC_PROG_CXX],
10443 [_AM_DEPENDENCIES(CXX)],
10444 [define([AC_PROG_CXX],
10445 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
10446 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
10447 [_AM_DEPENDENCIES(OBJC)],
10448 [define([AC_PROG_OBJC],
10449 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
10451 _AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
10452 dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
10453 dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
10454 dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
10455 AC_CONFIG_COMMANDS_PRE(dnl
10456 [m4_provide_if([_AM_COMPILER_EXEEXT],
10457 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
10460 dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
10461 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
10462 dnl mangled by Autoconf and run in a shell conditional statement.
10463 m4_define([_AC_COMPILER_EXEEXT],
10464 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
10467 # When config.status generates a header, we must update the stamp-h file.
10468 # This file resides in the same directory as the config header
10469 # that is generated. The stamp files are numbered to have different names.
10471 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
10472 # loop where config.status creates the headers, so we can generate
10473 # our stamp files there.
10474 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
10475 [# Compute $1's index in $config_headers.
10478 for _am_header in $config_headers :; do
10479 case $_am_header in
10480 $_am_arg | $_am_arg:* )
10483 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
10486 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
10488 # Copyright (C) 2001, 2003, 2005, 2008, 2011 Free Software Foundation,
10491 # This file is free software; the Free Software Foundation
10492 # gives unlimited permission to copy and/or distribute it,
10493 # with or without modifications, as long as this notice is preserved.
10497 # AM_PROG_INSTALL_SH
10498 # ------------------
10499 # Define $install_sh.
10500 AC_DEFUN([AM_PROG_INSTALL_SH],
10501 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10502 if test x"${install_sh}" != xset; then
10503 case $am_aux_dir in
10505 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
10507 install_sh="\${SHELL} $am_aux_dir/install-sh"
10510 AC_SUBST(install_sh)])
10512 # Copyright (C) 2003, 2005 Free Software Foundation, Inc.
10514 # This file is free software; the Free Software Foundation
10515 # gives unlimited permission to copy and/or distribute it,
10516 # with or without modifications, as long as this notice is preserved.
10520 # Check whether the underlying file-system supports filenames
10521 # with a leading dot. For instance MS-DOS doesn't.
10522 AC_DEFUN([AM_SET_LEADING_DOT],
10523 [rm -rf .tst 2>/dev/null
10524 mkdir .tst 2>/dev/null
10525 if test -d .tst; then
10530 rmdir .tst 2>/dev/null
10531 AC_SUBST([am__leading_dot])])
10533 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
10534 # From Jim Meyering
10536 # Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008,
10537 # 2011 Free Software Foundation, Inc.
10539 # This file is free software; the Free Software Foundation
10540 # gives unlimited permission to copy and/or distribute it,
10541 # with or without modifications, as long as this notice is preserved.
10545 # AM_MAINTAINER_MODE([DEFAULT-MODE])
10546 # ----------------------------------
10547 # Control maintainer-specific portions of Makefiles.
10548 # Default is to disable them, unless `enable' is passed literally.
10549 # For symmetry, `disable' may be passed as well. Anyway, the user
10550 # can override the default with the --enable/--disable switch.
10551 AC_DEFUN([AM_MAINTAINER_MODE],
10552 [m4_case(m4_default([$1], [disable]),
10553 [enable], [m4_define([am_maintainer_other], [disable])],
10554 [disable], [m4_define([am_maintainer_other], [enable])],
10555 [m4_define([am_maintainer_other], [enable])
10556 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
10557 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
10558 dnl maintainer-mode's default is 'disable' unless 'enable' is passed
10559 AC_ARG_ENABLE([maintainer-mode],
10560 [ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful
10561 (and sometimes confusing) to the casual installer],
10562 [USE_MAINTAINER_MODE=$enableval],
10563 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
10564 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
10565 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
10566 MAINT=$MAINTAINER_MODE_TRUE
10567 AC_SUBST([MAINT])dnl
10571 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
10573 # Check to see how 'make' treats includes. -*- Autoconf -*-
10575 # Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc.
10577 # This file is free software; the Free Software Foundation
10578 # gives unlimited permission to copy and/or distribute it,
10579 # with or without modifications, as long as this notice is preserved.
10583 # AM_MAKE_INCLUDE()
10584 # -----------------
10585 # Check to see how make treats includes.
10586 AC_DEFUN([AM_MAKE_INCLUDE],
10587 [am_make=${MAKE-make}
10588 cat > confinc << 'END'
10590 @echo this is the am__doit target
10593 # If we don't find an include directive, just comment out the code.
10594 AC_MSG_CHECKING([for style of include used by $am_make])
10598 # First try GNU make style include.
10599 echo "include confinc" > confmf
10600 # Ignore all kinds of additional output from `make'.
10601 case `$am_make -s -f confmf 2> /dev/null` in #(
10602 *the\ am__doit\ target*)
10603 am__include=include
10608 # Now try BSD make style include.
10609 if test "$am__include" = "#"; then
10610 echo '.include "confinc"' > confmf
10611 case `$am_make -s -f confmf 2> /dev/null` in #(
10612 *the\ am__doit\ target*)
10613 am__include=.include
10619 AC_SUBST([am__include])
10620 AC_SUBST([am__quote])
10621 AC_MSG_RESULT([$_am_result])
10622 rm -f confinc confmf
10625 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
10627 # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
10628 # Free Software Foundation, Inc.
10630 # This file is free software; the Free Software Foundation
10631 # gives unlimited permission to copy and/or distribute it,
10632 # with or without modifications, as long as this notice is preserved.
10636 # AM_MISSING_PROG(NAME, PROGRAM)
10637 # ------------------------------
10638 AC_DEFUN([AM_MISSING_PROG],
10639 [AC_REQUIRE([AM_MISSING_HAS_RUN])
10640 $1=${$1-"${am_missing_run}$2"}
10644 # AM_MISSING_HAS_RUN
10645 # ------------------
10646 # Define MISSING if not defined so far and test if it supports --run.
10647 # If it does, set am_missing_run to use it, otherwise, to nothing.
10648 AC_DEFUN([AM_MISSING_HAS_RUN],
10649 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10650 AC_REQUIRE_AUX_FILE([missing])dnl
10651 if test x"${MISSING+set}" != xset; then
10652 case $am_aux_dir in
10654 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
10656 MISSING="\${SHELL} $am_aux_dir/missing" ;;
10659 # Use eval to expand $SHELL
10660 if eval "$MISSING --run true"; then
10661 am_missing_run="$MISSING --run "
10664 AC_MSG_WARN([`missing' script is too old or missing])
10668 # Copyright (C) 2003, 2004, 2005, 2006, 2011 Free Software Foundation,
10671 # This file is free software; the Free Software Foundation
10672 # gives unlimited permission to copy and/or distribute it,
10673 # with or without modifications, as long as this notice is preserved.
10679 # Check for `mkdir -p'.
10680 AC_DEFUN([AM_PROG_MKDIR_P],
10681 [AC_PREREQ([2.60])dnl
10682 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
10683 dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
10684 dnl while keeping a definition of mkdir_p for backward compatibility.
10685 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
10686 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
10687 dnl Makefile.ins that do not define MKDIR_P, so we do our own
10688 dnl adjustment using top_builddir (which is defined more often than
10690 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
10692 [[\\/$]]* | ?:[[\\/]]*) ;;
10693 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
10697 # Helper functions for option handling. -*- Autoconf -*-
10699 # Copyright (C) 2001, 2002, 2003, 2005, 2008, 2010 Free Software
10702 # This file is free software; the Free Software Foundation
10703 # gives unlimited permission to copy and/or distribute it,
10704 # with or without modifications, as long as this notice is preserved.
10708 # _AM_MANGLE_OPTION(NAME)
10709 # -----------------------
10710 AC_DEFUN([_AM_MANGLE_OPTION],
10711 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
10713 # _AM_SET_OPTION(NAME)
10714 # --------------------
10715 # Set option NAME. Presently that only means defining a flag for this option.
10716 AC_DEFUN([_AM_SET_OPTION],
10717 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
10719 # _AM_SET_OPTIONS(OPTIONS)
10720 # ------------------------
10721 # OPTIONS is a space-separated list of Automake options.
10722 AC_DEFUN([_AM_SET_OPTIONS],
10723 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
10725 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
10726 # -------------------------------------------
10727 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
10728 AC_DEFUN([_AM_IF_OPTION],
10729 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
10731 # Check to make sure that the build environment is sane. -*- Autoconf -*-
10733 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
10734 # Free Software Foundation, Inc.
10736 # This file is free software; the Free Software Foundation
10737 # gives unlimited permission to copy and/or distribute it,
10738 # with or without modifications, as long as this notice is preserved.
10744 AC_DEFUN([AM_SANITY_CHECK],
10745 [AC_MSG_CHECKING([whether build environment is sane])
10748 echo timestamp > conftest.file
10749 # Reject unsafe characters in $srcdir or the absolute working directory
10750 # name. Accept space and tab only in the latter.
10754 *[[\\\"\#\$\&\'\`$am_lf]]*)
10755 AC_MSG_ERROR([unsafe absolute working directory name]);;
10758 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
10759 AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
10762 # Do `set' in a subshell so we don't clobber the current shell's
10763 # arguments. Must try -L first in case configure is actually a
10764 # symlink; some systems play weird games with the mod time of symlinks
10765 # (eg FreeBSD returns the mod time of the symlink's containing
10768 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
10769 if test "$[*]" = "X"; then
10771 set X `ls -t "$srcdir/configure" conftest.file`
10773 rm -f conftest.file
10774 if test "$[*]" != "X $srcdir/configure conftest.file" \
10775 && test "$[*]" != "X conftest.file $srcdir/configure"; then
10777 # If neither matched, then we have a broken ls. This can happen
10778 # if, for instance, CONFIG_SHELL is bash and it inherits a
10779 # broken ls alias from the environment. This has actually
10780 # happened. Such a system could not be considered "sane".
10781 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
10782 alias in your environment])
10785 test "$[2]" = conftest.file
10791 AC_MSG_ERROR([newly created file is older than distributed files!
10792 Check your system clock])
10794 AC_MSG_RESULT(yes)])
10796 # Copyright (C) 2009, 2011 Free Software Foundation, Inc.
10798 # This file is free software; the Free Software Foundation
10799 # gives unlimited permission to copy and/or distribute it,
10800 # with or without modifications, as long as this notice is preserved.
10804 # AM_SILENT_RULES([DEFAULT])
10805 # --------------------------
10806 # Enable less verbose build rules; with the default set to DEFAULT
10807 # (`yes' being less verbose, `no' or empty being verbose).
10808 AC_DEFUN([AM_SILENT_RULES],
10809 [AC_ARG_ENABLE([silent-rules],
10810 [ --enable-silent-rules less verbose build output (undo: `make V=1')
10811 --disable-silent-rules verbose build output (undo: `make V=0')])
10812 case $enable_silent_rules in
10813 yes) AM_DEFAULT_VERBOSITY=0;;
10814 no) AM_DEFAULT_VERBOSITY=1;;
10815 *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
10818 dnl A few `make' implementations (e.g., NonStop OS and NextStep)
10819 dnl do not support nested variable expansions.
10820 dnl See automake bug#9928 and bug#10237.
10821 am_make=${MAKE-make}
10822 AC_CACHE_CHECK([whether $am_make supports nested variables],
10823 [am_cv_make_support_nested_variables],
10824 [if AS_ECHO([['TRUE=$(BAR$(V))
10830 .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
10831 am_cv_make_support_nested_variables=yes
10833 am_cv_make_support_nested_variables=no
10835 if test $am_cv_make_support_nested_variables = yes; then
10836 dnl Using `$V' instead of `$(V)' breaks IRIX make.
10838 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
10840 AM_V=$AM_DEFAULT_VERBOSITY
10841 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
10843 AC_SUBST([AM_V])dnl
10844 AM_SUBST_NOTMAKE([AM_V])dnl
10845 AC_SUBST([AM_DEFAULT_V])dnl
10846 AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
10847 AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
10849 AC_SUBST([AM_BACKSLASH])dnl
10850 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
10853 # Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
10855 # This file is free software; the Free Software Foundation
10856 # gives unlimited permission to copy and/or distribute it,
10857 # with or without modifications, as long as this notice is preserved.
10861 # AM_PROG_INSTALL_STRIP
10862 # ---------------------
10863 # One issue with vendor `install' (even GNU) is that you can't
10864 # specify the program used to strip binaries. This is especially
10865 # annoying in cross-compiling environments, where the build's strip
10866 # is unlikely to handle the host's binaries.
10867 # Fortunately install-sh will honor a STRIPPROG variable, so we
10868 # always use install-sh in `make install-strip', and initialize
10869 # STRIPPROG with the value of the STRIP variable (set by the user).
10870 AC_DEFUN([AM_PROG_INSTALL_STRIP],
10871 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10872 # Installed binaries are usually stripped using `strip' when the user
10873 # run `make install-strip'. However `strip' might not be the right
10874 # tool to use in cross-compilation environments, therefore Automake
10875 # will honor the `STRIP' environment variable to overrule this program.
10876 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
10877 if test "$cross_compiling" != no; then
10878 AC_CHECK_TOOL([STRIP], [strip], :)
10880 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
10881 AC_SUBST([INSTALL_STRIP_PROGRAM])])
10883 # Copyright (C) 2006, 2008, 2010 Free Software Foundation, Inc.
10885 # This file is free software; the Free Software Foundation
10886 # gives unlimited permission to copy and/or distribute it,
10887 # with or without modifications, as long as this notice is preserved.
10891 # _AM_SUBST_NOTMAKE(VARIABLE)
10892 # ---------------------------
10893 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
10894 # This macro is traced by Automake.
10895 AC_DEFUN([_AM_SUBST_NOTMAKE])
10897 # AM_SUBST_NOTMAKE(VARIABLE)
10898 # --------------------------
10899 # Public sister of _AM_SUBST_NOTMAKE.
10900 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
10902 # Check how to create a tarball. -*- Autoconf -*-
10904 # Copyright (C) 2004, 2005, 2012 Free Software Foundation, Inc.
10906 # This file is free software; the Free Software Foundation
10907 # gives unlimited permission to copy and/or distribute it,
10908 # with or without modifications, as long as this notice is preserved.
10912 # _AM_PROG_TAR(FORMAT)
10913 # --------------------
10914 # Check how to create a tarball in format FORMAT.
10915 # FORMAT should be one of `v7', `ustar', or `pax'.
10917 # Substitute a variable $(am__tar) that is a command
10918 # writing to stdout a FORMAT-tarball containing the directory
10920 # tardir=directory && $(am__tar) > result.tar
10922 # Substitute a variable $(am__untar) that extract such
10923 # a tarball read from stdin.
10924 # $(am__untar) < result.tar
10925 AC_DEFUN([_AM_PROG_TAR],
10926 [# Always define AMTAR for backward compatibility. Yes, it's still used
10927 # in the wild :-( We should find a proper way to deprecate it ...
10928 AC_SUBST([AMTAR], ['$${TAR-tar}'])
10930 [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
10931 [m4_case([$1], [ustar],, [pax],,
10932 [m4_fatal([Unknown tar format])])
10933 AC_MSG_CHECKING([how to create a $1 tar archive])
10934 # Loop over all known methods to create a tar archive until one works.
10935 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
10936 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
10937 # Do not fold the above two line into one, because Tru64 sh and
10938 # Solaris sh will not grok spaces in the rhs of `-'.
10939 for _am_tool in $_am_tools
10943 for _am_tar in tar gnutar gtar;
10945 AM_RUN_LOG([$_am_tar --version]) && break
10947 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
10948 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
10949 am__untar="$_am_tar -xf -"
10952 # Must skip GNU tar: if it does not support --format= it doesn't create
10953 # ustar tarball either.
10954 (tar --version) >/dev/null 2>&1 && continue
10955 am__tar='tar chf - "$$tardir"'
10956 am__tar_='tar chf - "$tardir"'
10957 am__untar='tar xf -'
10960 am__tar='pax -L -x $1 -w "$$tardir"'
10961 am__tar_='pax -L -x $1 -w "$tardir"'
10965 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
10966 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
10967 am__untar='cpio -i -H $1 -d'
10976 # If the value was cached, stop now. We just wanted to have am__tar
10977 # and am__untar set.
10978 test -n "${am_cv_prog_tar_$1}" && break
10980 # tar/untar a dummy directory, and stop if the command works
10981 rm -rf conftest.dir
10983 echo GrepMe > conftest.dir/file
10984 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
10985 rm -rf conftest.dir
10986 if test -s conftest.tar; then
10987 AM_RUN_LOG([$am__untar <conftest.tar])
10988 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
10991 rm -rf conftest.dir
10993 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
10994 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
10995 AC_SUBST([am__tar])
10996 AC_SUBST([am__untar])