~ubuntu-branches/ubuntu/oneiric/bug-buddy/oneiric

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Didier Roche
  • Date: 2009-03-17 11:52:38 UTC
  • mfrom: (1.1.27 upstream)
  • Revision ID: james.westby@ubuntu.com-20090317115238-pelki75p8yvl9bw1
Tags: 2.26.0+dfsg-0ubuntu1
* New upstream release: (LP: #344132)
  - Don't hardcode a scrollkeeper check in the configure script.
  - Build correctly with --disable-eds.
  - Fix a segfault (Josseline Mouette).
  - Don't free uninitialized memory.
  - Drop libgnome and libgnomeui dependencies.
  - Make google-breakpad support optional (but enabled by default).
    Thanks to Sjoerd Simons.
  - Obtain the real path of the crashed process by looking in /proc.
    Thanks to Sam Morris and Matt Keenan.
  - Add an option to delete the included file after bug-buddy has
    processed it.
  - Implement a logger for pasting critical and fatal warnings in the
    stacktraces.
  - Include the loaded GTK+ modules in the stacktraces sent to bugzilla.
  - Update google-breakpad to SVN r290.
  - Compile with all the GLib/GTK+ deprecation flags.
* debian/control.in:
  - remove scroolkeeper, libgnome2-dev and libgnomeui-dev b-d
  - bump libgtk2.0-dev to 2.14
  - add libgconf2-dev
  - add Vcs-Bzr tag
  - re-generate debian/control
* debian/patches:
  - remove 01_double-free.patch as taken upstream
  - remove 02_disable_breakpad.patch as upstream handle --disable-*
    (and so, --disable-google-breakpad)
  - refresh 70_automake-autoconf.patch
* debian/rules: remove --disable-scrollkeeper as removed in configure
  file
* Adapt debian/watch to get unstable version

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
 
14
14
m4_ifndef([AC_AUTOCONF_VERSION],
15
15
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16
 
m4_if(AC_AUTOCONF_VERSION, [2.61],,
17
 
[m4_warning([this file was generated for autoconf 2.61.
 
16
m4_if(AC_AUTOCONF_VERSION, [2.63],,
 
17
[m4_warning([this file was generated for autoconf 2.63.
18
18
You have another version of autoconf.  It may work, but is not guaranteed to.
19
19
If you have problems, you may need to regenerate the build system entirely.
20
20
To do so, use the procedure documented by the package, typically `autoreconf'.])])
686
686
  AC_SUBST(WARN_CXXFLAGS)
687
687
])
688
688
 
 
689
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
 
690
 
 
691
# serial 52 AC_PROG_LIBTOOL
 
692
 
 
693
 
 
694
# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
 
695
# -----------------------------------------------------------
 
696
# If this macro is not defined by Autoconf, define it here.
 
697
m4_ifdef([AC_PROVIDE_IFELSE],
 
698
         [],
 
699
         [m4_define([AC_PROVIDE_IFELSE],
 
700
                 [m4_ifdef([AC_PROVIDE_$1],
 
701
                           [$2], [$3])])])
 
702
 
 
703
 
 
704
# AC_PROG_LIBTOOL
 
705
# ---------------
 
706
AC_DEFUN([AC_PROG_LIBTOOL],
 
707
[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
 
708
dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
 
709
dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
 
710
  AC_PROVIDE_IFELSE([AC_PROG_CXX],
 
711
    [AC_LIBTOOL_CXX],
 
712
    [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
 
713
  ])])
 
714
dnl And a similar setup for Fortran 77 support
 
715
  AC_PROVIDE_IFELSE([AC_PROG_F77],
 
716
    [AC_LIBTOOL_F77],
 
717
    [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
 
718
])])
 
719
 
 
720
dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
 
721
dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
 
722
dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
 
723
  AC_PROVIDE_IFELSE([AC_PROG_GCJ],
 
724
    [AC_LIBTOOL_GCJ],
 
725
    [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
 
726
      [AC_LIBTOOL_GCJ],
 
727
      [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
 
728
        [AC_LIBTOOL_GCJ],
 
729
      [ifdef([AC_PROG_GCJ],
 
730
             [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
 
731
       ifdef([A][M_PROG_GCJ],
 
732
             [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
 
733
       ifdef([LT_AC_PROG_GCJ],
 
734
             [define([LT_AC_PROG_GCJ],
 
735
                defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
 
736
])])# AC_PROG_LIBTOOL
 
737
 
 
738
 
 
739
# _AC_PROG_LIBTOOL
 
740
# ----------------
 
741
AC_DEFUN([_AC_PROG_LIBTOOL],
 
742
[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
 
743
AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
 
744
AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
 
745
AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
 
746
 
 
747
# This can be used to rebuild libtool when needed
 
748
LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
 
749
 
 
750
# Always use our own libtool.
 
751
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
 
752
AC_SUBST(LIBTOOL)dnl
 
753
 
 
754
# Prevent multiple expansion
 
755
define([AC_PROG_LIBTOOL], [])
 
756
])# _AC_PROG_LIBTOOL
 
757
 
 
758
 
 
759
# AC_LIBTOOL_SETUP
 
760
# ----------------
 
761
AC_DEFUN([AC_LIBTOOL_SETUP],
 
762
[AC_PREREQ(2.50)dnl
 
763
AC_REQUIRE([AC_ENABLE_SHARED])dnl
 
764
AC_REQUIRE([AC_ENABLE_STATIC])dnl
 
765
AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
 
766
AC_REQUIRE([AC_CANONICAL_HOST])dnl
 
767
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
 
768
AC_REQUIRE([AC_PROG_CC])dnl
 
769
AC_REQUIRE([AC_PROG_LD])dnl
 
770
AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
 
771
AC_REQUIRE([AC_PROG_NM])dnl
 
772
 
 
773
AC_REQUIRE([AC_PROG_LN_S])dnl
 
774
AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
 
775
# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
 
776
AC_REQUIRE([AC_OBJEXT])dnl
 
777
AC_REQUIRE([AC_EXEEXT])dnl
 
778
dnl
 
779
AC_LIBTOOL_SYS_MAX_CMD_LEN
 
780
AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
 
781
AC_LIBTOOL_OBJDIR
 
782
 
 
783
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
 
784
_LT_AC_PROG_ECHO_BACKSLASH
 
785
 
 
786
case $host_os in
 
787
aix3*)
 
788
  # AIX sometimes has problems with the GCC collect2 program.  For some
 
789
  # reason, if we set the COLLECT_NAMES environment variable, the problems
 
790
  # vanish in a puff of smoke.
 
791
  if test "X${COLLECT_NAMES+set}" != Xset; then
 
792
    COLLECT_NAMES=
 
793
    export COLLECT_NAMES
 
794
  fi
 
795
  ;;
 
796
esac
 
797
 
 
798
# Sed substitution that helps us do robust quoting.  It backslashifies
 
799
# metacharacters that are still active within double-quoted strings.
 
800
Xsed='sed -e 1s/^X//'
 
801
[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
 
802
 
 
803
# Same as above, but do not quote variable references.
 
804
[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
 
805
 
 
806
# Sed substitution to delay expansion of an escaped shell variable in a
 
807
# double_quote_subst'ed string.
 
808
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
 
809
 
 
810
# Sed substitution to avoid accidental globbing in evaled expressions
 
811
no_glob_subst='s/\*/\\\*/g'
 
812
 
 
813
# Constants:
 
814
rm="rm -f"
 
815
 
 
816
# Global variables:
 
817
default_ofile=libtool
 
818
can_build_shared=yes
 
819
 
 
820
# All known linkers require a `.a' archive for static linking (except MSVC,
 
821
# which needs '.lib').
 
822
libext=a
 
823
ltmain="$ac_aux_dir/ltmain.sh"
 
824
ofile="$default_ofile"
 
825
with_gnu_ld="$lt_cv_prog_gnu_ld"
 
826
 
 
827
AC_CHECK_TOOL(AR, ar, false)
 
828
AC_CHECK_TOOL(RANLIB, ranlib, :)
 
829
AC_CHECK_TOOL(STRIP, strip, :)
 
830
 
 
831
old_CC="$CC"
 
832
old_CFLAGS="$CFLAGS"
 
833
 
 
834
# Set sane defaults for various variables
 
835
test -z "$AR" && AR=ar
 
836
test -z "$AR_FLAGS" && AR_FLAGS=cru
 
837
test -z "$AS" && AS=as
 
838
test -z "$CC" && CC=cc
 
839
test -z "$LTCC" && LTCC=$CC
 
840
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
 
841
test -z "$DLLTOOL" && DLLTOOL=dlltool
 
842
test -z "$LD" && LD=ld
 
843
test -z "$LN_S" && LN_S="ln -s"
 
844
test -z "$MAGIC_CMD" && MAGIC_CMD=file
 
845
test -z "$NM" && NM=nm
 
846
test -z "$SED" && SED=sed
 
847
test -z "$OBJDUMP" && OBJDUMP=objdump
 
848
test -z "$RANLIB" && RANLIB=:
 
849
test -z "$STRIP" && STRIP=:
 
850
test -z "$ac_objext" && ac_objext=o
 
851
 
 
852
# Determine commands to create old-style static archives.
 
853
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
 
854
old_postinstall_cmds='chmod 644 $oldlib'
 
855
old_postuninstall_cmds=
 
856
 
 
857
if test -n "$RANLIB"; then
 
858
  case $host_os in
 
859
  openbsd*)
 
860
    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
 
861
    ;;
 
862
  *)
 
863
    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
 
864
    ;;
 
865
  esac
 
866
  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
 
867
fi
 
868
 
 
869
_LT_CC_BASENAME([$compiler])
 
870
 
 
871
# Only perform the check for file, if the check method requires it
 
872
case $deplibs_check_method in
 
873
file_magic*)
 
874
  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
 
875
    AC_PATH_MAGIC
 
876
  fi
 
877
  ;;
 
878
esac
 
879
 
 
880
_LT_REQUIRED_DARWIN_CHECKS
 
881
 
 
882
AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
 
883
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
 
884
enable_win32_dll=yes, enable_win32_dll=no)
 
885
 
 
886
AC_ARG_ENABLE([libtool-lock],
 
887
    [AC_HELP_STRING([--disable-libtool-lock],
 
888
        [avoid locking (might break parallel builds)])])
 
889
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
 
890
 
 
891
AC_ARG_WITH([pic],
 
892
    [AC_HELP_STRING([--with-pic],
 
893
        [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
 
894
    [pic_mode="$withval"],
 
895
    [pic_mode=default])
 
896
test -z "$pic_mode" && pic_mode=default
 
897
 
 
898
# Use C for the default configuration in the libtool script
 
899
tagname=
 
900
AC_LIBTOOL_LANG_C_CONFIG
 
901
_LT_AC_TAGCONFIG
 
902
])# AC_LIBTOOL_SETUP
 
903
 
 
904
 
 
905
# _LT_AC_SYS_COMPILER
 
906
# -------------------
 
907
AC_DEFUN([_LT_AC_SYS_COMPILER],
 
908
[AC_REQUIRE([AC_PROG_CC])dnl
 
909
 
 
910
# If no C compiler was specified, use CC.
 
911
LTCC=${LTCC-"$CC"}
 
912
 
 
913
# If no C compiler flags were specified, use CFLAGS.
 
914
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
 
915
 
 
916
# Allow CC to be a program name with arguments.
 
917
compiler=$CC
 
918
])# _LT_AC_SYS_COMPILER
 
919
 
 
920
 
 
921
# _LT_CC_BASENAME(CC)
 
922
# -------------------
 
923
# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
 
924
AC_DEFUN([_LT_CC_BASENAME],
 
925
[for cc_temp in $1""; do
 
926
  case $cc_temp in
 
927
    compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
 
928
    distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
 
929
    \-*) ;;
 
930
    *) break;;
 
931
  esac
 
932
done
 
933
cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
 
934
])
 
935
 
 
936
 
 
937
# _LT_COMPILER_BOILERPLATE
 
938
# ------------------------
 
939
# Check for compiler boilerplate output or warnings with
 
940
# the simple compiler test code.
 
941
AC_DEFUN([_LT_COMPILER_BOILERPLATE],
 
942
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
943
ac_outfile=conftest.$ac_objext
 
944
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
 
945
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 
946
_lt_compiler_boilerplate=`cat conftest.err`
 
947
$rm conftest*
 
948
])# _LT_COMPILER_BOILERPLATE
 
949
 
 
950
 
 
951
# _LT_LINKER_BOILERPLATE
 
952
# ----------------------
 
953
# Check for linker boilerplate output or warnings with
 
954
# the simple link test code.
 
955
AC_DEFUN([_LT_LINKER_BOILERPLATE],
 
956
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
957
ac_outfile=conftest.$ac_objext
 
958
echo "$lt_simple_link_test_code" >conftest.$ac_ext
 
959
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 
960
_lt_linker_boilerplate=`cat conftest.err`
 
961
$rm -r conftest*
 
962
])# _LT_LINKER_BOILERPLATE
 
963
 
 
964
# _LT_REQUIRED_DARWIN_CHECKS
 
965
# --------------------------
 
966
# Check for some things on darwin
 
967
AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[
 
968
  case $host_os in
 
969
    rhapsody* | darwin*)
 
970
    AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
 
971
    AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
 
972
 
 
973
    AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
 
974
      [lt_cv_apple_cc_single_mod=no
 
975
      if test -z "${LT_MULTI_MODULE}"; then
 
976
   # By default we will add the -single_module flag. You can override
 
977
   # by either setting the environment variable LT_MULTI_MODULE
 
978
   # non-empty at configure time, or by adding -multi_module to the
 
979
   # link flags.
 
980
   echo "int foo(void){return 1;}" > conftest.c
 
981
   $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
 
982
     -dynamiclib ${wl}-single_module conftest.c
 
983
   if test -f libconftest.dylib; then
 
984
     lt_cv_apple_cc_single_mod=yes
 
985
     rm -rf libconftest.dylib*
 
986
   fi
 
987
   rm conftest.c
 
988
      fi])
 
989
    AC_CACHE_CHECK([for -exported_symbols_list linker flag],
 
990
      [lt_cv_ld_exported_symbols_list],
 
991
      [lt_cv_ld_exported_symbols_list=no
 
992
      save_LDFLAGS=$LDFLAGS
 
993
      echo "_main" > conftest.sym
 
994
      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
 
995
      AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
 
996
   [lt_cv_ld_exported_symbols_list=yes],
 
997
   [lt_cv_ld_exported_symbols_list=no])
 
998
   LDFLAGS="$save_LDFLAGS"
 
999
    ])
 
1000
    case $host_os in
 
1001
    rhapsody* | darwin1.[[0123]])
 
1002
      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
 
1003
    darwin1.*)
 
1004
     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
 
1005
    darwin*)
 
1006
      # if running on 10.5 or later, the deployment target defaults
 
1007
      # to the OS version, if on x86, and 10.4, the deployment
 
1008
      # target defaults to 10.4. Don't you love it?
 
1009
      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
 
1010
   10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
 
1011
     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
 
1012
   10.[[012]]*)
 
1013
     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
 
1014
   10.*)
 
1015
     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
 
1016
      esac
 
1017
    ;;
 
1018
  esac
 
1019
    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
 
1020
      _lt_dar_single_mod='$single_module'
 
1021
    fi
 
1022
    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
 
1023
      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
 
1024
    else
 
1025
      _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
 
1026
    fi
 
1027
    if test "$DSYMUTIL" != ":"; then
 
1028
      _lt_dsymutil="~$DSYMUTIL \$lib || :"
 
1029
    else
 
1030
      _lt_dsymutil=
 
1031
    fi
 
1032
    ;;
 
1033
  esac
 
1034
])
 
1035
 
 
1036
# _LT_AC_SYS_LIBPATH_AIX
 
1037
# ----------------------
 
1038
# Links a minimal program and checks the executable
 
1039
# for the system default hardcoded library path. In most cases,
 
1040
# this is /usr/lib:/lib, but when the MPI compilers are used
 
1041
# the location of the communication and MPI libs are included too.
 
1042
# If we don't find anything, use the default library path according
 
1043
# to the aix ld manual.
 
1044
AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
 
1045
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1046
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
 
1047
lt_aix_libpath_sed='
 
1048
    /Import File Strings/,/^$/ {
 
1049
        /^0/ {
 
1050
            s/^0  *\(.*\)$/\1/
 
1051
            p
 
1052
        }
 
1053
    }'
 
1054
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 
1055
# Check for a 64-bit object if we didn't find anything.
 
1056
if test -z "$aix_libpath"; then
 
1057
  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 
1058
fi],[])
 
1059
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
1060
])# _LT_AC_SYS_LIBPATH_AIX
 
1061
 
 
1062
 
 
1063
# _LT_AC_SHELL_INIT(ARG)
 
1064
# ----------------------
 
1065
AC_DEFUN([_LT_AC_SHELL_INIT],
 
1066
[ifdef([AC_DIVERSION_NOTICE],
 
1067
             [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
 
1068
         [AC_DIVERT_PUSH(NOTICE)])
 
1069
$1
 
1070
AC_DIVERT_POP
 
1071
])# _LT_AC_SHELL_INIT
 
1072
 
 
1073
 
 
1074
# _LT_AC_PROG_ECHO_BACKSLASH
 
1075
# --------------------------
 
1076
# Add some code to the start of the generated configure script which
 
1077
# will find an echo command which doesn't interpret backslashes.
 
1078
AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
 
1079
[_LT_AC_SHELL_INIT([
 
1080
# Check that we are running under the correct shell.
 
1081
SHELL=${CONFIG_SHELL-/bin/sh}
 
1082
 
 
1083
case X$ECHO in
 
1084
X*--fallback-echo)
 
1085
  # Remove one level of quotation (which was required for Make).
 
1086
  ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
 
1087
  ;;
 
1088
esac
 
1089
 
 
1090
echo=${ECHO-echo}
 
1091
if test "X[$]1" = X--no-reexec; then
 
1092
  # Discard the --no-reexec flag, and continue.
 
1093
  shift
 
1094
elif test "X[$]1" = X--fallback-echo; then
 
1095
  # Avoid inline document here, it may be left over
 
1096
  :
 
1097
elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
 
1098
  # Yippee, $echo works!
 
1099
  :
 
1100
else
 
1101
  # Restart under the correct shell.
 
1102
  exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
 
1103
fi
 
1104
 
 
1105
if test "X[$]1" = X--fallback-echo; then
 
1106
  # used as fallback echo
 
1107
  shift
 
1108
  cat <<EOF
 
1109
[$]*
 
1110
EOF
 
1111
  exit 0
 
1112
fi
 
1113
 
 
1114
# The HP-UX ksh and POSIX shell print the target directory to stdout
 
1115
# if CDPATH is set.
 
1116
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
 
1117
 
 
1118
if test -z "$ECHO"; then
 
1119
if test "X${echo_test_string+set}" != Xset; then
 
1120
# find a string as large as possible, as long as the shell can cope with it
 
1121
  for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
 
1122
    # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
 
1123
    if (echo_test_string=`eval $cmd`) 2>/dev/null &&
 
1124
       echo_test_string=`eval $cmd` &&
 
1125
       (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
 
1126
    then
 
1127
      break
 
1128
    fi
 
1129
  done
 
1130
fi
 
1131
 
 
1132
if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
 
1133
   echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
 
1134
   test "X$echo_testing_string" = "X$echo_test_string"; then
 
1135
  :
 
1136
else
 
1137
  # The Solaris, AIX, and Digital Unix default echo programs unquote
 
1138
  # backslashes.  This makes it impossible to quote backslashes using
 
1139
  #   echo "$something" | sed 's/\\/\\\\/g'
 
1140
  #
 
1141
  # So, first we look for a working echo in the user's PATH.
 
1142
 
 
1143
  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
 
1144
  for dir in $PATH /usr/ucb; do
 
1145
    IFS="$lt_save_ifs"
 
1146
    if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
 
1147
       test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
 
1148
       echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
 
1149
       test "X$echo_testing_string" = "X$echo_test_string"; then
 
1150
      echo="$dir/echo"
 
1151
      break
 
1152
    fi
 
1153
  done
 
1154
  IFS="$lt_save_ifs"
 
1155
 
 
1156
  if test "X$echo" = Xecho; then
 
1157
    # We didn't find a better echo, so look for alternatives.
 
1158
    if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
 
1159
       echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
 
1160
       test "X$echo_testing_string" = "X$echo_test_string"; then
 
1161
      # This shell has a builtin print -r that does the trick.
 
1162
      echo='print -r'
 
1163
    elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
 
1164
         test "X$CONFIG_SHELL" != X/bin/ksh; then
 
1165
      # If we have ksh, try running configure again with it.
 
1166
      ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
 
1167
      export ORIGINAL_CONFIG_SHELL
 
1168
      CONFIG_SHELL=/bin/ksh
 
1169
      export CONFIG_SHELL
 
1170
      exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
 
1171
    else
 
1172
      # Try using printf.
 
1173
      echo='printf %s\n'
 
1174
      if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
 
1175
         echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
 
1176
         test "X$echo_testing_string" = "X$echo_test_string"; then
 
1177
        # Cool, printf works
 
1178
        :
 
1179
      elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
 
1180
           test "X$echo_testing_string" = 'X\t' &&
 
1181
           echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
 
1182
           test "X$echo_testing_string" = "X$echo_test_string"; then
 
1183
        CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
 
1184
        export CONFIG_SHELL
 
1185
        SHELL="$CONFIG_SHELL"
 
1186
        export SHELL
 
1187
        echo="$CONFIG_SHELL [$]0 --fallback-echo"
 
1188
      elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
 
1189
           test "X$echo_testing_string" = 'X\t' &&
 
1190
           echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
 
1191
           test "X$echo_testing_string" = "X$echo_test_string"; then
 
1192
        echo="$CONFIG_SHELL [$]0 --fallback-echo"
 
1193
      else
 
1194
        # maybe with a smaller string...
 
1195
        prev=:
 
1196
 
 
1197
        for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
 
1198
          if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
 
1199
          then
 
1200
            break
 
1201
          fi
 
1202
          prev="$cmd"
 
1203
        done
 
1204
 
 
1205
        if test "$prev" != 'sed 50q "[$]0"'; then
 
1206
          echo_test_string=`eval $prev`
 
1207
          export echo_test_string
 
1208
          exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
 
1209
        else
 
1210
          # Oops.  We lost completely, so just stick with echo.
 
1211
          echo=echo
 
1212
        fi
 
1213
      fi
 
1214
    fi
 
1215
  fi
 
1216
fi
 
1217
fi
 
1218
 
 
1219
# Copy echo and quote the copy suitably for passing to libtool from
 
1220
# the Makefile, instead of quoting the original, which is used later.
 
1221
ECHO=$echo
 
1222
if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
 
1223
   ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
 
1224
fi
 
1225
 
 
1226
AC_SUBST(ECHO)
 
1227
])])# _LT_AC_PROG_ECHO_BACKSLASH
 
1228
 
 
1229
 
 
1230
# _LT_AC_LOCK
 
1231
# -----------
 
1232
AC_DEFUN([_LT_AC_LOCK],
 
1233
[AC_ARG_ENABLE([libtool-lock],
 
1234
    [AC_HELP_STRING([--disable-libtool-lock],
 
1235
        [avoid locking (might break parallel builds)])])
 
1236
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
 
1237
 
 
1238
# Some flags need to be propagated to the compiler or linker for good
 
1239
# libtool support.
 
1240
case $host in
 
1241
ia64-*-hpux*)
 
1242
  # Find out which ABI we are using.
 
1243
  echo 'int i;' > conftest.$ac_ext
 
1244
  if AC_TRY_EVAL(ac_compile); then
 
1245
    case `/usr/bin/file conftest.$ac_objext` in
 
1246
    *ELF-32*)
 
1247
      HPUX_IA64_MODE="32"
 
1248
      ;;
 
1249
    *ELF-64*)
 
1250
      HPUX_IA64_MODE="64"
 
1251
      ;;
 
1252
    esac
 
1253
  fi
 
1254
  rm -rf conftest*
 
1255
  ;;
 
1256
*-*-irix6*)
 
1257
  # Find out which ABI we are using.
 
1258
  echo '[#]line __oline__ "configure"' > conftest.$ac_ext
 
1259
  if AC_TRY_EVAL(ac_compile); then
 
1260
   if test "$lt_cv_prog_gnu_ld" = yes; then
 
1261
    case `/usr/bin/file conftest.$ac_objext` in
 
1262
    *32-bit*)
 
1263
      LD="${LD-ld} -melf32bsmip"
 
1264
      ;;
 
1265
    *N32*)
 
1266
      LD="${LD-ld} -melf32bmipn32"
 
1267
      ;;
 
1268
    *64-bit*)
 
1269
      LD="${LD-ld} -melf64bmip"
 
1270
      ;;
 
1271
    esac
 
1272
   else
 
1273
    case `/usr/bin/file conftest.$ac_objext` in
 
1274
    *32-bit*)
 
1275
      LD="${LD-ld} -32"
 
1276
      ;;
 
1277
    *N32*)
 
1278
      LD="${LD-ld} -n32"
 
1279
      ;;
 
1280
    *64-bit*)
 
1281
      LD="${LD-ld} -64"
 
1282
      ;;
 
1283
    esac
 
1284
   fi
 
1285
  fi
 
1286
  rm -rf conftest*
 
1287
  ;;
 
1288
 
 
1289
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
 
1290
s390*-*linux*|sparc*-*linux*)
 
1291
  # Find out which ABI we are using.
 
1292
  echo 'int i;' > conftest.$ac_ext
 
1293
  if AC_TRY_EVAL(ac_compile); then
 
1294
    case `/usr/bin/file conftest.o` in
 
1295
    *32-bit*)
 
1296
      case $host in
 
1297
        x86_64-*kfreebsd*-gnu)
 
1298
          LD="${LD-ld} -m elf_i386_fbsd"
 
1299
          ;;
 
1300
        x86_64-*linux*)
 
1301
          LD="${LD-ld} -m elf_i386"
 
1302
          ;;
 
1303
        ppc64-*linux*|powerpc64-*linux*)
 
1304
          LD="${LD-ld} -m elf32ppclinux"
 
1305
          ;;
 
1306
        s390x-*linux*)
 
1307
          LD="${LD-ld} -m elf_s390"
 
1308
          ;;
 
1309
        sparc64-*linux*)
 
1310
          LD="${LD-ld} -m elf32_sparc"
 
1311
          ;;
 
1312
      esac
 
1313
      ;;
 
1314
    *64-bit*)
 
1315
      libsuff=64
 
1316
      case $host in
 
1317
        x86_64-*kfreebsd*-gnu)
 
1318
          LD="${LD-ld} -m elf_x86_64_fbsd"
 
1319
          ;;
 
1320
        x86_64-*linux*)
 
1321
          LD="${LD-ld} -m elf_x86_64"
 
1322
          ;;
 
1323
        ppc*-*linux*|powerpc*-*linux*)
 
1324
          LD="${LD-ld} -m elf64ppc"
 
1325
          ;;
 
1326
        s390*-*linux*)
 
1327
          LD="${LD-ld} -m elf64_s390"
 
1328
          ;;
 
1329
        sparc*-*linux*)
 
1330
          LD="${LD-ld} -m elf64_sparc"
 
1331
          ;;
 
1332
      esac
 
1333
      ;;
 
1334
    esac
 
1335
  fi
 
1336
  rm -rf conftest*
 
1337
  ;;
 
1338
 
 
1339
*-*-sco3.2v5*)
 
1340
  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
 
1341
  SAVE_CFLAGS="$CFLAGS"
 
1342
  CFLAGS="$CFLAGS -belf"
 
1343
  AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
 
1344
    [AC_LANG_PUSH(C)
 
1345
     AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
 
1346
     AC_LANG_POP])
 
1347
  if test x"$lt_cv_cc_needs_belf" != x"yes"; then
 
1348
    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
 
1349
    CFLAGS="$SAVE_CFLAGS"
 
1350
  fi
 
1351
  ;;
 
1352
sparc*-*solaris*)
 
1353
  # Find out which ABI we are using.
 
1354
  echo 'int i;' > conftest.$ac_ext
 
1355
  if AC_TRY_EVAL(ac_compile); then
 
1356
    case `/usr/bin/file conftest.o` in
 
1357
    *64-bit*)
 
1358
      case $lt_cv_prog_gnu_ld in
 
1359
      yes*) LD="${LD-ld} -m elf64_sparc" ;;
 
1360
      *)
 
1361
        if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
 
1362
          LD="${LD-ld} -64"
 
1363
        fi
 
1364
        ;;
 
1365
      esac
 
1366
      ;;
 
1367
    esac
 
1368
  fi
 
1369
  rm -rf conftest*
 
1370
  ;;
 
1371
 
 
1372
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
 
1373
[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
 
1374
  AC_CHECK_TOOL(DLLTOOL, dlltool, false)
 
1375
  AC_CHECK_TOOL(AS, as, false)
 
1376
  AC_CHECK_TOOL(OBJDUMP, objdump, false)
 
1377
  ;;
 
1378
  ])
 
1379
esac
 
1380
 
 
1381
need_locks="$enable_libtool_lock"
 
1382
 
 
1383
])# _LT_AC_LOCK
 
1384
 
 
1385
 
 
1386
# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
 
1387
#               [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
 
1388
# ----------------------------------------------------------------
 
1389
# Check whether the given compiler option works
 
1390
AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
 
1391
[AC_REQUIRE([LT_AC_PROG_SED])
 
1392
AC_CACHE_CHECK([$1], [$2],
 
1393
  [$2=no
 
1394
  ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
 
1395
   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
1396
   lt_compiler_flag="$3"
 
1397
   # Insert the option either (1) after the last *FLAGS variable, or
 
1398
   # (2) before a word containing "conftest.", or (3) at the end.
 
1399
   # Note that $ac_compile itself does not contain backslashes and begins
 
1400
   # with a dollar sign (not a hyphen), so the echo should work correctly.
 
1401
   # The option is referenced via a variable to avoid confusing sed.
 
1402
   lt_compile=`echo "$ac_compile" | $SED \
 
1403
   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
 
1404
   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
 
1405
   -e 's:$: $lt_compiler_flag:'`
 
1406
   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
 
1407
   (eval "$lt_compile" 2>conftest.err)
 
1408
   ac_status=$?
 
1409
   cat conftest.err >&AS_MESSAGE_LOG_FD
 
1410
   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
 
1411
   if (exit $ac_status) && test -s "$ac_outfile"; then
 
1412
     # The compiler can only warn and ignore the option if not recognized
 
1413
     # So say no if there are warnings other than the usual output.
 
1414
     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
 
1415
     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
 
1416
     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
 
1417
       $2=yes
 
1418
     fi
 
1419
   fi
 
1420
   $rm conftest*
 
1421
])
 
1422
 
 
1423
if test x"[$]$2" = xyes; then
 
1424
    ifelse([$5], , :, [$5])
 
1425
else
 
1426
    ifelse([$6], , :, [$6])
 
1427
fi
 
1428
])# AC_LIBTOOL_COMPILER_OPTION
 
1429
 
 
1430
 
 
1431
# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
 
1432
#                          [ACTION-SUCCESS], [ACTION-FAILURE])
 
1433
# ------------------------------------------------------------
 
1434
# Check whether the given compiler option works
 
1435
AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
 
1436
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1437
AC_CACHE_CHECK([$1], [$2],
 
1438
  [$2=no
 
1439
   save_LDFLAGS="$LDFLAGS"
 
1440
   LDFLAGS="$LDFLAGS $3"
 
1441
   echo "$lt_simple_link_test_code" > conftest.$ac_ext
 
1442
   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
 
1443
     # The linker can only warn and ignore the option if not recognized
 
1444
     # So say no if there are warnings
 
1445
     if test -s conftest.err; then
 
1446
       # Append any errors to the config.log.
 
1447
       cat conftest.err 1>&AS_MESSAGE_LOG_FD
 
1448
       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
 
1449
       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
 
1450
       if diff conftest.exp conftest.er2 >/dev/null; then
 
1451
         $2=yes
 
1452
       fi
 
1453
     else
 
1454
       $2=yes
 
1455
     fi
 
1456
   fi
 
1457
   $rm -r conftest*
 
1458
   LDFLAGS="$save_LDFLAGS"
 
1459
])
 
1460
 
 
1461
if test x"[$]$2" = xyes; then
 
1462
    ifelse([$4], , :, [$4])
 
1463
else
 
1464
    ifelse([$5], , :, [$5])
 
1465
fi
 
1466
])# AC_LIBTOOL_LINKER_OPTION
 
1467
 
 
1468
 
 
1469
# AC_LIBTOOL_SYS_MAX_CMD_LEN
 
1470
# --------------------------
 
1471
AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
 
1472
[# find the maximum length of command line arguments
 
1473
AC_MSG_CHECKING([the maximum length of command line arguments])
 
1474
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
 
1475
  i=0
 
1476
  teststring="ABCD"
 
1477
 
 
1478
  case $build_os in
 
1479
  msdosdjgpp*)
 
1480
    # On DJGPP, this test can blow up pretty badly due to problems in libc
 
1481
    # (any single argument exceeding 2000 bytes causes a buffer overrun
 
1482
    # during glob expansion).  Even if it were fixed, the result of this
 
1483
    # check would be larger than it should be.
 
1484
    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
 
1485
    ;;
 
1486
 
 
1487
  gnu*)
 
1488
    # Under GNU Hurd, this test is not required because there is
 
1489
    # no limit to the length of command line arguments.
 
1490
    # Libtool will interpret -1 as no limit whatsoever
 
1491
    lt_cv_sys_max_cmd_len=-1;
 
1492
    ;;
 
1493
 
 
1494
  cygwin* | mingw*)
 
1495
    # On Win9x/ME, this test blows up -- it succeeds, but takes
 
1496
    # about 5 minutes as the teststring grows exponentially.
 
1497
    # Worse, since 9x/ME are not pre-emptively multitasking,
 
1498
    # you end up with a "frozen" computer, even though with patience
 
1499
    # the test eventually succeeds (with a max line length of 256k).
 
1500
    # Instead, let's just punt: use the minimum linelength reported by
 
1501
    # all of the supported platforms: 8192 (on NT/2K/XP).
 
1502
    lt_cv_sys_max_cmd_len=8192;
 
1503
    ;;
 
1504
 
 
1505
  amigaos*)
 
1506
    # On AmigaOS with pdksh, this test takes hours, literally.
 
1507
    # So we just punt and use a minimum line length of 8192.
 
1508
    lt_cv_sys_max_cmd_len=8192;
 
1509
    ;;
 
1510
 
 
1511
  netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
 
1512
    # This has been around since 386BSD, at least.  Likely further.
 
1513
    if test -x /sbin/sysctl; then
 
1514
      lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
 
1515
    elif test -x /usr/sbin/sysctl; then
 
1516
      lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
 
1517
    else
 
1518
      lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
 
1519
    fi
 
1520
    # And add a safety zone
 
1521
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
 
1522
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
 
1523
    ;;
 
1524
 
 
1525
  interix*)
 
1526
    # We know the value 262144 and hardcode it with a safety zone (like BSD)
 
1527
    lt_cv_sys_max_cmd_len=196608
 
1528
    ;;
 
1529
 
 
1530
  osf*)
 
1531
    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
 
1532
    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
 
1533
    # nice to cause kernel panics so lets avoid the loop below.
 
1534
    # First set a reasonable default.
 
1535
    lt_cv_sys_max_cmd_len=16384
 
1536
    #
 
1537
    if test -x /sbin/sysconfig; then
 
1538
      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
 
1539
        *1*) lt_cv_sys_max_cmd_len=-1 ;;
 
1540
      esac
 
1541
    fi
 
1542
    ;;
 
1543
  sco3.2v5*)
 
1544
    lt_cv_sys_max_cmd_len=102400
 
1545
    ;;
 
1546
  sysv5* | sco5v6* | sysv4.2uw2*)
 
1547
    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
 
1548
    if test -n "$kargmax"; then
 
1549
      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[        ]]//'`
 
1550
    else
 
1551
      lt_cv_sys_max_cmd_len=32768
 
1552
    fi
 
1553
    ;;
 
1554
  *)
 
1555
    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
 
1556
    if test -n "$lt_cv_sys_max_cmd_len"; then
 
1557
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
 
1558
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
 
1559
    else
 
1560
      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
 
1561
      while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
 
1562
               = "XX$teststring") >/dev/null 2>&1 &&
 
1563
              new_result=`expr "X$teststring" : ".*" 2>&1` &&
 
1564
              lt_cv_sys_max_cmd_len=$new_result &&
 
1565
              test $i != 17 # 1/2 MB should be enough
 
1566
      do
 
1567
        i=`expr $i + 1`
 
1568
        teststring=$teststring$teststring
 
1569
      done
 
1570
      teststring=
 
1571
      # Add a significant safety factor because C++ compilers can tack on massive
 
1572
      # amounts of additional arguments before passing them to the linker.
 
1573
      # It appears as though 1/2 is a usable value.
 
1574
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
 
1575
    fi
 
1576
    ;;
 
1577
  esac
 
1578
])
 
1579
if test -n $lt_cv_sys_max_cmd_len ; then
 
1580
  AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
 
1581
else
 
1582
  AC_MSG_RESULT(none)
 
1583
fi
 
1584
])# AC_LIBTOOL_SYS_MAX_CMD_LEN
 
1585
 
 
1586
 
 
1587
# _LT_AC_CHECK_DLFCN
 
1588
# ------------------
 
1589
AC_DEFUN([_LT_AC_CHECK_DLFCN],
 
1590
[AC_CHECK_HEADERS(dlfcn.h)dnl
 
1591
])# _LT_AC_CHECK_DLFCN
 
1592
 
 
1593
 
 
1594
# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
 
1595
#                           ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
 
1596
# ---------------------------------------------------------------------
 
1597
AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
 
1598
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
 
1599
if test "$cross_compiling" = yes; then :
 
1600
  [$4]
 
1601
else
 
1602
  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
 
1603
  lt_status=$lt_dlunknown
 
1604
  cat > conftest.$ac_ext <<EOF
 
1605
[#line __oline__ "configure"
 
1606
#include "confdefs.h"
 
1607
 
 
1608
#if HAVE_DLFCN_H
 
1609
#include <dlfcn.h>
 
1610
#endif
 
1611
 
 
1612
#include <stdio.h>
 
1613
 
 
1614
#ifdef RTLD_GLOBAL
 
1615
#  define LT_DLGLOBAL           RTLD_GLOBAL
 
1616
#else
 
1617
#  ifdef DL_GLOBAL
 
1618
#    define LT_DLGLOBAL         DL_GLOBAL
 
1619
#  else
 
1620
#    define LT_DLGLOBAL         0
 
1621
#  endif
 
1622
#endif
 
1623
 
 
1624
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
 
1625
   find out it does not work in some platform. */
 
1626
#ifndef LT_DLLAZY_OR_NOW
 
1627
#  ifdef RTLD_LAZY
 
1628
#    define LT_DLLAZY_OR_NOW            RTLD_LAZY
 
1629
#  else
 
1630
#    ifdef DL_LAZY
 
1631
#      define LT_DLLAZY_OR_NOW          DL_LAZY
 
1632
#    else
 
1633
#      ifdef RTLD_NOW
 
1634
#        define LT_DLLAZY_OR_NOW        RTLD_NOW
 
1635
#      else
 
1636
#        ifdef DL_NOW
 
1637
#          define LT_DLLAZY_OR_NOW      DL_NOW
 
1638
#        else
 
1639
#          define LT_DLLAZY_OR_NOW      0
 
1640
#        endif
 
1641
#      endif
 
1642
#    endif
 
1643
#  endif
 
1644
#endif
 
1645
 
 
1646
#ifdef __cplusplus
 
1647
extern "C" void exit (int);
 
1648
#endif
 
1649
 
 
1650
void fnord() { int i=42;}
 
1651
int main ()
 
1652
{
 
1653
  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
 
1654
  int status = $lt_dlunknown;
 
1655
 
 
1656
  if (self)
 
1657
    {
 
1658
      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
 
1659
      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
 
1660
      /* dlclose (self); */
 
1661
    }
 
1662
  else
 
1663
    puts (dlerror ());
 
1664
 
 
1665
    exit (status);
 
1666
}]
 
1667
EOF
 
1668
  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
 
1669
    (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
 
1670
    lt_status=$?
 
1671
    case x$lt_status in
 
1672
      x$lt_dlno_uscore) $1 ;;
 
1673
      x$lt_dlneed_uscore) $2 ;;
 
1674
      x$lt_dlunknown|x*) $3 ;;
 
1675
    esac
 
1676
  else :
 
1677
    # compilation failed
 
1678
    $3
 
1679
  fi
 
1680
fi
 
1681
rm -fr conftest*
 
1682
])# _LT_AC_TRY_DLOPEN_SELF
 
1683
 
 
1684
 
 
1685
# AC_LIBTOOL_DLOPEN_SELF
 
1686
# ----------------------
 
1687
AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
 
1688
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
 
1689
if test "x$enable_dlopen" != xyes; then
 
1690
  enable_dlopen=unknown
 
1691
  enable_dlopen_self=unknown
 
1692
  enable_dlopen_self_static=unknown
 
1693
else
 
1694
  lt_cv_dlopen=no
 
1695
  lt_cv_dlopen_libs=
 
1696
 
 
1697
  case $host_os in
 
1698
  beos*)
 
1699
    lt_cv_dlopen="load_add_on"
 
1700
    lt_cv_dlopen_libs=
 
1701
    lt_cv_dlopen_self=yes
 
1702
    ;;
 
1703
 
 
1704
  mingw* | pw32*)
 
1705
    lt_cv_dlopen="LoadLibrary"
 
1706
    lt_cv_dlopen_libs=
 
1707
   ;;
 
1708
 
 
1709
  cygwin*)
 
1710
    lt_cv_dlopen="dlopen"
 
1711
    lt_cv_dlopen_libs=
 
1712
   ;;
 
1713
 
 
1714
  darwin*)
 
1715
  # if libdl is installed we need to link against it
 
1716
    AC_CHECK_LIB([dl], [dlopen],
 
1717
                [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
 
1718
    lt_cv_dlopen="dyld"
 
1719
    lt_cv_dlopen_libs=
 
1720
    lt_cv_dlopen_self=yes
 
1721
    ])
 
1722
   ;;
 
1723
 
 
1724
  *)
 
1725
    AC_CHECK_FUNC([shl_load],
 
1726
          [lt_cv_dlopen="shl_load"],
 
1727
      [AC_CHECK_LIB([dld], [shl_load],
 
1728
            [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
 
1729
        [AC_CHECK_FUNC([dlopen],
 
1730
              [lt_cv_dlopen="dlopen"],
 
1731
          [AC_CHECK_LIB([dl], [dlopen],
 
1732
                [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
 
1733
            [AC_CHECK_LIB([svld], [dlopen],
 
1734
                  [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
 
1735
              [AC_CHECK_LIB([dld], [dld_link],
 
1736
                    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
 
1737
              ])
 
1738
            ])
 
1739
          ])
 
1740
        ])
 
1741
      ])
 
1742
    ;;
 
1743
  esac
 
1744
 
 
1745
  if test "x$lt_cv_dlopen" != xno; then
 
1746
    enable_dlopen=yes
 
1747
  else
 
1748
    enable_dlopen=no
 
1749
  fi
 
1750
 
 
1751
  case $lt_cv_dlopen in
 
1752
  dlopen)
 
1753
    save_CPPFLAGS="$CPPFLAGS"
 
1754
    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
 
1755
 
 
1756
    save_LDFLAGS="$LDFLAGS"
 
1757
    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
 
1758
 
 
1759
    save_LIBS="$LIBS"
 
1760
    LIBS="$lt_cv_dlopen_libs $LIBS"
 
1761
 
 
1762
    AC_CACHE_CHECK([whether a program can dlopen itself],
 
1763
          lt_cv_dlopen_self, [dnl
 
1764
          _LT_AC_TRY_DLOPEN_SELF(
 
1765
            lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
 
1766
            lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
 
1767
    ])
 
1768
 
 
1769
    if test "x$lt_cv_dlopen_self" = xyes; then
 
1770
      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
 
1771
      AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
 
1772
          lt_cv_dlopen_self_static, [dnl
 
1773
          _LT_AC_TRY_DLOPEN_SELF(
 
1774
            lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
 
1775
            lt_cv_dlopen_self_static=no,  lt_cv_dlopen_self_static=cross)
 
1776
      ])
 
1777
    fi
 
1778
 
 
1779
    CPPFLAGS="$save_CPPFLAGS"
 
1780
    LDFLAGS="$save_LDFLAGS"
 
1781
    LIBS="$save_LIBS"
 
1782
    ;;
 
1783
  esac
 
1784
 
 
1785
  case $lt_cv_dlopen_self in
 
1786
  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
 
1787
  *) enable_dlopen_self=unknown ;;
 
1788
  esac
 
1789
 
 
1790
  case $lt_cv_dlopen_self_static in
 
1791
  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
 
1792
  *) enable_dlopen_self_static=unknown ;;
 
1793
  esac
 
1794
fi
 
1795
])# AC_LIBTOOL_DLOPEN_SELF
 
1796
 
 
1797
 
 
1798
# AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
 
1799
# ---------------------------------
 
1800
# Check to see if options -c and -o are simultaneously supported by compiler
 
1801
AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
 
1802
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1803
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
 
1804
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
 
1805
  [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
 
1806
  [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
 
1807
   $rm -r conftest 2>/dev/null
 
1808
   mkdir conftest
 
1809
   cd conftest
 
1810
   mkdir out
 
1811
   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
1812
 
 
1813
   lt_compiler_flag="-o out/conftest2.$ac_objext"
 
1814
   # Insert the option either (1) after the last *FLAGS variable, or
 
1815
   # (2) before a word containing "conftest.", or (3) at the end.
 
1816
   # Note that $ac_compile itself does not contain backslashes and begins
 
1817
   # with a dollar sign (not a hyphen), so the echo should work correctly.
 
1818
   lt_compile=`echo "$ac_compile" | $SED \
 
1819
   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
 
1820
   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
 
1821
   -e 's:$: $lt_compiler_flag:'`
 
1822
   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
 
1823
   (eval "$lt_compile" 2>out/conftest.err)
 
1824
   ac_status=$?
 
1825
   cat out/conftest.err >&AS_MESSAGE_LOG_FD
 
1826
   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
 
1827
   if (exit $ac_status) && test -s out/conftest2.$ac_objext
 
1828
   then
 
1829
     # The compiler can only warn and ignore the option if not recognized
 
1830
     # So say no if there are warnings
 
1831
     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
 
1832
     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
 
1833
     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
 
1834
       _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
 
1835
     fi
 
1836
   fi
 
1837
   chmod u+w . 2>&AS_MESSAGE_LOG_FD
 
1838
   $rm conftest*
 
1839
   # SGI C++ compiler will create directory out/ii_files/ for
 
1840
   # template instantiation
 
1841
   test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
 
1842
   $rm out/* && rmdir out
 
1843
   cd ..
 
1844
   rmdir conftest
 
1845
   $rm conftest*
 
1846
])
 
1847
])# AC_LIBTOOL_PROG_CC_C_O
 
1848
 
 
1849
 
 
1850
# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
 
1851
# -----------------------------------------
 
1852
# Check to see if we can do hard links to lock some files if needed
 
1853
AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
 
1854
[AC_REQUIRE([_LT_AC_LOCK])dnl
 
1855
 
 
1856
hard_links="nottested"
 
1857
if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
 
1858
  # do not overwrite the value of need_locks provided by the user
 
1859
  AC_MSG_CHECKING([if we can lock with hard links])
 
1860
  hard_links=yes
 
1861
  $rm conftest*
 
1862
  ln conftest.a conftest.b 2>/dev/null && hard_links=no
 
1863
  touch conftest.a
 
1864
  ln conftest.a conftest.b 2>&5 || hard_links=no
 
1865
  ln conftest.a conftest.b 2>/dev/null && hard_links=no
 
1866
  AC_MSG_RESULT([$hard_links])
 
1867
  if test "$hard_links" = no; then
 
1868
    AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
 
1869
    need_locks=warn
 
1870
  fi
 
1871
else
 
1872
  need_locks=no
 
1873
fi
 
1874
])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
 
1875
 
 
1876
 
 
1877
# AC_LIBTOOL_OBJDIR
 
1878
# -----------------
 
1879
AC_DEFUN([AC_LIBTOOL_OBJDIR],
 
1880
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
 
1881
[rm -f .libs 2>/dev/null
 
1882
mkdir .libs 2>/dev/null
 
1883
if test -d .libs; then
 
1884
  lt_cv_objdir=.libs
 
1885
else
 
1886
  # MS-DOS does not allow filenames that begin with a dot.
 
1887
  lt_cv_objdir=_libs
 
1888
fi
 
1889
rmdir .libs 2>/dev/null])
 
1890
objdir=$lt_cv_objdir
 
1891
])# AC_LIBTOOL_OBJDIR
 
1892
 
 
1893
 
 
1894
# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
 
1895
# ----------------------------------------------
 
1896
# Check hardcoding attributes.
 
1897
AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
 
1898
[AC_MSG_CHECKING([how to hardcode library paths into programs])
 
1899
_LT_AC_TAGVAR(hardcode_action, $1)=
 
1900
if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
 
1901
   test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
 
1902
   test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
 
1903
 
 
1904
  # We can hardcode non-existant directories.
 
1905
  if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
 
1906
     # If the only mechanism to avoid hardcoding is shlibpath_var, we
 
1907
     # have to relink, otherwise we might link with an installed library
 
1908
     # when we should be linking with a yet-to-be-installed one
 
1909
     ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
 
1910
     test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
 
1911
    # Linking always hardcodes the temporary library directory.
 
1912
    _LT_AC_TAGVAR(hardcode_action, $1)=relink
 
1913
  else
 
1914
    # We can link without hardcoding, and we can hardcode nonexisting dirs.
 
1915
    _LT_AC_TAGVAR(hardcode_action, $1)=immediate
 
1916
  fi
 
1917
else
 
1918
  # We cannot hardcode anything, or else we can only hardcode existing
 
1919
  # directories.
 
1920
  _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
 
1921
fi
 
1922
AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
 
1923
 
 
1924
if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
 
1925
  # Fast installation is not supported
 
1926
  enable_fast_install=no
 
1927
elif test "$shlibpath_overrides_runpath" = yes ||
 
1928
     test "$enable_shared" = no; then
 
1929
  # Fast installation is not necessary
 
1930
  enable_fast_install=needless
 
1931
fi
 
1932
])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
 
1933
 
 
1934
 
 
1935
# AC_LIBTOOL_SYS_LIB_STRIP
 
1936
# ------------------------
 
1937
AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
 
1938
[striplib=
 
1939
old_striplib=
 
1940
AC_MSG_CHECKING([whether stripping libraries is possible])
 
1941
if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
 
1942
  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
 
1943
  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
 
1944
  AC_MSG_RESULT([yes])
 
1945
else
 
1946
# FIXME - insert some real tests, host_os isn't really good enough
 
1947
  case $host_os in
 
1948
   darwin*)
 
1949
       if test -n "$STRIP" ; then
 
1950
         striplib="$STRIP -x"
 
1951
         old_striplib="$STRIP -S"
 
1952
         AC_MSG_RESULT([yes])
 
1953
       else
 
1954
  AC_MSG_RESULT([no])
 
1955
fi
 
1956
       ;;
 
1957
   *)
 
1958
  AC_MSG_RESULT([no])
 
1959
    ;;
 
1960
  esac
 
1961
fi
 
1962
])# AC_LIBTOOL_SYS_LIB_STRIP
 
1963
 
 
1964
 
 
1965
# AC_LIBTOOL_SYS_DYNAMIC_LINKER
 
1966
# -----------------------------
 
1967
# PORTME Fill in your ld.so characteristics
 
1968
AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
 
1969
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1970
AC_MSG_CHECKING([dynamic linker characteristics])
 
1971
library_names_spec=
 
1972
libname_spec='lib$name'
 
1973
soname_spec=
 
1974
shrext_cmds=".so"
 
1975
postinstall_cmds=
 
1976
postuninstall_cmds=
 
1977
finish_cmds=
 
1978
finish_eval=
 
1979
shlibpath_var=
 
1980
shlibpath_overrides_runpath=unknown
 
1981
version_type=none
 
1982
dynamic_linker="$host_os ld.so"
 
1983
sys_lib_dlsearch_path_spec="/lib /usr/lib"
 
1984
m4_if($1,[],[
 
1985
if test "$GCC" = yes; then
 
1986
  case $host_os in
 
1987
    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
 
1988
    *) lt_awk_arg="/^libraries:/" ;;
 
1989
  esac
 
1990
  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
 
1991
  if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
 
1992
    # if the path contains ";" then we assume it to be the separator
 
1993
    # otherwise default to the standard path separator (i.e. ":") - it is
 
1994
    # assumed that no part of a normal pathname contains ";" but that should
 
1995
    # okay in the real world where ";" in dirpaths is itself problematic.
 
1996
    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
 
1997
  else
 
1998
    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
 
1999
  fi
 
2000
  # Ok, now we have the path, separated by spaces, we can step through it
 
2001
  # and add multilib dir if necessary.
 
2002
  lt_tmp_lt_search_path_spec=
 
2003
  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
 
2004
  for lt_sys_path in $lt_search_path_spec; do
 
2005
    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
 
2006
      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
 
2007
    else
 
2008
      test -d "$lt_sys_path" && \
 
2009
        lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
 
2010
    fi
 
2011
  done
 
2012
  lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
 
2013
BEGIN {RS=" "; FS="/|\n";} {
 
2014
  lt_foo="";
 
2015
  lt_count=0;
 
2016
  for (lt_i = NF; lt_i > 0; lt_i--) {
 
2017
    if ($lt_i != "" && $lt_i != ".") {
 
2018
      if ($lt_i == "..") {
 
2019
        lt_count++;
 
2020
      } else {
 
2021
        if (lt_count == 0) {
 
2022
          lt_foo="/" $lt_i lt_foo;
 
2023
        } else {
 
2024
          lt_count--;
 
2025
        }
 
2026
      }
 
2027
    }
 
2028
  }
 
2029
  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
 
2030
  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
 
2031
}'`
 
2032
  sys_lib_search_path_spec=`echo $lt_search_path_spec`
 
2033
else
 
2034
  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
 
2035
fi])
 
2036
need_lib_prefix=unknown
 
2037
hardcode_into_libs=no
 
2038
 
 
2039
# when you set need_version to no, make sure it does not cause -set_version
 
2040
# flags to be left without arguments
 
2041
need_version=unknown
 
2042
 
 
2043
case $host_os in
 
2044
aix3*)
 
2045
  version_type=linux
 
2046
  library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
 
2047
  shlibpath_var=LIBPATH
 
2048
 
 
2049
  # AIX 3 has no versioning support, so we append a major version to the name.
 
2050
  soname_spec='${libname}${release}${shared_ext}$major'
 
2051
  ;;
 
2052
 
 
2053
aix[[4-9]]*)
 
2054
  version_type=linux
 
2055
  need_lib_prefix=no
 
2056
  need_version=no
 
2057
  hardcode_into_libs=yes
 
2058
  if test "$host_cpu" = ia64; then
 
2059
    # AIX 5 supports IA64
 
2060
    library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
 
2061
    shlibpath_var=LD_LIBRARY_PATH
 
2062
  else
 
2063
    # With GCC up to 2.95.x, collect2 would create an import file
 
2064
    # for dependence libraries.  The import file would start with
 
2065
    # the line `#! .'.  This would cause the generated library to
 
2066
    # depend on `.', always an invalid library.  This was fixed in
 
2067
    # development snapshots of GCC prior to 3.0.
 
2068
    case $host_os in
 
2069
      aix4 | aix4.[[01]] | aix4.[[01]].*)
 
2070
      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
 
2071
           echo ' yes '
 
2072
           echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
 
2073
        :
 
2074
      else
 
2075
        can_build_shared=no
 
2076
      fi
 
2077
      ;;
 
2078
    esac
 
2079
    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
 
2080
    # soname into executable. Probably we can add versioning support to
 
2081
    # collect2, so additional links can be useful in future.
 
2082
    if test "$aix_use_runtimelinking" = yes; then
 
2083
      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
 
2084
      # instead of lib<name>.a to let people know that these are not
 
2085
      # typical AIX shared libraries.
 
2086
      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2087
    else
 
2088
      # We preserve .a as extension for shared libraries through AIX4.2
 
2089
      # and later when we are not doing run time linking.
 
2090
      library_names_spec='${libname}${release}.a $libname.a'
 
2091
      soname_spec='${libname}${release}${shared_ext}$major'
 
2092
    fi
 
2093
    shlibpath_var=LIBPATH
 
2094
  fi
 
2095
  ;;
 
2096
 
 
2097
amigaos*)
 
2098
  library_names_spec='$libname.ixlibrary $libname.a'
 
2099
  # Create ${libname}_ixlibrary.a entries in /sys/libs.
 
2100
  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'
 
2101
  ;;
 
2102
 
 
2103
beos*)
 
2104
  library_names_spec='${libname}${shared_ext}'
 
2105
  dynamic_linker="$host_os ld.so"
 
2106
  shlibpath_var=LIBRARY_PATH
 
2107
  ;;
 
2108
 
 
2109
bsdi[[45]]*)
 
2110
  version_type=linux
 
2111
  need_version=no
 
2112
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2113
  soname_spec='${libname}${release}${shared_ext}$major'
 
2114
  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
 
2115
  shlibpath_var=LD_LIBRARY_PATH
 
2116
  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
 
2117
  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
 
2118
  # the default ld.so.conf also contains /usr/contrib/lib and
 
2119
  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
 
2120
  # libtool to hard-code these into programs
 
2121
  ;;
 
2122
 
 
2123
cygwin* | mingw* | pw32*)
 
2124
  version_type=windows
 
2125
  shrext_cmds=".dll"
 
2126
  need_version=no
 
2127
  need_lib_prefix=no
 
2128
 
 
2129
  case $GCC,$host_os in
 
2130
  yes,cygwin* | yes,mingw* | yes,pw32*)
 
2131
    library_names_spec='$libname.dll.a'
 
2132
    # DLL is installed to $(libdir)/../bin by postinstall_cmds
 
2133
    postinstall_cmds='base_file=`basename \${file}`~
 
2134
      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
 
2135
      dldir=$destdir/`dirname \$dlpath`~
 
2136
      test -d \$dldir || mkdir -p \$dldir~
 
2137
      $install_prog $dir/$dlname \$dldir/$dlname~
 
2138
      chmod a+x \$dldir/$dlname'
 
2139
    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
 
2140
      dlpath=$dir/\$dldll~
 
2141
       $rm \$dlpath'
 
2142
    shlibpath_overrides_runpath=yes
 
2143
 
 
2144
    case $host_os in
 
2145
    cygwin*)
 
2146
      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
 
2147
      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
 
2148
      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
 
2149
      ;;
 
2150
    mingw*)
 
2151
      # MinGW DLLs use traditional 'lib' prefix
 
2152
      soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
 
2153
      sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
 
2154
      if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
 
2155
        # It is most probably a Windows format PATH printed by
 
2156
        # mingw gcc, but we are running on Cygwin. Gcc prints its search
 
2157
        # path with ; separators, and with drive letters. We can handle the
 
2158
        # drive letters (cygwin fileutils understands them), so leave them,
 
2159
        # especially as we might pass files found there to a mingw objdump,
 
2160
        # which wouldn't understand a cygwinified path. Ahh.
 
2161
        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
 
2162
      else
 
2163
        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
 
2164
      fi
 
2165
      ;;
 
2166
    pw32*)
 
2167
      # pw32 DLLs use 'pw' prefix rather than 'lib'
 
2168
      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
 
2169
      ;;
 
2170
    esac
 
2171
    ;;
 
2172
 
 
2173
  *)
 
2174
    library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
 
2175
    ;;
 
2176
  esac
 
2177
  dynamic_linker='Win32 ld.exe'
 
2178
  # FIXME: first we should search . and the directory the executable is in
 
2179
  shlibpath_var=PATH
 
2180
  ;;
 
2181
 
 
2182
darwin* | rhapsody*)
 
2183
  dynamic_linker="$host_os dyld"
 
2184
  version_type=darwin
 
2185
  need_lib_prefix=no
 
2186
  need_version=no
 
2187
  library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
 
2188
  soname_spec='${libname}${release}${major}$shared_ext'
 
2189
  shlibpath_overrides_runpath=yes
 
2190
  shlibpath_var=DYLD_LIBRARY_PATH
 
2191
  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
 
2192
  m4_if([$1], [],[
 
2193
  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 
 
2194
  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
 
2195
  ;;
 
2196
 
 
2197
dgux*)
 
2198
  version_type=linux
 
2199
  need_lib_prefix=no
 
2200
  need_version=no
 
2201
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
 
2202
  soname_spec='${libname}${release}${shared_ext}$major'
 
2203
  shlibpath_var=LD_LIBRARY_PATH
 
2204
  ;;
 
2205
 
 
2206
freebsd1*)
 
2207
  dynamic_linker=no
 
2208
  ;;
 
2209
 
 
2210
freebsd* | dragonfly*)
 
2211
  # DragonFly does not have aout.  When/if they implement a new
 
2212
  # versioning mechanism, adjust this.
 
2213
  if test -x /usr/bin/objformat; then
 
2214
    objformat=`/usr/bin/objformat`
 
2215
  else
 
2216
    case $host_os in
 
2217
    freebsd[[123]]*) objformat=aout ;;
 
2218
    *) objformat=elf ;;
 
2219
    esac
 
2220
  fi
 
2221
  version_type=freebsd-$objformat
 
2222
  case $version_type in
 
2223
    freebsd-elf*)
 
2224
      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
 
2225
      need_version=no
 
2226
      need_lib_prefix=no
 
2227
      ;;
 
2228
    freebsd-*)
 
2229
      library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
 
2230
      need_version=yes
 
2231
      ;;
 
2232
  esac
 
2233
  shlibpath_var=LD_LIBRARY_PATH
 
2234
  case $host_os in
 
2235
  freebsd2*)
 
2236
    shlibpath_overrides_runpath=yes
 
2237
    ;;
 
2238
  freebsd3.[[01]]* | freebsdelf3.[[01]]*)
 
2239
    shlibpath_overrides_runpath=yes
 
2240
    hardcode_into_libs=yes
 
2241
    ;;
 
2242
  freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
 
2243
  freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
 
2244
    shlibpath_overrides_runpath=no
 
2245
    hardcode_into_libs=yes
 
2246
    ;;
 
2247
  *) # from 4.6 on, and DragonFly
 
2248
    shlibpath_overrides_runpath=yes
 
2249
    hardcode_into_libs=yes
 
2250
    ;;
 
2251
  esac
 
2252
  ;;
 
2253
 
 
2254
gnu*)
 
2255
  version_type=linux
 
2256
  need_lib_prefix=no
 
2257
  need_version=no
 
2258
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
 
2259
  soname_spec='${libname}${release}${shared_ext}$major'
 
2260
  shlibpath_var=LD_LIBRARY_PATH
 
2261
  hardcode_into_libs=yes
 
2262
  ;;
 
2263
 
 
2264
hpux9* | hpux10* | hpux11*)
 
2265
  # Give a soname corresponding to the major version so that dld.sl refuses to
 
2266
  # link against other versions.
 
2267
  version_type=sunos
 
2268
  need_lib_prefix=no
 
2269
  need_version=no
 
2270
  case $host_cpu in
 
2271
  ia64*)
 
2272
    shrext_cmds='.so'
 
2273
    hardcode_into_libs=yes
 
2274
    dynamic_linker="$host_os dld.so"
 
2275
    shlibpath_var=LD_LIBRARY_PATH
 
2276
    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
 
2277
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2278
    soname_spec='${libname}${release}${shared_ext}$major'
 
2279
    if test "X$HPUX_IA64_MODE" = X32; then
 
2280
      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
 
2281
    else
 
2282
      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
 
2283
    fi
 
2284
    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
 
2285
    ;;
 
2286
   hppa*64*)
 
2287
     shrext_cmds='.sl'
 
2288
     hardcode_into_libs=yes
 
2289
     dynamic_linker="$host_os dld.sl"
 
2290
     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
 
2291
     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
 
2292
     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2293
     soname_spec='${libname}${release}${shared_ext}$major'
 
2294
     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
 
2295
     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
 
2296
     ;;
 
2297
   *)
 
2298
    shrext_cmds='.sl'
 
2299
    dynamic_linker="$host_os dld.sl"
 
2300
    shlibpath_var=SHLIB_PATH
 
2301
    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
 
2302
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2303
    soname_spec='${libname}${release}${shared_ext}$major'
 
2304
    ;;
 
2305
  esac
 
2306
  # HP-UX runs *really* slowly unless shared libraries are mode 555.
 
2307
  postinstall_cmds='chmod 555 $lib'
 
2308
  ;;
 
2309
 
 
2310
interix[[3-9]]*)
 
2311
  version_type=linux
 
2312
  need_lib_prefix=no
 
2313
  need_version=no
 
2314
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
 
2315
  soname_spec='${libname}${release}${shared_ext}$major'
 
2316
  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
 
2317
  shlibpath_var=LD_LIBRARY_PATH
 
2318
  shlibpath_overrides_runpath=no
 
2319
  hardcode_into_libs=yes
 
2320
  ;;
 
2321
 
 
2322
irix5* | irix6* | nonstopux*)
 
2323
  case $host_os in
 
2324
    nonstopux*) version_type=nonstopux ;;
 
2325
    *)
 
2326
        if test "$lt_cv_prog_gnu_ld" = yes; then
 
2327
                version_type=linux
 
2328
        else
 
2329
                version_type=irix
 
2330
        fi ;;
 
2331
  esac
 
2332
  need_lib_prefix=no
 
2333
  need_version=no
 
2334
  soname_spec='${libname}${release}${shared_ext}$major'
 
2335
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
 
2336
  case $host_os in
 
2337
  irix5* | nonstopux*)
 
2338
    libsuff= shlibsuff=
 
2339
    ;;
 
2340
  *)
 
2341
    case $LD in # libtool.m4 will add one of these switches to LD
 
2342
    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
 
2343
      libsuff= shlibsuff= libmagic=32-bit;;
 
2344
    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
 
2345
      libsuff=32 shlibsuff=N32 libmagic=N32;;
 
2346
    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
 
2347
      libsuff=64 shlibsuff=64 libmagic=64-bit;;
 
2348
    *) libsuff= shlibsuff= libmagic=never-match;;
 
2349
    esac
 
2350
    ;;
 
2351
  esac
 
2352
  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
 
2353
  shlibpath_overrides_runpath=no
 
2354
  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
 
2355
  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
 
2356
  hardcode_into_libs=yes
 
2357
  ;;
 
2358
 
 
2359
# No shared lib support for Linux oldld, aout, or coff.
 
2360
linux*oldld* | linux*aout* | linux*coff*)
 
2361
  dynamic_linker=no
 
2362
  ;;
 
2363
 
 
2364
# This must be Linux ELF.
 
2365
linux* | k*bsd*-gnu)
 
2366
  version_type=linux
 
2367
  need_lib_prefix=no
 
2368
  need_version=no
 
2369
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2370
  soname_spec='${libname}${release}${shared_ext}$major'
 
2371
  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
 
2372
  shlibpath_var=LD_LIBRARY_PATH
 
2373
  shlibpath_overrides_runpath=no
 
2374
  # This implies no fast_install, which is unacceptable.
 
2375
  # Some rework will be needed to allow for fast_install
 
2376
  # before this can be enabled.
 
2377
  hardcode_into_libs=yes
 
2378
  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
 
2379
  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
 
2380
 
 
2381
  # Append ld.so.conf contents to the search path
 
2382
  if test -f /etc/ld.so.conf; then
 
2383
    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' ' '`
 
2384
    sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
 
2385
  fi
 
2386
 
 
2387
  # We used to test for /lib/ld.so.1 and disable shared libraries on
 
2388
  # powerpc, because MkLinux only supported shared libraries with the
 
2389
  # GNU dynamic linker.  Since this was broken with cross compilers,
 
2390
  # most powerpc-linux boxes support dynamic linking these days and
 
2391
  # people can always --disable-shared, the test was removed, and we
 
2392
  # assume the GNU/Linux dynamic linker is in use.
 
2393
  dynamic_linker='GNU/Linux ld.so'
 
2394
  ;;
 
2395
 
 
2396
netbsd*)
 
2397
  version_type=sunos
 
2398
  need_lib_prefix=no
 
2399
  need_version=no
 
2400
  if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
 
2401
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
 
2402
    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
 
2403
    dynamic_linker='NetBSD (a.out) ld.so'
 
2404
  else
 
2405
    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
 
2406
    soname_spec='${libname}${release}${shared_ext}$major'
 
2407
    dynamic_linker='NetBSD ld.elf_so'
 
2408
  fi
 
2409
  shlibpath_var=LD_LIBRARY_PATH
 
2410
  shlibpath_overrides_runpath=yes
 
2411
  hardcode_into_libs=yes
 
2412
  ;;
 
2413
 
 
2414
newsos6)
 
2415
  version_type=linux
 
2416
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2417
  shlibpath_var=LD_LIBRARY_PATH
 
2418
  shlibpath_overrides_runpath=yes
 
2419
  ;;
 
2420
 
 
2421
nto-qnx*)
 
2422
  version_type=linux
 
2423
  need_lib_prefix=no
 
2424
  need_version=no
 
2425
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2426
  soname_spec='${libname}${release}${shared_ext}$major'
 
2427
  shlibpath_var=LD_LIBRARY_PATH
 
2428
  shlibpath_overrides_runpath=yes
 
2429
  ;;
 
2430
 
 
2431
openbsd*)
 
2432
  version_type=sunos
 
2433
  sys_lib_dlsearch_path_spec="/usr/lib"
 
2434
  need_lib_prefix=no
 
2435
  # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
 
2436
  case $host_os in
 
2437
    openbsd3.3 | openbsd3.3.*) need_version=yes ;;
 
2438
    *)                         need_version=no  ;;
 
2439
  esac
 
2440
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
 
2441
  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
 
2442
  shlibpath_var=LD_LIBRARY_PATH
 
2443
  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
 
2444
    case $host_os in
 
2445
      openbsd2.[[89]] | openbsd2.[[89]].*)
 
2446
        shlibpath_overrides_runpath=no
 
2447
        ;;
 
2448
      *)
 
2449
        shlibpath_overrides_runpath=yes
 
2450
        ;;
 
2451
      esac
 
2452
  else
 
2453
    shlibpath_overrides_runpath=yes
 
2454
  fi
 
2455
  ;;
 
2456
 
 
2457
os2*)
 
2458
  libname_spec='$name'
 
2459
  shrext_cmds=".dll"
 
2460
  need_lib_prefix=no
 
2461
  library_names_spec='$libname${shared_ext} $libname.a'
 
2462
  dynamic_linker='OS/2 ld.exe'
 
2463
  shlibpath_var=LIBPATH
 
2464
  ;;
 
2465
 
 
2466
osf3* | osf4* | osf5*)
 
2467
  version_type=osf
 
2468
  need_lib_prefix=no
 
2469
  need_version=no
 
2470
  soname_spec='${libname}${release}${shared_ext}$major'
 
2471
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2472
  shlibpath_var=LD_LIBRARY_PATH
 
2473
  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
 
2474
  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
 
2475
  ;;
 
2476
 
 
2477
rdos*)
 
2478
  dynamic_linker=no
 
2479
  ;;
 
2480
 
 
2481
solaris*)
 
2482
  version_type=linux
 
2483
  need_lib_prefix=no
 
2484
  need_version=no
 
2485
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2486
  soname_spec='${libname}${release}${shared_ext}$major'
 
2487
  shlibpath_var=LD_LIBRARY_PATH
 
2488
  shlibpath_overrides_runpath=yes
 
2489
  hardcode_into_libs=yes
 
2490
  # ldd complains unless libraries are executable
 
2491
  postinstall_cmds='chmod +x $lib'
 
2492
  ;;
 
2493
 
 
2494
sunos4*)
 
2495
  version_type=sunos
 
2496
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
 
2497
  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
 
2498
  shlibpath_var=LD_LIBRARY_PATH
 
2499
  shlibpath_overrides_runpath=yes
 
2500
  if test "$with_gnu_ld" = yes; then
 
2501
    need_lib_prefix=no
 
2502
  fi
 
2503
  need_version=yes
 
2504
  ;;
 
2505
 
 
2506
sysv4 | sysv4.3*)
 
2507
  version_type=linux
 
2508
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2509
  soname_spec='${libname}${release}${shared_ext}$major'
 
2510
  shlibpath_var=LD_LIBRARY_PATH
 
2511
  case $host_vendor in
 
2512
    sni)
 
2513
      shlibpath_overrides_runpath=no
 
2514
      need_lib_prefix=no
 
2515
      export_dynamic_flag_spec='${wl}-Blargedynsym'
 
2516
      runpath_var=LD_RUN_PATH
 
2517
      ;;
 
2518
    siemens)
 
2519
      need_lib_prefix=no
 
2520
      ;;
 
2521
    motorola)
 
2522
      need_lib_prefix=no
 
2523
      need_version=no
 
2524
      shlibpath_overrides_runpath=no
 
2525
      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
 
2526
      ;;
 
2527
  esac
 
2528
  ;;
 
2529
 
 
2530
sysv4*MP*)
 
2531
  if test -d /usr/nec ;then
 
2532
    version_type=linux
 
2533
    library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
 
2534
    soname_spec='$libname${shared_ext}.$major'
 
2535
    shlibpath_var=LD_LIBRARY_PATH
 
2536
  fi
 
2537
  ;;
 
2538
 
 
2539
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
 
2540
  version_type=freebsd-elf
 
2541
  need_lib_prefix=no
 
2542
  need_version=no
 
2543
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
 
2544
  soname_spec='${libname}${release}${shared_ext}$major'
 
2545
  shlibpath_var=LD_LIBRARY_PATH
 
2546
  hardcode_into_libs=yes
 
2547
  if test "$with_gnu_ld" = yes; then
 
2548
    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
 
2549
    shlibpath_overrides_runpath=no
 
2550
  else
 
2551
    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
 
2552
    shlibpath_overrides_runpath=yes
 
2553
    case $host_os in
 
2554
      sco3.2v5*)
 
2555
        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
 
2556
        ;;
 
2557
    esac
 
2558
  fi
 
2559
  sys_lib_dlsearch_path_spec='/usr/lib'
 
2560
  ;;
 
2561
 
 
2562
uts4*)
 
2563
  version_type=linux
 
2564
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
 
2565
  soname_spec='${libname}${release}${shared_ext}$major'
 
2566
  shlibpath_var=LD_LIBRARY_PATH
 
2567
  ;;
 
2568
 
 
2569
*)
 
2570
  dynamic_linker=no
 
2571
  ;;
 
2572
esac
 
2573
AC_MSG_RESULT([$dynamic_linker])
 
2574
test "$dynamic_linker" = no && can_build_shared=no
 
2575
 
 
2576
AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec],
 
2577
[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"])
 
2578
sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
 
2579
AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec],
 
2580
[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"])
 
2581
sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
 
2582
 
 
2583
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
 
2584
if test "$GCC" = yes; then
 
2585
  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
 
2586
fi
 
2587
])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
 
2588
 
 
2589
 
 
2590
# _LT_AC_TAGCONFIG
 
2591
# ----------------
 
2592
AC_DEFUN([_LT_AC_TAGCONFIG],
 
2593
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
2594
AC_ARG_WITH([tags],
 
2595
    [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
 
2596
        [include additional configurations @<:@automatic@:>@])],
 
2597
    [tagnames="$withval"])
 
2598
 
 
2599
if test -f "$ltmain" && test -n "$tagnames"; then
 
2600
  if test ! -f "${ofile}"; then
 
2601
    AC_MSG_WARN([output file `$ofile' does not exist])
 
2602
  fi
 
2603
 
 
2604
  if test -z "$LTCC"; then
 
2605
    eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
 
2606
    if test -z "$LTCC"; then
 
2607
      AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
 
2608
    else
 
2609
      AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
 
2610
    fi
 
2611
  fi
 
2612
  if test -z "$LTCFLAGS"; then
 
2613
    eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
 
2614
  fi
 
2615
 
 
2616
  # Extract list of available tagged configurations in $ofile.
 
2617
  # Note that this assumes the entire list is on one line.
 
2618
  available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
 
2619
 
 
2620
  lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
 
2621
  for tagname in $tagnames; do
 
2622
    IFS="$lt_save_ifs"
 
2623
    # Check whether tagname contains only valid characters
 
2624
    case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
 
2625
    "") ;;
 
2626
    *)  AC_MSG_ERROR([invalid tag name: $tagname])
 
2627
        ;;
 
2628
    esac
 
2629
 
 
2630
    if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
 
2631
    then
 
2632
      AC_MSG_ERROR([tag name \"$tagname\" already exists])
 
2633
    fi
 
2634
 
 
2635
    # Update the list of available tags.
 
2636
    if test -n "$tagname"; then
 
2637
      echo appending configuration tag \"$tagname\" to $ofile
 
2638
 
 
2639
      case $tagname in
 
2640
      CXX)
 
2641
        if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
 
2642
            ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
 
2643
            (test "X$CXX" != "Xg++"))) ; then
 
2644
          AC_LIBTOOL_LANG_CXX_CONFIG
 
2645
        else
 
2646
          tagname=""
 
2647
        fi
 
2648
        ;;
 
2649
 
 
2650
      F77)
 
2651
        if test -n "$F77" && test "X$F77" != "Xno"; then
 
2652
          AC_LIBTOOL_LANG_F77_CONFIG
 
2653
        else
 
2654
          tagname=""
 
2655
        fi
 
2656
        ;;
 
2657
 
 
2658
      GCJ)
 
2659
        if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
 
2660
          AC_LIBTOOL_LANG_GCJ_CONFIG
 
2661
        else
 
2662
          tagname=""
 
2663
        fi
 
2664
        ;;
 
2665
 
 
2666
      RC)
 
2667
        AC_LIBTOOL_LANG_RC_CONFIG
 
2668
        ;;
 
2669
 
 
2670
      *)
 
2671
        AC_MSG_ERROR([Unsupported tag name: $tagname])
 
2672
        ;;
 
2673
      esac
 
2674
 
 
2675
      # Append the new tag name to the list of available tags.
 
2676
      if test -n "$tagname" ; then
 
2677
      available_tags="$available_tags $tagname"
 
2678
    fi
 
2679
    fi
 
2680
  done
 
2681
  IFS="$lt_save_ifs"
 
2682
 
 
2683
  # Now substitute the updated list of available tags.
 
2684
  if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
 
2685
    mv "${ofile}T" "$ofile"
 
2686
    chmod +x "$ofile"
 
2687
  else
 
2688
    rm -f "${ofile}T"
 
2689
    AC_MSG_ERROR([unable to update list of available tagged configurations.])
 
2690
  fi
 
2691
fi
 
2692
])# _LT_AC_TAGCONFIG
 
2693
 
 
2694
 
 
2695
# AC_LIBTOOL_DLOPEN
 
2696
# -----------------
 
2697
# enable checks for dlopen support
 
2698
AC_DEFUN([AC_LIBTOOL_DLOPEN],
 
2699
 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
 
2700
])# AC_LIBTOOL_DLOPEN
 
2701
 
 
2702
 
 
2703
# AC_LIBTOOL_WIN32_DLL
 
2704
# --------------------
 
2705
# declare package support for building win32 DLLs
 
2706
AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
 
2707
[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
 
2708
])# AC_LIBTOOL_WIN32_DLL
 
2709
 
 
2710
 
 
2711
# AC_ENABLE_SHARED([DEFAULT])
 
2712
# ---------------------------
 
2713
# implement the --enable-shared flag
 
2714
# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
 
2715
AC_DEFUN([AC_ENABLE_SHARED],
 
2716
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
 
2717
AC_ARG_ENABLE([shared],
 
2718
    [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
 
2719
        [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
 
2720
    [p=${PACKAGE-default}
 
2721
    case $enableval in
 
2722
    yes) enable_shared=yes ;;
 
2723
    no) enable_shared=no ;;
 
2724
    *)
 
2725
      enable_shared=no
 
2726
      # Look at the argument we got.  We use all the common list separators.
 
2727
      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
 
2728
      for pkg in $enableval; do
 
2729
        IFS="$lt_save_ifs"
 
2730
        if test "X$pkg" = "X$p"; then
 
2731
          enable_shared=yes
 
2732
        fi
 
2733
      done
 
2734
      IFS="$lt_save_ifs"
 
2735
      ;;
 
2736
    esac],
 
2737
    [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
 
2738
])# AC_ENABLE_SHARED
 
2739
 
 
2740
 
 
2741
# AC_DISABLE_SHARED
 
2742
# -----------------
 
2743
# set the default shared flag to --disable-shared
 
2744
AC_DEFUN([AC_DISABLE_SHARED],
 
2745
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 
2746
AC_ENABLE_SHARED(no)
 
2747
])# AC_DISABLE_SHARED
 
2748
 
 
2749
 
 
2750
# AC_ENABLE_STATIC([DEFAULT])
 
2751
# ---------------------------
 
2752
# implement the --enable-static flag
 
2753
# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
 
2754
AC_DEFUN([AC_ENABLE_STATIC],
 
2755
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
 
2756
AC_ARG_ENABLE([static],
 
2757
    [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
 
2758
        [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
 
2759
    [p=${PACKAGE-default}
 
2760
    case $enableval in
 
2761
    yes) enable_static=yes ;;
 
2762
    no) enable_static=no ;;
 
2763
    *)
 
2764
     enable_static=no
 
2765
      # Look at the argument we got.  We use all the common list separators.
 
2766
      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
 
2767
      for pkg in $enableval; do
 
2768
        IFS="$lt_save_ifs"
 
2769
        if test "X$pkg" = "X$p"; then
 
2770
          enable_static=yes
 
2771
        fi
 
2772
      done
 
2773
      IFS="$lt_save_ifs"
 
2774
      ;;
 
2775
    esac],
 
2776
    [enable_static=]AC_ENABLE_STATIC_DEFAULT)
 
2777
])# AC_ENABLE_STATIC
 
2778
 
 
2779
 
 
2780
# AC_DISABLE_STATIC
 
2781
# -----------------
 
2782
# set the default static flag to --disable-static
 
2783
AC_DEFUN([AC_DISABLE_STATIC],
 
2784
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 
2785
AC_ENABLE_STATIC(no)
 
2786
])# AC_DISABLE_STATIC
 
2787
 
 
2788
 
 
2789
# AC_ENABLE_FAST_INSTALL([DEFAULT])
 
2790
# ---------------------------------
 
2791
# implement the --enable-fast-install flag
 
2792
# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
 
2793
AC_DEFUN([AC_ENABLE_FAST_INSTALL],
 
2794
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
 
2795
AC_ARG_ENABLE([fast-install],
 
2796
    [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
 
2797
    [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
 
2798
    [p=${PACKAGE-default}
 
2799
    case $enableval in
 
2800
    yes) enable_fast_install=yes ;;
 
2801
    no) enable_fast_install=no ;;
 
2802
    *)
 
2803
      enable_fast_install=no
 
2804
      # Look at the argument we got.  We use all the common list separators.
 
2805
      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
 
2806
      for pkg in $enableval; do
 
2807
        IFS="$lt_save_ifs"
 
2808
        if test "X$pkg" = "X$p"; then
 
2809
          enable_fast_install=yes
 
2810
        fi
 
2811
      done
 
2812
      IFS="$lt_save_ifs"
 
2813
      ;;
 
2814
    esac],
 
2815
    [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
 
2816
])# AC_ENABLE_FAST_INSTALL
 
2817
 
 
2818
 
 
2819
# AC_DISABLE_FAST_INSTALL
 
2820
# -----------------------
 
2821
# set the default to --disable-fast-install
 
2822
AC_DEFUN([AC_DISABLE_FAST_INSTALL],
 
2823
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 
2824
AC_ENABLE_FAST_INSTALL(no)
 
2825
])# AC_DISABLE_FAST_INSTALL
 
2826
 
 
2827
 
 
2828
# AC_LIBTOOL_PICMODE([MODE])
 
2829
# --------------------------
 
2830
# implement the --with-pic flag
 
2831
# MODE is either `yes' or `no'.  If omitted, it defaults to `both'.
 
2832
AC_DEFUN([AC_LIBTOOL_PICMODE],
 
2833
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 
2834
pic_mode=ifelse($#,1,$1,default)
 
2835
])# AC_LIBTOOL_PICMODE
 
2836
 
 
2837
 
 
2838
# AC_PROG_EGREP
 
2839
# -------------
 
2840
# This is predefined starting with Autoconf 2.54, so this conditional
 
2841
# definition can be removed once we require Autoconf 2.54 or later.
 
2842
m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
 
2843
[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
 
2844
   [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
 
2845
    then ac_cv_prog_egrep='grep -E'
 
2846
    else ac_cv_prog_egrep='egrep'
 
2847
    fi])
 
2848
 EGREP=$ac_cv_prog_egrep
 
2849
 AC_SUBST([EGREP])
 
2850
])])
 
2851
 
 
2852
 
 
2853
# AC_PATH_TOOL_PREFIX
 
2854
# -------------------
 
2855
# find a file program which can recognize shared library
 
2856
AC_DEFUN([AC_PATH_TOOL_PREFIX],
 
2857
[AC_REQUIRE([AC_PROG_EGREP])dnl
 
2858
AC_MSG_CHECKING([for $1])
 
2859
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
 
2860
[case $MAGIC_CMD in
 
2861
[[\\/*] |  ?:[\\/]*])
 
2862
  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
 
2863
  ;;
 
2864
*)
 
2865
  lt_save_MAGIC_CMD="$MAGIC_CMD"
 
2866
  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
 
2867
dnl $ac_dummy forces splitting on constant user-supplied paths.
 
2868
dnl POSIX.2 word splitting is done only on the output of word expansions,
 
2869
dnl not every word.  This closes a longstanding sh security hole.
 
2870
  ac_dummy="ifelse([$2], , $PATH, [$2])"
 
2871
  for ac_dir in $ac_dummy; do
 
2872
    IFS="$lt_save_ifs"
 
2873
    test -z "$ac_dir" && ac_dir=.
 
2874
    if test -f $ac_dir/$1; then
 
2875
      lt_cv_path_MAGIC_CMD="$ac_dir/$1"
 
2876
      if test -n "$file_magic_test_file"; then
 
2877
        case $deplibs_check_method in
 
2878
        "file_magic "*)
 
2879
          file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
 
2880
          MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
 
2881
          if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
 
2882
            $EGREP "$file_magic_regex" > /dev/null; then
 
2883
            :
 
2884
          else
 
2885
            cat <<EOF 1>&2
 
2886
 
 
2887
*** Warning: the command libtool uses to detect shared libraries,
 
2888
*** $file_magic_cmd, produces output that libtool cannot recognize.
 
2889
*** The result is that libtool may fail to recognize shared libraries
 
2890
*** as such.  This will affect the creation of libtool libraries that
 
2891
*** depend on shared libraries, but programs linked with such libtool
 
2892
*** libraries will work regardless of this problem.  Nevertheless, you
 
2893
*** may want to report the problem to your system manager and/or to
 
2894
*** bug-libtool@gnu.org
 
2895
 
 
2896
EOF
 
2897
          fi ;;
 
2898
        esac
 
2899
      fi
 
2900
      break
 
2901
    fi
 
2902
  done
 
2903
  IFS="$lt_save_ifs"
 
2904
  MAGIC_CMD="$lt_save_MAGIC_CMD"
 
2905
  ;;
 
2906
esac])
 
2907
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
 
2908
if test -n "$MAGIC_CMD"; then
 
2909
  AC_MSG_RESULT($MAGIC_CMD)
 
2910
else
 
2911
  AC_MSG_RESULT(no)
 
2912
fi
 
2913
])# AC_PATH_TOOL_PREFIX
 
2914
 
 
2915
 
 
2916
# AC_PATH_MAGIC
 
2917
# -------------
 
2918
# find a file program which can recognize a shared library
 
2919
AC_DEFUN([AC_PATH_MAGIC],
 
2920
[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
 
2921
if test -z "$lt_cv_path_MAGIC_CMD"; then
 
2922
  if test -n "$ac_tool_prefix"; then
 
2923
    AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
 
2924
  else
 
2925
    MAGIC_CMD=:
 
2926
  fi
 
2927
fi
 
2928
])# AC_PATH_MAGIC
 
2929
 
 
2930
 
 
2931
# AC_PROG_LD
 
2932
# ----------
 
2933
# find the pathname to the GNU or non-GNU linker
 
2934
AC_DEFUN([AC_PROG_LD],
 
2935
[AC_ARG_WITH([gnu-ld],
 
2936
    [AC_HELP_STRING([--with-gnu-ld],
 
2937
        [assume the C compiler uses GNU ld @<:@default=no@:>@])],
 
2938
    [test "$withval" = no || with_gnu_ld=yes],
 
2939
    [with_gnu_ld=no])
 
2940
AC_REQUIRE([LT_AC_PROG_SED])dnl
 
2941
AC_REQUIRE([AC_PROG_CC])dnl
 
2942
AC_REQUIRE([AC_CANONICAL_HOST])dnl
 
2943
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
 
2944
ac_prog=ld
 
2945
if test "$GCC" = yes; then
 
2946
  # Check if gcc -print-prog-name=ld gives a path.
 
2947
  AC_MSG_CHECKING([for ld used by $CC])
 
2948
  case $host in
 
2949
  *-*-mingw*)
 
2950
    # gcc leaves a trailing carriage return which upsets mingw
 
2951
    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
 
2952
  *)
 
2953
    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
 
2954
  esac
 
2955
  case $ac_prog in
 
2956
    # Accept absolute paths.
 
2957
    [[\\/]]* | ?:[[\\/]]*)
 
2958
      re_direlt='/[[^/]][[^/]]*/\.\./'
 
2959
      # Canonicalize the pathname of ld
 
2960
      ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
 
2961
      while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
 
2962
        ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
 
2963
      done
 
2964
      test -z "$LD" && LD="$ac_prog"
 
2965
      ;;
 
2966
  "")
 
2967
    # If it fails, then pretend we aren't using GCC.
 
2968
    ac_prog=ld
 
2969
    ;;
 
2970
  *)
 
2971
    # If it is relative, then search for the first ld in PATH.
 
2972
    with_gnu_ld=unknown
 
2973
    ;;
 
2974
  esac
 
2975
elif test "$with_gnu_ld" = yes; then
 
2976
  AC_MSG_CHECKING([for GNU ld])
 
2977
else
 
2978
  AC_MSG_CHECKING([for non-GNU ld])
 
2979
fi
 
2980
AC_CACHE_VAL(lt_cv_path_LD,
 
2981
[if test -z "$LD"; then
 
2982
  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
 
2983
  for ac_dir in $PATH; do
 
2984
    IFS="$lt_save_ifs"
 
2985
    test -z "$ac_dir" && ac_dir=.
 
2986
    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
 
2987
      lt_cv_path_LD="$ac_dir/$ac_prog"
 
2988
      # Check to see if the program is GNU ld.  I'd rather use --version,
 
2989
      # but apparently some variants of GNU ld only accept -v.
 
2990
      # Break only if it was the GNU/non-GNU ld that we prefer.
 
2991
      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
 
2992
      *GNU* | *'with BFD'*)
 
2993
        test "$with_gnu_ld" != no && break
 
2994
        ;;
 
2995
      *)
 
2996
        test "$with_gnu_ld" != yes && break
 
2997
        ;;
 
2998
      esac
 
2999
    fi
 
3000
  done
 
3001
  IFS="$lt_save_ifs"
 
3002
else
 
3003
  lt_cv_path_LD="$LD" # Let the user override the test with a path.
 
3004
fi])
 
3005
LD="$lt_cv_path_LD"
 
3006
if test -n "$LD"; then
 
3007
  AC_MSG_RESULT($LD)
 
3008
else
 
3009
  AC_MSG_RESULT(no)
 
3010
fi
 
3011
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
 
3012
AC_PROG_LD_GNU
 
3013
])# AC_PROG_LD
 
3014
 
 
3015
 
 
3016
# AC_PROG_LD_GNU
 
3017
# --------------
 
3018
AC_DEFUN([AC_PROG_LD_GNU],
 
3019
[AC_REQUIRE([AC_PROG_EGREP])dnl
 
3020
AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
 
3021
[# I'd rather use --version here, but apparently some GNU lds only accept -v.
 
3022
case `$LD -v 2>&1 </dev/null` in
 
3023
*GNU* | *'with BFD'*)
 
3024
  lt_cv_prog_gnu_ld=yes
 
3025
  ;;
 
3026
*)
 
3027
  lt_cv_prog_gnu_ld=no
 
3028
  ;;
 
3029
esac])
 
3030
with_gnu_ld=$lt_cv_prog_gnu_ld
 
3031
])# AC_PROG_LD_GNU
 
3032
 
 
3033
 
 
3034
# AC_PROG_LD_RELOAD_FLAG
 
3035
# ----------------------
 
3036
# find reload flag for linker
 
3037
#   -- PORTME Some linkers may need a different reload flag.
 
3038
AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
 
3039
[AC_CACHE_CHECK([for $LD option to reload object files],
 
3040
  lt_cv_ld_reload_flag,
 
3041
  [lt_cv_ld_reload_flag='-r'])
 
3042
reload_flag=$lt_cv_ld_reload_flag
 
3043
case $reload_flag in
 
3044
"" | " "*) ;;
 
3045
*) reload_flag=" $reload_flag" ;;
 
3046
esac
 
3047
reload_cmds='$LD$reload_flag -o $output$reload_objs'
 
3048
case $host_os in
 
3049
  darwin*)
 
3050
    if test "$GCC" = yes; then
 
3051
      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
 
3052
    else
 
3053
      reload_cmds='$LD$reload_flag -o $output$reload_objs'
 
3054
    fi
 
3055
    ;;
 
3056
esac
 
3057
])# AC_PROG_LD_RELOAD_FLAG
 
3058
 
 
3059
 
 
3060
# AC_DEPLIBS_CHECK_METHOD
 
3061
# -----------------------
 
3062
# how to check for library dependencies
 
3063
#  -- PORTME fill in with the dynamic library characteristics
 
3064
AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
 
3065
[AC_CACHE_CHECK([how to recognize dependent libraries],
 
3066
lt_cv_deplibs_check_method,
 
3067
[lt_cv_file_magic_cmd='$MAGIC_CMD'
 
3068
lt_cv_file_magic_test_file=
 
3069
lt_cv_deplibs_check_method='unknown'
 
3070
# Need to set the preceding variable on all platforms that support
 
3071
# interlibrary dependencies.
 
3072
# 'none' -- dependencies not supported.
 
3073
# `unknown' -- same as none, but documents that we really don't know.
 
3074
# 'pass_all' -- all dependencies passed with no checks.
 
3075
# 'test_compile' -- check by making test program.
 
3076
# 'file_magic [[regex]]' -- check by looking for files in library path
 
3077
# which responds to the $file_magic_cmd with a given extended regex.
 
3078
# If you have `file' or equivalent on your system and you're not sure
 
3079
# whether `pass_all' will *always* work, you probably want this one.
 
3080
 
 
3081
case $host_os in
 
3082
aix[[4-9]]*)
 
3083
  lt_cv_deplibs_check_method=pass_all
 
3084
  ;;
 
3085
 
 
3086
beos*)
 
3087
  lt_cv_deplibs_check_method=pass_all
 
3088
  ;;
 
3089
 
 
3090
bsdi[[45]]*)
 
3091
  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
 
3092
  lt_cv_file_magic_cmd='/usr/bin/file -L'
 
3093
  lt_cv_file_magic_test_file=/shlib/libc.so
 
3094
  ;;
 
3095
 
 
3096
cygwin*)
 
3097
  # func_win32_libid is a shell function defined in ltmain.sh
 
3098
  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
 
3099
  lt_cv_file_magic_cmd='func_win32_libid'
 
3100
  ;;
 
3101
 
 
3102
mingw* | pw32*)
 
3103
  # Base MSYS/MinGW do not provide the 'file' command needed by
 
3104
  # func_win32_libid shell function, so use a weaker test based on 'objdump',
 
3105
  # unless we find 'file', for example because we are cross-compiling.
 
3106
  if ( file / ) >/dev/null 2>&1; then
 
3107
    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
 
3108
    lt_cv_file_magic_cmd='func_win32_libid'
 
3109
  else
 
3110
    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
 
3111
    lt_cv_file_magic_cmd='$OBJDUMP -f'
 
3112
  fi
 
3113
  ;;
 
3114
 
 
3115
darwin* | rhapsody*)
 
3116
  lt_cv_deplibs_check_method=pass_all
 
3117
  ;;
 
3118
 
 
3119
freebsd* | dragonfly*)
 
3120
  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
 
3121
    case $host_cpu in
 
3122
    i*86 )
 
3123
      # Not sure whether the presence of OpenBSD here was a mistake.
 
3124
      # Let's accept both of them until this is cleared up.
 
3125
      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
 
3126
      lt_cv_file_magic_cmd=/usr/bin/file
 
3127
      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
 
3128
      ;;
 
3129
    esac
 
3130
  else
 
3131
    lt_cv_deplibs_check_method=pass_all
 
3132
  fi
 
3133
  ;;
 
3134
 
 
3135
gnu*)
 
3136
  lt_cv_deplibs_check_method=pass_all
 
3137
  ;;
 
3138
 
 
3139
hpux10.20* | hpux11*)
 
3140
  lt_cv_file_magic_cmd=/usr/bin/file
 
3141
  case $host_cpu in
 
3142
  ia64*)
 
3143
    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
 
3144
    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
 
3145
    ;;
 
3146
  hppa*64*)
 
3147
    [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]']
 
3148
    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
 
3149
    ;;
 
3150
  *)
 
3151
    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
 
3152
    lt_cv_file_magic_test_file=/usr/lib/libc.sl
 
3153
    ;;
 
3154
  esac
 
3155
  ;;
 
3156
 
 
3157
interix[[3-9]]*)
 
3158
  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
 
3159
  lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
 
3160
  ;;
 
3161
 
 
3162
irix5* | irix6* | nonstopux*)
 
3163
  case $LD in
 
3164
  *-32|*"-32 ") libmagic=32-bit;;
 
3165
  *-n32|*"-n32 ") libmagic=N32;;
 
3166
  *-64|*"-64 ") libmagic=64-bit;;
 
3167
  *) libmagic=never-match;;
 
3168
  esac
 
3169
  lt_cv_deplibs_check_method=pass_all
 
3170
  ;;
 
3171
 
 
3172
# This must be Linux ELF.
 
3173
linux* | k*bsd*-gnu)
 
3174
  lt_cv_deplibs_check_method=pass_all
 
3175
  ;;
 
3176
 
 
3177
netbsd*)
 
3178
  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
 
3179
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
 
3180
  else
 
3181
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
 
3182
  fi
 
3183
  ;;
 
3184
 
 
3185
newos6*)
 
3186
  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
 
3187
  lt_cv_file_magic_cmd=/usr/bin/file
 
3188
  lt_cv_file_magic_test_file=/usr/lib/libnls.so
 
3189
  ;;
 
3190
 
 
3191
nto-qnx*)
 
3192
  lt_cv_deplibs_check_method=unknown
 
3193
  ;;
 
3194
 
 
3195
openbsd*)
 
3196
  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
 
3197
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
 
3198
  else
 
3199
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
 
3200
  fi
 
3201
  ;;
 
3202
 
 
3203
osf3* | osf4* | osf5*)
 
3204
  lt_cv_deplibs_check_method=pass_all
 
3205
  ;;
 
3206
 
 
3207
rdos*)
 
3208
  lt_cv_deplibs_check_method=pass_all
 
3209
  ;;
 
3210
 
 
3211
solaris*)
 
3212
  lt_cv_deplibs_check_method=pass_all
 
3213
  ;;
 
3214
 
 
3215
sysv4 | sysv4.3*)
 
3216
  case $host_vendor in
 
3217
  motorola)
 
3218
    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]]'
 
3219
    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
 
3220
    ;;
 
3221
  ncr)
 
3222
    lt_cv_deplibs_check_method=pass_all
 
3223
    ;;
 
3224
  sequent)
 
3225
    lt_cv_file_magic_cmd='/bin/file'
 
3226
    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
 
3227
    ;;
 
3228
  sni)
 
3229
    lt_cv_file_magic_cmd='/bin/file'
 
3230
    lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
 
3231
    lt_cv_file_magic_test_file=/lib/libc.so
 
3232
    ;;
 
3233
  siemens)
 
3234
    lt_cv_deplibs_check_method=pass_all
 
3235
    ;;
 
3236
  pc)
 
3237
    lt_cv_deplibs_check_method=pass_all
 
3238
    ;;
 
3239
  esac
 
3240
  ;;
 
3241
 
 
3242
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
 
3243
  lt_cv_deplibs_check_method=pass_all
 
3244
  ;;
 
3245
esac
 
3246
])
 
3247
file_magic_cmd=$lt_cv_file_magic_cmd
 
3248
deplibs_check_method=$lt_cv_deplibs_check_method
 
3249
test -z "$deplibs_check_method" && deplibs_check_method=unknown
 
3250
])# AC_DEPLIBS_CHECK_METHOD
 
3251
 
 
3252
 
 
3253
# AC_PROG_NM
 
3254
# ----------
 
3255
# find the pathname to a BSD-compatible name lister
 
3256
AC_DEFUN([AC_PROG_NM],
 
3257
[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
 
3258
[if test -n "$NM"; then
 
3259
  # Let the user override the test.
 
3260
  lt_cv_path_NM="$NM"
 
3261
else
 
3262
  lt_nm_to_check="${ac_tool_prefix}nm"
 
3263
  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
 
3264
    lt_nm_to_check="$lt_nm_to_check nm"
 
3265
  fi
 
3266
  for lt_tmp_nm in $lt_nm_to_check; do
 
3267
    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
 
3268
    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
 
3269
      IFS="$lt_save_ifs"
 
3270
      test -z "$ac_dir" && ac_dir=.
 
3271
      tmp_nm="$ac_dir/$lt_tmp_nm"
 
3272
      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
 
3273
        # Check to see if the nm accepts a BSD-compat flag.
 
3274
        # Adding the `sed 1q' prevents false positives on HP-UX, which says:
 
3275
        #   nm: unknown option "B" ignored
 
3276
        # Tru64's nm complains that /dev/null is an invalid object file
 
3277
        case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
 
3278
        */dev/null* | *'Invalid file or object type'*)
 
3279
          lt_cv_path_NM="$tmp_nm -B"
 
3280
          break
 
3281
          ;;
 
3282
        *)
 
3283
          case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
 
3284
          */dev/null*)
 
3285
            lt_cv_path_NM="$tmp_nm -p"
 
3286
            break
 
3287
            ;;
 
3288
          *)
 
3289
            lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
 
3290
            continue # so that we can try to find one that supports BSD flags
 
3291
            ;;
 
3292
          esac
 
3293
          ;;
 
3294
        esac
 
3295
      fi
 
3296
    done
 
3297
    IFS="$lt_save_ifs"
 
3298
  done
 
3299
  test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
 
3300
fi])
 
3301
NM="$lt_cv_path_NM"
 
3302
])# AC_PROG_NM
 
3303
 
 
3304
 
 
3305
# AC_CHECK_LIBM
 
3306
# -------------
 
3307
# check for math library
 
3308
AC_DEFUN([AC_CHECK_LIBM],
 
3309
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
 
3310
LIBM=
 
3311
case $host in
 
3312
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
 
3313
  # These system don't have libm, or don't need it
 
3314
  ;;
 
3315
*-ncr-sysv4.3*)
 
3316
  AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
 
3317
  AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
 
3318
  ;;
 
3319
*)
 
3320
  AC_CHECK_LIB(m, cos, LIBM="-lm")
 
3321
  ;;
 
3322
esac
 
3323
])# AC_CHECK_LIBM
 
3324
 
 
3325
 
 
3326
# AC_LIBLTDL_CONVENIENCE([DIRECTORY])
 
3327
# -----------------------------------
 
3328
# sets LIBLTDL to the link flags for the libltdl convenience library and
 
3329
# LTDLINCL to the include flags for the libltdl header and adds
 
3330
# --enable-ltdl-convenience to the configure arguments.  Note that
 
3331
# AC_CONFIG_SUBDIRS is not called here.  If DIRECTORY is not provided,
 
3332
# it is assumed to be `libltdl'.  LIBLTDL will be prefixed with
 
3333
# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
 
3334
# (note the single quotes!).  If your package is not flat and you're not
 
3335
# using automake, define top_builddir and top_srcdir appropriately in
 
3336
# the Makefiles.
 
3337
AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
 
3338
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 
3339
  case $enable_ltdl_convenience in
 
3340
  no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
 
3341
  "") enable_ltdl_convenience=yes
 
3342
      ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
 
3343
  esac
 
3344
  LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
 
3345
  LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
 
3346
  # For backwards non-gettext consistent compatibility...
 
3347
  INCLTDL="$LTDLINCL"
 
3348
])# AC_LIBLTDL_CONVENIENCE
 
3349
 
 
3350
 
 
3351
# AC_LIBLTDL_INSTALLABLE([DIRECTORY])
 
3352
# -----------------------------------
 
3353
# sets LIBLTDL to the link flags for the libltdl installable library and
 
3354
# LTDLINCL to the include flags for the libltdl header and adds
 
3355
# --enable-ltdl-install to the configure arguments.  Note that
 
3356
# AC_CONFIG_SUBDIRS is not called here.  If DIRECTORY is not provided,
 
3357
# and an installed libltdl is not found, it is assumed to be `libltdl'.
 
3358
# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
 
3359
# '${top_srcdir}/' (note the single quotes!).  If your package is not
 
3360
# flat and you're not using automake, define top_builddir and top_srcdir
 
3361
# appropriately in the Makefiles.
 
3362
# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
 
3363
AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
 
3364
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 
3365
  AC_CHECK_LIB(ltdl, lt_dlinit,
 
3366
  [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
 
3367
  [if test x"$enable_ltdl_install" = xno; then
 
3368
     AC_MSG_WARN([libltdl not installed, but installation disabled])
 
3369
   else
 
3370
     enable_ltdl_install=yes
 
3371
   fi
 
3372
  ])
 
3373
  if test x"$enable_ltdl_install" = x"yes"; then
 
3374
    ac_configure_args="$ac_configure_args --enable-ltdl-install"
 
3375
    LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
 
3376
    LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
 
3377
  else
 
3378
    ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
 
3379
    LIBLTDL="-lltdl"
 
3380
    LTDLINCL=
 
3381
  fi
 
3382
  # For backwards non-gettext consistent compatibility...
 
3383
  INCLTDL="$LTDLINCL"
 
3384
])# AC_LIBLTDL_INSTALLABLE
 
3385
 
 
3386
 
 
3387
# AC_LIBTOOL_CXX
 
3388
# --------------
 
3389
# enable support for C++ libraries
 
3390
AC_DEFUN([AC_LIBTOOL_CXX],
 
3391
[AC_REQUIRE([_LT_AC_LANG_CXX])
 
3392
])# AC_LIBTOOL_CXX
 
3393
 
 
3394
 
 
3395
# _LT_AC_LANG_CXX
 
3396
# ---------------
 
3397
AC_DEFUN([_LT_AC_LANG_CXX],
 
3398
[AC_REQUIRE([AC_PROG_CXX])
 
3399
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
 
3400
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
 
3401
])# _LT_AC_LANG_CXX
 
3402
 
 
3403
# _LT_AC_PROG_CXXCPP
 
3404
# ------------------
 
3405
AC_DEFUN([_LT_AC_PROG_CXXCPP],
 
3406
[
 
3407
AC_REQUIRE([AC_PROG_CXX])
 
3408
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
 
3409
    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
 
3410
    (test "X$CXX" != "Xg++"))) ; then
 
3411
  AC_PROG_CXXCPP
 
3412
fi
 
3413
])# _LT_AC_PROG_CXXCPP
 
3414
 
 
3415
# AC_LIBTOOL_F77
 
3416
# --------------
 
3417
# enable support for Fortran 77 libraries
 
3418
AC_DEFUN([AC_LIBTOOL_F77],
 
3419
[AC_REQUIRE([_LT_AC_LANG_F77])
 
3420
])# AC_LIBTOOL_F77
 
3421
 
 
3422
 
 
3423
# _LT_AC_LANG_F77
 
3424
# ---------------
 
3425
AC_DEFUN([_LT_AC_LANG_F77],
 
3426
[AC_REQUIRE([AC_PROG_F77])
 
3427
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
 
3428
])# _LT_AC_LANG_F77
 
3429
 
 
3430
 
 
3431
# AC_LIBTOOL_GCJ
 
3432
# --------------
 
3433
# enable support for GCJ libraries
 
3434
AC_DEFUN([AC_LIBTOOL_GCJ],
 
3435
[AC_REQUIRE([_LT_AC_LANG_GCJ])
 
3436
])# AC_LIBTOOL_GCJ
 
3437
 
 
3438
 
 
3439
# _LT_AC_LANG_GCJ
 
3440
# ---------------
 
3441
AC_DEFUN([_LT_AC_LANG_GCJ],
 
3442
[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
 
3443
  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
 
3444
    [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
 
3445
      [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
 
3446
         [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
 
3447
           [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
 
3448
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
 
3449
])# _LT_AC_LANG_GCJ
 
3450
 
 
3451
 
 
3452
# AC_LIBTOOL_RC
 
3453
# -------------
 
3454
# enable support for Windows resource files
 
3455
AC_DEFUN([AC_LIBTOOL_RC],
 
3456
[AC_REQUIRE([LT_AC_PROG_RC])
 
3457
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
 
3458
])# AC_LIBTOOL_RC
 
3459
 
 
3460
 
 
3461
# AC_LIBTOOL_LANG_C_CONFIG
 
3462
# ------------------------
 
3463
# Ensure that the configuration vars for the C compiler are
 
3464
# suitably defined.  Those variables are subsequently used by
 
3465
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
 
3466
AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
 
3467
AC_DEFUN([_LT_AC_LANG_C_CONFIG],
 
3468
[lt_save_CC="$CC"
 
3469
AC_LANG_PUSH(C)
 
3470
 
 
3471
# Source file extension for C test sources.
 
3472
ac_ext=c
 
3473
 
 
3474
# Object file extension for compiled C test sources.
 
3475
objext=o
 
3476
_LT_AC_TAGVAR(objext, $1)=$objext
 
3477
 
 
3478
# Code to be used in simple compile tests
 
3479
lt_simple_compile_test_code="int some_variable = 0;"
 
3480
 
 
3481
# Code to be used in simple link tests
 
3482
lt_simple_link_test_code='int main(){return(0);}'
 
3483
 
 
3484
_LT_AC_SYS_COMPILER
 
3485
 
 
3486
# save warnings/boilerplate of simple test code
 
3487
_LT_COMPILER_BOILERPLATE
 
3488
_LT_LINKER_BOILERPLATE
 
3489
 
 
3490
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
 
3491
AC_LIBTOOL_PROG_COMPILER_PIC($1)
 
3492
AC_LIBTOOL_PROG_CC_C_O($1)
 
3493
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
 
3494
AC_LIBTOOL_PROG_LD_SHLIBS($1)
 
3495
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 
3496
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
 
3497
AC_LIBTOOL_SYS_LIB_STRIP
 
3498
AC_LIBTOOL_DLOPEN_SELF
 
3499
 
 
3500
# Report which library types will actually be built
 
3501
AC_MSG_CHECKING([if libtool supports shared libraries])
 
3502
AC_MSG_RESULT([$can_build_shared])
 
3503
 
 
3504
AC_MSG_CHECKING([whether to build shared libraries])
 
3505
test "$can_build_shared" = "no" && enable_shared=no
 
3506
 
 
3507
# On AIX, shared libraries and static libraries use the same namespace, and
 
3508
# are all built from PIC.
 
3509
case $host_os in
 
3510
aix3*)
 
3511
  test "$enable_shared" = yes && enable_static=no
 
3512
  if test -n "$RANLIB"; then
 
3513
    archive_cmds="$archive_cmds~\$RANLIB \$lib"
 
3514
    postinstall_cmds='$RANLIB $lib'
 
3515
  fi
 
3516
  ;;
 
3517
 
 
3518
aix[[4-9]]*)
 
3519
  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
 
3520
    test "$enable_shared" = yes && enable_static=no
 
3521
  fi
 
3522
    ;;
 
3523
esac
 
3524
AC_MSG_RESULT([$enable_shared])
 
3525
 
 
3526
AC_MSG_CHECKING([whether to build static libraries])
 
3527
# Make sure either enable_shared or enable_static is yes.
 
3528
test "$enable_shared" = yes || enable_static=yes
 
3529
AC_MSG_RESULT([$enable_static])
 
3530
 
 
3531
AC_LIBTOOL_CONFIG($1)
 
3532
 
 
3533
AC_LANG_POP
 
3534
CC="$lt_save_CC"
 
3535
])# AC_LIBTOOL_LANG_C_CONFIG
 
3536
 
 
3537
 
 
3538
# AC_LIBTOOL_LANG_CXX_CONFIG
 
3539
# --------------------------
 
3540
# Ensure that the configuration vars for the C compiler are
 
3541
# suitably defined.  Those variables are subsequently used by
 
3542
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
 
3543
AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
 
3544
AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
 
3545
[AC_LANG_PUSH(C++)
 
3546
AC_REQUIRE([AC_PROG_CXX])
 
3547
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
 
3548
 
 
3549
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
3550
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
 
3551
_LT_AC_TAGVAR(always_export_symbols, $1)=no
 
3552
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
 
3553
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
 
3554
_LT_AC_TAGVAR(hardcode_direct, $1)=no
 
3555
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
 
3556
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
 
3557
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 
3558
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
 
3559
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
 
3560
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
 
3561
_LT_AC_TAGVAR(module_cmds, $1)=
 
3562
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
 
3563
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
 
3564
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
3565
_LT_AC_TAGVAR(no_undefined_flag, $1)=
 
3566
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
 
3567
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
 
3568
 
 
3569
# Dependencies to place before and after the object being linked:
 
3570
_LT_AC_TAGVAR(predep_objects, $1)=
 
3571
_LT_AC_TAGVAR(postdep_objects, $1)=
 
3572
_LT_AC_TAGVAR(predeps, $1)=
 
3573
_LT_AC_TAGVAR(postdeps, $1)=
 
3574
_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
 
3575
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
 
3576
 
 
3577
# Source file extension for C++ test sources.
 
3578
ac_ext=cpp
 
3579
 
 
3580
# Object file extension for compiled C++ test sources.
 
3581
objext=o
 
3582
_LT_AC_TAGVAR(objext, $1)=$objext
 
3583
 
 
3584
# Code to be used in simple compile tests
 
3585
lt_simple_compile_test_code="int some_variable = 0;"
 
3586
 
 
3587
# Code to be used in simple link tests
 
3588
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
 
3589
 
 
3590
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
 
3591
_LT_AC_SYS_COMPILER
 
3592
 
 
3593
# save warnings/boilerplate of simple test code
 
3594
_LT_COMPILER_BOILERPLATE
 
3595
_LT_LINKER_BOILERPLATE
 
3596
 
 
3597
# Allow CC to be a program name with arguments.
 
3598
lt_save_CC=$CC
 
3599
lt_save_LD=$LD
 
3600
lt_save_GCC=$GCC
 
3601
GCC=$GXX
 
3602
lt_save_with_gnu_ld=$with_gnu_ld
 
3603
lt_save_path_LD=$lt_cv_path_LD
 
3604
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
 
3605
  lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
 
3606
else
 
3607
  $as_unset lt_cv_prog_gnu_ld
 
3608
fi
 
3609
if test -n "${lt_cv_path_LDCXX+set}"; then
 
3610
  lt_cv_path_LD=$lt_cv_path_LDCXX
 
3611
else
 
3612
  $as_unset lt_cv_path_LD
 
3613
fi
 
3614
test -z "${LDCXX+set}" || LD=$LDCXX
 
3615
CC=${CXX-"c++"}
 
3616
compiler=$CC
 
3617
_LT_AC_TAGVAR(compiler, $1)=$CC
 
3618
_LT_CC_BASENAME([$compiler])
 
3619
 
 
3620
# We don't want -fno-exception wen compiling C++ code, so set the
 
3621
# no_builtin_flag separately
 
3622
if test "$GXX" = yes; then
 
3623
  _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
 
3624
else
 
3625
  _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
 
3626
fi
 
3627
 
 
3628
if test "$GXX" = yes; then
 
3629
  # Set up default GNU C++ configuration
 
3630
 
 
3631
  AC_PROG_LD
 
3632
 
 
3633
  # Check if GNU C++ uses GNU ld as the underlying linker, since the
 
3634
  # archiving commands below assume that GNU ld is being used.
 
3635
  if test "$with_gnu_ld" = yes; then
 
3636
    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
3637
    _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'
 
3638
 
 
3639
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
 
3640
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 
3641
 
 
3642
    # If archive_cmds runs LD, not CC, wlarc should be empty
 
3643
    # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
 
3644
    #     investigate it a little bit more. (MM)
 
3645
    wlarc='${wl}'
 
3646
 
 
3647
    # ancient GNU ld didn't support --whole-archive et. al.
 
3648
    if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
 
3649
        grep 'no-whole-archive' > /dev/null; then
 
3650
      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
 
3651
    else
 
3652
      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
 
3653
    fi
 
3654
  else
 
3655
    with_gnu_ld=no
 
3656
    wlarc=
 
3657
 
 
3658
    # A generic and very simple default shared library creation
 
3659
    # command for GNU C++ for the case where it uses the native
 
3660
    # linker, instead of GNU ld.  If possible, this setting should
 
3661
    # overridden to take advantage of the native linker features on
 
3662
    # the platform it is being used on.
 
3663
    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
 
3664
  fi
 
3665
 
 
3666
  # Commands to make compiler produce verbose output that lists
 
3667
  # what "hidden" libraries, object files and flags are used when
 
3668
  # linking a shared library.
 
3669
  output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
 
3670
 
 
3671
else
 
3672
  GXX=no
 
3673
  with_gnu_ld=no
 
3674
  wlarc=
 
3675
fi
 
3676
 
 
3677
# PORTME: fill in a description of your system's C++ link characteristics
 
3678
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
 
3679
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
 
3680
case $host_os in
 
3681
  aix3*)
 
3682
    # FIXME: insert proper C++ library support
 
3683
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3684
    ;;
 
3685
  aix[[4-9]]*)
 
3686
    if test "$host_cpu" = ia64; then
 
3687
      # On IA64, the linker does run time linking by default, so we don't
 
3688
      # have to do anything special.
 
3689
      aix_use_runtimelinking=no
 
3690
      exp_sym_flag='-Bexport'
 
3691
      no_entry_flag=""
 
3692
    else
 
3693
      aix_use_runtimelinking=no
 
3694
 
 
3695
      # Test if we are trying to use run time linking or normal
 
3696
      # AIX style linking. If -brtl is somewhere in LDFLAGS, we
 
3697
      # need to do runtime linking.
 
3698
      case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
 
3699
        for ld_flag in $LDFLAGS; do
 
3700
          case $ld_flag in
 
3701
          *-brtl*)
 
3702
            aix_use_runtimelinking=yes
 
3703
            break
 
3704
            ;;
 
3705
          esac
 
3706
        done
 
3707
        ;;
 
3708
      esac
 
3709
 
 
3710
      exp_sym_flag='-bexport'
 
3711
      no_entry_flag='-bnoentry'
 
3712
    fi
 
3713
 
 
3714
    # When large executables or shared objects are built, AIX ld can
 
3715
    # have problems creating the table of contents.  If linking a library
 
3716
    # or program results in "error TOC overflow" add -mminimal-toc to
 
3717
    # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
 
3718
    # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
 
3719
 
 
3720
    _LT_AC_TAGVAR(archive_cmds, $1)=''
 
3721
    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
3722
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
 
3723
    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
3724
 
 
3725
    if test "$GXX" = yes; then
 
3726
      case $host_os in aix4.[[012]]|aix4.[[012]].*)
 
3727
      # We only want to do this on AIX 4.2 and lower, the check
 
3728
      # below for broken collect2 doesn't work under 4.3+
 
3729
        collect2name=`${CC} -print-prog-name=collect2`
 
3730
        if test -f "$collect2name" && \
 
3731
           strings "$collect2name" | grep resolve_lib_name >/dev/null
 
3732
        then
 
3733
          # We have reworked collect2
 
3734
          :
 
3735
        else
 
3736
          # We have old collect2
 
3737
          _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
 
3738
          # It fails to find uninstalled libraries when the uninstalled
 
3739
          # path is not listed in the libpath.  Setting hardcode_minus_L
 
3740
          # to unsupported forces relinking
 
3741
          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
3742
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
3743
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 
3744
        fi
 
3745
        ;;
 
3746
      esac
 
3747
      shared_flag='-shared'
 
3748
      if test "$aix_use_runtimelinking" = yes; then
 
3749
        shared_flag="$shared_flag "'${wl}-G'
 
3750
      fi
 
3751
    else
 
3752
      # not using gcc
 
3753
      if test "$host_cpu" = ia64; then
 
3754
        # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
 
3755
        # chokes on -Wl,-G. The following line is correct:
 
3756
        shared_flag='-G'
 
3757
      else
 
3758
        if test "$aix_use_runtimelinking" = yes; then
 
3759
          shared_flag='${wl}-G'
 
3760
        else
 
3761
          shared_flag='${wl}-bM:SRE'
 
3762
        fi
 
3763
      fi
 
3764
    fi
 
3765
 
 
3766
    # It seems that -bexpall does not export symbols beginning with
 
3767
    # underscore (_), so it is better to generate a list of symbols to export.
 
3768
    _LT_AC_TAGVAR(always_export_symbols, $1)=yes
 
3769
    if test "$aix_use_runtimelinking" = yes; then
 
3770
      # Warning - without using the other runtime loading flags (-brtl),
 
3771
      # -berok will link without error, but may produce a broken library.
 
3772
      _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
 
3773
      # Determine the default libpath from the value encoded in an empty executable.
 
3774
      _LT_AC_SYS_LIBPATH_AIX
 
3775
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
3776
 
 
3777
      _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"
 
3778
     else
 
3779
      if test "$host_cpu" = ia64; then
 
3780
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
 
3781
        _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
 
3782
        _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"
 
3783
      else
 
3784
        # Determine the default libpath from the value encoded in an empty executable.
 
3785
        _LT_AC_SYS_LIBPATH_AIX
 
3786
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
3787
        # Warning - without using the other run time loading flags,
 
3788
        # -berok will link without error, but may produce a broken library.
 
3789
        _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 
3790
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
 
3791
        # Exported symbols can be pulled into shared objects from archives
 
3792
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 
3793
        _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 
3794
        # This is similar to how AIX traditionally builds its shared libraries.
 
3795
        _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'
 
3796
      fi
 
3797
    fi
 
3798
    ;;
 
3799
 
 
3800
  beos*)
 
3801
    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
3802
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
3803
      # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
 
3804
      # support --undefined.  This deserves some investigation.  FIXME
 
3805
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
3806
    else
 
3807
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3808
    fi
 
3809
    ;;
 
3810
 
 
3811
  chorus*)
 
3812
    case $cc_basename in
 
3813
      *)
 
3814
        # FIXME: insert proper C++ library support
 
3815
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3816
        ;;
 
3817
    esac
 
3818
    ;;
 
3819
 
 
3820
  cygwin* | mingw* | pw32*)
 
3821
    # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
 
3822
    # as there is no search path for DLLs.
 
3823
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
3824
    _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
3825
    _LT_AC_TAGVAR(always_export_symbols, $1)=no
 
3826
    _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
3827
 
 
3828
    if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
 
3829
      _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'
 
3830
      # If the export-symbols file already is a .def file (1st line
 
3831
      # is EXPORTS), use it as is; otherwise, prepend...
 
3832
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
 
3833
        cp $export_symbols $output_objdir/$soname.def;
 
3834
      else
 
3835
        echo EXPORTS > $output_objdir/$soname.def;
 
3836
        cat $export_symbols >> $output_objdir/$soname.def;
 
3837
      fi~
 
3838
      $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'
 
3839
    else
 
3840
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3841
    fi
 
3842
  ;;
 
3843
      darwin* | rhapsody*)
 
3844
      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
3845
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
3846
      _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
 
3847
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
 
3848
      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
 
3849
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
3850
      _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
 
3851
      if test "$GXX" = yes ; then
 
3852
      output_verbose_link_cmd='echo'
 
3853
      _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}"
 
3854
      _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
 
3855
      _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}"
 
3856
      _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}"
 
3857
      if test "$lt_cv_apple_cc_single_mod" != "yes"; then
 
3858
        _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}"
 
3859
        _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}"
 
3860
      fi
 
3861
      else
 
3862
      case $cc_basename in
 
3863
        xlc*)
 
3864
         output_verbose_link_cmd='echo'
 
3865
          _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'
 
3866
          _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
 
3867
          # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
 
3868
          _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}'
 
3869
          _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}'
 
3870
          ;;
 
3871
       *)
 
3872
         _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3873
          ;;
 
3874
      esac
 
3875
      fi
 
3876
        ;;
 
3877
 
 
3878
  dgux*)
 
3879
    case $cc_basename in
 
3880
      ec++*)
 
3881
        # FIXME: insert proper C++ library support
 
3882
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3883
        ;;
 
3884
      ghcx*)
 
3885
        # Green Hills C++ Compiler
 
3886
        # FIXME: insert proper C++ library support
 
3887
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3888
        ;;
 
3889
      *)
 
3890
        # FIXME: insert proper C++ library support
 
3891
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3892
        ;;
 
3893
    esac
 
3894
    ;;
 
3895
  freebsd[[12]]*)
 
3896
    # C++ shared libraries reported to be fairly broken before switch to ELF
 
3897
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3898
    ;;
 
3899
  freebsd-elf*)
 
3900
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
3901
    ;;
 
3902
  freebsd* | dragonfly*)
 
3903
    # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
 
3904
    # conventions
 
3905
    _LT_AC_TAGVAR(ld_shlibs, $1)=yes
 
3906
    ;;
 
3907
  gnu*)
 
3908
    ;;
 
3909
  hpux9*)
 
3910
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
3911
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
3912
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
3913
    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
3914
    _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
 
3915
                                # but as the default
 
3916
                                # location of the library.
 
3917
 
 
3918
    case $cc_basename in
 
3919
    CC*)
 
3920
      # FIXME: insert proper C++ library support
 
3921
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3922
      ;;
 
3923
    aCC*)
 
3924
      _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'
 
3925
      # Commands to make compiler produce verbose output that lists
 
3926
      # what "hidden" libraries, object files and flags are used when
 
3927
      # linking a shared library.
 
3928
      #
 
3929
      # There doesn't appear to be a way to prevent this compiler from
 
3930
      # explicitly linking system object files so we need to strip them
 
3931
      # from the output so that they don't get included in the library
 
3932
      # dependencies.
 
3933
      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'
 
3934
      ;;
 
3935
    *)
 
3936
      if test "$GXX" = yes; then
 
3937
        _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'
 
3938
      else
 
3939
        # FIXME: insert proper C++ library support
 
3940
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3941
      fi
 
3942
      ;;
 
3943
    esac
 
3944
    ;;
 
3945
  hpux10*|hpux11*)
 
3946
    if test $with_gnu_ld = no; then
 
3947
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
3948
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
3949
 
 
3950
      case $host_cpu in
 
3951
      hppa*64*|ia64*) ;;
 
3952
      *)
 
3953
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
3954
        ;;
 
3955
      esac
 
3956
    fi
 
3957
    case $host_cpu in
 
3958
    hppa*64*|ia64*)
 
3959
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
3960
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
3961
      ;;
 
3962
    *)
 
3963
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
3964
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
 
3965
                                              # but as the default
 
3966
                                              # location of the library.
 
3967
      ;;
 
3968
    esac
 
3969
 
 
3970
    case $cc_basename in
 
3971
      CC*)
 
3972
        # FIXME: insert proper C++ library support
 
3973
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3974
        ;;
 
3975
      aCC*)
 
3976
        case $host_cpu in
 
3977
        hppa*64*)
 
3978
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
3979
          ;;
 
3980
        ia64*)
 
3981
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
3982
          ;;
 
3983
        *)
 
3984
          _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'
 
3985
          ;;
 
3986
        esac
 
3987
        # Commands to make compiler produce verbose output that lists
 
3988
        # what "hidden" libraries, object files and flags are used when
 
3989
        # linking a shared library.
 
3990
        #
 
3991
        # There doesn't appear to be a way to prevent this compiler from
 
3992
        # explicitly linking system object files so we need to strip them
 
3993
        # from the output so that they don't get included in the library
 
3994
        # dependencies.
 
3995
        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'
 
3996
        ;;
 
3997
      *)
 
3998
        if test "$GXX" = yes; then
 
3999
          if test $with_gnu_ld = no; then
 
4000
            case $host_cpu in
 
4001
            hppa*64*)
 
4002
              _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
4003
              ;;
 
4004
            ia64*)
 
4005
              _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'
 
4006
              ;;
 
4007
            *)
 
4008
              _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'
 
4009
              ;;
 
4010
            esac
 
4011
          fi
 
4012
        else
 
4013
          # FIXME: insert proper C++ library support
 
4014
          _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4015
        fi
 
4016
        ;;
 
4017
    esac
 
4018
    ;;
 
4019
  interix[[3-9]]*)
 
4020
    _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
4021
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
4022
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
4023
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
4024
    # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
 
4025
    # Instead, shared libraries are loaded at an image base (0x10000000 by
 
4026
    # default) and relocated if they conflict, which is a slow very memory
 
4027
    # consuming and fragmenting process.  To avoid this, we pick a random,
 
4028
    # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
 
4029
    # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
 
4030
    _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'
 
4031
    _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'
 
4032
    ;;
 
4033
  irix5* | irix6*)
 
4034
    case $cc_basename in
 
4035
      CC*)
 
4036
        # SGI C++
 
4037
        _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'
 
4038
 
 
4039
        # Archives containing C++ object files must be created using
 
4040
        # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
 
4041
        # necessary to make sure instantiated templates are included
 
4042
        # in the archive.
 
4043
        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
 
4044
        ;;
 
4045
      *)
 
4046
        if test "$GXX" = yes; then
 
4047
          if test "$with_gnu_ld" = no; then
 
4048
            _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'
 
4049
          else
 
4050
            _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'
 
4051
          fi
 
4052
        fi
 
4053
        _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
4054
        ;;
 
4055
    esac
 
4056
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
4057
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4058
    ;;
 
4059
  linux* | k*bsd*-gnu)
 
4060
    case $cc_basename in
 
4061
      KCC*)
 
4062
        # Kuck and Associates, Inc. (KAI) C++ Compiler
 
4063
 
 
4064
        # KCC will only create a shared library if the output file
 
4065
        # ends with ".so" (or ".sl" for HP-UX), so rename the library
 
4066
        # to its proper name (with version) after linking.
 
4067
        _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'
 
4068
        _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'
 
4069
        # Commands to make compiler produce verbose output that lists
 
4070
        # what "hidden" libraries, object files and flags are used when
 
4071
        # linking a shared library.
 
4072
        #
 
4073
        # There doesn't appear to be a way to prevent this compiler from
 
4074
        # explicitly linking system object files so we need to strip them
 
4075
        # from the output so that they don't get included in the library
 
4076
        # dependencies.
 
4077
        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'
 
4078
 
 
4079
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
 
4080
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 
4081
 
 
4082
        # Archives containing C++ object files must be created using
 
4083
        # "CC -Bstatic", where "CC" is the KAI C++ compiler.
 
4084
        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
 
4085
        ;;
 
4086
      icpc*)
 
4087
        # Intel C++
 
4088
        with_gnu_ld=yes
 
4089
        # version 8.0 and above of icpc choke on multiply defined symbols
 
4090
        # if we add $predep_objects and $postdep_objects, however 7.1 and
 
4091
        # earlier do not add the objects themselves.
 
4092
        case `$CC -V 2>&1` in
 
4093
        *"Version 7."*)
 
4094
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4095
          _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'
 
4096
          ;;
 
4097
        *)  # Version 8.0 or newer
 
4098
          tmp_idyn=
 
4099
          case $host_cpu in
 
4100
            ia64*) tmp_idyn=' -i_dynamic';;
 
4101
          esac
 
4102
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4103
          _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'
 
4104
          ;;
 
4105
        esac
 
4106
        _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
4107
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
4108
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 
4109
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
 
4110
        ;;
 
4111
      pgCC* | pgcpp*)
 
4112
        # Portland Group C++ compiler
 
4113
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
 
4114
        _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'
 
4115
 
 
4116
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
 
4117
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 
4118
        _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'
 
4119
        ;;
 
4120
      cxx*)
 
4121
        # Compaq C++
 
4122
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4123
        _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'
 
4124
 
 
4125
        runpath_var=LD_RUN_PATH
 
4126
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
 
4127
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4128
 
 
4129
        # Commands to make compiler produce verbose output that lists
 
4130
        # what "hidden" libraries, object files and flags are used when
 
4131
        # linking a shared library.
 
4132
        #
 
4133
        # There doesn't appear to be a way to prevent this compiler from
 
4134
        # explicitly linking system object files so we need to strip them
 
4135
        # from the output so that they don't get included in the library
 
4136
        # dependencies.
 
4137
        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'
 
4138
        ;;
 
4139
      *)
 
4140
        case `$CC -V 2>&1 | sed 5q` in
 
4141
        *Sun\ C*)
 
4142
          # Sun C++ 5.9
 
4143
          _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
 
4144
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
4145
          _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'
 
4146
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
4147
          _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'
 
4148
 
 
4149
          # Not sure whether something based on
 
4150
          # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
 
4151
          # would be better.
 
4152
          output_verbose_link_cmd='echo'
 
4153
 
 
4154
          # Archives containing C++ object files must be created using
 
4155
          # "CC -xar", where "CC" is the Sun C++ compiler.  This is
 
4156
          # necessary to make sure instantiated templates are included
 
4157
          # in the archive.
 
4158
          _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
 
4159
          ;;
 
4160
        esac
 
4161
        ;;
 
4162
    esac
 
4163
    ;;
 
4164
  lynxos*)
 
4165
    # FIXME: insert proper C++ library support
 
4166
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4167
    ;;
 
4168
  m88k*)
 
4169
    # FIXME: insert proper C++ library support
 
4170
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4171
    ;;
 
4172
  mvs*)
 
4173
    case $cc_basename in
 
4174
      cxx*)
 
4175
        # FIXME: insert proper C++ library support
 
4176
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4177
        ;;
 
4178
      *)
 
4179
        # FIXME: insert proper C++ library support
 
4180
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4181
        ;;
 
4182
    esac
 
4183
    ;;
 
4184
  netbsd*)
 
4185
    if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
 
4186
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
 
4187
      wlarc=
 
4188
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
4189
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
4190
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
4191
    fi
 
4192
    # Workaround some broken pre-1.5 toolchains
 
4193
    output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
 
4194
    ;;
 
4195
  openbsd2*)
 
4196
    # C++ shared libraries are fairly broken
 
4197
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4198
    ;;
 
4199
  openbsd*)
 
4200
    if test -f /usr/libexec/ld.so; then
 
4201
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
4202
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
4203
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
 
4204
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
4205
      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
 
4206
        _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'
 
4207
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
4208
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
 
4209
      fi
 
4210
      output_verbose_link_cmd='echo'
 
4211
    else
 
4212
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4213
    fi
 
4214
    ;;
 
4215
  osf3*)
 
4216
    case $cc_basename in
 
4217
      KCC*)
 
4218
        # Kuck and Associates, Inc. (KAI) C++ Compiler
 
4219
 
 
4220
        # KCC will only create a shared library if the output file
 
4221
        # ends with ".so" (or ".sl" for HP-UX), so rename the library
 
4222
        # to its proper name (with version) after linking.
 
4223
        _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'
 
4224
 
 
4225
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
4226
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4227
 
 
4228
        # Archives containing C++ object files must be created using
 
4229
        # "CC -Bstatic", where "CC" is the KAI C++ compiler.
 
4230
        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
 
4231
 
 
4232
        ;;
 
4233
      RCC*)
 
4234
        # Rational C++ 2.4.1
 
4235
        # FIXME: insert proper C++ library support
 
4236
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4237
        ;;
 
4238
      cxx*)
 
4239
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
 
4240
        _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'
 
4241
 
 
4242
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
4243
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4244
 
 
4245
        # Commands to make compiler produce verbose output that lists
 
4246
        # what "hidden" libraries, object files and flags are used when
 
4247
        # linking a shared library.
 
4248
        #
 
4249
        # There doesn't appear to be a way to prevent this compiler from
 
4250
        # explicitly linking system object files so we need to strip them
 
4251
        # from the output so that they don't get included in the library
 
4252
        # dependencies.
 
4253
        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'
 
4254
        ;;
 
4255
      *)
 
4256
        if test "$GXX" = yes && test "$with_gnu_ld" = no; then
 
4257
          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
 
4258
          _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'
 
4259
 
 
4260
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
4261
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4262
 
 
4263
          # Commands to make compiler produce verbose output that lists
 
4264
          # what "hidden" libraries, object files and flags are used when
 
4265
          # linking a shared library.
 
4266
          output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
 
4267
 
 
4268
        else
 
4269
          # FIXME: insert proper C++ library support
 
4270
          _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4271
        fi
 
4272
        ;;
 
4273
    esac
 
4274
    ;;
 
4275
  osf4* | osf5*)
 
4276
    case $cc_basename in
 
4277
      KCC*)
 
4278
        # Kuck and Associates, Inc. (KAI) C++ Compiler
 
4279
 
 
4280
        # KCC will only create a shared library if the output file
 
4281
        # ends with ".so" (or ".sl" for HP-UX), so rename the library
 
4282
        # to its proper name (with version) after linking.
 
4283
        _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'
 
4284
 
 
4285
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
4286
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4287
 
 
4288
        # Archives containing C++ object files must be created using
 
4289
        # the KAI C++ compiler.
 
4290
        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
 
4291
        ;;
 
4292
      RCC*)
 
4293
        # Rational C++ 2.4.1
 
4294
        # FIXME: insert proper C++ library support
 
4295
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4296
        ;;
 
4297
      cxx*)
 
4298
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
 
4299
        _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'
 
4300
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
 
4301
          echo "-hidden">> $lib.exp~
 
4302
          $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~
 
4303
          $rm $lib.exp'
 
4304
 
 
4305
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
 
4306
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4307
 
 
4308
        # Commands to make compiler produce verbose output that lists
 
4309
        # what "hidden" libraries, object files and flags are used when
 
4310
        # linking a shared library.
 
4311
        #
 
4312
        # There doesn't appear to be a way to prevent this compiler from
 
4313
        # explicitly linking system object files so we need to strip them
 
4314
        # from the output so that they don't get included in the library
 
4315
        # dependencies.
 
4316
        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'
 
4317
        ;;
 
4318
      *)
 
4319
        if test "$GXX" = yes && test "$with_gnu_ld" = no; then
 
4320
          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
 
4321
         _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'
 
4322
 
 
4323
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
4324
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
4325
 
 
4326
          # Commands to make compiler produce verbose output that lists
 
4327
          # what "hidden" libraries, object files and flags are used when
 
4328
          # linking a shared library.
 
4329
          output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
 
4330
 
 
4331
        else
 
4332
          # FIXME: insert proper C++ library support
 
4333
          _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4334
        fi
 
4335
        ;;
 
4336
    esac
 
4337
    ;;
 
4338
  psos*)
 
4339
    # FIXME: insert proper C++ library support
 
4340
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4341
    ;;
 
4342
  sunos4*)
 
4343
    case $cc_basename in
 
4344
      CC*)
 
4345
        # Sun C++ 4.x
 
4346
        # FIXME: insert proper C++ library support
 
4347
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4348
        ;;
 
4349
      lcc*)
 
4350
        # Lucid
 
4351
        # FIXME: insert proper C++ library support
 
4352
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4353
        ;;
 
4354
      *)
 
4355
        # FIXME: insert proper C++ library support
 
4356
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4357
        ;;
 
4358
    esac
 
4359
    ;;
 
4360
  solaris*)
 
4361
    case $cc_basename in
 
4362
      CC*)
 
4363
        # Sun C++ 4.2, 5.x and Centerline C++
 
4364
        _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
 
4365
        _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
 
4366
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
4367
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
 
4368
        $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'
 
4369
 
 
4370
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
4371
        _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
4372
        case $host_os in
 
4373
          solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
 
4374
          *)
 
4375
            # The compiler driver will combine and reorder linker options,
 
4376
            # but understands `-z linker_flag'.
 
4377
            # Supported since Solaris 2.6 (maybe 2.5.1?)
 
4378
            _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
 
4379
            ;;
 
4380
        esac
 
4381
        _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
4382
 
 
4383
        output_verbose_link_cmd='echo'
 
4384
 
 
4385
        # Archives containing C++ object files must be created using
 
4386
        # "CC -xar", where "CC" is the Sun C++ compiler.  This is
 
4387
        # necessary to make sure instantiated templates are included
 
4388
        # in the archive.
 
4389
        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
 
4390
        ;;
 
4391
      gcx*)
 
4392
        # Green Hills C++ Compiler
 
4393
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
 
4394
 
 
4395
        # The C++ compiler must be used to create the archive.
 
4396
        _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
 
4397
        ;;
 
4398
      *)
 
4399
        # GNU C++ compiler with Solaris linker
 
4400
        if test "$GXX" = yes && test "$with_gnu_ld" = no; then
 
4401
          _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
 
4402
          if $CC --version | grep -v '^2\.7' > /dev/null; then
 
4403
            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
 
4404
            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
 
4405
                $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
 
4406
 
 
4407
            # Commands to make compiler produce verbose output that lists
 
4408
            # what "hidden" libraries, object files and flags are used when
 
4409
            # linking a shared library.
 
4410
            output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
 
4411
          else
 
4412
            # g++ 2.7 appears to require `-G' NOT `-shared' on this
 
4413
            # platform.
 
4414
            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
 
4415
            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
 
4416
                $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
 
4417
 
 
4418
            # Commands to make compiler produce verbose output that lists
 
4419
            # what "hidden" libraries, object files and flags are used when
 
4420
            # linking a shared library.
 
4421
            output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
 
4422
          fi
 
4423
 
 
4424
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
 
4425
          case $host_os in
 
4426
          solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
 
4427
          *)
 
4428
            _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
 
4429
            ;;
 
4430
          esac
 
4431
        fi
 
4432
        ;;
 
4433
    esac
 
4434
    ;;
 
4435
  sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
 
4436
    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
4437
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
4438
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
4439
    runpath_var='LD_RUN_PATH'
 
4440
 
 
4441
    case $cc_basename in
 
4442
      CC*)
 
4443
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
4444
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
4445
        ;;
 
4446
      *)
 
4447
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
4448
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
4449
        ;;
 
4450
    esac
 
4451
    ;;
 
4452
  sysv5* | sco3.2v5* | sco5v6*)
 
4453
    # Note: We can NOT use -z defs as we might desire, because we do not
 
4454
    # link with -lc, and that would cause any symbols used from libc to
 
4455
    # always be unresolved, which means just about no library would
 
4456
    # ever link correctly.  If we're not using GNU ld we use -z text
 
4457
    # though, which does catch some bad symbols but isn't as heavy-handed
 
4458
    # as -z defs.
 
4459
    # For security reasons, it is highly recommended that you always
 
4460
    # use absolute paths for naming shared libraries, and exclude the
 
4461
    # DT_RUNPATH tag from executables and libraries.  But doing so
 
4462
    # requires that you compile everything twice, which is a pain.
 
4463
    # So that behaviour is only enabled if SCOABSPATH is set to a
 
4464
    # non-empty value in the environment.  Most likely only useful for
 
4465
    # creating official distributions of packages.
 
4466
    # This is a hack until libtool officially supports absolute path
 
4467
    # names for shared libraries.
 
4468
    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
4469
    _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
 
4470
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
4471
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
4472
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
 
4473
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
 
4474
    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
4475
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
 
4476
    runpath_var='LD_RUN_PATH'
 
4477
 
 
4478
    case $cc_basename in
 
4479
      CC*)
 
4480
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
4481
        _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'
 
4482
        ;;
 
4483
      *)
 
4484
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
4485
        _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'
 
4486
        ;;
 
4487
    esac
 
4488
    ;;
 
4489
  tandem*)
 
4490
    case $cc_basename in
 
4491
      NCC*)
 
4492
        # NonStop-UX NCC 3.20
 
4493
        # FIXME: insert proper C++ library support
 
4494
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4495
        ;;
 
4496
      *)
 
4497
        # FIXME: insert proper C++ library support
 
4498
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4499
        ;;
 
4500
    esac
 
4501
    ;;
 
4502
  vxworks*)
 
4503
    # FIXME: insert proper C++ library support
 
4504
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4505
    ;;
 
4506
  *)
 
4507
    # FIXME: insert proper C++ library support
 
4508
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
4509
    ;;
 
4510
esac
 
4511
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
 
4512
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
 
4513
 
 
4514
_LT_AC_TAGVAR(GCC, $1)="$GXX"
 
4515
_LT_AC_TAGVAR(LD, $1)="$LD"
 
4516
 
 
4517
AC_LIBTOOL_POSTDEP_PREDEP($1)
 
4518
AC_LIBTOOL_PROG_COMPILER_PIC($1)
 
4519
AC_LIBTOOL_PROG_CC_C_O($1)
 
4520
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
 
4521
AC_LIBTOOL_PROG_LD_SHLIBS($1)
 
4522
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 
4523
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
 
4524
 
 
4525
AC_LIBTOOL_CONFIG($1)
 
4526
 
 
4527
AC_LANG_POP
 
4528
CC=$lt_save_CC
 
4529
LDCXX=$LD
 
4530
LD=$lt_save_LD
 
4531
GCC=$lt_save_GCC
 
4532
with_gnu_ldcxx=$with_gnu_ld
 
4533
with_gnu_ld=$lt_save_with_gnu_ld
 
4534
lt_cv_path_LDCXX=$lt_cv_path_LD
 
4535
lt_cv_path_LD=$lt_save_path_LD
 
4536
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
 
4537
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
 
4538
])# AC_LIBTOOL_LANG_CXX_CONFIG
 
4539
 
 
4540
# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
 
4541
# ------------------------------------
 
4542
# Figure out "hidden" library dependencies from verbose
 
4543
# compiler output when linking a shared library.
 
4544
# Parse the compiler output and extract the necessary
 
4545
# objects, libraries and library flags.
 
4546
AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],
 
4547
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
4548
dnl we can't use the lt_simple_compile_test_code here,
 
4549
dnl because it contains code intended for an executable,
 
4550
dnl not a library.  It's possible we should let each
 
4551
dnl tag define a new lt_????_link_test_code variable,
 
4552
dnl but it's only used here...
 
4553
ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
 
4554
int a;
 
4555
void foo (void) { a = 0; }
 
4556
EOF
 
4557
],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
 
4558
class Foo
 
4559
{
 
4560
public:
 
4561
  Foo (void) { a = 0; }
 
4562
private:
 
4563
  int a;
 
4564
};
 
4565
EOF
 
4566
],[$1],[F77],[cat > conftest.$ac_ext <<EOF
 
4567
      subroutine foo
 
4568
      implicit none
 
4569
      integer*4 a
 
4570
      a=0
 
4571
      return
 
4572
      end
 
4573
EOF
 
4574
],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
 
4575
public class foo {
 
4576
  private int a;
 
4577
  public void bar (void) {
 
4578
    a = 0;
 
4579
  }
 
4580
};
 
4581
EOF
 
4582
])
 
4583
dnl Parse the compiler output and extract the necessary
 
4584
dnl objects, libraries and library flags.
 
4585
if AC_TRY_EVAL(ac_compile); then
 
4586
  # Parse the compiler output and extract the necessary
 
4587
  # objects, libraries and library flags.
 
4588
 
 
4589
  # Sentinel used to keep track of whether or not we are before
 
4590
  # the conftest object file.
 
4591
  pre_test_object_deps_done=no
 
4592
 
 
4593
  # The `*' in the case matches for architectures that use `case' in
 
4594
  # $output_verbose_cmd can trigger glob expansion during the loop
 
4595
  # eval without this substitution.
 
4596
  output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
 
4597
 
 
4598
  for p in `eval $output_verbose_link_cmd`; do
 
4599
    case $p in
 
4600
 
 
4601
    -L* | -R* | -l*)
 
4602
       # Some compilers place space between "-{L,R}" and the path.
 
4603
       # Remove the space.
 
4604
       if test $p = "-L" \
 
4605
          || test $p = "-R"; then
 
4606
         prev=$p
 
4607
         continue
 
4608
       else
 
4609
         prev=
 
4610
       fi
 
4611
 
 
4612
       if test "$pre_test_object_deps_done" = no; then
 
4613
         case $p in
 
4614
         -L* | -R*)
 
4615
           # Internal compiler library paths should come after those
 
4616
           # provided the user.  The postdeps already come after the
 
4617
           # user supplied libs so there is no need to process them.
 
4618
           if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
 
4619
             _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
 
4620
           else
 
4621
             _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
 
4622
           fi
 
4623
           ;;
 
4624
         # The "-l" case would never come before the object being
 
4625
         # linked, so don't bother handling this case.
 
4626
         esac
 
4627
       else
 
4628
         if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
 
4629
           _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
 
4630
         else
 
4631
           _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
 
4632
         fi
 
4633
       fi
 
4634
       ;;
 
4635
 
 
4636
    *.$objext)
 
4637
       # This assumes that the test object file only shows up
 
4638
       # once in the compiler output.
 
4639
       if test "$p" = "conftest.$objext"; then
 
4640
         pre_test_object_deps_done=yes
 
4641
         continue
 
4642
       fi
 
4643
 
 
4644
       if test "$pre_test_object_deps_done" = no; then
 
4645
         if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
 
4646
           _LT_AC_TAGVAR(predep_objects, $1)="$p"
 
4647
         else
 
4648
           _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
 
4649
         fi
 
4650
       else
 
4651
         if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
 
4652
           _LT_AC_TAGVAR(postdep_objects, $1)="$p"
 
4653
         else
 
4654
           _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
 
4655
         fi
 
4656
       fi
 
4657
       ;;
 
4658
 
 
4659
    *) ;; # Ignore the rest.
 
4660
 
 
4661
    esac
 
4662
  done
 
4663
 
 
4664
  # Clean up.
 
4665
  rm -f a.out a.exe
 
4666
else
 
4667
  echo "libtool.m4: error: problem compiling $1 test program"
 
4668
fi
 
4669
 
 
4670
$rm -f confest.$objext
 
4671
 
 
4672
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
 
4673
if test -n "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
 
4674
  _LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_AC_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
 
4675
fi
 
4676
 
 
4677
# PORTME: override above test on systems where it is broken
 
4678
ifelse([$1],[CXX],
 
4679
[case $host_os in
 
4680
interix[[3-9]]*)
 
4681
  # Interix 3.5 installs completely hosed .la files for C++, so rather than
 
4682
  # hack all around it, let's just trust "g++" to DTRT.
 
4683
  _LT_AC_TAGVAR(predep_objects,$1)=
 
4684
  _LT_AC_TAGVAR(postdep_objects,$1)=
 
4685
  _LT_AC_TAGVAR(postdeps,$1)=
 
4686
  ;;
 
4687
 
 
4688
linux*)
 
4689
  case `$CC -V 2>&1 | sed 5q` in
 
4690
  *Sun\ C*)
 
4691
    # Sun C++ 5.9
 
4692
    #
 
4693
    # The more standards-conforming stlport4 library is
 
4694
    # incompatible with the Cstd library. Avoid specifying
 
4695
    # it if it's in CXXFLAGS. Ignore libCrun as
 
4696
    # -library=stlport4 depends on it.
 
4697
    case " $CXX $CXXFLAGS " in
 
4698
    *" -library=stlport4 "*)
 
4699
      solaris_use_stlport4=yes
 
4700
      ;;
 
4701
    esac
 
4702
    if test "$solaris_use_stlport4" != yes; then
 
4703
      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
 
4704
    fi
 
4705
    ;;
 
4706
  esac
 
4707
  ;;
 
4708
 
 
4709
solaris*)
 
4710
  case $cc_basename in
 
4711
  CC*)
 
4712
    # The more standards-conforming stlport4 library is
 
4713
    # incompatible with the Cstd library. Avoid specifying
 
4714
    # it if it's in CXXFLAGS. Ignore libCrun as
 
4715
    # -library=stlport4 depends on it.
 
4716
    case " $CXX $CXXFLAGS " in
 
4717
    *" -library=stlport4 "*)
 
4718
      solaris_use_stlport4=yes
 
4719
      ;;
 
4720
    esac
 
4721
 
 
4722
    # Adding this requires a known-good setup of shared libraries for
 
4723
    # Sun compiler versions before 5.6, else PIC objects from an old
 
4724
    # archive will be linked into the output, leading to subtle bugs.
 
4725
    if test "$solaris_use_stlport4" != yes; then
 
4726
      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
 
4727
    fi
 
4728
    ;;
 
4729
  esac
 
4730
  ;;
 
4731
esac
 
4732
])
 
4733
case " $_LT_AC_TAGVAR(postdeps, $1) " in
 
4734
*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
 
4735
esac
 
4736
])# AC_LIBTOOL_POSTDEP_PREDEP
 
4737
 
 
4738
# AC_LIBTOOL_LANG_F77_CONFIG
 
4739
# --------------------------
 
4740
# Ensure that the configuration vars for the C compiler are
 
4741
# suitably defined.  Those variables are subsequently used by
 
4742
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
 
4743
AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
 
4744
AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
 
4745
[AC_REQUIRE([AC_PROG_F77])
 
4746
AC_LANG_PUSH(Fortran 77)
 
4747
 
 
4748
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
4749
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
 
4750
_LT_AC_TAGVAR(always_export_symbols, $1)=no
 
4751
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
 
4752
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
 
4753
_LT_AC_TAGVAR(hardcode_direct, $1)=no
 
4754
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
 
4755
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
 
4756
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 
4757
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
 
4758
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
 
4759
_LT_AC_TAGVAR(module_cmds, $1)=
 
4760
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
 
4761
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
 
4762
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
4763
_LT_AC_TAGVAR(no_undefined_flag, $1)=
 
4764
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
 
4765
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
 
4766
 
 
4767
# Source file extension for f77 test sources.
 
4768
ac_ext=f
 
4769
 
 
4770
# Object file extension for compiled f77 test sources.
 
4771
objext=o
 
4772
_LT_AC_TAGVAR(objext, $1)=$objext
 
4773
 
 
4774
# Code to be used in simple compile tests
 
4775
lt_simple_compile_test_code="\
 
4776
      subroutine t
 
4777
      return
 
4778
      end
 
4779
"
 
4780
 
 
4781
# Code to be used in simple link tests
 
4782
lt_simple_link_test_code="\
 
4783
      program t
 
4784
      end
 
4785
"
 
4786
 
 
4787
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
 
4788
_LT_AC_SYS_COMPILER
 
4789
 
 
4790
# save warnings/boilerplate of simple test code
 
4791
_LT_COMPILER_BOILERPLATE
 
4792
_LT_LINKER_BOILERPLATE
 
4793
 
 
4794
# Allow CC to be a program name with arguments.
 
4795
lt_save_CC="$CC"
 
4796
CC=${F77-"f77"}
 
4797
compiler=$CC
 
4798
_LT_AC_TAGVAR(compiler, $1)=$CC
 
4799
_LT_CC_BASENAME([$compiler])
 
4800
 
 
4801
AC_MSG_CHECKING([if libtool supports shared libraries])
 
4802
AC_MSG_RESULT([$can_build_shared])
 
4803
 
 
4804
AC_MSG_CHECKING([whether to build shared libraries])
 
4805
test "$can_build_shared" = "no" && enable_shared=no
 
4806
 
 
4807
# On AIX, shared libraries and static libraries use the same namespace, and
 
4808
# are all built from PIC.
 
4809
case $host_os in
 
4810
aix3*)
 
4811
  test "$enable_shared" = yes && enable_static=no
 
4812
  if test -n "$RANLIB"; then
 
4813
    archive_cmds="$archive_cmds~\$RANLIB \$lib"
 
4814
    postinstall_cmds='$RANLIB $lib'
 
4815
  fi
 
4816
  ;;
 
4817
aix[[4-9]]*)
 
4818
  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
 
4819
    test "$enable_shared" = yes && enable_static=no
 
4820
  fi
 
4821
  ;;
 
4822
esac
 
4823
AC_MSG_RESULT([$enable_shared])
 
4824
 
 
4825
AC_MSG_CHECKING([whether to build static libraries])
 
4826
# Make sure either enable_shared or enable_static is yes.
 
4827
test "$enable_shared" = yes || enable_static=yes
 
4828
AC_MSG_RESULT([$enable_static])
 
4829
 
 
4830
_LT_AC_TAGVAR(GCC, $1)="$G77"
 
4831
_LT_AC_TAGVAR(LD, $1)="$LD"
 
4832
 
 
4833
AC_LIBTOOL_PROG_COMPILER_PIC($1)
 
4834
AC_LIBTOOL_PROG_CC_C_O($1)
 
4835
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
 
4836
AC_LIBTOOL_PROG_LD_SHLIBS($1)
 
4837
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 
4838
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
 
4839
 
 
4840
AC_LIBTOOL_CONFIG($1)
 
4841
 
 
4842
AC_LANG_POP
 
4843
CC="$lt_save_CC"
 
4844
])# AC_LIBTOOL_LANG_F77_CONFIG
 
4845
 
 
4846
 
 
4847
# AC_LIBTOOL_LANG_GCJ_CONFIG
 
4848
# --------------------------
 
4849
# Ensure that the configuration vars for the C compiler are
 
4850
# suitably defined.  Those variables are subsequently used by
 
4851
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
 
4852
AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
 
4853
AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
 
4854
[AC_LANG_SAVE
 
4855
 
 
4856
# Source file extension for Java test sources.
 
4857
ac_ext=java
 
4858
 
 
4859
# Object file extension for compiled Java test sources.
 
4860
objext=o
 
4861
_LT_AC_TAGVAR(objext, $1)=$objext
 
4862
 
 
4863
# Code to be used in simple compile tests
 
4864
lt_simple_compile_test_code="class foo {}"
 
4865
 
 
4866
# Code to be used in simple link tests
 
4867
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
 
4868
 
 
4869
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
 
4870
_LT_AC_SYS_COMPILER
 
4871
 
 
4872
# save warnings/boilerplate of simple test code
 
4873
_LT_COMPILER_BOILERPLATE
 
4874
_LT_LINKER_BOILERPLATE
 
4875
 
 
4876
# Allow CC to be a program name with arguments.
 
4877
lt_save_CC="$CC"
 
4878
CC=${GCJ-"gcj"}
 
4879
compiler=$CC
 
4880
_LT_AC_TAGVAR(compiler, $1)=$CC
 
4881
_LT_CC_BASENAME([$compiler])
 
4882
 
 
4883
# GCJ did not exist at the time GCC didn't implicitly link libc in.
 
4884
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
4885
 
 
4886
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
4887
 
 
4888
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
 
4889
AC_LIBTOOL_PROG_COMPILER_PIC($1)
 
4890
AC_LIBTOOL_PROG_CC_C_O($1)
 
4891
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
 
4892
AC_LIBTOOL_PROG_LD_SHLIBS($1)
 
4893
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 
4894
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
 
4895
 
 
4896
AC_LIBTOOL_CONFIG($1)
 
4897
 
 
4898
AC_LANG_RESTORE
 
4899
CC="$lt_save_CC"
 
4900
])# AC_LIBTOOL_LANG_GCJ_CONFIG
 
4901
 
 
4902
 
 
4903
# AC_LIBTOOL_LANG_RC_CONFIG
 
4904
# -------------------------
 
4905
# Ensure that the configuration vars for the Windows resource compiler are
 
4906
# suitably defined.  Those variables are subsequently used by
 
4907
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
 
4908
AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
 
4909
AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
 
4910
[AC_LANG_SAVE
 
4911
 
 
4912
# Source file extension for RC test sources.
 
4913
ac_ext=rc
 
4914
 
 
4915
# Object file extension for compiled RC test sources.
 
4916
objext=o
 
4917
_LT_AC_TAGVAR(objext, $1)=$objext
 
4918
 
 
4919
# Code to be used in simple compile tests
 
4920
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
 
4921
 
 
4922
# Code to be used in simple link tests
 
4923
lt_simple_link_test_code="$lt_simple_compile_test_code"
 
4924
 
 
4925
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
 
4926
_LT_AC_SYS_COMPILER
 
4927
 
 
4928
# save warnings/boilerplate of simple test code
 
4929
_LT_COMPILER_BOILERPLATE
 
4930
_LT_LINKER_BOILERPLATE
 
4931
 
 
4932
# Allow CC to be a program name with arguments.
 
4933
lt_save_CC="$CC"
 
4934
CC=${RC-"windres"}
 
4935
compiler=$CC
 
4936
_LT_AC_TAGVAR(compiler, $1)=$CC
 
4937
_LT_CC_BASENAME([$compiler])
 
4938
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
 
4939
 
 
4940
AC_LIBTOOL_CONFIG($1)
 
4941
 
 
4942
AC_LANG_RESTORE
 
4943
CC="$lt_save_CC"
 
4944
])# AC_LIBTOOL_LANG_RC_CONFIG
 
4945
 
 
4946
 
 
4947
# AC_LIBTOOL_CONFIG([TAGNAME])
 
4948
# ----------------------------
 
4949
# If TAGNAME is not passed, then create an initial libtool script
 
4950
# with a default configuration from the untagged config vars.  Otherwise
 
4951
# add code to config.status for appending the configuration named by
 
4952
# TAGNAME from the matching tagged config vars.
 
4953
AC_DEFUN([AC_LIBTOOL_CONFIG],
 
4954
[# The else clause should only fire when bootstrapping the
 
4955
# libtool distribution, otherwise you forgot to ship ltmain.sh
 
4956
# with your package, and you will get complaints that there are
 
4957
# no rules to generate ltmain.sh.
 
4958
if test -f "$ltmain"; then
 
4959
  # See if we are running on zsh, and set the options which allow our commands through
 
4960
  # without removal of \ escapes.
 
4961
  if test -n "${ZSH_VERSION+set}" ; then
 
4962
    setopt NO_GLOB_SUBST
 
4963
  fi
 
4964
  # Now quote all the things that may contain metacharacters while being
 
4965
  # careful not to overquote the AC_SUBSTed values.  We take copies of the
 
4966
  # variables and quote the copies for generation of the libtool script.
 
4967
  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
 
4968
    SED SHELL STRIP \
 
4969
    libname_spec library_names_spec soname_spec extract_expsyms_cmds \
 
4970
    old_striplib striplib file_magic_cmd finish_cmds finish_eval \
 
4971
    deplibs_check_method reload_flag reload_cmds need_locks \
 
4972
    lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
 
4973
    lt_cv_sys_global_symbol_to_c_name_address \
 
4974
    sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
 
4975
    old_postinstall_cmds old_postuninstall_cmds \
 
4976
    _LT_AC_TAGVAR(compiler, $1) \
 
4977
    _LT_AC_TAGVAR(CC, $1) \
 
4978
    _LT_AC_TAGVAR(LD, $1) \
 
4979
    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
 
4980
    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
 
4981
    _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
 
4982
    _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
 
4983
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
 
4984
    _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
 
4985
    _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
 
4986
    _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
 
4987
    _LT_AC_TAGVAR(old_archive_cmds, $1) \
 
4988
    _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
 
4989
    _LT_AC_TAGVAR(predep_objects, $1) \
 
4990
    _LT_AC_TAGVAR(postdep_objects, $1) \
 
4991
    _LT_AC_TAGVAR(predeps, $1) \
 
4992
    _LT_AC_TAGVAR(postdeps, $1) \
 
4993
    _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
 
4994
    _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \
 
4995
    _LT_AC_TAGVAR(archive_cmds, $1) \
 
4996
    _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
 
4997
    _LT_AC_TAGVAR(postinstall_cmds, $1) \
 
4998
    _LT_AC_TAGVAR(postuninstall_cmds, $1) \
 
4999
    _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
 
5000
    _LT_AC_TAGVAR(allow_undefined_flag, $1) \
 
5001
    _LT_AC_TAGVAR(no_undefined_flag, $1) \
 
5002
    _LT_AC_TAGVAR(export_symbols_cmds, $1) \
 
5003
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
 
5004
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
 
5005
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
 
5006
    _LT_AC_TAGVAR(hardcode_automatic, $1) \
 
5007
    _LT_AC_TAGVAR(module_cmds, $1) \
 
5008
    _LT_AC_TAGVAR(module_expsym_cmds, $1) \
 
5009
    _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
 
5010
    _LT_AC_TAGVAR(fix_srcfile_path, $1) \
 
5011
    _LT_AC_TAGVAR(exclude_expsyms, $1) \
 
5012
    _LT_AC_TAGVAR(include_expsyms, $1); do
 
5013
 
 
5014
    case $var in
 
5015
    _LT_AC_TAGVAR(old_archive_cmds, $1) | \
 
5016
    _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
 
5017
    _LT_AC_TAGVAR(archive_cmds, $1) | \
 
5018
    _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
 
5019
    _LT_AC_TAGVAR(module_cmds, $1) | \
 
5020
    _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
 
5021
    _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
 
5022
    _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
 
5023
    extract_expsyms_cmds | reload_cmds | finish_cmds | \
 
5024
    postinstall_cmds | postuninstall_cmds | \
 
5025
    old_postinstall_cmds | old_postuninstall_cmds | \
 
5026
    sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
 
5027
      # Double-quote double-evaled strings.
 
5028
      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
 
5029
      ;;
 
5030
    *)
 
5031
      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
 
5032
      ;;
 
5033
    esac
 
5034
  done
 
5035
 
 
5036
  case $lt_echo in
 
5037
  *'\[$]0 --fallback-echo"')
 
5038
    lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
 
5039
    ;;
 
5040
  esac
 
5041
 
 
5042
ifelse([$1], [],
 
5043
  [cfgfile="${ofile}T"
 
5044
  trap "$rm \"$cfgfile\"; exit 1" 1 2 15
 
5045
  $rm -f "$cfgfile"
 
5046
  AC_MSG_NOTICE([creating $ofile])],
 
5047
  [cfgfile="$ofile"])
 
5048
 
 
5049
  cat <<__EOF__ >> "$cfgfile"
 
5050
ifelse([$1], [],
 
5051
[#! $SHELL
 
5052
 
 
5053
# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
 
5054
# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
 
5055
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
 
5056
#
 
5057
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 
5058
# Free Software Foundation, Inc.
 
5059
#
 
5060
# This file is part of GNU Libtool:
 
5061
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
 
5062
#
 
5063
# This program is free software; you can redistribute it and/or modify
 
5064
# it under the terms of the GNU General Public License as published by
 
5065
# the Free Software Foundation; either version 2 of the License, or
 
5066
# (at your option) any later version.
 
5067
#
 
5068
# This program is distributed in the hope that it will be useful, but
 
5069
# WITHOUT ANY WARRANTY; without even the implied warranty of
 
5070
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
5071
# General Public License for more details.
 
5072
#
 
5073
# You should have received a copy of the GNU General Public License
 
5074
# along with this program; if not, write to the Free Software
 
5075
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 
5076
#
 
5077
# As a special exception to the GNU General Public License, if you
 
5078
# distribute this file as part of a program that contains a
 
5079
# configuration script generated by Autoconf, you may include it under
 
5080
# the same distribution terms that you use for the rest of that program.
 
5081
 
 
5082
# A sed program that does not truncate output.
 
5083
SED=$lt_SED
 
5084
 
 
5085
# Sed that helps us avoid accidentally triggering echo(1) options like -n.
 
5086
Xsed="$SED -e 1s/^X//"
 
5087
 
 
5088
# The HP-UX ksh and POSIX shell print the target directory to stdout
 
5089
# if CDPATH is set.
 
5090
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
 
5091
 
 
5092
# The names of the tagged configurations supported by this script.
 
5093
available_tags=
 
5094
 
 
5095
# ### BEGIN LIBTOOL CONFIG],
 
5096
[# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
 
5097
 
 
5098
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
 
5099
 
 
5100
# Shell to use when invoking shell scripts.
 
5101
SHELL=$lt_SHELL
 
5102
 
 
5103
# Whether or not to build shared libraries.
 
5104
build_libtool_libs=$enable_shared
 
5105
 
 
5106
# Whether or not to build static libraries.
 
5107
build_old_libs=$enable_static
 
5108
 
 
5109
# Whether or not to add -lc for building shared libraries.
 
5110
build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
 
5111
 
 
5112
# Whether or not to disallow shared libs when runtime libs are static
 
5113
allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
 
5114
 
 
5115
# Whether or not to optimize for fast installation.
 
5116
fast_install=$enable_fast_install
 
5117
 
 
5118
# The host system.
 
5119
host_alias=$host_alias
 
5120
host=$host
 
5121
host_os=$host_os
 
5122
 
 
5123
# The build system.
 
5124
build_alias=$build_alias
 
5125
build=$build
 
5126
build_os=$build_os
 
5127
 
 
5128
# An echo program that does not interpret backslashes.
 
5129
echo=$lt_echo
 
5130
 
 
5131
# The archiver.
 
5132
AR=$lt_AR
 
5133
AR_FLAGS=$lt_AR_FLAGS
 
5134
 
 
5135
# A C compiler.
 
5136
LTCC=$lt_LTCC
 
5137
 
 
5138
# LTCC compiler flags.
 
5139
LTCFLAGS=$lt_LTCFLAGS
 
5140
 
 
5141
# A language-specific compiler.
 
5142
CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
 
5143
 
 
5144
# Is the compiler the GNU C compiler?
 
5145
with_gcc=$_LT_AC_TAGVAR(GCC, $1)
 
5146
 
 
5147
# An ERE matcher.
 
5148
EGREP=$lt_EGREP
 
5149
 
 
5150
# The linker used to build libraries.
 
5151
LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
 
5152
 
 
5153
# Whether we need hard or soft links.
 
5154
LN_S=$lt_LN_S
 
5155
 
 
5156
# A BSD-compatible nm program.
 
5157
NM=$lt_NM
 
5158
 
 
5159
# A symbol stripping program
 
5160
STRIP=$lt_STRIP
 
5161
 
 
5162
# Used to examine libraries when file_magic_cmd begins "file"
 
5163
MAGIC_CMD=$MAGIC_CMD
 
5164
 
 
5165
# Used on cygwin: DLL creation program.
 
5166
DLLTOOL="$DLLTOOL"
 
5167
 
 
5168
# Used on cygwin: object dumper.
 
5169
OBJDUMP="$OBJDUMP"
 
5170
 
 
5171
# Used on cygwin: assembler.
 
5172
AS="$AS"
 
5173
 
 
5174
# The name of the directory that contains temporary libtool files.
 
5175
objdir=$objdir
 
5176
 
 
5177
# How to create reloadable object files.
 
5178
reload_flag=$lt_reload_flag
 
5179
reload_cmds=$lt_reload_cmds
 
5180
 
 
5181
# How to pass a linker flag through the compiler.
 
5182
wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
 
5183
 
 
5184
# Object file suffix (normally "o").
 
5185
objext="$ac_objext"
 
5186
 
 
5187
# Old archive suffix (normally "a").
 
5188
libext="$libext"
 
5189
 
 
5190
# Shared library suffix (normally ".so").
 
5191
shrext_cmds='$shrext_cmds'
 
5192
 
 
5193
# Executable file suffix (normally "").
 
5194
exeext="$exeext"
 
5195
 
 
5196
# Additional compiler flags for building library objects.
 
5197
pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
 
5198
pic_mode=$pic_mode
 
5199
 
 
5200
# What is the maximum length of a command?
 
5201
max_cmd_len=$lt_cv_sys_max_cmd_len
 
5202
 
 
5203
# Does compiler simultaneously support -c and -o options?
 
5204
compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
 
5205
 
 
5206
# Must we lock files when doing compilation?
 
5207
need_locks=$lt_need_locks
 
5208
 
 
5209
# Do we need the lib prefix for modules?
 
5210
need_lib_prefix=$need_lib_prefix
 
5211
 
 
5212
# Do we need a version for libraries?
 
5213
need_version=$need_version
 
5214
 
 
5215
# Whether dlopen is supported.
 
5216
dlopen_support=$enable_dlopen
 
5217
 
 
5218
# Whether dlopen of programs is supported.
 
5219
dlopen_self=$enable_dlopen_self
 
5220
 
 
5221
# Whether dlopen of statically linked programs is supported.
 
5222
dlopen_self_static=$enable_dlopen_self_static
 
5223
 
 
5224
# Compiler flag to prevent dynamic linking.
 
5225
link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
 
5226
 
 
5227
# Compiler flag to turn off builtin functions.
 
5228
no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
 
5229
 
 
5230
# Compiler flag to allow reflexive dlopens.
 
5231
export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
 
5232
 
 
5233
# Compiler flag to generate shared objects directly from archives.
 
5234
whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
 
5235
 
 
5236
# Compiler flag to generate thread-safe objects.
 
5237
thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
 
5238
 
 
5239
# Library versioning type.
 
5240
version_type=$version_type
 
5241
 
 
5242
# Format of library name prefix.
 
5243
libname_spec=$lt_libname_spec
 
5244
 
 
5245
# List of archive names.  First name is the real one, the rest are links.
 
5246
# The last name is the one that the linker finds with -lNAME.
 
5247
library_names_spec=$lt_library_names_spec
 
5248
 
 
5249
# The coded name of the library, if different from the real name.
 
5250
soname_spec=$lt_soname_spec
 
5251
 
 
5252
# Commands used to build and install an old-style archive.
 
5253
RANLIB=$lt_RANLIB
 
5254
old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
 
5255
old_postinstall_cmds=$lt_old_postinstall_cmds
 
5256
old_postuninstall_cmds=$lt_old_postuninstall_cmds
 
5257
 
 
5258
# Create an old-style archive from a shared archive.
 
5259
old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
 
5260
 
 
5261
# Create a temporary old-style archive to link instead of a shared archive.
 
5262
old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
 
5263
 
 
5264
# Commands used to build and install a shared archive.
 
5265
archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
 
5266
archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
 
5267
postinstall_cmds=$lt_postinstall_cmds
 
5268
postuninstall_cmds=$lt_postuninstall_cmds
 
5269
 
 
5270
# Commands used to build a loadable module (assumed same as above if empty)
 
5271
module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
 
5272
module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
 
5273
 
 
5274
# Commands to strip libraries.
 
5275
old_striplib=$lt_old_striplib
 
5276
striplib=$lt_striplib
 
5277
 
 
5278
# Dependencies to place before the objects being linked to create a
 
5279
# shared library.
 
5280
predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
 
5281
 
 
5282
# Dependencies to place after the objects being linked to create a
 
5283
# shared library.
 
5284
postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
 
5285
 
 
5286
# Dependencies to place before the objects being linked to create a
 
5287
# shared library.
 
5288
predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
 
5289
 
 
5290
# Dependencies to place after the objects being linked to create a
 
5291
# shared library.
 
5292
postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
 
5293
 
 
5294
# The directories searched by this compiler when creating a shared
 
5295
# library
 
5296
compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)
 
5297
 
 
5298
# The library search path used internally by the compiler when linking
 
5299
# a shared library.
 
5300
compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
 
5301
 
 
5302
# Method to check whether dependent libraries are shared objects.
 
5303
deplibs_check_method=$lt_deplibs_check_method
 
5304
 
 
5305
# Command to use when deplibs_check_method == file_magic.
 
5306
file_magic_cmd=$lt_file_magic_cmd
 
5307
 
 
5308
# Flag that allows shared libraries with undefined symbols to be built.
 
5309
allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
 
5310
 
 
5311
# Flag that forces no undefined symbols.
 
5312
no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
 
5313
 
 
5314
# Commands used to finish a libtool library installation in a directory.
 
5315
finish_cmds=$lt_finish_cmds
 
5316
 
 
5317
# Same as above, but a single script fragment to be evaled but not shown.
 
5318
finish_eval=$lt_finish_eval
 
5319
 
 
5320
# Take the output of nm and produce a listing of raw symbols and C names.
 
5321
global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
 
5322
 
 
5323
# Transform the output of nm in a proper C declaration
 
5324
global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
 
5325
 
 
5326
# Transform the output of nm in a C name address pair
 
5327
global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
 
5328
 
 
5329
# This is the shared library runtime path variable.
 
5330
runpath_var=$runpath_var
 
5331
 
 
5332
# This is the shared library path variable.
 
5333
shlibpath_var=$shlibpath_var
 
5334
 
 
5335
# Is shlibpath searched before the hard-coded library search path?
 
5336
shlibpath_overrides_runpath=$shlibpath_overrides_runpath
 
5337
 
 
5338
# How to hardcode a shared library path into an executable.
 
5339
hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
 
5340
 
 
5341
# Whether we should hardcode library paths into libraries.
 
5342
hardcode_into_libs=$hardcode_into_libs
 
5343
 
 
5344
# Flag to hardcode \$libdir into a binary during linking.
 
5345
# This must work even if \$libdir does not exist.
 
5346
hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
 
5347
 
 
5348
# If ld is used when linking, flag to hardcode \$libdir into
 
5349
# a binary during linking. This must work even if \$libdir does
 
5350
# not exist.
 
5351
hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
 
5352
 
 
5353
# Whether we need a single -rpath flag with a separated argument.
 
5354
hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
 
5355
 
 
5356
# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
 
5357
# resulting binary.
 
5358
hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
 
5359
 
 
5360
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
 
5361
# resulting binary.
 
5362
hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
 
5363
 
 
5364
# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
 
5365
# the resulting binary.
 
5366
hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
 
5367
 
 
5368
# Set to yes if building a shared library automatically hardcodes DIR into the library
 
5369
# and all subsequent libraries and executables linked against it.
 
5370
hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
 
5371
 
 
5372
# Variables whose values should be saved in libtool wrapper scripts and
 
5373
# restored at relink time.
 
5374
variables_saved_for_relink="$variables_saved_for_relink"
 
5375
 
 
5376
# Whether libtool must link a program against all its dependency libraries.
 
5377
link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
 
5378
 
 
5379
# Compile-time system search path for libraries
 
5380
sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
 
5381
 
 
5382
# Run-time system search path for libraries
 
5383
sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
 
5384
 
 
5385
# Fix the shell variable \$srcfile for the compiler.
 
5386
fix_srcfile_path=$lt_fix_srcfile_path
 
5387
 
 
5388
# Set to yes if exported symbols are required.
 
5389
always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
 
5390
 
 
5391
# The commands to list exported symbols.
 
5392
export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
 
5393
 
 
5394
# The commands to extract the exported symbol list from a shared archive.
 
5395
extract_expsyms_cmds=$lt_extract_expsyms_cmds
 
5396
 
 
5397
# Symbols that should not be listed in the preloaded symbols.
 
5398
exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
 
5399
 
 
5400
# Symbols that must always be exported.
 
5401
include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
 
5402
 
 
5403
ifelse([$1],[],
 
5404
[# ### END LIBTOOL CONFIG],
 
5405
[# ### END LIBTOOL TAG CONFIG: $tagname])
 
5406
 
 
5407
__EOF__
 
5408
 
 
5409
ifelse([$1],[], [
 
5410
  case $host_os in
 
5411
  aix3*)
 
5412
    cat <<\EOF >> "$cfgfile"
 
5413
 
 
5414
# AIX sometimes has problems with the GCC collect2 program.  For some
 
5415
# reason, if we set the COLLECT_NAMES environment variable, the problems
 
5416
# vanish in a puff of smoke.
 
5417
if test "X${COLLECT_NAMES+set}" != Xset; then
 
5418
  COLLECT_NAMES=
 
5419
  export COLLECT_NAMES
 
5420
fi
 
5421
EOF
 
5422
    ;;
 
5423
  esac
 
5424
 
 
5425
  # We use sed instead of cat because bash on DJGPP gets confused if
 
5426
  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
 
5427
  # text mode, it properly converts lines to CR/LF.  This bash problem
 
5428
  # is reportedly fixed, but why not run on old versions too?
 
5429
  sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
 
5430
 
 
5431
  mv -f "$cfgfile" "$ofile" || \
 
5432
    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
 
5433
  chmod +x "$ofile"
 
5434
])
 
5435
else
 
5436
  # If there is no Makefile yet, we rely on a make rule to execute
 
5437
  # `config.status --recheck' to rerun these tests and create the
 
5438
  # libtool script then.
 
5439
  ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
 
5440
  if test -f "$ltmain_in"; then
 
5441
    test -f Makefile && make "$ltmain"
 
5442
  fi
 
5443
fi
 
5444
])# AC_LIBTOOL_CONFIG
 
5445
 
 
5446
 
 
5447
# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
 
5448
# -------------------------------------------
 
5449
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
 
5450
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
 
5451
 
 
5452
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
 
5453
 
 
5454
if test "$GCC" = yes; then
 
5455
  _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
 
5456
 
 
5457
  AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
 
5458
    lt_cv_prog_compiler_rtti_exceptions,
 
5459
    [-fno-rtti -fno-exceptions], [],
 
5460
    [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
 
5461
fi
 
5462
])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
 
5463
 
 
5464
 
 
5465
# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
 
5466
# ---------------------------------
 
5467
AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
 
5468
[AC_REQUIRE([AC_CANONICAL_HOST])
 
5469
AC_REQUIRE([LT_AC_PROG_SED])
 
5470
AC_REQUIRE([AC_PROG_NM])
 
5471
AC_REQUIRE([AC_OBJEXT])
 
5472
# Check for command to grab the raw symbol name followed by C symbol from nm.
 
5473
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
 
5474
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
 
5475
[
 
5476
# These are sane defaults that work on at least a few old systems.
 
5477
# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
 
5478
 
 
5479
# Character class describing NM global symbol codes.
 
5480
symcode='[[BCDEGRST]]'
 
5481
 
 
5482
# Regexp to match symbols that can be accessed directly from C.
 
5483
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
 
5484
 
 
5485
# Transform an extracted symbol line into a proper C declaration
 
5486
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
 
5487
 
 
5488
# Transform an extracted symbol line into symbol name and symbol address
 
5489
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'"
 
5490
 
 
5491
# Define system-specific variables.
 
5492
case $host_os in
 
5493
aix*)
 
5494
  symcode='[[BCDT]]'
 
5495
  ;;
 
5496
cygwin* | mingw* | pw32*)
 
5497
  symcode='[[ABCDGISTW]]'
 
5498
  ;;
 
5499
hpux*) # Its linker distinguishes data from code symbols
 
