Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5410 in orxonox.OLD for trunk/aclocal.m4


Ignore:
Timestamp:
Oct 20, 2005, 10:03:09 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: building with LIBTOOL now, all Shared Libs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/aclocal.m4

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