Merge lp:~dbusmenu-team/libdbusmenu/ubuntu into lp:~ubuntu-desktop/libdbusmenu/ubuntu

Proposed by Ted Gould
Status: Merged
Merged at revision: 76
Proposed branch: lp:~dbusmenu-team/libdbusmenu/ubuntu
Merge into: lp:~ubuntu-desktop/libdbusmenu/ubuntu
Diff against target: 8975 lines (+208/-8363)
21 files modified
Makefile.in (+5/-1)
aclocal.m4 (+7/-8255)
configure (+11/-11)
configure.ac (+3/-3)
debian/changelog (+23/-0)
debian/gir1.0-dbusmenu-glib-0.2.install (+1/-1)
debian/libdbusmenu-glib-dev.install (+2/-2)
libdbusmenu-glib/Makefile.am (+14/-10)
libdbusmenu-glib/Makefile.in (+15/-10)
libdbusmenu-glib/client.c (+3/-0)
libdbusmenu-glib/dbus-menu.xml (+9/-3)
libdbusmenu-glib/menuitem.c (+3/-3)
libdbusmenu-glib/menuitem.h (+58/-53)
libdbusmenu-glib/server.c (+2/-2)
libdbusmenu-gtk/Makefile.am (+6/-3)
libdbusmenu-gtk/Makefile.in (+7/-3)
libdbusmenu-gtk/client.c (+23/-0)
libdbusmenu-gtk/client.h (+1/-0)
tests/Makefile.in (+5/-1)
tools/Makefile.in (+5/-1)
tools/testapp/Makefile.in (+5/-1)
To merge this branch: bzr merge lp:~dbusmenu-team/libdbusmenu/ubuntu
Reviewer Review Type Date Requested Status
Ken VanDine Pending
Review via email: mp+26225@code.launchpad.net

Description of the change

0.3.0

To post a comment you must log in.
lp:~dbusmenu-team/libdbusmenu/ubuntu updated
75. By Ken VanDine

* New upstream release.
  * Add function to get submenu of GTK-ified items
  * Fix signal prototype of ID update
  * Fixing up VAPI files to build them correctly
 * Fixing the version string in the GIR file
  * Fix documentation title page
  * Reject text nodes early (warnings with Qt integration)
* debian/libdbusmenu-glib-dev.install: Updating gir and vapi file
  names for package list.
* debian/gir1.0-dbusmenu-glib-0.2.install: Changing the name of the
  typelib file.

76. By Ken VanDine

