1 |
6 |
jlechner |
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
|
2 |
|
|
#
|
3 |
|
|
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
|
4 |
|
|
# 2006, 2007 Free Software Foundation, Inc.
|
5 |
|
|
#
|
6 |
|
|
# This file is part of GNU Libtool:
|
7 |
|
|
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
|
8 |
|
|
#
|
9 |
|
|
# This file is free software; the Free Software Foundation gives
|
10 |
|
|
# unlimited permission to copy and/or distribute it, with or without
|
11 |
|
|
# modifications, as long as this notice is preserved.
|
12 |
|
|
|
13 |
|
|
m4_define([_LT_COPYING], [dnl
|
14 |
|
|
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
|
15 |
|
|
# 2006, 2007 Free Software Foundation, Inc.
|
16 |
|
|
#
|
17 |
|
|
# This file is part of GNU Libtool:
|
18 |
|
|
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
|
19 |
|
|
#
|
20 |
|
|
# This program is free software; you can redistribute it and/or modify
|
21 |
|
|
# it under the terms of the GNU General Public License as published by
|
22 |
|
|
# the Free Software Foundation; either version 2 of the License, or
|
23 |
|
|
# (at your option) any later version.
|
24 |
|
|
#
|
25 |
|
|
# This program is distributed in the hope that it will be useful, but
|
26 |
|
|
# WITHOUT ANY WARRANTY; without even the implied warranty of
|
27 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
28 |
|
|
# General Public License for more details.
|
29 |
|
|
#
|
30 |
|
|
# You should have received a copy of the GNU General Public License
|
31 |
|
|
# along with this program; if not, a copy can be downloaded from
|
32 |
|
|
# http://www.gnu.org/copyleft/gpl.html, or by writing to the Free
|
33 |
|
|
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
34 |
|
|
# MA 02110-1301, USA.
|
35 |
|
|
#
|
36 |
|
|
# As a special exception to the GNU General Public License, if you
|
37 |
|
|
# distribute this file as part of a program that contains a
|
38 |
|
|
# configuration script generated by Autoconf, you may include it under
|
39 |
|
|
# the same distribution terms that you use for the rest of that program.
|
40 |
|
|
])
|
41 |
|
|
|
42 |
|
|
# serial 53 LT_INIT
|
43 |
|
|
|
44 |
|
|
|
45 |
|
|
# LT_PREREQ(VERSION)
|
46 |
|
|
# ------------------
|
47 |
|
|
# Complain and exit if this libtool version is less that VERSION.
|
48 |
|
|
m4_defun([LT_PREREQ],
|
49 |
|
|
[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
|
50 |
|
|
[m4_default([$3],
|
51 |
|
|
[m4_fatal([Libtool version $1 or higher is required],
|
52 |
|
|
63)])],
|
53 |
|
|
[$2])])
|
54 |
|
|
|
55 |
|
|
|
56 |
|
|
# LT_INIT([OPTIONS])
|
57 |
|
|
# ------------------
|
58 |
|
|
AC_DEFUN([LT_INIT],
|
59 |
|
|
[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
|
60 |
|
|
AC_BEFORE([$0], [LT_LANG])dnl
|
61 |
|
|
AC_BEFORE([$0], [LT_OUTPUT])dnl
|
62 |
|
|
|
63 |
|
|
dnl Autoconf doesn't catch unexpanded LT_ macros by default:
|
64 |
|
|
m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
|
65 |
|
|
m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
|
66 |
|
|
dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
|
67 |
|
|
dnl unless we require an AC_DEFUNed macro:
|
68 |
|
|
AC_REQUIRE([LTOPTIONS_VERSION])dnl
|
69 |
|
|
AC_REQUIRE([LTSUGAR_VERSION])dnl
|
70 |
|
|
AC_REQUIRE([LTVERSION_VERSION])dnl
|
71 |
|
|
m4_require([_LT_PROG_LTMAIN])dnl
|
72 |
|
|
m4_require([_LT_SET_OPTIONS], [_LT_SET_OPTIONS([$1])])dnl
|
73 |
|
|
|
74 |
|
|
# This can be used to rebuild libtool when needed
|
75 |
|
|
LIBTOOL_DEPS="$ltmain"
|
76 |
|
|
|
77 |
|
|
# Always use our own libtool.
|
78 |
|
|
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
|
79 |
|
|
AC_SUBST(LIBTOOL)dnl
|
80 |
|
|
|
81 |
|
|
_LT_SETUP
|
82 |
|
|
|
83 |
|
|
# Only expand once:
|
84 |
|
|
m4_define([LT_INIT])
|
85 |
|
|
])# _LT_INIT
|
86 |
|
|
|
87 |
|
|
# Old names:
|
88 |
|
|
AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
|
89 |
|
|
AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
|
90 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
91 |
|
|
dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
|
92 |
|
|
dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
|
93 |
|
|
|
94 |
|
|
|
95 |
|
|
# _LT_CC_BASENAME(CC)
|
96 |
|
|
# -------------------
|
97 |
|
|
# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
|
98 |
|
|
m4_defun([_LT_CC_BASENAME],
|
99 |
|
|
[for cc_temp in $1""; do
|
100 |
|
|
case $cc_temp in
|
101 |
|
|
compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
|
102 |
|
|
distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
|
103 |
|
|
\-*) ;;
|
104 |
|
|
*) break;;
|
105 |
|
|
esac
|
106 |
|
|
done
|
107 |
|
|
cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
|
108 |
|
|
])
|
109 |
|
|
|
110 |
|
|
|
111 |
|
|
# _LT_FILEUTILS_DEFAULTS
|
112 |
|
|
# ----------------------
|
113 |
|
|
# It is okay to use these file commands and assume they have been set
|
114 |
|
|
# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
|
115 |
|
|
m4_defun([_LT_FILEUTILS_DEFAULTS],
|
116 |
|
|
[: ${CP="cp -f"}
|
117 |
|
|
: ${MV="mv -f"}
|
118 |
|
|
: ${RM="rm -f"}
|
119 |
|
|
])# _LT_FILEUTILS_DEFAULTS
|
120 |
|
|
|
121 |
|
|
|
122 |
|
|
# _LT_SETUP
|
123 |
|
|
# ---------
|
124 |
|
|
m4_defun([_LT_SETUP],
|
125 |
|
|
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
126 |
|
|
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
|
127 |
|
|
_LT_DECL([], [host_alias], [0], [The host system])dnl
|
128 |
|
|
_LT_DECL([], [host], [0])dnl
|
129 |
|
|
_LT_DECL([], [host_os], [0])dnl
|
130 |
|
|
dnl
|
131 |
|
|
_LT_DECL([], [build_alias], [0], [The build system])dnl
|
132 |
|
|
_LT_DECL([], [build], [0])dnl
|
133 |
|
|
_LT_DECL([], [build_os], [0])dnl
|
134 |
|
|
dnl
|
135 |
|
|
AC_REQUIRE([AC_PROG_CC])dnl
|
136 |
|
|
AC_REQUIRE([LT_PATH_LD])dnl
|
137 |
|
|
AC_REQUIRE([LT_PATH_NM])dnl
|
138 |
|
|
dnl
|
139 |
|
|
AC_REQUIRE([AC_PROG_LN_S])dnl
|
140 |
|
|
test -z "$LN_S" && LN_S="ln -s"
|
141 |
|
|
_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
|
142 |
|
|
dnl
|
143 |
|
|
AC_REQUIRE([LT_CMD_MAX_LEN])dnl
|
144 |
|
|
AC_REQUIRE([AC_OBJEXT])dnl
|
145 |
|
|
_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
|
146 |
|
|
AC_REQUIRE([AC_EXEEXT])dnl
|
147 |
|
|
_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
|
148 |
|
|
dnl
|
149 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
150 |
|
|
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
|
151 |
|
|
m4_require([_LT_CMD_RELOAD])dnl
|
152 |
|
|
m4_require([_LT_CHECK_MAGIC_METHOD])dnl
|
153 |
|
|
m4_require([_LT_CMD_OLD_ARCHIVE])dnl
|
154 |
|
|
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
|
155 |
|
|
|
156 |
|
|
_LT_CONFIG_LIBTOOL_INIT([
|
157 |
|
|
# See if we are running on zsh, and set the options which allow our
|
158 |
|
|
# commands through without removal of \ escapes INIT.
|
159 |
|
|
if test -n "\${ZSH_VERSION+set}" ; then
|
160 |
|
|
setopt NO_GLOB_SUBST
|
161 |
|
|
fi
|
162 |
|
|
])
|
163 |
|
|
if test -n "${ZSH_VERSION+set}" ; then
|
164 |
|
|
setopt NO_GLOB_SUBST
|
165 |
|
|
fi
|
166 |
|
|
|
167 |
|
|
_LT_CHECK_OBJDIR
|
168 |
|
|
|
169 |
|
|
m4_require([_LT_TAG_COMPILER])dnl
|
170 |
|
|
_LT_PROG_ECHO_BACKSLASH
|
171 |
|
|
|
172 |
|
|
case $host_os in
|
173 |
|
|
aix3*)
|
174 |
|
|
# AIX sometimes has problems with the GCC collect2 program. For some
|
175 |
|
|
# reason, if we set the COLLECT_NAMES environment variable, the problems
|
176 |
|
|
# vanish in a puff of smoke.
|
177 |
|
|
if test "X${COLLECT_NAMES+set}" != Xset; then
|
178 |
|
|
COLLECT_NAMES=
|
179 |
|
|
export COLLECT_NAMES
|
180 |
|
|
fi
|
181 |
|
|
;;
|
182 |
|
|
esac
|
183 |
|
|
|
184 |
|
|
# Sed substitution that helps us do robust quoting. It backslashifies
|
185 |
|
|
# metacharacters that are still active within double-quoted strings.
|
186 |
|
|
sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
|
187 |
|
|
|
188 |
|
|
# Same as above, but do not quote variable references.
|
189 |
|
|
double_quote_subst='s/\([["`\\]]\)/\\\1/g'
|
190 |
|
|
|
191 |
|
|
# Sed substitution to delay expansion of an escaped shell variable in a
|
192 |
|
|
# double_quote_subst'ed string.
|
193 |
|
|
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
|
194 |
|
|
|
195 |
|
|
# Sed substitution to delay expansion of an escaped single quote.
|
196 |
|
|
delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
|
197 |
|
|
|
198 |
|
|
# Sed substitution to avoid accidental globbing in evaled expressions
|
199 |
|
|
no_glob_subst='s/\*/\\\*/g'
|
200 |
|
|
|
201 |
|
|
# Global variables:
|
202 |
|
|
ofile=libtool
|
203 |
|
|
can_build_shared=yes
|
204 |
|
|
|
205 |
|
|
# All known linkers require a `.a' archive for static linking (except MSVC,
|
206 |
|
|
# which needs '.lib').
|
207 |
|
|
libext=a
|
208 |
|
|
|
209 |
|
|
with_gnu_ld="$lt_cv_prog_gnu_ld"
|
210 |
|
|
|
211 |
|
|
old_CC="$CC"
|
212 |
|
|
old_CFLAGS="$CFLAGS"
|
213 |
|
|
|
214 |
|
|
# Set sane defaults for various variables
|
215 |
|
|
test -z "$CC" && CC=cc
|
216 |
|
|
test -z "$LTCC" && LTCC=$CC
|
217 |
|
|
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
|
218 |
|
|
test -z "$LD" && LD=ld
|
219 |
|
|
test -z "$ac_objext" && ac_objext=o
|
220 |
|
|
|
221 |
|
|
_LT_CC_BASENAME([$compiler])
|
222 |
|
|
|
223 |
|
|
# Only perform the check for file, if the check method requires it
|
224 |
|
|
test -z "$MAGIC_CMD" && MAGIC_CMD=file
|
225 |
|
|
case $deplibs_check_method in
|
226 |
|
|
file_magic*)
|
227 |
|
|
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
|
228 |
|
|
_LT_PATH_MAGIC
|
229 |
|
|
fi
|
230 |
|
|
;;
|
231 |
|
|
esac
|
232 |
|
|
|
233 |
|
|
# Use C for the default configuration in the libtool script
|
234 |
|
|
LT_SUPPORTED_TAG([CC])
|
235 |
|
|
_LT_LANG_C_CONFIG
|
236 |
|
|
_LT_LANG_DEFAULT_CONFIG
|
237 |
|
|
_LT_CONFIG_COMMANDS
|
238 |
|
|
])# _LT_SETUP
|
239 |
|
|
|
240 |
|
|
|
241 |
|
|
# _LT_PROG_LTMAIN
|
242 |
|
|
# ---------------
|
243 |
|
|
# Note that this code is called both from `configure', and `config.status'
|
244 |
|
|
# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
|
245 |
|
|
# `config.status' has no value for ac_aux_dir unless we are using Automake,
|
246 |
|
|
# so we pass a copy along to make sure it has a sensible value anyway.
|
247 |
|
|
m4_defun([_LT_PROG_LTMAIN],
|
248 |
|
|
[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
|
249 |
|
|
_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
|
250 |
|
|
ltmain="$ac_aux_dir/ltmain.sh"
|
251 |
|
|
])# _LT_PROG_LTMAIN
|
252 |
|
|
|
253 |
|
|
|
254 |
|
|
## ------------------------------------- ##
|
255 |
|
|
## Accumulate code for creating libtool. ##
|
256 |
|
|
## ------------------------------------- ##
|
257 |
|
|
|
258 |
|
|
# So that we can recreate a full libtool script including additional
|
259 |
|
|
# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
|
260 |
|
|
# in macros and then make a single call at the end using the `libtool'
|
261 |
|
|
# label.
|
262 |
|
|
|
263 |
|
|
|
264 |
|
|
# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
|
265 |
|
|
# ----------------------------------------
|
266 |
|
|
# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
|
267 |
|
|
m4_define([_LT_CONFIG_LIBTOOL_INIT],
|
268 |
|
|
[m4_ifval([$1],
|
269 |
|
|
[m4_append([_LT_OUTPUT_LIBTOOL_INIT],
|
270 |
|
|
[$1
|
271 |
|
|
])])])
|
272 |
|
|
|
273 |
|
|
# Initialize.
|
274 |
|
|
m4_define([_LT_OUTPUT_LIBTOOL_INIT])
|
275 |
|
|
|
276 |
|
|
|
277 |
|
|
# _LT_CONFIG_LIBTOOL([COMMANDS])
|
278 |
|
|
# ------------------------------
|
279 |
|
|
# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
|
280 |
|
|
m4_define([_LT_CONFIG_LIBTOOL],
|
281 |
|
|
[m4_ifval([$1],
|
282 |
|
|
[m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
|
283 |
|
|
[$1
|
284 |
|
|
])])])
|
285 |
|
|
|
286 |
|
|
# Initialize.
|
287 |
|
|
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
|
288 |
|
|
|
289 |
|
|
|
290 |
|
|
# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
|
291 |
|
|
# -----------------------------------------------------
|
292 |
|
|
m4_defun([_LT_CONFIG_SAVE_COMMANDS],
|
293 |
|
|
[_LT_CONFIG_LIBTOOL([$1])
|
294 |
|
|
_LT_CONFIG_LIBTOOL_INIT([$2])
|
295 |
|
|
])
|
296 |
|
|
|
297 |
|
|
|
298 |
|
|
# _LT_FORMAT_COMMENT([COMMENT])
|
299 |
|
|
# -----------------------------
|
300 |
|
|
# Add leading comment marks to the start of each line, and a trailing
|
301 |
|
|
# full-stop to the whole comment if one is not present already.
|
302 |
|
|
m4_define([_LT_FORMAT_COMMENT],
|
303 |
|
|
[m4_ifval([$1], [
|
304 |
|
|
m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
|
305 |
|
|
[['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
|
306 |
|
|
)])
|
307 |
|
|
|
308 |
|
|
|
309 |
|
|
|
310 |
|
|
## ------------------------ ##
|
311 |
|
|
## FIXME: Eliminate VARNAME ##
|
312 |
|
|
## ------------------------ ##
|
313 |
|
|
|
314 |
|
|
|
315 |
|
|
# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
|
316 |
|
|
# -------------------------------------------------------------------
|
317 |
|
|
# CONFIGNAME is the name given to the value in the libtool script.
|
318 |
|
|
# VARNAME is the (base) name used in the configure script.
|
319 |
|
|
# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
|
320 |
|
|
# VARNAME. Any other value will be used directly.
|
321 |
|
|
m4_define([_LT_DECL],
|
322 |
|
|
[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
|
323 |
|
|
[lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
|
324 |
|
|
[m4_ifval([$1], [$1], [$2])])
|
325 |
|
|
lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
|
326 |
|
|
m4_ifval([$4],
|
327 |
|
|
[lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
|
328 |
|
|
lt_dict_add_subkey([lt_decl_dict], [$2],
|
329 |
|
|
[tagged?], [m4_ifval([$5], [yes], [no])])])
|
330 |
|
|
])
|
331 |
|
|
|
332 |
|
|
|
333 |
|
|
# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
|
334 |
|
|
# --------------------------------------------------------
|
335 |
|
|
m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
|
336 |
|
|
|
337 |
|
|
|
338 |
|
|
# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
|
339 |
|
|
# ------------------------------------------------
|
340 |
|
|
m4_define([lt_decl_tag_varnames],
|
341 |
|
|
[_lt_decl_filter([tagged?], [yes], $@)])
|
342 |
|
|
|
343 |
|
|
|
344 |
|
|
# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
|
345 |
|
|
# ---------------------------------------------------------
|
346 |
|
|
m4_define([_lt_decl_filter],
|
347 |
|
|
[m4_case([$#],
|
348 |
|
|
[0], [m4_fatal([$0: too few arguments: $#])],
|
349 |
|
|
[1], [m4_fatal([$0: too few arguments: $#: $1])],
|
350 |
|
|
[2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
|
351 |
|
|
[3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
|
352 |
|
|
[lt_dict_filter([lt_decl_dict], $@)])[]dnl
|
353 |
|
|
])
|
354 |
|
|
|
355 |
|
|
|
356 |
|
|
# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
|
357 |
|
|
# --------------------------------------------------
|
358 |
|
|
m4_define([lt_decl_quote_varnames],
|
359 |
|
|
[_lt_decl_filter([value], [1], $@)])
|
360 |
|
|
|
361 |
|
|
|
362 |
|
|
# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
|
363 |
|
|
# ---------------------------------------------------
|
364 |
|
|
m4_define([lt_decl_dquote_varnames],
|
365 |
|
|
[_lt_decl_filter([value], [2], $@)])
|
366 |
|
|
|
367 |
|
|
|
368 |
|
|
# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
|
369 |
|
|
# ---------------------------------------------------
|
370 |
|
|
m4_define([lt_decl_varnames_tagged],
|
371 |
|
|
[_$0(m4_quote(m4_default([$1], [[, ]])),
|
372 |
|
|
m4_quote(m4_if([$2], [],
|
373 |
|
|
m4_quote(lt_decl_tag_varnames),
|
374 |
|
|
m4_quote(m4_shift($@)))),
|
375 |
|
|
m4_split(m4_normalize(m4_quote(_LT_TAGS))))])
|
376 |
|
|
m4_define([_lt_decl_varnames_tagged], [lt_combine([$1], [$2], [_], $3)])
|
377 |
|
|
|
378 |
|
|
|
379 |
|
|
# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
|
380 |
|
|
# ------------------------------------------------
|
381 |
|
|
m4_define([lt_decl_all_varnames],
|
382 |
|
|
[_$0(m4_quote(m4_default([$1], [[, ]])),
|
383 |
|
|
m4_if([$2], [],
|
384 |
|
|
m4_quote(lt_decl_varnames),
|
385 |
|
|
m4_quote(m4_shift($@))))[]dnl
|
386 |
|
|
])
|
387 |
|
|
m4_define([_lt_decl_all_varnames],
|
388 |
|
|
[lt_join($@, lt_decl_varnames_tagged([$1],
|
389 |
|
|
lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
|
390 |
|
|
])
|
391 |
|
|
|
392 |
|
|
|
393 |
|
|
# _LT_CONFIG_STATUS_DECLARE([VARNAME])
|
394 |
|
|
# ------------------------------------
|
395 |
|
|
# Quote a variable value, and forward it to `config.status' so that its
|
396 |
|
|
# declaration there will have the same value as in `configure'. VARNAME
|
397 |
|
|
# must have a single quote delimited value for this to work.
|
398 |
|
|
m4_define([_LT_CONFIG_STATUS_DECLARE],
|
399 |
|
|
[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
|
400 |
|
|
|
401 |
|
|
|
402 |
|
|
# _LT_CONFIG_STATUS_DECLARATIONS
|
403 |
|
|
# ------------------------------
|
404 |
|
|
# We delimit libtool config variables with single quotes, so when
|
405 |
|
|
# we write them to config.status, we have to be sure to quote all
|
406 |
|
|
# embedded single quotes properly. In configure, this macro expands
|
407 |
|
|
# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
|
408 |
|
|
#
|
409 |
|
|
# <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
|
410 |
|
|
m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
|
411 |
|
|
[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
|
412 |
|
|
[m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
|
413 |
|
|
|
414 |
|
|
|
415 |
|
|
# _LT_LIBTOOL_TAGS
|
416 |
|
|
# ----------------
|
417 |
|
|
# Output comment and list of tags supported by the script
|
418 |
|
|
m4_defun([_LT_LIBTOOL_TAGS],
|
419 |
|
|
[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
|
420 |
|
|
available_tags="_LT_TAGS"dnl
|
421 |
|
|
])
|
422 |
|
|
|
423 |
|
|
|
424 |
|
|
# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
|
425 |
|
|
# -----------------------------------
|
426 |
|
|
# Extract the dictionary values for VARNAME (optionally with TAG) and
|
427 |
|
|
# expand to a commented shell variable setting:
|
428 |
|
|
#
|
429 |
|
|
# # Some comment about what VAR is for.
|
430 |
|
|
# visible_name=$lt_internal_name
|
431 |
|
|
m4_define([_LT_LIBTOOL_DECLARE],
|
432 |
|
|
[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
|
433 |
|
|
[description])))[]dnl
|
434 |
|
|
m4_pushdef([_libtool_name],
|
435 |
|
|
m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
|
436 |
|
|
m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
|
437 |
|
|
[0], [_libtool_name=[$]$1],
|
438 |
|
|
[1], [_libtool_name=$lt_[]$1],
|
439 |
|
|
[2], [_libtool_name=$lt_[]$1],
|
440 |
|
|
[_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
|
441 |
|
|
m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
|
442 |
|
|
])
|
443 |
|
|
|
444 |
|
|
|
445 |
|
|
# _LT_LIBTOOL_CONFIG_VARS
|
446 |
|
|
# -----------------------
|
447 |
|
|
# Produce commented declarations of non-tagged libtool config variables
|
448 |
|
|
# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
|
449 |
|
|
# script. Tagged libtool config variables (even for the LIBTOOL CONFIG
|
450 |
|
|
# section) are produced by _LT_LIBTOOL_TAG_VARS.
|
451 |
|
|
m4_defun([_LT_LIBTOOL_CONFIG_VARS],
|
452 |
|
|
[m4_foreach([_lt_var],
|
453 |
|
|
m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
|
454 |
|
|
[m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
|
455 |
|
|
|
456 |
|
|
|
457 |
|
|
# _LT_LIBTOOL_TAG_VARS(TAG)
|
458 |
|
|
# -------------------------
|
459 |
|
|
m4_define([_LT_LIBTOOL_TAG_VARS],
|
460 |
|
|
[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
|
461 |
|
|
[m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
|
462 |
|
|
|
463 |
|
|
|
464 |
|
|
# _LT_TAGVAR(VARNAME, [TAGNAME])
|
465 |
|
|
# ------------------------------
|
466 |
|
|
m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
|
467 |
|
|
|
468 |
|
|
|
469 |
|
|
# _LT_CONFIG_COMMANDS
|
470 |
|
|
# -------------------
|
471 |
|
|
# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
|
472 |
|
|
# variables for single and double quote escaping we saved from calls
|
473 |
|
|
# to _LT_DECL, we can put quote escaped variables declarations
|
474 |
|
|
# into `config.status', and then the shell code to quote escape them in
|
475 |
|
|
# for loops in `config.status'. Finally, any additional code accumulated
|
476 |
|
|
# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
|
477 |
|
|
m4_defun([_LT_CONFIG_COMMANDS],
|
478 |
|
|
[AC_PROVIDE_IFELSE([LT_OUTPUT],
|
479 |
|
|
dnl If the libtool generation code has been placed in $CONFIG_LT,
|
480 |
|
|
dnl instead of duplicating it all over again into config.status,
|
481 |
|
|
dnl then we will have config.status run $CONFIG_LT later, so it
|
482 |
|
|
dnl needs to know what name is stored there:
|
483 |
|
|
[AC_CONFIG_COMMANDS([libtool],
|
484 |
|
|
[$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
|
485 |
|
|
dnl If the libtool generation code is destined for config.status,
|
486 |
|
|
dnl expand the accumulated commands and init code now:
|
487 |
|
|
[AC_CONFIG_COMMANDS([libtool],
|
488 |
|
|
[_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
|
489 |
|
|
])#_LT_CONFIG_COMMANDS
|
490 |
|
|
|
491 |
|
|
|
492 |
|
|
# Initialize.
|
493 |
|
|
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
|
494 |
|
|
[
|
495 |
|
|
|
496 |
|
|
# The HP-UX ksh and POSIX shell print the target directory to stdout
|
497 |
|
|
# if CDPATH is set.
|
498 |
|
|
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
|
499 |
|
|
|
500 |
|
|
sed_quote_subst='$sed_quote_subst'
|
501 |
|
|
double_quote_subst='$double_quote_subst'
|
502 |
|
|
delay_variable_subst='$delay_variable_subst'
|
503 |
|
|
_LT_CONFIG_STATUS_DECLARATIONS
|
504 |
|
|
LTCC='$LTCC'
|
505 |
|
|
LTCFLAGS='$LTCFLAGS'
|
506 |
|
|
compiler='$compiler_DEFAULT'
|
507 |
|
|
|
508 |
|
|
# Quote evaled strings.
|
509 |
|
|
for var in lt_decl_all_varnames([[ \
|
510 |
|
|
]], lt_decl_quote_varnames); do
|
511 |
|
|
case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
|
512 |
|
|
*[[\\\\\\\`\\"\\\$]]*)
|
513 |
|
|
eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
|
514 |
|
|
;;
|
515 |
|
|
*)
|
516 |
|
|
eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
|
517 |
|
|
;;
|
518 |
|
|
esac
|
519 |
|
|
done
|
520 |
|
|
|
521 |
|
|
# Double-quote double-evaled strings.
|
522 |
|
|
for var in lt_decl_all_varnames([[ \
|
523 |
|
|
]], lt_decl_dquote_varnames); do
|
524 |
|
|
case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
|
525 |
|
|
*[[\\\\\\\`\\"\\\$]]*)
|
526 |
|
|
eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
|
527 |
|
|
;;
|
528 |
|
|
*)
|
529 |
|
|
eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
|
530 |
|
|
;;
|
531 |
|
|
esac
|
532 |
|
|
done
|
533 |
|
|
|
534 |
|
|
# Fix-up fallback echo if it was mangled by the above quoting rules.
|
535 |
|
|
case \$lt_ECHO in
|
536 |
|
|
*'\\\[$]0 --fallback-echo"')dnl "
|
537 |
|
|
lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
|
538 |
|
|
;;
|
539 |
|
|
esac
|
540 |
|
|
|
541 |
|
|
_LT_OUTPUT_LIBTOOL_INIT
|
542 |
|
|
])
|
543 |
|
|
|
544 |
|
|
|
545 |
|
|
# LT_OUTPUT
|
546 |
|
|
# ---------
|
547 |
|
|
# This macro allows early generation of the libtool script (before
|
548 |
|
|
# AC_OUTPUT is called), incase it is used in configure for compilation
|
549 |
|
|
# tests.
|
550 |
|
|
AC_DEFUN([LT_OUTPUT],
|
551 |
|
|
[: ${CONFIG_LT=./config.lt}
|
552 |
|
|
AC_MSG_NOTICE([creating $CONFIG_LT])
|
553 |
|
|
cat >"$CONFIG_LT" <<_LTEOF
|
554 |
|
|
#! $SHELL
|
555 |
|
|
# Generated by $as_me.
|
556 |
|
|
# Run this file to recreate a libtool stub with the current configuration.
|
557 |
|
|
|
558 |
|
|
lt_cl_silent=false
|
559 |
|
|
SHELL=\${CONFIG_SHELL-$SHELL}
|
560 |
|
|
_LTEOF
|
561 |
|
|
|
562 |
|
|
cat >>"$CONFIG_LT" <<\_LTEOF
|
563 |
|
|
AS_SHELL_SANITIZE
|
564 |
|
|
_AS_PREPARE
|
565 |
|
|
|
566 |
|
|
exec AS_MESSAGE_FD>&1
|
567 |
|
|
exec AS_MESSAGE_LOG_FD>>config.log
|
568 |
|
|
{
|
569 |
|
|
echo
|
570 |
|
|
AS_BOX([Running $as_me.])
|
571 |
|
|
} >&AS_MESSAGE_LOG_FD
|
572 |
|
|
|
573 |
|
|
lt_cl_help="\
|
574 |
|
|
\`$as_me' creates a local libtool stub from the current configuration,
|
575 |
|
|
for use in further configure time tests before the real libtool is
|
576 |
|
|
generated.
|
577 |
|
|
|
578 |
|
|
Usage: $[0] [[OPTIONS]]
|
579 |
|
|
|
580 |
|
|
-h, --help print this help, then exit
|
581 |
|
|
-V, --version print version number, then exit
|
582 |
|
|
-q, --quiet do not print progress messages
|
583 |
|
|
-d, --debug don't remove temporary files
|
584 |
|
|
|
585 |
|
|
Report bugs to <bug-libtool@gnu.org>."
|
586 |
|
|
|
587 |
|
|
lt_cl_version="\
|
588 |
|
|
m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
|
589 |
|
|
m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
|
590 |
|
|
configured by $[0], generated by m4_PACKAGE_STRING.
|
591 |
|
|
|
592 |
|
|
Copyright (C) 2007 Free Software Foundation, Inc.
|
593 |
|
|
This config.lt script is free software; the Free Software Foundation
|
594 |
|
|
gives unlimited permision to copy, distribute and modify it."
|
595 |
|
|
|
596 |
|
|
while test $[#] != 0
|
597 |
|
|
do
|
598 |
|
|
case $[1] in
|
599 |
|
|
--version | --v* | -V )
|
600 |
|
|
echo "$lt_cl_version"; exit 0 ;;
|
601 |
|
|
--help | --h* | -h )
|
602 |
|
|
echo "$lt_cl_help"; exit 0 ;;
|
603 |
|
|
--debug | --d* | -d )
|
604 |
|
|
debug=: ;;
|
605 |
|
|
--quiet | --q* | --silent | --s* | -q )
|
606 |
|
|
lt_cl_silent=: ;;
|
607 |
|
|
|
608 |
|
|
-*) AC_MSG_ERROR([unrecognized option: $[1]
|
609 |
|
|
Try `$[0] --help' for more information.]) ;;
|
610 |
|
|
|
611 |
|
|
*) AC_MSG_ERROR([unrecognized argument: $[1]
|
612 |
|
|
Try `$[0] --help for more information.]) ;;
|
613 |
|
|
esac
|
614 |
|
|
shift
|
615 |
|
|
done
|
616 |
|
|
|
617 |
|
|
if $lt_cl_silent; then
|
618 |
|
|
exec AS_MESSAGE_FD>/dev/null
|
619 |
|
|
fi
|
620 |
|
|
_LTEOF
|
621 |
|
|
|
622 |
|
|
cat >>"$CONFIG_LT" <<_LTEOF
|
623 |
|
|
_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
|
624 |
|
|
_LTEOF
|
625 |
|
|
|
626 |
|
|
cat >>"$CONFIG_LT" <<\_LTEOF
|
627 |
|
|
AC_MSG_NOTICE([creating $ofile])
|
628 |
|
|
_LT_OUTPUT_LIBTOOL_COMMANDS
|
629 |
|
|
AS_EXIT(0)
|
630 |
|
|
_LTEOF
|
631 |
|
|
chmod +x "$CONFIG_LT"
|
632 |
|
|
|
633 |
|
|
# configure is writing to config.log, but config.lt does its own redirection,
|
634 |
|
|
# appending to config.log, which fails on DOS, as config.log is still kept
|
635 |
|
|
# open by configure. Here we exec the FD to /dev/null, effectively closing
|
636 |
|
|
# config.log, so it can be properly (re)opened and appended to by config.lt.
|
637 |
|
|
if test "$no_create" != yes; then
|
638 |
|
|
lt_cl_success=:
|
639 |
|
|
test "$silent" = yes &&
|
640 |
|
|
lt_config_lt_args="$lt_config_lt_args --quiet"
|
641 |
|
|
exec AS_MESSAGE_LOG_FD>/dev/null
|
642 |
|
|
$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
|
643 |
|
|
exec AS_MESSAGE_LOG_FD>>config.log
|
644 |
|
|
$lt_cl_success || AS_EXIT(1)
|
645 |
|
|
fi
|
646 |
|
|
])# LT_OUTPUT
|
647 |
|
|
|
648 |
|
|
|
649 |
|
|
# _LT_CONFIG(TAG)
|
650 |
|
|
# ---------------
|
651 |
|
|
# If TAG is the built-in tag, create an initial libtool script with a
|
652 |
|
|
# default configuration from the untagged config vars. Otherwise add code
|
653 |
|
|
# to config.status for appending the configuration named by TAG from the
|
654 |
|
|
# matching tagged config vars.
|
655 |
|
|
m4_defun([_LT_CONFIG],
|
656 |
|
|
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
657 |
|
|
_LT_CONFIG_SAVE_COMMANDS([
|
658 |
|
|
m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
|
659 |
|
|
m4_if(_LT_TAG, [C], [
|
660 |
|
|
# See if we are running on zsh, and set the options which allow our
|
661 |
|
|
# commands through without removal of \ escapes.
|
662 |
|
|
if test -n "${ZSH_VERSION+set}" ; then
|
663 |
|
|
setopt NO_GLOB_SUBST
|
664 |
|
|
fi
|
665 |
|
|
|
666 |
|
|
cfgfile="${ofile}T"
|
667 |
|
|
trap "$RM \"$cfgfile\"; exit 1" 1 2 15
|
668 |
|
|
$RM "$cfgfile"
|
669 |
|
|
|
670 |
|
|
cat <<_LT_EOF >> "$cfgfile"
|
671 |
|
|
#! $SHELL
|
672 |
|
|
|
673 |
|
|
# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
|
674 |
|
|
# Generated automatically by $as_me (GNU $PACKAGE$TIMESTAMP) $VERSION
|
675 |
|
|
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
|
676 |
|
|
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
|
677 |
|
|
#
|
678 |
|
|
_LT_COPYING
|
679 |
|
|
_LT_LIBTOOL_TAGS
|
680 |
|
|
|
681 |
|
|
# ### BEGIN LIBTOOL CONFIG
|
682 |
|
|
_LT_LIBTOOL_CONFIG_VARS
|
683 |
|
|
_LT_LIBTOOL_TAG_VARS
|
684 |
|
|
# ### END LIBTOOL CONFIG
|
685 |
|
|
|
686 |
|
|
_LT_EOF
|
687 |
|
|
|
688 |
|
|
case $host_os in
|
689 |
|
|
aix3*)
|
690 |
|
|
cat <<\_LT_EOF >> "$cfgfile"
|
691 |
|
|
# AIX sometimes has problems with the GCC collect2 program. For some
|
692 |
|
|
# reason, if we set the COLLECT_NAMES environment variable, the problems
|
693 |
|
|
# vanish in a puff of smoke.
|
694 |
|
|
if test "X${COLLECT_NAMES+set}" != Xset; then
|
695 |
|
|
COLLECT_NAMES=
|
696 |
|
|
export COLLECT_NAMES
|
697 |
|
|
fi
|
698 |
|
|
_LT_EOF
|
699 |
|
|
;;
|
700 |
|
|
esac
|
701 |
|
|
|
702 |
|
|
_LT_PROG_LTMAIN
|
703 |
|
|
|
704 |
|
|
# We use sed instead of cat because bash on DJGPP gets confused if
|
705 |
|
|
# if finds mixed CR/LF and LF-only lines. Since sed operates in
|
706 |
|
|
# text mode, it properly converts lines to CR/LF. This bash problem
|
707 |
|
|
# is reportedly fixed, but why not run on old versions too?
|
708 |
|
|
sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
|
709 |
|
|
|| (rm -f "$cfgfile"; exit 1)
|
710 |
|
|
|
711 |
|
|
_LT_PROG_XSI_SHELLFNS
|
712 |
|
|
|
713 |
|
|
sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
|
714 |
|
|
|| (rm -f "$cfgfile"; exit 1)
|
715 |
|
|
|
716 |
|
|
mv -f "$cfgfile" "$ofile" ||
|
717 |
|
|
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
|
718 |
|
|
chmod +x "$ofile"
|
719 |
|
|
],
|
720 |
|
|
[cat <<_LT_EOF >> "$ofile"
|
721 |
|
|
|
722 |
|
|
dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
|
723 |
|
|
dnl in a comment (ie after a #).
|
724 |
|
|
# ### BEGIN LIBTOOL TAG CONFIG: $1
|
725 |
|
|
_LT_LIBTOOL_TAG_VARS(_LT_TAG)
|
726 |
|
|
# ### END LIBTOOL TAG CONFIG: $1
|
727 |
|
|
_LT_EOF
|
728 |
|
|
])dnl /m4_if
|
729 |
|
|
],
|
730 |
|
|
[m4_if([$1], [], [
|
731 |
|
|
PACKAGE='$PACKAGE'
|
732 |
|
|
VERSION='$VERSION'
|
733 |
|
|
TIMESTAMP='$TIMESTAMP'
|
734 |
|
|
RM='$RM'
|
735 |
|
|
ofile='$ofile'], [])
|
736 |
|
|
])dnl /_LT_CONFIG_SAVE_COMMANDS
|
737 |
|
|
])# _LT_CONFIG
|
738 |
|
|
|
739 |
|
|
|
740 |
|
|
# LT_SUPPORTED_TAG(TAG)
|
741 |
|
|
# ---------------------
|
742 |
|
|
# Trace this macro to discover what tags are supported by the libtool
|
743 |
|
|
# --tag option, using:
|
744 |
|
|
# autoconf --trace 'LT_SUPPORTED_TAG:$1'
|
745 |
|
|
AC_DEFUN([LT_SUPPORTED_TAG], [])
|
746 |
|
|
|
747 |
|
|
|
748 |
|
|
# C support is built-in for now
|
749 |
|
|
m4_define([_LT_LANG_C_enabled], [])
|
750 |
|
|
m4_define([_LT_TAGS], [])
|
751 |
|
|
|
752 |
|
|
|
753 |
|
|
# LT_LANG(LANG)
|
754 |
|
|
# -------------
|
755 |
|
|
# Enable libtool support for the given language if not already enabled.
|
756 |
|
|
AC_DEFUN([LT_LANG],
|
757 |
|
|
[AC_BEFORE([$0], [LT_OUTPUT])dnl
|
758 |
|
|
m4_case([$1],
|
759 |
|
|
[C], [_LT_LANG(C)],
|
760 |
|
|
[C++], [_LT_LANG(CXX)],
|
761 |
|
|
[Java], [_LT_LANG(GCJ)],
|
762 |
|
|
[Fortran 77], [_LT_LANG(F77)],
|
763 |
|
|
[Fortran], [_LT_LANG(FC)],
|
764 |
|
|
[Windows Resource], [_LT_LANG(RC)],
|
765 |
|
|
[m4_ifdef([_LT_LANG_]$1[_CONFIG],
|
766 |
|
|
[_LT_LANG($1)],
|
767 |
|
|
[m4_fatal([$0: unsupported language: "$1"])])])dnl
|
768 |
|
|
])# LT_LANG
|
769 |
|
|
|
770 |
|
|
|
771 |
|
|
# _LT_LANG(LANGNAME)
|
772 |
|
|
# ------------------
|
773 |
|
|
m4_defun([_LT_LANG],
|
774 |
|
|
[m4_ifdef([_LT_LANG_]$1[_enabled], [],
|
775 |
|
|
[LT_SUPPORTED_TAG([$1])dnl
|
776 |
|
|
m4_append([_LT_TAGS], [$1 ])dnl
|
777 |
|
|
m4_define([_LT_LANG_]$1[_enabled], [])dnl
|
778 |
|
|
_LT_LANG_$1_CONFIG($1)])dnl
|
779 |
|
|
])# _LT_LANG
|
780 |
|
|
|
781 |
|
|
|
782 |
|
|
# _LT_LANG_DEFAULT_CONFIG
|
783 |
|
|
# -----------------------
|
784 |
|
|
m4_defun([_LT_LANG_DEFAULT_CONFIG],
|
785 |
|
|
[AC_PROVIDE_IFELSE([AC_PROG_CXX],
|
786 |
|
|
[LT_LANG(CXX)],
|
787 |
|
|
[m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
|
788 |
|
|
|
789 |
|
|
AC_PROVIDE_IFELSE([AC_PROG_F77],
|
790 |
|
|
[LT_LANG(F77)],
|
791 |
|
|
[m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
|
792 |
|
|
|
793 |
|
|
AC_PROVIDE_IFELSE([AC_PROG_FC],
|
794 |
|
|
[LT_LANG(FC)],
|
795 |
|
|
[m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
|
796 |
|
|
|
797 |
|
|
dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
|
798 |
|
|
dnl pulling things in needlessly.
|
799 |
|
|
AC_PROVIDE_IFELSE([AC_PROG_GCJ],
|
800 |
|
|
[LT_LANG(GCJ)],
|
801 |
|
|
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
|
802 |
|
|
[LT_LANG(GCJ)],
|
803 |
|
|
[AC_PROVIDE_IFELSE([LT_PROG_GCJ],
|
804 |
|
|
[LT_LANG(GCJ)],
|
805 |
|
|
[m4_ifdef([AC_PROG_GCJ],
|
806 |
|
|
[m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
|
807 |
|
|
m4_ifdef([A][M_PROG_GCJ],
|
808 |
|
|
[m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
|
809 |
|
|
m4_ifdef([LT_PROG_GCJ],
|
810 |
|
|
[m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
|
811 |
|
|
|
812 |
|
|
AC_PROVIDE_IFELSE([LT_PROG_RC],
|
813 |
|
|
[LT_LANG(RC)],
|
814 |
|
|
[m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
|
815 |
|
|
])# _LT_LANG_DEFAULT_CONFIG
|
816 |
|
|
|
817 |
|
|
# Obsolete macros:
|
818 |
|
|
AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
|
819 |
|
|
AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
|
820 |
|
|
AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
|
821 |
|
|
AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
|
822 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
823 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
|
824 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_F77], [])
|
825 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_FC], [])
|
826 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
|
827 |
|
|
|
828 |
|
|
|
829 |
|
|
# _LT_TAG_COMPILER
|
830 |
|
|
# ----------------
|
831 |
|
|
m4_defun([_LT_TAG_COMPILER],
|
832 |
|
|
[AC_REQUIRE([AC_PROG_CC])dnl
|
833 |
|
|
|
834 |
|
|
_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
|
835 |
|
|
_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
|
836 |
|
|
_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
|
837 |
|
|
_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
|
838 |
|
|
|
839 |
|
|
# If no C compiler was specified, use CC.
|
840 |
|
|
LTCC=${LTCC-"$CC"}
|
841 |
|
|
|
842 |
|
|
# If no C compiler flags were specified, use CFLAGS.
|
843 |
|
|
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
|
844 |
|
|
|
845 |
|
|
# Allow CC to be a program name with arguments.
|
846 |
|
|
compiler=$CC
|
847 |
|
|
])# _LT_TAG_COMPILER
|
848 |
|
|
|
849 |
|
|
|
850 |
|
|
# _LT_COMPILER_BOILERPLATE
|
851 |
|
|
# ------------------------
|
852 |
|
|
# Check for compiler boilerplate output or warnings with
|
853 |
|
|
# the simple compiler test code.
|
854 |
|
|
m4_defun([_LT_COMPILER_BOILERPLATE],
|
855 |
|
|
[m4_require([_LT_DECL_SED])dnl
|
856 |
|
|
ac_outfile=conftest.$ac_objext
|
857 |
|
|
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
|
858 |
|
|
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
|
859 |
|
|
_lt_compiler_boilerplate=`cat conftest.err`
|
860 |
|
|
$RM conftest*
|
861 |
|
|
])# _LT_COMPILER_BOILERPLATE
|
862 |
|
|
|
863 |
|
|
|
864 |
|
|
# _LT_LINKER_BOILERPLATE
|
865 |
|
|
# ----------------------
|
866 |
|
|
# Check for linker boilerplate output or warnings with
|
867 |
|
|
# the simple link test code.
|
868 |
|
|
m4_defun([_LT_LINKER_BOILERPLATE],
|
869 |
|
|
[m4_require([_LT_DECL_SED])dnl
|
870 |
|
|
ac_outfile=conftest.$ac_objext
|
871 |
|
|
echo "$lt_simple_link_test_code" >conftest.$ac_ext
|
872 |
|
|
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
|
873 |
|
|
_lt_linker_boilerplate=`cat conftest.err`
|
874 |
|
|
$RM conftest*
|
875 |
|
|
])# _LT_LINKER_BOILERPLATE
|
876 |
|
|
|
877 |
|
|
|
878 |
|
|
# _LT_SYS_MODULE_PATH_AIX
|
879 |
|
|
# -----------------------
|
880 |
|
|
# Links a minimal program and checks the executable
|
881 |
|
|
# for the system default hardcoded library path. In most cases,
|
882 |
|
|
# this is /usr/lib:/lib, but when the MPI compilers are used
|
883 |
|
|
# the location of the communication and MPI libs are included too.
|
884 |
|
|
# If we don't find anything, use the default library path according
|
885 |
|
|
# to the aix ld manual.
|
886 |
|
|
m4_defun([_LT_SYS_MODULE_PATH_AIX],
|
887 |
|
|
[m4_require([_LT_DECL_SED])dnl
|
888 |
|
|
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
|
889 |
|
|
lt_aix_libpath_sed='
|
890 |
|
|
/Import File Strings/,/^$/ {
|
891 |
|
|
/^0/ {
|
892 |
|
|
s/^0 *\(.*\)$/\1/
|
893 |
|
|
p
|
894 |
|
|
}
|
895 |
|
|
}'
|
896 |
|
|
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
|
897 |
|
|
# Check for a 64-bit object if we didn't find anything.
|
898 |
|
|
if test -z "$aix_libpath"; then
|
899 |
|
|
aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
|
900 |
|
|
fi],[])
|
901 |
|
|
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
|
902 |
|
|
])# _LT_SYS_MODULE_PATH_AIX
|
903 |
|
|
|
904 |
|
|
|
905 |
|
|
# _LT_SHELL_INIT(ARG)
|
906 |
|
|
# -------------------
|
907 |
|
|
m4_define([_LT_SHELL_INIT],
|
908 |
|
|
[ifdef([AC_DIVERSION_NOTICE],
|
909 |
|
|
[AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
|
910 |
|
|
[AC_DIVERT_PUSH(NOTICE)])
|
911 |
|
|
$1
|
912 |
|
|
AC_DIVERT_POP
|
913 |
|
|
])# _LT_SHELL_INIT
|
914 |
|
|
|
915 |
|
|
|
916 |
|
|
# _LT_PROG_ECHO_BACKSLASH
|
917 |
|
|
# -----------------------
|
918 |
|
|
# Add some code to the start of the generated configure script which
|
919 |
|
|
# will find an echo command which doesn't interpret backslashes.
|
920 |
|
|
m4_defun([_LT_PROG_ECHO_BACKSLASH],
|
921 |
|
|
[_LT_SHELL_INIT([
|
922 |
|
|
# Check that we are running under the correct shell.
|
923 |
|
|
SHELL=${CONFIG_SHELL-/bin/sh}
|
924 |
|
|
|
925 |
|
|
case X$lt_ECHO in
|
926 |
|
|
X*--fallback-echo)
|
927 |
|
|
# Remove one level of quotation (which was required for Make).
|
928 |
|
|
ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
|
929 |
|
|
;;
|
930 |
|
|
esac
|
931 |
|
|
|
932 |
|
|
ECHO=${lt_ECHO-echo}
|
933 |
|
|
if test "X[$]1" = X--no-reexec; then
|
934 |
|
|
# Discard the --no-reexec flag, and continue.
|
935 |
|
|
shift
|
936 |
|
|
elif test "X[$]1" = X--fallback-echo; then
|
937 |
|
|
# Avoid inline document here, it may be left over
|
938 |
|
|
:
|
939 |
|
|
elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
|
940 |
|
|
# Yippee, $ECHO works!
|
941 |
|
|
:
|
942 |
|
|
else
|
943 |
|
|
# Restart under the correct shell.
|
944 |
|
|
exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
|
945 |
|
|
fi
|
946 |
|
|
|
947 |
|
|
if test "X[$]1" = X--fallback-echo; then
|
948 |
|
|
# used as fallback echo
|
949 |
|
|
shift
|
950 |
|
|
cat <<_LT_EOF
|
951 |
|
|
[$]*
|
952 |
|
|
_LT_EOF
|
953 |
|
|
exit 0
|
954 |
|
|
fi
|
955 |
|
|
|
956 |
|
|
# The HP-UX ksh and POSIX shell print the target directory to stdout
|
957 |
|
|
# if CDPATH is set.
|
958 |
|
|
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
|
959 |
|
|
|
960 |
|
|
if test -z "$lt_ECHO"; then
|
961 |
|
|
if test "X${echo_test_string+set}" != Xset; then
|
962 |
|
|
# find a string as large as possible, as long as the shell can cope with it
|
963 |
|
|
for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
|
964 |
|
|
# expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
|
965 |
|
|
if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
|
966 |
|
|
{ test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
|
967 |
|
|
then
|
968 |
|
|
break
|
969 |
|
|
fi
|
970 |
|
|
done
|
971 |
|
|
fi
|
972 |
|
|
|
973 |
|
|
if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
|
974 |
|
|
echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
|
975 |
|
|
test "X$echo_testing_string" = "X$echo_test_string"; then
|
976 |
|
|
:
|
977 |
|
|
else
|
978 |
|
|
# The Solaris, AIX, and Digital Unix default echo programs unquote
|
979 |
|
|
# backslashes. This makes it impossible to quote backslashes using
|
980 |
|
|
# echo "$something" | sed 's/\\/\\\\/g'
|
981 |
|
|
#
|
982 |
|
|
# So, first we look for a working echo in the user's PATH.
|
983 |
|
|
|
984 |
|
|
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
985 |
|
|
for dir in $PATH /usr/ucb; do
|
986 |
|
|
IFS="$lt_save_ifs"
|
987 |
|
|
if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
|
988 |
|
|
test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
|
989 |
|
|
echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
|
990 |
|
|
test "X$echo_testing_string" = "X$echo_test_string"; then
|
991 |
|
|
ECHO="$dir/echo"
|
992 |
|
|
break
|
993 |
|
|
fi
|
994 |
|
|
done
|
995 |
|
|
IFS="$lt_save_ifs"
|
996 |
|
|
|
997 |
|
|
if test "X$ECHO" = Xecho; then
|
998 |
|
|
# We didn't find a better echo, so look for alternatives.
|
999 |
|
|
if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
|
1000 |
|
|
echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
|
1001 |
|
|
test "X$echo_testing_string" = "X$echo_test_string"; then
|
1002 |
|
|
# This shell has a builtin print -r that does the trick.
|
1003 |
|
|
ECHO='print -r'
|
1004 |
|
|
elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
|
1005 |
|
|
test "X$CONFIG_SHELL" != X/bin/ksh; then
|
1006 |
|
|
# If we have ksh, try running configure again with it.
|
1007 |
|
|
ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
|
1008 |
|
|
export ORIGINAL_CONFIG_SHELL
|
1009 |
|
|
CONFIG_SHELL=/bin/ksh
|
1010 |
|
|
export CONFIG_SHELL
|
1011 |
|
|
exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
|
1012 |
|
|
else
|
1013 |
|
|
# Try using printf.
|
1014 |
|
|
ECHO='printf %s\n'
|
1015 |
|
|
if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
|
1016 |
|
|
echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
|
1017 |
|
|
test "X$echo_testing_string" = "X$echo_test_string"; then
|
1018 |
|
|
# Cool, printf works
|
1019 |
|
|
:
|
1020 |
|
|
elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
|
1021 |
|
|
test "X$echo_testing_string" = 'X\t' &&
|
1022 |
|
|
echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
|
1023 |
|
|
test "X$echo_testing_string" = "X$echo_test_string"; then
|
1024 |
|
|
CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
|
1025 |
|
|
export CONFIG_SHELL
|
1026 |
|
|
SHELL="$CONFIG_SHELL"
|
1027 |
|
|
export SHELL
|
1028 |
|
|
ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
|
1029 |
|
|
elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
|
1030 |
|
|
test "X$echo_testing_string" = 'X\t' &&
|
1031 |
|
|
echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
|
1032 |
|
|
test "X$echo_testing_string" = "X$echo_test_string"; then
|
1033 |
|
|
ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
|
1034 |
|
|
else
|
1035 |
|
|
# maybe with a smaller string...
|
1036 |
|
|
prev=:
|
1037 |
|
|
|
1038 |
|
|
for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
|
1039 |
|
|
if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
|
1040 |
|
|
then
|
1041 |
|
|
break
|
1042 |
|
|
fi
|
1043 |
|
|
prev="$cmd"
|
1044 |
|
|
done
|
1045 |
|
|
|
1046 |
|
|
if test "$prev" != 'sed 50q "[$]0"'; then
|
1047 |
|
|
echo_test_string=`eval $prev`
|
1048 |
|
|
export echo_test_string
|
1049 |
|
|
exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
|
1050 |
|
|
else
|
1051 |
|
|
# Oops. We lost completely, so just stick with echo.
|
1052 |
|
|
ECHO=echo
|
1053 |
|
|
fi
|
1054 |
|
|
fi
|
1055 |
|
|
fi
|
1056 |
|
|
fi
|
1057 |
|
|
fi
|
1058 |
|
|
fi
|
1059 |
|
|
|
1060 |
|
|
# Copy echo and quote the copy suitably for passing to libtool from
|
1061 |
|
|
# the Makefile, instead of quoting the original, which is used later.
|
1062 |
|
|
lt_ECHO=$ECHO
|
1063 |
|
|
if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
|
1064 |
|
|
lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
|
1065 |
|
|
fi
|
1066 |
|
|
|
1067 |
|
|
AC_SUBST(lt_ECHO)
|
1068 |
|
|
])
|
1069 |
|
|
_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
|
1070 |
|
|
_LT_DECL([], [ECHO], [1],
|
1071 |
|
|
[An echo program that does not interpret backslashes])
|
1072 |
|
|
])# _LT_PROG_ECHO_BACKSLASH
|
1073 |
|
|
|
1074 |
|
|
|
1075 |
|
|
# _LT_ENABLE_LOCK
|
1076 |
|
|
# ---------------
|
1077 |
|
|
m4_defun([_LT_ENABLE_LOCK],
|
1078 |
|
|
[AC_REQUIRE([AC_OBJEXT])dnl
|
1079 |
|
|
AC_ARG_ENABLE([libtool-lock],
|
1080 |
|
|
[AS_HELP_STRING([--disable-libtool-lock],
|
1081 |
|
|
[avoid locking (might break parallel builds)])])
|
1082 |
|
|
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
|
1083 |
|
|
|
1084 |
|
|
# Some flags need to be propagated to the compiler or linker for good
|
1085 |
|
|
# libtool support.
|
1086 |
|
|
case $host in
|
1087 |
|
|
ia64-*-hpux*)
|
1088 |
|
|
# Find out which ABI we are using.
|
1089 |
|
|
echo 'int i;' > conftest.$ac_ext
|
1090 |
|
|
if AC_TRY_EVAL(ac_compile); then
|
1091 |
|
|
case `/usr/bin/file conftest.$ac_objext` in
|
1092 |
|
|
*ELF-32*)
|
1093 |
|
|
HPUX_IA64_MODE="32"
|
1094 |
|
|
;;
|
1095 |
|
|
*ELF-64*)
|
1096 |
|
|
HPUX_IA64_MODE="64"
|
1097 |
|
|
;;
|
1098 |
|
|
esac
|
1099 |
|
|
fi
|
1100 |
|
|
rm -rf conftest*
|
1101 |
|
|
;;
|
1102 |
|
|
*-*-irix6*)
|
1103 |
|
|
# Find out which ABI we are using.
|
1104 |
|
|
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
|
1105 |
|
|
if AC_TRY_EVAL(ac_compile); then
|
1106 |
|
|
if test "$lt_cv_prog_gnu_ld" = yes; then
|
1107 |
|
|
case `/usr/bin/file conftest.$ac_objext` in
|
1108 |
|
|
*32-bit*)
|
1109 |
|
|
LD="${LD-ld} -melf32bsmip"
|
1110 |
|
|
;;
|
1111 |
|
|
*N32*)
|
1112 |
|
|
LD="${LD-ld} -melf32bmipn32"
|
1113 |
|
|
;;
|
1114 |
|
|
*64-bit*)
|
1115 |
|
|
LD="${LD-ld} -melf64bmip"
|
1116 |
|
|
;;
|
1117 |
|
|
esac
|
1118 |
|
|
else
|
1119 |
|
|
case `/usr/bin/file conftest.$ac_objext` in
|
1120 |
|
|
*32-bit*)
|
1121 |
|
|
LD="${LD-ld} -32"
|
1122 |
|
|
;;
|
1123 |
|
|
*N32*)
|
1124 |
|
|
LD="${LD-ld} -n32"
|
1125 |
|
|
;;
|
1126 |
|
|
*64-bit*)
|
1127 |
|
|
LD="${LD-ld} -64"
|
1128 |
|
|
;;
|
1129 |
|
|
esac
|
1130 |
|
|
fi
|
1131 |
|
|
fi
|
1132 |
|
|
rm -rf conftest*
|
1133 |
|
|
;;
|
1134 |
|
|
|
1135 |
|
|
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
|
1136 |
|
|
s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
|
1137 |
|
|
# Find out which ABI we are using.
|
1138 |
|
|
echo 'int i;' > conftest.$ac_ext
|
1139 |
|
|
if AC_TRY_EVAL(ac_compile); then
|
1140 |
|
|
case `/usr/bin/file conftest.o` in
|
1141 |
|
|
*32-bit*)
|
1142 |
|
|
case $host in
|
1143 |
|
|
x86_64-*kfreebsd*-gnu)
|
1144 |
|
|
LD="${LD-ld} -m elf_i386_fbsd"
|
1145 |
|
|
;;
|
1146 |
|
|
x86_64-*linux*)
|
1147 |
|
|
LD="${LD-ld} -m elf_i386"
|
1148 |
|
|
;;
|
1149 |
|
|
ppc64-*linux*|powerpc64-*linux*)
|
1150 |
|
|
LD="${LD-ld} -m elf32ppclinux"
|
1151 |
|
|
;;
|
1152 |
|
|
s390x-*linux*)
|
1153 |
|
|
LD="${LD-ld} -m elf_s390"
|
1154 |
|
|
;;
|
1155 |
|
|
sparc64-*linux*)
|
1156 |
|
|
LD="${LD-ld} -m elf32_sparc"
|
1157 |
|
|
;;
|
1158 |
|
|
esac
|
1159 |
|
|
;;
|
1160 |
|
|
*64-bit*)
|
1161 |
|
|
case $host in
|
1162 |
|
|
x86_64-*kfreebsd*-gnu)
|
1163 |
|
|
LD="${LD-ld} -m elf_x86_64_fbsd"
|
1164 |
|
|
;;
|
1165 |
|
|
x86_64-*linux*)
|
1166 |
|
|
LD="${LD-ld} -m elf_x86_64"
|
1167 |
|
|
;;
|
1168 |
|
|
ppc*-*linux*|powerpc*-*linux*)
|
1169 |
|
|
LD="${LD-ld} -m elf64ppc"
|
1170 |
|
|
;;
|
1171 |
|
|
s390*-*linux*|s390*-*tpf*)
|
1172 |
|
|
LD="${LD-ld} -m elf64_s390"
|
1173 |
|
|
;;
|
1174 |
|
|
sparc*-*linux*)
|
1175 |
|
|
LD="${LD-ld} -m elf64_sparc"
|
1176 |
|
|
;;
|
1177 |
|
|
esac
|
1178 |
|
|
;;
|
1179 |
|
|
esac
|
1180 |
|
|
fi
|
1181 |
|
|
rm -rf conftest*
|
1182 |
|
|
;;
|
1183 |
|
|
|
1184 |
|
|
*-*-sco3.2v5*)
|
1185 |
|
|
# On SCO OpenServer 5, we need -belf to get full-featured binaries.
|
1186 |
|
|
SAVE_CFLAGS="$CFLAGS"
|
1187 |
|
|
CFLAGS="$CFLAGS -belf"
|
1188 |
|
|
AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
|
1189 |
|
|
[AC_LANG_PUSH(C)
|
1190 |
|
|
AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
|
1191 |
|
|
AC_LANG_POP])
|
1192 |
|
|
if test x"$lt_cv_cc_needs_belf" != x"yes"; then
|
1193 |
|
|
# this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
|
1194 |
|
|
CFLAGS="$SAVE_CFLAGS"
|
1195 |
|
|
fi
|
1196 |
|
|
;;
|
1197 |
|
|
sparc*-*solaris*)
|
1198 |
|
|
# Find out which ABI we are using.
|
1199 |
|
|
echo 'int i;' > conftest.$ac_ext
|
1200 |
|
|
if AC_TRY_EVAL(ac_compile); then
|
1201 |
|
|
case `/usr/bin/file conftest.o` in
|
1202 |
|
|
*64-bit*)
|
1203 |
|
|
case $lt_cv_prog_gnu_ld in
|
1204 |
|
|
yes*) LD="${LD-ld} -m elf64_sparc" ;;
|
1205 |
|
|
*) LD="${LD-ld} -64" ;;
|
1206 |
|
|
esac
|
1207 |
|
|
;;
|
1208 |
|
|
esac
|
1209 |
|
|
fi
|
1210 |
|
|
rm -rf conftest*
|
1211 |
|
|
;;
|
1212 |
|
|
esac
|
1213 |
|
|
|
1214 |
|
|
need_locks="$enable_libtool_lock"
|
1215 |
|
|
])# _LT_ENABLE_LOCK
|
1216 |
|
|
|
1217 |
|
|
|
1218 |
|
|
# _LT_CMD_OLD_ARCHIVE
|
1219 |
|
|
# -------------------
|
1220 |
|
|
m4_defun([_LT_CMD_OLD_ARCHIVE],
|
1221 |
|
|
[AC_CHECK_TOOL(AR, ar, false)
|
1222 |
|
|
test -z "$AR" && AR=ar
|
1223 |
|
|
test -z "$AR_FLAGS" && AR_FLAGS=cru
|
1224 |
|
|
_LT_DECL([], [AR], [1], [The archiver])
|
1225 |
|
|
_LT_DECL([], [AR_FLAGS], [1])
|
1226 |
|
|
|
1227 |
|
|
AC_CHECK_TOOL(STRIP, strip, :)
|
1228 |
|
|
test -z "$STRIP" && STRIP=:
|
1229 |
|
|
_LT_DECL([], [STRIP], [1], [A symbol stripping program])
|
1230 |
|
|
|
1231 |
|
|
AC_CHECK_TOOL(RANLIB, ranlib, :)
|
1232 |
|
|
test -z "$RANLIB" && RANLIB=:
|
1233 |
|
|
_LT_DECL([], [RANLIB], [1],
|
1234 |
|
|
[Commands used to install an old-style archive])
|
1235 |
|
|
|
1236 |
|
|
# Determine commands to create old-style static archives.
|
1237 |
|
|
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
|
1238 |
|
|
old_postinstall_cmds='chmod 644 $oldlib'
|
1239 |
|
|
old_postuninstall_cmds=
|
1240 |
|
|
|
1241 |
|
|
if test -n "$RANLIB"; then
|
1242 |
|
|
case $host_os in
|
1243 |
|
|
openbsd*)
|
1244 |
|
|
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
|
1245 |
|
|
;;
|
1246 |
|
|
*)
|
1247 |
|
|
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
|
1248 |
|
|
;;
|
1249 |
|
|
esac
|
1250 |
|
|
old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
|
1251 |
|
|
fi
|
1252 |
|
|
_LT_DECL([], [old_postinstall_cmds], [2])
|
1253 |
|
|
_LT_DECL([], [old_postuninstall_cmds], [2])
|
1254 |
|
|
_LT_TAGDECL([], [old_archive_cmds], [2],
|
1255 |
|
|
[Commands used to build an old-style archive])
|
1256 |
|
|
])# _LT_CMD_OLD_ARCHIVE
|
1257 |
|
|
|
1258 |
|
|
|
1259 |
|
|
# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
|
1260 |
|
|
# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
|
1261 |
|
|
# ----------------------------------------------------------------
|
1262 |
|
|
# Check whether the given compiler option works
|
1263 |
|
|
AC_DEFUN([_LT_COMPILER_OPTION],
|
1264 |
|
|
[AC_REQUIRE([AC_OBJEXT])dnl
|
1265 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
1266 |
|
|
m4_require([_LT_DECL_SED])dnl
|
1267 |
|
|
AC_CACHE_CHECK([$1], [$2],
|
1268 |
|
|
[$2=no
|
1269 |
|
|
m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
|
1270 |
|
|
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
|
1271 |
|
|
lt_compiler_flag="$3"
|
1272 |
|
|
# Insert the option either (1) after the last *FLAGS variable, or
|
1273 |
|
|
# (2) before a word containing "conftest.", or (3) at the end.
|
1274 |
|
|
# Note that $ac_compile itself does not contain backslashes and begins
|
1275 |
|
|
# with a dollar sign (not a hyphen), so the echo should work correctly.
|
1276 |
|
|
# The option is referenced via a variable to avoid confusing sed.
|
1277 |
|
|
lt_compile=`echo "$ac_compile" | $SED \
|
1278 |
|
|
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
|
1279 |
|
|
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
|
1280 |
|
|
-e 's:$: $lt_compiler_flag:'`
|
1281 |
|
|
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
|
1282 |
|
|
(eval "$lt_compile" 2>conftest.err)
|
1283 |
|
|
ac_status=$?
|
1284 |
|
|
cat conftest.err >&AS_MESSAGE_LOG_FD
|
1285 |
|
|
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
|
1286 |
|
|
if (exit $ac_status) && test -s "$ac_outfile"; then
|
1287 |
|
|
# The compiler can only warn and ignore the option if not recognized
|
1288 |
|
|
# So say no if there are warnings other than the usual output.
|
1289 |
|
|
$ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
|
1290 |
|
|
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
|
1291 |
|
|
if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
|
1292 |
|
|
$2=yes
|
1293 |
|
|
fi
|
1294 |
|
|
fi
|
1295 |
|
|
$RM conftest*
|
1296 |
|
|
])
|
1297 |
|
|
|
1298 |
|
|
if test x"[$]$2" = xyes; then
|
1299 |
|
|
m4_if([$5], , :, [$5])
|
1300 |
|
|
else
|
1301 |
|
|
m4_if([$6], , :, [$6])
|
1302 |
|
|
fi
|
1303 |
|
|
])# _LT_COMPILER_OPTION
|
1304 |
|
|
|
1305 |
|
|
# Old name:
|
1306 |
|
|
AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
|
1307 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
1308 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
|
1309 |
|
|
|
1310 |
|
|
|
1311 |
|
|
# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
|
1312 |
|
|
# [ACTION-SUCCESS], [ACTION-FAILURE])
|
1313 |
|
|
# ----------------------------------------------------
|
1314 |
|
|
# Check whether the given linker option works
|
1315 |
|
|
AC_DEFUN([_LT_LINKER_OPTION],
|
1316 |
|
|
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
1317 |
|
|
m4_require([_LT_DECL_SED])dnl
|
1318 |
|
|
AC_CACHE_CHECK([$1], [$2],
|
1319 |
|
|
[$2=no
|
1320 |
|
|
save_LDFLAGS="$LDFLAGS"
|
1321 |
|
|
LDFLAGS="$LDFLAGS $3"
|
1322 |
|
|
echo "$lt_simple_link_test_code" > conftest.$ac_ext
|
1323 |
|
|
if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
|
1324 |
|
|
# The linker can only warn and ignore the option if not recognized
|
1325 |
|
|
# So say no if there are warnings
|
1326 |
|
|
if test -s conftest.err; then
|
1327 |
|
|
# Append any errors to the config.log.
|
1328 |
|
|
cat conftest.err 1>&AS_MESSAGE_LOG_FD
|
1329 |
|
|
$ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
|
1330 |
|
|
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
|
1331 |
|
|
if diff conftest.exp conftest.er2 >/dev/null; then
|
1332 |
|
|
$2=yes
|
1333 |
|
|
fi
|
1334 |
|
|
else
|
1335 |
|
|
$2=yes
|
1336 |
|
|
fi
|
1337 |
|
|
fi
|
1338 |
|
|
$RM conftest*
|
1339 |
|
|
LDFLAGS="$save_LDFLAGS"
|
1340 |
|
|
])
|
1341 |
|
|
|
1342 |
|
|
if test x"[$]$2" = xyes; then
|
1343 |
|
|
m4_if([$4], , :, [$4])
|
1344 |
|
|
else
|
1345 |
|
|
m4_if([$5], , :, [$5])
|
1346 |
|
|
fi
|
1347 |
|
|
])# _LT_LINKER_OPTION
|
1348 |
|
|
|
1349 |
|
|
# Old name:
|
1350 |
|
|
AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
|
1351 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
1352 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
|
1353 |
|
|
|
1354 |
|
|
|
1355 |
|
|
# LT_CMD_MAX_LEN
|
1356 |
|
|
#---------------
|
1357 |
|
|
AC_DEFUN([LT_CMD_MAX_LEN],
|
1358 |
|
|
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
1359 |
|
|
# find the maximum length of command line arguments
|
1360 |
|
|
AC_MSG_CHECKING([the maximum length of command line arguments])
|
1361 |
|
|
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
|
1362 |
|
|
i=0
|
1363 |
|
|
teststring="ABCD"
|
1364 |
|
|
|
1365 |
|
|
case $build_os in
|
1366 |
|
|
msdosdjgpp*)
|
1367 |
|
|
# On DJGPP, this test can blow up pretty badly due to problems in libc
|
1368 |
|
|
# (any single argument exceeding 2000 bytes causes a buffer overrun
|
1369 |
|
|
# during glob expansion). Even if it were fixed, the result of this
|
1370 |
|
|
# check would be larger than it should be.
|
1371 |
|
|
lt_cv_sys_max_cmd_len=12288; # 12K is about right
|
1372 |
|
|
;;
|
1373 |
|
|
|
1374 |
|
|
gnu*)
|
1375 |
|
|
# Under GNU Hurd, this test is not required because there is
|
1376 |
|
|
# no limit to the length of command line arguments.
|
1377 |
|
|
# Libtool will interpret -1 as no limit whatsoever
|
1378 |
|
|
lt_cv_sys_max_cmd_len=-1;
|
1379 |
|
|
;;
|
1380 |
|
|
|
1381 |
|
|
cygwin* | mingw*)
|
1382 |
|
|
# On Win9x/ME, this test blows up -- it succeeds, but takes
|
1383 |
|
|
# about 5 minutes as the teststring grows exponentially.
|
1384 |
|
|
# Worse, since 9x/ME are not pre-emptively multitasking,
|
1385 |
|
|
# you end up with a "frozen" computer, even though with patience
|
1386 |
|
|
# the test eventually succeeds (with a max line length of 256k).
|
1387 |
|
|
# Instead, let's just punt: use the minimum linelength reported by
|
1388 |
|
|
# all of the supported platforms: 8192 (on NT/2K/XP).
|
1389 |
|
|
lt_cv_sys_max_cmd_len=8192;
|
1390 |
|
|
;;
|
1391 |
|
|
|
1392 |
|
|
amigaos*)
|
1393 |
|
|
# On AmigaOS with pdksh, this test takes hours, literally.
|
1394 |
|
|
# So we just punt and use a minimum line length of 8192.
|
1395 |
|
|
lt_cv_sys_max_cmd_len=8192;
|
1396 |
|
|
;;
|
1397 |
|
|
|
1398 |
|
|
netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
|
1399 |
|
|
# This has been around since 386BSD, at least. Likely further.
|
1400 |
|
|
if test -x /sbin/sysctl; then
|
1401 |
|
|
lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
|
1402 |
|
|
elif test -x /usr/sbin/sysctl; then
|
1403 |
|
|
lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
|
1404 |
|
|
else
|
1405 |
|
|
lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
|
1406 |
|
|
fi
|
1407 |
|
|
# And add a safety zone
|
1408 |
|
|
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
|
1409 |
|
|
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
|
1410 |
|
|
;;
|
1411 |
|
|
|
1412 |
|
|
interix*)
|
1413 |
|
|
# We know the value 262144 and hardcode it with a safety zone (like BSD)
|
1414 |
|
|
lt_cv_sys_max_cmd_len=196608
|
1415 |
|
|
;;
|
1416 |
|
|
|
1417 |
|
|
osf*)
|
1418 |
|
|
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
|
1419 |
|
|
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
|
1420 |
|
|
# nice to cause kernel panics so lets avoid the loop below.
|
1421 |
|
|
# First set a reasonable default.
|
1422 |
|
|
lt_cv_sys_max_cmd_len=16384
|
1423 |
|
|
#
|
1424 |
|
|
if test -x /sbin/sysconfig; then
|
1425 |
|
|
case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
|
1426 |
|
|
*1*) lt_cv_sys_max_cmd_len=-1 ;;
|
1427 |
|
|
esac
|
1428 |
|
|
fi
|
1429 |
|
|
;;
|
1430 |
|
|
sco3.2v5*)
|
1431 |
|
|
lt_cv_sys_max_cmd_len=102400
|
1432 |
|
|
;;
|
1433 |
|
|
sysv5* | sco5v6* | sysv4.2uw2*)
|
1434 |
|
|
kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
|
1435 |
|
|
if test -n "$kargmax"; then
|
1436 |
|
|
lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
|
1437 |
|
|
else
|
1438 |
|
|
lt_cv_sys_max_cmd_len=32768
|
1439 |
|
|
fi
|
1440 |
|
|
;;
|
1441 |
|
|
*)
|
1442 |
|
|
lt_cv_sys_max_cmd_len=`getconf ARG_MAX 2> /dev/null`
|
1443 |
|
|
if test -n $lt_cv_sys_max_cmd_len; then
|
1444 |
|
|
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
|
1445 |
|
|
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
|
1446 |
|
|
else
|
1447 |
|
|
# Make teststring a little bigger before we do anything with it.
|
1448 |
|
|
# a 1K string should be a reasonable start.
|
1449 |
|
|
for i in 1 2 3 4 5 6 7 8 ; do
|
1450 |
|
|
teststring=$teststring$teststring
|
1451 |
|
|
done
|
1452 |
|
|
SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
|
1453 |
|
|
# If test is not a shell built-in, we'll probably end up computing a
|
1454 |
|
|
# maximum length that is only half of the actual maximum length, but
|
1455 |
|
|
# we can't tell.
|
1456 |
|
|
while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
|
1457 |
|
|
= "XX$teststring$teststring"; } >/dev/null 2>&1 &&
|
1458 |
|
|
test $i != 17 # 1/2 MB should be enough
|
1459 |
|
|
do
|
1460 |
|
|
i=`expr $i + 1`
|
1461 |
|
|
teststring=$teststring$teststring
|
1462 |
|
|
done
|
1463 |
|
|
# Only check the string length outside the loop.
|
1464 |
|
|
lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
|
1465 |
|
|
teststring=
|
1466 |
|
|
# Add a significant safety factor because C++ compilers can tack on
|
1467 |
|
|
# massive amounts of additional arguments before passing them to the
|
1468 |
|
|
# linker. It appears as though 1/2 is a usable value.
|
1469 |
|
|
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
|
1470 |
|
|
fi
|
1471 |
|
|
;;
|
1472 |
|
|
esac
|
1473 |
|
|
])
|
1474 |
|
|
if test -n $lt_cv_sys_max_cmd_len ; then
|
1475 |
|
|
AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
|
1476 |
|
|
else
|
1477 |
|
|
AC_MSG_RESULT(none)
|
1478 |
|
|
fi
|
1479 |
|
|
max_cmd_len=$lt_cv_sys_max_cmd_len
|
1480 |
|
|
_LT_DECL([], [max_cmd_len], [0],
|
1481 |
|
|
[What is the maximum length of a command?])
|
1482 |
|
|
])# LT_CMD_MAX_LEN
|
1483 |
|
|
|
1484 |
|
|
# Old name:
|
1485 |
|
|
AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
|
1486 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
1487 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
|
1488 |
|
|
|
1489 |
|
|
|
1490 |
|
|
# _LT_HEADER_DLFCN
|
1491 |
|
|
# ----------------
|
1492 |
|
|
m4_defun([_LT_HEADER_DLFCN],
|
1493 |
|
|
[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
|
1494 |
|
|
])# _LT_HEADER_DLFCN
|
1495 |
|
|
|
1496 |
|
|
|
1497 |
|
|
# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
|
1498 |
|
|
# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
|
1499 |
|
|
# ----------------------------------------------------------------
|
1500 |
|
|
m4_defun([_LT_TRY_DLOPEN_SELF],
|
1501 |
|
|
[m4_require([_LT_HEADER_DLFCN])dnl
|
1502 |
|
|
if test "$cross_compiling" = yes; then :
|
1503 |
|
|
[$4]
|
1504 |
|
|
else
|
1505 |
|
|
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
1506 |
|
|
lt_status=$lt_dlunknown
|
1507 |
|
|
cat > conftest.$ac_ext <<_LT_EOF
|
1508 |
|
|
[#line __oline__ "configure"
|
1509 |
|
|
#include "confdefs.h"
|
1510 |
|
|
|
1511 |
|
|
#if HAVE_DLFCN_H
|
1512 |
|
|
#include <dlfcn.h>
|
1513 |
|
|
#endif
|
1514 |
|
|
|
1515 |
|
|
#include <stdio.h>
|
1516 |
|
|
|
1517 |
|
|
#ifdef RTLD_GLOBAL
|
1518 |
|
|
# define LT_DLGLOBAL RTLD_GLOBAL
|
1519 |
|
|
#else
|
1520 |
|
|
# ifdef DL_GLOBAL
|
1521 |
|
|
# define LT_DLGLOBAL DL_GLOBAL
|
1522 |
|
|
# else
|
1523 |
|
|
# define LT_DLGLOBAL 0
|
1524 |
|
|
# endif
|
1525 |
|
|
#endif
|
1526 |
|
|
|
1527 |
|
|
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
|
1528 |
|
|
find out it does not work in some platform. */
|
1529 |
|
|
#ifndef LT_DLLAZY_OR_NOW
|
1530 |
|
|
# ifdef RTLD_LAZY
|
1531 |
|
|
# define LT_DLLAZY_OR_NOW RTLD_LAZY
|
1532 |
|
|
# else
|
1533 |
|
|
# ifdef DL_LAZY
|
1534 |
|
|
# define LT_DLLAZY_OR_NOW DL_LAZY
|
1535 |
|
|
# else
|
1536 |
|
|
# ifdef RTLD_NOW
|
1537 |
|
|
# define LT_DLLAZY_OR_NOW RTLD_NOW
|
1538 |
|
|
# else
|
1539 |
|
|
# ifdef DL_NOW
|
1540 |
|
|
# define LT_DLLAZY_OR_NOW DL_NOW
|
1541 |
|
|
# else
|
1542 |
|
|
# define LT_DLLAZY_OR_NOW 0
|
1543 |
|
|
# endif
|
1544 |
|
|
# endif
|
1545 |
|
|
# endif
|
1546 |
|
|
# endif
|
1547 |
|
|
#endif
|
1548 |
|
|
|
1549 |
|
|
#ifdef __cplusplus
|
1550 |
|
|
extern "C" void exit (int);
|
1551 |
|
|
#endif
|
1552 |
|
|
|
1553 |
|
|
void fnord() { int i=42;}
|
1554 |
|
|
int main ()
|
1555 |
|
|
{
|
1556 |
|
|
void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
|
1557 |
|
|
int status = $lt_dlunknown;
|
1558 |
|
|
|
1559 |
|
|
if (self)
|
1560 |
|
|
{
|
1561 |
|
|
if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
|
1562 |
|
|
else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
|
1563 |
|
|
/* dlclose (self); */
|
1564 |
|
|
}
|
1565 |
|
|
else
|
1566 |
|
|
puts (dlerror ());
|
1567 |
|
|
|
1568 |
|
|
exit (status);
|
1569 |
|
|
}]
|
1570 |
|
|
_LT_EOF
|
1571 |
|
|
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
|
1572 |
|
|
(./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
|
1573 |
|
|
lt_status=$?
|
1574 |
|
|
case x$lt_status in
|
1575 |
|
|
x$lt_dlno_uscore) $1 ;;
|
1576 |
|
|
x$lt_dlneed_uscore) $2 ;;
|
1577 |
|
|
x$lt_dlunknown|x*) $3 ;;
|
1578 |
|
|
esac
|
1579 |
|
|
else :
|
1580 |
|
|
# compilation failed
|
1581 |
|
|
$3
|
1582 |
|
|
fi
|
1583 |
|
|
fi
|
1584 |
|
|
rm -fr conftest*
|
1585 |
|
|
])# _LT_TRY_DLOPEN_SELF
|
1586 |
|
|
|
1587 |
|
|
|
1588 |
|
|
# LT_SYS_DLOPEN_SELF
|
1589 |
|
|
# ------------------
|
1590 |
|
|
AC_DEFUN([LT_SYS_DLOPEN_SELF],
|
1591 |
|
|
[m4_require([_LT_HEADER_DLFCN])dnl
|
1592 |
|
|
if test "x$enable_dlopen" != xyes; then
|
1593 |
|
|
enable_dlopen=unknown
|
1594 |
|
|
enable_dlopen_self=unknown
|
1595 |
|
|
enable_dlopen_self_static=unknown
|
1596 |
|
|
else
|
1597 |
|
|
lt_cv_dlopen=no
|
1598 |
|
|
lt_cv_dlopen_libs=
|
1599 |
|
|
|
1600 |
|
|
case $host_os in
|
1601 |
|
|
beos*)
|
1602 |
|
|
lt_cv_dlopen="load_add_on"
|
1603 |
|
|
lt_cv_dlopen_libs=
|
1604 |
|
|
lt_cv_dlopen_self=yes
|
1605 |
|
|
;;
|
1606 |
|
|
|
1607 |
|
|
mingw* | pw32*)
|
1608 |
|
|
lt_cv_dlopen="LoadLibrary"
|
1609 |
|
|
lt_cv_dlopen_libs=
|
1610 |
|
|
;;
|
1611 |
|
|
|
1612 |
|
|
cygwin*)
|
1613 |
|
|
lt_cv_dlopen="dlopen"
|
1614 |
|
|
lt_cv_dlopen_libs=
|
1615 |
|
|
;;
|
1616 |
|
|
|
1617 |
|
|
darwin*)
|
1618 |
|
|
# if libdl is installed we need to link against it
|
1619 |
|
|
AC_CHECK_LIB([dl], [dlopen],
|
1620 |
|
|
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
|
1621 |
|
|
lt_cv_dlopen="dyld"
|
1622 |
|
|
lt_cv_dlopen_libs=
|
1623 |
|
|
lt_cv_dlopen_self=yes
|
1624 |
|
|
])
|
1625 |
|
|
;;
|
1626 |
|
|
|
1627 |
|
|
*)
|
1628 |
|
|
AC_CHECK_FUNC([shl_load],
|
1629 |
|
|
[lt_cv_dlopen="shl_load"],
|
1630 |
|
|
[AC_CHECK_LIB([dld], [shl_load],
|
1631 |
|
|
[lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
|
1632 |
|
|
[AC_CHECK_FUNC([dlopen],
|
1633 |
|
|
[lt_cv_dlopen="dlopen"],
|
1634 |
|
|
[AC_CHECK_LIB([dl], [dlopen],
|
1635 |
|
|
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
|
1636 |
|
|
[AC_CHECK_LIB([svld], [dlopen],
|
1637 |
|
|
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
|
1638 |
|
|
[AC_CHECK_LIB([dld], [dld_link],
|
1639 |
|
|
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
|
1640 |
|
|
])
|
1641 |
|
|
])
|
1642 |
|
|
])
|
1643 |
|
|
])
|
1644 |
|
|
])
|
1645 |
|
|
;;
|
1646 |
|
|
esac
|
1647 |
|
|
|
1648 |
|
|
if test "x$lt_cv_dlopen" != xno; then
|
1649 |
|
|
enable_dlopen=yes
|
1650 |
|
|
else
|
1651 |
|
|
enable_dlopen=no
|
1652 |
|
|
fi
|
1653 |
|
|
|
1654 |
|
|
case $lt_cv_dlopen in
|
1655 |
|
|
dlopen)
|
1656 |
|
|
save_CPPFLAGS="$CPPFLAGS"
|
1657 |
|
|
test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
|
1658 |
|
|
|
1659 |
|
|
save_LDFLAGS="$LDFLAGS"
|
1660 |
|
|
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
|
1661 |
|
|
|
1662 |
|
|
save_LIBS="$LIBS"
|
1663 |
|
|
LIBS="$lt_cv_dlopen_libs $LIBS"
|
1664 |
|
|
|
1665 |
|
|
AC_CACHE_CHECK([whether a program can dlopen itself],
|
1666 |
|
|
lt_cv_dlopen_self, [dnl
|
1667 |
|
|
_LT_TRY_DLOPEN_SELF(
|
1668 |
|
|
lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
|
1669 |
|
|
lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
|
1670 |
|
|
])
|
1671 |
|
|
|
1672 |
|
|
if test "x$lt_cv_dlopen_self" = xyes; then
|
1673 |
|
|
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
|
1674 |
|
|
AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
|
1675 |
|
|
lt_cv_dlopen_self_static, [dnl
|
1676 |
|
|
_LT_TRY_DLOPEN_SELF(
|
1677 |
|
|
lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
|
1678 |
|
|
lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
|
1679 |
|
|
])
|
1680 |
|
|
fi
|
1681 |
|
|
|
1682 |
|
|
CPPFLAGS="$save_CPPFLAGS"
|
1683 |
|
|
LDFLAGS="$save_LDFLAGS"
|
1684 |
|
|
LIBS="$save_LIBS"
|
1685 |
|
|
;;
|
1686 |
|
|
esac
|
1687 |
|
|
|
1688 |
|
|
case $lt_cv_dlopen_self in
|
1689 |
|
|
yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
|
1690 |
|
|
*) enable_dlopen_self=unknown ;;
|
1691 |
|
|
esac
|
1692 |
|
|
|
1693 |
|
|
case $lt_cv_dlopen_self_static in
|
1694 |
|
|
yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
|
1695 |
|
|
*) enable_dlopen_self_static=unknown ;;
|
1696 |
|
|
esac
|
1697 |
|
|
fi
|
1698 |
|
|
_LT_DECL([dlopen_support], [enable_dlopen], [0],
|
1699 |
|
|
[Whether dlopen is supported])
|
1700 |
|
|
_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
|
1701 |
|
|
[Whether dlopen of programs is supported])
|
1702 |
|
|
_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
|
1703 |
|
|
[Whether dlopen of statically linked programs is supported])
|
1704 |
|
|
])# LT_SYS_DLOPEN_SELF
|
1705 |
|
|
|
1706 |
|
|
# Old name:
|
1707 |
|
|
AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
|
1708 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
1709 |
|
|
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
|
1710 |
|
|
|
1711 |
|
|
|
1712 |
|
|
# _LT_COMPILER_C_O([TAGNAME])
|
1713 |
|
|
# ---------------------------
|
1714 |
|
|
# Check to see if options -c and -o are simultaneously supported by compiler.
|
1715 |
|
|
# This macro does not hard code the compiler like AC_PROG_CC_C_O.
|
1716 |
|
|
m4_defun([_LT_COMPILER_C_O],
|
1717 |
|
|
[AC_REQUIRE([AC_OBJEXT])dnl
|
1718 |
|
|
m4_require([_LT_DECL_SED])dnl
|
1719 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
1720 |
|
|
m4_require([_LT_TAG_COMPILER])dnl
|
1721 |
|
|
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
|
1722 |
|
|
[_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
|
1723 |
|
|
[_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
|
1724 |
|
|
$RM -r conftest 2>/dev/null
|
1725 |
|
|
mkdir conftest
|
1726 |
|
|
cd conftest
|
1727 |
|
|
mkdir out
|
1728 |
|
|
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
|
1729 |
|
|
|
1730 |
|
|
lt_compiler_flag="-o out/conftest2.$ac_objext"
|
1731 |
|
|
# Insert the option either (1) after the last *FLAGS variable, or
|
1732 |
|
|
# (2) before a word containing "conftest.", or (3) at the end.
|
1733 |
|
|
# Note that $ac_compile itself does not contain backslashes and begins
|
1734 |
|
|
# with a dollar sign (not a hyphen), so the echo should work correctly.
|
1735 |
|
|
lt_compile=`echo "$ac_compile" | $SED \
|
1736 |
|
|
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
|
1737 |
|
|
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
|
1738 |
|
|
-e 's:$: $lt_compiler_flag:'`
|
1739 |
|
|
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
|
1740 |
|
|
(eval "$lt_compile" 2>out/conftest.err)
|
1741 |
|
|
ac_status=$?
|
1742 |
|
|
cat out/conftest.err >&AS_MESSAGE_LOG_FD
|
1743 |
|
|
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
|
1744 |
|
|
if (exit $ac_status) && test -s out/conftest2.$ac_objext
|
1745 |
|
|
then
|
1746 |
|
|
# The compiler can only warn and ignore the option if not recognized
|
1747 |
|
|
# So say no if there are warnings
|
1748 |
|
|
$ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
|
1749 |
|
|
$SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
|
1750 |
|
|
if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
|
1751 |
|
|
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
|
1752 |
|
|
fi
|
1753 |
|
|
fi
|
1754 |
|
|
chmod u+w . 2>&AS_MESSAGE_LOG_FD
|
1755 |
|
|
$RM conftest*
|
1756 |
|
|
# SGI C++ compiler will create directory out/ii_files/ for
|
1757 |
|
|
# template instantiation
|
1758 |
|
|
test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
|
1759 |
|
|
$RM out/* && rmdir out
|
1760 |
|
|
cd ..
|
1761 |
|
|
$RM -r conftest
|
1762 |
|
|
$RM conftest*
|
1763 |
|
|
])
|
1764 |
|
|
_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
|
1765 |
|
|
[Does compiler simultaneously support -c and -o options?])
|
1766 |
|
|
])# _LT_COMPILER_C_O
|
1767 |
|
|
|
1768 |
|
|
|
1769 |
|
|
# _LT_COMPILER_FILE_LOCKS([TAGNAME])
|
1770 |
|
|
# ----------------------------------
|
1771 |
|
|
# Check to see if we can do hard links to lock some files if needed
|
1772 |
|
|
m4_defun([_LT_COMPILER_FILE_LOCKS],
|
1773 |
|
|
[m4_require([_LT_ENABLE_LOCK])dnl
|
1774 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
1775 |
|
|
_LT_COMPILER_C_O([$1])
|
1776 |
|
|
|
1777 |
|
|
hard_links="nottested"
|
1778 |
|
|
if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
|
1779 |
|
|
# do not overwrite the value of need_locks provided by the user
|
1780 |
|
|
AC_MSG_CHECKING([if we can lock with hard links])
|
1781 |
|
|
hard_links=yes
|
1782 |
|
|
$RM conftest*
|
1783 |
|
|
ln conftest.a conftest.b 2>/dev/null && hard_links=no
|
1784 |
|
|
touch conftest.a
|
1785 |
|
|
ln conftest.a conftest.b 2>&5 || hard_links=no
|
1786 |
|
|
ln conftest.a conftest.b 2>/dev/null && hard_links=no
|
1787 |
|
|
AC_MSG_RESULT([$hard_links])
|
1788 |
|
|
if test "$hard_links" = no; then
|
1789 |
|
|
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
|
1790 |
|
|
need_locks=warn
|
1791 |
|
|
fi
|
1792 |
|
|
else
|
1793 |
|
|
need_locks=no
|
1794 |
|
|
fi
|
1795 |
|
|
_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
|
1796 |
|
|
])# _LT_COMPILER_FILE_LOCKS
|
1797 |
|
|
|
1798 |
|
|
|
1799 |
|
|
# _LT_CHECK_OBJDIR
|
1800 |
|
|
# ----------------
|
1801 |
|
|
m4_defun([_LT_CHECK_OBJDIR],
|
1802 |
|
|
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
|
1803 |
|
|
[rm -f .libs 2>/dev/null
|
1804 |
|
|
mkdir .libs 2>/dev/null
|
1805 |
|
|
if test -d .libs; then
|
1806 |
|
|
lt_cv_objdir=.libs
|
1807 |
|
|
else
|
1808 |
|
|
# MS-DOS does not allow filenames that begin with a dot.
|
1809 |
|
|
lt_cv_objdir=_libs
|
1810 |
|
|
fi
|
1811 |
|
|
rmdir .libs 2>/dev/null])
|
1812 |
|
|
objdir=$lt_cv_objdir
|
1813 |
|
|
_LT_DECL([], [objdir], [0],
|
1814 |
|
|
[The name of the directory that contains temporary libtool files])dnl
|
1815 |
|
|
m4_pattern_allow([LT_OBJDIR])dnl
|
1816 |
|
|
AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
|
1817 |
|
|
[Define to the sub-directory in which libtool stores uninstalled libraries.])
|
1818 |
|
|
])# _LT_CHECK_OBJDIR
|
1819 |
|
|
|
1820 |
|
|
|
1821 |
|
|
# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
|
1822 |
|
|
# --------------------------------------
|
1823 |
|
|
# Check hardcoding attributes.
|
1824 |
|
|
m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
|
1825 |
|
|
[AC_MSG_CHECKING([how to hardcode library paths into programs])
|
1826 |
|
|
_LT_TAGVAR(hardcode_action, $1)=
|
1827 |
|
|
if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
|
1828 |
|
|
test -n "$_LT_TAGVAR(runpath_var, $1)" ||
|
1829 |
|
|
test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
|
1830 |
|
|
|
1831 |
|
|
# We can hardcode non-existent directories.
|
1832 |
|
|
if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
|
1833 |
|
|
# If the only mechanism to avoid hardcoding is shlibpath_var, we
|
1834 |
|
|
# have to relink, otherwise we might link with an installed library
|
1835 |
|
|
# when we should be linking with a yet-to-be-installed one
|
1836 |
|
|
## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
|
1837 |
|
|
test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
|
1838 |
|
|
# Linking always hardcodes the temporary library directory.
|
1839 |
|
|
_LT_TAGVAR(hardcode_action, $1)=relink
|
1840 |
|
|
else
|
1841 |
|
|
# We can link without hardcoding, and we can hardcode nonexisting dirs.
|
1842 |
|
|
_LT_TAGVAR(hardcode_action, $1)=immediate
|
1843 |
|
|
fi
|
1844 |
|
|
else
|
1845 |
|
|
# We cannot hardcode anything, or else we can only hardcode existing
|
1846 |
|
|
# directories.
|
1847 |
|
|
_LT_TAGVAR(hardcode_action, $1)=unsupported
|
1848 |
|
|
fi
|
1849 |
|
|
AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
|
1850 |
|
|
|
1851 |
|
|
if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
|
1852 |
|
|
test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
|
1853 |
|
|
# Fast installation is not supported
|
1854 |
|
|
enable_fast_install=no
|
1855 |
|
|
elif test "$shlibpath_overrides_runpath" = yes ||
|
1856 |
|
|
test "$enable_shared" = no; then
|
1857 |
|
|
# Fast installation is not necessary
|
1858 |
|
|
enable_fast_install=needless
|
1859 |
|
|
fi
|
1860 |
|
|
_LT_TAGDECL([], [hardcode_action], [0],
|
1861 |
|
|
[How to hardcode a shared library path into an executable])
|
1862 |
|
|
])# _LT_LINKER_HARDCODE_LIBPATH
|
1863 |
|
|
|
1864 |
|
|
|
1865 |
|
|
# _LT_CMD_STRIPLIB
|
1866 |
|
|
# ----------------
|
1867 |
|
|
m4_defun([_LT_CMD_STRIPLIB],
|
1868 |
|
|
[m4_require([_LT_DECL_EGREP])
|
1869 |
|
|
striplib=
|
1870 |
|
|
old_striplib=
|
1871 |
|
|
AC_MSG_CHECKING([whether stripping libraries is possible])
|
1872 |
|
|
if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
|
1873 |
|
|
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
|
1874 |
|
|
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
|
1875 |
|
|
AC_MSG_RESULT([yes])
|
1876 |
|
|
else
|
1877 |
|
|
# FIXME - insert some real tests, host_os isn't really good enough
|
1878 |
|
|
case $host_os in
|
1879 |
|
|
darwin*)
|
1880 |
|
|
if test -n "$STRIP" ; then
|
1881 |
|
|
striplib="$STRIP -x"
|
1882 |
|
|
old_striplib="$STRIP -S"
|
1883 |
|
|
AC_MSG_RESULT([yes])
|
1884 |
|
|
else
|
1885 |
|
|
AC_MSG_RESULT([no])
|
1886 |
|
|
fi
|
1887 |
|
|
;;
|
1888 |
|
|
*)
|
1889 |
|
|
AC_MSG_RESULT([no])
|
1890 |
|
|
;;
|
1891 |
|
|
esac
|
1892 |
|
|
fi
|
1893 |
|
|
_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
|
1894 |
|
|
_LT_DECL([], [striplib], [1])
|
1895 |
|
|
])# _LT_CMD_STRIPLIB
|
1896 |
|
|
|
1897 |
|
|
|
1898 |
|
|
# _LT_SYS_DYNAMIC_LINKER([TAG])
|
1899 |
|
|
# -----------------------------
|
1900 |
|
|
# PORTME Fill in your ld.so characteristics
|
1901 |
|
|
m4_defun([_LT_SYS_DYNAMIC_LINKER],
|
1902 |
|
|
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
1903 |
|
|
m4_require([_LT_DECL_EGREP])dnl
|
1904 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
1905 |
|
|
m4_require([_LT_DECL_SED])dnl
|
1906 |
|
|
AC_MSG_CHECKING([dynamic linker characteristics])
|
1907 |
|
|
m4_case([$1],
|
1908 |
|
|
[C], [withGCC=$GCC],
|
1909 |
|
|
[CXX], [withGCC=$GXX],
|
1910 |
|
|
[F77], [withGCC=$G77],
|
1911 |
|
|
[FC], [withGCC=$ac_cv_fc_compiler_gnu],
|
1912 |
|
|
[GCJ], [withGCC=$GCC],
|
1913 |
|
|
[], [withGCC=$GCC
|
1914 |
|
|
if test "$withGCC" = yes; then
|
1915 |
|
|
case $host_os in
|
1916 |
|
|
darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
|
1917 |
|
|
*) lt_awk_arg="/^libraries:/" ;;
|
1918 |
|
|
esac
|
1919 |
|
|
lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
|
1920 |
|
|
if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
|
1921 |
|
|
# if the path contains ";" then we assume it to be the separator
|
1922 |
|
|
# otherwise default to the standard path separator (i.e. ":") - it is
|
1923 |
|
|
# assumed that no part of a normal pathname contains ";" but that should
|
1924 |
|
|
# okay in the real world where ";" in dirpaths is itself problematic.
|
1925 |
|
|
lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
|
1926 |
|
|
else
|
1927 |
|
|
lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
|
1928 |
|
|
fi
|
1929 |
|
|
# Ok, now we have the path, separated by spaces, we can step through it
|
1930 |
|
|
# and add multilib dir if necessary.
|
1931 |
|
|
lt_tmp_lt_search_path_spec=
|
1932 |
|
|
lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
|
1933 |
|
|
for lt_sys_path in $lt_search_path_spec; do
|
1934 |
|
|
if test -d "$lt_sys_path/$lt_multi_os_dir"; then
|
1935 |
|
|
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
|
1936 |
|
|
else
|
1937 |
|
|
test -d "$lt_sys_path" && \
|
1938 |
|
|
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
|
1939 |
|
|
fi
|
1940 |
|
|
done
|
1941 |
|
|
lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
|
1942 |
|
|
BEGIN {RS=" "; FS="/|\n";} {
|
1943 |
|
|
lt_foo="";
|
1944 |
|
|
lt_count=0;
|
1945 |
|
|
for (lt_i = NF; lt_i > 0; lt_i--) {
|
1946 |
|
|
if ($lt_i != "" && $lt_i != ".") {
|
1947 |
|
|
if ($lt_i == "..") {
|
1948 |
|
|
lt_count++;
|
1949 |
|
|
} else {
|
1950 |
|
|
if (lt_count == 0) {
|
1951 |
|
|
lt_foo="/" $lt_i lt_foo;
|
1952 |
|
|
} else {
|
1953 |
|
|
lt_count--;
|
1954 |
|
|
}
|
1955 |
|
|
}
|
1956 |
|
|
}
|
1957 |
|
|
}
|
1958 |
|
|
if (lt_foo != "") { lt_freq[[lt_foo]]++; }
|
1959 |
|
|
if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
|
1960 |
|
|
}'`
|
1961 |
|
|
sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
|
1962 |
|
|
else
|
1963 |
|
|
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
|
1964 |
|
|
fi],
|
1965 |
|
|
[withGCC=$GCC])
|
1966 |
|
|
library_names_spec=
|
1967 |
|
|
libname_spec='lib$name'
|
1968 |
|
|
soname_spec=
|
1969 |
|
|
shrext_cmds=".so"
|
1970 |
|
|
postinstall_cmds=
|
1971 |
|
|
postuninstall_cmds=
|
1972 |
|
|
finish_cmds=
|
1973 |
|
|
finish_eval=
|
1974 |
|
|
shlibpath_var=
|
1975 |
|
|
shlibpath_overrides_runpath=unknown
|
1976 |
|
|
version_type=none
|
1977 |
|
|
dynamic_linker="$host_os ld.so"
|
1978 |
|
|
sys_lib_dlsearch_path_spec="/lib /usr/lib"
|
1979 |
|
|
need_lib_prefix=unknown
|
1980 |
|
|
hardcode_into_libs=no
|
1981 |
|
|
|
1982 |
|
|
# when you set need_version to no, make sure it does not cause -set_version
|
1983 |
|
|
# flags to be left without arguments
|
1984 |
|
|
need_version=unknown
|
1985 |
|
|
|
1986 |
|
|
case $host_os in
|
1987 |
|
|
aix3*)
|
1988 |
|
|
version_type=linux
|
1989 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
|
1990 |
|
|
shlibpath_var=LIBPATH
|
1991 |
|
|
|
1992 |
|
|
# AIX 3 has no versioning support, so we append a major version to the name.
|
1993 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
1994 |
|
|
;;
|
1995 |
|
|
|
1996 |
|
|
aix[[4-9]]*)
|
1997 |
|
|
version_type=linux
|
1998 |
|
|
need_lib_prefix=no
|
1999 |
|
|
need_version=no
|
2000 |
|
|
hardcode_into_libs=yes
|
2001 |
|
|
if test "$host_cpu" = ia64; then
|
2002 |
|
|
# AIX 5 supports IA64
|
2003 |
|
|
library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
|
2004 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2005 |
|
|
else
|
2006 |
|
|
# With GCC up to 2.95.x, collect2 would create an import file
|
2007 |
|
|
# for dependence libraries. The import file would start with
|
2008 |
|
|
# the line `#! .'. This would cause the generated library to
|
2009 |
|
|
# depend on `.', always an invalid library. This was fixed in
|
2010 |
|
|
# development snapshots of GCC prior to 3.0.
|
2011 |
|
|
case $host_os in
|
2012 |
|
|
aix4 | aix4.[[01]] | aix4.[[01]].*)
|
2013 |
|
|
if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
|
2014 |
|
|
echo ' yes '
|
2015 |
|
|
echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
|
2016 |
|
|
:
|
2017 |
|
|
else
|
2018 |
|
|
can_build_shared=no
|
2019 |
|
|
fi
|
2020 |
|
|
;;
|
2021 |
|
|
esac
|
2022 |
|
|
# AIX (on Power*) has no versioning support, so currently we can not hardcode correct
|
2023 |
|
|
# soname into executable. Probably we can add versioning support to
|
2024 |
|
|
# collect2, so additional links can be useful in future.
|
2025 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
2026 |
|
|
# If using run time linking (on AIX 4.2 or later) use lib<name>.so
|
2027 |
|
|
# instead of lib<name>.a to let people know that these are not
|
2028 |
|
|
# typical AIX shared libraries.
|
2029 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2030 |
|
|
else
|
2031 |
|
|
# We preserve .a as extension for shared libraries through AIX4.2
|
2032 |
|
|
# and later when we are not doing run time linking.
|
2033 |
|
|
library_names_spec='${libname}${release}.a $libname.a'
|
2034 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2035 |
|
|
fi
|
2036 |
|
|
shlibpath_var=LIBPATH
|
2037 |
|
|
fi
|
2038 |
|
|
;;
|
2039 |
|
|
|
2040 |
|
|
amigaos*)
|
2041 |
|
|
if test "$host_cpu" = m68k; then
|
2042 |
|
|
library_names_spec='$libname.ixlibrary $libname.a'
|
2043 |
|
|
# Create ${libname}_ixlibrary.a entries in /sys/libs.
|
2044 |
|
|
finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
|
2045 |
|
|
else
|
2046 |
|
|
dynamic_linker=no
|
2047 |
|
|
fi
|
2048 |
|
|
;;
|
2049 |
|
|
|
2050 |
|
|
beos*)
|
2051 |
|
|
library_names_spec='${libname}${shared_ext}'
|
2052 |
|
|
dynamic_linker="$host_os ld.so"
|
2053 |
|
|
shlibpath_var=LIBRARY_PATH
|
2054 |
|
|
;;
|
2055 |
|
|
|
2056 |
|
|
bsdi[[45]]*)
|
2057 |
|
|
version_type=linux
|
2058 |
|
|
need_version=no
|
2059 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2060 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2061 |
|
|
finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
|
2062 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2063 |
|
|
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
|
2064 |
|
|
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
|
2065 |
|
|
# the default ld.so.conf also contains /usr/contrib/lib and
|
2066 |
|
|
# /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
|
2067 |
|
|
# libtool to hard-code these into programs
|
2068 |
|
|
;;
|
2069 |
|
|
|
2070 |
|
|
cygwin* | mingw* | pw32*)
|
2071 |
|
|
version_type=windows
|
2072 |
|
|
shrext_cmds=".dll"
|
2073 |
|
|
need_version=no
|
2074 |
|
|
need_lib_prefix=no
|
2075 |
|
|
|
2076 |
|
|
case $withGCC,$host_os in
|
2077 |
|
|
yes,cygwin* | yes,mingw* | yes,pw32*)
|
2078 |
|
|
library_names_spec='$libname.dll.a'
|
2079 |
|
|
# DLL is installed to $(libdir)/../bin by postinstall_cmds
|
2080 |
|
|
postinstall_cmds='base_file=`basename \${file}`~
|
2081 |
|
|
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
|
2082 |
|
|
dldir=$destdir/`dirname \$dlpath`~
|
2083 |
|
|
test -d \$dldir || mkdir -p \$dldir~
|
2084 |
|
|
$install_prog $dir/$dlname \$dldir/$dlname~
|
2085 |
|
|
chmod a+x \$dldir/$dlname~
|
2086 |
|
|
if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
|
2087 |
|
|
eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
|
2088 |
|
|
fi'
|
2089 |
|
|
postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
|
2090 |
|
|
dlpath=$dir/\$dldll~
|
2091 |
|
|
$RM \$dlpath'
|
2092 |
|
|
shlibpath_overrides_runpath=yes
|
2093 |
|
|
|
2094 |
|
|
case $host_os in
|
2095 |
|
|
cygwin*)
|
2096 |
|
|
# Cygwin DLLs use 'cyg' prefix rather than 'lib'
|
2097 |
|
|
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
|
2098 |
|
|
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
|
2099 |
|
|
;;
|
2100 |
|
|
mingw*)
|
2101 |
|
|
# MinGW DLLs use traditional 'lib' prefix
|
2102 |
|
|
soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
|
2103 |
|
|
sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
|
2104 |
|
|
if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
|
2105 |
|
|
# It is most probably a Windows format PATH printed by
|
2106 |
|
|
# mingw gcc, but we are running on Cygwin. Gcc prints its search
|
2107 |
|
|
# path with ; separators, and with drive letters. We can handle the
|
2108 |
|
|
# drive letters (cygwin fileutils understands them), so leave them,
|
2109 |
|
|
# especially as we might pass files found there to a mingw objdump,
|
2110 |
|
|
# which wouldn't understand a cygwinified path. Ahh.
|
2111 |
|
|
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
|
2112 |
|
|
else
|
2113 |
|
|
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
|
2114 |
|
|
fi
|
2115 |
|
|
;;
|
2116 |
|
|
pw32*)
|
2117 |
|
|
# pw32 DLLs use 'pw' prefix rather than 'lib'
|
2118 |
|
|
library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
|
2119 |
|
|
;;
|
2120 |
|
|
esac
|
2121 |
|
|
;;
|
2122 |
|
|
|
2123 |
|
|
*)
|
2124 |
|
|
library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
|
2125 |
|
|
;;
|
2126 |
|
|
esac
|
2127 |
|
|
dynamic_linker='Win32 ld.exe'
|
2128 |
|
|
# FIXME: first we should search . and the directory the executable is in
|
2129 |
|
|
shlibpath_var=PATH
|
2130 |
|
|
;;
|
2131 |
|
|
|
2132 |
|
|
darwin* | rhapsody*)
|
2133 |
|
|
dynamic_linker="$host_os dyld"
|
2134 |
|
|
version_type=darwin
|
2135 |
|
|
need_lib_prefix=no
|
2136 |
|
|
need_version=no
|
2137 |
|
|
library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
|
2138 |
|
|
soname_spec='${libname}${release}${major}$shared_ext'
|
2139 |
|
|
shlibpath_overrides_runpath=yes
|
2140 |
|
|
shlibpath_var=DYLD_LIBRARY_PATH
|
2141 |
|
|
shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
|
2142 |
|
|
m4_if([$1], [],[
|
2143 |
|
|
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
|
2144 |
|
|
sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
|
2145 |
|
|
;;
|
2146 |
|
|
|
2147 |
|
|
dgux*)
|
2148 |
|
|
version_type=linux
|
2149 |
|
|
need_lib_prefix=no
|
2150 |
|
|
need_version=no
|
2151 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
|
2152 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2153 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2154 |
|
|
;;
|
2155 |
|
|
|
2156 |
|
|
freebsd1*)
|
2157 |
|
|
dynamic_linker=no
|
2158 |
|
|
;;
|
2159 |
|
|
|
2160 |
|
|
freebsd* | dragonfly*)
|
2161 |
|
|
# DragonFly does not have aout. When/if they implement a new
|
2162 |
|
|
# versioning mechanism, adjust this.
|
2163 |
|
|
if test -x /usr/bin/objformat; then
|
2164 |
|
|
objformat=`/usr/bin/objformat`
|
2165 |
|
|
else
|
2166 |
|
|
case $host_os in
|
2167 |
|
|
freebsd[[123]]*) objformat=aout ;;
|
2168 |
|
|
*) objformat=elf ;;
|
2169 |
|
|
esac
|
2170 |
|
|
fi
|
2171 |
|
|
version_type=freebsd-$objformat
|
2172 |
|
|
case $version_type in
|
2173 |
|
|
freebsd-elf*)
|
2174 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
|
2175 |
|
|
need_version=no
|
2176 |
|
|
need_lib_prefix=no
|
2177 |
|
|
;;
|
2178 |
|
|
freebsd-*)
|
2179 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
|
2180 |
|
|
need_version=yes
|
2181 |
|
|
;;
|
2182 |
|
|
esac
|
2183 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2184 |
|
|
case $host_os in
|
2185 |
|
|
freebsd2*)
|
2186 |
|
|
shlibpath_overrides_runpath=yes
|
2187 |
|
|
;;
|
2188 |
|
|
freebsd3.[[01]]* | freebsdelf3.[[01]]*)
|
2189 |
|
|
shlibpath_overrides_runpath=yes
|
2190 |
|
|
hardcode_into_libs=yes
|
2191 |
|
|
;;
|
2192 |
|
|
freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
|
2193 |
|
|
freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
|
2194 |
|
|
shlibpath_overrides_runpath=no
|
2195 |
|
|
hardcode_into_libs=yes
|
2196 |
|
|
;;
|
2197 |
|
|
*) # from 4.6 on, and DragonFly
|
2198 |
|
|
shlibpath_overrides_runpath=yes
|
2199 |
|
|
hardcode_into_libs=yes
|
2200 |
|
|
;;
|
2201 |
|
|
esac
|
2202 |
|
|
;;
|
2203 |
|
|
|
2204 |
|
|
gnu*)
|
2205 |
|
|
version_type=linux
|
2206 |
|
|
need_lib_prefix=no
|
2207 |
|
|
need_version=no
|
2208 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
|
2209 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2210 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2211 |
|
|
hardcode_into_libs=yes
|
2212 |
|
|
;;
|
2213 |
|
|
|
2214 |
|
|
hpux9* | hpux10* | hpux11*)
|
2215 |
|
|
# Give a soname corresponding to the major version so that dld.sl refuses to
|
2216 |
|
|
# link against other versions.
|
2217 |
|
|
version_type=sunos
|
2218 |
|
|
need_lib_prefix=no
|
2219 |
|
|
need_version=no
|
2220 |
|
|
case $host_cpu in
|
2221 |
|
|
ia64*)
|
2222 |
|
|
shrext_cmds='.so'
|
2223 |
|
|
hardcode_into_libs=yes
|
2224 |
|
|
dynamic_linker="$host_os dld.so"
|
2225 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2226 |
|
|
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
|
2227 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2228 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2229 |
|
|
if test "X$HPUX_IA64_MODE" = X32; then
|
2230 |
|
|
sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
|
2231 |
|
|
else
|
2232 |
|
|
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
|
2233 |
|
|
fi
|
2234 |
|
|
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
|
2235 |
|
|
;;
|
2236 |
|
|
hppa*64*)
|
2237 |
|
|
shrext_cmds='.sl'
|
2238 |
|
|
hardcode_into_libs=yes
|
2239 |
|
|
dynamic_linker="$host_os dld.sl"
|
2240 |
|
|
shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
|
2241 |
|
|
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
|
2242 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2243 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2244 |
|
|
sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
|
2245 |
|
|
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
|
2246 |
|
|
;;
|
2247 |
|
|
*)
|
2248 |
|
|
shrext_cmds='.sl'
|
2249 |
|
|
dynamic_linker="$host_os dld.sl"
|
2250 |
|
|
shlibpath_var=SHLIB_PATH
|
2251 |
|
|
shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
|
2252 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2253 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2254 |
|
|
;;
|
2255 |
|
|
esac
|
2256 |
|
|
# HP-UX runs *really* slowly unless shared libraries are mode 555.
|
2257 |
|
|
postinstall_cmds='chmod 555 $lib'
|
2258 |
|
|
;;
|
2259 |
|
|
|
2260 |
|
|
interix[[3-9]]*)
|
2261 |
|
|
version_type=linux
|
2262 |
|
|
need_lib_prefix=no
|
2263 |
|
|
need_version=no
|
2264 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
|
2265 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2266 |
|
|
dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
|
2267 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2268 |
|
|
shlibpath_overrides_runpath=no
|
2269 |
|
|
hardcode_into_libs=yes
|
2270 |
|
|
;;
|
2271 |
|
|
|
2272 |
|
|
irix5* | irix6* | nonstopux*)
|
2273 |
|
|
case $host_os in
|
2274 |
|
|
nonstopux*) version_type=nonstopux ;;
|
2275 |
|
|
*)
|
2276 |
|
|
if test "$lt_cv_prog_gnu_ld" = yes; then
|
2277 |
|
|
version_type=linux
|
2278 |
|
|
else
|
2279 |
|
|
version_type=irix
|
2280 |
|
|
fi ;;
|
2281 |
|
|
esac
|
2282 |
|
|
need_lib_prefix=no
|
2283 |
|
|
need_version=no
|
2284 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2285 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
|
2286 |
|
|
case $host_os in
|
2287 |
|
|
irix5* | nonstopux*)
|
2288 |
|
|
libsuff= shlibsuff=
|
2289 |
|
|
;;
|
2290 |
|
|
*)
|
2291 |
|
|
case $LD in # libtool.m4 will add one of these switches to LD
|
2292 |
|
|
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
|
2293 |
|
|
libsuff= shlibsuff= libmagic=32-bit;;
|
2294 |
|
|
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
|
2295 |
|
|
libsuff=32 shlibsuff=N32 libmagic=N32;;
|
2296 |
|
|
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
|
2297 |
|
|
libsuff=64 shlibsuff=64 libmagic=64-bit;;
|
2298 |
|
|
*) libsuff= shlibsuff= libmagic=never-match;;
|
2299 |
|
|
esac
|
2300 |
|
|
;;
|
2301 |
|
|
esac
|
2302 |
|
|
shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
|
2303 |
|
|
shlibpath_overrides_runpath=no
|
2304 |
|
|
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
|
2305 |
|
|
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
|
2306 |
|
|
hardcode_into_libs=yes
|
2307 |
|
|
;;
|
2308 |
|
|
|
2309 |
|
|
# No shared lib support for Linux oldld, aout, or coff.
|
2310 |
|
|
linux*oldld* | linux*aout* | linux*coff*)
|
2311 |
|
|
dynamic_linker=no
|
2312 |
|
|
;;
|
2313 |
|
|
|
2314 |
|
|
# This must be Linux ELF.
|
2315 |
|
|
linux* | k*bsd*-gnu)
|
2316 |
|
|
version_type=linux
|
2317 |
|
|
need_lib_prefix=no
|
2318 |
|
|
need_version=no
|
2319 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2320 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2321 |
|
|
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
|
2322 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2323 |
|
|
shlibpath_overrides_runpath=no
|
2324 |
|
|
# Some binutils ld are patched to set DT_RUNPATH
|
2325 |
|
|
save_LDFLAGS=$LDFLAGS
|
2326 |
|
|
save_libdir=$libdir
|
2327 |
|
|
eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
|
2328 |
|
|
LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
|
2329 |
|
|
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
|
2330 |
|
|
[AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir"],
|
2331 |
|
|
[shlibpath_overrides_runpath=yes])])
|
2332 |
|
|
LDFLAGS=$save_LDFLAGS
|
2333 |
|
|
libdir=$save_libdir
|
2334 |
|
|
|
2335 |
|
|
# This implies no fast_install, which is unacceptable.
|
2336 |
|
|
# Some rework will be needed to allow for fast_install
|
2337 |
|
|
# before this can be enabled.
|
2338 |
|
|
hardcode_into_libs=yes
|
2339 |
|
|
|
2340 |
|
|
# Append ld.so.conf contents to the search path
|
2341 |
|
|
if test -f /etc/ld.so.conf; then
|
2342 |
|
|
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/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
2343 |
|
|
sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
2344 |
|
|
fi
|
2345 |
|
|
|
2346 |
|
|
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
2347 |
|
|
# powerpc, because MkLinux only supported shared libraries with the
|
2348 |
|
|
# GNU dynamic linker. Since this was broken with cross compilers,
|
2349 |
|
|
# most powerpc-linux boxes support dynamic linking these days and
|
2350 |
|
|
# people can always --disable-shared, the test was removed, and we
|
2351 |
|
|
# assume the GNU/Linux dynamic linker is in use.
|
2352 |
|
|
dynamic_linker='GNU/Linux ld.so'
|
2353 |
|
|
;;
|
2354 |
|
|
|
2355 |
|
|
netbsd*)
|
2356 |
|
|
version_type=sunos
|
2357 |
|
|
need_lib_prefix=no
|
2358 |
|
|
need_version=no
|
2359 |
|
|
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
|
2360 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
|
2361 |
|
|
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
|
2362 |
|
|
dynamic_linker='NetBSD (a.out) ld.so'
|
2363 |
|
|
else
|
2364 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
|
2365 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2366 |
|
|
dynamic_linker='NetBSD ld.elf_so'
|
2367 |
|
|
fi
|
2368 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2369 |
|
|
shlibpath_overrides_runpath=yes
|
2370 |
|
|
hardcode_into_libs=yes
|
2371 |
|
|
;;
|
2372 |
|
|
|
2373 |
|
|
newsos6)
|
2374 |
|
|
version_type=linux
|
2375 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2376 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2377 |
|
|
shlibpath_overrides_runpath=yes
|
2378 |
|
|
;;
|
2379 |
|
|
|
2380 |
|
|
*nto* | *qnx*)
|
2381 |
|
|
version_type=qnx
|
2382 |
|
|
need_lib_prefix=no
|
2383 |
|
|
need_version=no
|
2384 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2385 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2386 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2387 |
|
|
shlibpath_overrides_runpath=no
|
2388 |
|
|
hardcode_into_libs=yes
|
2389 |
|
|
dynamic_linker='ldqnx.so'
|
2390 |
|
|
;;
|
2391 |
|
|
|
2392 |
|
|
openbsd*)
|
2393 |
|
|
version_type=sunos
|
2394 |
|
|
sys_lib_dlsearch_path_spec="/usr/lib"
|
2395 |
|
|
need_lib_prefix=no
|
2396 |
|
|
# Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
|
2397 |
|
|
case $host_os in
|
2398 |
|
|
openbsd3.3 | openbsd3.3.*) need_version=yes ;;
|
2399 |
|
|
*) need_version=no ;;
|
2400 |
|
|
esac
|
2401 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
|
2402 |
|
|
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
|
2403 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2404 |
|
|
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
2405 |
|
|
case $host_os in
|
2406 |
|
|
openbsd2.[[89]] | openbsd2.[[89]].*)
|
2407 |
|
|
shlibpath_overrides_runpath=no
|
2408 |
|
|
;;
|
2409 |
|
|
*)
|
2410 |
|
|
shlibpath_overrides_runpath=yes
|
2411 |
|
|
;;
|
2412 |
|
|
esac
|
2413 |
|
|
else
|
2414 |
|
|
shlibpath_overrides_runpath=yes
|
2415 |
|
|
fi
|
2416 |
|
|
;;
|
2417 |
|
|
|
2418 |
|
|
os2*)
|
2419 |
|
|
libname_spec='$name'
|
2420 |
|
|
shrext_cmds=".dll"
|
2421 |
|
|
need_lib_prefix=no
|
2422 |
|
|
library_names_spec='$libname${shared_ext} $libname.a'
|
2423 |
|
|
dynamic_linker='OS/2 ld.exe'
|
2424 |
|
|
shlibpath_var=LIBPATH
|
2425 |
|
|
;;
|
2426 |
|
|
|
2427 |
|
|
osf3* | osf4* | osf5*)
|
2428 |
|
|
version_type=osf
|
2429 |
|
|
need_lib_prefix=no
|
2430 |
|
|
need_version=no
|
2431 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2432 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2433 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2434 |
|
|
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
|
2435 |
|
|
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
|
2436 |
|
|
;;
|
2437 |
|
|
|
2438 |
|
|
rdos*)
|
2439 |
|
|
dynamic_linker=no
|
2440 |
|
|
;;
|
2441 |
|
|
|
2442 |
|
|
solaris*)
|
2443 |
|
|
version_type=linux
|
2444 |
|
|
need_lib_prefix=no
|
2445 |
|
|
need_version=no
|
2446 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2447 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2448 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2449 |
|
|
shlibpath_overrides_runpath=yes
|
2450 |
|
|
hardcode_into_libs=yes
|
2451 |
|
|
# ldd complains unless libraries are executable
|
2452 |
|
|
postinstall_cmds='chmod +x $lib'
|
2453 |
|
|
;;
|
2454 |
|
|
|
2455 |
|
|
sunos4*)
|
2456 |
|
|
version_type=sunos
|
2457 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
|
2458 |
|
|
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
|
2459 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2460 |
|
|
shlibpath_overrides_runpath=yes
|
2461 |
|
|
if test "$with_gnu_ld" = yes; then
|
2462 |
|
|
need_lib_prefix=no
|
2463 |
|
|
fi
|
2464 |
|
|
need_version=yes
|
2465 |
|
|
;;
|
2466 |
|
|
|
2467 |
|
|
sysv4 | sysv4.3*)
|
2468 |
|
|
version_type=linux
|
2469 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2470 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2471 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2472 |
|
|
case $host_vendor in
|
2473 |
|
|
sni)
|
2474 |
|
|
shlibpath_overrides_runpath=no
|
2475 |
|
|
need_lib_prefix=no
|
2476 |
|
|
runpath_var=LD_RUN_PATH
|
2477 |
|
|
;;
|
2478 |
|
|
siemens)
|
2479 |
|
|
need_lib_prefix=no
|
2480 |
|
|
;;
|
2481 |
|
|
motorola)
|
2482 |
|
|
need_lib_prefix=no
|
2483 |
|
|
need_version=no
|
2484 |
|
|
shlibpath_overrides_runpath=no
|
2485 |
|
|
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
|
2486 |
|
|
;;
|
2487 |
|
|
esac
|
2488 |
|
|
;;
|
2489 |
|
|
|
2490 |
|
|
sysv4*MP*)
|
2491 |
|
|
if test -d /usr/nec ;then
|
2492 |
|
|
version_type=linux
|
2493 |
|
|
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
|
2494 |
|
|
soname_spec='$libname${shared_ext}.$major'
|
2495 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2496 |
|
|
fi
|
2497 |
|
|
;;
|
2498 |
|
|
|
2499 |
|
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
|
2500 |
|
|
version_type=freebsd-elf
|
2501 |
|
|
need_lib_prefix=no
|
2502 |
|
|
need_version=no
|
2503 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
|
2504 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2505 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2506 |
|
|
shlibpath_overrides_runpath=yes
|
2507 |
|
|
hardcode_into_libs=yes
|
2508 |
|
|
if test "$with_gnu_ld" = yes; then
|
2509 |
|
|
sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
|
2510 |
|
|
else
|
2511 |
|
|
sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
|
2512 |
|
|
case $host_os in
|
2513 |
|
|
sco3.2v5*)
|
2514 |
|
|
sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
|
2515 |
|
|
;;
|
2516 |
|
|
esac
|
2517 |
|
|
fi
|
2518 |
|
|
sys_lib_dlsearch_path_spec='/usr/lib'
|
2519 |
|
|
;;
|
2520 |
|
|
|
2521 |
|
|
tpf*)
|
2522 |
|
|
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
|
2523 |
|
|
version_type=linux
|
2524 |
|
|
need_lib_prefix=no
|
2525 |
|
|
need_version=no
|
2526 |
|
|
library_name_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2527 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2528 |
|
|
shlibpath_overrides_runpath=no
|
2529 |
|
|
hardcode_into_libs=yes
|
2530 |
|
|
;;
|
2531 |
|
|
|
2532 |
|
|
uts4*)
|
2533 |
|
|
version_type=linux
|
2534 |
|
|
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
|
2535 |
|
|
soname_spec='${libname}${release}${shared_ext}$major'
|
2536 |
|
|
shlibpath_var=LD_LIBRARY_PATH
|
2537 |
|
|
;;
|
2538 |
|
|
|
2539 |
|
|
*)
|
2540 |
|
|
dynamic_linker=no
|
2541 |
|
|
;;
|
2542 |
|
|
esac
|
2543 |
|
|
AC_MSG_RESULT([$dynamic_linker])
|
2544 |
|
|
test "$dynamic_linker" = no && can_build_shared=no
|
2545 |
|
|
|
2546 |
|
|
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
|
2547 |
|
|
if test "$GCC" = yes; then
|
2548 |
|
|
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
|
2549 |
|
|
fi
|
2550 |
|
|
|
2551 |
|
|
_LT_DECL([], [variables_saved_for_relink], [1],
|
2552 |
|
|
[Variables whose values should be saved in libtool wrapper scripts and
|
2553 |
|
|
restored at link time])
|
2554 |
|
|
_LT_DECL([], [need_lib_prefix], [0],
|
2555 |
|
|
[Do we need the "lib" prefix for modules?])
|
2556 |
|
|
_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
|
2557 |
|
|
_LT_DECL([], [version_type], [0], [Library versioning type])
|
2558 |
|
|
_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
|
2559 |
|
|
_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
|
2560 |
|
|
_LT_DECL([], [shlibpath_overrides_runpath], [0],
|
2561 |
|
|
[Is shlibpath searched before the hard-coded library search path?])
|
2562 |
|
|
_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
|
2563 |
|
|
_LT_DECL([], [library_names_spec], [1],
|
2564 |
|
|
[[List of archive names. First name is the real one, the rest are links.
|
2565 |
|
|
The last name is the one that the linker finds with -lNAME]])
|
2566 |
|
|
_LT_DECL([], [soname_spec], [1],
|
2567 |
|
|
[[The coded name of the library, if different from the real name]])
|
2568 |
|
|
_LT_DECL([], [postinstall_cmds], [2],
|
2569 |
|
|
[Command to use after installation of a shared archive])
|
2570 |
|
|
_LT_DECL([], [postuninstall_cmds], [2],
|
2571 |
|
|
[Command to use after uninstallation of a shared archive])
|
2572 |
|
|
_LT_DECL([], [finish_cmds], [2],
|
2573 |
|
|
[Commands used to finish a libtool library installation in a directory])
|
2574 |
|
|
_LT_DECL([], [finish_eval], [1],
|
2575 |
|
|
[[As "finish_cmds", except a single script fragment to be evaled but
|
2576 |
|
|
not shown]])
|
2577 |
|
|
_LT_DECL([], [hardcode_into_libs], [0],
|
2578 |
|
|
[Whether we should hardcode library paths into libraries])
|
2579 |
|
|
_LT_DECL([], [sys_lib_search_path_spec], [2],
|
2580 |
|
|
[Compile-time system search path for libraries])
|
2581 |
|
|
_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
|
2582 |
|
|
[Run-time system search path for libraries])
|
2583 |
|
|
])# _LT_SYS_DYNAMIC_LINKER
|
2584 |
|
|
|
2585 |
|
|
|
2586 |
|
|
# _LT_PATH_TOOL_PREFIX(TOOL)
|
2587 |
|
|
# --------------------------
|
2588 |
|
|
# find a file program which can recognize shared library
|
2589 |
|
|
AC_DEFUN([_LT_PATH_TOOL_PREFIX],
|
2590 |
|
|
[m4_require([_LT_DECL_EGREP])dnl
|
2591 |
|
|
AC_MSG_CHECKING([for $1])
|
2592 |
|
|
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
|
2593 |
|
|
[case $MAGIC_CMD in
|
2594 |
|
|
[[\\/*] | ?:[\\/]*])
|
2595 |
|
|
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
|
2596 |
|
|
;;
|
2597 |
|
|
*)
|
2598 |
|
|
lt_save_MAGIC_CMD="$MAGIC_CMD"
|
2599 |
|
|
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
2600 |
|
|
dnl $ac_dummy forces splitting on constant user-supplied paths.
|
2601 |
|
|
dnl POSIX.2 word splitting is done only on the output of word expansions,
|
2602 |
|
|
dnl not every word. This closes a longstanding sh security hole.
|
2603 |
|
|
ac_dummy="m4_if([$2], , $PATH, [$2])"
|
2604 |
|
|
for ac_dir in $ac_dummy; do
|
2605 |
|
|
IFS="$lt_save_ifs"
|
2606 |
|
|
test -z "$ac_dir" && ac_dir=.
|
2607 |
|
|
if test -f $ac_dir/$1; then
|
2608 |
|
|
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
|
2609 |
|
|
if test -n "$file_magic_test_file"; then
|
2610 |
|
|
case $deplibs_check_method in
|
2611 |
|
|
"file_magic "*)
|
2612 |
|
|
file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
|
2613 |
|
|
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
|
2614 |
|
|
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
|
2615 |
|
|
$EGREP "$file_magic_regex" > /dev/null; then
|
2616 |
|
|
:
|
2617 |
|
|
else
|
2618 |
|
|
cat <<_LT_EOF 1>&2
|
2619 |
|
|
|
2620 |
|
|
*** Warning: the command libtool uses to detect shared libraries,
|
2621 |
|
|
*** $file_magic_cmd, produces output that libtool cannot recognize.
|
2622 |
|
|
*** The result is that libtool may fail to recognize shared libraries
|
2623 |
|
|
*** as such. This will affect the creation of libtool libraries that
|
2624 |
|
|
*** depend on shared libraries, but programs linked with such libtool
|
2625 |
|
|
*** libraries will work regardless of this problem. Nevertheless, you
|
2626 |
|
|
*** may want to report the problem to your system manager and/or to
|
2627 |
|
|
*** bug-libtool@gnu.org
|
2628 |
|
|
|
2629 |
|
|
_LT_EOF
|
2630 |
|
|
fi ;;
|
2631 |
|
|
esac
|
2632 |
|
|
fi
|
2633 |
|
|
break
|
2634 |
|
|
fi
|
2635 |
|
|
done
|
2636 |
|
|
IFS="$lt_save_ifs"
|
2637 |
|
|
MAGIC_CMD="$lt_save_MAGIC_CMD"
|
2638 |
|
|
;;
|
2639 |
|
|
esac])
|
2640 |
|
|
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
|
2641 |
|
|
if test -n "$MAGIC_CMD"; then
|
2642 |
|
|
AC_MSG_RESULT($MAGIC_CMD)
|
2643 |
|
|
else
|
2644 |
|
|
AC_MSG_RESULT(no)
|
2645 |
|
|
fi
|
2646 |
|
|
_LT_DECL([], [MAGIC_CMD], [0],
|
2647 |
|
|
[Used to examine libraries when file_magic_cmd begins with "file"])dnl
|
2648 |
|
|
])# _LT_PATH_TOOL_PREFIX
|
2649 |
|
|
|
2650 |
|
|
# Old name:
|
2651 |
|
|
AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
|
2652 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
2653 |
|
|
dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
|
2654 |
|
|
|
2655 |
|
|
|
2656 |
|
|
# _LT_PATH_MAGIC
|
2657 |
|
|
# --------------
|
2658 |
|
|
# find a file program which can recognize a shared library
|
2659 |
|
|
m4_defun([_LT_PATH_MAGIC],
|
2660 |
|
|
[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
|
2661 |
|
|
if test -z "$lt_cv_path_MAGIC_CMD"; then
|
2662 |
|
|
if test -n "$ac_tool_prefix"; then
|
2663 |
|
|
_LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
|
2664 |
|
|
else
|
2665 |
|
|
MAGIC_CMD=:
|
2666 |
|
|
fi
|
2667 |
|
|
fi
|
2668 |
|
|
])# _LT_PATH_MAGIC
|
2669 |
|
|
|
2670 |
|
|
|
2671 |
|
|
# LT_PATH_LD
|
2672 |
|
|
# ----------
|
2673 |
|
|
# find the pathname to the GNU or non-GNU linker
|
2674 |
|
|
AC_DEFUN([LT_PATH_LD],
|
2675 |
|
|
[AC_REQUIRE([AC_PROG_CC])dnl
|
2676 |
|
|
AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
2677 |
|
|
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
|
2678 |
|
|
m4_require([_LT_DECL_SED])dnl
|
2679 |
|
|
m4_require([_LT_DECL_EGREP])dnl
|
2680 |
|
|
|
2681 |
|
|
AC_ARG_WITH([gnu-ld],
|
2682 |
|
|
[AS_HELP_STRING([--with-gnu-ld],
|
2683 |
|
|
[assume the C compiler uses GNU ld @<:@default=no@:>@])],
|
2684 |
|
|
[test "$withval" = no || with_gnu_ld=yes],
|
2685 |
|
|
[with_gnu_ld=no])dnl
|
2686 |
|
|
|
2687 |
|
|
ac_prog=ld
|
2688 |
|
|
if test "$GCC" = yes; then
|
2689 |
|
|
# Check if gcc -print-prog-name=ld gives a path.
|
2690 |
|
|
AC_MSG_CHECKING([for ld used by $CC])
|
2691 |
|
|
case $host in
|
2692 |
|
|
*-*-mingw*)
|
2693 |
|
|
# gcc leaves a trailing carriage return which upsets mingw
|
2694 |
|
|
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
|
2695 |
|
|
*)
|
2696 |
|
|
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
|
2697 |
|
|
esac
|
2698 |
|
|
case $ac_prog in
|
2699 |
|
|
# Accept absolute paths.
|
2700 |
|
|
[[\\/]]* | ?:[[\\/]]*)
|
2701 |
|
|
re_direlt='/[[^/]][[^/]]*/\.\./'
|
2702 |
|
|
# Canonicalize the pathname of ld
|
2703 |
|
|
ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
|
2704 |
|
|
while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
|
2705 |
|
|
ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
|
2706 |
|
|
done
|
2707 |
|
|
test -z "$LD" && LD="$ac_prog"
|
2708 |
|
|
;;
|
2709 |
|
|
"")
|
2710 |
|
|
# If it fails, then pretend we aren't using GCC.
|
2711 |
|
|
ac_prog=ld
|
2712 |
|
|
;;
|
2713 |
|
|
*)
|
2714 |
|
|
# If it is relative, then search for the first ld in PATH.
|
2715 |
|
|
with_gnu_ld=unknown
|
2716 |
|
|
;;
|
2717 |
|
|
esac
|
2718 |
|
|
elif test "$with_gnu_ld" = yes; then
|
2719 |
|
|
AC_MSG_CHECKING([for GNU ld])
|
2720 |
|
|
else
|
2721 |
|
|
AC_MSG_CHECKING([for non-GNU ld])
|
2722 |
|
|
fi
|
2723 |
|
|
AC_CACHE_VAL(lt_cv_path_LD,
|
2724 |
|
|
[if test -z "$LD"; then
|
2725 |
|
|
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
2726 |
|
|
for ac_dir in $PATH; do
|
2727 |
|
|
IFS="$lt_save_ifs"
|
2728 |
|
|
test -z "$ac_dir" && ac_dir=.
|
2729 |
|
|
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
|
2730 |
|
|
lt_cv_path_LD="$ac_dir/$ac_prog"
|
2731 |
|
|
# Check to see if the program is GNU ld. I'd rather use --version,
|
2732 |
|
|
# but apparently some variants of GNU ld only accept -v.
|
2733 |
|
|
# Break only if it was the GNU/non-GNU ld that we prefer.
|
2734 |
|
|
case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
|
2735 |
|
|
*GNU* | *'with BFD'*)
|
2736 |
|
|
test "$with_gnu_ld" != no && break
|
2737 |
|
|
;;
|
2738 |
|
|
*)
|
2739 |
|
|
test "$with_gnu_ld" != yes && break
|
2740 |
|
|
;;
|
2741 |
|
|
esac
|
2742 |
|
|
fi
|
2743 |
|
|
done
|
2744 |
|
|
IFS="$lt_save_ifs"
|
2745 |
|
|
else
|
2746 |
|
|
lt_cv_path_LD="$LD" # Let the user override the test with a path.
|
2747 |
|
|
fi])
|
2748 |
|
|
LD="$lt_cv_path_LD"
|
2749 |
|
|
if test -n "$LD"; then
|
2750 |
|
|
AC_MSG_RESULT($LD)
|
2751 |
|
|
else
|
2752 |
|
|
AC_MSG_RESULT(no)
|
2753 |
|
|
fi
|
2754 |
|
|
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
|
2755 |
|
|
_LT_PATH_LD_GNU
|
2756 |
|
|
AC_SUBST([LD])
|
2757 |
|
|
|
2758 |
|
|
_LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
|
2759 |
|
|
])# LT_PATH_LD
|
2760 |
|
|
|
2761 |
|
|
# Old names:
|
2762 |
|
|
AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
|
2763 |
|
|
AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
|
2764 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
2765 |
|
|
dnl AC_DEFUN([AM_PROG_LD], [])
|
2766 |
|
|
dnl AC_DEFUN([AC_PROG_LD], [])
|
2767 |
|
|
|
2768 |
|
|
|
2769 |
|
|
# _LT_PATH_LD_GNU
|
2770 |
|
|
#- --------------
|
2771 |
|
|
m4_defun([_LT_PATH_LD_GNU],
|
2772 |
|
|
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
|
2773 |
|
|
[# I'd rather use --version here, but apparently some GNU lds only accept -v.
|
2774 |
|
|
case `$LD -v 2>&1 </dev/null` in
|
2775 |
|
|
*GNU* | *'with BFD'*)
|
2776 |
|
|
lt_cv_prog_gnu_ld=yes
|
2777 |
|
|
;;
|
2778 |
|
|
*)
|
2779 |
|
|
lt_cv_prog_gnu_ld=no
|
2780 |
|
|
;;
|
2781 |
|
|
esac])
|
2782 |
|
|
with_gnu_ld=$lt_cv_prog_gnu_ld
|
2783 |
|
|
])# _LT_PATH_LD_GNU
|
2784 |
|
|
|
2785 |
|
|
|
2786 |
|
|
# _LT_CMD_RELOAD
|
2787 |
|
|
# --------------
|
2788 |
|
|
# find reload flag for linker
|
2789 |
|
|
# -- PORTME Some linkers may need a different reload flag.
|
2790 |
|
|
m4_defun([_LT_CMD_RELOAD],
|
2791 |
|
|
[AC_CACHE_CHECK([for $LD option to reload object files],
|
2792 |
|
|
lt_cv_ld_reload_flag,
|
2793 |
|
|
[lt_cv_ld_reload_flag='-r'])
|
2794 |
|
|
reload_flag=$lt_cv_ld_reload_flag
|
2795 |
|
|
case $reload_flag in
|
2796 |
|
|
"" | " "*) ;;
|
2797 |
|
|
*) reload_flag=" $reload_flag" ;;
|
2798 |
|
|
esac
|
2799 |
|
|
reload_cmds='$LD$reload_flag -o $output$reload_objs'
|
2800 |
|
|
case $host_os in
|
2801 |
|
|
darwin*)
|
2802 |
|
|
if test "$GCC" = yes; then
|
2803 |
|
|
reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
|
2804 |
|
|
else
|
2805 |
|
|
reload_cmds='$LD$reload_flag -o $output$reload_objs'
|
2806 |
|
|
fi
|
2807 |
|
|
;;
|
2808 |
|
|
esac
|
2809 |
|
|
_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
|
2810 |
|
|
_LT_DECL([], [reload_cmds], [2])dnl
|
2811 |
|
|
])# _LT_CMD_RELOAD
|
2812 |
|
|
|
2813 |
|
|
|
2814 |
|
|
# _LT_CHECK_MAGIC_METHOD
|
2815 |
|
|
# ----------------------
|
2816 |
|
|
# how to check for library dependencies
|
2817 |
|
|
# -- PORTME fill in with the dynamic library characteristics
|
2818 |
|
|
m4_defun([_LT_CHECK_MAGIC_METHOD],
|
2819 |
|
|
[m4_require([_LT_DECL_EGREP])
|
2820 |
|
|
AC_CACHE_CHECK([how to recognize dependent libraries],
|
2821 |
|
|
lt_cv_deplibs_check_method,
|
2822 |
|
|
[lt_cv_file_magic_cmd='$MAGIC_CMD'
|
2823 |
|
|
lt_cv_file_magic_test_file=
|
2824 |
|
|
lt_cv_deplibs_check_method='unknown'
|
2825 |
|
|
# Need to set the preceding variable on all platforms that support
|
2826 |
|
|
# interlibrary dependencies.
|
2827 |
|
|
# 'none' -- dependencies not supported.
|
2828 |
|
|
# `unknown' -- same as none, but documents that we really don't know.
|
2829 |
|
|
# 'pass_all' -- all dependencies passed with no checks.
|
2830 |
|
|
# 'test_compile' -- check by making test program.
|
2831 |
|
|
# 'file_magic [[regex]]' -- check by looking for files in library path
|
2832 |
|
|
# which responds to the $file_magic_cmd with a given extended regex.
|
2833 |
|
|
# If you have `file' or equivalent on your system and you're not sure
|
2834 |
|
|
# whether `pass_all' will *always* work, you probably want this one.
|
2835 |
|
|
|
2836 |
|
|
case $host_os in
|
2837 |
|
|
aix[[4-9]]*)
|
2838 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2839 |
|
|
;;
|
2840 |
|
|
|
2841 |
|
|
beos*)
|
2842 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2843 |
|
|
;;
|
2844 |
|
|
|
2845 |
|
|
bsdi[[45]]*)
|
2846 |
|
|
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
|
2847 |
|
|
lt_cv_file_magic_cmd='/usr/bin/file -L'
|
2848 |
|
|
lt_cv_file_magic_test_file=/shlib/libc.so
|
2849 |
|
|
;;
|
2850 |
|
|
|
2851 |
|
|
cygwin*)
|
2852 |
|
|
# func_win32_libid is a shell function defined in ltmain.sh
|
2853 |
|
|
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
|
2854 |
|
|
lt_cv_file_magic_cmd='func_win32_libid'
|
2855 |
|
|
;;
|
2856 |
|
|
|
2857 |
|
|
mingw* | pw32*)
|
2858 |
|
|
# Base MSYS/MinGW do not provide the 'file' command needed by
|
2859 |
|
|
# func_win32_libid shell function, so use a weaker test based on 'objdump',
|
2860 |
|
|
# unless we find 'file', for example because we are cross-compiling.
|
2861 |
|
|
if ( file / ) >/dev/null 2>&1; then
|
2862 |
|
|
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
|
2863 |
|
|
lt_cv_file_magic_cmd='func_win32_libid'
|
2864 |
|
|
else
|
2865 |
|
|
lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
|
2866 |
|
|
lt_cv_file_magic_cmd='$OBJDUMP -f'
|
2867 |
|
|
fi
|
2868 |
|
|
;;
|
2869 |
|
|
|
2870 |
|
|
darwin* | rhapsody*)
|
2871 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2872 |
|
|
;;
|
2873 |
|
|
|
2874 |
|
|
freebsd* | dragonfly*)
|
2875 |
|
|
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
|
2876 |
|
|
case $host_cpu in
|
2877 |
|
|
i*86 )
|
2878 |
|
|
# Not sure whether the presence of OpenBSD here was a mistake.
|
2879 |
|
|
# Let's accept both of them until this is cleared up.
|
2880 |
|
|
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
|
2881 |
|
|
lt_cv_file_magic_cmd=/usr/bin/file
|
2882 |
|
|
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
|
2883 |
|
|
;;
|
2884 |
|
|
esac
|
2885 |
|
|
else
|
2886 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2887 |
|
|
fi
|
2888 |
|
|
;;
|
2889 |
|
|
|
2890 |
|
|
gnu*)
|
2891 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2892 |
|
|
;;
|
2893 |
|
|
|
2894 |
|
|
hpux10.20* | hpux11*)
|
2895 |
|
|
lt_cv_file_magic_cmd=/usr/bin/file
|
2896 |
|
|
case $host_cpu in
|
2897 |
|
|
ia64*)
|
2898 |
|
|
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
|
2899 |
|
|
lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
|
2900 |
|
|
;;
|
2901 |
|
|
hppa*64*)
|
2902 |
|
|
[lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
|
2903 |
|
|
lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
|
2904 |
|
|
;;
|
2905 |
|
|
*)
|
2906 |
|
|
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
|
2907 |
|
|
lt_cv_file_magic_test_file=/usr/lib/libc.sl
|
2908 |
|
|
;;
|
2909 |
|
|
esac
|
2910 |
|
|
;;
|
2911 |
|
|
|
2912 |
|
|
interix[[3-9]]*)
|
2913 |
|
|
# PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
|
2914 |
|
|
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
|
2915 |
|
|
;;
|
2916 |
|
|
|
2917 |
|
|
irix5* | irix6* | nonstopux*)
|
2918 |
|
|
case $LD in
|
2919 |
|
|
*-32|*"-32 ") libmagic=32-bit;;
|
2920 |
|
|
*-n32|*"-n32 ") libmagic=N32;;
|
2921 |
|
|
*-64|*"-64 ") libmagic=64-bit;;
|
2922 |
|
|
*) libmagic=never-match;;
|
2923 |
|
|
esac
|
2924 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2925 |
|
|
;;
|
2926 |
|
|
|
2927 |
|
|
# This must be Linux ELF.
|
2928 |
|
|
linux* | k*bsd*-gnu)
|
2929 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2930 |
|
|
;;
|
2931 |
|
|
|
2932 |
|
|
netbsd*)
|
2933 |
|
|
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
|
2934 |
|
|
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
|
2935 |
|
|
else
|
2936 |
|
|
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
|
2937 |
|
|
fi
|
2938 |
|
|
;;
|
2939 |
|
|
|
2940 |
|
|
newos6*)
|
2941 |
|
|
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
|
2942 |
|
|
lt_cv_file_magic_cmd=/usr/bin/file
|
2943 |
|
|
lt_cv_file_magic_test_file=/usr/lib/libnls.so
|
2944 |
|
|
;;
|
2945 |
|
|
|
2946 |
|
|
*nto* | *qnx*)
|
2947 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2948 |
|
|
;;
|
2949 |
|
|
|
2950 |
|
|
openbsd*)
|
2951 |
|
|
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
2952 |
|
|
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
|
2953 |
|
|
else
|
2954 |
|
|
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
|
2955 |
|
|
fi
|
2956 |
|
|
;;
|
2957 |
|
|
|
2958 |
|
|
osf3* | osf4* | osf5*)
|
2959 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2960 |
|
|
;;
|
2961 |
|
|
|
2962 |
|
|
rdos*)
|
2963 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2964 |
|
|
;;
|
2965 |
|
|
|
2966 |
|
|
solaris*)
|
2967 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2968 |
|
|
;;
|
2969 |
|
|
|
2970 |
|
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
|
2971 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2972 |
|
|
;;
|
2973 |
|
|
|
2974 |
|
|
sysv4 | sysv4.3*)
|
2975 |
|
|
case $host_vendor in
|
2976 |
|
|
motorola)
|
2977 |
|
|
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]]'
|
2978 |
|
|
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
|
2979 |
|
|
;;
|
2980 |
|
|
ncr)
|
2981 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2982 |
|
|
;;
|
2983 |
|
|
sequent)
|
2984 |
|
|
lt_cv_file_magic_cmd='/bin/file'
|
2985 |
|
|
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
|
2986 |
|
|
;;
|
2987 |
|
|
sni)
|
2988 |
|
|
lt_cv_file_magic_cmd='/bin/file'
|
2989 |
|
|
lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
|
2990 |
|
|
lt_cv_file_magic_test_file=/lib/libc.so
|
2991 |
|
|
;;
|
2992 |
|
|
siemens)
|
2993 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2994 |
|
|
;;
|
2995 |
|
|
pc)
|
2996 |
|
|
lt_cv_deplibs_check_method=pass_all
|
2997 |
|
|
;;
|
2998 |
|
|
esac
|
2999 |
|
|
;;
|
3000 |
|
|
|
3001 |
|
|
tpf*)
|
3002 |
|
|
lt_cv_deplibs_check_method=pass_all
|
3003 |
|
|
;;
|
3004 |
|
|
esac
|
3005 |
|
|
])
|
3006 |
|
|
file_magic_cmd=$lt_cv_file_magic_cmd
|
3007 |
|
|
deplibs_check_method=$lt_cv_deplibs_check_method
|
3008 |
|
|
test -z "$deplibs_check_method" && deplibs_check_method=unknown
|
3009 |
|
|
|
3010 |
|
|
_LT_DECL([], [deplibs_check_method], [1],
|
3011 |
|
|
[Method to check whether dependent libraries are shared objects])
|
3012 |
|
|
_LT_DECL([], [file_magic_cmd], [1],
|
3013 |
|
|
[Command to use when deplibs_check_method == "file_magic"])
|
3014 |
|
|
])# _LT_CHECK_MAGIC_METHOD
|
3015 |
|
|
|
3016 |
|
|
|
3017 |
|
|
# LT_PATH_NM
|
3018 |
|
|
# ----------
|
3019 |
|
|
# find the pathname to a BSD- or MS-compatible name lister
|
3020 |
|
|
AC_DEFUN([LT_PATH_NM],
|
3021 |
|
|
[AC_REQUIRE([AC_PROG_CC])dnl
|
3022 |
|
|
AC_REQUIRE([AC_OBJEXT])dnl
|
3023 |
|
|
AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
|
3024 |
|
|
[if test -n "$NM"; then
|
3025 |
|
|
# Let the user override the test.
|
3026 |
|
|
lt_cv_path_NM="$NM"
|
3027 |
|
|
else
|
3028 |
|
|
lt_nm_to_check="${ac_tool_prefix}nm"
|
3029 |
|
|
if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
|
3030 |
|
|
lt_nm_to_check="$lt_nm_to_check nm"
|
3031 |
|
|
fi
|
3032 |
|
|
for lt_tmp_nm in $lt_nm_to_check; do
|
3033 |
|
|
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
|
3034 |
|
|
for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
|
3035 |
|
|
IFS="$lt_save_ifs"
|
3036 |
|
|
test -z "$ac_dir" && ac_dir=.
|
3037 |
|
|
tmp_nm="$ac_dir/$lt_tmp_nm"
|
3038 |
|
|
if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
|
3039 |
|
|
# Check to see if the nm accepts a BSD-compat flag.
|
3040 |
|
|
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
|
3041 |
|
|
# nm: unknown option "B" ignored
|
3042 |
|
|
# Tru64's nm complains that /dev/null is an invalid object file
|
3043 |
|
|
case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
|
3044 |
|
|
*/dev/null* | *'Invalid file or object type'*)
|
3045 |
|
|
lt_cv_path_NM="$tmp_nm -B"
|
3046 |
|
|
break
|
3047 |
|
|
;;
|
3048 |
|
|
*)
|
3049 |
|
|
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
|
3050 |
|
|
*/dev/null*)
|
3051 |
|
|
lt_cv_path_NM="$tmp_nm -p"
|
3052 |
|
|
break
|
3053 |
|
|
;;
|
3054 |
|
|
*)
|
3055 |
|
|
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
|
3056 |
|
|
continue # so that we can try to find one that supports BSD flags
|
3057 |
|
|
;;
|
3058 |
|
|
esac
|
3059 |
|
|
;;
|
3060 |
|
|
esac
|
3061 |
|
|
fi
|
3062 |
|
|
done
|
3063 |
|
|
IFS="$lt_save_ifs"
|
3064 |
|
|
done
|
3065 |
|
|
: ${lt_cv_path_NM=no}
|
3066 |
|
|
fi])
|
3067 |
|
|
if test "$lt_cv_path_NM" != "no"; then
|
3068 |
|
|
NM="$lt_cv_path_NM"
|
3069 |
|
|
else
|
3070 |
|
|
# Didn't find any BSD compatible name lister, look for dumpbin.
|
3071 |
|
|
AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
|
3072 |
|
|
AC_SUBST([DUMPBIN])
|
3073 |
|
|
if test "$DUMPBIN" != ":"; then
|
3074 |
|
|
NM="$DUMPBIN"
|
3075 |
|
|
fi
|
3076 |
|
|
fi
|
3077 |
|
|
test -z "$NM" && NM=nm
|
3078 |
|
|
AC_SUBST([NM])
|
3079 |
|
|
_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
|
3080 |
|
|
|
3081 |
|
|
AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
|
3082 |
|
|
[lt_cv_nm_interface="BSD nm"
|
3083 |
|
|
echo "int some_variable = 0;" > conftest.$ac_ext
|
3084 |
|
|
(eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
|
3085 |
|
|
(eval "$ac_compile" 2>conftest.err)
|
3086 |
|
|
cat conftest.err >&AS_MESSAGE_LOG_FD
|
3087 |
|
|
(eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
|
3088 |
|
|
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
|
3089 |
|
|
cat conftest.err >&AS_MESSAGE_LOG_FD
|
3090 |
|
|
(eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
|
3091 |
|
|
cat conftest.out >&AS_MESSAGE_LOG_FD
|
3092 |
|
|
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
|
3093 |
|
|
lt_cv_nm_interface="MS dumpbin"
|
3094 |
|
|
fi
|
3095 |
|
|
rm -f conftest*])
|
3096 |
|
|
])# LT_PATH_NM
|
3097 |
|
|
|
3098 |
|
|
# Old names:
|
3099 |
|
|
AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
|
3100 |
|
|
AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
|
3101 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
3102 |
|
|
dnl AC_DEFUN([AM_PROG_NM], [])
|
3103 |
|
|
dnl AC_DEFUN([AC_PROG_NM], [])
|
3104 |
|
|
|
3105 |
|
|
|
3106 |
|
|
# LT_LIB_M
|
3107 |
|
|
# --------
|
3108 |
|
|
# check for math library
|
3109 |
|
|
AC_DEFUN([LT_LIB_M],
|
3110 |
|
|
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
3111 |
|
|
LIBM=
|
3112 |
|
|
case $host in
|
3113 |
|
|
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
|
3114 |
|
|
# These system don't have libm, or don't need it
|
3115 |
|
|
;;
|
3116 |
|
|
*-ncr-sysv4.3*)
|
3117 |
|
|
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
|
3118 |
|
|
AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
|
3119 |
|
|
;;
|
3120 |
|
|
*)
|
3121 |
|
|
AC_CHECK_LIB(m, cos, LIBM="-lm")
|
3122 |
|
|
;;
|
3123 |
|
|
esac
|
3124 |
|
|
AC_SUBST([LIBM])
|
3125 |
|
|
])# LT_LIB_M
|
3126 |
|
|
|
3127 |
|
|
# Old name:
|
3128 |
|
|
AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
|
3129 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
3130 |
|
|
dnl AC_DEFUN([AC_CHECK_LIBM], [])
|
3131 |
|
|
|
3132 |
|
|
|
3133 |
|
|
# _LT_COMPILER_NO_RTTI([TAGNAME])
|
3134 |
|
|
# -------------------------------
|
3135 |
|
|
m4_defun([_LT_COMPILER_NO_RTTI],
|
3136 |
|
|
[m4_require([_LT_TAG_COMPILER])dnl
|
3137 |
|
|
|
3138 |
|
|
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
|
3139 |
|
|
|
3140 |
|
|
if test "$GCC" = yes; then
|
3141 |
|
|
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
|
3142 |
|
|
|
3143 |
|
|
_LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
|
3144 |
|
|
lt_cv_prog_compiler_rtti_exceptions,
|
3145 |
|
|
[-fno-rtti -fno-exceptions], [],
|
3146 |
|
|
[_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
|
3147 |
|
|
fi
|
3148 |
|
|
_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
|
3149 |
|
|
[Compiler flag to turn off builtin functions])
|
3150 |
|
|
])# _LT_COMPILER_NO_RTTI
|
3151 |
|
|
|
3152 |
|
|
|
3153 |
|
|
# _LT_CMD_GLOBAL_SYMBOLS
|
3154 |
|
|
# ----------------------
|
3155 |
|
|
m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
|
3156 |
|
|
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
3157 |
|
|
AC_REQUIRE([AC_PROG_CC])dnl
|
3158 |
|
|
AC_REQUIRE([AC_OBJEXT])dnl
|
3159 |
|
|
AC_REQUIRE([LT_PATH_NM])dnl
|
3160 |
|
|
AC_REQUIRE([LT_PATH_LD])dnl
|
3161 |
|
|
m4_require([_LT_DECL_SED])dnl
|
3162 |
|
|
m4_require([_LT_DECL_EGREP])dnl
|
3163 |
|
|
m4_require([_LT_TAG_COMPILER])dnl
|
3164 |
|
|
|
3165 |
|
|
# Check for command to grab the raw symbol name followed by C symbol from nm.
|
3166 |
|
|
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
|
3167 |
|
|
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
|
3168 |
|
|
[
|
3169 |
|
|
# These are sane defaults that work on at least a few old systems.
|
3170 |
|
|
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
|
3171 |
|
|
|
3172 |
|
|
# Character class describing NM global symbol codes.
|
3173 |
|
|
symcode='[[BCDEGRST]]'
|
3174 |
|
|
|
3175 |
|
|
# Regexp to match symbols that can be accessed directly from C.
|
3176 |
|
|
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
|
3177 |
|
|
|
3178 |
|
|
# Define system-specific variables.
|
3179 |
|
|
case $host_os in
|
3180 |
|
|
aix*)
|
3181 |
|
|
symcode='[[BCDT]]'
|
3182 |
|
|
;;
|
3183 |
|
|
cygwin* | mingw* | pw32*)
|
3184 |
|
|
symcode='[[ABCDGISTW]]'
|
3185 |
|
|
;;
|
3186 |
|
|
hpux*)
|
3187 |
|
|
if test "$host_cpu" = ia64; then
|
3188 |
|
|
symcode='[[ABCDEGRST]]'
|
3189 |
|
|
fi
|
3190 |
|
|
;;
|
3191 |
|
|
irix* | nonstopux*)
|
3192 |
|
|
symcode='[[BCDEGRST]]'
|
3193 |
|
|
;;
|
3194 |
|
|
osf*)
|
3195 |
|
|
symcode='[[BCDEGQRST]]'
|
3196 |
|
|
;;
|
3197 |
|
|
solaris*)
|
3198 |
|
|
symcode='[[BDRT]]'
|
3199 |
|
|
;;
|
3200 |
|
|
sco3.2v5*)
|
3201 |
|
|
symcode='[[DT]]'
|
3202 |
|
|
;;
|
3203 |
|
|
sysv4.2uw2*)
|
3204 |
|
|
symcode='[[DT]]'
|
3205 |
|
|
;;
|
3206 |
|
|
sysv5* | sco5v6* | unixware* | OpenUNIX*)
|
3207 |
|
|
symcode='[[ABDT]]'
|
3208 |
|
|
;;
|
3209 |
|
|
sysv4)
|
3210 |
|
|
symcode='[[DFNSTU]]'
|
3211 |
|
|
;;
|
3212 |
|
|
esac
|
3213 |
|
|
|
3214 |
|
|
# If we're using GNU nm, then use its standard symbol codes.
|
3215 |
|
|
case `$NM -V 2>&1` in
|
3216 |
|
|
*GNU* | *'with BFD'*)
|
3217 |
|
|
symcode='[[ABCDGIRSTW]]' ;;
|
3218 |
|
|
esac
|
3219 |
|
|
|
3220 |
|
|
# Transform an extracted symbol line into a proper C declaration.
|
3221 |
|
|
# Some systems (esp. on ia64) link data and code symbols differently,
|
3222 |
|
|
# so use this general approach.
|
3223 |
|
|
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
|
3224 |
|
|
|
3225 |
|
|
# Transform an extracted symbol line into symbol name and symbol address
|
3226 |
|
|
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
|
3227 |
|
|
|
3228 |
|
|
# Handle CRLF in mingw tool chain
|
3229 |
|
|
opt_cr=
|
3230 |
|
|
case $build_os in
|
3231 |
|
|
mingw*)
|
3232 |
|
|
opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
|
3233 |
|
|
;;
|
3234 |
|
|
esac
|
3235 |
|
|
|
3236 |
|
|
# Try without a prefix underscore, then with it.
|
3237 |
|
|
for ac_symprfx in "" "_"; do
|
3238 |
|
|
|
3239 |
|
|
# Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
|
3240 |
|
|
symxfrm="\\1 $ac_symprfx\\2 \\2"
|
3241 |
|
|
|
3242 |
|
|
# Write the raw and C identifiers.
|
3243 |
|
|
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
|
3244 |
|
|
# Fake it for dumpbin and say T for any non-static function
|
3245 |
|
|
# and D for any global variable.
|
3246 |
|
|
# Also find C++ and __fastcall symbols from MSVC++,
|
3247 |
|
|
# which start with @ or ?.
|
3248 |
|
|
lt_cv_sys_global_symbol_pipe="$AWK ['"\
|
3249 |
|
|
" {last_section=section; section=\$ 3};"\
|
3250 |
|
|
" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
|
3251 |
|
|
" \$ 0!~/External *\|/{next};"\
|
3252 |
|
|
" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
|
3253 |
|
|
" {if(hide[section]) next};"\
|
3254 |
|
|
" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
|
3255 |
|
|
" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
|
3256 |
|
|
" s[1]~/^[@?]/{print s[1], s[1]; next};"\
|
3257 |
|
|
" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
|
3258 |
|
|
" ' prfx=^$ac_symprfx]"
|
3259 |
|
|
else
|
3260 |
|
|
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
|
3261 |
|
|
fi
|
3262 |
|
|
|
3263 |
|
|
# Check to see that the pipe works correctly.
|
3264 |
|
|
pipe_works=no
|
3265 |
|
|
|
3266 |
|
|
rm -f conftest*
|
3267 |
|
|
cat > conftest.$ac_ext <<_LT_EOF
|
3268 |
|
|
#ifdef __cplusplus
|
3269 |
|
|
extern "C" {
|
3270 |
|
|
#endif
|
3271 |
|
|
char nm_test_var;
|
3272 |
|
|
void nm_test_func(void);
|
3273 |
|
|
void nm_test_func(void){}
|
3274 |
|
|
#ifdef __cplusplus
|
3275 |
|
|
}
|
3276 |
|
|
#endif
|
3277 |
|
|
int main(){nm_test_var='a';nm_test_func();return(0);}
|
3278 |
|
|
_LT_EOF
|
3279 |
|
|
|
3280 |
|
|
if AC_TRY_EVAL(ac_compile); then
|
3281 |
|
|
# Now try to grab the symbols.
|
3282 |
|
|
nlist=conftest.nm
|
3283 |
|
|
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
|
3284 |
|
|
# Try sorting and uniquifying the output.
|
3285 |
|
|
if sort "$nlist" | uniq > "$nlist"T; then
|
3286 |
|
|
mv -f "$nlist"T "$nlist"
|
3287 |
|
|
else
|
3288 |
|
|
rm -f "$nlist"T
|
3289 |
|
|
fi
|
3290 |
|
|
|
3291 |
|
|
# Make sure that we snagged all the symbols we need.
|
3292 |
|
|
if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
|
3293 |
|
|
if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
|
3294 |
|
|
cat <<_LT_EOF > conftest.$ac_ext
|
3295 |
|
|
#ifdef __cplusplus
|
3296 |
|
|
extern "C" {
|
3297 |
|
|
#endif
|
3298 |
|
|
|
3299 |
|
|
_LT_EOF
|
3300 |
|
|
# Now generate the symbol file.
|
3301 |
|
|
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
|
3302 |
|
|
|
3303 |
|
|
cat <<_LT_EOF >> conftest.$ac_ext
|
3304 |
|
|
|
3305 |
|
|
/* The mapping between symbol names and symbols. */
|
3306 |
|
|
const struct {
|
3307 |
|
|
const char *name;
|
3308 |
|
|
void *address;
|
3309 |
|
|
}
|
3310 |
|
|
lt__PROGRAM__LTX_preloaded_symbols[[]] =
|
3311 |
|
|
{
|
3312 |
|
|
{ "@PROGRAM@", (void *) 0 },
|
3313 |
|
|
_LT_EOF
|
3314 |
|
|
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
|
3315 |
|
|
cat <<\_LT_EOF >> conftest.$ac_ext
|
3316 |
|
|
{0, (void *) 0}
|
3317 |
|
|
};
|
3318 |
|
|
|
3319 |
|
|
/* This works around a problem in FreeBSD linker */
|
3320 |
|
|
#ifdef FREEBSD_WORKAROUND
|
3321 |
|
|
static const void *lt_preloaded_setup() {
|
3322 |
|
|
return lt__PROGRAM__LTX_preloaded_symbols;
|
3323 |
|
|
}
|
3324 |
|
|
#endif
|
3325 |
|
|
|
3326 |
|
|
#ifdef __cplusplus
|
3327 |
|
|
}
|
3328 |
|
|
#endif
|
3329 |
|
|
_LT_EOF
|
3330 |
|
|
# Now try linking the two files.
|
3331 |
|
|
mv conftest.$ac_objext conftstm.$ac_objext
|
3332 |
|
|
lt_save_LIBS="$LIBS"
|
3333 |
|
|
lt_save_CFLAGS="$CFLAGS"
|
3334 |
|
|
LIBS="conftstm.$ac_objext"
|
3335 |
|
|
CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
|
3336 |
|
|
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
|
3337 |
|
|
pipe_works=yes
|
3338 |
|
|
fi
|
3339 |
|
|
LIBS="$lt_save_LIBS"
|
3340 |
|
|
CFLAGS="$lt_save_CFLAGS"
|
3341 |
|
|
else
|
3342 |
|
|
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
|
3343 |
|
|
fi
|
3344 |
|
|
else
|
3345 |
|
|
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
|
3346 |
|
|
fi
|
3347 |
|
|
else
|
3348 |
|
|
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
|
3349 |
|
|
fi
|
3350 |
|
|
else
|
3351 |
|
|
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
|
3352 |
|
|
cat conftest.$ac_ext >&5
|
3353 |
|
|
fi
|
3354 |
|
|
rm -f conftest* conftst*
|
3355 |
|
|
|
3356 |
|
|
# Do not use the global_symbol_pipe unless it works.
|
3357 |
|
|
if test "$pipe_works" = yes; then
|
3358 |
|
|
break
|
3359 |
|
|
else
|
3360 |
|
|
lt_cv_sys_global_symbol_pipe=
|
3361 |
|
|
fi
|
3362 |
|
|
done
|
3363 |
|
|
])
|
3364 |
|
|
if test -z "$lt_cv_sys_global_symbol_pipe"; then
|
3365 |
|
|
lt_cv_sys_global_symbol_to_cdecl=
|
3366 |
|
|
fi
|
3367 |
|
|
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
|
3368 |
|
|
AC_MSG_RESULT(failed)
|
3369 |
|
|
else
|
3370 |
|
|
AC_MSG_RESULT(ok)
|
3371 |
|
|
fi
|
3372 |
|
|
|
3373 |
|
|
_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
|
3374 |
|
|
[Take the output of nm and produce a listing of raw symbols and C names])
|
3375 |
|
|
_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
|
3376 |
|
|
[Transform the output of nm in a proper C declaration])
|
3377 |
|
|
_LT_DECL([global_symbol_to_c_name_address],
|
3378 |
|
|
[lt_cv_sys_global_symbol_to_c_name_address], [1],
|
3379 |
|
|
[Transform the output of nm in a C name address pair])
|
3380 |
|
|
]) # _LT_CMD_GLOBAL_SYMBOLS
|
3381 |
|
|
|
3382 |
|
|
|
3383 |
|
|
# _LT_COMPILER_PIC([TAGNAME])
|
3384 |
|
|
# ---------------------------
|
3385 |
|
|
m4_defun([_LT_COMPILER_PIC],
|
3386 |
|
|
[m4_require([_LT_TAG_COMPILER])dnl
|
3387 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)=
|
3388 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
|
3389 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)=
|
3390 |
|
|
|
3391 |
|
|
AC_MSG_CHECKING([for $compiler option to produce PIC])
|
3392 |
|
|
m4_if([$1], [CXX], [
|
3393 |
|
|
# C++ specific cases for pic, static, wl, etc.
|
3394 |
|
|
if test "$GXX" = yes; then
|
3395 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3396 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
|
3397 |
|
|
|
3398 |
|
|
case $host_os in
|
3399 |
|
|
aix*)
|
3400 |
|
|
# All AIX code is PIC.
|
3401 |
|
|
if test "$host_cpu" = ia64; then
|
3402 |
|
|
# AIX 5 now supports IA64 processor
|
3403 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3404 |
|
|
fi
|
3405 |
|
|
;;
|
3406 |
|
|
amigaos*)
|
3407 |
|
|
if test "$host_cpu" = m68k; then
|
3408 |
|
|
# FIXME: we need at least 68020 code to build shared libraries, but
|
3409 |
|
|
# adding the `-m68020' flag to GCC prevents building anything better,
|
3410 |
|
|
# like `-m68040'.
|
3411 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
|
3412 |
|
|
fi
|
3413 |
|
|
;;
|
3414 |
|
|
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
|
3415 |
|
|
# PIC is the default for these OSes.
|
3416 |
|
|
;;
|
3417 |
|
|
mingw* | cygwin* | os2* | pw32*)
|
3418 |
|
|
# This hack is so that the source file can tell whether it is being
|
3419 |
|
|
# built for inclusion in a dll (and should export symbols for example).
|
3420 |
|
|
# Although the cygwin gcc ignores -fPIC, still need this for old-style
|
3421 |
|
|
# (--disable-auto-import) libraries
|
3422 |
|
|
m4_if([$1], [GCJ], [],
|
3423 |
|
|
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
|
3424 |
|
|
;;
|
3425 |
|
|
darwin* | rhapsody*)
|
3426 |
|
|
# PIC is the default on this platform
|
3427 |
|
|
# Common symbols not allowed in MH_DYLIB files
|
3428 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
|
3429 |
|
|
;;
|
3430 |
|
|
*djgpp*)
|
3431 |
|
|
# DJGPP does not support shared libraries at all
|
3432 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
|
3433 |
|
|
;;
|
3434 |
|
|
interix[[3-9]]*)
|
3435 |
|
|
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
|
3436 |
|
|
# Instead, we relocate shared libraries at runtime.
|
3437 |
|
|
;;
|
3438 |
|
|
sysv4*MP*)
|
3439 |
|
|
if test -d /usr/nec; then
|
3440 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
|
3441 |
|
|
fi
|
3442 |
|
|
;;
|
3443 |
|
|
hpux*)
|
3444 |
|
|
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
|
3445 |
|
|
# not for PA HP-UX.
|
3446 |
|
|
case $host_cpu in
|
3447 |
|
|
hppa*64*|ia64*)
|
3448 |
|
|
;;
|
3449 |
|
|
*)
|
3450 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
|
3451 |
|
|
;;
|
3452 |
|
|
esac
|
3453 |
|
|
;;
|
3454 |
|
|
*qnx* | *nto*)
|
3455 |
|
|
# QNX uses GNU C++, but need to define -shared option too, otherwise
|
3456 |
|
|
# it will coredump.
|
3457 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
|
3458 |
|
|
;;
|
3459 |
|
|
*)
|
3460 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
|
3461 |
|
|
;;
|
3462 |
|
|
esac
|
3463 |
|
|
else
|
3464 |
|
|
case $host_os in
|
3465 |
|
|
aix[[4-9]]*)
|
3466 |
|
|
# All AIX code is PIC.
|
3467 |
|
|
if test "$host_cpu" = ia64; then
|
3468 |
|
|
# AIX 5 now supports IA64 processor
|
3469 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3470 |
|
|
else
|
3471 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
|
3472 |
|
|
fi
|
3473 |
|
|
;;
|
3474 |
|
|
chorus*)
|
3475 |
|
|
case $cc_basename in
|
3476 |
|
|
cxch68*)
|
3477 |
|
|
# Green Hills C++ Compiler
|
3478 |
|
|
# _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"
|
3479 |
|
|
;;
|
3480 |
|
|
esac
|
3481 |
|
|
;;
|
3482 |
|
|
darwin*)
|
3483 |
|
|
# PIC is the default on this platform
|
3484 |
|
|
# Common symbols not allowed in MH_DYLIB files
|
3485 |
|
|
case $cc_basename in
|
3486 |
|
|
xlc*)
|
3487 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
|
3488 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3489 |
|
|
;;
|
3490 |
|
|
esac
|
3491 |
|
|
;;
|
3492 |
|
|
dgux*)
|
3493 |
|
|
case $cc_basename in
|
3494 |
|
|
ec++*)
|
3495 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3496 |
|
|
;;
|
3497 |
|
|
ghcx*)
|
3498 |
|
|
# Green Hills C++ Compiler
|
3499 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
|
3500 |
|
|
;;
|
3501 |
|
|
*)
|
3502 |
|
|
;;
|
3503 |
|
|
esac
|
3504 |
|
|
;;
|
3505 |
|
|
freebsd* | dragonfly*)
|
3506 |
|
|
# FreeBSD uses GNU C++
|
3507 |
|
|
;;
|
3508 |
|
|
hpux9* | hpux10* | hpux11*)
|
3509 |
|
|
case $cc_basename in
|
3510 |
|
|
CC*)
|
3511 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3512 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
|
3513 |
|
|
if test "$host_cpu" != ia64; then
|
3514 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
|
3515 |
|
|
fi
|
3516 |
|
|
;;
|
3517 |
|
|
aCC*)
|
3518 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3519 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
|
3520 |
|
|
case $host_cpu in
|
3521 |
|
|
hppa*64*|ia64*)
|
3522 |
|
|
# +Z the default
|
3523 |
|
|
;;
|
3524 |
|
|
*)
|
3525 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
|
3526 |
|
|
;;
|
3527 |
|
|
esac
|
3528 |
|
|
;;
|
3529 |
|
|
*)
|
3530 |
|
|
;;
|
3531 |
|
|
esac
|
3532 |
|
|
;;
|
3533 |
|
|
interix*)
|
3534 |
|
|
# This is c89, which is MS Visual C++ (no shared libs)
|
3535 |
|
|
# Anyone wants to do a port?
|
3536 |
|
|
;;
|
3537 |
|
|
irix5* | irix6* | nonstopux*)
|
3538 |
|
|
case $cc_basename in
|
3539 |
|
|
CC*)
|
3540 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3541 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3542 |
|
|
# CC pic flag -KPIC is the default.
|
3543 |
|
|
;;
|
3544 |
|
|
*)
|
3545 |
|
|
;;
|
3546 |
|
|
esac
|
3547 |
|
|
;;
|
3548 |
|
|
linux* | k*bsd*-gnu)
|
3549 |
|
|
case $cc_basename in
|
3550 |
|
|
KCC*)
|
3551 |
|
|
# KAI C++ Compiler
|
3552 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
|
3553 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
|
3554 |
|
|
;;
|
3555 |
|
|
icpc* | ecpc* )
|
3556 |
|
|
# Intel C++
|
3557 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3558 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3559 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
|
3560 |
|
|
;;
|
3561 |
|
|
pgCC*)
|
3562 |
|
|
# Portland Group C++ compiler
|
3563 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3564 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
|
3565 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3566 |
|
|
;;
|
3567 |
|
|
cxx*)
|
3568 |
|
|
# Compaq C++
|
3569 |
|
|
# Make sure the PIC flag is empty. It appears that all Alpha
|
3570 |
|
|
# Linux and Compaq Tru64 Unix objects are PIC.
|
3571 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
|
3572 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3573 |
|
|
;;
|
3574 |
|
|
*)
|
3575 |
|
|
case `$CC -V 2>&1 | sed 5q` in
|
3576 |
|
|
*Sun\ C*)
|
3577 |
|
|
# Sun C++ 5.9
|
3578 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3579 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3580 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
|
3581 |
|
|
;;
|
3582 |
|
|
esac
|
3583 |
|
|
;;
|
3584 |
|
|
esac
|
3585 |
|
|
;;
|
3586 |
|
|
lynxos*)
|
3587 |
|
|
;;
|
3588 |
|
|
m88k*)
|
3589 |
|
|
;;
|
3590 |
|
|
mvs*)
|
3591 |
|
|
case $cc_basename in
|
3592 |
|
|
cxx*)
|
3593 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
|
3594 |
|
|
;;
|
3595 |
|
|
*)
|
3596 |
|
|
;;
|
3597 |
|
|
esac
|
3598 |
|
|
;;
|
3599 |
|
|
netbsd*)
|
3600 |
|
|
;;
|
3601 |
|
|
*qnx* | *nto*)
|
3602 |
|
|
# QNX uses GNU C++, but need to define -shared option too, otherwise
|
3603 |
|
|
# it will coredump.
|
3604 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
|
3605 |
|
|
;;
|
3606 |
|
|
osf3* | osf4* | osf5*)
|
3607 |
|
|
case $cc_basename in
|
3608 |
|
|
KCC*)
|
3609 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
|
3610 |
|
|
;;
|
3611 |
|
|
RCC*)
|
3612 |
|
|
# Rational C++ 2.4.1
|
3613 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
|
3614 |
|
|
;;
|
3615 |
|
|
cxx*)
|
3616 |
|
|
# Digital/Compaq C++
|
3617 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3618 |
|
|
# Make sure the PIC flag is empty. It appears that all Alpha
|
3619 |
|
|
# Linux and Compaq Tru64 Unix objects are PIC.
|
3620 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
|
3621 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3622 |
|
|
;;
|
3623 |
|
|
*)
|
3624 |
|
|
;;
|
3625 |
|
|
esac
|
3626 |
|
|
;;
|
3627 |
|
|
psos*)
|
3628 |
|
|
;;
|
3629 |
|
|
solaris*)
|
3630 |
|
|
case $cc_basename in
|
3631 |
|
|
CC*)
|
3632 |
|
|
# Sun C++ 4.2, 5.x and Centerline C++
|
3633 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3634 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3635 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
|
3636 |
|
|
;;
|
3637 |
|
|
gcx*)
|
3638 |
|
|
# Green Hills C++ Compiler
|
3639 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
|
3640 |
|
|
;;
|
3641 |
|
|
*)
|
3642 |
|
|
;;
|
3643 |
|
|
esac
|
3644 |
|
|
;;
|
3645 |
|
|
sunos4*)
|
3646 |
|
|
case $cc_basename in
|
3647 |
|
|
CC*)
|
3648 |
|
|
# Sun C++ 4.x
|
3649 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
|
3650 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3651 |
|
|
;;
|
3652 |
|
|
lcc*)
|
3653 |
|
|
# Lucid
|
3654 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
|
3655 |
|
|
;;
|
3656 |
|
|
*)
|
3657 |
|
|
;;
|
3658 |
|
|
esac
|
3659 |
|
|
;;
|
3660 |
|
|
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
|
3661 |
|
|
case $cc_basename in
|
3662 |
|
|
CC*)
|
3663 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3664 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3665 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3666 |
|
|
;;
|
3667 |
|
|
esac
|
3668 |
|
|
;;
|
3669 |
|
|
tandem*)
|
3670 |
|
|
case $cc_basename in
|
3671 |
|
|
NCC*)
|
3672 |
|
|
# NonStop-UX NCC 3.20
|
3673 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3674 |
|
|
;;
|
3675 |
|
|
*)
|
3676 |
|
|
;;
|
3677 |
|
|
esac
|
3678 |
|
|
;;
|
3679 |
|
|
vxworks*)
|
3680 |
|
|
;;
|
3681 |
|
|
*)
|
3682 |
|
|
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
|
3683 |
|
|
;;
|
3684 |
|
|
esac
|
3685 |
|
|
fi
|
3686 |
|
|
],
|
3687 |
|
|
[
|
3688 |
|
|
if test "$GCC" = yes; then
|
3689 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3690 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
|
3691 |
|
|
|
3692 |
|
|
case $host_os in
|
3693 |
|
|
aix*)
|
3694 |
|
|
# All AIX code is PIC.
|
3695 |
|
|
if test "$host_cpu" = ia64; then
|
3696 |
|
|
# AIX 5 now supports IA64 processor
|
3697 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3698 |
|
|
fi
|
3699 |
|
|
;;
|
3700 |
|
|
|
3701 |
|
|
amigaos*)
|
3702 |
|
|
if test "$host_cpu" = m68k; then
|
3703 |
|
|
# FIXME: we need at least 68020 code to build shared libraries, but
|
3704 |
|
|
# adding the `-m68020' flag to GCC prevents building anything better,
|
3705 |
|
|
# like `-m68040'.
|
3706 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
|
3707 |
|
|
fi
|
3708 |
|
|
;;
|
3709 |
|
|
|
3710 |
|
|
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
|
3711 |
|
|
# PIC is the default for these OSes.
|
3712 |
|
|
;;
|
3713 |
|
|
|
3714 |
|
|
mingw* | cygwin* | pw32* | os2*)
|
3715 |
|
|
# This hack is so that the source file can tell whether it is being
|
3716 |
|
|
# built for inclusion in a dll (and should export symbols for example).
|
3717 |
|
|
# Although the cygwin gcc ignores -fPIC, still need this for old-style
|
3718 |
|
|
# (--disable-auto-import) libraries
|
3719 |
|
|
m4_if([$1], [GCJ], [],
|
3720 |
|
|
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
|
3721 |
|
|
;;
|
3722 |
|
|
|
3723 |
|
|
darwin* | rhapsody*)
|
3724 |
|
|
# PIC is the default on this platform
|
3725 |
|
|
# Common symbols not allowed in MH_DYLIB files
|
3726 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
|
3727 |
|
|
;;
|
3728 |
|
|
|
3729 |
|
|
hpux*)
|
3730 |
|
|
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
|
3731 |
|
|
# not for PA HP-UX.
|
3732 |
|
|
case $host_cpu in
|
3733 |
|
|
hppa*64*|ia64*)
|
3734 |
|
|
# +Z the default
|
3735 |
|
|
;;
|
3736 |
|
|
*)
|
3737 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
|
3738 |
|
|
;;
|
3739 |
|
|
esac
|
3740 |
|
|
;;
|
3741 |
|
|
|
3742 |
|
|
interix[[3-9]]*)
|
3743 |
|
|
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
|
3744 |
|
|
# Instead, we relocate shared libraries at runtime.
|
3745 |
|
|
;;
|
3746 |
|
|
|
3747 |
|
|
msdosdjgpp*)
|
3748 |
|
|
# Just because we use GCC doesn't mean we suddenly get shared libraries
|
3749 |
|
|
# on systems that don't support them.
|
3750 |
|
|
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
|
3751 |
|
|
enable_shared=no
|
3752 |
|
|
;;
|
3753 |
|
|
|
3754 |
|
|
*nto* | *qnx*)
|
3755 |
|
|
# QNX uses GNU C++, but need to define -shared option too, otherwise
|
3756 |
|
|
# it will coredump.
|
3757 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
|
3758 |
|
|
;;
|
3759 |
|
|
|
3760 |
|
|
sysv4*MP*)
|
3761 |
|
|
if test -d /usr/nec; then
|
3762 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
|
3763 |
|
|
fi
|
3764 |
|
|
;;
|
3765 |
|
|
|
3766 |
|
|
*)
|
3767 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
|
3768 |
|
|
;;
|
3769 |
|
|
esac
|
3770 |
|
|
else
|
3771 |
|
|
# PORTME Check for flag to pass linker flags through the system compiler.
|
3772 |
|
|
case $host_os in
|
3773 |
|
|
aix*)
|
3774 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3775 |
|
|
if test "$host_cpu" = ia64; then
|
3776 |
|
|
# AIX 5 now supports IA64 processor
|
3777 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3778 |
|
|
else
|
3779 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
|
3780 |
|
|
fi
|
3781 |
|
|
;;
|
3782 |
|
|
darwin*)
|
3783 |
|
|
# PIC is the default on this platform
|
3784 |
|
|
# Common symbols not allowed in MH_DYLIB files
|
3785 |
|
|
case $cc_basename in
|
3786 |
|
|
xlc*)
|
3787 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
|
3788 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3789 |
|
|
;;
|
3790 |
|
|
esac
|
3791 |
|
|
;;
|
3792 |
|
|
|
3793 |
|
|
mingw* | cygwin* | pw32* | os2*)
|
3794 |
|
|
# This hack is so that the source file can tell whether it is being
|
3795 |
|
|
# built for inclusion in a dll (and should export symbols for example).
|
3796 |
|
|
m4_if([$1], [GCJ], [],
|
3797 |
|
|
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
|
3798 |
|
|
;;
|
3799 |
|
|
|
3800 |
|
|
hpux9* | hpux10* | hpux11*)
|
3801 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3802 |
|
|
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
|
3803 |
|
|
# not for PA HP-UX.
|
3804 |
|
|
case $host_cpu in
|
3805 |
|
|
hppa*64*|ia64*)
|
3806 |
|
|
# +Z the default
|
3807 |
|
|
;;
|
3808 |
|
|
*)
|
3809 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
|
3810 |
|
|
;;
|
3811 |
|
|
esac
|
3812 |
|
|
# Is there a better lt_prog_compiler_static that works with the bundled CC?
|
3813 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
|
3814 |
|
|
;;
|
3815 |
|
|
|
3816 |
|
|
irix5* | irix6* | nonstopux*)
|
3817 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3818 |
|
|
# PIC (with -KPIC) is the default.
|
3819 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3820 |
|
|
;;
|
3821 |
|
|
|
3822 |
|
|
linux* | k*bsd*-gnu)
|
3823 |
|
|
case $cc_basename in
|
3824 |
|
|
icc* | ecc*)
|
3825 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3826 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3827 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
|
3828 |
|
|
;;
|
3829 |
|
|
pgcc* | pgf77* | pgf90* | pgf95*)
|
3830 |
|
|
# Portland Group compilers (*not* the Pentium gcc compiler,
|
3831 |
|
|
# which looks to be a dead project)
|
3832 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3833 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
|
3834 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3835 |
|
|
;;
|
3836 |
|
|
ccc*)
|
3837 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3838 |
|
|
# All Alpha code is PIC.
|
3839 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3840 |
|
|
;;
|
3841 |
|
|
*)
|
3842 |
|
|
case `$CC -V 2>&1 | sed 5q` in
|
3843 |
|
|
*Sun\ C*)
|
3844 |
|
|
# Sun C 5.9
|
3845 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3846 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3847 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3848 |
|
|
;;
|
3849 |
|
|
*Sun\ F*)
|
3850 |
|
|
# Sun Fortran 8.3 passes all unrecognized flags to the linker
|
3851 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3852 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3853 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)=''
|
3854 |
|
|
;;
|
3855 |
|
|
esac
|
3856 |
|
|
;;
|
3857 |
|
|
esac
|
3858 |
|
|
;;
|
3859 |
|
|
|
3860 |
|
|
newsos6)
|
3861 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3862 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3863 |
|
|
;;
|
3864 |
|
|
|
3865 |
|
|
*nto* | *qnx*)
|
3866 |
|
|
# QNX uses GNU C++, but need to define -shared option too, otherwise
|
3867 |
|
|
# it will coredump.
|
3868 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
|
3869 |
|
|
;;
|
3870 |
|
|
|
3871 |
|
|
osf3* | osf4* | osf5*)
|
3872 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3873 |
|
|
# All OSF/1 code is PIC.
|
3874 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3875 |
|
|
;;
|
3876 |
|
|
|
3877 |
|
|
rdos*)
|
3878 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
|
3879 |
|
|
;;
|
3880 |
|
|
|
3881 |
|
|
solaris*)
|
3882 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3883 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3884 |
|
|
case $cc_basename in
|
3885 |
|
|
f77* | f90* | f95*)
|
3886 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
|
3887 |
|
|
*)
|
3888 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
|
3889 |
|
|
esac
|
3890 |
|
|
;;
|
3891 |
|
|
|
3892 |
|
|
sunos4*)
|
3893 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
|
3894 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
|
3895 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3896 |
|
|
;;
|
3897 |
|
|
|
3898 |
|
|
sysv4 | sysv4.2uw2* | sysv4.3*)
|
3899 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3900 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3901 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3902 |
|
|
;;
|
3903 |
|
|
|
3904 |
|
|
sysv4*MP*)
|
3905 |
|
|
if test -d /usr/nec ;then
|
3906 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
|
3907 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3908 |
|
|
fi
|
3909 |
|
|
;;
|
3910 |
|
|
|
3911 |
|
|
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
|
3912 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3913 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
|
3914 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3915 |
|
|
;;
|
3916 |
|
|
|
3917 |
|
|
unicos*)
|
3918 |
|
|
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
|
3919 |
|
|
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
|
3920 |
|
|
;;
|
3921 |
|
|
|
3922 |
|
|
uts4*)
|
3923 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
|
3924 |
|
|
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
|
3925 |
|
|
;;
|
3926 |
|
|
|
3927 |
|
|
*)
|
3928 |
|
|
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
|
3929 |
|
|
;;
|
3930 |
|
|
esac
|
3931 |
|
|
fi
|
3932 |
|
|
])
|
3933 |
|
|
case $host_os in
|
3934 |
|
|
# For platforms which do not support PIC, -DPIC is meaningless:
|
3935 |
|
|
*djgpp*)
|
3936 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
|
3937 |
|
|
;;
|
3938 |
|
|
*)
|
3939 |
|
|
_LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
|
3940 |
|
|
;;
|
3941 |
|
|
esac
|
3942 |
|
|
AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
|
3943 |
|
|
_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
|
3944 |
|
|
[How to pass a linker flag through the compiler])
|
3945 |
|
|
|
3946 |
|
|
#
|
3947 |
|
|
# Check to make sure the PIC flag actually works.
|
3948 |
|
|
#
|
3949 |
|
|
if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
|
3950 |
|
|
_LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
|
3951 |
|
|
[_LT_TAGVAR(lt_prog_compiler_pic_works, $1)],
|
3952 |
|
|
[$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
|
3953 |
|
|
[case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
|
3954 |
|
|
"" | " "*) ;;
|
3955 |
|
|
*) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
|
3956 |
|
|
esac],
|
3957 |
|
|
[_LT_TAGVAR(lt_prog_compiler_pic, $1)=
|
3958 |
|
|
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
|
3959 |
|
|
fi
|
3960 |
|
|
_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
|
3961 |
|
|
[Additional compiler flags for building library objects])
|
3962 |
|
|
|
3963 |
|
|
#
|
3964 |
|
|
# Check to make sure the static flag actually works.
|
3965 |
|
|
#
|
3966 |
|
|
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
|
3967 |
|
|
_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
|
3968 |
|
|
_LT_TAGVAR(lt_prog_compiler_static_works, $1),
|
3969 |
|
|
$lt_tmp_static_flag,
|
3970 |
|
|
[],
|
3971 |
|
|
[_LT_TAGVAR(lt_prog_compiler_static, $1)=])
|
3972 |
|
|
_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
|
3973 |
|
|
[Compiler flag to prevent dynamic linking])
|
3974 |
|
|
])# _LT_COMPILER_PIC
|
3975 |
|
|
|
3976 |
|
|
|
3977 |
|
|
# _LT_LINKER_SHLIBS([TAGNAME])
|
3978 |
|
|
# ----------------------------
|
3979 |
|
|
# See if the linker supports building shared libraries.
|
3980 |
|
|
m4_defun([_LT_LINKER_SHLIBS],
|
3981 |
|
|
[AC_REQUIRE([LT_PATH_LD])dnl
|
3982 |
|
|
AC_REQUIRE([LT_PATH_NM])dnl
|
3983 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
3984 |
|
|
m4_require([_LT_DECL_EGREP])dnl
|
3985 |
|
|
m4_require([_LT_DECL_SED])dnl
|
3986 |
|
|
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
|
3987 |
|
|
m4_require([_LT_TAG_COMPILER])dnl
|
3988 |
|
|
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
|
3989 |
|
|
m4_if([$1], [CXX], [
|
3990 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
|
3991 |
|
|
case $host_os in
|
3992 |
|
|
aix[[4-9]]*)
|
3993 |
|
|
# If we're using GNU nm, then we don't want the "-C" option.
|
3994 |
|
|
# -C means demangle to AIX nm, but means don't demangle with GNU nm
|
3995 |
|
|
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
|
3996 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
|
3997 |
|
|
else
|
3998 |
|
|
_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'
|
3999 |
|
|
fi
|
4000 |
|
|
;;
|
4001 |
|
|
pw32*)
|
4002 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
|
4003 |
|
|
;;
|
4004 |
|
|
cygwin* | mingw*)
|
4005 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
|
4006 |
|
|
;;
|
4007 |
|
|
*)
|
4008 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
|
4009 |
|
|
;;
|
4010 |
|
|
esac
|
4011 |
|
|
], [
|
4012 |
|
|
runpath_var=
|
4013 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=
|
4014 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=no
|
4015 |
|
|
_LT_TAGVAR(archive_cmds, $1)=
|
4016 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)=
|
4017 |
|
|
_LT_TAGVAR(compiler_needs_object, $1)=no
|
4018 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
|
4019 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
|
4020 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
|
4021 |
|
|
_LT_TAGVAR(hardcode_automatic, $1)=no
|
4022 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
4023 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
|
4024 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
|
4025 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
|
4026 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=
|
4027 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=no
|
4028 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
4029 |
|
|
_LT_TAGVAR(inherit_rpath, $1)=no
|
4030 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=unknown
|
4031 |
|
|
_LT_TAGVAR(module_cmds, $1)=
|
4032 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)=
|
4033 |
|
|
_LT_TAGVAR(old_archive_from_new_cmds, $1)=
|
4034 |
|
|
_LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
|
4035 |
|
|
_LT_TAGVAR(thread_safe_flag_spec, $1)=
|
4036 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
4037 |
|
|
# include_expsyms should be a list of space-separated symbols to be *always*
|
4038 |
|
|
# included in the symbol list
|
4039 |
|
|
_LT_TAGVAR(include_expsyms, $1)=
|
4040 |
|
|
# exclude_expsyms can be an extended regexp of symbols to exclude
|
4041 |
|
|
# it will be wrapped by ` (' and `)$', so one must not match beginning or
|
4042 |
|
|
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
|
4043 |
|
|
# as well as any symbol that contains `d'.
|
4044 |
|
|
_LT_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
|
4045 |
|
|
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
|
4046 |
|
|
# platforms (ab)use it in PIC code, but their linkers get confused if
|
4047 |
|
|
# the symbol is explicitly referenced. Since portable code cannot
|
4048 |
|
|
# rely on this symbol name, it's probably fine to never include it in
|
4049 |
|
|
# preloaded symbol tables.
|
4050 |
|
|
extract_expsyms_cmds=
|
4051 |
|
|
|
4052 |
|
|
case $host_os in
|
4053 |
|
|
cygwin* | mingw* | pw32*)
|
4054 |
|
|
# FIXME: the MSVC++ port hasn't been tested in a loooong time
|
4055 |
|
|
# When not using gcc, we currently assume that we are using
|
4056 |
|
|
# Microsoft Visual C++.
|
4057 |
|
|
if test "$GCC" != yes; then
|
4058 |
|
|
with_gnu_ld=no
|
4059 |
|
|
fi
|
4060 |
|
|
;;
|
4061 |
|
|
interix*)
|
4062 |
|
|
# we just hope/assume this is gcc and not c89 (= MSVC++)
|
4063 |
|
|
with_gnu_ld=yes
|
4064 |
|
|
;;
|
4065 |
|
|
openbsd*)
|
4066 |
|
|
with_gnu_ld=no
|
4067 |
|
|
;;
|
4068 |
|
|
esac
|
4069 |
|
|
|
4070 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=yes
|
4071 |
|
|
if test "$with_gnu_ld" = yes; then
|
4072 |
|
|
# If archive_cmds runs LD, not CC, wlarc should be empty
|
4073 |
|
|
wlarc='${wl}'
|
4074 |
|
|
|
4075 |
|
|
# Set some defaults for GNU ld with shared library support. These
|
4076 |
|
|
# are reset later if shared libraries are not supported. Putting them
|
4077 |
|
|
# here allows them to be overridden if necessary.
|
4078 |
|
|
runpath_var=LD_RUN_PATH
|
4079 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
4080 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
|
4081 |
|
|
# ancient GNU ld didn't support --whole-archive et. al.
|
4082 |
|
|
if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
|
4083 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
|
4084 |
|
|
else
|
4085 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
4086 |
|
|
fi
|
4087 |
|
|
supports_anon_versioning=no
|
4088 |
|
|
case `$LD -v 2>&1` in
|
4089 |
|
|
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
|
4090 |
|
|
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
|
4091 |
|
|
*\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
|
4092 |
|
|
*\ 2.11.*) ;; # other 2.11 versions
|
4093 |
|
|
*) supports_anon_versioning=yes ;;
|
4094 |
|
|
esac
|
4095 |
|
|
|
4096 |
|
|
# See if GNU ld supports shared libraries.
|
4097 |
|
|
case $host_os in
|
4098 |
|
|
aix[[3-9]]*)
|
4099 |
|
|
# On AIX/PPC, the GNU linker is very broken
|
4100 |
|
|
if test "$host_cpu" != ia64; then
|
4101 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4102 |
|
|
cat <<_LT_EOF 1>&2
|
4103 |
|
|
|
4104 |
|
|
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
|
4105 |
|
|
*** to be unable to reliably create shared libraries on AIX.
|
4106 |
|
|
*** Therefore, libtool is disabling shared libraries support. If you
|
4107 |
|
|
*** really care for shared libraries, you may want to modify your PATH
|
4108 |
|
|
*** so that a non-GNU linker is found, and then restart.
|
4109 |
|
|
|
4110 |
|
|
_LT_EOF
|
4111 |
|
|
fi
|
4112 |
|
|
;;
|
4113 |
|
|
|
4114 |
|
|
amigaos*)
|
4115 |
|
|
if test "$host_cpu" = m68k; then
|
4116 |
|
|
_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)'
|
4117 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4118 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4119 |
|
|
fi
|
4120 |
|
|
|
4121 |
|
|
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
|
4122 |
|
|
# that the semantics of dynamic libraries on AmigaOS, at least up
|
4123 |
|
|
# to version 4, is to share data among multiple programs linked
|
4124 |
|
|
# with the same dynamic library. Since this doesn't match the
|
4125 |
|
|
# behavior of shared libraries on other platforms, we can't use
|
4126 |
|
|
# them.
|
4127 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4128 |
|
|
;;
|
4129 |
|
|
|
4130 |
|
|
beos*)
|
4131 |
|
|
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
|
4132 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
4133 |
|
|
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
|
4134 |
|
|
# support --undefined. This deserves some investigation. FIXME
|
4135 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
4136 |
|
|
else
|
4137 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4138 |
|
|
fi
|
4139 |
|
|
;;
|
4140 |
|
|
|
4141 |
|
|
cygwin* | mingw* | pw32*)
|
4142 |
|
|
# _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
|
4143 |
|
|
# as there is no search path for DLLs.
|
4144 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4145 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
4146 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=no
|
4147 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
|
4148 |
|
|
_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'
|
4149 |
|
|
|
4150 |
|
|
if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
|
4151 |
|
|
_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'
|
4152 |
|
|
# If the export-symbols file already is a .def file (1st line
|
4153 |
|
|
# is EXPORTS), use it as is; otherwise, prepend...
|
4154 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
|
4155 |
|
|
cp $export_symbols $output_objdir/$soname.def;
|
4156 |
|
|
else
|
4157 |
|
|
echo EXPORTS > $output_objdir/$soname.def;
|
4158 |
|
|
cat $export_symbols >> $output_objdir/$soname.def;
|
4159 |
|
|
fi~
|
4160 |
|
|
$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
|
4161 |
|
|
else
|
4162 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4163 |
|
|
fi
|
4164 |
|
|
;;
|
4165 |
|
|
|
4166 |
|
|
interix[[3-9]]*)
|
4167 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
4168 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4169 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
4170 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
4171 |
|
|
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
|
4172 |
|
|
# Instead, shared libraries are loaded at an image base (0x10000000 by
|
4173 |
|
|
# default) and relocated if they conflict, which is a slow very memory
|
4174 |
|
|
# consuming and fragmenting process. To avoid this, we pick a random,
|
4175 |
|
|
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
|
4176 |
|
|
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
|
4177 |
|
|
_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'
|
4178 |
|
|
_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'
|
4179 |
|
|
;;
|
4180 |
|
|
|
4181 |
|
|
gnu* | linux* | tpf* | k*bsd*-gnu)
|
4182 |
|
|
tmp_diet=no
|
4183 |
|
|
if test "$host_os" = linux-dietlibc; then
|
4184 |
|
|
case $cc_basename in
|
4185 |
|
|
diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
|
4186 |
|
|
esac
|
4187 |
|
|
fi
|
4188 |
|
|
if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
|
4189 |
|
|
&& test "$tmp_diet" = no
|
4190 |
|
|
then
|
4191 |
|
|
tmp_addflag=
|
4192 |
|
|
case $cc_basename,$host_cpu in
|
4193 |
|
|
pgcc*) # Portland Group C compiler
|
4194 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
|
4195 |
|
|
tmp_addflag=' $pic_flag'
|
4196 |
|
|
;;
|
4197 |
|
|
pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
|
4198 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
|
4199 |
|
|
tmp_addflag=' $pic_flag -Mnomain' ;;
|
4200 |
|
|
ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
|
4201 |
|
|
tmp_addflag=' -i_dynamic' ;;
|
4202 |
|
|
efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
|
4203 |
|
|
tmp_addflag=' -i_dynamic -nofor_main' ;;
|
4204 |
|
|
ifc* | ifort*) # Intel Fortran compiler
|
4205 |
|
|
tmp_addflag=' -nofor_main' ;;
|
4206 |
|
|
esac
|
4207 |
|
|
case `$CC -V 2>&1 | sed 5q` in
|
4208 |
|
|
*Sun\ C*) # Sun C 5.9
|
4209 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
|
4210 |
|
|
_LT_TAGVAR(compiler_needs_object, $1)=yes
|
4211 |
|
|
tmp_sharedflag='-G' ;;
|
4212 |
|
|
*Sun\ F*) # Sun Fortran 8.3
|
4213 |
|
|
tmp_sharedflag='-G' ;;
|
4214 |
|
|
*)
|
4215 |
|
|
tmp_sharedflag='-shared' ;;
|
4216 |
|
|
esac
|
4217 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
4218 |
|
|
|
4219 |
|
|
if test "x$supports_anon_versioning" = xyes; then
|
4220 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
|
4221 |
|
|
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
|
4222 |
|
|
echo "local: *; };" >> $output_objdir/$libname.ver~
|
4223 |
|
|
$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
|
4224 |
|
|
fi
|
4225 |
|
|
else
|
4226 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4227 |
|
|
fi
|
4228 |
|
|
;;
|
4229 |
|
|
|
4230 |
|
|
netbsd*)
|
4231 |
|
|
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
|
4232 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
|
4233 |
|
|
wlarc=
|
4234 |
|
|
else
|
4235 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
4236 |
|
|
_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'
|
4237 |
|
|
fi
|
4238 |
|
|
;;
|
4239 |
|
|
|
4240 |
|
|
solaris*)
|
4241 |
|
|
if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
|
4242 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4243 |
|
|
cat <<_LT_EOF 1>&2
|
4244 |
|
|
|
4245 |
|
|
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
|
4246 |
|
|
*** create shared libraries on Solaris systems. Therefore, libtool
|
4247 |
|
|
*** is disabling shared libraries support. We urge you to upgrade GNU
|
4248 |
|
|
*** binutils to release 2.9.1 or newer. Another option is to modify
|
4249 |
|
|
*** your PATH or compiler configuration so that the native linker is
|
4250 |
|
|
*** used, and then restart.
|
4251 |
|
|
|
4252 |
|
|
_LT_EOF
|
4253 |
|
|
elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
|
4254 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
4255 |
|
|
_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'
|
4256 |
|
|
else
|
4257 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4258 |
|
|
fi
|
4259 |
|
|
;;
|
4260 |
|
|
|
4261 |
|
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
|
4262 |
|
|
case `$LD -v 2>&1` in
|
4263 |
|
|
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
|
4264 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4265 |
|
|
cat <<_LT_EOF 1>&2
|
4266 |
|
|
|
4267 |
|
|
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
|
4268 |
|
|
*** reliably create shared libraries on SCO systems. Therefore, libtool
|
4269 |
|
|
*** is disabling shared libraries support. We urge you to upgrade GNU
|
4270 |
|
|
*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
|
4271 |
|
|
*** your PATH or compiler configuration so that the native linker is
|
4272 |
|
|
*** used, and then restart.
|
4273 |
|
|
|
4274 |
|
|
_LT_EOF
|
4275 |
|
|
;;
|
4276 |
|
|
*)
|
4277 |
|
|
# For security reasons, it is highly recommended that you always
|
4278 |
|
|
# use absolute paths for naming shared libraries, and exclude the
|
4279 |
|
|
# DT_RUNPATH tag from executables and libraries. But doing so
|
4280 |
|
|
# requires that you compile everything twice, which is a pain.
|
4281 |
|
|
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
|
4282 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
4283 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
4284 |
|
|
_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'
|
4285 |
|
|
else
|
4286 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4287 |
|
|
fi
|
4288 |
|
|
;;
|
4289 |
|
|
esac
|
4290 |
|
|
;;
|
4291 |
|
|
|
4292 |
|
|
sunos4*)
|
4293 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
|
4294 |
|
|
wlarc=
|
4295 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4296 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4297 |
|
|
;;
|
4298 |
|
|
|
4299 |
|
|
*)
|
4300 |
|
|
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
|
4301 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
4302 |
|
|
_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'
|
4303 |
|
|
else
|
4304 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4305 |
|
|
fi
|
4306 |
|
|
;;
|
4307 |
|
|
esac
|
4308 |
|
|
|
4309 |
|
|
if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
|
4310 |
|
|
runpath_var=
|
4311 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
|
4312 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
|
4313 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
4314 |
|
|
fi
|
4315 |
|
|
else
|
4316 |
|
|
# PORTME fill in a description of your system's linker (not GNU ld)
|
4317 |
|
|
case $host_os in
|
4318 |
|
|
aix3*)
|
4319 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
4320 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=yes
|
4321 |
|
|
_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'
|
4322 |
|
|
# Note: this linker hardcodes the directories in LIBPATH if there
|
4323 |
|
|
# are no directories specified by -L.
|
4324 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4325 |
|
|
if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
|
4326 |
|
|
# Neither direct hardcoding nor static linking is supported with a
|
4327 |
|
|
# broken collect2.
|
4328 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=unsupported
|
4329 |
|
|
fi
|
4330 |
|
|
;;
|
4331 |
|
|
|
4332 |
|
|
aix[[4-9]]*)
|
4333 |
|
|
if test "$host_cpu" = ia64; then
|
4334 |
|
|
# On IA64, the linker does run time linking by default, so we don't
|
4335 |
|
|
# have to do anything special.
|
4336 |
|
|
aix_use_runtimelinking=no
|
4337 |
|
|
exp_sym_flag='-Bexport'
|
4338 |
|
|
no_entry_flag=""
|
4339 |
|
|
else
|
4340 |
|
|
# If we're using GNU nm, then we don't want the "-C" option.
|
4341 |
|
|
# -C means demangle to AIX nm, but means don't demangle with GNU nm
|
4342 |
|
|
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
|
4343 |
|
|
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
|
4344 |
|
|
else
|
4345 |
|
|
_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'
|
4346 |
|
|
fi
|
4347 |
|
|
aix_use_runtimelinking=no
|
4348 |
|
|
|
4349 |
|
|
# Test if we are trying to use run time linking or normal
|
4350 |
|
|
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
|
4351 |
|
|
# need to do runtime linking.
|
4352 |
|
|
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
|
4353 |
|
|
for ld_flag in $LDFLAGS; do
|
4354 |
|
|
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
|
4355 |
|
|
aix_use_runtimelinking=yes
|
4356 |
|
|
break
|
4357 |
|
|
fi
|
4358 |
|
|
done
|
4359 |
|
|
;;
|
4360 |
|
|
esac
|
4361 |
|
|
|
4362 |
|
|
exp_sym_flag='-bexport'
|
4363 |
|
|
no_entry_flag='-bnoentry'
|
4364 |
|
|
fi
|
4365 |
|
|
|
4366 |
|
|
# When large executables or shared objects are built, AIX ld can
|
4367 |
|
|
# have problems creating the table of contents. If linking a library
|
4368 |
|
|
# or program results in "error TOC overflow" add -mminimal-toc to
|
4369 |
|
|
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
|
4370 |
|
|
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
|
4371 |
|
|
|
4372 |
|
|
_LT_TAGVAR(archive_cmds, $1)=''
|
4373 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4374 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
4375 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
|
4376 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
4377 |
|
|
_LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
|
4378 |
|
|
|
4379 |
|
|
if test "$GCC" = yes; then
|
4380 |
|
|
case $host_os in aix4.[[012]]|aix4.[[012]].*)
|
4381 |
|
|
# We only want to do this on AIX 4.2 and lower, the check
|
4382 |
|
|
# below for broken collect2 doesn't work under 4.3+
|
4383 |
|
|
collect2name=`${CC} -print-prog-name=collect2`
|
4384 |
|
|
if test -f "$collect2name" &&
|
4385 |
|
|
strings "$collect2name" | $GREP resolve_lib_name >/dev/null
|
4386 |
|
|
then
|
4387 |
|
|
# We have reworked collect2
|
4388 |
|
|
:
|
4389 |
|
|
else
|
4390 |
|
|
# We have old collect2
|
4391 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=unsupported
|
4392 |
|
|
# It fails to find uninstalled libraries when the uninstalled
|
4393 |
|
|
# path is not listed in the libpath. Setting hardcode_minus_L
|
4394 |
|
|
# to unsupported forces relinking
|
4395 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4396 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4397 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=
|
4398 |
|
|
fi
|
4399 |
|
|
;;
|
4400 |
|
|
esac
|
4401 |
|
|
shared_flag='-shared'
|
4402 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
4403 |
|
|
shared_flag="$shared_flag "'${wl}-G'
|
4404 |
|
|
fi
|
4405 |
|
|
else
|
4406 |
|
|
# not using gcc
|
4407 |
|
|
if test "$host_cpu" = ia64; then
|
4408 |
|
|
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
|
4409 |
|
|
# chokes on -Wl,-G. The following line is correct:
|
4410 |
|
|
shared_flag='-G'
|
4411 |
|
|
else
|
4412 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
4413 |
|
|
shared_flag='${wl}-G'
|
4414 |
|
|
else
|
4415 |
|
|
shared_flag='${wl}-bM:SRE'
|
4416 |
|
|
fi
|
4417 |
|
|
fi
|
4418 |
|
|
fi
|
4419 |
|
|
|
4420 |
|
|
# It seems that -bexpall does not export symbols beginning with
|
4421 |
|
|
# underscore (_), so it is better to generate a list of symbols to export.
|
4422 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=yes
|
4423 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
4424 |
|
|
# Warning - without using the other runtime loading flags (-brtl),
|
4425 |
|
|
# -berok will link without error, but may produce a broken library.
|
4426 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
|
4427 |
|
|
# Determine the default libpath from the value encoded in an
|
4428 |
|
|
# empty executable.
|
4429 |
|
|
_LT_SYS_MODULE_PATH_AIX
|
4430 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
|
4431 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
|
4432 |
|
|
else
|
4433 |
|
|
if test "$host_cpu" = ia64; then
|
4434 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
|
4435 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
|
4436 |
|
|
_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"
|
4437 |
|
|
else
|
4438 |
|
|
# Determine the default libpath from the value encoded in an
|
4439 |
|
|
# empty executable.
|
4440 |
|
|
_LT_SYS_MODULE_PATH_AIX
|
4441 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
|
4442 |
|
|
# Warning - without using the other run time loading flags,
|
4443 |
|
|
# -berok will link without error, but may produce a broken library.
|
4444 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
|
4445 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
|
4446 |
|
|
# Exported symbols can be pulled into shared objects from archives
|
4447 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
|
4448 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
|
4449 |
|
|
# This is similar to how AIX traditionally builds its shared libraries.
|
4450 |
|
|
_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'
|
4451 |
|
|
fi
|
4452 |
|
|
fi
|
4453 |
|
|
;;
|
4454 |
|
|
|
4455 |
|
|
amigaos*)
|
4456 |
|
|
if test "$host_cpu" = m68k; then
|
4457 |
|
|
_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)'
|
4458 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4459 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4460 |
|
|
fi
|
4461 |
|
|
# see comment about different semantics on the GNU ld section
|
4462 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4463 |
|
|
;;
|
4464 |
|
|
|
4465 |
|
|
bsdi[[45]]*)
|
4466 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
|
4467 |
|
|
;;
|
4468 |
|
|
|
4469 |
|
|
cygwin* | mingw* | pw32*)
|
4470 |
|
|
# When not using gcc, we currently assume that we are using
|
4471 |
|
|
# Microsoft Visual C++.
|
4472 |
|
|
# hardcode_libdir_flag_spec is actually meaningless, as there is
|
4473 |
|
|
# no search path for DLLs.
|
4474 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
|
4475 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
4476 |
|
|
# Tell ltmain to make .lib files, not .a files.
|
4477 |
|
|
libext=lib
|
4478 |
|
|
# Tell ltmain to make .dll files, not .so files.
|
4479 |
|
|
shrext_cmds=".dll"
|
4480 |
|
|
# FIXME: Setting linknames here is a bad hack.
|
4481 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
|
4482 |
|
|
# The linker will automatically build a .lib file if we build a DLL.
|
4483 |
|
|
_LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
|
4484 |
|
|
# FIXME: Should let the user specify the lib program.
|
4485 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
|
4486 |
|
|
_LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
|
4487 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
|
4488 |
|
|
;;
|
4489 |
|
|
|
4490 |
|
|
darwin* | rhapsody*)
|
4491 |
|
|
case $host_os in
|
4492 |
|
|
rhapsody* | darwin1.[[012]])
|
4493 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
|
4494 |
|
|
;;
|
4495 |
|
|
*) # Darwin 1.3 on
|
4496 |
|
|
case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
|
4497 |
|
|
10.[[012]])
|
4498 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
|
4499 |
|
|
;;
|
4500 |
|
|
10.*)
|
4501 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
|
4502 |
|
|
;;
|
4503 |
|
|
esac
|
4504 |
|
|
;;
|
4505 |
|
|
esac
|
4506 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
4507 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
4508 |
|
|
_LT_TAGVAR(hardcode_automatic, $1)=yes
|
4509 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
4510 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=''
|
4511 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
4512 |
|
|
if test "$GCC" = yes ; then
|
4513 |
|
|
AC_CACHE_VAL([lt_cv_apple_cc_single_mod],
|
4514 |
|
|
[lt_cv_apple_cc_single_mod=no
|
4515 |
|
|
if test -z "${LT_MULTI_MODULE}"; then
|
4516 |
|
|
# By default we will add the -single_module flag. You can override
|
4517 |
|
|
# by either setting the environment variable LT_MULTI_MODULE
|
4518 |
|
|
# non-empty at configure time, or by adding -multi-module to the
|
4519 |
|
|
# link flags.
|
4520 |
|
|
echo "int foo(void){return 1;}" > conftest.c
|
4521 |
|
|
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
|
4522 |
|
|
-dynamiclib ${wl}-single_module conftest.c
|
4523 |
|
|
if test -f libconftest.dylib; then
|
4524 |
|
|
lt_cv_apple_cc_single_mod=yes
|
4525 |
|
|
rm libconftest.dylib
|
4526 |
|
|
fi
|
4527 |
|
|
rm conftest.$ac_ext
|
4528 |
|
|
fi])
|
4529 |
|
|
output_verbose_link_cmd=echo
|
4530 |
|
|
if test "X$lt_cv_apple_cc_single_mod" = Xyes ; then
|
4531 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
4532 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $single_module -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
4533 |
|
|
else
|
4534 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
4535 |
|
|
_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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
4536 |
|
|
fi
|
4537 |
|
|
_LT_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
4538 |
|
|
_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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
4539 |
|
|
else
|
4540 |
|
|
case $cc_basename in
|
4541 |
|
|
xlc*)
|
4542 |
|
|
output_verbose_link_cmd=echo
|
4543 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`$ECHO $rpath/$soname` $verstring'
|
4544 |
|
|
_LT_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
4545 |
|
|
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
|
4546 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
4547 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
4548 |
|
|
;;
|
4549 |
|
|
*)
|
4550 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4551 |
|
|
;;
|
4552 |
|
|
esac
|
4553 |
|
|
fi
|
4554 |
|
|
;;
|
4555 |
|
|
|
4556 |
|
|
dgux*)
|
4557 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4558 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4559 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4560 |
|
|
;;
|
4561 |
|
|
|
4562 |
|
|
freebsd1*)
|
4563 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4564 |
|
|
;;
|
4565 |
|
|
|
4566 |
|
|
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
|
4567 |
|
|
# support. Future versions do this automatically, but an explicit c++rt0.o
|
4568 |
|
|
# does not break anything, and helps significantly (at the cost of a little
|
4569 |
|
|
# extra space).
|
4570 |
|
|
freebsd2.2*)
|
4571 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
|
4572 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
4573 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4574 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4575 |
|
|
;;
|
4576 |
|
|
|
4577 |
|
|
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
|
4578 |
|
|
freebsd2*)
|
4579 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
|
4580 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4581 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4582 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4583 |
|
|
;;
|
4584 |
|
|
|
4585 |
|
|
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
|
4586 |
|
|
freebsd* | dragonfly*)
|
4587 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
|
4588 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
4589 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4590 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4591 |
|
|
;;
|
4592 |
|
|
|
4593 |
|
|
hpux9*)
|
4594 |
|
|
if test "$GCC" = yes; then
|
4595 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
|
4596 |
|
|
else
|
4597 |
|
|
_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'
|
4598 |
|
|
fi
|
4599 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
|
4600 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4601 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4602 |
|
|
|
4603 |
|
|
# hardcode_minus_L: Not really in the search PATH,
|
4604 |
|
|
# but as the default location of the library.
|
4605 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4606 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
4607 |
|
|
;;
|
4608 |
|
|
|
4609 |
|
|
hpux10*)
|
4610 |
|
|
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
|
4611 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
|
4612 |
|
|
else
|
4613 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
|
4614 |
|
|
fi
|
4615 |
|
|
if test "$with_gnu_ld" = no; then
|
4616 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
|
4617 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
|
4618 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4619 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4620 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
4621 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
4622 |
|
|
# hardcode_minus_L: Not really in the search PATH,
|
4623 |
|
|
# but as the default location of the library.
|
4624 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4625 |
|
|
fi
|
4626 |
|
|
;;
|
4627 |
|
|
|
4628 |
|
|
hpux11*)
|
4629 |
|
|
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
|
4630 |
|
|
case $host_cpu in
|
4631 |
|
|
hppa*64*)
|
4632 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4633 |
|
|
;;
|
4634 |
|
|
ia64*)
|
4635 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
|
4636 |
|
|
;;
|
4637 |
|
|
*)
|
4638 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
|
4639 |
|
|
;;
|
4640 |
|
|
esac
|
4641 |
|
|
else
|
4642 |
|
|
case $host_cpu in
|
4643 |
|
|
hppa*64*)
|
4644 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4645 |
|
|
;;
|
4646 |
|
|
ia64*)
|
4647 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
|
4648 |
|
|
;;
|
4649 |
|
|
*)
|
4650 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
|
4651 |
|
|
;;
|
4652 |
|
|
esac
|
4653 |
|
|
fi
|
4654 |
|
|
if test "$with_gnu_ld" = no; then
|
4655 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
|
4656 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4657 |
|
|
|
4658 |
|
|
case $host_cpu in
|
4659 |
|
|
hppa*64*|ia64*)
|
4660 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
4661 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4662 |
|
|
;;
|
4663 |
|
|
*)
|
4664 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4665 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
4666 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
4667 |
|
|
|
4668 |
|
|
# hardcode_minus_L: Not really in the search PATH,
|
4669 |
|
|
# but as the default location of the library.
|
4670 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4671 |
|
|
;;
|
4672 |
|
|
esac
|
4673 |
|
|
fi
|
4674 |
|
|
;;
|
4675 |
|
|
|
4676 |
|
|
irix5* | irix6* | nonstopux*)
|
4677 |
|
|
if test "$GCC" = yes; then
|
4678 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
|
4679 |
|
|
# Try to use the -exported_symbol ld option, if it does not
|
4680 |
|
|
# work, assume that -exports_file does not work either and
|
4681 |
|
|
# implicitly export all symbols.
|
4682 |
|
|
save_LDFLAGS="$LDFLAGS"
|
4683 |
|
|
LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
|
4684 |
|
|
AC_LINK_IFELSE(int foo(void) {},
|
4685 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
|
4686 |
|
|
)
|
4687 |
|
|
LDFLAGS="$save_LDFLAGS"
|
4688 |
|
|
else
|
4689 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
|
4690 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
|
4691 |
|
|
fi
|
4692 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
|
4693 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
4694 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4695 |
|
|
_LT_TAGVAR(inherit_rpath, $1)=yes
|
4696 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
4697 |
|
|
;;
|
4698 |
|
|
|
4699 |
|
|
netbsd*)
|
4700 |
|
|
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
|
4701 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
|
4702 |
|
|
else
|
4703 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
|
4704 |
|
|
fi
|
4705 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
4706 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4707 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4708 |
|
|
;;
|
4709 |
|
|
|
4710 |
|
|
newsos6)
|
4711 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4712 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4713 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
4714 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4715 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4716 |
|
|
;;
|
4717 |
|
|
|
4718 |
|
|
*nto* | *qnx*)
|
4719 |
|
|
;;
|
4720 |
|
|
|
4721 |
|
|
openbsd*)
|
4722 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4723 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4724 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
4725 |
|
|
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
4726 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
|
4727 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
|
4728 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
4729 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
4730 |
|
|
else
|
4731 |
|
|
case $host_os in
|
4732 |
|
|
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
|
4733 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
|
4734 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
4735 |
|
|
;;
|
4736 |
|
|
*)
|
4737 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
|
4738 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
4739 |
|
|
;;
|
4740 |
|
|
esac
|
4741 |
|
|
fi
|
4742 |
|
|
;;
|
4743 |
|
|
|
4744 |
|
|
os2*)
|
4745 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4746 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4747 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
4748 |
|
|
_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'
|
4749 |
|
|
_LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
|
4750 |
|
|
;;
|
4751 |
|
|
|
4752 |
|
|
osf3*)
|
4753 |
|
|
if test "$GCC" = yes; then
|
4754 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
|
4755 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
|
4756 |
|
|
else
|
4757 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
|
4758 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
|
4759 |
|
|
fi
|
4760 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
|
4761 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
4762 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4763 |
|
|
;;
|
4764 |
|
|
|
4765 |
|
|
osf4* | osf5*) # as osf3* with the addition of -msym flag
|
4766 |
|
|
if test "$GCC" = yes; then
|
4767 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
|
4768 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
|
4769 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
4770 |
|
|
else
|
4771 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
|
4772 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
|
4773 |
|
|
_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~
|
4774 |
|
|
$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
|
4775 |
|
|
|
4776 |
|
|
# Both c and cxx compiler support -rpath directly
|
4777 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
|
4778 |
|
|
fi
|
4779 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
|
4780 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
4781 |
|
|
;;
|
4782 |
|
|
|
4783 |
|
|
solaris*)
|
4784 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
|
4785 |
|
|
if test "$GCC" = yes; then
|
4786 |
|
|
wlarc='${wl}'
|
4787 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4788 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
|
4789 |
|
|
$CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
|
4790 |
|
|
else
|
4791 |
|
|
case `$CC -V 2>&1` in
|
4792 |
|
|
*"Compilers 5.0"*)
|
4793 |
|
|
wlarc=''
|
4794 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4795 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
|
4796 |
|
|
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
|
4797 |
|
|
;;
|
4798 |
|
|
*)
|
4799 |
|
|
wlarc='${wl}'
|
4800 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
|
4801 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
|
4802 |
|
|
$CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
|
4803 |
|
|
;;
|
4804 |
|
|
esac
|
4805 |
|
|
fi
|
4806 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
4807 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4808 |
|
|
case $host_os in
|
4809 |
|
|
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
|
4810 |
|
|
*)
|
4811 |
|
|
# The compiler driver will combine and reorder linker options,
|
4812 |
|
|
# but understands `-z linker_flag'. GCC discards it without `$wl',
|
4813 |
|
|
# but is careful enough not to reorder.
|
4814 |
|
|
# Supported since Solaris 2.6 (maybe 2.5.1?)
|
4815 |
|
|
if test "$GCC" = yes; then
|
4816 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
|
4817 |
|
|
else
|
4818 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
|
4819 |
|
|
fi
|
4820 |
|
|
;;
|
4821 |
|
|
esac
|
4822 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
4823 |
|
|
;;
|
4824 |
|
|
|
4825 |
|
|
sunos4*)
|
4826 |
|
|
if test "x$host_vendor" = xsequent; then
|
4827 |
|
|
# Use $CC to link under sequent, because it throws in some extra .o
|
4828 |
|
|
# files that make .init and .fini sections work.
|
4829 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
|
4830 |
|
|
else
|
4831 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
|
4832 |
|
|
fi
|
4833 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4834 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
4835 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
4836 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4837 |
|
|
;;
|
4838 |
|
|
|
4839 |
|
|
sysv4)
|
4840 |
|
|
case $host_vendor in
|
4841 |
|
|
sni)
|
4842 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4843 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
|
4844 |
|
|
;;
|
4845 |
|
|
siemens)
|
4846 |
|
|
## LD is ld it makes a PLAMLIB
|
4847 |
|
|
## CC just makes a GrossModule.
|
4848 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
|
4849 |
|
|
_LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
|
4850 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
4851 |
|
|
;;
|
4852 |
|
|
motorola)
|
4853 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4854 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
|
4855 |
|
|
;;
|
4856 |
|
|
esac
|
4857 |
|
|
runpath_var='LD_RUN_PATH'
|
4858 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4859 |
|
|
;;
|
4860 |
|
|
|
4861 |
|
|
sysv4.3*)
|
4862 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4863 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4864 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
|
4865 |
|
|
;;
|
4866 |
|
|
|
4867 |
|
|
sysv4*MP*)
|
4868 |
|
|
if test -d /usr/nec; then
|
4869 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4870 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4871 |
|
|
runpath_var=LD_RUN_PATH
|
4872 |
|
|
hardcode_runpath_var=yes
|
4873 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=yes
|
4874 |
|
|
fi
|
4875 |
|
|
;;
|
4876 |
|
|
|
4877 |
|
|
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
|
4878 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
|
4879 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
4880 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4881 |
|
|
runpath_var='LD_RUN_PATH'
|
4882 |
|
|
|
4883 |
|
|
if test "$GCC" = yes; then
|
4884 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4885 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4886 |
|
|
else
|
4887 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4888 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4889 |
|
|
fi
|
4890 |
|
|
;;
|
4891 |
|
|
|
4892 |
|
|
sysv5* | sco3.2v5* | sco5v6*)
|
4893 |
|
|
# Note: We can NOT use -z defs as we might desire, because we do not
|
4894 |
|
|
# link with -lc, and that would cause any symbols used from libc to
|
4895 |
|
|
# always be unresolved, which means just about no library would
|
4896 |
|
|
# ever link correctly. If we're not using GNU ld we use -z text
|
4897 |
|
|
# though, which does catch some bad symbols but isn't as heavy-handed
|
4898 |
|
|
# as -z defs.
|
4899 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
|
4900 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
|
4901 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
4902 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4903 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
|
4904 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
|
4905 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
4906 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
|
4907 |
|
|
runpath_var='LD_RUN_PATH'
|
4908 |
|
|
|
4909 |
|
|
if test "$GCC" = yes; then
|
4910 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4911 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4912 |
|
|
else
|
4913 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4914 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
4915 |
|
|
fi
|
4916 |
|
|
;;
|
4917 |
|
|
|
4918 |
|
|
uts4*)
|
4919 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
|
4920 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
4921 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
4922 |
|
|
;;
|
4923 |
|
|
|
4924 |
|
|
*)
|
4925 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
4926 |
|
|
;;
|
4927 |
|
|
esac
|
4928 |
|
|
|
4929 |
|
|
if test x$host_vendor = xsni; then
|
4930 |
|
|
case $host in
|
4931 |
|
|
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
|
4932 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
|
4933 |
|
|
;;
|
4934 |
|
|
esac
|
4935 |
|
|
fi
|
4936 |
|
|
fi
|
4937 |
|
|
])
|
4938 |
|
|
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
|
4939 |
|
|
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
|
4940 |
|
|
|
4941 |
|
|
_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
|
4942 |
|
|
|
4943 |
|
|
_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
|
4944 |
|
|
_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
|
4945 |
|
|
_LT_DECL([], [extract_expsyms_cmds], [2],
|
4946 |
|
|
[The commands to extract the exported symbol list from a shared archive])
|
4947 |
|
|
|
4948 |
|
|
#
|
4949 |
|
|
# Do we need to explicitly link libc?
|
4950 |
|
|
#
|
4951 |
|
|
case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
|
4952 |
|
|
x|xyes)
|
4953 |
|
|
# Assume -lc should be added
|
4954 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
|
4955 |
|
|
|
4956 |
|
|
if test "$enable_shared" = yes && test "$GCC" = yes; then
|
4957 |
|
|
case $_LT_TAGVAR(archive_cmds, $1) in
|
4958 |
|
|
*'~'*)
|
4959 |
|
|
# FIXME: we may have to deal with multi-command sequences.
|
4960 |
|
|
;;
|
4961 |
|
|
'$CC '*)
|
4962 |
|
|
# Test whether the compiler implicitly links with -lc since on some
|
4963 |
|
|
# systems, -lgcc has to come before -lc. If gcc already passes -lc
|
4964 |
|
|
# to ld, don't add -lc before -lgcc.
|
4965 |
|
|
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
|
4966 |
|
|
$RM conftest*
|
4967 |
|
|
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
|
4968 |
|
|
|
4969 |
|
|
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
|
4970 |
|
|
soname=conftest
|
4971 |
|
|
lib=conftest
|
4972 |
|
|
libobjs=conftest.$ac_objext
|
4973 |
|
|
deplibs=
|
4974 |
|
|
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
|
4975 |
|
|
pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
|
4976 |
|
|
compiler_flags=-v
|
4977 |
|
|
linker_flags=-v
|
4978 |
|
|
verstring=
|
4979 |
|
|
output_objdir=.
|
4980 |
|
|
libname=conftest
|
4981 |
|
|
lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
|
4982 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=
|
4983 |
|
|
if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
|
4984 |
|
|
then
|
4985 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
4986 |
|
|
else
|
4987 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
|
4988 |
|
|
fi
|
4989 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
|
4990 |
|
|
else
|
4991 |
|
|
cat conftest.err 1>&5
|
4992 |
|
|
fi
|
4993 |
|
|
$RM conftest*
|
4994 |
|
|
AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
|
4995 |
|
|
;;
|
4996 |
|
|
esac
|
4997 |
|
|
fi
|
4998 |
|
|
;;
|
4999 |
|
|
esac
|
5000 |
|
|
|
5001 |
|
|
_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
|
5002 |
|
|
[Whether or not to add -lc for building shared libraries])
|
5003 |
|
|
_LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
|
5004 |
|
|
[enable_shared_with_static_runtimes], [0],
|
5005 |
|
|
[Whether or not to disallow shared libs when runtime libs are static])
|
5006 |
|
|
_LT_TAGDECL([], [export_dynamic_flag_spec], [1],
|
5007 |
|
|
[Compiler flag to allow reflexive dlopens])
|
5008 |
|
|
_LT_TAGDECL([], [whole_archive_flag_spec], [1],
|
5009 |
|
|
[Compiler flag to generate shared objects directly from archives])
|
5010 |
|
|
_LT_TAGDECL([], [compiler_needs_object], [1],
|
5011 |
|
|
[Whether the compiler copes with passing no objects directly])
|
5012 |
|
|
_LT_TAGDECL([], [old_archive_from_new_cmds], [2],
|
5013 |
|
|
[Create an old-style archive from a shared archive])
|
5014 |
|
|
_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
|
5015 |
|
|
[Create a temporary old-style archive to link instead of a shared archive])
|
5016 |
|
|
_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
|
5017 |
|
|
_LT_TAGDECL([], [archive_expsym_cmds], [2])
|
5018 |
|
|
_LT_TAGDECL([], [module_cmds], [2],
|
5019 |
|
|
[Commands used to build a loadable module if different from building
|
5020 |
|
|
a shared archive.])
|
5021 |
|
|
_LT_TAGDECL([], [module_expsym_cmds], [2])
|
5022 |
|
|
_LT_TAGDECL([], [with_gnu_ld], [1],
|
5023 |
|
|
[Whether we are building with GNU ld or not])
|
5024 |
|
|
_LT_TAGDECL([], [allow_undefined_flag], [1],
|
5025 |
|
|
[Flag that allows shared libraries with undefined symbols to be built])
|
5026 |
|
|
_LT_TAGDECL([], [no_undefined_flag], [1],
|
5027 |
|
|
[Flag that enforces no undefined symbols])
|
5028 |
|
|
_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
|
5029 |
|
|
[Flag to hardcode $libdir into a binary during linking.
|
5030 |
|
|
This must work even if $libdir does not exist])
|
5031 |
|
|
_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
|
5032 |
|
|
[[If ld is used when linking, flag to hardcode $libdir into a binary
|
5033 |
|
|
during linking. This must work even if $libdir does not exist]])
|
5034 |
|
|
_LT_TAGDECL([], [hardcode_libdir_separator], [1],
|
5035 |
|
|
[Whether we need a single "-rpath" flag with a separated argument])
|
5036 |
|
|
_LT_TAGDECL([], [hardcode_direct], [0],
|
5037 |
|
|
[Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
|
5038 |
|
|
DIR into the resulting binary])
|
5039 |
|
|
_LT_TAGDECL([], [hardcode_direct_absolute], [0],
|
5040 |
|
|
[Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
|
5041 |
|
|
DIR into the resulting binary and the resulting library dependency is
|
5042 |
|
|
"absolute", i.e impossible to change by setting ${shlibpath_var} if the
|
5043 |
|
|
library is relocated])
|
5044 |
|
|
_LT_TAGDECL([], [hardcode_minus_L], [0],
|
5045 |
|
|
[Set to "yes" if using the -LDIR flag during linking hardcodes DIR
|
5046 |
|
|
into the resulting binary])
|
5047 |
|
|
_LT_TAGDECL([], [hardcode_shlibpath_var], [0],
|
5048 |
|
|
[Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
|
5049 |
|
|
into the resulting binary])
|
5050 |
|
|
_LT_TAGDECL([], [hardcode_automatic], [0],
|
5051 |
|
|
[Set to "yes" if building a shared library automatically hardcodes DIR
|
5052 |
|
|
into the library and all subsequent libraries and executables linked
|
5053 |
|
|
against it])
|
5054 |
|
|
_LT_TAGDECL([], [inherit_rpath], [0],
|
5055 |
|
|
[Set to yes if linker adds runtime paths of dependent libraries
|
5056 |
|
|
to runtime path list])
|
5057 |
|
|
_LT_TAGDECL([], [link_all_deplibs], [0],
|
5058 |
|
|
[Whether libtool must link a program against all its dependency libraries])
|
5059 |
|
|
_LT_TAGDECL([], [fix_srcfile_path], [1],
|
5060 |
|
|
[Fix the shell variable $srcfile for the compiler])
|
5061 |
|
|
_LT_TAGDECL([], [always_export_symbols], [0],
|
5062 |
|
|
[Set to "yes" if exported symbols are required])
|
5063 |
|
|
_LT_TAGDECL([], [export_symbols_cmds], [2],
|
5064 |
|
|
[The commands to list exported symbols])
|
5065 |
|
|
_LT_TAGDECL([], [exclude_expsyms], [1],
|
5066 |
|
|
[Symbols that should not be listed in the preloaded symbols])
|
5067 |
|
|
_LT_TAGDECL([], [include_expsyms], [1],
|
5068 |
|
|
[Symbols that must always be exported])
|
5069 |
|
|
_LT_TAGDECL([], [prelink_cmds], [2],
|
5070 |
|
|
[Commands necessary for linking programs (against libraries) with templates])
|
5071 |
|
|
_LT_TAGDECL([], [file_list_spec], [1],
|
5072 |
|
|
[Specify filename containing input files])
|
5073 |
|
|
dnl FIXME: Not yet implemented
|
5074 |
|
|
dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
|
5075 |
|
|
dnl [Compiler flag to generate thread safe objects])
|
5076 |
|
|
])# _LT_LINKER_SHLIBS
|
5077 |
|
|
|
5078 |
|
|
|
5079 |
|
|
# _LT_LANG_C_CONFIG([TAG])
|
5080 |
|
|
# ------------------------
|
5081 |
|
|
# Ensure that the configuration variables for a C compiler are suitably
|
5082 |
|
|
# defined. These variables are subsequently used by _LT_CONFIG to write
|
5083 |
|
|
# the compiler configuration to `libtool'.
|
5084 |
|
|
m4_defun([_LT_LANG_C_CONFIG],
|
5085 |
|
|
[m4_require([_LT_DECL_EGREP])dnl
|
5086 |
|
|
lt_save_CC="$CC"
|
5087 |
|
|
AC_LANG_PUSH(C)
|
5088 |
|
|
|
5089 |
|
|
# Source file extension for C test sources.
|
5090 |
|
|
ac_ext=c
|
5091 |
|
|
|
5092 |
|
|
# Object file extension for compiled C test sources.
|
5093 |
|
|
objext=o
|
5094 |
|
|
_LT_TAGVAR(objext, $1)=$objext
|
5095 |
|
|
|
5096 |
|
|
# Code to be used in simple compile tests
|
5097 |
|
|
lt_simple_compile_test_code="int some_variable = 0;"
|
5098 |
|
|
|
5099 |
|
|
# Code to be used in simple link tests
|
5100 |
|
|
lt_simple_link_test_code='int main(){return(0);}'
|
5101 |
|
|
|
5102 |
|
|
_LT_TAG_COMPILER
|
5103 |
|
|
# Save the default compiler, since it gets overwritten when the other
|
5104 |
|
|
# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
|
5105 |
|
|
compiler_DEFAULT=$CC
|
5106 |
|
|
|
5107 |
|
|
# save warnings/boilerplate of simple test code
|
5108 |
|
|
_LT_COMPILER_BOILERPLATE
|
5109 |
|
|
_LT_LINKER_BOILERPLATE
|
5110 |
|
|
|
5111 |
|
|
## CAVEAT EMPTOR:
|
5112 |
|
|
## There is no encapsulation within the following macros, do not change
|
5113 |
|
|
## the running order or otherwise move them around unless you know exactly
|
5114 |
|
|
## what you are doing...
|
5115 |
|
|
if test -n "$compiler"; then
|
5116 |
|
|
_LT_COMPILER_NO_RTTI($1)
|
5117 |
|
|
_LT_COMPILER_PIC($1)
|
5118 |
|
|
_LT_COMPILER_C_O($1)
|
5119 |
|
|
_LT_COMPILER_FILE_LOCKS($1)
|
5120 |
|
|
_LT_LINKER_SHLIBS($1)
|
5121 |
|
|
_LT_SYS_DYNAMIC_LINKER($1)
|
5122 |
|
|
_LT_LINKER_HARDCODE_LIBPATH($1)
|
5123 |
|
|
LT_SYS_DLOPEN_SELF
|
5124 |
|
|
_LT_CMD_STRIPLIB
|
5125 |
|
|
|
5126 |
|
|
# Report which library types will actually be built
|
5127 |
|
|
AC_MSG_CHECKING([if libtool supports shared libraries])
|
5128 |
|
|
AC_MSG_RESULT([$can_build_shared])
|
5129 |
|
|
|
5130 |
|
|
AC_MSG_CHECKING([whether to build shared libraries])
|
5131 |
|
|
test "$can_build_shared" = "no" && enable_shared=no
|
5132 |
|
|
|
5133 |
|
|
# On AIX, shared libraries and static libraries use the same namespace, and
|
5134 |
|
|
# are all built from PIC.
|
5135 |
|
|
case $host_os in
|
5136 |
|
|
aix3*)
|
5137 |
|
|
test "$enable_shared" = yes && enable_static=no
|
5138 |
|
|
if test -n "$RANLIB"; then
|
5139 |
|
|
archive_cmds="$archive_cmds~\$RANLIB \$lib"
|
5140 |
|
|
postinstall_cmds='$RANLIB $lib'
|
5141 |
|
|
fi
|
5142 |
|
|
;;
|
5143 |
|
|
|
5144 |
|
|
aix[[4-9]]*)
|
5145 |
|
|
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
|
5146 |
|
|
test "$enable_shared" = yes && enable_static=no
|
5147 |
|
|
fi
|
5148 |
|
|
;;
|
5149 |
|
|
esac
|
5150 |
|
|
AC_MSG_RESULT([$enable_shared])
|
5151 |
|
|
|
5152 |
|
|
AC_MSG_CHECKING([whether to build static libraries])
|
5153 |
|
|
# Make sure either enable_shared or enable_static is yes.
|
5154 |
|
|
test "$enable_shared" = yes || enable_static=yes
|
5155 |
|
|
AC_MSG_RESULT([$enable_static])
|
5156 |
|
|
|
5157 |
|
|
_LT_CONFIG($1)
|
5158 |
|
|
fi
|
5159 |
|
|
AC_LANG_POP
|
5160 |
|
|
CC="$lt_save_CC"
|
5161 |
|
|
])# _LT_LANG_C_CONFIG
|
5162 |
|
|
|
5163 |
|
|
|
5164 |
|
|
# _LT_PROG_CXX
|
5165 |
|
|
# ------------
|
5166 |
|
|
# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
|
5167 |
|
|
# compiler, we have our own version here.
|
5168 |
|
|
m4_defun([_LT_PROG_CXX],
|
5169 |
|
|
[
|
5170 |
|
|
pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
|
5171 |
|
|
AC_PROG_CXX
|
5172 |
|
|
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
|
5173 |
|
|
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
|
5174 |
|
|
(test "X$CXX" != "Xg++"))) ; then
|
5175 |
|
|
AC_PROG_CXXCPP
|
5176 |
|
|
else
|
5177 |
|
|
_lt_caught_CXX_error=yes
|
5178 |
|
|
fi
|
5179 |
|
|
popdef([AC_MSG_ERROR])
|
5180 |
|
|
])# _LT_PROG_CXX
|
5181 |
|
|
|
5182 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
5183 |
|
|
dnl AC_DEFUN([_LT_PROG_CXX], [])
|
5184 |
|
|
|
5185 |
|
|
|
5186 |
|
|
# _LT_LANG_CXX_CONFIG([TAG])
|
5187 |
|
|
# --------------------------
|
5188 |
|
|
# Ensure that the configuration variables for a C++ compiler are suitably
|
5189 |
|
|
# defined. These variables are subsequently used by _LT_CONFIG to write
|
5190 |
|
|
# the compiler configuration to `libtool'.
|
5191 |
|
|
m4_defun([_LT_LANG_CXX_CONFIG],
|
5192 |
|
|
[AC_REQUIRE([_LT_PROG_CXX])dnl
|
5193 |
|
|
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
5194 |
|
|
m4_require([_LT_DECL_EGREP])dnl
|
5195 |
|
|
|
5196 |
|
|
AC_LANG_PUSH(C++)
|
5197 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
5198 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=
|
5199 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=no
|
5200 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)=
|
5201 |
|
|
_LT_TAGVAR(compiler_needs_object, $1)=no
|
5202 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
|
5203 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
5204 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
|
5205 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
|
5206 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
|
5207 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=
|
5208 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=no
|
5209 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
5210 |
|
|
_LT_TAGVAR(hardcode_automatic, $1)=no
|
5211 |
|
|
_LT_TAGVAR(inherit_rpath, $1)=no
|
5212 |
|
|
_LT_TAGVAR(module_cmds, $1)=
|
5213 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)=
|
5214 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=unknown
|
5215 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
|
5216 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=
|
5217 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
5218 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
|
5219 |
|
|
|
5220 |
|
|
# Source file extension for C++ test sources.
|
5221 |
|
|
ac_ext=cpp
|
5222 |
|
|
|
5223 |
|
|
# Object file extension for compiled C++ test sources.
|
5224 |
|
|
objext=o
|
5225 |
|
|
_LT_TAGVAR(objext, $1)=$objext
|
5226 |
|
|
|
5227 |
|
|
# No sense in running all these tests if we already determined that
|
5228 |
|
|
# the CXX compiler isn't working. Some variables (like enable_shared)
|
5229 |
|
|
# are currently assumed to apply to all compilers on this platform,
|
5230 |
|
|
# and will be corrupted by setting them based on a non-working compiler.
|
5231 |
|
|
if test "$_lt_caught_CXX_error" != yes; then
|
5232 |
|
|
# Code to be used in simple compile tests
|
5233 |
|
|
lt_simple_compile_test_code="int some_variable = 0;"
|
5234 |
|
|
|
5235 |
|
|
# Code to be used in simple link tests
|
5236 |
|
|
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
|
5237 |
|
|
|
5238 |
|
|
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
|
5239 |
|
|
_LT_TAG_COMPILER
|
5240 |
|
|
|
5241 |
|
|
# save warnings/boilerplate of simple test code
|
5242 |
|
|
_LT_COMPILER_BOILERPLATE
|
5243 |
|
|
_LT_LINKER_BOILERPLATE
|
5244 |
|
|
|
5245 |
|
|
# Allow CC to be a program name with arguments.
|
5246 |
|
|
lt_save_CC=$CC
|
5247 |
|
|
lt_save_LD=$LD
|
5248 |
|
|
lt_save_GCC=$GCC
|
5249 |
|
|
GCC=$GXX
|
5250 |
|
|
lt_save_with_gnu_ld=$with_gnu_ld
|
5251 |
|
|
lt_save_path_LD=$lt_cv_path_LD
|
5252 |
|
|
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
|
5253 |
|
|
lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
|
5254 |
|
|
else
|
5255 |
|
|
$as_unset lt_cv_prog_gnu_ld
|
5256 |
|
|
fi
|
5257 |
|
|
if test -n "${lt_cv_path_LDCXX+set}"; then
|
5258 |
|
|
lt_cv_path_LD=$lt_cv_path_LDCXX
|
5259 |
|
|
else
|
5260 |
|
|
$as_unset lt_cv_path_LD
|
5261 |
|
|
fi
|
5262 |
|
|
test -z "${LDCXX+set}" || LD=$LDCXX
|
5263 |
|
|
CC=${CXX-"c++"}
|
5264 |
|
|
compiler=$CC
|
5265 |
|
|
_LT_TAGVAR(compiler, $1)=$CC
|
5266 |
|
|
_LT_CC_BASENAME([$compiler])
|
5267 |
|
|
|
5268 |
|
|
if test -n "$compiler"; then
|
5269 |
|
|
# We don't want -fno-exception when compiling C++ code, so set the
|
5270 |
|
|
# no_builtin_flag separately
|
5271 |
|
|
if test "$GXX" = yes; then
|
5272 |
|
|
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
|
5273 |
|
|
else
|
5274 |
|
|
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
|
5275 |
|
|
fi
|
5276 |
|
|
|
5277 |
|
|
if test "$GXX" = yes; then
|
5278 |
|
|
# Set up default GNU C++ configuration
|
5279 |
|
|
|
5280 |
|
|
LT_PATH_LD
|
5281 |
|
|
|
5282 |
|
|
# Check if GNU C++ uses GNU ld as the underlying linker, since the
|
5283 |
|
|
# archiving commands below assume that GNU ld is being used.
|
5284 |
|
|
if test "$with_gnu_ld" = yes; then
|
5285 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
5286 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
|
5287 |
|
|
|
5288 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
5289 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
|
5290 |
|
|
|
5291 |
|
|
# If archive_cmds runs LD, not CC, wlarc should be empty
|
5292 |
|
|
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
|
5293 |
|
|
# investigate it a little bit more. (MM)
|
5294 |
|
|
wlarc='${wl}'
|
5295 |
|
|
|
5296 |
|
|
# ancient GNU ld didn't support --whole-archive et. al.
|
5297 |
|
|
if eval "`$CC -print-prog-name=ld` --help 2>&1" |
|
5298 |
|
|
$GREP 'no-whole-archive' > /dev/null; then
|
5299 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
|
5300 |
|
|
else
|
5301 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
5302 |
|
|
fi
|
5303 |
|
|
else
|
5304 |
|
|
with_gnu_ld=no
|
5305 |
|
|
wlarc=
|
5306 |
|
|
|
5307 |
|
|
# A generic and very simple default shared library creation
|
5308 |
|
|
# command for GNU C++ for the case where it uses the native
|
5309 |
|
|
# linker, instead of GNU ld. If possible, this setting should
|
5310 |
|
|
# overridden to take advantage of the native linker features on
|
5311 |
|
|
# the platform it is being used on.
|
5312 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
|
5313 |
|
|
fi
|
5314 |
|
|
|
5315 |
|
|
# Commands to make compiler produce verbose output that lists
|
5316 |
|
|
# what "hidden" libraries, object files and flags are used when
|
5317 |
|
|
# linking a shared library.
|
5318 |
|
|
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
|
5319 |
|
|
|
5320 |
|
|
else
|
5321 |
|
|
GXX=no
|
5322 |
|
|
with_gnu_ld=no
|
5323 |
|
|
wlarc=
|
5324 |
|
|
fi
|
5325 |
|
|
|
5326 |
|
|
# PORTME: fill in a description of your system's C++ link characteristics
|
5327 |
|
|
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
|
5328 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=yes
|
5329 |
|
|
case $host_os in
|
5330 |
|
|
aix3*)
|
5331 |
|
|
# FIXME: insert proper C++ library support
|
5332 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5333 |
|
|
;;
|
5334 |
|
|
aix[[4-9]]*)
|
5335 |
|
|
if test "$host_cpu" = ia64; then
|
5336 |
|
|
# On IA64, the linker does run time linking by default, so we don't
|
5337 |
|
|
# have to do anything special.
|
5338 |
|
|
aix_use_runtimelinking=no
|
5339 |
|
|
exp_sym_flag='-Bexport'
|
5340 |
|
|
no_entry_flag=""
|
5341 |
|
|
else
|
5342 |
|
|
aix_use_runtimelinking=no
|
5343 |
|
|
|
5344 |
|
|
# Test if we are trying to use run time linking or normal
|
5345 |
|
|
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
|
5346 |
|
|
# need to do runtime linking.
|
5347 |
|
|
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
|
5348 |
|
|
for ld_flag in $LDFLAGS; do
|
5349 |
|
|
case $ld_flag in
|
5350 |
|
|
*-brtl*)
|
5351 |
|
|
aix_use_runtimelinking=yes
|
5352 |
|
|
break
|
5353 |
|
|
;;
|
5354 |
|
|
esac
|
5355 |
|
|
done
|
5356 |
|
|
;;
|
5357 |
|
|
esac
|
5358 |
|
|
|
5359 |
|
|
exp_sym_flag='-bexport'
|
5360 |
|
|
no_entry_flag='-bnoentry'
|
5361 |
|
|
fi
|
5362 |
|
|
|
5363 |
|
|
# When large executables or shared objects are built, AIX ld can
|
5364 |
|
|
# have problems creating the table of contents. If linking a library
|
5365 |
|
|
# or program results in "error TOC overflow" add -mminimal-toc to
|
5366 |
|
|
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
|
5367 |
|
|
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
|
5368 |
|
|
|
5369 |
|
|
_LT_TAGVAR(archive_cmds, $1)=''
|
5370 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
5371 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
5372 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
|
5373 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
5374 |
|
|
_LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
|
5375 |
|
|
|
5376 |
|
|
if test "$GXX" = yes; then
|
5377 |
|
|
case $host_os in aix4.[[012]]|aix4.[[012]].*)
|
5378 |
|
|
# We only want to do this on AIX 4.2 and lower, the check
|
5379 |
|
|
# below for broken collect2 doesn't work under 4.3+
|
5380 |
|
|
collect2name=`${CC} -print-prog-name=collect2`
|
5381 |
|
|
if test -f "$collect2name" &&
|
5382 |
|
|
strings "$collect2name" | $GREP resolve_lib_name >/dev/null
|
5383 |
|
|
then
|
5384 |
|
|
# We have reworked collect2
|
5385 |
|
|
:
|
5386 |
|
|
else
|
5387 |
|
|
# We have old collect2
|
5388 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=unsupported
|
5389 |
|
|
# It fails to find uninstalled libraries when the uninstalled
|
5390 |
|
|
# path is not listed in the libpath. Setting hardcode_minus_L
|
5391 |
|
|
# to unsupported forces relinking
|
5392 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes
|
5393 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
5394 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=
|
5395 |
|
|
fi
|
5396 |
|
|
esac
|
5397 |
|
|
shared_flag='-shared'
|
5398 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
5399 |
|
|
shared_flag="$shared_flag "'${wl}-G'
|
5400 |
|
|
fi
|
5401 |
|
|
else
|
5402 |
|
|
# not using gcc
|
5403 |
|
|
if test "$host_cpu" = ia64; then
|
5404 |
|
|
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
|
5405 |
|
|
# chokes on -Wl,-G. The following line is correct:
|
5406 |
|
|
shared_flag='-G'
|
5407 |
|
|
else
|
5408 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
5409 |
|
|
shared_flag='${wl}-G'
|
5410 |
|
|
else
|
5411 |
|
|
shared_flag='${wl}-bM:SRE'
|
5412 |
|
|
fi
|
5413 |
|
|
fi
|
5414 |
|
|
fi
|
5415 |
|
|
|
5416 |
|
|
# It seems that -bexpall does not export symbols beginning with
|
5417 |
|
|
# underscore (_), so it is better to generate a list of symbols to
|
5418 |
|
|
# export.
|
5419 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=yes
|
5420 |
|
|
if test "$aix_use_runtimelinking" = yes; then
|
5421 |
|
|
# Warning - without using the other runtime loading flags (-brtl),
|
5422 |
|
|
# -berok will link without error, but may produce a broken library.
|
5423 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
|
5424 |
|
|
# Determine the default libpath from the value encoded in an empty
|
5425 |
|
|
# executable.
|
5426 |
|
|
_LT_SYS_MODULE_PATH_AIX
|
5427 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
|
5428 |
|
|
|
5429 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
|
5430 |
|
|
else
|
5431 |
|
|
if test "$host_cpu" = ia64; then
|
5432 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
|
5433 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
|
5434 |
|
|
_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"
|
5435 |
|
|
else
|
5436 |
|
|
# Determine the default libpath from the value encoded in an
|
5437 |
|
|
# empty executable.
|
5438 |
|
|
_LT_SYS_MODULE_PATH_AIX
|
5439 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
|
5440 |
|
|
# Warning - without using the other run time loading flags,
|
5441 |
|
|
# -berok will link without error, but may produce a broken library.
|
5442 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
|
5443 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
|
5444 |
|
|
# Exported symbols can be pulled into shared objects from archives
|
5445 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
|
5446 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
|
5447 |
|
|
# This is similar to how AIX traditionally builds its shared
|
5448 |
|
|
# libraries.
|
5449 |
|
|
_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'
|
5450 |
|
|
fi
|
5451 |
|
|
fi
|
5452 |
|
|
;;
|
5453 |
|
|
|
5454 |
|
|
beos*)
|
5455 |
|
|
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
|
5456 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
5457 |
|
|
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
|
5458 |
|
|
# support --undefined. This deserves some investigation. FIXME
|
5459 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
5460 |
|
|
else
|
5461 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5462 |
|
|
fi
|
5463 |
|
|
;;
|
5464 |
|
|
|
5465 |
|
|
chorus*)
|
5466 |
|
|
case $cc_basename in
|
5467 |
|
|
*)
|
5468 |
|
|
# FIXME: insert proper C++ library support
|
5469 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5470 |
|
|
;;
|
5471 |
|
|
esac
|
5472 |
|
|
;;
|
5473 |
|
|
|
5474 |
|
|
cygwin* | mingw* | pw32*)
|
5475 |
|
|
# _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
|
5476 |
|
|
# as there is no search path for DLLs.
|
5477 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
|
5478 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
|
5479 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=no
|
5480 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
|
5481 |
|
|
|
5482 |
|
|
if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
|
5483 |
|
|
_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'
|
5484 |
|
|
# If the export-symbols file already is a .def file (1st line
|
5485 |
|
|
# is EXPORTS), use it as is; otherwise, prepend...
|
5486 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
|
5487 |
|
|
cp $export_symbols $output_objdir/$soname.def;
|
5488 |
|
|
else
|
5489 |
|
|
echo EXPORTS > $output_objdir/$soname.def;
|
5490 |
|
|
cat $export_symbols >> $output_objdir/$soname.def;
|
5491 |
|
|
fi~
|
5492 |
|
|
$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'
|
5493 |
|
|
else
|
5494 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5495 |
|
|
fi
|
5496 |
|
|
;;
|
5497 |
|
|
darwin* | rhapsody*)
|
5498 |
|
|
case $host_os in
|
5499 |
|
|
rhapsody* | darwin1.[[012]])
|
5500 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
|
5501 |
|
|
;;
|
5502 |
|
|
*) # Darwin 1.3 on
|
5503 |
|
|
case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
|
5504 |
|
|
10.[[012]])
|
5505 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
|
5506 |
|
|
;;
|
5507 |
|
|
10.*)
|
5508 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
|
5509 |
|
|
;;
|
5510 |
|
|
esac
|
5511 |
|
|
;;
|
5512 |
|
|
esac
|
5513 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
5514 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
5515 |
|
|
_LT_TAGVAR(hardcode_automatic, $1)=yes
|
5516 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
5517 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=''
|
5518 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
5519 |
|
|
|
5520 |
|
|
if test "$GXX" = yes ; then
|
5521 |
|
|
AC_CACHE_VAL([lt_cv_apple_cc_single_mod],
|
5522 |
|
|
[lt_cv_apple_cc_single_mod=no
|
5523 |
|
|
if test -z "${LT_MULTI_MODULE}"; then
|
5524 |
|
|
# By default we will add the -single_module flag. You can override
|
5525 |
|
|
# by either setting the environment variable LT_MULTI_MODULE
|
5526 |
|
|
# non-empty at configure time, or by adding -multi-module to the
|
5527 |
|
|
# link flags.
|
5528 |
|
|
echo "int foo(void){return 1;}" > conftest.c
|
5529 |
|
|
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
|
5530 |
|
|
-dynamiclib ${wl}-single_module conftest.c
|
5531 |
|
|
if test -f libconftest.dylib; then
|
5532 |
|
|
lt_cv_apple_cc_single_mod=yes
|
5533 |
|
|
rm libconftest.dylib
|
5534 |
|
|
fi
|
5535 |
|
|
rm conftest.$ac_ext
|
5536 |
|
|
fi])
|
5537 |
|
|
output_verbose_link_cmd=echo
|
5538 |
|
|
if test "X$lt_cv_apple_cc_single_mod" = Xyes ; then
|
5539 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
5540 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
5541 |
|
|
else
|
5542 |
|
|
_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'
|
5543 |
|
|
_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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
5544 |
|
|
fi
|
5545 |
|
|
_LT_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
5546 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
5547 |
|
|
else
|
5548 |
|
|
case $cc_basename in
|
5549 |
|
|
xlc*)
|
5550 |
|
|
output_verbose_link_cmd=echo
|
5551 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`$ECHO "$rpath/$soname"` $verstring'
|
5552 |
|
|
_LT_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
5553 |
|
|
# Don't fix this by using the ld -exported_symbols_list flag,
|
5554 |
|
|
# it doesn't exist in older darwin lds
|
5555 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
5556 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)='sed "s,^,_," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
5557 |
|
|
;;
|
5558 |
|
|
*)
|
5559 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5560 |
|
|
;;
|
5561 |
|
|
esac
|
5562 |
|
|
fi
|
5563 |
|
|
;;
|
5564 |
|
|
|
5565 |
|
|
dgux*)
|
5566 |
|
|
case $cc_basename in
|
5567 |
|
|
ec++*)
|
5568 |
|
|
# FIXME: insert proper C++ library support
|
5569 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5570 |
|
|
;;
|
5571 |
|
|
ghcx*)
|
5572 |
|
|
# Green Hills C++ Compiler
|
5573 |
|
|
# FIXME: insert proper C++ library support
|
5574 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5575 |
|
|
;;
|
5576 |
|
|
*)
|
5577 |
|
|
# FIXME: insert proper C++ library support
|
5578 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5579 |
|
|
;;
|
5580 |
|
|
esac
|
5581 |
|
|
;;
|
5582 |
|
|
|
5583 |
|
|
freebsd[[12]]*)
|
5584 |
|
|
# C++ shared libraries reported to be fairly broken before
|
5585 |
|
|
# switch to ELF
|
5586 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5587 |
|
|
;;
|
5588 |
|
|
|
5589 |
|
|
freebsd-elf*)
|
5590 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
5591 |
|
|
;;
|
5592 |
|
|
|
5593 |
|
|
freebsd* | dragonfly*)
|
5594 |
|
|
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
|
5595 |
|
|
# conventions
|
5596 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=yes
|
5597 |
|
|
;;
|
5598 |
|
|
|
5599 |
|
|
gnu*)
|
5600 |
|
|
;;
|
5601 |
|
|
|
5602 |
|
|
hpux9*)
|
5603 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
|
5604 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
5605 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
5606 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
5607 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
|
5608 |
|
|
# but as the default
|
5609 |
|
|
# location of the library.
|
5610 |
|
|
|
5611 |
|
|
case $cc_basename in
|
5612 |
|
|
CC*)
|
5613 |
|
|
# FIXME: insert proper C++ library support
|
5614 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5615 |
|
|
;;
|
5616 |
|
|
aCC*)
|
5617 |
|
|
_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'
|
5618 |
|
|
# Commands to make compiler produce verbose output that lists
|
5619 |
|
|
# what "hidden" libraries, object files and flags are used when
|
5620 |
|
|
# linking a shared library.
|
5621 |
|
|
#
|
5622 |
|
|
# There doesn't appear to be a way to prevent this compiler from
|
5623 |
|
|
# explicitly linking system object files so we need to strip them
|
5624 |
|
|
# from the output so that they don't get included in the library
|
5625 |
|
|
# dependencies.
|
5626 |
|
|
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
|
5627 |
|
|
;;
|
5628 |
|
|
*)
|
5629 |
|
|
if test "$GXX" = yes; then
|
5630 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
|
5631 |
|
|
else
|
5632 |
|
|
# FIXME: insert proper C++ library support
|
5633 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5634 |
|
|
fi
|
5635 |
|
|
;;
|
5636 |
|
|
esac
|
5637 |
|
|
;;
|
5638 |
|
|
|
5639 |
|
|
hpux10*|hpux11*)
|
5640 |
|
|
if test $with_gnu_ld = no; then
|
5641 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
|
5642 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
5643 |
|
|
|
5644 |
|
|
case $host_cpu in
|
5645 |
|
|
hppa*64*|ia64*)
|
5646 |
|
|
;;
|
5647 |
|
|
*)
|
5648 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
5649 |
|
|
;;
|
5650 |
|
|
esac
|
5651 |
|
|
fi
|
5652 |
|
|
case $host_cpu in
|
5653 |
|
|
hppa*64*|ia64*)
|
5654 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
5655 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
5656 |
|
|
;;
|
5657 |
|
|
*)
|
5658 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
5659 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
5660 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
|
5661 |
|
|
# but as the default
|
5662 |
|
|
# location of the library.
|
5663 |
|
|
;;
|
5664 |
|
|
esac
|
5665 |
|
|
|
5666 |
|
|
case $cc_basename in
|
5667 |
|
|
CC*)
|
5668 |
|
|
# FIXME: insert proper C++ library support
|
5669 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5670 |
|
|
;;
|
5671 |
|
|
aCC*)
|
5672 |
|
|
case $host_cpu in
|
5673 |
|
|
hppa*64*)
|
5674 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
5675 |
|
|
;;
|
5676 |
|
|
ia64*)
|
5677 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
5678 |
|
|
;;
|
5679 |
|
|
*)
|
5680 |
|
|
_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'
|
5681 |
|
|
;;
|
5682 |
|
|
esac
|
5683 |
|
|
# Commands to make compiler produce verbose output that lists
|
5684 |
|
|
# what "hidden" libraries, object files and flags are used when
|
5685 |
|
|
# linking a shared library.
|
5686 |
|
|
#
|
5687 |
|
|
# There doesn't appear to be a way to prevent this compiler from
|
5688 |
|
|
# explicitly linking system object files so we need to strip them
|
5689 |
|
|
# from the output so that they don't get included in the library
|
5690 |
|
|
# dependencies.
|
5691 |
|
|
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
|
5692 |
|
|
;;
|
5693 |
|
|
*)
|
5694 |
|
|
if test "$GXX" = yes; then
|
5695 |
|
|
if test $with_gnu_ld = no; then
|
5696 |
|
|
case $host_cpu in
|
5697 |
|
|
hppa*64*)
|
5698 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
5699 |
|
|
;;
|
5700 |
|
|
ia64*)
|
5701 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
5702 |
|
|
;;
|
5703 |
|
|
*)
|
5704 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
5705 |
|
|
;;
|
5706 |
|
|
esac
|
5707 |
|
|
fi
|
5708 |
|
|
else
|
5709 |
|
|
# FIXME: insert proper C++ library support
|
5710 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5711 |
|
|
fi
|
5712 |
|
|
;;
|
5713 |
|
|
esac
|
5714 |
|
|
;;
|
5715 |
|
|
|
5716 |
|
|
interix[[3-9]]*)
|
5717 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
5718 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
5719 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
5720 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
5721 |
|
|
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
|
5722 |
|
|
# Instead, shared libraries are loaded at an image base (0x10000000 by
|
5723 |
|
|
# default) and relocated if they conflict, which is a slow very memory
|
5724 |
|
|
# consuming and fragmenting process. To avoid this, we pick a random,
|
5725 |
|
|
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
|
5726 |
|
|
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
|
5727 |
|
|
_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'
|
5728 |
|
|
_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'
|
5729 |
|
|
;;
|
5730 |
|
|
irix5* | irix6*)
|
5731 |
|
|
case $cc_basename in
|
5732 |
|
|
CC*)
|
5733 |
|
|
# SGI C++
|
5734 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
|
5735 |
|
|
|
5736 |
|
|
# Archives containing C++ object files must be created using
|
5737 |
|
|
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
|
5738 |
|
|
# necessary to make sure instantiated templates are included
|
5739 |
|
|
# in the archive.
|
5740 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
|
5741 |
|
|
;;
|
5742 |
|
|
*)
|
5743 |
|
|
if test "$GXX" = yes; then
|
5744 |
|
|
if test "$with_gnu_ld" = no; then
|
5745 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
|
5746 |
|
|
else
|
5747 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
|
5748 |
|
|
fi
|
5749 |
|
|
fi
|
5750 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
5751 |
|
|
;;
|
5752 |
|
|
esac
|
5753 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
5754 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
5755 |
|
|
_LT_TAGVAR(inherit_rpath, $1)=yes
|
5756 |
|
|
;;
|
5757 |
|
|
|
5758 |
|
|
linux* | k*bsd*-gnu)
|
5759 |
|
|
case $cc_basename in
|
5760 |
|
|
KCC*)
|
5761 |
|
|
# Kuck and Associates, Inc. (KAI) C++ Compiler
|
5762 |
|
|
|
5763 |
|
|
# KCC will only create a shared library if the output file
|
5764 |
|
|
# ends with ".so" (or ".sl" for HP-UX), so rename the library
|
5765 |
|
|
# to its proper name (with version) after linking.
|
5766 |
|
|
_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'
|
5767 |
|
|
_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'
|
5768 |
|
|
# Commands to make compiler produce verbose output that lists
|
5769 |
|
|
# what "hidden" libraries, object files and flags are used when
|
5770 |
|
|
# linking a shared library.
|
5771 |
|
|
#
|
5772 |
|
|
# There doesn't appear to be a way to prevent this compiler from
|
5773 |
|
|
# explicitly linking system object files so we need to strip them
|
5774 |
|
|
# from the output so that they don't get included in the library
|
5775 |
|
|
# dependencies.
|
5776 |
|
|
output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
|
5777 |
|
|
|
5778 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
5779 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
|
5780 |
|
|
|
5781 |
|
|
# Archives containing C++ object files must be created using
|
5782 |
|
|
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
|
5783 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
|
5784 |
|
|
;;
|
5785 |
|
|
icpc* | ecpc* )
|
5786 |
|
|
# Intel C++
|
5787 |
|
|
with_gnu_ld=yes
|
5788 |
|
|
# version 8.0 and above of icpc choke on multiply defined symbols
|
5789 |
|
|
# if we add $predep_objects and $postdep_objects, however 7.1 and
|
5790 |
|
|
# earlier do not add the objects themselves.
|
5791 |
|
|
case `$CC -V 2>&1` in
|
5792 |
|
|
*"Version 7."*)
|
5793 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
5794 |
|
|
_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'
|
5795 |
|
|
;;
|
5796 |
|
|
*) # Version 8.0 or newer
|
5797 |
|
|
tmp_idyn=
|
5798 |
|
|
case $host_cpu in
|
5799 |
|
|
ia64*) tmp_idyn=' -i_dynamic';;
|
5800 |
|
|
esac
|
5801 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
5802 |
|
|
_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'
|
5803 |
|
|
;;
|
5804 |
|
|
esac
|
5805 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
5806 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
5807 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
|
5808 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
|
5809 |
|
|
;;
|
5810 |
|
|
pgCC*)
|
5811 |
|
|
# Portland Group C++ compiler
|
5812 |
|
|
case `$CC -V` in
|
5813 |
|
|
*pgCC\ [[1-5]]*)
|
5814 |
|
|
_LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
|
5815 |
|
|
rm -rf $tpldir~
|
5816 |
|
|
$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
|
5817 |
|
|
compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
|
5818 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
|
5819 |
|
|
rm -rf $tpldir~
|
5820 |
|
|
$CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
|
5821 |
|
|
$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
|
5822 |
|
|
$RANLIB $oldlib'
|
5823 |
|
|
_LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
|
5824 |
|
|
rm -rf $tpldir~
|
5825 |
|
|
$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
|
5826 |
|
|
$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
|
5827 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
|
5828 |
|
|
rm -rf $tpldir~
|
5829 |
|
|
$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
|
5830 |
|
|
$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
|
5831 |
|
|
;;
|
5832 |
|
|
*) # Version 6 will use weak symbols
|
5833 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
|
5834 |
|
|
_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'
|
5835 |
|
|
;;
|
5836 |
|
|
esac
|
5837 |
|
|
|
5838 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
|
5839 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
|
5840 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
|
5841 |
|
|
;;
|
5842 |
|
|
cxx*)
|
5843 |
|
|
# Compaq C++
|
5844 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
|
5845 |
|
|
_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'
|
5846 |
|
|
|
5847 |
|
|
runpath_var=LD_RUN_PATH
|
5848 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
|
5849 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
5850 |
|
|
|
5851 |
|
|
# Commands to make compiler produce verbose output that lists
|
5852 |
|
|
# what "hidden" libraries, object files and flags are used when
|
5853 |
|
|
# linking a shared library.
|
5854 |
|
|
#
|
5855 |
|
|
# There doesn't appear to be a way to prevent this compiler from
|
5856 |
|
|
# explicitly linking system object files so we need to strip them
|
5857 |
|
|
# from the output so that they don't get included in the library
|
5858 |
|
|
# dependencies.
|
5859 |
|
|
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
|
5860 |
|
|
;;
|
5861 |
|
|
*)
|
5862 |
|
|
case `$CC -V 2>&1 | sed 5q` in
|
5863 |
|
|
*Sun\ C*)
|
5864 |
|
|
# Sun C++ 5.9
|
5865 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
|
5866 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
5867 |
|
|
_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'
|
5868 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
5869 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
|
5870 |
|
|
_LT_TAGVAR(compiler_needs_object, $1)=yes
|
5871 |
|
|
|
5872 |
|
|
# Not sure whether something based on
|
5873 |
|
|
# $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
|
5874 |
|
|
# would be better.
|
5875 |
|
|
output_verbose_link_cmd='echo'
|
5876 |
|
|
|
5877 |
|
|
# Archives containing C++ object files must be created using
|
5878 |
|
|
# "CC -xar", where "CC" is the Sun C++ compiler. This is
|
5879 |
|
|
# necessary to make sure instantiated templates are included
|
5880 |
|
|
# in the archive.
|
5881 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
|
5882 |
|
|
;;
|
5883 |
|
|
esac
|
5884 |
|
|
;;
|
5885 |
|
|
esac
|
5886 |
|
|
;;
|
5887 |
|
|
|
5888 |
|
|
lynxos*)
|
5889 |
|
|
# FIXME: insert proper C++ library support
|
5890 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5891 |
|
|
;;
|
5892 |
|
|
|
5893 |
|
|
m88k*)
|
5894 |
|
|
# FIXME: insert proper C++ library support
|
5895 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5896 |
|
|
;;
|
5897 |
|
|
|
5898 |
|
|
mvs*)
|
5899 |
|
|
case $cc_basename in
|
5900 |
|
|
cxx*)
|
5901 |
|
|
# FIXME: insert proper C++ library support
|
5902 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5903 |
|
|
;;
|
5904 |
|
|
*)
|
5905 |
|
|
# FIXME: insert proper C++ library support
|
5906 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5907 |
|
|
;;
|
5908 |
|
|
esac
|
5909 |
|
|
;;
|
5910 |
|
|
|
5911 |
|
|
netbsd*)
|
5912 |
|
|
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
|
5913 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
|
5914 |
|
|
wlarc=
|
5915 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
5916 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
5917 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
5918 |
|
|
fi
|
5919 |
|
|
# Workaround some broken pre-1.5 toolchains
|
5920 |
|
|
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
|
5921 |
|
|
;;
|
5922 |
|
|
|
5923 |
|
|
*nto* | *qnx*)
|
5924 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=yes
|
5925 |
|
|
;;
|
5926 |
|
|
|
5927 |
|
|
openbsd2*)
|
5928 |
|
|
# C++ shared libraries are fairly broken
|
5929 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5930 |
|
|
;;
|
5931 |
|
|
|
5932 |
|
|
openbsd*)
|
5933 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=yes
|
5934 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
5935 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
|
5936 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
|
5937 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
5938 |
|
|
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
5939 |
|
|
_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'
|
5940 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
|
5941 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
|
5942 |
|
|
fi
|
5943 |
|
|
output_verbose_link_cmd=echo
|
5944 |
|
|
;;
|
5945 |
|
|
|
5946 |
|
|
osf3* | osf4* | osf5*)
|
5947 |
|
|
case $cc_basename in
|
5948 |
|
|
KCC*)
|
5949 |
|
|
# Kuck and Associates, Inc. (KAI) C++ Compiler
|
5950 |
|
|
|
5951 |
|
|
# KCC will only create a shared library if the output file
|
5952 |
|
|
# ends with ".so" (or ".sl" for HP-UX), so rename the library
|
5953 |
|
|
# to its proper name (with version) after linking.
|
5954 |
|
|
_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'
|
5955 |
|
|
|
5956 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
|
5957 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
5958 |
|
|
|
5959 |
|
|
# Archives containing C++ object files must be created using
|
5960 |
|
|
# the KAI C++ compiler.
|
5961 |
|
|
case $host in
|
5962 |
|
|
osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
|
5963 |
|
|
*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
|
5964 |
|
|
esac
|
5965 |
|
|
;;
|
5966 |
|
|
RCC*)
|
5967 |
|
|
# Rational C++ 2.4.1
|
5968 |
|
|
# FIXME: insert proper C++ library support
|
5969 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
5970 |
|
|
;;
|
5971 |
|
|
cxx*)
|
5972 |
|
|
case $host in
|
5973 |
|
|
osf3*)
|
5974 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
|
5975 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
|
5976 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
5977 |
|
|
;;
|
5978 |
|
|
*)
|
5979 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
|
5980 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
|
5981 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
|
5982 |
|
|
echo "-hidden">> $lib.exp~
|
5983 |
|
|
$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
|
5984 |
|
|
$RM $lib.exp'
|
5985 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
|
5986 |
|
|
;;
|
5987 |
|
|
esac
|
5988 |
|
|
|
5989 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
5990 |
|
|
|
5991 |
|
|
# Commands to make compiler produce verbose output that lists
|
5992 |
|
|
# what "hidden" libraries, object files and flags are used when
|
5993 |
|
|
# linking a shared library.
|
5994 |
|
|
#
|
5995 |
|
|
# There doesn't appear to be a way to prevent this compiler from
|
5996 |
|
|
# explicitly linking system object files so we need to strip them
|
5997 |
|
|
# from the output so that they don't get included in the library
|
5998 |
|
|
# dependencies.
|
5999 |
|
|
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
|
6000 |
|
|
;;
|
6001 |
|
|
*)
|
6002 |
|
|
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
|
6003 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
|
6004 |
|
|
case $host in
|
6005 |
|
|
osf3*)
|
6006 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
|
6007 |
|
|
;;
|
6008 |
|
|
*)
|
6009 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
|
6010 |
|
|
;;
|
6011 |
|
|
esac
|
6012 |
|
|
|
6013 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
|
6014 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
|
6015 |
|
|
|
6016 |
|
|
# Commands to make compiler produce verbose output that lists
|
6017 |
|
|
# what "hidden" libraries, object files and flags are used when
|
6018 |
|
|
# linking a shared library.
|
6019 |
|
|
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
|
6020 |
|
|
|
6021 |
|
|
else
|
6022 |
|
|
# FIXME: insert proper C++ library support
|
6023 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6024 |
|
|
fi
|
6025 |
|
|
;;
|
6026 |
|
|
esac
|
6027 |
|
|
;;
|
6028 |
|
|
|
6029 |
|
|
psos*)
|
6030 |
|
|
# FIXME: insert proper C++ library support
|
6031 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6032 |
|
|
;;
|
6033 |
|
|
|
6034 |
|
|
sunos4*)
|
6035 |
|
|
case $cc_basename in
|
6036 |
|
|
CC*)
|
6037 |
|
|
# Sun C++ 4.x
|
6038 |
|
|
# FIXME: insert proper C++ library support
|
6039 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6040 |
|
|
;;
|
6041 |
|
|
lcc*)
|
6042 |
|
|
# Lucid
|
6043 |
|
|
# FIXME: insert proper C++ library support
|
6044 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6045 |
|
|
;;
|
6046 |
|
|
*)
|
6047 |
|
|
# FIXME: insert proper C++ library support
|
6048 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6049 |
|
|
;;
|
6050 |
|
|
esac
|
6051 |
|
|
;;
|
6052 |
|
|
|
6053 |
|
|
solaris*)
|
6054 |
|
|
case $cc_basename in
|
6055 |
|
|
CC*)
|
6056 |
|
|
# Sun C++ 4.2, 5.x and Centerline C++
|
6057 |
|
|
_LT_TAGVAR(archive_cmds_need_lc,$1)=yes
|
6058 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
|
6059 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
|
6060 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
|
6061 |
|
|
$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'
|
6062 |
|
|
|
6063 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
|
6064 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
6065 |
|
|
case $host_os in
|
6066 |
|
|
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
|
6067 |
|
|
*)
|
6068 |
|
|
# The compiler driver will combine and reorder linker options,
|
6069 |
|
|
# but understands `-z linker_flag'.
|
6070 |
|
|
# Supported since Solaris 2.6 (maybe 2.5.1?)
|
6071 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
|
6072 |
|
|
;;
|
6073 |
|
|
esac
|
6074 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
6075 |
|
|
|
6076 |
|
|
output_verbose_link_cmd='echo'
|
6077 |
|
|
|
6078 |
|
|
# Archives containing C++ object files must be created using
|
6079 |
|
|
# "CC -xar", where "CC" is the Sun C++ compiler. This is
|
6080 |
|
|
# necessary to make sure instantiated templates are included
|
6081 |
|
|
# in the archive.
|
6082 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
|
6083 |
|
|
;;
|
6084 |
|
|
gcx*)
|
6085 |
|
|
# Green Hills C++ Compiler
|
6086 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
|
6087 |
|
|
|
6088 |
|
|
# The C++ compiler must be used to create the archive.
|
6089 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
|
6090 |
|
|
;;
|
6091 |
|
|
*)
|
6092 |
|
|
# GNU C++ compiler with Solaris linker
|
6093 |
|
|
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
|
6094 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
|
6095 |
|
|
if $CC --version | $GREP -v '^2\.7' > /dev/null; then
|
6096 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
|
6097 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
|
6098 |
|
|
$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
|
6099 |
|
|
|
6100 |
|
|
# Commands to make compiler produce verbose output that lists
|
6101 |
|
|
# what "hidden" libraries, object files and flags are used when
|
6102 |
|
|
# linking a shared library.
|
6103 |
|
|
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
|
6104 |
|
|
else
|
6105 |
|
|
# g++ 2.7 appears to require `-G' NOT `-shared' on this
|
6106 |
|
|
# platform.
|
6107 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
|
6108 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
|
6109 |
|
|
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
|
6110 |
|
|
|
6111 |
|
|
# Commands to make compiler produce verbose output that lists
|
6112 |
|
|
# what "hidden" libraries, object files and flags are used when
|
6113 |
|
|
# linking a shared library.
|
6114 |
|
|
output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
|
6115 |
|
|
fi
|
6116 |
|
|
|
6117 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
|
6118 |
|
|
case $host_os in
|
6119 |
|
|
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
|
6120 |
|
|
*)
|
6121 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
|
6122 |
|
|
;;
|
6123 |
|
|
esac
|
6124 |
|
|
fi
|
6125 |
|
|
;;
|
6126 |
|
|
esac
|
6127 |
|
|
;;
|
6128 |
|
|
|
6129 |
|
|
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
|
6130 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
|
6131 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
6132 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
6133 |
|
|
runpath_var='LD_RUN_PATH'
|
6134 |
|
|
|
6135 |
|
|
case $cc_basename in
|
6136 |
|
|
CC*)
|
6137 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6138 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6139 |
|
|
;;
|
6140 |
|
|
*)
|
6141 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6142 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6143 |
|
|
;;
|
6144 |
|
|
esac
|
6145 |
|
|
;;
|
6146 |
|
|
|
6147 |
|
|
sysv5* | sco3.2v5* | sco5v6*)
|
6148 |
|
|
# Note: We can NOT use -z defs as we might desire, because we do not
|
6149 |
|
|
# link with -lc, and that would cause any symbols used from libc to
|
6150 |
|
|
# always be unresolved, which means just about no library would
|
6151 |
|
|
# ever link correctly. If we're not using GNU ld we use -z text
|
6152 |
|
|
# though, which does catch some bad symbols but isn't as heavy-handed
|
6153 |
|
|
# as -z defs.
|
6154 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
|
6155 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
|
6156 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
6157 |
|
|
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
|
6158 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
|
6159 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
|
6160 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=yes
|
6161 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
|
6162 |
|
|
runpath_var='LD_RUN_PATH'
|
6163 |
|
|
|
6164 |
|
|
case $cc_basename in
|
6165 |
|
|
CC*)
|
6166 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6167 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6168 |
|
|
;;
|
6169 |
|
|
*)
|
6170 |
|
|
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6171 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
|
6172 |
|
|
;;
|
6173 |
|
|
esac
|
6174 |
|
|
;;
|
6175 |
|
|
|
6176 |
|
|
tandem*)
|
6177 |
|
|
case $cc_basename in
|
6178 |
|
|
NCC*)
|
6179 |
|
|
# NonStop-UX NCC 3.20
|
6180 |
|
|
# FIXME: insert proper C++ library support
|
6181 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6182 |
|
|
;;
|
6183 |
|
|
*)
|
6184 |
|
|
# FIXME: insert proper C++ library support
|
6185 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6186 |
|
|
;;
|
6187 |
|
|
esac
|
6188 |
|
|
;;
|
6189 |
|
|
|
6190 |
|
|
vxworks*)
|
6191 |
|
|
# FIXME: insert proper C++ library support
|
6192 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6193 |
|
|
;;
|
6194 |
|
|
|
6195 |
|
|
*)
|
6196 |
|
|
# FIXME: insert proper C++ library support
|
6197 |
|
|
_LT_TAGVAR(ld_shlibs, $1)=no
|
6198 |
|
|
;;
|
6199 |
|
|
esac
|
6200 |
|
|
|
6201 |
|
|
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
|
6202 |
|
|
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
|
6203 |
|
|
|
6204 |
|
|
_LT_TAGVAR(GCC, $1)="$GXX"
|
6205 |
|
|
_LT_TAGVAR(LD, $1)="$LD"
|
6206 |
|
|
|
6207 |
|
|
## CAVEAT EMPTOR:
|
6208 |
|
|
## There is no encapsulation within the following macros, do not change
|
6209 |
|
|
## the running order or otherwise move them around unless you know exactly
|
6210 |
|
|
## what you are doing...
|
6211 |
|
|
_LT_SYS_HIDDEN_LIBDEPS($1)
|
6212 |
|
|
_LT_COMPILER_PIC($1)
|
6213 |
|
|
_LT_COMPILER_C_O($1)
|
6214 |
|
|
_LT_COMPILER_FILE_LOCKS($1)
|
6215 |
|
|
_LT_LINKER_SHLIBS($1)
|
6216 |
|
|
_LT_SYS_DYNAMIC_LINKER($1)
|
6217 |
|
|
_LT_LINKER_HARDCODE_LIBPATH($1)
|
6218 |
|
|
|
6219 |
|
|
_LT_CONFIG($1)
|
6220 |
|
|
fi # test -n "$compiler"
|
6221 |
|
|
|
6222 |
|
|
CC=$lt_save_CC
|
6223 |
|
|
LDCXX=$LD
|
6224 |
|
|
LD=$lt_save_LD
|
6225 |
|
|
GCC=$lt_save_GCC
|
6226 |
|
|
with_gnu_ld=$lt_save_with_gnu_ld
|
6227 |
|
|
lt_cv_path_LDCXX=$lt_cv_path_LD
|
6228 |
|
|
lt_cv_path_LD=$lt_save_path_LD
|
6229 |
|
|
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
|
6230 |
|
|
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
|
6231 |
|
|
fi # test "$_lt_caught_CXX_error" != yes
|
6232 |
|
|
|
6233 |
|
|
AC_LANG_POP
|
6234 |
|
|
])# _LT_LANG_CXX_CONFIG
|
6235 |
|
|
|
6236 |
|
|
|
6237 |
|
|
# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
|
6238 |
|
|
# ---------------------------------
|
6239 |
|
|
# Figure out "hidden" library dependencies from verbose
|
6240 |
|
|
# compiler output when linking a shared library.
|
6241 |
|
|
# Parse the compiler output and extract the necessary
|
6242 |
|
|
# objects, libraries and library flags.
|
6243 |
|
|
m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
|
6244 |
|
|
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
|
6245 |
|
|
# Dependencies to place before and after the object being linked:
|
6246 |
|
|
_LT_TAGVAR(predep_objects, $1)=
|
6247 |
|
|
_LT_TAGVAR(postdep_objects, $1)=
|
6248 |
|
|
_LT_TAGVAR(predeps, $1)=
|
6249 |
|
|
_LT_TAGVAR(postdeps, $1)=
|
6250 |
|
|
_LT_TAGVAR(compiler_lib_search_path, $1)=
|
6251 |
|
|
|
6252 |
|
|
dnl we can't use the lt_simple_compile_test_code here,
|
6253 |
|
|
dnl because it contains code intended for an executable,
|
6254 |
|
|
dnl not a library. It's possible we should let each
|
6255 |
|
|
dnl tag define a new lt_????_link_test_code variable,
|
6256 |
|
|
dnl but it's only used here...
|
6257 |
|
|
m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
|
6258 |
|
|
int a;
|
6259 |
|
|
void foo (void) { a = 0; }
|
6260 |
|
|
_LT_EOF
|
6261 |
|
|
], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
|
6262 |
|
|
class Foo
|
6263 |
|
|
{
|
6264 |
|
|
public:
|
6265 |
|
|
Foo (void) { a = 0; }
|
6266 |
|
|
private:
|
6267 |
|
|
int a;
|
6268 |
|
|
};
|
6269 |
|
|
_LT_EOF
|
6270 |
|
|
], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
|
6271 |
|
|
subroutine foo
|
6272 |
|
|
implicit none
|
6273 |
|
|
integer*4 a
|
6274 |
|
|
a=0
|
6275 |
|
|
return
|
6276 |
|
|
end
|
6277 |
|
|
_LT_EOF
|
6278 |
|
|
], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
|
6279 |
|
|
subroutine foo
|
6280 |
|
|
implicit none
|
6281 |
|
|
integer a
|
6282 |
|
|
a=0
|
6283 |
|
|
return
|
6284 |
|
|
end
|
6285 |
|
|
_LT_EOF
|
6286 |
|
|
], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
|
6287 |
|
|
public class foo {
|
6288 |
|
|
private int a;
|
6289 |
|
|
public void bar (void) {
|
6290 |
|
|
a = 0;
|
6291 |
|
|
}
|
6292 |
|
|
};
|
6293 |
|
|
_LT_EOF
|
6294 |
|
|
])
|
6295 |
|
|
dnl Parse the compiler output and extract the necessary
|
6296 |
|
|
dnl objects, libraries and library flags.
|
6297 |
|
|
if AC_TRY_EVAL(ac_compile); then
|
6298 |
|
|
# Parse the compiler output and extract the necessary
|
6299 |
|
|
# objects, libraries and library flags.
|
6300 |
|
|
|
6301 |
|
|
# Sentinel used to keep track of whether or not we are before
|
6302 |
|
|
# the conftest object file.
|
6303 |
|
|
pre_test_object_deps_done=no
|
6304 |
|
|
|
6305 |
|
|
# The `*' in the case matches for architectures that use `case' in
|
6306 |
|
|
# $output_verbose_cmd can trigger glob expansion during the loop
|
6307 |
|
|
# eval without this substitution.
|
6308 |
|
|
output_verbose_link_cmd=`$ECHO "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
|
6309 |
|
|
|
6310 |
|
|
for p in `eval $output_verbose_link_cmd`; do
|
6311 |
|
|
case $p in
|
6312 |
|
|
|
6313 |
|
|
-L* | -R* | -l*)
|
6314 |
|
|
# Some compilers place space between "-{L,R}" and the path.
|
6315 |
|
|
# Remove the space.
|
6316 |
|
|
if test $p = "-L" ||
|
6317 |
|
|
test $p = "-R"; then
|
6318 |
|
|
prev=$p
|
6319 |
|
|
continue
|
6320 |
|
|
else
|
6321 |
|
|
prev=
|
6322 |
|
|
fi
|
6323 |
|
|
|
6324 |
|
|
if test "$pre_test_object_deps_done" = no; then
|
6325 |
|
|
case $p in
|
6326 |
|
|
-L* | -R*)
|
6327 |
|
|
# Internal compiler library paths should come after those
|
6328 |
|
|
# provided the user. The postdeps already come after the
|
6329 |
|
|
# user supplied libs so there is no need to process them.
|
6330 |
|
|
if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
|
6331 |
|
|
_LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
|
6332 |
|
|
else
|
6333 |
|
|
_LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
|
6334 |
|
|
fi
|
6335 |
|
|
;;
|
6336 |
|
|
# The "-l" case would never come before the object being
|
6337 |
|
|
# linked, so don't bother handling this case.
|
6338 |
|
|
esac
|
6339 |
|
|
else
|
6340 |
|
|
if test -z "$_LT_TAGVAR(postdeps, $1)"; then
|
6341 |
|
|
_LT_TAGVAR(postdeps, $1)="${prev}${p}"
|
6342 |
|
|
else
|
6343 |
|
|
_LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
|
6344 |
|
|
fi
|
6345 |
|
|
fi
|
6346 |
|
|
;;
|
6347 |
|
|
|
6348 |
|
|
*.$objext)
|
6349 |
|
|
# This assumes that the test object file only shows up
|
6350 |
|
|
# once in the compiler output.
|
6351 |
|
|
if test "$p" = "conftest.$objext"; then
|
6352 |
|
|
pre_test_object_deps_done=yes
|
6353 |
|
|
continue
|
6354 |
|
|
fi
|
6355 |
|
|
|
6356 |
|
|
if test "$pre_test_object_deps_done" = no; then
|
6357 |
|
|
if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
|
6358 |
|
|
_LT_TAGVAR(predep_objects, $1)="$p"
|
6359 |
|
|
else
|
6360 |
|
|
_LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
|
6361 |
|
|
fi
|
6362 |
|
|
else
|
6363 |
|
|
if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
|
6364 |
|
|
_LT_TAGVAR(postdep_objects, $1)="$p"
|
6365 |
|
|
else
|
6366 |
|
|
_LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
|
6367 |
|
|
fi
|
6368 |
|
|
fi
|
6369 |
|
|
;;
|
6370 |
|
|
|
6371 |
|
|
*) ;; # Ignore the rest.
|
6372 |
|
|
|
6373 |
|
|
esac
|
6374 |
|
|
done
|
6375 |
|
|
|
6376 |
|
|
# Clean up.
|
6377 |
|
|
rm -f a.out a.exe
|
6378 |
|
|
else
|
6379 |
|
|
echo "libtool.m4: error: problem compiling $1 test program"
|
6380 |
|
|
fi
|
6381 |
|
|
|
6382 |
|
|
$RM -f confest.$objext
|
6383 |
|
|
|
6384 |
|
|
# PORTME: override above test on systems where it is broken
|
6385 |
|
|
m4_if([$1], [CXX],
|
6386 |
|
|
[case $host_os in
|
6387 |
|
|
interix[[3-9]]*)
|
6388 |
|
|
# Interix 3.5 installs completely hosed .la files for C++, so rather than
|
6389 |
|
|
# hack all around it, let's just trust "g++" to DTRT.
|
6390 |
|
|
_LT_TAGVAR(predep_objects,$1)=
|
6391 |
|
|
_LT_TAGVAR(postdep_objects,$1)=
|
6392 |
|
|
_LT_TAGVAR(postdeps,$1)=
|
6393 |
|
|
;;
|
6394 |
|
|
|
6395 |
|
|
linux*)
|
6396 |
|
|
case `$CC -V 2>&1 | sed 5q` in
|
6397 |
|
|
*Sun\ C*)
|
6398 |
|
|
# Sun C++ 5.9
|
6399 |
|
|
|
6400 |
|
|
# The more standards-conforming stlport4 library is
|
6401 |
|
|
# incompatible with the Cstd library. Avoid specifying
|
6402 |
|
|
# it if it's in CXXFLAGS. Ignore libCrun as
|
6403 |
|
|
# -library=stlport4 depends on it.
|
6404 |
|
|
case " $CXX $CXXFLAGS " in
|
6405 |
|
|
*" -library=stlport4 "*)
|
6406 |
|
|
solaris_use_stlport4=yes
|
6407 |
|
|
;;
|
6408 |
|
|
esac
|
6409 |
|
|
|
6410 |
|
|
if test "$solaris_use_stlport4" != yes; then
|
6411 |
|
|
_LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
|
6412 |
|
|
fi
|
6413 |
|
|
;;
|
6414 |
|
|
esac
|
6415 |
|
|
;;
|
6416 |
|
|
|
6417 |
|
|
solaris*)
|
6418 |
|
|
case $cc_basename in
|
6419 |
|
|
CC*)
|
6420 |
|
|
# The more standards-conforming stlport4 library is
|
6421 |
|
|
# incompatible with the Cstd library. Avoid specifying
|
6422 |
|
|
# it if it's in CXXFLAGS. Ignore libCrun as
|
6423 |
|
|
# -library=stlport4 depends on it.
|
6424 |
|
|
case " $CXX $CXXFLAGS " in
|
6425 |
|
|
*" -library=stlport4 "*)
|
6426 |
|
|
solaris_use_stlport4=yes
|
6427 |
|
|
;;
|
6428 |
|
|
esac
|
6429 |
|
|
|
6430 |
|
|
# Adding this requires a known-good setup of shared libraries for
|
6431 |
|
|
# Sun compiler versions before 5.6, else PIC objects from an old
|
6432 |
|
|
# archive will be linked into the output, leading to subtle bugs.
|
6433 |
|
|
if test "$solaris_use_stlport4" != yes; then
|
6434 |
|
|
_LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
|
6435 |
|
|
fi
|
6436 |
|
|
;;
|
6437 |
|
|
esac
|
6438 |
|
|
;;
|
6439 |
|
|
esac
|
6440 |
|
|
])
|
6441 |
|
|
|
6442 |
|
|
case " $_LT_TAGVAR(postdeps, $1) " in
|
6443 |
|
|
*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
|
6444 |
|
|
esac
|
6445 |
|
|
_LT_TAGDECL([], [predep_objects], [1],
|
6446 |
|
|
[Dependencies to place before and after the objects being linked to
|
6447 |
|
|
create a shared library])
|
6448 |
|
|
_LT_TAGDECL([], [postdep_objects], [1])
|
6449 |
|
|
_LT_TAGDECL([], [predeps], [1])
|
6450 |
|
|
_LT_TAGDECL([], [postdeps], [1])
|
6451 |
|
|
_LT_TAGDECL([], [compiler_lib_search_path], [1],
|
6452 |
|
|
[The library search path used internally by the compiler when linking
|
6453 |
|
|
a shared library])
|
6454 |
|
|
])# _LT_SYS_HIDDEN_LIBDEPS
|
6455 |
|
|
|
6456 |
|
|
|
6457 |
|
|
# _LT_PROG_F77
|
6458 |
|
|
# ------------
|
6459 |
|
|
# Since AC_PROG_F77 is broken, in that it returns the empty string
|
6460 |
|
|
# if there is no fortran compiler, we have our own version here.
|
6461 |
|
|
m4_defun([_LT_PROG_F77],
|
6462 |
|
|
[
|
6463 |
|
|
pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
|
6464 |
|
|
AC_PROG_F77
|
6465 |
|
|
if test -z "$F77" || test "X$F77" = "Xno"; then
|
6466 |
|
|
_lt_disable_F77=yes
|
6467 |
|
|
fi
|
6468 |
|
|
popdef([AC_MSG_ERROR])
|
6469 |
|
|
])# _LT_PROG_F77
|
6470 |
|
|
|
6471 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
6472 |
|
|
dnl AC_DEFUN([_LT_PROG_F77], [])
|
6473 |
|
|
|
6474 |
|
|
|
6475 |
|
|
# _LT_LANG_F77_CONFIG([TAG])
|
6476 |
|
|
# --------------------------
|
6477 |
|
|
# Ensure that the configuration variables for a Fortran 77 compiler are
|
6478 |
|
|
# suitably defined. These variables are subsequently used by _LT_CONFIG
|
6479 |
|
|
# to write the compiler configuration to `libtool'.
|
6480 |
|
|
m4_defun([_LT_LANG_F77_CONFIG],
|
6481 |
|
|
[AC_REQUIRE([_LT_PROG_F77])dnl
|
6482 |
|
|
AC_LANG_PUSH(Fortran 77)
|
6483 |
|
|
|
6484 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
6485 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=
|
6486 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=no
|
6487 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)=
|
6488 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
|
6489 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
6490 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
|
6491 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
|
6492 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
|
6493 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=
|
6494 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=no
|
6495 |
|
|
_LT_TAGVAR(hardcode_automatic, $1)=no
|
6496 |
|
|
_LT_TAGVAR(inherit_rpath, $1)=no
|
6497 |
|
|
_LT_TAGVAR(module_cmds, $1)=
|
6498 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)=
|
6499 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=unknown
|
6500 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
|
6501 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=
|
6502 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
6503 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
|
6504 |
|
|
|
6505 |
|
|
# Source file extension for f77 test sources.
|
6506 |
|
|
ac_ext=f
|
6507 |
|
|
|
6508 |
|
|
# Object file extension for compiled f77 test sources.
|
6509 |
|
|
objext=o
|
6510 |
|
|
_LT_TAGVAR(objext, $1)=$objext
|
6511 |
|
|
|
6512 |
|
|
# No sense in running all these tests if we already determined that
|
6513 |
|
|
# the F77 compiler isn't working. Some variables (like enable_shared)
|
6514 |
|
|
# are currently assumed to apply to all compilers on this platform,
|
6515 |
|
|
# and will be corrupted by setting them based on a non-working compiler.
|
6516 |
|
|
if test "$_lt_disable_F77" != yes; then
|
6517 |
|
|
# Code to be used in simple compile tests
|
6518 |
|
|
lt_simple_compile_test_code="\
|
6519 |
|
|
subroutine t
|
6520 |
|
|
return
|
6521 |
|
|
end
|
6522 |
|
|
"
|
6523 |
|
|
|
6524 |
|
|
# Code to be used in simple link tests
|
6525 |
|
|
lt_simple_link_test_code="\
|
6526 |
|
|
program t
|
6527 |
|
|
end
|
6528 |
|
|
"
|
6529 |
|
|
|
6530 |
|
|
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
|
6531 |
|
|
_LT_TAG_COMPILER
|
6532 |
|
|
|
6533 |
|
|
# save warnings/boilerplate of simple test code
|
6534 |
|
|
_LT_COMPILER_BOILERPLATE
|
6535 |
|
|
_LT_LINKER_BOILERPLATE
|
6536 |
|
|
|
6537 |
|
|
# Allow CC to be a program name with arguments.
|
6538 |
|
|
lt_save_CC="$CC"
|
6539 |
|
|
CC=${F77-"f77"}
|
6540 |
|
|
compiler=$CC
|
6541 |
|
|
_LT_TAGVAR(compiler, $1)=$CC
|
6542 |
|
|
_LT_CC_BASENAME([$compiler])
|
6543 |
|
|
|
6544 |
|
|
if test -n "$compiler"; then
|
6545 |
|
|
AC_MSG_CHECKING([if libtool supports shared libraries])
|
6546 |
|
|
AC_MSG_RESULT([$can_build_shared])
|
6547 |
|
|
|
6548 |
|
|
AC_MSG_CHECKING([whether to build shared libraries])
|
6549 |
|
|
test "$can_build_shared" = "no" && enable_shared=no
|
6550 |
|
|
|
6551 |
|
|
# On AIX, shared libraries and static libraries use the same namespace, and
|
6552 |
|
|
# are all built from PIC.
|
6553 |
|
|
case $host_os in
|
6554 |
|
|
aix3*)
|
6555 |
|
|
test "$enable_shared" = yes && enable_static=no
|
6556 |
|
|
if test -n "$RANLIB"; then
|
6557 |
|
|
archive_cmds="$archive_cmds~\$RANLIB \$lib"
|
6558 |
|
|
postinstall_cmds='$RANLIB $lib'
|
6559 |
|
|
fi
|
6560 |
|
|
;;
|
6561 |
|
|
aix[[4-9]]*)
|
6562 |
|
|
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
|
6563 |
|
|
test "$enable_shared" = yes && enable_static=no
|
6564 |
|
|
fi
|
6565 |
|
|
;;
|
6566 |
|
|
esac
|
6567 |
|
|
AC_MSG_RESULT([$enable_shared])
|
6568 |
|
|
|
6569 |
|
|
AC_MSG_CHECKING([whether to build static libraries])
|
6570 |
|
|
# Make sure either enable_shared or enable_static is yes.
|
6571 |
|
|
test "$enable_shared" = yes || enable_static=yes
|
6572 |
|
|
AC_MSG_RESULT([$enable_static])
|
6573 |
|
|
|
6574 |
|
|
_LT_TAGVAR(GCC, $1)="$G77"
|
6575 |
|
|
_LT_TAGVAR(LD, $1)="$LD"
|
6576 |
|
|
|
6577 |
|
|
## CAVEAT EMPTOR:
|
6578 |
|
|
## There is no encapsulation within the following macros, do not change
|
6579 |
|
|
## the running order or otherwise move them around unless you know exactly
|
6580 |
|
|
## what you are doing...
|
6581 |
|
|
_LT_COMPILER_PIC($1)
|
6582 |
|
|
_LT_COMPILER_C_O($1)
|
6583 |
|
|
_LT_COMPILER_FILE_LOCKS($1)
|
6584 |
|
|
_LT_LINKER_SHLIBS($1)
|
6585 |
|
|
_LT_SYS_DYNAMIC_LINKER($1)
|
6586 |
|
|
_LT_LINKER_HARDCODE_LIBPATH($1)
|
6587 |
|
|
|
6588 |
|
|
_LT_CONFIG($1)
|
6589 |
|
|
fi # test -n "$compiler"
|
6590 |
|
|
|
6591 |
|
|
CC="$lt_save_CC"
|
6592 |
|
|
fi # test "$_lt_disable_F77" != yes
|
6593 |
|
|
|
6594 |
|
|
AC_LANG_POP
|
6595 |
|
|
])# _LT_LANG_F77_CONFIG
|
6596 |
|
|
|
6597 |
|
|
|
6598 |
|
|
# _LT_PROG_FC
|
6599 |
|
|
# -----------
|
6600 |
|
|
# Since AC_PROG_FC is broken, in that it returns the empty string
|
6601 |
|
|
# if there is no fortran compiler, we have our own version here.
|
6602 |
|
|
m4_defun([_LT_PROG_FC],
|
6603 |
|
|
[
|
6604 |
|
|
pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
|
6605 |
|
|
AC_PROG_FC
|
6606 |
|
|
if test -z "$FC" || test "X$FC" = "Xno"; then
|
6607 |
|
|
_lt_disable_FC=yes
|
6608 |
|
|
fi
|
6609 |
|
|
popdef([AC_MSG_ERROR])
|
6610 |
|
|
])# _LT_PROG_FC
|
6611 |
|
|
|
6612 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
6613 |
|
|
dnl AC_DEFUN([_LT_PROG_FC], [])
|
6614 |
|
|
|
6615 |
|
|
|
6616 |
|
|
# _LT_LANG_FC_CONFIG([TAG])
|
6617 |
|
|
# -------------------------
|
6618 |
|
|
# Ensure that the configuration variables for a Fortran compiler are
|
6619 |
|
|
# suitably defined. These variables are subsequently used by _LT_CONFIG
|
6620 |
|
|
# to write the compiler configuration to `libtool'.
|
6621 |
|
|
m4_defun([_LT_LANG_FC_CONFIG],
|
6622 |
|
|
[AC_REQUIRE([_LT_PROG_FC])dnl
|
6623 |
|
|
AC_LANG_PUSH(Fortran)
|
6624 |
|
|
|
6625 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
6626 |
|
|
_LT_TAGVAR(allow_undefined_flag, $1)=
|
6627 |
|
|
_LT_TAGVAR(always_export_symbols, $1)=no
|
6628 |
|
|
_LT_TAGVAR(archive_expsym_cmds, $1)=
|
6629 |
|
|
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
|
6630 |
|
|
_LT_TAGVAR(hardcode_direct, $1)=no
|
6631 |
|
|
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
|
6632 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
|
6633 |
|
|
_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
|
6634 |
|
|
_LT_TAGVAR(hardcode_libdir_separator, $1)=
|
6635 |
|
|
_LT_TAGVAR(hardcode_minus_L, $1)=no
|
6636 |
|
|
_LT_TAGVAR(hardcode_automatic, $1)=no
|
6637 |
|
|
_LT_TAGVAR(inherit_rpath, $1)=no
|
6638 |
|
|
_LT_TAGVAR(module_cmds, $1)=
|
6639 |
|
|
_LT_TAGVAR(module_expsym_cmds, $1)=
|
6640 |
|
|
_LT_TAGVAR(link_all_deplibs, $1)=unknown
|
6641 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
|
6642 |
|
|
_LT_TAGVAR(no_undefined_flag, $1)=
|
6643 |
|
|
_LT_TAGVAR(whole_archive_flag_spec, $1)=
|
6644 |
|
|
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
|
6645 |
|
|
|
6646 |
|
|
# Source file extension for fc test sources.
|
6647 |
|
|
ac_ext=${ac_fc_srcext-f}
|
6648 |
|
|
|
6649 |
|
|
# Object file extension for compiled fc test sources.
|
6650 |
|
|
objext=o
|
6651 |
|
|
_LT_TAGVAR(objext, $1)=$objext
|
6652 |
|
|
|
6653 |
|
|
# No sense in running all these tests if we already determined that
|
6654 |
|
|
# the FC compiler isn't working. Some variables (like enable_shared)
|
6655 |
|
|
# are currently assumed to apply to all compilers on this platform,
|
6656 |
|
|
# and will be corrupted by setting them based on a non-working compiler.
|
6657 |
|
|
if test "$_lt_disable_FC" != yes; then
|
6658 |
|
|
# Code to be used in simple compile tests
|
6659 |
|
|
lt_simple_compile_test_code="\
|
6660 |
|
|
subroutine t
|
6661 |
|
|
return
|
6662 |
|
|
end
|
6663 |
|
|
"
|
6664 |
|
|
|
6665 |
|
|
# Code to be used in simple link tests
|
6666 |
|
|
lt_simple_link_test_code="\
|
6667 |
|
|
program t
|
6668 |
|
|
end
|
6669 |
|
|
"
|
6670 |
|
|
|
6671 |
|
|
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
|
6672 |
|
|
_LT_TAG_COMPILER
|
6673 |
|
|
|
6674 |
|
|
# save warnings/boilerplate of simple test code
|
6675 |
|
|
_LT_COMPILER_BOILERPLATE
|
6676 |
|
|
_LT_LINKER_BOILERPLATE
|
6677 |
|
|
|
6678 |
|
|
# Allow CC to be a program name with arguments.
|
6679 |
|
|
lt_save_CC="$CC"
|
6680 |
|
|
CC=${FC-"f95"}
|
6681 |
|
|
compiler=$CC
|
6682 |
|
|
_LT_TAGVAR(compiler, $1)=$CC
|
6683 |
|
|
_LT_CC_BASENAME([$compiler])
|
6684 |
|
|
|
6685 |
|
|
if test -n "$compiler"; then
|
6686 |
|
|
AC_MSG_CHECKING([if libtool supports shared libraries])
|
6687 |
|
|
AC_MSG_RESULT([$can_build_shared])
|
6688 |
|
|
|
6689 |
|
|
AC_MSG_CHECKING([whether to build shared libraries])
|
6690 |
|
|
test "$can_build_shared" = "no" && enable_shared=no
|
6691 |
|
|
|
6692 |
|
|
# On AIX, shared libraries and static libraries use the same namespace, and
|
6693 |
|
|
# are all built from PIC.
|
6694 |
|
|
case $host_os in
|
6695 |
|
|
aix3*)
|
6696 |
|
|
test "$enable_shared" = yes && enable_static=no
|
6697 |
|
|
if test -n "$RANLIB"; then
|
6698 |
|
|
archive_cmds="$archive_cmds~\$RANLIB \$lib"
|
6699 |
|
|
postinstall_cmds='$RANLIB $lib'
|
6700 |
|
|
fi
|
6701 |
|
|
;;
|
6702 |
|
|
aix[[4-9]]*)
|
6703 |
|
|
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
|
6704 |
|
|
test "$enable_shared" = yes && enable_static=no
|
6705 |
|
|
fi
|
6706 |
|
|
;;
|
6707 |
|
|
esac
|
6708 |
|
|
AC_MSG_RESULT([$enable_shared])
|
6709 |
|
|
|
6710 |
|
|
AC_MSG_CHECKING([whether to build static libraries])
|
6711 |
|
|
# Make sure either enable_shared or enable_static is yes.
|
6712 |
|
|
test "$enable_shared" = yes || enable_static=yes
|
6713 |
|
|
AC_MSG_RESULT([$enable_static])
|
6714 |
|
|
|
6715 |
|
|
_LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
|
6716 |
|
|
_LT_TAGVAR(LD, $1)="$LD"
|
6717 |
|
|
|
6718 |
|
|
## CAVEAT EMPTOR:
|
6719 |
|
|
## There is no encapsulation within the following macros, do not change
|
6720 |
|
|
## the running order or otherwise move them around unless you know exactly
|
6721 |
|
|
## what you are doing...
|
6722 |
|
|
_LT_SYS_HIDDEN_LIBDEPS($1)
|
6723 |
|
|
_LT_COMPILER_PIC($1)
|
6724 |
|
|
_LT_COMPILER_C_O($1)
|
6725 |
|
|
_LT_COMPILER_FILE_LOCKS($1)
|
6726 |
|
|
_LT_LINKER_SHLIBS($1)
|
6727 |
|
|
_LT_SYS_DYNAMIC_LINKER($1)
|
6728 |
|
|
_LT_LINKER_HARDCODE_LIBPATH($1)
|
6729 |
|
|
|
6730 |
|
|
_LT_CONFIG($1)
|
6731 |
|
|
fi # test -n "$compiler"
|
6732 |
|
|
|
6733 |
|
|
CC="$lt_save_CC"
|
6734 |
|
|
fi # test "$_lt_disable_FC" != yes
|
6735 |
|
|
|
6736 |
|
|
AC_LANG_POP
|
6737 |
|
|
])# _LT_LANG_FC_CONFIG
|
6738 |
|
|
|
6739 |
|
|
|
6740 |
|
|
# _LT_LANG_GCJ_CONFIG([TAG])
|
6741 |
|
|
# --------------------------
|
6742 |
|
|
# Ensure that the configuration variables for the GNU Java Compiler compiler
|
6743 |
|
|
# are suitably defined. These variables are subsequently used by _LT_CONFIG
|
6744 |
|
|
# to write the compiler configuration to `libtool'.
|
6745 |
|
|
m4_defun([_LT_LANG_GCJ_CONFIG],
|
6746 |
|
|
[AC_REQUIRE([LT_PROG_GCJ])dnl
|
6747 |
|
|
AC_LANG_SAVE
|
6748 |
|
|
|
6749 |
|
|
# Source file extension for Java test sources.
|
6750 |
|
|
ac_ext=java
|
6751 |
|
|
|
6752 |
|
|
# Object file extension for compiled Java test sources.
|
6753 |
|
|
objext=o
|
6754 |
|
|
_LT_TAGVAR(objext, $1)=$objext
|
6755 |
|
|
|
6756 |
|
|
# Code to be used in simple compile tests
|
6757 |
|
|
lt_simple_compile_test_code="class foo {}"
|
6758 |
|
|
|
6759 |
|
|
# Code to be used in simple link tests
|
6760 |
|
|
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
|
6761 |
|
|
|
6762 |
|
|
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
|
6763 |
|
|
_LT_TAG_COMPILER
|
6764 |
|
|
|
6765 |
|
|
# save warnings/boilerplate of simple test code
|
6766 |
|
|
_LT_COMPILER_BOILERPLATE
|
6767 |
|
|
_LT_LINKER_BOILERPLATE
|
6768 |
|
|
|
6769 |
|
|
# Allow CC to be a program name with arguments.
|
6770 |
|
|
lt_save_CC="$CC"
|
6771 |
|
|
CC=${GCJ-"gcj"}
|
6772 |
|
|
compiler=$CC
|
6773 |
|
|
_LT_TAGVAR(compiler, $1)=$CC
|
6774 |
|
|
_LT_CC_BASENAME([$compiler])
|
6775 |
|
|
|
6776 |
|
|
# GCJ did not exist at the time GCC didn't implicitly link libc in.
|
6777 |
|
|
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
|
6778 |
|
|
|
6779 |
|
|
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
|
6780 |
|
|
|
6781 |
|
|
## CAVEAT EMPTOR:
|
6782 |
|
|
## There is no encapsulation within the following macros, do not change
|
6783 |
|
|
## the running order or otherwise move them around unless you know exactly
|
6784 |
|
|
## what you are doing...
|
6785 |
|
|
if test -n "$compiler"; then
|
6786 |
|
|
_LT_COMPILER_NO_RTTI($1)
|
6787 |
|
|
_LT_COMPILER_PIC($1)
|
6788 |
|
|
_LT_COMPILER_C_O($1)
|
6789 |
|
|
_LT_COMPILER_FILE_LOCKS($1)
|
6790 |
|
|
_LT_LINKER_SHLIBS($1)
|
6791 |
|
|
_LT_SYS_DYNAMIC_LINKER($1)
|
6792 |
|
|
_LT_LINKER_HARDCODE_LIBPATH($1)
|
6793 |
|
|
|
6794 |
|
|
_LT_CONFIG($1)
|
6795 |
|
|
fi
|
6796 |
|
|
|
6797 |
|
|
AC_LANG_RESTORE
|
6798 |
|
|
CC="$lt_save_CC"
|
6799 |
|
|
])# _LT_LANG_GCJ_CONFIG
|
6800 |
|
|
|
6801 |
|
|
|
6802 |
|
|
# _LT_LANG_RC_CONFIG([TAG])
|
6803 |
|
|
# -------------------------
|
6804 |
|
|
# Ensure that the configuration variables for the Windows resource compiler
|
6805 |
|
|
# are suitably defined. These variables are subsequently used by _LT_CONFIG
|
6806 |
|
|
# to write the compiler configuration to `libtool'.
|
6807 |
|
|
m4_defun([_LT_LANG_RC_CONFIG],
|
6808 |
|
|
[AC_REQUIRE([LT_PROG_RC])dnl
|
6809 |
|
|
AC_LANG_SAVE
|
6810 |
|
|
|
6811 |
|
|
# Source file extension for RC test sources.
|
6812 |
|
|
ac_ext=rc
|
6813 |
|
|
|
6814 |
|
|
# Object file extension for compiled RC test sources.
|
6815 |
|
|
objext=o
|
6816 |
|
|
_LT_TAGVAR(objext, $1)=$objext
|
6817 |
|
|
|
6818 |
|
|
# Code to be used in simple compile tests
|
6819 |
|
|
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
|
6820 |
|
|
|
6821 |
|
|
# Code to be used in simple link tests
|
6822 |
|
|
lt_simple_link_test_code="$lt_simple_compile_test_code"
|
6823 |
|
|
|
6824 |
|
|
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
|
6825 |
|
|
_LT_TAG_COMPILER
|
6826 |
|
|
|
6827 |
|
|
# save warnings/boilerplate of simple test code
|
6828 |
|
|
_LT_COMPILER_BOILERPLATE
|
6829 |
|
|
_LT_LINKER_BOILERPLATE
|
6830 |
|
|
|
6831 |
|
|
# Allow CC to be a program name with arguments.
|
6832 |
|
|
lt_save_CC="$CC"
|
6833 |
|
|
CC=${RC-"windres"}
|
6834 |
|
|
compiler=$CC
|
6835 |
|
|
_LT_TAGVAR(compiler, $1)=$CC
|
6836 |
|
|
_LT_CC_BASENAME([$compiler])
|
6837 |
|
|
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
|
6838 |
|
|
|
6839 |
|
|
if test -n "$compiler"; then
|
6840 |
|
|
:
|
6841 |
|
|
_LT_CONFIG($1)
|
6842 |
|
|
fi
|
6843 |
|
|
|
6844 |
|
|
AC_LANG_RESTORE
|
6845 |
|
|
CC="$lt_save_CC"
|
6846 |
|
|
])# _LT_LANG_RC_CONFIG
|
6847 |
|
|
|
6848 |
|
|
|
6849 |
|
|
# LT_PROG_GCJ
|
6850 |
|
|
# -----------
|
6851 |
|
|
AC_DEFUN([LT_PROG_GCJ],
|
6852 |
|
|
[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
|
6853 |
|
|
[m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
|
6854 |
|
|
[AC_CHECK_TOOL(GCJ, gcj,)
|
6855 |
|
|
test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
|
6856 |
|
|
AC_SUBST(GCJFLAGS)])])[]dnl
|
6857 |
|
|
])
|
6858 |
|
|
|
6859 |
|
|
# Old name:
|
6860 |
|
|
AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
|
6861 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
6862 |
|
|
dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
|
6863 |
|
|
|
6864 |
|
|
|
6865 |
|
|
# LT_PROG_RC
|
6866 |
|
|
# ----------
|
6867 |
|
|
AC_DEFUN([LT_PROG_RC],
|
6868 |
|
|
[AC_CHECK_TOOL(RC, windres,)
|
6869 |
|
|
])
|
6870 |
|
|
|
6871 |
|
|
# Old name:
|
6872 |
|
|
AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
|
6873 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
6874 |
|
|
dnl AC_DEFUN([LT_AC_PROG_RC], [])
|
6875 |
|
|
|
6876 |
|
|
|
6877 |
|
|
# _LT_DECL_EGREP
|
6878 |
|
|
# --------------
|
6879 |
|
|
# If we don't have a new enough Autoconf to choose the best grep
|
6880 |
|
|
# available, choose the one first in the user's PATH.
|
6881 |
|
|
m4_defun([_LT_DECL_EGREP],
|
6882 |
|
|
[AC_REQUIRE([AC_PROG_EGREP])dnl
|
6883 |
|
|
AC_REQUIRE([AC_PROG_FGREP])dnl
|
6884 |
|
|
test -z "$GREP" && GREP=grep
|
6885 |
|
|
_LT_DECL([], [GREP], [1], [A grep program that handles long lines])
|
6886 |
|
|
_LT_DECL([], [EGREP], [1], [An ERE matcher])
|
6887 |
|
|
_LT_DECL([], [FGREP], [1], [A literal string matcher])
|
6888 |
|
|
dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
|
6889 |
|
|
AC_SUBST([GREP])
|
6890 |
|
|
])
|
6891 |
|
|
|
6892 |
|
|
|
6893 |
|
|
# _LT_DECL_SED
|
6894 |
|
|
# ------------
|
6895 |
|
|
# Check for a fully-functional sed program, that truncates
|
6896 |
|
|
# as few characters as possible. Prefer GNU sed if found.
|
6897 |
|
|
m4_defun([_LT_DECL_SED],
|
6898 |
|
|
[AC_PROG_SED
|
6899 |
|
|
test -z "$SED" && SED=sed
|
6900 |
|
|
Xsed="$SED -e 1s/^X//"
|
6901 |
|
|
_LT_DECL([], [SED], [1], [A sed program that does not truncate output])
|
6902 |
|
|
_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
|
6903 |
|
|
[Sed that helps us avoid accidentally triggering echo(1) options like -n])
|
6904 |
|
|
])# _LT_DECL_SED
|
6905 |
|
|
|
6906 |
|
|
m4_ifndef([AC_PROG_SED], [
|
6907 |
|
|
############################################################
|
6908 |
|
|
# NOTE: This macro has been submitted for inclusion into #
|
6909 |
|
|
# GNU Autoconf as AC_PROG_SED. When it is available in #
|
6910 |
|
|
# a released version of Autoconf we should remove this #
|
6911 |
|
|
# macro and use it instead. #
|
6912 |
|
|
############################################################
|
6913 |
|
|
|
6914 |
|
|
m4_defun([AC_PROG_SED],
|
6915 |
|
|
[AC_MSG_CHECKING([for a sed that does not truncate output])
|
6916 |
|
|
AC_CACHE_VAL(lt_cv_path_SED,
|
6917 |
|
|
[# Loop through the user's path and test for sed and gsed.
|
6918 |
|
|
# Then use that list of sed's as ones to test for truncation.
|
6919 |
|
|
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
6920 |
|
|
for as_dir in $PATH
|
6921 |
|
|
do
|
6922 |
|
|
IFS=$as_save_IFS
|
6923 |
|
|
test -z "$as_dir" && as_dir=.
|
6924 |
|
|
for lt_ac_prog in sed gsed; do
|
6925 |
|
|
for ac_exec_ext in '' $ac_executable_extensions; do
|
6926 |
|
|
if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
|
6927 |
|
|
lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
|
6928 |
|
|
fi
|
6929 |
|
|
done
|
6930 |
|
|
done
|
6931 |
|
|
done
|
6932 |
|
|
IFS=$as_save_IFS
|
6933 |
|
|
lt_ac_max=0
|
6934 |
|
|
lt_ac_count=0
|
6935 |
|
|
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
|
6936 |
|
|
# along with /bin/sed that truncates output.
|
6937 |
|
|
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
|
6938 |
|
|
test ! -f $lt_ac_sed && continue
|
6939 |
|
|
cat /dev/null > conftest.in
|
6940 |
|
|
lt_ac_count=0
|
6941 |
|
|
echo $ECHO_N "0123456789$ECHO_C" >conftest.in
|
6942 |
|
|
# Check for GNU sed and select it if it is found.
|
6943 |
|
|
if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
|
6944 |
|
|
lt_cv_path_SED=$lt_ac_sed
|
6945 |
|
|
break
|
6946 |
|
|
fi
|
6947 |
|
|
while true; do
|
6948 |
|
|
cat conftest.in conftest.in >conftest.tmp
|
6949 |
|
|
mv conftest.tmp conftest.in
|
6950 |
|
|
cp conftest.in conftest.nl
|
6951 |
|
|
echo >>conftest.nl
|
6952 |
|
|
$lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
|
6953 |
|
|
cmp -s conftest.out conftest.nl || break
|
6954 |
|
|
# 10000 chars as input seems more than enough
|
6955 |
|
|
test $lt_ac_count -gt 10 && break
|
6956 |
|
|
lt_ac_count=`expr $lt_ac_count + 1`
|
6957 |
|
|
if test $lt_ac_count -gt $lt_ac_max; then
|
6958 |
|
|
lt_ac_max=$lt_ac_count
|
6959 |
|
|
lt_cv_path_SED=$lt_ac_sed
|
6960 |
|
|
fi
|
6961 |
|
|
done
|
6962 |
|
|
done
|
6963 |
|
|
])
|
6964 |
|
|
SED=$lt_cv_path_SED
|
6965 |
|
|
AC_SUBST([SED])
|
6966 |
|
|
AC_MSG_RESULT([$SED])
|
6967 |
|
|
])#AC_PROG_SED
|
6968 |
|
|
])#m4_ifndef
|
6969 |
|
|
|
6970 |
|
|
# Old name:
|
6971 |
|
|
AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
|
6972 |
|
|
dnl aclocal-1.4 backwards compatibility:
|
6973 |
|
|
dnl AC_DEFUN([LT_AC_PROG_SED], [])
|
6974 |
|
|
|
6975 |
|
|
|
6976 |
|
|
# _LT_CHECK_SHELL_FEATURES
|
6977 |
|
|
# ------------------------
|
6978 |
|
|
# Find out whether the shell is Bourne or XSI compatible,
|
6979 |
|
|
# or has some other useful features.
|
6980 |
|
|
m4_defun([_LT_CHECK_SHELL_FEATURES],
|
6981 |
|
|
[AC_MSG_CHECKING([whether the shell understands some XSI constructs])
|
6982 |
|
|
# Try some XSI features
|
6983 |
|
|
xsi_shell=no
|
6984 |
|
|
( _lt_dummy="a/b/c"
|
6985 |
|
|
test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
|
6986 |
|
|
= c,a/b,, ) >/dev/null 2>&1 \
|
6987 |
|
|
&& xsi_shell=yes
|
6988 |
|
|
AC_MSG_RESULT([$xsi_shell])
|
6989 |
|
|
_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
|
6990 |
|
|
|
6991 |
|
|
AC_MSG_CHECKING([whether the shell understands "+="])
|
6992 |
|
|
lt_shell_append=no
|
6993 |
|
|
( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
|
6994 |
|
|
>/dev/null 2>&1 \
|
6995 |
|
|
&& lt_shell_append=yes
|
6996 |
|
|
AC_MSG_RESULT([$lt_shell_append])
|
6997 |
|
|
_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
|
6998 |
|
|
|
6999 |
|
|
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
|
7000 |
|
|
lt_unset=unset
|
7001 |
|
|
else
|
7002 |
|
|
lt_unset=false
|
7003 |
|
|
fi
|
7004 |
|
|
_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
|
7005 |
|
|
|
7006 |
|
|
# test EBCDIC or ASCII
|
7007 |
|
|
case `echo X|tr X '\101'` in
|
7008 |
|
|
A) # ASCII based system
|
7009 |
|
|
# \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
|
7010 |
|
|
lt_SP2NL='tr \040 \012'
|
7011 |
|
|
lt_NL2SP='tr \015\012 \040\040'
|
7012 |
|
|
;;
|
7013 |
|
|
*) # EBCDIC based system
|
7014 |
|
|
lt_SP2NL='tr \100 \n'
|
7015 |
|
|
lt_NL2SP='tr \r\n \100\100'
|
7016 |
|
|
;;
|
7017 |
|
|
esac
|
7018 |
|
|
_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
|
7019 |
|
|
_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
|
7020 |
|
|
])# _LT_CHECK_SHELL_FEATURES
|
7021 |
|
|
|
7022 |
|
|
|
7023 |
|
|
# _LT_PROG_XSI_SHELLFNS
|
7024 |
|
|
# ---------------------
|
7025 |
|
|
# Bourne and XSI compatible variants of some useful shell functions.
|
7026 |
|
|
m4_defun([_LT_PROG_XSI_SHELLFNS],
|
7027 |
|
|
[case $xsi_shell in
|
7028 |
|
|
yes)
|
7029 |
|
|
cat << \_LT_EOF >> "$cfgfile"
|
7030 |
|
|
# func_dirname file append nondir_replacement
|
7031 |
|
|
# Compute the dirname of FILE. If nonempty, add APPEND to the result,
|
7032 |
|
|
# otherwise set result to NONDIR_REPLACEMENT.
|
7033 |
|
|
func_dirname ()
|
7034 |
|
|
{
|
7035 |
|
|
case ${1} in
|
7036 |
|
|
*/*) func_dirname_result="${1%/*}${2}" ;;
|
7037 |
|
|
* ) func_dirname_result="${3}" ;;
|
7038 |
|
|
esac
|
7039 |
|
|
}
|
7040 |
|
|
|
7041 |
|
|
# func_basename file
|
7042 |
|
|
func_basename ()
|
7043 |
|
|
{
|
7044 |
|
|
func_basename_result="${1##*/}"
|
7045 |
|
|
}
|
7046 |
|
|
|
7047 |
|
|
# func_stripname prefix suffix name
|
7048 |
|
|
# strip PREFIX and SUFFIX off of NAME.
|
7049 |
|
|
# PREFIX and SUFFIX must not contain globbing or regex special
|
7050 |
|
|
# characters, hashes, percent signs, but SUFFIX may contain a leading
|
7051 |
|
|
# dot (in which case that matches only a dot).
|
7052 |
|
|
func_stripname ()
|
7053 |
|
|
{
|
7054 |
|
|
# pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
|
7055 |
|
|
# positional parameters, so assign one to ordinary parameter first.
|
7056 |
|
|
func_stripname_result=${3}
|
7057 |
|
|
func_stripname_result=${func_stripname_result#"${1}"}
|
7058 |
|
|
func_stripname_result=${func_stripname_result%"${2}"}
|
7059 |
|
|
}
|
7060 |
|
|
|
7061 |
|
|
# func_opt_split
|
7062 |
|
|
func_opt_split ()
|
7063 |
|
|
{
|
7064 |
|
|
func_opt_split_opt=${1%%=*}
|
7065 |
|
|
func_opt_split_arg=${1#*=}
|
7066 |
|
|
}
|
7067 |
|
|
|
7068 |
|
|
# func_lo2o object
|
7069 |
|
|
func_lo2o ()
|
7070 |
|
|
{
|
7071 |
|
|
case ${1} in
|
7072 |
|
|
*.lo) func_lo2o_result=${1%.lo}.${objext} ;;
|
7073 |
|
|
*) func_lo2o_result=${1} ;;
|
7074 |
|
|
esac
|
7075 |
|
|
}
|
7076 |
|
|
_LT_EOF
|
7077 |
|
|
;;
|
7078 |
|
|
*) # Bourne compatible functions.
|
7079 |
|
|
cat << \_LT_EOF >> "$cfgfile"
|
7080 |
|
|
# func_dirname file append nondir_replacement
|
7081 |
|
|
# Compute the dirname of FILE. If nonempty, add APPEND to the result,
|
7082 |
|
|
# otherwise set result to NONDIR_REPLACEMENT.
|
7083 |
|
|
func_dirname ()
|
7084 |
|
|
{
|
7085 |
|
|
# Extract subdirectory from the argument.
|
7086 |
|
|
func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
|
7087 |
|
|
if test "X$func_dirname_result" = "X${1}"; then
|
7088 |
|
|
func_dirname_result="${3}"
|
7089 |
|
|
else
|
7090 |
|
|
func_dirname_result="$func_dirname_result${2}"
|
7091 |
|
|
fi
|
7092 |
|
|
}
|
7093 |
|
|
|
7094 |
|
|
# func_basename file
|
7095 |
|
|
func_basename ()
|
7096 |
|
|
{
|
7097 |
|
|
func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
|
7098 |
|
|
}
|
7099 |
|
|
|
7100 |
|
|
# func_stripname prefix suffix name
|
7101 |
|
|
# strip PREFIX and SUFFIX off of NAME.
|
7102 |
|
|
# PREFIX and SUFFIX must not contain globbing or regex special
|
7103 |
|
|
# characters, hashes, percent signs, but SUFFIX may contain a leading
|
7104 |
|
|
# dot (in which case that matches only a dot).
|
7105 |
|
|
# func_strip_suffix prefix name
|
7106 |
|
|
func_stripname ()
|
7107 |
|
|
{
|
7108 |
|
|
case ${2} in
|
7109 |
|
|
.*) func_stripname_result=`$ECHO "X${3}" \
|
7110 |
|
|
| $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
|
7111 |
|
|
*) func_stripname_result=`$ECHO "X${3}" \
|
7112 |
|
|
| $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
|
7113 |
|
|
esac
|
7114 |
|
|
}
|
7115 |
|
|
|
7116 |
|
|
# sed scripts:
|
7117 |
|
|
my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
|
7118 |
|
|
my_sed_long_arg='1s/^-[[^=]]*=//'
|
7119 |
|
|
|
7120 |
|
|
# func_opt_split
|
7121 |
|
|
func_opt_split ()
|
7122 |
|
|
{
|
7123 |
|
|
func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
|
7124 |
|
|
func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
|
7125 |
|
|
}
|
7126 |
|
|
|
7127 |
|
|
# func_lo2o object
|
7128 |
|
|
func_lo2o ()
|
7129 |
|
|
{
|
7130 |
|
|
func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
|
7131 |
|
|
}
|
7132 |
|
|
_LT_EOF
|
7133 |
|
|
esac
|
7134 |
|
|
|
7135 |
|
|
case $lt_shell_append in
|
7136 |
|
|
yes)
|
7137 |
|
|
cat << \_LT_EOF >> "$cfgfile"
|
7138 |
|
|
|
7139 |
|
|
# func_append var value
|
7140 |
|
|
# Append VALUE to the end of shell variable VAR.
|
7141 |
|
|
func_append ()
|
7142 |
|
|
{
|
7143 |
|
|
eval "$[1]+=\$[2]"
|
7144 |
|
|
}
|
7145 |
|
|
_LT_EOF
|
7146 |
|
|
;;
|
7147 |
|
|
*)
|
7148 |
|
|
cat << \_LT_EOF >> "$cfgfile"
|
7149 |
|
|
|
7150 |
|
|
# func_append var value
|
7151 |
|
|
# Append VALUE to the end of shell variable VAR.
|
7152 |
|
|
func_append ()
|
7153 |
|
|
{
|
7154 |
|
|
eval "$[1]=\$$[1]\$[2]"
|
7155 |
|
|
}
|
7156 |
|
|
_LT_EOF
|
7157 |
|
|
;;
|
7158 |
|
|
esac
|
7159 |
|
|
])
|