~ubuntu-branches/ubuntu/oneiric/cryptsetup/oneiric

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Scott James Remnant, Steve Langasek, Scott James Remnant
  • Date: 2009-10-14 04:52:16 UTC
  • Revision ID: james.westby@ubuntu.com-20091014045216-yej34imeg7sh3ljd
Tags: 2:1.0.6+20090405.svn49-1ubuntu6
[ Steve Langasek ]
* Move the Debian Vcs- fields aside.

[ Scott James Remnant ]
* debian/cryptdisks-enable.upstart: Don't overcompensate for my idiocy,
  cryptsetup should not need a controlling terminal, just a terminal
  is fine.  May fix LP: #439138.

Show diffs side-by-side

added added

removed removed

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