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