5500
  if test "$host_cpu" = ia64; then
 
5501
    symcode='[[ABCDEGRST]]'
 
5502
  fi
 
5503
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
 
5504
  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'"
 
5505
  ;;
 
5506
linux* | k*bsd*-gnu)
 
5507
  if test "$host_cpu" = ia64; then
 
5508
    symcode='[[ABCDGIRSTW]]'
 
5509
    lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
 
5510
    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'"
 
5511
  fi
 
5512
  ;;
 
5513
irix* | nonstopux*)
 
5514
  symcode='[[BCDEGRST]]'
 
5515
  ;;
 
5516
osf*)
 
5517
  symcode='[[BCDEGQRST]]'
 
5518
  ;;
 
5519
solaris*)
 
5520
  symcode='[[BDRT]]'
 
5521
  ;;
 
5522
sco3.2v5*)
 
5523
  symcode='[[DT]]'
 
5524
  ;;
 
5525
sysv4.2uw2*)
 
5526
  symcode='[[DT]]'
 
5527
  ;;
 
5528
sysv5* | sco5v6* | unixware* | OpenUNIX*)
 
5529
  symcode='[[ABDT]]'
 
5530
  ;;
 
5531
sysv4)
 
5532
  symcode='[[DFNSTU]]'
 
5533
  ;;
 
5534
esac
 
5535
 
 
5536
# Handle CRLF in mingw tool chain
 
5537
opt_cr=
 
5538
case $build_os in
 
5539
mingw*)
 
5540
  opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
 
5541
  ;;
 
5542
esac
 
5543
 
 
5544
# If we're using GNU nm, then use its standard symbol codes.
 
5545
case `$NM -V 2>&1` in
 
5546
*GNU* | *'with BFD'*)
 
5547
  symcode='[[ABCDGIRSTW]]' ;;
 
5548
esac
 
5549
 
 
5550
# Try without a prefix undercore, then with it.
 
5551
for ac_symprfx in "" "_"; do
 
5552
 
 
5553
  # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
 
5554
  symxfrm="\\1 $ac_symprfx\\2 \\2"
 
5555
 
 
5556
  # Write the raw and C identifiers.
 
5557
  lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[      ]]\($symcode$symcode*\)[[       ]][[    ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
 
5558
 
 
5559
  # Check to see that the pipe works correctly.
 
5560
  pipe_works=no
 
5561
 
 
5562
  rm -f conftest*
 
5563
  cat > conftest.$ac_ext <<EOF
 
5564
#ifdef __cplusplus
 
5565
extern "C" {
 
5566
#endif
 
5567
char nm_test_var;
 
5568
void nm_test_func(){}
 
5569
#ifdef __cplusplus
 
5570
}
 
5571
#endif
 
5572
int main(){nm_test_var='a';nm_test_func();return(0);}
 
5573
EOF
 
5574
 
 
5575
  if AC_TRY_EVAL(ac_compile); then
 
5576
    # Now try to grab the symbols.
 
5577
    nlist=conftest.nm
 
5578
    if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
 
5579
      # Try sorting and uniquifying the output.
 
5580
      if sort "$nlist" | uniq > "$nlist"T; then
 
5581
        mv -f "$nlist"T "$nlist"
 
5582
      else
 
5583
        rm -f "$nlist"T
 
5584
      fi
 
5585
 
 
5586
      # Make sure that we snagged all the symbols we need.
 
5587
      if grep ' nm_test_var$' "$nlist" >/dev/null; then
 
5588
        if grep ' nm_test_func$' "$nlist" >/dev/null; then
 
5589
          cat <<EOF > conftest.$ac_ext
 
5590
#ifdef __cplusplus
 
5591
extern "C" {
 
5592
#endif
 
5593
 
 
5594
EOF
 
5595
          # Now generate the symbol file.
 
5596
          eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
 
5597
 
 
5598
          cat <<EOF >> conftest.$ac_ext
 
5599
#if defined (__STDC__) && __STDC__
 
5600
# define lt_ptr_t void *
 
5601
#else
 
5602
# define lt_ptr_t char *
 
5603
# define const
 
5604
#endif
 
5605
 
 
5606
/* The mapping between symbol names and symbols. */
 
5607
const struct {
 
5608
  const char *name;
 
5609
  lt_ptr_t address;
 
5610
}
 
5611
lt_preloaded_symbols[[]] =
 
5612
{
 
5613
EOF
 
5614
          $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
 
5615
          cat <<\EOF >> conftest.$ac_ext
 
5616
  {0, (lt_ptr_t) 0}
 
5617
};
 
5618
 
 
5619
#ifdef __cplusplus
 
5620
}
 
5621
#endif
 
5622
EOF
 
5623
          # Now try linking the two files.
 
5624
          mv conftest.$ac_objext conftstm.$ac_objext
 
5625
          lt_save_LIBS="$LIBS"
 
5626
          lt_save_CFLAGS="$CFLAGS"
 
5627
          LIBS="conftstm.$ac_objext"
 
5628
          CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
 
5629
          if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
 
5630
            pipe_works=yes
 
5631
          fi
 
5632
          LIBS="$lt_save_LIBS"
 
5633
          CFLAGS="$lt_save_CFLAGS"
 
5634
        else
 
5635
          echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
 
5636
        fi
 
5637
      else
 
5638
        echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
 
5639
      fi
 
5640
    else
 
5641
      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
 
5642
    fi
 
5643
  else
 
5644
    echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
 
5645
    cat conftest.$ac_ext >&5
 
5646
  fi
 
5647
  rm -rf conftest* conftst*
 
5648
 
 
5649
  # Do not use the global_symbol_pipe unless it works.
 
5650
  if test "$pipe_works" = yes; then
 
5651
    break
 
5652
  else
 
5653
    lt_cv_sys_global_symbol_pipe=
 
5654
  fi
 
5655
done
 
5656
])
 
5657
if test -z "$lt_cv_sys_global_symbol_pipe"; then
 
5658
  lt_cv_sys_global_symbol_to_cdecl=
 
5659
fi
 
5660
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
 
5661
  AC_MSG_RESULT(failed)
 
5662
else
 
5663
  AC_MSG_RESULT(ok)
 
5664
fi
 
5665
]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
 
5666
 
 
5667
 
 
5668
# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
 
5669
# ---------------------------------------
 
5670
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
 
5671
[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
 
5672
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
 
5673
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
 
5674
 
 
5675
AC_MSG_CHECKING([for $compiler option to produce PIC])
 
5676
 ifelse([$1],[CXX],[
 
5677
  # C++ specific cases for pic, static, wl, etc.
 
5678
  if test "$GXX" = yes; then
 
5679
    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5680
    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
 
5681
 
 
5682
    case $host_os in
 
5683
    aix*)
 
5684
      # All AIX code is PIC.
 
5685
      if test "$host_cpu" = ia64; then
 
5686
        # AIX 5 now supports IA64 processor
 
5687
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5688
      fi
 
5689
      ;;
 
5690
    amigaos*)
 
5691
      # FIXME: we need at least 68020 code to build shared libraries, but
 
5692
      # adding the `-m68020' flag to GCC prevents building anything better,
 
5693
      # like `-m68040'.
 
5694
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
 
5695
      ;;
 
5696
    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
 
5697
      # PIC is the default for these OSes.
 
5698
      ;;
 
5699
    mingw* | cygwin* | os2* | pw32*)
 
5700
      # This hack is so that the source file can tell whether it is being
 
5701
      # built for inclusion in a dll (and should export symbols for example).
 
5702
      # Although the cygwin gcc ignores -fPIC, still need this for old-style
 
5703
      # (--disable-auto-import) libraries
 
5704
      m4_if([$1], [GCJ], [],
 
5705
        [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
 
5706
      ;;
 
5707
    darwin* | rhapsody*)
 
5708
      # PIC is the default on this platform
 
5709
      # Common symbols not allowed in MH_DYLIB files
 
5710
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
 
5711
      ;;
 
5712
    *djgpp*)
 
5713
      # DJGPP does not support shared libraries at all
 
5714
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
 
5715
      ;;
 
5716
    interix[[3-9]]*)
 
5717
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
 
5718
      # Instead, we relocate shared libraries at runtime.
 
5719
      ;;
 
5720
    sysv4*MP*)
 
5721
      if test -d /usr/nec; then
 
5722
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
 
5723
      fi
 
5724
      ;;
 
5725
    hpux*)
 
5726
      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
 
5727
      # not for PA HP-UX.
 
5728
      case $host_cpu in
 
5729
      hppa*64*|ia64*)
 
5730
        ;;
 
5731
      *)
 
5732
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
 
5733
        ;;
 
5734
      esac
 
5735
      ;;
 
5736
    *)
 
5737
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
 
5738
      ;;
 
5739
    esac
 
5740
  else
 
5741
    case $host_os in
 
5742
      aix[[4-9]]*)
 
5743
        # All AIX code is PIC.
 
5744
        if test "$host_cpu" = ia64; then
 
5745
          # AIX 5 now supports IA64 processor
 
5746
          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5747
        else
 
5748
          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
 
5749
        fi
 
5750
        ;;
 
5751
      chorus*)
 
5752
        case $cc_basename in
 
5753
        cxch68*)
 
5754
          # Green Hills C++ Compiler
 
5755
          # _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"
 
5756
          ;;
 
5757
        esac
 
5758
        ;;
 
5759
       darwin*)
 
5760
         # PIC is the default on this platform
 
5761
         # Common symbols not allowed in MH_DYLIB files
 
5762
         case $cc_basename in
 
5763
           xlc*)
 
5764
           _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
 
5765
           _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5766
           ;;
 
5767
         esac
 
5768
       ;;
 
5769
      dgux*)
 
5770
        case $cc_basename in
 
5771
          ec++*)
 
5772
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5773
            ;;
 
5774
          ghcx*)
 
5775
            # Green Hills C++ Compiler
 
5776
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
 
5777
            ;;
 
5778
          *)
 
5779
            ;;
 
5780
        esac
 
5781
        ;;
 
5782
      freebsd* | dragonfly*)
 
5783
        # FreeBSD uses GNU C++
 
5784
        ;;
 
5785
      hpux9* | hpux10* | hpux11*)
 
5786
        case $cc_basename in
 
5787
          CC*)
 
5788
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5789
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 
5790
            if test "$host_cpu" != ia64; then
 
5791
              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
 
5792
            fi
 
5793
            ;;
 
5794
          aCC*)
 
5795
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5796
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 
5797
            case $host_cpu in
 
5798
            hppa*64*|ia64*)
 
5799
              # +Z the default
 
5800
              ;;
 
5801
            *)
 
5802
              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
 
5803
              ;;
 
5804
            esac
 
5805
            ;;
 
5806
          *)
 
5807
            ;;
 
5808
        esac
 
5809
        ;;
 
5810
      interix*)
 
5811
        # This is c89, which is MS Visual C++ (no shared libs)
 
5812
        # Anyone wants to do a port?
 
5813
        ;;
 
5814
      irix5* | irix6* | nonstopux*)
 
5815
        case $cc_basename in
 
5816
          CC*)
 
5817
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5818
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
5819
            # CC pic flag -KPIC is the default.
 
5820
            ;;
 
5821
          *)
 
5822
            ;;
 
5823
        esac
 
5824
        ;;
 
5825
      linux* | k*bsd*-gnu)
 
5826
        case $cc_basename in
 
5827
          KCC*)
 
5828
            # KAI C++ Compiler
 
5829
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
 
5830
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
 
5831
            ;;
 
5832
          icpc* | ecpc*)
 
5833
            # Intel C++
 
5834
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5835
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5836
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
 
5837
            ;;
 
5838
          pgCC* | pgcpp*)
 
5839
            # Portland Group C++ compiler.
 
5840
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5841
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
 
5842
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5843
            ;;
 
5844
          cxx*)
 
5845
            # Compaq C++
 
5846
            # Make sure the PIC flag is empty.  It appears that all Alpha
 
5847
            # Linux and Compaq Tru64 Unix objects are PIC.
 
5848
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
 
5849
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
5850
            ;;
 
5851
          *)
 
5852
            case `$CC -V 2>&1 | sed 5q` in
 
5853
            *Sun\ C*)
 
5854
              # Sun C++ 5.9
 
5855
              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5856
              _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5857
              _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
 
5858
              ;;
 
5859
            esac
 
5860
            ;;
 
5861
        esac
 
5862
        ;;
 
5863
      lynxos*)
 
5864
        ;;
 
5865
      m88k*)
 
5866
        ;;
 
5867
      mvs*)
 
5868
        case $cc_basename in
 
5869
          cxx*)
 
5870
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
 
5871
            ;;
 
5872
          *)
 
5873
            ;;
 
5874
        esac
 
5875
        ;;
 
5876
      netbsd*)
 
5877
        ;;
 
5878
      osf3* | osf4* | osf5*)
 
5879
        case $cc_basename in
 
5880
          KCC*)
 
5881
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
 
5882
            ;;
 
5883
          RCC*)
 
5884
            # Rational C++ 2.4.1
 
5885
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
 
5886
            ;;
 
5887
          cxx*)
 
5888
            # Digital/Compaq C++
 
5889
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5890
            # Make sure the PIC flag is empty.  It appears that all Alpha
 
5891
            # Linux and Compaq Tru64 Unix objects are PIC.
 
5892
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
 
5893
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
5894
            ;;
 
5895
          *)
 
5896
            ;;
 
5897
        esac
 
5898
        ;;
 
5899
      psos*)
 
5900
        ;;
 
5901
      solaris*)
 
5902
        case $cc_basename in
 
5903
          CC*)
 
5904
            # Sun C++ 4.2, 5.x and Centerline C++
 
5905
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5906
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5907
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
 
5908
            ;;
 
5909
          gcx*)
 
5910
            # Green Hills C++ Compiler
 
5911
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
 
5912
            ;;
 
5913
          *)
 
5914
            ;;
 
5915
        esac
 
5916
        ;;
 
5917
      sunos4*)
 
5918
        case $cc_basename in
 
5919
          CC*)
 
5920
            # Sun C++ 4.x
 
5921
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
 
5922
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5923
            ;;
 
5924
          lcc*)
 
5925
            # Lucid
 
5926
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
 
5927
            ;;
 
5928
          *)
 
5929
            ;;
 
5930
        esac
 
5931
        ;;
 
5932
      tandem*)
 
5933
        case $cc_basename in
 
5934
          NCC*)
 
5935
            # NonStop-UX NCC 3.20
 
5936
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5937
            ;;
 
5938
          *)
 
5939
            ;;
 
5940
        esac
 
5941
        ;;
 
5942
      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
 
5943
        case $cc_basename in
 
5944
          CC*)
 
5945
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5946
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5947
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5948
            ;;
 
5949
        esac
 
5950
        ;;
 
5951
      vxworks*)
 
5952
        ;;
 
5953
      *)
 
5954
        _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
 
5955
        ;;
 
5956
    esac
 
5957
  fi
 
5958
],
 
5959
[
 
5960
  if test "$GCC" = yes; then
 
5961
    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5962
    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
 
5963
 
 
5964
    case $host_os in
 
5965
      aix*)
 
5966
      # All AIX code is PIC.
 
5967
      if test "$host_cpu" = ia64; then
 
5968
        # AIX 5 now supports IA64 processor
 
5969
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5970
      fi
 
5971
      ;;
 
5972
 
 
5973
    amigaos*)
 
5974
      # FIXME: we need at least 68020 code to build shared libraries, but
 
5975
      # adding the `-m68020' flag to GCC prevents building anything better,
 
5976
      # like `-m68040'.
 
5977
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
 
5978
      ;;
 
5979
 
 
5980
    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
 
5981
      # PIC is the default for these OSes.
 
5982
      ;;
 
5983
 
 
5984
    mingw* | cygwin* | pw32* | os2*)
 
5985
      # This hack is so that the source file can tell whether it is being
 
5986
      # built for inclusion in a dll (and should export symbols for example).
 
5987
      # Although the cygwin gcc ignores -fPIC, still need this for old-style
 
5988
      # (--disable-auto-import) libraries
 
5989
      m4_if([$1], [GCJ], [],
 
5990
        [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
 
5991
      ;;
 
5992
 
 
5993
    darwin* | rhapsody*)
 
5994
      # PIC is the default on this platform
 
5995
      # Common symbols not allowed in MH_DYLIB files
 
5996
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
 
5997
      ;;
 
5998
 
 
5999
    interix[[3-9]]*)
 
6000
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
 
6001
      # Instead, we relocate shared libraries at runtime.
 
6002
      ;;
 
6003
 
 
6004
    msdosdjgpp*)
 
6005
      # Just because we use GCC doesn't mean we suddenly get shared libraries
 
6006
      # on systems that don't support them.
 
6007
      _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
 
6008
      enable_shared=no
 
6009
      ;;
 
6010
 
 
6011
    sysv4*MP*)
 
6012
      if test -d /usr/nec; then
 
6013
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
 
6014
      fi
 
6015
      ;;
 
6016
 
 
6017
    hpux*)
 
6018
      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
 
6019
      # not for PA HP-UX.
 
6020
      case $host_cpu in
 
6021
      hppa*64*|ia64*)
 
6022
        # +Z the default
 
6023
        ;;
 
6024
      *)
 
6025
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
 
6026
        ;;
 
6027
      esac
 
6028
      ;;
 
6029
 
 
6030
    *)
 
6031
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
 
6032
      ;;
 
6033
    esac
 
6034
  else
 
6035
    # PORTME Check for flag to pass linker flags through the system compiler.
 
6036
    case $host_os in
 
6037
    aix*)
 
6038
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6039
      if test "$host_cpu" = ia64; then
 
6040
        # AIX 5 now supports IA64 processor
 
6041
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6042
      else
 
6043
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
 
6044
      fi
 
6045
      ;;
 
6046
      darwin*)
 
6047
        # PIC is the default on this platform
 
6048
        # Common symbols not allowed in MH_DYLIB files
 
6049
       case $cc_basename in
 
6050
         xlc*)
 
6051
         _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
 
6052
         _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6053
         ;;
 
6054
       esac
 
6055
       ;;
 
6056
 
 
6057
    mingw* | cygwin* | pw32* | os2*)
 
6058
      # This hack is so that the source file can tell whether it is being
 
6059
      # built for inclusion in a dll (and should export symbols for example).
 
6060
      m4_if([$1], [GCJ], [],
 
6061
        [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
 
6062
      ;;
 
6063
 
 
6064
    hpux9* | hpux10* | hpux11*)
 
6065
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6066
      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
 
6067
      # not for PA HP-UX.
 
6068
      case $host_cpu in
 
6069
      hppa*64*|ia64*)
 
6070
        # +Z the default
 
6071
        ;;
 
6072
      *)
 
6073
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
 
6074
        ;;
 
6075
      esac
 
6076
      # Is there a better lt_prog_compiler_static that works with the bundled CC?
 
6077
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 
6078
      ;;
 
6079
 
 
6080
    irix5* | irix6* | nonstopux*)
 
6081
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6082
      # PIC (with -KPIC) is the default.
 
6083
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
6084
      ;;
 
6085
 
 
6086
    newsos6)
 
6087
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6088
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6089
      ;;
 
6090
 
 
6091
    linux* | k*bsd*-gnu)
 
6092
      case $cc_basename in
 
6093
      icc* | ecc*)
 
6094
        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6095
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6096
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
 
6097
        ;;
 
6098
      pgcc* | pgf77* | pgf90* | pgf95*)
 
6099
        # Portland Group compilers (*not* the Pentium gcc compiler,
 
6100
        # which looks to be a dead project)
 
6101
        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6102
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
 
6103
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6104
        ;;
 
6105
      ccc*)
 
6106
        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6107
        # All Alpha code is PIC.
 
6108
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
6109
        ;;
 
6110
      *)
 
6111
        case `$CC -V 2>&1 | sed 5q` in
 
6112
        *Sun\ C*)
 
6113
          # Sun C 5.9
 
6114
          _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6115
          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6116
          _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6117
          ;;
 
6118
        *Sun\ F*)
 
6119
          # Sun Fortran 8.3 passes all unrecognized flags to the linker
 
6120
          _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6121
          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6122
          _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
 
6123
          ;;
 
6124
        esac
 
6125
        ;;
 
6126
      esac
 
6127
      ;;
 
6128
 
 
6129
    osf3* | osf4* | osf5*)
 
6130
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6131
      # All OSF/1 code is PIC.
 
6132
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
6133
      ;;
 
6134
 
 
6135
    rdos*)
 
6136
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 
6137
      ;;
 
6138
 
 
6139
    solaris*)
 
6140
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6141
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6142
      case $cc_basename in
 
6143
      f77* | f90* | f95*)
 
6144
        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
 
6145
      *)
 
6146
        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
 
6147
      esac
 
6148
      ;;
 
6149
 
 
6150
    sunos4*)
 
6151
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
 
6152
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
 
6153
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6154
      ;;
 
6155
 
 
6156
    sysv4 | sysv4.2uw2* | sysv4.3*)
 
6157
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6158
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6159
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6160
      ;;
 
6161
 
 
6162
    sysv4*MP*)
 
6163
      if test -d /usr/nec ;then
 
6164
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
 
6165
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6166
      fi
 
6167
      ;;
 
6168
 
 
6169
    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
 
6170
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6171
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
6172
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6173
      ;;
 
6174
 
 
6175
    unicos*)
 
6176
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
6177
      _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
 
6178
      ;;
 
6179
 
 
6180
    uts4*)
 
6181
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
 
6182
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
6183
      ;;
 
6184
 
 
6185
    *)
 
6186
      _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
 
6187
      ;;
 
6188
    esac
 
6189
  fi
 
6190
])
 
6191
AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
 
6192
 
 
6193
#
 
6194
# Check to make sure the PIC flag actually works.
 
6195
#
 
6196
if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
 
6197
  AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
 
6198
    _LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1),
 
6199
    [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
 
6200
    [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
 
6201
     "" | " "*) ;;
 
6202
     *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
 
6203
     esac],
 
6204
    [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
 
6205
     _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
 
6206
fi
 
6207
case $host_os in
 
6208
  # For platforms which do not support PIC, -DPIC is meaningless:
 
6209
  *djgpp*)
 
6210
    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
 
6211
    ;;
 
6212
  *)
 
6213
    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
 
6214
    ;;
 
6215
esac
 
6216
 
 
6217
#
 
6218
# Check to make sure the static flag actually works.
 
6219
#
 
6220
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
 
6221
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
 
6222
  _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1),
 
6223
  $lt_tmp_static_flag,
 
6224
  [],
 
6225
  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
 
6226
])
 
6227
 
 
6228
 
 
6229
# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
 
6230
# ------------------------------------
 
6231
# See if the linker supports building shared libraries.
 
6232
AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
 
6233
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
6234
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
 
6235
ifelse([$1],[CXX],[
 
6236
  _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
 
6237
  case $host_os in
 
6238
  aix[[4-9]]*)
 
6239
    # If we're using GNU nm, then we don't want the "-C" option.
 
6240
    # -C means demangle to AIX nm, but means don't demangle with GNU nm
 
6241
    if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
 
6242
      _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'
 
6243
    else
 
6244
      _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'
 
6245
    fi
 
6246
    ;;
 
6247
  pw32*)
 
6248
    _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
 
6249
  ;;
 
6250
  cygwin* | mingw*)
 
6251
    _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'
 
6252
  ;;
 
6253
  *)
 
6254
    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
 
6255
  ;;
 
6256
  esac
 
6257
  _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
 
6258
],[
 
6259
  runpath_var=
 
6260
  _LT_AC_TAGVAR(allow_undefined_flag, $1)=
 
6261
  _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
 
6262
  _LT_AC_TAGVAR(archive_cmds, $1)=
 
6263
  _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
 
6264
  _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
 
6265
  _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
 
6266
  _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
 
6267
  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
 
6268
  _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
 
6269
  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
 
6270
  _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
 
6271
  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 
6272
  _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
6273
  _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
 
6274
  _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
 
6275
  _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
 
6276
  _LT_AC_TAGVAR(hardcode_automatic, $1)=no
 
6277
  _LT_AC_TAGVAR(module_cmds, $1)=
 
6278
  _LT_AC_TAGVAR(module_expsym_cmds, $1)=
 
6279
  _LT_AC_TAGVAR(always_export_symbols, $1)=no
 
6280
  _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
 
6281
  # include_expsyms should be a list of space-separated symbols to be *always*
 
6282
  # included in the symbol list
 
6283
  _LT_AC_TAGVAR(include_expsyms, $1)=
 
6284
  # exclude_expsyms can be an extended regexp of symbols to exclude
 
6285
  # it will be wrapped by ` (' and `)$', so one must not match beginning or
 
6286
  # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
 
6287
  # as well as any symbol that contains `d'.
 
6288
  _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
 
6289
  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
 
6290
  # platforms (ab)use it in PIC code, but their linkers get confused if
 
6291
  # the symbol is explicitly referenced.  Since portable code cannot
 
6292
  # rely on this symbol name, it's probably fine to never include it in
 
6293
  # preloaded symbol tables.
 
6294
  # Exclude shared library initialization/finalization symbols.
 
6295
dnl Note also adjust exclude_expsyms for C++ above.
 
6296
  extract_expsyms_cmds=
 
6297
  # Just being paranoid about ensuring that cc_basename is set.
 
6298
  _LT_CC_BASENAME([$compiler])
 
6299
  case $host_os in
 
6300
  cygwin* | mingw* | pw32*)
 
6301
    # FIXME: the MSVC++ port hasn't been tested in a loooong time
 
6302
    # When not using gcc, we currently assume that we are using
 
6303
    # Microsoft Visual C++.
 
6304
    if test "$GCC" != yes; then
 
6305
      with_gnu_ld=no
 
6306
    fi
 
6307
    ;;
 
6308
  interix*)
 
6309
    # we just hope/assume this is gcc and not c89 (= MSVC++)
 
6310
    with_gnu_ld=yes
 
6311
    ;;
 
6312
  openbsd*)
 
6313
    with_gnu_ld=no
 
6314
    ;;
 
6315
  esac
 
6316
 
 
6317
  _LT_AC_TAGVAR(ld_shlibs, $1)=yes
 
6318
  if test "$with_gnu_ld" = yes; then
 
6319
    # If archive_cmds runs LD, not CC, wlarc should be empty
 
6320
    wlarc='${wl}'
 
6321
 
 
6322
    # Set some defaults for GNU ld with shared library support. These
 
6323
    # are reset later if shared libraries are not supported. Putting them
 
6324
    # here allows them to be overridden if necessary.
 
6325
    runpath_var=LD_RUN_PATH
 
6326
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
 
6327
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 
6328
    # ancient GNU ld didn't support --whole-archive et. al.
 
6329
    if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
 
6330
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
 
6331
      else
 
6332
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
 
6333
    fi
 
6334
    supports_anon_versioning=no
 
6335
    case `$LD -v 2>/dev/null` in
 
6336
      *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
 
6337
      *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
 
6338
      *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
 
6339
      *\ 2.11.*) ;; # other 2.11 versions
 
6340
      *) supports_anon_versioning=yes ;;
 
6341
    esac
 
6342
 
 
6343
    # See if GNU ld supports shared libraries.
 
6344
    case $host_os in
 
6345
    aix[[3-9]]*)
 
6346
      # On AIX/PPC, the GNU linker is very broken
 
6347
      if test "$host_cpu" != ia64; then
 
6348
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6349
        cat <<EOF 1>&2
 
6350
 
 
6351
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
 
6352
*** to be unable to reliably create shared libraries on AIX.
 
6353
*** Therefore, libtool is disabling shared libraries support.  If you
 
6354
*** really care for shared libraries, you may want to modify your PATH
 
6355
*** so that a non-GNU linker is found, and then restart.
 
6356
 
 
6357
EOF
 
6358
      fi
 
6359
      ;;
 
6360
 
 
6361
    amigaos*)
 
6362
      _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)'
 
6363
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6364
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6365
 
 
6366
      # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
 
6367
      # that the semantics of dynamic libraries on AmigaOS, at least up
 
6368
      # to version 4, is to share data among multiple programs linked
 
6369
      # with the same dynamic library.  Since this doesn't match the
 
6370
      # behavior of shared libraries on other platforms, we can't use
 
6371
      # them.
 
6372
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6373
      ;;
 
6374
 
 
6375
    beos*)
 
6376
      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
6377
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6378
        # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
 
6379
        # support --undefined.  This deserves some investigation.  FIXME
 
6380
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
6381
      else
 
6382
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6383
      fi
 
6384
      ;;
 
6385
 
 
6386
    cygwin* | mingw* | pw32*)
 
6387
      # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
 
6388
      # as there is no search path for DLLs.
 
6389
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6390
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6391
      _LT_AC_TAGVAR(always_export_symbols, $1)=no
 
6392
      _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
6393
      _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'
 
6394
 
 
6395
      if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
 
6396
        _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'
 
6397
        # If the export-symbols file already is a .def file (1st line
 
6398
        # is EXPORTS), use it as is; otherwise, prepend...
 
6399
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
 
6400
          cp $export_symbols $output_objdir/$soname.def;
 
6401
        else
 
6402
          echo EXPORTS > $output_objdir/$soname.def;
 
6403
          cat $export_symbols >> $output_objdir/$soname.def;
 
6404
        fi~
 
6405
        $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
 
6406
      else
 
6407
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6408
      fi
 
6409
      ;;
 
6410
 
 
6411
    interix[[3-9]]*)
 
6412
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
6413
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6414
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
6415
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6416
      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
 
6417
      # Instead, shared libraries are loaded at an image base (0x10000000 by
 
6418
      # default) and relocated if they conflict, which is a slow very memory
 
6419
      # consuming and fragmenting process.  To avoid this, we pick a random,
 
6420
      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
 
6421
      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
 
6422
      _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'
 
6423
      _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'
 
6424
      ;;
 
6425
 
 
6426
    gnu* | linux* | k*bsd*-gnu)
 
6427
      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
6428
        tmp_addflag=
 
6429
        case $cc_basename,$host_cpu in
 
6430
        pgcc*)                          # Portland Group C compiler
 
6431
          _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'
 
6432
          tmp_addflag=' $pic_flag'
 
6433
          ;;
 
6434
        pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
 
6435
          _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'
 
6436
          tmp_addflag=' $pic_flag -Mnomain' ;;
 
6437
        ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
 
6438
          tmp_addflag=' -i_dynamic' ;;
 
6439
        efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
 
6440
          tmp_addflag=' -i_dynamic -nofor_main' ;;
 
6441
        ifc* | ifort*)                  # Intel Fortran compiler
 
6442
          tmp_addflag=' -nofor_main' ;;
 
6443
        esac
 
6444
        case `$CC -V 2>&1 | sed 5q` in
 
6445
        *Sun\ C*)                       # Sun C 5.9
 
6446
          _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'
 
6447
          tmp_sharedflag='-G' ;;
 
6448
        *Sun\ F*)                       # Sun Fortran 8.3
 
6449
          tmp_sharedflag='-G' ;;
 
6450
        *)
 
6451
          tmp_sharedflag='-shared' ;;
 
6452
        esac
 
6453
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
6454
 
 
6455
        if test $supports_anon_versioning = yes; then
 
6456
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
 
6457
  cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
 
6458
  $echo "local: *; };" >> $output_objdir/$libname.ver~
 
6459
          $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
 
6460
        fi
 
6461
      else
 
6462
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6463
      fi
 
6464
      ;;
 
6465
 
 
6466
    netbsd*)
 
6467
      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
 
6468
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
 
6469
        wlarc=
 
6470
      else
 
6471
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
6472
        _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'
 
6473
      fi
 
6474
      ;;
 
6475
 
 
6476
    solaris*)
 
6477
      if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
 
6478
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6479
        cat <<EOF 1>&2
 
6480
 
 
6481
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
 
6482
*** create shared libraries on Solaris systems.  Therefore, libtool
 
6483
*** is disabling shared libraries support.  We urge you to upgrade GNU
 
6484
*** binutils to release 2.9.1 or newer.  Another option is to modify
 
6485
*** your PATH or compiler configuration so that the native linker is
 
6486
*** used, and then restart.
 
6487
 
 
6488
EOF
 
6489
      elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
6490
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
6491
        _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'
 
6492
      else
 
6493
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6494
      fi
 
6495
      ;;
 
6496
 
 
6497
    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
 
6498
      case `$LD -v 2>&1` in
 
6499
        *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
 
6500
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6501
        cat <<_LT_EOF 1>&2
 
6502
 
 
6503
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
 
6504
*** reliably create shared libraries on SCO systems.  Therefore, libtool
 
6505
*** is disabling shared libraries support.  We urge you to upgrade GNU
 
6506
*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
 
6507
*** your PATH or compiler configuration so that the native linker is
 
6508
*** used, and then restart.
 
6509
 
 
6510
_LT_EOF
 
6511
        ;;
 
6512
        *)
 
6513
          if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
6514
            _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
 
6515
            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
 
6516
            _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'
 
6517
          else
 
6518
            _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6519
          fi
 
6520
        ;;
 
6521
      esac
 
6522
      ;;
 
6523
 
 
6524
    sunos4*)
 
6525
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
 
6526
      wlarc=
 
6527
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6528
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6529
      ;;
 
6530
 
 
6531
    *)
 
6532
      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
6533
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
6534
        _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'
 
6535
      else
 
6536
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6537
      fi
 
6538
      ;;
 
6539
    esac
 
6540
 
 
6541
    if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
 
6542
      runpath_var=
 
6543
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
 
6544
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
 
6545
      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
 
6546
    fi
 
6547
  else
 
6548
    # PORTME fill in a description of your system's linker (not GNU ld)
 
6549
    case $host_os in
 
6550
    aix3*)
 
6551
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6552
      _LT_AC_TAGVAR(always_export_symbols, $1)=yes
 
6553
      _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'
 
6554
      # Note: this linker hardcodes the directories in LIBPATH if there
 
6555
      # are no directories specified by -L.
 
6556
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6557
      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
 
6558
        # Neither direct hardcoding nor static linking is supported with a
 
6559
        # broken collect2.
 
6560
        _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
 
6561
      fi
 
6562
      ;;
 
6563
 
 
6564
    aix[[4-9]]*)
 
6565
      if test "$host_cpu" = ia64; then
 
6566
        # On IA64, the linker does run time linking by default, so we don't
 
6567
        # have to do anything special.
 
6568
        aix_use_runtimelinking=no
 
6569
        exp_sym_flag='-Bexport'
 
6570
        no_entry_flag=""
 
6571
      else
 
6572
        # If we're using GNU nm, then we don't want the "-C" option.
 
6573
        # -C means demangle to AIX nm, but means don't demangle with GNU nm
 
6574
        if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
 
6575
          _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'
 
6576
        else
 
6577
          _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'
 
6578
        fi
 
6579
        aix_use_runtimelinking=no
 
6580
 
 
6581
        # Test if we are trying to use run time linking or normal
 
6582
        # AIX style linking. If -brtl is somewhere in LDFLAGS, we
 
6583
        # need to do runtime linking.
 
6584
        case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
 
6585
          for ld_flag in $LDFLAGS; do
 
6586
          if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
 
6587
            aix_use_runtimelinking=yes
 
6588
            break
 
6589
          fi
 
6590
          done
 
6591
          ;;
 
6592
        esac
 
6593
 
 
6594
        exp_sym_flag='-bexport'
 
6595
        no_entry_flag='-bnoentry'
 
6596
      fi
 
6597
 
 
6598
      # When large executables or shared objects are built, AIX ld can
 
6599
      # have problems creating the table of contents.  If linking a library
 
6600
      # or program results in "error TOC overflow" add -mminimal-toc to
 
6601
      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
 
6602
      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
 
6603
 
 
6604
      _LT_AC_TAGVAR(archive_cmds, $1)=''
 
6605
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6606
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
 
6607
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
6608
 
 
6609
      if test "$GCC" = yes; then
 
6610
        case $host_os in aix4.[[012]]|aix4.[[012]].*)
 
6611
        # We only want to do this on AIX 4.2 and lower, the check
 
6612
        # below for broken collect2 doesn't work under 4.3+
 
6613
          collect2name=`${CC} -print-prog-name=collect2`
 
6614
          if test -f "$collect2name" && \
 
6615
           strings "$collect2name" | grep resolve_lib_name >/dev/null
 
6616
          then
 
6617
          # We have reworked collect2
 
6618
          :
 
6619
          else
 
6620
          # We have old collect2
 
6621
          _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
 
6622
          # It fails to find uninstalled libraries when the uninstalled
 
6623
          # path is not listed in the libpath.  Setting hardcode_minus_L
 
6624
          # to unsupported forces relinking
 
6625
          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6626
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6627
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 
6628
          fi
 
6629
          ;;
 
6630
        esac
 
6631
        shared_flag='-shared'
 
6632
        if test "$aix_use_runtimelinking" = yes; then
 
6633
          shared_flag="$shared_flag "'${wl}-G'
 
6634
        fi
 
6635
      else
 
6636
        # not using gcc
 
6637
        if test "$host_cpu" = ia64; then
 
6638
        # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
 
6639
        # chokes on -Wl,-G. The following line is correct:
 
6640
          shared_flag='-G'
 
6641
        else
 
6642
          if test "$aix_use_runtimelinking" = yes; then
 
6643
            shared_flag='${wl}-G'
 
6644
          else
 
6645
            shared_flag='${wl}-bM:SRE'
 
6646
          fi
 
6647
        fi
 
6648
      fi
 
6649
 
 
6650
      # It seems that -bexpall does not export symbols beginning with
 
6651
      # underscore (_), so it is better to generate a list of symbols to export.
 
6652
      _LT_AC_TAGVAR(always_export_symbols, $1)=yes
 
6653
      if test "$aix_use_runtimelinking" = yes; then
 
6654
        # Warning - without using the other runtime loading flags (-brtl),
 
6655
        # -berok will link without error, but may produce a broken library.
 
6656
        _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
 
6657
       # Determine the default libpath from the value encoded in an empty executable.
 
6658
       _LT_AC_SYS_LIBPATH_AIX
 
6659
       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
6660
        _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"
 
6661
       else
 
6662
        if test "$host_cpu" = ia64; then
 
6663
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
 
6664
          _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
 
6665
          _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"
 
6666
        else
 
6667
         # Determine the default libpath from the value encoded in an empty executable.
 
6668
         _LT_AC_SYS_LIBPATH_AIX
 
6669
         _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
6670
          # Warning - without using the other run time loading flags,
 
6671
          # -berok will link without error, but may produce a broken library.
 
6672
          _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 
6673
          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
 
6674
          # Exported symbols can be pulled into shared objects from archives
 
6675
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 
6676
          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 
6677
          # This is similar to how AIX traditionally builds its shared libraries.
 
6678
          _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'
 
6679
        fi
 
6680
      fi
 
6681
      ;;
 
6682
 
 
6683
    amigaos*)
 
6684
      _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)'
 
6685
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6686
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6687
      # see comment about different semantics on the GNU ld section
 
6688
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6689
      ;;
 
6690
 
 
6691
    bsdi[[45]]*)
 
6692
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
 
6693
      ;;
 
6694
 
 
6695
    cygwin* | mingw* | pw32*)
 
6696
      # When not using gcc, we currently assume that we are using
 
6697
      # Microsoft Visual C++.
 
6698
      # hardcode_libdir_flag_spec is actually meaningless, as there is
 
6699
      # no search path for DLLs.
 
6700
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
 
6701
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6702
      # Tell ltmain to make .lib files, not .a files.
 
6703
      libext=lib
 
6704
      # Tell ltmain to make .dll files, not .so files.
 
6705
      shrext_cmds=".dll"
 
6706
      # FIXME: Setting linknames here is a bad hack.
 
6707
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
 
6708
      # The linker will automatically build a .lib file if we build a DLL.
 
6709
      _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
 
6710
      # FIXME: Should let the user specify the lib program.
 
6711
      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
 
6712
      _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
 
6713
      _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
6714
      ;;
 
6715
 
 
6716
    darwin* | rhapsody*)
 
6717
      case $host_os in
 
6718
        rhapsody* | darwin1.[[012]])
 
6719
         _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
 
6720
         ;;
 
6721
       *) # Darwin 1.3 on
 
6722
         if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
 
6723
           _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
 
6724
         else
 
6725
           case ${MACOSX_DEPLOYMENT_TARGET} in
 
6726
             10.[[012]])
 
6727
               _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
 
6728
               ;;
 
6729
             10.*)
 
6730
               _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
 
6731
               ;;
 
6732
           esac
 
6733
         fi
 
6734
         ;;
 
6735
      esac
 
6736
      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
6737
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
6738
      _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
 
6739
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
 
6740
      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
 
6741
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
6742
    if test "$GCC" = yes ; then
 
6743
        output_verbose_link_cmd='echo'
 
6744
        _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}"
 
6745
        _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
 
6746
        _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}"
 
6747
        _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}"
 
6748
    else
 
6749
      case $cc_basename in
 
6750
        xlc*)
 
6751
         output_verbose_link_cmd='echo'
 
6752
         _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'
 
6753
         _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
 
6754
          # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
 
6755
         _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}'
 
6756
          _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}'
 
6757
          ;;
 
6758
       *)
 
6759
         _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6760
          ;;
 
6761
      esac
 
6762
    fi
 
6763
      ;;
 
6764
 
 
6765
    dgux*)
 
6766
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
6767
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6768
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6769
      ;;
 
6770
 
 
6771
    freebsd1*)
 
6772
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6773
      ;;
 
6774
 
 
6775
    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
 
6776
    # support.  Future versions do this automatically, but an explicit c++rt0.o
 
6777
    # does not break anything, and helps significantly (at the cost of a little
 
6778
    # extra space).
 
6779
    freebsd2.2*)
 
6780
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
 
6781
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
6782
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6783
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6784
      ;;
 
6785
 
 
6786
    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
 
6787
    freebsd2*)
 
6788
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
 
6789
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6790
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6791
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6792
      ;;
 
6793
 
 
6794
    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
 
6795
    freebsd* | dragonfly*)
 
6796
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
 
6797
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
6798
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6799
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6800
      ;;
 
6801
 
 
6802
    hpux9*)
 
6803
      if test "$GCC" = yes; then
 
6804
        _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'
 
6805
      else
 
6806
        _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'
 
6807
      fi
 
6808
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
6809
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6810
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6811
 
 
6812
      # hardcode_minus_L: Not really in the search PATH,
 
6813
      # but as the default location of the library.
 
6814
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6815
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6816
      ;;
 
6817
 
 
6818
    hpux10*)
 
6819
      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 
6820
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
6821
      else
 
6822
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
 
6823
      fi
 
6824
      if test "$with_gnu_ld" = no; then
 
6825
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
6826
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6827
 
 
6828
        _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6829
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6830
 
 
6831
        # hardcode_minus_L: Not really in the search PATH,
 
6832
        # but as the default location of the library.
 
6833
        _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6834
      fi
 
6835
      ;;
 
6836
 
 
6837
    hpux11*)
 
6838
      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 
6839
        case $host_cpu in
 
6840
        hppa*64*)
 
6841
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6842
          ;;
 
6843
        ia64*)
 
6844
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 
6845
          ;;
 
6846
        *)
 
6847
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
6848
          ;;
 
6849
        esac
 
6850
      else
 
6851
        case $host_cpu in
 
6852
        hppa*64*)
 
6853
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6854
          ;;
 
6855
        ia64*)
 
6856
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 
6857
          ;;
 
6858
        *)
 
6859
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
6860
          ;;
 
6861
        esac
 
6862
      fi
 
6863
      if test "$with_gnu_ld" = no; then
 
6864
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
6865
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6866
 
 
6867
        case $host_cpu in
 
6868
        hppa*64*|ia64*)
 
6869
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
 
6870
          _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
6871
          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6872
          ;;
 
6873
        *)
 
6874
          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6875
          _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6876
 
 
6877
          # hardcode_minus_L: Not really in the search PATH,
 
6878
          # but as the default location of the library.
 
6879
          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6880
          ;;
 
6881
        esac
 
6882
      fi
 
6883
      ;;
 
6884
 
 
6885
    irix5* | irix6* | nonstopux*)
 
6886
      if test "$GCC" = yes; then
 
6887
        _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'
 
6888
      else
 
6889
        _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'
 
6890
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
 
6891
      fi
 
6892
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
6893
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6894
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
6895
      ;;
 
6896
 
 
6897
    netbsd*)
 
6898
      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
 
6899
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
 
6900
      else
 
6901
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
 
6902
      fi
 
6903
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
6904
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6905
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6906
      ;;
 
6907
 
 
6908
    newsos6)
 
6909
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
6910
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6911
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
6912
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6913
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6914
      ;;
 
6915
 
 
6916
    openbsd*)
 
6917
      if test -f /usr/libexec/ld.so; then
 
6918
        _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6919
        _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6920
        if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
 
6921
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
 
6922
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
 
6923
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
6924
          _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6925
        else
 
6926
          case $host_os in
 
6927
           openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
 
6928
             _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
 
6929
             _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
6930
             ;;
 
6931
           *)
 
6932
             _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
 
6933
             _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
6934
             ;;
 
6935
          esac
 
6936
        fi
 
6937
      else
 
6938
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
6939
      fi
 
6940
      ;;
 
6941
 
 
6942
    os2*)
 
6943
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6944
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6945
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6946
      _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'
 
6947
      _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
 
6948
      ;;
 
6949
 
 
6950
    osf3*)
 
6951
      if test "$GCC" = yes; then
 
6952
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
 
6953
        _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'
 
6954
      else
 
6955
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
 
6956
        _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'
 
6957
      fi
 
6958
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
6959
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6960
      ;;
 
6961
 
 
6962
    osf4* | osf5*)      # as osf3* with the addition of -msym flag
 
6963
      if test "$GCC" = yes; then
 
6964
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
 
6965
        _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'
 
6966
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 
6967
      else
 
6968
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
 
6969
        _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'
 
6970
        _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~
 
6971
        $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'
 
6972
 
 
6973
        # Both c and cxx compiler support -rpath directly
 
6974
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
 
6975
      fi
 
6976
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6977
      ;;
 
6978
 
 
6979
    solaris*)
 
6980
      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
 
6981
      if test "$GCC" = yes; then
 
6982
        wlarc='${wl}'
 
6983
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6984
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
 
6985
          $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
 
6986
      else
 
6987
        wlarc=''
 
6988
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
6989
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
 
6990
        $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
 
6991
      fi
 
6992
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
6993
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6994
      case $host_os in
 
6995
      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
 
6996
      *)
 
6997
        # The compiler driver will combine and reorder linker options,
 
6998
        # but understands `-z linker_flag'.  GCC discards it without `$wl',
 
6999
        # but is careful enough not to reorder.
 
7000
        # Supported since Solaris 2.6 (maybe 2.5.1?)
 
7001
        if test "$GCC" = yes; then
 
7002
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
 
7003
        else
 
7004
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
 
7005
        fi
 
7006
        ;;
 
7007
      esac
 
7008
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
7009
      ;;
 
7010
 
 
7011
    sunos4*)
 
7012
      if test "x$host_vendor" = xsequent; then
 
7013
        # Use $CC to link under sequent, because it throws in some extra .o
 
7014
        # files that make .init and .fini sections work.
 
7015
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
 
7016
      else
 
7017
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
 
7018
      fi
 
7019
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
7020
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
7021
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
7022
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7023
      ;;
 
7024
 
 
7025
    sysv4)
 
7026
      case $host_vendor in
 
7027
        sni)
 
7028
          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
7029
          _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
 
7030
        ;;
 
7031
        siemens)
 
7032
          ## LD is ld it makes a PLAMLIB
 
7033
          ## CC just makes a GrossModule.
 
7034
          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
 
7035
          _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
 
7036
          _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
7037
        ;;
 
7038
        motorola)
 
7039
          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
7040
          _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
 
7041
        ;;
 
7042
      esac
 
7043
      runpath_var='LD_RUN_PATH'
 
7044
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7045
      ;;
 
7046
 
 
7047
    sysv4.3*)
 
7048
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
7049
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7050
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
 
7051
      ;;
 
7052
 
 
7053
    sysv4*MP*)
 
7054
      if test -d /usr/nec; then
 
7055
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
7056
        _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7057
        runpath_var=LD_RUN_PATH
 
7058
        hardcode_runpath_var=yes
 
7059
        _LT_AC_TAGVAR(ld_shlibs, $1)=yes
 
7060
      fi
 
7061
      ;;
 
7062
 
 
7063
    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
 
7064
      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
7065
      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
7066
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7067
      runpath_var='LD_RUN_PATH'
 
7068
 
 
7069
      if test "$GCC" = yes; then
 
7070
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
7071
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
7072
      else
 
7073
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
7074
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
7075
      fi
 
7076
      ;;
 
7077
 
 
7078
    sysv5* | sco3.2v5* | sco5v6*)
 
7079
      # Note: We can NOT use -z defs as we might desire, because we do not
 
7080
      # link with -lc, and that would cause any symbols used from libc to
 
7081
      # always be unresolved, which means just about no library would
 
7082
      # ever link correctly.  If we're not using GNU ld we use -z text
 
7083
      # though, which does catch some bad symbols but isn't as heavy-handed
 
7084
      # as -z defs.
 
7085
      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
7086
      _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
 
7087
      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
7088
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7089
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
 
7090
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
 
7091
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
7092
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
 
7093
      runpath_var='LD_RUN_PATH'
 
7094
 
 
7095
      if test "$GCC" = yes; then
 
7096
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
7097
        _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'
 
7098
      else
 
7099
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
7100
        _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'
 
7101
      fi
 
7102
      ;;
 
7103
 
 
7104
    uts4*)
 
7105
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
 
7106
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
7107
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
7108
      ;;
 
7109
 
 
7110
    *)
 
7111
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
7112
      ;;
 
7113
    esac
 
7114
  fi
 
7115
])
 
7116
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
 
7117
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
 
7118
 
 
7119
#
 
7120
# Do we need to explicitly link libc?
 
7121
#
 
7122
case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
 
7123
x|xyes)
 
7124
  # Assume -lc should be added
 
7125
  _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 
7126
 
 
7127
  if test "$enable_shared" = yes && test "$GCC" = yes; then
 
7128
    case $_LT_AC_TAGVAR(archive_cmds, $1) in
 
7129
    *'~'*)
 
7130
      # FIXME: we may have to deal with multi-command sequences.
 
7131
      ;;
 
7132
    '$CC '*)
 
7133
      # Test whether the compiler implicitly links with -lc since on some
 
7134
      # systems, -lgcc has to come before -lc. If gcc already passes -lc
 
7135
      # to ld, don't add -lc before -lgcc.
 
7136
      AC_MSG_CHECKING([whether -lc should be explicitly linked in])
 
7137
      $rm conftest*
 
7138
      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
7139
 
 
7140
      if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
 
7141
        soname=conftest
 
7142
        lib=conftest
 
7143
        libobjs=conftest.$ac_objext
 
7144
        deplibs=
 
7145
        wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
 
7146
        pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
 
7147
        compiler_flags=-v
 
7148
        linker_flags=-v
 
7149
        verstring=
 
7150
        output_objdir=.
 
7151
        libname=conftest
 
7152
        lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
 
7153
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=
 
7154
        if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
 
7155
        then
 
7156
          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
7157
        else
 
7158
          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 
7159
        fi
 
7160
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
 
7161
      else
 
7162
        cat conftest.err 1>&5
 
7163
      fi
 
7164
      $rm conftest*
 
7165
      AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
 
7166
      ;;
 
7167
    esac
 
7168
  fi
 
7169
  ;;
 
7170
esac
 
7171
])# AC_LIBTOOL_PROG_LD_SHLIBS
 
7172
 
 
7173
 
 
7174
# _LT_AC_FILE_LTDLL_C
 
7175
# -------------------
 
7176
# Be careful that the start marker always follows a newline.
 
7177
AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
 
7178
# /* ltdll.c starts here */
 
7179
# #define WIN32_LEAN_AND_MEAN
 
7180
# #include <windows.h>
 
7181
# #undef WIN32_LEAN_AND_MEAN
 
7182
# #include <stdio.h>
 
7183
#
 
7184
# #ifndef __CYGWIN__
 
7185
# #  ifdef __CYGWIN32__
 
7186
# #    define __CYGWIN__ __CYGWIN32__
 
7187
# #  endif
 
7188
# #endif
 
7189
#
 
7190
# #ifdef __cplusplus
 
7191
# extern "C" {
 
7192
# #endif
 
7193
# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
 
7194
# #ifdef __cplusplus
 
7195
# }
 
7196
# #endif
 
7197
#
 
7198
# #ifdef __CYGWIN__
 
7199
# #include <cygwin/cygwin_dll.h>
 
7200
# DECLARE_CYGWIN_DLL( DllMain );
 
7201
# #endif
 
7202
# HINSTANCE __hDllInstance_base;
 
7203
#
 
7204
# BOOL APIENTRY
 
7205
# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
 
7206
# {
 
7207
#   __hDllInstance_base = hInst;
 
7208
#   return TRUE;
 
7209
# }
 
7210
# /* ltdll.c ends here */
 
7211
])# _LT_AC_FILE_LTDLL_C
 
7212
 
 
7213
 
 
7214
# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
 
7215
# ---------------------------------
 
7216
AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
 
7217
 
 
7218
 
 
7219
# old names
 
7220
AC_DEFUN([AM_PROG_LIBTOOL],   [AC_PROG_LIBTOOL])
 
7221
AC_DEFUN([AM_ENABLE_SHARED],  [AC_ENABLE_SHARED($@)])
 
7222
AC_DEFUN([AM_ENABLE_STATIC],  [AC_ENABLE_STATIC($@)])
 
7223
AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
 
7224
AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
 
7225
AC_DEFUN([AM_PROG_LD],        [AC_PROG_LD])
 
7226
AC_DEFUN([AM_PROG_NM],        [AC_PROG_NM])
 
7227
 
 
7228
# This is just to silence aclocal about the macro not being used
 
7229
ifelse([AC_DISABLE_FAST_INSTALL])
 
7230
 
 
7231
AC_DEFUN([LT_AC_PROG_GCJ],
 
7232
[AC_CHECK_TOOL(GCJ, gcj, no)
 
7233
  test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
 
7234
  AC_SUBST(GCJFLAGS)
 
7235
])
 
7236
 
 
7237
AC_DEFUN([LT_AC_PROG_RC],
 
7238
[AC_CHECK_TOOL(RC, windres, no)
 
7239
])
 
7240
 
 
7241
 
 
7242
# Cheap backport of AS_EXECUTABLE_P and required macros
 
7243
# from Autoconf 2.59; we should not use $as_executable_p directly.
 
7244
 
 
7245
# _AS_TEST_PREPARE
 
7246
# ----------------
 
7247
m4_ifndef([_AS_TEST_PREPARE],
 
7248
[m4_defun([_AS_TEST_PREPARE],
 
7249
[if test -x / >/dev/null 2>&1; then
 
7250
  as_executable_p='test -x'
 
7251
else
 
7252
  as_executable_p='test -f'
 
7253
fi
 
7254
])])# _AS_TEST_PREPARE
 
7255
 
 
7256
# AS_EXECUTABLE_P
 
7257
# ---------------
 
7258
# Check whether a file is executable.
 
7259
m4_ifndef([AS_EXECUTABLE_P],
 
7260
[m4_defun([AS_EXECUTABLE_P],
 
7261
[AS_REQUIRE([_AS_TEST_PREPARE])dnl
 
7262
$as_executable_p $1[]dnl
 
7263
])])# AS_EXECUTABLE_P
 
7264
 
 
7265
# NOTE: This macro has been submitted for inclusion into   #
 
7266
#  GNU Autoconf as AC_PROG_SED.  When it is available in   #
 
7267
#  a released version of Autoconf we should remove this    #
 
7268
#  macro and use it instead.                               #
 
7269
# LT_AC_PROG_SED
 
7270
# --------------
 
7271
# Check for a fully-functional sed program, that truncates
 
7272
# as few characters as possible.  Prefer GNU sed if found.
 
7273
AC_DEFUN([LT_AC_PROG_SED],
 
7274
[AC_MSG_CHECKING([for a sed that does not truncate output])
 
7275
AC_CACHE_VAL(lt_cv_path_SED,
 
7276
[# Loop through the user's path and test for sed and gsed.
 
7277
# Then use that list of sed's as ones to test for truncation.
 
7278
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 
7279
for as_dir in $PATH
 
7280
do
 
7281
  IFS=$as_save_IFS
 
7282
  test -z "$as_dir" && as_dir=.
 
7283
  for lt_ac_prog in sed gsed; do
 
7284
    for ac_exec_ext in '' $ac_executable_extensions; do
 
7285
      if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then
 
7286
        lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
 
7287
      fi
 
7288
    done
 
7289
  done
 
7290
done
 
7291
IFS=$as_save_IFS
 
7292
lt_ac_max=0
 
7293
lt_ac_count=0
 
7294
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
 
7295
# along with /bin/sed that truncates output.
 
7296
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
 
7297
  test ! -f $lt_ac_sed && continue
 
7298
  cat /dev/null > conftest.in
 
7299
  lt_ac_count=0
 
7300
  echo $ECHO_N "0123456789$ECHO_C" >conftest.in
 
7301
  # Check for GNU sed and select it if it is found.
 
7302
  if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
 
7303
    lt_cv_path_SED=$lt_ac_sed
 
7304
    break
 
7305
  fi
 
7306
  while true; do
 
7307
    cat conftest.in conftest.in >conftest.tmp
 
7308
    mv conftest.tmp conftest.in
 
7309
    cp conftest.in conftest.nl
 
7310
    echo >>conftest.nl
 
7311
    $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
 
7312
    cmp -s conftest.out conftest.nl || break
 
7313
    # 10000 chars as input seems more than enough
 
7314
    test $lt_ac_count -gt 10 && break
 
7315
    lt_ac_count=`expr $lt_ac_count + 1`
 
7316
    if test $lt_ac_count -gt $lt_ac_max; then
 
7317
      lt_ac_max=$lt_ac_count
 
7318
      lt_cv_path_SED=$lt_ac_sed
 
7319
    fi
 
7320
  done
 
7321
done
 
7322
])
 
7323
SED=$lt_cv_path_SED
 
7324
AC_SUBST([SED])
 
7325
AC_MSG_RESULT([$SED])
 
7326
])
 
7327
 
689
7328
# nls.m4 serial 3 (gettext-0.15)
690
7329
dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc.
691
7330
dnl This file is free software; the Free Software Foundation
786
7425
# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
787
7426
# ---------------------------------------------
788
7427
m4_define([_PKG_CONFIG],
789
 
[if test -n "$PKG_CONFIG"; then
790
 
    if test -n "$$1"; then
791
 
        pkg_cv_[]$1="$$1"
792
 
    else
793
 
        PKG_CHECK_EXISTS([$3],
794
 
                         [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
795
 
                         [pkg_failed=yes])
796
 
    fi
797
 
else
798
 
        pkg_failed=untried
 
7428
[if test -n "$$1"; then
 
7429
    pkg_cv_[]$1="$$1"
 
7430
 elif test -n "$PKG_CONFIG"; then
 
7431
    PKG_CHECK_EXISTS([$3],
 
7432
                     [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
 
7433
                     [pkg_failed=yes])
 
7434
 else
 
7435
    pkg_failed=untried
799
7436
fi[]dnl
800
7437
])# _PKG_CONFIG
801
7438
 
839
7476
if test $pkg_failed = yes; then
840
7477
        _PKG_SHORT_ERRORS_SUPPORTED
841
7478
        if test $_pkg_short_errors_supported = yes; then
842
 
                $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$2"`
 
7479
                $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
843
7480
        else 
844
 
                $1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
 
7481
                $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
845
7482
        fi
846
7483
        # Put the nasty error message in config.log where it belongs
847
7484
        echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
1771
8408
 
1772
8409
m4_include([m4/gnome-doc-utils.m4])
1773
8410
m4_include([m4/intltool.m4])
1774
 
m4_include([m4/libtool.m4])
1775
 
m4_include([m4/ltoptions.m4])
1776
 
m4_include([m4/ltsugar.m4])
1777
 
m4_include([m4/ltversion.m4])
1778
 
m4_include([m4/lt~obsolete.m4])