14
14
m4_ifndef([AC_AUTOCONF_VERSION],
15
15
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],,
17
[m4_warning([this file was generated for autoconf 2.67.
16
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],,
17
[m4_warning([this file was generated for autoconf 2.68.
18
18
You have another version of autoconf. It may work, but is not guaranteed to.
19
19
If you have problems, you may need to regenerate the build system entirely.
20
20
To do so, use the procedure documented by the package, typically `autoreconf'.])])
22
dnl -*- mode: autoconf -*-
27
dnl GTK_DOC_CHECK([minimum-gtk-doc-version])
28
AC_DEFUN([GTK_DOC_CHECK],
30
AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
31
AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
33
dnl check for tools we added during development
34
AC_PATH_PROG([GTKDOC_CHECK],[gtkdoc-check])
35
AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true])
36
AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf])
38
dnl for overriding the documentation installation directory
39
AC_ARG_WITH([html-dir],
40
AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
41
[with_html_dir='${datadir}/gtk-doc/html'])
42
HTML_DIR="$with_html_dir"
45
dnl enable/disable documentation building
46
AC_ARG_ENABLE([gtk-doc],
47
AS_HELP_STRING([--enable-gtk-doc],
48
[use gtk-doc to build documentation [[default=no]]]),,
51
if test x$enable_gtk_doc = xyes; then
53
[PKG_CHECK_EXISTS([gtk-doc],,
54
AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))],
55
[PKG_CHECK_EXISTS([gtk-doc >= $1],,
56
AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build $PACKAGE_NAME]))])
59
AC_MSG_CHECKING([whether to build gtk-doc documentation])
60
AC_MSG_RESULT($enable_gtk_doc)
62
dnl enable/disable output formats
63
AC_ARG_ENABLE([gtk-doc-html],
64
AS_HELP_STRING([--enable-gtk-doc-html],
65
[build documentation in html format [[default=yes]]]),,
66
[enable_gtk_doc_html=yes])
67
AC_ARG_ENABLE([gtk-doc-pdf],
68
AS_HELP_STRING([--enable-gtk-doc-pdf],
69
[build documentation in pdf format [[default=no]]]),,
70
[enable_gtk_doc_pdf=no])
72
if test -z "$GTKDOC_MKPDF"; then
77
AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
78
AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
79
AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])
80
AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"])
81
AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"])
84
dnl -*- mode: autoconf -*-
85
dnl Copyright 2009 Johan Dahlin
87
dnl This file is free software; the author(s) gives unlimited
88
dnl permission to copy and/or distribute it, with or without
89
dnl modifications, as long as this notice is preserved.
94
m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
96
AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
97
AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
98
AC_BEFORE([LT_INIT],[$0])dnl setup libtool first
100
dnl enable/disable introspection
101
m4_if([$2], [require],
103
enable_introspection=yes
105
AC_ARG_ENABLE(introspection,
106
AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
107
[Enable introspection for this build]),,
108
[enable_introspection=auto])
111
AC_MSG_CHECKING([for gobject-introspection])
113
dnl presence/version checking
114
AS_CASE([$enable_introspection],
116
found_introspection="no (disabled, use --enable-introspection to enable)"
119
PKG_CHECK_EXISTS([gobject-introspection-1.0],,
120
AC_MSG_ERROR([gobject-introspection-1.0 is not installed]))
121
PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1],
122
found_introspection=yes,
123
AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME]))
126
PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
129
AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@])
132
AC_MSG_RESULT([$found_introspection])
134
INTROSPECTION_SCANNER=
135
INTROSPECTION_COMPILER=
136
INTROSPECTION_GENERATE=
137
INTROSPECTION_GIRDIR=
138
INTROSPECTION_TYPELIBDIR=
139
if test "x$found_introspection" = "xyes"; then
140
INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
141
INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
142
INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
143
INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
144
INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
145
INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
146
INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
147
INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
149
AC_SUBST(INTROSPECTION_SCANNER)
150
AC_SUBST(INTROSPECTION_COMPILER)
151
AC_SUBST(INTROSPECTION_GENERATE)
152
AC_SUBST(INTROSPECTION_GIRDIR)
153
AC_SUBST(INTROSPECTION_TYPELIBDIR)
154
AC_SUBST(INTROSPECTION_CFLAGS)
155
AC_SUBST(INTROSPECTION_LIBS)
156
AC_SUBST(INTROSPECTION_MAKEFILE)
158
AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes")
163
dnl GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version])
165
AC_DEFUN([GOBJECT_INTROSPECTION_CHECK],
167
_GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1])
171
dnl GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version])
174
AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE],
176
_GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require])
179
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
181
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
182
# 2006, 2007, 2008 Free Software Foundation, Inc.
183
# Written by Gordon Matzigkeit, 1996
185
# This file is free software; the Free Software Foundation gives
186
# unlimited permission to copy and/or distribute it, with or without
187
# modifications, as long as this notice is preserved.
189
m4_define([_LT_COPYING], [dnl
190
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
191
# 2006, 2007, 2008 Free Software Foundation, Inc.
192
# Written by Gordon Matzigkeit, 1996
194
# This file is part of GNU Libtool.
196
# GNU Libtool is free software; you can redistribute it and/or
197
# modify it under the terms of the GNU General Public License as
198
# published by the Free Software Foundation; either version 2 of
199
# the License, or (at your option) any later version.
201
# As a special exception to the GNU General Public License,
202
# if you distribute this file as part of a program or library that
203
# is built using GNU Libtool, you may include this file under the
204
# same distribution terms that you use for the rest of that program.
206
# GNU Libtool is distributed in the hope that it will be useful,
207
# but WITHOUT ANY WARRANTY; without even the implied warranty of
208
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
209
# GNU General Public License for more details.
211
# You should have received a copy of the GNU General Public License
212
# along with GNU Libtool; see the file COPYING. If not, a copy
213
# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
214
# obtained by writing to the Free Software Foundation, Inc.,
215
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
223
# Complain and exit if this libtool version is less that VERSION.
224
m4_defun([LT_PREREQ],
225
[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
227
[m4_fatal([Libtool version $1 or higher is required],
234
# Complain if the absolute build directory name contains unusual characters
235
m4_defun([_LT_CHECK_BUILDDIR],
238
AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
246
[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
247
AC_BEFORE([$0], [LT_LANG])dnl
248
AC_BEFORE([$0], [LT_OUTPUT])dnl
249
AC_BEFORE([$0], [LTDL_INIT])dnl
250
m4_require([_LT_CHECK_BUILDDIR])dnl
252
dnl Autoconf doesn't catch unexpanded LT_ macros by default:
253
m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
254
m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
255
dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
256
dnl unless we require an AC_DEFUNed macro:
257
AC_REQUIRE([LTOPTIONS_VERSION])dnl
258
AC_REQUIRE([LTSUGAR_VERSION])dnl
259
AC_REQUIRE([LTVERSION_VERSION])dnl
260
AC_REQUIRE([LTOBSOLETE_VERSION])dnl
261
m4_require([_LT_PROG_LTMAIN])dnl
264
_LT_SET_OPTIONS([$0], [$1])
266
# This can be used to rebuild libtool when needed
267
LIBTOOL_DEPS="$ltmain"
269
# Always use our own libtool.
270
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
280
AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
281
AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
282
dnl aclocal-1.4 backwards compatibility:
283
dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
284
dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
287
# _LT_CC_BASENAME(CC)
288
# -------------------
289
# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
290
m4_defun([_LT_CC_BASENAME],
291
[for cc_temp in $1""; do
293
compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
294
distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
299
cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
303
# _LT_FILEUTILS_DEFAULTS
304
# ----------------------
305
# It is okay to use these file commands and assume they have been set
306
# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
307
m4_defun([_LT_FILEUTILS_DEFAULTS],
311
])# _LT_FILEUTILS_DEFAULTS
316
m4_defun([_LT_SETUP],
317
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
318
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
319
_LT_DECL([], [host_alias], [0], [The host system])dnl
320
_LT_DECL([], [host], [0])dnl
321
_LT_DECL([], [host_os], [0])dnl
323
_LT_DECL([], [build_alias], [0], [The build system])dnl
324
_LT_DECL([], [build], [0])dnl
325
_LT_DECL([], [build_os], [0])dnl
327
AC_REQUIRE([AC_PROG_CC])dnl
328
AC_REQUIRE([LT_PATH_LD])dnl
329
AC_REQUIRE([LT_PATH_NM])dnl
331
AC_REQUIRE([AC_PROG_LN_S])dnl
332
test -z "$LN_S" && LN_S="ln -s"
333
_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
335
AC_REQUIRE([LT_CMD_MAX_LEN])dnl
336
_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
337
_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
339
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
340
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
341
m4_require([_LT_CMD_RELOAD])dnl
342
m4_require([_LT_CHECK_MAGIC_METHOD])dnl
343
m4_require([_LT_CMD_OLD_ARCHIVE])dnl
344
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
346
_LT_CONFIG_LIBTOOL_INIT([
347
# See if we are running on zsh, and set the options which allow our
348
# commands through without removal of \ escapes INIT.
349
if test -n "\${ZSH_VERSION+set}" ; then
353
if test -n "${ZSH_VERSION+set}" ; then
359
m4_require([_LT_TAG_COMPILER])dnl
360
_LT_PROG_ECHO_BACKSLASH
364
# AIX sometimes has problems with the GCC collect2 program. For some
365
# reason, if we set the COLLECT_NAMES environment variable, the problems
366
# vanish in a puff of smoke.
367
if test "X${COLLECT_NAMES+set}" != Xset; then
374
# Sed substitution that helps us do robust quoting. It backslashifies
375
# metacharacters that are still active within double-quoted strings.
376
sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
378
# Same as above, but do not quote variable references.
379
double_quote_subst='s/\([["`\\]]\)/\\\1/g'
381
# Sed substitution to delay expansion of an escaped shell variable in a
382
# double_quote_subst'ed string.
383
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
385
# Sed substitution to delay expansion of an escaped single quote.
386
delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
388
# Sed substitution to avoid accidental globbing in evaled expressions
389
no_glob_subst='s/\*/\\\*/g'
395
# All known linkers require a `.a' archive for static linking (except MSVC,
396
# which needs '.lib').
399
with_gnu_ld="$lt_cv_prog_gnu_ld"
404
# Set sane defaults for various variables
405
test -z "$CC" && CC=cc
406
test -z "$LTCC" && LTCC=$CC
407
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
408
test -z "$LD" && LD=ld
409
test -z "$ac_objext" && ac_objext=o
411
_LT_CC_BASENAME([$compiler])
413
# Only perform the check for file, if the check method requires it
414
test -z "$MAGIC_CMD" && MAGIC_CMD=file
415
case $deplibs_check_method in
417
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
423
# Use C for the default configuration in the libtool script
424
LT_SUPPORTED_TAG([CC])
426
_LT_LANG_DEFAULT_CONFIG
433
# Note that this code is called both from `configure', and `config.status'
434
# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
435
# `config.status' has no value for ac_aux_dir unless we are using Automake,
436
# so we pass a copy along to make sure it has a sensible value anyway.
437
m4_defun([_LT_PROG_LTMAIN],
438
[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
439
_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
440
ltmain="$ac_aux_dir/ltmain.sh"
445
# So that we can recreate a full libtool script including additional
446
# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
447
# in macros and then make a single call at the end using the `libtool'
451
# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
452
# ----------------------------------------
453
# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
454
m4_define([_LT_CONFIG_LIBTOOL_INIT],
456
[m4_append([_LT_OUTPUT_LIBTOOL_INIT],
461
m4_define([_LT_OUTPUT_LIBTOOL_INIT])
464
# _LT_CONFIG_LIBTOOL([COMMANDS])
465
# ------------------------------
466
# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
467
m4_define([_LT_CONFIG_LIBTOOL],
469
[m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
474
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
477
# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
478
# -----------------------------------------------------
479
m4_defun([_LT_CONFIG_SAVE_COMMANDS],
480
[_LT_CONFIG_LIBTOOL([$1])
481
_LT_CONFIG_LIBTOOL_INIT([$2])
485
# _LT_FORMAT_COMMENT([COMMENT])
486
# -----------------------------
487
# Add leading comment marks to the start of each line, and a trailing
488
# full-stop to the whole comment if one is not present already.
489
m4_define([_LT_FORMAT_COMMENT],
491
m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
492
[['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
499
# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
500
# -------------------------------------------------------------------
501
# CONFIGNAME is the name given to the value in the libtool script.
502
# VARNAME is the (base) name used in the configure script.
503
# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
504
# VARNAME. Any other value will be used directly.
505
m4_define([_LT_DECL],
506
[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
507
[lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
508
[m4_ifval([$1], [$1], [$2])])
509
lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
511
[lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
512
lt_dict_add_subkey([lt_decl_dict], [$2],
513
[tagged?], [m4_ifval([$5], [yes], [no])])])
517
# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
518
# --------------------------------------------------------
519
m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
522
# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
523
# ------------------------------------------------
524
m4_define([lt_decl_tag_varnames],
525
[_lt_decl_filter([tagged?], [yes], $@)])
528
# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
529
# ---------------------------------------------------------
530
m4_define([_lt_decl_filter],
532
[0], [m4_fatal([$0: too few arguments: $#])],
533
[1], [m4_fatal([$0: too few arguments: $#: $1])],
534
[2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
535
[3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
536
[lt_dict_filter([lt_decl_dict], $@)])[]dnl
540
# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
541
# --------------------------------------------------
542
m4_define([lt_decl_quote_varnames],
543
[_lt_decl_filter([value], [1], $@)])
546
# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
547
# ---------------------------------------------------
548
m4_define([lt_decl_dquote_varnames],
549
[_lt_decl_filter([value], [2], $@)])
552
# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
553
# ---------------------------------------------------
554
m4_define([lt_decl_varnames_tagged],
555
[m4_assert([$# <= 2])dnl
556
_$0(m4_quote(m4_default([$1], [[, ]])),
557
m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
558
m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
559
m4_define([_lt_decl_varnames_tagged],
560
[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
563
# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
564
# ------------------------------------------------
565
m4_define([lt_decl_all_varnames],
566
[_$0(m4_quote(m4_default([$1], [[, ]])),
568
m4_quote(lt_decl_varnames),
569
m4_quote(m4_shift($@))))[]dnl
571
m4_define([_lt_decl_all_varnames],
572
[lt_join($@, lt_decl_varnames_tagged([$1],
573
lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
577
# _LT_CONFIG_STATUS_DECLARE([VARNAME])
578
# ------------------------------------
579
# Quote a variable value, and forward it to `config.status' so that its
580
# declaration there will have the same value as in `configure'. VARNAME
581
# must have a single quote delimited value for this to work.
582
m4_define([_LT_CONFIG_STATUS_DECLARE],
583
[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
586
# _LT_CONFIG_STATUS_DECLARATIONS
587
# ------------------------------
588
# We delimit libtool config variables with single quotes, so when
589
# we write them to config.status, we have to be sure to quote all
590
# embedded single quotes properly. In configure, this macro expands
591
# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
593
# <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
594
m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
595
[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
596
[m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
601
# Output comment and list of tags supported by the script
602
m4_defun([_LT_LIBTOOL_TAGS],
603
[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
604
available_tags="_LT_TAGS"dnl
608
# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
609
# -----------------------------------
610
# Extract the dictionary values for VARNAME (optionally with TAG) and
611
# expand to a commented shell variable setting:
613
# # Some comment about what VAR is for.
614
# visible_name=$lt_internal_name
615
m4_define([_LT_LIBTOOL_DECLARE],
616
[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
617
[description])))[]dnl
618
m4_pushdef([_libtool_name],
619
m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
620
m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
621
[0], [_libtool_name=[$]$1],
622
[1], [_libtool_name=$lt_[]$1],
623
[2], [_libtool_name=$lt_[]$1],
624
[_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
625
m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
629
# _LT_LIBTOOL_CONFIG_VARS
630
# -----------------------
631
# Produce commented declarations of non-tagged libtool config variables
632
# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
633
# script. Tagged libtool config variables (even for the LIBTOOL CONFIG
634
# section) are produced by _LT_LIBTOOL_TAG_VARS.
635
m4_defun([_LT_LIBTOOL_CONFIG_VARS],
636
[m4_foreach([_lt_var],
637
m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
638
[m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
641
# _LT_LIBTOOL_TAG_VARS(TAG)
642
# -------------------------
643
m4_define([_LT_LIBTOOL_TAG_VARS],
644
[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
645
[m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
648
# _LT_TAGVAR(VARNAME, [TAGNAME])
649
# ------------------------------
650
m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
653
# _LT_CONFIG_COMMANDS
654
# -------------------
655
# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
656
# variables for single and double quote escaping we saved from calls
657
# to _LT_DECL, we can put quote escaped variables declarations
658
# into `config.status', and then the shell code to quote escape them in
659
# for loops in `config.status'. Finally, any additional code accumulated
660
# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
661
m4_defun([_LT_CONFIG_COMMANDS],
662
[AC_PROVIDE_IFELSE([LT_OUTPUT],
663
dnl If the libtool generation code has been placed in $CONFIG_LT,
664
dnl instead of duplicating it all over again into config.status,
665
dnl then we will have config.status run $CONFIG_LT later, so it
666
dnl needs to know what name is stored there:
667
[AC_CONFIG_COMMANDS([libtool],
668
[$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
669
dnl If the libtool generation code is destined for config.status,
670
dnl expand the accumulated commands and init code now:
671
[AC_CONFIG_COMMANDS([libtool],
672
[_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
673
])#_LT_CONFIG_COMMANDS
677
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
680
# The HP-UX ksh and POSIX shell print the target directory to stdout
682
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
684
sed_quote_subst='$sed_quote_subst'
685
double_quote_subst='$double_quote_subst'
686
delay_variable_subst='$delay_variable_subst'
687
_LT_CONFIG_STATUS_DECLARATIONS
690
compiler='$compiler_DEFAULT'
692
# Quote evaled strings.
693
for var in lt_decl_all_varnames([[ \
694
]], lt_decl_quote_varnames); do
695
case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
696
*[[\\\\\\\`\\"\\\$]]*)
697
eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
700
eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
705
# Double-quote double-evaled strings.
706
for var in lt_decl_all_varnames([[ \
707
]], lt_decl_dquote_varnames); do
708
case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
709
*[[\\\\\\\`\\"\\\$]]*)
710
eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
713
eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
718
# Fix-up fallback echo if it was mangled by the above quoting rules.
720
*'\\\[$]0 --fallback-echo"')dnl "
721
lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
725
_LT_OUTPUT_LIBTOOL_INIT
731
# This macro allows early generation of the libtool script (before
732
# AC_OUTPUT is called), incase it is used in configure for compilation
734
AC_DEFUN([LT_OUTPUT],
735
[: ${CONFIG_LT=./config.lt}
736
AC_MSG_NOTICE([creating $CONFIG_LT])
737
cat >"$CONFIG_LT" <<_LTEOF
739
# Generated by $as_me.
740
# Run this file to recreate a libtool stub with the current configuration.
743
SHELL=\${CONFIG_SHELL-$SHELL}
746
cat >>"$CONFIG_LT" <<\_LTEOF
750
exec AS_MESSAGE_FD>&1
751
exec AS_MESSAGE_LOG_FD>>config.log
754
AS_BOX([Running $as_me.])
755
} >&AS_MESSAGE_LOG_FD
758
\`$as_me' creates a local libtool stub from the current configuration,
759
for use in further configure time tests before the real libtool is
762
Usage: $[0] [[OPTIONS]]
764
-h, --help print this help, then exit
765
-V, --version print version number, then exit
766
-q, --quiet do not print progress messages
767
-d, --debug don't remove temporary files
769
Report bugs to <bug-libtool@gnu.org>."
772
m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
773
m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
774
configured by $[0], generated by m4_PACKAGE_STRING.
776
Copyright (C) 2008 Free Software Foundation, Inc.
777
This config.lt script is free software; the Free Software Foundation
778
gives unlimited permision to copy, distribute and modify it."
783
--version | --v* | -V )
784
echo "$lt_cl_version"; exit 0 ;;
786
echo "$lt_cl_help"; exit 0 ;;
787
--debug | --d* | -d )
789
--quiet | --q* | --silent | --s* | -q )
792
-*) AC_MSG_ERROR([unrecognized option: $[1]
793
Try \`$[0] --help' for more information.]) ;;
795
*) AC_MSG_ERROR([unrecognized argument: $[1]
796
Try \`$[0] --help' for more information.]) ;;
801
if $lt_cl_silent; then
802
exec AS_MESSAGE_FD>/dev/null
806
cat >>"$CONFIG_LT" <<_LTEOF
807
_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
810
cat >>"$CONFIG_LT" <<\_LTEOF
811
AC_MSG_NOTICE([creating $ofile])
812
_LT_OUTPUT_LIBTOOL_COMMANDS
815
chmod +x "$CONFIG_LT"
817
# configure is writing to config.log, but config.lt does its own redirection,
818
# appending to config.log, which fails on DOS, as config.log is still kept
819
# open by configure. Here we exec the FD to /dev/null, effectively closing
820
# config.log, so it can be properly (re)opened and appended to by config.lt.
821
if test "$no_create" != yes; then
823
test "$silent" = yes &&
824
lt_config_lt_args="$lt_config_lt_args --quiet"
825
exec AS_MESSAGE_LOG_FD>/dev/null
826
$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
827
exec AS_MESSAGE_LOG_FD>>config.log
828
$lt_cl_success || AS_EXIT(1)
835
# If TAG is the built-in tag, create an initial libtool script with a
836
# default configuration from the untagged config vars. Otherwise add code
837
# to config.status for appending the configuration named by TAG from the
838
# matching tagged config vars.
839
m4_defun([_LT_CONFIG],
840
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
841
_LT_CONFIG_SAVE_COMMANDS([
842
m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
843
m4_if(_LT_TAG, [C], [
844
# See if we are running on zsh, and set the options which allow our
845
# commands through without removal of \ escapes.
846
if test -n "${ZSH_VERSION+set}" ; then
851
trap "$RM \"$cfgfile\"; exit 1" 1 2 15
854
cat <<_LT_EOF >> "$cfgfile"
857
# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
858
# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
859
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
860
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
865
# ### BEGIN LIBTOOL CONFIG
866
_LT_LIBTOOL_CONFIG_VARS
868
# ### END LIBTOOL CONFIG
874
cat <<\_LT_EOF >> "$cfgfile"
875
# AIX sometimes has problems with the GCC collect2 program. For some
876
# reason, if we set the COLLECT_NAMES environment variable, the problems
877
# vanish in a puff of smoke.
878
if test "X${COLLECT_NAMES+set}" != Xset; then
888
# We use sed instead of cat because bash on DJGPP gets confused if
889
# if finds mixed CR/LF and LF-only lines. Since sed operates in
890
# text mode, it properly converts lines to CR/LF. This bash problem
891
# is reportedly fixed, but why not run on old versions too?
892
sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
893
|| (rm -f "$cfgfile"; exit 1)
895
_LT_PROG_XSI_SHELLFNS
897
sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
898
|| (rm -f "$cfgfile"; exit 1)
900
mv -f "$cfgfile" "$ofile" ||
901
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
904
[cat <<_LT_EOF >> "$ofile"
906
dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
907
dnl in a comment (ie after a #).
908
# ### BEGIN LIBTOOL TAG CONFIG: $1
909
_LT_LIBTOOL_TAG_VARS(_LT_TAG)
910
# ### END LIBTOOL TAG CONFIG: $1
917
TIMESTAMP='$TIMESTAMP'
920
])dnl /_LT_CONFIG_SAVE_COMMANDS
924
# LT_SUPPORTED_TAG(TAG)
925
# ---------------------
926
# Trace this macro to discover what tags are supported by the libtool
927
# --tag option, using:
928
# autoconf --trace 'LT_SUPPORTED_TAG:$1'
929
AC_DEFUN([LT_SUPPORTED_TAG], [])
932
# C support is built-in for now
933
m4_define([_LT_LANG_C_enabled], [])
934
m4_define([_LT_TAGS], [])
939
# Enable libtool support for the given language if not already enabled.
941
[AC_BEFORE([$0], [LT_OUTPUT])dnl
944
[C++], [_LT_LANG(CXX)],
945
[Java], [_LT_LANG(GCJ)],
946
[Fortran 77], [_LT_LANG(F77)],
947
[Fortran], [_LT_LANG(FC)],
948
[Windows Resource], [_LT_LANG(RC)],
949
[m4_ifdef([_LT_LANG_]$1[_CONFIG],
951
[m4_fatal([$0: unsupported language: "$1"])])])dnl
958
[m4_ifdef([_LT_LANG_]$1[_enabled], [],
959
[LT_SUPPORTED_TAG([$1])dnl
960
m4_append([_LT_TAGS], [$1 ])dnl
961
m4_define([_LT_LANG_]$1[_enabled], [])dnl
962
_LT_LANG_$1_CONFIG($1)])dnl
966
# _LT_LANG_DEFAULT_CONFIG
967
# -----------------------
968
m4_defun([_LT_LANG_DEFAULT_CONFIG],
969
[AC_PROVIDE_IFELSE([AC_PROG_CXX],
971
[m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
973
AC_PROVIDE_IFELSE([AC_PROG_F77],
975
[m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
977
AC_PROVIDE_IFELSE([AC_PROG_FC],
979
[m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
981
dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
982
dnl pulling things in needlessly.
983
AC_PROVIDE_IFELSE([AC_PROG_GCJ],
985
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
987
[AC_PROVIDE_IFELSE([LT_PROG_GCJ],
989
[m4_ifdef([AC_PROG_GCJ],
990
[m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
991
m4_ifdef([A][M_PROG_GCJ],
992
[m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
993
m4_ifdef([LT_PROG_GCJ],
994
[m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
996
AC_PROVIDE_IFELSE([LT_PROG_RC],
998
[m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
999
])# _LT_LANG_DEFAULT_CONFIG
1002
AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1003
AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1004
AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1005
AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1006
dnl aclocal-1.4 backwards compatibility:
1007
dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1008
dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1009
dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1010
dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1015
m4_defun([_LT_TAG_COMPILER],
1016
[AC_REQUIRE([AC_PROG_CC])dnl
1018
_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1019
_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1020
_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1021
_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1023
# If no C compiler was specified, use CC.
1026
# If no C compiler flags were specified, use CFLAGS.
1027
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1029
# Allow CC to be a program name with arguments.
1031
])# _LT_TAG_COMPILER
1034
# _LT_COMPILER_BOILERPLATE
1035
# ------------------------
1036
# Check for compiler boilerplate output or warnings with
1037
# the simple compiler test code.
1038
m4_defun([_LT_COMPILER_BOILERPLATE],
1039
[m4_require([_LT_DECL_SED])dnl
1040
ac_outfile=conftest.$ac_objext
1041
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1042
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1043
_lt_compiler_boilerplate=`cat conftest.err`
1045
])# _LT_COMPILER_BOILERPLATE
1048
# _LT_LINKER_BOILERPLATE
1049
# ----------------------
1050
# Check for linker boilerplate output or warnings with
1051
# the simple link test code.
1052
m4_defun([_LT_LINKER_BOILERPLATE],
1053
[m4_require([_LT_DECL_SED])dnl
1054
ac_outfile=conftest.$ac_objext
1055
echo "$lt_simple_link_test_code" >conftest.$ac_ext
1056
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1057
_lt_linker_boilerplate=`cat conftest.err`
1059
])# _LT_LINKER_BOILERPLATE
1061
# _LT_REQUIRED_DARWIN_CHECKS
1062
# -------------------------
1063
m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1065
rhapsody* | darwin*)
1066
AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1067
AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1068
AC_CHECK_TOOL([LIPO], [lipo], [:])
1069
AC_CHECK_TOOL([OTOOL], [otool], [:])
1070
AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1071
_LT_DECL([], [DSYMUTIL], [1],
1072
[Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1073
_LT_DECL([], [NMEDIT], [1],
1074
[Tool to change global to local symbols on Mac OS X])
1075
_LT_DECL([], [LIPO], [1],
1076
[Tool to manipulate fat objects and archives on Mac OS X])
1077
_LT_DECL([], [OTOOL], [1],
1078
[ldd/readelf like tool for Mach-O binaries on Mac OS X])
1079
_LT_DECL([], [OTOOL64], [1],
1080
[ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1082
AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1083
[lt_cv_apple_cc_single_mod=no
1084
if test -z "${LT_MULTI_MODULE}"; then
1085
# By default we will add the -single_module flag. You can override
1086
# by either setting the environment variable LT_MULTI_MODULE
1087
# non-empty at configure time, or by adding -multi_module to the
1089
rm -rf libconftest.dylib*
1090
echo "int foo(void){return 1;}" > conftest.c
1091
echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1092
-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1093
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1094
-dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1096
if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
1097
lt_cv_apple_cc_single_mod=yes
1099
cat conftest.err >&AS_MESSAGE_LOG_FD
1101
rm -rf libconftest.dylib*
1104
AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1105
[lt_cv_ld_exported_symbols_list],
1106
[lt_cv_ld_exported_symbols_list=no
1107
save_LDFLAGS=$LDFLAGS
1108
echo "_main" > conftest.sym
1109
LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1110
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1111
[lt_cv_ld_exported_symbols_list=yes],
1112
[lt_cv_ld_exported_symbols_list=no])
1113
LDFLAGS="$save_LDFLAGS"
1116
rhapsody* | darwin1.[[012]])
1117
_lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1119
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1120
darwin*) # darwin 5.x on
1121
# if running on 10.5 or later, the deployment target defaults
1122
# to the OS version, if on x86, and 10.4, the deployment
1123
# target defaults to 10.4. Don't you love it?
1124
case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1125
10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1126
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1128
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1130
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1134
if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1135
_lt_dar_single_mod='$single_module'
1137
if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1138
_lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1140
_lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1142
if test "$DSYMUTIL" != ":"; then
1143
_lt_dsymutil='~$DSYMUTIL $lib || :'
1152
# _LT_DARWIN_LINKER_FEATURES
1153
# --------------------------
1154
# Checks for linker and compiler features on darwin
1155
m4_defun([_LT_DARWIN_LINKER_FEATURES],
1157
m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1158
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
1159
_LT_TAGVAR(hardcode_direct, $1)=no
1160
_LT_TAGVAR(hardcode_automatic, $1)=yes
1161
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1162
_LT_TAGVAR(whole_archive_flag_spec, $1)=''
1163
_LT_TAGVAR(link_all_deplibs, $1)=yes
1164
_LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1165
case $cc_basename in
1166
ifort*) _lt_dar_can_shared=yes ;;
1167
*) _lt_dar_can_shared=$GCC ;;
1169
if test "$_lt_dar_can_shared" = "yes"; then
1170
output_verbose_link_cmd=echo
1171
_LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
1172
_LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1173
_LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
1174
_LT_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}"
1176
[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1177
_LT_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}"
1178
_LT_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}"
1182
_LT_TAGVAR(ld_shlibs, $1)=no
1186
# _LT_SYS_MODULE_PATH_AIX
1187
# -----------------------
1188
# Links a minimal program and checks the executable
1189
# for the system default hardcoded library path. In most cases,
1190
# this is /usr/lib:/lib, but when the MPI compilers are used
1191
# the location of the communication and MPI libs are included too.
1192
# If we don't find anything, use the default library path according
1193
# to the aix ld manual.
1194
m4_defun([_LT_SYS_MODULE_PATH_AIX],
1195
[m4_require([_LT_DECL_SED])dnl
1196
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1197
lt_aix_libpath_sed='
1198
/Import File Strings/,/^$/ {
1204
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1205
# Check for a 64-bit object if we didn't find anything.
1206
if test -z "$aix_libpath"; then
1207
aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1209
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1210
])# _LT_SYS_MODULE_PATH_AIX
1213
# _LT_SHELL_INIT(ARG)
1214
# -------------------
1215
m4_define([_LT_SHELL_INIT],
1216
[ifdef([AC_DIVERSION_NOTICE],
1217
[AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1218
[AC_DIVERT_PUSH(NOTICE)])
1224
# _LT_PROG_ECHO_BACKSLASH
1225
# -----------------------
1226
# Add some code to the start of the generated configure script which
1227
# will find an echo command which doesn't interpret backslashes.
1228
m4_defun([_LT_PROG_ECHO_BACKSLASH],
1230
# Check that we are running under the correct shell.
1231
SHELL=${CONFIG_SHELL-/bin/sh}
1235
# Remove one level of quotation (which was required for Make).
1236
ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1240
ECHO=${lt_ECHO-echo}
1241
if test "X[$]1" = X--no-reexec; then
1242
# Discard the --no-reexec flag, and continue.
1244
elif test "X[$]1" = X--fallback-echo; then
1245
# Avoid inline document here, it may be left over
1247
elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
1248
# Yippee, $ECHO works!
1251
# Restart under the correct shell.
1252
exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1255
if test "X[$]1" = X--fallback-echo; then
1256
# used as fallback echo
1264
# The HP-UX ksh and POSIX shell print the target directory to stdout
1266
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1268
if test -z "$lt_ECHO"; then
1269
if test "X${echo_test_string+set}" != Xset; then
1270
# find a string as large as possible, as long as the shell can cope with it
1271
for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1272
# expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1273
if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
1274
{ test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
1281
if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1282
echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1283
test "X$echo_testing_string" = "X$echo_test_string"; then
1286
# The Solaris, AIX, and Digital Unix default echo programs unquote
1287
# backslashes. This makes it impossible to quote backslashes using
1288
# echo "$something" | sed 's/\\/\\\\/g'
1290
# So, first we look for a working echo in the user's PATH.
1292
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1293
for dir in $PATH /usr/ucb; do
1295
if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1296
test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1297
echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1298
test "X$echo_testing_string" = "X$echo_test_string"; then
1305
if test "X$ECHO" = Xecho; then
1306
# We didn't find a better echo, so look for alternatives.
1307
if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
1308
echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
1309
test "X$echo_testing_string" = "X$echo_test_string"; then
1310
# This shell has a builtin print -r that does the trick.
1312
elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
1313
test "X$CONFIG_SHELL" != X/bin/ksh; then
1314
# If we have ksh, try running configure again with it.
1315
ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1316
export ORIGINAL_CONFIG_SHELL
1317
CONFIG_SHELL=/bin/ksh
1319
exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1323
if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1324
echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1325
test "X$echo_testing_string" = "X$echo_test_string"; then
1326
# Cool, printf works
1328
elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1329
test "X$echo_testing_string" = 'X\t' &&
1330
echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1331
test "X$echo_testing_string" = "X$echo_test_string"; then
1332
CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1334
SHELL="$CONFIG_SHELL"
1336
ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1337
elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1338
test "X$echo_testing_string" = 'X\t' &&
1339
echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1340
test "X$echo_testing_string" = "X$echo_test_string"; then
1341
ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1343
# maybe with a smaller string...
1346
for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1347
if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
1354
if test "$prev" != 'sed 50q "[$]0"'; then
1355
echo_test_string=`eval $prev`
1356
export echo_test_string
1357
exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1359
# Oops. We lost completely, so just stick with echo.
1368
# Copy echo and quote the copy suitably for passing to libtool from
1369
# the Makefile, instead of quoting the original, which is used later.
1371
if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1372
lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1377
_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1378
_LT_DECL([], [ECHO], [1],
1379
[An echo program that does not interpret backslashes])
1380
])# _LT_PROG_ECHO_BACKSLASH
1385
m4_defun([_LT_ENABLE_LOCK],
1386
[AC_ARG_ENABLE([libtool-lock],
1387
[AS_HELP_STRING([--disable-libtool-lock],
1388
[avoid locking (might break parallel builds)])])
1389
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1391
# Some flags need to be propagated to the compiler or linker for good
1395
# Find out which ABI we are using.
1396
echo 'int i;' > conftest.$ac_ext
1397
if AC_TRY_EVAL(ac_compile); then
1398
case `/usr/bin/file conftest.$ac_objext` in
1410
# Find out which ABI we are using.
1411
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1412
if AC_TRY_EVAL(ac_compile); then
1413
if test "$lt_cv_prog_gnu_ld" = yes; then
1414
case `/usr/bin/file conftest.$ac_objext` in
1416
LD="${LD-ld} -melf32bsmip"
1419
LD="${LD-ld} -melf32bmipn32"
1422
LD="${LD-ld} -melf64bmip"
1426
case `/usr/bin/file conftest.$ac_objext` in
1442
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1443
s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1444
# Find out which ABI we are using.
1445
echo 'int i;' > conftest.$ac_ext
1446
if AC_TRY_EVAL(ac_compile); then
1447
case `/usr/bin/file conftest.o` in
1450
x86_64-*kfreebsd*-gnu)
1451
LD="${LD-ld} -m elf_i386_fbsd"
1454
LD="${LD-ld} -m elf_i386"
1456
ppc64-*linux*|powerpc64-*linux*)
1457
LD="${LD-ld} -m elf32ppclinux"
1460
LD="${LD-ld} -m elf_s390"
1463
LD="${LD-ld} -m elf32_sparc"
1469
x86_64-*kfreebsd*-gnu)
1470
LD="${LD-ld} -m elf_x86_64_fbsd"
1473
LD="${LD-ld} -m elf_x86_64"
1475
ppc*-*linux*|powerpc*-*linux*)
1476
LD="${LD-ld} -m elf64ppc"
1478
s390*-*linux*|s390*-*tpf*)
1479
LD="${LD-ld} -m elf64_s390"
1482
LD="${LD-ld} -m elf64_sparc"
1492
# On SCO OpenServer 5, we need -belf to get full-featured binaries.
1493
SAVE_CFLAGS="$CFLAGS"
1494
CFLAGS="$CFLAGS -belf"
1495
AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1497
AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1499
if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1500
# this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1501
CFLAGS="$SAVE_CFLAGS"
1505
# Find out which ABI we are using.
1506
echo 'int i;' > conftest.$ac_ext
1507
if AC_TRY_EVAL(ac_compile); then
1508
case `/usr/bin/file conftest.o` in
1510
case $lt_cv_prog_gnu_ld in
1511
yes*) LD="${LD-ld} -m elf64_sparc" ;;
1513
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1525
need_locks="$enable_libtool_lock"
1529
# _LT_CMD_OLD_ARCHIVE
1530
# -------------------
1531
m4_defun([_LT_CMD_OLD_ARCHIVE],
1532
[AC_CHECK_TOOL(AR, ar, false)
1533
test -z "$AR" && AR=ar
1534
test -z "$AR_FLAGS" && AR_FLAGS=cru
1535
_LT_DECL([], [AR], [1], [The archiver])
1536
_LT_DECL([], [AR_FLAGS], [1])
1538
AC_CHECK_TOOL(STRIP, strip, :)
1539
test -z "$STRIP" && STRIP=:
1540
_LT_DECL([], [STRIP], [1], [A symbol stripping program])
1542
AC_CHECK_TOOL(RANLIB, ranlib, :)
1543
test -z "$RANLIB" && RANLIB=:
1544
_LT_DECL([], [RANLIB], [1],
1545
[Commands used to install an old-style archive])
1547
# Determine commands to create old-style static archives.
1548
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1549
old_postinstall_cmds='chmod 644 $oldlib'
1550
old_postuninstall_cmds=
1552
if test -n "$RANLIB"; then
1555
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
1558
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
1561
old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
1563
_LT_DECL([], [old_postinstall_cmds], [2])
1564
_LT_DECL([], [old_postuninstall_cmds], [2])
1565
_LT_TAGDECL([], [old_archive_cmds], [2],
1566
[Commands used to build an old-style archive])
1567
])# _LT_CMD_OLD_ARCHIVE
1570
# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1571
# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1572
# ----------------------------------------------------------------
1573
# Check whether the given compiler option works
1574
AC_DEFUN([_LT_COMPILER_OPTION],
1575
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1576
m4_require([_LT_DECL_SED])dnl
1577
AC_CACHE_CHECK([$1], [$2],
1579
m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1580
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1581
lt_compiler_flag="$3"
1582
# Insert the option either (1) after the last *FLAGS variable, or
1583
# (2) before a word containing "conftest.", or (3) at the end.
1584
# Note that $ac_compile itself does not contain backslashes and begins
1585
# with a dollar sign (not a hyphen), so the echo should work correctly.
1586
# The option is referenced via a variable to avoid confusing sed.
1587
lt_compile=`echo "$ac_compile" | $SED \
1588
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1589
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1590
-e 's:$: $lt_compiler_flag:'`
1591
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1592
(eval "$lt_compile" 2>conftest.err)
1594
cat conftest.err >&AS_MESSAGE_LOG_FD
1595
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1596
if (exit $ac_status) && test -s "$ac_outfile"; then
1597
# The compiler can only warn and ignore the option if not recognized
1598
# So say no if there are warnings other than the usual output.
1599
$ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
1600
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1601
if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1608
if test x"[$]$2" = xyes; then
1609
m4_if([$5], , :, [$5])
1611
m4_if([$6], , :, [$6])
1613
])# _LT_COMPILER_OPTION
1616
AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
1617
dnl aclocal-1.4 backwards compatibility:
1618
dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
1621
# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1622
# [ACTION-SUCCESS], [ACTION-FAILURE])
1623
# ----------------------------------------------------
1624
# Check whether the given linker option works
1625
AC_DEFUN([_LT_LINKER_OPTION],
1626
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1627
m4_require([_LT_DECL_SED])dnl
1628
AC_CACHE_CHECK([$1], [$2],
1630
save_LDFLAGS="$LDFLAGS"
1631
LDFLAGS="$LDFLAGS $3"
1632
echo "$lt_simple_link_test_code" > conftest.$ac_ext
1633
if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1634
# The linker can only warn and ignore the option if not recognized
1635
# So say no if there are warnings
1636
if test -s conftest.err; then
1637
# Append any errors to the config.log.
1638
cat conftest.err 1>&AS_MESSAGE_LOG_FD
1639
$ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
1640
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1641
if diff conftest.exp conftest.er2 >/dev/null; then
1649
LDFLAGS="$save_LDFLAGS"
1652
if test x"[$]$2" = xyes; then
1653
m4_if([$4], , :, [$4])
1655
m4_if([$5], , :, [$5])
1657
])# _LT_LINKER_OPTION
1660
AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
1661
dnl aclocal-1.4 backwards compatibility:
1662
dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
1667
AC_DEFUN([LT_CMD_MAX_LEN],
1668
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
1669
# find the maximum length of command line arguments
1670
AC_MSG_CHECKING([the maximum length of command line arguments])
1671
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1677
# On DJGPP, this test can blow up pretty badly due to problems in libc
1678
# (any single argument exceeding 2000 bytes causes a buffer overrun
1679
# during glob expansion). Even if it were fixed, the result of this
1680
# check would be larger than it should be.
1681
lt_cv_sys_max_cmd_len=12288; # 12K is about right
1685
# Under GNU Hurd, this test is not required because there is
1686
# no limit to the length of command line arguments.
1687
# Libtool will interpret -1 as no limit whatsoever
1688
lt_cv_sys_max_cmd_len=-1;
1691
cygwin* | mingw* | cegcc*)
1692
# On Win9x/ME, this test blows up -- it succeeds, but takes
1693
# about 5 minutes as the teststring grows exponentially.
1694
# Worse, since 9x/ME are not pre-emptively multitasking,
1695
# you end up with a "frozen" computer, even though with patience
1696
# the test eventually succeeds (with a max line length of 256k).
1697
# Instead, let's just punt: use the minimum linelength reported by
1698
# all of the supported platforms: 8192 (on NT/2K/XP).
1699
lt_cv_sys_max_cmd_len=8192;
1703
# On AmigaOS with pdksh, this test takes hours, literally.
1704
# So we just punt and use a minimum line length of 8192.
1705
lt_cv_sys_max_cmd_len=8192;
1708
netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1709
# This has been around since 386BSD, at least. Likely further.
1710
if test -x /sbin/sysctl; then
1711
lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1712
elif test -x /usr/sbin/sysctl; then
1713
lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1715
lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1717
# And add a safety zone
1718
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1719
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1723
# We know the value 262144 and hardcode it with a safety zone (like BSD)
1724
lt_cv_sys_max_cmd_len=196608
1728
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1729
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1730
# nice to cause kernel panics so lets avoid the loop below.
1731
# First set a reasonable default.
1732
lt_cv_sys_max_cmd_len=16384
1734
if test -x /sbin/sysconfig; then
1735
case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1736
*1*) lt_cv_sys_max_cmd_len=-1 ;;
1741
lt_cv_sys_max_cmd_len=102400
1743
sysv5* | sco5v6* | sysv4.2uw2*)
1744
kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1745
if test -n "$kargmax"; then
1746
lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1748
lt_cv_sys_max_cmd_len=32768
1752
lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1753
if test -n "$lt_cv_sys_max_cmd_len"; then
1754
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1755
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1757
# Make teststring a little bigger before we do anything with it.
1758
# a 1K string should be a reasonable start.
1759
for i in 1 2 3 4 5 6 7 8 ; do
1760
teststring=$teststring$teststring
1762
SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1763
# If test is not a shell built-in, we'll probably end up computing a
1764
# maximum length that is only half of the actual maximum length, but
1766
while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
1767
= "XX$teststring$teststring"; } >/dev/null 2>&1 &&
1768
test $i != 17 # 1/2 MB should be enough
1771
teststring=$teststring$teststring
1773
# Only check the string length outside the loop.
1774
lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
1776
# Add a significant safety factor because C++ compilers can tack on
1777
# massive amounts of additional arguments before passing them to the
1778
# linker. It appears as though 1/2 is a usable value.
1779
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1784
if test -n $lt_cv_sys_max_cmd_len ; then
1785
AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1789
max_cmd_len=$lt_cv_sys_max_cmd_len
1790
_LT_DECL([], [max_cmd_len], [0],
1791
[What is the maximum length of a command?])
1795
AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
1796
dnl aclocal-1.4 backwards compatibility:
1797
dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
1802
m4_defun([_LT_HEADER_DLFCN],
1803
[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
1804
])# _LT_HEADER_DLFCN
1807
# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1808
# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1809
# ----------------------------------------------------------------
1810
m4_defun([_LT_TRY_DLOPEN_SELF],
1811
[m4_require([_LT_HEADER_DLFCN])dnl
1812
if test "$cross_compiling" = yes; then :
1815
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1816
lt_status=$lt_dlunknown
1817
cat > conftest.$ac_ext <<_LT_EOF
1818
[#line __oline__ "configure"
1819
#include "confdefs.h"
1828
# define LT_DLGLOBAL RTLD_GLOBAL
1831
# define LT_DLGLOBAL DL_GLOBAL
1833
# define LT_DLGLOBAL 0
1837
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1838
find out it does not work in some platform. */
1839
#ifndef LT_DLLAZY_OR_NOW
1841
# define LT_DLLAZY_OR_NOW RTLD_LAZY
1844
# define LT_DLLAZY_OR_NOW DL_LAZY
1847
# define LT_DLLAZY_OR_NOW RTLD_NOW
1850
# define LT_DLLAZY_OR_NOW DL_NOW
1852
# define LT_DLLAZY_OR_NOW 0
1859
void fnord() { int i=42;}
1862
void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1863
int status = $lt_dlunknown;
1867
if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1868
else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1869
/* dlclose (self); */
1877
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1878
(./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1881
x$lt_dlno_uscore) $1 ;;
1882
x$lt_dlneed_uscore) $2 ;;
1883
x$lt_dlunknown|x*) $3 ;;
1886
# compilation failed
1891
])# _LT_TRY_DLOPEN_SELF
1894
# LT_SYS_DLOPEN_SELF
1895
# ------------------
1896
AC_DEFUN([LT_SYS_DLOPEN_SELF],
1897
[m4_require([_LT_HEADER_DLFCN])dnl
1898
if test "x$enable_dlopen" != xyes; then
1899
enable_dlopen=unknown
1900
enable_dlopen_self=unknown
1901
enable_dlopen_self_static=unknown
1908
lt_cv_dlopen="load_add_on"
1910
lt_cv_dlopen_self=yes
1913
mingw* | pw32* | cegcc*)
1914
lt_cv_dlopen="LoadLibrary"
1919
lt_cv_dlopen="dlopen"
1924
# if libdl is installed we need to link against it
1925
AC_CHECK_LIB([dl], [dlopen],
1926
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1929
lt_cv_dlopen_self=yes
1934
AC_CHECK_FUNC([shl_load],
1935
[lt_cv_dlopen="shl_load"],
1936
[AC_CHECK_LIB([dld], [shl_load],
1937
[lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1938
[AC_CHECK_FUNC([dlopen],
1939
[lt_cv_dlopen="dlopen"],
1940
[AC_CHECK_LIB([dl], [dlopen],
1941
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1942
[AC_CHECK_LIB([svld], [dlopen],
1943
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1944
[AC_CHECK_LIB([dld], [dld_link],
1945
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1954
if test "x$lt_cv_dlopen" != xno; then
1960
case $lt_cv_dlopen in
1962
save_CPPFLAGS="$CPPFLAGS"
1963
test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1965
save_LDFLAGS="$LDFLAGS"
1966
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1969
LIBS="$lt_cv_dlopen_libs $LIBS"
1971
AC_CACHE_CHECK([whether a program can dlopen itself],
1972
lt_cv_dlopen_self, [dnl
1973
_LT_TRY_DLOPEN_SELF(
1974
lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1975
lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1978
if test "x$lt_cv_dlopen_self" = xyes; then
1979
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1980
AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1981
lt_cv_dlopen_self_static, [dnl
1982
_LT_TRY_DLOPEN_SELF(
1983
lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1984
lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1988
CPPFLAGS="$save_CPPFLAGS"
1989
LDFLAGS="$save_LDFLAGS"
1994
case $lt_cv_dlopen_self in
1995
yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1996
*) enable_dlopen_self=unknown ;;
1999
case $lt_cv_dlopen_self_static in
2000
yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2001
*) enable_dlopen_self_static=unknown ;;
2004
_LT_DECL([dlopen_support], [enable_dlopen], [0],
2005
[Whether dlopen is supported])
2006
_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2007
[Whether dlopen of programs is supported])
2008
_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2009
[Whether dlopen of statically linked programs is supported])
2010
])# LT_SYS_DLOPEN_SELF
2013
AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2014
dnl aclocal-1.4 backwards compatibility:
2015
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2018
# _LT_COMPILER_C_O([TAGNAME])
2019
# ---------------------------
2020
# Check to see if options -c and -o are simultaneously supported by compiler.
2021
# This macro does not hard code the compiler like AC_PROG_CC_C_O.
2022
m4_defun([_LT_COMPILER_C_O],
2023
[m4_require([_LT_DECL_SED])dnl
2024
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2025
m4_require([_LT_TAG_COMPILER])dnl
2026
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2027
[_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2028
[_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2029
$RM -r conftest 2>/dev/null
2033
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2035
lt_compiler_flag="-o out/conftest2.$ac_objext"
2036
# Insert the option either (1) after the last *FLAGS variable, or
2037
# (2) before a word containing "conftest.", or (3) at the end.
2038
# Note that $ac_compile itself does not contain backslashes and begins
2039
# with a dollar sign (not a hyphen), so the echo should work correctly.
2040
lt_compile=`echo "$ac_compile" | $SED \
2041
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2042
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2043
-e 's:$: $lt_compiler_flag:'`
2044
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2045
(eval "$lt_compile" 2>out/conftest.err)
2047
cat out/conftest.err >&AS_MESSAGE_LOG_FD
2048
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2049
if (exit $ac_status) && test -s out/conftest2.$ac_objext
2051
# The compiler can only warn and ignore the option if not recognized
2052
# So say no if there are warnings
2053
$ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
2054
$SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2055
if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2056
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2059
chmod u+w . 2>&AS_MESSAGE_LOG_FD
2061
# SGI C++ compiler will create directory out/ii_files/ for
2062
# template instantiation
2063
test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2064
$RM out/* && rmdir out
2069
_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2070
[Does compiler simultaneously support -c and -o options?])
2071
])# _LT_COMPILER_C_O
2074
# _LT_COMPILER_FILE_LOCKS([TAGNAME])
2075
# ----------------------------------
2076
# Check to see if we can do hard links to lock some files if needed
2077
m4_defun([_LT_COMPILER_FILE_LOCKS],
2078
[m4_require([_LT_ENABLE_LOCK])dnl
2079
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2080
_LT_COMPILER_C_O([$1])
2082
hard_links="nottested"
2083
if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2084
# do not overwrite the value of need_locks provided by the user
2085
AC_MSG_CHECKING([if we can lock with hard links])
2088
ln conftest.a conftest.b 2>/dev/null && hard_links=no
2090
ln conftest.a conftest.b 2>&5 || hard_links=no
2091
ln conftest.a conftest.b 2>/dev/null && hard_links=no
2092
AC_MSG_RESULT([$hard_links])
2093
if test "$hard_links" = no; then
2094
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2100
_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2101
])# _LT_COMPILER_FILE_LOCKS
2106
m4_defun([_LT_CHECK_OBJDIR],
2107
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2108
[rm -f .libs 2>/dev/null
2109
mkdir .libs 2>/dev/null
2110
if test -d .libs; then
2113
# MS-DOS does not allow filenames that begin with a dot.
2116
rmdir .libs 2>/dev/null])
2117
objdir=$lt_cv_objdir
2118
_LT_DECL([], [objdir], [0],
2119
[The name of the directory that contains temporary libtool files])dnl
2120
m4_pattern_allow([LT_OBJDIR])dnl
2121
AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2122
[Define to the sub-directory in which libtool stores uninstalled libraries.])
2123
])# _LT_CHECK_OBJDIR
2126
# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2127
# --------------------------------------
2128
# Check hardcoding attributes.
2129
m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2130
[AC_MSG_CHECKING([how to hardcode library paths into programs])
2131
_LT_TAGVAR(hardcode_action, $1)=
2132
if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2133
test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2134
test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2136
# We can hardcode non-existent directories.
2137
if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2138
# If the only mechanism to avoid hardcoding is shlibpath_var, we
2139
# have to relink, otherwise we might link with an installed library
2140
# when we should be linking with a yet-to-be-installed one
2141
## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2142
test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2143
# Linking always hardcodes the temporary library directory.
2144
_LT_TAGVAR(hardcode_action, $1)=relink
2146
# We can link without hardcoding, and we can hardcode nonexisting dirs.
2147
_LT_TAGVAR(hardcode_action, $1)=immediate
2150
# We cannot hardcode anything, or else we can only hardcode existing
2152
_LT_TAGVAR(hardcode_action, $1)=unsupported
2154
AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2156
if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2157
test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2158
# Fast installation is not supported
2159
enable_fast_install=no
2160
elif test "$shlibpath_overrides_runpath" = yes ||
2161
test "$enable_shared" = no; then
2162
# Fast installation is not necessary
2163
enable_fast_install=needless
2165
_LT_TAGDECL([], [hardcode_action], [0],
2166
[How to hardcode a shared library path into an executable])
2167
])# _LT_LINKER_HARDCODE_LIBPATH
2172
m4_defun([_LT_CMD_STRIPLIB],
2173
[m4_require([_LT_DECL_EGREP])
2176
AC_MSG_CHECKING([whether stripping libraries is possible])
2177
if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2178
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2179
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2180
AC_MSG_RESULT([yes])
2182
# FIXME - insert some real tests, host_os isn't really good enough
2185
if test -n "$STRIP" ; then
2186
striplib="$STRIP -x"
2187
old_striplib="$STRIP -S"
2188
AC_MSG_RESULT([yes])
2198
_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2199
_LT_DECL([], [striplib], [1])
2200
])# _LT_CMD_STRIPLIB
2203
# _LT_SYS_DYNAMIC_LINKER([TAG])
2204
# -----------------------------
2205
# PORTME Fill in your ld.so characteristics
2206
m4_defun([_LT_SYS_DYNAMIC_LINKER],
2207
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
2208
m4_require([_LT_DECL_EGREP])dnl
2209
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2210
m4_require([_LT_DECL_OBJDUMP])dnl
2211
m4_require([_LT_DECL_SED])dnl
2212
AC_MSG_CHECKING([dynamic linker characteristics])
2215
if test "$GCC" = yes; then
2217
darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2218
*) lt_awk_arg="/^libraries:/" ;;
2220
lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2221
if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
2222
# if the path contains ";" then we assume it to be the separator
2223
# otherwise default to the standard path separator (i.e. ":") - it is
2224
# assumed that no part of a normal pathname contains ";" but that should
2225
# okay in the real world where ";" in dirpaths is itself problematic.
2226
lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
2228
lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2230
# Ok, now we have the path, separated by spaces, we can step through it
2231
# and add multilib dir if necessary.
2232
lt_tmp_lt_search_path_spec=
2233
lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2234
for lt_sys_path in $lt_search_path_spec; do
2235
if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2236
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2238
test -d "$lt_sys_path" && \
2239
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2242
lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
2243
BEGIN {RS=" "; FS="/|\n";} {
2246
for (lt_i = NF; lt_i > 0; lt_i--) {
2247
if ($lt_i != "" && $lt_i != ".") {
2248
if ($lt_i == "..") {
2251
if (lt_count == 0) {
2252
lt_foo="/" $lt_i lt_foo;
2259
if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2260
if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2262
sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
2264
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2267
libname_spec='lib$name'
2275
shlibpath_overrides_runpath=unknown
2277
dynamic_linker="$host_os ld.so"
2278
sys_lib_dlsearch_path_spec="/lib /usr/lib"
2279
need_lib_prefix=unknown
2280
hardcode_into_libs=no
2282
# when you set need_version to no, make sure it does not cause -set_version
2283
# flags to be left without arguments
2284
need_version=unknown
2289
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2290
shlibpath_var=LIBPATH
2292
# AIX 3 has no versioning support, so we append a major version to the name.
2293
soname_spec='${libname}${release}${shared_ext}$major'
2300
hardcode_into_libs=yes
2301
if test "$host_cpu" = ia64; then
2302
# AIX 5 supports IA64
2303
library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2304
shlibpath_var=LD_LIBRARY_PATH
2306
# With GCC up to 2.95.x, collect2 would create an import file
2307
# for dependence libraries. The import file would start with
2308
# the line `#! .'. This would cause the generated library to
2309
# depend on `.', always an invalid library. This was fixed in
2310
# development snapshots of GCC prior to 3.0.
2312
aix4 | aix4.[[01]] | aix4.[[01]].*)
2313
if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2315
echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2322
# AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2323
# soname into executable. Probably we can add versioning support to
2324
# collect2, so additional links can be useful in future.
2325
if test "$aix_use_runtimelinking" = yes; then
2326
# If using run time linking (on AIX 4.2 or later) use lib<name>.so
2327
# instead of lib<name>.a to let people know that these are not
2328
# typical AIX shared libraries.
2329
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2331
# We preserve .a as extension for shared libraries through AIX4.2
2332
# and later when we are not doing run time linking.
2333
library_names_spec='${libname}${release}.a $libname.a'
2334
soname_spec='${libname}${release}${shared_ext}$major'
2336
shlibpath_var=LIBPATH
2343
# Since July 2007 AmigaOS4 officially supports .so libraries.
2344
# When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2345
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2348
library_names_spec='$libname.ixlibrary $libname.a'
2349
# Create ${libname}_ixlibrary.a entries in /sys/libs.
2350
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'
2356
library_names_spec='${libname}${shared_ext}'
2357
dynamic_linker="$host_os ld.so"
2358
shlibpath_var=LIBRARY_PATH
2364
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2365
soname_spec='${libname}${release}${shared_ext}$major'
2366
finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2367
shlibpath_var=LD_LIBRARY_PATH
2368
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2369
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2370
# the default ld.so.conf also contains /usr/contrib/lib and
2371
# /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2372
# libtool to hard-code these into programs
2375
cygwin* | mingw* | pw32* | cegcc*)
2376
version_type=windows
2381
case $GCC,$host_os in
2382
yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
2383
library_names_spec='$libname.dll.a'
2384
# DLL is installed to $(libdir)/../bin by postinstall_cmds
2385
postinstall_cmds='base_file=`basename \${file}`~
2386
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2387
dldir=$destdir/`dirname \$dlpath`~
2388
test -d \$dldir || mkdir -p \$dldir~
2389
$install_prog $dir/$dlname \$dldir/$dlname~
2390
chmod a+x \$dldir/$dlname~
2391
if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2392
eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2394
postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2395
dlpath=$dir/\$dldll~
2397
shlibpath_overrides_runpath=yes
2401
# Cygwin DLLs use 'cyg' prefix rather than 'lib'
2402
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2403
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2406
# MinGW DLLs use traditional 'lib' prefix
2407
soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2408
sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2409
if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2410
# It is most probably a Windows format PATH printed by
2411
# mingw gcc, but we are running on Cygwin. Gcc prints its search
2412
# path with ; separators, and with drive letters. We can handle the
2413
# drive letters (cygwin fileutils understands them), so leave them,
2414
# especially as we might pass files found there to a mingw objdump,
2415
# which wouldn't understand a cygwinified path. Ahh.
2416
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2418
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2422
# pw32 DLLs use 'pw' prefix rather than 'lib'
2423
library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2429
library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2432
dynamic_linker='Win32 ld.exe'
2433
# FIXME: first we should search . and the directory the executable is in
2437
darwin* | rhapsody*)
2438
dynamic_linker="$host_os dyld"
2442
library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2443
soname_spec='${libname}${release}${major}$shared_ext'
2444
shlibpath_overrides_runpath=yes
2445
shlibpath_var=DYLD_LIBRARY_PATH
2446
shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2448
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2449
sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2456
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2457
soname_spec='${libname}${release}${shared_ext}$major'
2458
shlibpath_var=LD_LIBRARY_PATH
2465
freebsd* | dragonfly*)
2466
# DragonFly does not have aout. When/if they implement a new
2467
# versioning mechanism, adjust this.
2468
if test -x /usr/bin/objformat; then
2469
objformat=`/usr/bin/objformat`
2472
freebsd[[123]]*) objformat=aout ;;
2476
version_type=freebsd-$objformat
2477
case $version_type in
2479
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2484
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2488
shlibpath_var=LD_LIBRARY_PATH
2491
shlibpath_overrides_runpath=yes
2493
freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2494
shlibpath_overrides_runpath=yes
2495
hardcode_into_libs=yes
2497
freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2498
freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2499
shlibpath_overrides_runpath=no
2500
hardcode_into_libs=yes
2502
*) # from 4.6 on, and DragonFly
2503
shlibpath_overrides_runpath=yes
2504
hardcode_into_libs=yes
2513
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2514
soname_spec='${libname}${release}${shared_ext}$major'
2515
shlibpath_var=LD_LIBRARY_PATH
2516
hardcode_into_libs=yes
2519
hpux9* | hpux10* | hpux11*)
2520
# Give a soname corresponding to the major version so that dld.sl refuses to
2521
# link against other versions.
2528
hardcode_into_libs=yes
2529
dynamic_linker="$host_os dld.so"
2530
shlibpath_var=LD_LIBRARY_PATH
2531
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2532
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2533
soname_spec='${libname}${release}${shared_ext}$major'
2534
if test "X$HPUX_IA64_MODE" = X32; then
2535
sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2537
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2539
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2543
hardcode_into_libs=yes
2544
dynamic_linker="$host_os dld.sl"
2545
shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2546
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2547
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2548
soname_spec='${libname}${release}${shared_ext}$major'
2549
sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2550
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2554
dynamic_linker="$host_os dld.sl"
2555
shlibpath_var=SHLIB_PATH
2556
shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2557
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2558
soname_spec='${libname}${release}${shared_ext}$major'
2561
# HP-UX runs *really* slowly unless shared libraries are mode 555.
2562
postinstall_cmds='chmod 555 $lib'
2569
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2570
soname_spec='${libname}${release}${shared_ext}$major'
2571
dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2572
shlibpath_var=LD_LIBRARY_PATH
2573
shlibpath_overrides_runpath=no
2574
hardcode_into_libs=yes
2577
irix5* | irix6* | nonstopux*)
2579
nonstopux*) version_type=nonstopux ;;
2581
if test "$lt_cv_prog_gnu_ld" = yes; then
2589
soname_spec='${libname}${release}${shared_ext}$major'
2590
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2592
irix5* | nonstopux*)
2596
case $LD in # libtool.m4 will add one of these switches to LD
2597
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2598
libsuff= shlibsuff= libmagic=32-bit;;
2599
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2600
libsuff=32 shlibsuff=N32 libmagic=N32;;
2601
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2602
libsuff=64 shlibsuff=64 libmagic=64-bit;;
2603
*) libsuff= shlibsuff= libmagic=never-match;;
2607
shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2608
shlibpath_overrides_runpath=no
2609
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2610
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2611
hardcode_into_libs=yes
2614
# No shared lib support for Linux oldld, aout, or coff.
2615
linux*oldld* | linux*aout* | linux*coff*)
2619
# This must be Linux ELF.
2620
linux* | k*bsd*-gnu | kopensolaris*-gnu)
2624
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2625
soname_spec='${libname}${release}${shared_ext}$major'
2626
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2627
shlibpath_var=LD_LIBRARY_PATH
2628
shlibpath_overrides_runpath=no
2629
# Some binutils ld are patched to set DT_RUNPATH
2630
save_LDFLAGS=$LDFLAGS
2632
eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
2633
LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
2634
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2635
[AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
2636
[shlibpath_overrides_runpath=yes])])
2637
LDFLAGS=$save_LDFLAGS
2640
# This implies no fast_install, which is unacceptable.
2641
# Some rework will be needed to allow for fast_install
2642
# before this can be enabled.
2643
hardcode_into_libs=yes
2645
# Append ld.so.conf contents to the search path
2646
if test -f /etc/ld.so.conf; then
2647
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' ' '`
2648
sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2651
# We used to test for /lib/ld.so.1 and disable shared libraries on
2652
# powerpc, because MkLinux only supported shared libraries with the
2653
# GNU dynamic linker. Since this was broken with cross compilers,
2654
# most powerpc-linux boxes support dynamic linking these days and
2655
# people can always --disable-shared, the test was removed, and we
2656
# assume the GNU/Linux dynamic linker is in use.
2657
dynamic_linker='GNU/Linux ld.so'
2664
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2665
soname_spec='${libname}${release}${shared_ext}$major'
2666
shlibpath_var=LD_LIBRARY_PATH
2667
shlibpath_overrides_runpath=no
2668
hardcode_into_libs=yes
2669
dynamic_linker='NetBSD ld.elf_so'
2676
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2677
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2678
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2679
dynamic_linker='NetBSD (a.out) ld.so'
2681
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2682
soname_spec='${libname}${release}${shared_ext}$major'
2683
dynamic_linker='NetBSD ld.elf_so'
2685
shlibpath_var=LD_LIBRARY_PATH
2686
shlibpath_overrides_runpath=yes
2687
hardcode_into_libs=yes
2692
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2693
shlibpath_var=LD_LIBRARY_PATH
2694
shlibpath_overrides_runpath=yes
2701
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2702
soname_spec='${libname}${release}${shared_ext}$major'
2703
shlibpath_var=LD_LIBRARY_PATH
2704
shlibpath_overrides_runpath=no
2705
hardcode_into_libs=yes
2706
dynamic_linker='ldqnx.so'
2711
sys_lib_dlsearch_path_spec="/usr/lib"
2713
# Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2715
openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2716
*) need_version=no ;;
2718
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2719
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2720
shlibpath_var=LD_LIBRARY_PATH
2721
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2723
openbsd2.[[89]] | openbsd2.[[89]].*)
2724
shlibpath_overrides_runpath=no
2727
shlibpath_overrides_runpath=yes
2731
shlibpath_overrides_runpath=yes
2736
libname_spec='$name'
2739
library_names_spec='$libname${shared_ext} $libname.a'
2740
dynamic_linker='OS/2 ld.exe'
2741
shlibpath_var=LIBPATH
2744
osf3* | osf4* | osf5*)
2748
soname_spec='${libname}${release}${shared_ext}$major'
2749
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2750
shlibpath_var=LD_LIBRARY_PATH
2751
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2752
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2763
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2764
soname_spec='${libname}${release}${shared_ext}$major'
2765
shlibpath_var=LD_LIBRARY_PATH
2766
shlibpath_overrides_runpath=yes
2767
hardcode_into_libs=yes
2768
# ldd complains unless libraries are executable
2769
postinstall_cmds='chmod +x $lib'
2774
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2775
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2776
shlibpath_var=LD_LIBRARY_PATH
2777
shlibpath_overrides_runpath=yes
2778
if test "$with_gnu_ld" = yes; then
2786
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2787
soname_spec='${libname}${release}${shared_ext}$major'
2788
shlibpath_var=LD_LIBRARY_PATH
2789
case $host_vendor in
2791
shlibpath_overrides_runpath=no
2793
runpath_var=LD_RUN_PATH
2801
shlibpath_overrides_runpath=no
2802
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2808
if test -d /usr/nec ;then
2810
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2811
soname_spec='$libname${shared_ext}.$major'
2812
shlibpath_var=LD_LIBRARY_PATH
2816
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2817
version_type=freebsd-elf
2820
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2821
soname_spec='${libname}${release}${shared_ext}$major'
2822
shlibpath_var=LD_LIBRARY_PATH
2823
shlibpath_overrides_runpath=yes
2824
hardcode_into_libs=yes
2825
if test "$with_gnu_ld" = yes; then
2826
sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2828
sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2831
sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2835
sys_lib_dlsearch_path_spec='/usr/lib'
2839
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
2843
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2844
shlibpath_var=LD_LIBRARY_PATH
2845
shlibpath_overrides_runpath=no
2846
hardcode_into_libs=yes
2851
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2852
soname_spec='${libname}${release}${shared_ext}$major'
2853
shlibpath_var=LD_LIBRARY_PATH
2860
AC_MSG_RESULT([$dynamic_linker])
2861
test "$dynamic_linker" = no && can_build_shared=no
2863
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2864
if test "$GCC" = yes; then
2865
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2868
if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
2869
sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
2871
if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
2872
sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
2875
_LT_DECL([], [variables_saved_for_relink], [1],
2876
[Variables whose values should be saved in libtool wrapper scripts and
2877
restored at link time])
2878
_LT_DECL([], [need_lib_prefix], [0],
2879
[Do we need the "lib" prefix for modules?])
2880
_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
2881
_LT_DECL([], [version_type], [0], [Library versioning type])
2882
_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
2883
_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
2884
_LT_DECL([], [shlibpath_overrides_runpath], [0],
2885
[Is shlibpath searched before the hard-coded library search path?])
2886
_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
2887
_LT_DECL([], [library_names_spec], [1],
2888
[[List of archive names. First name is the real one, the rest are links.
2889
The last name is the one that the linker finds with -lNAME]])
2890
_LT_DECL([], [soname_spec], [1],
2891
[[The coded name of the library, if different from the real name]])
2892
_LT_DECL([], [postinstall_cmds], [2],
2893
[Command to use after installation of a shared archive])
2894
_LT_DECL([], [postuninstall_cmds], [2],
2895
[Command to use after uninstallation of a shared archive])
2896
_LT_DECL([], [finish_cmds], [2],
2897
[Commands used to finish a libtool library installation in a directory])
2898
_LT_DECL([], [finish_eval], [1],
2899
[[As "finish_cmds", except a single script fragment to be evaled but
2901
_LT_DECL([], [hardcode_into_libs], [0],
2902
[Whether we should hardcode library paths into libraries])
2903
_LT_DECL([], [sys_lib_search_path_spec], [2],
2904
[Compile-time system search path for libraries])
2905
_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
2906
[Run-time system search path for libraries])
2907
])# _LT_SYS_DYNAMIC_LINKER
2910
# _LT_PATH_TOOL_PREFIX(TOOL)
2911
# --------------------------
2912
# find a file program which can recognize shared library
2913
AC_DEFUN([_LT_PATH_TOOL_PREFIX],
2914
[m4_require([_LT_DECL_EGREP])dnl
2915
AC_MSG_CHECKING([for $1])
2916
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2918
[[\\/*] | ?:[\\/]*])
2919
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2922
lt_save_MAGIC_CMD="$MAGIC_CMD"
2923
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2924
dnl $ac_dummy forces splitting on constant user-supplied paths.
2925
dnl POSIX.2 word splitting is done only on the output of word expansions,
2926
dnl not every word. This closes a longstanding sh security hole.
2927
ac_dummy="m4_if([$2], , $PATH, [$2])"
2928
for ac_dir in $ac_dummy; do
2930
test -z "$ac_dir" && ac_dir=.
2931
if test -f $ac_dir/$1; then
2932
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2933
if test -n "$file_magic_test_file"; then
2934
case $deplibs_check_method in
2936
file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
2937
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2938
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2939
$EGREP "$file_magic_regex" > /dev/null; then
2944
*** Warning: the command libtool uses to detect shared libraries,
2945
*** $file_magic_cmd, produces output that libtool cannot recognize.
2946
*** The result is that libtool may fail to recognize shared libraries
2947
*** as such. This will affect the creation of libtool libraries that
2948
*** depend on shared libraries, but programs linked with such libtool
2949
*** libraries will work regardless of this problem. Nevertheless, you
2950
*** may want to report the problem to your system manager and/or to
2951
*** bug-libtool@gnu.org
2961
MAGIC_CMD="$lt_save_MAGIC_CMD"
2964
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2965
if test -n "$MAGIC_CMD"; then
2966
AC_MSG_RESULT($MAGIC_CMD)
2970
_LT_DECL([], [MAGIC_CMD], [0],
2971
[Used to examine libraries when file_magic_cmd begins with "file"])dnl
2972
])# _LT_PATH_TOOL_PREFIX
2975
AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
2976
dnl aclocal-1.4 backwards compatibility:
2977
dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
2982
# find a file program which can recognize a shared library
2983
m4_defun([_LT_PATH_MAGIC],
2984
[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2985
if test -z "$lt_cv_path_MAGIC_CMD"; then
2986
if test -n "$ac_tool_prefix"; then
2987
_LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2997
# find the pathname to the GNU or non-GNU linker
2998
AC_DEFUN([LT_PATH_LD],
2999
[AC_REQUIRE([AC_PROG_CC])dnl
3000
AC_REQUIRE([AC_CANONICAL_HOST])dnl
3001
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3002
m4_require([_LT_DECL_SED])dnl
3003
m4_require([_LT_DECL_EGREP])dnl
3005
AC_ARG_WITH([gnu-ld],
3006
[AS_HELP_STRING([--with-gnu-ld],
3007
[assume the C compiler uses GNU ld @<:@default=no@:>@])],
3008
[test "$withval" = no || with_gnu_ld=yes],
3009
[with_gnu_ld=no])dnl
3012
if test "$GCC" = yes; then
3013
# Check if gcc -print-prog-name=ld gives a path.
3014
AC_MSG_CHECKING([for ld used by $CC])
3017
# gcc leaves a trailing carriage return which upsets mingw
3018
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3020
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3023
# Accept absolute paths.
3024
[[\\/]]* | ?:[[\\/]]*)
3025
re_direlt='/[[^/]][[^/]]*/\.\./'
3026
# Canonicalize the pathname of ld
3027
ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3028
while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3029
ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3031
test -z "$LD" && LD="$ac_prog"
3034
# If it fails, then pretend we aren't using GCC.
3038
# If it is relative, then search for the first ld in PATH.
3042
elif test "$with_gnu_ld" = yes; then
3043
AC_MSG_CHECKING([for GNU ld])
3045
AC_MSG_CHECKING([for non-GNU ld])
3047
AC_CACHE_VAL(lt_cv_path_LD,
3048
[if test -z "$LD"; then
3049
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3050
for ac_dir in $PATH; do
3052
test -z "$ac_dir" && ac_dir=.
3053
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3054
lt_cv_path_LD="$ac_dir/$ac_prog"
3055
# Check to see if the program is GNU ld. I'd rather use --version,
3056
# but apparently some variants of GNU ld only accept -v.
3057
# Break only if it was the GNU/non-GNU ld that we prefer.
3058
case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3059
*GNU* | *'with BFD'*)
3060
test "$with_gnu_ld" != no && break
3063
test "$with_gnu_ld" != yes && break
3070
lt_cv_path_LD="$LD" # Let the user override the test with a path.
3073
if test -n "$LD"; then
3078
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3082
_LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3086
AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3087
AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3088
dnl aclocal-1.4 backwards compatibility:
3089
dnl AC_DEFUN([AM_PROG_LD], [])
3090
dnl AC_DEFUN([AC_PROG_LD], [])
3095
m4_defun([_LT_PATH_LD_GNU],
3096
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3097
[# I'd rather use --version here, but apparently some GNU lds only accept -v.
3098
case `$LD -v 2>&1 </dev/null` in
3099
*GNU* | *'with BFD'*)
3100
lt_cv_prog_gnu_ld=yes
3103
lt_cv_prog_gnu_ld=no
3106
with_gnu_ld=$lt_cv_prog_gnu_ld
3112
# find reload flag for linker
3113
# -- PORTME Some linkers may need a different reload flag.
3114
m4_defun([_LT_CMD_RELOAD],
3115
[AC_CACHE_CHECK([for $LD option to reload object files],
3116
lt_cv_ld_reload_flag,
3117
[lt_cv_ld_reload_flag='-r'])
3118
reload_flag=$lt_cv_ld_reload_flag
3119
case $reload_flag in
3121
*) reload_flag=" $reload_flag" ;;
3123
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3126
if test "$GCC" = yes; then
3127
reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3129
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3133
_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3134
_LT_DECL([], [reload_cmds], [2])dnl
3138
# _LT_CHECK_MAGIC_METHOD
3139
# ----------------------
3140
# how to check for library dependencies
3141
# -- PORTME fill in with the dynamic library characteristics
3142
m4_defun([_LT_CHECK_MAGIC_METHOD],
3143
[m4_require([_LT_DECL_EGREP])
3144
m4_require([_LT_DECL_OBJDUMP])
3145
AC_CACHE_CHECK([how to recognize dependent libraries],
3146
lt_cv_deplibs_check_method,
3147
[lt_cv_file_magic_cmd='$MAGIC_CMD'
3148
lt_cv_file_magic_test_file=
3149
lt_cv_deplibs_check_method='unknown'
3150
# Need to set the preceding variable on all platforms that support
3151
# interlibrary dependencies.
3152
# 'none' -- dependencies not supported.
3153
# `unknown' -- same as none, but documents that we really don't know.
3154
# 'pass_all' -- all dependencies passed with no checks.
3155
# 'test_compile' -- check by making test program.
3156
# 'file_magic [[regex]]' -- check by looking for files in library path
3157
# which responds to the $file_magic_cmd with a given extended regex.
3158
# If you have `file' or equivalent on your system and you're not sure
3159
# whether `pass_all' will *always* work, you probably want this one.
3163
lt_cv_deplibs_check_method=pass_all
3167
lt_cv_deplibs_check_method=pass_all
3171
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3172
lt_cv_file_magic_cmd='/usr/bin/file -L'
3173
lt_cv_file_magic_test_file=/shlib/libc.so
3177
# func_win32_libid is a shell function defined in ltmain.sh
3178
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3179
lt_cv_file_magic_cmd='func_win32_libid'
3183
# Base MSYS/MinGW do not provide the 'file' command needed by
3184
# func_win32_libid shell function, so use a weaker test based on 'objdump',
3185
# unless we find 'file', for example because we are cross-compiling.
3186
if ( file / ) >/dev/null 2>&1; then
3187
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3188
lt_cv_file_magic_cmd='func_win32_libid'
3190
lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3191
lt_cv_file_magic_cmd='$OBJDUMP -f'
3196
# use the weaker test based on 'objdump'. See mingw*.
3197
lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3198
lt_cv_file_magic_cmd='$OBJDUMP -f'
3201
darwin* | rhapsody*)
3202
lt_cv_deplibs_check_method=pass_all
3205
freebsd* | dragonfly*)
3206
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3209
# Not sure whether the presence of OpenBSD here was a mistake.
3210
# Let's accept both of them until this is cleared up.
3211
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3212
lt_cv_file_magic_cmd=/usr/bin/file
3213
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3217
lt_cv_deplibs_check_method=pass_all
3222
lt_cv_deplibs_check_method=pass_all
3225
hpux10.20* | hpux11*)
3226
lt_cv_file_magic_cmd=/usr/bin/file
3229
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3230
lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3233
[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]']
3234
lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3237
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3238
lt_cv_file_magic_test_file=/usr/lib/libc.sl
3244
# PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3245
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3248
irix5* | irix6* | nonstopux*)
3250
*-32|*"-32 ") libmagic=32-bit;;
3251
*-n32|*"-n32 ") libmagic=N32;;
3252
*-64|*"-64 ") libmagic=64-bit;;
3253
*) libmagic=never-match;;
3255
lt_cv_deplibs_check_method=pass_all
3258
# This must be Linux ELF.
3259
linux* | k*bsd*-gnu | kopensolaris*-gnu)
3260
lt_cv_deplibs_check_method=pass_all
3263
netbsd* | netbsdelf*-gnu)
3264
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3265
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3267
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3272
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3273
lt_cv_file_magic_cmd=/usr/bin/file
3274
lt_cv_file_magic_test_file=/usr/lib/libnls.so
3278
lt_cv_deplibs_check_method=pass_all
3282
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3283
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3285
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3289
osf3* | osf4* | osf5*)
3290
lt_cv_deplibs_check_method=pass_all
3294
lt_cv_deplibs_check_method=pass_all
3298
lt_cv_deplibs_check_method=pass_all
3301
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3302
lt_cv_deplibs_check_method=pass_all
3306
case $host_vendor in
3308
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]]'
3309
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3312
lt_cv_deplibs_check_method=pass_all
3315
lt_cv_file_magic_cmd='/bin/file'
3316
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3319
lt_cv_file_magic_cmd='/bin/file'
3320
lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3321
lt_cv_file_magic_test_file=/lib/libc.so
3324
lt_cv_deplibs_check_method=pass_all
3327
lt_cv_deplibs_check_method=pass_all
3333
lt_cv_deplibs_check_method=pass_all
3337
file_magic_cmd=$lt_cv_file_magic_cmd
3338
deplibs_check_method=$lt_cv_deplibs_check_method
3339
test -z "$deplibs_check_method" && deplibs_check_method=unknown
3341
_LT_DECL([], [deplibs_check_method], [1],
3342
[Method to check whether dependent libraries are shared objects])
3343
_LT_DECL([], [file_magic_cmd], [1],
3344
[Command to use when deplibs_check_method == "file_magic"])
3345
])# _LT_CHECK_MAGIC_METHOD
3350
# find the pathname to a BSD- or MS-compatible name lister
3351
AC_DEFUN([LT_PATH_NM],
3352
[AC_REQUIRE([AC_PROG_CC])dnl
3353
AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
3354
[if test -n "$NM"; then
3355
# Let the user override the test.
3358
lt_nm_to_check="${ac_tool_prefix}nm"
3359
if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3360
lt_nm_to_check="$lt_nm_to_check nm"
3362
for lt_tmp_nm in $lt_nm_to_check; do
3363
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3364
for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3366
test -z "$ac_dir" && ac_dir=.
3367
tmp_nm="$ac_dir/$lt_tmp_nm"
3368
if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3369
# Check to see if the nm accepts a BSD-compat flag.
3370
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
3371
# nm: unknown option "B" ignored
3372
# Tru64's nm complains that /dev/null is an invalid object file
3373
case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3374
*/dev/null* | *'Invalid file or object type'*)
3375
lt_cv_path_NM="$tmp_nm -B"
3379
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3381
lt_cv_path_NM="$tmp_nm -p"
3385
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3386
continue # so that we can try to find one that supports BSD flags
3395
: ${lt_cv_path_NM=no}
3397
if test "$lt_cv_path_NM" != "no"; then
3400
# Didn't find any BSD compatible name lister, look for dumpbin.
3401
AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
3403
if test "$DUMPBIN" != ":"; then
3407
test -z "$NM" && NM=nm
3409
_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
3411
AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3412
[lt_cv_nm_interface="BSD nm"
3413
echo "int some_variable = 0;" > conftest.$ac_ext
3414
(eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3415
(eval "$ac_compile" 2>conftest.err)
3416
cat conftest.err >&AS_MESSAGE_LOG_FD
3417
(eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3418
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3419
cat conftest.err >&AS_MESSAGE_LOG_FD
3420
(eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
3421
cat conftest.out >&AS_MESSAGE_LOG_FD
3422
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3423
lt_cv_nm_interface="MS dumpbin"
3429
AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
3430
AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
3431
dnl aclocal-1.4 backwards compatibility:
3432
dnl AC_DEFUN([AM_PROG_NM], [])
3433
dnl AC_DEFUN([AC_PROG_NM], [])
3438
# check for math library
3439
AC_DEFUN([LT_LIB_M],
3440
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3443
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3444
# These system don't have libm, or don't need it
3447
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3448
AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3451
AC_CHECK_LIB(m, cos, LIBM="-lm")
3458
AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
3459
dnl aclocal-1.4 backwards compatibility:
3460
dnl AC_DEFUN([AC_CHECK_LIBM], [])
3463
# _LT_COMPILER_NO_RTTI([TAGNAME])
3464
# -------------------------------
3465
m4_defun([_LT_COMPILER_NO_RTTI],
3466
[m4_require([_LT_TAG_COMPILER])dnl
3468
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3470
if test "$GCC" = yes; then
3471
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3473
_LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
3474
lt_cv_prog_compiler_rtti_exceptions,
3475
[-fno-rtti -fno-exceptions], [],
3476
[_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
3478
_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
3479
[Compiler flag to turn off builtin functions])
3480
])# _LT_COMPILER_NO_RTTI
3483
# _LT_CMD_GLOBAL_SYMBOLS
3484
# ----------------------
3485
m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
3486
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3487
AC_REQUIRE([AC_PROG_CC])dnl
3488
AC_REQUIRE([LT_PATH_NM])dnl
3489
AC_REQUIRE([LT_PATH_LD])dnl
3490
m4_require([_LT_DECL_SED])dnl
3491
m4_require([_LT_DECL_EGREP])dnl
3492
m4_require([_LT_TAG_COMPILER])dnl
3494
# Check for command to grab the raw symbol name followed by C symbol from nm.
3495
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
3496
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
3498
# These are sane defaults that work on at least a few old systems.
3499
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
3501
# Character class describing NM global symbol codes.
3502
symcode='[[BCDEGRST]]'
3504
# Regexp to match symbols that can be accessed directly from C.
3505
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
3507
# Define system-specific variables.
3512
cygwin* | mingw* | pw32* | cegcc*)
3513
symcode='[[ABCDGISTW]]'
3516
if test "$host_cpu" = ia64; then
3517
symcode='[[ABCDEGRST]]'
3521
symcode='[[BCDEGRST]]'
3524
symcode='[[BCDEGQRST]]'
3535
sysv5* | sco5v6* | unixware* | OpenUNIX*)
3539
symcode='[[DFNSTU]]'
3543
# If we're using GNU nm, then use its standard symbol codes.
3544
case `$NM -V 2>&1` in
3545
*GNU* | *'with BFD'*)
3546
symcode='[[ABCDGIRSTW]]' ;;
3549
# Transform an extracted symbol line into a proper C declaration.
3550
# Some systems (esp. on ia64) link data and code symbols differently,
3551
# so use this general approach.
3552
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
3554
# Transform an extracted symbol line into symbol name and symbol address
3555
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
3556
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
3558
# Handle CRLF in mingw tool chain
3562
opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
3566
# Try without a prefix underscore, then with it.
3567
for ac_symprfx in "" "_"; do
3569
# Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
3570
symxfrm="\\1 $ac_symprfx\\2 \\2"
3572
# Write the raw and C identifiers.
3573
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3574
# Fake it for dumpbin and say T for any non-static function
3575
# and D for any global variable.
3576
# Also find C++ and __fastcall symbols from MSVC++,
3577
# which start with @ or ?.
3578
lt_cv_sys_global_symbol_pipe="$AWK ['"\
3579
" {last_section=section; section=\$ 3};"\
3580
" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
3581
" \$ 0!~/External *\|/{next};"\
3582
" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
3583
" {if(hide[section]) next};"\
3584
" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
3585
" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
3586
" s[1]~/^[@?]/{print s[1], s[1]; next};"\
3587
" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
3588
" ' prfx=^$ac_symprfx]"
3590
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
3593
# Check to see that the pipe works correctly.
3597
cat > conftest.$ac_ext <<_LT_EOF
3602
void nm_test_func(void);
3603
void nm_test_func(void){}
3607
int main(){nm_test_var='a';nm_test_func();return(0);}
3610
if AC_TRY_EVAL(ac_compile); then
3611
# Now try to grab the symbols.
3613
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
3614
# Try sorting and uniquifying the output.
3615
if sort "$nlist" | uniq > "$nlist"T; then
3616
mv -f "$nlist"T "$nlist"
3621
# Make sure that we snagged all the symbols we need.
3622
if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
3623
if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
3624
cat <<_LT_EOF > conftest.$ac_ext
3630
# Now generate the symbol file.
3631
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
3633
cat <<_LT_EOF >> conftest.$ac_ext
3635
/* The mapping between symbol names and symbols. */
3640
lt__PROGRAM__LTX_preloaded_symbols[[]] =
3642
{ "@PROGRAM@", (void *) 0 },
3644
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
3645
cat <<\_LT_EOF >> conftest.$ac_ext
3649
/* This works around a problem in FreeBSD linker */
3650
#ifdef FREEBSD_WORKAROUND
3651
static const void *lt_preloaded_setup() {
3652
return lt__PROGRAM__LTX_preloaded_symbols;
3660
# Now try linking the two files.
3661
mv conftest.$ac_objext conftstm.$ac_objext
3662
lt_save_LIBS="$LIBS"
3663
lt_save_CFLAGS="$CFLAGS"
3664
LIBS="conftstm.$ac_objext"
3665
CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
3666
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
3669
LIBS="$lt_save_LIBS"
3670
CFLAGS="$lt_save_CFLAGS"
3672
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
3675
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
3678
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
3681
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
3682
cat conftest.$ac_ext >&5
3684
rm -rf conftest* conftst*
3686
# Do not use the global_symbol_pipe unless it works.
3687
if test "$pipe_works" = yes; then
3690
lt_cv_sys_global_symbol_pipe=
3694
if test -z "$lt_cv_sys_global_symbol_pipe"; then
3695
lt_cv_sys_global_symbol_to_cdecl=
3697
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
3698
AC_MSG_RESULT(failed)
3703
_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
3704
[Take the output of nm and produce a listing of raw symbols and C names])
3705
_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
3706
[Transform the output of nm in a proper C declaration])
3707
_LT_DECL([global_symbol_to_c_name_address],
3708
[lt_cv_sys_global_symbol_to_c_name_address], [1],
3709
[Transform the output of nm in a C name address pair])
3710
_LT_DECL([global_symbol_to_c_name_address_lib_prefix],
3711
[lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
3712
[Transform the output of nm in a C name address pair when lib prefix is needed])
3713
]) # _LT_CMD_GLOBAL_SYMBOLS
3716
# _LT_COMPILER_PIC([TAGNAME])
3717
# ---------------------------
3718
m4_defun([_LT_COMPILER_PIC],
3719
[m4_require([_LT_TAG_COMPILER])dnl
3720
_LT_TAGVAR(lt_prog_compiler_wl, $1)=
3721
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
3722
_LT_TAGVAR(lt_prog_compiler_static, $1)=
3724
AC_MSG_CHECKING([for $compiler option to produce PIC])
3725
m4_if([$1], [CXX], [
3726
# C++ specific cases for pic, static, wl, etc.
3727
if test "$GXX" = yes; then
3728
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3729
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
3733
# All AIX code is PIC.
3734
if test "$host_cpu" = ia64; then
3735
# AIX 5 now supports IA64 processor
3736
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3743
# see comment about AmigaOS4 .so support
3744
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3747
# FIXME: we need at least 68020 code to build shared libraries, but
3748
# adding the `-m68020' flag to GCC prevents building anything better,
3750
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
3755
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
3756
# PIC is the default for these OSes.
3758
mingw* | cygwin* | os2* | pw32* | cegcc*)
3759
# This hack is so that the source file can tell whether it is being
3760
# built for inclusion in a dll (and should export symbols for example).
3761
# Although the cygwin gcc ignores -fPIC, still need this for old-style
3762
# (--disable-auto-import) libraries
3763
m4_if([$1], [GCJ], [],
3764
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
3766
darwin* | rhapsody*)
3767
# PIC is the default on this platform
3768
# Common symbols not allowed in MH_DYLIB files
3769
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
3772
# DJGPP does not support shared libraries at all
3773
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
3776
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
3777
# Instead, we relocate shared libraries at runtime.
3780
if test -d /usr/nec; then
3781
_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
3785
# PIC is the default for 64-bit PA HP-UX, but not for 32-bit
3786
# PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
3787
# sets the default TLS model and affects inlining.
3792
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3797
# QNX uses GNU C++, but need to define -shared option too, otherwise
3799
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
3802
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3808
# All AIX code is PIC.
3809
if test "$host_cpu" = ia64; then
3810
# AIX 5 now supports IA64 processor
3811
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3813
_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
3817
case $cc_basename in
3819
# Green Hills C++ Compiler
3820
# _LT_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"
3825
case $cc_basename in
3827
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
3830
# Green Hills C++ Compiler
3831
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
3837
freebsd* | dragonfly*)
3838
# FreeBSD uses GNU C++
3840
hpux9* | hpux10* | hpux11*)
3841
case $cc_basename in
3843
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3844
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
3845
if test "$host_cpu" != ia64; then
3846
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
3850
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3851
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
3857
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
3866
# This is c89, which is MS Visual C++ (no shared libs)
3867
# Anyone wants to do a port?
3869
irix5* | irix6* | nonstopux*)
3870
case $cc_basename in
3872
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3873
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
3874
# CC pic flag -KPIC is the default.
3880
linux* | k*bsd*-gnu | kopensolaris*-gnu)
3881
case $cc_basename in
3884
_LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
3885
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3888
# old Intel C++ for x86_64 which still supported -KPIC.
3889
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3890
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
3891
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
3894
# Intel C++, used to be incompatible with GCC.
3895
# ICC 10 doesn't accept -KPIC any more.
3896
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3897
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3898
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
3901
# Portland Group C++ compiler
3902
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3903
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
3904
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3908
# Make sure the PIC flag is empty. It appears that all Alpha
3909
# Linux and Compaq Tru64 Unix objects are PIC.
3910
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
3911
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
3915
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3916
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
3917
_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
3920
case `$CC -V 2>&1 | sed 5q` in
3923
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
3924
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3925
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
3936
case $cc_basename in
3938
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
3944
netbsd* | netbsdelf*-gnu)
3947
# QNX uses GNU C++, but need to define -shared option too, otherwise
3949
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
3951
osf3* | osf4* | osf5*)
3952
case $cc_basename in
3954
_LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
3957
# Rational C++ 2.4.1
3958
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
3961
# Digital/Compaq C++
3962
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3963
# Make sure the PIC flag is empty. It appears that all Alpha
3964
# Linux and Compaq Tru64 Unix objects are PIC.
3965
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
3966
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
3975
case $cc_basename in
3977
# Sun C++ 4.2, 5.x and Centerline C++
3978
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
3979
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3980
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
3983
# Green Hills C++ Compiler
3984
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
3991
case $cc_basename in
3994
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
3995
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3999
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4005
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4006
case $cc_basename in
4008
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4009
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4010
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4015
case $cc_basename in
4017
# NonStop-UX NCC 3.20
4018
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4027
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4033
if test "$GCC" = yes; then
4034
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4035
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4039
# All AIX code is PIC.
4040
if test "$host_cpu" = ia64; then
4041
# AIX 5 now supports IA64 processor
4042
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4049
# see comment about AmigaOS4 .so support
4050
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4053
# FIXME: we need at least 68020 code to build shared libraries, but
4054
# adding the `-m68020' flag to GCC prevents building anything better,
4056
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4061
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4062
# PIC is the default for these OSes.
4065
mingw* | cygwin* | pw32* | os2* | cegcc*)
4066
# This hack is so that the source file can tell whether it is being
4067
# built for inclusion in a dll (and should export symbols for example).
4068
# Although the cygwin gcc ignores -fPIC, still need this for old-style
4069
# (--disable-auto-import) libraries
4070
m4_if([$1], [GCJ], [],
4071
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4074
darwin* | rhapsody*)
4075
# PIC is the default on this platform
4076
# Common symbols not allowed in MH_DYLIB files
4077
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4081
# PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4082
# PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4083
# sets the default TLS model and affects inlining.
4089
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4095
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
4096
# Instead, we relocate shared libraries at runtime.
4100
# Just because we use GCC doesn't mean we suddenly get shared libraries
4101
# on systems that don't support them.
4102
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4107
# QNX uses GNU C++, but need to define -shared option too, otherwise
4109
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4113
if test -d /usr/nec; then
4114
_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4119
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4123
# PORTME Check for flag to pass linker flags through the system compiler.
4126
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4127
if test "$host_cpu" = ia64; then
4128
# AIX 5 now supports IA64 processor
4129
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4131
_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4135
mingw* | cygwin* | pw32* | os2* | cegcc*)
4136
# This hack is so that the source file can tell whether it is being
4137
# built for inclusion in a dll (and should export symbols for example).
4138
m4_if([$1], [GCJ], [],
4139
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4142
hpux9* | hpux10* | hpux11*)
4143
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4144
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4151
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4154
# Is there a better lt_prog_compiler_static that works with the bundled CC?
4155
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4158
irix5* | irix6* | nonstopux*)
4159
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4160
# PIC (with -KPIC) is the default.
4161
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4164
linux* | k*bsd*-gnu | kopensolaris*-gnu)
4165
case $cc_basename in
4166
# old Intel for x86_64 which still supported -KPIC.
4168
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4169
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4170
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4172
# icc used to be incompatible with GCC.
4173
# ICC 10 doesn't accept -KPIC any more.
4175
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4176
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4177
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4179
# Lahey Fortran 8.1.
4181
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4182
_LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
4183
_LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
4185
pgcc* | pgf77* | pgf90* | pgf95*)
4186
# Portland Group compilers (*not* the Pentium gcc compiler,
4187
# which looks to be a dead project)
4188
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4189
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4190
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4193
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4194
# All Alpha code is PIC.
4195
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4198
# IBM XL C 8.0/Fortran 10.1 on PPC
4199
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4200
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4201
_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4204
case `$CC -V 2>&1 | sed 5q` in
4207
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4208
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4209
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4212
# Sun Fortran 8.3 passes all unrecognized flags to the linker
4213
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4214
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4215
_LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4223
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4224
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4228
# QNX uses GNU C++, but need to define -shared option too, otherwise
4230
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4233
osf3* | osf4* | osf5*)
4234
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4235
# All OSF/1 code is PIC.
4236
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4240
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4244
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4245
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4246
case $cc_basename in
4248
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4250
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4255
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4256
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4257
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4260
sysv4 | sysv4.2uw2* | sysv4.3*)
4261
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4262
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4263
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4267
if test -d /usr/nec ;then
4268
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
4269
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4273
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4274
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4275
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4276
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4280
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4281
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4285
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4286
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4290
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4296
# For platforms which do not support PIC, -DPIC is meaningless:
4298
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4301
_LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4304
AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4305
_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4306
[How to pass a linker flag through the compiler])
4309
# Check to make sure the PIC flag actually works.
4311
if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4312
_LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
4313
[_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
4314
[$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
4315
[case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
4317
*) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
4319
[_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4320
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
4322
_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4323
[Additional compiler flags for building library objects])
4326
# Check to make sure the static flag actually works.
4328
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
4329
_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
4330
_LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
4331
$lt_tmp_static_flag,
4333
[_LT_TAGVAR(lt_prog_compiler_static, $1)=])
4334
_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
4335
[Compiler flag to prevent dynamic linking])
4336
])# _LT_COMPILER_PIC
4339
# _LT_LINKER_SHLIBS([TAGNAME])
4340
# ----------------------------
4341
# See if the linker supports building shared libraries.
4342
m4_defun([_LT_LINKER_SHLIBS],
4343
[AC_REQUIRE([LT_PATH_LD])dnl
4344
AC_REQUIRE([LT_PATH_NM])dnl
4345
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4346
m4_require([_LT_DECL_EGREP])dnl
4347
m4_require([_LT_DECL_SED])dnl
4348
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
4349
m4_require([_LT_TAG_COMPILER])dnl
4350
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4351
m4_if([$1], [CXX], [
4352
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4355
# If we're using GNU nm, then we don't want the "-C" option.
4356
# -C means demangle to AIX nm, but means don't demangle with GNU nm
4357
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4358
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4360
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4364
_LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4366
cygwin* | mingw* | cegcc*)
4367
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4369
linux* | k*bsd*-gnu)
4370
_LT_TAGVAR(link_all_deplibs, $1)=no
4373
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4376
_LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4379
_LT_TAGVAR(allow_undefined_flag, $1)=
4380
_LT_TAGVAR(always_export_symbols, $1)=no
4381
_LT_TAGVAR(archive_cmds, $1)=
4382
_LT_TAGVAR(archive_expsym_cmds, $1)=
4383
_LT_TAGVAR(compiler_needs_object, $1)=no
4384
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4385
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
4386
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4387
_LT_TAGVAR(hardcode_automatic, $1)=no
4388
_LT_TAGVAR(hardcode_direct, $1)=no
4389
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
4390
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4391
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4392
_LT_TAGVAR(hardcode_libdir_separator, $1)=
4393
_LT_TAGVAR(hardcode_minus_L, $1)=no
4394
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4395
_LT_TAGVAR(inherit_rpath, $1)=no
4396
_LT_TAGVAR(link_all_deplibs, $1)=unknown
4397
_LT_TAGVAR(module_cmds, $1)=
4398
_LT_TAGVAR(module_expsym_cmds, $1)=
4399
_LT_TAGVAR(old_archive_from_new_cmds, $1)=
4400
_LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
4401
_LT_TAGVAR(thread_safe_flag_spec, $1)=
4402
_LT_TAGVAR(whole_archive_flag_spec, $1)=
4403
# include_expsyms should be a list of space-separated symbols to be *always*
4404
# included in the symbol list
4405
_LT_TAGVAR(include_expsyms, $1)=
4406
# exclude_expsyms can be an extended regexp of symbols to exclude
4407
# it will be wrapped by ` (' and `)$', so one must not match beginning or
4408
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4409
# as well as any symbol that contains `d'.
4410
_LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4411
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4412
# platforms (ab)use it in PIC code, but their linkers get confused if
4413
# the symbol is explicitly referenced. Since portable code cannot
4414
# rely on this symbol name, it's probably fine to never include it in
4415
# preloaded symbol tables.
4416
# Exclude shared library initialization/finalization symbols.
4417
dnl Note also adjust exclude_expsyms for C++ above.
4418
extract_expsyms_cmds=
4421
cygwin* | mingw* | pw32* | cegcc*)
4422
# FIXME: the MSVC++ port hasn't been tested in a loooong time
4423
# When not using gcc, we currently assume that we are using
4424
# Microsoft Visual C++.
4425
if test "$GCC" != yes; then
4430
# we just hope/assume this is gcc and not c89 (= MSVC++)
4436
linux* | k*bsd*-gnu)
4437
_LT_TAGVAR(link_all_deplibs, $1)=no
4441
_LT_TAGVAR(ld_shlibs, $1)=yes
4442
if test "$with_gnu_ld" = yes; then
4443
# If archive_cmds runs LD, not CC, wlarc should be empty
4446
# Set some defaults for GNU ld with shared library support. These
4447
# are reset later if shared libraries are not supported. Putting them
4448
# here allows them to be overridden if necessary.
4449
runpath_var=LD_RUN_PATH
4450
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4451
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4452
# ancient GNU ld didn't support --whole-archive et. al.
4453
if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
4454
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4456
_LT_TAGVAR(whole_archive_flag_spec, $1)=
4458
supports_anon_versioning=no
4459
case `$LD -v 2>&1` in
4460
*GNU\ gold*) supports_anon_versioning=yes ;;
4461
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
4462
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
4463
*\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
4464
*\ 2.11.*) ;; # other 2.11 versions
4465
*) supports_anon_versioning=yes ;;
4468
# See if GNU ld supports shared libraries.
4471
# On AIX/PPC, the GNU linker is very broken
4472
if test "$host_cpu" != ia64; then
4473
_LT_TAGVAR(ld_shlibs, $1)=no
4476
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
4477
*** to be unable to reliably create shared libraries on AIX.
4478
*** Therefore, libtool is disabling shared libraries support. If you
4479
*** really care for shared libraries, you may want to modify your PATH
4480
*** so that a non-GNU linker is found, and then restart.
4489
# see comment about AmigaOS4 .so support
4490
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4491
_LT_TAGVAR(archive_expsym_cmds, $1)=''
4494
_LT_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)'
4495
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4496
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4502
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4503
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4504
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
4505
# support --undefined. This deserves some investigation. FIXME
4506
_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4508
_LT_TAGVAR(ld_shlibs, $1)=no
4512
cygwin* | mingw* | pw32* | cegcc*)
4513
# _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4514
# as there is no search path for DLLs.
4515
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4516
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4517
_LT_TAGVAR(always_export_symbols, $1)=no
4518
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4519
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
4521
if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
4522
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4523
# If the export-symbols file already is a .def file (1st line
4524
# is EXPORTS), use it as is; otherwise, prepend...
4525
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
4526
cp $export_symbols $output_objdir/$soname.def;
4528
echo EXPORTS > $output_objdir/$soname.def;
4529
cat $export_symbols >> $output_objdir/$soname.def;
4531
$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4533
_LT_TAGVAR(ld_shlibs, $1)=no
4538
_LT_TAGVAR(hardcode_direct, $1)=no
4539
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4540
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4541
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4542
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4543
# Instead, shared libraries are loaded at an image base (0x10000000 by
4544
# default) and relocated if they conflict, which is a slow very memory
4545
# consuming and fragmenting process. To avoid this, we pick a random,
4546
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4547
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
4548
_LT_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'
4549
_LT_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'
4552
gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
4554
if test "$host_os" = linux-dietlibc; then
4555
case $cc_basename in
4556
diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
4559
if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
4560
&& test "$tmp_diet" = no
4563
tmp_sharedflag='-shared'
4564
case $cc_basename,$host_cpu in
4565
pgcc*) # Portland Group C compiler
4566
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
4567
tmp_addflag=' $pic_flag'
4569
pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
4570
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
4571
tmp_addflag=' $pic_flag -Mnomain' ;;
4572
ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
4573
tmp_addflag=' -i_dynamic' ;;
4574
efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
4575
tmp_addflag=' -i_dynamic -nofor_main' ;;
4576
ifc* | ifort*) # Intel Fortran compiler
4577
tmp_addflag=' -nofor_main' ;;
4578
lf95*) # Lahey Fortran 8.1
4579
_LT_TAGVAR(whole_archive_flag_spec, $1)=
4580
tmp_sharedflag='--shared' ;;
4581
xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
4582
tmp_sharedflag='-qmkshrobj'
4585
case `$CC -V 2>&1 | sed 5q` in
4586
*Sun\ C*) # Sun C 5.9
4587
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
4588
_LT_TAGVAR(compiler_needs_object, $1)=yes
4589
tmp_sharedflag='-G' ;;
4590
*Sun\ F*) # Sun Fortran 8.3
4591
tmp_sharedflag='-G' ;;
4593
_LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4595
if test "x$supports_anon_versioning" = xyes; then
4596
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4597
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4598
echo "local: *; };" >> $output_objdir/$libname.ver~
4599
$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
4602
case $cc_basename in
4604
# IBM XL Fortran 10.1 on PPC cannot create shared libs itself
4605
_LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
4606
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4607
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
4608
_LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
4609
if test "x$supports_anon_versioning" = xyes; then
4610
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4611
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4612
echo "local: *; };" >> $output_objdir/$libname.ver~
4613
$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
4618
_LT_TAGVAR(ld_shlibs, $1)=no
4622
netbsd* | netbsdelf*-gnu)
4623
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4624
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
4627
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4628
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4633
if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
4634
_LT_TAGVAR(ld_shlibs, $1)=no
4637
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
4638
*** create shared libraries on Solaris systems. Therefore, libtool
4639
*** is disabling shared libraries support. We urge you to upgrade GNU
4640
*** binutils to release 2.9.1 or newer. Another option is to modify
4641
*** your PATH or compiler configuration so that the native linker is
4642
*** used, and then restart.
4645
elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4646
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4647
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4649
_LT_TAGVAR(ld_shlibs, $1)=no
4653
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
4654
case `$LD -v 2>&1` in
4655
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
4656
_LT_TAGVAR(ld_shlibs, $1)=no
4659
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
4660
*** reliably create shared libraries on SCO systems. Therefore, libtool
4661
*** is disabling shared libraries support. We urge you to upgrade GNU
4662
*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
4663
*** your PATH or compiler configuration so that the native linker is
4664
*** used, and then restart.
4669
# For security reasons, it is highly recommended that you always
4670
# use absolute paths for naming shared libraries, and exclude the
4671
# DT_RUNPATH tag from executables and libraries. But doing so
4672
# requires that you compile everything twice, which is a pain.
4673
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4674
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4675
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4676
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4678
_LT_TAGVAR(ld_shlibs, $1)=no
4685
_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
4687
_LT_TAGVAR(hardcode_direct, $1)=yes
4688
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4692
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4693
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4694
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4696
_LT_TAGVAR(ld_shlibs, $1)=no
4701
if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
4703
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4704
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
4705
_LT_TAGVAR(whole_archive_flag_spec, $1)=
4708
# PORTME fill in a description of your system's linker (not GNU ld)
4711
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4712
_LT_TAGVAR(always_export_symbols, $1)=yes
4713
_LT_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'
4714
# Note: this linker hardcodes the directories in LIBPATH if there
4715
# are no directories specified by -L.
4716
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4717
if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
4718
# Neither direct hardcoding nor static linking is supported with a
4720
_LT_TAGVAR(hardcode_direct, $1)=unsupported
4725
if test "$host_cpu" = ia64; then
4726
# On IA64, the linker does run time linking by default, so we don't
4727
# have to do anything special.
4728
aix_use_runtimelinking=no
4729
exp_sym_flag='-Bexport'
4732
# If we're using GNU nm, then we don't want the "-C" option.
4733
# -C means demangle to AIX nm, but means don't demangle with GNU nm
4734
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4735
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4737
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4739
aix_use_runtimelinking=no
4741
# Test if we are trying to use run time linking or normal
4742
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
4743
# need to do runtime linking.
4744
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
4745
for ld_flag in $LDFLAGS; do
4746
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
4747
aix_use_runtimelinking=yes
4754
exp_sym_flag='-bexport'
4755
no_entry_flag='-bnoentry'
4758
# When large executables or shared objects are built, AIX ld can
4759
# have problems creating the table of contents. If linking a library
4760
# or program results in "error TOC overflow" add -mminimal-toc to
4761
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
4762
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
4764
_LT_TAGVAR(archive_cmds, $1)=''
4765
_LT_TAGVAR(hardcode_direct, $1)=yes
4766
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
4767
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
4768
_LT_TAGVAR(link_all_deplibs, $1)=yes
4769
_LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
4771
if test "$GCC" = yes; then
4772
case $host_os in aix4.[[012]]|aix4.[[012]].*)
4773
# We only want to do this on AIX 4.2 and lower, the check
4774
# below for broken collect2 doesn't work under 4.3+
4775
collect2name=`${CC} -print-prog-name=collect2`
4776
if test -f "$collect2name" &&
4777
strings "$collect2name" | $GREP resolve_lib_name >/dev/null
4779
# We have reworked collect2
4782
# We have old collect2
4783
_LT_TAGVAR(hardcode_direct, $1)=unsupported
4784
# It fails to find uninstalled libraries when the uninstalled
4785
# path is not listed in the libpath. Setting hardcode_minus_L
4786
# to unsupported forces relinking
4787
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4788
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4789
_LT_TAGVAR(hardcode_libdir_separator, $1)=
4793
shared_flag='-shared'
4794
if test "$aix_use_runtimelinking" = yes; then
4795
shared_flag="$shared_flag "'${wl}-G'
4797
_LT_TAGVAR(link_all_deplibs, $1)=no
4800
if test "$host_cpu" = ia64; then
4801
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
4802
# chokes on -Wl,-G. The following line is correct:
4805
if test "$aix_use_runtimelinking" = yes; then
4806
shared_flag='${wl}-G'
4808
shared_flag='${wl}-bM:SRE'
4813
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
4814
# It seems that -bexpall does not export symbols beginning with
4815
# underscore (_), so it is better to generate a list of symbols to export.
4816
_LT_TAGVAR(always_export_symbols, $1)=yes
4817
if test "$aix_use_runtimelinking" = yes; then
4818
# Warning - without using the other runtime loading flags (-brtl),
4819
# -berok will link without error, but may produce a broken library.
4820
_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
4821
# Determine the default libpath from the value encoded in an
4823
_LT_SYS_MODULE_PATH_AIX
4824
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
4825
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
4827
if test "$host_cpu" = ia64; then
4828
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
4829
_LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
4830
_LT_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"
4832
# Determine the default libpath from the value encoded in an
4834
_LT_SYS_MODULE_PATH_AIX
4835
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
4836
# Warning - without using the other run time loading flags,
4837
# -berok will link without error, but may produce a broken library.
4838
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
4839
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
4840
# Exported symbols can be pulled into shared objects from archives
4841
_LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
4842
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
4843
# This is similar to how AIX traditionally builds its shared libraries.
4844
_LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
4852
# see comment about AmigaOS4 .so support
4853
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4854
_LT_TAGVAR(archive_expsym_cmds, $1)=''
4857
_LT_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)'
4858
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4859
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4865
_LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
4868
cygwin* | mingw* | pw32* | cegcc*)
4869
# When not using gcc, we currently assume that we are using
4870
# Microsoft Visual C++.
4871
# hardcode_libdir_flag_spec is actually meaningless, as there is
4872
# no search path for DLLs.
4873
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
4874
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4875
# Tell ltmain to make .lib files, not .a files.
4877
# Tell ltmain to make .dll files, not .so files.
4879
# FIXME: Setting linknames here is a bad hack.
4880
_LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
4881
# The linker will automatically build a .lib file if we build a DLL.
4882
_LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
4883
# FIXME: Should let the user specify the lib program.
4884
_LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
4885
_LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
4886
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4889
darwin* | rhapsody*)
4890
_LT_DARWIN_LINKER_FEATURES($1)
4894
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4895
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4896
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4900
_LT_TAGVAR(ld_shlibs, $1)=no
4903
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
4904
# support. Future versions do this automatically, but an explicit c++rt0.o
4905
# does not break anything, and helps significantly (at the cost of a little
4908
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
4909
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4910
_LT_TAGVAR(hardcode_direct, $1)=yes
4911
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4914
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
4916
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
4917
_LT_TAGVAR(hardcode_direct, $1)=yes
4918
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4919
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4922
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
4923
freebsd* | dragonfly*)
4924
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
4925
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4926
_LT_TAGVAR(hardcode_direct, $1)=yes
4927
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4931
if test "$GCC" = yes; then
4932
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4934
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4936
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4937
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
4938
_LT_TAGVAR(hardcode_direct, $1)=yes
4940
# hardcode_minus_L: Not really in the search PATH,
4941
# but as the default location of the library.
4942
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4943
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4947
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
4948
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
4950
_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
4952
if test "$with_gnu_ld" = no; then
4953
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4954
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
4955
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
4956
_LT_TAGVAR(hardcode_direct, $1)=yes
4957
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
4958
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4959
# hardcode_minus_L: Not really in the search PATH,
4960
# but as the default location of the library.
4961
_LT_TAGVAR(hardcode_minus_L, $1)=yes
4966
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
4969
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
4972
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
4975
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
4981
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
4984
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
4987
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
4991
if test "$with_gnu_ld" = no; then
4992
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4993
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
4997
_LT_TAGVAR(hardcode_direct, $1)=no
4998
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5001
_LT_TAGVAR(hardcode_direct, $1)=yes
5002
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5003
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5005
# hardcode_minus_L: Not really in the search PATH,
5006
# but as the default location of the library.
5007
_LT_TAGVAR(hardcode_minus_L, $1)=yes
5013
irix5* | irix6* | nonstopux*)
5014
if test "$GCC" = yes; then
5015
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5016
# Try to use the -exported_symbol ld option, if it does not
5017
# work, assume that -exports_file does not work either and
5018
# implicitly export all symbols.
5019
save_LDFLAGS="$LDFLAGS"
5020
LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
5021
AC_LINK_IFELSE(int foo(void) {},
5022
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
5024
LDFLAGS="$save_LDFLAGS"
5026
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
5027
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
5029
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5030
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5031
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
5032
_LT_TAGVAR(inherit_rpath, $1)=yes
5033
_LT_TAGVAR(link_all_deplibs, $1)=yes
5036
netbsd* | netbsdelf*-gnu)
5037
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5038
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
5040
_LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
5042
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5043
_LT_TAGVAR(hardcode_direct, $1)=yes
5044
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5048
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5049
_LT_TAGVAR(hardcode_direct, $1)=yes
5050
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5051
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
5052
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5059
if test -f /usr/libexec/ld.so; then
5060
_LT_TAGVAR(hardcode_direct, $1)=yes
5061
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5062
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5063
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5064
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5065
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
5066
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5067
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5070
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5071
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5072
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5075
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5076
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5081
_LT_TAGVAR(ld_shlibs, $1)=no
5086
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5087
_LT_TAGVAR(hardcode_minus_L, $1)=yes
5088
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5089
_LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
5090
_LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
5094
if test "$GCC" = yes; then
5095
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5096
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5098
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5099
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
5101
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5102
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5103
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
5106
osf4* | osf5*) # as osf3* with the addition of -msym flag
5107
if test "$GCC" = yes; then
5108
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5109
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5110
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5112
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5113
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
5114
_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
5115
$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
5117
# Both c and cxx compiler support -rpath directly
5118
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
5120
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5121
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
5125
_LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5126
if test "$GCC" = yes; then
5128
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5129
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5130
$CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5132
case `$CC -V 2>&1` in
5135
_LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
5136
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5137
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
5141
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
5142
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5143
$CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5147
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5148
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5150
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
5152
# The compiler driver will combine and reorder linker options,
5153
# but understands `-z linker_flag'. GCC discards it without `$wl',
5154
# but is careful enough not to reorder.
5155
# Supported since Solaris 2.6 (maybe 2.5.1?)
5156
if test "$GCC" = yes; then
5157
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
5159
_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
5163
_LT_TAGVAR(link_all_deplibs, $1)=yes
5167
if test "x$host_vendor" = xsequent; then
5168
# Use $CC to link under sequent, because it throws in some extra .o
5169
# files that make .init and .fini sections work.
5170
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
5172
_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
5174
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5175
_LT_TAGVAR(hardcode_direct, $1)=yes
5176
_LT_TAGVAR(hardcode_minus_L, $1)=yes
5177
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5181
case $host_vendor in
5183
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5184
_LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
5187
## LD is ld it makes a PLAMLIB
5188
## CC just makes a GrossModule.
5189
_LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
5190
_LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
5191
_LT_TAGVAR(hardcode_direct, $1)=no
5194
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5195
_LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
5198
runpath_var='LD_RUN_PATH'
5199
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5203
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5204
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5205
_LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
5209
if test -d /usr/nec; then
5210
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5211
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5212
runpath_var=LD_RUN_PATH
5213
hardcode_runpath_var=yes
5214
_LT_TAGVAR(ld_shlibs, $1)=yes
5218
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
5219
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5220
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5221
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5222
runpath_var='LD_RUN_PATH'
5224
if test "$GCC" = yes; then
5225
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5226
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5228
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5229
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5233
sysv5* | sco3.2v5* | sco5v6*)
5234
# Note: We can NOT use -z defs as we might desire, because we do not
5235
# link with -lc, and that would cause any symbols used from libc to
5236
# always be unresolved, which means just about no library would
5237
# ever link correctly. If we're not using GNU ld we use -z text
5238
# though, which does catch some bad symbols but isn't as heavy-handed
5240
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5241
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
5242
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5243
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5244
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
5245
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5246
_LT_TAGVAR(link_all_deplibs, $1)=yes
5247
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
5248
runpath_var='LD_RUN_PATH'
5250
if test "$GCC" = yes; then
5251
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5252
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5254
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5255
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5260
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5261
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5262
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5266
_LT_TAGVAR(ld_shlibs, $1)=no
5270
if test x$host_vendor = xsni; then
5272
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5273
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
5279
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
5280
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
5282
_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
5284
_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
5285
_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
5286
_LT_DECL([], [extract_expsyms_cmds], [2],
5287
[The commands to extract the exported symbol list from a shared archive])
5290
# Do we need to explicitly link libc?
5292
case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
5294
# Assume -lc should be added
5295
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5297
if test "$enable_shared" = yes && test "$GCC" = yes; then
5298
case $_LT_TAGVAR(archive_cmds, $1) in
5300
# FIXME: we may have to deal with multi-command sequences.
5303
# Test whether the compiler implicitly links with -lc since on some
5304
# systems, -lgcc has to come before -lc. If gcc already passes -lc
5305
# to ld, don't add -lc before -lgcc.
5306
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
5308
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
5310
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
5313
libobjs=conftest.$ac_objext
5315
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
5316
pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
5322
lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
5323
_LT_TAGVAR(allow_undefined_flag, $1)=
5324
if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
5326
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5328
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5330
_LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
5332
cat conftest.err 1>&5
5335
AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
5342
_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
5343
[Whether or not to add -lc for building shared libraries])
5344
_LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
5345
[enable_shared_with_static_runtimes], [0],
5346
[Whether or not to disallow shared libs when runtime libs are static])
5347
_LT_TAGDECL([], [export_dynamic_flag_spec], [1],
5348
[Compiler flag to allow reflexive dlopens])
5349
_LT_TAGDECL([], [whole_archive_flag_spec], [1],
5350
[Compiler flag to generate shared objects directly from archives])
5351
_LT_TAGDECL([], [compiler_needs_object], [1],
5352
[Whether the compiler copes with passing no objects directly])
5353
_LT_TAGDECL([], [old_archive_from_new_cmds], [2],
5354
[Create an old-style archive from a shared archive])
5355
_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
5356
[Create a temporary old-style archive to link instead of a shared archive])
5357
_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
5358
_LT_TAGDECL([], [archive_expsym_cmds], [2])
5359
_LT_TAGDECL([], [module_cmds], [2],
5360
[Commands used to build a loadable module if different from building
5362
_LT_TAGDECL([], [module_expsym_cmds], [2])
5363
_LT_TAGDECL([], [with_gnu_ld], [1],
5364
[Whether we are building with GNU ld or not])
5365
_LT_TAGDECL([], [allow_undefined_flag], [1],
5366
[Flag that allows shared libraries with undefined symbols to be built])
5367
_LT_TAGDECL([], [no_undefined_flag], [1],
5368
[Flag that enforces no undefined symbols])
5369
_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
5370
[Flag to hardcode $libdir into a binary during linking.
5371
This must work even if $libdir does not exist])
5372
_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
5373
[[If ld is used when linking, flag to hardcode $libdir into a binary
5374
during linking. This must work even if $libdir does not exist]])
5375
_LT_TAGDECL([], [hardcode_libdir_separator], [1],
5376
[Whether we need a single "-rpath" flag with a separated argument])
5377
_LT_TAGDECL([], [hardcode_direct], [0],
5378
[Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5379
DIR into the resulting binary])
5380
_LT_TAGDECL([], [hardcode_direct_absolute], [0],
5381
[Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5382
DIR into the resulting binary and the resulting library dependency is
5383
"absolute", i.e impossible to change by setting ${shlibpath_var} if the
5384
library is relocated])
5385
_LT_TAGDECL([], [hardcode_minus_L], [0],
5386
[Set to "yes" if using the -LDIR flag during linking hardcodes DIR
5387
into the resulting binary])
5388
_LT_TAGDECL([], [hardcode_shlibpath_var], [0],
5389
[Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
5390
into the resulting binary])
5391
_LT_TAGDECL([], [hardcode_automatic], [0],
5392
[Set to "yes" if building a shared library automatically hardcodes DIR
5393
into the library and all subsequent libraries and executables linked
5395
_LT_TAGDECL([], [inherit_rpath], [0],
5396
[Set to yes if linker adds runtime paths of dependent libraries
5397
to runtime path list])
5398
_LT_TAGDECL([], [link_all_deplibs], [0],
5399
[Whether libtool must link a program against all its dependency libraries])
5400
_LT_TAGDECL([], [fix_srcfile_path], [1],
5401
[Fix the shell variable $srcfile for the compiler])
5402
_LT_TAGDECL([], [always_export_symbols], [0],
5403
[Set to "yes" if exported symbols are required])
5404
_LT_TAGDECL([], [export_symbols_cmds], [2],
5405
[The commands to list exported symbols])
5406
_LT_TAGDECL([], [exclude_expsyms], [1],
5407
[Symbols that should not be listed in the preloaded symbols])
5408
_LT_TAGDECL([], [include_expsyms], [1],
5409
[Symbols that must always be exported])
5410
_LT_TAGDECL([], [prelink_cmds], [2],
5411
[Commands necessary for linking programs (against libraries) with templates])
5412
_LT_TAGDECL([], [file_list_spec], [1],
5413
[Specify filename containing input files])
5414
dnl FIXME: Not yet implemented
5415
dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
5416
dnl [Compiler flag to generate thread safe objects])
5417
])# _LT_LINKER_SHLIBS
5420
# _LT_LANG_C_CONFIG([TAG])
5421
# ------------------------
5422
# Ensure that the configuration variables for a C compiler are suitably
5423
# defined. These variables are subsequently used by _LT_CONFIG to write
5424
# the compiler configuration to `libtool'.
5425
m4_defun([_LT_LANG_C_CONFIG],
5426
[m4_require([_LT_DECL_EGREP])dnl
5430
# Source file extension for C test sources.
5433
# Object file extension for compiled C test sources.
5435
_LT_TAGVAR(objext, $1)=$objext
5437
# Code to be used in simple compile tests
5438
lt_simple_compile_test_code="int some_variable = 0;"
5440
# Code to be used in simple link tests
5441
lt_simple_link_test_code='int main(){return(0);}'
5444
# Save the default compiler, since it gets overwritten when the other
5445
# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
5446
compiler_DEFAULT=$CC
5448
# save warnings/boilerplate of simple test code
5449
_LT_COMPILER_BOILERPLATE
5450
_LT_LINKER_BOILERPLATE
5452
if test -n "$compiler"; then
5453
_LT_COMPILER_NO_RTTI($1)
5454
_LT_COMPILER_PIC($1)
5455
_LT_COMPILER_C_O($1)
5456
_LT_COMPILER_FILE_LOCKS($1)
5457
_LT_LINKER_SHLIBS($1)
5458
_LT_SYS_DYNAMIC_LINKER($1)
5459
_LT_LINKER_HARDCODE_LIBPATH($1)
5463
# Report which library types will actually be built
5464
AC_MSG_CHECKING([if libtool supports shared libraries])
5465
AC_MSG_RESULT([$can_build_shared])
5467
AC_MSG_CHECKING([whether to build shared libraries])
5468
test "$can_build_shared" = "no" && enable_shared=no
5470
# On AIX, shared libraries and static libraries use the same namespace, and
5471
# are all built from PIC.
5474
test "$enable_shared" = yes && enable_static=no
5475
if test -n "$RANLIB"; then
5476
archive_cmds="$archive_cmds~\$RANLIB \$lib"
5477
postinstall_cmds='$RANLIB $lib'
5482
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
5483
test "$enable_shared" = yes && enable_static=no
5487
AC_MSG_RESULT([$enable_shared])
5489
AC_MSG_CHECKING([whether to build static libraries])
5490
# Make sure either enable_shared or enable_static is yes.
5491
test "$enable_shared" = yes || enable_static=yes
5492
AC_MSG_RESULT([$enable_static])
5498
])# _LT_LANG_C_CONFIG
5503
# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
5504
# compiler, we have our own version here.
5505
m4_defun([_LT_PROG_CXX],
5507
pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
5509
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
5510
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
5511
(test "X$CXX" != "Xg++"))) ; then
5514
_lt_caught_CXX_error=yes
5516
popdef([AC_MSG_ERROR])
5519
dnl aclocal-1.4 backwards compatibility:
5520
dnl AC_DEFUN([_LT_PROG_CXX], [])
5523
# _LT_LANG_CXX_CONFIG([TAG])
5524
# --------------------------
5525
# Ensure that the configuration variables for a C++ compiler are suitably
5526
# defined. These variables are subsequently used by _LT_CONFIG to write
5527
# the compiler configuration to `libtool'.
5528
m4_defun([_LT_LANG_CXX_CONFIG],
5529
[AC_REQUIRE([_LT_PROG_CXX])dnl
5530
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5531
m4_require([_LT_DECL_EGREP])dnl
5534
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5535
_LT_TAGVAR(allow_undefined_flag, $1)=
5536
_LT_TAGVAR(always_export_symbols, $1)=no
5537
_LT_TAGVAR(archive_expsym_cmds, $1)=
5538
_LT_TAGVAR(compiler_needs_object, $1)=no
5539
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
5540
_LT_TAGVAR(hardcode_direct, $1)=no
5541
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
5542
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5543
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5544
_LT_TAGVAR(hardcode_libdir_separator, $1)=
5545
_LT_TAGVAR(hardcode_minus_L, $1)=no
5546
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5547
_LT_TAGVAR(hardcode_automatic, $1)=no
5548
_LT_TAGVAR(inherit_rpath, $1)=no
5549
_LT_TAGVAR(module_cmds, $1)=
5550
_LT_TAGVAR(module_expsym_cmds, $1)=
5551
_LT_TAGVAR(link_all_deplibs, $1)=unknown
5552
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5553
_LT_TAGVAR(no_undefined_flag, $1)=
5554
_LT_TAGVAR(whole_archive_flag_spec, $1)=
5555
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5557
# Source file extension for C++ test sources.
5560
# Object file extension for compiled C++ test sources.
5562
_LT_TAGVAR(objext, $1)=$objext
5564
# No sense in running all these tests if we already determined that
5565
# the CXX compiler isn't working. Some variables (like enable_shared)
5566
# are currently assumed to apply to all compilers on this platform,
5567
# and will be corrupted by setting them based on a non-working compiler.
5568
if test "$_lt_caught_CXX_error" != yes; then
5569
# Code to be used in simple compile tests
5570
lt_simple_compile_test_code="int some_variable = 0;"
5572
# Code to be used in simple link tests
5573
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
5575
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
5578
# save warnings/boilerplate of simple test code
5579
_LT_COMPILER_BOILERPLATE
5580
_LT_LINKER_BOILERPLATE
5582
# Allow CC to be a program name with arguments.
5587
lt_save_with_gnu_ld=$with_gnu_ld
5588
lt_save_path_LD=$lt_cv_path_LD
5589
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
5590
lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
5592
$as_unset lt_cv_prog_gnu_ld
5594
if test -n "${lt_cv_path_LDCXX+set}"; then
5595
lt_cv_path_LD=$lt_cv_path_LDCXX
5597
$as_unset lt_cv_path_LD
5599
test -z "${LDCXX+set}" || LD=$LDCXX
5602
_LT_TAGVAR(compiler, $1)=$CC
5603
_LT_CC_BASENAME([$compiler])
5605
if test -n "$compiler"; then
5606
# We don't want -fno-exception when compiling C++ code, so set the
5607
# no_builtin_flag separately
5608
if test "$GXX" = yes; then
5609
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5611
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5614
if test "$GXX" = yes; then
5615
# Set up default GNU C++ configuration
5619
# Check if GNU C++ uses GNU ld as the underlying linker, since the
5620
# archiving commands below assume that GNU ld is being used.
5621
if test "$with_gnu_ld" = yes; then
5622
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
5623
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5625
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5626
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5628
# If archive_cmds runs LD, not CC, wlarc should be empty
5629
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
5630
# investigate it a little bit more. (MM)
5633
# ancient GNU ld didn't support --whole-archive et. al.
5634
if eval "`$CC -print-prog-name=ld` --help 2>&1" |
5635
$GREP 'no-whole-archive' > /dev/null; then
5636
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5638
_LT_TAGVAR(whole_archive_flag_spec, $1)=
5644
# A generic and very simple default shared library creation
5645
# command for GNU C++ for the case where it uses the native
5646
# linker, instead of GNU ld. If possible, this setting should
5647
# overridden to take advantage of the native linker features on
5648
# the platform it is being used on.
5649
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
5652
# Commands to make compiler produce verbose output that lists
5653
# what "hidden" libraries, object files and flags are used when
5654
# linking a shared library.
5655
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
5663
# PORTME: fill in a description of your system's C++ link characteristics
5664
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5665
_LT_TAGVAR(ld_shlibs, $1)=yes
5668
# FIXME: insert proper C++ library support
5669
_LT_TAGVAR(ld_shlibs, $1)=no
5672
if test "$host_cpu" = ia64; then
5673
# On IA64, the linker does run time linking by default, so we don't
5674
# have to do anything special.
5675
aix_use_runtimelinking=no
5676
exp_sym_flag='-Bexport'
5679
aix_use_runtimelinking=no
5681
# Test if we are trying to use run time linking or normal
5682
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
5683
# need to do runtime linking.
5684
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5685
for ld_flag in $LDFLAGS; do
5688
aix_use_runtimelinking=yes
5696
exp_sym_flag='-bexport'
5697
no_entry_flag='-bnoentry'
5700
# When large executables or shared objects are built, AIX ld can
5701
# have problems creating the table of contents. If linking a library
5702
# or program results in "error TOC overflow" add -mminimal-toc to
5703
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5704
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5706
_LT_TAGVAR(archive_cmds, $1)=''
5707
_LT_TAGVAR(hardcode_direct, $1)=yes
5708
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5709
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5710
_LT_TAGVAR(link_all_deplibs, $1)=yes
5711
_LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5713
if test "$GXX" = yes; then
5714
case $host_os in aix4.[[012]]|aix4.[[012]].*)
5715
# We only want to do this on AIX 4.2 and lower, the check
5716
# below for broken collect2 doesn't work under 4.3+
5717
collect2name=`${CC} -print-prog-name=collect2`
5718
if test -f "$collect2name" &&
5719
strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5721
# We have reworked collect2
5724
# We have old collect2
5725
_LT_TAGVAR(hardcode_direct, $1)=unsupported
5726
# It fails to find uninstalled libraries when the uninstalled
5727
# path is not listed in the libpath. Setting hardcode_minus_L
5728
# to unsupported forces relinking
5729
_LT_TAGVAR(hardcode_minus_L, $1)=yes
5730
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5731
_LT_TAGVAR(hardcode_libdir_separator, $1)=
5734
shared_flag='-shared'
5735
if test "$aix_use_runtimelinking" = yes; then
5736
shared_flag="$shared_flag "'${wl}-G'
5740
if test "$host_cpu" = ia64; then
5741
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5742
# chokes on -Wl,-G. The following line is correct:
5745
if test "$aix_use_runtimelinking" = yes; then
5746
shared_flag='${wl}-G'
5748
shared_flag='${wl}-bM:SRE'
5753
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
5754
# It seems that -bexpall does not export symbols beginning with
5755
# underscore (_), so it is better to generate a list of symbols to
5757
_LT_TAGVAR(always_export_symbols, $1)=yes
5758
if test "$aix_use_runtimelinking" = yes; then
5759
# Warning - without using the other runtime loading flags (-brtl),
5760
# -berok will link without error, but may produce a broken library.
5761
_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5762
# Determine the default libpath from the value encoded in an empty
5764
_LT_SYS_MODULE_PATH_AIX
5765
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5767
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5769
if test "$host_cpu" = ia64; then
5770
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5771
_LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5772
_LT_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"
5774
# Determine the default libpath from the value encoded in an
5776
_LT_SYS_MODULE_PATH_AIX
5777
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5778
# Warning - without using the other run time loading flags,
5779
# -berok will link without error, but may produce a broken library.
5780
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5781
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5782
# Exported symbols can be pulled into shared objects from archives
5783
_LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5784
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5785
# This is similar to how AIX traditionally builds its shared
5787
_LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
5793
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5794
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5795
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5796
# support --undefined. This deserves some investigation. FIXME
5797
_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5799
_LT_TAGVAR(ld_shlibs, $1)=no
5804
case $cc_basename in
5806
# FIXME: insert proper C++ library support
5807
_LT_TAGVAR(ld_shlibs, $1)=no
5812
cygwin* | mingw* | pw32* | cegcc*)
5813
# _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5814
# as there is no search path for DLLs.
5815
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5816
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5817
_LT_TAGVAR(always_export_symbols, $1)=no
5818
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5820
if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5821
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5822
# If the export-symbols file already is a .def file (1st line
5823
# is EXPORTS), use it as is; otherwise, prepend...
5824
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5825
cp $export_symbols $output_objdir/$soname.def;
5827
echo EXPORTS > $output_objdir/$soname.def;
5828
cat $export_symbols >> $output_objdir/$soname.def;
5830
$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'
5832
_LT_TAGVAR(ld_shlibs, $1)=no
5835
darwin* | rhapsody*)
5836
_LT_DARWIN_LINKER_FEATURES($1)
5840
case $cc_basename in
5842
# FIXME: insert proper C++ library support
5843
_LT_TAGVAR(ld_shlibs, $1)=no
5846
# Green Hills C++ Compiler
5847
# FIXME: insert proper C++ library support
5848
_LT_TAGVAR(ld_shlibs, $1)=no
5851
# FIXME: insert proper C++ library support
5852
_LT_TAGVAR(ld_shlibs, $1)=no
5858
# C++ shared libraries reported to be fairly broken before
5860
_LT_TAGVAR(ld_shlibs, $1)=no
5864
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5867
freebsd* | dragonfly*)
5868
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
5870
_LT_TAGVAR(ld_shlibs, $1)=yes
5877
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5878
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
5879
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5880
_LT_TAGVAR(hardcode_direct, $1)=yes
5881
_LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
5882
# but as the default
5883
# location of the library.
5885
case $cc_basename in
5887
# FIXME: insert proper C++ library support
5888
_LT_TAGVAR(ld_shlibs, $1)=no
5891
_LT_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'
5892
# Commands to make compiler produce verbose output that lists
5893
# what "hidden" libraries, object files and flags are used when
5894
# linking a shared library.
5896
# There doesn't appear to be a way to prevent this compiler from
5897
# explicitly linking system object files so we need to strip them
5898
# from the output so that they don't get included in the library
5900
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
5903
if test "$GXX" = yes; then
5904
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5906
# FIXME: insert proper C++ library support
5907
_LT_TAGVAR(ld_shlibs, $1)=no
5914
if test $with_gnu_ld = no; then
5915
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5916
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
5922
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5928
_LT_TAGVAR(hardcode_direct, $1)=no
5929
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5932
_LT_TAGVAR(hardcode_direct, $1)=yes
5933
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5934
_LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
5935
# but as the default
5936
# location of the library.
5940
case $cc_basename in
5942
# FIXME: insert proper C++ library support
5943
_LT_TAGVAR(ld_shlibs, $1)=no
5948
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5951
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5954
_LT_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'
5957
# Commands to make compiler produce verbose output that lists
5958
# what "hidden" libraries, object files and flags are used when
5959
# linking a shared library.
5961
# There doesn't appear to be a way to prevent this compiler from
5962
# explicitly linking system object files so we need to strip them
5963
# from the output so that they don't get included in the library
5965
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
5968
if test "$GXX" = yes; then
5969
if test $with_gnu_ld = no; then
5972
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5975
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5978
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
5983
# FIXME: insert proper C++ library support
5984
_LT_TAGVAR(ld_shlibs, $1)=no
5991
_LT_TAGVAR(hardcode_direct, $1)=no
5992
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5993
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5994
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5995
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5996
# Instead, shared libraries are loaded at an image base (0x10000000 by
5997
# default) and relocated if they conflict, which is a slow very memory
5998
# consuming and fragmenting process. To avoid this, we pick a random,
5999
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6000
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
6001
_LT_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'
6002
_LT_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'
6005
case $cc_basename in
6008
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6010
# Archives containing C++ object files must be created using
6011
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
6012
# necessary to make sure instantiated templates are included
6014
_LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
6017
if test "$GXX" = yes; then
6018
if test "$with_gnu_ld" = no; then
6019
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6021
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
6024
_LT_TAGVAR(link_all_deplibs, $1)=yes
6027
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6028
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
6029
_LT_TAGVAR(inherit_rpath, $1)=yes
6032
linux* | k*bsd*-gnu | kopensolaris*-gnu)
6033
case $cc_basename in
6035
# Kuck and Associates, Inc. (KAI) C++ Compiler
6037
# KCC will only create a shared library if the output file
6038
# ends with ".so" (or ".sl" for HP-UX), so rename the library
6039
# to its proper name (with version) after linking.
6040
_LT_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'
6041
_LT_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'
6042
# Commands to make compiler produce verbose output that lists
6043
# what "hidden" libraries, object files and flags are used when
6044
# linking a shared library.
6046
# There doesn't appear to be a way to prevent this compiler from
6047
# explicitly linking system object files so we need to strip them
6048
# from the output so that they don't get included in the library
6050
output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6052
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6053
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6055
# Archives containing C++ object files must be created using
6056
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
6057
_LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
6062
# version 8.0 and above of icpc choke on multiply defined symbols
6063
# if we add $predep_objects and $postdep_objects, however 7.1 and
6064
# earlier do not add the objects themselves.
6065
case `$CC -V 2>&1` in
6067
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6068
_LT_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'
6070
*) # Version 8.0 or newer
6073
ia64*) tmp_idyn=' -i_dynamic';;
6075
_LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6076
_LT_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'
6079
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6080
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6081
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6082
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6085
# Portland Group C++ compiler
6087
*pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*)
6088
_LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
6090
$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6091
compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
6092
_LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
6094
$CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6095
$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
6097
_LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6099
$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6100
$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6101
_LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6103
$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6104
$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6106
*) # Version 6 will use weak symbols
6107
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6108
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6112
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6113
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6114
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6118
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6119
_LT_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'
6121
runpath_var=LD_RUN_PATH
6122
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6123
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
6125
# Commands to make compiler produce verbose output that lists
6126
# what "hidden" libraries, object files and flags are used when
6127
# linking a shared library.
6129
# There doesn't appear to be a way to prevent this compiler from
6130
# explicitly linking system object files so we need to strip them
6131
# from the output so that they don't get included in the library
6133
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6136
# IBM XL 8.0 on PPC, with GNU ld
6137
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6138
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6139
_LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6140
if test "x$supports_anon_versioning" = xyes; then
6141
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6142
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6143
echo "local: *; };" >> $output_objdir/$libname.ver~
6144
$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6148
case `$CC -V 2>&1 | sed 5q` in
6151
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6152
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6153
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
6154
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6155
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6156
_LT_TAGVAR(compiler_needs_object, $1)=yes
6158
# Not sure whether something based on
6159
# $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
6161
output_verbose_link_cmd='echo'
6163
# Archives containing C++ object files must be created using
6164
# "CC -xar", where "CC" is the Sun C++ compiler. This is
6165
# necessary to make sure instantiated templates are included
6167
_LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6175
# FIXME: insert proper C++ library support
6176
_LT_TAGVAR(ld_shlibs, $1)=no
6180
# FIXME: insert proper C++ library support
6181
_LT_TAGVAR(ld_shlibs, $1)=no
6185
case $cc_basename in
6187
# FIXME: insert proper C++ library support
6188
_LT_TAGVAR(ld_shlibs, $1)=no
6191
# FIXME: insert proper C++ library support
6192
_LT_TAGVAR(ld_shlibs, $1)=no
6198
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6199
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
6201
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6202
_LT_TAGVAR(hardcode_direct, $1)=yes
6203
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6205
# Workaround some broken pre-1.5 toolchains
6206
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
6210
_LT_TAGVAR(ld_shlibs, $1)=yes
6214
# C++ shared libraries are fairly broken
6215
_LT_TAGVAR(ld_shlibs, $1)=no
6219
if test -f /usr/libexec/ld.so; then
6220
_LT_TAGVAR(hardcode_direct, $1)=yes
6221
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6222
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6223
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6224
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6225
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6226
_LT_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'
6227
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6228
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6230
output_verbose_link_cmd=echo
6232
_LT_TAGVAR(ld_shlibs, $1)=no
6236
osf3* | osf4* | osf5*)
6237
case $cc_basename in
6239
# Kuck and Associates, Inc. (KAI) C++ Compiler
6241
# KCC will only create a shared library if the output file
6242
# ends with ".so" (or ".sl" for HP-UX), so rename the library
6243
# to its proper name (with version) after linking.
6244
_LT_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'
6246
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6247
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
6249
# Archives containing C++ object files must be created using
6250
# the KAI C++ compiler.
6252
osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
6253
*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
6257
# Rational C++ 2.4.1
6258
# FIXME: insert proper C++ library support
6259
_LT_TAGVAR(ld_shlibs, $1)=no
6264
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6265
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6266
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6269
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6270
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6271
_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
6272
echo "-hidden">> $lib.exp~
6273
$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
6275
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6279
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
6281
# Commands to make compiler produce verbose output that lists
6282
# what "hidden" libraries, object files and flags are used when
6283
# linking a shared library.
6285
# There doesn't appear to be a way to prevent this compiler from
6286
# explicitly linking system object files so we need to strip them
6287
# from the output so that they don't get included in the library
6289
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6292
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6293
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6296
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6299
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6303
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6304
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
6306
# Commands to make compiler produce verbose output that lists
6307
# what "hidden" libraries, object files and flags are used when
6308
# linking a shared library.
6309
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6312
# FIXME: insert proper C++ library support
6313
_LT_TAGVAR(ld_shlibs, $1)=no
6320
# FIXME: insert proper C++ library support
6321
_LT_TAGVAR(ld_shlibs, $1)=no
6325
case $cc_basename in
6328
# FIXME: insert proper C++ library support
6329
_LT_TAGVAR(ld_shlibs, $1)=no
6333
# FIXME: insert proper C++ library support
6334
_LT_TAGVAR(ld_shlibs, $1)=no
6337
# FIXME: insert proper C++ library support
6338
_LT_TAGVAR(ld_shlibs, $1)=no
6344
case $cc_basename in
6346
# Sun C++ 4.2, 5.x and Centerline C++
6347
_LT_TAGVAR(archive_cmds_need_lc,$1)=yes
6348
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6349
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6350
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6351
$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'
6353
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6354
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6356
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6358
# The compiler driver will combine and reorder linker options,
6359
# but understands `-z linker_flag'.
6360
# Supported since Solaris 2.6 (maybe 2.5.1?)
6361
_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6364
_LT_TAGVAR(link_all_deplibs, $1)=yes
6366
output_verbose_link_cmd='echo'
6368
# Archives containing C++ object files must be created using
6369
# "CC -xar", where "CC" is the Sun C++ compiler. This is
6370
# necessary to make sure instantiated templates are included
6372
_LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6375
# Green Hills C++ Compiler
6376
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6378
# The C++ compiler must be used to create the archive.
6379
_LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
6382
# GNU C++ compiler with Solaris linker
6383
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6384
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
6385
if $CC --version | $GREP -v '^2\.7' > /dev/null; then
6386
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6387
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6388
$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6390
# Commands to make compiler produce verbose output that lists
6391
# what "hidden" libraries, object files and flags are used when
6392
# linking a shared library.
6393
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6395
# g++ 2.7 appears to require `-G' NOT `-shared' on this
6397
_LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6398
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6399
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6401
# Commands to make compiler produce verbose output that lists
6402
# what "hidden" libraries, object files and flags are used when
6403
# linking a shared library.
6404
output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6407
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
6409
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6411
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6419
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6420
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6421
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6422
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6423
runpath_var='LD_RUN_PATH'
6425
case $cc_basename in
6427
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6428
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6431
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6432
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6437
sysv5* | sco3.2v5* | sco5v6*)
6438
# Note: We can NOT use -z defs as we might desire, because we do not
6439
# link with -lc, and that would cause any symbols used from libc to
6440
# always be unresolved, which means just about no library would
6441
# ever link correctly. If we're not using GNU ld we use -z text
6442
# though, which does catch some bad symbols but isn't as heavy-handed
6444
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6445
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6446
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6447
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6448
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6449
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6450
_LT_TAGVAR(link_all_deplibs, $1)=yes
6451
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6452
runpath_var='LD_RUN_PATH'
6454
case $cc_basename in
6456
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6457
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6460
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6461
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6467
case $cc_basename in
6469
# NonStop-UX NCC 3.20
6470
# FIXME: insert proper C++ library support
6471
_LT_TAGVAR(ld_shlibs, $1)=no
6474
# FIXME: insert proper C++ library support
6475
_LT_TAGVAR(ld_shlibs, $1)=no
6481
# FIXME: insert proper C++ library support
6482
_LT_TAGVAR(ld_shlibs, $1)=no
6486
# FIXME: insert proper C++ library support
6487
_LT_TAGVAR(ld_shlibs, $1)=no
6491
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6492
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6494
_LT_TAGVAR(GCC, $1)="$GXX"
6495
_LT_TAGVAR(LD, $1)="$LD"
6498
## There is no encapsulation within the following macros, do not change
6499
## the running order or otherwise move them around unless you know exactly
6500
## what you are doing...
6501
_LT_SYS_HIDDEN_LIBDEPS($1)
6502
_LT_COMPILER_PIC($1)
6503
_LT_COMPILER_C_O($1)
6504
_LT_COMPILER_FILE_LOCKS($1)
6505
_LT_LINKER_SHLIBS($1)
6506
_LT_SYS_DYNAMIC_LINKER($1)
6507
_LT_LINKER_HARDCODE_LIBPATH($1)
6510
fi # test -n "$compiler"
6516
with_gnu_ld=$lt_save_with_gnu_ld
6517
lt_cv_path_LDCXX=$lt_cv_path_LD
6518
lt_cv_path_LD=$lt_save_path_LD
6519
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
6520
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
6521
fi # test "$_lt_caught_CXX_error" != yes
6524
])# _LT_LANG_CXX_CONFIG
6527
# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
6528
# ---------------------------------
6529
# Figure out "hidden" library dependencies from verbose
6530
# compiler output when linking a shared library.
6531
# Parse the compiler output and extract the necessary
6532
# objects, libraries and library flags.
6533
m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
6534
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6535
# Dependencies to place before and after the object being linked:
6536
_LT_TAGVAR(predep_objects, $1)=
6537
_LT_TAGVAR(postdep_objects, $1)=
6538
_LT_TAGVAR(predeps, $1)=
6539
_LT_TAGVAR(postdeps, $1)=
6540
_LT_TAGVAR(compiler_lib_search_path, $1)=
6542
dnl we can't use the lt_simple_compile_test_code here,
6543
dnl because it contains code intended for an executable,
6544
dnl not a library. It's possible we should let each
6545
dnl tag define a new lt_????_link_test_code variable,
6546
dnl but it's only used here...
6547
m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
6549
void foo (void) { a = 0; }
6551
], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
6555
Foo (void) { a = 0; }
6560
], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
6568
], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
6576
], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
6579
public void bar (void) {
6585
dnl Parse the compiler output and extract the necessary
6586
dnl objects, libraries and library flags.
6587
if AC_TRY_EVAL(ac_compile); then
6588
# Parse the compiler output and extract the necessary
6589
# objects, libraries and library flags.
6591
# Sentinel used to keep track of whether or not we are before
6592
# the conftest object file.
6593
pre_test_object_deps_done=no
6595
for p in `eval "$output_verbose_link_cmd"`; do
6599
# Some compilers place space between "-{L,R}" and the path.
6601
if test $p = "-L" ||
6602
test $p = "-R"; then
6609
if test "$pre_test_object_deps_done" = no; then
6612
# Internal compiler library paths should come after those
6613
# provided the user. The postdeps already come after the
6614
# user supplied libs so there is no need to process them.
6615
if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
6616
_LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
6618
_LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
6621
# The "-l" case would never come before the object being
6622
# linked, so don't bother handling this case.
6625
if test -z "$_LT_TAGVAR(postdeps, $1)"; then
6626
_LT_TAGVAR(postdeps, $1)="${prev}${p}"
6628
_LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
6634
# This assumes that the test object file only shows up
6635
# once in the compiler output.
6636
if test "$p" = "conftest.$objext"; then
6637
pre_test_object_deps_done=yes
6641
if test "$pre_test_object_deps_done" = no; then
6642
if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
6643
_LT_TAGVAR(predep_objects, $1)="$p"
6645
_LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
6648
if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
6649
_LT_TAGVAR(postdep_objects, $1)="$p"
6651
_LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
6656
*) ;; # Ignore the rest.
6664
echo "libtool.m4: error: problem compiling $1 test program"
6667
$RM -f confest.$objext
6669
# PORTME: override above test on systems where it is broken
6673
# Interix 3.5 installs completely hosed .la files for C++, so rather than
6674
# hack all around it, let's just trust "g++" to DTRT.
6675
_LT_TAGVAR(predep_objects,$1)=
6676
_LT_TAGVAR(postdep_objects,$1)=
6677
_LT_TAGVAR(postdeps,$1)=
6681
case `$CC -V 2>&1 | sed 5q` in
6685
# The more standards-conforming stlport4 library is
6686
# incompatible with the Cstd library. Avoid specifying
6687
# it if it's in CXXFLAGS. Ignore libCrun as
6688
# -library=stlport4 depends on it.
6689
case " $CXX $CXXFLAGS " in
6690
*" -library=stlport4 "*)
6691
solaris_use_stlport4=yes
6695
if test "$solaris_use_stlport4" != yes; then
6696
_LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
6703
case $cc_basename in
6705
# The more standards-conforming stlport4 library is
6706
# incompatible with the Cstd library. Avoid specifying
6707
# it if it's in CXXFLAGS. Ignore libCrun as
6708
# -library=stlport4 depends on it.
6709
case " $CXX $CXXFLAGS " in
6710
*" -library=stlport4 "*)
6711
solaris_use_stlport4=yes
6715
# Adding this requires a known-good setup of shared libraries for
6716
# Sun compiler versions before 5.6, else PIC objects from an old
6717
# archive will be linked into the output, leading to subtle bugs.
6718
if test "$solaris_use_stlport4" != yes; then
6719
_LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
6727
case " $_LT_TAGVAR(postdeps, $1) " in
6728
*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
6730
_LT_TAGVAR(compiler_lib_search_dirs, $1)=
6731
if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
6732
_LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
6734
_LT_TAGDECL([], [compiler_lib_search_dirs], [1],
6735
[The directories searched by this compiler when creating a shared library])
6736
_LT_TAGDECL([], [predep_objects], [1],
6737
[Dependencies to place before and after the objects being linked to
6738
create a shared library])
6739
_LT_TAGDECL([], [postdep_objects], [1])
6740
_LT_TAGDECL([], [predeps], [1])
6741
_LT_TAGDECL([], [postdeps], [1])
6742
_LT_TAGDECL([], [compiler_lib_search_path], [1],
6743
[The library search path used internally by the compiler when linking
6745
])# _LT_SYS_HIDDEN_LIBDEPS
6750
# Since AC_PROG_F77 is broken, in that it returns the empty string
6751
# if there is no fortran compiler, we have our own version here.
6752
m4_defun([_LT_PROG_F77],
6754
pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
6756
if test -z "$F77" || test "X$F77" = "Xno"; then
6759
popdef([AC_MSG_ERROR])
6762
dnl aclocal-1.4 backwards compatibility:
6763
dnl AC_DEFUN([_LT_PROG_F77], [])
6766
# _LT_LANG_F77_CONFIG([TAG])
6767
# --------------------------
6768
# Ensure that the configuration variables for a Fortran 77 compiler are
6769
# suitably defined. These variables are subsequently used by _LT_CONFIG
6770
# to write the compiler configuration to `libtool'.
6771
m4_defun([_LT_LANG_F77_CONFIG],
6772
[AC_REQUIRE([_LT_PROG_F77])dnl
6773
AC_LANG_PUSH(Fortran 77)
6775
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6776
_LT_TAGVAR(allow_undefined_flag, $1)=
6777
_LT_TAGVAR(always_export_symbols, $1)=no
6778
_LT_TAGVAR(archive_expsym_cmds, $1)=
6779
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
6780
_LT_TAGVAR(hardcode_direct, $1)=no
6781
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
6782
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6783
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6784
_LT_TAGVAR(hardcode_libdir_separator, $1)=
6785
_LT_TAGVAR(hardcode_minus_L, $1)=no
6786
_LT_TAGVAR(hardcode_automatic, $1)=no
6787
_LT_TAGVAR(inherit_rpath, $1)=no
6788
_LT_TAGVAR(module_cmds, $1)=
6789
_LT_TAGVAR(module_expsym_cmds, $1)=
6790
_LT_TAGVAR(link_all_deplibs, $1)=unknown
6791
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
6792
_LT_TAGVAR(no_undefined_flag, $1)=
6793
_LT_TAGVAR(whole_archive_flag_spec, $1)=
6794
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6796
# Source file extension for f77 test sources.
6799
# Object file extension for compiled f77 test sources.
6801
_LT_TAGVAR(objext, $1)=$objext
6803
# No sense in running all these tests if we already determined that
6804
# the F77 compiler isn't working. Some variables (like enable_shared)
6805
# are currently assumed to apply to all compilers on this platform,
6806
# and will be corrupted by setting them based on a non-working compiler.
6807
if test "$_lt_disable_F77" != yes; then
6808
# Code to be used in simple compile tests
6809
lt_simple_compile_test_code="\
6815
# Code to be used in simple link tests
6816
lt_simple_link_test_code="\
6821
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
6824
# save warnings/boilerplate of simple test code
6825
_LT_COMPILER_BOILERPLATE
6826
_LT_LINKER_BOILERPLATE
6828
# Allow CC to be a program name with arguments.
6833
_LT_TAGVAR(compiler, $1)=$CC
6834
_LT_CC_BASENAME([$compiler])
6836
if test -n "$compiler"; then
6837
AC_MSG_CHECKING([if libtool supports shared libraries])
6838
AC_MSG_RESULT([$can_build_shared])
6840
AC_MSG_CHECKING([whether to build shared libraries])
6841
test "$can_build_shared" = "no" && enable_shared=no
6843
# On AIX, shared libraries and static libraries use the same namespace, and
6844
# are all built from PIC.
6847
test "$enable_shared" = yes && enable_static=no
6848
if test -n "$RANLIB"; then
6849
archive_cmds="$archive_cmds~\$RANLIB \$lib"
6850
postinstall_cmds='$RANLIB $lib'
6854
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
6855
test "$enable_shared" = yes && enable_static=no
6859
AC_MSG_RESULT([$enable_shared])
6861
AC_MSG_CHECKING([whether to build static libraries])
6862
# Make sure either enable_shared or enable_static is yes.
6863
test "$enable_shared" = yes || enable_static=yes
6864
AC_MSG_RESULT([$enable_static])
6866
_LT_TAGVAR(GCC, $1)="$G77"
6867
_LT_TAGVAR(LD, $1)="$LD"
6870
## There is no encapsulation within the following macros, do not change
6871
## the running order or otherwise move them around unless you know exactly
6872
## what you are doing...
6873
_LT_COMPILER_PIC($1)
6874
_LT_COMPILER_C_O($1)
6875
_LT_COMPILER_FILE_LOCKS($1)
6876
_LT_LINKER_SHLIBS($1)
6877
_LT_SYS_DYNAMIC_LINKER($1)
6878
_LT_LINKER_HARDCODE_LIBPATH($1)
6881
fi # test -n "$compiler"
6885
fi # test "$_lt_disable_F77" != yes
6888
])# _LT_LANG_F77_CONFIG
6893
# Since AC_PROG_FC is broken, in that it returns the empty string
6894
# if there is no fortran compiler, we have our own version here.
6895
m4_defun([_LT_PROG_FC],
6897
pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
6899
if test -z "$FC" || test "X$FC" = "Xno"; then
6902
popdef([AC_MSG_ERROR])
6905
dnl aclocal-1.4 backwards compatibility:
6906
dnl AC_DEFUN([_LT_PROG_FC], [])
6909
# _LT_LANG_FC_CONFIG([TAG])
6910
# -------------------------
6911
# Ensure that the configuration variables for a Fortran compiler are
6912
# suitably defined. These variables are subsequently used by _LT_CONFIG
6913
# to write the compiler configuration to `libtool'.
6914
m4_defun([_LT_LANG_FC_CONFIG],
6915
[AC_REQUIRE([_LT_PROG_FC])dnl
6916
AC_LANG_PUSH(Fortran)
6918
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6919
_LT_TAGVAR(allow_undefined_flag, $1)=
6920
_LT_TAGVAR(always_export_symbols, $1)=no
6921
_LT_TAGVAR(archive_expsym_cmds, $1)=
6922
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
6923
_LT_TAGVAR(hardcode_direct, $1)=no
6924
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
6925
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6926
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6927
_LT_TAGVAR(hardcode_libdir_separator, $1)=
6928
_LT_TAGVAR(hardcode_minus_L, $1)=no
6929
_LT_TAGVAR(hardcode_automatic, $1)=no
6930
_LT_TAGVAR(inherit_rpath, $1)=no
6931
_LT_TAGVAR(module_cmds, $1)=
6932
_LT_TAGVAR(module_expsym_cmds, $1)=
6933
_LT_TAGVAR(link_all_deplibs, $1)=unknown
6934
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
6935
_LT_TAGVAR(no_undefined_flag, $1)=
6936
_LT_TAGVAR(whole_archive_flag_spec, $1)=
6937
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6939
# Source file extension for fc test sources.
6940
ac_ext=${ac_fc_srcext-f}
6942
# Object file extension for compiled fc test sources.
6944
_LT_TAGVAR(objext, $1)=$objext
6946
# No sense in running all these tests if we already determined that
6947
# the FC compiler isn't working. Some variables (like enable_shared)
6948
# are currently assumed to apply to all compilers on this platform,
6949
# and will be corrupted by setting them based on a non-working compiler.
6950
if test "$_lt_disable_FC" != yes; then
6951
# Code to be used in simple compile tests
6952
lt_simple_compile_test_code="\
6958
# Code to be used in simple link tests
6959
lt_simple_link_test_code="\
6964
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
6967
# save warnings/boilerplate of simple test code
6968
_LT_COMPILER_BOILERPLATE
6969
_LT_LINKER_BOILERPLATE
6971
# Allow CC to be a program name with arguments.
6976
GCC=$ac_cv_fc_compiler_gnu
6978
_LT_TAGVAR(compiler, $1)=$CC
6979
_LT_CC_BASENAME([$compiler])
6981
if test -n "$compiler"; then
6982
AC_MSG_CHECKING([if libtool supports shared libraries])
6983
AC_MSG_RESULT([$can_build_shared])
6985
AC_MSG_CHECKING([whether to build shared libraries])
6986
test "$can_build_shared" = "no" && enable_shared=no
6988
# On AIX, shared libraries and static libraries use the same namespace, and
6989
# are all built from PIC.
6992
test "$enable_shared" = yes && enable_static=no
6993
if test -n "$RANLIB"; then
6994
archive_cmds="$archive_cmds~\$RANLIB \$lib"
6995
postinstall_cmds='$RANLIB $lib'
6999
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7000
test "$enable_shared" = yes && enable_static=no
7004
AC_MSG_RESULT([$enable_shared])
7006
AC_MSG_CHECKING([whether to build static libraries])
7007
# Make sure either enable_shared or enable_static is yes.
7008
test "$enable_shared" = yes || enable_static=yes
7009
AC_MSG_RESULT([$enable_static])
7011
_LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
7012
_LT_TAGVAR(LD, $1)="$LD"
7015
## There is no encapsulation within the following macros, do not change
7016
## the running order or otherwise move them around unless you know exactly
7017
## what you are doing...
7018
_LT_SYS_HIDDEN_LIBDEPS($1)
7019
_LT_COMPILER_PIC($1)
7020
_LT_COMPILER_C_O($1)
7021
_LT_COMPILER_FILE_LOCKS($1)
7022
_LT_LINKER_SHLIBS($1)
7023
_LT_SYS_DYNAMIC_LINKER($1)
7024
_LT_LINKER_HARDCODE_LIBPATH($1)
7027
fi # test -n "$compiler"
7031
fi # test "$_lt_disable_FC" != yes
7034
])# _LT_LANG_FC_CONFIG
7037
# _LT_LANG_GCJ_CONFIG([TAG])
7038
# --------------------------
7039
# Ensure that the configuration variables for the GNU Java Compiler compiler
7040
# are suitably defined. These variables are subsequently used by _LT_CONFIG
7041
# to write the compiler configuration to `libtool'.
7042
m4_defun([_LT_LANG_GCJ_CONFIG],
7043
[AC_REQUIRE([LT_PROG_GCJ])dnl
7046
# Source file extension for Java test sources.
7049
# Object file extension for compiled Java test sources.
7051
_LT_TAGVAR(objext, $1)=$objext
7053
# Code to be used in simple compile tests
7054
lt_simple_compile_test_code="class foo {}"
7056
# Code to be used in simple link tests
7057
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
7059
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
7062
# save warnings/boilerplate of simple test code
7063
_LT_COMPILER_BOILERPLATE
7064
_LT_LINKER_BOILERPLATE
7066
# Allow CC to be a program name with arguments.
7072
_LT_TAGVAR(compiler, $1)=$CC
7073
_LT_TAGVAR(LD, $1)="$LD"
7074
_LT_CC_BASENAME([$compiler])
7076
# GCJ did not exist at the time GCC didn't implicitly link libc in.
7077
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
7079
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7081
if test -n "$compiler"; then
7082
_LT_COMPILER_NO_RTTI($1)
7083
_LT_COMPILER_PIC($1)
7084
_LT_COMPILER_C_O($1)
7085
_LT_COMPILER_FILE_LOCKS($1)
7086
_LT_LINKER_SHLIBS($1)
7087
_LT_LINKER_HARDCODE_LIBPATH($1)
7096
])# _LT_LANG_GCJ_CONFIG
7099
# _LT_LANG_RC_CONFIG([TAG])
7100
# -------------------------
7101
# Ensure that the configuration variables for the Windows resource compiler
7102
# are suitably defined. These variables are subsequently used by _LT_CONFIG
7103
# to write the compiler configuration to `libtool'.
7104
m4_defun([_LT_LANG_RC_CONFIG],
7105
[AC_REQUIRE([LT_PROG_RC])dnl
7108
# Source file extension for RC test sources.
7111
# Object file extension for compiled RC test sources.
7113
_LT_TAGVAR(objext, $1)=$objext
7115
# Code to be used in simple compile tests
7116
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
7118
# Code to be used in simple link tests
7119
lt_simple_link_test_code="$lt_simple_compile_test_code"
7121
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
7124
# save warnings/boilerplate of simple test code
7125
_LT_COMPILER_BOILERPLATE
7126
_LT_LINKER_BOILERPLATE
7128
# Allow CC to be a program name with arguments.
7134
_LT_TAGVAR(compiler, $1)=$CC
7135
_LT_CC_BASENAME([$compiler])
7136
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
7138
if test -n "$compiler"; then
7146
])# _LT_LANG_RC_CONFIG
7151
AC_DEFUN([LT_PROG_GCJ],
7152
[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
7153
[m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
7154
[AC_CHECK_TOOL(GCJ, gcj,)
7155
test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7156
AC_SUBST(GCJFLAGS)])])[]dnl
7160
AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
7161
dnl aclocal-1.4 backwards compatibility:
7162
dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
7167
AC_DEFUN([LT_PROG_RC],
7168
[AC_CHECK_TOOL(RC, windres,)
7172
AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
7173
dnl aclocal-1.4 backwards compatibility:
7174
dnl AC_DEFUN([LT_AC_PROG_RC], [])
7179
# If we don't have a new enough Autoconf to choose the best grep
7180
# available, choose the one first in the user's PATH.
7181
m4_defun([_LT_DECL_EGREP],
7182
[AC_REQUIRE([AC_PROG_EGREP])dnl
7183
AC_REQUIRE([AC_PROG_FGREP])dnl
7184
test -z "$GREP" && GREP=grep
7185
_LT_DECL([], [GREP], [1], [A grep program that handles long lines])
7186
_LT_DECL([], [EGREP], [1], [An ERE matcher])
7187
_LT_DECL([], [FGREP], [1], [A literal string matcher])
7188
dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
7195
# If we don't have a new enough Autoconf to choose the best objdump
7196
# available, choose the one first in the user's PATH.
7197
m4_defun([_LT_DECL_OBJDUMP],
7198
[AC_CHECK_TOOL(OBJDUMP, objdump, false)
7199
test -z "$OBJDUMP" && OBJDUMP=objdump
7200
_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
7207
# Check for a fully-functional sed program, that truncates
7208
# as few characters as possible. Prefer GNU sed if found.
7209
m4_defun([_LT_DECL_SED],
7211
test -z "$SED" && SED=sed
7212
Xsed="$SED -e 1s/^X//"
7213
_LT_DECL([], [SED], [1], [A sed program that does not truncate output])
7214
_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
7215
[Sed that helps us avoid accidentally triggering echo(1) options like -n])
7218
m4_ifndef([AC_PROG_SED], [
7219
# NOTE: This macro has been submitted for inclusion into #
7220
# GNU Autoconf as AC_PROG_SED. When it is available in #
7221
# a released version of Autoconf we should remove this #
7222
# macro and use it instead. #
7224
m4_defun([AC_PROG_SED],
7225
[AC_MSG_CHECKING([for a sed that does not truncate output])
7226
AC_CACHE_VAL(lt_cv_path_SED,
7227
[# Loop through the user's path and test for sed and gsed.
7228
# Then use that list of sed's as ones to test for truncation.
7229
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7233
test -z "$as_dir" && as_dir=.
7234
for lt_ac_prog in sed gsed; do
7235
for ac_exec_ext in '' $ac_executable_extensions; do
7236
if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
7237
lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7245
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
7246
# along with /bin/sed that truncates output.
7247
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7248
test ! -f $lt_ac_sed && continue
7249
cat /dev/null > conftest.in
7251
echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7252
# Check for GNU sed and select it if it is found.
7253
if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7254
lt_cv_path_SED=$lt_ac_sed
7258
cat conftest.in conftest.in >conftest.tmp
7259
mv conftest.tmp conftest.in
7260
cp conftest.in conftest.nl
7262
$lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7263
cmp -s conftest.out conftest.nl || break
7264
# 10000 chars as input seems more than enough
7265
test $lt_ac_count -gt 10 && break
7266
lt_ac_count=`expr $lt_ac_count + 1`
7267
if test $lt_ac_count -gt $lt_ac_max; then
7268
lt_ac_max=$lt_ac_count
7269
lt_cv_path_SED=$lt_ac_sed
7276
AC_MSG_RESULT([$SED])
7281
AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
7282
dnl aclocal-1.4 backwards compatibility:
7283
dnl AC_DEFUN([LT_AC_PROG_SED], [])
7286
# _LT_CHECK_SHELL_FEATURES
7287
# ------------------------
7288
# Find out whether the shell is Bourne or XSI compatible,
7289
# or has some other useful features.
7290
m4_defun([_LT_CHECK_SHELL_FEATURES],
7291
[AC_MSG_CHECKING([whether the shell understands some XSI constructs])
7292
# Try some XSI features
7295
test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
7297
&& eval 'test $(( 1 + 1 )) -eq 2 \
7298
&& test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7300
AC_MSG_RESULT([$xsi_shell])
7301
_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
7303
AC_MSG_CHECKING([whether the shell understands "+="])
7305
( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
7307
&& lt_shell_append=yes
7308
AC_MSG_RESULT([$lt_shell_append])
7309
_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
7311
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7316
_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
7318
# test EBCDIC or ASCII
7319
case `echo X|tr X '\101'` in
7320
A) # ASCII based system
7321
# \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7322
lt_SP2NL='tr \040 \012'
7323
lt_NL2SP='tr \015\012 \040\040'
7325
*) # EBCDIC based system
7326
lt_SP2NL='tr \100 \n'
7327
lt_NL2SP='tr \r\n \100\100'
7330
_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
7331
_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
7332
])# _LT_CHECK_SHELL_FEATURES
7335
# _LT_PROG_XSI_SHELLFNS
7336
# ---------------------
7337
# Bourne and XSI compatible variants of some useful shell functions.
7338
m4_defun([_LT_PROG_XSI_SHELLFNS],
7341
cat << \_LT_EOF >> "$cfgfile"
7343
# func_dirname file append nondir_replacement
7344
# Compute the dirname of FILE. If nonempty, add APPEND to the result,
7345
# otherwise set result to NONDIR_REPLACEMENT.
7349
*/*) func_dirname_result="${1%/*}${2}" ;;
7350
* ) func_dirname_result="${3}" ;;
7354
# func_basename file
7357
func_basename_result="${1##*/}"
7360
# func_dirname_and_basename file append nondir_replacement
7361
# perform func_basename and func_dirname in a single function
7363
# dirname: Compute the dirname of FILE. If nonempty,
7364
# add APPEND to the result, otherwise set result
7365
# to NONDIR_REPLACEMENT.
7366
# value returned in "$func_dirname_result"
7367
# basename: Compute filename of FILE.
7368
# value retuned in "$func_basename_result"
7369
# Implementation must be kept synchronized with func_dirname
7370
# and func_basename. For efficiency, we do not delegate to
7371
# those functions but instead duplicate the functionality here.
7372
func_dirname_and_basename ()
7375
*/*) func_dirname_result="${1%/*}${2}" ;;
7376
* ) func_dirname_result="${3}" ;;
7378
func_basename_result="${1##*/}"
7381
# func_stripname prefix suffix name
7382
# strip PREFIX and SUFFIX off of NAME.
7383
# PREFIX and SUFFIX must not contain globbing or regex special
7384
# characters, hashes, percent signs, but SUFFIX may contain a leading
7385
# dot (in which case that matches only a dot).
7388
# pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
7389
# positional parameters, so assign one to ordinary parameter first.
7390
func_stripname_result=${3}
7391
func_stripname_result=${func_stripname_result#"${1}"}
7392
func_stripname_result=${func_stripname_result%"${2}"}
7398
func_opt_split_opt=${1%%=*}
7399
func_opt_split_arg=${1#*=}
7406
*.lo) func_lo2o_result=${1%.lo}.${objext} ;;
7407
*) func_lo2o_result=${1} ;;
7411
# func_xform libobj-or-source
7414
func_xform_result=${1%.*}.lo
7417
# func_arith arithmetic-term...
7420
func_arith_result=$(( $[*] ))
7424
# STRING may not start with a hyphen.
7427
func_len_result=${#1}
7432
*) # Bourne compatible functions.
7433
cat << \_LT_EOF >> "$cfgfile"
7435
# func_dirname file append nondir_replacement
7436
# Compute the dirname of FILE. If nonempty, add APPEND to the result,
7437
# otherwise set result to NONDIR_REPLACEMENT.
7440
# Extract subdirectory from the argument.
7441
func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
7442
if test "X$func_dirname_result" = "X${1}"; then
7443
func_dirname_result="${3}"
7445
func_dirname_result="$func_dirname_result${2}"
7449
# func_basename file
7452
func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
7455
dnl func_dirname_and_basename
7456
dnl A portable version of this function is already defined in general.m4sh
7457
dnl so there is no need for it here.
7459
# func_stripname prefix suffix name
7460
# strip PREFIX and SUFFIX off of NAME.
7461
# PREFIX and SUFFIX must not contain globbing or regex special
7462
# characters, hashes, percent signs, but SUFFIX may contain a leading
7463
# dot (in which case that matches only a dot).
7464
# func_strip_suffix prefix name
7468
.*) func_stripname_result=`$ECHO "X${3}" \
7469
| $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
7470
*) func_stripname_result=`$ECHO "X${3}" \
7471
| $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
7476
my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
7477
my_sed_long_arg='1s/^-[[^=]]*=//'
7482
func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
7483
func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
7489
func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
7492
# func_xform libobj-or-source
7495
func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'`
7498
# func_arith arithmetic-term...
7501
func_arith_result=`expr "$[@]"`
7505
# STRING may not start with a hyphen.
7508
func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
7514
case $lt_shell_append in
7516
cat << \_LT_EOF >> "$cfgfile"
7518
# func_append var value
7519
# Append VALUE to the end of shell variable VAR.
7527
cat << \_LT_EOF >> "$cfgfile"
7529
# func_append var value
7530
# Append VALUE to the end of shell variable VAR.
7533
eval "$[1]=\$$[1]\$[2]"
7541
# Helper functions for option handling. -*- Autoconf -*-
7543
# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
7544
# Written by Gary V. Vaughan, 2004
7546
# This file is free software; the Free Software Foundation gives
7547
# unlimited permission to copy and/or distribute it, with or without
7548
# modifications, as long as this notice is preserved.
7550
# serial 6 ltoptions.m4
7552
# This is to help aclocal find these macros, as it can't see m4_define.
7553
AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
7556
# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
7557
# ------------------------------------------
7558
m4_define([_LT_MANGLE_OPTION],
7559
[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
7562
# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
7563
# ---------------------------------------
7564
# Set option OPTION-NAME for macro MACRO-NAME, and if there is a
7565
# matching handler defined, dispatch to it. Other OPTION-NAMEs are
7567
m4_define([_LT_SET_OPTION],
7568
[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
7569
m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
7570
_LT_MANGLE_DEFUN([$1], [$2]),
7571
[m4_warning([Unknown $1 option `$2'])])[]dnl
7575
# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
7576
# ------------------------------------------------------------
7577
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
7578
m4_define([_LT_IF_OPTION],
7579
[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
7582
# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
7583
# -------------------------------------------------------
7584
# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
7586
m4_define([_LT_UNLESS_OPTIONS],
7587
[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
7588
[m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
7589
[m4_define([$0_found])])])[]dnl
7590
m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
7595
# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
7596
# ----------------------------------------
7597
# OPTION-LIST is a space-separated list of Libtool options associated
7598
# with MACRO-NAME. If any OPTION has a matching handler declared with
7599
# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
7600
# the unknown option and exit.
7601
m4_defun([_LT_SET_OPTIONS],
7603
m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
7604
[_LT_SET_OPTION([$1], _LT_Option)])
7606
m4_if([$1],[LT_INIT],[
7608
dnl Simply set some default values (i.e off) if boolean options were not
7610
_LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
7612
_LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
7615
dnl If no reference was made to various pairs of opposing options, then
7616
dnl we run the default mode handler for the pair. For example, if neither
7617
dnl `shared' nor `disable-shared' was passed, we enable building of shared
7618
dnl archives by default:
7619
_LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
7620
_LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
7621
_LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
7622
_LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
7623
[_LT_ENABLE_FAST_INSTALL])
7629
# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
7630
# -----------------------------------------
7631
m4_define([_LT_MANGLE_DEFUN],
7632
[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
7635
# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
7636
# -----------------------------------------------
7637
m4_define([LT_OPTION_DEFINE],
7638
[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
7639
])# LT_OPTION_DEFINE
7644
LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
7647
AU_DEFUN([AC_LIBTOOL_DLOPEN],
7648
[_LT_SET_OPTION([LT_INIT], [dlopen])
7649
AC_DIAGNOSE([obsolete],
7650
[$0: Remove this warning and the call to _LT_SET_OPTION when you
7651
put the `dlopen' option into LT_INIT's first parameter.])
7654
dnl aclocal-1.4 backwards compatibility:
7655
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
7660
# Declare package support for building win32 dll's.
7661
LT_OPTION_DEFINE([LT_INIT], [win32-dll],
7662
[enable_win32_dll=yes
7665
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*)
7666
AC_CHECK_TOOL(AS, as, false)
7667
AC_CHECK_TOOL(DLLTOOL, dlltool, false)
7668
AC_CHECK_TOOL(OBJDUMP, objdump, false)
7672
test -z "$AS" && AS=as
7673
_LT_DECL([], [AS], [0], [Assembler program])dnl
7675
test -z "$DLLTOOL" && DLLTOOL=dlltool
7676
_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl
7678
test -z "$OBJDUMP" && OBJDUMP=objdump
7679
_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl
7682
AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
7683
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
7684
_LT_SET_OPTION([LT_INIT], [win32-dll])
7685
AC_DIAGNOSE([obsolete],
7686
[$0: Remove this warning and the call to _LT_SET_OPTION when you
7687
put the `win32-dll' option into LT_INIT's first parameter.])
7690
dnl aclocal-1.4 backwards compatibility:
7691
dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
7694
# _LT_ENABLE_SHARED([DEFAULT])
7695
# ----------------------------
7696
# implement the --enable-shared flag, and supports the `shared' and
7697
# `disable-shared' LT_INIT options.
7698
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
7699
m4_define([_LT_ENABLE_SHARED],
7700
[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
7701
AC_ARG_ENABLE([shared],
7702
[AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
7703
[build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
7704
[p=${PACKAGE-default}
7706
yes) enable_shared=yes ;;
7707
no) enable_shared=no ;;
7710
# Look at the argument we got. We use all the common list separators.
7711
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7712
for pkg in $enableval; do
7714
if test "X$pkg" = "X$p"; then
7721
[enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
7723
_LT_DECL([build_libtool_libs], [enable_shared], [0],
7724
[Whether or not to build shared libraries])
7725
])# _LT_ENABLE_SHARED
7727
LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
7728
LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
7731
AC_DEFUN([AC_ENABLE_SHARED],
7732
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
7735
AC_DEFUN([AC_DISABLE_SHARED],
7736
[_LT_SET_OPTION([LT_INIT], [disable-shared])
7739
AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
7740
AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
7742
dnl aclocal-1.4 backwards compatibility:
7743
dnl AC_DEFUN([AM_ENABLE_SHARED], [])
7744
dnl AC_DEFUN([AM_DISABLE_SHARED], [])
7748
# _LT_ENABLE_STATIC([DEFAULT])
7749
# ----------------------------
7750
# implement the --enable-static flag, and support the `static' and
7751
# `disable-static' LT_INIT options.
7752
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
7753
m4_define([_LT_ENABLE_STATIC],
7754
[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
7755
AC_ARG_ENABLE([static],
7756
[AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
7757
[build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
7758
[p=${PACKAGE-default}
7760
yes) enable_static=yes ;;
7761
no) enable_static=no ;;
7764
# Look at the argument we got. We use all the common list separators.
7765
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7766
for pkg in $enableval; do
7768
if test "X$pkg" = "X$p"; then
7775
[enable_static=]_LT_ENABLE_STATIC_DEFAULT)
7777
_LT_DECL([build_old_libs], [enable_static], [0],
7778
[Whether or not to build static libraries])
7779
])# _LT_ENABLE_STATIC
7781
LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
7782
LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
7785
AC_DEFUN([AC_ENABLE_STATIC],
7786
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
7789
AC_DEFUN([AC_DISABLE_STATIC],
7790
[_LT_SET_OPTION([LT_INIT], [disable-static])
7793
AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
7794
AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
7796
dnl aclocal-1.4 backwards compatibility:
7797
dnl AC_DEFUN([AM_ENABLE_STATIC], [])
7798
dnl AC_DEFUN([AM_DISABLE_STATIC], [])
7802
# _LT_ENABLE_FAST_INSTALL([DEFAULT])
7803
# ----------------------------------
7804
# implement the --enable-fast-install flag, and support the `fast-install'
7805
# and `disable-fast-install' LT_INIT options.
7806
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
7807
m4_define([_LT_ENABLE_FAST_INSTALL],
7808
[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
7809
AC_ARG_ENABLE([fast-install],
7810
[AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
7811
[optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
7812
[p=${PACKAGE-default}
7814
yes) enable_fast_install=yes ;;
7815
no) enable_fast_install=no ;;
7817
enable_fast_install=no
7818
# Look at the argument we got. We use all the common list separators.
7819
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7820
for pkg in $enableval; do
7822
if test "X$pkg" = "X$p"; then
7823
enable_fast_install=yes
7829
[enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
7831
_LT_DECL([fast_install], [enable_fast_install], [0],
7832
[Whether or not to optimize for fast installation])dnl
7833
])# _LT_ENABLE_FAST_INSTALL
7835
LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
7836
LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
7839
AU_DEFUN([AC_ENABLE_FAST_INSTALL],
7840
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
7841
AC_DIAGNOSE([obsolete],
7842
[$0: Remove this warning and the call to _LT_SET_OPTION when you put
7843
the `fast-install' option into LT_INIT's first parameter.])
7846
AU_DEFUN([AC_DISABLE_FAST_INSTALL],
7847
[_LT_SET_OPTION([LT_INIT], [disable-fast-install])
7848
AC_DIAGNOSE([obsolete],
7849
[$0: Remove this warning and the call to _LT_SET_OPTION when you put
7850
the `disable-fast-install' option into LT_INIT's first parameter.])
7853
dnl aclocal-1.4 backwards compatibility:
7854
dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
7855
dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
7858
# _LT_WITH_PIC([MODE])
7859
# --------------------
7860
# implement the --with-pic flag, and support the `pic-only' and `no-pic'
7862
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
7863
m4_define([_LT_WITH_PIC],
7865
[AS_HELP_STRING([--with-pic],
7866
[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
7867
[pic_mode="$withval"],
7870
test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
7872
_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
7875
LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
7876
LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
7879
AU_DEFUN([AC_LIBTOOL_PICMODE],
7880
[_LT_SET_OPTION([LT_INIT], [pic-only])
7881
AC_DIAGNOSE([obsolete],
7882
[$0: Remove this warning and the call to _LT_SET_OPTION when you
7883
put the `pic-only' option into LT_INIT's first parameter.])
7886
dnl aclocal-1.4 backwards compatibility:
7887
dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
7890
m4_define([_LTDL_MODE], [])
7891
LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
7892
[m4_define([_LTDL_MODE], [nonrecursive])])
7893
LT_OPTION_DEFINE([LTDL_INIT], [recursive],
7894
[m4_define([_LTDL_MODE], [recursive])])
7895
LT_OPTION_DEFINE([LTDL_INIT], [subproject],
7896
[m4_define([_LTDL_MODE], [subproject])])
7898
m4_define([_LTDL_TYPE], [])
7899
LT_OPTION_DEFINE([LTDL_INIT], [installable],
7900
[m4_define([_LTDL_TYPE], [installable])])
7901
LT_OPTION_DEFINE([LTDL_INIT], [convenience],
7902
[m4_define([_LTDL_TYPE], [convenience])])
7904
# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
7906
# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
7907
# Written by Gary V. Vaughan, 2004
7909
# This file is free software; the Free Software Foundation gives
7910
# unlimited permission to copy and/or distribute it, with or without
7911
# modifications, as long as this notice is preserved.
7913
# serial 6 ltsugar.m4
7915
# This is to help aclocal find these macros, as it can't see m4_define.
7916
AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
7919
# lt_join(SEP, ARG1, [ARG2...])
7920
# -----------------------------
7921
# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
7922
# associated separator.
7923
# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
7924
# versions in m4sugar had bugs.
7925
m4_define([lt_join],
7926
[m4_if([$#], [1], [],
7928
[m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
7929
m4_define([_lt_join],
7930
[m4_if([$#$2], [2], [],
7931
[m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
7937
# Manipulate m4 lists.
7938
# These macros are necessary as long as will still need to support
7939
# Autoconf-2.59 which quotes differently.
7940
m4_define([lt_car], [[$1]])
7942
[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
7944
[m4_dquote(m4_shift($@))])])
7945
m4_define([lt_unquote], $1)
7948
# lt_append(MACRO-NAME, STRING, [SEPARATOR])
7949
# ------------------------------------------
7950
# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
7951
# Note that neither SEPARATOR nor STRING are expanded; they are appended
7952
# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
7953
# No SEPARATOR is output if MACRO-NAME was previously undefined (different
7954
# than defined and empty).
7956
# This macro is needed until we can rely on Autoconf 2.62, since earlier
7957
# versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
7958
m4_define([lt_append],
7960
m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
7964
# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
7965
# ----------------------------------------------------------
7966
# Produce a SEP delimited list of all paired combinations of elements of
7967
# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
7968
# has the form PREFIXmINFIXSUFFIXn.
7969
# Needed until we can rely on m4_combine added in Autoconf 2.62.
7970
m4_define([lt_combine],
7971
[m4_if(m4_eval([$# > 3]), [1],
7972
[m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
7973
[[m4_foreach([_Lt_prefix], [$2],
7974
[m4_foreach([_Lt_suffix],
7975
]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
7976
[_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
7979
# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
7980
# -----------------------------------------------------------------------
7981
# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
7982
# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
7983
m4_define([lt_if_append_uniq],
7985
[m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
7986
[lt_append([$1], [$2], [$3])$4],
7988
[lt_append([$1], [$2], [$3])$4])])
7991
# lt_dict_add(DICT, KEY, VALUE)
7992
# -----------------------------
7993
m4_define([lt_dict_add],
7994
[m4_define([$1($2)], [$3])])
7997
# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
7998
# --------------------------------------------
7999
m4_define([lt_dict_add_subkey],
8000
[m4_define([$1($2:$3)], [$4])])
8003
# lt_dict_fetch(DICT, KEY, [SUBKEY])
8004
# ----------------------------------
8005
m4_define([lt_dict_fetch],
8007
m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
8008
m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
8011
# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
8012
# -----------------------------------------------------------------
8013
m4_define([lt_if_dict_fetch],
8014
[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
8019
# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
8020
# --------------------------------------------------------------
8021
m4_define([lt_dict_filter],
8022
[m4_if([$5], [], [],
8023
[lt_join(m4_quote(m4_default([$4], [[, ]])),
8024
lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
8025
[lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
8028
# ltversion.m4 -- version numbers -*- Autoconf -*-
8030
# Copyright (C) 2004 Free Software Foundation, Inc.
8031
# Written by Scott James Remnant, 2004
8033
# This file is free software; the Free Software Foundation gives
8034
# unlimited permission to copy and/or distribute it, with or without
8035
# modifications, as long as this notice is preserved.
8037
# Generated from ltversion.in.
8039
# serial 3017 ltversion.m4
8040
# This file is part of GNU Libtool
8042
m4_define([LT_PACKAGE_VERSION], [2.2.6b])
8043
m4_define([LT_PACKAGE_REVISION], [1.3017])
8045
AC_DEFUN([LTVERSION_VERSION],
8046
[macro_version='2.2.6b'
8047
macro_revision='1.3017'
8048
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
8049
_LT_DECL(, macro_revision, 0)
8052
# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
8054
# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
8055
# Written by Scott James Remnant, 2004.
8057
# This file is free software; the Free Software Foundation gives
8058
# unlimited permission to copy and/or distribute it, with or without
8059
# modifications, as long as this notice is preserved.
8061
# serial 4 lt~obsolete.m4
8063
# These exist entirely to fool aclocal when bootstrapping libtool.
8065
# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
8066
# which have later been changed to m4_define as they aren't part of the
8067
# exported API, or moved to Autoconf or Automake where they belong.
8069
# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
8070
# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
8071
# using a macro with the same name in our local m4/libtool.m4 it'll
8072
# pull the old libtool.m4 in (it doesn't see our shiny new m4_define
8073
# and doesn't know about Autoconf macros at all.)
8075
# So we provide this file, which has a silly filename so it's always
8076
# included after everything else. This provides aclocal with the
8077
# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
8078
# because those macros already exist, or will be overwritten later.
8079
# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
8081
# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
8082
# Yes, that means every name once taken will need to remain here until
8083
# we give up compatibility with versions before 1.7, at which point
8084
# we need to keep only those names which we still refer to.
8086
# This is to help aclocal find these macros, as it can't see m4_define.
8087
AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
8089
m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
8090
m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
8091
m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
8092
m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
8093
m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
8094
m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
8095
m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
8096
m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
8097
m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
8098
m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
8099
m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
8100
m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
8101
m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
8102
m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
8103
m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
8104
m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
8105
m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
8106
m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
8107
m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
8108
m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
8109
m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
8110
m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
8111
m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
8112
m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
8113
m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
8114
m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
8115
m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
8116
m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
8117
m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
8118
m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
8119
m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
8120
m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
8121
m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
8122
m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
8123
m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
8124
m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
8125
m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
8126
m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
8127
m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
8128
m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
8129
m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
8130
m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
8131
m4_ifndef([AC_LIBTOOL_RC], [AC_DEFUN([AC_LIBTOOL_RC])])
8132
m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
8133
m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
8134
m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
8135
m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
8136
m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
8137
m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
8138
m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
8139
m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
8140
m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
8141
m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
8142
m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
8143
m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
8145
22
# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
8146
23
# serial 1 (pkg-config-0.24)