| 1 | dnl aclocal.m4 generated automatically by aclocal 1.4-p5
|
|---|
| 2 |
|
|---|
| 3 | dnl Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
|
|---|
| 4 | dnl This file is free software; the Free Software Foundation
|
|---|
| 5 | dnl gives unlimited permission to copy and/or distribute it,
|
|---|
| 6 | dnl with or without modifications, as long as this notice is preserved.
|
|---|
| 7 |
|
|---|
| 8 | dnl This program is distributed in the hope that it will be useful,
|
|---|
| 9 | dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
|---|
| 10 | dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
|---|
| 11 | dnl PARTICULAR PURPOSE.
|
|---|
| 12 |
|
|---|
| 13 | #serial 12
|
|---|
| 14 |
|
|---|
| 15 | dnl By default, many hosts won't let programs access large files;
|
|---|
| 16 | dnl one must use special compiler options to get large-file access to work.
|
|---|
| 17 | dnl For more details about this brain damage please see:
|
|---|
| 18 | dnl http://www.sas.com/standards/large.file/x_open.20Mar96.html
|
|---|
| 19 |
|
|---|
| 20 | dnl Written by Paul Eggert <eggert@twinsun.com>.
|
|---|
| 21 |
|
|---|
| 22 | dnl Internal subroutine of AC_SYS_LARGEFILE.
|
|---|
| 23 | dnl AC_SYS_LARGEFILE_TEST_INCLUDES
|
|---|
| 24 | AC_DEFUN(AC_SYS_LARGEFILE_TEST_INCLUDES,
|
|---|
| 25 | [[#include <sys/types.h>
|
|---|
| 26 | int a[(off_t) 9223372036854775807 == 9223372036854775807 ? 1 : -1];
|
|---|
| 27 | ]])
|
|---|
| 28 |
|
|---|
| 29 | dnl Internal subroutine of AC_SYS_LARGEFILE.
|
|---|
| 30 | dnl AC_SYS_LARGEFILE_MACRO_VALUE(C-MACRO, VALUE, CACHE-VAR, COMMENT, INCLUDES, FUNCTION-BODY)
|
|---|
| 31 | AC_DEFUN(AC_SYS_LARGEFILE_MACRO_VALUE,
|
|---|
| 32 | [AC_CACHE_CHECK([for $1 value needed for large files], $3,
|
|---|
| 33 | [$3=no
|
|---|
| 34 | AC_TRY_COMPILE(AC_SYS_LARGEFILE_TEST_INCLUDES
|
|---|
| 35 | $5
|
|---|
| 36 | ,
|
|---|
| 37 | [$6],
|
|---|
| 38 | ,
|
|---|
| 39 | [AC_TRY_COMPILE([#define $1 $2]
|
|---|
| 40 | AC_SYS_LARGEFILE_TEST_INCLUDES
|
|---|
| 41 | $5
|
|---|
| 42 | ,
|
|---|
| 43 | [$6],
|
|---|
| 44 | [$3=$2])])])
|
|---|
| 45 | if test "[$]$3" != no; then
|
|---|
| 46 | AC_DEFINE_UNQUOTED([$1], [$]$3, [$4])
|
|---|
| 47 | fi])
|
|---|
| 48 |
|
|---|
| 49 | AC_DEFUN(AC_SYS_LARGEFILE,
|
|---|
| 50 | [AC_ARG_ENABLE(largefile,
|
|---|
| 51 | [ --disable-largefile omit support for large files])
|
|---|
| 52 | if test "$enable_largefile" != no; then
|
|---|
| 53 |
|
|---|
| 54 | AC_CACHE_CHECK([for special C compiler options needed for large files],
|
|---|
| 55 | ac_cv_sys_largefile_CC,
|
|---|
| 56 | [ac_cv_sys_largefile_CC=no
|
|---|
| 57 | if test "$GCC" != yes; then
|
|---|
| 58 | # IRIX 6.2 and later do not support large files by default,
|
|---|
| 59 | # so use the C compiler's -n32 option if that helps.
|
|---|
| 60 | AC_TRY_COMPILE(AC_SYS_LARGEFILE_TEST_INCLUDES, , ,
|
|---|
| 61 | [ac_save_CC="$CC"
|
|---|
| 62 | CC="$CC -n32"
|
|---|
| 63 | AC_TRY_COMPILE(AC_SYS_LARGEFILE_TEST_INCLUDES, ,
|
|---|
| 64 | ac_cv_sys_largefile_CC=' -n32')
|
|---|
| 65 | CC="$ac_save_CC"])
|
|---|
| 66 | fi])
|
|---|
| 67 | if test "$ac_cv_sys_largefile_CC" != no; then
|
|---|
| 68 | CC="$CC$ac_cv_sys_largefile_CC"
|
|---|
| 69 | fi
|
|---|
| 70 |
|
|---|
| 71 | AC_SYS_LARGEFILE_MACRO_VALUE(_FILE_OFFSET_BITS, 64,
|
|---|
| 72 | ac_cv_sys_file_offset_bits,
|
|---|
| 73 | [Number of bits in a file offset, on hosts where this is settable.])
|
|---|
| 74 | AC_SYS_LARGEFILE_MACRO_VALUE(_LARGEFILE_SOURCE, 1,
|
|---|
| 75 | ac_cv_sys_largefile_source,
|
|---|
| 76 | [Define to make ftello visible on some hosts (e.g. HP-UX 10.20).],
|
|---|
| 77 | [#include <stdio.h>], [return !ftello;])
|
|---|
| 78 | AC_SYS_LARGEFILE_MACRO_VALUE(_LARGE_FILES, 1,
|
|---|
| 79 | ac_cv_sys_large_files,
|
|---|
| 80 | [Define for large files, on AIX-style hosts.])
|
|---|
| 81 | AC_SYS_LARGEFILE_MACRO_VALUE(_XOPEN_SOURCE, 500,
|
|---|
| 82 | ac_cv_sys_xopen_source,
|
|---|
| 83 | [Define to make ftello visible on some hosts (e.g. glibc 2.1.3).],
|
|---|
| 84 | [#include <stdio.h>], [return !ftello;])
|
|---|
| 85 | fi
|
|---|
| 86 | ])
|
|---|
| 87 |
|
|---|
| 88 | # Do all the work for Automake. This macro actually does too much --
|
|---|
| 89 | # some checks are only needed if your package does certain things.
|
|---|
| 90 | # But this isn't really a big deal.
|
|---|
| 91 |
|
|---|
| 92 | # serial 1
|
|---|
| 93 |
|
|---|
| 94 | dnl Usage:
|
|---|
| 95 | dnl AM_INIT_AUTOMAKE(package,version, [no-define])
|
|---|
| 96 |
|
|---|
| 97 | AC_DEFUN([AM_INIT_AUTOMAKE],
|
|---|
| 98 | [AC_REQUIRE([AC_PROG_INSTALL])
|
|---|
| 99 | PACKAGE=[$1]
|
|---|
| 100 | AC_SUBST(PACKAGE)
|
|---|
| 101 | VERSION=[$2]
|
|---|
| 102 | AC_SUBST(VERSION)
|
|---|
| 103 | dnl test to see if srcdir already configured
|
|---|
| 104 | if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
|
|---|
| 105 | AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
|
|---|
| 106 | fi
|
|---|
| 107 | ifelse([$3],,
|
|---|
| 108 | AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
|
|---|
| 109 | AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
|
|---|
| 110 | AC_REQUIRE([AM_SANITY_CHECK])
|
|---|
| 111 | AC_REQUIRE([AC_ARG_PROGRAM])
|
|---|
| 112 | dnl FIXME This is truly gross.
|
|---|
| 113 | missing_dir=`cd $ac_aux_dir && pwd`
|
|---|
| 114 | AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
|
|---|
| 115 | AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
|
|---|
| 116 | AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
|
|---|
| 117 | AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
|
|---|
| 118 | AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
|
|---|
| 119 | AC_REQUIRE([AC_PROG_MAKE_SET])])
|
|---|
| 120 |
|
|---|
| 121 | #
|
|---|
| 122 | # Check to make sure that the build environment is sane.
|
|---|
| 123 | #
|
|---|
| 124 |
|
|---|
| 125 | AC_DEFUN([AM_SANITY_CHECK],
|
|---|
| 126 | [AC_MSG_CHECKING([whether build environment is sane])
|
|---|
| 127 | # Just in case
|
|---|
| 128 | sleep 1
|
|---|
| 129 | echo timestamp > conftestfile
|
|---|
| 130 | # Do `set' in a subshell so we don't clobber the current shell's
|
|---|
| 131 | # arguments. Must try -L first in case configure is actually a
|
|---|
| 132 | # symlink; some systems play weird games with the mod time of symlinks
|
|---|
| 133 | # (eg FreeBSD returns the mod time of the symlink's containing
|
|---|
| 134 | # directory).
|
|---|
| 135 | if (
|
|---|
| 136 | set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
|
|---|
| 137 | if test "[$]*" = "X"; then
|
|---|
| 138 | # -L didn't work.
|
|---|
| 139 | set X `ls -t $srcdir/configure conftestfile`
|
|---|
| 140 | fi
|
|---|
| 141 | if test "[$]*" != "X $srcdir/configure conftestfile" \
|
|---|
| 142 | && test "[$]*" != "X conftestfile $srcdir/configure"; then
|
|---|
| 143 |
|
|---|
| 144 | # If neither matched, then we have a broken ls. This can happen
|
|---|
| 145 | # if, for instance, CONFIG_SHELL is bash and it inherits a
|
|---|
| 146 | # broken ls alias from the environment. This has actually
|
|---|
| 147 | # happened. Such a system could not be considered "sane".
|
|---|
| 148 | AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
|
|---|
| 149 | alias in your environment])
|
|---|
| 150 | fi
|
|---|
| 151 |
|
|---|
| 152 | test "[$]2" = conftestfile
|
|---|
| 153 | )
|
|---|
| 154 | then
|
|---|
| 155 | # Ok.
|
|---|
| 156 | :
|
|---|
| 157 | else
|
|---|
| 158 | AC_MSG_ERROR([newly created file is older than distributed files!
|
|---|
| 159 | Check your system clock])
|
|---|
| 160 | fi
|
|---|
| 161 | rm -f conftest*
|
|---|
| 162 | AC_MSG_RESULT(yes)])
|
|---|
| 163 |
|
|---|
| 164 | dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
|
|---|
| 165 | dnl The program must properly implement --version.
|
|---|
| 166 | AC_DEFUN([AM_MISSING_PROG],
|
|---|
| 167 | [AC_MSG_CHECKING(for working $2)
|
|---|
| 168 | # Run test in a subshell; some versions of sh will print an error if
|
|---|
| 169 | # an executable is not found, even if stderr is redirected.
|
|---|
| 170 | # Redirect stdin to placate older versions of autoconf. Sigh.
|
|---|
| 171 | if ($2 --version) < /dev/null > /dev/null 2>&1; then
|
|---|
| 172 | $1=$2
|
|---|
| 173 | AC_MSG_RESULT(found)
|
|---|
| 174 | else
|
|---|
| 175 | $1="$3/missing $2"
|
|---|
| 176 | AC_MSG_RESULT(missing)
|
|---|
| 177 | fi
|
|---|
| 178 | AC_SUBST($1)])
|
|---|
| 179 |
|
|---|
| 180 | # isc-posix.m4 serial 1 (gettext-0.10.40)
|
|---|
| 181 | dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
|
|---|
| 182 | dnl This file is free software, distributed under the terms of the GNU
|
|---|
| 183 | dnl General Public License. As a special exception to the GNU General
|
|---|
| 184 | dnl Public License, this file may be distributed as part of a program
|
|---|
| 185 | dnl that contains a configuration script generated by Autoconf, under
|
|---|
| 186 | dnl the same distribution terms as the rest of that program.
|
|---|
| 187 |
|
|---|
| 188 | # This test replaces the one in autoconf.
|
|---|
| 189 | # Currently this macro should have the same name as the autoconf macro
|
|---|
| 190 | # because gettext's gettext.m4 (distributed in the automake package)
|
|---|
| 191 | # still uses it. Otherwise, the use in gettext.m4 makes autoheader
|
|---|
| 192 | # give these diagnostics:
|
|---|
| 193 | # configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
|
|---|
| 194 | # configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
|
|---|
| 195 |
|
|---|
| 196 | undefine([AC_ISC_POSIX])
|
|---|
| 197 |
|
|---|
| 198 | AC_DEFUN([AC_ISC_POSIX],
|
|---|
| 199 | [
|
|---|
| 200 | dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
|
|---|
| 201 | AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
|
|---|
| 202 | ]
|
|---|
| 203 | )
|
|---|
| 204 |
|
|---|
| 205 |
|
|---|
| 206 | # serial 1
|
|---|
| 207 |
|
|---|
| 208 | AC_DEFUN([AM_C_PROTOTYPES],
|
|---|
| 209 | [AC_REQUIRE([AM_PROG_CC_STDC])
|
|---|
| 210 | AC_REQUIRE([AC_PROG_CPP])
|
|---|
| 211 | AC_MSG_CHECKING([for function prototypes])
|
|---|
| 212 | if test "$am_cv_prog_cc_stdc" != no; then
|
|---|
| 213 | AC_MSG_RESULT(yes)
|
|---|
| 214 | AC_DEFINE(PROTOTYPES,1,[Define if compiler has function prototypes])
|
|---|
| 215 | U= ANSI2KNR=
|
|---|
| 216 | else
|
|---|
| 217 | AC_MSG_RESULT(no)
|
|---|
| 218 | U=_ ANSI2KNR=./ansi2knr
|
|---|
| 219 | # Ensure some checks needed by ansi2knr itself.
|
|---|
| 220 | AC_HEADER_STDC
|
|---|
| 221 | AC_CHECK_HEADERS(string.h)
|
|---|
| 222 | fi
|
|---|
| 223 | AC_SUBST(U)dnl
|
|---|
| 224 | AC_SUBST(ANSI2KNR)dnl
|
|---|
| 225 | ])
|
|---|
| 226 |
|
|---|
| 227 |
|
|---|
| 228 | # serial 1
|
|---|
| 229 |
|
|---|
| 230 | # @defmac AC_PROG_CC_STDC
|
|---|
| 231 | # @maindex PROG_CC_STDC
|
|---|
| 232 | # @ovindex CC
|
|---|
| 233 | # If the C compiler in not in ANSI C mode by default, try to add an option
|
|---|
| 234 | # to output variable @code{CC} to make it so. This macro tries various
|
|---|
| 235 | # options that select ANSI C on some system or another. It considers the
|
|---|
| 236 | # compiler to be in ANSI C mode if it handles function prototypes correctly.
|
|---|
| 237 | #
|
|---|
| 238 | # If you use this macro, you should check after calling it whether the C
|
|---|
| 239 | # compiler has been set to accept ANSI C; if not, the shell variable
|
|---|
| 240 | # @code{am_cv_prog_cc_stdc} is set to @samp{no}. If you wrote your source
|
|---|
| 241 | # code in ANSI C, you can make an un-ANSIfied copy of it by using the
|
|---|
| 242 | # program @code{ansi2knr}, which comes with Ghostscript.
|
|---|
| 243 | # @end defmac
|
|---|
| 244 |
|
|---|
| 245 | AC_DEFUN([AM_PROG_CC_STDC],
|
|---|
| 246 | [AC_REQUIRE([AC_PROG_CC])
|
|---|
| 247 | AC_BEFORE([$0], [AC_C_INLINE])
|
|---|
| 248 | AC_BEFORE([$0], [AC_C_CONST])
|
|---|
| 249 | dnl Force this before AC_PROG_CPP. Some cpp's, eg on HPUX, require
|
|---|
| 250 | dnl a magic option to avoid problems with ANSI preprocessor commands
|
|---|
| 251 | dnl like #elif.
|
|---|
| 252 | dnl FIXME: can't do this because then AC_AIX won't work due to a
|
|---|
| 253 | dnl circular dependency.
|
|---|
| 254 | dnl AC_BEFORE([$0], [AC_PROG_CPP])
|
|---|
| 255 | AC_MSG_CHECKING(for ${CC-cc} option to accept ANSI C)
|
|---|
| 256 | AC_CACHE_VAL(am_cv_prog_cc_stdc,
|
|---|
| 257 | [am_cv_prog_cc_stdc=no
|
|---|
| 258 | ac_save_CC="$CC"
|
|---|
| 259 | # Don't try gcc -ansi; that turns off useful extensions and
|
|---|
| 260 | # breaks some systems' header files.
|
|---|
| 261 | # AIX -qlanglvl=ansi
|
|---|
| 262 | # Ultrix and OSF/1 -std1
|
|---|
| 263 | # HP-UX -Aa -D_HPUX_SOURCE
|
|---|
| 264 | # SVR4 -Xc -D__EXTENSIONS__
|
|---|
| 265 | for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
|
|---|
| 266 | do
|
|---|
| 267 | CC="$ac_save_CC $ac_arg"
|
|---|
| 268 | AC_TRY_COMPILE(
|
|---|
| 269 | [#include <stdarg.h>
|
|---|
| 270 | #include <stdio.h>
|
|---|
| 271 | #include <sys/types.h>
|
|---|
| 272 | #include <sys/stat.h>
|
|---|
| 273 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
|
|---|
| 274 | struct buf { int x; };
|
|---|
| 275 | FILE * (*rcsopen) (struct buf *, struct stat *, int);
|
|---|
| 276 | static char *e (p, i)
|
|---|
| 277 | char **p;
|
|---|
| 278 | int i;
|
|---|
| 279 | {
|
|---|
| 280 | return p[i];
|
|---|
| 281 | }
|
|---|
| 282 | static char *f (char * (*g) (char **, int), char **p, ...)
|
|---|
| 283 | {
|
|---|
| 284 | char *s;
|
|---|
| 285 | va_list v;
|
|---|
| 286 | va_start (v,p);
|
|---|
| 287 | s = g (p, va_arg (v,int));
|
|---|
| 288 | va_end (v);
|
|---|
| 289 | return s;
|
|---|
| 290 | }
|
|---|
| 291 | int test (int i, double x);
|
|---|
| 292 | struct s1 {int (*f) (int a);};
|
|---|
| 293 | struct s2 {int (*f) (double a);};
|
|---|
| 294 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
|
|---|
| 295 | int argc;
|
|---|
| 296 | char **argv;
|
|---|
| 297 | ], [
|
|---|
| 298 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
|
|---|
| 299 | ],
|
|---|
| 300 | [am_cv_prog_cc_stdc="$ac_arg"; break])
|
|---|
| 301 | done
|
|---|
| 302 | CC="$ac_save_CC"
|
|---|
| 303 | ])
|
|---|
| 304 | if test -z "$am_cv_prog_cc_stdc"; then
|
|---|
| 305 | AC_MSG_RESULT([none needed])
|
|---|
| 306 | else
|
|---|
| 307 | AC_MSG_RESULT($am_cv_prog_cc_stdc)
|
|---|
| 308 | fi
|
|---|
| 309 | case "x$am_cv_prog_cc_stdc" in
|
|---|
| 310 | x|xno) ;;
|
|---|
| 311 | *) CC="$CC $am_cv_prog_cc_stdc" ;;
|
|---|
| 312 | esac
|
|---|
| 313 | ])
|
|---|
| 314 |
|
|---|
| 315 | # libtool.m4 - Configure libtool for the host system. -*-Shell-script-*-
|
|---|
| 316 |
|
|---|
| 317 | # serial 46 AC_PROG_LIBTOOL
|
|---|
| 318 |
|
|---|
| 319 | AC_DEFUN([AC_PROG_LIBTOOL],
|
|---|
| 320 | [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
|
|---|
| 321 |
|
|---|
| 322 | # This can be used to rebuild libtool when needed
|
|---|
| 323 | LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
|
|---|
| 324 |
|
|---|
| 325 | # Always use our own libtool.
|
|---|
| 326 | LIBTOOL='$(SHELL) $(top_builddir)/libtool'
|
|---|
| 327 | AC_SUBST(LIBTOOL)dnl
|
|---|
| 328 |
|
|---|
| 329 | # Prevent multiple expansion
|
|---|
| 330 | define([AC_PROG_LIBTOOL], [])
|
|---|
| 331 | ])
|
|---|
| 332 |
|
|---|
| 333 | AC_DEFUN([AC_LIBTOOL_SETUP],
|
|---|
| 334 | [AC_PREREQ(2.13)dnl
|
|---|
| 335 | AC_REQUIRE([AC_ENABLE_SHARED])dnl
|
|---|
| 336 | AC_REQUIRE([AC_ENABLE_STATIC])dnl
|
|---|
| 337 | AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
|
|---|
| 338 | AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
|---|
| 339 | AC_REQUIRE([AC_CANONICAL_BUILD])dnl
|
|---|
| 340 | AC_REQUIRE([AC_PROG_CC])dnl
|
|---|
| 341 | AC_REQUIRE([AC_PROG_LD])dnl
|
|---|
| 342 | AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
|
|---|
| 343 | AC_REQUIRE([AC_PROG_NM])dnl
|
|---|
| 344 | AC_REQUIRE([AC_PROG_LN_S])dnl
|
|---|
| 345 | AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
|
|---|
| 346 | AC_REQUIRE([AC_OBJEXT])dnl
|
|---|
| 347 | AC_REQUIRE([AC_EXEEXT])dnl
|
|---|
| 348 | dnl
|
|---|
| 349 |
|
|---|
| 350 | _LT_AC_PROG_ECHO_BACKSLASH
|
|---|
| 351 | # Only perform the check for file, if the check method requires it
|
|---|
| 352 | case $deplibs_check_method in
|
|---|
| 353 | file_magic*)
|
|---|
| 354 | if test "$file_magic_cmd" = '$MAGIC_CMD'; then
|
|---|
| 355 | AC_PATH_MAGIC
|
|---|
| 356 | fi
|
|---|
| 357 | ;;
|
|---|
| 358 | esac
|
|---|
| 359 |
|
|---|
| 360 | AC_CHECK_TOOL(RANLIB, ranlib, :)
|
|---|
| 361 | AC_CHECK_TOOL(STRIP, strip, :)
|
|---|
| 362 |
|
|---|
| 363 | ifdef([AC_PROVIDE_AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
|
|---|
| 364 | ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL],
|
|---|
| 365 | enable_win32_dll=yes, enable_win32_dll=no)
|
|---|
| 366 |
|
|---|
| 367 | AC_ARG_ENABLE(libtool-lock,
|
|---|
| 368 | [ --disable-libtool-lock avoid locking (might break parallel builds)])
|
|---|
| 369 | test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
|
|---|
| 370 |
|
|---|
| 371 | # Some flags need to be propagated to the compiler or linker for good
|
|---|
| 372 | # libtool support.
|
|---|
| 373 | case $host in
|
|---|
| 374 | *-*-irix6*)
|
|---|
| 375 | # Find out which ABI we are using.
|
|---|
| 376 | echo '[#]line __oline__ "configure"' > conftest.$ac_ext
|
|---|
| 377 | if AC_TRY_EVAL(ac_compile); then
|
|---|
| 378 | case `/usr/bin/file conftest.$ac_objext` in
|
|---|
| 379 | *32-bit*)
|
|---|
| 380 | LD="${LD-ld} -32"
|
|---|
| 381 | ;;
|
|---|
| 382 | *N32*)
|
|---|
| 383 | LD="${LD-ld} -n32"
|
|---|
| 384 | ;;
|
|---|
| 385 | *64-bit*)
|
|---|
| 386 | LD="${LD-ld} -64"
|
|---|
| 387 | ;;
|
|---|
| 388 | esac
|
|---|
| 389 | fi
|
|---|
| 390 | rm -rf conftest*
|
|---|
| 391 | ;;
|
|---|
| 392 |
|
|---|
| 393 | *-*-sco3.2v5*)
|
|---|
| 394 | # On SCO OpenServer 5, we need -belf to get full-featured binaries.
|
|---|
| 395 | SAVE_CFLAGS="$CFLAGS"
|
|---|
| 396 | CFLAGS="$CFLAGS -belf"
|
|---|
| 397 | AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
|
|---|
| 398 | [AC_LANG_SAVE
|
|---|
| 399 | AC_LANG_C
|
|---|
| 400 | AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
|
|---|
| 401 | AC_LANG_RESTORE])
|
|---|
| 402 | if test x"$lt_cv_cc_needs_belf" != x"yes"; then
|
|---|
| 403 | # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
|
|---|
| 404 | CFLAGS="$SAVE_CFLAGS"
|
|---|
| 405 | fi
|
|---|
| 406 | ;;
|
|---|
| 407 |
|
|---|
| 408 | ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL],
|
|---|
| 409 | [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
|
|---|
| 410 | AC_CHECK_TOOL(DLLTOOL, dlltool, false)
|
|---|
| 411 | AC_CHECK_TOOL(AS, as, false)
|
|---|
| 412 | AC_CHECK_TOOL(OBJDUMP, objdump, false)
|
|---|
| 413 |
|
|---|
| 414 | # recent cygwin and mingw systems supply a stub DllMain which the user
|
|---|
| 415 | # can override, but on older systems we have to supply one
|
|---|
| 416 | AC_CACHE_CHECK([if libtool should supply DllMain function], lt_cv_need_dllmain,
|
|---|
| 417 | [AC_TRY_LINK([],
|
|---|
| 418 | [extern int __attribute__((__stdcall__)) DllMain(void*, int, void*);
|
|---|
| 419 | DllMain (0, 0, 0);],
|
|---|
| 420 | [lt_cv_need_dllmain=no],[lt_cv_need_dllmain=yes])])
|
|---|
| 421 |
|
|---|
| 422 | case $host/$CC in
|
|---|
| 423 | *-*-cygwin*/gcc*-mno-cygwin*|*-*-mingw*)
|
|---|
| 424 | # old mingw systems require "-dll" to link a DLL, while more recent ones
|
|---|
| 425 | # require "-mdll"
|
|---|
| 426 | SAVE_CFLAGS="$CFLAGS"
|
|---|
| 427 | CFLAGS="$CFLAGS -mdll"
|
|---|
| 428 | AC_CACHE_CHECK([how to link DLLs], lt_cv_cc_dll_switch,
|
|---|
| 429 | [AC_TRY_LINK([], [], [lt_cv_cc_dll_switch=-mdll],[lt_cv_cc_dll_switch=-dll])])
|
|---|
| 430 | CFLAGS="$SAVE_CFLAGS" ;;
|
|---|
| 431 | *-*-cygwin* | *-*-pw32*)
|
|---|
| 432 | # cygwin systems need to pass --dll to the linker, and not link
|
|---|
| 433 | # crt.o which will require a WinMain@16 definition.
|
|---|
| 434 | lt_cv_cc_dll_switch="-Wl,--dll -nostartfiles" ;;
|
|---|
| 435 | esac
|
|---|
| 436 | ;;
|
|---|
| 437 | ])
|
|---|
| 438 | esac
|
|---|
| 439 |
|
|---|
| 440 | _LT_AC_LTCONFIG_HACK
|
|---|
| 441 |
|
|---|
| 442 | ])
|
|---|
| 443 |
|
|---|
| 444 | # AC_LIBTOOL_HEADER_ASSERT
|
|---|
| 445 | # ------------------------
|
|---|
| 446 | AC_DEFUN([AC_LIBTOOL_HEADER_ASSERT],
|
|---|
| 447 | [AC_CACHE_CHECK([whether $CC supports assert without backlinking],
|
|---|
| 448 | [lt_cv_func_assert_works],
|
|---|
| 449 | [case $host in
|
|---|
| 450 | *-*-solaris*)
|
|---|
| 451 | if test "$GCC" = yes && test "$with_gnu_ld" != yes; then
|
|---|
| 452 | case `$CC --version 2>/dev/null` in
|
|---|
| 453 | [[12]].*) lt_cv_func_assert_works=no ;;
|
|---|
| 454 | *) lt_cv_func_assert_works=yes ;;
|
|---|
| 455 | esac
|
|---|
| 456 | fi
|
|---|
| 457 | ;;
|
|---|
| 458 | esac])
|
|---|
| 459 |
|
|---|
| 460 | if test "x$lt_cv_func_assert_works" = xyes; then
|
|---|
| 461 | AC_CHECK_HEADERS(assert.h)
|
|---|
| 462 | fi
|
|---|
| 463 | ])# AC_LIBTOOL_HEADER_ASSERT
|
|---|
| 464 |
|
|---|
| 465 | # _LT_AC_CHECK_DLFCN
|
|---|
| 466 | # --------------------
|
|---|
| 467 | AC_DEFUN([_LT_AC_CHECK_DLFCN],
|
|---|
| 468 | [AC_CHECK_HEADERS(dlfcn.h)
|
|---|
| 469 | ])# _LT_AC_CHECK_DLFCN
|
|---|
| 470 |
|
|---|
| 471 | # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
|
|---|
| 472 | # ---------------------------------
|
|---|
| 473 | AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
|
|---|
| 474 | [AC_REQUIRE([AC_CANONICAL_HOST])
|
|---|
| 475 | AC_REQUIRE([AC_PROG_NM])
|
|---|
| 476 | AC_REQUIRE([AC_OBJEXT])
|
|---|
| 477 | # Check for command to grab the raw symbol name followed by C symbol from nm.
|
|---|
| 478 | AC_MSG_CHECKING([command to parse $NM output])
|
|---|
| 479 | AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [dnl
|
|---|
| 480 |
|
|---|
| 481 | # These are sane defaults that work on at least a few old systems.
|
|---|
| 482 | # [They come from Ultrix. What could be older than Ultrix?!! ;)]
|
|---|
| 483 |
|
|---|
| 484 | # Character class describing NM global symbol codes.
|
|---|
| 485 | symcode='[[BCDEGRST]]'
|
|---|
| 486 |
|
|---|
| 487 | # Regexp to match symbols that can be accessed directly from C.
|
|---|
| 488 | sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
|
|---|
| 489 |
|
|---|
| 490 | # Transform the above into a raw symbol and a C symbol.
|
|---|
| 491 | symxfrm='\1 \2\3 \3'
|
|---|
| 492 |
|
|---|
| 493 | # Transform an extracted symbol line into a proper C declaration
|
|---|
| 494 | lt_cv_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
|
|---|
| 495 |
|
|---|
| 496 | # Transform an extracted symbol line into symbol name and symbol address
|
|---|
| 497 | 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'"
|
|---|
| 498 |
|
|---|
| 499 | # Define system-specific variables.
|
|---|
| 500 | case $host_os in
|
|---|
| 501 | aix*)
|
|---|
| 502 | symcode='[[BCDT]]'
|
|---|
| 503 | ;;
|
|---|
| 504 | cygwin* | mingw* | pw32*)
|
|---|
| 505 | symcode='[[ABCDGISTW]]'
|
|---|
| 506 | ;;
|
|---|
| 507 | hpux*) # Its linker distinguishes data from code symbols
|
|---|
| 508 | lt_cv_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
|
|---|
| 509 | 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'"
|
|---|
| 510 | ;;
|
|---|
| 511 | irix*)
|
|---|
| 512 | symcode='[[BCDEGRST]]'
|
|---|
| 513 | ;;
|
|---|
| 514 | solaris* | sysv5*)
|
|---|
| 515 | symcode='[[BDT]]'
|
|---|
| 516 | ;;
|
|---|
| 517 | sysv4)
|
|---|
| 518 | symcode='[[DFNSTU]]'
|
|---|
| 519 | ;;
|
|---|
| 520 | esac
|
|---|
| 521 |
|
|---|
| 522 | # Handle CRLF in mingw tool chain
|
|---|
| 523 | opt_cr=
|
|---|
| 524 | case $host_os in
|
|---|
| 525 | mingw*)
|
|---|
| 526 | opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
|
|---|
| 527 | ;;
|
|---|
| 528 | esac
|
|---|
| 529 |
|
|---|
| 530 | # If we're using GNU nm, then use its standard symbol codes.
|
|---|
| 531 | if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
|
|---|
| 532 | symcode='[[ABCDGISTW]]'
|
|---|
| 533 | fi
|
|---|
| 534 |
|
|---|
| 535 | # Try without a prefix undercore, then with it.
|
|---|
| 536 | for ac_symprfx in "" "_"; do
|
|---|
| 537 |
|
|---|
| 538 | # Write the raw and C identifiers.
|
|---|
| 539 | lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
|
|---|
| 540 |
|
|---|
| 541 | # Check to see that the pipe works correctly.
|
|---|
| 542 | pipe_works=no
|
|---|
| 543 | rm -f conftest*
|
|---|
| 544 | cat > conftest.$ac_ext <<EOF
|
|---|
| 545 | #ifdef __cplusplus
|
|---|
| 546 | extern "C" {
|
|---|
| 547 | #endif
|
|---|
| 548 | char nm_test_var;
|
|---|
| 549 | void nm_test_func(){}
|
|---|
| 550 | #ifdef __cplusplus
|
|---|
| 551 | }
|
|---|
| 552 | #endif
|
|---|
| 553 | int main(){nm_test_var='a';nm_test_func();return(0);}
|
|---|
| 554 | EOF
|
|---|
| 555 |
|
|---|
| 556 | if AC_TRY_EVAL(ac_compile); then
|
|---|
| 557 | # Now try to grab the symbols.
|
|---|
| 558 | nlist=conftest.nm
|
|---|
| 559 | if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
|
|---|
| 560 | # Try sorting and uniquifying the output.
|
|---|
| 561 | if sort "$nlist" | uniq > "$nlist"T; then
|
|---|
| 562 | mv -f "$nlist"T "$nlist"
|
|---|
| 563 | else
|
|---|
| 564 | rm -f "$nlist"T
|
|---|
| 565 | fi
|
|---|
| 566 |
|
|---|
| 567 | # Make sure that we snagged all the symbols we need.
|
|---|
| 568 | if egrep ' nm_test_var$' "$nlist" >/dev/null; then
|
|---|
| 569 | if egrep ' nm_test_func$' "$nlist" >/dev/null; then
|
|---|
| 570 | cat <<EOF > conftest.$ac_ext
|
|---|
| 571 | #ifdef __cplusplus
|
|---|
| 572 | extern "C" {
|
|---|
| 573 | #endif
|
|---|
| 574 |
|
|---|
| 575 | EOF
|
|---|
| 576 | # Now generate the symbol file.
|
|---|
| 577 | eval "$lt_cv_global_symbol_to_cdecl"' < "$nlist" >> conftest.$ac_ext'
|
|---|
| 578 |
|
|---|
| 579 | cat <<EOF >> conftest.$ac_ext
|
|---|
| 580 | #if defined (__STDC__) && __STDC__
|
|---|
| 581 | # define lt_ptr void *
|
|---|
| 582 | #else
|
|---|
| 583 | # define lt_ptr char *
|
|---|
| 584 | # define const
|
|---|
| 585 | #endif
|
|---|
| 586 |
|
|---|
| 587 | /* The mapping between symbol names and symbols. */
|
|---|
| 588 | const struct {
|
|---|
| 589 | const char *name;
|
|---|
| 590 | lt_ptr address;
|
|---|
| 591 | }
|
|---|
| 592 | lt_preloaded_symbols[[]] =
|
|---|
| 593 | {
|
|---|
| 594 | EOF
|
|---|
| 595 | sed "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr) \&\2},/" < "$nlist" >> conftest.$ac_ext
|
|---|
| 596 | cat <<\EOF >> conftest.$ac_ext
|
|---|
| 597 | {0, (lt_ptr) 0}
|
|---|
| 598 | };
|
|---|
| 599 |
|
|---|
| 600 | #ifdef __cplusplus
|
|---|
| 601 | }
|
|---|
| 602 | #endif
|
|---|
| 603 | EOF
|
|---|
| 604 | # Now try linking the two files.
|
|---|
| 605 | mv conftest.$ac_objext conftstm.$ac_objext
|
|---|
| 606 | save_LIBS="$LIBS"
|
|---|
| 607 | save_CFLAGS="$CFLAGS"
|
|---|
| 608 | LIBS="conftstm.$ac_objext"
|
|---|
| 609 | CFLAGS="$CFLAGS$no_builtin_flag"
|
|---|
| 610 | if AC_TRY_EVAL(ac_link) && test -s conftest; then
|
|---|
| 611 | pipe_works=yes
|
|---|
| 612 | fi
|
|---|
| 613 | LIBS="$save_LIBS"
|
|---|
| 614 | CFLAGS="$save_CFLAGS"
|
|---|
| 615 | else
|
|---|
| 616 | echo "cannot find nm_test_func in $nlist" >&AC_FD_CC
|
|---|
| 617 | fi
|
|---|
| 618 | else
|
|---|
| 619 | echo "cannot find nm_test_var in $nlist" >&AC_FD_CC
|
|---|
| 620 | fi
|
|---|
| 621 | else
|
|---|
| 622 | echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AC_FD_CC
|
|---|
| 623 | fi
|
|---|
| 624 | else
|
|---|
| 625 | echo "$progname: failed program was:" >&AC_FD_CC
|
|---|
| 626 | cat conftest.$ac_ext >&5
|
|---|
| 627 | fi
|
|---|
| 628 | rm -f conftest* conftst*
|
|---|
| 629 |
|
|---|
| 630 | # Do not use the global_symbol_pipe unless it works.
|
|---|
| 631 | if test "$pipe_works" = yes; then
|
|---|
| 632 | break
|
|---|
| 633 | else
|
|---|
| 634 | lt_cv_sys_global_symbol_pipe=
|
|---|
| 635 | fi
|
|---|
| 636 | done
|
|---|
| 637 | ])
|
|---|
| 638 | global_symbol_pipe="$lt_cv_sys_global_symbol_pipe"
|
|---|
| 639 | if test -z "$lt_cv_sys_global_symbol_pipe"; then
|
|---|
| 640 | global_symbol_to_cdecl=
|
|---|
| 641 | global_symbol_to_c_name_address=
|
|---|
| 642 | else
|
|---|
| 643 | global_symbol_to_cdecl="$lt_cv_global_symbol_to_cdecl"
|
|---|
| 644 | global_symbol_to_c_name_address="$lt_cv_global_symbol_to_c_name_address"
|
|---|
| 645 | fi
|
|---|
| 646 | if test -z "$global_symbol_pipe$global_symbol_to_cdec$global_symbol_to_c_name_address";
|
|---|
| 647 | then
|
|---|
| 648 | AC_MSG_RESULT(failed)
|
|---|
| 649 | else
|
|---|
| 650 | AC_MSG_RESULT(ok)
|
|---|
| 651 | fi
|
|---|
| 652 | ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
|
|---|
| 653 |
|
|---|
| 654 | # _LT_AC_LIBTOOL_SYS_PATH_SEPARATOR
|
|---|
| 655 | # ---------------------------------
|
|---|
| 656 | AC_DEFUN([_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR],
|
|---|
| 657 | [# Find the correct PATH separator. Usually this is `:', but
|
|---|
| 658 | # DJGPP uses `;' like DOS.
|
|---|
| 659 | if test "X${PATH_SEPARATOR+set}" != Xset; then
|
|---|
| 660 | UNAME=${UNAME-`uname 2>/dev/null`}
|
|---|
| 661 | case X$UNAME in
|
|---|
| 662 | *-DOS) lt_cv_sys_path_separator=';' ;;
|
|---|
| 663 | *) lt_cv_sys_path_separator=':' ;;
|
|---|
| 664 | esac
|
|---|
| 665 | PATH_SEPARATOR=$lt_cv_sys_path_separator
|
|---|
| 666 | fi
|
|---|
| 667 | ])# _LT_AC_LIBTOOL_SYS_PATH_SEPARATOR
|
|---|
| 668 |
|
|---|
| 669 | # _LT_AC_PROG_ECHO_BACKSLASH
|
|---|
| 670 | # --------------------------
|
|---|
| 671 | # Add some code to the start of the generated configure script which
|
|---|
| 672 | # will find an echo command which doesn't interpret backslashes.
|
|---|
| 673 | AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
|
|---|
| 674 | [ifdef([AC_DIVERSION_NOTICE], [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
|
|---|
| 675 | [AC_DIVERT_PUSH(NOTICE)])
|
|---|
| 676 | _LT_AC_LIBTOOL_SYS_PATH_SEPARATOR
|
|---|
| 677 |
|
|---|
| 678 | # Check that we are running under the correct shell.
|
|---|
| 679 | SHELL=${CONFIG_SHELL-/bin/sh}
|
|---|
| 680 |
|
|---|
| 681 | case X$ECHO in
|
|---|
| 682 | X*--fallback-echo)
|
|---|
| 683 | # Remove one level of quotation (which was required for Make).
|
|---|
| 684 | ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
|
|---|
| 685 | ;;
|
|---|
| 686 | esac
|
|---|
| 687 |
|
|---|
| 688 | echo=${ECHO-echo}
|
|---|
| 689 | if test "X[$]1" = X--no-reexec; then
|
|---|
| 690 | # Discard the --no-reexec flag, and continue.
|
|---|
| 691 | shift
|
|---|
| 692 | elif test "X[$]1" = X--fallback-echo; then
|
|---|
| 693 | # Avoid inline document here, it may be left over
|
|---|
| 694 | :
|
|---|
| 695 | elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then
|
|---|
| 696 | # Yippee, $echo works!
|
|---|
| 697 | :
|
|---|
| 698 | else
|
|---|
| 699 | # Restart under the correct shell.
|
|---|
| 700 | exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
|
|---|
| 701 | fi
|
|---|
| 702 |
|
|---|
| 703 | if test "X[$]1" = X--fallback-echo; then
|
|---|
| 704 | # used as fallback echo
|
|---|
| 705 | shift
|
|---|
| 706 | cat <<EOF
|
|---|
| 707 | $*
|
|---|
| 708 | EOF
|
|---|
| 709 | exit 0
|
|---|
| 710 | fi
|
|---|
| 711 |
|
|---|
| 712 | # The HP-UX ksh and POSIX shell print the target directory to stdout
|
|---|
| 713 | # if CDPATH is set.
|
|---|
| 714 | if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
|
|---|
| 715 |
|
|---|
| 716 | if test -z "$ECHO"; then
|
|---|
| 717 | if test "X${echo_test_string+set}" != Xset; then
|
|---|
| 718 | # find a string as large as possible, as long as the shell can cope with it
|
|---|
| 719 | for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
|
|---|
| 720 | # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
|
|---|
| 721 | if (echo_test_string="`eval $cmd`") 2>/dev/null &&
|
|---|
| 722 | echo_test_string="`eval $cmd`" &&
|
|---|
| 723 | (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
|
|---|
| 724 | then
|
|---|
| 725 | break
|
|---|
| 726 | fi
|
|---|
| 727 | done
|
|---|
| 728 | fi
|
|---|
| 729 |
|
|---|
| 730 | if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
|
|---|
| 731 | echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
|
|---|
| 732 | test "X$echo_testing_string" = "X$echo_test_string"; then
|
|---|
| 733 | :
|
|---|
| 734 | else
|
|---|
| 735 | # The Solaris, AIX, and Digital Unix default echo programs unquote
|
|---|
| 736 | # backslashes. This makes it impossible to quote backslashes using
|
|---|
| 737 | # echo "$something" | sed 's/\\/\\\\/g'
|
|---|
| 738 | #
|
|---|
| 739 | # So, first we look for a working echo in the user's PATH.
|
|---|
| 740 |
|
|---|
| 741 | IFS="${IFS= }"; save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
|---|
| 742 | for dir in $PATH /usr/ucb; do
|
|---|
| 743 | if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
|
|---|
| 744 | test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
|
|---|
| 745 | echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
|
|---|
| 746 | test "X$echo_testing_string" = "X$echo_test_string"; then
|
|---|
| 747 | echo="$dir/echo"
|
|---|
| 748 | break
|
|---|
| 749 | fi
|
|---|
| 750 | done
|
|---|
| 751 | IFS="$save_ifs"
|
|---|
| 752 |
|
|---|
| 753 | if test "X$echo" = Xecho; then
|
|---|
| 754 | # We didn't find a better echo, so look for alternatives.
|
|---|
| 755 | if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
|
|---|
| 756 | echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
|
|---|
| 757 | test "X$echo_testing_string" = "X$echo_test_string"; then
|
|---|
| 758 | # This shell has a builtin print -r that does the trick.
|
|---|
| 759 | echo='print -r'
|
|---|
| 760 | elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
|
|---|
| 761 | test "X$CONFIG_SHELL" != X/bin/ksh; then
|
|---|
| 762 | # If we have ksh, try running configure again with it.
|
|---|
| 763 | ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
|
|---|
| 764 | export ORIGINAL_CONFIG_SHELL
|
|---|
| 765 | CONFIG_SHELL=/bin/ksh
|
|---|
| 766 | export CONFIG_SHELL
|
|---|
| 767 | exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
|
|---|
| 768 | else
|
|---|
| 769 | # Try using printf.
|
|---|
| 770 | echo='printf %s\n'
|
|---|
| 771 | if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
|
|---|
| 772 | echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
|
|---|
| 773 | test "X$echo_testing_string" = "X$echo_test_string"; then
|
|---|
| 774 | # Cool, printf works
|
|---|
| 775 | :
|
|---|
| 776 | elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
|
|---|
| 777 | test "X$echo_testing_string" = 'X\t' &&
|
|---|
| 778 | echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
|
|---|
| 779 | test "X$echo_testing_string" = "X$echo_test_string"; then
|
|---|
| 780 | CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
|
|---|
| 781 | export CONFIG_SHELL
|
|---|
| 782 | SHELL="$CONFIG_SHELL"
|
|---|
| 783 | export SHELL
|
|---|
| 784 | echo="$CONFIG_SHELL [$]0 --fallback-echo"
|
|---|
| 785 | elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
|
|---|
| 786 | test "X$echo_testing_string" = 'X\t' &&
|
|---|
| 787 | echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
|
|---|
| 788 | test "X$echo_testing_string" = "X$echo_test_string"; then
|
|---|
| 789 | echo="$CONFIG_SHELL [$]0 --fallback-echo"
|
|---|
| 790 | else
|
|---|
| 791 | # maybe with a smaller string...
|
|---|
| 792 | prev=:
|
|---|
| 793 |
|
|---|
| 794 | for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
|
|---|
| 795 | if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
|
|---|
| 796 | then
|
|---|
| 797 | break
|
|---|
| 798 | fi
|
|---|
| 799 | prev="$cmd"
|
|---|
| 800 | done
|
|---|
| 801 |
|
|---|
| 802 | if test "$prev" != 'sed 50q "[$]0"'; then
|
|---|
| 803 | echo_test_string=`eval $prev`
|
|---|
| 804 | export echo_test_string
|
|---|
| 805 | exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
|
|---|
| 806 | else
|
|---|
| 807 | # Oops. We lost completely, so just stick with echo.
|
|---|
| 808 | echo=echo
|
|---|
| 809 | fi
|
|---|
| 810 | fi
|
|---|
| 811 | fi
|
|---|
| 812 | fi
|
|---|
| 813 | fi
|
|---|
| 814 | fi
|
|---|
| 815 |
|
|---|
| 816 | # Copy echo and quote the copy suitably for passing to libtool from
|
|---|
| 817 | # the Makefile, instead of quoting the original, which is used later.
|
|---|
| 818 | ECHO=$echo
|
|---|
| 819 | if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
|
|---|
| 820 | ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
|
|---|
| 821 | fi
|
|---|
| 822 |
|
|---|
| 823 | AC_SUBST(ECHO)
|
|---|
| 824 | AC_DIVERT_POP
|
|---|
| 825 | ])# _LT_AC_PROG_ECHO_BACKSLASH
|
|---|
| 826 |
|
|---|
| 827 | # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
|
|---|
| 828 | # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
|
|---|
| 829 | # ------------------------------------------------------------------
|
|---|
| 830 | AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
|
|---|
| 831 | [if test "$cross_compiling" = yes; then :
|
|---|
| 832 | [$4]
|
|---|
| 833 | else
|
|---|
| 834 | AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
|
|---|
| 835 | lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
|---|
| 836 | lt_status=$lt_dlunknown
|
|---|
| 837 | cat > conftest.$ac_ext <<EOF
|
|---|
| 838 | [#line __oline__ "configure"
|
|---|
| 839 | #include "confdefs.h"
|
|---|
| 840 |
|
|---|
| 841 | #if HAVE_DLFCN_H
|
|---|
| 842 | #include <dlfcn.h>
|
|---|
| 843 | #endif
|
|---|
| 844 |
|
|---|
| 845 | #include <stdio.h>
|
|---|
| 846 |
|
|---|
| 847 | #ifdef RTLD_GLOBAL
|
|---|
| 848 | # define LT_DLGLOBAL RTLD_GLOBAL
|
|---|
| 849 | #else
|
|---|
| 850 | # ifdef DL_GLOBAL
|
|---|
| 851 | # define LT_DLGLOBAL DL_GLOBAL
|
|---|
| 852 | # else
|
|---|
| 853 | # define LT_DLGLOBAL 0
|
|---|
| 854 | # endif
|
|---|
| 855 | #endif
|
|---|
| 856 |
|
|---|
| 857 | /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
|
|---|
| 858 | find out it does not work in some platform. */
|
|---|
| 859 | #ifndef LT_DLLAZY_OR_NOW
|
|---|
| 860 | # ifdef RTLD_LAZY
|
|---|
| 861 | # define LT_DLLAZY_OR_NOW RTLD_LAZY
|
|---|
| 862 | # else
|
|---|
| 863 | # ifdef DL_LAZY
|
|---|
| 864 | # define LT_DLLAZY_OR_NOW DL_LAZY
|
|---|
| 865 | # else
|
|---|
| 866 | # ifdef RTLD_NOW
|
|---|
| 867 | # define LT_DLLAZY_OR_NOW RTLD_NOW
|
|---|
| 868 | # else
|
|---|
| 869 | # ifdef DL_NOW
|
|---|
| 870 | # define LT_DLLAZY_OR_NOW DL_NOW
|
|---|
| 871 | # else
|
|---|
| 872 | # define LT_DLLAZY_OR_NOW 0
|
|---|
| 873 | # endif
|
|---|
| 874 | # endif
|
|---|
| 875 | # endif
|
|---|
| 876 | # endif
|
|---|
| 877 | #endif
|
|---|
| 878 |
|
|---|
| 879 | #ifdef __cplusplus
|
|---|
| 880 | extern "C" void exit (int);
|
|---|
| 881 | #endif
|
|---|
| 882 |
|
|---|
| 883 | void fnord() { int i=42;}
|
|---|
| 884 | int main ()
|
|---|
| 885 | {
|
|---|
| 886 | void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
|
|---|
| 887 | int status = $lt_dlunknown;
|
|---|
| 888 |
|
|---|
| 889 | if (self)
|
|---|
| 890 | {
|
|---|
| 891 | if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
|
|---|
| 892 | else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
|
|---|
| 893 | /* dlclose (self); */
|
|---|
| 894 | }
|
|---|
| 895 |
|
|---|
| 896 | exit (status);
|
|---|
| 897 | }]
|
|---|
| 898 | EOF
|
|---|
| 899 | if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
|
|---|
| 900 | (./conftest; exit; ) 2>/dev/null
|
|---|
| 901 | lt_status=$?
|
|---|
| 902 | case x$lt_status in
|
|---|
| 903 | x$lt_dlno_uscore) $1 ;;
|
|---|
| 904 | x$lt_dlneed_uscore) $2 ;;
|
|---|
| 905 | x$lt_unknown|x*) $3 ;;
|
|---|
| 906 | esac
|
|---|
| 907 | else :
|
|---|
| 908 | # compilation failed
|
|---|
| 909 | $3
|
|---|
| 910 | fi
|
|---|
| 911 | fi
|
|---|
| 912 | rm -fr conftest*
|
|---|
| 913 | ])# _LT_AC_TRY_DLOPEN_SELF
|
|---|
| 914 |
|
|---|
| 915 | # AC_LIBTOOL_DLOPEN_SELF
|
|---|
| 916 | # -------------------
|
|---|
| 917 | AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
|
|---|
| 918 | [if test "x$enable_dlopen" != xyes; then
|
|---|
| 919 | enable_dlopen=unknown
|
|---|
| 920 | enable_dlopen_self=unknown
|
|---|
| 921 | enable_dlopen_self_static=unknown
|
|---|
| 922 | else
|
|---|
| 923 | lt_cv_dlopen=no
|
|---|
| 924 | lt_cv_dlopen_libs=
|
|---|
| 925 |
|
|---|
| 926 | case $host_os in
|
|---|
| 927 | beos*)
|
|---|
| 928 | lt_cv_dlopen="load_add_on"
|
|---|
| 929 | lt_cv_dlopen_libs=
|
|---|
| 930 | lt_cv_dlopen_self=yes
|
|---|
| 931 | ;;
|
|---|
| 932 |
|
|---|
| 933 | cygwin* | mingw* | pw32*)
|
|---|
| 934 | lt_cv_dlopen="LoadLibrary"
|
|---|
| 935 | lt_cv_dlopen_libs=
|
|---|
| 936 | ;;
|
|---|
| 937 |
|
|---|
| 938 | *)
|
|---|
| 939 | AC_CHECK_FUNC([shl_load],
|
|---|
| 940 | [lt_cv_dlopen="shl_load"],
|
|---|
| 941 | [AC_CHECK_LIB([dld], [shl_load],
|
|---|
| 942 | [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
|
|---|
| 943 | [AC_CHECK_FUNC([dlopen],
|
|---|
| 944 | [lt_cv_dlopen="dlopen"],
|
|---|
| 945 | [AC_CHECK_LIB([dl], [dlopen],
|
|---|
| 946 | [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
|
|---|
| 947 | [AC_CHECK_LIB([svld], [dlopen],
|
|---|
| 948 | [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
|
|---|
| 949 | [AC_CHECK_LIB([dld], [dld_link],
|
|---|
| 950 | [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
|
|---|
| 951 | ])
|
|---|
| 952 | ])
|
|---|
| 953 | ])
|
|---|
| 954 | ])
|
|---|
| 955 | ])
|
|---|
| 956 | ;;
|
|---|
| 957 | esac
|
|---|
| 958 |
|
|---|
| 959 | if test "x$lt_cv_dlopen" != xno; then
|
|---|
| 960 | enable_dlopen=yes
|
|---|
| 961 | else
|
|---|
| 962 | enable_dlopen=no
|
|---|
| 963 | fi
|
|---|
| 964 |
|
|---|
| 965 | case $lt_cv_dlopen in
|
|---|
| 966 | dlopen)
|
|---|
| 967 | save_CPPFLAGS="$CPPFLAGS"
|
|---|
| 968 | AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
|
|---|
| 969 | test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
|
|---|
| 970 |
|
|---|
| 971 | save_LDFLAGS="$LDFLAGS"
|
|---|
| 972 | eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
|
|---|
| 973 |
|
|---|
| 974 | save_LIBS="$LIBS"
|
|---|
| 975 | LIBS="$lt_cv_dlopen_libs $LIBS"
|
|---|
| 976 |
|
|---|
| 977 | AC_CACHE_CHECK([whether a program can dlopen itself],
|
|---|
| 978 | lt_cv_dlopen_self, [dnl
|
|---|
| 979 | _LT_AC_TRY_DLOPEN_SELF(
|
|---|
| 980 | lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
|
|---|
| 981 | lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
|
|---|
| 982 | ])
|
|---|
| 983 |
|
|---|
| 984 | if test "x$lt_cv_dlopen_self" = xyes; then
|
|---|
| 985 | LDFLAGS="$LDFLAGS $link_static_flag"
|
|---|
| 986 | AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
|
|---|
| 987 | lt_cv_dlopen_self_static, [dnl
|
|---|
| 988 | _LT_AC_TRY_DLOPEN_SELF(
|
|---|
| 989 | lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
|
|---|
| 990 | lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
|
|---|
| 991 | ])
|
|---|
| 992 | fi
|
|---|
| 993 |
|
|---|
| 994 | CPPFLAGS="$save_CPPFLAGS"
|
|---|
| 995 | LDFLAGS="$save_LDFLAGS"
|
|---|
| 996 | LIBS="$save_LIBS"
|
|---|
| 997 | ;;
|
|---|
| 998 | esac
|
|---|
| 999 |
|
|---|
| 1000 | case $lt_cv_dlopen_self in
|
|---|
| 1001 | yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
|
|---|
| 1002 | *) enable_dlopen_self=unknown ;;
|
|---|
| 1003 | esac
|
|---|
| 1004 |
|
|---|
| 1005 | case $lt_cv_dlopen_self_static in
|
|---|
| 1006 | yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
|
|---|
| 1007 | *) enable_dlopen_self_static=unknown ;;
|
|---|
| 1008 | esac
|
|---|
| 1009 | fi
|
|---|
| 1010 | ])# AC_LIBTOOL_DLOPEN_SELF
|
|---|
| 1011 |
|
|---|
| 1012 | AC_DEFUN([_LT_AC_LTCONFIG_HACK],
|
|---|
| 1013 | [AC_REQUIRE([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])dnl
|
|---|
| 1014 | # Sed substitution that helps us do robust quoting. It backslashifies
|
|---|
| 1015 | # metacharacters that are still active within double-quoted strings.
|
|---|
| 1016 | Xsed='sed -e s/^X//'
|
|---|
| 1017 | sed_quote_subst='s/\([[\\"\\`$\\\\]]\)/\\\1/g'
|
|---|
| 1018 |
|
|---|
| 1019 | # Same as above, but do not quote variable references.
|
|---|
| 1020 | double_quote_subst='s/\([[\\"\\`\\\\]]\)/\\\1/g'
|
|---|
| 1021 |
|
|---|
| 1022 | # Sed substitution to delay expansion of an escaped shell variable in a
|
|---|
| 1023 | # double_quote_subst'ed string.
|
|---|
| 1024 | delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
|
|---|
| 1025 |
|
|---|
| 1026 | # Constants:
|
|---|
| 1027 | rm="rm -f"
|
|---|
| 1028 |
|
|---|
| 1029 | # Global variables:
|
|---|
| 1030 | default_ofile=libtool
|
|---|
| 1031 | can_build_shared=yes
|
|---|
| 1032 |
|
|---|
| 1033 | # All known linkers require a `.a' archive for static linking (except M$VC,
|
|---|
| 1034 | # which needs '.lib').
|
|---|
| 1035 | libext=a
|
|---|
| 1036 | ltmain="$ac_aux_dir/ltmain.sh"
|
|---|
| 1037 | ofile="$default_ofile"
|
|---|
| 1038 | with_gnu_ld="$lt_cv_prog_gnu_ld"
|
|---|
| 1039 | need_locks="$enable_libtool_lock"
|
|---|
| 1040 |
|
|---|
| 1041 | old_CC="$CC"
|
|---|
| 1042 | old_CFLAGS="$CFLAGS"
|
|---|
| 1043 |
|
|---|
| 1044 | # Set sane defaults for various variables
|
|---|
| 1045 | test -z "$AR" && AR=ar
|
|---|
| 1046 | test -z "$AR_FLAGS" && AR_FLAGS=cru
|
|---|
| 1047 | test -z "$AS" && AS=as
|
|---|
| 1048 | test -z "$CC" && CC=cc
|
|---|
| 1049 | test -z "$DLLTOOL" && DLLTOOL=dlltool
|
|---|
| 1050 | test -z "$LD" && LD=ld
|
|---|
| 1051 | test -z "$LN_S" && LN_S="ln -s"
|
|---|
| 1052 | test -z "$MAGIC_CMD" && MAGIC_CMD=file
|
|---|
| 1053 | test -z "$NM" && NM=nm
|
|---|
| 1054 | test -z "$OBJDUMP" && OBJDUMP=objdump
|
|---|
| 1055 | test -z "$RANLIB" && RANLIB=:
|
|---|
| 1056 | test -z "$STRIP" && STRIP=:
|
|---|
| 1057 | test -z "$ac_objext" && ac_objext=o
|
|---|
| 1058 |
|
|---|
| 1059 | if test x"$host" != x"$build"; then
|
|---|
| 1060 | ac_tool_prefix=${host_alias}-
|
|---|
| 1061 | else
|
|---|
| 1062 | ac_tool_prefix=
|
|---|
| 1063 | fi
|
|---|
| 1064 |
|
|---|
| 1065 | # Transform linux* to *-*-linux-gnu*, to support old configure scripts.
|
|---|
| 1066 | case $host_os in
|
|---|
| 1067 | linux-gnu*) ;;
|
|---|
| 1068 | linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
|
|---|
| 1069 | esac
|
|---|
| 1070 |
|
|---|
| 1071 | case $host_os in
|
|---|
| 1072 | aix3*)
|
|---|
| 1073 | # AIX sometimes has problems with the GCC collect2 program. For some
|
|---|
| 1074 | # reason, if we set the COLLECT_NAMES environment variable, the problems
|
|---|
| 1075 | # vanish in a puff of smoke.
|
|---|
| 1076 | if test "X${COLLECT_NAMES+set}" != Xset; then
|
|---|
| 1077 | COLLECT_NAMES=
|
|---|
| 1078 | export COLLECT_NAMES
|
|---|
| 1079 | fi
|
|---|
| 1080 | ;;
|
|---|
| 1081 | esac
|
|---|
| 1082 |
|
|---|
| 1083 | # Determine commands to create old-style static archives.
|
|---|
| 1084 | old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
|
|---|
| 1085 | old_postinstall_cmds='chmod 644 $oldlib'
|
|---|
| 1086 | old_postuninstall_cmds=
|
|---|
| 1087 |
|
|---|
| 1088 | if test -n "$RANLIB"; then
|
|---|
| 1089 | case $host_os in
|
|---|
| 1090 | openbsd*)
|
|---|
| 1091 | old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
|
|---|
| 1092 | ;;
|
|---|
| 1093 | *)
|
|---|
| 1094 | old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
|
|---|
| 1095 | ;;
|
|---|
| 1096 | esac
|
|---|
| 1097 | old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
|
|---|
| 1098 | fi
|
|---|
| 1099 |
|
|---|
| 1100 | # Allow CC to be a program name with arguments.
|
|---|
| 1101 | set dummy $CC
|
|---|
| 1102 | compiler="[$]2"
|
|---|
| 1103 |
|
|---|
| 1104 | AC_MSG_CHECKING([for objdir])
|
|---|
| 1105 | rm -f .libs 2>/dev/null
|
|---|
| 1106 | mkdir .libs 2>/dev/null
|
|---|
| 1107 | if test -d .libs; then
|
|---|
| 1108 | objdir=.libs
|
|---|
| 1109 | else
|
|---|
| 1110 | # MS-DOS does not allow filenames that begin with a dot.
|
|---|
| 1111 | objdir=_libs
|
|---|
| 1112 | fi
|
|---|
| 1113 | rmdir .libs 2>/dev/null
|
|---|
| 1114 | AC_MSG_RESULT($objdir)
|
|---|
| 1115 |
|
|---|
| 1116 |
|
|---|
| 1117 | AC_ARG_WITH(pic,
|
|---|
| 1118 | [ --with-pic try to use only PIC/non-PIC objects [default=use both]],
|
|---|
| 1119 | pic_mode="$withval", pic_mode=default)
|
|---|
| 1120 | test -z "$pic_mode" && pic_mode=default
|
|---|
| 1121 |
|
|---|
| 1122 | # We assume here that the value for lt_cv_prog_cc_pic will not be cached
|
|---|
| 1123 | # in isolation, and that seeing it set (from the cache) indicates that
|
|---|
| 1124 | # the associated values are set (in the cache) correctly too.
|
|---|
| 1125 | AC_MSG_CHECKING([for $compiler option to produce PIC])
|
|---|
| 1126 | AC_CACHE_VAL(lt_cv_prog_cc_pic,
|
|---|
| 1127 | [ lt_cv_prog_cc_pic=
|
|---|
| 1128 | lt_cv_prog_cc_shlib=
|
|---|
| 1129 | lt_cv_prog_cc_wl=
|
|---|
| 1130 | lt_cv_prog_cc_static=
|
|---|
| 1131 | lt_cv_prog_cc_no_builtin=
|
|---|
| 1132 | lt_cv_prog_cc_can_build_shared=$can_build_shared
|
|---|
| 1133 |
|
|---|
| 1134 | if test "$GCC" = yes; then
|
|---|
| 1135 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1136 | lt_cv_prog_cc_static='-static'
|
|---|
| 1137 |
|
|---|
| 1138 | case $host_os in
|
|---|
| 1139 | aix*)
|
|---|
| 1140 | # Below there is a dirty hack to force normal static linking with -ldl
|
|---|
| 1141 | # The problem is because libdl dynamically linked with both libc and
|
|---|
| 1142 | # libC (AIX C++ library), which obviously doesn't included in libraries
|
|---|
| 1143 | # list by gcc. This cause undefined symbols with -static flags.
|
|---|
| 1144 | # This hack allows C programs to be linked with "-static -ldl", but
|
|---|
| 1145 | # not sure about C++ programs.
|
|---|
| 1146 | lt_cv_prog_cc_static="$lt_cv_prog_cc_static ${lt_cv_prog_cc_wl}-lC"
|
|---|
| 1147 | ;;
|
|---|
| 1148 | amigaos*)
|
|---|
| 1149 | # FIXME: we need at least 68020 code to build shared libraries, but
|
|---|
| 1150 | # adding the `-m68020' flag to GCC prevents building anything better,
|
|---|
| 1151 | # like `-m68040'.
|
|---|
| 1152 | lt_cv_prog_cc_pic='-m68020 -resident32 -malways-restore-a4'
|
|---|
| 1153 | ;;
|
|---|
| 1154 | beos* | irix5* | irix6* | osf3* | osf4* | osf5*)
|
|---|
| 1155 | # PIC is the default for these OSes.
|
|---|
| 1156 | ;;
|
|---|
| 1157 | darwin* | rhapsody*)
|
|---|
| 1158 | # PIC is the default on this platform
|
|---|
| 1159 | # Common symbols not allowed in MH_DYLIB files
|
|---|
| 1160 | lt_cv_prog_cc_pic='-fno-common'
|
|---|
| 1161 | ;;
|
|---|
| 1162 | cygwin* | mingw* | pw32* | os2*)
|
|---|
| 1163 | # This hack is so that the source file can tell whether it is being
|
|---|
| 1164 | # built for inclusion in a dll (and should export symbols for example).
|
|---|
| 1165 | lt_cv_prog_cc_pic='-DDLL_EXPORT'
|
|---|
| 1166 | ;;
|
|---|
| 1167 | sysv4*MP*)
|
|---|
| 1168 | if test -d /usr/nec; then
|
|---|
| 1169 | lt_cv_prog_cc_pic=-Kconform_pic
|
|---|
| 1170 | fi
|
|---|
| 1171 | ;;
|
|---|
| 1172 | *)
|
|---|
| 1173 | lt_cv_prog_cc_pic='-fPIC'
|
|---|
| 1174 | ;;
|
|---|
| 1175 | esac
|
|---|
| 1176 | else
|
|---|
| 1177 | # PORTME Check for PIC flags for the system compiler.
|
|---|
| 1178 | case $host_os in
|
|---|
| 1179 | aix3* | aix4* | aix5*)
|
|---|
| 1180 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1181 | # All AIX code is PIC.
|
|---|
| 1182 | if test "$host_cpu" = ia64; then
|
|---|
| 1183 | # AIX 5 now supports IA64 processor
|
|---|
| 1184 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1185 | else
|
|---|
| 1186 | lt_cv_prog_cc_static='-bnso -bI:/lib/syscalls.exp'
|
|---|
| 1187 | fi
|
|---|
| 1188 | ;;
|
|---|
| 1189 |
|
|---|
| 1190 | hpux9* | hpux10* | hpux11*)
|
|---|
| 1191 | # Is there a better lt_cv_prog_cc_static that works with the bundled CC?
|
|---|
| 1192 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1193 | lt_cv_prog_cc_static="${lt_cv_prog_cc_wl}-a ${lt_cv_prog_cc_wl}archive"
|
|---|
| 1194 | lt_cv_prog_cc_pic='+Z'
|
|---|
| 1195 | ;;
|
|---|
| 1196 |
|
|---|
| 1197 | irix5* | irix6*)
|
|---|
| 1198 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1199 | lt_cv_prog_cc_static='-non_shared'
|
|---|
| 1200 | # PIC (with -KPIC) is the default.
|
|---|
| 1201 | ;;
|
|---|
| 1202 |
|
|---|
| 1203 | cygwin* | mingw* | pw32* | os2*)
|
|---|
| 1204 | # This hack is so that the source file can tell whether it is being
|
|---|
| 1205 | # built for inclusion in a dll (and should export symbols for example).
|
|---|
| 1206 | lt_cv_prog_cc_pic='-DDLL_EXPORT'
|
|---|
| 1207 | ;;
|
|---|
| 1208 |
|
|---|
| 1209 | newsos6)
|
|---|
| 1210 | lt_cv_prog_cc_pic='-KPIC'
|
|---|
| 1211 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1212 | ;;
|
|---|
| 1213 |
|
|---|
| 1214 | osf3* | osf4* | osf5*)
|
|---|
| 1215 | # All OSF/1 code is PIC.
|
|---|
| 1216 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1217 | lt_cv_prog_cc_static='-non_shared'
|
|---|
| 1218 | ;;
|
|---|
| 1219 |
|
|---|
| 1220 | sco3.2v5*)
|
|---|
| 1221 | lt_cv_prog_cc_pic='-Kpic'
|
|---|
| 1222 | lt_cv_prog_cc_static='-dn'
|
|---|
| 1223 | lt_cv_prog_cc_shlib='-belf'
|
|---|
| 1224 | ;;
|
|---|
| 1225 |
|
|---|
| 1226 | solaris*)
|
|---|
| 1227 | lt_cv_prog_cc_pic='-KPIC'
|
|---|
| 1228 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1229 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1230 | ;;
|
|---|
| 1231 |
|
|---|
| 1232 | sunos4*)
|
|---|
| 1233 | lt_cv_prog_cc_pic='-PIC'
|
|---|
| 1234 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1235 | lt_cv_prog_cc_wl='-Qoption ld '
|
|---|
| 1236 | ;;
|
|---|
| 1237 |
|
|---|
| 1238 | sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
|
|---|
| 1239 | lt_cv_prog_cc_pic='-KPIC'
|
|---|
| 1240 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1241 | if test "x$host_vendor" = xsni; then
|
|---|
| 1242 | lt_cv_prog_cc_wl='-LD'
|
|---|
| 1243 | else
|
|---|
| 1244 | lt_cv_prog_cc_wl='-Wl,'
|
|---|
| 1245 | fi
|
|---|
| 1246 | ;;
|
|---|
| 1247 |
|
|---|
| 1248 | uts4*)
|
|---|
| 1249 | lt_cv_prog_cc_pic='-pic'
|
|---|
| 1250 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1251 | ;;
|
|---|
| 1252 |
|
|---|
| 1253 | sysv4*MP*)
|
|---|
| 1254 | if test -d /usr/nec ;then
|
|---|
| 1255 | lt_cv_prog_cc_pic='-Kconform_pic'
|
|---|
| 1256 | lt_cv_prog_cc_static='-Bstatic'
|
|---|
| 1257 | fi
|
|---|
| 1258 | ;;
|
|---|
| 1259 |
|
|---|
| 1260 | *)
|
|---|
| 1261 | lt_cv_prog_cc_can_build_shared=no
|
|---|
| 1262 | ;;
|
|---|
| 1263 | esac
|
|---|
| 1264 | fi
|
|---|
| 1265 | ])
|
|---|
| 1266 | if test -z "$lt_cv_prog_cc_pic"; then
|
|---|
| 1267 | AC_MSG_RESULT([none])
|
|---|
| 1268 | else
|
|---|
| 1269 | AC_MSG_RESULT([$lt_cv_prog_cc_pic])
|
|---|
| 1270 |
|
|---|
| 1271 | # Check to make sure the pic_flag actually works.
|
|---|
| 1272 | AC_MSG_CHECKING([if $compiler PIC flag $lt_cv_prog_cc_pic works])
|
|---|
| 1273 | AC_CACHE_VAL(lt_cv_prog_cc_pic_works, [dnl
|
|---|
| 1274 | save_CFLAGS="$CFLAGS"
|
|---|
| 1275 | CFLAGS="$CFLAGS $lt_cv_prog_cc_pic -DPIC"
|
|---|
| 1276 | AC_TRY_COMPILE([], [], [dnl
|
|---|
| 1277 | case $host_os in
|
|---|
| 1278 | hpux9* | hpux10* | hpux11*)
|
|---|
| 1279 | # On HP-UX, both CC and GCC only warn that PIC is supported... then
|
|---|
| 1280 | # they create non-PIC objects. So, if there were any warnings, we
|
|---|
| 1281 | # assume that PIC is not supported.
|
|---|
| 1282 | if test -s conftest.err; then
|
|---|
| 1283 | lt_cv_prog_cc_pic_works=no
|
|---|
| 1284 | else
|
|---|
| 1285 | lt_cv_prog_cc_pic_works=yes
|
|---|
| 1286 | fi
|
|---|
| 1287 | ;;
|
|---|
| 1288 | *)
|
|---|
| 1289 | lt_cv_prog_cc_pic_works=yes
|
|---|
| 1290 | ;;
|
|---|
| 1291 | esac
|
|---|
| 1292 | ], [dnl
|
|---|
| 1293 | lt_cv_prog_cc_pic_works=no
|
|---|
| 1294 | ])
|
|---|
| 1295 | CFLAGS="$save_CFLAGS"
|
|---|
| 1296 | ])
|
|---|
| 1297 |
|
|---|
| 1298 | if test "X$lt_cv_prog_cc_pic_works" = Xno; then
|
|---|
| 1299 | lt_cv_prog_cc_pic=
|
|---|
| 1300 | lt_cv_prog_cc_can_build_shared=no
|
|---|
| 1301 | else
|
|---|
| 1302 | lt_cv_prog_cc_pic=" $lt_cv_prog_cc_pic"
|
|---|
| 1303 | fi
|
|---|
| 1304 |
|
|---|
| 1305 | AC_MSG_RESULT([$lt_cv_prog_cc_pic_works])
|
|---|
| 1306 | fi
|
|---|
| 1307 |
|
|---|
| 1308 | # Check for any special shared library compilation flags.
|
|---|
| 1309 | if test -n "$lt_cv_prog_cc_shlib"; then
|
|---|
| 1310 | AC_MSG_WARN([\`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries])
|
|---|
| 1311 | if echo "$old_CC $old_CFLAGS " | egrep -e "[[ ]]$lt_cv_prog_cc_shlib[[ ]]" >/dev/null; then :
|
|---|
| 1312 | else
|
|---|
| 1313 | AC_MSG_WARN([add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure])
|
|---|
| 1314 | lt_cv_prog_cc_can_build_shared=no
|
|---|
| 1315 | fi
|
|---|
| 1316 | fi
|
|---|
| 1317 |
|
|---|
| 1318 | AC_MSG_CHECKING([if $compiler static flag $lt_cv_prog_cc_static works])
|
|---|
| 1319 | AC_CACHE_VAL([lt_cv_prog_cc_static_works], [dnl
|
|---|
| 1320 | lt_cv_prog_cc_static_works=no
|
|---|
| 1321 | save_LDFLAGS="$LDFLAGS"
|
|---|
| 1322 | LDFLAGS="$LDFLAGS $lt_cv_prog_cc_static"
|
|---|
| 1323 | AC_TRY_LINK([], [], [lt_cv_prog_cc_static_works=yes])
|
|---|
| 1324 | LDFLAGS="$save_LDFLAGS"
|
|---|
| 1325 | ])
|
|---|
| 1326 |
|
|---|
| 1327 | # Belt *and* braces to stop my trousers falling down:
|
|---|
| 1328 | test "X$lt_cv_prog_cc_static_works" = Xno && lt_cv_prog_cc_static=
|
|---|
| 1329 | AC_MSG_RESULT([$lt_cv_prog_cc_static_works])
|
|---|
| 1330 |
|
|---|
| 1331 | pic_flag="$lt_cv_prog_cc_pic"
|
|---|
| 1332 | special_shlib_compile_flags="$lt_cv_prog_cc_shlib"
|
|---|
| 1333 | wl="$lt_cv_prog_cc_wl"
|
|---|
| 1334 | link_static_flag="$lt_cv_prog_cc_static"
|
|---|
| 1335 | no_builtin_flag="$lt_cv_prog_cc_no_builtin"
|
|---|
| 1336 | can_build_shared="$lt_cv_prog_cc_can_build_shared"
|
|---|
| 1337 |
|
|---|
| 1338 |
|
|---|
| 1339 | # Check to see if options -o and -c are simultaneously supported by compiler
|
|---|
| 1340 | AC_MSG_CHECKING([if $compiler supports -c -o file.$ac_objext])
|
|---|
| 1341 | AC_CACHE_VAL([lt_cv_compiler_c_o], [
|
|---|
| 1342 | $rm -r conftest 2>/dev/null
|
|---|
| 1343 | mkdir conftest
|
|---|
| 1344 | cd conftest
|
|---|
| 1345 | echo "int some_variable = 0;" > conftest.$ac_ext
|
|---|
| 1346 | mkdir out
|
|---|
| 1347 | # According to Tom Tromey, Ian Lance Taylor reported there are C compilers
|
|---|
| 1348 | # that will create temporary files in the current directory regardless of
|
|---|
| 1349 | # the output directory. Thus, making CWD read-only will cause this test
|
|---|
| 1350 | # to fail, enabling locking or at least warning the user not to do parallel
|
|---|
| 1351 | # builds.
|
|---|
| 1352 | chmod -w .
|
|---|
| 1353 | save_CFLAGS="$CFLAGS"
|
|---|
| 1354 | CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
|
|---|
| 1355 | compiler_c_o=no
|
|---|
| 1356 | if { (eval echo configure:__oline__: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
|
|---|
| 1357 | # The compiler can only warn and ignore the option if not recognized
|
|---|
| 1358 | # So say no if there are warnings
|
|---|
| 1359 | if test -s out/conftest.err; then
|
|---|
| 1360 | lt_cv_compiler_c_o=no
|
|---|
| 1361 | else
|
|---|
| 1362 | lt_cv_compiler_c_o=yes
|
|---|
| 1363 | fi
|
|---|
| 1364 | else
|
|---|
| 1365 | # Append any errors to the config.log.
|
|---|
| 1366 | cat out/conftest.err 1>&AC_FD_CC
|
|---|
| 1367 | lt_cv_compiler_c_o=no
|
|---|
| 1368 | fi
|
|---|
| 1369 | CFLAGS="$save_CFLAGS"
|
|---|
| 1370 | chmod u+w .
|
|---|
| 1371 | $rm conftest* out/*
|
|---|
| 1372 | rmdir out
|
|---|
| 1373 | cd ..
|
|---|
| 1374 | rmdir conftest
|
|---|
| 1375 | $rm -r conftest 2>/dev/null
|
|---|
| 1376 | ])
|
|---|
| 1377 | compiler_c_o=$lt_cv_compiler_c_o
|
|---|
| 1378 | AC_MSG_RESULT([$compiler_c_o])
|
|---|
| 1379 |
|
|---|
| 1380 | if test x"$compiler_c_o" = x"yes"; then
|
|---|
| 1381 | # Check to see if we can write to a .lo
|
|---|
| 1382 | AC_MSG_CHECKING([if $compiler supports -c -o file.lo])
|
|---|
| 1383 | AC_CACHE_VAL([lt_cv_compiler_o_lo], [
|
|---|
| 1384 | lt_cv_compiler_o_lo=no
|
|---|
| 1385 | save_CFLAGS="$CFLAGS"
|
|---|
| 1386 | CFLAGS="$CFLAGS -c -o conftest.lo"
|
|---|
| 1387 | save_objext="$ac_objext"
|
|---|
| 1388 | ac_objext=lo
|
|---|
| 1389 | AC_TRY_COMPILE([], [int some_variable = 0;], [dnl
|
|---|
| 1390 | # The compiler can only warn and ignore the option if not recognized
|
|---|
| 1391 | # So say no if there are warnings
|
|---|
| 1392 | if test -s conftest.err; then
|
|---|
| 1393 | lt_cv_compiler_o_lo=no
|
|---|
| 1394 | else
|
|---|
| 1395 | lt_cv_compiler_o_lo=yes
|
|---|
| 1396 | fi
|
|---|
| 1397 | ])
|
|---|
| 1398 | ac_objext="$save_objext"
|
|---|
| 1399 | CFLAGS="$save_CFLAGS"
|
|---|
| 1400 | ])
|
|---|
| 1401 | compiler_o_lo=$lt_cv_compiler_o_lo
|
|---|
| 1402 | AC_MSG_RESULT([$compiler_o_lo])
|
|---|
| 1403 | else
|
|---|
| 1404 | compiler_o_lo=no
|
|---|
| 1405 | fi
|
|---|
| 1406 |
|
|---|
| 1407 | # Check to see if we can do hard links to lock some files if needed
|
|---|
| 1408 | hard_links="nottested"
|
|---|
| 1409 | if test "$compiler_c_o" = no && test "$need_locks" != no; then
|
|---|
| 1410 | # do not overwrite the value of need_locks provided by the user
|
|---|
| 1411 | AC_MSG_CHECKING([if we can lock with hard links])
|
|---|
| 1412 | hard_links=yes
|
|---|
| 1413 | $rm conftest*
|
|---|
| 1414 | ln conftest.a conftest.b 2>/dev/null && hard_links=no
|
|---|
| 1415 | touch conftest.a
|
|---|
| 1416 | ln conftest.a conftest.b 2>&5 || hard_links=no
|
|---|
| 1417 | ln conftest.a conftest.b 2>/dev/null && hard_links=no
|
|---|
| 1418 | AC_MSG_RESULT([$hard_links])
|
|---|
| 1419 | if test "$hard_links" = no; then
|
|---|
| 1420 | AC_MSG_WARN([\`$CC' does not support \`-c -o', so \`make -j' may be unsafe])
|
|---|
| 1421 | need_locks=warn
|
|---|
| 1422 | fi
|
|---|
| 1423 | else
|
|---|
| 1424 | need_locks=no
|
|---|
| 1425 | fi
|
|---|
| 1426 |
|
|---|
| 1427 | if test "$GCC" = yes; then
|
|---|
| 1428 | # Check to see if options -fno-rtti -fno-exceptions are supported by compiler
|
|---|
| 1429 | AC_MSG_CHECKING([if $compiler supports -fno-rtti -fno-exceptions])
|
|---|
| 1430 | echo "int some_variable = 0;" > conftest.$ac_ext
|
|---|
| 1431 | save_CFLAGS="$CFLAGS"
|
|---|
| 1432 | CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.$ac_ext"
|
|---|
| 1433 | compiler_rtti_exceptions=no
|
|---|
| 1434 | AC_TRY_COMPILE([], [int some_variable = 0;], [dnl
|
|---|
| 1435 | # The compiler can only warn and ignore the option if not recognized
|
|---|
| 1436 | # So say no if there are warnings
|
|---|
| 1437 | if test -s conftest.err; then
|
|---|
| 1438 | compiler_rtti_exceptions=no
|
|---|
| 1439 | else
|
|---|
| 1440 | compiler_rtti_exceptions=yes
|
|---|
| 1441 | fi
|
|---|
| 1442 | ])
|
|---|
| 1443 | CFLAGS="$save_CFLAGS"
|
|---|
| 1444 | AC_MSG_RESULT([$compiler_rtti_exceptions])
|
|---|
| 1445 |
|
|---|
| 1446 | if test "$compiler_rtti_exceptions" = "yes"; then
|
|---|
| 1447 | no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions'
|
|---|
| 1448 | else
|
|---|
| 1449 | no_builtin_flag=' -fno-builtin'
|
|---|
| 1450 | fi
|
|---|
| 1451 | fi
|
|---|
| 1452 |
|
|---|
| 1453 | # See if the linker supports building shared libraries.
|
|---|
| 1454 | AC_MSG_CHECKING([whether the linker ($LD) supports shared libraries])
|
|---|
| 1455 |
|
|---|
| 1456 | allow_undefined_flag=
|
|---|
| 1457 | no_undefined_flag=
|
|---|
| 1458 | need_lib_prefix=unknown
|
|---|
| 1459 | need_version=unknown
|
|---|
| 1460 | # when you set need_version to no, make sure it does not cause -set_version
|
|---|
| 1461 | # flags to be left without arguments
|
|---|
| 1462 | archive_cmds=
|
|---|
| 1463 | archive_expsym_cmds=
|
|---|
| 1464 | old_archive_from_new_cmds=
|
|---|
| 1465 | old_archive_from_expsyms_cmds=
|
|---|
| 1466 | export_dynamic_flag_spec=
|
|---|
| 1467 | whole_archive_flag_spec=
|
|---|
| 1468 | thread_safe_flag_spec=
|
|---|
| 1469 | hardcode_into_libs=no
|
|---|
| 1470 | hardcode_libdir_flag_spec=
|
|---|
| 1471 | hardcode_libdir_separator=
|
|---|
| 1472 | hardcode_direct=no
|
|---|
| 1473 | hardcode_minus_L=no
|
|---|
| 1474 | hardcode_shlibpath_var=unsupported
|
|---|
| 1475 | runpath_var=
|
|---|
| 1476 | link_all_deplibs=unknown
|
|---|
| 1477 | always_export_symbols=no
|
|---|
| 1478 | export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
|
|---|
| 1479 | # include_expsyms should be a list of space-separated symbols to be *always*
|
|---|
| 1480 | # included in the symbol list
|
|---|
| 1481 | include_expsyms=
|
|---|
| 1482 | # exclude_expsyms can be an egrep regular expression of symbols to exclude
|
|---|
| 1483 | # it will be wrapped by ` (' and `)$', so one must not match beginning or
|
|---|
| 1484 | # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
|
|---|
| 1485 | # as well as any symbol that contains `d'.
|
|---|
| 1486 | exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
|
|---|
| 1487 | # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
|
|---|
| 1488 | # platforms (ab)use it in PIC code, but their linkers get confused if
|
|---|
| 1489 | # the symbol is explicitly referenced. Since portable code cannot
|
|---|
| 1490 | # rely on this symbol name, it's probably fine to never include it in
|
|---|
| 1491 | # preloaded symbol tables.
|
|---|
| 1492 | extract_expsyms_cmds=
|
|---|
| 1493 |
|
|---|
| 1494 | case $host_os in
|
|---|
| 1495 | cygwin* | mingw* | pw32*)
|
|---|
| 1496 | # FIXME: the MSVC++ port hasn't been tested in a loooong time
|
|---|
| 1497 | # When not using gcc, we currently assume that we are using
|
|---|
| 1498 | # Microsoft Visual C++.
|
|---|
| 1499 | if test "$GCC" != yes; then
|
|---|
| 1500 | with_gnu_ld=no
|
|---|
| 1501 | fi
|
|---|
| 1502 | ;;
|
|---|
| 1503 | openbsd*)
|
|---|
| 1504 | with_gnu_ld=no
|
|---|
| 1505 | ;;
|
|---|
| 1506 | esac
|
|---|
| 1507 |
|
|---|
| 1508 | ld_shlibs=yes
|
|---|
| 1509 | if test "$with_gnu_ld" = yes; then
|
|---|
| 1510 | # If archive_cmds runs LD, not CC, wlarc should be empty
|
|---|
| 1511 | wlarc='${wl}'
|
|---|
| 1512 |
|
|---|
| 1513 | # See if GNU ld supports shared libraries.
|
|---|
| 1514 | case $host_os in
|
|---|
| 1515 | aix3* | aix4* | aix5*)
|
|---|
| 1516 | # On AIX, the GNU linker is very broken
|
|---|
| 1517 | # Note:Check GNU linker on AIX 5-IA64 when/if it becomes available.
|
|---|
| 1518 | ld_shlibs=no
|
|---|
| 1519 | cat <<EOF 1>&2
|
|---|
| 1520 |
|
|---|
| 1521 | *** Warning: the GNU linker, at least up to release 2.9.1, is reported
|
|---|
| 1522 | *** to be unable to reliably create shared libraries on AIX.
|
|---|
| 1523 | *** Therefore, libtool is disabling shared libraries support. If you
|
|---|
| 1524 | *** really care for shared libraries, you may want to modify your PATH
|
|---|
| 1525 | *** so that a non-GNU linker is found, and then restart.
|
|---|
| 1526 |
|
|---|
| 1527 | EOF
|
|---|
| 1528 | ;;
|
|---|
| 1529 |
|
|---|
| 1530 | amigaos*)
|
|---|
| 1531 | 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)'
|
|---|
| 1532 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 1533 | hardcode_minus_L=yes
|
|---|
| 1534 |
|
|---|
| 1535 | # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
|
|---|
| 1536 | # that the semantics of dynamic libraries on AmigaOS, at least up
|
|---|
| 1537 | # to version 4, is to share data among multiple programs linked
|
|---|
| 1538 | # with the same dynamic library. Since this doesn't match the
|
|---|
| 1539 | # behavior of shared libraries on other platforms, we can use
|
|---|
| 1540 | # them.
|
|---|
| 1541 | ld_shlibs=no
|
|---|
| 1542 | ;;
|
|---|
| 1543 |
|
|---|
| 1544 | beos*)
|
|---|
| 1545 | if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
|
|---|
| 1546 | allow_undefined_flag=unsupported
|
|---|
| 1547 | # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
|
|---|
| 1548 | # support --undefined. This deserves some investigation. FIXME
|
|---|
| 1549 | archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
|---|
| 1550 | else
|
|---|
| 1551 | ld_shlibs=no
|
|---|
| 1552 | fi
|
|---|
| 1553 | ;;
|
|---|
| 1554 |
|
|---|
| 1555 | cygwin* | mingw* | pw32*)
|
|---|
| 1556 | # hardcode_libdir_flag_spec is actually meaningless, as there is
|
|---|
| 1557 | # no search path for DLLs.
|
|---|
| 1558 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 1559 | allow_undefined_flag=unsupported
|
|---|
| 1560 | always_export_symbols=yes
|
|---|
| 1561 |
|
|---|
| 1562 | extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
|
|---|
| 1563 | sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
|
|---|
| 1564 | test -f $output_objdir/impgen.exe || (cd $output_objdir && \
|
|---|
| 1565 | if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
|
|---|
| 1566 | else $CC -o impgen impgen.c ; fi)~
|
|---|
| 1567 | $output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
|
|---|
| 1568 |
|
|---|
| 1569 | old_archive_from_expsyms_cmds='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
|
|---|
| 1570 |
|
|---|
| 1571 | # cygwin and mingw dlls have different entry points and sets of symbols
|
|---|
| 1572 | # to exclude.
|
|---|
| 1573 | # FIXME: what about values for MSVC?
|
|---|
| 1574 | dll_entry=__cygwin_dll_entry@12
|
|---|
| 1575 | dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
|
|---|
| 1576 | case $host_os in
|
|---|
| 1577 | mingw*)
|
|---|
| 1578 | # mingw values
|
|---|
| 1579 | dll_entry=_DllMainCRTStartup@12
|
|---|
| 1580 | dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
|
|---|
| 1581 | ;;
|
|---|
| 1582 | esac
|
|---|
| 1583 |
|
|---|
| 1584 | # mingw and cygwin differ, and it's simplest to just exclude the union
|
|---|
| 1585 | # of the two symbol sets.
|
|---|
| 1586 | dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
|
|---|
| 1587 |
|
|---|
| 1588 | # recent cygwin and mingw systems supply a stub DllMain which the user
|
|---|
| 1589 | # can override, but on older systems we have to supply one (in ltdll.c)
|
|---|
| 1590 | if test "x$lt_cv_need_dllmain" = "xyes"; then
|
|---|
| 1591 | ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
|
|---|
| 1592 | 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~
|
|---|
| 1593 | test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
|
|---|
| 1594 | else
|
|---|
| 1595 | ltdll_obj=
|
|---|
| 1596 | ltdll_cmds=
|
|---|
| 1597 | fi
|
|---|
| 1598 |
|
|---|
| 1599 | # Extract the symbol export list from an `--export-all' def file,
|
|---|
| 1600 | # then regenerate the def file from the symbol export list, so that
|
|---|
| 1601 | # the compiled dll only exports the symbol export list.
|
|---|
| 1602 | # Be careful not to strip the DATA tag left be newer dlltools.
|
|---|
| 1603 | export_symbols_cmds="$ltdll_cmds"'
|
|---|
| 1604 | $DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
|
|---|
| 1605 | sed -e "1,/EXPORTS/d" -e "s/ @ [[0-9]]*//" -e "s/ *;.*$//" < $output_objdir/$soname-def > $export_symbols'
|
|---|
| 1606 |
|
|---|
| 1607 | # If the export-symbols file already is a .def file (1st line
|
|---|
| 1608 | # is EXPORTS), use it as is.
|
|---|
| 1609 | # If DATA tags from a recent dlltool are present, honour them!
|
|---|
| 1610 | archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
|
|---|
| 1611 | cp $export_symbols $output_objdir/$soname-def;
|
|---|
| 1612 | else
|
|---|
| 1613 | echo EXPORTS > $output_objdir/$soname-def;
|
|---|
| 1614 | _lt_hint=1;
|
|---|
| 1615 | cat $export_symbols | while read symbol; do
|
|---|
| 1616 | set dummy \$symbol;
|
|---|
| 1617 | case \[$]# in
|
|---|
| 1618 | 2) echo " \[$]2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
|
|---|
| 1619 | *) echo " \[$]2 @ \$_lt_hint \[$]3 ; " >> $output_objdir/$soname-def;;
|
|---|
| 1620 | esac;
|
|---|
| 1621 | _lt_hint=`expr 1 + \$_lt_hint`;
|
|---|
| 1622 | done;
|
|---|
| 1623 | fi~
|
|---|
| 1624 | '"$ltdll_cmds"'
|
|---|
| 1625 | $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~
|
|---|
| 1626 | $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~
|
|---|
| 1627 | $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~
|
|---|
| 1628 | $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~
|
|---|
| 1629 | $CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
|
|---|
| 1630 | ;;
|
|---|
| 1631 |
|
|---|
| 1632 | netbsd*)
|
|---|
| 1633 | if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
|
|---|
| 1634 | archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
|
|---|
| 1635 | wlarc=
|
|---|
| 1636 | else
|
|---|
| 1637 | archive_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
|---|
| 1638 | archive_expsym_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
|
|---|
| 1639 | fi
|
|---|
| 1640 | ;;
|
|---|
| 1641 |
|
|---|
| 1642 | solaris* | sysv5*)
|
|---|
| 1643 | if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
|
|---|
| 1644 | ld_shlibs=no
|
|---|
| 1645 | cat <<EOF 1>&2
|
|---|
| 1646 |
|
|---|
| 1647 | *** Warning: The releases 2.8.* of the GNU linker cannot reliably
|
|---|
| 1648 | *** create shared libraries on Solaris systems. Therefore, libtool
|
|---|
| 1649 | *** is disabling shared libraries support. We urge you to upgrade GNU
|
|---|
| 1650 | *** binutils to release 2.9.1 or newer. Another option is to modify
|
|---|
| 1651 | *** your PATH or compiler configuration so that the native linker is
|
|---|
| 1652 | *** used, and then restart.
|
|---|
| 1653 |
|
|---|
| 1654 | EOF
|
|---|
| 1655 | elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
|
|---|
| 1656 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
|---|
| 1657 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
|
|---|
| 1658 | else
|
|---|
| 1659 | ld_shlibs=no
|
|---|
| 1660 | fi
|
|---|
| 1661 | ;;
|
|---|
| 1662 |
|
|---|
| 1663 | sunos4*)
|
|---|
| 1664 | archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1665 | wlarc=
|
|---|
| 1666 | hardcode_direct=yes
|
|---|
| 1667 | hardcode_shlibpath_var=no
|
|---|
| 1668 | ;;
|
|---|
| 1669 |
|
|---|
| 1670 | *)
|
|---|
| 1671 | if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
|
|---|
| 1672 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
|---|
| 1673 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
|
|---|
| 1674 | else
|
|---|
| 1675 | ld_shlibs=no
|
|---|
| 1676 | fi
|
|---|
| 1677 | ;;
|
|---|
| 1678 | esac
|
|---|
| 1679 |
|
|---|
| 1680 | if test "$ld_shlibs" = yes; then
|
|---|
| 1681 | runpath_var=LD_RUN_PATH
|
|---|
| 1682 | hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
|
|---|
| 1683 | export_dynamic_flag_spec='${wl}--export-dynamic'
|
|---|
| 1684 | case $host_os in
|
|---|
| 1685 | cygwin* | mingw* | pw32*)
|
|---|
| 1686 | # dlltool doesn't understand --whole-archive et. al.
|
|---|
| 1687 | whole_archive_flag_spec=
|
|---|
| 1688 | ;;
|
|---|
| 1689 | *)
|
|---|
| 1690 | # ancient GNU ld didn't support --whole-archive et. al.
|
|---|
| 1691 | if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
|
|---|
| 1692 | whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
|
|---|
| 1693 | else
|
|---|
| 1694 | whole_archive_flag_spec=
|
|---|
| 1695 | fi
|
|---|
| 1696 | ;;
|
|---|
| 1697 | esac
|
|---|
| 1698 | fi
|
|---|
| 1699 | else
|
|---|
| 1700 | # PORTME fill in a description of your system's linker (not GNU ld)
|
|---|
| 1701 | case $host_os in
|
|---|
| 1702 | aix3*)
|
|---|
| 1703 | allow_undefined_flag=unsupported
|
|---|
| 1704 | always_export_symbols=yes
|
|---|
| 1705 | 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'
|
|---|
| 1706 | # Note: this linker hardcodes the directories in LIBPATH if there
|
|---|
| 1707 | # are no directories specified by -L.
|
|---|
| 1708 | hardcode_minus_L=yes
|
|---|
| 1709 | if test "$GCC" = yes && test -z "$link_static_flag"; then
|
|---|
| 1710 | # Neither direct hardcoding nor static linking is supported with a
|
|---|
| 1711 | # broken collect2.
|
|---|
| 1712 | hardcode_direct=unsupported
|
|---|
| 1713 | fi
|
|---|
| 1714 | ;;
|
|---|
| 1715 |
|
|---|
| 1716 | aix4* | aix5*)
|
|---|
| 1717 | if test "$host_cpu" = ia64; then
|
|---|
| 1718 | # On IA64, the linker does run time linking by default, so we don't
|
|---|
| 1719 | # have to do anything special.
|
|---|
| 1720 | aix_use_runtimelinking=no
|
|---|
| 1721 | exp_sym_flag='-Bexport'
|
|---|
| 1722 | no_entry_flag=""
|
|---|
| 1723 | else
|
|---|
| 1724 | aix_use_runtimelinking=no
|
|---|
| 1725 |
|
|---|
| 1726 | # Test if we are trying to use run time linking or normal
|
|---|
| 1727 | # AIX style linking. If -brtl is somewhere in LDFLAGS, we
|
|---|
| 1728 | # need to do runtime linking.
|
|---|
| 1729 | case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
|
|---|
| 1730 | for ld_flag in $LDFLAGS; do
|
|---|
| 1731 | if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
|
|---|
| 1732 | aix_use_runtimelinking=yes
|
|---|
| 1733 | break
|
|---|
| 1734 | fi
|
|---|
| 1735 | done
|
|---|
| 1736 | esac
|
|---|
| 1737 |
|
|---|
| 1738 | exp_sym_flag='-bexport'
|
|---|
| 1739 | no_entry_flag='-bnoentry'
|
|---|
| 1740 | fi
|
|---|
| 1741 |
|
|---|
| 1742 | # When large executables or shared objects are built, AIX ld can
|
|---|
| 1743 | # have problems creating the table of contents. If linking a library
|
|---|
| 1744 | # or program results in "error TOC overflow" add -mminimal-toc to
|
|---|
| 1745 | # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
|
|---|
| 1746 | # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
|
|---|
| 1747 |
|
|---|
| 1748 | hardcode_direct=yes
|
|---|
| 1749 | archive_cmds=''
|
|---|
| 1750 | hardcode_libdir_separator=':'
|
|---|
| 1751 | if test "$GCC" = yes; then
|
|---|
| 1752 | case $host_os in aix4.[[012]]|aix4.[[012]].*)
|
|---|
| 1753 | collect2name=`${CC} -print-prog-name=collect2`
|
|---|
| 1754 | if test -f "$collect2name" && \
|
|---|
| 1755 | strings "$collect2name" | grep resolve_lib_name >/dev/null
|
|---|
| 1756 | then
|
|---|
| 1757 | # We have reworked collect2
|
|---|
| 1758 | hardcode_direct=yes
|
|---|
| 1759 | else
|
|---|
| 1760 | # We have old collect2
|
|---|
| 1761 | hardcode_direct=unsupported
|
|---|
| 1762 | # It fails to find uninstalled libraries when the uninstalled
|
|---|
| 1763 | # path is not listed in the libpath. Setting hardcode_minus_L
|
|---|
| 1764 | # to unsupported forces relinking
|
|---|
| 1765 | hardcode_minus_L=yes
|
|---|
| 1766 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 1767 | hardcode_libdir_separator=
|
|---|
| 1768 | fi
|
|---|
| 1769 | esac
|
|---|
| 1770 |
|
|---|
| 1771 | shared_flag='-shared'
|
|---|
| 1772 | else
|
|---|
| 1773 | # not using gcc
|
|---|
| 1774 | if test "$host_cpu" = ia64; then
|
|---|
| 1775 | shared_flag='${wl}-G'
|
|---|
| 1776 | else
|
|---|
| 1777 | if test "$aix_use_runtimelinking" = yes; then
|
|---|
| 1778 | shared_flag='${wl}-G'
|
|---|
| 1779 | else
|
|---|
| 1780 | shared_flag='${wl}-bM:SRE'
|
|---|
| 1781 | fi
|
|---|
| 1782 | fi
|
|---|
| 1783 | fi
|
|---|
| 1784 |
|
|---|
| 1785 | # It seems that -bexpall can do strange things, so it is better to
|
|---|
| 1786 | # generate a list of symbols to export.
|
|---|
| 1787 | always_export_symbols=yes
|
|---|
| 1788 | if test "$aix_use_runtimelinking" = yes; then
|
|---|
| 1789 | # Warning - without using the other runtime loading flags (-brtl),
|
|---|
| 1790 | # -berok will link without error, but may produce a broken library.
|
|---|
| 1791 | allow_undefined_flag='-berok'
|
|---|
| 1792 | hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
|
|---|
| 1793 | 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"
|
|---|
| 1794 | else
|
|---|
| 1795 | if test "$host_cpu" = ia64; then
|
|---|
| 1796 | hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
|
|---|
| 1797 | allow_undefined_flag="-z nodefs"
|
|---|
| 1798 | 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"
|
|---|
| 1799 | else
|
|---|
| 1800 | hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
|
|---|
| 1801 | # Warning - without using the other run time loading flags,
|
|---|
| 1802 | # -berok will link without error, but may produce a broken library.
|
|---|
| 1803 | allow_undefined_flag='${wl}-berok'
|
|---|
| 1804 | # This is a bit strange, but is similar to how AIX traditionally builds
|
|---|
| 1805 | # it's shared libraries.
|
|---|
| 1806 | 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'
|
|---|
| 1807 | fi
|
|---|
| 1808 | fi
|
|---|
| 1809 | ;;
|
|---|
| 1810 |
|
|---|
| 1811 | amigaos*)
|
|---|
| 1812 | 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)'
|
|---|
| 1813 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 1814 | hardcode_minus_L=yes
|
|---|
| 1815 | # see comment about different semantics on the GNU ld section
|
|---|
| 1816 | ld_shlibs=no
|
|---|
| 1817 | ;;
|
|---|
| 1818 |
|
|---|
| 1819 | cygwin* | mingw* | pw32*)
|
|---|
| 1820 | # When not using gcc, we currently assume that we are using
|
|---|
| 1821 | # Microsoft Visual C++.
|
|---|
| 1822 | # hardcode_libdir_flag_spec is actually meaningless, as there is
|
|---|
| 1823 | # no search path for DLLs.
|
|---|
| 1824 | hardcode_libdir_flag_spec=' '
|
|---|
| 1825 | allow_undefined_flag=unsupported
|
|---|
| 1826 | # Tell ltmain to make .lib files, not .a files.
|
|---|
| 1827 | libext=lib
|
|---|
| 1828 | # FIXME: Setting linknames here is a bad hack.
|
|---|
| 1829 | archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
|
|---|
| 1830 | # The linker will automatically build a .lib file if we build a DLL.
|
|---|
| 1831 | old_archive_from_new_cmds='true'
|
|---|
| 1832 | # FIXME: Should let the user specify the lib program.
|
|---|
| 1833 | old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
|
|---|
| 1834 | fix_srcfile_path='`cygpath -w "$srcfile"`'
|
|---|
| 1835 | ;;
|
|---|
| 1836 |
|
|---|
| 1837 | darwin* | rhapsody*)
|
|---|
| 1838 | case "$host_os" in
|
|---|
| 1839 | rhapsody* | darwin1.[[012]])
|
|---|
| 1840 | allow_undefined_flag='-undefined suppress'
|
|---|
| 1841 | ;;
|
|---|
| 1842 | *) # Darwin 1.3 on
|
|---|
| 1843 | allow_undefined_flag='-flat_namespace -undefined suppress'
|
|---|
| 1844 | ;;
|
|---|
| 1845 | esac
|
|---|
| 1846 | # FIXME: Relying on posixy $() will cause problems for
|
|---|
| 1847 | # cross-compilation, but unfortunately the echo tests do not
|
|---|
| 1848 | # yet detect zsh echo's removal of \ escapes.
|
|---|
| 1849 | archive_cmds='$nonopt $(test "x$module" = xyes && echo -bundle || echo -dynamiclib) $allow_undefined_flag -o $lib $libobjs $deplibs$linker_flags -install_name $rpath/$soname $verstring'
|
|---|
| 1850 | # We need to add '_' to the symbols in $export_symbols first
|
|---|
| 1851 | #archive_expsym_cmds="$archive_cmds"' && strip -s $export_symbols'
|
|---|
| 1852 | hardcode_direct=yes
|
|---|
| 1853 | hardcode_shlibpath_var=no
|
|---|
| 1854 | whole_archive_flag_spec='-all_load $convenience'
|
|---|
| 1855 | ;;
|
|---|
| 1856 |
|
|---|
| 1857 | freebsd1*)
|
|---|
| 1858 | ld_shlibs=no
|
|---|
| 1859 | ;;
|
|---|
| 1860 |
|
|---|
| 1861 | # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
|
|---|
| 1862 | # support. Future versions do this automatically, but an explicit c++rt0.o
|
|---|
| 1863 | # does not break anything, and helps significantly (at the cost of a little
|
|---|
| 1864 | # extra space).
|
|---|
| 1865 | freebsd2.2*)
|
|---|
| 1866 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
|
|---|
| 1867 | hardcode_libdir_flag_spec='-R$libdir'
|
|---|
| 1868 | hardcode_direct=yes
|
|---|
| 1869 | hardcode_shlibpath_var=no
|
|---|
| 1870 | ;;
|
|---|
| 1871 |
|
|---|
| 1872 | # Unfortunately, older versions of FreeBSD 2 do not have this feature.
|
|---|
| 1873 | freebsd2*)
|
|---|
| 1874 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1875 | hardcode_direct=yes
|
|---|
| 1876 | hardcode_minus_L=yes
|
|---|
| 1877 | hardcode_shlibpath_var=no
|
|---|
| 1878 | ;;
|
|---|
| 1879 |
|
|---|
| 1880 | # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
|
|---|
| 1881 | freebsd*)
|
|---|
| 1882 | archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
|
|---|
| 1883 | hardcode_libdir_flag_spec='-R$libdir'
|
|---|
| 1884 | hardcode_direct=yes
|
|---|
| 1885 | hardcode_shlibpath_var=no
|
|---|
| 1886 | ;;
|
|---|
| 1887 |
|
|---|
| 1888 | hpux9* | hpux10* | hpux11*)
|
|---|
| 1889 | case $host_os in
|
|---|
| 1890 | 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' ;;
|
|---|
| 1891 | *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
|
|---|
| 1892 | esac
|
|---|
| 1893 | hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
|---|
| 1894 | hardcode_libdir_separator=:
|
|---|
| 1895 | hardcode_direct=yes
|
|---|
| 1896 | hardcode_minus_L=yes # Not in the search PATH, but as the default
|
|---|
| 1897 | # location of the library.
|
|---|
| 1898 | export_dynamic_flag_spec='${wl}-E'
|
|---|
| 1899 | ;;
|
|---|
| 1900 |
|
|---|
| 1901 | irix5* | irix6*)
|
|---|
| 1902 | if test "$GCC" = yes; then
|
|---|
| 1903 | 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'
|
|---|
| 1904 | else
|
|---|
| 1905 | 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'
|
|---|
| 1906 | fi
|
|---|
| 1907 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|---|
| 1908 | hardcode_libdir_separator=:
|
|---|
| 1909 | link_all_deplibs=yes
|
|---|
| 1910 | ;;
|
|---|
| 1911 |
|
|---|
| 1912 | netbsd*)
|
|---|
| 1913 | if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
|
|---|
| 1914 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
|
|---|
| 1915 | else
|
|---|
| 1916 | archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
|
|---|
| 1917 | fi
|
|---|
| 1918 | hardcode_libdir_flag_spec='-R$libdir'
|
|---|
| 1919 | hardcode_direct=yes
|
|---|
| 1920 | hardcode_shlibpath_var=no
|
|---|
| 1921 | ;;
|
|---|
| 1922 |
|
|---|
| 1923 | newsos6)
|
|---|
| 1924 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1925 | hardcode_direct=yes
|
|---|
| 1926 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|---|
| 1927 | hardcode_libdir_separator=:
|
|---|
| 1928 | hardcode_shlibpath_var=no
|
|---|
| 1929 | ;;
|
|---|
| 1930 |
|
|---|
| 1931 | openbsd*)
|
|---|
| 1932 | hardcode_direct=yes
|
|---|
| 1933 | hardcode_shlibpath_var=no
|
|---|
| 1934 | if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
|---|
| 1935 | archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1936 | hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
|---|
| 1937 | export_dynamic_flag_spec='${wl}-E'
|
|---|
| 1938 | else
|
|---|
| 1939 | case "$host_os" in
|
|---|
| 1940 | openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
|
|---|
| 1941 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1942 | hardcode_libdir_flag_spec='-R$libdir'
|
|---|
| 1943 | ;;
|
|---|
| 1944 | *)
|
|---|
| 1945 | archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1946 | hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
|---|
| 1947 | ;;
|
|---|
| 1948 | esac
|
|---|
| 1949 | fi
|
|---|
| 1950 | ;;
|
|---|
| 1951 |
|
|---|
| 1952 | os2*)
|
|---|
| 1953 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 1954 | hardcode_minus_L=yes
|
|---|
| 1955 | allow_undefined_flag=unsupported
|
|---|
| 1956 | 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'
|
|---|
| 1957 | old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
|
|---|
| 1958 | ;;
|
|---|
| 1959 |
|
|---|
| 1960 | osf3*)
|
|---|
| 1961 | if test "$GCC" = yes; then
|
|---|
| 1962 | allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
|
|---|
| 1963 | 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'
|
|---|
| 1964 | else
|
|---|
| 1965 | allow_undefined_flag=' -expect_unresolved \*'
|
|---|
| 1966 | 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'
|
|---|
| 1967 | fi
|
|---|
| 1968 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|---|
| 1969 | hardcode_libdir_separator=:
|
|---|
| 1970 | ;;
|
|---|
| 1971 |
|
|---|
| 1972 | osf4* | osf5*) # as osf3* with the addition of -msym flag
|
|---|
| 1973 | if test "$GCC" = yes; then
|
|---|
| 1974 | allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
|
|---|
| 1975 | 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'
|
|---|
| 1976 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|---|
| 1977 | else
|
|---|
| 1978 | allow_undefined_flag=' -expect_unresolved \*'
|
|---|
| 1979 | 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'
|
|---|
| 1980 | archive_expsym_cmds='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
|
|---|
| 1981 | $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'
|
|---|
| 1982 |
|
|---|
| 1983 | #Both c and cxx compiler support -rpath directly
|
|---|
| 1984 | hardcode_libdir_flag_spec='-rpath $libdir'
|
|---|
| 1985 | fi
|
|---|
| 1986 | hardcode_libdir_separator=:
|
|---|
| 1987 | ;;
|
|---|
| 1988 |
|
|---|
| 1989 | sco3.2v5*)
|
|---|
| 1990 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 1991 | hardcode_shlibpath_var=no
|
|---|
| 1992 | runpath_var=LD_RUN_PATH
|
|---|
| 1993 | hardcode_runpath_var=yes
|
|---|
| 1994 | export_dynamic_flag_spec='${wl}-Bexport'
|
|---|
| 1995 | ;;
|
|---|
| 1996 |
|
|---|
| 1997 | solaris*)
|
|---|
| 1998 | # gcc --version < 3.0 without binutils cannot create self contained
|
|---|
| 1999 | # shared libraries reliably, requiring libgcc.a to resolve some of
|
|---|
| 2000 | # the object symbols generated in some cases. Libraries that use
|
|---|
| 2001 | # assert need libgcc.a to resolve __eprintf, for example. Linking
|
|---|
| 2002 | # a copy of libgcc.a into every shared library to guarantee resolving
|
|---|
| 2003 | # such symbols causes other problems: According to Tim Van Holder
|
|---|
| 2004 | # <tim.van.holder@pandora.be>, C++ libraries end up with a separate
|
|---|
| 2005 | # (to the application) exception stack for one thing.
|
|---|
| 2006 | no_undefined_flag=' -z defs'
|
|---|
| 2007 | if test "$GCC" = yes; then
|
|---|
| 2008 | case `$CC --version 2>/dev/null` in
|
|---|
| 2009 | [[12]].*)
|
|---|
| 2010 | cat <<EOF 1>&2
|
|---|
| 2011 |
|
|---|
| 2012 | *** Warning: Releases of GCC earlier than version 3.0 cannot reliably
|
|---|
| 2013 | *** create self contained shared libraries on Solaris systems, without
|
|---|
| 2014 | *** introducing a dependency on libgcc.a. Therefore, libtool is disabling
|
|---|
| 2015 | *** -no-undefined support, which will at least allow you to build shared
|
|---|
| 2016 | *** libraries. However, you may find that when you link such libraries
|
|---|
| 2017 | *** into an application without using GCC, you have to manually add
|
|---|
| 2018 | *** \`gcc --print-libgcc-file-name\` to the link command. We urge you to
|
|---|
| 2019 | *** upgrade to a newer version of GCC. Another option is to rebuild your
|
|---|
| 2020 | *** current GCC to use the GNU linker from GNU binutils 2.9.1 or newer.
|
|---|
| 2021 |
|
|---|
| 2022 | EOF
|
|---|
| 2023 | no_undefined_flag=
|
|---|
| 2024 | ;;
|
|---|
| 2025 | esac
|
|---|
| 2026 | fi
|
|---|
| 2027 | # $CC -shared without GNU ld will not create a library from C++
|
|---|
| 2028 | # object files and a static libstdc++, better avoid it by now
|
|---|
| 2029 | archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2030 | archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
|
|---|
| 2031 | $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
|
|---|
| 2032 | hardcode_libdir_flag_spec='-R$libdir'
|
|---|
| 2033 | hardcode_shlibpath_var=no
|
|---|
| 2034 | case $host_os in
|
|---|
| 2035 | solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
|
|---|
| 2036 | *) # Supported since Solaris 2.6 (maybe 2.5.1?)
|
|---|
| 2037 | whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
|
|---|
| 2038 | esac
|
|---|
| 2039 | link_all_deplibs=yes
|
|---|
| 2040 | ;;
|
|---|
| 2041 |
|
|---|
| 2042 | sunos4*)
|
|---|
| 2043 | if test "x$host_vendor" = xsequent; then
|
|---|
| 2044 | # Use $CC to link under sequent, because it throws in some extra .o
|
|---|
| 2045 | # files that make .init and .fini sections work.
|
|---|
| 2046 | archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
|
|---|
| 2047 | else
|
|---|
| 2048 | archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2049 | fi
|
|---|
| 2050 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 2051 | hardcode_direct=yes
|
|---|
| 2052 | hardcode_minus_L=yes
|
|---|
| 2053 | hardcode_shlibpath_var=no
|
|---|
| 2054 | ;;
|
|---|
| 2055 |
|
|---|
| 2056 | sysv4)
|
|---|
| 2057 | if test "x$host_vendor" = xsno; then
|
|---|
| 2058 | archive_cmds='$LD -G -Bsymbolic -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2059 | hardcode_direct=yes # is this really true???
|
|---|
| 2060 | else
|
|---|
| 2061 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2062 | hardcode_direct=no #Motorola manual says yes, but my tests say they lie
|
|---|
| 2063 | fi
|
|---|
| 2064 | runpath_var='LD_RUN_PATH'
|
|---|
| 2065 | hardcode_shlibpath_var=no
|
|---|
| 2066 | ;;
|
|---|
| 2067 |
|
|---|
| 2068 | sysv4.3*)
|
|---|
| 2069 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2070 | hardcode_shlibpath_var=no
|
|---|
| 2071 | export_dynamic_flag_spec='-Bexport'
|
|---|
| 2072 | ;;
|
|---|
| 2073 |
|
|---|
| 2074 | sysv5*)
|
|---|
| 2075 | no_undefined_flag=' -z text'
|
|---|
| 2076 | # $CC -shared without GNU ld will not create a library from C++
|
|---|
| 2077 | # object files and a static libstdc++, better avoid it by now
|
|---|
| 2078 | archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2079 | archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
|
|---|
| 2080 | $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
|
|---|
| 2081 | hardcode_libdir_flag_spec=
|
|---|
| 2082 | hardcode_shlibpath_var=no
|
|---|
| 2083 | runpath_var='LD_RUN_PATH'
|
|---|
| 2084 | ;;
|
|---|
| 2085 |
|
|---|
| 2086 | uts4*)
|
|---|
| 2087 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2088 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 2089 | hardcode_shlibpath_var=no
|
|---|
| 2090 | ;;
|
|---|
| 2091 |
|
|---|
| 2092 | dgux*)
|
|---|
| 2093 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2094 | hardcode_libdir_flag_spec='-L$libdir'
|
|---|
| 2095 | hardcode_shlibpath_var=no
|
|---|
| 2096 | ;;
|
|---|
| 2097 |
|
|---|
| 2098 | sysv4*MP*)
|
|---|
| 2099 | if test -d /usr/nec; then
|
|---|
| 2100 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2101 | hardcode_shlibpath_var=no
|
|---|
| 2102 | runpath_var=LD_RUN_PATH
|
|---|
| 2103 | hardcode_runpath_var=yes
|
|---|
| 2104 | ld_shlibs=yes
|
|---|
| 2105 | fi
|
|---|
| 2106 | ;;
|
|---|
| 2107 |
|
|---|
| 2108 | sysv4.2uw2*)
|
|---|
| 2109 | archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
|
|---|
| 2110 | hardcode_direct=yes
|
|---|
| 2111 | hardcode_minus_L=no
|
|---|
| 2112 | hardcode_shlibpath_var=no
|
|---|
| 2113 | hardcode_runpath_var=yes
|
|---|
| 2114 | runpath_var=LD_RUN_PATH
|
|---|
| 2115 | ;;
|
|---|
| 2116 |
|
|---|
| 2117 | sysv5uw7* | unixware7*)
|
|---|
| 2118 | no_undefined_flag='${wl}-z ${wl}text'
|
|---|
| 2119 | if test "$GCC" = yes; then
|
|---|
| 2120 | archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
|
|---|
| 2121 | else
|
|---|
| 2122 | archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
|
|---|
| 2123 | fi
|
|---|
| 2124 | runpath_var='LD_RUN_PATH'
|
|---|
| 2125 | hardcode_shlibpath_var=no
|
|---|
| 2126 | ;;
|
|---|
| 2127 |
|
|---|
| 2128 | *)
|
|---|
| 2129 | ld_shlibs=no
|
|---|
| 2130 | ;;
|
|---|
| 2131 | esac
|
|---|
| 2132 | fi
|
|---|
| 2133 | AC_MSG_RESULT([$ld_shlibs])
|
|---|
| 2134 | test "$ld_shlibs" = no && can_build_shared=no
|
|---|
| 2135 |
|
|---|
| 2136 | # Check hardcoding attributes.
|
|---|
| 2137 | AC_MSG_CHECKING([how to hardcode library paths into programs])
|
|---|
| 2138 | hardcode_action=
|
|---|
| 2139 | if test -n "$hardcode_libdir_flag_spec" || \
|
|---|
| 2140 | test -n "$runpath_var"; then
|
|---|
| 2141 |
|
|---|
| 2142 | # We can hardcode non-existant directories.
|
|---|
| 2143 | if test "$hardcode_direct" != no &&
|
|---|
| 2144 | # If the only mechanism to avoid hardcoding is shlibpath_var, we
|
|---|
| 2145 | # have to relink, otherwise we might link with an installed library
|
|---|
| 2146 | # when we should be linking with a yet-to-be-installed one
|
|---|
| 2147 | ## test "$hardcode_shlibpath_var" != no &&
|
|---|
| 2148 | test "$hardcode_minus_L" != no; then
|
|---|
| 2149 | # Linking always hardcodes the temporary library directory.
|
|---|
| 2150 | hardcode_action=relink
|
|---|
| 2151 | else
|
|---|
| 2152 | # We can link without hardcoding, and we can hardcode nonexisting dirs.
|
|---|
| 2153 | hardcode_action=immediate
|
|---|
| 2154 | fi
|
|---|
| 2155 | else
|
|---|
| 2156 | # We cannot hardcode anything, or else we can only hardcode existing
|
|---|
| 2157 | # directories.
|
|---|
| 2158 | hardcode_action=unsupported
|
|---|
| 2159 | fi
|
|---|
| 2160 | AC_MSG_RESULT([$hardcode_action])
|
|---|
| 2161 |
|
|---|
| 2162 | striplib=
|
|---|
| 2163 | old_striplib=
|
|---|
| 2164 | AC_MSG_CHECKING([whether stripping libraries is possible])
|
|---|
| 2165 | if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
|
|---|
| 2166 | test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
|
|---|
| 2167 | test -z "$striplib" && striplib="$STRIP --strip-unneeded"
|
|---|
| 2168 | AC_MSG_RESULT([yes])
|
|---|
| 2169 | else
|
|---|
| 2170 | AC_MSG_RESULT([no])
|
|---|
| 2171 | fi
|
|---|
| 2172 |
|
|---|
| 2173 | reload_cmds='$LD$reload_flag -o $output$reload_objs'
|
|---|
| 2174 | test -z "$deplibs_check_method" && deplibs_check_method=unknown
|
|---|
| 2175 |
|
|---|
| 2176 | # PORTME Fill in your ld.so characteristics
|
|---|
| 2177 | AC_MSG_CHECKING([dynamic linker characteristics])
|
|---|
| 2178 | library_names_spec=
|
|---|
| 2179 | libname_spec='lib$name'
|
|---|
| 2180 | soname_spec=
|
|---|
| 2181 | postinstall_cmds=
|
|---|
| 2182 | postuninstall_cmds=
|
|---|
| 2183 | finish_cmds=
|
|---|
| 2184 | finish_eval=
|
|---|
| 2185 | shlibpath_var=
|
|---|
| 2186 | shlibpath_overrides_runpath=unknown
|
|---|
| 2187 | version_type=none
|
|---|
| 2188 | dynamic_linker="$host_os ld.so"
|
|---|
| 2189 | sys_lib_dlsearch_path_spec="/lib /usr/lib"
|
|---|
| 2190 | sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
|
|---|
| 2191 |
|
|---|
| 2192 | case $host_os in
|
|---|
| 2193 | aix3*)
|
|---|
| 2194 | version_type=linux
|
|---|
| 2195 | library_names_spec='${libname}${release}.so$versuffix $libname.a'
|
|---|
| 2196 | shlibpath_var=LIBPATH
|
|---|
| 2197 |
|
|---|
| 2198 | # AIX has no versioning support, so we append a major version to the name.
|
|---|
| 2199 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2200 | ;;
|
|---|
| 2201 |
|
|---|
| 2202 | aix4* | aix5*)
|
|---|
| 2203 | version_type=linux
|
|---|
| 2204 | if test "$host_cpu" = ia64; then
|
|---|
| 2205 | # AIX 5 supports IA64
|
|---|
| 2206 | library_names_spec='${libname}${release}.so$major ${libname}${release}.so$versuffix $libname.so'
|
|---|
| 2207 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2208 | else
|
|---|
| 2209 | # With GCC up to 2.95.x, collect2 would create an import file
|
|---|
| 2210 | # for dependence libraries. The import file would start with
|
|---|
| 2211 | # the line `#! .'. This would cause the generated library to
|
|---|
| 2212 | # depend on `.', always an invalid library. This was fixed in
|
|---|
| 2213 | # development snapshots of GCC prior to 3.0.
|
|---|
| 2214 | case $host_os in
|
|---|
| 2215 | aix4 | aix4.[[01]] | aix4.[[01]].*)
|
|---|
| 2216 | if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
|
|---|
| 2217 | echo ' yes '
|
|---|
| 2218 | echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
|
|---|
| 2219 | :
|
|---|
| 2220 | else
|
|---|
| 2221 | can_build_shared=no
|
|---|
| 2222 | fi
|
|---|
| 2223 | ;;
|
|---|
| 2224 | esac
|
|---|
| 2225 | # AIX (on Power*) has no versioning support, so currently we can
|
|---|
| 2226 | # not hardcode correct soname into executable. Probably we can
|
|---|
| 2227 | # add versioning support to collect2, so additional links can
|
|---|
| 2228 | # be useful in future.
|
|---|
| 2229 | if test "$aix_use_runtimelinking" = yes; then
|
|---|
| 2230 | # If using run time linking (on AIX 4.2 or later) use lib<name>.so
|
|---|
| 2231 | # instead of lib<name>.a to let people know that these are not
|
|---|
| 2232 | # typical AIX shared libraries.
|
|---|
| 2233 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2234 | else
|
|---|
| 2235 | # We preserve .a as extension for shared libraries through AIX4.2
|
|---|
| 2236 | # and later when we are not doing run time linking.
|
|---|
| 2237 | library_names_spec='${libname}${release}.a $libname.a'
|
|---|
| 2238 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2239 | fi
|
|---|
| 2240 | shlibpath_var=LIBPATH
|
|---|
| 2241 | fi
|
|---|
| 2242 | ;;
|
|---|
| 2243 |
|
|---|
| 2244 | amigaos*)
|
|---|
| 2245 | library_names_spec='$libname.ixlibrary $libname.a'
|
|---|
| 2246 | # Create ${libname}_ixlibrary.a entries in /sys/libs.
|
|---|
| 2247 | finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "(cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a)"; (cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a) || exit 1; done'
|
|---|
| 2248 | ;;
|
|---|
| 2249 |
|
|---|
| 2250 | beos*)
|
|---|
| 2251 | library_names_spec='${libname}.so'
|
|---|
| 2252 | dynamic_linker="$host_os ld.so"
|
|---|
| 2253 | shlibpath_var=LIBRARY_PATH
|
|---|
| 2254 | ;;
|
|---|
| 2255 |
|
|---|
| 2256 | bsdi4*)
|
|---|
| 2257 | version_type=linux
|
|---|
| 2258 | need_version=no
|
|---|
| 2259 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2260 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2261 | finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
|
|---|
| 2262 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2263 | sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
|
|---|
| 2264 | sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
|
|---|
| 2265 | export_dynamic_flag_spec=-rdynamic
|
|---|
| 2266 | # the default ld.so.conf also contains /usr/contrib/lib and
|
|---|
| 2267 | # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
|
|---|
| 2268 | # libtool to hard-code these into programs
|
|---|
| 2269 | ;;
|
|---|
| 2270 |
|
|---|
| 2271 | cygwin* | mingw* | pw32*)
|
|---|
| 2272 | version_type=windows
|
|---|
| 2273 | need_version=no
|
|---|
| 2274 | need_lib_prefix=no
|
|---|
| 2275 | case $GCC,$host_os in
|
|---|
| 2276 | yes,cygwin*)
|
|---|
| 2277 | library_names_spec='$libname.dll.a'
|
|---|
| 2278 | soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
|
|---|
| 2279 | postinstall_cmds='dlpath=`bash 2>&1 -c '\''. $dir/${file}i;echo \$dlname'\''`~
|
|---|
| 2280 | dldir=$destdir/`dirname \$dlpath`~
|
|---|
| 2281 | test -d \$dldir || mkdir -p \$dldir~
|
|---|
| 2282 | $install_prog .libs/$dlname \$dldir/$dlname'
|
|---|
| 2283 | postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
|
|---|
| 2284 | dlpath=$dir/\$dldll~
|
|---|
| 2285 | $rm \$dlpath'
|
|---|
| 2286 | ;;
|
|---|
| 2287 | yes,mingw*)
|
|---|
| 2288 | library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
|
|---|
| 2289 | sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g"`
|
|---|
| 2290 | ;;
|
|---|
| 2291 | yes,pw32*)
|
|---|
| 2292 | library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
|
|---|
| 2293 | ;;
|
|---|
| 2294 | *)
|
|---|
| 2295 | library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll $libname.lib'
|
|---|
| 2296 | ;;
|
|---|
| 2297 | esac
|
|---|
| 2298 | dynamic_linker='Win32 ld.exe'
|
|---|
| 2299 | # FIXME: first we should search . and the directory the executable is in
|
|---|
| 2300 | shlibpath_var=PATH
|
|---|
| 2301 | ;;
|
|---|
| 2302 |
|
|---|
| 2303 | darwin* | rhapsody*)
|
|---|
| 2304 | dynamic_linker="$host_os dyld"
|
|---|
| 2305 | version_type=darwin
|
|---|
| 2306 | need_lib_prefix=no
|
|---|
| 2307 | need_version=no
|
|---|
| 2308 | # FIXME: Relying on posixy $() will cause problems for
|
|---|
| 2309 | # cross-compilation, but unfortunately the echo tests do not
|
|---|
| 2310 | # yet detect zsh echo's removal of \ escapes.
|
|---|
| 2311 | 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)'
|
|---|
| 2312 | soname_spec='${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib)'
|
|---|
| 2313 | shlibpath_overrides_runpath=yes
|
|---|
| 2314 | shlibpath_var=DYLD_LIBRARY_PATH
|
|---|
| 2315 | ;;
|
|---|
| 2316 |
|
|---|
| 2317 | freebsd1*)
|
|---|
| 2318 | dynamic_linker=no
|
|---|
| 2319 | ;;
|
|---|
| 2320 |
|
|---|
| 2321 | freebsd*)
|
|---|
| 2322 | objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
|
|---|
| 2323 | version_type=freebsd-$objformat
|
|---|
| 2324 | case $version_type in
|
|---|
| 2325 | freebsd-elf*)
|
|---|
| 2326 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
|
|---|
| 2327 | need_version=no
|
|---|
| 2328 | need_lib_prefix=no
|
|---|
| 2329 | ;;
|
|---|
| 2330 | freebsd-*)
|
|---|
| 2331 | library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix'
|
|---|
| 2332 | need_version=yes
|
|---|
| 2333 | ;;
|
|---|
| 2334 | esac
|
|---|
| 2335 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2336 | case $host_os in
|
|---|
| 2337 | freebsd2*)
|
|---|
| 2338 | shlibpath_overrides_runpath=yes
|
|---|
| 2339 | ;;
|
|---|
| 2340 | *)
|
|---|
| 2341 | shlibpath_overrides_runpath=no
|
|---|
| 2342 | hardcode_into_libs=yes
|
|---|
| 2343 | ;;
|
|---|
| 2344 | esac
|
|---|
| 2345 | ;;
|
|---|
| 2346 |
|
|---|
| 2347 | gnu*)
|
|---|
| 2348 | version_type=linux
|
|---|
| 2349 | need_lib_prefix=no
|
|---|
| 2350 | need_version=no
|
|---|
| 2351 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
|
|---|
| 2352 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2353 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2354 | hardcode_into_libs=yes
|
|---|
| 2355 | ;;
|
|---|
| 2356 |
|
|---|
| 2357 | hpux9* | hpux10* | hpux11*)
|
|---|
| 2358 | # Give a soname corresponding to the major version so that dld.sl refuses to
|
|---|
| 2359 | # link against other versions.
|
|---|
| 2360 | dynamic_linker="$host_os dld.sl"
|
|---|
| 2361 | version_type=sunos
|
|---|
| 2362 | need_lib_prefix=no
|
|---|
| 2363 | need_version=no
|
|---|
| 2364 | shlibpath_var=SHLIB_PATH
|
|---|
| 2365 | shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
|
|---|
| 2366 | library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
|
|---|
| 2367 | soname_spec='${libname}${release}.sl$major'
|
|---|
| 2368 | # HP-UX runs *really* slowly unless shared libraries are mode 555.
|
|---|
| 2369 | postinstall_cmds='chmod 555 $lib'
|
|---|
| 2370 | ;;
|
|---|
| 2371 |
|
|---|
| 2372 | irix5* | irix6*)
|
|---|
| 2373 | version_type=irix
|
|---|
| 2374 | need_lib_prefix=no
|
|---|
| 2375 | need_version=no
|
|---|
| 2376 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2377 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so $libname.so'
|
|---|
| 2378 | case $host_os in
|
|---|
| 2379 | irix5*)
|
|---|
| 2380 | libsuff= shlibsuff=
|
|---|
| 2381 | ;;
|
|---|
| 2382 | *)
|
|---|
| 2383 | case $LD in # libtool.m4 will add one of these switches to LD
|
|---|
| 2384 | *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
|
|---|
| 2385 | *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
|
|---|
| 2386 | *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
|
|---|
| 2387 | *) libsuff= shlibsuff= libmagic=never-match;;
|
|---|
| 2388 | esac
|
|---|
| 2389 | ;;
|
|---|
| 2390 | esac
|
|---|
| 2391 | shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
|
|---|
| 2392 | shlibpath_overrides_runpath=no
|
|---|
| 2393 | sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
|
|---|
| 2394 | sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
|
|---|
| 2395 | ;;
|
|---|
| 2396 |
|
|---|
| 2397 | # No shared lib support for Linux oldld, aout, or coff.
|
|---|
| 2398 | linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
|
|---|
| 2399 | dynamic_linker=no
|
|---|
| 2400 | ;;
|
|---|
| 2401 |
|
|---|
| 2402 | # This must be Linux ELF.
|
|---|
| 2403 | linux-gnu*)
|
|---|
| 2404 | version_type=linux
|
|---|
| 2405 | need_lib_prefix=no
|
|---|
| 2406 | need_version=no
|
|---|
| 2407 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2408 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2409 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
|
|---|
| 2410 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2411 | shlibpath_overrides_runpath=no
|
|---|
| 2412 | # This implies no fast_install, which is unacceptable.
|
|---|
| 2413 | # Some rework will be needed to allow for fast_install
|
|---|
| 2414 | # before this can be enabled.
|
|---|
| 2415 | hardcode_into_libs=yes
|
|---|
| 2416 |
|
|---|
| 2417 | # We used to test for /lib/ld.so.1 and disable shared libraries on
|
|---|
| 2418 | # powerpc, because MkLinux only supported shared libraries with the
|
|---|
| 2419 | # GNU dynamic linker. Since this was broken with cross compilers,
|
|---|
| 2420 | # most powerpc-linux boxes support dynamic linking these days and
|
|---|
| 2421 | # people can always --disable-shared, the test was removed, and we
|
|---|
| 2422 | # assume the GNU/Linux dynamic linker is in use.
|
|---|
| 2423 | dynamic_linker='GNU/Linux ld.so'
|
|---|
| 2424 | ;;
|
|---|
| 2425 |
|
|---|
| 2426 | netbsd*)
|
|---|
| 2427 | version_type=sunos
|
|---|
| 2428 | need_lib_prefix=no
|
|---|
| 2429 | need_version=no
|
|---|
| 2430 | if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
|
|---|
| 2431 | library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
|
|---|
| 2432 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
|
|---|
| 2433 | dynamic_linker='NetBSD (a.out) ld.so'
|
|---|
| 2434 | else
|
|---|
| 2435 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so'
|
|---|
| 2436 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2437 | dynamic_linker='NetBSD ld.elf_so'
|
|---|
| 2438 | fi
|
|---|
| 2439 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2440 | shlibpath_overrides_runpath=yes
|
|---|
| 2441 | hardcode_into_libs=yes
|
|---|
| 2442 | ;;
|
|---|
| 2443 |
|
|---|
| 2444 | newsos6)
|
|---|
| 2445 | version_type=linux
|
|---|
| 2446 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2447 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2448 | shlibpath_overrides_runpath=yes
|
|---|
| 2449 | ;;
|
|---|
| 2450 |
|
|---|
| 2451 | openbsd*)
|
|---|
| 2452 | version_type=sunos
|
|---|
| 2453 | need_lib_prefix=no
|
|---|
| 2454 | need_version=no
|
|---|
| 2455 | if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
|---|
| 2456 | case "$host_os" in
|
|---|
| 2457 | openbsd2.[[89]] | openbsd2.[[89]].*)
|
|---|
| 2458 | shlibpath_overrides_runpath=no
|
|---|
| 2459 | ;;
|
|---|
| 2460 | *)
|
|---|
| 2461 | shlibpath_overrides_runpath=yes
|
|---|
| 2462 | ;;
|
|---|
| 2463 | esac
|
|---|
| 2464 | else
|
|---|
| 2465 | shlibpath_overrides_runpath=yes
|
|---|
| 2466 | fi
|
|---|
| 2467 | library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
|
|---|
| 2468 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
|
|---|
| 2469 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2470 | ;;
|
|---|
| 2471 |
|
|---|
| 2472 | os2*)
|
|---|
| 2473 | libname_spec='$name'
|
|---|
| 2474 | need_lib_prefix=no
|
|---|
| 2475 | library_names_spec='$libname.dll $libname.a'
|
|---|
| 2476 | dynamic_linker='OS/2 ld.exe'
|
|---|
| 2477 | shlibpath_var=LIBPATH
|
|---|
| 2478 | ;;
|
|---|
| 2479 |
|
|---|
| 2480 | osf3* | osf4* | osf5*)
|
|---|
| 2481 | version_type=osf
|
|---|
| 2482 | need_version=no
|
|---|
| 2483 | soname_spec='${libname}${release}.so'
|
|---|
| 2484 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
|
|---|
| 2485 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2486 | sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
|
|---|
| 2487 | sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
|
|---|
| 2488 | ;;
|
|---|
| 2489 |
|
|---|
| 2490 | sco3.2v5*)
|
|---|
| 2491 | version_type=osf
|
|---|
| 2492 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2493 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2494 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2495 | ;;
|
|---|
| 2496 |
|
|---|
| 2497 | solaris*)
|
|---|
| 2498 | version_type=linux
|
|---|
| 2499 | need_lib_prefix=no
|
|---|
| 2500 | need_version=no
|
|---|
| 2501 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2502 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2503 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2504 | shlibpath_overrides_runpath=yes
|
|---|
| 2505 | hardcode_into_libs=yes
|
|---|
| 2506 | # ldd complains unless libraries are executable
|
|---|
| 2507 | postinstall_cmds='chmod +x $lib'
|
|---|
| 2508 | ;;
|
|---|
| 2509 |
|
|---|
| 2510 | sunos4*)
|
|---|
| 2511 | version_type=sunos
|
|---|
| 2512 | library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
|
|---|
| 2513 | finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
|
|---|
| 2514 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2515 | shlibpath_overrides_runpath=yes
|
|---|
| 2516 | if test "$with_gnu_ld" = yes; then
|
|---|
| 2517 | need_lib_prefix=no
|
|---|
| 2518 | fi
|
|---|
| 2519 | need_version=yes
|
|---|
| 2520 | ;;
|
|---|
| 2521 |
|
|---|
| 2522 | sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
|
|---|
| 2523 | version_type=linux
|
|---|
| 2524 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2525 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2526 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2527 | case $host_vendor in
|
|---|
| 2528 | sni)
|
|---|
| 2529 | shlibpath_overrides_runpath=no
|
|---|
| 2530 | ;;
|
|---|
| 2531 | motorola)
|
|---|
| 2532 | need_lib_prefix=no
|
|---|
| 2533 | need_version=no
|
|---|
| 2534 | shlibpath_overrides_runpath=no
|
|---|
| 2535 | sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
|
|---|
| 2536 | ;;
|
|---|
| 2537 | esac
|
|---|
| 2538 | ;;
|
|---|
| 2539 |
|
|---|
| 2540 | uts4*)
|
|---|
| 2541 | version_type=linux
|
|---|
| 2542 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2543 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2544 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2545 | ;;
|
|---|
| 2546 |
|
|---|
| 2547 | dgux*)
|
|---|
| 2548 | version_type=linux
|
|---|
| 2549 | need_lib_prefix=no
|
|---|
| 2550 | need_version=no
|
|---|
| 2551 | library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
|---|
| 2552 | soname_spec='${libname}${release}.so$major'
|
|---|
| 2553 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2554 | ;;
|
|---|
| 2555 |
|
|---|
| 2556 | sysv4*MP*)
|
|---|
| 2557 | if test -d /usr/nec ;then
|
|---|
| 2558 | version_type=linux
|
|---|
| 2559 | library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
|
|---|
| 2560 | soname_spec='$libname.so.$major'
|
|---|
| 2561 | shlibpath_var=LD_LIBRARY_PATH
|
|---|
| 2562 | fi
|
|---|
| 2563 | ;;
|
|---|
| 2564 |
|
|---|
| 2565 | *)
|
|---|
| 2566 | dynamic_linker=no
|
|---|
| 2567 | ;;
|
|---|
| 2568 | esac
|
|---|
| 2569 | AC_MSG_RESULT([$dynamic_linker])
|
|---|
| 2570 | test "$dynamic_linker" = no && can_build_shared=no
|
|---|
| 2571 |
|
|---|
| 2572 | # Report the final consequences.
|
|---|
| 2573 | AC_MSG_CHECKING([if libtool supports shared libraries])
|
|---|
| 2574 | AC_MSG_RESULT([$can_build_shared])
|
|---|
| 2575 |
|
|---|
| 2576 | AC_MSG_CHECKING([whether to build shared libraries])
|
|---|
| 2577 | test "$can_build_shared" = "no" && enable_shared=no
|
|---|
| 2578 |
|
|---|
| 2579 | # On AIX, shared libraries and static libraries use the same namespace, and
|
|---|
| 2580 | # are all built from PIC.
|
|---|
| 2581 | case "$host_os" in
|
|---|
| 2582 | aix3*)
|
|---|
| 2583 | test "$enable_shared" = yes && enable_static=no
|
|---|
| 2584 | if test -n "$RANLIB"; then
|
|---|
| 2585 | archive_cmds="$archive_cmds~\$RANLIB \$lib"
|
|---|
| 2586 | postinstall_cmds='$RANLIB $lib'
|
|---|
| 2587 | fi
|
|---|
| 2588 | ;;
|
|---|
| 2589 |
|
|---|
| 2590 | aix4*)
|
|---|
| 2591 | if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
|
|---|
| 2592 | test "$enable_shared" = yes && enable_static=no
|
|---|
| 2593 | fi
|
|---|
| 2594 | ;;
|
|---|
| 2595 | esac
|
|---|
| 2596 | AC_MSG_RESULT([$enable_shared])
|
|---|
| 2597 |
|
|---|
| 2598 | AC_MSG_CHECKING([whether to build static libraries])
|
|---|
| 2599 | # Make sure either enable_shared or enable_static is yes.
|
|---|
| 2600 | test "$enable_shared" = yes || enable_static=yes
|
|---|
| 2601 | AC_MSG_RESULT([$enable_static])
|
|---|
| 2602 |
|
|---|
| 2603 | if test "$hardcode_action" = relink; then
|
|---|
| 2604 | # Fast installation is not supported
|
|---|
| 2605 | enable_fast_install=no
|
|---|
| 2606 | elif test "$shlibpath_overrides_runpath" = yes ||
|
|---|
| 2607 | test "$enable_shared" = no; then
|
|---|
| 2608 | # Fast installation is not necessary
|
|---|
| 2609 | enable_fast_install=needless
|
|---|
| 2610 | fi
|
|---|
| 2611 |
|
|---|
| 2612 | variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
|
|---|
| 2613 | if test "$GCC" = yes; then
|
|---|
| 2614 | variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
|
|---|
| 2615 | fi
|
|---|
| 2616 |
|
|---|
| 2617 | AC_LIBTOOL_DLOPEN_SELF
|
|---|
| 2618 |
|
|---|
| 2619 | if test "$enable_shared" = yes && test "$GCC" = yes; then
|
|---|
| 2620 | case $archive_cmds in
|
|---|
| 2621 | *'~'*)
|
|---|
| 2622 | # FIXME: we may have to deal with multi-command sequences.
|
|---|
| 2623 | ;;
|
|---|
| 2624 | '$CC '*)
|
|---|
| 2625 | # Test whether the compiler implicitly links with -lc since on some
|
|---|
| 2626 | # systems, -lgcc has to come before -lc. If gcc already passes -lc
|
|---|
| 2627 | # to ld, don't add -lc before -lgcc.
|
|---|
| 2628 | AC_MSG_CHECKING([whether -lc should be explicitly linked in])
|
|---|
| 2629 | AC_CACHE_VAL([lt_cv_archive_cmds_need_lc],
|
|---|
| 2630 | [$rm conftest*
|
|---|
| 2631 | echo 'static int dummy;' > conftest.$ac_ext
|
|---|
| 2632 |
|
|---|
| 2633 | if AC_TRY_EVAL(ac_compile); then
|
|---|
| 2634 | soname=conftest
|
|---|
| 2635 | lib=conftest
|
|---|
| 2636 | libobjs=conftest.$ac_objext
|
|---|
| 2637 | deplibs=
|
|---|
| 2638 | wl=$lt_cv_prog_cc_wl
|
|---|
| 2639 | compiler_flags=-v
|
|---|
| 2640 | linker_flags=-v
|
|---|
| 2641 | verstring=
|
|---|
| 2642 | output_objdir=.
|
|---|
| 2643 | libname=conftest
|
|---|
| 2644 | save_allow_undefined_flag=$allow_undefined_flag
|
|---|
| 2645 | allow_undefined_flag=
|
|---|
| 2646 | if AC_TRY_EVAL(archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
|
|---|
| 2647 | then
|
|---|
| 2648 | lt_cv_archive_cmds_need_lc=no
|
|---|
| 2649 | else
|
|---|
| 2650 | lt_cv_archive_cmds_need_lc=yes
|
|---|
| 2651 | fi
|
|---|
| 2652 | allow_undefined_flag=$save_allow_undefined_flag
|
|---|
| 2653 | else
|
|---|
| 2654 | cat conftest.err 1>&5
|
|---|
| 2655 | fi])
|
|---|
| 2656 | AC_MSG_RESULT([$lt_cv_archive_cmds_need_lc])
|
|---|
| 2657 | ;;
|
|---|
| 2658 | esac
|
|---|
| 2659 | fi
|
|---|
| 2660 | need_lc=${lt_cv_archive_cmds_need_lc-yes}
|
|---|
| 2661 |
|
|---|
| 2662 | # The second clause should only fire when bootstrapping the
|
|---|
| 2663 | # libtool distribution, otherwise you forgot to ship ltmain.sh
|
|---|
| 2664 | # with your package, and you will get complaints that there are
|
|---|
| 2665 | # no rules to generate ltmain.sh.
|
|---|
| 2666 | if test -f "$ltmain"; then
|
|---|
| 2667 | :
|
|---|
| 2668 | else
|
|---|
| 2669 | # If there is no Makefile yet, we rely on a make rule to execute
|
|---|
| 2670 | # `config.status --recheck' to rerun these tests and create the
|
|---|
| 2671 | # libtool script then.
|
|---|
| 2672 | test -f Makefile && make "$ltmain"
|
|---|
| 2673 | fi
|
|---|
| 2674 |
|
|---|
| 2675 | if test -f "$ltmain"; then
|
|---|
| 2676 | trap "$rm \"${ofile}T\"; exit 1" 1 2 15
|
|---|
| 2677 | $rm -f "${ofile}T"
|
|---|
| 2678 |
|
|---|
| 2679 | echo creating $ofile
|
|---|
| 2680 |
|
|---|
| 2681 | # Now quote all the things that may contain metacharacters while being
|
|---|
| 2682 | # careful not to overquote the AC_SUBSTed values. We take copies of the
|
|---|
| 2683 | # variables and quote the copies for generation of the libtool script.
|
|---|
| 2684 | for var in echo old_CC old_CFLAGS \
|
|---|
| 2685 | AR AR_FLAGS CC LD LN_S NM SHELL \
|
|---|
| 2686 | reload_flag reload_cmds wl \
|
|---|
| 2687 | pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \
|
|---|
| 2688 | thread_safe_flag_spec whole_archive_flag_spec libname_spec \
|
|---|
| 2689 | library_names_spec soname_spec \
|
|---|
| 2690 | RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \
|
|---|
| 2691 | old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds \
|
|---|
| 2692 | postuninstall_cmds extract_expsyms_cmds old_archive_from_expsyms_cmds \
|
|---|
| 2693 | old_striplib striplib file_magic_cmd export_symbols_cmds \
|
|---|
| 2694 | deplibs_check_method allow_undefined_flag no_undefined_flag \
|
|---|
| 2695 | finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
|
|---|
| 2696 | global_symbol_to_c_name_address \
|
|---|
| 2697 | hardcode_libdir_flag_spec hardcode_libdir_separator \
|
|---|
| 2698 | sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
|
|---|
| 2699 | compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
|
|---|
| 2700 |
|
|---|
| 2701 | case $var in
|
|---|
| 2702 | reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
|
|---|
| 2703 | old_postinstall_cmds | old_postuninstall_cmds | \
|
|---|
| 2704 | export_symbols_cmds | archive_cmds | archive_expsym_cmds | \
|
|---|
| 2705 | extract_expsyms_cmds | old_archive_from_expsyms_cmds | \
|
|---|
| 2706 | postinstall_cmds | postuninstall_cmds | \
|
|---|
| 2707 | finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
|
|---|
| 2708 | # Double-quote double-evaled strings.
|
|---|
| 2709 | eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
|
|---|
| 2710 | ;;
|
|---|
| 2711 | *)
|
|---|
| 2712 | eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
|
|---|
| 2713 | ;;
|
|---|
| 2714 | esac
|
|---|
| 2715 | done
|
|---|
| 2716 |
|
|---|
| 2717 | cat <<__EOF__ > "${ofile}T"
|
|---|
| 2718 | #! $SHELL
|
|---|
| 2719 |
|
|---|
| 2720 | # `$echo "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
|
|---|
| 2721 | # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
|
|---|
| 2722 | # NOTE: Changes made to this file will be lost: look at ltmain.sh.
|
|---|
| 2723 | #
|
|---|
| 2724 | # Copyright (C) 1996-2000 Free Software Foundation, Inc.
|
|---|
| 2725 | # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
|
|---|
| 2726 | #
|
|---|
| 2727 | # This program is free software; you can redistribute it and/or modify
|
|---|
| 2728 | # it under the terms of the GNU General Public License as published by
|
|---|
| 2729 | # the Free Software Foundation; either version 2 of the License, or
|
|---|
| 2730 | # (at your option) any later version.
|
|---|
| 2731 | #
|
|---|
| 2732 | # This program is distributed in the hope that it will be useful, but
|
|---|
| 2733 | # WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 2734 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|---|
| 2735 | # General Public License for more details.
|
|---|
| 2736 | #
|
|---|
| 2737 | # You should have received a copy of the GNU General Public License
|
|---|
| 2738 | # along with this program; if not, write to the Free Software
|
|---|
| 2739 | # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|---|
| 2740 | #
|
|---|
| 2741 | # As a special exception to the GNU General Public License, if you
|
|---|
| 2742 | # distribute this file as part of a program that contains a
|
|---|
| 2743 | # configuration script generated by Autoconf, you may include it under
|
|---|
| 2744 | # the same distribution terms that you use for the rest of that program.
|
|---|
| 2745 |
|
|---|
| 2746 | # Sed that helps us avoid accidentally triggering echo(1) options like -n.
|
|---|
| 2747 | Xsed="sed -e s/^X//"
|
|---|
| 2748 |
|
|---|
| 2749 | # The HP-UX ksh and POSIX shell print the target directory to stdout
|
|---|
| 2750 | # if CDPATH is set.
|
|---|
| 2751 | if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
|
|---|
| 2752 |
|
|---|
| 2753 | # ### BEGIN LIBTOOL CONFIG
|
|---|
| 2754 |
|
|---|
| 2755 | # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
|
|---|
| 2756 |
|
|---|
| 2757 | # Shell to use when invoking shell scripts.
|
|---|
| 2758 | SHELL=$lt_SHELL
|
|---|
| 2759 |
|
|---|
| 2760 | # Whether or not to build shared libraries.
|
|---|
| 2761 | build_libtool_libs=$enable_shared
|
|---|
| 2762 |
|
|---|
| 2763 | # Whether or not to build static libraries.
|
|---|
| 2764 | build_old_libs=$enable_static
|
|---|
| 2765 |
|
|---|
| 2766 | # Whether or not to add -lc for building shared libraries.
|
|---|
| 2767 | build_libtool_need_lc=$need_lc
|
|---|
| 2768 |
|
|---|
| 2769 | # Whether or not to optimize for fast installation.
|
|---|
| 2770 | fast_install=$enable_fast_install
|
|---|
| 2771 |
|
|---|
| 2772 | # The host system.
|
|---|
| 2773 | host_alias=$host_alias
|
|---|
| 2774 | host=$host
|
|---|
| 2775 |
|
|---|
| 2776 | # An echo program that does not interpret backslashes.
|
|---|
| 2777 | echo=$lt_echo
|
|---|
| 2778 |
|
|---|
| 2779 | # The archiver.
|
|---|
| 2780 | AR=$lt_AR
|
|---|
| 2781 | AR_FLAGS=$lt_AR_FLAGS
|
|---|
| 2782 |
|
|---|
| 2783 | # The default C compiler.
|
|---|
| 2784 | CC=$lt_CC
|
|---|
| 2785 |
|
|---|
| 2786 | # Is the compiler the GNU C compiler?
|
|---|
| 2787 | with_gcc=$GCC
|
|---|
| 2788 |
|
|---|
| 2789 | # The linker used to build libraries.
|
|---|
| 2790 | LD=$lt_LD
|
|---|
| 2791 |
|
|---|
| 2792 | # Whether we need hard or soft links.
|
|---|
| 2793 | LN_S=$lt_LN_S
|
|---|
| 2794 |
|
|---|
| 2795 | # A BSD-compatible nm program.
|
|---|
| 2796 | NM=$lt_NM
|
|---|
| 2797 |
|
|---|
| 2798 | # A symbol stripping program
|
|---|
| 2799 | STRIP=$STRIP
|
|---|
| 2800 |
|
|---|
| 2801 | # Used to examine libraries when file_magic_cmd begins "file"
|
|---|
| 2802 | MAGIC_CMD=$MAGIC_CMD
|
|---|
| 2803 |
|
|---|
| 2804 | # Used on cygwin: DLL creation program.
|
|---|
| 2805 | DLLTOOL="$DLLTOOL"
|
|---|
| 2806 |
|
|---|
| 2807 | # Used on cygwin: object dumper.
|
|---|
| 2808 | OBJDUMP="$OBJDUMP"
|
|---|
| 2809 |
|
|---|
| 2810 | # Used on cygwin: assembler.
|
|---|
| 2811 | AS="$AS"
|
|---|
| 2812 |
|
|---|
| 2813 | # The name of the directory that contains temporary libtool files.
|
|---|
| 2814 | objdir=$objdir
|
|---|
| 2815 |
|
|---|
| 2816 | # How to create reloadable object files.
|
|---|
| 2817 | reload_flag=$lt_reload_flag
|
|---|
| 2818 | reload_cmds=$lt_reload_cmds
|
|---|
| 2819 |
|
|---|
| 2820 | # How to pass a linker flag through the compiler.
|
|---|
| 2821 | wl=$lt_wl
|
|---|
| 2822 |
|
|---|
| 2823 | # Object file suffix (normally "o").
|
|---|
| 2824 | objext="$ac_objext"
|
|---|
| 2825 |
|
|---|
| 2826 | # Old archive suffix (normally "a").
|
|---|
| 2827 | libext="$libext"
|
|---|
| 2828 |
|
|---|
| 2829 | # Executable file suffix (normally "").
|
|---|
| 2830 | exeext="$exeext"
|
|---|
| 2831 |
|
|---|
| 2832 | # Additional compiler flags for building library objects.
|
|---|
| 2833 | pic_flag=$lt_pic_flag
|
|---|
| 2834 | pic_mode=$pic_mode
|
|---|
| 2835 |
|
|---|
| 2836 | # Does compiler simultaneously support -c and -o options?
|
|---|
| 2837 | compiler_c_o=$lt_compiler_c_o
|
|---|
| 2838 |
|
|---|
| 2839 | # Can we write directly to a .lo ?
|
|---|
| 2840 | compiler_o_lo=$lt_compiler_o_lo
|
|---|
| 2841 |
|
|---|
| 2842 | # Must we lock files when doing compilation ?
|
|---|
| 2843 | need_locks=$lt_need_locks
|
|---|
| 2844 |
|
|---|
| 2845 | # Do we need the lib prefix for modules?
|
|---|
| 2846 | need_lib_prefix=$need_lib_prefix
|
|---|
| 2847 |
|
|---|
| 2848 | # Do we need a version for libraries?
|
|---|
| 2849 | need_version=$need_version
|
|---|
| 2850 |
|
|---|
| 2851 | # Whether dlopen is supported.
|
|---|
| 2852 | dlopen_support=$enable_dlopen
|
|---|
| 2853 |
|
|---|
| 2854 | # Whether dlopen of programs is supported.
|
|---|
| 2855 | dlopen_self=$enable_dlopen_self
|
|---|
| 2856 |
|
|---|
| 2857 | # Whether dlopen of statically linked programs is supported.
|
|---|
| 2858 | dlopen_self_static=$enable_dlopen_self_static
|
|---|
| 2859 |
|
|---|
| 2860 | # Compiler flag to prevent dynamic linking.
|
|---|
| 2861 | link_static_flag=$lt_link_static_flag
|
|---|
| 2862 |
|
|---|
| 2863 | # Compiler flag to turn off builtin functions.
|
|---|
| 2864 | no_builtin_flag=$lt_no_builtin_flag
|
|---|
| 2865 |
|
|---|
| 2866 | # Compiler flag to allow reflexive dlopens.
|
|---|
| 2867 | export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
|
|---|
| 2868 |
|
|---|
| 2869 | # Compiler flag to generate shared objects directly from archives.
|
|---|
| 2870 | whole_archive_flag_spec=$lt_whole_archive_flag_spec
|
|---|
| 2871 |
|
|---|
| 2872 | # Compiler flag to generate thread-safe objects.
|
|---|
| 2873 | thread_safe_flag_spec=$lt_thread_safe_flag_spec
|
|---|
| 2874 |
|
|---|
| 2875 | # Library versioning type.
|
|---|
| 2876 | version_type=$version_type
|
|---|
| 2877 |
|
|---|
| 2878 | # Format of library name prefix.
|
|---|
| 2879 | libname_spec=$lt_libname_spec
|
|---|
| 2880 |
|
|---|
| 2881 | # List of archive names. First name is the real one, the rest are links.
|
|---|
| 2882 | # The last name is the one that the linker finds with -lNAME.
|
|---|
| 2883 | library_names_spec=$lt_library_names_spec
|
|---|
| 2884 |
|
|---|
| 2885 | # The coded name of the library, if different from the real name.
|
|---|
| 2886 | soname_spec=$lt_soname_spec
|
|---|
| 2887 |
|
|---|
| 2888 | # Commands used to build and install an old-style archive.
|
|---|
| 2889 | RANLIB=$lt_RANLIB
|
|---|
| 2890 | old_archive_cmds=$lt_old_archive_cmds
|
|---|
| 2891 | old_postinstall_cmds=$lt_old_postinstall_cmds
|
|---|
| 2892 | old_postuninstall_cmds=$lt_old_postuninstall_cmds
|
|---|
| 2893 |
|
|---|
| 2894 | # Create an old-style archive from a shared archive.
|
|---|
| 2895 | old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
|
|---|
| 2896 |
|
|---|
| 2897 | # Create a temporary old-style archive to link instead of a shared archive.
|
|---|
| 2898 | old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
|
|---|
| 2899 |
|
|---|
| 2900 | # Commands used to build and install a shared archive.
|
|---|
| 2901 | archive_cmds=$lt_archive_cmds
|
|---|
| 2902 | archive_expsym_cmds=$lt_archive_expsym_cmds
|
|---|
| 2903 | postinstall_cmds=$lt_postinstall_cmds
|
|---|
| 2904 | postuninstall_cmds=$lt_postuninstall_cmds
|
|---|
| 2905 |
|
|---|
| 2906 | # Commands to strip libraries.
|
|---|
| 2907 | old_striplib=$lt_old_striplib
|
|---|
| 2908 | striplib=$lt_striplib
|
|---|
| 2909 |
|
|---|
| 2910 | # Method to check whether dependent libraries are shared objects.
|
|---|
| 2911 | deplibs_check_method=$lt_deplibs_check_method
|
|---|
| 2912 |
|
|---|
| 2913 | # Command to use when deplibs_check_method == file_magic.
|
|---|
| 2914 | file_magic_cmd=$lt_file_magic_cmd
|
|---|
| 2915 |
|
|---|
| 2916 | # Flag that allows shared libraries with undefined symbols to be built.
|
|---|
| 2917 | allow_undefined_flag=$lt_allow_undefined_flag
|
|---|
| 2918 |
|
|---|
| 2919 | # Flag that forces no undefined symbols.
|
|---|
| 2920 | no_undefined_flag=$lt_no_undefined_flag
|
|---|
| 2921 |
|
|---|
| 2922 | # Commands used to finish a libtool library installation in a directory.
|
|---|
| 2923 | finish_cmds=$lt_finish_cmds
|
|---|
| 2924 |
|
|---|
| 2925 | # Same as above, but a single script fragment to be evaled but not shown.
|
|---|
| 2926 | finish_eval=$lt_finish_eval
|
|---|
| 2927 |
|
|---|
| 2928 | # Take the output of nm and produce a listing of raw symbols and C names.
|
|---|
| 2929 | global_symbol_pipe=$lt_global_symbol_pipe
|
|---|
| 2930 |
|
|---|
| 2931 | # Transform the output of nm in a proper C declaration
|
|---|
| 2932 | global_symbol_to_cdecl=$lt_global_symbol_to_cdecl
|
|---|
| 2933 |
|
|---|
| 2934 | # Transform the output of nm in a C name address pair
|
|---|
| 2935 | global_symbol_to_c_name_address=$lt_global_symbol_to_c_name_address
|
|---|
| 2936 |
|
|---|
| 2937 | # This is the shared library runtime path variable.
|
|---|
| 2938 | runpath_var=$runpath_var
|
|---|
| 2939 |
|
|---|
| 2940 | # This is the shared library path variable.
|
|---|
| 2941 | shlibpath_var=$shlibpath_var
|
|---|
| 2942 |
|
|---|
| 2943 | # Is shlibpath searched before the hard-coded library search path?
|
|---|
| 2944 | shlibpath_overrides_runpath=$shlibpath_overrides_runpath
|
|---|
| 2945 |
|
|---|
| 2946 | # How to hardcode a shared library path into an executable.
|
|---|
| 2947 | hardcode_action=$hardcode_action
|
|---|
| 2948 |
|
|---|
| 2949 | # Whether we should hardcode library paths into libraries.
|
|---|
| 2950 | hardcode_into_libs=$hardcode_into_libs
|
|---|
| 2951 |
|
|---|
| 2952 | # Flag to hardcode \$libdir into a binary during linking.
|
|---|
| 2953 | # This must work even if \$libdir does not exist.
|
|---|
| 2954 | hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
|
|---|
| 2955 |
|
|---|
| 2956 | # Whether we need a single -rpath flag with a separated argument.
|
|---|
| 2957 | hardcode_libdir_separator=$lt_hardcode_libdir_separator
|
|---|
| 2958 |
|
|---|
| 2959 | # Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
|
|---|
| 2960 | # resulting binary.
|
|---|
| 2961 | hardcode_direct=$hardcode_direct
|
|---|
| 2962 |
|
|---|
| 2963 | # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
|
|---|
| 2964 | # resulting binary.
|
|---|
| 2965 | hardcode_minus_L=$hardcode_minus_L
|
|---|
| 2966 |
|
|---|
| 2967 | # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
|
|---|
| 2968 | # the resulting binary.
|
|---|
| 2969 | hardcode_shlibpath_var=$hardcode_shlibpath_var
|
|---|
| 2970 |
|
|---|
| 2971 | # Variables whose values should be saved in libtool wrapper scripts and
|
|---|
| 2972 | # restored at relink time.
|
|---|
| 2973 | variables_saved_for_relink="$variables_saved_for_relink"
|
|---|
| 2974 |
|
|---|
| 2975 | # Whether libtool must link a program against all its dependency libraries.
|
|---|
| 2976 | link_all_deplibs=$link_all_deplibs
|
|---|
| 2977 |
|
|---|
| 2978 | # Compile-time system search path for libraries
|
|---|
| 2979 | sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
|
|---|
| 2980 |
|
|---|
| 2981 | # Run-time system search path for libraries
|
|---|
| 2982 | sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
|
|---|
| 2983 |
|
|---|
| 2984 | # Fix the shell variable \$srcfile for the compiler.
|
|---|
| 2985 | fix_srcfile_path="$fix_srcfile_path"
|
|---|
| 2986 |
|
|---|
| 2987 | # Set to yes if exported symbols are required.
|
|---|
| 2988 | always_export_symbols=$always_export_symbols
|
|---|
| 2989 |
|
|---|
| 2990 | # The commands to list exported symbols.
|
|---|
| 2991 | export_symbols_cmds=$lt_export_symbols_cmds
|
|---|
| 2992 |
|
|---|
| 2993 | # The commands to extract the exported symbol list from a shared archive.
|
|---|
| 2994 | extract_expsyms_cmds=$lt_extract_expsyms_cmds
|
|---|
| 2995 |
|
|---|
| 2996 | # Symbols that should not be listed in the preloaded symbols.
|
|---|
| 2997 | exclude_expsyms=$lt_exclude_expsyms
|
|---|
| 2998 |
|
|---|
| 2999 | # Symbols that must always be exported.
|
|---|
| 3000 | include_expsyms=$lt_include_expsyms
|
|---|
| 3001 |
|
|---|
| 3002 | # ### END LIBTOOL CONFIG
|
|---|
| 3003 |
|
|---|
| 3004 | __EOF__
|
|---|
| 3005 |
|
|---|
| 3006 | case $host_os in
|
|---|
| 3007 | aix3*)
|
|---|
| 3008 | cat <<\EOF >> "${ofile}T"
|
|---|
| 3009 |
|
|---|
| 3010 | # AIX sometimes has problems with the GCC collect2 program. For some
|
|---|
| 3011 | # reason, if we set the COLLECT_NAMES environment variable, the problems
|
|---|
| 3012 | # vanish in a puff of smoke.
|
|---|
| 3013 | if test "X${COLLECT_NAMES+set}" != Xset; then
|
|---|
| 3014 | COLLECT_NAMES=
|
|---|
| 3015 | export COLLECT_NAMES
|
|---|
| 3016 | fi
|
|---|
| 3017 | EOF
|
|---|
| 3018 | ;;
|
|---|
| 3019 | esac
|
|---|
| 3020 |
|
|---|
| 3021 | case $host_os in
|
|---|
| 3022 | cygwin* | mingw* | pw32* | os2*)
|
|---|
| 3023 | cat <<'EOF' >> "${ofile}T"
|
|---|
| 3024 | # This is a source program that is used to create dlls on Windows
|
|---|
| 3025 | # Don't remove nor modify the starting and closing comments
|
|---|
| 3026 | # /* ltdll.c starts here */
|
|---|
| 3027 | # #define WIN32_LEAN_AND_MEAN
|
|---|
| 3028 | # #include <windows.h>
|
|---|
| 3029 | # #undef WIN32_LEAN_AND_MEAN
|
|---|
| 3030 | # #include <stdio.h>
|
|---|
| 3031 | #
|
|---|
| 3032 | # #ifndef __CYGWIN__
|
|---|
| 3033 | # # ifdef __CYGWIN32__
|
|---|
| 3034 | # # define __CYGWIN__ __CYGWIN32__
|
|---|
| 3035 | # # endif
|
|---|
| 3036 | # #endif
|
|---|
| 3037 | #
|
|---|
| 3038 | # #ifdef __cplusplus
|
|---|
| 3039 | # extern "C" {
|
|---|
| 3040 | # #endif
|
|---|
| 3041 | # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
|
|---|
| 3042 | # #ifdef __cplusplus
|
|---|
| 3043 | # }
|
|---|
| 3044 | # #endif
|
|---|
| 3045 | #
|
|---|
| 3046 | # #ifdef __CYGWIN__
|
|---|
| 3047 | # #include <cygwin/cygwin_dll.h>
|
|---|
| 3048 | # DECLARE_CYGWIN_DLL( DllMain );
|
|---|
| 3049 | # #endif
|
|---|
| 3050 | # HINSTANCE __hDllInstance_base;
|
|---|
| 3051 | #
|
|---|
| 3052 | # BOOL APIENTRY
|
|---|
| 3053 | # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
|
|---|
| 3054 | # {
|
|---|
| 3055 | # __hDllInstance_base = hInst;
|
|---|
| 3056 | # return TRUE;
|
|---|
| 3057 | # }
|
|---|
| 3058 | # /* ltdll.c ends here */
|
|---|
| 3059 | # This is a source program that is used to create import libraries
|
|---|
| 3060 | # on Windows for dlls which lack them. Don't remove nor modify the
|
|---|
| 3061 | # starting and closing comments
|
|---|
| 3062 | # /* impgen.c starts here */
|
|---|
| 3063 | # /* Copyright (C) 1999-2000 Free Software Foundation, Inc.
|
|---|
| 3064 | #
|
|---|
| 3065 | # This file is part of GNU libtool.
|
|---|
| 3066 | #
|
|---|
| 3067 | # This program is free software; you can redistribute it and/or modify
|
|---|
| 3068 | # it under the terms of the GNU General Public License as published by
|
|---|
| 3069 | # the Free Software Foundation; either version 2 of the License, or
|
|---|
| 3070 | # (at your option) any later version.
|
|---|
| 3071 | #
|
|---|
| 3072 | # This program is distributed in the hope that it will be useful,
|
|---|
| 3073 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 3074 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 3075 | # GNU General Public License for more details.
|
|---|
| 3076 | #
|
|---|
| 3077 | # You should have received a copy of the GNU General Public License
|
|---|
| 3078 | # along with this program; if not, write to the Free Software
|
|---|
| 3079 | # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|---|
| 3080 | # */
|
|---|
| 3081 | #
|
|---|
| 3082 | # #include <stdio.h> /* for printf() */
|
|---|
| 3083 | # #include <unistd.h> /* for open(), lseek(), read() */
|
|---|
| 3084 | # #include <fcntl.h> /* for O_RDONLY, O_BINARY */
|
|---|
| 3085 | # #include <string.h> /* for strdup() */
|
|---|
| 3086 | #
|
|---|
| 3087 | # /* O_BINARY isn't required (or even defined sometimes) under Unix */
|
|---|
| 3088 | # #ifndef O_BINARY
|
|---|
| 3089 | # #define O_BINARY 0
|
|---|
| 3090 | # #endif
|
|---|
| 3091 | #
|
|---|
| 3092 | # static unsigned int
|
|---|
| 3093 | # pe_get16 (fd, offset)
|
|---|
| 3094 | # int fd;
|
|---|
| 3095 | # int offset;
|
|---|
| 3096 | # {
|
|---|
| 3097 | # unsigned char b[2];
|
|---|
| 3098 | # lseek (fd, offset, SEEK_SET);
|
|---|
| 3099 | # read (fd, b, 2);
|
|---|
| 3100 | # return b[0] + (b[1]<<8);
|
|---|
| 3101 | # }
|
|---|
| 3102 | #
|
|---|
| 3103 | # static unsigned int
|
|---|
| 3104 | # pe_get32 (fd, offset)
|
|---|
| 3105 | # int fd;
|
|---|
| 3106 | # int offset;
|
|---|
| 3107 | # {
|
|---|
| 3108 | # unsigned char b[4];
|
|---|
| 3109 | # lseek (fd, offset, SEEK_SET);
|
|---|
| 3110 | # read (fd, b, 4);
|
|---|
| 3111 | # return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
|
|---|
| 3112 | # }
|
|---|
| 3113 | #
|
|---|
| 3114 | # static unsigned int
|
|---|
| 3115 | # pe_as32 (ptr)
|
|---|
| 3116 | # void *ptr;
|
|---|
| 3117 | # {
|
|---|
| 3118 | # unsigned char *b = ptr;
|
|---|
| 3119 | # return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
|
|---|
| 3120 | # }
|
|---|
| 3121 | #
|
|---|
| 3122 | # int
|
|---|
| 3123 | # main (argc, argv)
|
|---|
| 3124 | # int argc;
|
|---|
| 3125 | # char *argv[];
|
|---|
| 3126 | # {
|
|---|
| 3127 | # int dll;
|
|---|
| 3128 | # unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
|
|---|
| 3129 | # unsigned long export_rva, export_size, nsections, secptr, expptr;
|
|---|
| 3130 | # unsigned long name_rvas, nexp;
|
|---|
| 3131 | # unsigned char *expdata, *erva;
|
|---|
| 3132 | # char *filename, *dll_name;
|
|---|
| 3133 | #
|
|---|
| 3134 | # filename = argv[1];
|
|---|
| 3135 | #
|
|---|
| 3136 | # dll = open(filename, O_RDONLY|O_BINARY);
|
|---|
| 3137 | # if (dll < 1)
|
|---|
| 3138 | # return 1;
|
|---|
| 3139 | #
|
|---|
| 3140 | # dll_name = filename;
|
|---|
| 3141 | #
|
|---|
| 3142 | # for (i=0; filename[i]; i++)
|
|---|
| 3143 | # if (filename[i] == '/' || filename[i] == '\\' || filename[i] == ':')
|
|---|
| 3144 | # dll_name = filename + i +1;
|
|---|
| 3145 | #
|
|---|
| 3146 | # pe_header_offset = pe_get32 (dll, 0x3c);
|
|---|
| 3147 | # opthdr_ofs = pe_header_offset + 4 + 20;
|
|---|
| 3148 | # num_entries = pe_get32 (dll, opthdr_ofs + 92);
|
|---|
| 3149 | #
|
|---|
| 3150 | # if (num_entries < 1) /* no exports */
|
|---|
| 3151 | # return 1;
|
|---|
| 3152 | #
|
|---|
| 3153 | # export_rva = pe_get32 (dll, opthdr_ofs + 96);
|
|---|
| 3154 | # export_size = pe_get32 (dll, opthdr_ofs + 100);
|
|---|
| 3155 | # nsections = pe_get16 (dll, pe_header_offset + 4 +2);
|
|---|
| 3156 | # secptr = (pe_header_offset + 4 + 20 +
|
|---|
| 3157 | # pe_get16 (dll, pe_header_offset + 4 + 16));
|
|---|
| 3158 | #
|
|---|
| 3159 | # expptr = 0;
|
|---|
| 3160 | # for (i = 0; i < nsections; i++)
|
|---|
| 3161 | # {
|
|---|
| 3162 | # char sname[8];
|
|---|
| 3163 | # unsigned long secptr1 = secptr + 40 * i;
|
|---|
| 3164 | # unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
|
|---|
| 3165 | # unsigned long vsize = pe_get32 (dll, secptr1 + 16);
|
|---|
| 3166 | # unsigned long fptr = pe_get32 (dll, secptr1 + 20);
|
|---|
| 3167 | # lseek(dll, secptr1, SEEK_SET);
|
|---|
| 3168 | # read(dll, sname, 8);
|
|---|
| 3169 | # if (vaddr <= export_rva && vaddr+vsize > export_rva)
|
|---|
| 3170 | # {
|
|---|
| 3171 | # expptr = fptr + (export_rva - vaddr);
|
|---|
| 3172 | # if (export_rva + export_size > vaddr + vsize)
|
|---|
| 3173 | # export_size = vsize - (export_rva - vaddr);
|
|---|
| 3174 | # break;
|
|---|
| 3175 | # }
|
|---|
| 3176 | # }
|
|---|
| 3177 | #
|
|---|
| 3178 | # expdata = (unsigned char*)malloc(export_size);
|
|---|
| 3179 | # lseek (dll, expptr, SEEK_SET);
|
|---|
| 3180 | # read (dll, expdata, export_size);
|
|---|
| 3181 | # erva = expdata - export_rva;
|
|---|
| 3182 | #
|
|---|
| 3183 | # nexp = pe_as32 (expdata+24);
|
|---|
| 3184 | # name_rvas = pe_as32 (expdata+32);
|
|---|
| 3185 | #
|
|---|
| 3186 | # printf ("EXPORTS\n");
|
|---|
| 3187 | # for (i = 0; i<nexp; i++)
|
|---|
| 3188 | # {
|
|---|
| 3189 | # unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
|
|---|
| 3190 | # printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
|
|---|
| 3191 | # }
|
|---|
| 3192 | #
|
|---|
| 3193 | # return 0;
|
|---|
| 3194 | # }
|
|---|
| 3195 | # /* impgen.c ends here */
|
|---|
| 3196 |
|
|---|
| 3197 | EOF
|
|---|
| 3198 | ;;
|
|---|
| 3199 | esac
|
|---|
| 3200 |
|
|---|
| 3201 | # We use sed instead of cat because bash on DJGPP gets confused if
|
|---|
| 3202 | # if finds mixed CR/LF and LF-only lines. Since sed operates in
|
|---|
| 3203 | # text mode, it properly converts lines to CR/LF. This bash problem
|
|---|
| 3204 | # is reportedly fixed, but why not run on old versions too?
|
|---|
| 3205 | sed '$q' "$ltmain" >> "${ofile}T" || (rm -f "${ofile}T"; exit 1)
|
|---|
| 3206 |
|
|---|
| 3207 | mv -f "${ofile}T" "$ofile" || \
|
|---|
| 3208 | (rm -f "$ofile" && cp "${ofile}T" "$ofile" && rm -f "${ofile}T")
|
|---|
| 3209 | chmod +x "$ofile"
|
|---|
| 3210 | fi
|
|---|
| 3211 |
|
|---|
| 3212 | ])# _LT_AC_LTCONFIG_HACK
|
|---|
| 3213 |
|
|---|
| 3214 | # AC_LIBTOOL_DLOPEN - enable checks for dlopen support
|
|---|
| 3215 | AC_DEFUN([AC_LIBTOOL_DLOPEN], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])])
|
|---|
| 3216 |
|
|---|
| 3217 | # AC_LIBTOOL_WIN32_DLL - declare package support for building win32 dll's
|
|---|
| 3218 | AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])])
|
|---|
| 3219 |
|
|---|
| 3220 | # AC_ENABLE_SHARED - implement the --enable-shared flag
|
|---|
| 3221 | # Usage: AC_ENABLE_SHARED[(DEFAULT)]
|
|---|
| 3222 | # Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
|
|---|
| 3223 | # `yes'.
|
|---|
| 3224 | AC_DEFUN([AC_ENABLE_SHARED],
|
|---|
| 3225 | [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
|
|---|
| 3226 | AC_ARG_ENABLE(shared,
|
|---|
| 3227 | changequote(<<, >>)dnl
|
|---|
| 3228 | << --enable-shared[=PKGS] build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
|
|---|
| 3229 | changequote([, ])dnl
|
|---|
| 3230 | [p=${PACKAGE-default}
|
|---|
| 3231 | case $enableval in
|
|---|
| 3232 | yes) enable_shared=yes ;;
|
|---|
| 3233 | no) enable_shared=no ;;
|
|---|
| 3234 | *)
|
|---|
| 3235 | enable_shared=no
|
|---|
| 3236 | # Look at the argument we got. We use all the common list separators.
|
|---|
| 3237 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
|
|---|
| 3238 | for pkg in $enableval; do
|
|---|
| 3239 | if test "X$pkg" = "X$p"; then
|
|---|
| 3240 | enable_shared=yes
|
|---|
| 3241 | fi
|
|---|
| 3242 | done
|
|---|
| 3243 | IFS="$ac_save_ifs"
|
|---|
| 3244 | ;;
|
|---|
| 3245 | esac],
|
|---|
| 3246 | enable_shared=AC_ENABLE_SHARED_DEFAULT)dnl
|
|---|
| 3247 | ])
|
|---|
| 3248 |
|
|---|
| 3249 | # AC_DISABLE_SHARED - set the default shared flag to --disable-shared
|
|---|
| 3250 | AC_DEFUN([AC_DISABLE_SHARED],
|
|---|
| 3251 | [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
|
|---|
| 3252 | AC_ENABLE_SHARED(no)])
|
|---|
| 3253 |
|
|---|
| 3254 | # AC_ENABLE_STATIC - implement the --enable-static flag
|
|---|
| 3255 | # Usage: AC_ENABLE_STATIC[(DEFAULT)]
|
|---|
| 3256 | # Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
|
|---|
| 3257 | # `yes'.
|
|---|
| 3258 | AC_DEFUN([AC_ENABLE_STATIC],
|
|---|
| 3259 | [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
|
|---|
| 3260 | AC_ARG_ENABLE(static,
|
|---|
| 3261 | changequote(<<, >>)dnl
|
|---|
| 3262 | << --enable-static[=PKGS] build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
|
|---|
| 3263 | changequote([, ])dnl
|
|---|
| 3264 | [p=${PACKAGE-default}
|
|---|
| 3265 | case $enableval in
|
|---|
| 3266 | yes) enable_static=yes ;;
|
|---|
| 3267 | no) enable_static=no ;;
|
|---|
| 3268 | *)
|
|---|
| 3269 | enable_static=no
|
|---|
| 3270 | # Look at the argument we got. We use all the common list separators.
|
|---|
| 3271 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
|
|---|
| 3272 | for pkg in $enableval; do
|
|---|
| 3273 | if test "X$pkg" = "X$p"; then
|
|---|
| 3274 | enable_static=yes
|
|---|
| 3275 | fi
|
|---|
| 3276 | done
|
|---|
| 3277 | IFS="$ac_save_ifs"
|
|---|
| 3278 | ;;
|
|---|
| 3279 | esac],
|
|---|
| 3280 | enable_static=AC_ENABLE_STATIC_DEFAULT)dnl
|
|---|
| 3281 | ])
|
|---|
| 3282 |
|
|---|
| 3283 | # AC_DISABLE_STATIC - set the default static flag to --disable-static
|
|---|
| 3284 | AC_DEFUN([AC_DISABLE_STATIC],
|
|---|
| 3285 | [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
|
|---|
| 3286 | AC_ENABLE_STATIC(no)])
|
|---|
| 3287 |
|
|---|
| 3288 |
|
|---|
| 3289 | # AC_ENABLE_FAST_INSTALL - implement the --enable-fast-install flag
|
|---|
| 3290 | # Usage: AC_ENABLE_FAST_INSTALL[(DEFAULT)]
|
|---|
| 3291 | # Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
|
|---|
| 3292 | # `yes'.
|
|---|
| 3293 | AC_DEFUN([AC_ENABLE_FAST_INSTALL],
|
|---|
| 3294 | [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
|
|---|
| 3295 | AC_ARG_ENABLE(fast-install,
|
|---|
| 3296 | changequote(<<, >>)dnl
|
|---|
| 3297 | << --enable-fast-install[=PKGS] optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
|
|---|
| 3298 | changequote([, ])dnl
|
|---|
| 3299 | [p=${PACKAGE-default}
|
|---|
| 3300 | case $enableval in
|
|---|
| 3301 | yes) enable_fast_install=yes ;;
|
|---|
| 3302 | no) enable_fast_install=no ;;
|
|---|
| 3303 | *)
|
|---|
| 3304 | enable_fast_install=no
|
|---|
| 3305 | # Look at the argument we got. We use all the common list separators.
|
|---|
| 3306 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
|
|---|
| 3307 | for pkg in $enableval; do
|
|---|
| 3308 | if test "X$pkg" = "X$p"; then
|
|---|
| 3309 | enable_fast_install=yes
|
|---|
| 3310 | fi
|
|---|
| 3311 | done
|
|---|
| 3312 | IFS="$ac_save_ifs"
|
|---|
| 3313 | ;;
|
|---|
| 3314 | esac],
|
|---|
| 3315 | enable_fast_install=AC_ENABLE_FAST_INSTALL_DEFAULT)dnl
|
|---|
| 3316 | ])
|
|---|
| 3317 |
|
|---|
| 3318 | # AC_DISABLE_FAST_INSTALL - set the default to --disable-fast-install
|
|---|
| 3319 | AC_DEFUN([AC_DISABLE_FAST_INSTALL],
|
|---|
| 3320 | [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
|
|---|
| 3321 | AC_ENABLE_FAST_INSTALL(no)])
|
|---|
| 3322 |
|
|---|
| 3323 | # AC_LIBTOOL_PICMODE - implement the --with-pic flag
|
|---|
| 3324 | # Usage: AC_LIBTOOL_PICMODE[(MODE)]
|
|---|
| 3325 | # Where MODE is either `yes' or `no'. If omitted, it defaults to
|
|---|
| 3326 | # `both'.
|
|---|
| 3327 | AC_DEFUN([AC_LIBTOOL_PICMODE],
|
|---|
| 3328 | [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
|
|---|
| 3329 | pic_mode=ifelse($#,1,$1,default)])
|
|---|
| 3330 |
|
|---|
| 3331 |
|
|---|
| 3332 | # AC_PATH_TOOL_PREFIX - find a file program which can recognise shared library
|
|---|
| 3333 | AC_DEFUN([AC_PATH_TOOL_PREFIX],
|
|---|
| 3334 | [AC_MSG_CHECKING([for $1])
|
|---|
| 3335 | AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
|
|---|
| 3336 | [case $MAGIC_CMD in
|
|---|
| 3337 | /*)
|
|---|
| 3338 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
|
|---|
| 3339 | ;;
|
|---|
| 3340 | ?:/*)
|
|---|
| 3341 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
|
|---|
| 3342 | ;;
|
|---|
| 3343 | *)
|
|---|
| 3344 | ac_save_MAGIC_CMD="$MAGIC_CMD"
|
|---|
| 3345 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
|
|---|
| 3346 | dnl $ac_dummy forces splitting on constant user-supplied paths.
|
|---|
| 3347 | dnl POSIX.2 word splitting is done only on the output of word expansions,
|
|---|
| 3348 | dnl not every word. This closes a longstanding sh security hole.
|
|---|
| 3349 | ac_dummy="ifelse([$2], , $PATH, [$2])"
|
|---|
| 3350 | for ac_dir in $ac_dummy; do
|
|---|
| 3351 | test -z "$ac_dir" && ac_dir=.
|
|---|
| 3352 | if test -f $ac_dir/$1; then
|
|---|
| 3353 | lt_cv_path_MAGIC_CMD="$ac_dir/$1"
|
|---|
| 3354 | if test -n "$file_magic_test_file"; then
|
|---|
| 3355 | case $deplibs_check_method in
|
|---|
| 3356 | "file_magic "*)
|
|---|
| 3357 | file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
|
|---|
| 3358 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
|
|---|
| 3359 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
|
|---|
| 3360 | egrep "$file_magic_regex" > /dev/null; then
|
|---|
| 3361 | :
|
|---|
| 3362 | else
|
|---|
| 3363 | cat <<EOF 1>&2
|
|---|
| 3364 |
|
|---|
| 3365 | *** Warning: the command libtool uses to detect shared libraries,
|
|---|
| 3366 | *** $file_magic_cmd, produces output that libtool cannot recognize.
|
|---|
| 3367 | *** The result is that libtool may fail to recognize shared libraries
|
|---|
| 3368 | *** as such. This will affect the creation of libtool libraries that
|
|---|
| 3369 | *** depend on shared libraries, but programs linked with such libtool
|
|---|
| 3370 | *** libraries will work regardless of this problem. Nevertheless, you
|
|---|
| 3371 | *** may want to report the problem to your system manager and/or to
|
|---|
| 3372 | *** bug-libtool@gnu.org
|
|---|
| 3373 |
|
|---|
| 3374 | EOF
|
|---|
| 3375 | fi ;;
|
|---|
| 3376 | esac
|
|---|
| 3377 | fi
|
|---|
| 3378 | break
|
|---|
| 3379 | fi
|
|---|
| 3380 | done
|
|---|
| 3381 | IFS="$ac_save_ifs"
|
|---|
| 3382 | MAGIC_CMD="$ac_save_MAGIC_CMD"
|
|---|
| 3383 | ;;
|
|---|
| 3384 | esac])
|
|---|
| 3385 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
|
|---|
| 3386 | if test -n "$MAGIC_CMD"; then
|
|---|
| 3387 | AC_MSG_RESULT($MAGIC_CMD)
|
|---|
| 3388 | else
|
|---|
| 3389 | AC_MSG_RESULT(no)
|
|---|
| 3390 | fi
|
|---|
| 3391 | ])
|
|---|
| 3392 |
|
|---|
| 3393 |
|
|---|
| 3394 | # AC_PATH_MAGIC - find a file program which can recognise a shared library
|
|---|
| 3395 | AC_DEFUN([AC_PATH_MAGIC],
|
|---|
| 3396 | [AC_REQUIRE([AC_CHECK_TOOL_PREFIX])dnl
|
|---|
| 3397 | AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin:$PATH)
|
|---|
| 3398 | if test -z "$lt_cv_path_MAGIC_CMD"; then
|
|---|
| 3399 | if test -n "$ac_tool_prefix"; then
|
|---|
| 3400 | AC_PATH_TOOL_PREFIX(file, /usr/bin:$PATH)
|
|---|
| 3401 | else
|
|---|
| 3402 | MAGIC_CMD=:
|
|---|
| 3403 | fi
|
|---|
| 3404 | fi
|
|---|
| 3405 | ])
|
|---|
| 3406 |
|
|---|
| 3407 |
|
|---|
| 3408 | # AC_PROG_LD - find the path to the GNU or non-GNU linker
|
|---|
| 3409 | AC_DEFUN([AC_PROG_LD],
|
|---|
| 3410 | [AC_ARG_WITH(gnu-ld,
|
|---|
| 3411 | [ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
|
|---|
| 3412 | test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
|
|---|
| 3413 | AC_REQUIRE([AC_PROG_CC])dnl
|
|---|
| 3414 | AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
|---|
| 3415 | AC_REQUIRE([AC_CANONICAL_BUILD])dnl
|
|---|
| 3416 | AC_REQUIRE([_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR])dnl
|
|---|
| 3417 | ac_prog=ld
|
|---|
| 3418 | if test "$GCC" = yes; then
|
|---|
| 3419 | # Check if gcc -print-prog-name=ld gives a path.
|
|---|
| 3420 | AC_MSG_CHECKING([for ld used by GCC])
|
|---|
| 3421 | case $host in
|
|---|
| 3422 | *-*-mingw*)
|
|---|
| 3423 | # gcc leaves a trailing carriage return which upsets mingw
|
|---|
| 3424 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
|
|---|
| 3425 | *)
|
|---|
| 3426 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
|
|---|
| 3427 | esac
|
|---|
| 3428 | case $ac_prog in
|
|---|
| 3429 | # Accept absolute paths.
|
|---|
| 3430 | [[\\/]]* | [[A-Za-z]]:[[\\/]]*)
|
|---|
| 3431 | re_direlt='/[[^/]][[^/]]*/\.\./'
|
|---|
| 3432 | # Canonicalize the path of ld
|
|---|
| 3433 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
|
|---|
| 3434 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
|
|---|
| 3435 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
|
|---|
| 3436 | done
|
|---|
| 3437 | test -z "$LD" && LD="$ac_prog"
|
|---|
| 3438 | ;;
|
|---|
| 3439 | "")
|
|---|
| 3440 | # If it fails, then pretend we aren't using GCC.
|
|---|
| 3441 | ac_prog=ld
|
|---|
| 3442 | ;;
|
|---|
| 3443 | *)
|
|---|
| 3444 | # If it is relative, then search for the first ld in PATH.
|
|---|
| 3445 | with_gnu_ld=unknown
|
|---|
| 3446 | ;;
|
|---|
| 3447 | esac
|
|---|
| 3448 | elif test "$with_gnu_ld" = yes; then
|
|---|
| 3449 | AC_MSG_CHECKING([for GNU ld])
|
|---|
| 3450 | else
|
|---|
| 3451 | AC_MSG_CHECKING([for non-GNU ld])
|
|---|
| 3452 | fi
|
|---|
| 3453 | AC_CACHE_VAL(lt_cv_path_LD,
|
|---|
| 3454 | [if test -z "$LD"; then
|
|---|
| 3455 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
|---|
| 3456 | for ac_dir in $PATH; do
|
|---|
| 3457 | test -z "$ac_dir" && ac_dir=.
|
|---|
| 3458 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
|
|---|
| 3459 | lt_cv_path_LD="$ac_dir/$ac_prog"
|
|---|
| 3460 | # Check to see if the program is GNU ld. I'd rather use --version,
|
|---|
| 3461 | # but apparently some GNU ld's only accept -v.
|
|---|
| 3462 | # Break only if it was the GNU/non-GNU ld that we prefer.
|
|---|
| 3463 | if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
|
|---|
| 3464 | test "$with_gnu_ld" != no && break
|
|---|
| 3465 | else
|
|---|
| 3466 | test "$with_gnu_ld" != yes && break
|
|---|
| 3467 | fi
|
|---|
| 3468 | fi
|
|---|
| 3469 | done
|
|---|
| 3470 | IFS="$ac_save_ifs"
|
|---|
| 3471 | else
|
|---|
| 3472 | lt_cv_path_LD="$LD" # Let the user override the test with a path.
|
|---|
| 3473 | fi])
|
|---|
| 3474 | LD="$lt_cv_path_LD"
|
|---|
| 3475 | if test -n "$LD"; then
|
|---|
| 3476 | AC_MSG_RESULT($LD)
|
|---|
| 3477 | else
|
|---|
| 3478 | AC_MSG_RESULT(no)
|
|---|
| 3479 | fi
|
|---|
| 3480 | test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
|
|---|
| 3481 | AC_PROG_LD_GNU
|
|---|
| 3482 | ])
|
|---|
| 3483 |
|
|---|
| 3484 | # AC_PROG_LD_GNU -
|
|---|
| 3485 | AC_DEFUN([AC_PROG_LD_GNU],
|
|---|
| 3486 | [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
|
|---|
| 3487 | [# I'd rather use --version here, but apparently some GNU ld's only accept -v.
|
|---|
| 3488 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
|
|---|
| 3489 | lt_cv_prog_gnu_ld=yes
|
|---|
| 3490 | else
|
|---|
| 3491 | lt_cv_prog_gnu_ld=no
|
|---|
| 3492 | fi])
|
|---|
| 3493 | with_gnu_ld=$lt_cv_prog_gnu_ld
|
|---|
| 3494 | ])
|
|---|
| 3495 |
|
|---|
| 3496 | # AC_PROG_LD_RELOAD_FLAG - find reload flag for linker
|
|---|
| 3497 | # -- PORTME Some linkers may need a different reload flag.
|
|---|
| 3498 | AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
|
|---|
| 3499 | [AC_CACHE_CHECK([for $LD option to reload object files], lt_cv_ld_reload_flag,
|
|---|
| 3500 | [lt_cv_ld_reload_flag='-r'])
|
|---|
| 3501 | reload_flag=$lt_cv_ld_reload_flag
|
|---|
| 3502 | test -n "$reload_flag" && reload_flag=" $reload_flag"
|
|---|
| 3503 | ])
|
|---|
| 3504 |
|
|---|
| 3505 | # AC_DEPLIBS_CHECK_METHOD - how to check for library dependencies
|
|---|
| 3506 | # -- PORTME fill in with the dynamic library characteristics
|
|---|
| 3507 | AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
|
|---|
| 3508 | [AC_CACHE_CHECK([how to recognise dependant libraries],
|
|---|
| 3509 | lt_cv_deplibs_check_method,
|
|---|
| 3510 | [lt_cv_file_magic_cmd='$MAGIC_CMD'
|
|---|
| 3511 | lt_cv_file_magic_test_file=
|
|---|
| 3512 | lt_cv_deplibs_check_method='unknown'
|
|---|
| 3513 | # Need to set the preceding variable on all platforms that support
|
|---|
| 3514 | # interlibrary dependencies.
|
|---|
| 3515 | # 'none' -- dependencies not supported.
|
|---|
| 3516 | # `unknown' -- same as none, but documents that we really don't know.
|
|---|
| 3517 | # 'pass_all' -- all dependencies passed with no checks.
|
|---|
| 3518 | # 'test_compile' -- check by making test program.
|
|---|
| 3519 | # 'file_magic [[regex]]' -- check by looking for files in library path
|
|---|
| 3520 | # which responds to the $file_magic_cmd with a given egrep regex.
|
|---|
| 3521 | # If you have `file' or equivalent on your system and you're not sure
|
|---|
| 3522 | # whether `pass_all' will *always* work, you probably want this one.
|
|---|
| 3523 |
|
|---|
| 3524 | case $host_os in
|
|---|
| 3525 | aix4* | aix5*)
|
|---|
| 3526 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3527 | ;;
|
|---|
| 3528 |
|
|---|
| 3529 | beos*)
|
|---|
| 3530 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3531 | ;;
|
|---|
| 3532 |
|
|---|
| 3533 | bsdi4*)
|
|---|
| 3534 | lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
|
|---|
| 3535 | lt_cv_file_magic_cmd='/usr/bin/file -L'
|
|---|
| 3536 | lt_cv_file_magic_test_file=/shlib/libc.so
|
|---|
| 3537 | ;;
|
|---|
| 3538 |
|
|---|
| 3539 | cygwin* | mingw* | pw32*)
|
|---|
| 3540 | lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
|
|---|
| 3541 | lt_cv_file_magic_cmd='$OBJDUMP -f'
|
|---|
| 3542 | ;;
|
|---|
| 3543 |
|
|---|
| 3544 | darwin* | rhapsody*)
|
|---|
| 3545 | lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
|
|---|
| 3546 | lt_cv_file_magic_cmd='/usr/bin/file -L'
|
|---|
| 3547 | case "$host_os" in
|
|---|
| 3548 | rhapsody* | darwin1.[[012]])
|
|---|
| 3549 | lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1`
|
|---|
| 3550 | ;;
|
|---|
| 3551 | *) # Darwin 1.3 on
|
|---|
| 3552 | lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
|
|---|
| 3553 | ;;
|
|---|
| 3554 | esac
|
|---|
| 3555 | ;;
|
|---|
| 3556 |
|
|---|
| 3557 | freebsd*)
|
|---|
| 3558 | if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
|
|---|
| 3559 | case $host_cpu in
|
|---|
| 3560 | i*86 )
|
|---|
| 3561 | # Not sure whether the presence of OpenBSD here was a mistake.
|
|---|
| 3562 | # Let's accept both of them until this is cleared up.
|
|---|
| 3563 | lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[[3-9]]86 (compact )?demand paged shared library'
|
|---|
| 3564 | lt_cv_file_magic_cmd=/usr/bin/file
|
|---|
| 3565 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
|
|---|
| 3566 | ;;
|
|---|
| 3567 | esac
|
|---|
| 3568 | else
|
|---|
| 3569 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3570 | fi
|
|---|
| 3571 | ;;
|
|---|
| 3572 |
|
|---|
| 3573 | gnu*)
|
|---|
| 3574 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3575 | ;;
|
|---|
| 3576 |
|
|---|
| 3577 | hpux10.20*|hpux11*)
|
|---|
| 3578 | lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
|
|---|
| 3579 | lt_cv_file_magic_cmd=/usr/bin/file
|
|---|
| 3580 | lt_cv_file_magic_test_file=/usr/lib/libc.sl
|
|---|
| 3581 | ;;
|
|---|
| 3582 |
|
|---|
| 3583 | irix5* | irix6*)
|
|---|
| 3584 | case $host_os in
|
|---|
| 3585 | irix5*)
|
|---|
| 3586 | # this will be overridden with pass_all, but let us keep it just in case
|
|---|
| 3587 | lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
|
|---|
| 3588 | ;;
|
|---|
| 3589 | *)
|
|---|
| 3590 | case $LD in
|
|---|
| 3591 | *-32|*"-32 ") libmagic=32-bit;;
|
|---|
| 3592 | *-n32|*"-n32 ") libmagic=N32;;
|
|---|
| 3593 | *-64|*"-64 ") libmagic=64-bit;;
|
|---|
| 3594 | *) libmagic=never-match;;
|
|---|
| 3595 | esac
|
|---|
| 3596 | # this will be overridden with pass_all, but let us keep it just in case
|
|---|
| 3597 | lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[[1234]] dynamic lib MIPS - version 1"
|
|---|
| 3598 | ;;
|
|---|
| 3599 | esac
|
|---|
| 3600 | lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
|
|---|
| 3601 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3602 | ;;
|
|---|
| 3603 |
|
|---|
| 3604 | # This must be Linux ELF.
|
|---|
| 3605 | linux-gnu*)
|
|---|
| 3606 | case $host_cpu in
|
|---|
| 3607 | alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* | s390* )
|
|---|
| 3608 | lt_cv_deplibs_check_method=pass_all ;;
|
|---|
| 3609 | *)
|
|---|
| 3610 | # glibc up to 2.1.1 does not perform some relocations on ARM
|
|---|
| 3611 | lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;;
|
|---|
| 3612 | esac
|
|---|
| 3613 | lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
|
|---|
| 3614 | ;;
|
|---|
| 3615 |
|
|---|
| 3616 | netbsd*)
|
|---|
| 3617 | if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
|
|---|
| 3618 | lt_cv_deplibs_check_method='match_pattern /lib[[^/\.]]+\.so\.[[0-9]]+\.[[0-9]]+$'
|
|---|
| 3619 | else
|
|---|
| 3620 | lt_cv_deplibs_check_method='match_pattern /lib[[^/\.]]+\.so$'
|
|---|
| 3621 | fi
|
|---|
| 3622 | ;;
|
|---|
| 3623 |
|
|---|
| 3624 | newos6*)
|
|---|
| 3625 | lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
|
|---|
| 3626 | lt_cv_file_magic_cmd=/usr/bin/file
|
|---|
| 3627 | lt_cv_file_magic_test_file=/usr/lib/libnls.so
|
|---|
| 3628 | ;;
|
|---|
| 3629 |
|
|---|
| 3630 | openbsd*)
|
|---|
| 3631 | lt_cv_file_magic_cmd=/usr/bin/file
|
|---|
| 3632 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
|
|---|
| 3633 | if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
|---|
| 3634 | lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB shared object'
|
|---|
| 3635 | else
|
|---|
| 3636 | lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library'
|
|---|
| 3637 | fi
|
|---|
| 3638 | ;;
|
|---|
| 3639 |
|
|---|
| 3640 | osf3* | osf4* | osf5*)
|
|---|
| 3641 | # this will be overridden with pass_all, but let us keep it just in case
|
|---|
| 3642 | lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
|
|---|
| 3643 | lt_cv_file_magic_test_file=/shlib/libc.so
|
|---|
| 3644 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3645 | ;;
|
|---|
| 3646 |
|
|---|
| 3647 | sco3.2v5*)
|
|---|
| 3648 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3649 | ;;
|
|---|
| 3650 |
|
|---|
| 3651 | solaris*)
|
|---|
| 3652 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3653 | lt_cv_file_magic_test_file=/lib/libc.so
|
|---|
| 3654 | ;;
|
|---|
| 3655 |
|
|---|
| 3656 | sysv5uw[[78]]* | sysv4*uw2*)
|
|---|
| 3657 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3658 | ;;
|
|---|
| 3659 |
|
|---|
| 3660 | sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
|
|---|
| 3661 | case $host_vendor in
|
|---|
| 3662 | motorola)
|
|---|
| 3663 | lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
|
|---|
| 3664 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
|
|---|
| 3665 | ;;
|
|---|
| 3666 | ncr)
|
|---|
| 3667 | lt_cv_deplibs_check_method=pass_all
|
|---|
| 3668 | ;;
|
|---|
| 3669 | sequent)
|
|---|
| 3670 | lt_cv_file_magic_cmd='/bin/file'
|
|---|
| 3671 | lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
|
|---|
| 3672 | ;;
|
|---|
| 3673 | sni)
|
|---|
| 3674 | lt_cv_file_magic_cmd='/bin/file'
|
|---|
| 3675 | lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
|
|---|
| 3676 | lt_cv_file_magic_test_file=/lib/libc.so
|
|---|
| 3677 | ;;
|
|---|
| 3678 | esac
|
|---|
| 3679 | ;;
|
|---|
| 3680 | esac
|
|---|
| 3681 | ])
|
|---|
| 3682 | file_magic_cmd=$lt_cv_file_magic_cmd
|
|---|
| 3683 | deplibs_check_method=$lt_cv_deplibs_check_method
|
|---|
| 3684 | ])
|
|---|
| 3685 |
|
|---|
| 3686 |
|
|---|
| 3687 | # AC_PROG_NM - find the path to a BSD-compatible name lister
|
|---|
| 3688 | AC_DEFUN([AC_PROG_NM],
|
|---|
| 3689 | [AC_REQUIRE([_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR])dnl
|
|---|
| 3690 | AC_MSG_CHECKING([for BSD-compatible nm])
|
|---|
| 3691 | AC_CACHE_VAL(lt_cv_path_NM,
|
|---|
| 3692 | [if test -n "$NM"; then
|
|---|
| 3693 | # Let the user override the test.
|
|---|
| 3694 | lt_cv_path_NM="$NM"
|
|---|
| 3695 | else
|
|---|
| 3696 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
|---|
| 3697 | for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
|
|---|
| 3698 | test -z "$ac_dir" && ac_dir=.
|
|---|
| 3699 | tmp_nm=$ac_dir/${ac_tool_prefix}nm
|
|---|
| 3700 | if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
|
|---|
| 3701 | # Check to see if the nm accepts a BSD-compat flag.
|
|---|
| 3702 | # Adding the `sed 1q' prevents false positives on HP-UX, which says:
|
|---|
| 3703 | # nm: unknown option "B" ignored
|
|---|
| 3704 | # Tru64's nm complains that /dev/null is an invalid object file
|
|---|
| 3705 | if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
|
|---|
| 3706 | lt_cv_path_NM="$tmp_nm -B"
|
|---|
| 3707 | break
|
|---|
| 3708 | elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
|
|---|
| 3709 | lt_cv_path_NM="$tmp_nm -p"
|
|---|
| 3710 | break
|
|---|
| 3711 | else
|
|---|
| 3712 | lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
|
|---|
| 3713 | continue # so that we can try to find one that supports BSD flags
|
|---|
| 3714 | fi
|
|---|
| 3715 | fi
|
|---|
| 3716 | done
|
|---|
| 3717 | IFS="$ac_save_ifs"
|
|---|
| 3718 | test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
|
|---|
| 3719 | fi])
|
|---|
| 3720 | NM="$lt_cv_path_NM"
|
|---|
| 3721 | AC_MSG_RESULT([$NM])
|
|---|
| 3722 | ])
|
|---|
| 3723 |
|
|---|
| 3724 | # AC_CHECK_LIBM - check for math library
|
|---|
| 3725 | AC_DEFUN([AC_CHECK_LIBM],
|
|---|
| 3726 | [AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
|---|
| 3727 | LIBM=
|
|---|
| 3728 | case $host in
|
|---|
| 3729 | *-*-beos* | *-*-cygwin* | *-*-pw32*)
|
|---|
| 3730 | # These system don't have libm
|
|---|
| 3731 | ;;
|
|---|
| 3732 | *-ncr-sysv4.3*)
|
|---|
| 3733 | AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
|
|---|
| 3734 | AC_CHECK_LIB(m, main, LIBM="$LIBM -lm")
|
|---|
| 3735 | ;;
|
|---|
| 3736 | *)
|
|---|
| 3737 | AC_CHECK_LIB(m, main, LIBM="-lm")
|
|---|
| 3738 | ;;
|
|---|
| 3739 | esac
|
|---|
| 3740 | ])
|
|---|
| 3741 |
|
|---|
| 3742 | # AC_LIBLTDL_CONVENIENCE[(dir)] - sets LIBLTDL to the link flags for
|
|---|
| 3743 | # the libltdl convenience library and INCLTDL to the include flags for
|
|---|
| 3744 | # the libltdl header and adds --enable-ltdl-convenience to the
|
|---|
| 3745 | # configure arguments. Note that LIBLTDL and INCLTDL are not
|
|---|
| 3746 | # AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If DIR is not
|
|---|
| 3747 | # provided, it is assumed to be `libltdl'. LIBLTDL will be prefixed
|
|---|
| 3748 | # with '${top_builddir}/' and INCLTDL will be prefixed with
|
|---|
| 3749 | # '${top_srcdir}/' (note the single quotes!). If your package is not
|
|---|
| 3750 | # flat and you're not using automake, define top_builddir and
|
|---|
| 3751 | # top_srcdir appropriately in the Makefiles.
|
|---|
| 3752 | AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
|
|---|
| 3753 | [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
|
|---|
| 3754 | case $enable_ltdl_convenience in
|
|---|
| 3755 | no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
|
|---|
| 3756 | "") enable_ltdl_convenience=yes
|
|---|
| 3757 | ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
|
|---|
| 3758 | esac
|
|---|
| 3759 | LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
|
|---|
| 3760 | INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
|
|---|
| 3761 | ])
|
|---|
| 3762 |
|
|---|
| 3763 | # AC_LIBLTDL_INSTALLABLE[(dir)] - sets LIBLTDL to the link flags for
|
|---|
| 3764 | # the libltdl installable library and INCLTDL to the include flags for
|
|---|
| 3765 | # the libltdl header and adds --enable-ltdl-install to the configure
|
|---|
| 3766 | # arguments. Note that LIBLTDL and INCLTDL are not AC_SUBSTed, nor is
|
|---|
| 3767 | # AC_CONFIG_SUBDIRS called. If DIR is not provided and an installed
|
|---|
| 3768 | # libltdl is not found, it is assumed to be `libltdl'. LIBLTDL will
|
|---|
| 3769 | # be prefixed with '${top_builddir}/' and INCLTDL will be prefixed
|
|---|
| 3770 | # with '${top_srcdir}/' (note the single quotes!). If your package is
|
|---|
| 3771 | # not flat and you're not using automake, define top_builddir and
|
|---|
| 3772 | # top_srcdir appropriately in the Makefiles.
|
|---|
| 3773 | # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
|
|---|
| 3774 | AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
|
|---|
| 3775 | [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
|
|---|
| 3776 | AC_CHECK_LIB(ltdl, main,
|
|---|
| 3777 | [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
|
|---|
| 3778 | [if test x"$enable_ltdl_install" = xno; then
|
|---|
| 3779 | AC_MSG_WARN([libltdl not installed, but installation disabled])
|
|---|
| 3780 | else
|
|---|
| 3781 | enable_ltdl_install=yes
|
|---|
| 3782 | fi
|
|---|
| 3783 | ])
|
|---|
| 3784 | if test x"$enable_ltdl_install" = x"yes"; then
|
|---|
| 3785 | ac_configure_args="$ac_configure_args --enable-ltdl-install"
|
|---|
| 3786 | LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
|
|---|
| 3787 | INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
|
|---|
| 3788 | else
|
|---|
| 3789 | ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
|
|---|
| 3790 | LIBLTDL="-lltdl"
|
|---|
| 3791 | INCLTDL=
|
|---|
| 3792 | fi
|
|---|
| 3793 | ])
|
|---|
| 3794 |
|
|---|
| 3795 | # old names
|
|---|
| 3796 | AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
|
|---|
| 3797 | AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
|
|---|
| 3798 | AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
|
|---|
| 3799 | AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
|
|---|
| 3800 | AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
|
|---|
| 3801 | AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
|
|---|
| 3802 | AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
|
|---|
| 3803 |
|
|---|
| 3804 | # This is just to silence aclocal about the macro not being used
|
|---|
| 3805 | ifelse([AC_DISABLE_FAST_INSTALL])
|
|---|
| 3806 |
|
|---|