Fix annotations for GIR scanner

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'Makefile.in'
--- Makefile.in 2010-04-01 14:09:51 +0000
+++ Makefile.in 2010-06-04 19:44:24 +0000
@@ -40,7 +40,11 @@
40 compile config.guess config.sub depcomp install-sh ltmain.sh \40 compile config.guess config.sub depcomp install-sh ltmain.sh \
41 missing mkinstalldirs41 missing mkinstalldirs
42ACLOCAL_M4 = $(top_srcdir)/aclocal.m442ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
43am__aclocal_m4_deps = $(top_srcdir)/configure.ac43am__aclocal_m4_deps = $(top_srcdir)/m4/intltool.m4 \
44 $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \
45 $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
46 $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
47 $(top_srcdir)/configure.ac
44am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \48am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
45 $(ACLOCAL_M4)49 $(ACLOCAL_M4)
46am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \50am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
4751
=== modified file 'aclocal.m4'
--- aclocal.m4 2010-04-01 14:09:51 +0000
+++ aclocal.m4 2010-06-04 19:44:24 +0000
@@ -452,8261 +452,6 @@
452fi])452fi])
453453
454454
455
456dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
457# serial 40 IT_PROG_INTLTOOL
458AC_DEFUN([IT_PROG_INTLTOOL], [
459AC_PREREQ([2.50])dnl
460AC_REQUIRE([AM_NLS])dnl
461
462case "$am__api_version" in
463 1.[01234])
464 AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
465 ;;
466 *)
467 ;;
468esac
469
470if test -n "$1"; then
471 AC_MSG_CHECKING([for intltool >= $1])
472
473 INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
474 INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
475 [INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
476 ]
477 AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
478 test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
479 AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.])
480fi
481
482AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
483AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
484AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
485if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
486 AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
487fi
488
489 INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
490INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
491 INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
492 INTLTOOL_PROP_RULE='%.prop: %.prop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
493 INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -p $(top_srcdir)/po $< [$]@'
494 INTLTOOL_PONG_RULE='%.pong: %.pong.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
495 INTLTOOL_SERVER_RULE='%.server: %.server.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
496 INTLTOOL_SHEET_RULE='%.sheet: %.sheet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
497INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
498 INTLTOOL_UI_RULE='%.ui: %.ui.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
499 INTLTOOL_XML_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
500 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< [$]@'
501 INTLTOOL_XAM_RULE='%.xam: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
502 INTLTOOL_KBD_RULE='%.kbd: %.kbd.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
503 INTLTOOL_CAVES_RULE='%.caves: %.caves.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
504 INTLTOOL_SCHEMAS_RULE='%.schemas: %.schemas.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
505 INTLTOOL_THEME_RULE='%.theme: %.theme.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
506 INTLTOOL_SERVICE_RULE='%.service: %.service.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
507 INTLTOOL_POLICY_RULE='%.policy: %.policy.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
508
509_IT_SUBST(INTLTOOL_DESKTOP_RULE)
510_IT_SUBST(INTLTOOL_DIRECTORY_RULE)
511_IT_SUBST(INTLTOOL_KEYS_RULE)
512_IT_SUBST(INTLTOOL_PROP_RULE)
513_IT_SUBST(INTLTOOL_OAF_RULE)
514_IT_SUBST(INTLTOOL_PONG_RULE)
515_IT_SUBST(INTLTOOL_SERVER_RULE)
516_IT_SUBST(INTLTOOL_SHEET_RULE)
517_IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
518_IT_SUBST(INTLTOOL_UI_RULE)
519_IT_SUBST(INTLTOOL_XAM_RULE)
520_IT_SUBST(INTLTOOL_KBD_RULE)
521_IT_SUBST(INTLTOOL_XML_RULE)
522_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
523_IT_SUBST(INTLTOOL_CAVES_RULE)
524_IT_SUBST(INTLTOOL_SCHEMAS_RULE)
525_IT_SUBST(INTLTOOL_THEME_RULE)
526_IT_SUBST(INTLTOOL_SERVICE_RULE)
527_IT_SUBST(INTLTOOL_POLICY_RULE)
528
529# Check the gettext tools to make sure they are GNU
530AC_PATH_PROG(XGETTEXT, xgettext)
531AC_PATH_PROG(MSGMERGE, msgmerge)
532AC_PATH_PROG(MSGFMT, msgfmt)
533AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
534if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
535 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
536fi
537xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
538mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
539mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
540if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
541 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
542fi
543
544AC_PATH_PROG(INTLTOOL_PERL, perl)
545if test -z "$INTLTOOL_PERL"; then
546 AC_MSG_ERROR([perl not found])
547fi
548AC_MSG_CHECKING([for perl >= 5.8.1])
549$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
550if test $? -ne 0; then
551 AC_MSG_ERROR([perl 5.8.1 is required for intltool])
552else
553 IT_PERL_VERSION="`$INTLTOOL_PERL -e \"printf '%vd', $^V\"`"
554 AC_MSG_RESULT([$IT_PERL_VERSION])
555fi
556if test "x$2" != "xno-xml"; then
557 AC_MSG_CHECKING([for XML::Parser])
558 if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
559 AC_MSG_RESULT([ok])
560 else
561 AC_MSG_ERROR([XML::Parser perl module is required for intltool])
562 fi
563fi
564
565# Substitute ALL_LINGUAS so we can use it in po/Makefile
566AC_SUBST(ALL_LINGUAS)
567
568# Set DATADIRNAME correctly if it is not set yet
569# (copied from glib-gettext.m4)
570if test -z "$DATADIRNAME"; then
571 AC_LINK_IFELSE(
572 [AC_LANG_PROGRAM([[]],
573 [[extern int _nl_msg_cat_cntr;
574 return _nl_msg_cat_cntr]])],
575 [DATADIRNAME=share],
576 [case $host in
577 *-*-solaris*)
578 dnl On Solaris, if bind_textdomain_codeset is in libc,
579 dnl GNU format message catalog is always supported,
580 dnl since both are added to the libc all together.
581 dnl Hence, we'd like to go with DATADIRNAME=share
582 dnl in this case.
583 AC_CHECK_FUNC(bind_textdomain_codeset,
584 [DATADIRNAME=share], [DATADIRNAME=lib])
585 ;;
586 *)
587 [DATADIRNAME=lib]
588 ;;
589 esac])
590fi
591AC_SUBST(DATADIRNAME)
592
593IT_PO_SUBDIR([po])
594
595])
596
597
598# IT_PO_SUBDIR(DIRNAME)
599# ---------------------
600# All po subdirs have to be declared with this macro; the subdir "po" is
601# declared by IT_PROG_INTLTOOL.
602#
603AC_DEFUN([IT_PO_SUBDIR],
604[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
605dnl
606dnl The following CONFIG_COMMANDS should be exetuted at the very end
607dnl of config.status.
608AC_CONFIG_COMMANDS_PRE([
609 AC_CONFIG_COMMANDS([$1/stamp-it], [
610 if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
611 AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
612 fi
613 rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
614 >"$1/stamp-it.tmp"
615 [sed '/^#/d
616 s/^[[].*] *//
617 /^[ ]*$/d
618 '"s|^| $ac_top_srcdir/|" \
619 "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
620 ]
621 [sed '/^POTFILES =/,/[^\\]$/ {
622 /^POTFILES =/!d
623 r $1/POTFILES
624 }
625 ' "$1/Makefile.in" >"$1/Makefile"]
626 rm -f "$1/Makefile.tmp"
627 mv "$1/stamp-it.tmp" "$1/stamp-it"
628 ])
629])dnl
630])
631
632# _IT_SUBST(VARIABLE)
633# -------------------
634# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
635#
636AC_DEFUN([_IT_SUBST],
637[
638AC_SUBST([$1])
639m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
640]
641)
642
643# deprecated macros
644AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
645# A hint is needed for aclocal from Automake <= 1.9.4:
646# AC_DEFUN([AC_PROG_INTLTOOL], ...)
647
648
649dnl -*- mode: autoconf -*-
650dnl Copyright 2009 Johan Dahlin
651dnl
652dnl This file is free software; the author(s) gives unlimited
653dnl permission to copy and/or distribute it, with or without
654dnl modifications, as long as this notice is preserved.
655dnl
656
657# serial 1
658
659m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
660[
661 AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
662 AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
663 AC_BEFORE([LT_INIT],[$0])dnl setup libtool first
664
665 dnl enable/disable introspection
666 m4_if([$2], [require],
667 [dnl
668 enable_introspection=yes
669 ],[dnl
670 AC_ARG_ENABLE(introspection,
671 AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
672 [Enable introspection for this build]),,
673 [enable_introspection=auto])
674 ])dnl
675
676 AC_MSG_CHECKING([for gobject-introspection])
677
678 dnl presence/version checking
679 AS_CASE([$enable_introspection],
680 [no], [dnl
681 found_introspection="no (disabled, use --enable-introspection to enable)"
682 ],dnl
683 [yes],[dnl
684 PKG_CHECK_EXISTS([gobject-introspection-1.0],,
685 AC_MSG_ERROR([gobject-introspection-1.0 is not installed]))
686 PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1],
687 found_introspection=yes,
688 AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME]))
689 ],dnl
690 [auto],[dnl
691 PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
692 ],dnl
693 [dnl
694 AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@])
695 ])dnl
696
697 AC_MSG_RESULT([$found_introspection])
698
699 INTROSPECTION_SCANNER=
700 INTROSPECTION_COMPILER=
701 INTROSPECTION_GENERATE=
702 INTROSPECTION_GIRDIR=
703 INTROSPECTION_TYPELIBDIR=
704 if test "x$found_introspection" = "xyes"; then
705 INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
706 INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
707 INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
708 INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
709 INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
710 INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
711 INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
712 INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
713 fi
714 AC_SUBST(INTROSPECTION_SCANNER)
715 AC_SUBST(INTROSPECTION_COMPILER)
716 AC_SUBST(INTROSPECTION_GENERATE)
717 AC_SUBST(INTROSPECTION_GIRDIR)
718 AC_SUBST(INTROSPECTION_TYPELIBDIR)
719 AC_SUBST(INTROSPECTION_CFLAGS)
720 AC_SUBST(INTROSPECTION_LIBS)
721 AC_SUBST(INTROSPECTION_MAKEFILE)
722
723 AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes")
724])
725
726
727dnl Usage:
728dnl GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version])
729
730AC_DEFUN([GOBJECT_INTROSPECTION_CHECK],
731[
732 _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1])
733])
734
735dnl Usage:
736dnl GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version])
737
738
739AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE],
740[
741 _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require])
742])
743
744# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
745#
746# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
747# 2006, 2007, 2008 Free Software Foundation, Inc.
748# Written by Gordon Matzigkeit, 1996
749#
750# This file is free software; the Free Software Foundation gives
751# unlimited permission to copy and/or distribute it, with or without
752# modifications, as long as this notice is preserved.
753
754m4_define([_LT_COPYING], [dnl
755# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
756# 2006, 2007, 2008 Free Software Foundation, Inc.
757# Written by Gordon Matzigkeit, 1996
758#
759# This file is part of GNU Libtool.
760#
761# GNU Libtool is free software; you can redistribute it and/or
762# modify it under the terms of the GNU General Public License as
763# published by the Free Software Foundation; either version 2 of
764# the License, or (at your option) any later version.
765#
766# As a special exception to the GNU General Public License,
767# if you distribute this file as part of a program or library that
768# is built using GNU Libtool, you may include this file under the
769# same distribution terms that you use for the rest of that program.
770#
771# GNU Libtool is distributed in the hope that it will be useful,
772# but WITHOUT ANY WARRANTY; without even the implied warranty of
773# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
774# GNU General Public License for more details.
775#
776# You should have received a copy of the GNU General Public License
777# along with GNU Libtool; see the file COPYING. If not, a copy
778# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
779# obtained by writing to the Free Software Foundation, Inc.,
780# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
781])
782
783# serial 56 LT_INIT
784
785
786# LT_PREREQ(VERSION)
787# ------------------
788# Complain and exit if this libtool version is less that VERSION.
789m4_defun([LT_PREREQ],
790[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
791 [m4_default([$3],
792 [m4_fatal([Libtool version $1 or higher is required],
793 63)])],
794 [$2])])
795
796
797# _LT_CHECK_BUILDDIR
798# ------------------
799# Complain if the absolute build directory name contains unusual characters
800m4_defun([_LT_CHECK_BUILDDIR],
801[case `pwd` in
802 *\ * | *\ *)
803 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
804esac
805])
806
807
808# LT_INIT([OPTIONS])
809# ------------------
810AC_DEFUN([LT_INIT],
811[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
812AC_BEFORE([$0], [LT_LANG])dnl
813AC_BEFORE([$0], [LT_OUTPUT])dnl
814AC_BEFORE([$0], [LTDL_INIT])dnl
815m4_require([_LT_CHECK_BUILDDIR])dnl
816
817dnl Autoconf doesn't catch unexpanded LT_ macros by default:
818m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
819m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
820dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
821dnl unless we require an AC_DEFUNed macro:
822AC_REQUIRE([LTOPTIONS_VERSION])dnl
823AC_REQUIRE([LTSUGAR_VERSION])dnl
824AC_REQUIRE([LTVERSION_VERSION])dnl
825AC_REQUIRE([LTOBSOLETE_VERSION])dnl
826m4_require([_LT_PROG_LTMAIN])dnl
827
828dnl Parse OPTIONS
829_LT_SET_OPTIONS([$0], [$1])
830
831# This can be used to rebuild libtool when needed
832LIBTOOL_DEPS="$ltmain"
833
834# Always use our own libtool.
835LIBTOOL='$(SHELL) $(top_builddir)/libtool'
836AC_SUBST(LIBTOOL)dnl
837
838_LT_SETUP
839
840# Only expand once:
841m4_define([LT_INIT])
842])# LT_INIT
843
844# Old names:
845AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
846AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
847dnl aclocal-1.4 backwards compatibility:
848dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
849dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
850
851
852# _LT_CC_BASENAME(CC)
853# -------------------
854# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
855m4_defun([_LT_CC_BASENAME],
856[for cc_temp in $1""; do
857 case $cc_temp in
858 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
859 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
860 \-*) ;;
861 *) break;;
862 esac
863done
864cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
865])
866
867
868# _LT_FILEUTILS_DEFAULTS
869# ----------------------
870# It is okay to use these file commands and assume they have been set
871# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
872m4_defun([_LT_FILEUTILS_DEFAULTS],
873[: ${CP="cp -f"}
874: ${MV="mv -f"}
875: ${RM="rm -f"}
876])# _LT_FILEUTILS_DEFAULTS
877
878
879# _LT_SETUP
880# ---------
881m4_defun([_LT_SETUP],
882[AC_REQUIRE([AC_CANONICAL_HOST])dnl
883AC_REQUIRE([AC_CANONICAL_BUILD])dnl
884_LT_DECL([], [host_alias], [0], [The host system])dnl
885_LT_DECL([], [host], [0])dnl
886_LT_DECL([], [host_os], [0])dnl
887dnl
888_LT_DECL([], [build_alias], [0], [The build system])dnl
889_LT_DECL([], [build], [0])dnl
890_LT_DECL([], [build_os], [0])dnl
891dnl
892AC_REQUIRE([AC_PROG_CC])dnl
893AC_REQUIRE([LT_PATH_LD])dnl
894AC_REQUIRE([LT_PATH_NM])dnl
895dnl
896AC_REQUIRE([AC_PROG_LN_S])dnl
897test -z "$LN_S" && LN_S="ln -s"
898_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
899dnl
900AC_REQUIRE([LT_CMD_MAX_LEN])dnl
901_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
902_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
903dnl
904m4_require([_LT_FILEUTILS_DEFAULTS])dnl
905m4_require([_LT_CHECK_SHELL_FEATURES])dnl
906m4_require([_LT_CMD_RELOAD])dnl
907m4_require([_LT_CHECK_MAGIC_METHOD])dnl
908m4_require([_LT_CMD_OLD_ARCHIVE])dnl
909m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
910
911_LT_CONFIG_LIBTOOL_INIT([
912# See if we are running on zsh, and set the options which allow our
913# commands through without removal of \ escapes INIT.
914if test -n "\${ZSH_VERSION+set}" ; then
915 setopt NO_GLOB_SUBST
916fi
917])
918if test -n "${ZSH_VERSION+set}" ; then
919 setopt NO_GLOB_SUBST
920fi
921
922_LT_CHECK_OBJDIR
923
924m4_require([_LT_TAG_COMPILER])dnl
925_LT_PROG_ECHO_BACKSLASH
926
927case $host_os in
928aix3*)
929 # AIX sometimes has problems with the GCC collect2 program. For some
930 # reason, if we set the COLLECT_NAMES environment variable, the problems
931 # vanish in a puff of smoke.
932 if test "X${COLLECT_NAMES+set}" != Xset; then
933 COLLECT_NAMES=
934 export COLLECT_NAMES
935 fi
936 ;;
937esac
938
939# Sed substitution that helps us do robust quoting. It backslashifies
940# metacharacters that are still active within double-quoted strings.
941sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
942
943# Same as above, but do not quote variable references.
944double_quote_subst='s/\([["`\\]]\)/\\\1/g'
945
946# Sed substitution to delay expansion of an escaped shell variable in a
947# double_quote_subst'ed string.
948delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
949
950# Sed substitution to delay expansion of an escaped single quote.
951delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
952
953# Sed substitution to avoid accidental globbing in evaled expressions
954no_glob_subst='s/\*/\\\*/g'
955
956# Global variables:
957ofile=libtool
958can_build_shared=yes
959
960# All known linkers require a `.a' archive for static linking (except MSVC,
961# which needs '.lib').
962libext=a
963
964with_gnu_ld="$lt_cv_prog_gnu_ld"
965
966old_CC="$CC"
967old_CFLAGS="$CFLAGS"
968
969# Set sane defaults for various variables
970test -z "$CC" && CC=cc
971test -z "$LTCC" && LTCC=$CC
972test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
973test -z "$LD" && LD=ld
974test -z "$ac_objext" && ac_objext=o
975
976_LT_CC_BASENAME([$compiler])
977
978# Only perform the check for file, if the check method requires it
979test -z "$MAGIC_CMD" && MAGIC_CMD=file
980case $deplibs_check_method in
981file_magic*)
982 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
983 _LT_PATH_MAGIC
984 fi
985 ;;
986esac
987
988# Use C for the default configuration in the libtool script
989LT_SUPPORTED_TAG([CC])
990_LT_LANG_C_CONFIG
991_LT_LANG_DEFAULT_CONFIG
992_LT_CONFIG_COMMANDS
993])# _LT_SETUP
994
995
996# _LT_PROG_LTMAIN
997# ---------------
998# Note that this code is called both from `configure', and `config.status'
999# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
1000# `config.status' has no value for ac_aux_dir unless we are using Automake,
1001# so we pass a copy along to make sure it has a sensible value anyway.
1002m4_defun([_LT_PROG_LTMAIN],
1003[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
1004_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
1005ltmain="$ac_aux_dir/ltmain.sh"
1006])# _LT_PROG_LTMAIN
1007
1008
1009
1010# So that we can recreate a full libtool script including additional
1011# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
1012# in macros and then make a single call at the end using the `libtool'
1013# label.
1014
1015
1016# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
1017# ----------------------------------------
1018# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1019m4_define([_LT_CONFIG_LIBTOOL_INIT],
1020[m4_ifval([$1],
1021 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
1022 [$1
1023])])])
1024
1025# Initialize.
1026m4_define([_LT_OUTPUT_LIBTOOL_INIT])
1027
1028
1029# _LT_CONFIG_LIBTOOL([COMMANDS])
1030# ------------------------------
1031# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
1032m4_define([_LT_CONFIG_LIBTOOL],
1033[m4_ifval([$1],
1034 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
1035 [$1
1036])])])
1037
1038# Initialize.
1039m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
1040
1041
1042# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
1043# -----------------------------------------------------
1044m4_defun([_LT_CONFIG_SAVE_COMMANDS],
1045[_LT_CONFIG_LIBTOOL([$1])
1046_LT_CONFIG_LIBTOOL_INIT([$2])
1047])
1048
1049
1050# _LT_FORMAT_COMMENT([COMMENT])
1051# -----------------------------
1052# Add leading comment marks to the start of each line, and a trailing
1053# full-stop to the whole comment if one is not present already.
1054m4_define([_LT_FORMAT_COMMENT],
1055[m4_ifval([$1], [
1056m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
1057 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
1058)])
1059
1060
1061
1062
1063
1064# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
1065# -------------------------------------------------------------------
1066# CONFIGNAME is the name given to the value in the libtool script.
1067# VARNAME is the (base) name used in the configure script.
1068# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
1069# VARNAME. Any other value will be used directly.
1070m4_define([_LT_DECL],
1071[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
1072 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
1073 [m4_ifval([$1], [$1], [$2])])
1074 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
1075 m4_ifval([$4],
1076 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
1077 lt_dict_add_subkey([lt_decl_dict], [$2],
1078 [tagged?], [m4_ifval([$5], [yes], [no])])])
1079])
1080
1081
1082# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
1083# --------------------------------------------------------
1084m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
1085
1086
1087# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
1088# ------------------------------------------------
1089m4_define([lt_decl_tag_varnames],
1090[_lt_decl_filter([tagged?], [yes], $@)])
1091
1092
1093# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
1094# ---------------------------------------------------------
1095m4_define([_lt_decl_filter],
1096[m4_case([$#],
1097 [0], [m4_fatal([$0: too few arguments: $#])],
1098 [1], [m4_fatal([$0: too few arguments: $#: $1])],
1099 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
1100 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
1101 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
1102])
1103
1104
1105# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
1106# --------------------------------------------------
1107m4_define([lt_decl_quote_varnames],
1108[_lt_decl_filter([value], [1], $@)])
1109
1110
1111# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
1112# ---------------------------------------------------
1113m4_define([lt_decl_dquote_varnames],
1114[_lt_decl_filter([value], [2], $@)])
1115
1116
1117# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
1118# ---------------------------------------------------
1119m4_define([lt_decl_varnames_tagged],
1120[m4_assert([$# <= 2])dnl
1121_$0(m4_quote(m4_default([$1], [[, ]])),
1122 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
1123 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
1124m4_define([_lt_decl_varnames_tagged],
1125[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
1126
1127
1128# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
1129# ------------------------------------------------
1130m4_define([lt_decl_all_varnames],
1131[_$0(m4_quote(m4_default([$1], [[, ]])),
1132 m4_if([$2], [],
1133 m4_quote(lt_decl_varnames),
1134 m4_quote(m4_shift($@))))[]dnl
1135])
1136m4_define([_lt_decl_all_varnames],
1137[lt_join($@, lt_decl_varnames_tagged([$1],
1138 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
1139])
1140
1141
1142# _LT_CONFIG_STATUS_DECLARE([VARNAME])
1143# ------------------------------------
1144# Quote a variable value, and forward it to `config.status' so that its
1145# declaration there will have the same value as in `configure'. VARNAME
1146# must have a single quote delimited value for this to work.
1147m4_define([_LT_CONFIG_STATUS_DECLARE],
1148[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
1149
1150
1151# _LT_CONFIG_STATUS_DECLARATIONS
1152# ------------------------------
1153# We delimit libtool config variables with single quotes, so when
1154# we write them to config.status, we have to be sure to quote all
1155# embedded single quotes properly. In configure, this macro expands
1156# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
1157#
1158# <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
1159m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
1160[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
1161 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
1162
1163
1164# _LT_LIBTOOL_TAGS
1165# ----------------
1166# Output comment and list of tags supported by the script
1167m4_defun([_LT_LIBTOOL_TAGS],
1168[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
1169available_tags="_LT_TAGS"dnl
1170])
1171
1172
1173# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
1174# -----------------------------------
1175# Extract the dictionary values for VARNAME (optionally with TAG) and
1176# expand to a commented shell variable setting:
1177#
1178# # Some comment about what VAR is for.
1179# visible_name=$lt_internal_name
1180m4_define([_LT_LIBTOOL_DECLARE],
1181[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
1182 [description])))[]dnl
1183m4_pushdef([_libtool_name],
1184 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
1185m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
1186 [0], [_libtool_name=[$]$1],
1187 [1], [_libtool_name=$lt_[]$1],
1188 [2], [_libtool_name=$lt_[]$1],
1189 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
1190m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
1191])
1192
1193
1194# _LT_LIBTOOL_CONFIG_VARS
1195# -----------------------
1196# Produce commented declarations of non-tagged libtool config variables
1197# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
1198# script. Tagged libtool config variables (even for the LIBTOOL CONFIG
1199# section) are produced by _LT_LIBTOOL_TAG_VARS.
1200m4_defun([_LT_LIBTOOL_CONFIG_VARS],
1201[m4_foreach([_lt_var],
1202 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
1203 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
1204
1205
1206# _LT_LIBTOOL_TAG_VARS(TAG)
1207# -------------------------
1208m4_define([_LT_LIBTOOL_TAG_VARS],
1209[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
1210 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
1211
1212
1213# _LT_TAGVAR(VARNAME, [TAGNAME])
1214# ------------------------------
1215m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
1216
1217
1218# _LT_CONFIG_COMMANDS
1219# -------------------
1220# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
1221# variables for single and double quote escaping we saved from calls
1222# to _LT_DECL, we can put quote escaped variables declarations
1223# into `config.status', and then the shell code to quote escape them in
1224# for loops in `config.status'. Finally, any additional code accumulated
1225# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
1226m4_defun([_LT_CONFIG_COMMANDS],
1227[AC_PROVIDE_IFELSE([LT_OUTPUT],
1228 dnl If the libtool generation code has been placed in $CONFIG_LT,
1229 dnl instead of duplicating it all over again into config.status,
1230 dnl then we will have config.status run $CONFIG_LT later, so it
1231 dnl needs to know what name is stored there:
1232 [AC_CONFIG_COMMANDS([libtool],
1233 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
1234 dnl If the libtool generation code is destined for config.status,
1235 dnl expand the accumulated commands and init code now:
1236 [AC_CONFIG_COMMANDS([libtool],
1237 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
1238])#_LT_CONFIG_COMMANDS
1239
1240
1241# Initialize.
1242m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
1243[
1244
1245# The HP-UX ksh and POSIX shell print the target directory to stdout
1246# if CDPATH is set.
1247(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1248
1249sed_quote_subst='$sed_quote_subst'
1250double_quote_subst='$double_quote_subst'
1251delay_variable_subst='$delay_variable_subst'
1252_LT_CONFIG_STATUS_DECLARATIONS
1253LTCC='$LTCC'
1254LTCFLAGS='$LTCFLAGS'
1255compiler='$compiler_DEFAULT'
1256
1257# Quote evaled strings.
1258for var in lt_decl_all_varnames([[ \
1259]], lt_decl_quote_varnames); do
1260 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
1261 *[[\\\\\\\`\\"\\\$]]*)
1262 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1263 ;;
1264 *)
1265 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1266 ;;
1267 esac
1268done
1269
1270# Double-quote double-evaled strings.
1271for var in lt_decl_all_varnames([[ \
1272]], lt_decl_dquote_varnames); do
1273 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
1274 *[[\\\\\\\`\\"\\\$]]*)
1275 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1276 ;;
1277 *)
1278 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1279 ;;
1280 esac
1281done
1282
1283# Fix-up fallback echo if it was mangled by the above quoting rules.
1284case \$lt_ECHO in
1285*'\\\[$]0 --fallback-echo"')dnl "
1286 lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
1287 ;;
1288esac
1289
1290_LT_OUTPUT_LIBTOOL_INIT
1291])
1292
1293
1294# LT_OUTPUT
1295# ---------
1296# This macro allows early generation of the libtool script (before
1297# AC_OUTPUT is called), incase it is used in configure for compilation
1298# tests.
1299AC_DEFUN([LT_OUTPUT],
1300[: ${CONFIG_LT=./config.lt}
1301AC_MSG_NOTICE([creating $CONFIG_LT])
1302cat >"$CONFIG_LT" <<_LTEOF
1303#! $SHELL
1304# Generated by $as_me.
1305# Run this file to recreate a libtool stub with the current configuration.
1306
1307lt_cl_silent=false
1308SHELL=\${CONFIG_SHELL-$SHELL}
1309_LTEOF
1310
1311cat >>"$CONFIG_LT" <<\_LTEOF
1312AS_SHELL_SANITIZE
1313_AS_PREPARE
1314
1315exec AS_MESSAGE_FD>&1
1316exec AS_MESSAGE_LOG_FD>>config.log
1317{
1318 echo
1319 AS_BOX([Running $as_me.])
1320} >&AS_MESSAGE_LOG_FD
1321
1322lt_cl_help="\
1323\`$as_me' creates a local libtool stub from the current configuration,
1324for use in further configure time tests before the real libtool is
1325generated.
1326
1327Usage: $[0] [[OPTIONS]]
1328
1329 -h, --help print this help, then exit
1330 -V, --version print version number, then exit
1331 -q, --quiet do not print progress messages
1332 -d, --debug don't remove temporary files
1333
1334Report bugs to <bug-libtool@gnu.org>."
1335
1336lt_cl_version="\
1337m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1338m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1339configured by $[0], generated by m4_PACKAGE_STRING.
1340
1341Copyright (C) 2008 Free Software Foundation, Inc.
1342This config.lt script is free software; the Free Software Foundation
1343gives unlimited permision to copy, distribute and modify it."
1344
1345while test $[#] != 0
1346do
1347 case $[1] in
1348 --version | --v* | -V )
1349 echo "$lt_cl_version"; exit 0 ;;
1350 --help | --h* | -h )
1351 echo "$lt_cl_help"; exit 0 ;;
1352 --debug | --d* | -d )
1353 debug=: ;;
1354 --quiet | --q* | --silent | --s* | -q )
1355 lt_cl_silent=: ;;
1356
1357 -*) AC_MSG_ERROR([unrecognized option: $[1]
1358Try \`$[0] --help' for more information.]) ;;
1359
1360 *) AC_MSG_ERROR([unrecognized argument: $[1]
1361Try \`$[0] --help' for more information.]) ;;
1362 esac
1363 shift
1364done
1365
1366if $lt_cl_silent; then
1367 exec AS_MESSAGE_FD>/dev/null
1368fi
1369_LTEOF
1370
1371cat >>"$CONFIG_LT" <<_LTEOF
1372_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1373_LTEOF
1374
1375cat >>"$CONFIG_LT" <<\_LTEOF
1376AC_MSG_NOTICE([creating $ofile])
1377_LT_OUTPUT_LIBTOOL_COMMANDS
1378AS_EXIT(0)
1379_LTEOF
1380chmod +x "$CONFIG_LT"
1381
1382# configure is writing to config.log, but config.lt does its own redirection,
1383# appending to config.log, which fails on DOS, as config.log is still kept
1384# open by configure. Here we exec the FD to /dev/null, effectively closing
1385# config.log, so it can be properly (re)opened and appended to by config.lt.
1386if test "$no_create" != yes; then
1387 lt_cl_success=:
1388 test "$silent" = yes &&
1389 lt_config_lt_args="$lt_config_lt_args --quiet"
1390 exec AS_MESSAGE_LOG_FD>/dev/null
1391 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
1392 exec AS_MESSAGE_LOG_FD>>config.log
1393 $lt_cl_success || AS_EXIT(1)
1394fi
1395])# LT_OUTPUT
1396
1397
1398# _LT_CONFIG(TAG)
1399# ---------------
1400# If TAG is the built-in tag, create an initial libtool script with a
1401# default configuration from the untagged config vars. Otherwise add code
1402# to config.status for appending the configuration named by TAG from the
1403# matching tagged config vars.
1404m4_defun([_LT_CONFIG],
1405[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1406_LT_CONFIG_SAVE_COMMANDS([
1407 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
1408 m4_if(_LT_TAG, [C], [
1409 # See if we are running on zsh, and set the options which allow our
1410 # commands through without removal of \ escapes.
1411 if test -n "${ZSH_VERSION+set}" ; then
1412 setopt NO_GLOB_SUBST
1413 fi
1414
1415 cfgfile="${ofile}T"
1416 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
1417 $RM "$cfgfile"
1418
1419 cat <<_LT_EOF >> "$cfgfile"
1420#! $SHELL
1421
1422# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
1423# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
1424# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1425# NOTE: Changes made to this file will be lost: look at ltmain.sh.
1426#
1427_LT_COPYING
1428_LT_LIBTOOL_TAGS
1429
1430# ### BEGIN LIBTOOL CONFIG
1431_LT_LIBTOOL_CONFIG_VARS
1432_LT_LIBTOOL_TAG_VARS
1433# ### END LIBTOOL CONFIG
1434
1435_LT_EOF
1436
1437 case $host_os in
1438 aix3*)
1439 cat <<\_LT_EOF >> "$cfgfile"
1440# AIX sometimes has problems with the GCC collect2 program. For some
1441# reason, if we set the COLLECT_NAMES environment variable, the problems
1442# vanish in a puff of smoke.
1443if test "X${COLLECT_NAMES+set}" != Xset; then
1444 COLLECT_NAMES=
1445 export COLLECT_NAMES
1446fi
1447_LT_EOF
1448 ;;
1449 esac
1450
1451 _LT_PROG_LTMAIN
1452
1453 # We use sed instead of cat because bash on DJGPP gets confused if
1454 # if finds mixed CR/LF and LF-only lines. Since sed operates in
1455 # text mode, it properly converts lines to CR/LF. This bash problem
1456 # is reportedly fixed, but why not run on old versions too?
1457 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
1458 || (rm -f "$cfgfile"; exit 1)
1459
1460 _LT_PROG_XSI_SHELLFNS
1461
1462 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
1463 || (rm -f "$cfgfile"; exit 1)
1464
1465 mv -f "$cfgfile" "$ofile" ||
1466 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
1467 chmod +x "$ofile"
1468],
1469[cat <<_LT_EOF >> "$ofile"
1470
1471dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
1472dnl in a comment (ie after a #).
1473# ### BEGIN LIBTOOL TAG CONFIG: $1
1474_LT_LIBTOOL_TAG_VARS(_LT_TAG)
1475# ### END LIBTOOL TAG CONFIG: $1
1476_LT_EOF
1477])dnl /m4_if
1478],
1479[m4_if([$1], [], [
1480 PACKAGE='$PACKAGE'
1481 VERSION='$VERSION'
1482 TIMESTAMP='$TIMESTAMP'
1483 RM='$RM'
1484 ofile='$ofile'], [])
1485])dnl /_LT_CONFIG_SAVE_COMMANDS
1486])# _LT_CONFIG
1487
1488
1489# LT_SUPPORTED_TAG(TAG)
1490# ---------------------
1491# Trace this macro to discover what tags are supported by the libtool
1492# --tag option, using:
1493# autoconf --trace 'LT_SUPPORTED_TAG:$1'
1494AC_DEFUN([LT_SUPPORTED_TAG], [])
1495
1496
1497# C support is built-in for now
1498m4_define([_LT_LANG_C_enabled], [])
1499m4_define([_LT_TAGS], [])
1500
1501
1502# LT_LANG(LANG)
1503# -------------
1504# Enable libtool support for the given language if not already enabled.
1505AC_DEFUN([LT_LANG],
1506[AC_BEFORE([$0], [LT_OUTPUT])dnl
1507m4_case([$1],
1508 [C], [_LT_LANG(C)],
1509 [C++], [_LT_LANG(CXX)],
1510 [Java], [_LT_LANG(GCJ)],
1511 [Fortran 77], [_LT_LANG(F77)],
1512 [Fortran], [_LT_LANG(FC)],
1513 [Windows Resource], [_LT_LANG(RC)],
1514 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
1515 [_LT_LANG($1)],
1516 [m4_fatal([$0: unsupported language: "$1"])])])dnl
1517])# LT_LANG
1518
1519
1520# _LT_LANG(LANGNAME)
1521# ------------------
1522m4_defun([_LT_LANG],
1523[m4_ifdef([_LT_LANG_]$1[_enabled], [],
1524 [LT_SUPPORTED_TAG([$1])dnl
1525 m4_append([_LT_TAGS], [$1 ])dnl
1526 m4_define([_LT_LANG_]$1[_enabled], [])dnl
1527 _LT_LANG_$1_CONFIG($1)])dnl
1528])# _LT_LANG
1529
1530
1531# _LT_LANG_DEFAULT_CONFIG
1532# -----------------------
1533m4_defun([_LT_LANG_DEFAULT_CONFIG],
1534[AC_PROVIDE_IFELSE([AC_PROG_CXX],
1535 [LT_LANG(CXX)],
1536 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
1537
1538AC_PROVIDE_IFELSE([AC_PROG_F77],
1539 [LT_LANG(F77)],
1540 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
1541
1542AC_PROVIDE_IFELSE([AC_PROG_FC],
1543 [LT_LANG(FC)],
1544 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
1545
1546dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
1547dnl pulling things in needlessly.
1548AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1549 [LT_LANG(GCJ)],
1550 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1551 [LT_LANG(GCJ)],
1552 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
1553 [LT_LANG(GCJ)],
1554 [m4_ifdef([AC_PROG_GCJ],
1555 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
1556 m4_ifdef([A][M_PROG_GCJ],
1557 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
1558 m4_ifdef([LT_PROG_GCJ],
1559 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
1560
1561AC_PROVIDE_IFELSE([LT_PROG_RC],
1562 [LT_LANG(RC)],
1563 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
1564])# _LT_LANG_DEFAULT_CONFIG
1565
1566# Obsolete macros:
1567AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1568AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1569AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1570AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1571dnl aclocal-1.4 backwards compatibility:
1572dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1573dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1574dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1575dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1576
1577
1578# _LT_TAG_COMPILER
1579# ----------------
1580m4_defun([_LT_TAG_COMPILER],
1581[AC_REQUIRE([AC_PROG_CC])dnl
1582
1583_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1584_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1585_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1586_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1587
1588# If no C compiler was specified, use CC.
1589LTCC=${LTCC-"$CC"}
1590
1591# If no C compiler flags were specified, use CFLAGS.
1592LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1593
1594# Allow CC to be a program name with arguments.
1595compiler=$CC
1596])# _LT_TAG_COMPILER
1597
1598
1599# _LT_COMPILER_BOILERPLATE
1600# ------------------------
1601# Check for compiler boilerplate output or warnings with
1602# the simple compiler test code.
1603m4_defun([_LT_COMPILER_BOILERPLATE],
1604[m4_require([_LT_DECL_SED])dnl
1605ac_outfile=conftest.$ac_objext
1606echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1607eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1608_lt_compiler_boilerplate=`cat conftest.err`
1609$RM conftest*
1610])# _LT_COMPILER_BOILERPLATE
1611
1612
1613# _LT_LINKER_BOILERPLATE
1614# ----------------------
1615# Check for linker boilerplate output or warnings with
1616# the simple link test code.
1617m4_defun([_LT_LINKER_BOILERPLATE],
1618[m4_require([_LT_DECL_SED])dnl
1619ac_outfile=conftest.$ac_objext
1620echo "$lt_simple_link_test_code" >conftest.$ac_ext
1621eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1622_lt_linker_boilerplate=`cat conftest.err`
1623$RM -r conftest*
1624])# _LT_LINKER_BOILERPLATE
1625
1626# _LT_REQUIRED_DARWIN_CHECKS
1627# -------------------------
1628m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1629 case $host_os in
1630 rhapsody* | darwin*)
1631 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1632 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1633 AC_CHECK_TOOL([LIPO], [lipo], [:])
1634 AC_CHECK_TOOL([OTOOL], [otool], [:])
1635 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1636 _LT_DECL([], [DSYMUTIL], [1],
1637 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1638 _LT_DECL([], [NMEDIT], [1],
1639 [Tool to change global to local symbols on Mac OS X])
1640 _LT_DECL([], [LIPO], [1],
1641 [Tool to manipulate fat objects and archives on Mac OS X])
1642 _LT_DECL([], [OTOOL], [1],
1643 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1644 _LT_DECL([], [OTOOL64], [1],
1645 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1646
1647 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1648 [lt_cv_apple_cc_single_mod=no
1649 if test -z "${LT_MULTI_MODULE}"; then
1650 # By default we will add the -single_module flag. You can override
1651 # by either setting the environment variable LT_MULTI_MODULE
1652 # non-empty at configure time, or by adding -multi_module to the
1653 # link flags.
1654 rm -rf libconftest.dylib*
1655 echo "int foo(void){return 1;}" > conftest.c
1656 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1657-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1658 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1659 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1660 _lt_result=$?
1661 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
1662 lt_cv_apple_cc_single_mod=yes
1663 else
1664 cat conftest.err >&AS_MESSAGE_LOG_FD
1665 fi
1666 rm -rf libconftest.dylib*
1667 rm -f conftest.*
1668 fi])
1669 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1670 [lt_cv_ld_exported_symbols_list],
1671 [lt_cv_ld_exported_symbols_list=no
1672 save_LDFLAGS=$LDFLAGS
1673 echo "_main" > conftest.sym
1674 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1675 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1676 [lt_cv_ld_exported_symbols_list=yes],
1677 [lt_cv_ld_exported_symbols_list=no])
1678 LDFLAGS="$save_LDFLAGS"
1679 ])
1680 case $host_os in
1681 rhapsody* | darwin1.[[012]])
1682 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1683 darwin1.*)
1684 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1685 darwin*) # darwin 5.x on
1686 # if running on 10.5 or later, the deployment target defaults
1687 # to the OS version, if on x86, and 10.4, the deployment
1688 # target defaults to 10.4. Don't you love it?
1689 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1690 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1691 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1692 10.[[012]]*)
1693 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1694 10.*)
1695 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1696 esac
1697 ;;
1698 esac
1699 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1700 _lt_dar_single_mod='$single_module'
1701 fi
1702 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1703 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1704 else
1705 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1706 fi
1707 if test "$DSYMUTIL" != ":"; then
1708 _lt_dsymutil='~$DSYMUTIL $lib || :'
1709 else
1710 _lt_dsymutil=
1711 fi
1712 ;;
1713 esac
1714])
1715
1716
1717# _LT_DARWIN_LINKER_FEATURES
1718# --------------------------
1719# Checks for linker and compiler features on darwin
1720m4_defun([_LT_DARWIN_LINKER_FEATURES],
1721[
1722 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1723 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1724 _LT_TAGVAR(hardcode_direct, $1)=no
1725 _LT_TAGVAR(hardcode_automatic, $1)=yes
1726 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1727 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1728 _LT_TAGVAR(link_all_deplibs, $1)=yes
1729 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1730 case $cc_basename in
1731 ifort*) _lt_dar_can_shared=yes ;;
1732 *) _lt_dar_can_shared=$GCC ;;
1733 esac
1734 if test "$_lt_dar_can_shared" = "yes"; then
1735 output_verbose_link_cmd=echo
1736 _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}"
1737 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1738 _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}"
1739 _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}"
1740 m4_if([$1], [CXX],
1741[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1742 _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}"
1743 _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}"
1744 fi
1745],[])
1746 else
1747 _LT_TAGVAR(ld_shlibs, $1)=no
1748 fi
1749])
1750
1751# _LT_SYS_MODULE_PATH_AIX
1752# -----------------------
1753# Links a minimal program and checks the executable
1754# for the system default hardcoded library path. In most cases,
1755# this is /usr/lib:/lib, but when the MPI compilers are used
1756# the location of the communication and MPI libs are included too.
1757# If we don't find anything, use the default library path according
1758# to the aix ld manual.
1759m4_defun([_LT_SYS_MODULE_PATH_AIX],
1760[m4_require([_LT_DECL_SED])dnl
1761AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1762lt_aix_libpath_sed='
1763 /Import File Strings/,/^$/ {
1764 /^0/ {
1765 s/^0 *\(.*\)$/\1/
1766 p
1767 }
1768 }'
1769aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1770# Check for a 64-bit object if we didn't find anything.
1771if test -z "$aix_libpath"; then
1772 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1773fi],[])
1774if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1775])# _LT_SYS_MODULE_PATH_AIX
1776
1777
1778# _LT_SHELL_INIT(ARG)
1779# -------------------
1780m4_define([_LT_SHELL_INIT],
1781[ifdef([AC_DIVERSION_NOTICE],
1782 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1783 [AC_DIVERT_PUSH(NOTICE)])
1784$1
1785AC_DIVERT_POP
1786])# _LT_SHELL_INIT
1787
1788
1789# _LT_PROG_ECHO_BACKSLASH
1790# -----------------------
1791# Add some code to the start of the generated configure script which
1792# will find an echo command which doesn't interpret backslashes.
1793m4_defun([_LT_PROG_ECHO_BACKSLASH],
1794[_LT_SHELL_INIT([
1795# Check that we are running under the correct shell.
1796SHELL=${CONFIG_SHELL-/bin/sh}
1797
1798case X$lt_ECHO in
1799X*--fallback-echo)
1800 # Remove one level of quotation (which was required for Make).
1801 ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1802 ;;
1803esac
1804
1805ECHO=${lt_ECHO-echo}
1806if test "X[$]1" = X--no-reexec; then
1807 # Discard the --no-reexec flag, and continue.
1808 shift
1809elif test "X[$]1" = X--fallback-echo; then
1810 # Avoid inline document here, it may be left over
1811 :
1812elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
1813 # Yippee, $ECHO works!
1814 :
1815else
1816 # Restart under the correct shell.
1817 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1818fi
1819
1820if test "X[$]1" = X--fallback-echo; then
1821 # used as fallback echo
1822 shift
1823 cat <<_LT_EOF
1824[$]*
1825_LT_EOF
1826 exit 0
1827fi
1828
1829# The HP-UX ksh and POSIX shell print the target directory to stdout
1830# if CDPATH is set.
1831(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1832
1833if test -z "$lt_ECHO"; then
1834 if test "X${echo_test_string+set}" != Xset; then
1835 # find a string as large as possible, as long as the shell can cope with it
1836 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1837 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1838 if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
1839 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
1840 then
1841 break
1842 fi
1843 done
1844 fi
1845
1846 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1847 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1848 test "X$echo_testing_string" = "X$echo_test_string"; then
1849 :
1850 else
1851 # The Solaris, AIX, and Digital Unix default echo programs unquote
1852 # backslashes. This makes it impossible to quote backslashes using
1853 # echo "$something" | sed 's/\\/\\\\/g'
1854 #
1855 # So, first we look for a working echo in the user's PATH.
1856
1857 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1858 for dir in $PATH /usr/ucb; do
1859 IFS="$lt_save_ifs"
1860 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1861 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1862 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1863 test "X$echo_testing_string" = "X$echo_test_string"; then
1864 ECHO="$dir/echo"
1865 break
1866 fi
1867 done
1868 IFS="$lt_save_ifs"
1869
1870 if test "X$ECHO" = Xecho; then
1871 # We didn't find a better echo, so look for alternatives.
1872 if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
1873 echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
1874 test "X$echo_testing_string" = "X$echo_test_string"; then
1875 # This shell has a builtin print -r that does the trick.
1876 ECHO='print -r'
1877 elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
1878 test "X$CONFIG_SHELL" != X/bin/ksh; then
1879 # If we have ksh, try running configure again with it.
1880 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1881 export ORIGINAL_CONFIG_SHELL
1882 CONFIG_SHELL=/bin/ksh
1883 export CONFIG_SHELL
1884 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1885 else
1886 # Try using printf.
1887 ECHO='printf %s\n'
1888 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1889 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1890 test "X$echo_testing_string" = "X$echo_test_string"; then
1891 # Cool, printf works
1892 :
1893 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1894 test "X$echo_testing_string" = 'X\t' &&
1895 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1896 test "X$echo_testing_string" = "X$echo_test_string"; then
1897 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1898 export CONFIG_SHELL
1899 SHELL="$CONFIG_SHELL"
1900 export SHELL
1901 ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1902 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1903 test "X$echo_testing_string" = 'X\t' &&
1904 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1905 test "X$echo_testing_string" = "X$echo_test_string"; then
1906 ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1907 else
1908 # maybe with a smaller string...
1909 prev=:
1910
1911 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1912 if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
1913 then
1914 break
1915 fi
1916 prev="$cmd"
1917 done
1918
1919 if test "$prev" != 'sed 50q "[$]0"'; then
1920 echo_test_string=`eval $prev`
1921 export echo_test_string
1922 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1923 else
1924 # Oops. We lost completely, so just stick with echo.
1925 ECHO=echo
1926 fi
1927 fi
1928 fi
1929 fi
1930 fi
1931fi
1932
1933# Copy echo and quote the copy suitably for passing to libtool from
1934# the Makefile, instead of quoting the original, which is used later.
1935lt_ECHO=$ECHO
1936if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1937 lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1938fi
1939
1940AC_SUBST(lt_ECHO)
1941])
1942_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1943_LT_DECL([], [ECHO], [1],
1944 [An echo program that does not interpret backslashes])
1945])# _LT_PROG_ECHO_BACKSLASH
1946
1947
1948# _LT_ENABLE_LOCK
1949# ---------------
1950m4_defun([_LT_ENABLE_LOCK],
1951[AC_ARG_ENABLE([libtool-lock],
1952 [AS_HELP_STRING([--disable-libtool-lock],
1953 [avoid locking (might break parallel builds)])])
1954test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1955
1956# Some flags need to be propagated to the compiler or linker for good
1957# libtool support.
1958case $host in
1959ia64-*-hpux*)
1960 # Find out which ABI we are using.
1961 echo 'int i;' > conftest.$ac_ext
1962 if AC_TRY_EVAL(ac_compile); then
1963 case `/usr/bin/file conftest.$ac_objext` in
1964 *ELF-32*)
1965 HPUX_IA64_MODE="32"
1966 ;;
1967 *ELF-64*)
1968 HPUX_IA64_MODE="64"
1969 ;;
1970 esac
1971 fi
1972 rm -rf conftest*
1973 ;;
1974*-*-irix6*)
1975 # Find out which ABI we are using.
1976 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1977 if AC_TRY_EVAL(ac_compile); then
1978 if test "$lt_cv_prog_gnu_ld" = yes; then
1979 case `/usr/bin/file conftest.$ac_objext` in
1980 *32-bit*)
1981 LD="${LD-ld} -melf32bsmip"
1982 ;;
1983 *N32*)
1984 LD="${LD-ld} -melf32bmipn32"
1985 ;;
1986 *64-bit*)
1987 LD="${LD-ld} -melf64bmip"
1988 ;;
1989 esac
1990 else
1991 case `/usr/bin/file conftest.$ac_objext` in
1992 *32-bit*)
1993 LD="${LD-ld} -32"
1994 ;;
1995 *N32*)
1996 LD="${LD-ld} -n32"
1997 ;;
1998 *64-bit*)
1999 LD="${LD-ld} -64"
2000 ;;
2001 esac
2002 fi
2003 fi
2004 rm -rf conftest*
2005 ;;
2006
2007x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
2008s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
2009 # Find out which ABI we are using.
2010 echo 'int i;' > conftest.$ac_ext
2011 if AC_TRY_EVAL(ac_compile); then
2012 case `/usr/bin/file conftest.o` in
2013 *32-bit*)
2014 case $host in
2015 x86_64-*kfreebsd*-gnu)
2016 LD="${LD-ld} -m elf_i386_fbsd"
2017 ;;
2018 x86_64-*linux*)
2019 LD="${LD-ld} -m elf_i386"
2020 ;;
2021 ppc64-*linux*|powerpc64-*linux*)
2022 LD="${LD-ld} -m elf32ppclinux"
2023 ;;
2024 s390x-*linux*)
2025 LD="${LD-ld} -m elf_s390"
2026 ;;
2027 sparc64-*linux*)
2028 LD="${LD-ld} -m elf32_sparc"
2029 ;;
2030 esac
2031 ;;
2032 *64-bit*)
2033 case $host in
2034 x86_64-*kfreebsd*-gnu)
2035 LD="${LD-ld} -m elf_x86_64_fbsd"
2036 ;;
2037 x86_64-*linux*)
2038 LD="${LD-ld} -m elf_x86_64"
2039 ;;
2040 ppc*-*linux*|powerpc*-*linux*)
2041 LD="${LD-ld} -m elf64ppc"
2042 ;;
2043 s390*-*linux*|s390*-*tpf*)
2044 LD="${LD-ld} -m elf64_s390"
2045 ;;
2046 sparc*-*linux*)
2047 LD="${LD-ld} -m elf64_sparc"
2048 ;;
2049 esac
2050 ;;
2051 esac
2052 fi
2053 rm -rf conftest*
2054 ;;
2055
2056*-*-sco3.2v5*)
2057 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2058 SAVE_CFLAGS="$CFLAGS"
2059 CFLAGS="$CFLAGS -belf"
2060 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
2061 [AC_LANG_PUSH(C)
2062 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
2063 AC_LANG_POP])
2064 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2065 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2066 CFLAGS="$SAVE_CFLAGS"
2067 fi
2068 ;;
2069sparc*-*solaris*)
2070 # Find out which ABI we are using.
2071 echo 'int i;' > conftest.$ac_ext
2072 if AC_TRY_EVAL(ac_compile); then
2073 case `/usr/bin/file conftest.o` in
2074 *64-bit*)
2075 case $lt_cv_prog_gnu_ld in
2076 yes*) LD="${LD-ld} -m elf64_sparc" ;;
2077 *)
2078 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
2079 LD="${LD-ld} -64"
2080 fi
2081 ;;
2082 esac
2083 ;;
2084 esac
2085 fi
2086 rm -rf conftest*
2087 ;;
2088esac
2089
2090need_locks="$enable_libtool_lock"
2091])# _LT_ENABLE_LOCK
2092
2093
2094# _LT_CMD_OLD_ARCHIVE
2095# -------------------
2096m4_defun([_LT_CMD_OLD_ARCHIVE],
2097[AC_CHECK_TOOL(AR, ar, false)
2098test -z "$AR" && AR=ar
2099test -z "$AR_FLAGS" && AR_FLAGS=cru
2100_LT_DECL([], [AR], [1], [The archiver])
2101_LT_DECL([], [AR_FLAGS], [1])
2102
2103AC_CHECK_TOOL(STRIP, strip, :)
2104test -z "$STRIP" && STRIP=:
2105_LT_DECL([], [STRIP], [1], [A symbol stripping program])
2106
2107AC_CHECK_TOOL(RANLIB, ranlib, :)
2108test -z "$RANLIB" && RANLIB=:
2109_LT_DECL([], [RANLIB], [1],
2110 [Commands used to install an old-style archive])
2111
2112# Determine commands to create old-style static archives.
2113old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
2114old_postinstall_cmds='chmod 644 $oldlib'
2115old_postuninstall_cmds=
2116
2117if test -n "$RANLIB"; then
2118 case $host_os in
2119 openbsd*)
2120 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
2121 ;;
2122 *)
2123 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
2124 ;;
2125 esac
2126 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
2127fi
2128_LT_DECL([], [old_postinstall_cmds], [2])
2129_LT_DECL([], [old_postuninstall_cmds], [2])
2130_LT_TAGDECL([], [old_archive_cmds], [2],
2131 [Commands used to build an old-style archive])
2132])# _LT_CMD_OLD_ARCHIVE
2133
2134
2135# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2136# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
2137# ----------------------------------------------------------------
2138# Check whether the given compiler option works
2139AC_DEFUN([_LT_COMPILER_OPTION],
2140[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2141m4_require([_LT_DECL_SED])dnl
2142AC_CACHE_CHECK([$1], [$2],
2143 [$2=no
2144 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
2145 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2146 lt_compiler_flag="$3"
2147 # Insert the option either (1) after the last *FLAGS variable, or
2148 # (2) before a word containing "conftest.", or (3) at the end.
2149 # Note that $ac_compile itself does not contain backslashes and begins
2150 # with a dollar sign (not a hyphen), so the echo should work correctly.
2151 # The option is referenced via a variable to avoid confusing sed.
2152 lt_compile=`echo "$ac_compile" | $SED \
2153 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2154 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2155 -e 's:$: $lt_compiler_flag:'`
2156 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2157 (eval "$lt_compile" 2>conftest.err)
2158 ac_status=$?
2159 cat conftest.err >&AS_MESSAGE_LOG_FD
2160 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2161 if (exit $ac_status) && test -s "$ac_outfile"; then
2162 # The compiler can only warn and ignore the option if not recognized
2163 # So say no if there are warnings other than the usual output.
2164 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
2165 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2166 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2167 $2=yes
2168 fi
2169 fi
2170 $RM conftest*
2171])
2172
2173if test x"[$]$2" = xyes; then
2174 m4_if([$5], , :, [$5])
2175else
2176 m4_if([$6], , :, [$6])
2177fi
2178])# _LT_COMPILER_OPTION
2179
2180# Old name:
2181AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2182dnl aclocal-1.4 backwards compatibility:
2183dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2184
2185
2186# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2187# [ACTION-SUCCESS], [ACTION-FAILURE])
2188# ----------------------------------------------------
2189# Check whether the given linker option works
2190AC_DEFUN([_LT_LINKER_OPTION],
2191[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2192m4_require([_LT_DECL_SED])dnl
2193AC_CACHE_CHECK([$1], [$2],
2194 [$2=no
2195 save_LDFLAGS="$LDFLAGS"
2196 LDFLAGS="$LDFLAGS $3"
2197 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2198 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2199 # The linker can only warn and ignore the option if not recognized
2200 # So say no if there are warnings
2201 if test -s conftest.err; then
2202 # Append any errors to the config.log.
2203 cat conftest.err 1>&AS_MESSAGE_LOG_FD
2204 $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
2205 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2206 if diff conftest.exp conftest.er2 >/dev/null; then
2207 $2=yes
2208 fi
2209 else
2210 $2=yes
2211 fi
2212 fi
2213 $RM -r conftest*
2214 LDFLAGS="$save_LDFLAGS"
2215])
2216
2217if test x"[$]$2" = xyes; then
2218 m4_if([$4], , :, [$4])
2219else
2220 m4_if([$5], , :, [$5])
2221fi
2222])# _LT_LINKER_OPTION
2223
2224# Old name:
2225AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2226dnl aclocal-1.4 backwards compatibility:
2227dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2228
2229
2230# LT_CMD_MAX_LEN
2231#---------------
2232AC_DEFUN([LT_CMD_MAX_LEN],
2233[AC_REQUIRE([AC_CANONICAL_HOST])dnl
2234# find the maximum length of command line arguments
2235AC_MSG_CHECKING([the maximum length of command line arguments])
2236AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2237 i=0
2238 teststring="ABCD"
2239
2240 case $build_os in
2241 msdosdjgpp*)
2242 # On DJGPP, this test can blow up pretty badly due to problems in libc
2243 # (any single argument exceeding 2000 bytes causes a buffer overrun
2244 # during glob expansion). Even if it were fixed, the result of this
2245 # check would be larger than it should be.
2246 lt_cv_sys_max_cmd_len=12288; # 12K is about right
2247 ;;
2248
2249 gnu*)
2250 # Under GNU Hurd, this test is not required because there is
2251 # no limit to the length of command line arguments.
2252 # Libtool will interpret -1 as no limit whatsoever
2253 lt_cv_sys_max_cmd_len=-1;
2254 ;;
2255
2256 cygwin* | mingw* | cegcc*)
2257 # On Win9x/ME, this test blows up -- it succeeds, but takes
2258 # about 5 minutes as the teststring grows exponentially.
2259 # Worse, since 9x/ME are not pre-emptively multitasking,
2260 # you end up with a "frozen" computer, even though with patience
2261 # the test eventually succeeds (with a max line length of 256k).
2262 # Instead, let's just punt: use the minimum linelength reported by
2263 # all of the supported platforms: 8192 (on NT/2K/XP).
2264 lt_cv_sys_max_cmd_len=8192;
2265 ;;
2266
2267 amigaos*)
2268 # On AmigaOS with pdksh, this test takes hours, literally.
2269 # So we just punt and use a minimum line length of 8192.
2270 lt_cv_sys_max_cmd_len=8192;
2271 ;;
2272
2273 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
2274 # This has been around since 386BSD, at least. Likely further.
2275 if test -x /sbin/sysctl; then
2276 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2277 elif test -x /usr/sbin/sysctl; then
2278 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2279 else
2280 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
2281 fi
2282 # And add a safety zone
2283 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2284 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2285 ;;
2286
2287 interix*)
2288 # We know the value 262144 and hardcode it with a safety zone (like BSD)
2289 lt_cv_sys_max_cmd_len=196608
2290 ;;
2291
2292 osf*)
2293 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2294 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2295 # nice to cause kernel panics so lets avoid the loop below.
2296 # First set a reasonable default.
2297 lt_cv_sys_max_cmd_len=16384
2298 #
2299 if test -x /sbin/sysconfig; then
2300 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2301 *1*) lt_cv_sys_max_cmd_len=-1 ;;
2302 esac
2303 fi
2304 ;;
2305 sco3.2v5*)
2306 lt_cv_sys_max_cmd_len=102400
2307 ;;
2308 sysv5* | sco5v6* | sysv4.2uw2*)
2309 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2310 if test -n "$kargmax"; then
2311 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
2312 else
2313 lt_cv_sys_max_cmd_len=32768
2314 fi
2315 ;;
2316 *)
2317 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
2318 if test -n "$lt_cv_sys_max_cmd_len"; then
2319 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2320 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2321 else
2322 # Make teststring a little bigger before we do anything with it.
2323 # a 1K string should be a reasonable start.
2324 for i in 1 2 3 4 5 6 7 8 ; do
2325 teststring=$teststring$teststring
2326 done
2327 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
2328 # If test is not a shell built-in, we'll probably end up computing a
2329 # maximum length that is only half of the actual maximum length, but
2330 # we can't tell.
2331 while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
2332 = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
2333 test $i != 17 # 1/2 MB should be enough
2334 do
2335 i=`expr $i + 1`
2336 teststring=$teststring$teststring
2337 done
2338 # Only check the string length outside the loop.
2339 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
2340 teststring=
2341 # Add a significant safety factor because C++ compilers can tack on
2342 # massive amounts of additional arguments before passing them to the
2343 # linker. It appears as though 1/2 is a usable value.
2344 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
2345 fi
2346 ;;
2347 esac
2348])
2349if test -n $lt_cv_sys_max_cmd_len ; then
2350 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
2351else
2352 AC_MSG_RESULT(none)
2353fi
2354max_cmd_len=$lt_cv_sys_max_cmd_len
2355_LT_DECL([], [max_cmd_len], [0],
2356 [What is the maximum length of a command?])
2357])# LT_CMD_MAX_LEN
2358
2359# Old name:
2360AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
2361dnl aclocal-1.4 backwards compatibility:
2362dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
2363
2364
2365# _LT_HEADER_DLFCN
2366# ----------------
2367m4_defun([_LT_HEADER_DLFCN],
2368[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
2369])# _LT_HEADER_DLFCN
2370
2371
2372# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
2373# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
2374# ----------------------------------------------------------------
2375m4_defun([_LT_TRY_DLOPEN_SELF],
2376[m4_require([_LT_HEADER_DLFCN])dnl
2377if test "$cross_compiling" = yes; then :
2378 [$4]
2379else
2380 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
2381 lt_status=$lt_dlunknown
2382 cat > conftest.$ac_ext <<_LT_EOF
2383[#line __oline__ "configure"
2384#include "confdefs.h"
2385
2386#if HAVE_DLFCN_H
2387#include <dlfcn.h>
2388#endif
2389
2390#include <stdio.h>
2391
2392#ifdef RTLD_GLOBAL
2393# define LT_DLGLOBAL RTLD_GLOBAL
2394#else
2395# ifdef DL_GLOBAL
2396# define LT_DLGLOBAL DL_GLOBAL
2397# else
2398# define LT_DLGLOBAL 0
2399# endif
2400#endif
2401
2402/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
2403 find out it does not work in some platform. */
2404#ifndef LT_DLLAZY_OR_NOW
2405# ifdef RTLD_LAZY
2406# define LT_DLLAZY_OR_NOW RTLD_LAZY
2407# else
2408# ifdef DL_LAZY
2409# define LT_DLLAZY_OR_NOW DL_LAZY
2410# else
2411# ifdef RTLD_NOW
2412# define LT_DLLAZY_OR_NOW RTLD_NOW
2413# else
2414# ifdef DL_NOW
2415# define LT_DLLAZY_OR_NOW DL_NOW
2416# else
2417# define LT_DLLAZY_OR_NOW 0
2418# endif
2419# endif
2420# endif
2421# endif
2422#endif
2423
2424void fnord() { int i=42;}
2425int main ()
2426{
2427 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
2428 int status = $lt_dlunknown;
2429
2430 if (self)
2431 {
2432 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
2433 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
2434 /* dlclose (self); */
2435 }
2436 else
2437 puts (dlerror ());
2438
2439 return status;
2440}]
2441_LT_EOF
2442 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
2443 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
2444 lt_status=$?
2445 case x$lt_status in
2446 x$lt_dlno_uscore) $1 ;;
2447 x$lt_dlneed_uscore) $2 ;;
2448 x$lt_dlunknown|x*) $3 ;;
2449 esac
2450 else :
2451 # compilation failed
2452 $3
2453 fi
2454fi
2455rm -fr conftest*
2456])# _LT_TRY_DLOPEN_SELF
2457
2458
2459# LT_SYS_DLOPEN_SELF
2460# ------------------
2461AC_DEFUN([LT_SYS_DLOPEN_SELF],
2462[m4_require([_LT_HEADER_DLFCN])dnl
2463if test "x$enable_dlopen" != xyes; then
2464 enable_dlopen=unknown
2465 enable_dlopen_self=unknown
2466 enable_dlopen_self_static=unknown
2467else
2468 lt_cv_dlopen=no
2469 lt_cv_dlopen_libs=
2470
2471 case $host_os in
2472 beos*)
2473 lt_cv_dlopen="load_add_on"
2474 lt_cv_dlopen_libs=
2475 lt_cv_dlopen_self=yes
2476 ;;
2477
2478 mingw* | pw32* | cegcc*)
2479 lt_cv_dlopen="LoadLibrary"
2480 lt_cv_dlopen_libs=
2481 ;;
2482
2483 cygwin*)
2484 lt_cv_dlopen="dlopen"
2485 lt_cv_dlopen_libs=
2486 ;;
2487
2488 darwin*)
2489 # if libdl is installed we need to link against it
2490 AC_CHECK_LIB([dl], [dlopen],
2491 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
2492 lt_cv_dlopen="dyld"
2493 lt_cv_dlopen_libs=
2494 lt_cv_dlopen_self=yes
2495 ])
2496 ;;
2497
2498 *)
2499 AC_CHECK_FUNC([shl_load],
2500 [lt_cv_dlopen="shl_load"],
2501 [AC_CHECK_LIB([dld], [shl_load],
2502 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
2503 [AC_CHECK_FUNC([dlopen],
2504 [lt_cv_dlopen="dlopen"],
2505 [AC_CHECK_LIB([dl], [dlopen],
2506 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
2507 [AC_CHECK_LIB([svld], [dlopen],
2508 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
2509 [AC_CHECK_LIB([dld], [dld_link],
2510 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
2511 ])
2512 ])
2513 ])
2514 ])
2515 ])
2516 ;;
2517 esac
2518
2519 if test "x$lt_cv_dlopen" != xno; then
2520 enable_dlopen=yes
2521 else
2522 enable_dlopen=no
2523 fi
2524
2525 case $lt_cv_dlopen in
2526 dlopen)
2527 save_CPPFLAGS="$CPPFLAGS"
2528 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2529
2530 save_LDFLAGS="$LDFLAGS"
2531 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2532
2533 save_LIBS="$LIBS"
2534 LIBS="$lt_cv_dlopen_libs $LIBS"
2535
2536 AC_CACHE_CHECK([whether a program can dlopen itself],
2537 lt_cv_dlopen_self, [dnl
2538 _LT_TRY_DLOPEN_SELF(
2539 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2540 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2541 ])
2542
2543 if test "x$lt_cv_dlopen_self" = xyes; then
2544 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2545 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2546 lt_cv_dlopen_self_static, [dnl
2547 _LT_TRY_DLOPEN_SELF(
2548 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2549 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2550 ])
2551 fi
2552
2553 CPPFLAGS="$save_CPPFLAGS"
2554 LDFLAGS="$save_LDFLAGS"
2555 LIBS="$save_LIBS"
2556 ;;
2557 esac
2558
2559 case $lt_cv_dlopen_self in
2560 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2561 *) enable_dlopen_self=unknown ;;
2562 esac
2563
2564 case $lt_cv_dlopen_self_static in
2565 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2566 *) enable_dlopen_self_static=unknown ;;
2567 esac
2568fi
2569_LT_DECL([dlopen_support], [enable_dlopen], [0],
2570 [Whether dlopen is supported])
2571_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2572 [Whether dlopen of programs is supported])
2573_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2574 [Whether dlopen of statically linked programs is supported])
2575])# LT_SYS_DLOPEN_SELF
2576
2577# Old name:
2578AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2579dnl aclocal-1.4 backwards compatibility:
2580dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2581
2582
2583# _LT_COMPILER_C_O([TAGNAME])
2584# ---------------------------
2585# Check to see if options -c and -o are simultaneously supported by compiler.
2586# This macro does not hard code the compiler like AC_PROG_CC_C_O.
2587m4_defun([_LT_COMPILER_C_O],
2588[m4_require([_LT_DECL_SED])dnl
2589m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2590m4_require([_LT_TAG_COMPILER])dnl
2591AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2592 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2593 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2594 $RM -r conftest 2>/dev/null
2595 mkdir conftest
2596 cd conftest
2597 mkdir out
2598 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2599
2600 lt_compiler_flag="-o out/conftest2.$ac_objext"
2601 # Insert the option either (1) after the last *FLAGS variable, or
2602 # (2) before a word containing "conftest.", or (3) at the end.
2603 # Note that $ac_compile itself does not contain backslashes and begins
2604 # with a dollar sign (not a hyphen), so the echo should work correctly.
2605 lt_compile=`echo "$ac_compile" | $SED \
2606 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2607 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2608 -e 's:$: $lt_compiler_flag:'`
2609 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2610 (eval "$lt_compile" 2>out/conftest.err)
2611 ac_status=$?
2612 cat out/conftest.err >&AS_MESSAGE_LOG_FD
2613 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2614 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2615 then
2616 # The compiler can only warn and ignore the option if not recognized
2617 # So say no if there are warnings
2618 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
2619 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2620 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2621 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2622 fi
2623 fi
2624 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2625 $RM conftest*
2626 # SGI C++ compiler will create directory out/ii_files/ for
2627 # template instantiation
2628 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2629 $RM out/* && rmdir out
2630 cd ..
2631 $RM -r conftest
2632 $RM conftest*
2633])
2634_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2635 [Does compiler simultaneously support -c and -o options?])
2636])# _LT_COMPILER_C_O
2637
2638
2639# _LT_COMPILER_FILE_LOCKS([TAGNAME])
2640# ----------------------------------
2641# Check to see if we can do hard links to lock some files if needed
2642m4_defun([_LT_COMPILER_FILE_LOCKS],
2643[m4_require([_LT_ENABLE_LOCK])dnl
2644m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2645_LT_COMPILER_C_O([$1])
2646
2647hard_links="nottested"
2648if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2649 # do not overwrite the value of need_locks provided by the user
2650 AC_MSG_CHECKING([if we can lock with hard links])
2651 hard_links=yes
2652 $RM conftest*
2653 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2654 touch conftest.a
2655 ln conftest.a conftest.b 2>&5 || hard_links=no
2656 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2657 AC_MSG_RESULT([$hard_links])
2658 if test "$hard_links" = no; then
2659 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2660 need_locks=warn
2661 fi
2662else
2663 need_locks=no
2664fi
2665_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2666])# _LT_COMPILER_FILE_LOCKS
2667
2668
2669# _LT_CHECK_OBJDIR
2670# ----------------
2671m4_defun([_LT_CHECK_OBJDIR],
2672[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2673[rm -f .libs 2>/dev/null
2674mkdir .libs 2>/dev/null
2675if test -d .libs; then
2676 lt_cv_objdir=.libs
2677else
2678 # MS-DOS does not allow filenames that begin with a dot.
2679 lt_cv_objdir=_libs
2680fi
2681rmdir .libs 2>/dev/null])
2682objdir=$lt_cv_objdir
2683_LT_DECL([], [objdir], [0],
2684 [The name of the directory that contains temporary libtool files])dnl
2685m4_pattern_allow([LT_OBJDIR])dnl
2686AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2687 [Define to the sub-directory in which libtool stores uninstalled libraries.])
2688])# _LT_CHECK_OBJDIR
2689
2690
2691# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2692# --------------------------------------
2693# Check hardcoding attributes.
2694m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2695[AC_MSG_CHECKING([how to hardcode library paths into programs])
2696_LT_TAGVAR(hardcode_action, $1)=
2697if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2698 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2699 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2700
2701 # We can hardcode non-existent directories.
2702 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2703 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2704 # have to relink, otherwise we might link with an installed library
2705 # when we should be linking with a yet-to-be-installed one
2706 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2707 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2708 # Linking always hardcodes the temporary library directory.
2709 _LT_TAGVAR(hardcode_action, $1)=relink
2710 else
2711 # We can link without hardcoding, and we can hardcode nonexisting dirs.
2712 _LT_TAGVAR(hardcode_action, $1)=immediate
2713 fi
2714else
2715 # We cannot hardcode anything, or else we can only hardcode existing
2716 # directories.
2717 _LT_TAGVAR(hardcode_action, $1)=unsupported
2718fi
2719AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2720
2721if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2722 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2723 # Fast installation is not supported
2724 enable_fast_install=no
2725elif test "$shlibpath_overrides_runpath" = yes ||
2726 test "$enable_shared" = no; then
2727 # Fast installation is not necessary
2728 enable_fast_install=needless
2729fi
2730_LT_TAGDECL([], [hardcode_action], [0],
2731 [How to hardcode a shared library path into an executable])
2732])# _LT_LINKER_HARDCODE_LIBPATH
2733
2734
2735# _LT_CMD_STRIPLIB
2736# ----------------
2737m4_defun([_LT_CMD_STRIPLIB],
2738[m4_require([_LT_DECL_EGREP])
2739striplib=
2740old_striplib=
2741AC_MSG_CHECKING([whether stripping libraries is possible])
2742if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2743 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2744 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2745 AC_MSG_RESULT([yes])
2746else
2747# FIXME - insert some real tests, host_os isn't really good enough
2748 case $host_os in
2749 darwin*)
2750 if test -n "$STRIP" ; then
2751 striplib="$STRIP -x"
2752 old_striplib="$STRIP -S"
2753 AC_MSG_RESULT([yes])
2754 else
2755 AC_MSG_RESULT([no])
2756 fi
2757 ;;
2758 *)
2759 AC_MSG_RESULT([no])
2760 ;;
2761 esac
2762fi
2763_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2764_LT_DECL([], [striplib], [1])
2765])# _LT_CMD_STRIPLIB
2766
2767
2768# _LT_SYS_DYNAMIC_LINKER([TAG])
2769# -----------------------------
2770# PORTME Fill in your ld.so characteristics
2771m4_defun([_LT_SYS_DYNAMIC_LINKER],
2772[AC_REQUIRE([AC_CANONICAL_HOST])dnl
2773m4_require([_LT_DECL_EGREP])dnl
2774m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2775m4_require([_LT_DECL_OBJDUMP])dnl
2776m4_require([_LT_DECL_SED])dnl
2777AC_MSG_CHECKING([dynamic linker characteristics])
2778m4_if([$1],
2779 [], [
2780if test "$GCC" = yes; then
2781 case $host_os in
2782 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2783 *) lt_awk_arg="/^libraries:/" ;;
2784 esac
2785 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2786 if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
2787 # if the path contains ";" then we assume it to be the separator
2788 # otherwise default to the standard path separator (i.e. ":") - it is
2789 # assumed that no part of a normal pathname contains ";" but that should
2790 # okay in the real world where ";" in dirpaths is itself problematic.
2791 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
2792 else
2793 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2794 fi
2795 # Ok, now we have the path, separated by spaces, we can step through it
2796 # and add multilib dir if necessary.
2797 lt_tmp_lt_search_path_spec=
2798 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2799 for lt_sys_path in $lt_search_path_spec; do
2800 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2801 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2802 else
2803 test -d "$lt_sys_path" && \
2804 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2805 fi
2806 done
2807 lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
2808BEGIN {RS=" "; FS="/|\n";} {
2809 lt_foo="";
2810 lt_count=0;
2811 for (lt_i = NF; lt_i > 0; lt_i--) {
2812 if ($lt_i != "" && $lt_i != ".") {
2813 if ($lt_i == "..") {
2814 lt_count++;
2815 } else {
2816 if (lt_count == 0) {
2817 lt_foo="/" $lt_i lt_foo;
2818 } else {
2819 lt_count--;
2820 }
2821 }
2822 }
2823 }
2824 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2825 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2826}'`
2827 sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
2828else
2829 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2830fi])
2831library_names_spec=
2832libname_spec='lib$name'
2833soname_spec=
2834shrext_cmds=".so"
2835postinstall_cmds=
2836postuninstall_cmds=
2837finish_cmds=
2838finish_eval=
2839shlibpath_var=
2840shlibpath_overrides_runpath=unknown
2841version_type=none
2842dynamic_linker="$host_os ld.so"
2843sys_lib_dlsearch_path_spec="/lib /usr/lib"
2844need_lib_prefix=unknown
2845hardcode_into_libs=no
2846
2847# when you set need_version to no, make sure it does not cause -set_version
2848# flags to be left without arguments
2849need_version=unknown
2850
2851case $host_os in
2852aix3*)
2853 version_type=linux
2854 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2855 shlibpath_var=LIBPATH
2856
2857 # AIX 3 has no versioning support, so we append a major version to the name.
2858 soname_spec='${libname}${release}${shared_ext}$major'
2859 ;;
2860
2861aix[[4-9]]*)
2862 version_type=linux
2863 need_lib_prefix=no
2864 need_version=no
2865 hardcode_into_libs=yes
2866 if test "$host_cpu" = ia64; then
2867 # AIX 5 supports IA64
2868 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2869 shlibpath_var=LD_LIBRARY_PATH
2870 else
2871 # With GCC up to 2.95.x, collect2 would create an import file
2872 # for dependence libraries. The import file would start with
2873 # the line `#! .'. This would cause the generated library to
2874 # depend on `.', always an invalid library. This was fixed in
2875 # development snapshots of GCC prior to 3.0.
2876 case $host_os in
2877 aix4 | aix4.[[01]] | aix4.[[01]].*)
2878 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2879 echo ' yes '
2880 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2881 :
2882 else
2883 can_build_shared=no
2884 fi
2885 ;;
2886 esac
2887 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2888 # soname into executable. Probably we can add versioning support to
2889 # collect2, so additional links can be useful in future.
2890 if test "$aix_use_runtimelinking" = yes; then
2891 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2892 # instead of lib<name>.a to let people know that these are not
2893 # typical AIX shared libraries.
2894 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2895 else
2896 # We preserve .a as extension for shared libraries through AIX4.2
2897 # and later when we are not doing run time linking.
2898 library_names_spec='${libname}${release}.a $libname.a'
2899 soname_spec='${libname}${release}${shared_ext}$major'
2900 fi
2901 shlibpath_var=LIBPATH
2902 fi
2903 ;;
2904
2905amigaos*)
2906 case $host_cpu in
2907 powerpc)
2908 # Since July 2007 AmigaOS4 officially supports .so libraries.
2909 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2910 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2911 ;;
2912 m68k)
2913 library_names_spec='$libname.ixlibrary $libname.a'
2914 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2915 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2916 ;;
2917 esac
2918 ;;
2919
2920beos*)
2921 library_names_spec='${libname}${shared_ext}'
2922 dynamic_linker="$host_os ld.so"
2923 shlibpath_var=LIBRARY_PATH
2924 ;;
2925
2926bsdi[[45]]*)
2927 version_type=linux
2928 need_version=no
2929 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2930 soname_spec='${libname}${release}${shared_ext}$major'
2931 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2932 shlibpath_var=LD_LIBRARY_PATH
2933 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2934 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2935 # the default ld.so.conf also contains /usr/contrib/lib and
2936 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2937 # libtool to hard-code these into programs
2938 ;;
2939
2940cygwin* | mingw* | pw32* | cegcc*)
2941 version_type=windows
2942 shrext_cmds=".dll"
2943 need_version=no
2944 need_lib_prefix=no
2945
2946 case $GCC,$host_os in
2947 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
2948 library_names_spec='$libname.dll.a'
2949 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2950 postinstall_cmds='base_file=`basename \${file}`~
2951 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2952 dldir=$destdir/`dirname \$dlpath`~
2953 test -d \$dldir || mkdir -p \$dldir~
2954 $install_prog $dir/$dlname \$dldir/$dlname~
2955 chmod a+x \$dldir/$dlname~
2956 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2957 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2958 fi'
2959 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2960 dlpath=$dir/\$dldll~
2961 $RM \$dlpath'
2962 shlibpath_overrides_runpath=yes
2963
2964 case $host_os in
2965 cygwin*)
2966 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2967 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2968 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2969 ;;
2970 mingw* | cegcc*)
2971 # MinGW DLLs use traditional 'lib' prefix
2972 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2973 sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2974 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2975 # It is most probably a Windows format PATH printed by
2976 # mingw gcc, but we are running on Cygwin. Gcc prints its search
2977 # path with ; separators, and with drive letters. We can handle the
2978 # drive letters (cygwin fileutils understands them), so leave them,
2979 # especially as we might pass files found there to a mingw objdump,
2980 # which wouldn't understand a cygwinified path. Ahh.
2981 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2982 else
2983 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2984 fi
2985 ;;
2986 pw32*)
2987 # pw32 DLLs use 'pw' prefix rather than 'lib'
2988 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2989 ;;
2990 esac
2991 ;;
2992
2993 *)
2994 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2995 ;;
2996 esac
2997 dynamic_linker='Win32 ld.exe'
2998 # FIXME: first we should search . and the directory the executable is in
2999 shlibpath_var=PATH
3000 ;;
3001
3002darwin* | rhapsody*)
3003 dynamic_linker="$host_os dyld"
3004 version_type=darwin
3005 need_lib_prefix=no
3006 need_version=no
3007 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
3008 soname_spec='${libname}${release}${major}$shared_ext'
3009 shlibpath_overrides_runpath=yes
3010 shlibpath_var=DYLD_LIBRARY_PATH
3011 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3012m4_if([$1], [],[
3013 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3014 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3015 ;;
3016
3017dgux*)
3018 version_type=linux
3019 need_lib_prefix=no
3020 need_version=no
3021 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
3022 soname_spec='${libname}${release}${shared_ext}$major'
3023 shlibpath_var=LD_LIBRARY_PATH
3024 ;;
3025
3026freebsd1*)
3027 dynamic_linker=no
3028 ;;
3029
3030freebsd* | dragonfly*)
3031 # DragonFly does not have aout. When/if they implement a new
3032 # versioning mechanism, adjust this.
3033 if test -x /usr/bin/objformat; then
3034 objformat=`/usr/bin/objformat`
3035 else
3036 case $host_os in
3037 freebsd[[123]]*) objformat=aout ;;
3038 *) objformat=elf ;;
3039 esac
3040 fi
3041 version_type=freebsd-$objformat
3042 case $version_type in
3043 freebsd-elf*)
3044 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3045 need_version=no
3046 need_lib_prefix=no
3047 ;;
3048 freebsd-*)
3049 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
3050 need_version=yes
3051 ;;
3052 esac
3053 shlibpath_var=LD_LIBRARY_PATH
3054 case $host_os in
3055 freebsd2*)
3056 shlibpath_overrides_runpath=yes
3057 ;;
3058 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3059 shlibpath_overrides_runpath=yes
3060 hardcode_into_libs=yes
3061 ;;
3062 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3063 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3064 shlibpath_overrides_runpath=no
3065 hardcode_into_libs=yes
3066 ;;
3067 *) # from 4.6 on, and DragonFly
3068 shlibpath_overrides_runpath=yes
3069 hardcode_into_libs=yes
3070 ;;
3071 esac
3072 ;;
3073
3074gnu*)
3075 version_type=linux
3076 need_lib_prefix=no
3077 need_version=no
3078 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3079 soname_spec='${libname}${release}${shared_ext}$major'
3080 shlibpath_var=LD_LIBRARY_PATH
3081 hardcode_into_libs=yes
3082 ;;
3083
3084hpux9* | hpux10* | hpux11*)
3085 # Give a soname corresponding to the major version so that dld.sl refuses to
3086 # link against other versions.
3087 version_type=sunos
3088 need_lib_prefix=no
3089 need_version=no
3090 case $host_cpu in
3091 ia64*)
3092 shrext_cmds='.so'
3093 hardcode_into_libs=yes
3094 dynamic_linker="$host_os dld.so"
3095 shlibpath_var=LD_LIBRARY_PATH
3096 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3097 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3098 soname_spec='${libname}${release}${shared_ext}$major'
3099 if test "X$HPUX_IA64_MODE" = X32; then
3100 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3101 else
3102 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
3103 fi
3104 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3105 ;;
3106 hppa*64*)
3107 shrext_cmds='.sl'
3108 hardcode_into_libs=yes
3109 dynamic_linker="$host_os dld.sl"
3110 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
3111 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3112 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3113 soname_spec='${libname}${release}${shared_ext}$major'
3114 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3115 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3116 ;;
3117 *)
3118 shrext_cmds='.sl'
3119 dynamic_linker="$host_os dld.sl"
3120 shlibpath_var=SHLIB_PATH
3121 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3122 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3123 soname_spec='${libname}${release}${shared_ext}$major'
3124 ;;
3125 esac
3126 # HP-UX runs *really* slowly unless shared libraries are mode 555.
3127 postinstall_cmds='chmod 555 $lib'
3128 ;;
3129
3130interix[[3-9]]*)
3131 version_type=linux
3132 need_lib_prefix=no
3133 need_version=no
3134 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3135 soname_spec='${libname}${release}${shared_ext}$major'
3136 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3137 shlibpath_var=LD_LIBRARY_PATH
3138 shlibpath_overrides_runpath=no
3139 hardcode_into_libs=yes
3140 ;;
3141
3142irix5* | irix6* | nonstopux*)
3143 case $host_os in
3144 nonstopux*) version_type=nonstopux ;;
3145 *)
3146 if test "$lt_cv_prog_gnu_ld" = yes; then
3147 version_type=linux
3148 else
3149 version_type=irix
3150 fi ;;
3151 esac
3152 need_lib_prefix=no
3153 need_version=no
3154 soname_spec='${libname}${release}${shared_ext}$major'
3155 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
3156 case $host_os in
3157 irix5* | nonstopux*)
3158 libsuff= shlibsuff=
3159 ;;
3160 *)
3161 case $LD in # libtool.m4 will add one of these switches to LD
3162 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3163 libsuff= shlibsuff= libmagic=32-bit;;
3164 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3165 libsuff=32 shlibsuff=N32 libmagic=N32;;
3166 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3167 libsuff=64 shlibsuff=64 libmagic=64-bit;;
3168 *) libsuff= shlibsuff= libmagic=never-match;;
3169 esac
3170 ;;
3171 esac
3172 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3173 shlibpath_overrides_runpath=no
3174 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
3175 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
3176 hardcode_into_libs=yes
3177 ;;
3178
3179# No shared lib support for Linux oldld, aout, or coff.
3180linux*oldld* | linux*aout* | linux*coff*)
3181 dynamic_linker=no
3182 ;;
3183
3184# This must be Linux ELF.
3185linux* | k*bsd*-gnu | kopensolaris*-gnu)
3186 version_type=linux
3187 need_lib_prefix=no
3188 need_version=no
3189 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3190 soname_spec='${libname}${release}${shared_ext}$major'
3191 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3192 shlibpath_var=LD_LIBRARY_PATH
3193 shlibpath_overrides_runpath=no
3194 # Some binutils ld are patched to set DT_RUNPATH
3195 save_LDFLAGS=$LDFLAGS
3196 save_libdir=$libdir
3197 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3198 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3199 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3200 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3201 [shlibpath_overrides_runpath=yes])])
3202 LDFLAGS=$save_LDFLAGS
3203 libdir=$save_libdir
3204
3205 # This implies no fast_install, which is unacceptable.
3206 # Some rework will be needed to allow for fast_install
3207 # before this can be enabled.
3208 hardcode_into_libs=yes
3209
3210 # Append ld.so.conf contents to the search path
3211 if test -f /etc/ld.so.conf; then
3212 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
3213 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3214 fi
3215
3216 # We used to test for /lib/ld.so.1 and disable shared libraries on
3217 # powerpc, because MkLinux only supported shared libraries with the
3218 # GNU dynamic linker. Since this was broken with cross compilers,
3219 # most powerpc-linux boxes support dynamic linking these days and
3220 # people can always --disable-shared, the test was removed, and we
3221 # assume the GNU/Linux dynamic linker is in use.
3222 dynamic_linker='GNU/Linux ld.so'
3223 ;;
3224
3225netbsdelf*-gnu)
3226 version_type=linux
3227 need_lib_prefix=no
3228 need_version=no
3229 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3230 soname_spec='${libname}${release}${shared_ext}$major'
3231 shlibpath_var=LD_LIBRARY_PATH
3232 shlibpath_overrides_runpath=no
3233 hardcode_into_libs=yes
3234 dynamic_linker='NetBSD ld.elf_so'
3235 ;;
3236
3237netbsd*)
3238 version_type=sunos
3239 need_lib_prefix=no
3240 need_version=no
3241 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
3242 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3243 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3244 dynamic_linker='NetBSD (a.out) ld.so'
3245 else
3246 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3247 soname_spec='${libname}${release}${shared_ext}$major'
3248 dynamic_linker='NetBSD ld.elf_so'
3249 fi
3250 shlibpath_var=LD_LIBRARY_PATH
3251 shlibpath_overrides_runpath=yes
3252 hardcode_into_libs=yes
3253 ;;
3254
3255newsos6)
3256 version_type=linux
3257 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3258 shlibpath_var=LD_LIBRARY_PATH
3259 shlibpath_overrides_runpath=yes
3260 ;;
3261
3262*nto* | *qnx*)
3263 version_type=qnx
3264 need_lib_prefix=no
3265 need_version=no
3266 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3267 soname_spec='${libname}${release}${shared_ext}$major'
3268 shlibpath_var=LD_LIBRARY_PATH
3269 shlibpath_overrides_runpath=no
3270 hardcode_into_libs=yes
3271 dynamic_linker='ldqnx.so'
3272 ;;
3273
3274openbsd*)
3275 version_type=sunos
3276 sys_lib_dlsearch_path_spec="/usr/lib"
3277 need_lib_prefix=no
3278 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
3279 case $host_os in
3280 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
3281 *) need_version=no ;;
3282 esac
3283 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3284 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3285 shlibpath_var=LD_LIBRARY_PATH
3286 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3287 case $host_os in
3288 openbsd2.[[89]] | openbsd2.[[89]].*)
3289 shlibpath_overrides_runpath=no
3290 ;;
3291 *)
3292 shlibpath_overrides_runpath=yes
3293 ;;
3294 esac
3295 else
3296 shlibpath_overrides_runpath=yes
3297 fi
3298 ;;
3299
3300os2*)
3301 libname_spec='$name'
3302 shrext_cmds=".dll"
3303 need_lib_prefix=no
3304 library_names_spec='$libname${shared_ext} $libname.a'
3305 dynamic_linker='OS/2 ld.exe'
3306 shlibpath_var=LIBPATH
3307 ;;
3308
3309osf3* | osf4* | osf5*)
3310 version_type=osf
3311 need_lib_prefix=no
3312 need_version=no
3313 soname_spec='${libname}${release}${shared_ext}$major'
3314 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3315 shlibpath_var=LD_LIBRARY_PATH
3316 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
3317 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
3318 ;;
3319
3320rdos*)
3321 dynamic_linker=no
3322 ;;
3323
3324solaris*)
3325 version_type=linux
3326 need_lib_prefix=no
3327 need_version=no
3328 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3329 soname_spec='${libname}${release}${shared_ext}$major'
3330 shlibpath_var=LD_LIBRARY_PATH
3331 shlibpath_overrides_runpath=yes
3332 hardcode_into_libs=yes
3333 # ldd complains unless libraries are executable
3334 postinstall_cmds='chmod +x $lib'
3335 ;;
3336
3337sunos4*)
3338 version_type=sunos
3339 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3340 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
3341 shlibpath_var=LD_LIBRARY_PATH
3342 shlibpath_overrides_runpath=yes
3343 if test "$with_gnu_ld" = yes; then
3344 need_lib_prefix=no
3345 fi
3346 need_version=yes
3347 ;;
3348
3349sysv4 | sysv4.3*)
3350 version_type=linux
3351 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3352 soname_spec='${libname}${release}${shared_ext}$major'
3353 shlibpath_var=LD_LIBRARY_PATH
3354 case $host_vendor in
3355 sni)
3356 shlibpath_overrides_runpath=no
3357 need_lib_prefix=no
3358 runpath_var=LD_RUN_PATH
3359 ;;
3360 siemens)
3361 need_lib_prefix=no
3362 ;;
3363 motorola)
3364 need_lib_prefix=no
3365 need_version=no
3366 shlibpath_overrides_runpath=no
3367 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
3368 ;;
3369 esac
3370 ;;
3371
3372sysv4*MP*)
3373 if test -d /usr/nec ;then
3374 version_type=linux
3375 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
3376 soname_spec='$libname${shared_ext}.$major'
3377 shlibpath_var=LD_LIBRARY_PATH
3378 fi
3379 ;;
3380
3381sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3382 version_type=freebsd-elf
3383 need_lib_prefix=no
3384 need_version=no
3385 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3386 soname_spec='${libname}${release}${shared_ext}$major'
3387 shlibpath_var=LD_LIBRARY_PATH
3388 shlibpath_overrides_runpath=yes
3389 hardcode_into_libs=yes
3390 if test "$with_gnu_ld" = yes; then
3391 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
3392 else
3393 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
3394 case $host_os in
3395 sco3.2v5*)
3396 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
3397 ;;
3398 esac
3399 fi
3400 sys_lib_dlsearch_path_spec='/usr/lib'
3401 ;;
3402
3403tpf*)
3404 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
3405 version_type=linux
3406 need_lib_prefix=no
3407 need_version=no
3408 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3409 shlibpath_var=LD_LIBRARY_PATH
3410 shlibpath_overrides_runpath=no
3411 hardcode_into_libs=yes
3412 ;;
3413
3414uts4*)
3415 version_type=linux
3416 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3417 soname_spec='${libname}${release}${shared_ext}$major'
3418 shlibpath_var=LD_LIBRARY_PATH
3419 ;;
3420
3421*)
3422 dynamic_linker=no
3423 ;;
3424esac
3425AC_MSG_RESULT([$dynamic_linker])
3426test "$dynamic_linker" = no && can_build_shared=no
3427
3428variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3429if test "$GCC" = yes; then
3430 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3431fi
3432
3433if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
3434 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
3435fi
3436if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
3437 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
3438fi
3439
3440_LT_DECL([], [variables_saved_for_relink], [1],
3441 [Variables whose values should be saved in libtool wrapper scripts and
3442 restored at link time])
3443_LT_DECL([], [need_lib_prefix], [0],
3444 [Do we need the "lib" prefix for modules?])
3445_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3446_LT_DECL([], [version_type], [0], [Library versioning type])
3447_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3448_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3449_LT_DECL([], [shlibpath_overrides_runpath], [0],
3450 [Is shlibpath searched before the hard-coded library search path?])
3451_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3452_LT_DECL([], [library_names_spec], [1],
3453 [[List of archive names. First name is the real one, the rest are links.
3454 The last name is the one that the linker finds with -lNAME]])
3455_LT_DECL([], [soname_spec], [1],
3456 [[The coded name of the library, if different from the real name]])
3457_LT_DECL([], [postinstall_cmds], [2],
3458 [Command to use after installation of a shared archive])
3459_LT_DECL([], [postuninstall_cmds], [2],
3460 [Command to use after uninstallation of a shared archive])
3461_LT_DECL([], [finish_cmds], [2],
3462 [Commands used to finish a libtool library installation in a directory])
3463_LT_DECL([], [finish_eval], [1],
3464 [[As "finish_cmds", except a single script fragment to be evaled but
3465 not shown]])
3466_LT_DECL([], [hardcode_into_libs], [0],
3467 [Whether we should hardcode library paths into libraries])
3468_LT_DECL([], [sys_lib_search_path_spec], [2],
3469 [Compile-time system search path for libraries])
3470_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3471 [Run-time system search path for libraries])
3472])# _LT_SYS_DYNAMIC_LINKER
3473
3474
3475# _LT_PATH_TOOL_PREFIX(TOOL)
3476# --------------------------
3477# find a file program which can recognize shared library
3478AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3479[m4_require([_LT_DECL_EGREP])dnl
3480AC_MSG_CHECKING([for $1])
3481AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3482[case $MAGIC_CMD in
3483[[\\/*] | ?:[\\/]*])
3484 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3485 ;;
3486*)
3487 lt_save_MAGIC_CMD="$MAGIC_CMD"
3488 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3489dnl $ac_dummy forces splitting on constant user-supplied paths.
3490dnl POSIX.2 word splitting is done only on the output of word expansions,
3491dnl not every word. This closes a longstanding sh security hole.
3492 ac_dummy="m4_if([$2], , $PATH, [$2])"
3493 for ac_dir in $ac_dummy; do
3494 IFS="$lt_save_ifs"
3495 test -z "$ac_dir" && ac_dir=.
3496 if test -f $ac_dir/$1; then
3497 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3498 if test -n "$file_magic_test_file"; then
3499 case $deplibs_check_method in
3500 "file_magic "*)
3501 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3502 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3503 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3504 $EGREP "$file_magic_regex" > /dev/null; then
3505 :
3506 else
3507 cat <<_LT_EOF 1>&2
3508
3509*** Warning: the command libtool uses to detect shared libraries,
3510*** $file_magic_cmd, produces output that libtool cannot recognize.
3511*** The result is that libtool may fail to recognize shared libraries
3512*** as such. This will affect the creation of libtool libraries that
3513*** depend on shared libraries, but programs linked with such libtool
3514*** libraries will work regardless of this problem. Nevertheless, you
3515*** may want to report the problem to your system manager and/or to
3516*** bug-libtool@gnu.org
3517
3518_LT_EOF
3519 fi ;;
3520 esac
3521 fi
3522 break
3523 fi
3524 done
3525 IFS="$lt_save_ifs"
3526 MAGIC_CMD="$lt_save_MAGIC_CMD"
3527 ;;
3528esac])
3529MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3530if test -n "$MAGIC_CMD"; then
3531 AC_MSG_RESULT($MAGIC_CMD)
3532else
3533 AC_MSG_RESULT(no)
3534fi
3535_LT_DECL([], [MAGIC_CMD], [0],
3536 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3537])# _LT_PATH_TOOL_PREFIX
3538
3539# Old name:
3540AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3541dnl aclocal-1.4 backwards compatibility:
3542dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3543
3544
3545# _LT_PATH_MAGIC
3546# --------------
3547# find a file program which can recognize a shared library
3548m4_defun([_LT_PATH_MAGIC],
3549[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3550if test -z "$lt_cv_path_MAGIC_CMD"; then
3551 if test -n "$ac_tool_prefix"; then
3552 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3553 else
3554 MAGIC_CMD=:
3555 fi
3556fi
3557])# _LT_PATH_MAGIC
3558
3559
3560# LT_PATH_LD
3561# ----------
3562# find the pathname to the GNU or non-GNU linker
3563AC_DEFUN([LT_PATH_LD],
3564[AC_REQUIRE([AC_PROG_CC])dnl
3565AC_REQUIRE([AC_CANONICAL_HOST])dnl
3566AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3567m4_require([_LT_DECL_SED])dnl
3568m4_require([_LT_DECL_EGREP])dnl
3569
3570AC_ARG_WITH([gnu-ld],
3571 [AS_HELP_STRING([--with-gnu-ld],
3572 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3573 [test "$withval" = no || with_gnu_ld=yes],
3574 [with_gnu_ld=no])dnl
3575
3576ac_prog=ld
3577if test "$GCC" = yes; then
3578 # Check if gcc -print-prog-name=ld gives a path.
3579 AC_MSG_CHECKING([for ld used by $CC])
3580 case $host in
3581 *-*-mingw*)
3582 # gcc leaves a trailing carriage return which upsets mingw
3583 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3584 *)
3585 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3586 esac
3587 case $ac_prog in
3588 # Accept absolute paths.
3589 [[\\/]]* | ?:[[\\/]]*)
3590 re_direlt='/[[^/]][[^/]]*/\.\./'
3591 # Canonicalize the pathname of ld
3592 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3593 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3594 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3595 done
3596 test -z "$LD" && LD="$ac_prog"
3597 ;;
3598 "")
3599 # If it fails, then pretend we aren't using GCC.
3600 ac_prog=ld
3601 ;;
3602 *)
3603 # If it is relative, then search for the first ld in PATH.
3604 with_gnu_ld=unknown
3605 ;;
3606 esac
3607elif test "$with_gnu_ld" = yes; then
3608 AC_MSG_CHECKING([for GNU ld])
3609else
3610 AC_MSG_CHECKING([for non-GNU ld])
3611fi
3612AC_CACHE_VAL(lt_cv_path_LD,
3613[if test -z "$LD"; then
3614 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3615 for ac_dir in $PATH; do
3616 IFS="$lt_save_ifs"
3617 test -z "$ac_dir" && ac_dir=.
3618 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3619 lt_cv_path_LD="$ac_dir/$ac_prog"
3620 # Check to see if the program is GNU ld. I'd rather use --version,
3621 # but apparently some variants of GNU ld only accept -v.
3622 # Break only if it was the GNU/non-GNU ld that we prefer.
3623 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3624 *GNU* | *'with BFD'*)
3625 test "$with_gnu_ld" != no && break
3626 ;;
3627 *)
3628 test "$with_gnu_ld" != yes && break
3629 ;;
3630 esac
3631 fi
3632 done
3633 IFS="$lt_save_ifs"
3634else
3635 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3636fi])
3637LD="$lt_cv_path_LD"
3638if test -n "$LD"; then
3639 AC_MSG_RESULT($LD)
3640else
3641 AC_MSG_RESULT(no)
3642fi
3643test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3644_LT_PATH_LD_GNU
3645AC_SUBST([LD])
3646
3647_LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3648])# LT_PATH_LD
3649
3650# Old names:
3651AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3652AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3653dnl aclocal-1.4 backwards compatibility:
3654dnl AC_DEFUN([AM_PROG_LD], [])
3655dnl AC_DEFUN([AC_PROG_LD], [])
3656
3657
3658# _LT_PATH_LD_GNU
3659#- --------------
3660m4_defun([_LT_PATH_LD_GNU],
3661[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3662[# I'd rather use --version here, but apparently some GNU lds only accept -v.
3663case `$LD -v 2>&1 </dev/null` in
3664*GNU* | *'with BFD'*)
3665 lt_cv_prog_gnu_ld=yes
3666 ;;
3667*)
3668 lt_cv_prog_gnu_ld=no
3669 ;;
3670esac])
3671with_gnu_ld=$lt_cv_prog_gnu_ld
3672])# _LT_PATH_LD_GNU
3673
3674
3675# _LT_CMD_RELOAD
3676# --------------
3677# find reload flag for linker
3678# -- PORTME Some linkers may need a different reload flag.
3679m4_defun([_LT_CMD_RELOAD],
3680[AC_CACHE_CHECK([for $LD option to reload object files],
3681 lt_cv_ld_reload_flag,
3682 [lt_cv_ld_reload_flag='-r'])
3683reload_flag=$lt_cv_ld_reload_flag
3684case $reload_flag in
3685"" | " "*) ;;
3686*) reload_flag=" $reload_flag" ;;
3687esac
3688reload_cmds='$LD$reload_flag -o $output$reload_objs'
3689case $host_os in
3690 darwin*)
3691 if test "$GCC" = yes; then
3692 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3693 else
3694 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3695 fi
3696 ;;
3697esac
3698_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3699_LT_DECL([], [reload_cmds], [2])dnl
3700])# _LT_CMD_RELOAD
3701
3702
3703# _LT_CHECK_MAGIC_METHOD
3704# ----------------------
3705# how to check for library dependencies
3706# -- PORTME fill in with the dynamic library characteristics
3707m4_defun([_LT_CHECK_MAGIC_METHOD],
3708[m4_require([_LT_DECL_EGREP])
3709m4_require([_LT_DECL_OBJDUMP])
3710AC_CACHE_CHECK([how to recognize dependent libraries],
3711lt_cv_deplibs_check_method,
3712[lt_cv_file_magic_cmd='$MAGIC_CMD'
3713lt_cv_file_magic_test_file=
3714lt_cv_deplibs_check_method='unknown'
3715# Need to set the preceding variable on all platforms that support
3716# interlibrary dependencies.
3717# 'none' -- dependencies not supported.
3718# `unknown' -- same as none, but documents that we really don't know.
3719# 'pass_all' -- all dependencies passed with no checks.
3720# 'test_compile' -- check by making test program.
3721# 'file_magic [[regex]]' -- check by looking for files in library path
3722# which responds to the $file_magic_cmd with a given extended regex.
3723# If you have `file' or equivalent on your system and you're not sure
3724# whether `pass_all' will *always* work, you probably want this one.
3725
3726case $host_os in
3727aix[[4-9]]*)
3728 lt_cv_deplibs_check_method=pass_all
3729 ;;
3730
3731beos*)
3732 lt_cv_deplibs_check_method=pass_all
3733 ;;
3734
3735bsdi[[45]]*)
3736 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3737 lt_cv_file_magic_cmd='/usr/bin/file -L'
3738 lt_cv_file_magic_test_file=/shlib/libc.so
3739 ;;
3740
3741cygwin*)
3742 # func_win32_libid is a shell function defined in ltmain.sh
3743 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3744 lt_cv_file_magic_cmd='func_win32_libid'
3745 ;;
3746
3747mingw* | pw32*)
3748 # Base MSYS/MinGW do not provide the 'file' command needed by
3749 # func_win32_libid shell function, so use a weaker test based on 'objdump',
3750 # unless we find 'file', for example because we are cross-compiling.
3751 if ( file / ) >/dev/null 2>&1; then
3752 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3753 lt_cv_file_magic_cmd='func_win32_libid'
3754 else
3755 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3756 lt_cv_file_magic_cmd='$OBJDUMP -f'
3757 fi
3758 ;;
3759
3760cegcc)
3761 # use the weaker test based on 'objdump'. See mingw*.
3762 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3763 lt_cv_file_magic_cmd='$OBJDUMP -f'
3764 ;;
3765
3766darwin* | rhapsody*)
3767 lt_cv_deplibs_check_method=pass_all
3768 ;;
3769
3770freebsd* | dragonfly*)
3771 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3772 case $host_cpu in
3773 i*86 )
3774 # Not sure whether the presence of OpenBSD here was a mistake.
3775 # Let's accept both of them until this is cleared up.
3776 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3777 lt_cv_file_magic_cmd=/usr/bin/file
3778 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3779 ;;
3780 esac
3781 else
3782 lt_cv_deplibs_check_method=pass_all
3783 fi
3784 ;;
3785
3786gnu*)
3787 lt_cv_deplibs_check_method=pass_all
3788 ;;
3789
3790hpux10.20* | hpux11*)
3791 lt_cv_file_magic_cmd=/usr/bin/file
3792 case $host_cpu in
3793 ia64*)
3794 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3795 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3796 ;;
3797 hppa*64*)
3798 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
3799 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3800 ;;
3801 *)
3802 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3803 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3804 ;;
3805 esac
3806 ;;
3807
3808interix[[3-9]]*)
3809 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3810 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3811 ;;
3812
3813irix5* | irix6* | nonstopux*)
3814 case $LD in
3815 *-32|*"-32 ") libmagic=32-bit;;
3816 *-n32|*"-n32 ") libmagic=N32;;
3817 *-64|*"-64 ") libmagic=64-bit;;
3818 *) libmagic=never-match;;
3819 esac
3820 lt_cv_deplibs_check_method=pass_all
3821 ;;
3822
3823# This must be Linux ELF.
3824linux* | k*bsd*-gnu | kopensolaris*-gnu)
3825 lt_cv_deplibs_check_method=pass_all
3826 ;;
3827
3828netbsd* | netbsdelf*-gnu)
3829 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3830 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3831 else
3832 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3833 fi
3834 ;;
3835
3836newos6*)
3837 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3838 lt_cv_file_magic_cmd=/usr/bin/file
3839 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3840 ;;
3841
3842*nto* | *qnx*)
3843 lt_cv_deplibs_check_method=pass_all
3844 ;;
3845
3846openbsd*)
3847 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3848 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3849 else
3850 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3851 fi
3852 ;;
3853
3854osf3* | osf4* | osf5*)
3855 lt_cv_deplibs_check_method=pass_all
3856 ;;
3857
3858rdos*)
3859 lt_cv_deplibs_check_method=pass_all
3860 ;;
3861
3862solaris*)
3863 lt_cv_deplibs_check_method=pass_all
3864 ;;
3865
3866sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3867 lt_cv_deplibs_check_method=pass_all
3868 ;;
3869
3870sysv4 | sysv4.3*)
3871 case $host_vendor in
3872 motorola)
3873 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]]'
3874 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3875 ;;
3876 ncr)
3877 lt_cv_deplibs_check_method=pass_all
3878 ;;
3879 sequent)
3880 lt_cv_file_magic_cmd='/bin/file'
3881 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3882 ;;
3883 sni)
3884 lt_cv_file_magic_cmd='/bin/file'
3885 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3886 lt_cv_file_magic_test_file=/lib/libc.so
3887 ;;
3888 siemens)
3889 lt_cv_deplibs_check_method=pass_all
3890 ;;
3891 pc)
3892 lt_cv_deplibs_check_method=pass_all
3893 ;;
3894 esac
3895 ;;
3896
3897tpf*)
3898 lt_cv_deplibs_check_method=pass_all
3899 ;;
3900esac
3901])
3902file_magic_cmd=$lt_cv_file_magic_cmd
3903deplibs_check_method=$lt_cv_deplibs_check_method
3904test -z "$deplibs_check_method" && deplibs_check_method=unknown
3905
3906_LT_DECL([], [deplibs_check_method], [1],
3907 [Method to check whether dependent libraries are shared objects])
3908_LT_DECL([], [file_magic_cmd], [1],
3909 [Command to use when deplibs_check_method == "file_magic"])
3910])# _LT_CHECK_MAGIC_METHOD
3911
3912
3913# LT_PATH_NM
3914# ----------
3915# find the pathname to a BSD- or MS-compatible name lister
3916AC_DEFUN([LT_PATH_NM],
3917[AC_REQUIRE([AC_PROG_CC])dnl
3918AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
3919[if test -n "$NM"; then
3920 # Let the user override the test.
3921 lt_cv_path_NM="$NM"
3922else
3923 lt_nm_to_check="${ac_tool_prefix}nm"
3924 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3925 lt_nm_to_check="$lt_nm_to_check nm"
3926 fi
3927 for lt_tmp_nm in $lt_nm_to_check; do
3928 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3929 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3930 IFS="$lt_save_ifs"
3931 test -z "$ac_dir" && ac_dir=.
3932 tmp_nm="$ac_dir/$lt_tmp_nm"
3933 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3934 # Check to see if the nm accepts a BSD-compat flag.
3935 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3936 # nm: unknown option "B" ignored
3937 # Tru64's nm complains that /dev/null is an invalid object file
3938 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3939 */dev/null* | *'Invalid file or object type'*)
3940 lt_cv_path_NM="$tmp_nm -B"
3941 break
3942 ;;
3943 *)
3944 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3945 */dev/null*)
3946 lt_cv_path_NM="$tmp_nm -p"
3947 break
3948 ;;
3949 *)
3950 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3951 continue # so that we can try to find one that supports BSD flags
3952 ;;
3953 esac
3954 ;;
3955 esac
3956 fi
3957 done
3958 IFS="$lt_save_ifs"
3959 done
3960 : ${lt_cv_path_NM=no}
3961fi])
3962if test "$lt_cv_path_NM" != "no"; then
3963 NM="$lt_cv_path_NM"
3964else
3965 # Didn't find any BSD compatible name lister, look for dumpbin.
3966 AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
3967 AC_SUBST([DUMPBIN])
3968 if test "$DUMPBIN" != ":"; then
3969 NM="$DUMPBIN"
3970 fi
3971fi
3972test -z "$NM" && NM=nm
3973AC_SUBST([NM])
3974_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
3975
3976AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3977 [lt_cv_nm_interface="BSD nm"
3978 echo "int some_variable = 0;" > conftest.$ac_ext
3979 (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3980 (eval "$ac_compile" 2>conftest.err)
3981 cat conftest.err >&AS_MESSAGE_LOG_FD
3982 (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3983 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3984 cat conftest.err >&AS_MESSAGE_LOG_FD
3985 (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
3986 cat conftest.out >&AS_MESSAGE_LOG_FD
3987 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3988 lt_cv_nm_interface="MS dumpbin"
3989 fi
3990 rm -f conftest*])
3991])# LT_PATH_NM
3992
3993# Old names:
3994AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
3995AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
3996dnl aclocal-1.4 backwards compatibility:
3997dnl AC_DEFUN([AM_PROG_NM], [])
3998dnl AC_DEFUN([AC_PROG_NM], [])
3999
4000
4001# LT_LIB_M
4002# --------
4003# check for math library
4004AC_DEFUN([LT_LIB_M],
4005[AC_REQUIRE([AC_CANONICAL_HOST])dnl
4006LIBM=
4007case $host in
4008*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
4009 # These system don't have libm, or don't need it
4010 ;;
4011*-ncr-sysv4.3*)
4012 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
4013 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
4014 ;;
4015*)
4016 AC_CHECK_LIB(m, cos, LIBM="-lm")
4017 ;;
4018esac
4019AC_SUBST([LIBM])
4020])# LT_LIB_M
4021
4022# Old name:
4023AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
4024dnl aclocal-1.4 backwards compatibility:
4025dnl AC_DEFUN([AC_CHECK_LIBM], [])
4026
4027
4028# _LT_COMPILER_NO_RTTI([TAGNAME])
4029# -------------------------------
4030m4_defun([_LT_COMPILER_NO_RTTI],
4031[m4_require([_LT_TAG_COMPILER])dnl
4032
4033_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4034
4035if test "$GCC" = yes; then
4036 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
4037
4038 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4039 lt_cv_prog_compiler_rtti_exceptions,
4040 [-fno-rtti -fno-exceptions], [],
4041 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4042fi
4043_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
4044 [Compiler flag to turn off builtin functions])
4045])# _LT_COMPILER_NO_RTTI
4046
4047
4048# _LT_CMD_GLOBAL_SYMBOLS
4049# ----------------------
4050m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
4051[AC_REQUIRE([AC_CANONICAL_HOST])dnl
4052AC_REQUIRE([AC_PROG_CC])dnl
4053AC_REQUIRE([LT_PATH_NM])dnl
4054AC_REQUIRE([LT_PATH_LD])dnl
4055m4_require([_LT_DECL_SED])dnl
4056m4_require([_LT_DECL_EGREP])dnl
4057m4_require([_LT_TAG_COMPILER])dnl
4058
4059# Check for command to grab the raw symbol name followed by C symbol from nm.
4060AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4061AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4062[
4063# These are sane defaults that work on at least a few old systems.
4064# [They come from Ultrix. What could be older than Ultrix?!! ;)]
4065
4066# Character class describing NM global symbol codes.
4067symcode='[[BCDEGRST]]'
4068
4069# Regexp to match symbols that can be accessed directly from C.
4070sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4071
4072# Define system-specific variables.
4073case $host_os in
4074aix*)
4075 symcode='[[BCDT]]'
4076 ;;
4077cygwin* | mingw* | pw32* | cegcc*)
4078 symcode='[[ABCDGISTW]]'
4079 ;;
4080hpux*)
4081 if test "$host_cpu" = ia64; then
4082 symcode='[[ABCDEGRST]]'
4083 fi
4084 ;;
4085irix* | nonstopux*)
4086 symcode='[[BCDEGRST]]'
4087 ;;
4088osf*)
4089 symcode='[[BCDEGQRST]]'
4090 ;;
4091solaris*)
4092 symcode='[[BDRT]]'
4093 ;;
4094sco3.2v5*)
4095 symcode='[[DT]]'
4096 ;;
4097sysv4.2uw2*)
4098 symcode='[[DT]]'
4099 ;;
4100sysv5* | sco5v6* | unixware* | OpenUNIX*)
4101 symcode='[[ABDT]]'
4102 ;;
4103sysv4)
4104 symcode='[[DFNSTU]]'
4105 ;;
4106esac
4107
4108# If we're using GNU nm, then use its standard symbol codes.
4109case `$NM -V 2>&1` in
4110*GNU* | *'with BFD'*)
4111 symcode='[[ABCDGIRSTW]]' ;;
4112esac
4113
4114# Transform an extracted symbol line into a proper C declaration.
4115# Some systems (esp. on ia64) link data and code symbols differently,
4116# so use this general approach.
4117lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4118
4119# Transform an extracted symbol line into symbol name and symbol address
4120lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
4121lt_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'"
4122
4123# Handle CRLF in mingw tool chain
4124opt_cr=
4125case $build_os in
4126mingw*)
4127 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4128 ;;
4129esac
4130
4131# Try without a prefix underscore, then with it.
4132for ac_symprfx in "" "_"; do
4133
4134 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4135 symxfrm="\\1 $ac_symprfx\\2 \\2"
4136
4137 # Write the raw and C identifiers.
4138 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4139 # Fake it for dumpbin and say T for any non-static function
4140 # and D for any global variable.
4141 # Also find C++ and __fastcall symbols from MSVC++,
4142 # which start with @ or ?.
4143 lt_cv_sys_global_symbol_pipe="$AWK ['"\
4144" {last_section=section; section=\$ 3};"\
4145" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
4146" \$ 0!~/External *\|/{next};"\
4147" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
4148" {if(hide[section]) next};"\
4149" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
4150" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
4151" s[1]~/^[@?]/{print s[1], s[1]; next};"\
4152" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
4153" ' prfx=^$ac_symprfx]"
4154 else
4155 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4156 fi
4157
4158 # Check to see that the pipe works correctly.
4159 pipe_works=no
4160
4161 rm -f conftest*
4162 cat > conftest.$ac_ext <<_LT_EOF
4163#ifdef __cplusplus
4164extern "C" {
4165#endif
4166char nm_test_var;
4167void nm_test_func(void);
4168void nm_test_func(void){}
4169#ifdef __cplusplus
4170}
4171#endif
4172int main(){nm_test_var='a';nm_test_func();return(0);}
4173_LT_EOF
4174
4175 if AC_TRY_EVAL(ac_compile); then
4176 # Now try to grab the symbols.
4177 nlist=conftest.nm
4178 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
4179 # Try sorting and uniquifying the output.
4180 if sort "$nlist" | uniq > "$nlist"T; then
4181 mv -f "$nlist"T "$nlist"
4182 else
4183 rm -f "$nlist"T
4184 fi
4185
4186 # Make sure that we snagged all the symbols we need.
4187 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
4188 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
4189 cat <<_LT_EOF > conftest.$ac_ext
4190#ifdef __cplusplus
4191extern "C" {
4192#endif
4193
4194_LT_EOF
4195 # Now generate the symbol file.
4196 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
4197
4198 cat <<_LT_EOF >> conftest.$ac_ext
4199
4200/* The mapping between symbol names and symbols. */
4201const struct {
4202 const char *name;
4203 void *address;
4204}
4205lt__PROGRAM__LTX_preloaded_symbols[[]] =
4206{
4207 { "@PROGRAM@", (void *) 0 },
4208_LT_EOF
4209 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4210 cat <<\_LT_EOF >> conftest.$ac_ext
4211 {0, (void *) 0}
4212};
4213
4214/* This works around a problem in FreeBSD linker */
4215#ifdef FREEBSD_WORKAROUND
4216static const void *lt_preloaded_setup() {
4217 return lt__PROGRAM__LTX_preloaded_symbols;
4218}
4219#endif
4220
4221#ifdef __cplusplus
4222}
4223#endif
4224_LT_EOF
4225 # Now try linking the two files.
4226 mv conftest.$ac_objext conftstm.$ac_objext
4227 lt_save_LIBS="$LIBS"
4228 lt_save_CFLAGS="$CFLAGS"
4229 LIBS="conftstm.$ac_objext"
4230 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4231 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4232 pipe_works=yes
4233 fi
4234 LIBS="$lt_save_LIBS"
4235 CFLAGS="$lt_save_CFLAGS"
4236 else
4237 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4238 fi
4239 else
4240 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4241 fi
4242 else
4243 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4244 fi
4245 else
4246 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4247 cat conftest.$ac_ext >&5
4248 fi
4249 rm -rf conftest* conftst*
4250
4251 # Do not use the global_symbol_pipe unless it works.
4252 if test "$pipe_works" = yes; then
4253 break
4254 else
4255 lt_cv_sys_global_symbol_pipe=
4256 fi
4257done
4258])
4259if test -z "$lt_cv_sys_global_symbol_pipe"; then
4260 lt_cv_sys_global_symbol_to_cdecl=
4261fi
4262if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4263 AC_MSG_RESULT(failed)
4264else
4265 AC_MSG_RESULT(ok)
4266fi
4267
4268_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
4269 [Take the output of nm and produce a listing of raw symbols and C names])
4270_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
4271 [Transform the output of nm in a proper C declaration])
4272_LT_DECL([global_symbol_to_c_name_address],
4273 [lt_cv_sys_global_symbol_to_c_name_address], [1],
4274 [Transform the output of nm in a C name address pair])
4275_LT_DECL([global_symbol_to_c_name_address_lib_prefix],
4276 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
4277 [Transform the output of nm in a C name address pair when lib prefix is needed])
4278]) # _LT_CMD_GLOBAL_SYMBOLS
4279
4280
4281# _LT_COMPILER_PIC([TAGNAME])
4282# ---------------------------
4283m4_defun([_LT_COMPILER_PIC],
4284[m4_require([_LT_TAG_COMPILER])dnl
4285_LT_TAGVAR(lt_prog_compiler_wl, $1)=
4286_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4287_LT_TAGVAR(lt_prog_compiler_static, $1)=
4288
4289AC_MSG_CHECKING([for $compiler option to produce PIC])
4290m4_if([$1], [CXX], [
4291 # C++ specific cases for pic, static, wl, etc.
4292 if test "$GXX" = yes; then
4293 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4294 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4295
4296 case $host_os in
4297 aix*)
4298 # All AIX code is PIC.
4299 if test "$host_cpu" = ia64; then
4300 # AIX 5 now supports IA64 processor
4301 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4302 fi
4303 ;;
4304
4305 amigaos*)
4306 case $host_cpu in
4307 powerpc)
4308 # see comment about AmigaOS4 .so support
4309 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4310 ;;
4311 m68k)
4312 # FIXME: we need at least 68020 code to build shared libraries, but
4313 # adding the `-m68020' flag to GCC prevents building anything better,
4314 # like `-m68040'.
4315 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4316 ;;
4317 esac
4318 ;;
4319
4320 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4321 # PIC is the default for these OSes.
4322 ;;
4323 mingw* | cygwin* | os2* | pw32* | cegcc*)
4324 # This hack is so that the source file can tell whether it is being
4325 # built for inclusion in a dll (and should export symbols for example).
4326 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4327 # (--disable-auto-import) libraries
4328 m4_if([$1], [GCJ], [],
4329 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4330 ;;
4331 darwin* | rhapsody*)
4332 # PIC is the default on this platform
4333 # Common symbols not allowed in MH_DYLIB files
4334 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4335 ;;
4336 *djgpp*)
4337 # DJGPP does not support shared libraries at all
4338 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4339 ;;
4340 interix[[3-9]]*)
4341 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4342 # Instead, we relocate shared libraries at runtime.
4343 ;;
4344 sysv4*MP*)
4345 if test -d /usr/nec; then
4346 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4347 fi
4348 ;;
4349 hpux*)
4350 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4351 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4352 # sets the default TLS model and affects inlining.
4353 case $host_cpu in
4354 hppa*64*)
4355 ;;
4356 *)
4357 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4358 ;;
4359 esac
4360 ;;
4361 *qnx* | *nto*)
4362 # QNX uses GNU C++, but need to define -shared option too, otherwise
4363 # it will coredump.
4364 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4365 ;;
4366 *)
4367 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4368 ;;
4369 esac
4370 else
4371 case $host_os in
4372 aix[[4-9]]*)
4373 # All AIX code is PIC.
4374 if test "$host_cpu" = ia64; then
4375 # AIX 5 now supports IA64 processor
4376 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4377 else
4378 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4379 fi
4380 ;;
4381 chorus*)
4382 case $cc_basename in
4383 cxch68*)
4384 # Green Hills C++ Compiler
4385 # _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"
4386 ;;
4387 esac
4388 ;;
4389 dgux*)
4390 case $cc_basename in
4391 ec++*)
4392 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4393 ;;
4394 ghcx*)
4395 # Green Hills C++ Compiler
4396 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4397 ;;
4398 *)
4399 ;;
4400 esac
4401 ;;
4402 freebsd* | dragonfly*)
4403 # FreeBSD uses GNU C++
4404 ;;
4405 hpux9* | hpux10* | hpux11*)
4406 case $cc_basename in
4407 CC*)
4408 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4409 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4410 if test "$host_cpu" != ia64; then
4411 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4412 fi
4413 ;;
4414 aCC*)
4415 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4416 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4417 case $host_cpu in
4418 hppa*64*|ia64*)
4419 # +Z the default
4420 ;;
4421 *)
4422 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4423 ;;
4424 esac
4425 ;;
4426 *)
4427 ;;
4428 esac
4429 ;;
4430 interix*)
4431 # This is c89, which is MS Visual C++ (no shared libs)
4432 # Anyone wants to do a port?
4433 ;;
4434 irix5* | irix6* | nonstopux*)
4435 case $cc_basename in
4436 CC*)
4437 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4438 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4439 # CC pic flag -KPIC is the default.
4440 ;;
4441 *)
4442 ;;
4443 esac
4444 ;;
4445 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4446 case $cc_basename in
4447 KCC*)
4448 # KAI C++ Compiler
4449 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4450 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4451 ;;
4452 ecpc* )
4453 # old Intel C++ for x86_64 which still supported -KPIC.
4454 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4455 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4456 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4457 ;;
4458 icpc* )
4459 # Intel C++, used to be incompatible with GCC.
4460 # ICC 10 doesn't accept -KPIC any more.
4461 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4462 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4463 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4464 ;;
4465 pgCC* | pgcpp*)
4466 # Portland Group C++ compiler
4467 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4468 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4469 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4470 ;;
4471 cxx*)
4472 # Compaq C++
4473 # Make sure the PIC flag is empty. It appears that all Alpha
4474 # Linux and Compaq Tru64 Unix objects are PIC.
4475 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4476 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4477 ;;
4478 xlc* | xlC*)
4479 # IBM XL 8.0 on PPC
4480 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4481 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4482 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4483 ;;
4484 *)
4485 case `$CC -V 2>&1 | sed 5q` in
4486 *Sun\ C*)
4487 # Sun C++ 5.9
4488 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4489 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4490 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4491 ;;
4492 esac
4493 ;;
4494 esac
4495 ;;
4496 lynxos*)
4497 ;;
4498 m88k*)
4499 ;;
4500 mvs*)
4501 case $cc_basename in
4502 cxx*)
4503 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4504 ;;
4505 *)
4506 ;;
4507 esac
4508 ;;
4509 netbsd* | netbsdelf*-gnu)
4510 ;;
4511 *qnx* | *nto*)
4512 # QNX uses GNU C++, but need to define -shared option too, otherwise
4513 # it will coredump.
4514 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4515 ;;
4516 osf3* | osf4* | osf5*)
4517 case $cc_basename in
4518 KCC*)
4519 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4520 ;;
4521 RCC*)
4522 # Rational C++ 2.4.1
4523 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4524 ;;
4525 cxx*)
4526 # Digital/Compaq C++
4527 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4528 # Make sure the PIC flag is empty. It appears that all Alpha
4529 # Linux and Compaq Tru64 Unix objects are PIC.
4530 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4531 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4532 ;;
4533 *)
4534 ;;
4535 esac
4536 ;;
4537 psos*)
4538 ;;
4539 solaris*)
4540 case $cc_basename in
4541 CC*)
4542 # Sun C++ 4.2, 5.x and Centerline C++
4543 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4544 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4545 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4546 ;;
4547 gcx*)
4548 # Green Hills C++ Compiler
4549 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4550 ;;
4551 *)
4552 ;;
4553 esac
4554 ;;
4555 sunos4*)
4556 case $cc_basename in
4557 CC*)
4558 # Sun C++ 4.x
4559 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4560 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4561 ;;
4562 lcc*)
4563 # Lucid
4564 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4565 ;;
4566 *)
4567 ;;
4568 esac
4569 ;;
4570 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4571 case $cc_basename in
4572 CC*)
4573 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4574 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4575 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4576 ;;
4577 esac
4578 ;;
4579 tandem*)
4580 case $cc_basename in
4581 NCC*)
4582 # NonStop-UX NCC 3.20
4583 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4584 ;;
4585 *)
4586 ;;
4587 esac
4588 ;;
4589 vxworks*)
4590 ;;
4591 *)
4592 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4593 ;;
4594 esac
4595 fi
4596],
4597[
4598 if test "$GCC" = yes; then
4599 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4600 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4601
4602 case $host_os in
4603 aix*)
4604 # All AIX code is PIC.
4605 if test "$host_cpu" = ia64; then
4606 # AIX 5 now supports IA64 processor
4607 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4608 fi
4609 ;;
4610
4611 amigaos*)
4612 case $host_cpu in
4613 powerpc)
4614 # see comment about AmigaOS4 .so support
4615 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4616 ;;
4617 m68k)
4618 # FIXME: we need at least 68020 code to build shared libraries, but
4619 # adding the `-m68020' flag to GCC prevents building anything better,
4620 # like `-m68040'.
4621 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4622 ;;
4623 esac
4624 ;;
4625
4626 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4627 # PIC is the default for these OSes.
4628 ;;
4629
4630 mingw* | cygwin* | pw32* | os2* | cegcc*)
4631 # This hack is so that the source file can tell whether it is being
4632 # built for inclusion in a dll (and should export symbols for example).
4633 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4634 # (--disable-auto-import) libraries
4635 m4_if([$1], [GCJ], [],
4636 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4637 ;;
4638
4639 darwin* | rhapsody*)
4640 # PIC is the default on this platform
4641 # Common symbols not allowed in MH_DYLIB files
4642 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4643 ;;
4644
4645 hpux*)
4646 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4647 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4648 # sets the default TLS model and affects inlining.
4649 case $host_cpu in
4650 hppa*64*)
4651 # +Z the default
4652 ;;
4653 *)
4654 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4655 ;;
4656 esac
4657 ;;
4658
4659 interix[[3-9]]*)
4660 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4661 # Instead, we relocate shared libraries at runtime.
4662 ;;
4663
4664 msdosdjgpp*)
4665 # Just because we use GCC doesn't mean we suddenly get shared libraries
4666 # on systems that don't support them.
4667 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4668 enable_shared=no
4669 ;;
4670
4671 *nto* | *qnx*)
4672 # QNX uses GNU C++, but need to define -shared option too, otherwise
4673 # it will coredump.
4674 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4675 ;;
4676
4677 sysv4*MP*)
4678 if test -d /usr/nec; then
4679 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4680 fi
4681 ;;
4682
4683 *)
4684 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4685 ;;
4686 esac
4687 else
4688 # PORTME Check for flag to pass linker flags through the system compiler.
4689 case $host_os in
4690 aix*)
4691 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4692 if test "$host_cpu" = ia64; then
4693 # AIX 5 now supports IA64 processor
4694 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4695 else
4696 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4697 fi
4698 ;;
4699
4700 mingw* | cygwin* | pw32* | os2* | cegcc*)
4701 # This hack is so that the source file can tell whether it is being
4702 # built for inclusion in a dll (and should export symbols for example).
4703 m4_if([$1], [GCJ], [],
4704 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4705 ;;
4706
4707 hpux9* | hpux10* | hpux11*)
4708 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4709 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4710 # not for PA HP-UX.
4711 case $host_cpu in
4712 hppa*64*|ia64*)
4713 # +Z the default
4714 ;;
4715 *)
4716 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4717 ;;
4718 esac
4719 # Is there a better lt_prog_compiler_static that works with the bundled CC?
4720 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4721 ;;
4722
4723 irix5* | irix6* | nonstopux*)
4724 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4725 # PIC (with -KPIC) is the default.
4726 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4727 ;;
4728
4729 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4730 case $cc_basename in
4731 # old Intel for x86_64 which still supported -KPIC.
4732 ecc*)
4733 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4734 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4735 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4736 ;;
4737 # icc used to be incompatible with GCC.
4738 # ICC 10 doesn't accept -KPIC any more.
4739 icc* | ifort*)
4740 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4741 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4742 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4743 ;;
4744 # Lahey Fortran 8.1.
4745 lf95*)
4746 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4747 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
4748 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
4749 ;;
4750 pgcc* | pgf77* | pgf90* | pgf95*)
4751 # Portland Group compilers (*not* the Pentium gcc compiler,
4752 # which looks to be a dead project)
4753 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4754 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4755 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4756 ;;
4757 ccc*)
4758 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4759 # All Alpha code is PIC.
4760 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4761 ;;
4762 xl*)
4763 # IBM XL C 8.0/Fortran 10.1 on PPC
4764 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4765 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4766 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4767 ;;
4768 *)
4769 case `$CC -V 2>&1 | sed 5q` in
4770 *Sun\ C*)
4771 # Sun C 5.9
4772 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4773 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4774 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4775 ;;
4776 *Sun\ F*)
4777 # Sun Fortran 8.3 passes all unrecognized flags to the linker
4778 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4779 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4780 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4781 ;;
4782 esac
4783 ;;
4784 esac
4785 ;;
4786
4787 newsos6)
4788 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4789 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4790 ;;
4791
4792 *nto* | *qnx*)
4793 # QNX uses GNU C++, but need to define -shared option too, otherwise
4794 # it will coredump.
4795 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4796 ;;
4797
4798 osf3* | osf4* | osf5*)
4799 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4800 # All OSF/1 code is PIC.
4801 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4802 ;;
4803
4804 rdos*)
4805 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4806 ;;
4807
4808 solaris*)
4809 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4810 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4811 case $cc_basename in
4812 f77* | f90* | f95*)
4813 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4814 *)
4815 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4816 esac
4817 ;;
4818
4819 sunos4*)
4820 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4821 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4822 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4823 ;;
4824
4825 sysv4 | sysv4.2uw2* | sysv4.3*)
4826 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4827 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4828 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4829 ;;
4830
4831 sysv4*MP*)
4832 if test -d /usr/nec ;then
4833 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
4834 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4835 fi
4836 ;;
4837
4838 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4839 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4840 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4841 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4842 ;;
4843
4844 unicos*)
4845 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4846 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4847 ;;
4848
4849 uts4*)
4850 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4851 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4852 ;;
4853
4854 *)
4855 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4856 ;;
4857 esac
4858 fi
4859])
4860case $host_os in
4861 # For platforms which do not support PIC, -DPIC is meaningless:
4862 *djgpp*)
4863 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4864 ;;
4865 *)
4866 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4867 ;;
4868esac
4869AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4870_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4871 [How to pass a linker flag through the compiler])
4872
4873#
4874# Check to make sure the PIC flag actually works.
4875#
4876if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4877 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
4878 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
4879 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
4880 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
4881 "" | " "*) ;;
4882 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
4883 esac],
4884 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4885 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
4886fi
4887_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4888 [Additional compiler flags for building library objects])
4889
4890#
4891# Check to make sure the static flag actually works.
4892#
4893wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
4894_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
4895 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
4896 $lt_tmp_static_flag,
4897 [],
4898 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
4899_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
4900 [Compiler flag to prevent dynamic linking])
4901])# _LT_COMPILER_PIC
4902
4903
4904# _LT_LINKER_SHLIBS([TAGNAME])
4905# ----------------------------
4906# See if the linker supports building shared libraries.
4907m4_defun([_LT_LINKER_SHLIBS],
4908[AC_REQUIRE([LT_PATH_LD])dnl
4909AC_REQUIRE([LT_PATH_NM])dnl
4910m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4911m4_require([_LT_DECL_EGREP])dnl
4912m4_require([_LT_DECL_SED])dnl
4913m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
4914m4_require([_LT_TAG_COMPILER])dnl
4915AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4916m4_if([$1], [CXX], [
4917 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4918 case $host_os in
4919 aix[[4-9]]*)
4920 # If we're using GNU nm, then we don't want the "-C" option.
4921 # -C means demangle to AIX nm, but means don't demangle with GNU nm
4922 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4923 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4924 else
4925 _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'
4926 fi
4927 ;;
4928 pw32*)
4929 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4930 ;;
4931 cygwin* | mingw* | cegcc*)
4932 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4933 ;;
4934 linux* | k*bsd*-gnu)
4935 _LT_TAGVAR(link_all_deplibs, $1)=no
4936 ;;
4937 *)
4938 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4939 ;;
4940 esac
4941 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4942], [
4943 runpath_var=
4944 _LT_TAGVAR(allow_undefined_flag, $1)=
4945 _LT_TAGVAR(always_export_symbols, $1)=no
4946 _LT_TAGVAR(archive_cmds, $1)=
4947 _LT_TAGVAR(archive_expsym_cmds, $1)=
4948 _LT_TAGVAR(compiler_needs_object, $1)=no
4949 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4950 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
4951 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4952 _LT_TAGVAR(hardcode_automatic, $1)=no
4953 _LT_TAGVAR(hardcode_direct, $1)=no
4954 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
4955 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4956 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4957 _LT_TAGVAR(hardcode_libdir_separator, $1)=
4958 _LT_TAGVAR(hardcode_minus_L, $1)=no
4959 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4960 _LT_TAGVAR(inherit_rpath, $1)=no
4961 _LT_TAGVAR(link_all_deplibs, $1)=unknown
4962 _LT_TAGVAR(module_cmds, $1)=
4963 _LT_TAGVAR(module_expsym_cmds, $1)=
4964 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
4965 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
4966 _LT_TAGVAR(thread_safe_flag_spec, $1)=
4967 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4968 # include_expsyms should be a list of space-separated symbols to be *always*
4969 # included in the symbol list
4970 _LT_TAGVAR(include_expsyms, $1)=
4971 # exclude_expsyms can be an extended regexp of symbols to exclude
4972 # it will be wrapped by ` (' and `)$', so one must not match beginning or
4973 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4974 # as well as any symbol that contains `d'.
4975 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4976 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4977 # platforms (ab)use it in PIC code, but their linkers get confused if
4978 # the symbol is explicitly referenced. Since portable code cannot
4979 # rely on this symbol name, it's probably fine to never include it in
4980 # preloaded symbol tables.
4981 # Exclude shared library initialization/finalization symbols.
4982dnl Note also adjust exclude_expsyms for C++ above.
4983 extract_expsyms_cmds=
4984
4985 case $host_os in
4986 cygwin* | mingw* | pw32* | cegcc*)
4987 # FIXME: the MSVC++ port hasn't been tested in a loooong time
4988 # When not using gcc, we currently assume that we are using
4989 # Microsoft Visual C++.
4990 if test "$GCC" != yes; then
4991 with_gnu_ld=no
4992 fi
4993 ;;
4994 interix*)
4995 # we just hope/assume this is gcc and not c89 (= MSVC++)
4996 with_gnu_ld=yes
4997 ;;
4998 openbsd*)
4999 with_gnu_ld=no
5000 ;;
5001 linux* | k*bsd*-gnu)
5002 _LT_TAGVAR(link_all_deplibs, $1)=no
5003 ;;
5004 esac
5005
5006 _LT_TAGVAR(ld_shlibs, $1)=yes
5007 if test "$with_gnu_ld" = yes; then
5008 # If archive_cmds runs LD, not CC, wlarc should be empty
5009 wlarc='${wl}'
5010
5011 # Set some defaults for GNU ld with shared library support. These
5012 # are reset later if shared libraries are not supported. Putting them
5013 # here allows them to be overridden if necessary.
5014 runpath_var=LD_RUN_PATH
5015 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5016 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5017 # ancient GNU ld didn't support --whole-archive et. al.
5018 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
5019 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5020 else
5021 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5022 fi
5023 supports_anon_versioning=no
5024 case `$LD -v 2>&1` in
5025 *GNU\ gold*) supports_anon_versioning=yes ;;
5026 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5027 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5028 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5029 *\ 2.11.*) ;; # other 2.11 versions
5030 *) supports_anon_versioning=yes ;;
5031 esac
5032
5033 # See if GNU ld supports shared libraries.
5034 case $host_os in
5035 aix[[3-9]]*)
5036 # On AIX/PPC, the GNU linker is very broken
5037 if test "$host_cpu" != ia64; then
5038 _LT_TAGVAR(ld_shlibs, $1)=no
5039 cat <<_LT_EOF 1>&2
5040
5041*** Warning: the GNU linker, at least up to release 2.9.1, is reported
5042*** to be unable to reliably create shared libraries on AIX.
5043*** Therefore, libtool is disabling shared libraries support. If you
5044*** really care for shared libraries, you may want to modify your PATH
5045*** so that a non-GNU linker is found, and then restart.
5046
5047_LT_EOF
5048 fi
5049 ;;
5050
5051 amigaos*)
5052 case $host_cpu in
5053 powerpc)
5054 # see comment about AmigaOS4 .so support
5055 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5056 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5057 ;;
5058 m68k)
5059 _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)'
5060 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5061 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5062 ;;
5063 esac
5064 ;;
5065
5066 beos*)
5067 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5068 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5069 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5070 # support --undefined. This deserves some investigation. FIXME
5071 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5072 else
5073 _LT_TAGVAR(ld_shlibs, $1)=no
5074 fi
5075 ;;
5076
5077 cygwin* | mingw* | pw32* | cegcc*)
5078 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5079 # as there is no search path for DLLs.
5080 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5081 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5082 _LT_TAGVAR(always_export_symbols, $1)=no
5083 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5084 _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'
5085
5086 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5087 _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'
5088 # If the export-symbols file already is a .def file (1st line
5089 # is EXPORTS), use it as is; otherwise, prepend...
5090 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5091 cp $export_symbols $output_objdir/$soname.def;
5092 else
5093 echo EXPORTS > $output_objdir/$soname.def;
5094 cat $export_symbols >> $output_objdir/$soname.def;
5095 fi~
5096 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5097 else
5098 _LT_TAGVAR(ld_shlibs, $1)=no
5099 fi
5100 ;;
5101
5102 interix[[3-9]]*)
5103 _LT_TAGVAR(hardcode_direct, $1)=no
5104 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5105 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5106 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5107 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5108 # Instead, shared libraries are loaded at an image base (0x10000000 by
5109 # default) and relocated if they conflict, which is a slow very memory
5110 # consuming and fragmenting process. To avoid this, we pick a random,
5111 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
5112 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
5113 _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'
5114 _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'
5115 ;;
5116
5117 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
5118 tmp_diet=no
5119 if test "$host_os" = linux-dietlibc; then
5120 case $cc_basename in
5121 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
5122 esac
5123 fi
5124 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
5125 && test "$tmp_diet" = no
5126 then
5127 tmp_addflag=
5128 tmp_sharedflag='-shared'
5129 case $cc_basename,$host_cpu in
5130 pgcc*) # Portland Group C compiler
5131 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
5132 tmp_addflag=' $pic_flag'
5133 ;;
5134 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
5135 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
5136 tmp_addflag=' $pic_flag -Mnomain' ;;
5137 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5138 tmp_addflag=' -i_dynamic' ;;
5139 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5140 tmp_addflag=' -i_dynamic -nofor_main' ;;
5141 ifc* | ifort*) # Intel Fortran compiler
5142 tmp_addflag=' -nofor_main' ;;
5143 lf95*) # Lahey Fortran 8.1
5144 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5145 tmp_sharedflag='--shared' ;;
5146 xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
5147 tmp_sharedflag='-qmkshrobj'
5148 tmp_addflag= ;;
5149 esac
5150 case `$CC -V 2>&1 | sed 5q` in
5151 *Sun\ C*) # Sun C 5.9
5152 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
5153 _LT_TAGVAR(compiler_needs_object, $1)=yes
5154 tmp_sharedflag='-G' ;;
5155 *Sun\ F*) # Sun Fortran 8.3
5156 tmp_sharedflag='-G' ;;
5157 esac
5158 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5159
5160 if test "x$supports_anon_versioning" = xyes; then
5161 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5162 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5163 echo "local: *; };" >> $output_objdir/$libname.ver~
5164 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5165 fi
5166
5167 case $cc_basename in
5168 xlf*)
5169 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
5170 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
5171 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5172 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
5173 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
5174 if test "x$supports_anon_versioning" = xyes; then
5175 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5176 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5177 echo "local: *; };" >> $output_objdir/$libname.ver~
5178 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5179 fi
5180 ;;
5181 esac
5182 else
5183 _LT_TAGVAR(ld_shlibs, $1)=no
5184 fi
5185 ;;
5186
5187 netbsd* | netbsdelf*-gnu)
5188 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5189 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5190 wlarc=
5191 else
5192 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5193 _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'
5194 fi
5195 ;;
5196
5197 solaris*)
5198 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
5199 _LT_TAGVAR(ld_shlibs, $1)=no
5200 cat <<_LT_EOF 1>&2
5201
5202*** Warning: The releases 2.8.* of the GNU linker cannot reliably
5203*** create shared libraries on Solaris systems. Therefore, libtool
5204*** is disabling shared libraries support. We urge you to upgrade GNU
5205*** binutils to release 2.9.1 or newer. Another option is to modify
5206*** your PATH or compiler configuration so that the native linker is
5207*** used, and then restart.
5208
5209_LT_EOF
5210 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5211 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5212 _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'
5213 else
5214 _LT_TAGVAR(ld_shlibs, $1)=no
5215 fi
5216 ;;
5217
5218 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5219 case `$LD -v 2>&1` in
5220 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5221 _LT_TAGVAR(ld_shlibs, $1)=no
5222 cat <<_LT_EOF 1>&2
5223
5224*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
5225*** reliably create shared libraries on SCO systems. Therefore, libtool
5226*** is disabling shared libraries support. We urge you to upgrade GNU
5227*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5228*** your PATH or compiler configuration so that the native linker is
5229*** used, and then restart.
5230
5231_LT_EOF
5232 ;;
5233 *)
5234 # For security reasons, it is highly recommended that you always
5235 # use absolute paths for naming shared libraries, and exclude the
5236 # DT_RUNPATH tag from executables and libraries. But doing so
5237 # requires that you compile everything twice, which is a pain.
5238 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5239 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5240 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5241 _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'
5242 else
5243 _LT_TAGVAR(ld_shlibs, $1)=no
5244 fi
5245 ;;
5246 esac
5247 ;;
5248
5249 sunos4*)
5250 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5251 wlarc=
5252 _LT_TAGVAR(hardcode_direct, $1)=yes
5253 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5254 ;;
5255
5256 *)
5257 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5258 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5259 _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'
5260 else
5261 _LT_TAGVAR(ld_shlibs, $1)=no
5262 fi
5263 ;;
5264 esac
5265
5266 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
5267 runpath_var=
5268 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5269 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5270 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5271 fi
5272 else
5273 # PORTME fill in a description of your system's linker (not GNU ld)
5274 case $host_os in
5275 aix3*)
5276 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5277 _LT_TAGVAR(always_export_symbols, $1)=yes
5278 _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'
5279 # Note: this linker hardcodes the directories in LIBPATH if there
5280 # are no directories specified by -L.
5281 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5282 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5283 # Neither direct hardcoding nor static linking is supported with a
5284 # broken collect2.
5285 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5286 fi
5287 ;;
5288
5289 aix[[4-9]]*)
5290 if test "$host_cpu" = ia64; then
5291 # On IA64, the linker does run time linking by default, so we don't
5292 # have to do anything special.
5293 aix_use_runtimelinking=no
5294 exp_sym_flag='-Bexport'
5295 no_entry_flag=""
5296 else
5297 # If we're using GNU nm, then we don't want the "-C" option.
5298 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5299 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5300 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5301 else
5302 _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'
5303 fi
5304 aix_use_runtimelinking=no
5305
5306 # Test if we are trying to use run time linking or normal
5307 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5308 # need to do runtime linking.
5309 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5310 for ld_flag in $LDFLAGS; do
5311 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5312 aix_use_runtimelinking=yes
5313 break
5314 fi
5315 done
5316 ;;
5317 esac
5318
5319 exp_sym_flag='-bexport'
5320 no_entry_flag='-bnoentry'
5321 fi
5322
5323 # When large executables or shared objects are built, AIX ld can
5324 # have problems creating the table of contents. If linking a library
5325 # or program results in "error TOC overflow" add -mminimal-toc to
5326 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5327 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5328
5329 _LT_TAGVAR(archive_cmds, $1)=''
5330 _LT_TAGVAR(hardcode_direct, $1)=yes
5331 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5332 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5333 _LT_TAGVAR(link_all_deplibs, $1)=yes
5334 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5335
5336 if test "$GCC" = yes; then
5337 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5338 # We only want to do this on AIX 4.2 and lower, the check
5339 # below for broken collect2 doesn't work under 4.3+
5340 collect2name=`${CC} -print-prog-name=collect2`
5341 if test -f "$collect2name" &&
5342 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5343 then
5344 # We have reworked collect2
5345 :
5346 else
5347 # We have old collect2
5348 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5349 # It fails to find uninstalled libraries when the uninstalled
5350 # path is not listed in the libpath. Setting hardcode_minus_L
5351 # to unsupported forces relinking
5352 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5353 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5354 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5355 fi
5356 ;;
5357 esac
5358 shared_flag='-shared'
5359 if test "$aix_use_runtimelinking" = yes; then
5360 shared_flag="$shared_flag "'${wl}-G'
5361 fi
5362 _LT_TAGVAR(link_all_deplibs, $1)=no
5363 else
5364 # not using gcc
5365 if test "$host_cpu" = ia64; then
5366 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5367 # chokes on -Wl,-G. The following line is correct:
5368 shared_flag='-G'
5369 else
5370 if test "$aix_use_runtimelinking" = yes; then
5371 shared_flag='${wl}-G'
5372 else
5373 shared_flag='${wl}-bM:SRE'
5374 fi
5375 fi
5376 fi
5377
5378 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
5379 # It seems that -bexpall does not export symbols beginning with
5380 # underscore (_), so it is better to generate a list of symbols to export.
5381 _LT_TAGVAR(always_export_symbols, $1)=yes
5382 if test "$aix_use_runtimelinking" = yes; then
5383 # Warning - without using the other runtime loading flags (-brtl),
5384 # -berok will link without error, but may produce a broken library.
5385 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5386 # Determine the default libpath from the value encoded in an
5387 # empty executable.
5388 _LT_SYS_MODULE_PATH_AIX
5389 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5390 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5391 else
5392 if test "$host_cpu" = ia64; then
5393 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5394 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5395 _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"
5396 else
5397 # Determine the default libpath from the value encoded in an
5398 # empty executable.
5399 _LT_SYS_MODULE_PATH_AIX
5400 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5401 # Warning - without using the other run time loading flags,
5402 # -berok will link without error, but may produce a broken library.
5403 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5404 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5405 # Exported symbols can be pulled into shared objects from archives
5406 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5407 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5408 # This is similar to how AIX traditionally builds its shared libraries.
5409 _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'
5410 fi
5411 fi
5412 ;;
5413
5414 amigaos*)
5415 case $host_cpu in
5416 powerpc)
5417 # see comment about AmigaOS4 .so support
5418 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5419 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5420 ;;
5421 m68k)
5422 _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)'
5423 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5424 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5425 ;;
5426 esac
5427 ;;
5428
5429 bsdi[[45]]*)
5430 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
The diff has been truncated for viewing.

Subscribers

People subscribed via source and target branches

to all changes: