~ubuntu-branches/ubuntu/lucid/tidy/lucid

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Jason Thomas
  • Date: 2008-01-20 21:46:03 UTC
  • mfrom: (3.1.1 lenny)
  • Revision ID: james.westby@ubuntu.com-20080120214603-poklofici9og61tx
Tags: 20080116cvs-2
* debian/control: build depends on xsltproc
  (closes: #461608)
* debian/tidy.preinst,postinst: add code to move old config file
  (closes: #461623)

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
 
14
14
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
15
15
 
16
 
# serial 47 Debian 1.5.20-2 AC_PROG_LIBTOOL
 
16
# serial 51 Debian 1.5.24-2 AC_PROG_LIBTOOL
17
17
 
18
18
 
19
19
# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
163
163
test -z "$AS" && AS=as
164
164
test -z "$CC" && CC=cc
165
165
test -z "$LTCC" && LTCC=$CC
 
166
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
166
167
test -z "$DLLTOOL" && DLLTOOL=dlltool
167
168
test -z "$LD" && LD=ld
168
169
test -z "$LN_S" && LN_S="ln -s"
175
176
test -z "$ac_objext" && ac_objext=o
176
177
 
177
178
# Determine commands to create old-style static archives.
178
 
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
 
179
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
179
180
old_postinstall_cmds='chmod 644 $oldlib'
180
181
old_postuninstall_cmds=
181
182
 
182
183
if test -n "$RANLIB"; then
183
184
  case $host_os in
184
185
  openbsd*)
185
 
    old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
 
186
    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
186
187
    ;;
187
188
  *)
188
 
    old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
 
189
    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
189
190
    ;;
190
191
  esac
191
192
  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
233
234
# If no C compiler was specified, use CC.
234
235
LTCC=${LTCC-"$CC"}
235
236
 
 
237
# If no C compiler flags were specified, use CFLAGS.
 
238
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
 
239
 
236
240
# Allow CC to be a program name with arguments.
237
241
compiler=$CC
238
242
])# _LT_AC_SYS_COMPILER
259
263
# Check for compiler boilerplate output or warnings with
260
264
# the simple compiler test code.
261
265
AC_DEFUN([_LT_COMPILER_BOILERPLATE],
262
 
[ac_outfile=conftest.$ac_objext
263
 
printf "$lt_simple_compile_test_code" >conftest.$ac_ext
264
 
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
 
266
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
267
ac_outfile=conftest.$ac_objext
 
268
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
 
269
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
265
270
_lt_compiler_boilerplate=`cat conftest.err`
266
271
$rm conftest*
267
272
])# _LT_COMPILER_BOILERPLATE
272
277
# Check for linker boilerplate output or warnings with
273
278
# the simple link test code.
274
279
AC_DEFUN([_LT_LINKER_BOILERPLATE],
275
 
[ac_outfile=conftest.$ac_objext
276
 
printf "$lt_simple_link_test_code" >conftest.$ac_ext
277
 
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
 
280
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
281
ac_outfile=conftest.$ac_objext
 
282
echo "$lt_simple_link_test_code" >conftest.$ac_ext
 
283
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
278
284
_lt_linker_boilerplate=`cat conftest.err`
279
285
$rm conftest*
280
286
])# _LT_LINKER_BOILERPLATE
289
295
# If we don't find anything, use the default library path according
290
296
# to the aix ld manual.
291
297
AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
292
 
[AC_LINK_IFELSE(AC_LANG_PROGRAM,[
293
 
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
294
 
}'`
 
298
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
299
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
 
300
lt_aix_libpath_sed='
 
301
    /Import File Strings/,/^$/ {
 
302
        /^0/ {
 
303
            s/^0  *\(.*\)$/\1/
 
304
            p
 
305
        }
 
306
    }'
 
307
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
295
308
# Check for a 64-bit object if we didn't find anything.
296
 
if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
297
 
}'`; fi],[])
 
309
if test -z "$aix_libpath"; then
 
310
  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 
311
fi],[])
298
312
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
299
313
])# _LT_AC_SYS_LIBPATH_AIX
300
314
 
525
539
  rm -rf conftest*
526
540
  ;;
527
541
 
528
 
x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
 
542
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
 
543
s390*-*linux*|sparc*-*linux*)
529
544
  # Find out which ABI we are using.
530
545
  echo 'int i;' > conftest.$ac_ext
531
546
  if AC_TRY_EVAL(ac_compile); then
532
547
    case `/usr/bin/file conftest.o` in
533
548
    *32-bit*)
534
549
      case $host in
 
550
        x86_64-*kfreebsd*-gnu)
 
551
          LD="${LD-ld} -m elf_i386_fbsd"
 
552
          ;;
535
553
        x86_64-*linux*)
536
554
          LD="${LD-ld} -m elf_i386"
537
555
          ;;
548
566
      ;;
549
567
    *64-bit*)
550
568
      case $host in
 
569
        x86_64-*kfreebsd*-gnu)
 
570
          LD="${LD-ld} -m elf_x86_64_fbsd"
 
571
          ;;
551
572
        x86_64-*linux*)
552
573
          LD="${LD-ld} -m elf_x86_64"
553
574
          ;;
580
601
    CFLAGS="$SAVE_CFLAGS"
581
602
  fi
582
603
  ;;
 
604
sparc*-*solaris*)
 
605
  # Find out which ABI we are using.
 
606
  echo 'int i;' > conftest.$ac_ext
 
607
  if AC_TRY_EVAL(ac_compile); then
 
608
    case `/usr/bin/file conftest.o` in
 
609
    *64-bit*)
 
610
      case $lt_cv_prog_gnu_ld in
 
611
      yes*) LD="${LD-ld} -m elf64_sparc" ;;
 
612
      *)    LD="${LD-ld} -64" ;;
 
613
      esac
 
614
      ;;
 
615
    esac
 
616
  fi
 
617
  rm -rf conftest*
 
618
  ;;
 
619
 
583
620
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
584
621
[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
585
622
  AC_CHECK_TOOL(DLLTOOL, dlltool, false)
603
640
AC_CACHE_CHECK([$1], [$2],
604
641
  [$2=no
605
642
  ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
606
 
   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
643
   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
607
644
   lt_compiler_flag="$3"
608
645
   # Insert the option either (1) after the last *FLAGS variable, or
609
646
   # (2) before a word containing "conftest.", or (3) at the end.
622
659
   if (exit $ac_status) && test -s "$ac_outfile"; then
623
660
     # The compiler can only warn and ignore the option if not recognized
624
661
     # So say no if there are warnings other than the usual output.
625
 
     $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
626
 
     $SED '/^$/d' conftest.err >conftest.er2
627
 
     if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
 
662
     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
 
663
     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
 
664
     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
628
665
       $2=yes
629
666
     fi
630
667
   fi
644
681
# ------------------------------------------------------------
645
682
# Check whether the given compiler option works
646
683
AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
647
 
[AC_CACHE_CHECK([$1], [$2],
 
684
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
685
AC_CACHE_CHECK([$1], [$2],
648
686
  [$2=no
649
687
   save_LDFLAGS="$LDFLAGS"
650
688
   LDFLAGS="$LDFLAGS $3"
651
 
   printf "$lt_simple_link_test_code" > conftest.$ac_ext
 
689
   echo "$lt_simple_link_test_code" > conftest.$ac_ext
652
690
   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
653
691
     # The linker can only warn and ignore the option if not recognized
654
692
     # So say no if there are warnings
655
693
     if test -s conftest.err; then
656
694
       # Append any errors to the config.log.
657
695
       cat conftest.err 1>&AS_MESSAGE_LOG_FD
658
 
       $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
659
 
       $SED '/^$/d' conftest.err >conftest.er2
 
696
       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
 
697
       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
660
698
       if diff conftest.exp conftest.er2 >/dev/null; then
661
699
         $2=yes
662
700
       fi
731
769
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
732
770
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
733
771
    ;;
 
772
 
 
773
  interix*)
 
774
    # We know the value 262144 and hardcode it with a safety zone (like BSD)
 
775
    lt_cv_sys_max_cmd_len=196608
 
776
    ;;
 
777
 
734
778
  osf*)
735
779
    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
736
780
    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
744
788
      esac
745
789
    fi
746
790
    ;;
 
791
  sco3.2v5*)
 
792
    lt_cv_sys_max_cmd_len=102400
 
793
    ;;
 
794
  sysv5* | sco5v6* | sysv4.2uw2*)
 
795
    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
 
796
    if test -n "$kargmax"; then
 
797
      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[        ]]//'`
 
798
    else
 
799
      lt_cv_sys_max_cmd_len=32768
 
800
    fi
 
801
    ;;
747
802
  *)
748
 
    # If test is not a shell built-in, we'll probably end up computing a
749
 
    # maximum length that is only half of the actual maximum length, but
750
 
    # we can't tell.
751
 
    SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
752
 
    while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
 
803
    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
 
804
    if test -n "$lt_cv_sys_max_cmd_len"; then
 
805
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
 
806
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
 
807
    else
 
808
      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
 
809
      while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
753
810
               = "XX$teststring") >/dev/null 2>&1 &&
754
 
            new_result=`expr "X$teststring" : ".*" 2>&1` &&
755
 
            lt_cv_sys_max_cmd_len=$new_result &&
756
 
            test $i != 17 # 1/2 MB should be enough
757
 
    do
758
 
      i=`expr $i + 1`
759
 
      teststring=$teststring$teststring
760
 
    done
761
 
    teststring=
762
 
    # Add a significant safety factor because C++ compilers can tack on massive
763
 
    # amounts of additional arguments before passing them to the linker.
764
 
    # It appears as though 1/2 is a usable value.
765
 
    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
 
811
              new_result=`expr "X$teststring" : ".*" 2>&1` &&
 
812
              lt_cv_sys_max_cmd_len=$new_result &&
 
813
              test $i != 17 # 1/2 MB should be enough
 
814
      do
 
815
        i=`expr $i + 1`
 
816
        teststring=$teststring$teststring
 
817
      done
 
818
      teststring=
 
819
      # Add a significant safety factor because C++ compilers can tack on massive
 
820
      # amounts of additional arguments before passing them to the linker.
 
821
      # It appears as though 1/2 is a usable value.
 
822
      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
 
823
    fi
766
824
    ;;
767
825
  esac
768
826
])
775
833
 
776
834
 
777
835
# _LT_AC_CHECK_DLFCN
778
 
