~ubuntu-branches/ubuntu/vivid/libunity-misc/vivid

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Didier Roche
  • Date: 2011-08-01 17:35:56 UTC
  • mfrom: (1.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20110801173556-859qxyar2xfd3hli
Tags: 4.0.4-0ubuntu1
* New upstream release.
* debian/libunity-misc4.symbols:
  - add the new symbols
* debian/control:
  - build-dep on libx11-dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
 
14
14
m4_ifndef([AC_AUTOCONF_VERSION],
15
15
  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16
 
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],,
17
 
[m4_warning([this file was generated for autoconf 2.67.
 
16
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],,
 
17
[m4_warning([this file was generated for autoconf 2.68.
18
18
You have another version of autoconf.  It may work, but is not guaranteed to.
19
19
If you have problems, you may need to regenerate the build system entirely.
20
20
To do so, use the procedure documented by the package, typically `autoreconf'.])])
84
84
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
85
85
#
86
86
#   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
87
 
#                 2006, 2007, 2008 Free Software Foundation, Inc.
 
87
#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
 
88
#                 Inc.
88
89
#   Written by Gordon Matzigkeit, 1996
89
90
#
90
91
# This file is free software; the Free Software Foundation gives
93
94
 
94
95
m4_define([_LT_COPYING], [dnl
95
96
#   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
96
 
#                 2006, 2007, 2008 Free Software Foundation, Inc.
 
97
#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
 
98
#                 Inc.
97
99
#   Written by Gordon Matzigkeit, 1996
98
100
#
99
101
#   This file is part of GNU Libtool.
120
122
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
121
123
])
122
124
 
123
 
# serial 56 LT_INIT
 
125
# serial 57 LT_INIT
124
126
 
125
127
 
126
128
# LT_PREREQ(VERSION)
149
151
# ------------------
150
152
AC_DEFUN([LT_INIT],
151
153
[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
 
154
AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
152
155
AC_BEFORE([$0], [LT_LANG])dnl
153
156
AC_BEFORE([$0], [LT_OUTPUT])dnl
154
157
AC_BEFORE([$0], [LTDL_INIT])dnl
165
168
AC_REQUIRE([LTOBSOLETE_VERSION])dnl
166
169
m4_require([_LT_PROG_LTMAIN])dnl
167
170
 
 
171
_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
 
172
 
168
173
dnl Parse OPTIONS
169
174
_LT_SET_OPTIONS([$0], [$1])
170
175
 
201
206
    *) break;;
202
207
  esac
203
208
done
204
 
cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
 
209
cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
205
210
])
206
211
 
207
212
 
221
226
m4_defun([_LT_SETUP],
222
227
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
223
228
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
 
229
AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
 
230
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
 
231
 
224
232
_LT_DECL([], [host_alias], [0], [The host system])dnl
225
233
_LT_DECL([], [host], [0])dnl
226
234
_LT_DECL([], [host_os], [0])dnl
243
251
dnl
244
252
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
245
253
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
 
254
m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
246
255
m4_require([_LT_CMD_RELOAD])dnl
247
256
m4_require([_LT_CHECK_MAGIC_METHOD])dnl
 
257
m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
248
258
m4_require([_LT_CMD_OLD_ARCHIVE])dnl
249
259
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
 
260
m4_require([_LT_WITH_SYSROOT])dnl
250
261
 
251
262
_LT_CONFIG_LIBTOOL_INIT([
252
263
# See if we are running on zsh, and set the options which allow our
262
273
_LT_CHECK_OBJDIR
263
274
 
264
275
m4_require([_LT_TAG_COMPILER])dnl
265
 
_LT_PROG_ECHO_BACKSLASH
266
276
 
267
277
case $host_os in
268
278
aix3*)
276
286
  ;;
277
287
esac
278
288
 
279
 
# Sed substitution that helps us do robust quoting.  It backslashifies
280
 
# metacharacters that are still active within double-quoted strings.
281
 
sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
282
 
 
283
 
# Same as above, but do not quote variable references.
284
 
double_quote_subst='s/\([["`\\]]\)/\\\1/g'
285
 
 
286
 
# Sed substitution to delay expansion of an escaped shell variable in a
287
 
# double_quote_subst'ed string.
288
 
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
289
 
 
290
 
# Sed substitution to delay expansion of an escaped single quote.
291
 
delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
292
 
 
293
 
# Sed substitution to avoid accidental globbing in evaled expressions
294
 
no_glob_subst='s/\*/\\\*/g'
295
 
 
296
289
# Global variables:
297
290
ofile=libtool
298
291
can_build_shared=yes
333
326
])# _LT_SETUP
334
327
 
335
328
 
 
329
# _LT_PREPARE_SED_QUOTE_VARS
 
330
# --------------------------
 
331
# Define a few sed substitution that help us do robust quoting.
 
332
m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
 
333
[# Backslashify metacharacters that are still active within
 
334
# double-quoted strings.
 
335
sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
 
336
 
 
337
# Same as above, but do not quote variable references.
 
338
double_quote_subst='s/\([["`\\]]\)/\\\1/g'
 
339
 
 
340
# Sed substitution to delay expansion of an escaped shell variable in a
 
341
# double_quote_subst'ed string.
 
342
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
 
343
 
 
344
# Sed substitution to delay expansion of an escaped single quote.
 
345
delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
 
346
 
 
347
# Sed substitution to avoid accidental globbing in evaled expressions
 
348
no_glob_subst='s/\*/\\\*/g'
 
349
])
 
350
 
336
351
# _LT_PROG_LTMAIN
337
352
# ---------------
338
353
# Note that this code is called both from `configure', and `config.status'
485
500
# declaration there will have the same value as in `configure'.  VARNAME
486
501
# must have a single quote delimited value for this to work.
487
502
m4_define([_LT_CONFIG_STATUS_DECLARE],
488
 
[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
 
503
[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
489
504
 
490
505
 
491
506
# _LT_CONFIG_STATUS_DECLARATIONS
495
510
# embedded single quotes properly.  In configure, this macro expands
496
511
# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
497
512
#
498
 
#    <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
 
513
#    <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
499
514
m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
500
515
[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
501
516
    [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
594
609
LTCFLAGS='$LTCFLAGS'
595
610
compiler='$compiler_DEFAULT'
596
611
 
 
612
# A function that is used when there is no print builtin or printf.
 
613
func_fallback_echo ()
 
614
{
 
615
  eval 'cat <<_LTECHO_EOF
 
616
\$[]1
 
617
_LTECHO_EOF'
 
618
}
 
619
 
597
620
# Quote evaled strings.
598
621
for var in lt_decl_all_varnames([[ \
599
622
]], lt_decl_quote_varnames); do
600
 
    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
 
623
    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
601
624
    *[[\\\\\\\`\\"\\\$]]*)
602
 
      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
 
625
      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
603
626
      ;;
604
627
    *)
605
628
      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
610
633
# Double-quote double-evaled strings.
611
634
for var in lt_decl_all_varnames([[ \
612
635
]], lt_decl_dquote_varnames); do
613
 
    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
 
636
    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
614
637
    *[[\\\\\\\`\\"\\\$]]*)
615
 
      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
 
638
      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
616
639
      ;;
617
640
    *)
618
641
      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
620
643
    esac
621
644
done
622
645
 
623
 
# Fix-up fallback echo if it was mangled by the above quoting rules.
624
 
case \$lt_ECHO in
625
 
*'\\\[$]0 --fallback-echo"')dnl "
626
 
  lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
627
 
  ;;
628
 
esac
629
 
 
630
646
_LT_OUTPUT_LIBTOOL_INIT
631
647
])
632
648
 
 
649
# _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
 
650
# ------------------------------------
 
651
# Generate a child script FILE with all initialization necessary to
 
652
# reuse the environment learned by the parent script, and make the
 
653
# file executable.  If COMMENT is supplied, it is inserted after the
 
654
# `#!' sequence but before initialization text begins.  After this
 
655
# macro, additional text can be appended to FILE to form the body of
 
656
# the child script.  The macro ends with non-zero status if the
 
657
# file could not be fully written (such as if the disk is full).
 
658
m4_ifdef([AS_INIT_GENERATED],
 
659
[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
 
660
[m4_defun([_LT_GENERATED_FILE_INIT],
 
661
[m4_require([AS_PREPARE])]dnl
 
662
[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
 
663
[lt_write_fail=0
 
664
cat >$1 <<_ASEOF || lt_write_fail=1
 
665
#! $SHELL
 
666
# Generated by $as_me.
 
667
$2
 
668
SHELL=\${CONFIG_SHELL-$SHELL}
 
669
export SHELL
 
670
_ASEOF
 
671
cat >>$1 <<\_ASEOF || lt_write_fail=1
 
672
AS_SHELL_SANITIZE
 
673
_AS_PREPARE
 
674
exec AS_MESSAGE_FD>&1
 
675
_ASEOF
 
676
test $lt_write_fail = 0 && chmod +x $1[]dnl
 
677
m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
633
678
 
634
679
# LT_OUTPUT
635
680
# ---------
639
684
AC_DEFUN([LT_OUTPUT],
640
685
[: ${CONFIG_LT=./config.lt}
641
686
AC_MSG_NOTICE([creating $CONFIG_LT])
642
 
cat >"$CONFIG_LT" <<_LTEOF
643
 
#! $SHELL
644
 
# Generated by $as_me.
645
 
# Run this file to recreate a libtool stub with the current configuration.
 
687
_LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
 
688
[# Run this file to recreate a libtool stub with the current configuration.])
646
689
 
 
690
cat >>"$CONFIG_LT" <<\_LTEOF
647
691
lt_cl_silent=false
648
 
SHELL=\${CONFIG_SHELL-$SHELL}
649
 
_LTEOF
650
 
 
651
 
cat >>"$CONFIG_LT" <<\_LTEOF
652
 
AS_SHELL_SANITIZE
653
 
_AS_PREPARE
654
 
 
655
 
exec AS_MESSAGE_FD>&1
656
692
exec AS_MESSAGE_LOG_FD>>config.log
657
693
{
658
694
  echo
678
714
m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
679
715
configured by $[0], generated by m4_PACKAGE_STRING.
680
716
 
681
 
Copyright (C) 2008 Free Software Foundation, Inc.
 
717
Copyright (C) 2010 Free Software Foundation, Inc.
682
718
This config.lt script is free software; the Free Software Foundation
683
719
gives unlimited permision to copy, distribute and modify it."
684
720
 
723
759
# appending to config.log, which fails on DOS, as config.log is still kept
724
760
# open by configure.  Here we exec the FD to /dev/null, effectively closing
725
761
# config.log, so it can be properly (re)opened and appended to by config.lt.
726
 
if test "$no_create" != yes; then
727
 
  lt_cl_success=:
728
 
  test "$silent" = yes &&
729
 
    lt_config_lt_args="$lt_config_lt_args --quiet"
730
 
  exec AS_MESSAGE_LOG_FD>/dev/null
731
 
  $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
732
 
  exec AS_MESSAGE_LOG_FD>>config.log
733
 
  $lt_cl_success || AS_EXIT(1)
734
 
fi
 
762
lt_cl_success=:
 
763
test "$silent" = yes &&
 
764
  lt_config_lt_args="$lt_config_lt_args --quiet"
 
765
exec AS_MESSAGE_LOG_FD>/dev/null
 
766
$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
 
767
exec AS_MESSAGE_LOG_FD>>config.log
 
768
$lt_cl_success || AS_EXIT(1)
735
769
])# LT_OUTPUT
736
770
 
737
771
 
794
828
  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
795
829
  # text mode, it properly converts lines to CR/LF.  This bash problem
796
830
  # is reportedly fixed, but why not run on old versions too?
797
 
  sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
798
 
    || (rm -f "$cfgfile"; exit 1)
799
 
 
800
 
  _LT_PROG_XSI_SHELLFNS
801
 
 
802
 
  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
803
 
    || (rm -f "$cfgfile"; exit 1)
804
 
 
805
 
  mv -f "$cfgfile" "$ofile" ||
 
831
  sed '$q' "$ltmain" >> "$cfgfile" \
 
832
     || (rm -f "$cfgfile"; exit 1)
 
833
 
 
834
  _LT_PROG_REPLACE_SHELLFNS
 
835
 
 
836
   mv -f "$cfgfile" "$ofile" ||
806
837
    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
807
838
  chmod +x "$ofile"
808
839
],
908
939
AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
909
940
AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
910
941
AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
 
942
AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
911
943
dnl aclocal-1.4 backwards compatibility:
912
944
dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
913
945
dnl AC_DEFUN([AC_LIBTOOL_F77], [])
914
946
dnl AC_DEFUN([AC_LIBTOOL_FC], [])
915
947
dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
 
948
dnl AC_DEFUN([AC_LIBTOOL_RC], [])
916
949
 
917
950
 
918
951
# _LT_TAG_COMPILER
1017
1050
        [lt_cv_ld_exported_symbols_list=no])
1018
1051
        LDFLAGS="$save_LDFLAGS"
1019
1052
    ])
 
1053
    AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
 
1054
      [lt_cv_ld_force_load=no
 
1055
      cat > conftest.c << _LT_EOF
 
1056
int forced_loaded() { return 2;}
 
1057
_LT_EOF
 
1058
      echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
 
1059
      $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
 
1060
      echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
 
1061
      $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
 
1062
      echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
 
1063
      $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
 
1064
      cat > conftest.c << _LT_EOF
 
1065
int main() { return 0;}
 
1066
_LT_EOF
 
1067
      echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
 
1068
      $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
 
1069
      _lt_result=$?
 
1070
      if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
 
1071
        lt_cv_ld_force_load=yes
 
1072
      else
 
1073
        cat conftest.err >&AS_MESSAGE_LOG_FD
 
1074
      fi
 
1075
        rm -f conftest.err libconftest.a conftest conftest.c
 
1076
        rm -rf conftest.dSYM
 
1077
    ])
1020
1078
    case $host_os in
1021
1079
    rhapsody* | darwin1.[[012]])
1022
1080
      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1044
1102
    else
1045
1103
      _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1046
1104
    fi
1047
 
    if test "$DSYMUTIL" != ":"; then
 
1105
    if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
1048
1106
      _lt_dsymutil='~$DSYMUTIL $lib || :'
1049
1107
    else
1050
1108
      _lt_dsymutil=
1064
1122
  _LT_TAGVAR(hardcode_direct, $1)=no
1065
1123
  _LT_TAGVAR(hardcode_automatic, $1)=yes
1066
1124
  _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1067
 
  _LT_TAGVAR(whole_archive_flag_spec, $1)=''
 
1125
  if test "$lt_cv_ld_force_load" = "yes"; then
 
1126
    _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
 
1127
  else
 
1128
    _LT_TAGVAR(whole_archive_flag_spec, $1)=''
 
1129
  fi
1068
1130
  _LT_TAGVAR(link_all_deplibs, $1)=yes
1069
1131
  _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1070
1132
  case $cc_basename in
1072
1134
     *) _lt_dar_can_shared=$GCC ;;
1073
1135
  esac
1074
1136
  if test "$_lt_dar_can_shared" = "yes"; then
1075
 
    output_verbose_link_cmd=echo
 
1137
    output_verbose_link_cmd=func_echo_all
1076
1138
    _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
1077
1139
    _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1078
1140
    _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
1088
1150
  fi
1089
1151
])
1090
1152
 
1091
 
# _LT_SYS_MODULE_PATH_AIX
1092
 
# -----------------------
 
1153
# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
 
1154
# ----------------------------------
1093
1155
# Links a minimal program and checks the executable
1094
1156
# for the system default hardcoded library path. In most cases,
1095
1157
# this is /usr/lib:/lib, but when the MPI compilers are used
1096
1158
# the location of the communication and MPI libs are included too.
1097
1159
# If we don't find anything, use the default library path according
1098
1160
# to the aix ld manual.
 
1161
# Store the results from the different compilers for each TAGNAME.
 
1162
# Allow to override them for all tags through lt_cv_aix_libpath.
1099
1163
m4_defun([_LT_SYS_MODULE_PATH_AIX],
1100
1164
[m4_require([_LT_DECL_SED])dnl
1101
 
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1102
 
lt_aix_libpath_sed='
1103
 
    /Import File Strings/,/^$/ {
1104
 
        /^0/ {
1105
 
            s/^0  *\(.*\)$/\1/
1106
 
            p
1107
 
        }
1108
 
    }'
1109
 
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1110
 
# Check for a 64-bit object if we didn't find anything.
1111
 
if test -z "$aix_libpath"; then
1112
 
  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1113
 
fi],[])
1114
 
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
1165
if test "${lt_cv_aix_libpath+set}" = set; then
 
1166
  aix_libpath=$lt_cv_aix_libpath
 
1167
else
 
1168
  AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
 
1169
  [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
 
1170
  lt_aix_libpath_sed='[
 
1171
      /Import File Strings/,/^$/ {
 
1172
          /^0/ {
 
1173
              s/^0  *\([^ ]*\) *$/\1/
 
1174
              p
 
1175
          }
 
1176
      }]'
 
1177
  _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 
1178
  # Check for a 64-bit object if we didn't find anything.
 
1179
  if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
 
1180
    _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 
1181
  fi],[])
 
1182
  if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
 
1183
    _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
 
1184
  fi
 
1185
  ])
 
1186
  aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
 
1187
fi
1115
1188
])# _LT_SYS_MODULE_PATH_AIX
1116
1189
 
1117
1190
 
1118
1191
# _LT_SHELL_INIT(ARG)
1119
1192
# -------------------
1120
1193
m4_define([_LT_SHELL_INIT],
1121
 
[ifdef([AC_DIVERSION_NOTICE],
1122
 
             [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1123
 
         [AC_DIVERT_PUSH(NOTICE)])
1124
 
$1
1125
 
AC_DIVERT_POP
1126
 
])# _LT_SHELL_INIT
 
1194
[m4_divert_text([M4SH-INIT], [$1
 
1195
])])# _LT_SHELL_INIT
 
1196
 
1127
1197
 
1128
1198
 
1129
1199
# _LT_PROG_ECHO_BACKSLASH
1130
1200
# -----------------------
1131
 
# Add some code to the start of the generated configure script which
1132
 
# will find an echo command which doesn't interpret backslashes.
 
1201
# Find how we can fake an echo command that does not interpret backslash.
 
1202
# In particular, with Autoconf 2.60 or later we add some code to the start
 
1203
# of the generated configure script which will find a shell with a builtin
 
1204
# printf (which we can use as an echo command).
1133
1205
m4_defun([_LT_PROG_ECHO_BACKSLASH],
1134
 
[_LT_SHELL_INIT([
1135
 
# Check that we are running under the correct shell.
1136
 
SHELL=${CONFIG_SHELL-/bin/sh}
1137
 
 
1138
 
case X$lt_ECHO in
1139
 
X*--fallback-echo)
1140
 
  # Remove one level of quotation (which was required for Make).
1141
 
  ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1142
 
  ;;
 
1206
[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
 
1207
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
 
1208
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
 
1209
 
 
1210
AC_MSG_CHECKING([how to print strings])
 
1211
# Test print first, because it will be a builtin if present.
 
1212
if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
 
1213
   test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
 
1214
  ECHO='print -r --'
 
1215
elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
 
1216
  ECHO='printf %s\n'
 
1217
else
 
1218
  # Use this function as a fallback that always works.
 
1219
  func_fallback_echo ()
 
1220
  {
 
1221
    eval 'cat <<_LTECHO_EOF
 
1222
$[]1
 
1223
_LTECHO_EOF'
 
1224
  }
 
1225
  ECHO='func_fallback_echo'
 
1226
fi
 
1227
 
 
1228
# func_echo_all arg...
 
1229
# Invoke $ECHO with all args, space-separated.
 
1230
func_echo_all ()
 
1231
{
 
1232
    $ECHO "$*" 
 
1233
}
 
1234
 
 
1235
case "$ECHO" in
 
1236
  printf*) AC_MSG_RESULT([printf]) ;;
 
1237
  print*) AC_MSG_RESULT([print -r]) ;;
 
1238
  *) AC_MSG_RESULT([cat]) ;;
1143
1239
esac
1144
1240
 
1145
 
ECHO=${lt_ECHO-echo}
1146
 
if test "X[$]1" = X--no-reexec; then
1147
 
  # Discard the --no-reexec flag, and continue.
1148
 
  shift
1149
 
elif test "X[$]1" = X--fallback-echo; then
1150
 
  # Avoid inline document here, it may be left over
1151
 
  :
1152
 
elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
1153
 
  # Yippee, $ECHO works!
1154
 
  :
1155
 
else
1156
 
  # Restart under the correct shell.
1157
 
  exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1158
 
fi
1159
 
 
1160
 
if test "X[$]1" = X--fallback-echo; then
1161
 
  # used as fallback echo
1162
 
  shift
1163
 
  cat <<_LT_EOF
1164
 
[$]*
1165
 
_LT_EOF
1166
 
  exit 0
1167
 
fi
1168
 
 
1169
 
# The HP-UX ksh and POSIX shell print the target directory to stdout
1170
 
# if CDPATH is set.
1171
 
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1172
 
 
1173
 
if test -z "$lt_ECHO"; then
1174
 
  if test "X${echo_test_string+set}" != Xset; then
1175
 
    # find a string as large as possible, as long as the shell can cope with it
1176
 
    for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1177
 
      # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1178
 
      if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
1179
 
         { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
1180
 
      then
1181
 
        break
1182
 
      fi
1183
 
    done
1184
 
  fi
1185
 
 
1186
 
  if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1187
 
     echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1188
 
     test "X$echo_testing_string" = "X$echo_test_string"; then
1189
 
    :
1190
 
  else
1191
 
    # The Solaris, AIX, and Digital Unix default echo programs unquote
1192
 
    # backslashes.  This makes it impossible to quote backslashes using
1193
 
    #   echo "$something" | sed 's/\\/\\\\/g'
1194
 
    #
1195
 
    # So, first we look for a working echo in the user's PATH.
1196
 
 
1197
 
    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1198
 
    for dir in $PATH /usr/ucb; do
1199
 
      IFS="$lt_save_ifs"
1200
 
      if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1201
 
         test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1202
 
         echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1203
 
         test "X$echo_testing_string" = "X$echo_test_string"; then
1204
 
        ECHO="$dir/echo"
1205
 
        break
1206
 
      fi
1207
 
    done
1208
 
    IFS="$lt_save_ifs"
1209
 
 
1210
 
    if test "X$ECHO" = Xecho; then
1211
 
      # We didn't find a better echo, so look for alternatives.
1212
 
      if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
1213
 
         echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
1214
 
         test "X$echo_testing_string" = "X$echo_test_string"; then
1215
 
        # This shell has a builtin print -r that does the trick.
1216
 
        ECHO='print -r'
1217
 
      elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
1218
 
           test "X$CONFIG_SHELL" != X/bin/ksh; then
1219
 
        # If we have ksh, try running configure again with it.
1220
 
        ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1221
 
        export ORIGINAL_CONFIG_SHELL
1222
 
        CONFIG_SHELL=/bin/ksh
1223
 
        export CONFIG_SHELL
1224
 
        exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1225
 
      else
1226
 
        # Try using printf.
1227
 
        ECHO='printf %s\n'
1228
 
        if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1229
 
           echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1230
 
           test "X$echo_testing_string" = "X$echo_test_string"; then
1231
 
          # Cool, printf works
1232
 
          :
1233
 
        elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1234
 
             test "X$echo_testing_string" = 'X\t' &&
1235
 
             echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1236
 
             test "X$echo_testing_string" = "X$echo_test_string"; then
1237
 
          CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1238
 
          export CONFIG_SHELL
1239
 
          SHELL="$CONFIG_SHELL"
1240
 
          export SHELL
1241
 
          ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1242
 
        elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1243
 
             test "X$echo_testing_string" = 'X\t' &&
1244
 
             echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1245
 
             test "X$echo_testing_string" = "X$echo_test_string"; then
1246
 
          ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1247
 
        else
1248
 
          # maybe with a smaller string...
1249
 
          prev=:
1250
 
 
1251
 
          for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1252
 
            if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
1253
 
            then
1254
 
              break
1255
 
            fi
1256
 
            prev="$cmd"
1257
 
          done
1258
 
 
1259
 
          if test "$prev" != 'sed 50q "[$]0"'; then
1260
 
            echo_test_string=`eval $prev`
1261
 
            export echo_test_string
1262
 
            exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1263
 
          else
1264
 
            # Oops.  We lost completely, so just stick with echo.
1265
 
            ECHO=echo
1266
 
          fi
1267
 
        fi
1268
 
      fi
1269
 
    fi
1270
 
  fi
1271
 
fi
1272
 
 
1273
 
# Copy echo and quote the copy suitably for passing to libtool from
1274
 
# the Makefile, instead of quoting the original, which is used later.
1275
 
lt_ECHO=$ECHO
1276
 
if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1277
 
   lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1278
 
fi
1279
 
 
1280
 
AC_SUBST(lt_ECHO)
1281
 
])
 
1241
m4_ifdef([_AS_DETECT_SUGGESTED],
 
1242
[_AS_DETECT_SUGGESTED([
 
1243
  test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
 
1244
    ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
 
1245
    ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
 
1246
    ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
 
1247
    PATH=/empty FPATH=/empty; export PATH FPATH
 
1248
    test "X`printf %s $ECHO`" = "X$ECHO" \
 
1249
      || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
 
1250
 
1282
1251
_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1283
 
_LT_DECL([], [ECHO], [1],
1284
 
    [An echo program that does not interpret backslashes])
 
1252
_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1285
1253
])# _LT_PROG_ECHO_BACKSLASH
1286
1254
 
1287
1255
 
 
1256
# _LT_WITH_SYSROOT
 
1257
# ----------------
 
1258
AC_DEFUN([_LT_WITH_SYSROOT],
 
1259
[AC_MSG_CHECKING([for sysroot])
 
1260
AC_ARG_WITH([sysroot],
 
1261
[  --with-sysroot[=DIR] Search for dependent libraries within DIR
 
1262
                        (or the compiler's sysroot if not specified).],
 
1263
[], [with_sysroot=no])
 
1264
 
 
1265
dnl lt_sysroot will always be passed unquoted.  We quote it here
 
1266
dnl in case the user passed a directory name.
 
1267
lt_sysroot=
 
1268
case ${with_sysroot} in #(
 
1269
 yes)
 
1270
   if test "$GCC" = yes; then
 
1271
     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
 
1272
   fi
 
1273
   ;; #(
 
1274
 /*)
 
1275
   lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
 
1276
   ;; #(
 
1277
 no|'')
 
1278
   ;; #(
 
1279
 *)
 
1280
   AC_MSG_RESULT([${with_sysroot}])
 
1281
   AC_MSG_ERROR([The sysroot must be an absolute path.])
 
1282
   ;;
 
1283
esac
 
1284
 
 
1285
 AC_MSG_RESULT([${lt_sysroot:-no}])
 
1286
_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
 
1287
[dependent libraries, and in which our libraries should be installed.])])
 
1288
 
1288
1289
# _LT_ENABLE_LOCK
1289
1290
# ---------------
1290
1291
m4_defun([_LT_ENABLE_LOCK],
1313
1314
  ;;
1314
1315
*-*-irix6*)
1315
1316
  # Find out which ABI we are using.
1316
 
  echo '[#]line __oline__ "configure"' > conftest.$ac_ext
 
1317
  echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1317
1318
  if AC_TRY_EVAL(ac_compile); then
1318
1319
    if test "$lt_cv_prog_gnu_ld" = yes; then
1319
1320
      case `/usr/bin/file conftest.$ac_objext` in
1431
1432
])# _LT_ENABLE_LOCK
1432
1433
 
1433
1434
 
 
1435
# _LT_PROG_AR
 
1436
# -----------
 
1437
m4_defun([_LT_PROG_AR],
 
1438
[AC_CHECK_TOOLS(AR, [ar], false)
 
1439
: ${AR=ar}
 
1440
: ${AR_FLAGS=cru}
 
1441
_LT_DECL([], [AR], [1], [The archiver])
 
1442
_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
 
1443
 
 
1444
AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
 
1445
  [lt_cv_ar_at_file=no
 
1446
   AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
 
1447
     [echo conftest.$ac_objext > conftest.lst
 
1448
      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
 
1449
      AC_TRY_EVAL([lt_ar_try])
 
1450
      if test "$ac_status" -eq 0; then
 
1451
        # Ensure the archiver fails upon bogus file names.
 
1452
        rm -f conftest.$ac_objext libconftest.a
 
1453
        AC_TRY_EVAL([lt_ar_try])
 
1454
        if test "$ac_status" -ne 0; then
 
1455
          lt_cv_ar_at_file=@
 
1456
        fi
 
1457
      fi
 
1458
      rm -f conftest.* libconftest.a
 
1459
     ])
 
1460
  ])
 
1461
 
 
1462
if test "x$lt_cv_ar_at_file" = xno; then
 
1463
  archiver_list_spec=
 
1464
else
 
1465
  archiver_list_spec=$lt_cv_ar_at_file
 
1466
fi
 
1467
_LT_DECL([], [archiver_list_spec], [1],
 
1468
  [How to feed a file listing to the archiver])
 
1469
])# _LT_PROG_AR
 
1470
 
 
1471
 
1434
1472
# _LT_CMD_OLD_ARCHIVE
1435
1473
# -------------------
1436
1474
m4_defun([_LT_CMD_OLD_ARCHIVE],
1437
 
[AC_CHECK_TOOL(AR, ar, false)
1438
 
test -z "$AR" && AR=ar
1439
 
test -z "$AR_FLAGS" && AR_FLAGS=cru
1440
 
_LT_DECL([], [AR], [1], [The archiver])
1441
 
_LT_DECL([], [AR_FLAGS], [1])
 
1475
[_LT_PROG_AR
1442
1476
 
1443
1477
AC_CHECK_TOOL(STRIP, strip, :)
1444
1478
test -z "$STRIP" && STRIP=:
1465
1499
  esac
1466
1500
  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
1467
1501
fi
 
1502
 
 
1503
case $host_os in
 
1504
  darwin*)
 
1505
    lock_old_archive_extraction=yes ;;
 
1506
  *)
 
1507
    lock_old_archive_extraction=no ;;
 
1508
esac
1468
1509
_LT_DECL([], [old_postinstall_cmds], [2])
1469
1510
_LT_DECL([], [old_postuninstall_cmds], [2])
1470
1511
_LT_TAGDECL([], [old_archive_cmds], [2],
1471
1512
    [Commands used to build an old-style archive])
 
1513
_LT_DECL([], [lock_old_archive_extraction], [0],
 
1514
    [Whether to use a lock for old archive extraction])
1472
1515
])# _LT_CMD_OLD_ARCHIVE
1473
1516
 
1474
1517
 
1493
1536
   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1494
1537
   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1495
1538
   -e 's:$: $lt_compiler_flag:'`
1496
 
   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
 
1539
   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1497
1540
   (eval "$lt_compile" 2>conftest.err)
1498
1541
   ac_status=$?
1499
1542
   cat conftest.err >&AS_MESSAGE_LOG_FD
1500
 
   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
 
1543
   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1501
1544
   if (exit $ac_status) && test -s "$ac_outfile"; then
1502
1545
     # The compiler can only warn and ignore the option if not recognized
1503
1546
     # So say no if there are warnings other than the usual output.
1504
 
     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
 
1547
     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
1505
1548
     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1506
1549
     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1507
1550
       $2=yes
1541
1584
     if test -s conftest.err; then
1542
1585
       # Append any errors to the config.log.
1543
1586
       cat conftest.err 1>&AS_MESSAGE_LOG_FD
1544
 
       $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
 
1587
       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
1545
1588
       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1546
1589
       if diff conftest.exp conftest.er2 >/dev/null; then
1547
1590
         $2=yes
1604
1647
    lt_cv_sys_max_cmd_len=8192;
1605
1648
    ;;
1606
1649
 
 
1650
  mint*)
 
1651
    # On MiNT this can take a long time and run out of memory.
 
1652
    lt_cv_sys_max_cmd_len=8192;
 
1653
    ;;
 
1654
 
1607
1655
  amigaos*)
1608
1656
    # On AmigaOS with pdksh, this test takes hours, literally.
1609
1657
    # So we just punt and use a minimum line length of 8192.
1668
1716
      # If test is not a shell built-in, we'll probably end up computing a
1669
1717
      # maximum length that is only half of the actual maximum length, but
1670
1718
      # we can't tell.
1671
 
      while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
1672
 
                 = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
 
1719
      while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
 
1720
                 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
1673
1721
              test $i != 17 # 1/2 MB should be enough
1674
1722
      do
1675
1723
        i=`expr $i + 1`
1720
1768
  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1721
1769
  lt_status=$lt_dlunknown
1722
1770
  cat > conftest.$ac_ext <<_LT_EOF
1723
 
[#line __oline__ "configure"
 
1771
[#line $LINENO "configure"
1724
1772
#include "confdefs.h"
1725
1773
 
1726
1774
#if HAVE_DLFCN_H
1761
1809
#  endif
1762
1810
#endif
1763
1811
 
1764
 
void fnord() { int i=42;}
 
1812
/* When -fvisbility=hidden is used, assume the code has been annotated
 
1813
   correspondingly for the symbols needed.  */
 
1814
#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
 
1815
int fnord () __attribute__((visibility("default")));
 
1816
#endif
 
1817
 
 
1818
int fnord () { return 42; }
1765
1819
int main ()
1766
1820
{
1767
1821
  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1770
1824
  if (self)
1771
1825
    {
1772
1826
      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
1773
 
      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
 
1827
      else
 
1828
        {
 
1829
          if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
 
1830
          else puts (dlerror ());
 
1831
        }
1774
1832
      /* dlclose (self); */
1775
1833
    }
1776
1834
  else
1946
2004
   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1947
2005
   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1948
2006
   -e 's:$: $lt_compiler_flag:'`
1949
 
   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
 
2007
   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1950
2008
   (eval "$lt_compile" 2>out/conftest.err)
1951
2009
   ac_status=$?
1952
2010
   cat out/conftest.err >&AS_MESSAGE_LOG_FD
1953
 
   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
 
2011
   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1954
2012
   if (exit $ac_status) && test -s out/conftest2.$ac_objext
1955
2013
   then
1956
2014
     # The compiler can only warn and ignore the option if not recognized
1957
2015
     # So say no if there are warnings
1958
 
     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
 
2016
     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
1959
2017
     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
1960
2018
     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1961
2019
       _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2114
2172
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2115
2173
m4_require([_LT_DECL_OBJDUMP])dnl
2116
2174
m4_require([_LT_DECL_SED])dnl
 
2175
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2117
2176
AC_MSG_CHECKING([dynamic linker characteristics])
2118
2177
m4_if([$1],
2119
2178
        [], [
2122
2181
    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2123
2182
    *) lt_awk_arg="/^libraries:/" ;;
2124
2183
  esac
2125
 
  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2126
 
  if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
 
2184
  case $host_os in
 
2185
    mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
 
2186
    *) lt_sed_strip_eq="s,=/,/,g" ;;
 
2187
  esac
 
2188
  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
 
2189
  case $lt_search_path_spec in
 
2190
  *\;*)
2127
2191
    # if the path contains ";" then we assume it to be the separator
2128
2192
    # otherwise default to the standard path separator (i.e. ":") - it is
2129
2193
    # assumed that no part of a normal pathname contains ";" but that should
2130
2194
    # okay in the real world where ";" in dirpaths is itself problematic.
2131
 
    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
2132
 
  else
2133
 
    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
2134
 
  fi
 
2195
    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
 
2196
    ;;
 
2197
  *)
 
2198
    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
 
2199
    ;;
 
2200
  esac
2135
2201
  # Ok, now we have the path, separated by spaces, we can step through it
2136
2202
  # and add multilib dir if necessary.
2137
2203
  lt_tmp_lt_search_path_spec=
2144
2210
        lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2145
2211
    fi
2146
2212
  done
2147
 
  lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
 
2213
  lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2148
2214
BEGIN {RS=" "; FS="/|\n";} {
2149
2215
  lt_foo="";
2150
2216
  lt_count=0;
2164
2230
  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2165
2231
  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2166
2232
}'`
2167
 
  sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
 
2233
  # AWK program above erroneously prepends '/' to C:/dos/paths
 
2234
  # for these hosts.
 
2235
  case $host_os in
 
2236
    mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
 
2237
      $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
 
2238
  esac
 
2239
  sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
2168
2240
else
2169
2241
  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2170
2242
fi])
2252
2324
  m68k)
2253
2325
    library_names_spec='$libname.ixlibrary $libname.a'
2254
2326
    # Create ${libname}_ixlibrary.a entries in /sys/libs.
2255
 
    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'
 
2327
    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2256
2328
    ;;
2257
2329
  esac
2258
2330
  ;;
2283
2355
  need_version=no
2284
2356
  need_lib_prefix=no
2285
2357
 
2286
 
  case $GCC,$host_os in
2287
 
  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
 
2358
  case $GCC,$cc_basename in
 
2359
  yes,*)
 
2360
    # gcc
2288
2361
    library_names_spec='$libname.dll.a'
2289
2362
    # DLL is installed to $(libdir)/../bin by postinstall_cmds
2290
2363
    postinstall_cmds='base_file=`basename \${file}`~
2305
2378
    cygwin*)
2306
2379
      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2307
2380
      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2308
 
      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
 
2381
m4_if([$1], [],[
 
2382
      sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
2309
2383
      ;;
2310
2384
    mingw* | cegcc*)
2311
2385
      # MinGW DLLs use traditional 'lib' prefix
2312
2386
      soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2313
 
      sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2314
 
      if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2315
 
        # It is most probably a Windows format PATH printed by
2316
 
        # mingw gcc, but we are running on Cygwin. Gcc prints its search
2317
 
        # path with ; separators, and with drive letters. We can handle the
2318
 
        # drive letters (cygwin fileutils understands them), so leave them,
2319
 
        # especially as we might pass files found there to a mingw objdump,
2320
 
        # which wouldn't understand a cygwinified path. Ahh.
2321
 
        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2322
 
      else
2323
 
        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
2324
 
      fi
2325
2387
      ;;
2326
2388
    pw32*)
2327
2389
      # pw32 DLLs use 'pw' prefix rather than 'lib'
2328
2390
      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2329
2391
      ;;
2330
2392
    esac
 
2393
    dynamic_linker='Win32 ld.exe'
 
2394
    ;;
 
2395
 
 
2396
  *,cl*)
 
2397
    # Native MSVC
 
2398
    libname_spec='$name'
 
2399
    soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
 
2400
    library_names_spec='${libname}.dll.lib'
 
2401
 
 
2402
    case $build_os in
 
2403
    mingw*)
 
2404
      sys_lib_search_path_spec=
 
2405
      lt_save_ifs=$IFS
 
2406
      IFS=';'
 
2407
      for lt_path in $LIB
 
2408
      do
 
2409
        IFS=$lt_save_ifs
 
2410
        # Let DOS variable expansion print the short 8.3 style file name.
 
2411
        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
 
2412
        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
 
2413
      done
 
2414
      IFS=$lt_save_ifs
 
2415
      # Convert to MSYS style.
 
2416
      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
 
2417
      ;;
 
2418
    cygwin*)
 
2419
      # Convert to unix form, then to dos form, then back to unix form
 
2420
      # but this time dos style (no spaces!) so that the unix form looks
 
2421
      # like /cygdrive/c/PROGRA~1:/cygdr...
 
2422
      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
 
2423
      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
 
2424
      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
 
2425
      ;;
 
2426
    *)
 
2427
      sys_lib_search_path_spec="$LIB"
 
2428
      if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
 
2429
        # It is most probably a Windows format PATH.
 
2430
        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
 
2431
      else
 
2432
        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
 
2433
      fi
 
2434
      # FIXME: find the short name or the path components, as spaces are
 
2435
      # common. (e.g. "Program Files" -> "PROGRA~1")
 
2436
      ;;
 
2437
    esac
 
2438
 
 
2439
    # DLL is installed to $(libdir)/../bin by postinstall_cmds
 
2440
    postinstall_cmds='base_file=`basename \${file}`~
 
2441
      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
 
2442
      dldir=$destdir/`dirname \$dlpath`~
 
2443
      test -d \$dldir || mkdir -p \$dldir~
 
2444
      $install_prog $dir/$dlname \$dldir/$dlname'
 
2445
    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
 
2446
      dlpath=$dir/\$dldll~
 
2447
       $RM \$dlpath'
 
2448
    shlibpath_overrides_runpath=yes
 
2449
    dynamic_linker='Win32 link.exe'
2331
2450
    ;;
2332
2451
 
2333
2452
  *)
 
2453
    # Assume MSVC wrapper
2334
2454
    library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
 
2455
    dynamic_linker='Win32 ld.exe'
2335
2456
    ;;
2336
2457
  esac
2337
 
  dynamic_linker='Win32 ld.exe'
2338
2458
  # FIXME: first we should search . and the directory the executable is in
2339
2459
  shlibpath_var=PATH
2340
2460
  ;;
2418
2538
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2419
2539
  soname_spec='${libname}${release}${shared_ext}$major'
2420
2540
  shlibpath_var=LD_LIBRARY_PATH
 
2541
  shlibpath_overrides_runpath=no
 
2542
  hardcode_into_libs=yes
 
2543
  ;;
 
2544
 
 
2545
haiku*)
 
2546
  version_type=linux
 
2547
  need_lib_prefix=no
 
2548
  need_version=no
 
2549
  dynamic_linker="$host_os runtime_loader"
 
2550
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
 
2551
  soname_spec='${libname}${release}${shared_ext}$major'
 
2552
  shlibpath_var=LIBRARY_PATH
 
2553
  shlibpath_overrides_runpath=yes
 
2554
  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
2421
2555
  hardcode_into_libs=yes
2422
2556
  ;;
2423
2557
 
2463
2597
    soname_spec='${libname}${release}${shared_ext}$major'
2464
2598
    ;;
2465
2599
  esac
2466
 
  # HP-UX runs *really* slowly unless shared libraries are mode 555.
 
2600
  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
2467
2601
  postinstall_cmds='chmod 555 $lib'
 
2602
  # or fails outright, so override atomically:
 
2603
  install_override_mode=555
2468
2604
  ;;
2469
2605
 
2470
2606
interix[[3-9]]*)
2531
2667
  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2532
2668
  shlibpath_var=LD_LIBRARY_PATH
2533
2669
  shlibpath_overrides_runpath=no
 
2670
 
2534
2671
  # Some binutils ld are patched to set DT_RUNPATH
2535
 
  save_LDFLAGS=$LDFLAGS
2536
 
  save_libdir=$libdir
2537
 
  eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
2538
 
       LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
2539
 
  AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2540
 
    [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
2541
 
       [shlibpath_overrides_runpath=yes])])
2542
 
  LDFLAGS=$save_LDFLAGS
2543
 
  libdir=$save_libdir
 
2672
  AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
 
2673
    [lt_cv_shlibpath_overrides_runpath=no
 
2674
    save_LDFLAGS=$LDFLAGS
 
2675
    save_libdir=$libdir
 
2676
    eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
 
2677
         LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
 
2678
    AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
 
2679
      [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
 
2680
         [lt_cv_shlibpath_overrides_runpath=yes])])
 
2681
    LDFLAGS=$save_LDFLAGS
 
2682
    libdir=$save_libdir
 
2683
    ])
 
2684
  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
2544
2685
 
2545
2686
  # This implies no fast_install, which is unacceptable.
2546
2687
  # Some rework will be needed to allow for fast_install
2549
2690
 
2550
2691
  # Append ld.so.conf contents to the search path
2551
2692
  if test -f /etc/ld.so.conf; then
2552
 
    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[   ]*hwcap[        ]/d;s/[:,      ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
 
2693
    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[   ]*hwcap[        ]/d;s/[:,      ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
2553
2694
    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2554
2695
  fi
2555
2696
 
2794
2935
    The last name is the one that the linker finds with -lNAME]])
2795
2936
_LT_DECL([], [soname_spec], [1],
2796
2937
    [[The coded name of the library, if different from the real name]])
 
2938
_LT_DECL([], [install_override_mode], [1],
 
2939
    [Permission mode override for installation of shared libraries])
2797
2940
_LT_DECL([], [postinstall_cmds], [2],
2798
2941
    [Command to use after installation of a shared archive])
2799
2942
_LT_DECL([], [postuninstall_cmds], [2],
2906
3049
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2907
3050
m4_require([_LT_DECL_SED])dnl
2908
3051
m4_require([_LT_DECL_EGREP])dnl
 
3052
m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
2909
3053
 
2910
3054
AC_ARG_WITH([gnu-ld],
2911
3055
    [AS_HELP_STRING([--with-gnu-ld],
3027
3171
esac
3028
3172
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3029
3173
case $host_os in
 
3174
  cygwin* | mingw* | pw32* | cegcc*)
 
3175
    if test "$GCC" != yes; then
 
3176
      reload_cmds=false
 
3177
    fi
 
3178
    ;;
3030
3179
  darwin*)
3031
3180
    if test "$GCC" = yes; then
3032
3181
      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3035
3184
    fi
3036
3185
    ;;
3037
3186
esac
3038
 
_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3039
 
_LT_DECL([], [reload_cmds], [2])dnl
 
3187
_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
 
3188
_LT_TAGDECL([], [reload_cmds], [2])dnl
3040
3189
])# _LT_CMD_RELOAD
3041
3190
 
3042
3191
 
3088
3237
  # Base MSYS/MinGW do not provide the 'file' command needed by
3089
3238
  # func_win32_libid shell function, so use a weaker test based on 'objdump',
3090
3239
  # unless we find 'file', for example because we are cross-compiling.
3091
 
  if ( file / ) >/dev/null 2>&1; then
 
3240
  # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
 
3241
  if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
3092
3242
    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3093
3243
    lt_cv_file_magic_cmd='func_win32_libid'
3094
3244
  else
3095
 
    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
 
3245
    # Keep this pattern in sync with the one in func_win32_libid.
 
3246
    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
3096
3247
    lt_cv_file_magic_cmd='$OBJDUMP -f'
3097
3248
  fi
3098
3249
  ;;
3099
3250
 
3100
 
cegcc)
 
3251
cegcc*)
3101
3252
  # use the weaker test based on 'objdump'. See mingw*.
3102
3253
  lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3103
3254
  lt_cv_file_magic_cmd='$OBJDUMP -f'
3127
3278
  lt_cv_deplibs_check_method=pass_all
3128
3279
  ;;
3129
3280
 
 
3281
haiku*)
 
3282
  lt_cv_deplibs_check_method=pass_all
 
3283
  ;;
 
3284
 
3130
3285
hpux10.20* | hpux11*)
3131
3286
  lt_cv_file_magic_cmd=/usr/bin/file
3132
3287
  case $host_cpu in
3135
3290
    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3136
3291
    ;;
3137
3292
  hppa*64*)
3138
 
    [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]']
 
3293
    [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
3139
3294
    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3140
3295
    ;;
3141
3296
  *)
3142
 
    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
 
3297
    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
3143
3298
    lt_cv_file_magic_test_file=/usr/lib/libc.sl
3144
3299
    ;;
3145
3300
  esac
3239
3394
  ;;
3240
3395
esac
3241
3396
])
 
3397
 
 
3398
file_magic_glob=
 
3399
want_nocaseglob=no
 
3400
if test "$build" = "$host"; then
 
3401
  case $host_os in
 
3402
  mingw* | pw32*)
 
3403
    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
 
3404
      want_nocaseglob=yes
 
3405
    else
 
3406
      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
 
3407
    fi
 
3408
    ;;
 
3409
  esac
 
3410
fi
 
3411
 
3242
3412
file_magic_cmd=$lt_cv_file_magic_cmd
3243
3413
deplibs_check_method=$lt_cv_deplibs_check_method
3244
3414
test -z "$deplibs_check_method" && deplibs_check_method=unknown
3246
3416
_LT_DECL([], [deplibs_check_method], [1],
3247
3417
    [Method to check whether dependent libraries are shared objects])
3248
3418
_LT_DECL([], [file_magic_cmd], [1],
3249
 
    [Command to use when deplibs_check_method == "file_magic"])
 
3419
    [Command to use when deplibs_check_method = "file_magic"])
 
3420
_LT_DECL([], [file_magic_glob], [1],
 
3421
    [How to find potential files when deplibs_check_method = "file_magic"])
 
3422
_LT_DECL([], [want_nocaseglob], [1],
 
3423
    [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
3250
3424
])# _LT_CHECK_MAGIC_METHOD
3251
3425
 
3252
3426
 
3303
3477
  NM="$lt_cv_path_NM"
3304
3478
else
3305
3479
  # Didn't find any BSD compatible name lister, look for dumpbin.
3306
 
  AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
 
3480
  if test -n "$DUMPBIN"; then :
 
3481
    # Let the user override the test.
 
3482
  else
 
3483
    AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
 
3484
    case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
 
3485
    *COFF*)
 
3486
      DUMPBIN="$DUMPBIN -symbols"
 
3487
      ;;
 
3488
    *)
 
3489
      DUMPBIN=:
 
3490
      ;;
 
3491
    esac
 
3492
  fi
3307
3493
  AC_SUBST([DUMPBIN])
3308
3494
  if test "$DUMPBIN" != ":"; then
3309
3495
    NM="$DUMPBIN"
3316
3502
AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3317
3503
  [lt_cv_nm_interface="BSD nm"
3318
3504
  echo "int some_variable = 0;" > conftest.$ac_ext
3319
 
  (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
 
3505
  (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3320
3506
  (eval "$ac_compile" 2>conftest.err)
3321
3507
  cat conftest.err >&AS_MESSAGE_LOG_FD
3322
 
  (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
 
3508
  (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3323
3509
  (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3324
3510
  cat conftest.err >&AS_MESSAGE_LOG_FD
3325
 
  (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
 
3511
  (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
3326
3512
  cat conftest.out >&AS_MESSAGE_LOG_FD
3327
3513
  if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3328
3514
    lt_cv_nm_interface="MS dumpbin"
3337
3523
dnl AC_DEFUN([AM_PROG_NM], [])
3338
3524
dnl AC_DEFUN([AC_PROG_NM], [])
3339
3525
 
 
3526
# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
 
3527
# --------------------------------
 
3528
# how to determine the name of the shared library
 
3529
# associated with a specific link library.
 
3530
#  -- PORTME fill in with the dynamic library characteristics
 
3531
m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
 
3532
[m4_require([_LT_DECL_EGREP])
 
3533
m4_require([_LT_DECL_OBJDUMP])
 
3534
m4_require([_LT_DECL_DLLTOOL])
 
3535
AC_CACHE_CHECK([how to associate runtime and link libraries],
 
3536
lt_cv_sharedlib_from_linklib_cmd,
 
3537
[lt_cv_sharedlib_from_linklib_cmd='unknown'
 
3538
 
 
3539
case $host_os in
 
3540
cygwin* | mingw* | pw32* | cegcc*)
 
3541
  # two different shell functions defined in ltmain.sh
 
3542
  # decide which to use based on capabilities of $DLLTOOL
 
3543
  case `$DLLTOOL --help 2>&1` in
 
3544
  *--identify-strict*)
 
3545
    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
 
3546
    ;;
 
3547
  *)
 
3548
    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
 
3549
    ;;
 
3550
  esac
 
3551
  ;;
 
3552
*)
 
3553
  # fallback: assume linklib IS sharedlib
 
3554
  lt_cv_sharedlib_from_linklib_cmd="$ECHO"
 
3555
  ;;
 
3556
esac
 
3557
])
 
3558
sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
 
3559
test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
 
3560
 
 
3561
_LT_DECL([], [sharedlib_from_linklib_cmd], [1],
 
3562
    [Command to associate shared and link libraries])
 
3563
])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
 
3564
 
 
3565
 
 
3566
# _LT_PATH_MANIFEST_TOOL
 
3567
# ----------------------
 
3568
# locate the manifest tool
 
3569
m4_defun([_LT_PATH_MANIFEST_TOOL],
 
3570
[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
 
3571
test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 
3572
AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
 
3573
  [lt_cv_path_mainfest_tool=no
 
3574
  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
 
3575
  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
 
3576
  cat conftest.err >&AS_MESSAGE_LOG_FD
 
3577
  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
 
3578
    lt_cv_path_mainfest_tool=yes
 
3579
  fi
 
3580
  rm -f conftest*])
 
3581
if test "x$lt_cv_path_mainfest_tool" != xyes; then
 
3582
  MANIFEST_TOOL=:
 
3583
fi
 
3584
_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
 
3585
])# _LT_PATH_MANIFEST_TOOL
 
3586
 
3340
3587
 
3341
3588
# LT_LIB_M
3342
3589
# --------
3345
3592
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3346
3593
LIBM=
3347
3594
case $host in
3348
 
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
 
3595
*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
3349
3596
  # These system don't have libm, or don't need it
3350
3597
  ;;
3351
3598
*-ncr-sysv4.3*)
3373
3620
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3374
3621
 
3375
3622
if test "$GCC" = yes; then
3376
 
  _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
 
3623
  case $cc_basename in
 
3624
  nvcc*)
 
3625
    _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
 
3626
  *)
 
3627
    _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
 
3628
  esac
3377
3629
 
3378
3630
  _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
3379
3631
    lt_cv_prog_compiler_rtti_exceptions,
3390
3642
m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
3391
3643
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3392
3644
AC_REQUIRE([AC_PROG_CC])dnl
 
3645
AC_REQUIRE([AC_PROG_AWK])dnl
3393
3646
AC_REQUIRE([LT_PATH_NM])dnl
3394
3647
AC_REQUIRE([LT_PATH_LD])dnl
3395
3648
m4_require([_LT_DECL_SED])dnl
3457
3710
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
3458
3711
 
3459
3712
# Transform an extracted symbol line into symbol name and symbol address
3460
 
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
3461
 
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
 
3713
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
 
3714
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
3462
3715
 
3463
3716
# Handle CRLF in mingw tool chain
3464
3717
opt_cr=
3494
3747
  else
3495
3748
    lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[     ]]\($symcode$symcode*\)[[       ]][[    ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
3496
3749
  fi
 
3750
  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
3497
3751
 
3498
3752
  # Check to see that the pipe works correctly.
3499
3753
  pipe_works=no
3515
3769
  if AC_TRY_EVAL(ac_compile); then
3516
3770
    # Now try to grab the symbols.
3517
3771
    nlist=conftest.nm
3518
 
    if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
 
3772
    if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
3519
3773
      # Try sorting and uniquifying the output.
3520
3774
      if sort "$nlist" | uniq > "$nlist"T; then
3521
3775
        mv -f "$nlist"T "$nlist"
3527
3781
      if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
3528
3782
        if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
3529
3783
          cat <<_LT_EOF > conftest.$ac_ext
 
3784
/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
 
3785
#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
 
3786
/* DATA imports from DLLs on WIN32 con't be const, because runtime
 
3787
   relocations are performed -- see ld's documentation on pseudo-relocs.  */
 
3788
# define LT@&t@_DLSYM_CONST
 
3789
#elif defined(__osf__)
 
3790
/* This system does not cope well with relocations in const data.  */
 
3791
# define LT@&t@_DLSYM_CONST
 
3792
#else
 
3793
# define LT@&t@_DLSYM_CONST const
 
3794
#endif
 
3795
 
3530
3796
#ifdef __cplusplus
3531
3797
extern "C" {
3532
3798
#endif
3538
3804
          cat <<_LT_EOF >> conftest.$ac_ext
3539
3805
 
3540
3806
/* The mapping between symbol names and symbols.  */
3541
 
const struct {
 
3807
LT@&t@_DLSYM_CONST struct {
3542
3808
  const char *name;
3543
3809
  void       *address;
3544
3810
}
3564
3830
_LT_EOF
3565
3831
          # Now try linking the two files.
3566
3832
          mv conftest.$ac_objext conftstm.$ac_objext
3567
 
          lt_save_LIBS="$LIBS"
3568
 
          lt_save_CFLAGS="$CFLAGS"
 
3833
          lt_globsym_save_LIBS=$LIBS
 
3834
          lt_globsym_save_CFLAGS=$CFLAGS
3569
3835
          LIBS="conftstm.$ac_objext"
3570
3836
          CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
3571
3837
          if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
3572
3838
            pipe_works=yes
3573
3839
          fi
3574
 
          LIBS="$lt_save_LIBS"
3575
 
          CFLAGS="$lt_save_CFLAGS"
 
3840
          LIBS=$lt_globsym_save_LIBS
 
3841
          CFLAGS=$lt_globsym_save_CFLAGS
3576
3842
        else
3577
3843
          echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
3578
3844
        fi
3605
3871
  AC_MSG_RESULT(ok)
3606
3872
fi
3607
3873
 
 
3874
# Response file support.
 
3875
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
 
3876
  nm_file_list_spec='@'
 
3877
elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
 
3878
  nm_file_list_spec='@'
 
3879
fi
 
3880
 
3608
3881
_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
3609
3882
    [Take the output of nm and produce a listing of raw symbols and C names])
3610
3883
_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
3615
3888
_LT_DECL([global_symbol_to_c_name_address_lib_prefix],
3616
3889
    [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
3617
3890
    [Transform the output of nm in a C name address pair when lib prefix is needed])
 
3891
_LT_DECL([], [nm_file_list_spec], [1],
 
3892
    [Specify filename containing input files for $NM])
3618
3893
]) # _LT_CMD_GLOBAL_SYMBOLS
3619
3894
 
3620
3895
 
3626
3901
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
3627
3902
_LT_TAGVAR(lt_prog_compiler_static, $1)=
3628
3903
 
3629
 
AC_MSG_CHECKING([for $compiler option to produce PIC])
3630
3904
m4_if([$1], [CXX], [
3631
3905
  # C++ specific cases for pic, static, wl, etc.
3632
3906
  if test "$GXX" = yes; then
3677
3951
      # DJGPP does not support shared libraries at all
3678
3952
      _LT_TAGVAR(lt_prog_compiler_pic, $1)=
3679
3953
      ;;
 
3954
    haiku*)
 
3955
      # PIC is the default for Haiku.
 
3956
      # The "-static" flag exists, but is broken.
 
3957
      _LT_TAGVAR(lt_prog_compiler_static, $1)=
 
3958
      ;;
3680
3959
    interix[[3-9]]*)
3681
3960
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
3682
3961
      # Instead, we relocate shared libraries at runtime.
3726
4005
          ;;
3727
4006
        esac
3728
4007
        ;;
 
4008
      mingw* | cygwin* | os2* | pw32* | cegcc*)
 
4009
        # This hack is so that the source file can tell whether it is being
 
4010
        # built for inclusion in a dll (and should export symbols for example).
 
4011
        m4_if([$1], [GCJ], [],
 
4012
          [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
 
4013
        ;;
3729
4014
      dgux*)
3730
4015
        case $cc_basename in
3731
4016
          ec++*)
3815
4100
            _LT_TAGVAR(lt_prog_compiler_pic, $1)=
3816
4101
            _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
3817
4102
            ;;
3818
 
          xlc* | xlC*)
3819
 
            # IBM XL 8.0 on PPC
 
4103
          xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
 
4104
            # IBM XL 8.0, 9.0 on PPC and BlueGene
3820
4105
            _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3821
4106
            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
3822
4107
            _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
3878
4163
        ;;
3879
4164
      solaris*)
3880
4165
        case $cc_basename in
3881
 
          CC*)
 
4166
          CC* | sunCC*)
3882
4167
            # Sun C++ 4.2, 5.x and Centerline C++
3883
4168
            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
3884
4169
            _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3982
4267
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
3983
4268
      ;;
3984
4269
 
 
4270
    haiku*)
 
4271
      # PIC is the default for Haiku.
 
4272
      # The "-static" flag exists, but is broken.
 
4273
      _LT_TAGVAR(lt_prog_compiler_static, $1)=
 
4274
      ;;
 
4275
 
3985
4276
    hpux*)
3986
4277
      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
3987
4278
      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
4024
4315
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4025
4316
      ;;
4026
4317
    esac
 
4318
 
 
4319
    case $cc_basename in
 
4320
    nvcc*) # Cuda Compiler Driver 2.2
 
4321
      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
 
4322
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC'
 
4323
      ;;
 
4324
    esac
4027
4325
  else
4028
4326
    # PORTME Check for flag to pass linker flags through the system compiler.
4029
4327
    case $host_os in
4087
4385
        _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
4088
4386
        _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
4089
4387
        ;;
4090
 
      pgcc* | pgf77* | pgf90* | pgf95*)
 
4388
      nagfor*)
 
4389
        # NAG Fortran compiler
 
4390
        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
 
4391
        _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
 
4392
        _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
4393
        ;;
 
4394
      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
4091
4395
        # Portland Group compilers (*not* the Pentium gcc compiler,
4092
4396
        # which looks to be a dead project)
4093
4397
        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4099
4403
        # All Alpha code is PIC.
4100
4404
        _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4101
4405
        ;;
4102
 
      xl*)
4103
 
        # IBM XL C 8.0/Fortran 10.1 on PPC
 
4406
      xl* | bgxl* | bgf* | mpixl*)
 
4407
        # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
4104
4408
        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4105
4409
        _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4106
4410
        _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4107
4411
        ;;
4108
4412
      *)
4109
4413
        case `$CC -V 2>&1 | sed 5q` in
 
4414
        *Sun\ F* | *Sun*Fortran*)
 
4415
          # Sun Fortran 8.3 passes all unrecognized flags to the linker
 
4416
          _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
4417
          _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
4418
          _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
 
4419
          ;;
4110
4420
        *Sun\ C*)
4111
4421
          # Sun C 5.9
4112
4422
          _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4113
4423
          _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4114
4424
          _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4115
4425
          ;;
4116
 
        *Sun\ F*)
4117
 
          # Sun Fortran 8.3 passes all unrecognized flags to the linker
4118
 
          _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4119
 
          _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4120
 
          _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4121
 
          ;;
4122
4426
        esac
4123
4427
        ;;
4124
4428
      esac
4149
4453
      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4150
4454
      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4151
4455
      case $cc_basename in
4152
 
      f77* | f90* | f95*)
 
4456
      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
4153
4457
        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4154
4458
      *)
4155
4459
        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4206
4510
    _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4207
4511
    ;;
4208
4512
esac
4209
 
AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4210
 
_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4211
 
        [How to pass a linker flag through the compiler])
 
4513
 
 
4514
AC_CACHE_CHECK([for $compiler option to produce PIC],
 
4515
  [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
 
4516
  [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
 
4517
_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
4212
4518
 
4213
4519
#
4214
4520
# Check to make sure the PIC flag actually works.
4227
4533
_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4228
4534
        [Additional compiler flags for building library objects])
4229
4535
 
 
4536
_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
 
4537
        [How to pass a linker flag through the compiler])
4230
4538
#
4231
4539
# Check to make sure the static flag actually works.
4232
4540
#
4247
4555
m4_defun([_LT_LINKER_SHLIBS],
4248
4556
[AC_REQUIRE([LT_PATH_LD])dnl
4249
4557
AC_REQUIRE([LT_PATH_NM])dnl
 
4558
m4_require([_LT_PATH_MANIFEST_TOOL])dnl
4250
4559
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4251
4560
m4_require([_LT_DECL_EGREP])dnl
4252
4561
m4_require([_LT_DECL_SED])dnl
4255
4564
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4256
4565
m4_if([$1], [CXX], [
4257
4566
  _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
 
4567
  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4258
4568
  case $host_os in
4259
4569
  aix[[4-9]]*)
4260
4570
    # If we're using GNU nm, then we don't want the "-C" option.
4261
4571
    # -C means demangle to AIX nm, but means don't demangle with GNU nm
 
4572
    # Also, AIX nm treats weak defined symbols like other global defined
 
4573
    # symbols, whereas GNU nm marks them as "W".
4262
4574
    if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4263
 
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 
4575
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4264
4576
    else
4265
4577
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4266
4578
    fi
4267
4579
    ;;
4268
4580
  pw32*)
4269
4581
    _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4270
 
  ;;
 
4582
    ;;
4271
4583
  cygwin* | mingw* | cegcc*)
4272
 
    _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4273
 
  ;;
4274
 
  linux* | k*bsd*-gnu)
 
4584
    case $cc_basename in
 
4585
    cl*) ;;
 
4586
    *)
 
4587
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
 
4588
      _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
 
4589
      ;;
 
4590
    esac
 
4591
    ;;
 
4592
  linux* | k*bsd*-gnu | gnu*)
4275
4593
    _LT_TAGVAR(link_all_deplibs, $1)=no
4276
 
  ;;
 
4594
    ;;
4277
4595
  *)
4278
4596
    _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4279
 
  ;;
 
4597
    ;;
4280
4598
  esac
4281
 
  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4282
4599
], [
4283
4600
  runpath_var=
4284
4601
  _LT_TAGVAR(allow_undefined_flag, $1)=
4338
4655
  openbsd*)
4339
4656
    with_gnu_ld=no
4340
4657
    ;;
4341
 
  linux* | k*bsd*-gnu)
 
4658
  linux* | k*bsd*-gnu | gnu*)
4342
4659
    _LT_TAGVAR(link_all_deplibs, $1)=no
4343
4660
    ;;
4344
4661
  esac
4345
4662
 
4346
4663
  _LT_TAGVAR(ld_shlibs, $1)=yes
 
4664
 
 
4665
  # On some targets, GNU ld is compatible enough with the native linker
 
4666
  # that we're better off using the native interface for both.
 
4667
  lt_use_gnu_ld_interface=no
4347
4668
  if test "$with_gnu_ld" = yes; then
 
4669
    case $host_os in
 
4670
      aix*)
 
4671
        # The AIX port of GNU ld has always aspired to compatibility
 
4672
        # with the native linker.  However, as the warning in the GNU ld
 
4673
        # block says, versions before 2.19.5* couldn't really create working
 
4674
        # shared libraries, regardless of the interface used.
 
4675
        case `$LD -v 2>&1` in
 
4676
          *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
 
4677
          *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
 
4678
          *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
 
4679
          *)
 
4680
            lt_use_gnu_ld_interface=yes
 
4681
            ;;
 
4682
        esac
 
4683
        ;;
 
4684
      *)
 
4685
        lt_use_gnu_ld_interface=yes
 
4686
        ;;
 
4687
    esac
 
4688
  fi
 
4689
 
 
4690
  if test "$lt_use_gnu_ld_interface" = yes; then
4348
4691
    # If archive_cmds runs LD, not CC, wlarc should be empty
4349
4692
    wlarc='${wl}'
4350
4693
 
4378
4721
        _LT_TAGVAR(ld_shlibs, $1)=no
4379
4722
        cat <<_LT_EOF 1>&2
4380
4723
 
4381
 
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
 
4724
*** Warning: the GNU linker, at least up to release 2.19, is reported
4382
4725
*** to be unable to reliably create shared libraries on AIX.
4383
4726
*** Therefore, libtool is disabling shared libraries support.  If you
4384
 
*** really care for shared libraries, you may want to modify your PATH
4385
 
*** so that a non-GNU linker is found, and then restart.
 
4727
*** really care for shared libraries, you may want to install binutils
 
4728
*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
 
4729
*** You will then need to restart the configuration process.
4386
4730
 
4387
4731
_LT_EOF
4388
4732
      fi
4418
4762
      # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4419
4763
      # as there is no search path for DLLs.
4420
4764
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
4765
      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
4421
4766
      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4422
4767
      _LT_TAGVAR(always_export_symbols, $1)=no
4423
4768
      _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4424
 
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
 
4769
      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
 
4770
      _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
4425
4771
 
4426
4772
      if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
4427
4773
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4439
4785
      fi
4440
4786
      ;;
4441
4787
 
 
4788
    haiku*)
 
4789
      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4790
      _LT_TAGVAR(link_all_deplibs, $1)=yes
 
4791
      ;;
 
4792
 
4442
4793
    interix[[3-9]]*)
4443
4794
      _LT_TAGVAR(hardcode_direct, $1)=no
4444
4795
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4464
4815
      if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
4465
4816
         && test "$tmp_diet" = no
4466
4817
      then
4467
 
        tmp_addflag=
 
4818
        tmp_addflag=' $pic_flag'
4468
4819
        tmp_sharedflag='-shared'
4469
4820
        case $cc_basename,$host_cpu in
4470
4821
        pgcc*)                          # Portland Group C compiler
4471
 
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
 
4822
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4472
4823
          tmp_addflag=' $pic_flag'
4473
4824
          ;;
4474
 
        pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
4475
 
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
 
4825
        pgf77* | pgf90* | pgf95* | pgfortran*)
 
4826
                                        # Portland Group f77 and f90 compilers
 
4827
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4476
4828
          tmp_addflag=' $pic_flag -Mnomain' ;;
4477
4829
        ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
4478
4830
          tmp_addflag=' -i_dynamic' ;;
4483
4835
        lf95*)                          # Lahey Fortran 8.1
4484
4836
          _LT_TAGVAR(whole_archive_flag_spec, $1)=
4485
4837
          tmp_sharedflag='--shared' ;;
4486
 
        xl[[cC]]*)                      # IBM XL C 8.0 on PPC (deal with xlf below)
 
4838
        xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
4487
4839
          tmp_sharedflag='-qmkshrobj'
4488
4840
          tmp_addflag= ;;
 
4841
        nvcc*)  # Cuda Compiler Driver 2.2
 
4842
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 
4843
          _LT_TAGVAR(compiler_needs_object, $1)=yes
 
4844
          ;;
4489
4845
        esac
4490
4846
        case `$CC -V 2>&1 | sed 5q` in
4491
4847
        *Sun\ C*)                       # Sun C 5.9
4492
 
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
 
4848
          _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4493
4849
          _LT_TAGVAR(compiler_needs_object, $1)=yes
4494
4850
          tmp_sharedflag='-G' ;;
4495
4851
        *Sun\ F*)                       # Sun Fortran 8.3
4505
4861
        fi
4506
4862
 
4507
4863
        case $cc_basename in
4508
 
        xlf*)
 
4864
        xlf* | bgf* | bgxlf* | mpixlf*)
4509
4865
          # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
4510
4866
          _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
4511
4867
          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4512
4868
          _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
4513
 
          _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
 
4869
          _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
4514
4870
          if test "x$supports_anon_versioning" = xyes; then
4515
4871
            _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4516
4872
              cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4517
4873
              echo "local: *; };" >> $output_objdir/$libname.ver~
4518
 
              $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
 
4874
              $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
4519
4875
          fi
4520
4876
          ;;
4521
4877
        esac
4529
4885
        _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
4530
4886
        wlarc=
4531
4887
      else
4532
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4533
 
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
 
4888
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4889
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4534
4890
      fi
4535
4891
      ;;
4536
4892
 
4548
4904
 
4549
4905
_LT_EOF
4550
4906
      elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4551
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4552
 
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
 
4907
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4908
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4553
4909
      else
4554
4910
        _LT_TAGVAR(ld_shlibs, $1)=no
4555
4911
      fi
4595
4951
 
4596
4952
    *)
4597
4953
      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4598
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4599
 
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
 
4954
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
4955
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4600
4956
      else
4601
4957
        _LT_TAGVAR(ld_shlibs, $1)=no
4602
4958
      fi
4636
4992
      else
4637
4993
        # If we're using GNU nm, then we don't want the "-C" option.
4638
4994
        # -C means demangle to AIX nm, but means don't demangle with GNU nm
 
4995
        # Also, AIX nm treats weak defined symbols like other global
 
4996
        # defined symbols, whereas GNU nm marks them as "W".
4639
4997
        if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4640
 
          _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 
4998
          _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4641
4999
        else
4642
5000
          _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4643
5001
        fi
4725
5083
        _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
4726
5084
        # Determine the default libpath from the value encoded in an
4727
5085
        # empty executable.
4728
 
        _LT_SYS_MODULE_PATH_AIX
 
5086
        _LT_SYS_MODULE_PATH_AIX([$1])
4729
5087
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
4730
 
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
 
5088
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
4731
5089
      else
4732
5090
        if test "$host_cpu" = ia64; then
4733
5091
          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
4736
5094
        else
4737
5095
         # Determine the default libpath from the value encoded in an
4738
5096
         # empty executable.
4739
 
         _LT_SYS_MODULE_PATH_AIX
 
5097
         _LT_SYS_MODULE_PATH_AIX([$1])
4740
5098
         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
4741
5099
          # Warning - without using the other run time loading flags,
4742
5100
          # -berok will link without error, but may produce a broken library.
4743
5101
          _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
4744
5102
          _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
4745
 
          # Exported symbols can be pulled into shared objects from archives
4746
 
          _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 
5103
          if test "$with_gnu_ld" = yes; then
 
5104
            # We only use this code for GNU lds that support --whole-archive.
 
5105
            _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
 
5106
          else
 
5107
            # Exported symbols can be pulled into shared objects from archives
 
5108
            _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 
5109
          fi
4747
5110
          _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
4748
5111
          # This is similar to how AIX traditionally builds its shared libraries.
4749
5112
          _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
4775
5138
      # Microsoft Visual C++.
4776
5139
      # hardcode_libdir_flag_spec is actually meaningless, as there is
4777
5140
      # no search path for DLLs.
4778
 
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
4779
 
      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4780
 
      # Tell ltmain to make .lib files, not .a files.
4781
 
      libext=lib
4782
 
      # Tell ltmain to make .dll files, not .so files.
4783
 
      shrext_cmds=".dll"
4784
 
      # FIXME: Setting linknames here is a bad hack.
4785
 
      _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
4786
 
      # The linker will automatically build a .lib file if we build a DLL.
4787
 
      _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
4788
 
      # FIXME: Should let the user specify the lib program.
4789
 
      _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
4790
 
      _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
4791
 
      _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
5141
      case $cc_basename in
 
5142
      cl*)
 
5143
        # Native MSVC
 
5144
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
 
5145
        _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
 
5146
        _LT_TAGVAR(always_export_symbols, $1)=yes
 
5147
        _LT_TAGVAR(file_list_spec, $1)='@'
 
5148
        # Tell ltmain to make .lib files, not .a files.
 
5149
        libext=lib
 
5150
        # Tell ltmain to make .dll files, not .so files.
 
5151
        shrext_cmds=".dll"
 
5152
        # FIXME: Setting linknames here is a bad hack.
 
5153
        _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
 
5154
        _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
 
5155
            sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
 
5156
          else
 
5157
            sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
 
5158
          fi~
 
5159
          $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
 
5160
          linknames='
 
5161
        # The linker will not automatically build a static lib if we build a DLL.
 
5162
        # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
 
5163
        _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
5164
        _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
 
5165
        # Don't use ranlib
 
5166
        _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
 
5167
        _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
 
5168
          lt_tool_outputfile="@TOOL_OUTPUT@"~
 
5169
          case $lt_outputfile in
 
5170
            *.exe|*.EXE) ;;
 
5171
            *)
 
5172
              lt_outputfile="$lt_outputfile.exe"
 
5173
              lt_tool_outputfile="$lt_tool_outputfile.exe"
 
5174
              ;;
 
5175
          esac~
 
5176
          if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
 
5177
            $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
 
5178
            $RM "$lt_outputfile.manifest";
 
5179
          fi'
 
5180
        ;;
 
5181
      *)
 
5182
        # Assume MSVC wrapper
 
5183
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
 
5184
        _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
 
5185
        # Tell ltmain to make .lib files, not .a files.
 
5186
        libext=lib
 
5187
        # Tell ltmain to make .dll files, not .so files.
 
5188
        shrext_cmds=".dll"
 
5189
        # FIXME: Setting linknames here is a bad hack.
 
5190
        _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
 
5191
        # The linker will automatically build a .lib file if we build a DLL.
 
5192
        _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
 
5193
        # FIXME: Should let the user specify the lib program.
 
5194
        _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
 
5195
        _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
5196
        ;;
 
5197
      esac
4792
5198
      ;;
4793
5199
 
4794
5200
    darwin* | rhapsody*)
4826
5232
 
4827
5233
    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
4828
5234
    freebsd* | dragonfly*)
4829
 
      _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
 
5235
      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
4830
5236
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4831
5237
      _LT_TAGVAR(hardcode_direct, $1)=yes
4832
5238
      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4834
5240
 
4835
5241
    hpux9*)
4836
5242
      if test "$GCC" = yes; then
4837
 
        _LT_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'
 
5243
        _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4838
5244
      else
4839
5245
        _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4840
5246
      fi
4849
5255
      ;;
4850
5256
 
4851
5257
    hpux10*)
4852
 
      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
4853
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
5258
      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
 
5259
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
4854
5260
      else
4855
5261
        _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
4856
5262
      fi
4868
5274
      ;;
4869
5275
 
4870
5276
    hpux11*)
4871
 
      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 
5277
      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
4872
5278
        case $host_cpu in
4873
5279
        hppa*64*)
4874
5280
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
4875
5281
          ;;
4876
5282
        ia64*)
4877
 
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 
5283
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
4878
5284
          ;;
4879
5285
        *)
4880
 
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
5286
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
4881
5287
          ;;
4882
5288
        esac
4883
5289
      else
4889
5295
          _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
4890
5296
          ;;
4891
5297
        *)
4892
 
          _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
5298
        m4_if($1, [], [
 
5299
          # Older versions of the 11.00 compiler do not understand -b yet
 
5300
          # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
 
5301
          _LT_LINKER_OPTION([if $CC understands -b],
 
5302
            _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
 
5303
            [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
 
5304
            [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
 
5305
          [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
4893
5306
          ;;
4894
5307
        esac
4895
5308
      fi
4917
5330
 
4918
5331
    irix5* | irix6* | nonstopux*)
4919
5332
      if test "$GCC" = yes; then
4920
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 
5333
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4921
5334
        # Try to use the -exported_symbol ld option, if it does not
4922
5335
        # work, assume that -exports_file does not work either and
4923
5336
        # implicitly export all symbols.
4924
 
        save_LDFLAGS="$LDFLAGS"
4925
 
        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
4926
 
        AC_LINK_IFELSE(int foo(void) {},
4927
 
          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
4928
 
        )
4929
 
        LDFLAGS="$save_LDFLAGS"
 
5337
        # This should be the same for all languages, so no per-tag cache variable.
 
5338
        AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
 
5339
          [lt_cv_irix_exported_symbol],
 
5340
          [save_LDFLAGS="$LDFLAGS"
 
5341
           LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
 
5342
           AC_LINK_IFELSE(
 
5343
             [AC_LANG_SOURCE(
 
5344
                [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
 
5345
                              [C++], [[int foo (void) { return 0; }]],
 
5346
                              [Fortran 77], [[
 
5347
      subroutine foo
 
5348
      end]],
 
5349
                              [Fortran], [[
 
5350
      subroutine foo
 
5351
      end]])])],
 
5352
              [lt_cv_irix_exported_symbol=yes],
 
5353
              [lt_cv_irix_exported_symbol=no])
 
5354
           LDFLAGS="$save_LDFLAGS"])
 
5355
        if test "$lt_cv_irix_exported_symbol" = yes; then
 
5356
          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
 
5357
        fi
4930
5358
      else
4931
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
4932
 
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
 
5359
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 
5360
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
4933
5361
      fi
4934
5362
      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
4935
5363
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4991
5419
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4992
5420
      _LT_TAGVAR(hardcode_minus_L, $1)=yes
4993
5421
      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4994
 
      _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
 
5422
      _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
4995
5423
      _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
4996
5424
      ;;
4997
5425
 
4998
5426
    osf3*)
4999
5427
      if test "$GCC" = yes; then
5000
5428
        _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5001
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 
5429
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5002
5430
      else
5003
5431
        _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5004
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
 
5432
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5005
5433
      fi
5006
5434
      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5007
5435
      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5011
5439
    osf4* | osf5*)      # as osf3* with the addition of -msym flag
5012
5440
      if test "$GCC" = yes; then
5013
5441
        _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5014
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 
5442
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5015
5443
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5016
5444
      else
5017
5445
        _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5018
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
 
5446
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5019
5447
        _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
5020
 
        $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
 
5448
        $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
5021
5449
 
5022
5450
        # Both c and cxx compiler support -rpath directly
5023
5451
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
5030
5458
      _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5031
5459
      if test "$GCC" = yes; then
5032
5460
        wlarc='${wl}'
5033
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
5461
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5034
5462
        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5035
 
          $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
 
5463
          $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5036
5464
      else
5037
5465
        case `$CC -V 2>&1` in
5038
5466
        *"Compilers 5.0"*)
5208
5636
      # Test whether the compiler implicitly links with -lc since on some
5209
5637
      # systems, -lgcc has to come before -lc. If gcc already passes -lc
5210
5638
      # to ld, don't add -lc before -lgcc.
5211
 
      AC_MSG_CHECKING([whether -lc should be explicitly linked in])
5212
 
      $RM conftest*
5213
 
      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
5639
      AC_CACHE_CHECK([whether -lc should be explicitly linked in],
 
5640
        [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
 
5641
        [$RM conftest*
 
5642
        echo "$lt_simple_compile_test_code" > conftest.$ac_ext
5214
5643
 
5215
 
      if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
5216
 
        soname=conftest
5217
 
        lib=conftest
5218
 
        libobjs=conftest.$ac_objext
5219
 
        deplibs=
5220
 
        wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
5221
 
        pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
5222
 
        compiler_flags=-v
5223
 
        linker_flags=-v
5224
 
        verstring=
5225
 
        output_objdir=.
5226
 
        libname=conftest
5227
 
        lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
5228
 
        _LT_TAGVAR(allow_undefined_flag, $1)=
5229
 
        if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
5230
 
        then
5231
 
          _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5232
 
        else
5233
 
          _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5234
 
        fi
5235
 
        _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
5236
 
      else
5237
 
        cat conftest.err 1>&5
5238
 
      fi
5239
 
      $RM conftest*
5240
 
      AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
 
5644
        if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
 
5645
          soname=conftest
 
5646
          lib=conftest
 
5647
          libobjs=conftest.$ac_objext
 
5648
          deplibs=
 
5649
          wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
 
5650
          pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
 
5651
          compiler_flags=-v
 
5652
          linker_flags=-v
 
5653
          verstring=
 
5654
          output_objdir=.
 
5655
          libname=conftest
 
5656
          lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
 
5657
          _LT_TAGVAR(allow_undefined_flag, $1)=
 
5658
          if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
 
5659
          then
 
5660
            lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
 
5661
          else
 
5662
            lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
 
5663
          fi
 
5664
          _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
 
5665
        else
 
5666
          cat conftest.err 1>&5
 
5667
        fi
 
5668
        $RM conftest*
 
5669
        ])
 
5670
      _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
5241
5671
      ;;
5242
5672
    esac
5243
5673
  fi
5302
5732
    to runtime path list])
5303
5733
_LT_TAGDECL([], [link_all_deplibs], [0],
5304
5734
    [Whether libtool must link a program against all its dependency libraries])
5305
 
_LT_TAGDECL([], [fix_srcfile_path], [1],
5306
 
    [Fix the shell variable $srcfile for the compiler])
5307
5735
_LT_TAGDECL([], [always_export_symbols], [0],
5308
5736
    [Set to "yes" if exported symbols are required])
5309
5737
_LT_TAGDECL([], [export_symbols_cmds], [2],
5314
5742
    [Symbols that must always be exported])
5315
5743
_LT_TAGDECL([], [prelink_cmds], [2],
5316
5744
    [Commands necessary for linking programs (against libraries) with templates])
 
5745
_LT_TAGDECL([], [postlink_cmds], [2],
 
5746
    [Commands necessary for finishing linking programs])
5317
5747
_LT_TAGDECL([], [file_list_spec], [1],
5318
5748
    [Specify filename containing input files])
5319
5749
dnl FIXME: Not yet implemented
5403
5833
])# _LT_LANG_C_CONFIG
5404
5834
 
5405
5835
 
5406
 
# _LT_PROG_CXX
5407
 
# ------------
5408
 
# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
5409
 
# compiler, we have our own version here.
5410
 
m4_defun([_LT_PROG_CXX],
5411
 
[
5412
 
pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
5413
 
AC_PROG_CXX
 
5836
# _LT_LANG_CXX_CONFIG([TAG])
 
5837
# --------------------------
 
5838
# Ensure that the configuration variables for a C++ compiler are suitably
 
5839
# defined.  These variables are subsequently used by _LT_CONFIG to write
 
5840
# the compiler configuration to `libtool'.
 
5841
m4_defun([_LT_LANG_CXX_CONFIG],
 
5842
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
 
5843
m4_require([_LT_DECL_EGREP])dnl
 
5844
m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5414
5845
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
5415
5846
    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
5416
5847
    (test "X$CXX" != "Xg++"))) ; then
5418
5849
else
5419
5850
  _lt_caught_CXX_error=yes
5420
5851
fi
5421
 
popdef([AC_MSG_ERROR])
5422
 
])# _LT_PROG_CXX
5423
 
 
5424
 
dnl aclocal-1.4 backwards compatibility:
5425
 
dnl AC_DEFUN([_LT_PROG_CXX], [])
5426
 
 
5427
 
 
5428
 
# _LT_LANG_CXX_CONFIG([TAG])
5429
 
# --------------------------
5430
 
# Ensure that the configuration variables for a C++ compiler are suitably
5431
 
# defined.  These variables are subsequently used by _LT_CONFIG to write
5432
 
# the compiler configuration to `libtool'.
5433
 
m4_defun([_LT_LANG_CXX_CONFIG],
5434
 
[AC_REQUIRE([_LT_PROG_CXX])dnl
5435
 
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5436
 
m4_require([_LT_DECL_EGREP])dnl
5437
5852
 
5438
5853
AC_LANG_PUSH(C++)
5439
5854
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5455
5870
_LT_TAGVAR(module_expsym_cmds, $1)=
5456
5871
_LT_TAGVAR(link_all_deplibs, $1)=unknown
5457
5872
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
5873
_LT_TAGVAR(reload_flag, $1)=$reload_flag
 
5874
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
5458
5875
_LT_TAGVAR(no_undefined_flag, $1)=
5459
5876
_LT_TAGVAR(whole_archive_flag_spec, $1)=
5460
5877
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5486
5903
 
5487
5904
  # Allow CC to be a program name with arguments.
5488
5905
  lt_save_CC=$CC
 
5906
  lt_save_CFLAGS=$CFLAGS
5489
5907
  lt_save_LD=$LD
5490
5908
  lt_save_GCC=$GCC
5491
5909
  GCC=$GXX
5503
5921
  fi
5504
5922
  test -z "${LDCXX+set}" || LD=$LDCXX
5505
5923
  CC=${CXX-"c++"}
 
5924
  CFLAGS=$CXXFLAGS
5506
5925
  compiler=$CC
5507
5926
  _LT_TAGVAR(compiler, $1)=$CC
5508
5927
  _LT_CC_BASENAME([$compiler])
5524
5943
      # Check if GNU C++ uses GNU ld as the underlying linker, since the
5525
5944
      # archiving commands below assume that GNU ld is being used.
5526
5945
      if test "$with_gnu_ld" = yes; then
5527
 
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
5528
 
        _LT_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'
 
5946
        _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
5947
        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5529
5948
 
5530
5949
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5531
5950
        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5557
5976
      # Commands to make compiler produce verbose output that lists
5558
5977
      # what "hidden" libraries, object files and flags are used when
5559
5978
      # linking a shared library.
5560
 
      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
 
5979
      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
5561
5980
 
5562
5981
    else
5563
5982
      GXX=no
5666
6085
          _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5667
6086
          # Determine the default libpath from the value encoded in an empty
5668
6087
          # executable.
5669
 
          _LT_SYS_MODULE_PATH_AIX
 
6088
          _LT_SYS_MODULE_PATH_AIX([$1])
5670
6089
          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5671
6090
 
5672
 
          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
 
6091
          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5673
6092
        else
5674
6093
          if test "$host_cpu" = ia64; then
5675
6094
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5678
6097
          else
5679
6098
            # Determine the default libpath from the value encoded in an
5680
6099
            # empty executable.
5681
 
            _LT_SYS_MODULE_PATH_AIX
 
6100
            _LT_SYS_MODULE_PATH_AIX([$1])
5682
6101
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5683
6102
            # Warning - without using the other run time loading flags,
5684
6103
            # -berok will link without error, but may produce a broken library.
5685
6104
            _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5686
6105
            _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5687
 
            # Exported symbols can be pulled into shared objects from archives
5688
 
            _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 
6106
            if test "$with_gnu_ld" = yes; then
 
6107
              # We only use this code for GNU lds that support --whole-archive.
 
6108
              _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
 
6109
            else
 
6110
              # Exported symbols can be pulled into shared objects from archives
 
6111
              _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 
6112
            fi
5689
6113
            _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5690
6114
            # This is similar to how AIX traditionally builds its shared
5691
6115
            # libraries.
5715
6139
        ;;
5716
6140
 
5717
6141
      cygwin* | mingw* | pw32* | cegcc*)
5718
 
        # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5719
 
        # as there is no search path for DLLs.
5720
 
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5721
 
        _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5722
 
        _LT_TAGVAR(always_export_symbols, $1)=no
5723
 
        _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
6142
        case $GXX,$cc_basename in
 
6143
        ,cl* | no,cl*)
 
6144
          # Native MSVC
 
6145
          # hardcode_libdir_flag_spec is actually meaningless, as there is
 
6146
          # no search path for DLLs.
 
6147
          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
 
6148
          _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6149
          _LT_TAGVAR(always_export_symbols, $1)=yes
 
6150
          _LT_TAGVAR(file_list_spec, $1)='@'
 
6151
          # Tell ltmain to make .lib files, not .a files.
 
6152
          libext=lib
 
6153
          # Tell ltmain to make .dll files, not .so files.
 
6154
          shrext_cmds=".dll"
 
6155
          # FIXME: Setting linknames here is a bad hack.
 
6156
          _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
 
6157
          _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
 
6158
              $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
 
6159
            else
 
6160
              $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
 
6161
            fi~
 
6162
            $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
 
6163
            linknames='
 
6164
          # The linker will not automatically build a static lib if we build a DLL.
 
6165
          # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
 
6166
          _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
6167
          # Don't use ranlib
 
6168
          _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
 
6169
          _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
 
6170
            lt_tool_outputfile="@TOOL_OUTPUT@"~
 
6171
            case $lt_outputfile in
 
6172
              *.exe|*.EXE) ;;
 
6173
              *)
 
6174
                lt_outputfile="$lt_outputfile.exe"
 
6175
                lt_tool_outputfile="$lt_tool_outputfile.exe"
 
6176
                ;;
 
6177
            esac~
 
6178
            func_to_tool_file "$lt_outputfile"~
 
6179
            if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
 
6180
              $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
 
6181
              $RM "$lt_outputfile.manifest";
 
6182
            fi'
 
6183
          ;;
 
6184
        *)
 
6185
          # g++
 
6186
          # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
 
6187
          # as there is no search path for DLLs.
 
6188
          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 
6189
          _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
 
6190
          _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
 
6191
          _LT_TAGVAR(always_export_symbols, $1)=no
 
6192
          _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5724
6193
 
5725
 
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5726
 
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5727
 
          # If the export-symbols file already is a .def file (1st line
5728
 
          # is EXPORTS), use it as is; otherwise, prepend...
5729
 
          _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5730
 
            cp $export_symbols $output_objdir/$soname.def;
5731
 
          else
5732
 
            echo EXPORTS > $output_objdir/$soname.def;
5733
 
            cat $export_symbols >> $output_objdir/$soname.def;
5734
 
          fi~
5735
 
          $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5736
 
        else
5737
 
          _LT_TAGVAR(ld_shlibs, $1)=no
5738
 
        fi
5739
 
        ;;
 
6194
          if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
 
6195
            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
 
6196
            # If the export-symbols file already is a .def file (1st line
 
6197
            # is EXPORTS), use it as is; otherwise, prepend...
 
6198
            _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
 
6199
              cp $export_symbols $output_objdir/$soname.def;
 
6200
            else
 
6201
              echo EXPORTS > $output_objdir/$soname.def;
 
6202
              cat $export_symbols >> $output_objdir/$soname.def;
 
6203
            fi~
 
6204
            $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
 
6205
          else
 
6206
            _LT_TAGVAR(ld_shlibs, $1)=no
 
6207
          fi
 
6208
          ;;
 
6209
        esac
 
6210
        ;;
5740
6211
      darwin* | rhapsody*)
5741
6212
        _LT_DARWIN_LINKER_FEATURES($1)
5742
6213
        ;;
5778
6249
      gnu*)
5779
6250
        ;;
5780
6251
 
 
6252
      haiku*)
 
6253
        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
6254
        _LT_TAGVAR(link_all_deplibs, $1)=yes
 
6255
        ;;
 
6256
 
5781
6257
      hpux9*)
5782
6258
        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5783
6259
        _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5802
6278
            # explicitly linking system object files so we need to strip them
5803
6279
            # from the output so that they don't get included in the library
5804
6280
            # dependencies.
5805
 
            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
 
6281
            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
5806
6282
            ;;
5807
6283
          *)
5808
6284
            if test "$GXX" = yes; then
5809
 
              _LT_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'
 
6285
              _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5810
6286
            else
5811
6287
              # FIXME: insert proper C++ library support
5812
6288
              _LT_TAGVAR(ld_shlibs, $1)=no
5867
6343
            # explicitly linking system object files so we need to strip them
5868
6344
            # from the output so that they don't get included in the library
5869
6345
            # dependencies.
5870
 
            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 "X$list" | $Xsed'
 
6346
            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
5871
6347
            ;;
5872
6348
          *)
5873
6349
            if test "$GXX" = yes; then
5877
6353
                    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5878
6354
                    ;;
5879
6355
                  ia64*)
5880
 
                    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
6356
                    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5881
6357
                    ;;
5882
6358
                  *)
5883
 
                    _LT_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'
 
6359
                    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5884
6360
                    ;;
5885
6361
                esac
5886
6362
              fi
5910
6386
        case $cc_basename in
5911
6387
          CC*)
5912
6388
            # SGI C++
5913
 
            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
 
6389
            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5914
6390
 
5915
6391
            # Archives containing C++ object files must be created using
5916
6392
            # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
5921
6397
          *)
5922
6398
            if test "$GXX" = yes; then
5923
6399
              if test "$with_gnu_ld" = no; then
5924
 
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 
6400
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5925
6401
              else
5926
 
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
 
6402
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
5927
6403
              fi
5928
6404
            fi
5929
6405
            _LT_TAGVAR(link_all_deplibs, $1)=yes
5952
6428
            # explicitly linking system object files so we need to strip them
5953
6429
            # from the output so that they don't get included in the library
5954
6430
            # dependencies.
5955
 
            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 "X$list" | $Xsed'
 
6431
            output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
5956
6432
 
5957
6433
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5958
6434
            _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5989
6465
          pgCC* | pgcpp*)
5990
6466
            # Portland Group C++ compiler
5991
6467
            case `$CC -V` in
5992
 
            *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*)
 
6468
            *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
5993
6469
              _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
5994
6470
                rm -rf $tpldir~
5995
6471
                $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
5996
 
                compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
 
6472
                compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
5997
6473
              _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
5998
6474
                rm -rf $tpldir~
5999
6475
                $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6000
 
                $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
 
6476
                $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
6001
6477
                $RANLIB $oldlib'
6002
6478
              _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6003
6479
                rm -rf $tpldir~
6004
6480
                $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6005
 
                $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
 
6481
                $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6006
6482
              _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6007
6483
                rm -rf $tpldir~
6008
6484
                $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6009
 
                $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
 
6485
                $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6010
6486
              ;;
6011
 
            *) # Version 6 will use weak symbols
 
6487
            *) # Version 6 and above use weak symbols
6012
6488
              _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6013
6489
              _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6014
6490
              ;;
6016
6492
 
6017
6493
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6018
6494
            _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6019
 
            _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
 
6495
            _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6020
6496
            ;;
6021
6497
          cxx*)
6022
6498
            # Compaq C++
6035
6511
            # explicitly linking system object files so we need to strip them
6036
6512
            # from the output so that they don't get included in the library
6037
6513
            # dependencies.
6038
 
            output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "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 "X$list" | $Xsed'
 
6514
            output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
6039
6515
            ;;
6040
 
          xl*)
 
6516
          xl* | mpixl* | bgxl*)
6041
6517
            # IBM XL 8.0 on PPC, with GNU ld
6042
6518
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6043
6519
            _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6057
6533
              _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6058
6534
              _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
6059
6535
              _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6060
 
              _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
 
6536
              _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6061
6537
              _LT_TAGVAR(compiler_needs_object, $1)=yes
6062
6538
 
6063
6539
              # Not sure whether something based on
6064
6540
              # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
6065
6541
              # would be better.
6066
 
              output_verbose_link_cmd='echo'
 
6542
              output_verbose_link_cmd='func_echo_all'
6067
6543
 
6068
6544
              # Archives containing C++ object files must be created using
6069
6545
              # "CC -xar", where "CC" is the Sun C++ compiler.  This is
6132
6608
            _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6133
6609
            _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6134
6610
          fi
6135
 
          output_verbose_link_cmd=echo
 
6611
          output_verbose_link_cmd=func_echo_all
6136
6612
        else
6137
6613
          _LT_TAGVAR(ld_shlibs, $1)=no
6138
6614
        fi
6167
6643
            case $host in
6168
6644
              osf3*)
6169
6645
                _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6170
 
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
 
6646
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6171
6647
                _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6172
6648
                ;;
6173
6649
              *)
6174
6650
                _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6175
 
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
 
6651
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6176
6652
                _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
6177
6653
                  echo "-hidden">> $lib.exp~
6178
 
                  $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 "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
 
6654
                  $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~
6179
6655
                  $RM $lib.exp'
6180
6656
                _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6181
6657
                ;;
6191
6667
            # explicitly linking system object files so we need to strip them
6192
6668
            # from the output so that they don't get included in the library
6193
6669
            # dependencies.
6194
 
            output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "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 "X$list" | $Xsed'
 
6670
            output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6195
6671
            ;;
6196
6672
          *)
6197
6673
            if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6198
6674
              _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6199
6675
              case $host in
6200
6676
                osf3*)
6201
 
                  _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 
6677
                  _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6202
6678
                  ;;
6203
6679
                *)
6204
 
                  _LT_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" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 
6680
                  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6205
6681
                  ;;
6206
6682
              esac
6207
6683
 
6211
6687
              # Commands to make compiler produce verbose output that lists
6212
6688
              # what "hidden" libraries, object files and flags are used when
6213
6689
              # linking a shared library.
6214
 
              output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
 
6690
              output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6215
6691
 
6216
6692
            else
6217
6693
              # FIXME: insert proper C++ library support
6247
6723
 
6248
6724
      solaris*)
6249
6725
        case $cc_basename in
6250
 
          CC*)
 
6726
          CC* | sunCC*)
6251
6727
            # Sun C++ 4.2, 5.x and Centerline C++
6252
6728
            _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
6253
6729
            _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6268
6744
            esac
6269
6745
            _LT_TAGVAR(link_all_deplibs, $1)=yes
6270
6746
 
6271
 
            output_verbose_link_cmd='echo'
 
6747
            output_verbose_link_cmd='func_echo_all'
6272
6748
 
6273
6749
            # Archives containing C++ object files must be created using
6274
6750
            # "CC -xar", where "CC" is the Sun C++ compiler.  This is
6288
6764
            if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6289
6765
              _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
6290
6766
              if $CC --version | $GREP -v '^2\.7' > /dev/null; then
6291
 
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
 
6767
                _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6292
6768
                _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6293
 
                  $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
 
6769
                  $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6294
6770
 
6295
6771
                # Commands to make compiler produce verbose output that lists
6296
6772
                # what "hidden" libraries, object files and flags are used when
6297
6773
                # linking a shared library.
6298
 
                output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
 
6774
                output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6299
6775
              else
6300
6776
                # g++ 2.7 appears to require `-G' NOT `-shared' on this
6301
6777
                # platform.
6306
6782
                # Commands to make compiler produce verbose output that lists
6307
6783
                # what "hidden" libraries, object files and flags are used when
6308
6784
                # linking a shared library.
6309
 
                output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
 
6785
                output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6310
6786
              fi
6311
6787
 
6312
6788
              _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
6360
6836
          CC*)
6361
6837
            _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6362
6838
            _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6839
            _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
 
6840
              '"$_LT_TAGVAR(old_archive_cmds, $1)"
 
6841
            _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
 
6842
              '"$_LT_TAGVAR(reload_cmds, $1)"
6363
6843
            ;;
6364
6844
          *)
6365
6845
            _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6415
6895
  fi # test -n "$compiler"
6416
6896
 
6417
6897
  CC=$lt_save_CC
 
6898
  CFLAGS=$lt_save_CFLAGS
6418
6899
  LDCXX=$LD
6419
6900
  LD=$lt_save_LD
6420
6901
  GCC=$lt_save_GCC
6429
6910
])# _LT_LANG_CXX_CONFIG
6430
6911
 
6431
6912
 
 
6913
# _LT_FUNC_STRIPNAME_CNF
 
6914
# ----------------------
 
6915
# func_stripname_cnf prefix suffix name
 
6916
# strip PREFIX and SUFFIX off of NAME.
 
6917
# PREFIX and SUFFIX must not contain globbing or regex special
 
6918
# characters, hashes, percent signs, but SUFFIX may contain a leading
 
6919
# dot (in which case that matches only a dot).
 
6920
#
 
6921
# This function is identical to the (non-XSI) version of func_stripname,
 
6922
# except this one can be used by m4 code that may be executed by configure,
 
6923
# rather than the libtool script.
 
6924
m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
 
6925
AC_REQUIRE([_LT_DECL_SED])
 
6926
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
 
6927
func_stripname_cnf ()
 
6928
{
 
6929
  case ${2} in
 
6930
  .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
 
6931
  *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
 
6932
  esac
 
6933
} # func_stripname_cnf
 
6934
])# _LT_FUNC_STRIPNAME_CNF
 
6935
 
6432
6936
# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
6433
6937
# ---------------------------------
6434
6938
# Figure out "hidden" library dependencies from verbose
6437
6941
# objects, libraries and library flags.
6438
6942
m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
6439
6943
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
 
6944
AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
6440
6945
# Dependencies to place before and after the object being linked:
6441
6946
_LT_TAGVAR(predep_objects, $1)=
6442
6947
_LT_TAGVAR(postdep_objects, $1)=
6487
6992
};
6488
6993
_LT_EOF
6489
6994
])
 
6995
 
 
6996
_lt_libdeps_save_CFLAGS=$CFLAGS
 
6997
case "$CC $CFLAGS " in #(
 
6998
*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
 
6999
*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
 
7000
esac
 
7001
 
6490
7002
dnl Parse the compiler output and extract the necessary
6491
7003
dnl objects, libraries and library flags.
6492
7004
if AC_TRY_EVAL(ac_compile); then
6498
7010
  pre_test_object_deps_done=no
6499
7011
 
6500
7012
  for p in `eval "$output_verbose_link_cmd"`; do
6501
 
    case $p in
 
7013
    case ${prev}${p} in
6502
7014
 
6503
7015
    -L* | -R* | -l*)
6504
7016
       # Some compilers place space between "-{L,R}" and the path.
6507
7019
          test $p = "-R"; then
6508
7020
         prev=$p
6509
7021
         continue
6510
 
       else
6511
 
         prev=
6512
7022
       fi
6513
7023
 
 
7024
       # Expand the sysroot to ease extracting the directories later.
 
7025
       if test -z "$prev"; then
 
7026
         case $p in
 
7027
         -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
 
7028
         -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
 
7029
         -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
 
7030
         esac
 
7031
       fi
 
7032
       case $p in
 
7033
       =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
 
7034
       esac
6514
7035
       if test "$pre_test_object_deps_done" = no; then
6515
 
         case $p in
6516
 
         -L* | -R*)
 
7036
         case ${prev} in
 
7037
         -L | -R)
6517
7038
           # Internal compiler library paths should come after those
6518
7039
           # provided the user.  The postdeps already come after the
6519
7040
           # user supplied libs so there is no need to process them.
6533
7054
           _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
6534
7055
         fi
6535
7056
       fi
 
7057
       prev=
6536
7058
       ;;
6537
7059
 
 
7060
    *.lto.$objext) ;; # Ignore GCC LTO objects
6538
7061
    *.$objext)
6539
7062
       # This assumes that the test object file only shows up
6540
7063
       # once in the compiler output.
6570
7093
fi
6571
7094
 
6572
7095
$RM -f confest.$objext
 
7096
CFLAGS=$_lt_libdeps_save_CFLAGS
6573
7097
 
6574
7098
# PORTME: override above test on systems where it is broken
6575
7099
m4_if([$1], [CXX],
6606
7130
 
6607
7131
solaris*)
6608
7132
  case $cc_basename in
6609
 
  CC*)
 
7133
  CC* | sunCC*)
6610
7134
    # The more standards-conforming stlport4 library is
6611
7135
    # incompatible with the Cstd library. Avoid specifying
6612
7136
    # it if it's in CXXFLAGS. Ignore libCrun as
6650
7174
])# _LT_SYS_HIDDEN_LIBDEPS
6651
7175
 
6652
7176
 
6653
 
# _LT_PROG_F77
6654
 
# ------------
6655
 
# Since AC_PROG_F77 is broken, in that it returns the empty string
6656
 
# if there is no fortran compiler, we have our own version here.
6657
 
m4_defun([_LT_PROG_F77],
6658
 
[
6659
 
pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
6660
 
AC_PROG_F77
6661
 
if test -z "$F77" || test "X$F77" = "Xno"; then
6662
 
  _lt_disable_F77=yes
6663
 
fi
6664
 
popdef([AC_MSG_ERROR])
6665
 
])# _LT_PROG_F77
6666
 
 
6667
 
dnl aclocal-1.4 backwards compatibility:
6668
 
dnl AC_DEFUN([_LT_PROG_F77], [])
6669
 
 
6670
 
 
6671
7177
# _LT_LANG_F77_CONFIG([TAG])
6672
7178
# --------------------------
6673
7179
# Ensure that the configuration variables for a Fortran 77 compiler are
6674
7180
# suitably defined.  These variables are subsequently used by _LT_CONFIG
6675
7181
# to write the compiler configuration to `libtool'.
6676
7182
m4_defun([_LT_LANG_F77_CONFIG],
6677
 
[AC_REQUIRE([_LT_PROG_F77])dnl
6678
 
AC_LANG_PUSH(Fortran 77)
 
7183
[AC_LANG_PUSH(Fortran 77)
 
7184
if test -z "$F77" || test "X$F77" = "Xno"; then
 
7185
  _lt_disable_F77=yes
 
7186
fi
6679
7187
 
6680
7188
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6681
7189
_LT_TAGVAR(allow_undefined_flag, $1)=
6694
7202
_LT_TAGVAR(module_expsym_cmds, $1)=
6695
7203
_LT_TAGVAR(link_all_deplibs, $1)=unknown
6696
7204
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
7205
_LT_TAGVAR(reload_flag, $1)=$reload_flag
 
7206
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6697
7207
_LT_TAGVAR(no_undefined_flag, $1)=
6698
7208
_LT_TAGVAR(whole_archive_flag_spec, $1)=
6699
7209
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6733
7243
  # Allow CC to be a program name with arguments.
6734
7244
  lt_save_CC="$CC"
6735
7245
  lt_save_GCC=$GCC
 
7246
  lt_save_CFLAGS=$CFLAGS
6736
7247
  CC=${F77-"f77"}
 
7248
  CFLAGS=$FFLAGS
6737
7249
  compiler=$CC
6738
7250
  _LT_TAGVAR(compiler, $1)=$CC
6739
7251
  _LT_CC_BASENAME([$compiler])
6787
7299
 
6788
7300
  GCC=$lt_save_GCC
6789
7301
  CC="$lt_save_CC"
 
7302
  CFLAGS="$lt_save_CFLAGS"
6790
7303
fi # test "$_lt_disable_F77" != yes
6791
7304
 
6792
7305
AC_LANG_POP
6793
7306
])# _LT_LANG_F77_CONFIG
6794
7307
 
6795
7308
 
6796
 
# _LT_PROG_FC
6797
 
# -----------
6798
 
# Since AC_PROG_FC is broken, in that it returns the empty string
6799
 
# if there is no fortran compiler, we have our own version here.
6800
 
m4_defun([_LT_PROG_FC],
6801
 
[
6802
 
pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
6803
 
AC_PROG_FC
6804
 
if test -z "$FC" || test "X$FC" = "Xno"; then
6805
 
  _lt_disable_FC=yes
6806
 
fi
6807
 
popdef([AC_MSG_ERROR])
6808
 
])# _LT_PROG_FC
6809
 
 
6810
 
dnl aclocal-1.4 backwards compatibility:
6811
 
dnl AC_DEFUN([_LT_PROG_FC], [])
6812
 
 
6813
 
 
6814
7309
# _LT_LANG_FC_CONFIG([TAG])
6815
7310
# -------------------------
6816
7311
# Ensure that the configuration variables for a Fortran compiler are
6817
7312
# suitably defined.  These variables are subsequently used by _LT_CONFIG
6818
7313
# to write the compiler configuration to `libtool'.
6819
7314
m4_defun([_LT_LANG_FC_CONFIG],
6820
 
[AC_REQUIRE([_LT_PROG_FC])dnl
6821
 
AC_LANG_PUSH(Fortran)
 
7315
[AC_LANG_PUSH(Fortran)
 
7316
 
 
7317
if test -z "$FC" || test "X$FC" = "Xno"; then
 
7318
  _lt_disable_FC=yes
 
7319
fi
6822
7320
 
6823
7321
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6824
7322
_LT_TAGVAR(allow_undefined_flag, $1)=
6837
7335
_LT_TAGVAR(module_expsym_cmds, $1)=
6838
7336
_LT_TAGVAR(link_all_deplibs, $1)=unknown
6839
7337
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
7338
_LT_TAGVAR(reload_flag, $1)=$reload_flag
 
7339
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6840
7340
_LT_TAGVAR(no_undefined_flag, $1)=
6841
7341
_LT_TAGVAR(whole_archive_flag_spec, $1)=
6842
7342
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6876
7376
  # Allow CC to be a program name with arguments.
6877
7377
  lt_save_CC="$CC"
6878
7378
  lt_save_GCC=$GCC
 
7379
  lt_save_CFLAGS=$CFLAGS
6879
7380
  CC=${FC-"f95"}
 
7381
  CFLAGS=$FCFLAGS
6880
7382
  compiler=$CC
6881
7383
  GCC=$ac_cv_fc_compiler_gnu
6882
7384
 
6932
7434
  fi # test -n "$compiler"
6933
7435
 
6934
7436
  GCC=$lt_save_GCC
6935
 
  CC="$lt_save_CC"
 
7437
  CC=$lt_save_CC
 
7438
  CFLAGS=$lt_save_CFLAGS
6936
7439
fi # test "$_lt_disable_FC" != yes
6937
7440
 
6938
7441
AC_LANG_POP
6969
7472
_LT_LINKER_BOILERPLATE
6970
7473
 
6971
7474
# Allow CC to be a program name with arguments.
6972
 
lt_save_CC="$CC"
 
7475
lt_save_CC=$CC
 
7476
lt_save_CFLAGS=$CFLAGS
6973
7477
lt_save_GCC=$GCC
6974
7478
GCC=yes
6975
7479
CC=${GCJ-"gcj"}
 
7480
CFLAGS=$GCJFLAGS
6976
7481
compiler=$CC
6977
7482
_LT_TAGVAR(compiler, $1)=$CC
6978
7483
_LT_TAGVAR(LD, $1)="$LD"
6982
7487
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6983
7488
 
6984
7489
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
 
7490
_LT_TAGVAR(reload_flag, $1)=$reload_flag
 
7491
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6985
7492
 
6986
7493
if test -n "$compiler"; then
6987
7494
  _LT_COMPILER_NO_RTTI($1)
6997
7504
AC_LANG_RESTORE
6998
7505
 
6999
7506
GCC=$lt_save_GCC
7000
 
CC="$lt_save_CC"
 
7507
CC=$lt_save_CC
 
7508
CFLAGS=$lt_save_CFLAGS
7001
7509
])# _LT_LANG_GCJ_CONFIG
7002
7510
 
7003
7511
 
7032
7540
 
7033
7541
# Allow CC to be a program name with arguments.
7034
7542
lt_save_CC="$CC"
 
7543
lt_save_CFLAGS=$CFLAGS
7035
7544
lt_save_GCC=$GCC
7036
7545
GCC=
7037
7546
CC=${RC-"windres"}
 
7547
CFLAGS=
7038
7548
compiler=$CC
7039
7549
_LT_TAGVAR(compiler, $1)=$CC
7040
7550
_LT_CC_BASENAME([$compiler])
7047
7557
 
7048
7558
GCC=$lt_save_GCC
7049
7559
AC_LANG_RESTORE
7050
 
CC="$lt_save_CC"
 
7560
CC=$lt_save_CC
 
7561
CFLAGS=$lt_save_CFLAGS
7051
7562
])# _LT_LANG_RC_CONFIG
7052
7563
 
7053
7564
 
7106
7617
AC_SUBST([OBJDUMP])
7107
7618
])
7108
7619
 
 
7620
# _LT_DECL_DLLTOOL
 
7621
# ----------------
 
7622
# Ensure DLLTOOL variable is set.
 
7623
m4_defun([_LT_DECL_DLLTOOL],
 
7624
[AC_CHECK_TOOL(DLLTOOL, dlltool, false)
 
7625
test -z "$DLLTOOL" && DLLTOOL=dlltool
 
7626
_LT_DECL([], [DLLTOOL], [1], [DLL creation program])
 
7627
AC_SUBST([DLLTOOL])
 
7628
])
7109
7629
 
7110
7630
# _LT_DECL_SED
7111
7631
# ------------
7197
7717
# Try some XSI features
7198
7718
xsi_shell=no
7199
7719
( _lt_dummy="a/b/c"
7200
 
  test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
7201
 
      = c,a/b,, \
 
7720
  test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
 
7721
      = c,a/b,b/c, \
7202
7722
    && eval 'test $(( 1 + 1 )) -eq 2 \
7203
7723
    && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7204
7724
  && xsi_shell=yes
7237
7757
])# _LT_CHECK_SHELL_FEATURES
7238
7758
 
7239
7759
 
7240
 
# _LT_PROG_XSI_SHELLFNS
7241
 
# ---------------------
7242
 
# Bourne and XSI compatible variants of some useful shell functions.
7243
 
m4_defun([_LT_PROG_XSI_SHELLFNS],
7244
 
[case $xsi_shell in
7245
 
  yes)
7246
 
    cat << \_LT_EOF >> "$cfgfile"
7247
 
 
7248
 
# func_dirname file append nondir_replacement
7249
 
# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
7250
 
# otherwise set result to NONDIR_REPLACEMENT.
7251
 
func_dirname ()
7252
 
{
7253
 
  case ${1} in
7254
 
    */*) func_dirname_result="${1%/*}${2}" ;;
7255
 
    *  ) func_dirname_result="${3}" ;;
7256
 
  esac
7257
 
}
7258
 
 
7259
 
# func_basename file
7260
 
func_basename ()
7261
 
{
7262
 
  func_basename_result="${1##*/}"
7263
 
}
7264
 
 
7265
 
# func_dirname_and_basename file append nondir_replacement
7266
 
# perform func_basename and func_dirname in a single function
7267
 
# call:
7268
 
#   dirname:  Compute the dirname of FILE.  If nonempty,
7269
 
#             add APPEND to the result, otherwise set result
7270
 
#             to NONDIR_REPLACEMENT.
7271
 
#             value returned in "$func_dirname_result"
7272
 
#   basename: Compute filename of FILE.
7273
 
#             value retuned in "$func_basename_result"
7274
 
# Implementation must be kept synchronized with func_dirname
7275
 
# and func_basename. For efficiency, we do not delegate to
7276
 
# those functions but instead duplicate the functionality here.
7277
 
func_dirname_and_basename ()
7278
 
{
7279
 
  case ${1} in
7280
 
    */*) func_dirname_result="${1%/*}${2}" ;;
7281
 
    *  ) func_dirname_result="${3}" ;;
7282
 
  esac
7283
 
  func_basename_result="${1##*/}"
7284
 
}
7285
 
 
7286
 
# func_stripname prefix suffix name
7287
 
# strip PREFIX and SUFFIX off of NAME.
7288
 
# PREFIX and SUFFIX must not contain globbing or regex special
7289
 
# characters, hashes, percent signs, but SUFFIX may contain a leading
7290
 
# dot (in which case that matches only a dot).
7291
 
func_stripname ()
7292
 
{
7293
 
  # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
7294
 
  # positional parameters, so assign one to ordinary parameter first.
7295
 
  func_stripname_result=${3}
7296
 
  func_stripname_result=${func_stripname_result#"${1}"}
7297
 
  func_stripname_result=${func_stripname_result%"${2}"}
7298
 
}
7299
 
 
7300
 
# func_opt_split
7301
 
func_opt_split ()
7302
 
{
7303
 
  func_opt_split_opt=${1%%=*}
7304
 
  func_opt_split_arg=${1#*=}
7305
 
}
7306
 
 
7307
 
# func_lo2o object
7308
 
func_lo2o ()
7309
 
{
7310
 
  case ${1} in
7311
 
    *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
7312
 
    *)    func_lo2o_result=${1} ;;
7313
 
  esac
7314
 
}
7315
 
 
7316
 
# func_xform libobj-or-source
7317
 
func_xform ()
7318
 
{
7319
 
  func_xform_result=${1%.*}.lo
7320
 
}
7321
 
 
7322
 
# func_arith arithmetic-term...
7323
 
func_arith ()
7324
 
{
7325
 
  func_arith_result=$(( $[*] ))
7326
 
}
7327
 
 
7328
 
# func_len string
7329
 
# STRING may not start with a hyphen.
7330
 
func_len ()
7331
 
{
7332
 
  func_len_result=${#1}
7333
 
}
7334
 
 
7335
 
_LT_EOF
7336
 
    ;;
7337
 
  *) # Bourne compatible functions.
7338
 
    cat << \_LT_EOF >> "$cfgfile"
7339
 
 
7340
 
# func_dirname file append nondir_replacement
7341
 
# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
7342
 
# otherwise set result to NONDIR_REPLACEMENT.
7343
 
func_dirname ()
7344
 
{
7345
 
  # Extract subdirectory from the argument.
7346
 
  func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
7347
 
  if test "X$func_dirname_result" = "X${1}"; then
7348
 
    func_dirname_result="${3}"
7349
 
  else
7350
 
    func_dirname_result="$func_dirname_result${2}"
7351
 
  fi
7352
 
}
7353
 
 
7354
 
# func_basename file
7355
 
func_basename ()
7356
 
{
7357
 
  func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
7358
 
}
7359
 
 
7360
 
dnl func_dirname_and_basename
7361
 
dnl A portable version of this function is already defined in general.m4sh
7362
 
dnl so there is no need for it here.
7363
 
 
7364
 
# func_stripname prefix suffix name
7365
 
# strip PREFIX and SUFFIX off of NAME.
7366
 
# PREFIX and SUFFIX must not contain globbing or regex special
7367
 
# characters, hashes, percent signs, but SUFFIX may contain a leading
7368
 
# dot (in which case that matches only a dot).
7369
 
# func_strip_suffix prefix name
7370
 
func_stripname ()
7371
 
{
7372
 
  case ${2} in
7373
 
    .*) func_stripname_result=`$ECHO "X${3}" \
7374
 
           | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
7375
 
    *)  func_stripname_result=`$ECHO "X${3}" \
7376
 
           | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
7377
 
  esac
7378
 
}
7379
 
 
7380
 
# sed scripts:
7381
 
my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
7382
 
my_sed_long_arg='1s/^-[[^=]]*=//'
7383
 
 
7384
 
# func_opt_split
7385
 
func_opt_split ()
7386
 
{
7387
 
  func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
7388
 
  func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
7389
 
}
7390
 
 
7391
 
# func_lo2o object
7392
 
func_lo2o ()
7393
 
{
7394
 
  func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
7395
 
}
7396
 
 
7397
 
# func_xform libobj-or-source
7398
 
func_xform ()
7399
 
{
7400
 
  func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'`
7401
 
}
7402
 
 
7403
 
# func_arith arithmetic-term...
7404
 
func_arith ()
7405
 
{
7406
 
  func_arith_result=`expr "$[@]"`
7407
 
}
7408
 
 
7409
 
# func_len string
7410
 
# STRING may not start with a hyphen.
7411
 
func_len ()
7412
 
{
7413
 
  func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
7414
 
}
7415
 
 
7416
 
_LT_EOF
7417
 
esac
7418
 
 
7419
 
case $lt_shell_append in
7420
 
  yes)
7421
 
    cat << \_LT_EOF >> "$cfgfile"
7422
 
 
7423
 
# func_append var value
7424
 
# Append VALUE to the end of shell variable VAR.
7425
 
func_append ()
7426
 
{
7427
 
  eval "$[1]+=\$[2]"
7428
 
}
7429
 
_LT_EOF
7430
 
    ;;
7431
 
  *)
7432
 
    cat << \_LT_EOF >> "$cfgfile"
7433
 
 
7434
 
# func_append var value
7435
 
# Append VALUE to the end of shell variable VAR.
7436
 
func_append ()
7437
 
{
7438
 
  eval "$[1]=\$$[1]\$[2]"
7439
 
}
7440
 
 
7441
 
_LT_EOF
7442
 
    ;;
7443
 
  esac
7444
 
])
 
7760
# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
 
7761
# ------------------------------------------------------
 
7762
# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
 
7763
# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
 
7764
m4_defun([_LT_PROG_FUNCTION_REPLACE],
 
7765
[dnl {
 
7766
sed -e '/^$1 ()$/,/^} # $1 /c\
 
7767
$1 ()\
 
7768
{\
 
7769
m4_bpatsubsts([$2], [$], [\\], [^\([     ]\)], [\\\1])
 
7770
} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
 
7771
  && mv -f "$cfgfile.tmp" "$cfgfile" \
 
7772
    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
 
7773
test 0 -eq $? || _lt_function_replace_fail=:
 
7774
])
 
7775
 
 
7776
 
 
7777
# _LT_PROG_REPLACE_SHELLFNS
 
7778
# -------------------------
 
7779
# Replace existing portable implementations of several shell functions with
 
7780
# equivalent extended shell implementations where those features are available..
 
7781
m4_defun([_LT_PROG_REPLACE_SHELLFNS],
 
7782
[if test x"$xsi_shell" = xyes; then
 
7783
  _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
 
7784
    case ${1} in
 
7785
      */*) func_dirname_result="${1%/*}${2}" ;;
 
7786
      *  ) func_dirname_result="${3}" ;;
 
7787
    esac])
 
7788
 
 
7789
  _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
 
7790
    func_basename_result="${1##*/}"])
 
7791
 
 
7792
  _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
 
7793
    case ${1} in
 
7794
      */*) func_dirname_result="${1%/*}${2}" ;;
 
7795
      *  ) func_dirname_result="${3}" ;;
 
7796
    esac
 
7797
    func_basename_result="${1##*/}"])
 
7798
 
 
7799
  _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
 
7800
    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
 
7801
    # positional parameters, so assign one to ordinary parameter first.
 
7802
    func_stripname_result=${3}
 
7803
    func_stripname_result=${func_stripname_result#"${1}"}
 
7804
    func_stripname_result=${func_stripname_result%"${2}"}])
 
7805
 
 
7806
  _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
 
7807
    func_split_long_opt_name=${1%%=*}
 
7808
    func_split_long_opt_arg=${1#*=}])
 
7809
 
 
7810
  _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
 
7811
    func_split_short_opt_arg=${1#??}
 
7812
    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
 
7813
 
 
7814
  _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
 
7815
    case ${1} in
 
7816
      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
 
7817
      *)    func_lo2o_result=${1} ;;
 
7818
    esac])
 
7819
 
 
7820
  _LT_PROG_FUNCTION_REPLACE([func_xform], [    func_xform_result=${1%.*}.lo])
 
7821
 
 
7822
  _LT_PROG_FUNCTION_REPLACE([func_arith], [    func_arith_result=$(( $[*] ))])
 
7823
 
 
7824
  _LT_PROG_FUNCTION_REPLACE([func_len], [    func_len_result=${#1}])
 
7825
fi
 
7826
 
 
7827
if test x"$lt_shell_append" = xyes; then
 
7828
  _LT_PROG_FUNCTION_REPLACE([func_append], [    eval "${1}+=\\${2}"])
 
7829
 
 
7830
  _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
 
7831
    func_quote_for_eval "${2}"
 
7832
dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
 
7833
    eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
 
7834
 
 
7835
  # Save a `func_append' function call where possible by direct use of '+='
 
7836
  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
 
7837
    && mv -f "$cfgfile.tmp" "$cfgfile" \
 
7838
      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
 
7839
  test 0 -eq $? || _lt_function_replace_fail=:
 
7840
else
 
7841
  # Save a `func_append' function call even when '+=' is not available
 
7842
  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
 
7843
    && mv -f "$cfgfile.tmp" "$cfgfile" \
 
7844
      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
 
7845
  test 0 -eq $? || _lt_function_replace_fail=:
 
7846
fi
 
7847
 
 
7848
if test x"$_lt_function_replace_fail" = x":"; then
 
7849
  AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
 
7850
fi
 
7851
])
 
7852
 
 
7853
# _LT_PATH_CONVERSION_FUNCTIONS
 
7854
# -----------------------------
 
7855
# Determine which file name conversion functions should be used by
 
7856
# func_to_host_file (and, implicitly, by func_to_host_path).  These are needed
 
7857
# for certain cross-compile configurations and native mingw.
 
7858
m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
 
7859
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
 
7860
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
 
7861
AC_MSG_CHECKING([how to convert $build file names to $host format])
 
7862
AC_CACHE_VAL(lt_cv_to_host_file_cmd,
 
7863
[case $host in
 
7864
  *-*-mingw* )
 
7865
    case $build in
 
7866
      *-*-mingw* ) # actually msys
 
7867
        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
 
7868
        ;;
 
7869
      *-*-cygwin* )
 
7870
        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
 
7871
        ;;
 
7872
      * ) # otherwise, assume *nix
 
7873
        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
 
7874
        ;;
 
7875
    esac
 
7876
    ;;
 
7877
  *-*-cygwin* )
 
7878
    case $build in
 
7879
      *-*-mingw* ) # actually msys
 
7880
        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
 
7881
        ;;
 
7882
      *-*-cygwin* )
 
7883
        lt_cv_to_host_file_cmd=func_convert_file_noop
 
7884
        ;;
 
7885
      * ) # otherwise, assume *nix
 
7886
        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
 
7887
        ;;
 
7888
    esac
 
7889
    ;;
 
7890
  * ) # unhandled hosts (and "normal" native builds)
 
7891
    lt_cv_to_host_file_cmd=func_convert_file_noop
 
7892
    ;;
 
7893
esac
 
7894
])
 
7895
to_host_file_cmd=$lt_cv_to_host_file_cmd
 
7896
AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
 
7897
_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
 
7898
         [0], [convert $build file names to $host format])dnl
 
7899
 
 
7900
AC_MSG_CHECKING([how to convert $build file names to toolchain format])
 
7901
AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
 
7902
[#assume ordinary cross tools, or native build.
 
7903
lt_cv_to_tool_file_cmd=func_convert_file_noop
 
7904
case $host in
 
7905
  *-*-mingw* )
 
7906
    case $build in
 
7907
      *-*-mingw* ) # actually msys
 
7908
        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
 
7909
        ;;
 
7910
    esac
 
7911
    ;;
 
7912
esac
 
7913
])
 
7914
to_tool_file_cmd=$lt_cv_to_tool_file_cmd
 
7915
AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
 
7916
_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
 
7917
         [0], [convert $build files to toolchain format])dnl
 
7918
])# _LT_PATH_CONVERSION_FUNCTIONS
7445
7919
 
7446
7920
# Helper functions for option handling.                    -*- Autoconf -*-
7447
7921
#
7448
 
#   Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
 
7922
#   Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
 
7923
#   Inc.
7449
7924
#   Written by Gary V. Vaughan, 2004
7450
7925
#
7451
7926
# This file is free software; the Free Software Foundation gives
7452
7927
# unlimited permission to copy and/or distribute it, with or without
7453
7928
# modifications, as long as this notice is preserved.
7454
7929
 
7455
 
# serial 6 ltoptions.m4
 
7930
# serial 7 ltoptions.m4
7456
7931
 
7457
7932
# This is to help aclocal find these macros, as it can't see m4_define.
7458
7933
AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
7567
8042
[enable_win32_dll=yes
7568
8043
 
7569
8044
case $host in
7570
 
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*)
 
8045
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
7571
8046
  AC_CHECK_TOOL(AS, as, false)
7572
8047
  AC_CHECK_TOOL(DLLTOOL, dlltool, false)
7573
8048
  AC_CHECK_TOOL(OBJDUMP, objdump, false)
7575
8050
esac
7576
8051
 
7577
8052
test -z "$AS" && AS=as
7578
 
_LT_DECL([], [AS],      [0], [Assembler program])dnl
 
8053
_LT_DECL([], [AS],      [1], [Assembler program])dnl
7579
8054
 
7580
8055
test -z "$DLLTOOL" && DLLTOOL=dlltool
7581
 
_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl
 
8056
_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
7582
8057
 
7583
8058
test -z "$OBJDUMP" && OBJDUMP=objdump
7584
 
_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl
 
8059
_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
7585
8060
])# win32-dll
7586
8061
 
7587
8062
AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
7939
8414
# unlimited permission to copy and/or distribute it, with or without
7940
8415
# modifications, as long as this notice is preserved.
7941
8416
 
7942
 
# Generated from ltversion.in.
 
8417
# @configure_input@
7943
8418
 
7944
 
# serial 3017 ltversion.m4
 
8419
# serial 3293 ltversion.m4
7945
8420
# This file is part of GNU Libtool
7946
8421
 
7947
 
m4_define([LT_PACKAGE_VERSION], [2.2.6b])
7948
 
m4_define([LT_PACKAGE_REVISION], [1.3017])
 
8422
m4_define([LT_PACKAGE_VERSION], [2.4])
 
8423
m4_define([LT_PACKAGE_REVISION], [1.3293])
7949
8424
 
7950
8425
AC_DEFUN([LTVERSION_VERSION],
7951
 
[macro_version='2.2.6b'
7952
 
macro_revision='1.3017'
 
8426
[macro_version='2.4'
 
8427
macro_revision='1.3293'
7953
8428
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
7954
8429
_LT_DECL(, macro_revision, 0)
7955
8430
])
7956
8431
 
7957
8432
# lt~obsolete.m4 -- aclocal satisfying obsolete definitions.    -*-Autoconf-*-
7958
8433
#
7959
 
#   Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
 
8434
#   Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
7960
8435
#   Written by Scott James Remnant, 2004.
7961
8436
#
7962
8437
# This file is free software; the Free Software Foundation gives
7963
8438
# unlimited permission to copy and/or distribute it, with or without
7964
8439
# modifications, as long as this notice is preserved.
7965
8440
 
7966
 
# serial 4 lt~obsolete.m4
 
8441
# serial 5 lt~obsolete.m4
7967
8442
 
7968
8443
# These exist entirely to fool aclocal when bootstrapping libtool.
7969
8444
#
8033
8508
m4_ifndef([_LT_AC_LANG_CXX],            [AC_DEFUN([_LT_AC_LANG_CXX])])
8034
8509
m4_ifndef([_LT_AC_LANG_F77],            [AC_DEFUN([_LT_AC_LANG_F77])])
8035
8510
m4_ifndef([_LT_AC_LANG_GCJ],            [AC_DEFUN([_LT_AC_LANG_GCJ])])
8036
 
m4_ifndef([AC_LIBTOOL_RC],              [AC_DEFUN([AC_LIBTOOL_RC])])
8037
8511
m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG],   [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
8038
8512
m4_ifndef([_LT_AC_LANG_C_CONFIG],       [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
8039
8513
m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
8046
8520
m4_ifndef([_LT_AC_LANG_RC_CONFIG],      [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
8047
8521
m4_ifndef([AC_LIBTOOL_CONFIG],          [AC_DEFUN([AC_LIBTOOL_CONFIG])])
8048
8522
m4_ifndef([_LT_AC_FILE_LTDLL_C],        [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
 
8523
m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
 
8524
m4_ifndef([_LT_AC_PROG_CXXCPP],         [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
 
8525
m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
 
8526
m4_ifndef([_LT_PROG_ECHO_BACKSLASH],    [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
 
8527
m4_ifndef([_LT_PROG_F77],               [AC_DEFUN([_LT_PROG_F77])])
 
8528
m4_ifndef([_LT_PROG_FC],                [AC_DEFUN([_LT_PROG_FC])])
 
8529
m4_ifndef([_LT_PROG_CXX],               [AC_DEFUN([_LT_PROG_CXX])])
8049
8530
 
8050
8531
# pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
8051
8532
# serial 1 (pkg-config-0.24)
8075
8556
# ----------------------------------
8076
8557
AC_DEFUN([PKG_PROG_PKG_CONFIG],
8077
8558
[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
8078
 
m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
 
8559
m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
 
8560
m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
8079
8561
AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
8080
8562
AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
8081
8563
AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
8121
8603
    pkg_cv_[]$1="$$1"
8122
8604
 elif test -n "$PKG_CONFIG"; then
8123
8605
    PKG_CHECK_EXISTS([$3],
8124
 
                     [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
 
8606
                     [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
 
8607
                      test "x$?" != "x0" && pkg_failed=yes ],
8125
8608
                     [pkg_failed=yes])
8126
8609
 else
8127
8610
    pkg_failed=untried
8169
8652
        AC_MSG_RESULT([no])
8170
8653
        _PKG_SHORT_ERRORS_SUPPORTED
8171
8654
        if test $_pkg_short_errors_supported = yes; then
8172
 
                $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
 
8655
                $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
8173
8656
        else 
8174
 
                $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
 
8657
                $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
8175
8658
        fi
8176
8659
        # Put the nasty error message in config.log where it belongs
8177
8660
        echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD