~ubuntu-branches/ubuntu/feisty/libwpd/feisty

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Masayuki Hatta (mhatta)
  • Date: 2004-08-10 00:37:47 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20040810003747-5i7g92h2v88z70zo
Tags: 0.7.2-1
New upstream release

Show diffs side-by-side

added added

removed removed

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