500
dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
501
# serial 40 IT_PROG_INTLTOOL
502
AC_DEFUN([IT_PROG_INTLTOOL], [
504
AC_REQUIRE([AM_NLS])dnl
506
case "$am__api_version" in
508
AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
514
if test -n "$1"; then
515
AC_MSG_CHECKING([for intltool >= $1])
517
INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
518
INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
519
[INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
521
AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
522
test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
523
AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.])
526
AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
527
AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
528
AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
529
if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
530
AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
533
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 $< [$]@'
534
INTLTOOL_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 $< [$]@'
535
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 $< [$]@'
536
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 $< [$]@'
537
INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -p $(top_srcdir)/po $< [$]@'
538
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 $< [$]@'
539
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 $< [$]@'
540
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 $< [$]@'
541
INTLTOOL_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 $< [$]@'
542
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 $< [$]@'
543
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 $< [$]@'
544
INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< [$]@'
545
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 $< [$]@'
546
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 $< [$]@'
547
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 $< [$]@'
548
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 $< [$]@'
549
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 $< [$]@'
550
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 $< [$]@'
551
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 $< [$]@'
553
AC_SUBST(INTLTOOL_DESKTOP_RULE)
554
AC_SUBST(INTLTOOL_DIRECTORY_RULE)
555
AC_SUBST(INTLTOOL_KEYS_RULE)
556
AC_SUBST(INTLTOOL_PROP_RULE)
557
AC_SUBST(INTLTOOL_OAF_RULE)
558
AC_SUBST(INTLTOOL_PONG_RULE)
559
AC_SUBST(INTLTOOL_SERVER_RULE)
560
AC_SUBST(INTLTOOL_SHEET_RULE)
561
AC_SUBST(INTLTOOL_SOUNDLIST_RULE)
562
AC_SUBST(INTLTOOL_UI_RULE)
563
AC_SUBST(INTLTOOL_XAM_RULE)
564
AC_SUBST(INTLTOOL_KBD_RULE)
565
AC_SUBST(INTLTOOL_XML_RULE)
566
AC_SUBST(INTLTOOL_XML_NOMERGE_RULE)
567
AC_SUBST(INTLTOOL_CAVES_RULE)
568
AC_SUBST(INTLTOOL_SCHEMAS_RULE)
569
AC_SUBST(INTLTOOL_THEME_RULE)
570
AC_SUBST(INTLTOOL_SERVICE_RULE)
571
AC_SUBST(INTLTOOL_POLICY_RULE)
573
# Check the gettext tools to make sure they are GNU
574
AC_PATH_PROG(XGETTEXT, xgettext)
575
AC_PATH_PROG(MSGMERGE, msgmerge)
576
AC_PATH_PROG(MSGFMT, msgfmt)
577
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
578
if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
579
AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
581
xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
582
mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
583
mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
584
if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
585
AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
588
AC_PATH_PROG(INTLTOOL_PERL, [perl])
589
if test -z "$INTLTOOL_PERL"; then
590
AC_MSG_ERROR([perl not found; required for intltool])
592
if test -z "`$INTLTOOL_PERL -v | fgrep '5.' 2> /dev/null`"; then
593
AC_MSG_ERROR([perl 5.x required for intltool])
595
if test "x$2" != "xno-xml"; then
596
AC_MSG_CHECKING([for XML::Parser])
597
if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
600
AC_MSG_ERROR([XML::Parser perl module is required for intltool])
604
# Substitute ALL_LINGUAS so we can use it in po/Makefile
605
AC_SUBST(ALL_LINGUAS)
607
# Set DATADIRNAME correctly if it is not set yet
608
# (copied from glib-gettext.m4)
609
if test -z "$DATADIRNAME"; then
611
[AC_LANG_PROGRAM([[]],
612
[[extern int _nl_msg_cat_cntr;
613
return _nl_msg_cat_cntr]])],
617
dnl On Solaris, if bind_textdomain_codeset is in libc,
618
dnl GNU format message catalog is always supported,
619
dnl since both are added to the libc all together.
620
dnl Hence, we'd like to go with DATADIRNAME=share
622
AC_CHECK_FUNC(bind_textdomain_codeset,
623
[DATADIRNAME=share], [DATADIRNAME=lib])
630
AC_SUBST(DATADIRNAME)
637
# IT_PO_SUBDIR(DIRNAME)
638
# ---------------------
639
# All po subdirs have to be declared with this macro; the subdir "po" is
640
# declared by IT_PROG_INTLTOOL.
642
AC_DEFUN([IT_PO_SUBDIR],
643
[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
645
dnl The following CONFIG_COMMANDS should be exetuted at the very end
646
dnl of config.status.
647
AC_CONFIG_COMMANDS_PRE([
648
AC_CONFIG_COMMANDS([$1/stamp-it], [
649
if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" ]; then
650
AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
652
rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
657
'"s|^| $ac_top_srcdir/|" \
658
"$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
660
[sed '/^POTFILES =/,/[^\\]$/ {
664
' "$1/Makefile.in" >"$1/Makefile"]
665
rm -f "$1/Makefile.tmp"
666
mv "$1/stamp-it.tmp" "$1/stamp-it"
672
AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
673
# A hint is needed for aclocal from Automake <= 1.9.4:
674
# AC_DEFUN([AC_PROG_INTLTOOL], ...)
677
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
679
# serial 52 AC_PROG_LIBTOOL
682
# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
683
# -----------------------------------------------------------
684
# If this macro is not defined by Autoconf, define it here.
685
m4_ifdef([AC_PROVIDE_IFELSE],
687
[m4_define([AC_PROVIDE_IFELSE],
688
[m4_ifdef([AC_PROVIDE_$1],
694
AC_DEFUN([AC_PROG_LIBTOOL],
695
[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
696
dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
697
dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
698
AC_PROVIDE_IFELSE([AC_PROG_CXX],
700
[define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
702
dnl And a similar setup for Fortran 77 support
703
AC_PROVIDE_IFELSE([AC_PROG_F77],
705
[define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
708
dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
709
dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
710
dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
711
AC_PROVIDE_IFELSE([AC_PROG_GCJ],
713
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
715
[AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
717
[ifdef([AC_PROG_GCJ],
718
[define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
719
ifdef([A][M_PROG_GCJ],
720
[define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
721
ifdef([LT_AC_PROG_GCJ],
722
[define([LT_AC_PROG_GCJ],
723
defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
724
])])# AC_PROG_LIBTOOL
729
AC_DEFUN([_AC_PROG_LIBTOOL],
730
[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
731
AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
732
AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
733
AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
735
# This can be used to rebuild libtool when needed
736
LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
738
# Always use our own libtool.
739
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
742
# Prevent multiple expansion
743
define([AC_PROG_LIBTOOL], [])
749
AC_DEFUN([AC_LIBTOOL_SETUP],
751
AC_REQUIRE([AC_ENABLE_SHARED])dnl
752
AC_REQUIRE([AC_ENABLE_STATIC])dnl
753
AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
754
AC_REQUIRE([AC_CANONICAL_HOST])dnl
755
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
756
AC_REQUIRE([AC_PROG_CC])dnl
757
AC_REQUIRE([AC_PROG_LD])dnl
758
AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
759
AC_REQUIRE([AC_PROG_NM])dnl
761
AC_REQUIRE([AC_PROG_LN_S])dnl
762
AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
763
# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
764
AC_REQUIRE([AC_OBJEXT])dnl
765
AC_REQUIRE([AC_EXEEXT])dnl
767
AC_LIBTOOL_SYS_MAX_CMD_LEN
768
AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
771
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
772
_LT_AC_PROG_ECHO_BACKSLASH
776
# AIX sometimes has problems with the GCC collect2 program. For some
777
# reason, if we set the COLLECT_NAMES environment variable, the problems
778
# vanish in a puff of smoke.
779
if test "X${COLLECT_NAMES+set}" != Xset; then
786
# Sed substitution that helps us do robust quoting. It backslashifies
787
# metacharacters that are still active within double-quoted strings.
788
Xsed='sed -e 1s/^X//'
789
[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
791
# Same as above, but do not quote variable references.
792
[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
794
# Sed substitution to delay expansion of an escaped shell variable in a
795
# double_quote_subst'ed string.
796
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
798
# Sed substitution to avoid accidental globbing in evaled expressions
799
no_glob_subst='s/\*/\\\*/g'
805
default_ofile=libtool
808
# All known linkers require a `.a' archive for static linking (except MSVC,
809
# which needs '.lib').
811
ltmain="$ac_aux_dir/ltmain.sh"
812
ofile="$default_ofile"
813
with_gnu_ld="$lt_cv_prog_gnu_ld"
815
AC_CHECK_TOOL(AR, ar, false)
816
AC_CHECK_TOOL(RANLIB, ranlib, :)
817
AC_CHECK_TOOL(STRIP, strip, :)
822
# Set sane defaults for various variables
823
test -z "$AR" && AR=ar
824
test -z "$AR_FLAGS" && AR_FLAGS=cru
825
test -z "$AS" && AS=as
826
test -z "$CC" && CC=cc
827
test -z "$LTCC" && LTCC=$CC
828
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
829
test -z "$DLLTOOL" && DLLTOOL=dlltool
830
test -z "$LD" && LD=ld
831
test -z "$LN_S" && LN_S="ln -s"
832
test -z "$MAGIC_CMD" && MAGIC_CMD=file
833
test -z "$NM" && NM=nm
834
test -z "$SED" && SED=sed
835
test -z "$OBJDUMP" && OBJDUMP=objdump
836
test -z "$RANLIB" && RANLIB=:
837
test -z "$STRIP" && STRIP=:
838
test -z "$ac_objext" && ac_objext=o
840
# Determine commands to create old-style static archives.
841
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
842
old_postinstall_cmds='chmod 644 $oldlib'
843
old_postuninstall_cmds=
845
if test -n "$RANLIB"; then
848
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
851
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
854
old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
857
_LT_CC_BASENAME([$compiler])
859
# Only perform the check for file, if the check method requires it
860
case $deplibs_check_method in
862
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
868
_LT_REQUIRED_DARWIN_CHECKS
870
AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
871
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
872
enable_win32_dll=yes, enable_win32_dll=no)
874
AC_ARG_ENABLE([libtool-lock],
875
[AC_HELP_STRING([--disable-libtool-lock],
876
[avoid locking (might break parallel builds)])])
877
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
880
[AC_HELP_STRING([--with-pic],
881
[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
882
[pic_mode="$withval"],
884
test -z "$pic_mode" && pic_mode=default
886
# Check if we have a version mismatch between libtool.m4 and ltmain.sh.
888
# Note: This should be in AC_LIBTOOL_SETUP, _after_ $ltmain have been defined.
889
# We also should do it _before_ AC_LIBTOOL_LANG_C_CONFIG that actually
890
# calls AC_LIBTOOL_CONFIG and creates libtool.
894
# Use C for the default configuration in the libtool script
896
AC_LIBTOOL_LANG_C_CONFIG
903
AC_DEFUN([_LT_VERSION_CHECK],
904
[AC_MSG_CHECKING([for correct ltmain.sh version])
905
if test "x$ltmain" = "x" ; then
909
*** @<:@Gentoo@:>@ sanity check failed! ***
910
*** \$ltmain is not defined, please check the patch for consistency! ***
913
gentoo_lt_version="1.5.26"
914
gentoo_ltmain_version=`sed -n '/^[[ ]]*VERSION=/{s/^[[ ]]*VERSION=//;p;q;}' "$ltmain"`
915
if test "x$gentoo_lt_version" != "x$gentoo_ltmain_version" ; then
919
*** @<:@Gentoo@:>@ sanity check failed! ***
920
*** libtool.m4 and ltmain.sh have a version mismatch! ***
921
*** (libtool.m4 = $gentoo_lt_version, ltmain.sh = $gentoo_ltmain_version) ***
925
libtoolize --copy --force
927
if appropriate, please contact the maintainer of this
928
package (or your distribution) for help.
933
])# _LT_VERSION_CHECK
936
# _LT_AC_SYS_COMPILER
937
# -------------------
938
AC_DEFUN([_LT_AC_SYS_COMPILER],
939
[AC_REQUIRE([AC_PROG_CC])dnl
941
# If no C compiler was specified, use CC.
944
# If no C compiler flags were specified, use CFLAGS.
945
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
947
# Allow CC to be a program name with arguments.
949
])# _LT_AC_SYS_COMPILER
952
# _LT_CC_BASENAME(CC)
953
# -------------------
954
# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
955
AC_DEFUN([_LT_CC_BASENAME],
956
[for cc_temp in $1""; do
958
compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
959
distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
964
cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
968
# _LT_COMPILER_BOILERPLATE
969
# ------------------------
970
# Check for compiler boilerplate output or warnings with
971
# the simple compiler test code.
972
AC_DEFUN([_LT_COMPILER_BOILERPLATE],
973
[AC_REQUIRE([LT_AC_PROG_SED])dnl
974
ac_outfile=conftest.$ac_objext
975
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
976
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
977
_lt_compiler_boilerplate=`cat conftest.err`
979
])# _LT_COMPILER_BOILERPLATE
982
# _LT_LINKER_BOILERPLATE
983
# ----------------------
984
# Check for linker boilerplate output or warnings with
985
# the simple link test code.
986
AC_DEFUN([_LT_LINKER_BOILERPLATE],
987
[AC_REQUIRE([LT_AC_PROG_SED])dnl
988
ac_outfile=conftest.$ac_objext
989
echo "$lt_simple_link_test_code" >conftest.$ac_ext
990
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
991
_lt_linker_boilerplate=`cat conftest.err`
993
])# _LT_LINKER_BOILERPLATE
995
# _LT_REQUIRED_DARWIN_CHECKS
996
# --------------------------
997
# Check for some things on darwin
998
AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[
1000
rhapsody* | darwin*)
1001
AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1002
AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1004
AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1005
[lt_cv_apple_cc_single_mod=no
1006
if test -z "${LT_MULTI_MODULE}"; then
1007
# By default we will add the -single_module flag. You can override
1008
# by either setting the environment variable LT_MULTI_MODULE
1009
# non-empty at configure time, or by adding -multi_module to the
1011
echo "int foo(void){return 1;}" > conftest.c
1012
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1013
-dynamiclib ${wl}-single_module conftest.c
1014
if test -f libconftest.dylib; then
1015
lt_cv_apple_cc_single_mod=yes
1016
rm -rf libconftest.dylib*
1020
AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1021
[lt_cv_ld_exported_symbols_list],
1022
[lt_cv_ld_exported_symbols_list=no
1023
save_LDFLAGS=$LDFLAGS
1024
echo "_main" > conftest.sym
1025
LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1026
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1027
[lt_cv_ld_exported_symbols_list=yes],
1028
[lt_cv_ld_exported_symbols_list=no])
1029
LDFLAGS="$save_LDFLAGS"
1032
rhapsody* | darwin1.[[0123]])
1033
_lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1035
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1037
# if running on 10.5 or later, the deployment target defaults
1038
# to the OS version, if on x86, and 10.4, the deployment
1039
# target defaults to 10.4. Don't you love it?
1040
case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1041
10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1042
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1044
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1046
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1050
if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1051
_lt_dar_single_mod='$single_module'
1053
if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1054
_lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1056
_lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
1058
if test "$DSYMUTIL" != ":"; then
1059
_lt_dsymutil="~$DSYMUTIL \$lib || :"
1067
# _LT_AC_SYS_LIBPATH_AIX
1068
# ----------------------
1069
# Links a minimal program and checks the executable
1070
# for the system default hardcoded library path. In most cases,
1071
# this is /usr/lib:/lib, but when the MPI compilers are used
1072
# the location of the communication and MPI libs are included too.
1073
# If we don't find anything, use the default library path according
1074
# to the aix ld manual.
1075
AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
1076
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1077
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1078
lt_aix_libpath_sed='
1079
/Import File Strings/,/^$/ {
1085
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1086
# Check for a 64-bit object if we didn't find anything.
1087
if test -z "$aix_libpath"; then
1088
aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1090
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1091
])# _LT_AC_SYS_LIBPATH_AIX
1094
# _LT_AC_SHELL_INIT(ARG)
1095
# ----------------------
1096
AC_DEFUN([_LT_AC_SHELL_INIT],
1097
[ifdef([AC_DIVERSION_NOTICE],
1098
[AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1099
[AC_DIVERT_PUSH(NOTICE)])
1102
])# _LT_AC_SHELL_INIT
1105
# _LT_AC_PROG_ECHO_BACKSLASH
1106
# --------------------------
1107
# Add some code to the start of the generated configure script which
1108
# will find an echo command which doesn't interpret backslashes.
1109
AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
1110
[_LT_AC_SHELL_INIT([
1111
# Check that we are running under the correct shell.
1112
SHELL=${CONFIG_SHELL-/bin/sh}
1116
# Remove one level of quotation (which was required for Make).
1117
ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1122
if test "X[$]1" = X--no-reexec; then
1123
# Discard the --no-reexec flag, and continue.
1125
elif test "X[$]1" = X--fallback-echo; then
1126
# Avoid inline document here, it may be left over
1128
elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
1129
# Yippee, $echo works!
1132
# Restart under the correct shell.
1133
exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1136
if test "X[$]1" = X--fallback-echo; then
1137
# used as fallback echo
1145
# The HP-UX ksh and POSIX shell print the target directory to stdout
1147
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1149
if test -z "$ECHO"; then
1150
if test "X${echo_test_string+set}" != Xset; then
1151
# find a string as large as possible, as long as the shell can cope with it
1152
for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1153
# expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1154
if (echo_test_string=`eval $cmd`) 2>/dev/null &&
1155
echo_test_string=`eval $cmd` &&
1156
(test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
1163
if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1164
echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1165
test "X$echo_testing_string" = "X$echo_test_string"; then
1168
# The Solaris, AIX, and Digital Unix default echo programs unquote
1169
# backslashes. This makes it impossible to quote backslashes using
1170
# echo "$something" | sed 's/\\/\\\\/g'
1172
# So, first we look for a working echo in the user's PATH.
1174
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1175
for dir in $PATH /usr/ucb; do
1177
if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1178
test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1179
echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1180
test "X$echo_testing_string" = "X$echo_test_string"; then
1187
if test "X$echo" = Xecho; then
1188
# We didn't find a better echo, so look for alternatives.
1189
if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
1190
echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
1191
test "X$echo_testing_string" = "X$echo_test_string"; then
1192
# This shell has a builtin print -r that does the trick.
1194
elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
1195
test "X$CONFIG_SHELL" != X/bin/ksh; then
1196
# If we have ksh, try running configure again with it.
1197
ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1198
export ORIGINAL_CONFIG_SHELL
1199
CONFIG_SHELL=/bin/ksh
1201
exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1205
if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1206
echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1207
test "X$echo_testing_string" = "X$echo_test_string"; then
1208
# Cool, printf works
1210
elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1211
test "X$echo_testing_string" = 'X\t' &&
1212
echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1213
test "X$echo_testing_string" = "X$echo_test_string"; then
1214
CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1216
SHELL="$CONFIG_SHELL"
1218
echo="$CONFIG_SHELL [$]0 --fallback-echo"
1219
elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1220
test "X$echo_testing_string" = 'X\t' &&
1221
echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1222
test "X$echo_testing_string" = "X$echo_test_string"; then
1223
echo="$CONFIG_SHELL [$]0 --fallback-echo"
1225
# maybe with a smaller string...
1228
for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1229
if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
1236
if test "$prev" != 'sed 50q "[$]0"'; then
1237
echo_test_string=`eval $prev`
1238
export echo_test_string
1239
exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1241
# Oops. We lost completely, so just stick with echo.
1250
# Copy echo and quote the copy suitably for passing to libtool from
1251
# the Makefile, instead of quoting the original, which is used later.
1253
if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1254
ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1258
])])# _LT_AC_PROG_ECHO_BACKSLASH
1263
AC_DEFUN([_LT_AC_LOCK],
1264
[AC_ARG_ENABLE([libtool-lock],
1265
[AC_HELP_STRING([--disable-libtool-lock],
1266
[avoid locking (might break parallel builds)])])
1267
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1269
# Some flags need to be propagated to the compiler or linker for good
1273
# Find out which ABI we are using.
1274
echo 'int i;' > conftest.$ac_ext
1275
if AC_TRY_EVAL(ac_compile); then
1276
case `/usr/bin/file conftest.$ac_objext` in
1288
# Find out which ABI we are using.
1289
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1290
if AC_TRY_EVAL(ac_compile); then
1291
if test "$lt_cv_prog_gnu_ld" = yes; then
1292
case `/usr/bin/file conftest.$ac_objext` in
1294
LD="${LD-ld} -melf32bsmip"
1297
LD="${LD-ld} -melf32bmipn32"
1300
LD="${LD-ld} -melf64bmip"
1304
case `/usr/bin/file conftest.$ac_objext` in
1320
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1321
s390*-*linux*|sparc*-*linux*)
1322
# Find out which ABI we are using.
1323
echo 'int i;' > conftest.$ac_ext
1324
if AC_TRY_EVAL(ac_compile); then
1325
case `/usr/bin/file conftest.o` in
1328
x86_64-*kfreebsd*-gnu)
1329
LD="${LD-ld} -m elf_i386_fbsd"
1332
LD="${LD-ld} -m elf_i386"
1334
ppc64-*linux*|powerpc64-*linux*)
1335
LD="${LD-ld} -m elf32ppclinux"
1338
LD="${LD-ld} -m elf_s390"
1341
LD="${LD-ld} -m elf32_sparc"
1347
x86_64-*kfreebsd*-gnu)
1348
LD="${LD-ld} -m elf_x86_64_fbsd"
1351
LD="${LD-ld} -m elf_x86_64"
1353
ppc*-*linux*|powerpc*-*linux*)
1354
LD="${LD-ld} -m elf64ppc"
1357
LD="${LD-ld} -m elf64_s390"
1360
LD="${LD-ld} -m elf64_sparc"
1370
# On SCO OpenServer 5, we need -belf to get full-featured binaries.
1371
SAVE_CFLAGS="$CFLAGS"
1372
CFLAGS="$CFLAGS -belf"
1373
AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1375
AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1377
if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1378
# this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1379
CFLAGS="$SAVE_CFLAGS"
1383
# Find out which ABI we are using.
1384
echo 'int i;' > conftest.$ac_ext
1385
if AC_TRY_EVAL(ac_compile); then
1386
case `/usr/bin/file conftest.o` in
1388
case $lt_cv_prog_gnu_ld in
1389
yes*) LD="${LD-ld} -m elf64_sparc" ;;
1391
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1402
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1403
[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
1404
AC_CHECK_TOOL(DLLTOOL, dlltool, false)
1405
AC_CHECK_TOOL(AS, as, false)
1406
AC_CHECK_TOOL(OBJDUMP, objdump, false)
1411
need_locks="$enable_libtool_lock"
1416
# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1417
# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1418
# ----------------------------------------------------------------
1419
# Check whether the given compiler option works
1420
AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
1421
[AC_REQUIRE([LT_AC_PROG_SED])
1422
AC_CACHE_CHECK([$1], [$2],
1424
ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1425
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1426
lt_compiler_flag="$3"
1427
# Insert the option either (1) after the last *FLAGS variable, or
1428
# (2) before a word containing "conftest.", or (3) at the end.
1429
# Note that $ac_compile itself does not contain backslashes and begins
1430
# with a dollar sign (not a hyphen), so the echo should work correctly.
1431
# The option is referenced via a variable to avoid confusing sed.
1432
lt_compile=`echo "$ac_compile" | $SED \
1433
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1434
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1435
-e 's:$: $lt_compiler_flag:'`
1436
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1437
(eval "$lt_compile" 2>conftest.err)
1439
cat conftest.err >&AS_MESSAGE_LOG_FD
1440
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1441
if (exit $ac_status) && test -s "$ac_outfile"; then
1442
# The compiler can only warn and ignore the option if not recognized
1443
# So say no if there are warnings other than the usual output.
1444
$echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
1445
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1446
if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1453
if test x"[$]$2" = xyes; then
1454
ifelse([$5], , :, [$5])
1456
ifelse([$6], , :, [$6])
1458
])# AC_LIBTOOL_COMPILER_OPTION
1461
# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1462
# [ACTION-SUCCESS], [ACTION-FAILURE])
1463
# ------------------------------------------------------------
1464
# Check whether the given compiler option works
1465
AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
1466
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1467
AC_CACHE_CHECK([$1], [$2],
1469
save_LDFLAGS="$LDFLAGS"
1470
LDFLAGS="$LDFLAGS $3"
1471
echo "$lt_simple_link_test_code" > conftest.$ac_ext
1472
if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1473
# The linker can only warn and ignore the option if not recognized
1474
# So say no if there are warnings
1475
if test -s conftest.err; then
1476
# Append any errors to the config.log.
1477
cat conftest.err 1>&AS_MESSAGE_LOG_FD
1478
$echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
1479
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1480
if diff conftest.exp conftest.er2 >/dev/null; then
1488
LDFLAGS="$save_LDFLAGS"
1491
if test x"[$]$2" = xyes; then
1492
ifelse([$4], , :, [$4])
1494
ifelse([$5], , :, [$5])
1496
])# AC_LIBTOOL_LINKER_OPTION
1499
# AC_LIBTOOL_SYS_MAX_CMD_LEN
1500
# --------------------------
1501
AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
1502
[# find the maximum length of command line arguments
1503
AC_MSG_CHECKING([the maximum length of command line arguments])
1504
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1510
# On DJGPP, this test can blow up pretty badly due to problems in libc
1511
# (any single argument exceeding 2000 bytes causes a buffer overrun
1512
# during glob expansion). Even if it were fixed, the result of this
1513
# check would be larger than it should be.
1514
lt_cv_sys_max_cmd_len=12288; # 12K is about right
1518
# Under GNU Hurd, this test is not required because there is
1519
# no limit to the length of command line arguments.
1520
# Libtool will interpret -1 as no limit whatsoever
1521
lt_cv_sys_max_cmd_len=-1;
1525
# On Win9x/ME, this test blows up -- it succeeds, but takes
1526
# about 5 minutes as the teststring grows exponentially.
1527
# Worse, since 9x/ME are not pre-emptively multitasking,
1528
# you end up with a "frozen" computer, even though with patience
1529
# the test eventually succeeds (with a max line length of 256k).
1530
# Instead, let's just punt: use the minimum linelength reported by
1531
# all of the supported platforms: 8192 (on NT/2K/XP).
1532
lt_cv_sys_max_cmd_len=8192;
1536
# On AmigaOS with pdksh, this test takes hours, literally.
1537
# So we just punt and use a minimum line length of 8192.
1538
lt_cv_sys_max_cmd_len=8192;
1541
netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1542
# This has been around since 386BSD, at least. Likely further.
1543
if test -x /sbin/sysctl; then
1544
lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1545
elif test -x /usr/sbin/sysctl; then
1546
lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1548
lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1550
# And add a safety zone
1551
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1552
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1556
# We know the value 262144 and hardcode it with a safety zone (like BSD)
1557
lt_cv_sys_max_cmd_len=196608
1561
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1562
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1563
# nice to cause kernel panics so lets avoid the loop below.
1564
# First set a reasonable default.
1565
lt_cv_sys_max_cmd_len=16384
1567
if test -x /sbin/sysconfig; then
1568
case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1569
*1*) lt_cv_sys_max_cmd_len=-1 ;;
1574
lt_cv_sys_max_cmd_len=102400
1576
sysv5* | sco5v6* | sysv4.2uw2*)
1577
kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1578
if test -n "$kargmax"; then
1579
lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1581
lt_cv_sys_max_cmd_len=32768
1585
lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1586
if test -n "$lt_cv_sys_max_cmd_len"; then
1587
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1588
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1590
SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1591
while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
1592
= "XX$teststring") >/dev/null 2>&1 &&
1593
new_result=`expr "X$teststring" : ".*" 2>&1` &&
1594
lt_cv_sys_max_cmd_len=$new_result &&
1595
test $i != 17 # 1/2 MB should be enough
1598
teststring=$teststring$teststring
1601
# Add a significant safety factor because C++ compilers can tack on massive
1602
# amounts of additional arguments before passing them to the linker.
1603
# It appears as though 1/2 is a usable value.
1604
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1609
if test -n $lt_cv_sys_max_cmd_len ; then
1610
AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1614
])# AC_LIBTOOL_SYS_MAX_CMD_LEN
1617
# _LT_AC_CHECK_DLFCN
1618
# ------------------
1619
AC_DEFUN([_LT_AC_CHECK_DLFCN],
1620
[AC_CHECK_HEADERS(dlfcn.h)dnl
1621
])# _LT_AC_CHECK_DLFCN
1624
# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1625
# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1626
# ---------------------------------------------------------------------
1627
AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
1628
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1629
if test "$cross_compiling" = yes; then :
1632
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1633
lt_status=$lt_dlunknown
1634
cat > conftest.$ac_ext <<EOF
1635
[#line __oline__ "configure"
1636
#include "confdefs.h"
1645
# define LT_DLGLOBAL RTLD_GLOBAL
1648
# define LT_DLGLOBAL DL_GLOBAL
1650
# define LT_DLGLOBAL 0
1654
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1655
find out it does not work in some platform. */
1656
#ifndef LT_DLLAZY_OR_NOW
1658
# define LT_DLLAZY_OR_NOW RTLD_LAZY
1661
# define LT_DLLAZY_OR_NOW DL_LAZY
1664
# define LT_DLLAZY_OR_NOW RTLD_NOW
1667
# define LT_DLLAZY_OR_NOW DL_NOW
1669
# define LT_DLLAZY_OR_NOW 0
1677
extern "C" void exit (int);
1680
void fnord() { int i=42;}
1683
void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1684
int status = $lt_dlunknown;
1688
if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1689
else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1690
/* dlclose (self); */
1698
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1699
(./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1702
x$lt_dlno_uscore) $1 ;;
1703
x$lt_dlneed_uscore) $2 ;;
1704
x$lt_dlunknown|x*) $3 ;;
1707
# compilation failed
1712
])# _LT_AC_TRY_DLOPEN_SELF
1715
# AC_LIBTOOL_DLOPEN_SELF
1716
# ----------------------
1717
AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
1718
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1719
if test "x$enable_dlopen" != xyes; then
1720
enable_dlopen=unknown
1721
enable_dlopen_self=unknown
1722
enable_dlopen_self_static=unknown
1729
lt_cv_dlopen="load_add_on"
1731
lt_cv_dlopen_self=yes
1735
lt_cv_dlopen="LoadLibrary"
1740
lt_cv_dlopen="dlopen"
1745
# if libdl is installed we need to link against it
1746
AC_CHECK_LIB([dl], [dlopen],
1747
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1750
lt_cv_dlopen_self=yes
1755
AC_CHECK_FUNC([shl_load],
1756
[lt_cv_dlopen="shl_load"],
1757
[AC_CHECK_LIB([dld], [shl_load],
1758
[lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1759
[AC_CHECK_FUNC([dlopen],
1760
[lt_cv_dlopen="dlopen"],
1761
[AC_CHECK_LIB([dl], [dlopen],
1762
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1763
[AC_CHECK_LIB([svld], [dlopen],
1764
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1765
[AC_CHECK_LIB([dld], [dld_link],
1766
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1775
if test "x$lt_cv_dlopen" != xno; then
1781
case $lt_cv_dlopen in
1783
save_CPPFLAGS="$CPPFLAGS"
1784
test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1786
save_LDFLAGS="$LDFLAGS"
1787
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1790
LIBS="$lt_cv_dlopen_libs $LIBS"
1792
AC_CACHE_CHECK([whether a program can dlopen itself],
1793
lt_cv_dlopen_self, [dnl
1794
_LT_AC_TRY_DLOPEN_SELF(
1795
lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1796
lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1799
if test "x$lt_cv_dlopen_self" = xyes; then
1800
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1801
AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1802
lt_cv_dlopen_self_static, [dnl
1803
_LT_AC_TRY_DLOPEN_SELF(
1804
lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1805
lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1809
CPPFLAGS="$save_CPPFLAGS"
1810
LDFLAGS="$save_LDFLAGS"
1815
case $lt_cv_dlopen_self in
1816
yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1817
*) enable_dlopen_self=unknown ;;
1820
case $lt_cv_dlopen_self_static in
1821
yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1822
*) enable_dlopen_self_static=unknown ;;
1825
])# AC_LIBTOOL_DLOPEN_SELF
1828
# AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1829
# ---------------------------------
1830
# Check to see if options -c and -o are simultaneously supported by compiler
1831
AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1832
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1833
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1834
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1835
[_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1836
[_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1837
$rm -r conftest 2>/dev/null
1841
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1843
lt_compiler_flag="-o out/conftest2.$ac_objext"
1844
# Insert the option either (1) after the last *FLAGS variable, or
1845
# (2) before a word containing "conftest.", or (3) at the end.
1846
# Note that $ac_compile itself does not contain backslashes and begins
1847
# with a dollar sign (not a hyphen), so the echo should work correctly.
1848
lt_compile=`echo "$ac_compile" | $SED \
1849
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1850
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1851
-e 's:$: $lt_compiler_flag:'`
1852
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1853
(eval "$lt_compile" 2>out/conftest.err)
1855
cat out/conftest.err >&AS_MESSAGE_LOG_FD
1856
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1857
if (exit $ac_status) && test -s out/conftest2.$ac_objext
1859
# The compiler can only warn and ignore the option if not recognized
1860
# So say no if there are warnings
1861
$echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
1862
$SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
1863
if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1864
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1867
chmod u+w . 2>&AS_MESSAGE_LOG_FD
1869
# SGI C++ compiler will create directory out/ii_files/ for
1870
# template instantiation
1871
test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
1872
$rm out/* && rmdir out
1877
])# AC_LIBTOOL_PROG_CC_C_O
1880
# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
1881
# -----------------------------------------
1882
# Check to see if we can do hard links to lock some files if needed
1883
AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
1884
[AC_REQUIRE([_LT_AC_LOCK])dnl
1886
hard_links="nottested"
1887
if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1888
# do not overwrite the value of need_locks provided by the user
1889
AC_MSG_CHECKING([if we can lock with hard links])
1892
ln conftest.a conftest.b 2>/dev/null && hard_links=no
1894
ln conftest.a conftest.b 2>&5 || hard_links=no
1895
ln conftest.a conftest.b 2>/dev/null && hard_links=no
1896
AC_MSG_RESULT([$hard_links])
1897
if test "$hard_links" = no; then
1898
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1904
])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
1909
AC_DEFUN([AC_LIBTOOL_OBJDIR],
1910
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
1911
[rm -f .libs 2>/dev/null
1912
mkdir .libs 2>/dev/null
1913
if test -d .libs; then
1916
# MS-DOS does not allow filenames that begin with a dot.
1919
rmdir .libs 2>/dev/null])
1920
objdir=$lt_cv_objdir
1921
])# AC_LIBTOOL_OBJDIR
1924
# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
1925
# ----------------------------------------------
1926
# Check hardcoding attributes.
1927
AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
1928
[AC_MSG_CHECKING([how to hardcode library paths into programs])
1929
_LT_AC_TAGVAR(hardcode_action, $1)=
1930
if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
1931
test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
1932
test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
1934
# We can hardcode non-existant directories.
1935
if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
1936
# If the only mechanism to avoid hardcoding is shlibpath_var, we
1937
# have to relink, otherwise we might link with an installed library
1938
# when we should be linking with a yet-to-be-installed one
1939
## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
1940
test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
1941
# Linking always hardcodes the temporary library directory.
1942
_LT_AC_TAGVAR(hardcode_action, $1)=relink
1944
# We can link without hardcoding, and we can hardcode nonexisting dirs.
1945
_LT_AC_TAGVAR(hardcode_action, $1)=immediate
1948
# We cannot hardcode anything, or else we can only hardcode existing
1950
_LT_AC_TAGVAR(hardcode_action, $1)=unsupported
1952
AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
1954
if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
1955
# Fast installation is not supported
1956
enable_fast_install=no
1957
elif test "$shlibpath_overrides_runpath" = yes ||
1958
test "$enable_shared" = no; then
1959
# Fast installation is not necessary
1960
enable_fast_install=needless
1962
])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
1965
# AC_LIBTOOL_SYS_LIB_STRIP
1966
# ------------------------
1967
AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
1970
AC_MSG_CHECKING([whether stripping libraries is possible])
1971
if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
1972
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
1973
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
1974
AC_MSG_RESULT([yes])
1976
# FIXME - insert some real tests, host_os isn't really good enough
1979
if test -n "$STRIP" ; then
1980
striplib="$STRIP -x"
1981
old_striplib="$STRIP -S"
1982
AC_MSG_RESULT([yes])
1992
])# AC_LIBTOOL_SYS_LIB_STRIP
1995
# AC_LIBTOOL_SYS_DYNAMIC_LINKER
1996
# -----------------------------
1997
# PORTME Fill in your ld.so characteristics
1998
AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
1999
[AC_REQUIRE([LT_AC_PROG_SED])dnl
2000
AC_MSG_CHECKING([dynamic linker characteristics])
2002
libname_spec='lib$name'
2010
shlibpath_overrides_runpath=unknown
2012
dynamic_linker="$host_os ld.so"
2013
sys_lib_dlsearch_path_spec="/lib /usr/lib"
2015
if test "$GCC" = yes; then
2017
darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2018
*) lt_awk_arg="/^libraries:/" ;;
2020
lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2021
if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
2022
# if the path contains ";" then we assume it to be the separator
2023
# otherwise default to the standard path separator (i.e. ":") - it is
2024
# assumed that no part of a normal pathname contains ";" but that should
2025
# okay in the real world where ";" in dirpaths is itself problematic.
2026
lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
2028
lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2030
# Ok, now we have the path, separated by spaces, we can step through it
2031
# and add multilib dir if necessary.
2032
lt_tmp_lt_search_path_spec=
2033
lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2034
for lt_sys_path in $lt_search_path_spec; do
2035
if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2036
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2038
test -d "$lt_sys_path" && \
2039
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2042
lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
2043
BEGIN {RS=" "; FS="/|\n";} {
2046
for (lt_i = NF; lt_i > 0; lt_i--) {
2047
if ($lt_i != "" && $lt_i != ".") {
2048
if ($lt_i == "..") {
2051
if (lt_count == 0) {
2052
lt_foo="/" $lt_i lt_foo;
2059
if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2060
if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2062
sys_lib_search_path_spec=`echo $lt_search_path_spec`
2064
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2066
need_lib_prefix=unknown
2067
hardcode_into_libs=no
2069
# when you set need_version to no, make sure it does not cause -set_version
2070
# flags to be left without arguments
2071
need_version=unknown
2076
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2077
shlibpath_var=LIBPATH
2079
# AIX 3 has no versioning support, so we append a major version to the name.
2080
soname_spec='${libname}${release}${shared_ext}$major'
2087
hardcode_into_libs=yes
2088
if test "$host_cpu" = ia64; then
2089
# AIX 5 supports IA64
2090
library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2091
shlibpath_var=LD_LIBRARY_PATH
2093
# With GCC up to 2.95.x, collect2 would create an import file
2094
# for dependence libraries. The import file would start with
2095
# the line `#! .'. This would cause the generated library to
2096
# depend on `.', always an invalid library. This was fixed in
2097
# development snapshots of GCC prior to 3.0.
2099
aix4 | aix4.[[01]] | aix4.[[01]].*)
2100
if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2102
echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
2109
# AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2110
# soname into executable. Probably we can add versioning support to
2111
# collect2, so additional links can be useful in future.
2112
if test "$aix_use_runtimelinking" = yes; then
2113
# If using run time linking (on AIX 4.2 or later) use lib<name>.so
2114
# instead of lib<name>.a to let people know that these are not
2115
# typical AIX shared libraries.
2116
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2118
# We preserve .a as extension for shared libraries through AIX4.2
2119
# and later when we are not doing run time linking.
2120
library_names_spec='${libname}${release}.a $libname.a'
2121
soname_spec='${libname}${release}${shared_ext}$major'
2123
shlibpath_var=LIBPATH
2128
library_names_spec='$libname.ixlibrary $libname.a'
2129
# Create ${libname}_ixlibrary.a entries in /sys/libs.
2130
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'
2134
library_names_spec='${libname}${shared_ext}'
2135
dynamic_linker="$host_os ld.so"
2136
shlibpath_var=LIBRARY_PATH
2142
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2143
soname_spec='${libname}${release}${shared_ext}$major'
2144
finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2145
shlibpath_var=LD_LIBRARY_PATH
2146
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2147
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2148
# the default ld.so.conf also contains /usr/contrib/lib and
2149
# /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2150
# libtool to hard-code these into programs
2153
cygwin* | mingw* | pw32*)
2154
version_type=windows
2159
case $GCC,$host_os in
2160
yes,cygwin* | yes,mingw* | yes,pw32*)
2161
library_names_spec='$libname.dll.a'
2162
# DLL is installed to $(libdir)/../bin by postinstall_cmds
2163
postinstall_cmds='base_file=`basename \${file}`~
2164
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
2165
dldir=$destdir/`dirname \$dlpath`~
2166
test -d \$dldir || mkdir -p \$dldir~
2167
$install_prog $dir/$dlname \$dldir/$dlname~
2168
chmod a+x \$dldir/$dlname'
2169
postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2170
dlpath=$dir/\$dldll~
2172
shlibpath_overrides_runpath=yes
2176
# Cygwin DLLs use 'cyg' prefix rather than 'lib'
2177
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2178
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2181
# MinGW DLLs use traditional 'lib' prefix
2182
soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2183
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2184
if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
2185
# It is most probably a Windows format PATH printed by
2186
# mingw gcc, but we are running on Cygwin. Gcc prints its search
2187
# path with ; separators, and with drive letters. We can handle the
2188
# drive letters (cygwin fileutils understands them), so leave them,
2189
# especially as we might pass files found there to a mingw objdump,
2190
# which wouldn't understand a cygwinified path. Ahh.
2191
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2193
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2197
# pw32 DLLs use 'pw' prefix rather than 'lib'
2198
library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2204
library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2207
dynamic_linker='Win32 ld.exe'
2208
# FIXME: first we should search . and the directory the executable is in
2212
darwin* | rhapsody*)
2213
dynamic_linker="$host_os dyld"
2217
library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2218
soname_spec='${libname}${release}${major}$shared_ext'
2219
shlibpath_overrides_runpath=yes
2220
shlibpath_var=DYLD_LIBRARY_PATH
2221
shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2223
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2224
sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2231
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2232
soname_spec='${libname}${release}${shared_ext}$major'
2233
shlibpath_var=LD_LIBRARY_PATH
2240
freebsd* | dragonfly*)
2241
# DragonFly does not have aout. When/if they implement a new
2242
# versioning mechanism, adjust this.
2243
if test -x /usr/bin/objformat; then
2244
objformat=`/usr/bin/objformat`
2247
freebsd[[123]]*) objformat=aout ;;
2251
# Handle Gentoo/FreeBSD as it was Linux
2252
case $host_vendor in
2254
version_type=linux ;;
2256
version_type=freebsd-$objformat ;;
2259
case $version_type in
2261
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2266
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2270
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2271
soname_spec='${libname}${release}${shared_ext}$major'
2276
shlibpath_var=LD_LIBRARY_PATH
2279
shlibpath_overrides_runpath=yes
2281
freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2282
shlibpath_overrides_runpath=yes
2283
hardcode_into_libs=yes
2285
freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2286
freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2287
shlibpath_overrides_runpath=no
2288
hardcode_into_libs=yes
2290
*) # from 4.6 on, and DragonFly
2291
shlibpath_overrides_runpath=yes
2292
hardcode_into_libs=yes
2301
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2302
soname_spec='${libname}${release}${shared_ext}$major'
2303
shlibpath_var=LD_LIBRARY_PATH
2304
hardcode_into_libs=yes
2307
hpux9* | hpux10* | hpux11*)
2308
# Give a soname corresponding to the major version so that dld.sl refuses to
2309
# link against other versions.
2316
hardcode_into_libs=yes
2317
dynamic_linker="$host_os dld.so"
2318
shlibpath_var=LD_LIBRARY_PATH
2319
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2320
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2321
soname_spec='${libname}${release}${shared_ext}$major'
2322
if test "X$HPUX_IA64_MODE" = X32; then
2323
sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2325
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2327
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2331
hardcode_into_libs=yes
2332
dynamic_linker="$host_os dld.sl"
2333
shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2334
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2335
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2336
soname_spec='${libname}${release}${shared_ext}$major'
2337
sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2338
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2342
dynamic_linker="$host_os dld.sl"
2343
shlibpath_var=SHLIB_PATH
2344
shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2345
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2346
soname_spec='${libname}${release}${shared_ext}$major'
2349
# HP-UX runs *really* slowly unless shared libraries are mode 555.
2350
postinstall_cmds='chmod 555 $lib'
2357
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2358
soname_spec='${libname}${release}${shared_ext}$major'
2359
dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2360
shlibpath_var=LD_LIBRARY_PATH
2361
shlibpath_overrides_runpath=no
2362
hardcode_into_libs=yes
2365
irix5* | irix6* | nonstopux*)
2367
nonstopux*) version_type=nonstopux ;;
2369
if test "$lt_cv_prog_gnu_ld" = yes; then
2377
soname_spec='${libname}${release}${shared_ext}$major'
2378
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2380
irix5* | nonstopux*)
2384
case $LD in # libtool.m4 will add one of these switches to LD
2385
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2386
libsuff= shlibsuff= libmagic=32-bit;;
2387
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2388
libsuff=32 shlibsuff=N32 libmagic=N32;;
2389
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2390
libsuff=64 shlibsuff=64 libmagic=64-bit;;
2391
*) libsuff= shlibsuff= libmagic=never-match;;
2395
shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2396
shlibpath_overrides_runpath=no
2397
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2398
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2399
hardcode_into_libs=yes
2402
# No shared lib support for Linux oldld, aout, or coff.
2403
linux*oldld* | linux*aout* | linux*coff*)
2407
# This must be Linux ELF.
2408
linux* | k*bsd*-gnu)
2412
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2413
soname_spec='${libname}${release}${shared_ext}$major'
2414
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2415
shlibpath_var=LD_LIBRARY_PATH
2416
shlibpath_overrides_runpath=no
2417
# This implies no fast_install, which is unacceptable.
2418
# Some rework will be needed to allow for fast_install
2419
# before this can be enabled.
2420
hardcode_into_libs=yes
2422
# Append ld.so.conf contents to the search path
2423
if test -f /etc/ld.so.conf; then
2424
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' ' '`
2425
sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2428
# We used to test for /lib/ld.so.1 and disable shared libraries on
2429
# powerpc, because MkLinux only supported shared libraries with the
2430
# GNU dynamic linker. Since this was broken with cross compilers,
2431
# most powerpc-linux boxes support dynamic linking these days and
2432
# people can always --disable-shared, the test was removed, and we
2433
# assume the GNU/Linux dynamic linker is in use.
2434
dynamic_linker='GNU/Linux ld.so'
2441
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
2442
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2443
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2444
dynamic_linker='NetBSD (a.out) ld.so'
2446
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2447
soname_spec='${libname}${release}${shared_ext}$major'
2448
dynamic_linker='NetBSD ld.elf_so'
2450
shlibpath_var=LD_LIBRARY_PATH
2451
shlibpath_overrides_runpath=yes
2452
hardcode_into_libs=yes
2457
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2458
shlibpath_var=LD_LIBRARY_PATH
2459
shlibpath_overrides_runpath=yes
2466
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2467
soname_spec='${libname}${release}${shared_ext}$major'
2468
shlibpath_var=LD_LIBRARY_PATH
2469
shlibpath_overrides_runpath=yes
2474
sys_lib_dlsearch_path_spec="/usr/lib"
2476
# Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2478
openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2479
*) need_version=no ;;
2481
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2482
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2483
shlibpath_var=LD_LIBRARY_PATH
2484
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2486
openbsd2.[[89]] | openbsd2.[[89]].*)
2487
shlibpath_overrides_runpath=no
2490
shlibpath_overrides_runpath=yes
2494
shlibpath_overrides_runpath=yes
2499
libname_spec='$name'
2502
library_names_spec='$libname${shared_ext} $libname.a'
2503
dynamic_linker='OS/2 ld.exe'
2504
shlibpath_var=LIBPATH
2507
osf3* | osf4* | osf5*)
2511
soname_spec='${libname}${release}${shared_ext}$major'
2512
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2513
shlibpath_var=LD_LIBRARY_PATH
2514
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2515
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2526
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2527
soname_spec='${libname}${release}${shared_ext}$major'
2528
shlibpath_var=LD_LIBRARY_PATH
2529
shlibpath_overrides_runpath=yes
2530
hardcode_into_libs=yes
2531
# ldd complains unless libraries are executable
2532
postinstall_cmds='chmod +x $lib'
2537
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2538
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2539
shlibpath_var=LD_LIBRARY_PATH
2540
shlibpath_overrides_runpath=yes
2541
if test "$with_gnu_ld" = yes; then
2549
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2550
soname_spec='${libname}${release}${shared_ext}$major'
2551
shlibpath_var=LD_LIBRARY_PATH
2552
case $host_vendor in
2554
shlibpath_overrides_runpath=no
2556
export_dynamic_flag_spec='${wl}-Blargedynsym'
2557
runpath_var=LD_RUN_PATH
2565
shlibpath_overrides_runpath=no
2566
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2572
if test -d /usr/nec ;then
2574
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2575
soname_spec='$libname${shared_ext}.$major'
2576
shlibpath_var=LD_LIBRARY_PATH
2580
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2581
version_type=freebsd-elf
2584
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2585
soname_spec='${libname}${release}${shared_ext}$major'
2586
shlibpath_var=LD_LIBRARY_PATH
2587
hardcode_into_libs=yes
2588
if test "$with_gnu_ld" = yes; then
2589
sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2590
shlibpath_overrides_runpath=no
2592
sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2593
shlibpath_overrides_runpath=yes
2596
sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2600
sys_lib_dlsearch_path_spec='/usr/lib'
2605
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2606
soname_spec='${libname}${release}${shared_ext}$major'
2607
shlibpath_var=LD_LIBRARY_PATH
2614
AC_MSG_RESULT([$dynamic_linker])
2615
test "$dynamic_linker" = no && can_build_shared=no
2617
AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec],
2618
[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"])
2619
sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
2620
AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec],
2621
[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"])
2622
sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
2624
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2625
if test "$GCC" = yes; then
2626
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2628
])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2633
AC_DEFUN([_LT_AC_TAGCONFIG],
2634
[AC_REQUIRE([LT_AC_PROG_SED])dnl
2636
[AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2637
[include additional configurations @<:@automatic@:>@])],
2638
[tagnames="$withval"])
2640
if test -f "$ltmain" && test -n "$tagnames"; then
2641
if test ! -f "${ofile}"; then
2642
AC_MSG_WARN([output file `$ofile' does not exist])
2645
if test -z "$LTCC"; then
2646
eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2647
if test -z "$LTCC"; then
2648
AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2650
AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2653
if test -z "$LTCFLAGS"; then
2654
eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
2657
# Extract list of available tagged configurations in $ofile.
2658
# Note that this assumes the entire list is on one line.
2659
available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2661
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2662
for tagname in $tagnames; do
2664
# Check whether tagname contains only valid characters
2665
case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2667
*) AC_MSG_ERROR([invalid tag name: $tagname])
2671
if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2673
AC_MSG_ERROR([tag name \"$tagname\" already exists])
2676
# Update the list of available tags.
2677
if test -n "$tagname"; then
2678
echo appending configuration tag \"$tagname\" to $ofile
2682
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2683
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2684
(test "X$CXX" != "Xg++"))) ; then
2685
AC_LIBTOOL_LANG_CXX_CONFIG
2692
if test -n "$F77" && test "X$F77" != "Xno"; then
2693
AC_LIBTOOL_LANG_F77_CONFIG
2700
if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2701
AC_LIBTOOL_LANG_GCJ_CONFIG
2708
AC_LIBTOOL_LANG_RC_CONFIG
2712
AC_MSG_ERROR([Unsupported tag name: $tagname])
2716
# Append the new tag name to the list of available tags.
2717
if test -n "$tagname" ; then
2718
available_tags="$available_tags $tagname"
2724
# Now substitute the updated list of available tags.
2725
if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2726
mv "${ofile}T" "$ofile"
2730
AC_MSG_ERROR([unable to update list of available tagged configurations.])
2733
])# _LT_AC_TAGCONFIG
2738
# enable checks for dlopen support
2739
AC_DEFUN([AC_LIBTOOL_DLOPEN],
2740
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2741
])# AC_LIBTOOL_DLOPEN
2744
# AC_LIBTOOL_WIN32_DLL
2745
# --------------------
2746
# declare package support for building win32 DLLs
2747
AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2748
[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2749
])# AC_LIBTOOL_WIN32_DLL
2752
# AC_ENABLE_SHARED([DEFAULT])
2753
# ---------------------------
2754
# implement the --enable-shared flag
2755
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2756
AC_DEFUN([AC_ENABLE_SHARED],
2757
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2758
AC_ARG_ENABLE([shared],
2759
[AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2760
[build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2761
[p=${PACKAGE-default}
2763
yes) enable_shared=yes ;;
2764
no) enable_shared=no ;;
2767
# Look at the argument we got. We use all the common list separators.
2768
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2769
for pkg in $enableval; do
2771
if test "X$pkg" = "X$p"; then
2778
[enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2779
])# AC_ENABLE_SHARED
2784
# set the default shared flag to --disable-shared
2785
AC_DEFUN([AC_DISABLE_SHARED],
2786
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2787
AC_ENABLE_SHARED(no)
2788
])# AC_DISABLE_SHARED
2791
# AC_ENABLE_STATIC([DEFAULT])
2792
# ---------------------------
2793
# implement the --enable-static flag
2794
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2795
AC_DEFUN([AC_ENABLE_STATIC],
2796
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2797
AC_ARG_ENABLE([static],
2798
[AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2799
[build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2800
[p=${PACKAGE-default}
2802
yes) enable_static=yes ;;
2803
no) enable_static=no ;;
2806
# Look at the argument we got. We use all the common list separators.
2807
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2808
for pkg in $enableval; do
2810
if test "X$pkg" = "X$p"; then
2817
[enable_static=]AC_ENABLE_STATIC_DEFAULT)
2818
])# AC_ENABLE_STATIC
2823
# set the default static flag to --disable-static
2824
AC_DEFUN([AC_DISABLE_STATIC],
2825
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2826
AC_ENABLE_STATIC(no)
2827
])# AC_DISABLE_STATIC
2830
# AC_ENABLE_FAST_INSTALL([DEFAULT])
2831
# ---------------------------------
2832
# implement the --enable-fast-install flag
2833
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2834
AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2835
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2836
AC_ARG_ENABLE([fast-install],
2837
[AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2838
[optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2839
[p=${PACKAGE-default}
2841
yes) enable_fast_install=yes ;;
2842
no) enable_fast_install=no ;;
2844
enable_fast_install=no
2845
# Look at the argument we got. We use all the common list separators.
2846
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2847
for pkg in $enableval; do
2849
if test "X$pkg" = "X$p"; then
2850
enable_fast_install=yes
2856
[enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2857
])# AC_ENABLE_FAST_INSTALL
2860
# AC_DISABLE_FAST_INSTALL
2861
# -----------------------
2862
# set the default to --disable-fast-install
2863
AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2864
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2865
AC_ENABLE_FAST_INSTALL(no)
2866
])# AC_DISABLE_FAST_INSTALL
2869
# AC_LIBTOOL_PICMODE([MODE])
2870
# --------------------------
2871
# implement the --with-pic flag
2872
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
2873
AC_DEFUN([AC_LIBTOOL_PICMODE],
2874
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2875
pic_mode=ifelse($#,1,$1,default)
2876
])# AC_LIBTOOL_PICMODE
2881
# This is predefined starting with Autoconf 2.54, so this conditional
2882
# definition can be removed once we require Autoconf 2.54 or later.
2883
m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
2884
[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
2885
[if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2886
then ac_cv_prog_egrep='grep -E'
2887
else ac_cv_prog_egrep='egrep'
2889
EGREP=$ac_cv_prog_egrep
2894
# AC_PATH_TOOL_PREFIX
2895
# -------------------
2896
# find a file program which can recognize shared library
2897
AC_DEFUN([AC_PATH_TOOL_PREFIX],
2898
[AC_REQUIRE([AC_PROG_EGREP])dnl
2899
AC_MSG_CHECKING([for $1])
2900
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2902
[[\\/*] | ?:[\\/]*])
2903
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2906
lt_save_MAGIC_CMD="$MAGIC_CMD"
2907
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2908
dnl $ac_dummy forces splitting on constant user-supplied paths.
2909
dnl POSIX.2 word splitting is done only on the output of word expansions,
2910
dnl not every word. This closes a longstanding sh security hole.
2911
ac_dummy="ifelse([$2], , $PATH, [$2])"
2912
for ac_dir in $ac_dummy; do
2914
test -z "$ac_dir" && ac_dir=.
2915
if test -f $ac_dir/$1; then
2916
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2917
if test -n "$file_magic_test_file"; then
2918
case $deplibs_check_method in
2920
file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
2921
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2922
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2923
$EGREP "$file_magic_regex" > /dev/null; then
2928
*** Warning: the command libtool uses to detect shared libraries,
2929
*** $file_magic_cmd, produces output that libtool cannot recognize.
2930
*** The result is that libtool may fail to recognize shared libraries
2931
*** as such. This will affect the creation of libtool libraries that
2932
*** depend on shared libraries, but programs linked with such libtool
2933
*** libraries will work regardless of this problem. Nevertheless, you
2934
*** may want to report the problem to your system manager and/or to
2935
*** bug-libtool@gnu.org
2945
MAGIC_CMD="$lt_save_MAGIC_CMD"
2948
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2949
if test -n "$MAGIC_CMD"; then
2950
AC_MSG_RESULT($MAGIC_CMD)
2954
])# AC_PATH_TOOL_PREFIX
2959
# find a file program which can recognize a shared library
2960
AC_DEFUN([AC_PATH_MAGIC],
2961
[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2962
if test -z "$lt_cv_path_MAGIC_CMD"; then
2963
if test -n "$ac_tool_prefix"; then
2964
AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2974
# find the pathname to the GNU or non-GNU linker
2975
AC_DEFUN([AC_PROG_LD],
2976
[AC_ARG_WITH([gnu-ld],
2977
[AC_HELP_STRING([--with-gnu-ld],
2978
[assume the C compiler uses GNU ld @<:@default=no@:>@])],
2979
[test "$withval" = no || with_gnu_ld=yes],
2981
AC_REQUIRE([LT_AC_PROG_SED])dnl
2982
AC_REQUIRE([AC_PROG_CC])dnl
2983
AC_REQUIRE([AC_CANONICAL_HOST])dnl
2984
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2986
if test "$GCC" = yes; then
2987
# Check if gcc -print-prog-name=ld gives a path.
2988
AC_MSG_CHECKING([for ld used by $CC])
2991
# gcc leaves a trailing carriage return which upsets mingw
2992
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2994
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2997
# Accept absolute paths.
2998
[[\\/]]* | ?:[[\\/]]*)
2999
re_direlt='/[[^/]][[^/]]*/\.\./'
3000
# Canonicalize the pathname of ld
3001
ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
3002
while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3003
ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
3005
test -z "$LD" && LD="$ac_prog"
3008
# If it fails, then pretend we aren't using GCC.
3012
# If it is relative, then search for the first ld in PATH.
3016
elif test "$with_gnu_ld" = yes; then
3017
AC_MSG_CHECKING([for GNU ld])
3019
AC_MSG_CHECKING([for non-GNU ld])
3021
AC_CACHE_VAL(lt_cv_path_LD,
3022
[if test -z "$LD"; then
3023
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3024
for ac_dir in $PATH; do
3026
test -z "$ac_dir" && ac_dir=.
3027
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3028
lt_cv_path_LD="$ac_dir/$ac_prog"
3029
# Check to see if the program is GNU ld. I'd rather use --version,
3030
# but apparently some variants of GNU ld only accept -v.
3031
# Break only if it was the GNU/non-GNU ld that we prefer.
3032
case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3033
*GNU* | *'with BFD'*)
3034
test "$with_gnu_ld" != no && break
3037
test "$with_gnu_ld" != yes && break
3044
lt_cv_path_LD="$LD" # Let the user override the test with a path.
3047
if test -n "$LD"; then
3052
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3059
AC_DEFUN([AC_PROG_LD_GNU],
3060
[AC_REQUIRE([AC_PROG_EGREP])dnl
3061
AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3062
[# I'd rather use --version here, but apparently some GNU lds only accept -v.
3063
case `$LD -v 2>&1 </dev/null` in
3064
*GNU* | *'with BFD'*)
3065
lt_cv_prog_gnu_ld=yes
3068
lt_cv_prog_gnu_ld=no
3071
with_gnu_ld=$lt_cv_prog_gnu_ld
3075
# AC_PROG_LD_RELOAD_FLAG
3076
# ----------------------
3077
# find reload flag for linker
3078
# -- PORTME Some linkers may need a different reload flag.
3079
AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
3080
[AC_CACHE_CHECK([for $LD option to reload object files],
3081
lt_cv_ld_reload_flag,
3082
[lt_cv_ld_reload_flag='-r'])
3083
reload_flag=$lt_cv_ld_reload_flag
3084
case $reload_flag in
3086
*) reload_flag=" $reload_flag" ;;
3088
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3091
if test "$GCC" = yes; then
3092
reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3094
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3098
])# AC_PROG_LD_RELOAD_FLAG
3101
# AC_DEPLIBS_CHECK_METHOD
3102
# -----------------------
3103
# how to check for library dependencies
3104
# -- PORTME fill in with the dynamic library characteristics
3105
AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
3106
[AC_CACHE_CHECK([how to recognize dependent libraries],
3107
lt_cv_deplibs_check_method,
3108
[lt_cv_file_magic_cmd='$MAGIC_CMD'
3109
lt_cv_file_magic_test_file=
3110
lt_cv_deplibs_check_method='unknown'
3111
# Need to set the preceding variable on all platforms that support
3112
# interlibrary dependencies.
3113
# 'none' -- dependencies not supported.
3114
# `unknown' -- same as none, but documents that we really don't know.
3115
# 'pass_all' -- all dependencies passed with no checks.
3116
# 'test_compile' -- check by making test program.
3117
# 'file_magic [[regex]]' -- check by looking for files in library path
3118
# which responds to the $file_magic_cmd with a given extended regex.
3119
# If you have `file' or equivalent on your system and you're not sure
3120
# whether `pass_all' will *always* work, you probably want this one.
3124
lt_cv_deplibs_check_method=pass_all
3128
lt_cv_deplibs_check_method=pass_all
3132
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3133
lt_cv_file_magic_cmd='/usr/bin/file -L'
3134
lt_cv_file_magic_test_file=/shlib/libc.so
3138
# func_win32_libid is a shell function defined in ltmain.sh
3139
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3140
lt_cv_file_magic_cmd='func_win32_libid'
3144
# Base MSYS/MinGW do not provide the 'file' command needed by
3145
# func_win32_libid shell function, so use a weaker test based on 'objdump',
3146
# unless we find 'file', for example because we are cross-compiling.
3147
if ( file / ) >/dev/null 2>&1; then
3148
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3149
lt_cv_file_magic_cmd='func_win32_libid'
3151
lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3152
lt_cv_file_magic_cmd='$OBJDUMP -f'
3156
darwin* | rhapsody*)
3157
lt_cv_deplibs_check_method=pass_all
3160
freebsd* | dragonfly*)
3161
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3164
# Not sure whether the presence of OpenBSD here was a mistake.
3165
# Let's accept both of them until this is cleared up.
3166
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3167
lt_cv_file_magic_cmd=/usr/bin/file
3168
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3172
lt_cv_deplibs_check_method=pass_all
3177
lt_cv_deplibs_check_method=pass_all
3180
hpux10.20* | hpux11*)
3181
lt_cv_file_magic_cmd=/usr/bin/file
3184
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3185
lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3188
[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]']
3189
lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3192
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3193
lt_cv_file_magic_test_file=/usr/lib/libc.sl
3199
# PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3200
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3203
irix5* | irix6* | nonstopux*)
3205
*-32|*"-32 ") libmagic=32-bit;;
3206
*-n32|*"-n32 ") libmagic=N32;;
3207
*-64|*"-64 ") libmagic=64-bit;;
3208
*) libmagic=never-match;;
3210
lt_cv_deplibs_check_method=pass_all
3213
# This must be Linux ELF.
3214
linux* | k*bsd*-gnu)
3215
lt_cv_deplibs_check_method=pass_all
3219
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3220
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3222
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3227
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3228
lt_cv_file_magic_cmd=/usr/bin/file
3229
lt_cv_file_magic_test_file=/usr/lib/libnls.so
3233
lt_cv_deplibs_check_method=unknown
3237
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3238
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3240
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3244
osf3* | osf4* | osf5*)
3245
lt_cv_deplibs_check_method=pass_all
3249
lt_cv_deplibs_check_method=pass_all
3253
lt_cv_deplibs_check_method=pass_all
3257
case $host_vendor in
3259
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]]'
3260
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3263
lt_cv_deplibs_check_method=pass_all
3266
lt_cv_file_magic_cmd='/bin/file'
3267
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3270
lt_cv_file_magic_cmd='/bin/file'
3271
lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3272
lt_cv_file_magic_test_file=/lib/libc.so
3275
lt_cv_deplibs_check_method=pass_all
3278
lt_cv_deplibs_check_method=pass_all
3283
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3284
lt_cv_deplibs_check_method=pass_all
3288
file_magic_cmd=$lt_cv_file_magic_cmd
3289
deplibs_check_method=$lt_cv_deplibs_check_method
3290
test -z "$deplibs_check_method" && deplibs_check_method=unknown
3291
])# AC_DEPLIBS_CHECK_METHOD
3296
# find the pathname to a BSD-compatible name lister
3297
AC_DEFUN([AC_PROG_NM],
3298
[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
3299
[if test -n "$NM"; then
3300
# Let the user override the test.
3303
lt_nm_to_check="${ac_tool_prefix}nm"
3304
if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3305
lt_nm_to_check="$lt_nm_to_check nm"
3307
for lt_tmp_nm in $lt_nm_to_check; do
3308
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3309
for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3311
test -z "$ac_dir" && ac_dir=.
3312
tmp_nm="$ac_dir/$lt_tmp_nm"
3313
if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3314
# Check to see if the nm accepts a BSD-compat flag.
3315
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
3316
# nm: unknown option "B" ignored
3317
# Tru64's nm complains that /dev/null is an invalid object file
3318
case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3319
*/dev/null* | *'Invalid file or object type'*)
3320
lt_cv_path_NM="$tmp_nm -B"
3324
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3326
lt_cv_path_NM="$tmp_nm -p"
3330
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3331
continue # so that we can try to find one that supports BSD flags
3340
test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3348
# check for math library
3349
AC_DEFUN([AC_CHECK_LIBM],
3350
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3353
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3354
# These system don't have libm, or don't need it
3357
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3358
AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3361
AC_CHECK_LIB(m, cos, LIBM="-lm")
3367
# AC_LIBLTDL_CONVENIENCE([DIRECTORY])
3368
# -----------------------------------
3369
# sets LIBLTDL to the link flags for the libltdl convenience library and
3370
# LTDLINCL to the include flags for the libltdl header and adds
3371
# --enable-ltdl-convenience to the configure arguments. Note that
3372
# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3373
# it is assumed to be `libltdl'. LIBLTDL will be prefixed with
3374
# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
3375
# (note the single quotes!). If your package is not flat and you're not
3376
# using automake, define top_builddir and top_srcdir appropriately in
3378
AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3379
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3380
case $enable_ltdl_convenience in
3381
no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3382
"") enable_ltdl_convenience=yes
3383
ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3385
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3386
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3387
# For backwards non-gettext consistent compatibility...
3389
])# AC_LIBLTDL_CONVENIENCE
3392
# AC_LIBLTDL_INSTALLABLE([DIRECTORY])
3393
# -----------------------------------
3394
# sets LIBLTDL to the link flags for the libltdl installable library and
3395
# LTDLINCL to the include flags for the libltdl header and adds
3396
# --enable-ltdl-install to the configure arguments. Note that
3397
# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3398
# and an installed libltdl is not found, it is assumed to be `libltdl'.
3399
# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
3400
# '${top_srcdir}/' (note the single quotes!). If your package is not
3401
# flat and you're not using automake, define top_builddir and top_srcdir
3402
# appropriately in the Makefiles.
3403
# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3404
AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3405
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3406
AC_CHECK_LIB(ltdl, lt_dlinit,
3407
[test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3408
[if test x"$enable_ltdl_install" = xno; then
3409
AC_MSG_WARN([libltdl not installed, but installation disabled])
3411
enable_ltdl_install=yes
3414
if test x"$enable_ltdl_install" = x"yes"; then
3415
ac_configure_args="$ac_configure_args --enable-ltdl-install"
3416
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3417
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3419
ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
3423
# For backwards non-gettext consistent compatibility...
3425
])# AC_LIBLTDL_INSTALLABLE
3430
# enable support for C++ libraries
3431
AC_DEFUN([AC_LIBTOOL_CXX],
3432
[AC_REQUIRE([_LT_AC_LANG_CXX])
3438
AC_DEFUN([_LT_AC_LANG_CXX],
3439
[AC_REQUIRE([AC_PROG_CXX])
3440
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3441
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
3444
# _LT_AC_PROG_CXXCPP
3445
# ------------------
3446
AC_DEFUN([_LT_AC_PROG_CXXCPP],
3448
AC_REQUIRE([AC_PROG_CXX])
3449
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
3450
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
3451
(test "X$CXX" != "Xg++"))) ; then
3454
])# _LT_AC_PROG_CXXCPP
3458
# enable support for Fortran 77 libraries
3459
AC_DEFUN([AC_LIBTOOL_F77],
3460
[AC_REQUIRE([_LT_AC_LANG_F77])
3466
AC_DEFUN([_LT_AC_LANG_F77],
3467
[AC_REQUIRE([AC_PROG_F77])
3468
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
3474
# enable support for GCJ libraries
3475
AC_DEFUN([AC_LIBTOOL_GCJ],
3476
[AC_REQUIRE([_LT_AC_LANG_GCJ])
3482
AC_DEFUN([_LT_AC_LANG_GCJ],
3483
[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
3484
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
3485
[AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
3486
[ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
3487
[ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
3488
[AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
3489
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
3495
# enable support for Windows resource files
3496
AC_DEFUN([AC_LIBTOOL_RC],
3497
[AC_REQUIRE([LT_AC_PROG_RC])
3498
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
3502
# AC_LIBTOOL_LANG_C_CONFIG
3503
# ------------------------
3504
# Ensure that the configuration vars for the C compiler are
3505
# suitably defined. Those variables are subsequently used by
3506
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3507
AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
3508
AC_DEFUN([_LT_AC_LANG_C_CONFIG],
3512
# Source file extension for C test sources.
3515
# Object file extension for compiled C test sources.
3517
_LT_AC_TAGVAR(objext, $1)=$objext
3519
# Code to be used in simple compile tests
3520
lt_simple_compile_test_code="int some_variable = 0;"
3522
# Code to be used in simple link tests
3523
lt_simple_link_test_code='int main(){return(0);}'
3527
# save warnings/boilerplate of simple test code
3528
_LT_COMPILER_BOILERPLATE
3529
_LT_LINKER_BOILERPLATE
3531
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
3532
AC_LIBTOOL_PROG_COMPILER_PIC($1)
3533
AC_LIBTOOL_PROG_CC_C_O($1)
3534
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3535
AC_LIBTOOL_PROG_LD_SHLIBS($1)
3536
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3537
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3538
AC_LIBTOOL_SYS_LIB_STRIP
3539
AC_LIBTOOL_DLOPEN_SELF
3541
# Report which library types will actually be built
3542
AC_MSG_CHECKING([if libtool supports shared libraries])
3543
AC_MSG_RESULT([$can_build_shared])
3545
AC_MSG_CHECKING([whether to build shared libraries])
3546
test "$can_build_shared" = "no" && enable_shared=no
3548
# On AIX, shared libraries and static libraries use the same namespace, and
3549
# are all built from PIC.
3552
test "$enable_shared" = yes && enable_static=no
3553
if test -n "$RANLIB"; then
3554
archive_cmds="$archive_cmds~\$RANLIB \$lib"
3555
postinstall_cmds='$RANLIB $lib'
3560
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3561
test "$enable_shared" = yes && enable_static=no
3565
AC_MSG_RESULT([$enable_shared])
3567
AC_MSG_CHECKING([whether to build static libraries])
3568
# Make sure either enable_shared or enable_static is yes.
3569
test "$enable_shared" = yes || enable_static=yes
3570
AC_MSG_RESULT([$enable_static])
3572
AC_LIBTOOL_CONFIG($1)
3576
])# AC_LIBTOOL_LANG_C_CONFIG
3579
# AC_LIBTOOL_LANG_CXX_CONFIG
3580
# --------------------------
3581
# Ensure that the configuration vars for the C compiler are
3582
# suitably defined. Those variables are subsequently used by
3583
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3584
AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
3585
AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
3587
AC_REQUIRE([AC_PROG_CXX])
3588
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3590
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3591
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
3592
_LT_AC_TAGVAR(always_export_symbols, $1)=no
3593
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3594
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3595
_LT_AC_TAGVAR(hardcode_direct, $1)=no
3596
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3597
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3598
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3599
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3600
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3601
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
3602
_LT_AC_TAGVAR(module_cmds, $1)=
3603
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
3604
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3605
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3606
_LT_AC_TAGVAR(no_undefined_flag, $1)=
3607
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3608
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3610
# Dependencies to place before and after the object being linked:
3611
_LT_AC_TAGVAR(predep_objects, $1)=
3612
_LT_AC_TAGVAR(postdep_objects, $1)=
3613
_LT_AC_TAGVAR(predeps, $1)=
3614
_LT_AC_TAGVAR(postdeps, $1)=
3615
_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3616
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
3618
# Source file extension for C++ test sources.
3621
# Object file extension for compiled C++ test sources.
3623
_LT_AC_TAGVAR(objext, $1)=$objext
3625
# Code to be used in simple compile tests
3626
lt_simple_compile_test_code="int some_variable = 0;"
3628
# Code to be used in simple link tests
3629
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
3631
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3634
# save warnings/boilerplate of simple test code
3635
_LT_COMPILER_BOILERPLATE
3636
_LT_LINKER_BOILERPLATE
3638
# Allow CC to be a program name with arguments.
3643
lt_save_with_gnu_ld=$with_gnu_ld
3644
lt_save_path_LD=$lt_cv_path_LD
3645
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3646
lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3648
$as_unset lt_cv_prog_gnu_ld
3650
if test -n "${lt_cv_path_LDCXX+set}"; then
3651
lt_cv_path_LD=$lt_cv_path_LDCXX
3653
$as_unset lt_cv_path_LD
3655
test -z "${LDCXX+set}" || LD=$LDCXX
3658
_LT_AC_TAGVAR(compiler, $1)=$CC
3659
_LT_CC_BASENAME([$compiler])
3661
# We don't want -fno-exception wen compiling C++ code, so set the
3662
# no_builtin_flag separately
3663
if test "$GXX" = yes; then
3664
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3666
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3669
if test "$GXX" = yes; then
3670
# Set up default GNU C++ configuration
3674
# Check if GNU C++ uses GNU ld as the underlying linker, since the
3675
# archiving commands below assume that GNU ld is being used.
3676
if test "$with_gnu_ld" = yes; then
3677
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3678
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3680
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3681
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3683
# If archive_cmds runs LD, not CC, wlarc should be empty
3684
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3685
# investigate it a little bit more. (MM)
3688
# ancient GNU ld didn't support --whole-archive et. al.
3689
if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3690
grep 'no-whole-archive' > /dev/null; then
3691
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3693
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3699
# A generic and very simple default shared library creation
3700
# command for GNU C++ for the case where it uses the native
3701
# linker, instead of GNU ld. If possible, this setting should
3702
# overridden to take advantage of the native linker features on
3703
# the platform it is being used on.
3704
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3707
# Commands to make compiler produce verbose output that lists
3708
# what "hidden" libraries, object files and flags are used when
3709
# linking a shared library.
3710
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3718
# PORTME: fill in a description of your system's C++ link characteristics
3719
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3720
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
3723
# FIXME: insert proper C++ library support
3724
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3727
if test "$host_cpu" = ia64; then
3728
# On IA64, the linker does run time linking by default, so we don't
3729
# have to do anything special.
3730
aix_use_runtimelinking=no
3731
exp_sym_flag='-Bexport'
3734
aix_use_runtimelinking=no
3736
# Test if we are trying to use run time linking or normal
3737
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
3738
# need to do runtime linking.
3739
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
3740
for ld_flag in $LDFLAGS; do
3743
aix_use_runtimelinking=yes
3751
exp_sym_flag='-bexport'
3752
no_entry_flag='-bnoentry'
3755
# When large executables or shared objects are built, AIX ld can
3756
# have problems creating the table of contents. If linking a library
3757
# or program results in "error TOC overflow" add -mminimal-toc to
3758
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
3759
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3761
_LT_AC_TAGVAR(archive_cmds, $1)=''
3762
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
3763
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3764
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3766
if test "$GXX" = yes; then
3767
case $host_os in aix4.[[012]]|aix4.[[012]].*)
3768
# We only want to do this on AIX 4.2 and lower, the check
3769
# below for broken collect2 doesn't work under 4.3+
3770
collect2name=`${CC} -print-prog-name=collect2`
3771
if test -f "$collect2name" && \
3772
strings "$collect2name" | grep resolve_lib_name >/dev/null
3774
# We have reworked collect2
3777
# We have old collect2
3778
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3779
# It fails to find uninstalled libraries when the uninstalled
3780
# path is not listed in the libpath. Setting hardcode_minus_L
3781
# to unsupported forces relinking
3782
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3783
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3784
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3788
shared_flag='-shared'
3789
if test "$aix_use_runtimelinking" = yes; then
3790
shared_flag="$shared_flag "'${wl}-G'
3794
if test "$host_cpu" = ia64; then
3795
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3796
# chokes on -Wl,-G. The following line is correct:
3799
if test "$aix_use_runtimelinking" = yes; then
3800
shared_flag='${wl}-G'
3802
shared_flag='${wl}-bM:SRE'
3807
# It seems that -bexpall does not export symbols beginning with
3808
# underscore (_), so it is better to generate a list of symbols to export.
3809
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
3810
if test "$aix_use_runtimelinking" = yes; then
3811
# Warning - without using the other runtime loading flags (-brtl),
3812
# -berok will link without error, but may produce a broken library.
3813
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3814
# Determine the default libpath from the value encoded in an empty executable.
3815
_LT_AC_SYS_LIBPATH_AIX
3816
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3818
_LT_AC_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 "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3820
if test "$host_cpu" = ia64; then
3821
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3822
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3823
_LT_AC_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"
3825
# Determine the default libpath from the value encoded in an empty executable.
3826
_LT_AC_SYS_LIBPATH_AIX
3827
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3828
# Warning - without using the other run time loading flags,
3829
# -berok will link without error, but may produce a broken library.
3830
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3831
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3832
# Exported symbols can be pulled into shared objects from archives
3833
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
3834
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3835
# This is similar to how AIX traditionally builds its shared libraries.
3836
_LT_AC_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'
3842
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
3843
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3844
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
3845
# support --undefined. This deserves some investigation. FIXME
3846
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
3848
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3853
case $cc_basename in
3855
# FIXME: insert proper C++ library support
3856
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3861
cygwin* | mingw* | pw32*)
3862
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3863
# as there is no search path for DLLs.
3864
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3865
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3866
_LT_AC_TAGVAR(always_export_symbols, $1)=no
3867
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3869
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3870
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
3871
# If the export-symbols file already is a .def file (1st line
3872
# is EXPORTS), use it as is; otherwise, prepend...
3873
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3874
cp $export_symbols $output_objdir/$soname.def;
3876
echo EXPORTS > $output_objdir/$soname.def;
3877
cat $export_symbols >> $output_objdir/$soname.def;
3879
$CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
3881
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3884
darwin* | rhapsody*)
3885
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3886
_LT_AC_TAGVAR(hardcode_direct, $1)=no
3887
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3888
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3889
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
3890
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3891
_LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
3892
if test "$GXX" = yes ; then
3893
output_verbose_link_cmd='echo'
3894
_LT_AC_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}"
3895
_LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
3896
_LT_AC_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}"
3897
_LT_AC_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}"
3898
if test "$lt_cv_apple_cc_single_mod" != "yes"; then
3899
_LT_AC_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}"
3900
_LT_AC_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}"
3903
case $cc_basename in
3905
output_verbose_link_cmd='echo'
3906
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
3907
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3908
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
3909
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3910
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3913
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3920
case $cc_basename in
3922
# FIXME: insert proper C++ library support
3923
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3926
# Green Hills C++ Compiler
3927
# FIXME: insert proper C++ library support
3928
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3931
# FIXME: insert proper C++ library support
3932
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3937
# C++ shared libraries reported to be fairly broken before switch to ELF
3938
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3941
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3943
freebsd* | dragonfly*)
3944
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3946
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
3951
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3952
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3953
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3954
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
3955
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3956
# but as the default
3957
# location of the library.
3959
case $cc_basename in
3961
# FIXME: insert proper C++ library support
3962
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3965
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3966
# Commands to make compiler produce verbose output that lists
3967
# what "hidden" libraries, object files and flags are used when
3968
# linking a shared library.
3970
# There doesn't appear to be a way to prevent this compiler from
3971
# explicitly linking system object files so we need to strip them
3972
# from the output so that they don't get included in the library
3974
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3977
if test "$GXX" = yes; then
3978
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3980
# FIXME: insert proper C++ library support
3981
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3987
if test $with_gnu_ld = no; then
3988
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3989
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3994
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4000
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4001
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4004
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4005
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4006
# but as the default
4007
# location of the library.
4011
case $cc_basename in
4013
# FIXME: insert proper C++ library support
4014
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4019
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4022
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4025
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4028
# Commands to make compiler produce verbose output that lists
4029
# what "hidden" libraries, object files and flags are used when
4030
# linking a shared library.
4032
# There doesn't appear to be a way to prevent this compiler from
4033
# explicitly linking system object files so we need to strip them
4034
# from the output so that they don't get included in the library
4036
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4039
if test "$GXX" = yes; then
4040
if test $with_gnu_ld = no; then
4043
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4046
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4049
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4054
# FIXME: insert proper C++ library support
4055
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4061
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4062
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4063
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4064
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4065
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4066
# Instead, shared libraries are loaded at an image base (0x10000000 by
4067
# default) and relocated if they conflict, which is a slow very memory
4068
# consuming and fragmenting process. To avoid this, we pick a random,
4069
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4070
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
4071
_LT_AC_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'
4072
_LT_AC_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'
4075
case $cc_basename in
4078
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4080
# Archives containing C++ object files must be created using
4081
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
4082
# necessary to make sure instantiated templates are included
4084
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
4087
if test "$GXX" = yes; then
4088
if test "$with_gnu_ld" = no; then
4089
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4091
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
4094
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4097
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4098
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4100
linux* | k*bsd*-gnu)
4101
case $cc_basename in
4103
# Kuck and Associates, Inc. (KAI) C++ Compiler
4105
# KCC will only create a shared library if the output file
4106
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4107
# to its proper name (with version) after linking.
4108
_LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4109
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
4110
# Commands to make compiler produce verbose output that lists
4111
# what "hidden" libraries, object files and flags are used when
4112
# linking a shared library.
4114
# There doesn't appear to be a way to prevent this compiler from
4115
# explicitly linking system object files so we need to strip them
4116
# from the output so that they don't get included in the library
4118
output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4120
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
4121
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4123
# Archives containing C++ object files must be created using
4124
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
4125
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4130
# version 8.0 and above of icpc choke on multiply defined symbols
4131
# if we add $predep_objects and $postdep_objects, however 7.1 and
4132
# earlier do not add the objects themselves.
4133
case `$CC -V 2>&1` in
4135
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4136
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4138
*) # Version 8.0 or newer
4141
ia64*) tmp_idyn=' -i_dynamic';;
4143
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4144
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4147
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4148
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4149
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4150
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
4153
# Portland Group C++ compiler
4154
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
4155
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
4157
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
4158
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4159
_LT_AC_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'
4163
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4164
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
4166
runpath_var=LD_RUN_PATH
4167
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4168
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4170
# Commands to make compiler produce verbose output that lists
4171
# what "hidden" libraries, object files and flags are used when
4172
# linking a shared library.
4174
# There doesn't appear to be a way to prevent this compiler from
4175
# explicitly linking system object files so we need to strip them
4176
# from the output so that they don't get included in the library
4178
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4181
case `$CC -V 2>&1 | sed 5q` in
4184
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4185
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4186
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
4187
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4188
_LT_AC_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'
4190
# Not sure whether something based on
4191
# $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
4193
output_verbose_link_cmd='echo'
4195
# Archives containing C++ object files must be created using
4196
# "CC -xar", where "CC" is the Sun C++ compiler. This is
4197
# necessary to make sure instantiated templates are included
4199
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4206
# FIXME: insert proper C++ library support
4207
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4210
# FIXME: insert proper C++ library support
4211
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4214
case $cc_basename in
4216
# FIXME: insert proper C++ library support
4217
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4220
# FIXME: insert proper C++ library support
4221
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4226
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4227
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
4229
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4230
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4231
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4233
# Workaround some broken pre-1.5 toolchains
4234
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
4237
# C++ shared libraries are fairly broken
4238
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4241
if test -f /usr/libexec/ld.so; then
4242
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4243
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4244
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
4245
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4246
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4247
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
4248
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4249
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4251
output_verbose_link_cmd='echo'
4253
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4257
case $cc_basename in
4259
# Kuck and Associates, Inc. (KAI) C++ Compiler
4261
# KCC will only create a shared library if the output file
4262
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4263
# to its proper name (with version) after linking.
4264
_LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4266
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4267
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4269
# Archives containing C++ object files must be created using
4270
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
4271
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4275
# Rational C++ 2.4.1
4276
# FIXME: insert proper C++ library support
4277
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4280
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4281
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4283
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4284
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4286
# Commands to make compiler produce verbose output that lists
4287
# what "hidden" libraries, object files and flags are used when
4288
# linking a shared library.
4290
# There doesn't appear to be a way to prevent this compiler from
4291
# explicitly linking system object files so we need to strip them
4292
# from the output so that they don't get included in the library
4294
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4297
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4298
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4299
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4301
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4302
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4304
# Commands to make compiler produce verbose output that lists
4305
# what "hidden" libraries, object files and flags are used when
4306
# linking a shared library.
4307
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4310
# FIXME: insert proper C++ library support
4311
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4317
case $cc_basename in
4319
# Kuck and Associates, Inc. (KAI) C++ Compiler
4321
# KCC will only create a shared library if the output file
4322
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4323
# to its proper name (with version) after linking.
4324
_LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4326
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4327
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4329
# Archives containing C++ object files must be created using
4330
# the KAI C++ compiler.
4331
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
4334
# Rational C++ 2.4.1
4335
# FIXME: insert proper C++ library support
4336
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4339
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
4340
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4341
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
4342
echo "-hidden">> $lib.exp~
4343
$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~
4346
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4347
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4349
# Commands to make compiler produce verbose output that lists
4350
# what "hidden" libraries, object files and flags are used when
4351
# linking a shared library.
4353
# There doesn't appear to be a way to prevent this compiler from
4354
# explicitly linking system object files so we need to strip them
4355
# from the output so that they don't get included in the library
4357
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4360
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4361
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4362
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4364
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4365
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4367
# Commands to make compiler produce verbose output that lists
4368
# what "hidden" libraries, object files and flags are used when
4369
# linking a shared library.
4370
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4373
# FIXME: insert proper C++ library support
4374
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4380
# FIXME: insert proper C++ library support
4381
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4384
case $cc_basename in
4387
# FIXME: insert proper C++ library support
4388
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4392
# FIXME: insert proper C++ library support
4393
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4396
# FIXME: insert proper C++ library support
4397
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4402
case $cc_basename in
4404
# Sun C++ 4.2, 5.x and Centerline C++
4405
_LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
4406
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4407
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4408
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4409
$CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4411
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4412
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4414
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
4416
# The compiler driver will combine and reorder linker options,
4417
# but understands `-z linker_flag'.
4418
# Supported since Solaris 2.6 (maybe 2.5.1?)
4419
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
4422
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4424
output_verbose_link_cmd='echo'
4426
# Archives containing C++ object files must be created using
4427
# "CC -xar", where "CC" is the Sun C++ compiler. This is
4428
# necessary to make sure instantiated templates are included
4430
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4433
# Green Hills C++ Compiler
4434
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4436
# The C++ compiler must be used to create the archive.
4437
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
4440
# GNU C++ compiler with Solaris linker
4441
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4442
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
4443
if $CC --version | grep -v '^2\.7' > /dev/null; then
4444
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4445
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4446
$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4448
# Commands to make compiler produce verbose output that lists
4449
# what "hidden" libraries, object files and flags are used when
4450
# linking a shared library.
4451
output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4453
# g++ 2.7 appears to require `-G' NOT `-shared' on this
4455
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4456
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4457
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4459
# Commands to make compiler produce verbose output that lists
4460
# what "hidden" libraries, object files and flags are used when
4461
# linking a shared library.
4462
output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4465
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
4467
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
4469
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
4476
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
4477
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4478
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4479
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4480
runpath_var='LD_RUN_PATH'
4482
case $cc_basename in
4484
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4485
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4488
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4489
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4493
sysv5* | sco3.2v5* | sco5v6*)
4494
# Note: We can NOT use -z defs as we might desire, because we do not
4495
# link with -lc, and that would cause any symbols used from libc to
4496
# always be unresolved, which means just about no library would
4497
# ever link correctly. If we're not using GNU ld we use -z text
4498
# though, which does catch some bad symbols but isn't as heavy-handed
4500
# For security reasons, it is highly recommended that you always
4501
# use absolute paths for naming shared libraries, and exclude the
4502
# DT_RUNPATH tag from executables and libraries. But doing so
4503
# requires that you compile everything twice, which is a pain.
4504
# So that behaviour is only enabled if SCOABSPATH is set to a
4505
# non-empty value in the environment. Most likely only useful for
4506
# creating official distributions of packages.
4507
# This is a hack until libtool officially supports absolute path
4508
# names for shared libraries.
4509
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4510
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
4511
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4512
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4513
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
4514
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
4515
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4516
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
4517
runpath_var='LD_RUN_PATH'
4519
case $cc_basename in
4521
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4522
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4525
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4526
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4531
case $cc_basename in
4533
# NonStop-UX NCC 3.20
4534
# FIXME: insert proper C++ library support
4535
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4538
# FIXME: insert proper C++ library support
4539
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4544
# FIXME: insert proper C++ library support
4545
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4548
# FIXME: insert proper C++ library support
4549
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4552
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
4553
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4555
_LT_AC_TAGVAR(GCC, $1)="$GXX"
4556
_LT_AC_TAGVAR(LD, $1)="$LD"
4558
AC_LIBTOOL_POSTDEP_PREDEP($1)
4559
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4560
AC_LIBTOOL_PROG_CC_C_O($1)
4561
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4562
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4563
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4564
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4566
AC_LIBTOOL_CONFIG($1)
4573
with_gnu_ldcxx=$with_gnu_ld
4574
with_gnu_ld=$lt_save_with_gnu_ld
4575
lt_cv_path_LDCXX=$lt_cv_path_LD
4576
lt_cv_path_LD=$lt_save_path_LD
4577
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
4578
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
4579
])# AC_LIBTOOL_LANG_CXX_CONFIG
4581
# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
4582
# ------------------------------------
4583
# Figure out "hidden" library dependencies from verbose
4584
# compiler output when linking a shared library.
4585
# Parse the compiler output and extract the necessary
4586
# objects, libraries and library flags.
4587
AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],
4588
[AC_REQUIRE([LT_AC_PROG_SED])dnl
4589
dnl we can't use the lt_simple_compile_test_code here,
4590
dnl because it contains code intended for an executable,
4591
dnl not a library. It's possible we should let each
4592
dnl tag define a new lt_????_link_test_code variable,
4593
dnl but it's only used here...
4594
ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
4596
void foo (void) { a = 0; }
4598
],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
4602
Foo (void) { a = 0; }
4607
],[$1],[F77],[cat > conftest.$ac_ext <<EOF
4615
],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
4618
public void bar (void) {
4624
dnl Parse the compiler output and extract the necessary
4625
dnl objects, libraries and library flags.
4626
if AC_TRY_EVAL(ac_compile); then
4627
# Parse the compiler output and extract the necessary
4628
# objects, libraries and library flags.
4630
# Sentinel used to keep track of whether or not we are before
4631
# the conftest object file.
4632
pre_test_object_deps_done=no
4634
# The `*' in the case matches for architectures that use `case' in
4635
# $output_verbose_cmd can trigger glob expansion during the loop
4636
# eval without this substitution.
4637
output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
4639
for p in `eval $output_verbose_link_cmd`; do
4643
# Some compilers place space between "-{L,R}" and the path.
4646
|| test $p = "-R"; then
4653
if test "$pre_test_object_deps_done" = no; then
4656
# Internal compiler library paths should come after those
4657
# provided the user. The postdeps already come after the
4658
# user supplied libs so there is no need to process them.
4659
if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4660
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
4662
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
4665
# The "-l" case would never come before the object being
4666
# linked, so don't bother handling this case.
4669
if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
4670
_LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
4672
_LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
4678
# This assumes that the test object file only shows up
4679
# once in the compiler output.
4680
if test "$p" = "conftest.$objext"; then
4681
pre_test_object_deps_done=yes
4685
if test "$pre_test_object_deps_done" = no; then
4686
if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
4687
_LT_AC_TAGVAR(predep_objects, $1)="$p"
4689
_LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
4692
if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
4693
_LT_AC_TAGVAR(postdep_objects, $1)="$p"
4695
_LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
4700
*) ;; # Ignore the rest.
4708
echo "libtool.m4: error: problem compiling $1 test program"
4711
$rm -f confest.$objext
4713
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
4714
if test -n "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4715
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_AC_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
4718
# PORTME: override above test on systems where it is broken
4722
# Interix 3.5 installs completely hosed .la files for C++, so rather than
4723
# hack all around it, let's just trust "g++" to DTRT.
4724
_LT_AC_TAGVAR(predep_objects,$1)=
4725
_LT_AC_TAGVAR(postdep_objects,$1)=
4726
_LT_AC_TAGVAR(postdeps,$1)=
4730
case `$CC -V 2>&1 | sed 5q` in
4734
# The more standards-conforming stlport4 library is
4735
# incompatible with the Cstd library. Avoid specifying
4736
# it if it's in CXXFLAGS. Ignore libCrun as
4737
# -library=stlport4 depends on it.
4738
case " $CXX $CXXFLAGS " in
4739
*" -library=stlport4 "*)
4740
solaris_use_stlport4=yes
4743
if test "$solaris_use_stlport4" != yes; then
4744
_LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
4751
case $cc_basename in
4753
# The more standards-conforming stlport4 library is
4754
# incompatible with the Cstd library. Avoid specifying
4755
# it if it's in CXXFLAGS. Ignore libCrun as
4756
# -library=stlport4 depends on it.
4757
case " $CXX $CXXFLAGS " in
4758
*" -library=stlport4 "*)
4759
solaris_use_stlport4=yes
4763
# Adding this requires a known-good setup of shared libraries for
4764
# Sun compiler versions before 5.6, else PIC objects from an old
4765
# archive will be linked into the output, leading to subtle bugs.
4766
if test "$solaris_use_stlport4" != yes; then
4767
_LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
4774
case " $_LT_AC_TAGVAR(postdeps, $1) " in
4775
*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4777
])# AC_LIBTOOL_POSTDEP_PREDEP
4779
# AC_LIBTOOL_LANG_F77_CONFIG
4780
# --------------------------
4781
# Ensure that the configuration vars for the C compiler are
4782
# suitably defined. Those variables are subsequently used by
4783
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4784
AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4785
AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4786
[AC_REQUIRE([AC_PROG_F77])
4787
AC_LANG_PUSH(Fortran 77)
4789
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4790
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
4791
_LT_AC_TAGVAR(always_export_symbols, $1)=no
4792
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
4793
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
4794
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4795
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
4796
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4797
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
4798
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
4799
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
4800
_LT_AC_TAGVAR(module_cmds, $1)=
4801
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
4802
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
4803
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4804
_LT_AC_TAGVAR(no_undefined_flag, $1)=
4805
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
4806
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4808
# Source file extension for f77 test sources.
4811
# Object file extension for compiled f77 test sources.
4813
_LT_AC_TAGVAR(objext, $1)=$objext
4815
# Code to be used in simple compile tests
4816
lt_simple_compile_test_code="\
4822
# Code to be used in simple link tests
4823
lt_simple_link_test_code="\
4828
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4831
# save warnings/boilerplate of simple test code
4832
_LT_COMPILER_BOILERPLATE
4833
_LT_LINKER_BOILERPLATE
4835
# Allow CC to be a program name with arguments.
4839
_LT_AC_TAGVAR(compiler, $1)=$CC
4840
_LT_CC_BASENAME([$compiler])
4842
AC_MSG_CHECKING([if libtool supports shared libraries])
4843
AC_MSG_RESULT([$can_build_shared])
4845
AC_MSG_CHECKING([whether to build shared libraries])
4846
test "$can_build_shared" = "no" && enable_shared=no
4848
# On AIX, shared libraries and static libraries use the same namespace, and
4849
# are all built from PIC.
4852
test "$enable_shared" = yes && enable_static=no
4853
if test -n "$RANLIB"; then
4854
archive_cmds="$archive_cmds~\$RANLIB \$lib"
4855
postinstall_cmds='$RANLIB $lib'
4859
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
4860
test "$enable_shared" = yes && enable_static=no
4864
AC_MSG_RESULT([$enable_shared])
4866
AC_MSG_CHECKING([whether to build static libraries])
4867
# Make sure either enable_shared or enable_static is yes.
4868
test "$enable_shared" = yes || enable_static=yes
4869
AC_MSG_RESULT([$enable_static])
4871
_LT_AC_TAGVAR(GCC, $1)="$G77"
4872
_LT_AC_TAGVAR(LD, $1)="$LD"
4874
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4875
AC_LIBTOOL_PROG_CC_C_O($1)
4876
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4877
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4878
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4879
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4881
AC_LIBTOOL_CONFIG($1)
4885
])# AC_LIBTOOL_LANG_F77_CONFIG
4888
# AC_LIBTOOL_LANG_GCJ_CONFIG
4889
# --------------------------
4890
# Ensure that the configuration vars for the C compiler are
4891
# suitably defined. Those variables are subsequently used by
4892
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4893
AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4894
AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4897
# Source file extension for Java test sources.
4900
# Object file extension for compiled Java test sources.
4902
_LT_AC_TAGVAR(objext, $1)=$objext
4904
# Code to be used in simple compile tests
4905
lt_simple_compile_test_code="class foo {}"
4907
# Code to be used in simple link tests
4908
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
4910
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4913
# save warnings/boilerplate of simple test code
4914
_LT_COMPILER_BOILERPLATE
4915
_LT_LINKER_BOILERPLATE
4917
# Allow CC to be a program name with arguments.
4921
_LT_AC_TAGVAR(compiler, $1)=$CC
4922
_LT_CC_BASENAME([$compiler])
4924
# GCJ did not exist at the time GCC didn't implicitly link libc in.
4925
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4927
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4929
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4930
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4931
AC_LIBTOOL_PROG_CC_C_O($1)
4932
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4933
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4934
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4935
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4937
AC_LIBTOOL_CONFIG($1)
4941
])# AC_LIBTOOL_LANG_GCJ_CONFIG
4944
# AC_LIBTOOL_LANG_RC_CONFIG
4945
# -------------------------
4946
# Ensure that the configuration vars for the Windows resource compiler are
4947
# suitably defined. Those variables are subsequently used by
4948
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4949
AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4950
AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4953
# Source file extension for RC test sources.
4956
# Object file extension for compiled RC test sources.
4958
_LT_AC_TAGVAR(objext, $1)=$objext
4960
# Code to be used in simple compile tests
4961
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
4963
# Code to be used in simple link tests
4964
lt_simple_link_test_code="$lt_simple_compile_test_code"
4966
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4969
# save warnings/boilerplate of simple test code
4970
_LT_COMPILER_BOILERPLATE
4971
_LT_LINKER_BOILERPLATE
4973
# Allow CC to be a program name with arguments.
4977
_LT_AC_TAGVAR(compiler, $1)=$CC
4978
_LT_CC_BASENAME([$compiler])
4979
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4981
AC_LIBTOOL_CONFIG($1)
4985
])# AC_LIBTOOL_LANG_RC_CONFIG
4988
# AC_LIBTOOL_CONFIG([TAGNAME])
4989
# ----------------------------
4990
# If TAGNAME is not passed, then create an initial libtool script
4991
# with a default configuration from the untagged config vars. Otherwise
4992
# add code to config.status for appending the configuration named by
4993
# TAGNAME from the matching tagged config vars.
4994
AC_DEFUN([AC_LIBTOOL_CONFIG],
4995
[# The else clause should only fire when bootstrapping the
4996
# libtool distribution, otherwise you forgot to ship ltmain.sh
4997
# with your package, and you will get complaints that there are
4998
# no rules to generate ltmain.sh.
4999
if test -f "$ltmain"; then
5000
# See if we are running on zsh, and set the options which allow our commands through
5001
# without removal of \ escapes.
5002
if test -n "${ZSH_VERSION+set}" ; then
5003
setopt NO_GLOB_SUBST
5005
# Now quote all the things that may contain metacharacters while being
5006
# careful not to overquote the AC_SUBSTed values. We take copies of the
5007
# variables and quote the copies for generation of the libtool script.
5008
for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
5010
libname_spec library_names_spec soname_spec extract_expsyms_cmds \
5011
old_striplib striplib file_magic_cmd finish_cmds finish_eval \
5012
deplibs_check_method reload_flag reload_cmds need_locks \
5013
lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
5014
lt_cv_sys_global_symbol_to_c_name_address \
5015
sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
5016
old_postinstall_cmds old_postuninstall_cmds \
5017
_LT_AC_TAGVAR(compiler, $1) \
5018
_LT_AC_TAGVAR(CC, $1) \
5019
_LT_AC_TAGVAR(LD, $1) \
5020
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
5021
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
5022
_LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
5023
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
5024
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
5025
_LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
5026
_LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
5027
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
5028
_LT_AC_TAGVAR(old_archive_cmds, $1) \
5029
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
5030
_LT_AC_TAGVAR(predep_objects, $1) \
5031
_LT_AC_TAGVAR(postdep_objects, $1) \
5032
_LT_AC_TAGVAR(predeps, $1) \
5033
_LT_AC_TAGVAR(postdeps, $1) \
5034
_LT_AC_TAGVAR(compiler_lib_search_path, $1) \
5035
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \
5036
_LT_AC_TAGVAR(archive_cmds, $1) \
5037
_LT_AC_TAGVAR(archive_expsym_cmds, $1) \
5038
_LT_AC_TAGVAR(postinstall_cmds, $1) \
5039
_LT_AC_TAGVAR(postuninstall_cmds, $1) \
5040
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
5041
_LT_AC_TAGVAR(allow_undefined_flag, $1) \
5042
_LT_AC_TAGVAR(no_undefined_flag, $1) \
5043
_LT_AC_TAGVAR(export_symbols_cmds, $1) \
5044
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
5045
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
5046
_LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
5047
_LT_AC_TAGVAR(hardcode_automatic, $1) \
5048
_LT_AC_TAGVAR(module_cmds, $1) \
5049
_LT_AC_TAGVAR(module_expsym_cmds, $1) \
5050
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
5051
_LT_AC_TAGVAR(fix_srcfile_path, $1) \
5052
_LT_AC_TAGVAR(exclude_expsyms, $1) \
5053
_LT_AC_TAGVAR(include_expsyms, $1); do
5056
_LT_AC_TAGVAR(old_archive_cmds, $1) | \
5057
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
5058
_LT_AC_TAGVAR(archive_cmds, $1) | \
5059
_LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
5060
_LT_AC_TAGVAR(module_cmds, $1) | \
5061
_LT_AC_TAGVAR(module_expsym_cmds, $1) | \
5062
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
5063
_LT_AC_TAGVAR(export_symbols_cmds, $1) | \
5064
extract_expsyms_cmds | reload_cmds | finish_cmds | \
5065
postinstall_cmds | postuninstall_cmds | \
5066
old_postinstall_cmds | old_postuninstall_cmds | \
5067
sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
5068
# Double-quote double-evaled strings.
5069
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
5072
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
5078
*'\[$]0 --fallback-echo"')
5079
lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
5084
[cfgfile="${ofile}T"
5085
trap "$rm \"$cfgfile\"; exit 1" 1 2 15
5087
AC_MSG_NOTICE([creating $ofile])],
5090
cat <<__EOF__ >> "$cfgfile"
5094
# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
5095
# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
5096
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
5098
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
5099
# Free Software Foundation, Inc.
5101
# This file is part of GNU Libtool:
5102
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
5104
# This program is free software; you can redistribute it and/or modify
5105
# it under the terms of the GNU General Public License as published by
5106
# the Free Software Foundation; either version 2 of the License, or
5107
# (at your option) any later version.
5109
# This program is distributed in the hope that it will be useful, but
5110
# WITHOUT ANY WARRANTY; without even the implied warranty of
5111
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5112
# General Public License for more details.
5114
# You should have received a copy of the GNU General Public License
5115
# along with this program; if not, write to the Free Software
5116
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
5118
# As a special exception to the GNU General Public License, if you
5119
# distribute this file as part of a program that contains a
5120
# configuration script generated by Autoconf, you may include it under
5121
# the same distribution terms that you use for the rest of that program.
5123
# A sed program that does not truncate output.
5126
# Sed that helps us avoid accidentally triggering echo(1) options like -n.
5127
Xsed="$SED -e 1s/^X//"
5129
# The HP-UX ksh and POSIX shell print the target directory to stdout
5131
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
5133
# The names of the tagged configurations supported by this script.
5136
# ### BEGIN LIBTOOL CONFIG],
5137
[# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
5139
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5141
# Shell to use when invoking shell scripts.
5144
# Whether or not to build shared libraries.
5145
build_libtool_libs=$enable_shared
5147
# Whether or not to build static libraries.
5148
build_old_libs=$enable_static
5150
# Whether or not to add -lc for building shared libraries.
5151
build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
5153
# Whether or not to disallow shared libs when runtime libs are static
5154
allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
5156
# Whether or not to optimize for fast installation.
5157
fast_install=$enable_fast_install
5160
host_alias=$host_alias
5165
build_alias=$build_alias
5169
# An echo program that does not interpret backslashes.
5174
AR_FLAGS=$lt_AR_FLAGS
5179
# LTCC compiler flags.
5180
LTCFLAGS=$lt_LTCFLAGS
5182
# A language-specific compiler.
5183
CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
5185
# Is the compiler the GNU C compiler?
5186
with_gcc=$_LT_AC_TAGVAR(GCC, $1)
5191
# The linker used to build libraries.
5192
LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
5194
# Whether we need hard or soft links.
5197
# A BSD-compatible nm program.
5200
# A symbol stripping program
5203
# Used to examine libraries when file_magic_cmd begins "file"
5204
MAGIC_CMD=$MAGIC_CMD
5206
# Used on cygwin: DLL creation program.
5209
# Used on cygwin: object dumper.
5212
# Used on cygwin: assembler.
5215
# The name of the directory that contains temporary libtool files.
5218
# How to create reloadable object files.
5219
reload_flag=$lt_reload_flag
5220
reload_cmds=$lt_reload_cmds
5222
# How to pass a linker flag through the compiler.
5223
wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
5225
# Object file suffix (normally "o").
5228
# Old archive suffix (normally "a").
5231
# Shared library suffix (normally ".so").
5232
shrext_cmds='$shrext_cmds'
5234
# Executable file suffix (normally "").
5237
# Additional compiler flags for building library objects.
5238
pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
5241
# What is the maximum length of a command?
5242
max_cmd_len=$lt_cv_sys_max_cmd_len
5244
# Does compiler simultaneously support -c and -o options?
5245
compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
5247
# Must we lock files when doing compilation?
5248
need_locks=$lt_need_locks
5250
# Do we need the lib prefix for modules?
5251
need_lib_prefix=$need_lib_prefix
5253
# Do we need a version for libraries?
5254
need_version=$need_version
5256
# Whether dlopen is supported.
5257
dlopen_support=$enable_dlopen
5259
# Whether dlopen of programs is supported.
5260
dlopen_self=$enable_dlopen_self
5262
# Whether dlopen of statically linked programs is supported.
5263
dlopen_self_static=$enable_dlopen_self_static
5265
# Compiler flag to prevent dynamic linking.
5266
link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
5268
# Compiler flag to turn off builtin functions.
5269
no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
5271
# Compiler flag to allow reflexive dlopens.
5272
export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
5274
# Compiler flag to generate shared objects directly from archives.
5275
whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
5277
# Compiler flag to generate thread-safe objects.
5278
thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
5280
# Library versioning type.
5281
version_type=$version_type
5283
# Format of library name prefix.
5284
libname_spec=$lt_libname_spec
5286
# List of archive names. First name is the real one, the rest are links.
5287
# The last name is the one that the linker finds with -lNAME.
5288
library_names_spec=$lt_library_names_spec
5290
# The coded name of the library, if different from the real name.
5291
soname_spec=$lt_soname_spec
5293
# Commands used to build and install an old-style archive.
5295
old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
5296
old_postinstall_cmds=$lt_old_postinstall_cmds
5297
old_postuninstall_cmds=$lt_old_postuninstall_cmds
5299
# Create an old-style archive from a shared archive.
5300
old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
5302
# Create a temporary old-style archive to link instead of a shared archive.
5303
old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
5305
# Commands used to build and install a shared archive.
5306
archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
5307
archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
5308
postinstall_cmds=$lt_postinstall_cmds
5309
postuninstall_cmds=$lt_postuninstall_cmds
5311
# Commands used to build a loadable module (assumed same as above if empty)
5312
module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
5313
module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
5315
# Commands to strip libraries.
5316
old_striplib=$lt_old_striplib
5317
striplib=$lt_striplib
5319
# Dependencies to place before the objects being linked to create a
5321
predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
5323
# Dependencies to place after the objects being linked to create a
5325
postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
5327
# Dependencies to place before the objects being linked to create a
5329
predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
5331
# Dependencies to place after the objects being linked to create a
5333
postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
5335
# The directories searched by this compiler when creating a shared
5337
compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)
5339
# The library search path used internally by the compiler when linking
5341
compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
5343
# Method to check whether dependent libraries are shared objects.
5344
deplibs_check_method=$lt_deplibs_check_method
5346
# Command to use when deplibs_check_method == file_magic.
5347
file_magic_cmd=$lt_file_magic_cmd
5349
# Flag that allows shared libraries with undefined symbols to be built.
5350
allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
5352
# Flag that forces no undefined symbols.
5353
no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
5355
# Commands used to finish a libtool library installation in a directory.
5356
finish_cmds=$lt_finish_cmds
5358
# Same as above, but a single script fragment to be evaled but not shown.
5359
finish_eval=$lt_finish_eval
5361
# Take the output of nm and produce a listing of raw symbols and C names.
5362
global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
5364
# Transform the output of nm in a proper C declaration
5365
global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
5367
# Transform the output of nm in a C name address pair
5368
global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
5370
# This is the shared library runtime path variable.
5371
runpath_var=$runpath_var
5373
# This is the shared library path variable.
5374
shlibpath_var=$shlibpath_var
5376
# Is shlibpath searched before the hard-coded library search path?
5377
shlibpath_overrides_runpath=$shlibpath_overrides_runpath
5379
# How to hardcode a shared library path into an executable.
5380
hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
5382
# Whether we should hardcode library paths into libraries.
5383
hardcode_into_libs=$hardcode_into_libs
5385
# Flag to hardcode \$libdir into a binary during linking.
5386
# This must work even if \$libdir does not exist.
5387
hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
5389
# If ld is used when linking, flag to hardcode \$libdir into
5390
# a binary during linking. This must work even if \$libdir does
5392
hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
5394
# Whether we need a single -rpath flag with a separated argument.
5395
hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
5397
# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
5399
hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
5401
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
5403
hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
5405
# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
5406
# the resulting binary.
5407
hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
5409
# Set to yes if building a shared library automatically hardcodes DIR into the library
5410
# and all subsequent libraries and executables linked against it.
5411
hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
5413
# Variables whose values should be saved in libtool wrapper scripts and
5414
# restored at relink time.
5415
variables_saved_for_relink="$variables_saved_for_relink"
5417
# Whether libtool must link a program against all its dependency libraries.
5418
link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
5420
# Compile-time system search path for libraries
5421
sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
5423
# Run-time system search path for libraries
5424
sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
5426
# Fix the shell variable \$srcfile for the compiler.
5427
fix_srcfile_path=$lt_fix_srcfile_path
5429
# Set to yes if exported symbols are required.
5430
always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
5432
# The commands to list exported symbols.
5433
export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
5435
# The commands to extract the exported symbol list from a shared archive.
5436
extract_expsyms_cmds=$lt_extract_expsyms_cmds
5438
# Symbols that should not be listed in the preloaded symbols.
5439
exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
5441
# Symbols that must always be exported.
5442
include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
5445
[# ### END LIBTOOL CONFIG],
5446
[# ### END LIBTOOL TAG CONFIG: $tagname])
5453
cat <<\EOF >> "$cfgfile"
5455
# AIX sometimes has problems with the GCC collect2 program. For some
5456
# reason, if we set the COLLECT_NAMES environment variable, the problems
5457
# vanish in a puff of smoke.
5458
if test "X${COLLECT_NAMES+set}" != Xset; then
5460
export COLLECT_NAMES
5466
# We use sed instead of cat because bash on DJGPP gets confused if
5467
# if finds mixed CR/LF and LF-only lines. Since sed operates in
5468
# text mode, it properly converts lines to CR/LF. This bash problem
5469
# is reportedly fixed, but why not run on old versions too?
5470
sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
5472
mv -f "$cfgfile" "$ofile" || \
5473
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
5477
# If there is no Makefile yet, we rely on a make rule to execute
5478
# `config.status --recheck' to rerun these tests and create the
5479
# libtool script then.
5480
ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
5481
if test -f "$ltmain_in"; then
5482
test -f Makefile && make "$ltmain"
5485
])# AC_LIBTOOL_CONFIG
5488
# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
5489
# -------------------------------------------
5490
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
5491
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
5493
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5495
if test "$GCC" = yes; then
5496
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5498
AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
5499
lt_cv_prog_compiler_rtti_exceptions,
5500
[-fno-rtti -fno-exceptions], [],
5501
[_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
5503
])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
5506
# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5507
# ---------------------------------
5508
AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
5509
[AC_REQUIRE([AC_CANONICAL_HOST])
5510
AC_REQUIRE([LT_AC_PROG_SED])
5511
AC_REQUIRE([AC_PROG_NM])
5512
AC_REQUIRE([AC_OBJEXT])
5513
# Check for command to grab the raw symbol name followed by C symbol from nm.
5514
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
5515
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
5517
# These are sane defaults that work on at least a few old systems.
5518
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
5520
# Character class describing NM global symbol codes.
5521
symcode='[[BCDEGRST]]'
5523
# Regexp to match symbols that can be accessed directly from C.
5524
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
5526
# Transform an extracted symbol line into a proper C declaration
5527
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
5529
# Transform an extracted symbol line into symbol name and symbol address
5530
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5532
# Define system-specific variables.
5537
cygwin* | mingw* | pw32*)
5538
symcode='[[ABCDGISTW]]'
5540
hpux*) # Its linker distinguishes data from code symbols
5541
if test "$host_cpu" = ia64; then
5542
symcode='[[ABCDEGRST]]'
5544
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5545
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5547
linux* | k*bsd*-gnu)
5548
if test "$host_cpu" = ia64; then
5549
symcode='[[ABCDGIRSTW]]'
5550
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5551
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5555
symcode='[[BCDEGRST]]'
5558
symcode='[[BCDEGQRST]]'
5569
sysv5* | sco5v6* | unixware* | OpenUNIX*)
5573
symcode='[[DFNSTU]]'
5577
# Handle CRLF in mingw tool chain
5581
opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5585
# If we're using GNU nm, then use its standard symbol codes.
5586
case `$NM -V 2>&1` in
5587
*GNU* | *'with BFD'*)
5588
symcode='[[ABCDGIRSTW]]' ;;
5591
# Try without a prefix undercore, then with it.
5592
for ac_symprfx in "" "_"; do
5594
# Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5595
symxfrm="\\1 $ac_symprfx\\2 \\2"
5597
# Write the raw and C identifiers.
5598
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5600
# Check to see that the pipe works correctly.
5604
cat > conftest.$ac_ext <<EOF
5609
void nm_test_func(){}
5613
int main(){nm_test_var='a';nm_test_func();return(0);}
5616
if AC_TRY_EVAL(ac_compile); then
5617
# Now try to grab the symbols.
5619
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5620
# Try sorting and uniquifying the output.
5621
if sort "$nlist" | uniq > "$nlist"T; then
5622
mv -f "$nlist"T "$nlist"
5627
# Make sure that we snagged all the symbols we need.
5628
if grep ' nm_test_var$' "$nlist" >/dev/null; then
5629
if grep ' nm_test_func$' "$nlist" >/dev/null; then
5630
cat <<EOF > conftest.$ac_ext
5636
# Now generate the symbol file.
5637
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
5639
cat <<EOF >> conftest.$ac_ext
5640
#if defined (__STDC__) && __STDC__
5641
# define lt_ptr_t void *
5643
# define lt_ptr_t char *
5647
/* The mapping between symbol names and symbols. */
5652
lt_preloaded_symbols[[]] =
5655
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
5656
cat <<\EOF >> conftest.$ac_ext
5664
# Now try linking the two files.
5665
mv conftest.$ac_objext conftstm.$ac_objext
5666
lt_save_LIBS="$LIBS"
5667
lt_save_CFLAGS="$CFLAGS"
5668
LIBS="conftstm.$ac_objext"
5669
CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5670
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5673
LIBS="$lt_save_LIBS"
5674
CFLAGS="$lt_save_CFLAGS"
5676
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5679
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5682
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5685
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5686
cat conftest.$ac_ext >&5
5688
rm -rf conftest* conftst*
5690
# Do not use the global_symbol_pipe unless it works.
5691
if test "$pipe_works" = yes; then
5694
lt_cv_sys_global_symbol_pipe=
5698
if test -z "$lt_cv_sys_global_symbol_pipe"; then
5699
lt_cv_sys_global_symbol_to_cdecl=
5701
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5702
AC_MSG_RESULT(failed)
5706
]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5709
# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
5710
# ---------------------------------------
5711
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
5712
[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
5713
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5714
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
5716
AC_MSG_CHECKING([for $compiler option to produce PIC])
5718
# C++ specific cases for pic, static, wl, etc.
5719
if test "$GXX" = yes; then
5720
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5721
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5725
# All AIX code is PIC.
5726
if test "$host_cpu" = ia64; then
5727
# AIX 5 now supports IA64 processor
5728
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5732
# FIXME: we need at least 68020 code to build shared libraries, but
5733
# adding the `-m68020' flag to GCC prevents building anything better,
5735
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5737
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5738
# PIC is the default for these OSes.
5740
mingw* | cygwin* | os2* | pw32*)
5741
# This hack is so that the source file can tell whether it is being
5742
# built for inclusion in a dll (and should export symbols for example).
5743
# Although the cygwin gcc ignores -fPIC, still need this for old-style
5744
# (--disable-auto-import) libraries
5745
m4_if([$1], [GCJ], [],
5746
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5748
darwin* | rhapsody*)
5749
# PIC is the default on this platform
5750
# Common symbols not allowed in MH_DYLIB files
5751
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5754
# DJGPP does not support shared libraries at all
5755
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5758
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
5759
# Instead, we relocate shared libraries at runtime.
5762
if test -d /usr/nec; then
5763
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5767
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5773
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5778
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5784
# All AIX code is PIC.
5785
if test "$host_cpu" = ia64; then
5786
# AIX 5 now supports IA64 processor
5787
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5789
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5793
case $cc_basename in
5795
# Green Hills C++ Compiler
5796
# _LT_AC_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"
5801
# PIC is the default on this platform
5802
# Common symbols not allowed in MH_DYLIB files
5803
case $cc_basename in
5805
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
5806
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5811
case $cc_basename in
5813
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5816
# Green Hills C++ Compiler
5817
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5823
freebsd* | dragonfly*)
5824
# FreeBSD uses GNU C++
5826
hpux9* | hpux10* | hpux11*)
5827
case $cc_basename in
5829
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5830
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5831
if test "$host_cpu" != ia64; then
5832
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5836
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5837
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5843
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5852
# This is c89, which is MS Visual C++ (no shared libs)
5853
# Anyone wants to do a port?
5855
irix5* | irix6* | nonstopux*)
5856
case $cc_basename in
5858
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5859
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5860
# CC pic flag -KPIC is the default.
5866
linux* | k*bsd*-gnu)
5867
case $cc_basename in
5870
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5871
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5875
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5876
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5877
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5880
# Portland Group C++ compiler.
5881
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5882
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5883
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5887
# Make sure the PIC flag is empty. It appears that all Alpha
5888
# Linux and Compaq Tru64 Unix objects are PIC.
5889
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5890
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5893
case `$CC -V 2>&1 | sed 5q` in
5896
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5897
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5898
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5909
case $cc_basename in
5911
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5919
osf3* | osf4* | osf5*)
5920
case $cc_basename in
5922
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5925
# Rational C++ 2.4.1
5926
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5929
# Digital/Compaq C++
5930
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5931
# Make sure the PIC flag is empty. It appears that all Alpha
5932
# Linux and Compaq Tru64 Unix objects are PIC.
5933
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5934
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5943
case $cc_basename in
5945
# Sun C++ 4.2, 5.x and Centerline C++
5946
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5947
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5948
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5951
# Green Hills C++ Compiler
5952
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5959
case $cc_basename in
5962
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5963
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5967
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5974
case $cc_basename in
5976
# NonStop-UX NCC 3.20
5977
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5983
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5984
case $cc_basename in
5986
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5987
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5988
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5995
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6001
if test "$GCC" = yes; then
6002
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6003
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6007
# All AIX code is PIC.
6008
if test "$host_cpu" = ia64; then
6009
# AIX 5 now supports IA64 processor
6010
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6015
# FIXME: we need at least 68020 code to build shared libraries, but
6016
# adding the `-m68020' flag to GCC prevents building anything better,
6018
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
6021
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
6022
# PIC is the default for these OSes.
6025
mingw* | cygwin* | pw32* | os2*)
6026
# This hack is so that the source file can tell whether it is being
6027
# built for inclusion in a dll (and should export symbols for example).
6028
# Although the cygwin gcc ignores -fPIC, still need this for old-style
6029
# (--disable-auto-import) libraries
6030
m4_if([$1], [GCJ], [],
6031
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
6034
darwin* | rhapsody*)
6035
# PIC is the default on this platform
6036
# Common symbols not allowed in MH_DYLIB files
6037
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
6041
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
6042
# Instead, we relocate shared libraries at runtime.
6046
# Just because we use GCC doesn't mean we suddenly get shared libraries
6047
# on systems that don't support them.
6048
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6053
if test -d /usr/nec; then
6054
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
6059
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6066
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6072
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6076
# PORTME Check for flag to pass linker flags through the system compiler.
6079
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6080
if test "$host_cpu" = ia64; then
6081
# AIX 5 now supports IA64 processor
6082
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6084
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
6088
# PIC is the default on this platform
6089
# Common symbols not allowed in MH_DYLIB files
6090
case $cc_basename in
6092
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
6093
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6098
mingw* | cygwin* | pw32* | os2*)
6099
# This hack is so that the source file can tell whether it is being
6100
# built for inclusion in a dll (and should export symbols for example).
6101
m4_if([$1], [GCJ], [],
6102
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
6105
hpux9* | hpux10* | hpux11*)
6106
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6107
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6114
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6117
# Is there a better lt_prog_compiler_static that works with the bundled CC?
6118
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6121
irix5* | irix6* | nonstopux*)
6122
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6123
# PIC (with -KPIC) is the default.
6124
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6128
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6129
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6132
linux* | k*bsd*-gnu)
6133
case $cc_basename in
6135
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6136
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6137
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6139
pgcc* | pgf77* | pgf90* | pgf95*)
6140
# Portland Group compilers (*not* the Pentium gcc compiler,
6141
# which looks to be a dead project)
6142
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6143
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
6144
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6147
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6148
# All Alpha code is PIC.
6149
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6152
case `$CC -V 2>&1 | sed 5q` in
6155
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6156
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6157
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6160
# Sun Fortran 8.3 passes all unrecognized flags to the linker
6161
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6162
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6163
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
6170
osf3* | osf4* | osf5*)
6171
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6172
# All OSF/1 code is PIC.
6173
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6177
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6181
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6182
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6183
case $cc_basename in
6185
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
6187
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
6192
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6193
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6194
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6197
sysv4 | sysv4.2uw2* | sysv4.3*)
6198
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6199
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6200
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6204
if test -d /usr/nec ;then
6205
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
6206
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6210
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6211
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6212
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6213
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6217
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6218
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6222
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6223
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6227
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6232
AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
6235
# Check to make sure the PIC flag actually works.
6237
if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
6238
AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
6239
_LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1),
6240
[$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
6241
[case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
6243
*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
6245
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6246
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
6249
# For platforms which do not support PIC, -DPIC is meaningless:
6251
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6254
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
6259
# Check to make sure the static flag actually works.
6261
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
6262
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
6263
_LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1),
6264
$lt_tmp_static_flag,
6266
[_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
6270
# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
6271
# ------------------------------------
6272
# See if the linker supports building shared libraries.
6273
AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
6274
[AC_REQUIRE([LT_AC_PROG_SED])dnl
6275
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6277
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6280
# If we're using GNU nm, then we don't want the "-C" option.
6281
# -C means demangle to AIX nm, but means don't demangle with GNU nm
6282
if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6283
_LT_AC_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'
6285
_LT_AC_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'
6289
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
6292
_LT_AC_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'
6295
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6298
_LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
6301
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
6302
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6303
_LT_AC_TAGVAR(archive_cmds, $1)=
6304
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
6305
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
6306
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
6307
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6308
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6309
_LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
6310
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6311
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6312
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6313
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6314
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6315
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6316
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
6317
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
6318
_LT_AC_TAGVAR(module_cmds, $1)=
6319
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
6320
_LT_AC_TAGVAR(always_export_symbols, $1)=no
6321
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6322
# include_expsyms should be a list of space-separated symbols to be *always*
6323
# included in the symbol list
6324
_LT_AC_TAGVAR(include_expsyms, $1)=
6325
# exclude_expsyms can be an extended regexp of symbols to exclude
6326
# it will be wrapped by ` (' and `)$', so one must not match beginning or
6327
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
6328
# as well as any symbol that contains `d'.
6329
_LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
6330
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
6331
# platforms (ab)use it in PIC code, but their linkers get confused if
6332
# the symbol is explicitly referenced. Since portable code cannot
6333
# rely on this symbol name, it's probably fine to never include it in
6334
# preloaded symbol tables.
6335
# Exclude shared library initialization/finalization symbols.
6336
dnl Note also adjust exclude_expsyms for C++ above.
6337
extract_expsyms_cmds=
6338
# Just being paranoid about ensuring that cc_basename is set.
6339
_LT_CC_BASENAME([$compiler])
6341
cygwin* | mingw* | pw32*)
6342
# FIXME: the MSVC++ port hasn't been tested in a loooong time
6343
# When not using gcc, we currently assume that we are using
6344
# Microsoft Visual C++.
6345
if test "$GCC" != yes; then
6350
# we just hope/assume this is gcc and not c89 (= MSVC++)
6358
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
6359
if test "$with_gnu_ld" = yes; then
6360
# If archive_cmds runs LD, not CC, wlarc should be empty
6363
# Set some defaults for GNU ld with shared library support. These
6364
# are reset later if shared libraries are not supported. Putting them
6365
# here allows them to be overridden if necessary.
6366
runpath_var=LD_RUN_PATH
6367
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6368
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6369
# ancient GNU ld didn't support --whole-archive et. al.
6370
if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
6371
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6373
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6375
supports_anon_versioning=no
6376
case `$LD -v 2>/dev/null` in
6377
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6378
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6379
*\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6380
*\ 2.11.*) ;; # other 2.11 versions
6381
*) supports_anon_versioning=yes ;;
6384
# See if GNU ld supports shared libraries.
6387
# On AIX/PPC, the GNU linker is very broken
6388
if test "$host_cpu" != ia64; then
6389
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6392
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
6393
*** to be unable to reliably create shared libraries on AIX.
6394
*** Therefore, libtool is disabling shared libraries support. If you
6395
*** really care for shared libraries, you may want to modify your PATH
6396
*** so that a non-GNU linker is found, and then restart.
6403
_LT_AC_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)'
6404
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6405
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6407
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
6408
# that the semantics of dynamic libraries on AmigaOS, at least up
6409
# to version 4, is to share data among multiple programs linked
6410
# with the same dynamic library. Since this doesn't match the
6411
# behavior of shared libraries on other platforms, we can't use
6413
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6417
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6418
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6419
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6420
# support --undefined. This deserves some investigation. FIXME
6421
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6423
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6427
cygwin* | mingw* | pw32*)
6428
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6429
# as there is no search path for DLLs.
6430
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6431
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6432
_LT_AC_TAGVAR(always_export_symbols, $1)=no
6433
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6434
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
6436
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
6437
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6438
# If the export-symbols file already is a .def file (1st line
6439
# is EXPORTS), use it as is; otherwise, prepend...
6440
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6441
cp $export_symbols $output_objdir/$soname.def;
6443
echo EXPORTS > $output_objdir/$soname.def;
6444
cat $export_symbols >> $output_objdir/$soname.def;
6446
$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6448
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6453
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6454
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6455
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6456
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6457
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6458
# Instead, shared libraries are loaded at an image base (0x10000000 by
6459
# default) and relocated if they conflict, which is a slow very memory
6460
# consuming and fragmenting process. To avoid this, we pick a random,
6461
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6462
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
6463
_LT_AC_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'
6464
_LT_AC_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'
6467
gnu* | linux* | k*bsd*-gnu)
6468
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6470
case $cc_basename,$host_cpu in
6471
pgcc*) # Portland Group C compiler
6472
_LT_AC_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'
6473
tmp_addflag=' $pic_flag'
6475
pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
6476
_LT_AC_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'
6477
tmp_addflag=' $pic_flag -Mnomain' ;;
6478
ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
6479
tmp_addflag=' -i_dynamic' ;;
6480
efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
6481
tmp_addflag=' -i_dynamic -nofor_main' ;;
6482
ifc* | ifort*) # Intel Fortran compiler
6483
tmp_addflag=' -nofor_main' ;;
6485
case `$CC -V 2>&1 | sed 5q` in
6486
*Sun\ C*) # Sun C 5.9
6487
_LT_AC_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'
6488
tmp_sharedflag='-G' ;;
6489
*Sun\ F*) # Sun Fortran 8.3
6490
tmp_sharedflag='-G' ;;
6492
tmp_sharedflag='-shared' ;;
6494
_LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6496
if test $supports_anon_versioning = yes; then
6497
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
6498
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6499
$echo "local: *; };" >> $output_objdir/$libname.ver~
6500
$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6503
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6508
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6509
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6512
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6513
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6518
if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
6519
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6522
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
6523
*** create shared libraries on Solaris systems. Therefore, libtool
6524
*** is disabling shared libraries support. We urge you to upgrade GNU
6525
*** binutils to release 2.9.1 or newer. Another option is to modify
6526
*** your PATH or compiler configuration so that the native linker is
6527
*** used, and then restart.
6530
elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6531
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6532
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6534
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6538
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
6539
case `$LD -v 2>&1` in
6540
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
6541
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6544
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
6545
*** reliably create shared libraries on SCO systems. Therefore, libtool
6546
*** is disabling shared libraries support. We urge you to upgrade GNU
6547
*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
6548
*** your PATH or compiler configuration so that the native linker is
6549
*** used, and then restart.
6554
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6555
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
6556
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
6557
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
6559
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6566
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6568
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6569
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6573
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6574
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6575
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6577
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6582
if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
6584
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6585
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6586
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6589
# PORTME fill in a description of your system's linker (not GNU ld)
6592
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6593
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6594
_LT_AC_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'
6595
# Note: this linker hardcodes the directories in LIBPATH if there
6596
# are no directories specified by -L.
6597
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6598
if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
6599
# Neither direct hardcoding nor static linking is supported with a
6601
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6606
if test "$host_cpu" = ia64; then
6607
# On IA64, the linker does run time linking by default, so we don't
6608
# have to do anything special.
6609
aix_use_runtimelinking=no
6610
exp_sym_flag='-Bexport'
6613
# If we're using GNU nm, then we don't want the "-C" option.
6614
# -C means demangle to AIX nm, but means don't demangle with GNU nm
6615
if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6616
_LT_AC_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'
6618
_LT_AC_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'
6620
aix_use_runtimelinking=no
6622
# Test if we are trying to use run time linking or normal
6623
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
6624
# need to do runtime linking.
6625
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6626
for ld_flag in $LDFLAGS; do
6627
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6628
aix_use_runtimelinking=yes
6635
exp_sym_flag='-bexport'
6636
no_entry_flag='-bnoentry'
6639
# When large executables or shared objects are built, AIX ld can
6640
# have problems creating the table of contents. If linking a library
6641
# or program results in "error TOC overflow" add -mminimal-toc to
6642
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6643
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6645
_LT_AC_TAGVAR(archive_cmds, $1)=''
6646
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6647
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6648
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6650
if test "$GCC" = yes; then
6651
case $host_os in aix4.[[012]]|aix4.[[012]].*)
6652
# We only want to do this on AIX 4.2 and lower, the check
6653
# below for broken collect2 doesn't work under 4.3+
6654
collect2name=`${CC} -print-prog-name=collect2`
6655
if test -f "$collect2name" && \
6656
strings "$collect2name" | grep resolve_lib_name >/dev/null
6658
# We have reworked collect2
6661
# We have old collect2
6662
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6663
# It fails to find uninstalled libraries when the uninstalled
6664
# path is not listed in the libpath. Setting hardcode_minus_L
6665
# to unsupported forces relinking
6666
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6667
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6668
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6672
shared_flag='-shared'
6673
if test "$aix_use_runtimelinking" = yes; then
6674
shared_flag="$shared_flag "'${wl}-G'
6678
if test "$host_cpu" = ia64; then
6679
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6680
# chokes on -Wl,-G. The following line is correct:
6683
if test "$aix_use_runtimelinking" = yes; then
6684
shared_flag='${wl}-G'
6686
shared_flag='${wl}-bM:SRE'
6691
# It seems that -bexpall does not export symbols beginning with
6692
# underscore (_), so it is better to generate a list of symbols to export.
6693
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6694
if test "$aix_use_runtimelinking" = yes; then
6695
# Warning - without using the other runtime loading flags (-brtl),
6696
# -berok will link without error, but may produce a broken library.
6697
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
6698
# Determine the default libpath from the value encoded in an empty executable.
6699
_LT_AC_SYS_LIBPATH_AIX
6700
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6701
_LT_AC_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 "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6703
if test "$host_cpu" = ia64; then
6704
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6705
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6706
_LT_AC_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"
6708
# Determine the default libpath from the value encoded in an empty executable.
6709
_LT_AC_SYS_LIBPATH_AIX
6710
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6711
# Warning - without using the other run time loading flags,
6712
# -berok will link without error, but may produce a broken library.
6713
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6714
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6715
# Exported symbols can be pulled into shared objects from archives
6716
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6717
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6718
# This is similar to how AIX traditionally builds its shared libraries.
6719
_LT_AC_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'
6725
_LT_AC_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)'
6726
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6727
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6728
# see comment about different semantics on the GNU ld section
6729
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6733
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6736
cygwin* | mingw* | pw32*)
6737
# When not using gcc, we currently assume that we are using
6738
# Microsoft Visual C++.
6739
# hardcode_libdir_flag_spec is actually meaningless, as there is
6740
# no search path for DLLs.
6741
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6742
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6743
# Tell ltmain to make .lib files, not .a files.
6745
# Tell ltmain to make .dll files, not .so files.
6747
# FIXME: Setting linknames here is a bad hack.
6748
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
6749
# The linker will automatically build a .lib file if we build a DLL.
6750
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
6751
# FIXME: Should let the user specify the lib program.
6752
_LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6753
_LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
6754
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6757
darwin* | rhapsody*)
6759
rhapsody* | darwin1.[[012]])
6760
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
6763
if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
6764
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6766
case ${MACOSX_DEPLOYMENT_TARGET} in
6768
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6771
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
6777
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6778
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6779
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
6780
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6781
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
6782
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6783
if test "$GCC" = yes ; then
6784
output_verbose_link_cmd='echo'
6785
_LT_AC_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}"
6786
_LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
6787
_LT_AC_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}"
6788
_LT_AC_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}"
6790
case $cc_basename in
6792
output_verbose_link_cmd='echo'
6793
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
6794
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6795
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
6796
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6797
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6800
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6807
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6808
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6809
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6813
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6816
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6817
# support. Future versions do this automatically, but an explicit c++rt0.o
6818
# does not break anything, and helps significantly (at the cost of a little
6821
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6822
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6823
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6824
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6827
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
6829
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6830
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6831
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6832
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6835
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6836
freebsd* | dragonfly*)
6837
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
6838
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6839
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6840
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6844
if test "$GCC" = yes; then
6845
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6847
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6849
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6850
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6851
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6853
# hardcode_minus_L: Not really in the search PATH,
6854
# but as the default location of the library.
6855
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6856
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6860
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6861
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6863
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6865
if test "$with_gnu_ld" = no; then
6866
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6867
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6869
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6870
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6872
# hardcode_minus_L: Not really in the search PATH,
6873
# but as the default location of the library.
6874
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6879
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6882
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6885
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6888
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6894
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6897
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6900
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6904
if test "$with_gnu_ld" = no; then
6905
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6906
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6910
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
6911
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6912
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6915
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6916
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6918
# hardcode_minus_L: Not really in the search PATH,
6919
# but as the default location of the library.
6920
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6926
irix5* | irix6* | nonstopux*)
6927
if test "$GCC" = yes; then
6928
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6930
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6931
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6933
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6934
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6935
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6939
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6940
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6942
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6944
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6945
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6946
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6950
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6951
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6952
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6953
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6954
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6958
if test -f /usr/libexec/ld.so; then
6959
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6960
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6961
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6962
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6963
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6964
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6965
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6968
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6969
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6970
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6973
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6974
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6979
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6984
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6985
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6986
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6987
_LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
6988
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6992
if test "$GCC" = yes; then
6993
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6994
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6996
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6997
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6999
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7000
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7003
osf4* | osf5*) # as osf3* with the addition of -msym flag
7004
if test "$GCC" = yes; then
7005
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7006
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7007
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7009
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7010
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
7011
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
7012
$LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
7014
# Both c and cxx compiler support -rpath directly
7015
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7017
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7021
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
7022
if test "$GCC" = yes; then
7024
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7025
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7026
$CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
7029
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
7030
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7031
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
7033
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7034
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7036
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7038
# The compiler driver will combine and reorder linker options,
7039
# but understands `-z linker_flag'. GCC discards it without `$wl',
7040
# but is careful enough not to reorder.
7041
# Supported since Solaris 2.6 (maybe 2.5.1?)
7042
if test "$GCC" = yes; then
7043
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
7045
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7049
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7053
if test "x$host_vendor" = xsequent; then
7054
# Use $CC to link under sequent, because it throws in some extra .o
7055
# files that make .init and .fini sections work.
7056
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
7058
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
7060
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7061
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7062
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7063
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7067
case $host_vendor in
7069
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7070
_LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
7073
## LD is ld it makes a PLAMLIB
7074
## CC just makes a GrossModule.
7075
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
7076
_LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
7077
_LT_AC_TAGVAR(hardcode_direct, $1)=no
7080
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7081
_LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
7084
runpath_var='LD_RUN_PATH'
7085
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7089
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7090
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7091
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
7095
if test -d /usr/nec; then
7096
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7097
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7098
runpath_var=LD_RUN_PATH
7099
hardcode_runpath_var=yes
7100
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
7104
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7105
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7106
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7107
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7108
runpath_var='LD_RUN_PATH'
7110
if test "$GCC" = yes; then
7111
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7112
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7114
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7115
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7119
sysv5* | sco3.2v5* | sco5v6*)
7120
# Note: We can NOT use -z defs as we might desire, because we do not
7121
# link with -lc, and that would cause any symbols used from libc to
7122
# always be unresolved, which means just about no library would
7123
# ever link correctly. If we're not using GNU ld we use -z text
7124
# though, which does catch some bad symbols but isn't as heavy-handed
7126
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7127
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7128
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7129
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7130
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
7131
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
7132
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7133
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7134
runpath_var='LD_RUN_PATH'
7136
if test "$GCC" = yes; then
7137
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7138
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7140
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7141
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7146
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7147
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7148
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7152
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7157
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
7158
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7161
# Do we need to explicitly link libc?
7163
case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
7165
# Assume -lc should be added
7166
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7168
if test "$enable_shared" = yes && test "$GCC" = yes; then
7169
case $_LT_AC_TAGVAR(archive_cmds, $1) in
7171
# FIXME: we may have to deal with multi-command sequences.
7174
# Test whether the compiler implicitly links with -lc since on some
7175
# systems, -lgcc has to come before -lc. If gcc already passes -lc
7176
# to ld, don't add -lc before -lgcc.
7177
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
7179
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
7181
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
7184
libobjs=conftest.$ac_objext
7186
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
7187
pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
7193
lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
7194
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
7195
if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
7197
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7199
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7201
_LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
7203
cat conftest.err 1>&5
7206
AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
7212
])# AC_LIBTOOL_PROG_LD_SHLIBS
7215
# _LT_AC_FILE_LTDLL_C
7216
# -------------------
7217
# Be careful that the start marker always follows a newline.
7218
AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
7219
# /* ltdll.c starts here */
7220
# #define WIN32_LEAN_AND_MEAN
7221
# #include <windows.h>
7222
# #undef WIN32_LEAN_AND_MEAN
7223
# #include <stdio.h>
7225
# #ifndef __CYGWIN__
7226
# # ifdef __CYGWIN32__
7227
# # define __CYGWIN__ __CYGWIN32__
7231
# #ifdef __cplusplus
7234
# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
7235
# #ifdef __cplusplus
7240
# #include <cygwin/cygwin_dll.h>
7241
# DECLARE_CYGWIN_DLL( DllMain );
7243
# HINSTANCE __hDllInstance_base;
7246
# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
7248
# __hDllInstance_base = hInst;
7251
# /* ltdll.c ends here */
7252
])# _LT_AC_FILE_LTDLL_C
7255
# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
7256
# ---------------------------------
7257
AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
7261
AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
7262
AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
7263
AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
7264
AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
7265
AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
7266
AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
7267
AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
7269
# This is just to silence aclocal about the macro not being used
7270
ifelse([AC_DISABLE_FAST_INSTALL])
7272
AC_DEFUN([LT_AC_PROG_GCJ],
7273
[AC_CHECK_TOOL(GCJ, gcj, no)
7274
test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7278
AC_DEFUN([LT_AC_PROG_RC],
7279
[AC_CHECK_TOOL(RC, windres, no)
7283
# Cheap backport of AS_EXECUTABLE_P and required macros
7284
# from Autoconf 2.59; we should not use $as_executable_p directly.
7288
m4_ifndef([_AS_TEST_PREPARE],
7289
[m4_defun([_AS_TEST_PREPARE],
7290
[if test -x / >/dev/null 2>&1; then
7291
as_executable_p='test -x'
7293
as_executable_p='test -f'
7295
])])# _AS_TEST_PREPARE
7299
# Check whether a file is executable.
7300
m4_ifndef([AS_EXECUTABLE_P],
7301
[m4_defun([AS_EXECUTABLE_P],
7302
[AS_REQUIRE([_AS_TEST_PREPARE])dnl
7303
$as_executable_p $1[]dnl
7304
])])# AS_EXECUTABLE_P
7306
# NOTE: This macro has been submitted for inclusion into #
7307
# GNU Autoconf as AC_PROG_SED. When it is available in #
7308
# a released version of Autoconf we should remove this #
7309
# macro and use it instead. #
7312
# Check for a fully-functional sed program, that truncates
7313
# as few characters as possible. Prefer GNU sed if found.
7314
AC_DEFUN([LT_AC_PROG_SED],
7315
[AC_MSG_CHECKING([for a sed that does not truncate output])
7316
AC_CACHE_VAL(lt_cv_path_SED,
7317
[# Loop through the user's path and test for sed and gsed.
7318
# Then use that list of sed's as ones to test for truncation.
7319
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7323
test -z "$as_dir" && as_dir=.
7324
for lt_ac_prog in sed gsed; do
7325
for ac_exec_ext in '' $ac_executable_extensions; do
7326
if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then
7327
lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7335
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
7336
# along with /bin/sed that truncates output.
7337
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7338
test ! -f $lt_ac_sed && continue
7339
cat /dev/null > conftest.in
7341
echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7342
# Check for GNU sed and select it if it is found.
7343
if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7344
lt_cv_path_SED=$lt_ac_sed
7348
cat conftest.in conftest.in >conftest.tmp
7349
mv conftest.tmp conftest.in
7350
cp conftest.in conftest.nl
7352
$lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7353
cmp -s conftest.out conftest.nl || break
7354
# 10000 chars as input seems more than enough
7355
test $lt_ac_count -gt 10 && break
7356
lt_ac_count=`expr $lt_ac_count + 1`
7357
if test $lt_ac_count -gt $lt_ac_max; then
7358
lt_ac_max=$lt_ac_count
7359
lt_cv_path_SED=$lt_ac_sed
7366
AC_MSG_RESULT([$SED])
7369
500
# nls.m4 serial 3 (gettext-0.15)
7370
501
dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc.
7371
502
dnl This file is free software; the Free Software Foundation