# --------------------
 
836
# ------------------
779
837
AC_DEFUN([_LT_AC_CHECK_DLFCN],
780
838
[AC_CHECK_HEADERS(dlfcn.h)dnl
781
839
])# _LT_AC_CHECK_DLFCN
783
841
 
784
842
# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
785
843
#                           ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
786
 
# ------------------------------------------------------------------
 
844
# ---------------------------------------------------------------------
787
845
AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
788
846
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
789
847
if test "$cross_compiling" = yes; then :
849
907
      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
850
908
      /* dlclose (self); */
851
909
    }
 
910
  else
 
911
    puts (dlerror ());
852
912
 
853
913
    exit (status);
854
914
}]
859
919
    case x$lt_status in
860
920
      x$lt_dlno_uscore) $1 ;;
861
921
      x$lt_dlneed_uscore) $2 ;;
862
 
      x$lt_unknown|x*) $3 ;;
 
922
      x$lt_dlunknown|x*) $3 ;;
863
923
    esac
864
924
  else :
865
925
    # compilation failed
871
931
 
872
932
 
873
933
# AC_LIBTOOL_DLOPEN_SELF
874
 
# -------------------
 
934
# ----------------------
875
935
AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
876
936
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
877
937
if test "x$enable_dlopen" != xyes; then
942
1002
    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
943
1003
 
944
1004
    save_LDFLAGS="$LDFLAGS"
945
 
    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
 
1005
    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
946
1006
 
947
1007
    save_LIBS="$LIBS"
948
1008
    LIBS="$lt_cv_dlopen_libs $LIBS"
955
1015
    ])
956
1016
 
957
1017
    if test "x$lt_cv_dlopen_self" = xyes; then
958
 
      LDFLAGS="$LDFLAGS $link_static_flag"
 
1018
      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
959
1019
      AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
960
1020
          lt_cv_dlopen_self_static, [dnl
961
1021
          _LT_AC_TRY_DLOPEN_SELF(
987
1047
# ---------------------------------
988
1048
# Check to see if options -c and -o are simultaneously supported by compiler
989
1049
AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
990
 
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
 
1050
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1051
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
991
1052
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
992
1053
  [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
993
1054
  [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
995
1056
   mkdir conftest
996
1057
   cd conftest
997
1058
   mkdir out
998
 
   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
1059
   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
999
1060
 
1000
1061
   lt_compiler_flag="-o out/conftest2.$ac_objext"
1001
1062
   # Insert the option either (1) after the last *FLAGS variable, or
1015
1076
   then
1016
1077
     # The compiler can only warn and ignore the option if not recognized
1017
1078
     # So say no if there are warnings
1018
 
     $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
1019
 
     $SED '/^$/d' out/conftest.err >out/conftest.er2
1020
 
     if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
 
1079
     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
 
1080
     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
 
1081
     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1021
1082
       _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1022
1083
     fi
1023
1084
   fi
1135
1196
   darwin*)
1136
1197
       if test -n "$STRIP" ; then
1137
1198
         striplib="$STRIP -x"
 
1199
         old_striplib="$STRIP -S"
1138
1200
         AC_MSG_RESULT([yes])
1139
1201
       else
1140
1202
  AC_MSG_RESULT([no])
1152
1214
# -----------------------------
1153
1215
# PORTME Fill in your ld.so characteristics
1154
1216
AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
1155
 
[AC_MSG_CHECKING([dynamic linker characteristics])
 
1217
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1218
AC_MSG_CHECKING([dynamic linker characteristics])
1156
1219
library_names_spec=
1157
1220
libname_spec='lib$name'
1158
1221
soname_spec=
1166
1229
version_type=none
1167
1230
dynamic_linker="$host_os ld.so"
1168
1231
sys_lib_dlsearch_path_spec="/lib /usr/lib"
 
1232
m4_if($1,[],[
1169
1233
if test "$GCC" = yes; then
1170
 
  sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1171
 
  if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
 
1234
  case $host_os in
 
1235
    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
 
1236
    *) lt_awk_arg="/^libraries:/" ;;
 
1237
  esac
 
1238
  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
 
1239
  if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
1172
1240
    # if the path contains ";" then we assume it to be the separator
1173
1241
    # otherwise default to the standard path separator (i.e. ":") - it is
1174
1242
    # assumed that no part of a normal pathname contains ";" but that should
1175
1243
    # okay in the real world where ";" in dirpaths is itself problematic.
1176
 
    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
 
1244
    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
1177
1245
  else
1178
 
    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
 
1246
    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
1179
1247
  fi
 
1248
  # Ok, now we have the path, separated by spaces, we can step through it
 
1249
  # and add multilib dir if necessary.
 
1250
  lt_tmp_lt_search_path_spec=
 
1251
  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
 
1252
  for lt_sys_path in $lt_search_path_spec; do
 
1253
    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
 
1254
      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
 
1255
    else
 
1256
      test -d "$lt_sys_path" && \
 
1257
        lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
 
1258
    fi
 
1259
  done
 
1260
  lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
 
1261
BEGIN {RS=" "; FS="/|\n";} {
 
1262
  lt_foo="";
 
1263
  lt_count=0;
 
1264
  for (lt_i = NF; lt_i > 0; lt_i--) {
 
1265
    if ($lt_i != "" && $lt_i != ".") {
 
1266
      if ($lt_i == "..") {
 
1267
        lt_count++;
 
1268
      } else {
 
1269
        if (lt_count == 0) {
 
1270
          lt_foo="/" $lt_i lt_foo;
 
1271
        } else {
 
1272
          lt_count--;
 
1273
        }
 
1274
      }
 
1275
    }
 
1276
  }
 
1277
  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
 
1278
  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
 
1279
}'`
 
1280
  sys_lib_search_path_spec=`echo $lt_search_path_spec`
1180
1281
else
1181
1282
  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1182
 
fi
 
1283
fi])
1183
1284
need_lib_prefix=unknown
1184
1285
hardcode_into_libs=no
1185
1286
 
1336
1437
  shlibpath_overrides_runpath=yes
1337
1438
  shlibpath_var=DYLD_LIBRARY_PATH
1338
1439
  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
1339
 
  # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
1340
 
  if test "$GCC" = yes; then
1341
 
    sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
1342
 
  else
1343
 
    sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
1344
 
  fi
 
1440
  m4_if([$1], [],[
 
1441
  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 
1345
1442
  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
1346
1443
  ;;
1347
1444
 
1358
1455
  dynamic_linker=no
1359
1456
  ;;
1360
1457
 
1361
 
kfreebsd*-gnu)
1362
 
  version_type=linux
1363
 
  need_lib_prefix=no
1364
 
  need_version=no
1365
 
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1366
 
  soname_spec='${libname}${release}${shared_ext}$major'
1367
 
  shlibpath_var=LD_LIBRARY_PATH
1368
 
  shlibpath_overrides_runpath=no
1369
 
  hardcode_into_libs=yes
1370
 
  dynamic_linker='GNU ld.so'
1371
 
  ;;
1372
 
 
1373
1458
freebsd* | dragonfly*)
1374
1459
  # DragonFly does not have aout.  When/if they implement a new
1375
1460
  # versioning mechanism, adjust this.
1402
1487
    shlibpath_overrides_runpath=yes
1403
1488
    hardcode_into_libs=yes
1404
1489
    ;;
1405
 
  *) # from 3.2 on
 
1490
  freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
 
1491
  freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
1406
1492
    shlibpath_overrides_runpath=no
1407
1493
    hardcode_into_libs=yes
1408
1494
    ;;
 
1495
  *) # from 4.6 on, and DragonFly
 
1496
    shlibpath_overrides_runpath=yes
 
1497
    hardcode_into_libs=yes
 
1498
    ;;
1409
1499
  esac
1410
1500
  ;;
1411
1501
 
1465
1555
  postinstall_cmds='chmod 555 $lib'
1466
1556
  ;;
1467
1557
 
 
1558
interix[[3-9]]*)
 
1559
  version_type=linux
 
1560
  need_lib_prefix=no
 
1561
  need_version=no
 
1562
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
 
1563
  soname_spec='${libname}${release}${shared_ext}$major'
 
1564
  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
 
1565
  shlibpath_var=LD_LIBRARY_PATH
 
1566
  shlibpath_overrides_runpath=no
 
1567
  hardcode_into_libs=yes
 
1568
  ;;
 
1569
 
1468
1570
irix5* | irix6* | nonstopux*)
1469
1571
  case $host_os in
1470
1572
    nonstopux*) version_type=nonstopux ;;
1508
1610
  ;;
1509
1611
 
1510
1612
# This must be Linux ELF.
1511
 
linux*)
 
1613
linux* | k*bsd*-gnu)
1512
1614
  version_type=linux
1513
1615
  need_lib_prefix=no
1514
1616
  need_version=no
1524
1626
 
1525
1627
  # Append ld.so.conf contents to the search path
1526
1628
  if test -f /etc/ld.so.conf; then
1527
 
    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:,    ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
 
1629
    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' ' '`
1528
1630
    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
1529
1631
  fi
1530
1632
 
1549
1651
  dynamic_linker='NetBSD ld.elf_so'
1550
1652
  ;;
1551
1653
 
1552
 
knetbsd*-gnu)
1553
 
  version_type=linux
1554
 
  need_lib_prefix=no
1555
 
  need_version=no
1556
 
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1557
 
  soname_spec='${libname}${release}${shared_ext}$major'
1558
 
  shlibpath_var=LD_LIBRARY_PATH
1559
 
  shlibpath_overrides_runpath=no
1560
 
  hardcode_into_libs=yes
1561
 
  dynamic_linker='GNU ld.so'
1562
 
  ;;
1563
 
 
1564
1654
netbsd*)
1565
1655
  version_type=sunos
1566
1656
  need_lib_prefix=no
1598
1688
 
1599
1689
openbsd*)
1600
1690
  version_type=sunos
 
1691
  sys_lib_dlsearch_path_spec="/usr/lib"
1601
1692
  need_lib_prefix=no
1602
1693
  # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
1603
1694
  case $host_os in
1641
1732
  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
1642
1733
  ;;
1643
1734
 
1644
 
sco3.2v5*)
1645
 
  version_type=osf
1646
 
  soname_spec='${libname}${release}${shared_ext}$major'
1647
 
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1648
 
  shlibpath_var=LD_LIBRARY_PATH
 
1735
rdos*)
 
1736
  dynamic_linker=no
1649
1737
  ;;
1650
1738
 
1651
1739
solaris*)
1673
1761
  need_version=yes
1674
1762
  ;;
1675
1763
 
1676
 
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
 
1764
sysv4 | sysv4.3*)
1677
1765
  version_type=linux
1678
1766
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1679
1767
  soname_spec='${libname}${release}${shared_ext}$major'
1706
1794
  fi
1707
1795
  ;;
1708
1796
 
 
1797
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
 
1798
  version_type=freebsd-elf
 
1799
  need_lib_prefix=no
 
1800
  need_version=no
 
1801
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
 
1802
  soname_spec='${libname}${release}${shared_ext}$major'
 
1803
  shlibpath_var=LD_LIBRARY_PATH
 
1804
  hardcode_into_libs=yes
 
1805
  if test "$with_gnu_ld" = yes; then
 
1806
    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
 
1807
    shlibpath_overrides_runpath=no
 
1808
  else
 
1809
    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
 
1810
    shlibpath_overrides_runpath=yes
 
1811
    case $host_os in
 
1812
      sco3.2v5*)
 
1813
        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
 
1814
        ;;
 
1815
    esac
 
1816
  fi
 
1817
  sys_lib_dlsearch_path_spec='/usr/lib'
 
1818
  ;;
 
1819
 
1709
1820
uts4*)
1710
1821
  version_type=linux
1711
1822
  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1719
1830
esac
1720
1831
AC_MSG_RESULT([$dynamic_linker])
1721
1832
test "$dynamic_linker" = no && can_build_shared=no
 
1833
 
 
1834
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
 
1835
if test "$GCC" = yes; then
 
1836
  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
 
1837
fi
1722
1838
])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
1723
1839
 
1724
1840
 
1725
1841
# _LT_AC_TAGCONFIG
1726
1842
# ----------------
1727
1843
AC_DEFUN([_LT_AC_TAGCONFIG],
1728
 
[AC_ARG_WITH([tags],
 
1844
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
1845
AC_ARG_WITH([tags],
1729
1846
    [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
1730
1847
        [include additional configurations @<:@automatic@:>@])],
1731
1848
    [tagnames="$withval"])
1743
1860
      AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
1744
1861
    fi
1745
1862
  fi
 
1863
  if test -z "$LTCFLAGS"; then
 
1864
    eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
 
1865
  fi
1746
1866
 
1747
1867
  # Extract list of available tagged configurations in $ofile.
1748
1868
  # Note that this assumes the entire list is on one line.
1871
1991
 
1872
1992
# AC_DISABLE_SHARED
1873
1993
# -----------------
1874
 
#- set the default shared flag to --disable-shared
 
1994
# set the default shared flag to --disable-shared
1875
1995
AC_DEFUN([AC_DISABLE_SHARED],
1876
1996
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
1877
1997
AC_ENABLE_SHARED(no)
1983
2103
 
1984
2104
# AC_PATH_TOOL_PREFIX
1985
2105
# -------------------
1986
 
# find a file program which can recognise shared library
 
2106
# find a file program which can recognize shared library
1987
2107
AC_DEFUN([AC_PATH_TOOL_PREFIX],
1988
2108
[AC_REQUIRE([AC_PROG_EGREP])dnl
1989
2109
AC_MSG_CHECKING([for $1])
2046
2166
 
2047
2167
# AC_PATH_MAGIC
2048
2168
# -------------
2049
 
# find a file program which can recognise a shared library
 
2169
# find a file program which can recognize a shared library
2050
2170
AC_DEFUN([AC_PATH_MAGIC],
2051
2171
[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2052
2172
if test -z "$lt_cv_path_MAGIC_CMD"; then
2179
2299
case $host_os in
2180
2300
  darwin*)
2181
2301
    if test "$GCC" = yes; then
2182
 
      reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
 
2302
      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
2183
2303
    else
2184
2304
      reload_cmds='$LD$reload_flag -o $output$reload_objs'
2185
2305
    fi
2193
2313
# how to check for library dependencies
2194
2314
#  -- PORTME fill in with the dynamic library characteristics
2195
2315
AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
2196
 
[AC_CACHE_CHECK([how to recognise dependent libraries],
 
2316
[AC_CACHE_CHECK([how to recognize dependent libraries],
2197
2317
lt_cv_deplibs_check_method,
2198
2318
[lt_cv_file_magic_cmd='$MAGIC_CMD'
2199
2319
lt_cv_file_magic_test_file=
2232
2352
 
2233
2353
mingw* | pw32*)
2234
2354
  # Base MSYS/MinGW do not provide the 'file' command needed by
2235
 
  # func_win32_libid shell function, so use a weaker test based on 'objdump'.
2236
 
  lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
2237
 
  lt_cv_file_magic_cmd='$OBJDUMP -f'
 
2355
  # func_win32_libid shell function, so use a weaker test based on 'objdump',
 
2356
  # unless we find 'file', for example because we are cross-compiling.
 
2357
  if ( file / ) >/dev/null 2>&1; then
 
2358
    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
 
2359
    lt_cv_file_magic_cmd='func_win32_libid'
 
2360
  else
 
2361
    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
 
2362
    lt_cv_file_magic_cmd='$OBJDUMP -f'
 
2363
  fi
2238
2364
  ;;
2239
2365
 
2240
2366
darwin* | rhapsody*)
2241
2367
  lt_cv_deplibs_check_method=pass_all
2242
2368
  ;;
2243
2369
 
2244
 
freebsd* | kfreebsd*-gnu | dragonfly*)
 
2370
freebsd* | dragonfly*)
2245
2371
  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2246
2372
    case $host_cpu in
2247
2373
    i*86 )
2279
2405
  esac
2280
2406
  ;;
2281
2407
 
 
2408
interix[[3-9]]*)
 
2409
  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
 
2410
  lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
 
2411
  ;;
 
2412
 
2282
2413
irix5* | irix6* | nonstopux*)
2283
2414
  case $LD in
2284
2415
  *-32|*"-32 ") libmagic=32-bit;;
2290
2421
  ;;
2291
2422
 
2292
2423
# This must be Linux ELF.
2293
 
linux*)
 
2424
linux* | k*bsd*-gnu)
2294
2425
  lt_cv_deplibs_check_method=pass_all
2295
2426
  ;;
2296
2427
 
2297
 
netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
 
2428
netbsd* | netbsdelf*-gnu)
2298
2429
  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2299
2430
    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
2300
2431
  else
2324
2455
  lt_cv_deplibs_check_method=pass_all
2325
2456
  ;;
2326
2457
 
2327
 
sco3.2v5*)
 
2458
rdos*)
2328
2459
  lt_cv_deplibs_check_method=pass_all
2329
2460
  ;;
2330
2461
 
2332
2463
  lt_cv_deplibs_check_method=pass_all
2333
2464
  ;;
2334
2465
 
2335
 
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
 
2466
sysv4 | sysv4.3*)
2336
2467
  case $host_vendor in
2337
2468
  motorola)
2338
2469
    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
2353
2484
  siemens)
2354
2485
    lt_cv_deplibs_check_method=pass_all
2355
2486
    ;;
 
2487
  pc)
 
2488
    lt_cv_deplibs_check_method=pass_all
 
2489
    ;;
2356
2490
  esac
2357
2491
  ;;
2358
2492
 
2359
 
sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
 
2493
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2360
2494
  lt_cv_deplibs_check_method=pass_all
2361
2495
  ;;
2362
2496
esac
2376
2510
  # Let the user override the test.
2377
2511
  lt_cv_path_NM="$NM"
2378
2512
else
2379
 
  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2380
 
  for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2381
 
    IFS="$lt_save_ifs"
2382
 
    test -z "$ac_dir" && ac_dir=.
2383
 
    tmp_nm="$ac_dir/${ac_tool_prefix}nm"
2384
 
    if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
2385
 
      # Check to see if the nm accepts a BSD-compat flag.
2386
 
      # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2387
 
      #   nm: unknown option "B" ignored
2388
 
      # Tru64's nm complains that /dev/null is an invalid object file
2389
 
      case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
2390
 
      */dev/null* | *'Invalid file or object type'*)
2391
 
        lt_cv_path_NM="$tmp_nm -B"
2392
 
        break
2393
 
        ;;
2394
 
      *)
2395
 
        case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
2396
 
        */dev/null*)
2397
 
          lt_cv_path_NM="$tmp_nm -p"
 
2513
  lt_nm_to_check="${ac_tool_prefix}nm"
 
2514
  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
 
2515
    lt_nm_to_check="$lt_nm_to_check nm"
 
2516
  fi
 
2517
  for lt_tmp_nm in $lt_nm_to_check; do
 
2518
    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
 
2519
    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
 
2520
      IFS="$lt_save_ifs"
 
2521
      test -z "$ac_dir" && ac_dir=.
 
2522
      tmp_nm="$ac_dir/$lt_tmp_nm"
 
2523
      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
 
2524
        # Check to see if the nm accepts a BSD-compat flag.
 
2525
        # Adding the `sed 1q' prevents false positives on HP-UX, which says:
 
2526
        #   nm: unknown option "B" ignored
 
2527
        # Tru64's nm complains that /dev/null is an invalid object file
 
2528
        case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
 
2529
        */dev/null* | *'Invalid file or object type'*)
 
2530
          lt_cv_path_NM="$tmp_nm -B"
2398
2531
          break
2399
2532
          ;;
2400
2533
        *)
2401
 
          lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
2402
 
          continue # so that we can try to find one that supports BSD flags
 
2534
          case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
 
2535
          */dev/null*)
 
2536
            lt_cv_path_NM="$tmp_nm -p"
 
2537
            break
 
2538
            ;;
 
2539
          *)
 
2540
            lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
 
2541
            continue # so that we can try to find one that supports BSD flags
 
2542
            ;;
 
2543
          esac
2403
2544
          ;;
2404
2545
        esac
2405
 
      esac
2406
 
    fi
 
2546
      fi
 
2547
    done
 
2548
    IFS="$lt_save_ifs"
2407
2549
  done
2408
 
  IFS="$lt_save_ifs"
2409
2550
  test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
2410
2551
fi])
2411
2552
NM="$lt_cv_path_NM"
2511
2652
])# _LT_AC_LANG_CXX
2512
2653
 
2513
2654
# _LT_AC_PROG_CXXCPP
2514
 
# ---------------
 
2655
# ------------------
2515
2656
AC_DEFUN([_LT_AC_PROG_CXXCPP],
2516
2657
[
2517
2658
AC_REQUIRE([AC_PROG_CXX])
2560
2701
 
2561
2702
 
2562
2703
# AC_LIBTOOL_RC
2563
 
# --------------
 
2704
# -------------
2564
2705
# enable support for Windows resource files
2565
2706
AC_DEFUN([AC_LIBTOOL_RC],
2566
2707
[AC_REQUIRE([LT_AC_PROG_RC])
2586
2727
_LT_AC_TAGVAR(objext, $1)=$objext
2587
2728
 
2588
2729
# Code to be used in simple compile tests
2589
 
lt_simple_compile_test_code="int some_variable = 0;\n"
 
2730
lt_simple_compile_test_code="int some_variable = 0;"
2590
2731
 
2591
2732
# Code to be used in simple link tests
2592
 
lt_simple_link_test_code='int main(){return(0);}\n'
 
2733
lt_simple_link_test_code='int main(){return(0);}'
2593
2734
 
2594
2735
_LT_AC_SYS_COMPILER
2595
2736
 
2597
2738
_LT_COMPILER_BOILERPLATE
2598
2739
_LT_LINKER_BOILERPLATE
2599
2740
 
2600
 
#
2601
 
# Check for any special shared library compilation flags.
2602
 
#
2603
 
_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
2604
 
if test "$GCC" = no; then
2605
 
  case $host_os in
2606
 
  sco3.2v5*)
2607
 
    _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
2608
 
    ;;
2609
 
  esac
2610
 
fi
2611
 
if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
2612
 
  AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
2613
 
  if echo "$old_CC $old_CFLAGS " | grep "[[     ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[        ]]" >/dev/null; then :
2614
 
  else
2615
 
    AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
2616
 
    _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
2617
 
  fi
2618
 
fi
2619
 
 
2620
 
 
2621
 
#
2622
 
# Check to make sure the static flag actually works.
2623
 
#
2624
 
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
2625
 
  _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
2626
 
  $_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
2627
 
  [],
2628
 
  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
2629
 
 
2630
 
 
2631
2741
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
2632
2742
AC_LIBTOOL_PROG_COMPILER_PIC($1)
2633
2743
AC_LIBTOOL_PROG_CC_C_O($1)
2636
2746
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
2637
2747
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
2638
2748
AC_LIBTOOL_SYS_LIB_STRIP
2639
 
AC_LIBTOOL_DLOPEN_SELF($1)
 
2749
AC_LIBTOOL_DLOPEN_SELF
2640
2750
 
2641
 
# Report which librarie types wil actually be built
 
2751
# Report which library types will actually be built
2642
2752
AC_MSG_CHECKING([if libtool supports shared libraries])
2643
2753
AC_MSG_RESULT([$can_build_shared])
2644
2754
 
2697
2807
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
2698
2808
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
2699
2809
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
 
2810
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
2700
2811
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
2701
2812
_LT_AC_TAGVAR(module_cmds, $1)=
2702
2813
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
2721
2832
_LT_AC_TAGVAR(objext, $1)=$objext
2722
2833
 
2723
2834
# Code to be used in simple compile tests
2724
 
lt_simple_compile_test_code="int some_variable = 0;\n"
 
2835
lt_simple_compile_test_code="int some_variable = 0;"
2725
2836
 
2726
2837
# Code to be used in simple link tests
2727
 
lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
 
2838
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
2728
2839
 
2729
2840
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
2730
2841
_LT_AC_SYS_COMPILER
2743
2854
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
2744
2855
  lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
2745
2856
else
2746
 
  unset lt_cv_prog_gnu_ld
 
2857
  $as_unset lt_cv_prog_gnu_ld
2747
2858
fi
2748
2859
if test -n "${lt_cv_path_LDCXX+set}"; then
2749
2860
  lt_cv_path_LD=$lt_cv_path_LDCXX
2750
2861
else
2751
 
  unset lt_cv_path_LD
 
2862
  $as_unset lt_cv_path_LD
2752
2863
fi
2753
2864
test -z "${LDCXX+set}" || LD=$LDCXX
2754
2865
CC=${CXX-"c++"}
2843
2954
            ;;
2844
2955
          esac
2845
2956
        done
 
2957
        ;;
2846
2958
      esac
2847
2959
 
2848
2960
      exp_sym_flag='-bexport'
2869
2981
           strings "$collect2name" | grep resolve_lib_name >/dev/null
2870
2982
        then
2871
2983
          # We have reworked collect2
2872
 
          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
2984
          :
2873
2985
        else
2874
2986
          # We have old collect2
2875
2987
          _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
2880
2992
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
2881
2993
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
2882
2994
        fi
 
2995
        ;;
2883
2996
      esac
2884
2997
      shared_flag='-shared'
2885
2998
      if test "$aix_use_runtimelinking" = yes; then
2911
3024
      _LT_AC_SYS_LIBPATH_AIX
2912
3025
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
2913
3026
 
2914
 
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
 
3027
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
2915
3028
     else
2916
3029
      if test "$host_cpu" = ia64; then
2917
3030
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
2918
3031
        _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
2919
 
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
 
3032
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
2920
3033
      else
2921
3034
        # Determine the default libpath from the value encoded in an empty executable.
2922
3035
        _LT_AC_SYS_LIBPATH_AIX
2925
3038
        # -berok will link without error, but may produce a broken library.
2926
3039
        _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
2927
3040
        _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
2928
 
        # -bexpall does not export symbols beginning with underscore (_)
2929
 
        _LT_AC_TAGVAR(always_export_symbols, $1)=yes
2930
3041
        # Exported symbols can be pulled into shared objects from archives
2931
 
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
 
3042
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
2932
3043
        _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
2933
3044
        # This is similar to how AIX traditionally builds its shared libraries.
2934
 
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
 
3045
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
2935
3046
      fi
2936
3047
    fi
2937
3048
    ;;
 
3049
 
 
3050
  beos*)
 
3051
    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
3052
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
 
3053
      # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
 
3054
      # support --undefined.  This deserves some investigation.  FIXME
 
3055
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
3056
    else
 
3057
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
3058
    fi
 
3059
    ;;
 
3060
 
2938
3061
  chorus*)
2939
3062
    case $cc_basename in
2940
3063
      *)
2944
3067
    esac
2945
3068
    ;;
2946
3069
 
2947
 
 
2948
3070
  cygwin* | mingw* | pw32*)
2949
3071
    # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
2950
3072
    # as there is no search path for DLLs.
2954
3076
    _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
2955
3077
 
2956
3078
    if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
2957
 
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
 
3079
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
2958
3080
      # If the export-symbols file already is a .def file (1st line
2959
3081
      # is EXPORTS), use it as is; otherwise, prepend...
2960
3082
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
2963
3085
        echo EXPORTS > $output_objdir/$soname.def;
2964
3086
        cat $export_symbols >> $output_objdir/$soname.def;
2965
3087
      fi~
2966
 
      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
 
3088
      $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'
2967
3089
    else
2968
3090
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
2969
3091
    fi
3018
3140
      case $cc_basename in
3019
3141
        xlc*)
3020
3142
         output_verbose_link_cmd='echo'
3021
 
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
 
3143
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
3022
3144
          _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3023
3145
          # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
3024
 
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
 
3146
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3025
3147
          _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3026
3148
          ;;
3027
3149
       *)
3055
3177
  freebsd-elf*)
3056
3178
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3057
3179
    ;;
3058
 
  freebsd* | kfreebsd*-gnu | dragonfly*)
 
3180
  freebsd* | dragonfly*)
3059
3181
    # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3060
3182
    # conventions
3061
3183
    _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3100
3222
    ;;
3101
3223
  hpux10*|hpux11*)
3102
3224
    if test $with_gnu_ld = no; then
 
3225
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
3226
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
3227
 
3103
3228
      case $host_cpu in
3104
 
      hppa*64*)
3105
 
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3106
 
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
3107
 
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3108
 
        ;;
3109
 
      ia64*)
3110
 
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3111
 
        ;;
 
3229
      hppa*64*|ia64*) ;;
3112
3230
      *)
3113
 
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3114
 
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3115
3231
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3116
3232
        ;;
3117
3233
      esac
3118
3234
    fi
3119
3235
    case $host_cpu in
3120
 
    hppa*64*)
3121
 
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
3122
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3123
 
      ;;
3124
 
    ia64*)
3125
 
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
3126
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3127
 
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3128
 
                                              # but as the default
3129
 
                                              # location of the library.
 
3236
    hppa*64*|ia64*)
 
3237
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
3238
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3130
3239
      ;;
3131
3240
    *)
3132
3241
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3143
3252
        ;;
3144
3253
      aCC*)
3145
3254
        case $host_cpu in
3146
 
        hppa*64*|ia64*)
3147
 
          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
 
3255
        hppa*64*)
 
3256
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
3257
          ;;
 
3258
        ia64*)
 
3259
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3148
3260
          ;;
3149
3261
        *)
3150
3262
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3164
3276
        if test "$GXX" = yes; then
3165
3277
          if test $with_gnu_ld = no; then
3166
3278
            case $host_cpu in
3167
 
            ia64*|hppa*64*)
3168
 
              _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
 
3279
            hppa*64*)
 
3280
              _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
3281
              ;;
 
3282
            ia64*)
 
3283
              _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3169
3284
              ;;
3170
3285
            *)
3171
3286
              _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3179
3294
        ;;
3180
3295
    esac
3181
3296
    ;;
 
3297
  interix[[3-9]]*)
 
3298
    _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
3299
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
3300
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
3301
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
3302
    # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
 
3303
    # Instead, shared libraries are loaded at an image base (0x10000000 by
 
3304
    # default) and relocated if they conflict, which is a slow very memory
 
3305
    # consuming and fragmenting process.  To avoid this, we pick a random,
 
3306
    # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
 
3307
    # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
 
3308
    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
 
3309
    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
 
3310
    ;;
3182
3311
  irix5* | irix6*)
3183
3312
    case $cc_basename in
3184
3313
      CC*)
3205
3334
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3206
3335
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3207
3336
    ;;
3208
 
  linux*)
 
3337
  linux* | k*bsd*-gnu)
3209
3338
    case $cc_basename in
3210
3339
      KCC*)
3211
3340
        # Kuck and Associates, Inc. (KAI) C++ Compiler
3285
3414
        # dependencies.
3286
3415
        output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3287
3416
        ;;
 
3417
      *)
 
3418
        case `$CC -V 2>&1 | sed 5q` in
 
3419
        *Sun\ C*)
 
3420
          # Sun C++ 5.9
 
3421
          _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
 
3422
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 
3423
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
 
3424
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
3425
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 
3426
 
 
3427
          # Not sure whether something based on
 
3428
          # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
 
3429
          # would be better.
 
3430
          output_verbose_link_cmd='echo'
 
3431
 
 
3432
          # Archives containing C++ object files must be created using
 
3433
          # "CC -xar", where "CC" is the Sun C++ compiler.  This is
 
3434
          # necessary to make sure instantiated templates are included
 
3435
          # in the archive.
 
3436
          _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
 
3437
          ;;
 
3438
        esac
 
3439
        ;;
3288
3440
    esac
3289
3441
    ;;
3290
3442
  lynxos*)
3307
3459
        ;;
3308
3460
    esac
3309
3461
    ;;
3310
 
  netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
 
3462
  netbsd* | netbsdelf*-gnu)
3311
3463
    if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
3312
3464
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
3313
3465
      wlarc=
3323
3475
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
3324
3476
    ;;
3325
3477
  openbsd*)
3326
 
    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3327
 
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3328
 
    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3329
 
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3330
 
    if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3331
 
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
3332
 
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3333
 
      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
 
3478
    if test -f /usr/libexec/ld.so; then
 
3479
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
3480
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
3481
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
 
3482
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
3483
      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
 
3484
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
 
3485
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
3486
        _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
 
3487
      fi
 
3488
      output_verbose_link_cmd='echo'
 
3489
    else
 
3490
      _LT_AC_TAGVAR(ld_shlibs, $1)=no
3334
3491
    fi
3335
 
    output_verbose_link_cmd='echo'
3336
3492
    ;;
3337
3493
  osf3*)
3338
3494
    case $cc_basename in
3461
3617
    # FIXME: insert proper C++ library support
3462
3618
    _LT_AC_TAGVAR(ld_shlibs, $1)=no
3463
3619
    ;;
3464
 
  sco*)
3465
 
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3466
 
    case $cc_basename in
3467
 
      CC*)
3468
 
        # FIXME: insert proper C++ library support
3469
 
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3470
 
        ;;
3471
 
      *)
3472
 
        # FIXME: insert proper C++ library support
3473
 
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
3474
 
        ;;
3475
 
    esac
3476
 
    ;;
3477
3620
  sunos4*)
3478
3621
    case $cc_basename in
3479
3622
      CC*)
3507
3650
        case $host_os in
3508
3651
          solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
3509
3652
          *)
3510
 
            # The C++ compiler is used as linker so we must use $wl
3511
 
            # flag to pass the commands to the underlying system
3512
 
            # linker. We must also pass each convience library through
3513
 
            # to the system linker between allextract/defaultextract.
3514
 
            # The C++ compiler will combine linker options so we
3515
 
            # cannot just pass the convience library names through
3516
 
            # without $wl.
 
3653
            # The compiler driver will combine and reorder linker options,
 
3654
            # but understands `-z linker_flag'.
3517
3655
            # Supported since Solaris 2.6 (maybe 2.5.1?)
3518
 
            _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
 
3656
            _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
3519
3657
            ;;
3520
3658
        esac
3521
3659
        _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3562
3700
          fi
3563
3701
 
3564
3702
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
 
3703
          case $host_os in
 
3704
          solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
 
3705
          *)
 
3706
            _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
 
3707
            ;;
 
3708
          esac
3565
3709
        fi
3566
3710
        ;;
3567
3711
    esac
3568
3712
    ;;
3569
 
  sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
3570
 
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
3713
  sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
 
3714
    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
3715
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
3716
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
3717
    runpath_var='LD_RUN_PATH'
 
3718
 
 
3719
    case $cc_basename in
 
3720
      CC*)
 
3721
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3722
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3723
        ;;
 
3724
      *)
 
3725
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3726
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3727
        ;;
 
3728
    esac
 
3729
    ;;
 
3730
  sysv5* | sco3.2v5* | sco5v6*)
 
3731
    # Note: We can NOT use -z defs as we might desire, because we do not
 
3732
    # link with -lc, and that would cause any symbols used from libc to
 
3733
    # always be unresolved, which means just about no library would
 
3734
    # ever link correctly.  If we're not using GNU ld we use -z text
 
3735
    # though, which does catch some bad symbols but isn't as heavy-handed
 
3736
    # as -z defs.
 
3737
    # For security reasons, it is highly recommended that you always
 
3738
    # use absolute paths for naming shared libraries, and exclude the
 
3739
    # DT_RUNPATH tag from executables and libraries.  But doing so
 
3740
    # requires that you compile everything twice, which is a pain.
 
3741
    # So that behaviour is only enabled if SCOABSPATH is set to a
 
3742
    # non-empty value in the environment.  Most likely only useful for
 
3743
    # creating official distributions of packages.
 
3744
    # This is a hack until libtool officially supports absolute path
 
3745
    # names for shared libraries.
 
3746
    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
3747
    _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
 
3748
    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
3749
    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
3750
    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
 
3751
    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
 
3752
    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
3753
    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
 
3754
    runpath_var='LD_RUN_PATH'
 
3755
 
 
3756
    case $cc_basename in
 
3757
      CC*)
 
3758
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3759
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3760
        ;;
 
3761
      *)
 
3762
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3763
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
3764
        ;;
 
3765
    esac
3571
3766
    ;;
3572
3767
  tandem*)
3573
3768
    case $cc_basename in
3604
3799
AC_LIBTOOL_PROG_LD_SHLIBS($1)
3605
3800
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3606
3801
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3607
 
AC_LIBTOOL_SYS_LIB_STRIP
3608
 
AC_LIBTOOL_DLOPEN_SELF($1)
3609
3802
 
3610
3803
AC_LIBTOOL_CONFIG($1)
3611
3804
 
3623
3816
])# AC_LIBTOOL_LANG_CXX_CONFIG
3624
3817
 
3625
3818
# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
3626
 
# ------------------------
 
3819
# ------------------------------------
3627
3820
# Figure out "hidden" library dependencies from verbose
3628
3821
# compiler output when linking a shared library.
3629
3822
# Parse the compiler output and extract the necessary
3756
3949
# PORTME: override above test on systems where it is broken
3757
3950
ifelse([$1],[CXX],
3758
3951
[case $host_os in
 
3952
interix[[3-9]]*)
 
3953
  # Interix 3.5 installs completely hosed .la files for C++, so rather than
 
3954
  # hack all around it, let's just trust "g++" to DTRT.
 
3955
  _LT_AC_TAGVAR(predep_objects,$1)=
 
3956
  _LT_AC_TAGVAR(postdep_objects,$1)=
 
3957
  _LT_AC_TAGVAR(postdeps,$1)=
 
3958
  ;;
 
3959
 
 
3960
linux*)
 
3961
  case `$CC -V 2>&1 | sed 5q` in
 
3962
  *Sun\ C*)
 
3963
    # Sun C++ 5.9
 
3964
    #
 
3965
    # The more standards-conforming stlport4 library is
 
3966
    # incompatible with the Cstd library. Avoid specifying
 
3967
    # it if it's in CXXFLAGS. Ignore libCrun as
 
3968
    # -library=stlport4 depends on it.
 
3969
    case " $CXX $CXXFLAGS " in
 
3970
    *" -library=stlport4 "*)
 
3971
      solaris_use_stlport4=yes
 
3972
      ;;
 
3973
    esac
 
3974
    if test "$solaris_use_stlport4" != yes; then
 
3975
      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
 
3976
    fi
 
3977
    ;;
 
3978
  esac
 
3979
  ;;
 
3980
 
3759
3981
solaris*)
3760
3982
  case $cc_basename in
3761
3983
  CC*)
 
3984
    # The more standards-conforming stlport4 library is
 
3985
    # incompatible with the Cstd library. Avoid specifying
 
3986
    # it if it's in CXXFLAGS. Ignore libCrun as
 
3987
    # -library=stlport4 depends on it.
 
3988
    case " $CXX $CXXFLAGS " in
 
3989
    *" -library=stlport4 "*)
 
3990
      solaris_use_stlport4=yes
 
3991
      ;;
 
3992
    esac
 
3993
 
3762
3994
    # Adding this requires a known-good setup of shared libraries for
3763
3995
    # Sun compiler versions before 5.6, else PIC objects from an old
3764
3996
    # archive will be linked into the output, leading to subtle bugs.
3765
 
    _LT_AC_TAGVAR(postdeps,$1)='-lCstd -lCrun'
 
3997
    if test "$solaris_use_stlport4" != yes; then
 
3998
      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
 
3999
    fi
3766
4000
    ;;
3767
4001
  esac
 
4002
  ;;
3768
4003
esac
3769
4004
])
3770
4005
 
3774
4009
])# AC_LIBTOOL_POSTDEP_PREDEP
3775
4010
 
3776
4011
# AC_LIBTOOL_LANG_F77_CONFIG
3777
 
# ------------------------
 
4012
# --------------------------
3778
4013
# Ensure that the configuration vars for the C compiler are
3779
4014
# suitably defined.  Those variables are subsequently used by
3780
4015
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3810
4045
_LT_AC_TAGVAR(objext, $1)=$objext
3811
4046
 
3812
4047
# Code to be used in simple compile tests
3813
 
lt_simple_compile_test_code="      subroutine t\n      return\n      end\n"
 
4048
lt_simple_compile_test_code="\
 
4049
      subroutine t
 
4050
      return
 
4051
      end
 
4052
"
3814
4053
 
3815
4054
# Code to be used in simple link tests
3816
 
lt_simple_link_test_code="      program t\n      end\n"
 
4055
lt_simple_link_test_code="\
 
4056
      program t
 
4057
      end
 
4058
"
3817
4059
 
3818
4060
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3819
4061
_LT_AC_SYS_COMPILER
3858
4100
test "$enable_shared" = yes || enable_static=yes
3859
4101
AC_MSG_RESULT([$enable_static])
3860
4102
 
3861
 
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
3862
 
 
3863
4103
_LT_AC_TAGVAR(GCC, $1)="$G77"
3864
4104
_LT_AC_TAGVAR(LD, $1)="$LD"
3865
4105
 
3869
4109
AC_LIBTOOL_PROG_LD_SHLIBS($1)
3870
4110
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3871
4111
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3872
 
AC_LIBTOOL_SYS_LIB_STRIP
3873
 
 
3874
4112
 
3875
4113
AC_LIBTOOL_CONFIG($1)
3876
4114
 
3896
4134
_LT_AC_TAGVAR(objext, $1)=$objext
3897
4135
 
3898
4136
# Code to be used in simple compile tests
3899
 
lt_simple_compile_test_code="class foo {}\n"
 
4137
lt_simple_compile_test_code="class foo {}"
3900
4138
 
3901
4139
# Code to be used in simple link tests
3902
 
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
 
4140
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
3903
4141
 
3904
4142
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3905
4143
_LT_AC_SYS_COMPILER
3927
4165
AC_LIBTOOL_PROG_LD_SHLIBS($1)
3928
4166
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3929
4167
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3930
 
AC_LIBTOOL_SYS_LIB_STRIP
3931
 
AC_LIBTOOL_DLOPEN_SELF($1)
3932
4168
 
3933
4169
AC_LIBTOOL_CONFIG($1)
3934
4170
 
3938
4174
 
3939
4175
 
3940
4176
# AC_LIBTOOL_LANG_RC_CONFIG
3941
 
# --------------------------
 
4177
# -------------------------
3942
4178
# Ensure that the configuration vars for the Windows resource compiler are
3943
4179
# suitably defined.  Those variables are subsequently used by
3944
4180
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3954
4190
_LT_AC_TAGVAR(objext, $1)=$objext
3955
4191
 
3956
4192
# Code to be used in simple compile tests
3957
 
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
 
4193
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
3958
4194
 
3959
4195
# Code to be used in simple link tests
3960
4196
lt_simple_link_test_code="$lt_simple_compile_test_code"
4001
4237
  # Now quote all the things that may contain metacharacters while being
4002
4238
  # careful not to overquote the AC_SUBSTed values.  We take copies of the
4003
4239
  # variables and quote the copies for generation of the libtool script.
4004
 
  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
 
4240
  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
4005
4241
    SED SHELL STRIP \
4006
4242
    libname_spec library_names_spec soname_spec extract_expsyms_cmds \
4007
4243
    old_striplib striplib file_magic_cmd finish_cmds finish_eval \
4043
4279
    _LT_AC_TAGVAR(module_cmds, $1) \
4044
4280
    _LT_AC_TAGVAR(module_expsym_cmds, $1) \
4045
4281
    _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
 
4282
    _LT_AC_TAGVAR(fix_srcfile_path, $1) \
4046
4283
    _LT_AC_TAGVAR(exclude_expsyms, $1) \
4047
4284
    _LT_AC_TAGVAR(include_expsyms, $1); do
4048
4285
 
4089
4326
# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
4090
4327
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
4091
4328
#
4092
 
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
 
4329
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
4093
4330
# Free Software Foundation, Inc.
4094
4331
#
4095
4332
# This file is part of GNU Libtool:
4170
4407
# A C compiler.
4171
4408
LTCC=$lt_LTCC
4172
4409
 
 
4410
# LTCC compiler flags.
 
4411
LTCFLAGS=$lt_LTCFLAGS
 
4412
 
4173
4413
# A language-specific compiler.
4174
4414
CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
4175
4415
 
4411
4651
sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
4412
4652
 
4413
4653
# Fix the shell variable \$srcfile for the compiler.
4414
 
fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
 
4654
fix_srcfile_path=$lt_fix_srcfile_path
4415
4655
 
4416
4656
# Set to yes if exported symbols are required.
4417
4657
always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
4494
4734
# ---------------------------------
4495
4735
AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
4496
4736
[AC_REQUIRE([AC_CANONICAL_HOST])
 
4737
AC_REQUIRE([LT_AC_PROG_SED])
4497
4738
AC_REQUIRE([AC_PROG_NM])
4498
4739
AC_REQUIRE([AC_OBJEXT])
4499
4740
# Check for command to grab the raw symbol name followed by C symbol from nm.
4530
4771
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4531
4772
  lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
4532
4773
  ;;
4533
 
linux*)
 
4774
linux* | k*bsd*-gnu)
4534
4775
  if test "$host_cpu" = ia64; then
4535
4776
    symcode='[[ABCDGIRSTW]]'
4536
4777
    lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4543
4784
osf*)
4544
4785
  symcode='[[BCDEGQRST]]'
4545
4786
  ;;
4546
 
solaris* | sysv5*)
 
4787
solaris*)
4547
4788
  symcode='[[BDRT]]'
4548
4789
  ;;
 
4790
sco3.2v5*)
 
4791
  symcode='[[DT]]'
 
4792
  ;;
 
4793
sysv4.2uw2*)
 
4794
  symcode='[[DT]]'
 
4795
  ;;
 
4796
sysv5* | sco5v6* | unixware* | OpenUNIX*)
 
4797
  symcode='[[ABDT]]'
 
4798
  ;;
4549
4799
sysv4)
4550
4800
  symcode='[[DFNSTU]]'
4551
4801
  ;;
4711
4961
      # like `-m68040'.
4712
4962
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4713
4963
      ;;
4714
 
    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
 
4964
    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4715
4965
      # PIC is the default for these OSes.
4716
4966
      ;;
4717
 
    mingw* | os2* | pw32*)
 
4967
    mingw* | cygwin* | os2* | pw32*)
4718
4968
      # This hack is so that the source file can tell whether it is being
4719
4969
      # built for inclusion in a dll (and should export symbols for example).
 
4970
      # Although the cygwin gcc ignores -fPIC, still need this for old-style
 
4971
      # (--disable-auto-import) libraries
4720
4972
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
4721
4973
      ;;
4722
4974
    darwin* | rhapsody*)
4728
4980
      # DJGPP does not support shared libraries at all
4729
4981
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4730
4982
      ;;
 
4983
    interix[[3-9]]*)
 
4984
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
 
4985
      # Instead, we relocate shared libraries at runtime.
 
4986
      ;;
4731
4987
    sysv4*MP*)
4732
4988
      if test -d /usr/nec; then
4733
4989
        _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4790
5046
            ;;
4791
5047
        esac
4792
5048
        ;;
4793
 
      freebsd* | kfreebsd*-gnu | dragonfly*)
 
5049
      freebsd* | dragonfly*)
4794
5050
        # FreeBSD uses GNU C++
4795
5051
        ;;
4796
5052
      hpux9* | hpux10* | hpux11*)
4797
5053
        case $cc_basename in
4798
5054
          CC*)
4799
5055
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4800
 
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
 
5056
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4801
5057
            if test "$host_cpu" != ia64; then
4802
5058
              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4803
5059
            fi
4804
5060
            ;;
4805
5061
          aCC*)
4806
5062
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4807
 
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
 
5063
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4808
5064
            case $host_cpu in
4809
5065
            hppa*64*|ia64*)
4810
5066
              # +Z the default
4818
5074
            ;;
4819
5075
        esac
4820
5076
        ;;
 
5077
      interix*)
 
5078
        # This is c89, which is MS Visual C++ (no shared libs)
 
5079
        # Anyone wants to do a port?
 
5080
        ;;
4821
5081
      irix5* | irix6* | nonstopux*)
4822
5082
        case $cc_basename in
4823
5083
          CC*)
4829
5089
            ;;
4830
5090
        esac
4831
5091
        ;;
4832
 
      linux*)
 
5092
      linux* | k*bsd*-gnu)
4833
5093
        case $cc_basename in
4834
5094
          KCC*)
4835
5095
            # KAI C++ Compiler
4856
5116
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4857
5117
            ;;
4858
5118
          *)
 
5119
            case `$CC -V 2>&1 | sed 5q` in
 
5120
            *Sun\ C*)
 
5121
              # Sun C++ 5.9
 
5122
              _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5123
              _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5124
              _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
 
5125
              ;;
 
5126
            esac
4859
5127
            ;;
4860
5128
        esac
4861
5129
        ;;
4872
5140
            ;;
4873
5141
        esac
4874
5142
        ;;
4875
 
      netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
 
5143
      netbsd* | netbsdelf*-gnu)
4876
5144
        ;;
4877
5145
      osf3* | osf4* | osf5*)
4878
5146
        case $cc_basename in
4897
5165
        ;;
4898
5166
      psos*)
4899
5167
        ;;
4900
 
      sco*)
4901
 
        case $cc_basename in
4902
 
          CC*)
4903
 
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4904
 
            ;;
4905
 
          *)
4906
 
            ;;
4907
 
        esac
4908
 
        ;;
4909
5168
      solaris*)
4910
5169
        case $cc_basename in
4911
5170
          CC*)
4947
5206
            ;;
4948
5207
        esac
4949
5208
        ;;
4950
 
      unixware*)
 
5209
      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
 
5210
        case $cc_basename in
 
5211
          CC*)
 
5212
            _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5213
            _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5214
            _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5215
            ;;
 
5216
        esac
4951
5217
        ;;
4952
5218
      vxworks*)
4953
5219
        ;;
4978
5244
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4979
5245
      ;;
4980
5246
 
4981
 
    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
 
5247
    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4982
5248
      # PIC is the default for these OSes.
4983
5249
      ;;
4984
5250
 
4985
 
    mingw* | pw32* | os2*)
 
5251
    mingw* | cygwin* | pw32* | os2*)
4986
5252
      # This hack is so that the source file can tell whether it is being
4987
5253
      # built for inclusion in a dll (and should export symbols for example).
 
5254
      # Although the cygwin gcc ignores -fPIC, still need this for old-style
 
5255
      # (--disable-auto-import) libraries
4988
5256
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
4989
5257
      ;;
4990
5258
 
4994
5262
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4995
5263
      ;;
4996
5264
 
 
5265
    interix[[3-9]]*)
 
5266
      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
 
5267
      # Instead, we relocate shared libraries at runtime.
 
5268
      ;;
 
5269
 
4997
5270
    msdosdjgpp*)
4998
5271
      # Just because we use GCC doesn't mean we suddenly get shared libraries
4999
5272
      # on systems that don't support them.
5047
5320
       esac
5048
5321
       ;;
5049
5322
 
5050
 
    mingw* | pw32* | os2*)
 
5323
    mingw* | cygwin* | pw32* | os2*)
5051
5324
      # This hack is so that the source file can tell whether it is being
5052
5325
      # built for inclusion in a dll (and should export symbols for example).
5053
5326
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5080
5353
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5081
5354
      ;;
5082
5355
 
5083
 
    linux*)
 
5356
    linux* | k*bsd*-gnu)
5084
5357
      case $cc_basename in
5085
5358
      icc* | ecc*)
5086
5359
        _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5099
5372
        # All Alpha code is PIC.
5100
5373
        _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5101
5374
        ;;
 
5375
      *)
 
5376
        case `$CC -V 2>&1 | sed 5q` in
 
5377
        *Sun\ C*)
 
5378
          # Sun C 5.9
 
5379
          _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5380
          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5381
          _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5382
          ;;
 
5383
        *Sun\ F*)
 
5384
          # Sun Fortran 8.3 passes all unrecognized flags to the linker
 
5385
          _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5386
          _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5387
          _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
 
5388
          ;;
 
5389
        esac
 
5390
        ;;
5102
5391
      esac
5103
5392
      ;;
5104
5393
 
5108
5397
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5109
5398
      ;;
5110
5399
 
5111
 
    sco3.2v5*)
5112
 
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
5113
 
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
 
5400
    rdos*)
 
5401
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5114
5402
      ;;
5115
5403
 
5116
5404
    solaris*)
5130
5418
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5131
5419
      ;;
5132
5420
 
5133
 
    sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
 
5421
    sysv4 | sysv4.2uw2* | sysv4.3*)
5134
5422
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5135
5423
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5136
5424
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5143
5431
      fi
5144
5432
      ;;
5145
5433
 
 
5434
    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
 
5435
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 
5436
      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 
5437
      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
 
5438
      ;;
 
5439
 
5146
5440
    unicos*)
5147
5441
      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5148
5442
      _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5184
5478
    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
5185
5479
    ;;
5186
5480
esac
 
5481
 
 
5482
#
 
5483
# Check to make sure the static flag actually works.
 
5484
#
 
5485
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
 
5486
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
 
5487
  _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
 
5488
  $lt_tmp_static_flag,
 
5489
  [],
 
5490
  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
5187
5491
])
5188
5492
 
5189
5493
 
5191
5495
# ------------------------------------
5192
5496
# See if the linker supports building shared libraries.
5193
5497
AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
5194
 
[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
 
5498
[AC_REQUIRE([LT_AC_PROG_SED])dnl
 
5499
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5195
5500
ifelse([$1],[CXX],[
5196
5501
  _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5197
5502
  case $host_os in
5208
5513
    _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5209
5514
  ;;
5210
5515
  cygwin* | mingw*)
5211
 
    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
 
5516
    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
5212
5517
  ;;
5213
 
  linux*)
 
5518
  linux* | k*bsd*-gnu)
5214
5519
    _LT_AC_TAGVAR(link_all_deplibs, $1)=no
5215
5520
  ;;
5216
5521
  *)
5265
5570
      with_gnu_ld=no
5266
5571
    fi
5267
5572
    ;;
 
5573
  interix*)
 
5574
    # we just hope/assume this is gcc and not c89 (= MSVC++)
 
5575
    with_gnu_ld=yes
 
5576
    ;;
5268
5577
  openbsd*)
5269
5578
    with_gnu_ld=no
5270
5579
    ;;
5346
5655
      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5347
5656
      _LT_AC_TAGVAR(always_export_symbols, $1)=no
5348
5657
      _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5349
 
      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
 
5658
      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
5350
5659
 
5351
5660
      if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
5352
 
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
 
5661
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5353
5662
        # If the export-symbols file already is a .def file (1st line
5354
5663
        # is EXPORTS), use it as is; otherwise, prepend...
5355
5664
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5358
5667
          echo EXPORTS > $output_objdir/$soname.def;
5359
5668
          cat $export_symbols >> $output_objdir/$soname.def;
5360
5669
        fi~
5361
 
        $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
 
5670
        $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5362
5671
      else
5363
5672
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
5364
5673
      fi
5365
5674
      ;;
5366
5675
 
5367
 
    linux*)
 
5676
    interix[[3-9]]*)
 
5677
      _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
5678
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
5679
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
5680
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
5681
      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
 
5682
      # Instead, shared libraries are loaded at an image base (0x10000000 by
 
5683
      # default) and relocated if they conflict, which is a slow very memory
 
5684
      # consuming and fragmenting process.  To avoid this, we pick a random,
 
5685
      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
 
5686
      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
 
5687
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
 
5688
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
 
5689
      ;;
 
5690
 
 
5691
    gnu* | linux* | k*bsd*-gnu)
5368
5692
      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5369
5693
        tmp_addflag=
5370
5694
        case $cc_basename,$host_cpu in
5382
5706
        ifc* | ifort*)                  # Intel Fortran compiler
5383
5707
          tmp_addflag=' -nofor_main' ;;
5384
5708
        esac
5385
 
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
5709
        case `$CC -V 2>&1 | sed 5q` in
 
5710
        *Sun\ C*)                       # Sun C 5.9
 
5711
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 
5712
          tmp_sharedflag='-G' ;;
 
5713
        *Sun\ F*)                       # Sun Fortran 8.3
 
5714
          tmp_sharedflag='-G' ;;
 
5715
        *)
 
5716
          tmp_sharedflag='-shared' ;;
 
5717
        esac
 
5718
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5386
5719
 
5387
5720
        if test $supports_anon_versioning = yes; then
5388
5721
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
5389
5722
  cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5390
5723
  $echo "local: *; };" >> $output_objdir/$libname.ver~
5391
 
          $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
 
5724
          $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5392
5725
        fi
5393
5726
        _LT_AC_TAGVAR(link_all_deplibs, $1)=no
5394
5727
      else
5396
5729
      fi
5397
5730
      ;;
5398
5731
 
5399
 
    netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
 
5732
    netbsd* | netbsdelf*-gnu)
5400
5733
      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5401
5734
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5402
5735
        wlarc=
5406
5739
      fi
5407
5740
      ;;
5408
5741
 
5409
 
    solaris* | sysv5*)
 
5742
    solaris*)
5410
5743
      if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
5411
5744
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
5412
5745
        cat <<EOF 1>&2
5427
5760
      fi
5428
5761
      ;;
5429
5762
 
 
5763
    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
 
5764
      case `$LD -v 2>&1` in
 
5765
        *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
 
5766
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
5767
        cat <<_LT_EOF 1>&2
 
5768
 
 
5769
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
 
5770
*** reliably create shared libraries on SCO systems.  Therefore, libtool
 
5771
*** is disabling shared libraries support.  We urge you to upgrade GNU
 
5772
*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
 
5773
*** your PATH or compiler configuration so that the native linker is
 
5774
*** used, and then restart.
 
5775
 
 
5776
_LT_EOF
 
5777
        ;;
 
5778
        *)
 
5779
          if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 
5780
            _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
 
5781
            _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
 
5782
            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
 
5783
          else
 
5784
            _LT_AC_TAGVAR(ld_shlibs, $1)=no
 
5785
          fi
 
5786
        ;;
 
5787
      esac
 
5788
      ;;
 
5789
 
5430
5790
    sunos4*)
5431
5791
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5432
5792
      wlarc=
5460
5820
      # Note: this linker hardcodes the directories in LIBPATH if there
5461
5821
      # are no directories specified by -L.
5462
5822
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5463
 
      if test "$GCC" = yes && test -z "$link_static_flag"; then
 
5823
      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5464
5824
        # Neither direct hardcoding nor static linking is supported with a
5465
5825
        # broken collect2.
5466
5826
        _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5494
5854
            break
5495
5855
          fi
5496
5856
          done
 
5857
          ;;
5497
5858
        esac
5498
5859
 
5499
5860
        exp_sym_flag='-bexport'
5520
5881
           strings "$collect2name" | grep resolve_lib_name >/dev/null
5521
5882
          then
5522
5883
          # We have reworked collect2
5523
 
          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
5884
          :
5524
5885
          else
5525
5886
          # We have old collect2
5526
5887
          _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5531
5892
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5532
5893
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5533
5894
          fi
 
5895
          ;;
5534
5896
        esac
5535
5897
        shared_flag='-shared'
5536
5898
        if test "$aix_use_runtimelinking" = yes; then
5543
5905
        # chokes on -Wl,-G. The following line is correct:
5544
5906
          shared_flag='-G'
5545
5907
        else
5546
 
        if test "$aix_use_runtimelinking" = yes; then
 
5908
          if test "$aix_use_runtimelinking" = yes; then
5547
5909
            shared_flag='${wl}-G'
5548
5910
          else
5549
5911
            shared_flag='${wl}-bM:SRE'
5550
 
        fi
 
5912
          fi
5551
5913
        fi
5552
5914
      fi
5553
5915
 
5561
5923
       # Determine the default libpath from the value encoded in an empty executable.
5562
5924
       _LT_AC_SYS_LIBPATH_AIX
5563
5925
       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5564
 
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
 
5926
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5565
5927
       else
5566
5928
        if test "$host_cpu" = ia64; then
5567
5929
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5568
5930
          _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5569
 
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
 
5931
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
5570
5932
        else
5571
5933
         # Determine the default libpath from the value encoded in an empty executable.
5572
5934
         _LT_AC_SYS_LIBPATH_AIX
5575
5937
          # -berok will link without error, but may produce a broken library.
5576
5938
          _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5577
5939
          _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5578
 
          # -bexpall does not export symbols beginning with underscore (_)
5579
 
          _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5580
5940
          # Exported symbols can be pulled into shared objects from archives
5581
 
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
 
5941
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5582
5942
          _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
5583
5943
          # This is similar to how AIX traditionally builds its shared libraries.
5584
 
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
 
5944
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
5585
5945
        fi
5586
5946
      fi
5587
5947
      ;;
5614
5974
      # The linker will automatically build a .lib file if we build a DLL.
5615
5975
      _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
5616
5976
      # FIXME: Should let the user specify the lib program.
5617
 
      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
 
5977
      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
5618
5978
      _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
5619
5979
      _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5620
5980
      ;;
5656
6016
      case $cc_basename in
5657
6017
        xlc*)
5658
6018
         output_verbose_link_cmd='echo'
5659
 
         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
 
6019
         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
5660
6020
         _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
5661
6021
          # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
5662
 
         _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
 
6022
         _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
5663
6023
          _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
5664
6024
          ;;
5665
6025
       *)
5699
6059
      ;;
5700
6060
 
5701
6061
    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5702
 
    freebsd* | kfreebsd*-gnu | dragonfly*)
 
6062
    freebsd* | dragonfly*)
5703
6063
      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
5704
6064
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5705
6065
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5722
6082
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5723
6083
      ;;
5724
6084
 
5725
 
    hpux10* | hpux11*)
 
6085
    hpux10*)
 
6086
      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 
6087
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 
6088
      else
 
6089
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
 
6090
      fi
 
6091
      if test "$with_gnu_ld" = no; then
 
6092
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
6093
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6094
 
 
6095
        _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6096
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6097
 
 
6098
        # hardcode_minus_L: Not really in the search PATH,
 
6099
        # but as the default location of the library.
 
6100
        _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6101
      fi
 
6102
      ;;
 
6103
 
 
6104
    hpux11*)
5726
6105
      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
5727
6106
        case $host_cpu in
5728
 
        hppa*64*|ia64*)
 
6107
        hppa*64*)
5729
6108
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5730
6109
          ;;
 
6110
        ia64*)
 
6111
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 
6112
          ;;
5731
6113
        *)
5732
6114
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5733
6115
          ;;
5734
6116
        esac
5735
6117
      else
5736
6118
        case $host_cpu in
5737
 
        hppa*64*|ia64*)
5738
 
          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
 
6119
        hppa*64*)
 
6120
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6121
          ;;
 
6122
        ia64*)
 
6123
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5739
6124
          ;;
5740
6125
        *)
5741
 
          _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
 
6126
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5742
6127
          ;;
5743
6128
        esac
5744
6129
      fi
5745
6130
      if test "$with_gnu_ld" = no; then
 
6131
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
6132
        _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 
6133
 
5746
6134
        case $host_cpu in
5747
 
        hppa*64*)
5748
 
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
 
6135
        hppa*64*|ia64*)
5749
6136
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
5750
 
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5751
 
          _LT_AC_TAGVAR(hardcode_direct, $1)=no
5752
 
          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5753
 
          ;;
5754
 
        ia64*)
5755
 
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5756
 
          _LT_AC_TAGVAR(hardcode_direct, $1)=no
5757
 
          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5758
 
 
5759
 
          # hardcode_minus_L: Not really in the search PATH,
5760
 
          # but as the default location of the library.
5761
 
          _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
 
6137
          _LT_AC_TAGVAR(hardcode_direct, $1)=no
 
6138
          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5762
6139
          ;;
5763
6140
        *)
5764
 
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5765
 
          _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5766
6141
          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5767
6142
          _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5768
6143
 
5786
6161
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5787
6162
      ;;
5788
6163
 
5789
 
    netbsd* | netbsdelf*-gnu | knetbsd*-gnu)
 
6164
    netbsd* | netbsdelf*-gnu)
5790
6165
      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5791
6166
        _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
5792
6167
      else
5806
6181
      ;;
5807
6182
 
5808
6183
    openbsd*)
5809
 
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5810
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5811
 
      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5812
 
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5813
 
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
5814
 
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5815
 
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6184
      if test -f /usr/libexec/ld.so; then
 
6185
        _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 
6186
        _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6187
        if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
 
6188
          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
 
6189
          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
 
6190
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
6191
          _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
6192
        else
 
6193
          case $host_os in
 
6194
           openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
 
6195
             _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
 
6196
             _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 
6197
             ;;
 
6198
           *)
 
6199
             _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
 
6200
             _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 
6201
             ;;
 
6202
          esac
 
6203
        fi
5816
6204
      else
5817
 
       case $host_os in
5818
 
         openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5819
 
           _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5820
 
           _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5821
 
           ;;
5822
 
         *)
5823
 
           _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5824
 
           _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5825
 
           ;;
5826
 
       esac
 
6205
        _LT_AC_TAGVAR(ld_shlibs, $1)=no
5827
6206
      fi
5828
6207
      ;;
5829
6208
 
5864
6243
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
5865
6244
      ;;
5866
6245
 
5867
 
    sco3.2v5*)
5868
 
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5869
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5870
 
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
5871
 
      runpath_var=LD_RUN_PATH
5872
 
      hardcode_runpath_var=yes
5873
 
      ;;
5874
 
 
5875
6246
    solaris*)
5876
6247
      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
5877
6248
      if test "$GCC" = yes; then
5890
6261
      case $host_os in
5891
6262
      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
5892
6263
      *)
5893
 
        # The compiler driver will combine linker options so we
5894
 
        # cannot just pass the convience library names through
5895
 
        # without $wl, iff we do not link with $LD.
5896
 
        # Luckily, gcc supports the same syntax we need for Sun Studio.
 
6264
        # The compiler driver will combine and reorder linker options,
 
6265
        # but understands `-z linker_flag'.  GCC discards it without `$wl',
 
6266
        # but is careful enough not to reorder.
5897
6267
        # Supported since Solaris 2.6 (maybe 2.5.1?)
5898
 
        case $wlarc in
5899
 
        '')
5900
 
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
5901
 
        *)
5902
 
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
5903
 
        esac ;;
 
6268
        if test "$GCC" = yes; then
 
6269
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
 
6270
        else
 
6271
          _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
 
6272
        fi
 
6273
        ;;
5904
6274
      esac
5905
6275
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5906
6276
      ;;
5957
6327
      fi
5958
6328
      ;;
5959
6329
 
5960
 
    sysv4.2uw2*)
5961
 
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
5962
 
      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5963
 
      _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
5964
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5965
 
      hardcode_runpath_var=yes
5966
 
      runpath_var=LD_RUN_PATH
5967
 
      ;;
5968
 
 
5969
 
   sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[[78]]* | unixware7*)
5970
 
      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
5971
 
      if test "$GCC" = yes; then
5972
 
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5973
 
      else
5974
 
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5975
 
      fi
5976
 
      runpath_var='LD_RUN_PATH'
5977
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5978
 
      ;;
5979
 
 
5980
 
    sysv5*)
5981
 
      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
5982
 
      # $CC -shared without GNU ld will not create a library from C++
5983
 
      # object files and a static libstdc++, better avoid it by now
5984
 
      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
5985
 
      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
5986
 
                $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
5987
 
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5988
 
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5989
 
      runpath_var='LD_RUN_PATH'
 
6330
    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
 
6331
      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
6332
      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
6333
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6334
      runpath_var='LD_RUN_PATH'
 
6335
 
 
6336
      if test "$GCC" = yes; then
 
6337
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6338
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6339
      else
 
6340
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6341
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6342
      fi
 
6343
      ;;
 
6344
 
 
6345
    sysv5* | sco3.2v5* | sco5v6*)
 
6346
      # Note: We can NOT use -z defs as we might desire, because we do not
 
6347
      # link with -lc, and that would cause any symbols used from libc to
 
6348
      # always be unresolved, which means just about no library would
 
6349
      # ever link correctly.  If we're not using GNU ld we use -z text
 
6350
      # though, which does catch some bad symbols but isn't as heavy-handed
 
6351
      # as -z defs.
 
6352
      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
 
6353
      _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
 
6354
      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
 
6355
      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 
6356
      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
 
6357
      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
 
6358
      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
 
6359
      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
 
6360
      runpath_var='LD_RUN_PATH'
 
6361
 
 
6362
      if test "$GCC" = yes; then
 
6363
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6364
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6365
      else
 
6366
        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6367
        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
 
6368
      fi
5990
6369
      ;;
5991
6370
 
5992
6371
    uts4*)
6004
6383
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
6005
6384
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6006
6385
 
6007
 
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
6008
 
if test "$GCC" = yes; then
6009
 
  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
6010
 
fi
6011
 
 
6012
6386
#
6013
6387
# Do we need to explicitly link libc?
6014
6388
#
6028
6402
      # to ld, don't add -lc before -lgcc.
6029
6403
      AC_MSG_CHECKING([whether -lc should be explicitly linked in])
6030
6404
      $rm conftest*
6031
 
      printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
6405
      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6032
6406
 
6033
6407
      if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6034
6408
        soname=conftest
6036
6410
        libobjs=conftest.$ac_objext
6037
6411
        deplibs=
6038
6412
        wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
 
6413
        pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
6039
6414
        compiler_flags=-v
6040
6415
        linker_flags=-v
6041
6416
        verstring=
6130
6505
[AC_CHECK_TOOL(RC, windres, no)
6131
6506
])
6132
6507
 
 
6508
 
 
6509
# Cheap backport of AS_EXECUTABLE_P and required macros
 
6510
# from Autoconf 2.59; we should not use $as_executable_p directly.
 
6511
 
 
6512
# _AS_TEST_PREPARE
 
6513
# ----------------
 
6514
m4_ifndef([_AS_TEST_PREPARE],
 
6515
[m4_defun([_AS_TEST_PREPARE],
 
6516
[if test -x / >/dev/null 2>&1; then
 
6517
  as_executable_p='test -x'
 
6518
else
 
6519
  as_executable_p='test -f'
 
6520
fi
 
6521
])])# _AS_TEST_PREPARE
 
6522
 
 
6523
# AS_EXECUTABLE_P
 
6524
# ---------------
 
6525
# Check whether a file is executable.
 
6526
m4_ifndef([AS_EXECUTABLE_P],
 
6527
[m4_defun([AS_EXECUTABLE_P],
 
6528
[AS_REQUIRE([_AS_TEST_PREPARE])dnl
 
6529
$as_executable_p $1[]dnl
 
6530
])])# AS_EXECUTABLE_P
 
6531
 
6133
6532
# NOTE: This macro has been submitted for inclusion into   #
6134
6533
#  GNU Autoconf as AC_PROG_SED.  When it is available in   #
6135
6534
#  a released version of Autoconf we should remove this    #
6150
6549
  test -z "$as_dir" && as_dir=.
6151
6550
  for lt_ac_prog in sed gsed; do
6152
6551
    for ac_exec_ext in '' $ac_executable_extensions; do
6153
 
      if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
 
6552
      if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then
6154
6553
        lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
6155
6554
      fi
6156
6555
    done
6157
6556
  done
6158
6557
done
 
6558
IFS=$as_save_IFS
6159
6559
lt_ac_max=0
6160
6560
lt_ac_count=0
6161
6561
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
6188
6588
done
6189
6589
])
6190
6590
SED=$lt_cv_path_SED
 
6591
AC_SUBST([SED])
6191
6592
AC_MSG_RESULT([$SED])
6192
6593
])
6193
6594