ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/branches/8.1.x/aclocal.m4
Revision: 2063
Committed: Thu May 16 09:55:35 2013 UTC (10 years, 10 months ago) by michael
File size: 378383 byte(s)
Log Message:
- automake 1.13.2

File Contents

# User Rev Content
1 michael 2063 # generated automatically by aclocal 1.13.2 -*- Autoconf -*-
2 michael 912
3 michael 2063 # Copyright (C) 1996-2013 Free Software Foundation, Inc.
4 michael 1425
5 michael 912 # This file is free software; the Free Software Foundation
6     # gives unlimited permission to copy and/or distribute it,
7     # with or without modifications, as long as this notice is preserved.
8    
9     # This program is distributed in the hope that it will be useful,
10     # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11     # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12     # PARTICULAR PURPOSE.
13    
14 michael 1720 m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
15 db 941 m4_ifndef([AC_AUTOCONF_VERSION],
16     [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
17 michael 1373 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
18     [m4_warning([this file was generated for autoconf 2.69.
19 db 941 You have another version of autoconf. It may work, but is not guaranteed to.
20     If you have problems, you may need to regenerate the build system entirely.
21 michael 1373 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
22 michael 912
23 michael 945 # Portability macros for glibc argz. -*- Autoconf -*-
24     #
25     # Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
26     # Written by Gary V. Vaughan <gary@gnu.org>
27     #
28     # This file is free software; the Free Software Foundation gives
29     # unlimited permission to copy and/or distribute it, with or without
30     # modifications, as long as this notice is preserved.
31    
32     # serial 5 argz.m4
33    
34     AC_DEFUN([gl_FUNC_ARGZ],
35     [gl_PREREQ_ARGZ
36    
37     AC_CHECK_HEADERS([argz.h], [], [], [AC_INCLUDES_DEFAULT])
38    
39     AC_CHECK_TYPES([error_t],
40     [],
41     [AC_DEFINE([error_t], [int],
42     [Define to a type to use for `error_t' if it is not otherwise available.])
43     AC_DEFINE([__error_t_defined], [1], [Define so that glibc/gnulib argp.h
44     does not typedef error_t.])],
45     [#if defined(HAVE_ARGZ_H)
46     # include <argz.h>
47     #endif])
48    
49     ARGZ_H=
50     AC_CHECK_FUNCS([argz_add argz_append argz_count argz_create_sep argz_insert \
51     argz_next argz_stringify], [], [ARGZ_H=argz.h; AC_LIBOBJ([argz])])
52    
53     dnl if have system argz functions, allow forced use of
54     dnl libltdl-supplied implementation (and default to do so
55     dnl on "known bad" systems). Could use a runtime check, but
56     dnl (a) detecting malloc issues is notoriously unreliable
57     dnl (b) only known system that declares argz functions,
58     dnl provides them, yet they are broken, is cygwin
59     dnl releases prior to 16-Mar-2007 (1.5.24 and earlier)
60     dnl So, it's more straightforward simply to special case
61     dnl this for known bad systems.
62     AS_IF([test -z "$ARGZ_H"],
63     [AC_CACHE_CHECK(
64     [if argz actually works],
65     [lt_cv_sys_argz_works],
66     [[case $host_os in #(
67     *cygwin*)
68     lt_cv_sys_argz_works=no
69     if test "$cross_compiling" != no; then
70     lt_cv_sys_argz_works="guessing no"
71     else
72     lt_sed_extract_leading_digits='s/^\([0-9\.]*\).*/\1/'
73     save_IFS=$IFS
74     IFS=-.
75     set x `uname -r | sed -e "$lt_sed_extract_leading_digits"`
76     IFS=$save_IFS
77     lt_os_major=${2-0}
78     lt_os_minor=${3-0}
79     lt_os_micro=${4-0}
80     if test "$lt_os_major" -gt 1 \
81     || { test "$lt_os_major" -eq 1 \
82     && { test "$lt_os_minor" -gt 5 \
83     || { test "$lt_os_minor" -eq 5 \
84     && test "$lt_os_micro" -gt 24; }; }; }; then
85     lt_cv_sys_argz_works=yes
86     fi
87     fi
88     ;; #(
89     *) lt_cv_sys_argz_works=yes ;;
90     esac]])
91 michael 1106 AS_IF([test "$lt_cv_sys_argz_works" = yes],
92 michael 945 [AC_DEFINE([HAVE_WORKING_ARGZ], 1,
93     [This value is set to 1 to indicate that the system argz facility works])],
94     [ARGZ_H=argz.h
95     AC_LIBOBJ([argz])])])
96    
97     AC_SUBST([ARGZ_H])
98     ])
99    
100     # Prerequisites of lib/argz.c.
101     AC_DEFUN([gl_PREREQ_ARGZ], [:])
102    
103 michael 912 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
104 michael 945 #
105     # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
106 michael 1257 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
107     # Foundation, Inc.
108 michael 945 # Written by Gordon Matzigkeit, 1996
109     #
110     # This file is free software; the Free Software Foundation gives
111     # unlimited permission to copy and/or distribute it, with or without
112     # modifications, as long as this notice is preserved.
113 michael 912
114 michael 945 m4_define([_LT_COPYING], [dnl
115     # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
116 michael 1257 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
117     # Foundation, Inc.
118 michael 945 # Written by Gordon Matzigkeit, 1996
119     #
120     # This file is part of GNU Libtool.
121     #
122     # GNU Libtool is free software; you can redistribute it and/or
123     # modify it under the terms of the GNU General Public License as
124     # published by the Free Software Foundation; either version 2 of
125     # the License, or (at your option) any later version.
126     #
127     # As a special exception to the GNU General Public License,
128     # if you distribute this file as part of a program or library that
129     # is built using GNU Libtool, you may include this file under the
130     # same distribution terms that you use for the rest of that program.
131     #
132     # GNU Libtool is distributed in the hope that it will be useful,
133     # but WITHOUT ANY WARRANTY; without even the implied warranty of
134     # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
135     # GNU General Public License for more details.
136     #
137     # You should have received a copy of the GNU General Public License
138     # along with GNU Libtool; see the file COPYING. If not, a copy
139     # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
140     # obtained by writing to the Free Software Foundation, Inc.,
141     # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
142     ])
143 michael 912
144 michael 1094 # serial 57 LT_INIT
145 michael 912
146    
147 michael 945 # LT_PREREQ(VERSION)
148     # ------------------
149     # Complain and exit if this libtool version is less that VERSION.
150     m4_defun([LT_PREREQ],
151     [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
152     [m4_default([$3],
153     [m4_fatal([Libtool version $1 or higher is required],
154     63)])],
155     [$2])])
156 michael 912
157    
158 michael 945 # _LT_CHECK_BUILDDIR
159     # ------------------
160     # Complain if the absolute build directory name contains unusual characters
161     m4_defun([_LT_CHECK_BUILDDIR],
162     [case `pwd` in
163     *\ * | *\ *)
164     AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
165     esac
166     ])
167 michael 912
168    
169 michael 945 # LT_INIT([OPTIONS])
170     # ------------------
171     AC_DEFUN([LT_INIT],
172     [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
173 michael 1094 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
174 michael 945 AC_BEFORE([$0], [LT_LANG])dnl
175     AC_BEFORE([$0], [LT_OUTPUT])dnl
176     AC_BEFORE([$0], [LTDL_INIT])dnl
177     m4_require([_LT_CHECK_BUILDDIR])dnl
178 michael 912
179 michael 945 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
180     m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
181     m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
182     dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
183     dnl unless we require an AC_DEFUNed macro:
184     AC_REQUIRE([LTOPTIONS_VERSION])dnl
185     AC_REQUIRE([LTSUGAR_VERSION])dnl
186     AC_REQUIRE([LTVERSION_VERSION])dnl
187     AC_REQUIRE([LTOBSOLETE_VERSION])dnl
188     m4_require([_LT_PROG_LTMAIN])dnl
189    
190 michael 1094 _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
191    
192 michael 945 dnl Parse OPTIONS
193     _LT_SET_OPTIONS([$0], [$1])
194    
195 michael 912 # This can be used to rebuild libtool when needed
196 michael 945 LIBTOOL_DEPS="$ltmain"
197 michael 912
198     # Always use our own libtool.
199     LIBTOOL='$(SHELL) $(top_builddir)/libtool'
200     AC_SUBST(LIBTOOL)dnl
201    
202 michael 945 _LT_SETUP
203 michael 912
204 michael 945 # Only expand once:
205     m4_define([LT_INIT])
206     ])# LT_INIT
207 michael 912
208 michael 945 # Old names:
209     AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
210     AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
211     dnl aclocal-1.4 backwards compatibility:
212     dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
213     dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
214    
215    
216     # _LT_CC_BASENAME(CC)
217     # -------------------
218     # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
219     m4_defun([_LT_CC_BASENAME],
220     [for cc_temp in $1""; do
221     case $cc_temp in
222     compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
223     distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
224     \-*) ;;
225     *) break;;
226     esac
227     done
228 michael 1094 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
229 michael 945 ])
230    
231    
232     # _LT_FILEUTILS_DEFAULTS
233     # ----------------------
234     # It is okay to use these file commands and assume they have been set
235     # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
236     m4_defun([_LT_FILEUTILS_DEFAULTS],
237     [: ${CP="cp -f"}
238     : ${MV="mv -f"}
239     : ${RM="rm -f"}
240     ])# _LT_FILEUTILS_DEFAULTS
241    
242    
243     # _LT_SETUP
244     # ---------
245     m4_defun([_LT_SETUP],
246     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
247 michael 912 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
248 michael 1094 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
249     AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
250    
251 michael 1257 _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
252     dnl
253 michael 945 _LT_DECL([], [host_alias], [0], [The host system])dnl
254     _LT_DECL([], [host], [0])dnl
255     _LT_DECL([], [host_os], [0])dnl
256     dnl
257     _LT_DECL([], [build_alias], [0], [The build system])dnl
258     _LT_DECL([], [build], [0])dnl
259     _LT_DECL([], [build_os], [0])dnl
260     dnl
261 michael 912 AC_REQUIRE([AC_PROG_CC])dnl
262 michael 945 AC_REQUIRE([LT_PATH_LD])dnl
263     AC_REQUIRE([LT_PATH_NM])dnl
264     dnl
265 michael 912 AC_REQUIRE([AC_PROG_LN_S])dnl
266 michael 945 test -z "$LN_S" && LN_S="ln -s"
267     _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
268 michael 912 dnl
269 michael 945 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
270     _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
271     _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
272     dnl
273     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
274     m4_require([_LT_CHECK_SHELL_FEATURES])dnl
275 michael 1106 m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
276 michael 945 m4_require([_LT_CMD_RELOAD])dnl
277     m4_require([_LT_CHECK_MAGIC_METHOD])dnl
278 michael 1106 m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
279 michael 945 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
280     m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
281 michael 1106 m4_require([_LT_WITH_SYSROOT])dnl
282 michael 912
283 michael 945 _LT_CONFIG_LIBTOOL_INIT([
284     # See if we are running on zsh, and set the options which allow our
285     # commands through without removal of \ escapes INIT.
286     if test -n "\${ZSH_VERSION+set}" ; then
287     setopt NO_GLOB_SUBST
288     fi
289     ])
290     if test -n "${ZSH_VERSION+set}" ; then
291     setopt NO_GLOB_SUBST
292     fi
293 michael 912
294 michael 945 _LT_CHECK_OBJDIR
295    
296     m4_require([_LT_TAG_COMPILER])dnl
297    
298 michael 912 case $host_os in
299     aix3*)
300     # AIX sometimes has problems with the GCC collect2 program. For some
301     # reason, if we set the COLLECT_NAMES environment variable, the problems
302     # vanish in a puff of smoke.
303     if test "X${COLLECT_NAMES+set}" != Xset; then
304     COLLECT_NAMES=
305     export COLLECT_NAMES
306     fi
307     ;;
308     esac
309    
310     # Global variables:
311 michael 945 ofile=libtool
312 michael 912 can_build_shared=yes
313    
314     # All known linkers require a `.a' archive for static linking (except MSVC,
315     # which needs '.lib').
316     libext=a
317 michael 945
318 michael 912 with_gnu_ld="$lt_cv_prog_gnu_ld"
319    
320     old_CC="$CC"
321     old_CFLAGS="$CFLAGS"
322    
323     # Set sane defaults for various variables
324     test -z "$CC" && CC=cc
325     test -z "$LTCC" && LTCC=$CC
326     test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
327     test -z "$LD" && LD=ld
328     test -z "$ac_objext" && ac_objext=o
329    
330     _LT_CC_BASENAME([$compiler])
331    
332     # Only perform the check for file, if the check method requires it
333 michael 945 test -z "$MAGIC_CMD" && MAGIC_CMD=file
334 michael 912 case $deplibs_check_method in
335     file_magic*)
336     if test "$file_magic_cmd" = '$MAGIC_CMD'; then
337 michael 945 _LT_PATH_MAGIC
338 michael 912 fi
339     ;;
340     esac
341    
342 michael 945 # Use C for the default configuration in the libtool script
343     LT_SUPPORTED_TAG([CC])
344     _LT_LANG_C_CONFIG
345     _LT_LANG_DEFAULT_CONFIG
346     _LT_CONFIG_COMMANDS
347     ])# _LT_SETUP
348 db 941
349 michael 912
350 michael 1094 # _LT_PREPARE_SED_QUOTE_VARS
351     # --------------------------
352     # Define a few sed substitution that help us do robust quoting.
353     m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
354     [# Backslashify metacharacters that are still active within
355     # double-quoted strings.
356     sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
357    
358     # Same as above, but do not quote variable references.
359     double_quote_subst='s/\([["`\\]]\)/\\\1/g'
360    
361     # Sed substitution to delay expansion of an escaped shell variable in a
362     # double_quote_subst'ed string.
363     delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
364    
365     # Sed substitution to delay expansion of an escaped single quote.
366     delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
367    
368     # Sed substitution to avoid accidental globbing in evaled expressions
369     no_glob_subst='s/\*/\\\*/g'
370     ])
371    
372 michael 945 # _LT_PROG_LTMAIN
373     # ---------------
374     # Note that this code is called both from `configure', and `config.status'
375     # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
376     # `config.status' has no value for ac_aux_dir unless we are using Automake,
377     # so we pass a copy along to make sure it has a sensible value anyway.
378     m4_defun([_LT_PROG_LTMAIN],
379     [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
380     _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
381     ltmain="$ac_aux_dir/ltmain.sh"
382     ])# _LT_PROG_LTMAIN
383 michael 912
384    
385    
386 michael 945 # So that we can recreate a full libtool script including additional
387     # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
388     # in macros and then make a single call at the end using the `libtool'
389     # label.
390 michael 912
391 michael 945
392     # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
393     # ----------------------------------------
394     # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
395     m4_define([_LT_CONFIG_LIBTOOL_INIT],
396     [m4_ifval([$1],
397     [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
398     [$1
399     ])])])
400    
401     # Initialize.
402     m4_define([_LT_OUTPUT_LIBTOOL_INIT])
403    
404    
405     # _LT_CONFIG_LIBTOOL([COMMANDS])
406     # ------------------------------
407     # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
408     m4_define([_LT_CONFIG_LIBTOOL],
409     [m4_ifval([$1],
410     [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
411     [$1
412     ])])])
413    
414     # Initialize.
415     m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
416    
417    
418     # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
419     # -----------------------------------------------------
420     m4_defun([_LT_CONFIG_SAVE_COMMANDS],
421     [_LT_CONFIG_LIBTOOL([$1])
422     _LT_CONFIG_LIBTOOL_INIT([$2])
423     ])
424    
425    
426     # _LT_FORMAT_COMMENT([COMMENT])
427     # -----------------------------
428     # Add leading comment marks to the start of each line, and a trailing
429     # full-stop to the whole comment if one is not present already.
430     m4_define([_LT_FORMAT_COMMENT],
431     [m4_ifval([$1], [
432     m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
433     [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
434     )])
435    
436    
437    
438    
439    
440     # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
441     # -------------------------------------------------------------------
442     # CONFIGNAME is the name given to the value in the libtool script.
443     # VARNAME is the (base) name used in the configure script.
444     # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
445     # VARNAME. Any other value will be used directly.
446     m4_define([_LT_DECL],
447     [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
448     [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
449     [m4_ifval([$1], [$1], [$2])])
450     lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
451     m4_ifval([$4],
452     [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
453     lt_dict_add_subkey([lt_decl_dict], [$2],
454     [tagged?], [m4_ifval([$5], [yes], [no])])])
455     ])
456    
457    
458     # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
459     # --------------------------------------------------------
460     m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
461    
462    
463     # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
464     # ------------------------------------------------
465     m4_define([lt_decl_tag_varnames],
466     [_lt_decl_filter([tagged?], [yes], $@)])
467    
468    
469     # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
470     # ---------------------------------------------------------
471     m4_define([_lt_decl_filter],
472     [m4_case([$#],
473     [0], [m4_fatal([$0: too few arguments: $#])],
474     [1], [m4_fatal([$0: too few arguments: $#: $1])],
475     [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
476     [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
477     [lt_dict_filter([lt_decl_dict], $@)])[]dnl
478     ])
479    
480    
481     # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
482     # --------------------------------------------------
483     m4_define([lt_decl_quote_varnames],
484     [_lt_decl_filter([value], [1], $@)])
485    
486    
487     # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
488     # ---------------------------------------------------
489     m4_define([lt_decl_dquote_varnames],
490     [_lt_decl_filter([value], [2], $@)])
491    
492    
493     # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
494     # ---------------------------------------------------
495     m4_define([lt_decl_varnames_tagged],
496     [m4_assert([$# <= 2])dnl
497     _$0(m4_quote(m4_default([$1], [[, ]])),
498     m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
499     m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
500     m4_define([_lt_decl_varnames_tagged],
501     [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
502    
503    
504     # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
505     # ------------------------------------------------
506     m4_define([lt_decl_all_varnames],
507     [_$0(m4_quote(m4_default([$1], [[, ]])),
508     m4_if([$2], [],
509     m4_quote(lt_decl_varnames),
510     m4_quote(m4_shift($@))))[]dnl
511     ])
512     m4_define([_lt_decl_all_varnames],
513     [lt_join($@, lt_decl_varnames_tagged([$1],
514     lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
515     ])
516    
517    
518     # _LT_CONFIG_STATUS_DECLARE([VARNAME])
519     # ------------------------------------
520     # Quote a variable value, and forward it to `config.status' so that its
521     # declaration there will have the same value as in `configure'. VARNAME
522     # must have a single quote delimited value for this to work.
523     m4_define([_LT_CONFIG_STATUS_DECLARE],
524 michael 1094 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
525 michael 945
526    
527     # _LT_CONFIG_STATUS_DECLARATIONS
528     # ------------------------------
529     # We delimit libtool config variables with single quotes, so when
530     # we write them to config.status, we have to be sure to quote all
531     # embedded single quotes properly. In configure, this macro expands
532     # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
533     #
534 michael 1094 # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
535 michael 945 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
536     [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
537     [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
538    
539    
540     # _LT_LIBTOOL_TAGS
541     # ----------------
542     # Output comment and list of tags supported by the script
543     m4_defun([_LT_LIBTOOL_TAGS],
544     [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
545     available_tags="_LT_TAGS"dnl
546     ])
547    
548    
549     # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
550     # -----------------------------------
551     # Extract the dictionary values for VARNAME (optionally with TAG) and
552     # expand to a commented shell variable setting:
553     #
554     # # Some comment about what VAR is for.
555     # visible_name=$lt_internal_name
556     m4_define([_LT_LIBTOOL_DECLARE],
557     [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
558     [description])))[]dnl
559     m4_pushdef([_libtool_name],
560     m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
561     m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
562     [0], [_libtool_name=[$]$1],
563     [1], [_libtool_name=$lt_[]$1],
564     [2], [_libtool_name=$lt_[]$1],
565     [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
566     m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
567     ])
568    
569    
570     # _LT_LIBTOOL_CONFIG_VARS
571     # -----------------------
572     # Produce commented declarations of non-tagged libtool config variables
573     # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
574     # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
575     # section) are produced by _LT_LIBTOOL_TAG_VARS.
576     m4_defun([_LT_LIBTOOL_CONFIG_VARS],
577     [m4_foreach([_lt_var],
578     m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
579     [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
580    
581    
582     # _LT_LIBTOOL_TAG_VARS(TAG)
583     # -------------------------
584     m4_define([_LT_LIBTOOL_TAG_VARS],
585     [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
586     [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
587    
588    
589     # _LT_TAGVAR(VARNAME, [TAGNAME])
590     # ------------------------------
591     m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
592    
593    
594     # _LT_CONFIG_COMMANDS
595 michael 912 # -------------------
596 michael 945 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
597     # variables for single and double quote escaping we saved from calls
598     # to _LT_DECL, we can put quote escaped variables declarations
599     # into `config.status', and then the shell code to quote escape them in
600     # for loops in `config.status'. Finally, any additional code accumulated
601     # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
602     m4_defun([_LT_CONFIG_COMMANDS],
603     [AC_PROVIDE_IFELSE([LT_OUTPUT],
604     dnl If the libtool generation code has been placed in $CONFIG_LT,
605     dnl instead of duplicating it all over again into config.status,
606     dnl then we will have config.status run $CONFIG_LT later, so it
607     dnl needs to know what name is stored there:
608     [AC_CONFIG_COMMANDS([libtool],
609     [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
610     dnl If the libtool generation code is destined for config.status,
611     dnl expand the accumulated commands and init code now:
612     [AC_CONFIG_COMMANDS([libtool],
613     [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
614     ])#_LT_CONFIG_COMMANDS
615    
616    
617     # Initialize.
618     m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
619     [
620    
621     # The HP-UX ksh and POSIX shell print the target directory to stdout
622     # if CDPATH is set.
623     (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
624    
625     sed_quote_subst='$sed_quote_subst'
626     double_quote_subst='$double_quote_subst'
627     delay_variable_subst='$delay_variable_subst'
628     _LT_CONFIG_STATUS_DECLARATIONS
629     LTCC='$LTCC'
630     LTCFLAGS='$LTCFLAGS'
631     compiler='$compiler_DEFAULT'
632    
633 michael 1094 # A function that is used when there is no print builtin or printf.
634     func_fallback_echo ()
635     {
636     eval 'cat <<_LTECHO_EOF
637     \$[]1
638     _LTECHO_EOF'
639     }
640    
641 michael 945 # Quote evaled strings.
642     for var in lt_decl_all_varnames([[ \
643     ]], lt_decl_quote_varnames); do
644 michael 1094 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
645 michael 945 *[[\\\\\\\`\\"\\\$]]*)
646 michael 1094 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
647 michael 945 ;;
648     *)
649     eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
650     ;;
651     esac
652     done
653    
654     # Double-quote double-evaled strings.
655     for var in lt_decl_all_varnames([[ \
656     ]], lt_decl_dquote_varnames); do
657 michael 1094 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
658 michael 945 *[[\\\\\\\`\\"\\\$]]*)
659 michael 1094 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
660 michael 945 ;;
661     *)
662     eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
663     ;;
664     esac
665     done
666    
667     _LT_OUTPUT_LIBTOOL_INIT
668     ])
669    
670 michael 1094 # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
671     # ------------------------------------
672     # Generate a child script FILE with all initialization necessary to
673     # reuse the environment learned by the parent script, and make the
674     # file executable. If COMMENT is supplied, it is inserted after the
675     # `#!' sequence but before initialization text begins. After this
676     # macro, additional text can be appended to FILE to form the body of
677     # the child script. The macro ends with non-zero status if the
678     # file could not be fully written (such as if the disk is full).
679     m4_ifdef([AS_INIT_GENERATED],
680     [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
681     [m4_defun([_LT_GENERATED_FILE_INIT],
682     [m4_require([AS_PREPARE])]dnl
683     [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
684     [lt_write_fail=0
685     cat >$1 <<_ASEOF || lt_write_fail=1
686     #! $SHELL
687     # Generated by $as_me.
688     $2
689     SHELL=\${CONFIG_SHELL-$SHELL}
690     export SHELL
691     _ASEOF
692     cat >>$1 <<\_ASEOF || lt_write_fail=1
693     AS_SHELL_SANITIZE
694     _AS_PREPARE
695     exec AS_MESSAGE_FD>&1
696     _ASEOF
697     test $lt_write_fail = 0 && chmod +x $1[]dnl
698     m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
699 michael 945
700     # LT_OUTPUT
701     # ---------
702     # This macro allows early generation of the libtool script (before
703     # AC_OUTPUT is called), incase it is used in configure for compilation
704     # tests.
705     AC_DEFUN([LT_OUTPUT],
706     [: ${CONFIG_LT=./config.lt}
707     AC_MSG_NOTICE([creating $CONFIG_LT])
708 michael 1094 _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
709     [# Run this file to recreate a libtool stub with the current configuration.])
710 michael 945
711 michael 1094 cat >>"$CONFIG_LT" <<\_LTEOF
712 michael 945 lt_cl_silent=false
713     exec AS_MESSAGE_LOG_FD>>config.log
714     {
715     echo
716     AS_BOX([Running $as_me.])
717     } >&AS_MESSAGE_LOG_FD
718    
719     lt_cl_help="\
720     \`$as_me' creates a local libtool stub from the current configuration,
721     for use in further configure time tests before the real libtool is
722     generated.
723    
724     Usage: $[0] [[OPTIONS]]
725    
726     -h, --help print this help, then exit
727     -V, --version print version number, then exit
728     -q, --quiet do not print progress messages
729     -d, --debug don't remove temporary files
730    
731     Report bugs to <bug-libtool@gnu.org>."
732    
733     lt_cl_version="\
734     m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
735     m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
736     configured by $[0], generated by m4_PACKAGE_STRING.
737    
738 michael 1257 Copyright (C) 2011 Free Software Foundation, Inc.
739 michael 945 This config.lt script is free software; the Free Software Foundation
740     gives unlimited permision to copy, distribute and modify it."
741    
742     while test $[#] != 0
743     do
744     case $[1] in
745     --version | --v* | -V )
746     echo "$lt_cl_version"; exit 0 ;;
747     --help | --h* | -h )
748     echo "$lt_cl_help"; exit 0 ;;
749     --debug | --d* | -d )
750     debug=: ;;
751     --quiet | --q* | --silent | --s* | -q )
752     lt_cl_silent=: ;;
753    
754     -*) AC_MSG_ERROR([unrecognized option: $[1]
755     Try \`$[0] --help' for more information.]) ;;
756    
757     *) AC_MSG_ERROR([unrecognized argument: $[1]
758     Try \`$[0] --help' for more information.]) ;;
759     esac
760     shift
761     done
762    
763     if $lt_cl_silent; then
764     exec AS_MESSAGE_FD>/dev/null
765     fi
766     _LTEOF
767    
768     cat >>"$CONFIG_LT" <<_LTEOF
769     _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
770     _LTEOF
771    
772     cat >>"$CONFIG_LT" <<\_LTEOF
773     AC_MSG_NOTICE([creating $ofile])
774     _LT_OUTPUT_LIBTOOL_COMMANDS
775     AS_EXIT(0)
776     _LTEOF
777     chmod +x "$CONFIG_LT"
778    
779     # configure is writing to config.log, but config.lt does its own redirection,
780     # appending to config.log, which fails on DOS, as config.log is still kept
781     # open by configure. Here we exec the FD to /dev/null, effectively closing
782     # config.log, so it can be properly (re)opened and appended to by config.lt.
783 michael 1094 lt_cl_success=:
784     test "$silent" = yes &&
785     lt_config_lt_args="$lt_config_lt_args --quiet"
786     exec AS_MESSAGE_LOG_FD>/dev/null
787     $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
788     exec AS_MESSAGE_LOG_FD>>config.log
789     $lt_cl_success || AS_EXIT(1)
790 michael 945 ])# LT_OUTPUT
791    
792    
793     # _LT_CONFIG(TAG)
794     # ---------------
795     # If TAG is the built-in tag, create an initial libtool script with a
796     # default configuration from the untagged config vars. Otherwise add code
797     # to config.status for appending the configuration named by TAG from the
798     # matching tagged config vars.
799     m4_defun([_LT_CONFIG],
800     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
801     _LT_CONFIG_SAVE_COMMANDS([
802     m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
803     m4_if(_LT_TAG, [C], [
804     # See if we are running on zsh, and set the options which allow our
805     # commands through without removal of \ escapes.
806     if test -n "${ZSH_VERSION+set}" ; then
807     setopt NO_GLOB_SUBST
808     fi
809    
810     cfgfile="${ofile}T"
811     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
812     $RM "$cfgfile"
813    
814     cat <<_LT_EOF >> "$cfgfile"
815     #! $SHELL
816    
817     # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
818     # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
819     # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
820     # NOTE: Changes made to this file will be lost: look at ltmain.sh.
821     #
822     _LT_COPYING
823     _LT_LIBTOOL_TAGS
824    
825     # ### BEGIN LIBTOOL CONFIG
826     _LT_LIBTOOL_CONFIG_VARS
827     _LT_LIBTOOL_TAG_VARS
828     # ### END LIBTOOL CONFIG
829    
830     _LT_EOF
831    
832     case $host_os in
833     aix3*)
834     cat <<\_LT_EOF >> "$cfgfile"
835     # AIX sometimes has problems with the GCC collect2 program. For some
836     # reason, if we set the COLLECT_NAMES environment variable, the problems
837     # vanish in a puff of smoke.
838     if test "X${COLLECT_NAMES+set}" != Xset; then
839     COLLECT_NAMES=
840     export COLLECT_NAMES
841     fi
842     _LT_EOF
843     ;;
844     esac
845    
846     _LT_PROG_LTMAIN
847    
848     # We use sed instead of cat because bash on DJGPP gets confused if
849     # if finds mixed CR/LF and LF-only lines. Since sed operates in
850     # text mode, it properly converts lines to CR/LF. This bash problem
851     # is reportedly fixed, but why not run on old versions too?
852 michael 1106 sed '$q' "$ltmain" >> "$cfgfile" \
853     || (rm -f "$cfgfile"; exit 1)
854 michael 945
855 michael 1106 _LT_PROG_REPLACE_SHELLFNS
856 michael 945
857 michael 1106 mv -f "$cfgfile" "$ofile" ||
858 michael 945 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
859     chmod +x "$ofile"
860     ],
861     [cat <<_LT_EOF >> "$ofile"
862    
863     dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
864     dnl in a comment (ie after a #).
865     # ### BEGIN LIBTOOL TAG CONFIG: $1
866     _LT_LIBTOOL_TAG_VARS(_LT_TAG)
867     # ### END LIBTOOL TAG CONFIG: $1
868     _LT_EOF
869     ])dnl /m4_if
870     ],
871     [m4_if([$1], [], [
872     PACKAGE='$PACKAGE'
873     VERSION='$VERSION'
874     TIMESTAMP='$TIMESTAMP'
875     RM='$RM'
876     ofile='$ofile'], [])
877     ])dnl /_LT_CONFIG_SAVE_COMMANDS
878     ])# _LT_CONFIG
879    
880    
881     # LT_SUPPORTED_TAG(TAG)
882     # ---------------------
883     # Trace this macro to discover what tags are supported by the libtool
884     # --tag option, using:
885     # autoconf --trace 'LT_SUPPORTED_TAG:$1'
886     AC_DEFUN([LT_SUPPORTED_TAG], [])
887    
888    
889     # C support is built-in for now
890     m4_define([_LT_LANG_C_enabled], [])
891     m4_define([_LT_TAGS], [])
892    
893    
894     # LT_LANG(LANG)
895     # -------------
896     # Enable libtool support for the given language if not already enabled.
897     AC_DEFUN([LT_LANG],
898     [AC_BEFORE([$0], [LT_OUTPUT])dnl
899     m4_case([$1],
900     [C], [_LT_LANG(C)],
901     [C++], [_LT_LANG(CXX)],
902 michael 1257 [Go], [_LT_LANG(GO)],
903 michael 945 [Java], [_LT_LANG(GCJ)],
904     [Fortran 77], [_LT_LANG(F77)],
905     [Fortran], [_LT_LANG(FC)],
906     [Windows Resource], [_LT_LANG(RC)],
907     [m4_ifdef([_LT_LANG_]$1[_CONFIG],
908     [_LT_LANG($1)],
909     [m4_fatal([$0: unsupported language: "$1"])])])dnl
910     ])# LT_LANG
911    
912    
913     # _LT_LANG(LANGNAME)
914     # ------------------
915     m4_defun([_LT_LANG],
916     [m4_ifdef([_LT_LANG_]$1[_enabled], [],
917     [LT_SUPPORTED_TAG([$1])dnl
918     m4_append([_LT_TAGS], [$1 ])dnl
919     m4_define([_LT_LANG_]$1[_enabled], [])dnl
920     _LT_LANG_$1_CONFIG($1)])dnl
921     ])# _LT_LANG
922    
923    
924 michael 1257 m4_ifndef([AC_PROG_GO], [
925     # NOTE: This macro has been submitted for inclusion into #
926     # GNU Autoconf as AC_PROG_GO. When it is available in #
927     # a released version of Autoconf we should remove this #
928     # macro and use it instead. #
929     m4_defun([AC_PROG_GO],
930     [AC_LANG_PUSH(Go)dnl
931     AC_ARG_VAR([GOC], [Go compiler command])dnl
932     AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
933     _AC_ARG_VAR_LDFLAGS()dnl
934     AC_CHECK_TOOL(GOC, gccgo)
935     if test -z "$GOC"; then
936     if test -n "$ac_tool_prefix"; then
937     AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
938     fi
939     fi
940     if test -z "$GOC"; then
941     AC_CHECK_PROG(GOC, gccgo, gccgo, false)
942     fi
943     ])#m4_defun
944     ])#m4_ifndef
945    
946    
947 michael 945 # _LT_LANG_DEFAULT_CONFIG
948     # -----------------------
949     m4_defun([_LT_LANG_DEFAULT_CONFIG],
950     [AC_PROVIDE_IFELSE([AC_PROG_CXX],
951     [LT_LANG(CXX)],
952     [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
953    
954     AC_PROVIDE_IFELSE([AC_PROG_F77],
955     [LT_LANG(F77)],
956     [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
957    
958     AC_PROVIDE_IFELSE([AC_PROG_FC],
959     [LT_LANG(FC)],
960     [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
961    
962     dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
963     dnl pulling things in needlessly.
964     AC_PROVIDE_IFELSE([AC_PROG_GCJ],
965     [LT_LANG(GCJ)],
966     [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
967     [LT_LANG(GCJ)],
968     [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
969     [LT_LANG(GCJ)],
970     [m4_ifdef([AC_PROG_GCJ],
971     [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
972     m4_ifdef([A][M_PROG_GCJ],
973     [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
974     m4_ifdef([LT_PROG_GCJ],
975     [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
976    
977 michael 1257 AC_PROVIDE_IFELSE([AC_PROG_GO],
978     [LT_LANG(GO)],
979     [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
980    
981 michael 945 AC_PROVIDE_IFELSE([LT_PROG_RC],
982     [LT_LANG(RC)],
983     [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
984     ])# _LT_LANG_DEFAULT_CONFIG
985    
986     # Obsolete macros:
987     AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
988     AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
989     AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
990     AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
991 michael 1094 AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
992 michael 945 dnl aclocal-1.4 backwards compatibility:
993     dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
994     dnl AC_DEFUN([AC_LIBTOOL_F77], [])
995     dnl AC_DEFUN([AC_LIBTOOL_FC], [])
996     dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
997 michael 1094 dnl AC_DEFUN([AC_LIBTOOL_RC], [])
998 michael 945
999    
1000     # _LT_TAG_COMPILER
1001     # ----------------
1002     m4_defun([_LT_TAG_COMPILER],
1003 michael 912 [AC_REQUIRE([AC_PROG_CC])dnl
1004    
1005 michael 945 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1006     _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1007     _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1008     _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1009    
1010 michael 912 # If no C compiler was specified, use CC.
1011     LTCC=${LTCC-"$CC"}
1012    
1013     # If no C compiler flags were specified, use CFLAGS.
1014     LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1015    
1016     # Allow CC to be a program name with arguments.
1017     compiler=$CC
1018 michael 945 ])# _LT_TAG_COMPILER
1019 michael 912
1020    
1021     # _LT_COMPILER_BOILERPLATE
1022     # ------------------------
1023     # Check for compiler boilerplate output or warnings with
1024     # the simple compiler test code.
1025 michael 945 m4_defun([_LT_COMPILER_BOILERPLATE],
1026     [m4_require([_LT_DECL_SED])dnl
1027 michael 912 ac_outfile=conftest.$ac_objext
1028     echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1029     eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1030     _lt_compiler_boilerplate=`cat conftest.err`
1031 michael 945 $RM conftest*
1032 michael 912 ])# _LT_COMPILER_BOILERPLATE
1033    
1034    
1035     # _LT_LINKER_BOILERPLATE
1036     # ----------------------
1037     # Check for linker boilerplate output or warnings with
1038     # the simple link test code.
1039 michael 945 m4_defun([_LT_LINKER_BOILERPLATE],
1040     [m4_require([_LT_DECL_SED])dnl
1041 michael 912 ac_outfile=conftest.$ac_objext
1042     echo "$lt_simple_link_test_code" >conftest.$ac_ext
1043     eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1044     _lt_linker_boilerplate=`cat conftest.err`
1045 michael 945 $RM -r conftest*
1046 michael 912 ])# _LT_LINKER_BOILERPLATE
1047    
1048 db 941 # _LT_REQUIRED_DARWIN_CHECKS
1049 michael 945 # -------------------------
1050     m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1051 db 941 case $host_os in
1052     rhapsody* | darwin*)
1053     AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1054     AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1055 michael 945 AC_CHECK_TOOL([LIPO], [lipo], [:])
1056     AC_CHECK_TOOL([OTOOL], [otool], [:])
1057     AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1058     _LT_DECL([], [DSYMUTIL], [1],
1059     [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1060     _LT_DECL([], [NMEDIT], [1],
1061     [Tool to change global to local symbols on Mac OS X])
1062     _LT_DECL([], [LIPO], [1],
1063     [Tool to manipulate fat objects and archives on Mac OS X])
1064     _LT_DECL([], [OTOOL], [1],
1065     [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1066     _LT_DECL([], [OTOOL64], [1],
1067     [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1068 michael 912
1069 db 941 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1070     [lt_cv_apple_cc_single_mod=no
1071     if test -z "${LT_MULTI_MODULE}"; then
1072 michael 945 # By default we will add the -single_module flag. You can override
1073     # by either setting the environment variable LT_MULTI_MODULE
1074     # non-empty at configure time, or by adding -multi_module to the
1075     # link flags.
1076     rm -rf libconftest.dylib*
1077     echo "int foo(void){return 1;}" > conftest.c
1078     echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1079     -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1080     $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1081     -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1082     _lt_result=$?
1083 michael 1257 # If there is a non-empty error log, and "single_module"
1084     # appears in it, assume the flag caused a linker warning
1085     if test -s conftest.err && $GREP single_module conftest.err; then
1086     cat conftest.err >&AS_MESSAGE_LOG_FD
1087     # Otherwise, if the output was created with a 0 exit code from
1088     # the compiler, it worked.
1089     elif test -f libconftest.dylib && test $_lt_result -eq 0; then
1090 michael 945 lt_cv_apple_cc_single_mod=yes
1091     else
1092     cat conftest.err >&AS_MESSAGE_LOG_FD
1093     fi
1094     rm -rf libconftest.dylib*
1095     rm -f conftest.*
1096 db 941 fi])
1097 michael 1257
1098 db 941 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1099     [lt_cv_ld_exported_symbols_list],
1100     [lt_cv_ld_exported_symbols_list=no
1101     save_LDFLAGS=$LDFLAGS
1102     echo "_main" > conftest.sym
1103     LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1104     AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1105 michael 945 [lt_cv_ld_exported_symbols_list=yes],
1106     [lt_cv_ld_exported_symbols_list=no])
1107     LDFLAGS="$save_LDFLAGS"
1108 db 941 ])
1109 michael 1257
1110 michael 1094 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
1111     [lt_cv_ld_force_load=no
1112     cat > conftest.c << _LT_EOF
1113     int forced_loaded() { return 2;}
1114     _LT_EOF
1115     echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1116     $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1117     echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1118     $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1119     echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1120     $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1121     cat > conftest.c << _LT_EOF
1122     int main() { return 0;}
1123     _LT_EOF
1124     echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
1125     $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
1126     _lt_result=$?
1127 michael 1257 if test -s conftest.err && $GREP force_load conftest.err; then
1128     cat conftest.err >&AS_MESSAGE_LOG_FD
1129     elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
1130 michael 1094 lt_cv_ld_force_load=yes
1131     else
1132     cat conftest.err >&AS_MESSAGE_LOG_FD
1133     fi
1134     rm -f conftest.err libconftest.a conftest conftest.c
1135     rm -rf conftest.dSYM
1136     ])
1137 db 941 case $host_os in
1138 michael 945 rhapsody* | darwin1.[[012]])
1139 db 941 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1140     darwin1.*)
1141 michael 945 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1142     darwin*) # darwin 5.x on
1143 db 941 # if running on 10.5 or later, the deployment target defaults
1144     # to the OS version, if on x86, and 10.4, the deployment
1145     # target defaults to 10.4. Don't you love it?
1146     case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1147 michael 945 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1148     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1149     10.[[012]]*)
1150     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1151     10.*)
1152     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1153 db 941 esac
1154     ;;
1155     esac
1156     if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1157     _lt_dar_single_mod='$single_module'
1158     fi
1159     if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1160     _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1161     else
1162 michael 945 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1163 db 941 fi
1164 michael 1094 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
1165 michael 945 _lt_dsymutil='~$DSYMUTIL $lib || :'
1166 db 941 else
1167     _lt_dsymutil=
1168     fi
1169     ;;
1170     esac
1171     ])
1172    
1173 michael 945
1174 michael 1257 # _LT_DARWIN_LINKER_FEATURES([TAG])
1175     # ---------------------------------
1176 michael 945 # Checks for linker and compiler features on darwin
1177     m4_defun([_LT_DARWIN_LINKER_FEATURES],
1178     [
1179     m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1180     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1181     _LT_TAGVAR(hardcode_direct, $1)=no
1182     _LT_TAGVAR(hardcode_automatic, $1)=yes
1183     _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1184 michael 1094 if test "$lt_cv_ld_force_load" = "yes"; then
1185     _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1186 michael 1257 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
1187     [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
1188 michael 1094 else
1189     _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1190     fi
1191 michael 945 _LT_TAGVAR(link_all_deplibs, $1)=yes
1192     _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1193     case $cc_basename in
1194     ifort*) _lt_dar_can_shared=yes ;;
1195     *) _lt_dar_can_shared=$GCC ;;
1196     esac
1197     if test "$_lt_dar_can_shared" = "yes"; then
1198 michael 1094 output_verbose_link_cmd=func_echo_all
1199 michael 945 _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
1200     _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1201     _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
1202     _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
1203     m4_if([$1], [CXX],
1204     [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1205     _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
1206     _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
1207     fi
1208     ],[])
1209     else
1210     _LT_TAGVAR(ld_shlibs, $1)=no
1211     fi
1212     ])
1213    
1214 michael 1106 # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
1215     # ----------------------------------
1216 michael 912 # Links a minimal program and checks the executable
1217     # for the system default hardcoded library path. In most cases,
1218     # this is /usr/lib:/lib, but when the MPI compilers are used
1219     # the location of the communication and MPI libs are included too.
1220     # If we don't find anything, use the default library path according
1221     # to the aix ld manual.
1222 michael 1106 # Store the results from the different compilers for each TAGNAME.
1223     # Allow to override them for all tags through lt_cv_aix_libpath.
1224 michael 945 m4_defun([_LT_SYS_MODULE_PATH_AIX],
1225     [m4_require([_LT_DECL_SED])dnl
1226 michael 1106 if test "${lt_cv_aix_libpath+set}" = set; then
1227     aix_libpath=$lt_cv_aix_libpath
1228     else
1229     AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
1230     [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
1231     lt_aix_libpath_sed='[
1232     /Import File Strings/,/^$/ {
1233     /^0/ {
1234     s/^0 *\([^ ]*\) *$/\1/
1235     p
1236     }
1237     }]'
1238     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1239     # Check for a 64-bit object if we didn't find anything.
1240     if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1241     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1242     fi],[])
1243     if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1244     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
1245     fi
1246     ])
1247     aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
1248     fi
1249 michael 945 ])# _LT_SYS_MODULE_PATH_AIX
1250 michael 912
1251    
1252 michael 945 # _LT_SHELL_INIT(ARG)
1253     # -------------------
1254     m4_define([_LT_SHELL_INIT],
1255 michael 1094 [m4_divert_text([M4SH-INIT], [$1
1256     ])])# _LT_SHELL_INIT
1257 michael 912
1258    
1259 michael 1094
1260 michael 945 # _LT_PROG_ECHO_BACKSLASH
1261     # -----------------------
1262 michael 1094 # Find how we can fake an echo command that does not interpret backslash.
1263     # In particular, with Autoconf 2.60 or later we add some code to the start
1264     # of the generated configure script which will find a shell with a builtin
1265     # printf (which we can use as an echo command).
1266 michael 945 m4_defun([_LT_PROG_ECHO_BACKSLASH],
1267 michael 1094 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1268     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1269     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1270 michael 912
1271 michael 1094 AC_MSG_CHECKING([how to print strings])
1272     # Test print first, because it will be a builtin if present.
1273 michael 1106 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
1274 michael 1094 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
1275     ECHO='print -r --'
1276     elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
1277     ECHO='printf %s\n'
1278 michael 912 else
1279 michael 1094 # Use this function as a fallback that always works.
1280     func_fallback_echo ()
1281     {
1282     eval 'cat <<_LTECHO_EOF
1283     $[]1
1284     _LTECHO_EOF'
1285     }
1286     ECHO='func_fallback_echo'
1287 michael 912 fi
1288    
1289 michael 1094 # func_echo_all arg...
1290     # Invoke $ECHO with all args, space-separated.
1291     func_echo_all ()
1292     {
1293     $ECHO "$*"
1294     }
1295 michael 912
1296 michael 1094 case "$ECHO" in
1297     printf*) AC_MSG_RESULT([printf]) ;;
1298     print*) AC_MSG_RESULT([print -r]) ;;
1299     *) AC_MSG_RESULT([cat]) ;;
1300     esac
1301 michael 912
1302 michael 1094 m4_ifdef([_AS_DETECT_SUGGESTED],
1303     [_AS_DETECT_SUGGESTED([
1304     test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
1305     ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1306     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1307     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1308     PATH=/empty FPATH=/empty; export PATH FPATH
1309     test "X`printf %s $ECHO`" = "X$ECHO" \
1310     || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
1311 michael 912
1312 michael 945 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1313 michael 1094 _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1314 michael 945 ])# _LT_PROG_ECHO_BACKSLASH
1315 michael 912
1316    
1317 michael 1106 # _LT_WITH_SYSROOT
1318     # ----------------
1319     AC_DEFUN([_LT_WITH_SYSROOT],
1320     [AC_MSG_CHECKING([for sysroot])
1321     AC_ARG_WITH([sysroot],
1322     [ --with-sysroot[=DIR] Search for dependent libraries within DIR
1323     (or the compiler's sysroot if not specified).],
1324     [], [with_sysroot=no])
1325    
1326     dnl lt_sysroot will always be passed unquoted. We quote it here
1327     dnl in case the user passed a directory name.
1328     lt_sysroot=
1329     case ${with_sysroot} in #(
1330     yes)
1331     if test "$GCC" = yes; then
1332     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
1333     fi
1334     ;; #(
1335     /*)
1336     lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
1337     ;; #(
1338     no|'')
1339     ;; #(
1340     *)
1341     AC_MSG_RESULT([${with_sysroot}])
1342     AC_MSG_ERROR([The sysroot must be an absolute path.])
1343     ;;
1344     esac
1345    
1346     AC_MSG_RESULT([${lt_sysroot:-no}])
1347     _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
1348     [dependent libraries, and in which our libraries should be installed.])])
1349    
1350 michael 945 # _LT_ENABLE_LOCK
1351     # ---------------
1352     m4_defun([_LT_ENABLE_LOCK],
1353 michael 912 [AC_ARG_ENABLE([libtool-lock],
1354 michael 945 [AS_HELP_STRING([--disable-libtool-lock],
1355     [avoid locking (might break parallel builds)])])
1356 michael 912 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1357    
1358     # Some flags need to be propagated to the compiler or linker for good
1359     # libtool support.
1360     case $host in
1361     ia64-*-hpux*)
1362     # Find out which ABI we are using.
1363     echo 'int i;' > conftest.$ac_ext
1364     if AC_TRY_EVAL(ac_compile); then
1365     case `/usr/bin/file conftest.$ac_objext` in
1366 michael 945 *ELF-32*)
1367     HPUX_IA64_MODE="32"
1368     ;;
1369     *ELF-64*)
1370     HPUX_IA64_MODE="64"
1371     ;;
1372 michael 912 esac
1373     fi
1374     rm -rf conftest*
1375     ;;
1376     *-*-irix6*)
1377     # Find out which ABI we are using.
1378 michael 1094 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1379 michael 912 if AC_TRY_EVAL(ac_compile); then
1380 michael 945 if test "$lt_cv_prog_gnu_ld" = yes; then
1381     case `/usr/bin/file conftest.$ac_objext` in
1382     *32-bit*)
1383     LD="${LD-ld} -melf32bsmip"
1384     ;;
1385     *N32*)
1386     LD="${LD-ld} -melf32bmipn32"
1387     ;;
1388     *64-bit*)
1389     LD="${LD-ld} -melf64bmip"
1390     ;;
1391     esac
1392     else
1393     case `/usr/bin/file conftest.$ac_objext` in
1394     *32-bit*)
1395     LD="${LD-ld} -32"
1396     ;;
1397     *N32*)
1398     LD="${LD-ld} -n32"
1399     ;;
1400     *64-bit*)
1401     LD="${LD-ld} -64"
1402     ;;
1403     esac
1404     fi
1405 michael 912 fi
1406     rm -rf conftest*
1407     ;;
1408    
1409     x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1410 michael 945 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1411 michael 912 # Find out which ABI we are using.
1412     echo 'int i;' > conftest.$ac_ext
1413     if AC_TRY_EVAL(ac_compile); then
1414     case `/usr/bin/file conftest.o` in
1415 michael 945 *32-bit*)
1416     case $host in
1417     x86_64-*kfreebsd*-gnu)
1418     LD="${LD-ld} -m elf_i386_fbsd"
1419     ;;
1420     x86_64-*linux*)
1421     LD="${LD-ld} -m elf_i386"
1422     ;;
1423     ppc64-*linux*|powerpc64-*linux*)
1424     LD="${LD-ld} -m elf32ppclinux"
1425     ;;
1426     s390x-*linux*)
1427     LD="${LD-ld} -m elf_s390"
1428     ;;
1429     sparc64-*linux*)
1430     LD="${LD-ld} -m elf32_sparc"
1431     ;;
1432     esac
1433     ;;
1434     *64-bit*)
1435     case $host in
1436     x86_64-*kfreebsd*-gnu)
1437     LD="${LD-ld} -m elf_x86_64_fbsd"
1438     ;;
1439     x86_64-*linux*)
1440     LD="${LD-ld} -m elf_x86_64"
1441     ;;
1442     ppc*-*linux*|powerpc*-*linux*)
1443     LD="${LD-ld} -m elf64ppc"
1444     ;;
1445     s390*-*linux*|s390*-*tpf*)
1446     LD="${LD-ld} -m elf64_s390"
1447     ;;
1448     sparc*-*linux*)
1449     LD="${LD-ld} -m elf64_sparc"
1450     ;;
1451     esac
1452     ;;
1453 michael 912 esac
1454     fi
1455     rm -rf conftest*
1456     ;;
1457    
1458     *-*-sco3.2v5*)
1459     # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1460     SAVE_CFLAGS="$CFLAGS"
1461     CFLAGS="$CFLAGS -belf"
1462     AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1463     [AC_LANG_PUSH(C)
1464 michael 945 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1465 michael 912 AC_LANG_POP])
1466     if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1467     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1468     CFLAGS="$SAVE_CFLAGS"
1469     fi
1470     ;;
1471 michael 1257 *-*solaris*)
1472 michael 912 # Find out which ABI we are using.
1473     echo 'int i;' > conftest.$ac_ext
1474     if AC_TRY_EVAL(ac_compile); then
1475     case `/usr/bin/file conftest.o` in
1476     *64-bit*)
1477     case $lt_cv_prog_gnu_ld in
1478 michael 1257 yes*)
1479     case $host in
1480     i?86-*-solaris*)
1481     LD="${LD-ld} -m elf_x86_64"
1482     ;;
1483     sparc*-*-solaris*)
1484     LD="${LD-ld} -m elf64_sparc"
1485     ;;
1486     esac
1487     # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
1488     if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
1489     LD="${LD-ld}_sol2"
1490     fi
1491     ;;
1492 db 941 *)
1493 michael 945 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1494 db 941 LD="${LD-ld} -64"
1495     fi
1496     ;;
1497 michael 912 esac
1498     ;;
1499     esac
1500     fi
1501     rm -rf conftest*
1502     ;;
1503     esac
1504    
1505     need_locks="$enable_libtool_lock"
1506 michael 945 ])# _LT_ENABLE_LOCK
1507 michael 912
1508    
1509 michael 1106 # _LT_PROG_AR
1510     # -----------
1511     m4_defun([_LT_PROG_AR],
1512     [AC_CHECK_TOOLS(AR, [ar], false)
1513     : ${AR=ar}
1514     : ${AR_FLAGS=cru}
1515     _LT_DECL([], [AR], [1], [The archiver])
1516     _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
1517    
1518     AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
1519     [lt_cv_ar_at_file=no
1520     AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
1521     [echo conftest.$ac_objext > conftest.lst
1522     lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
1523     AC_TRY_EVAL([lt_ar_try])
1524     if test "$ac_status" -eq 0; then
1525     # Ensure the archiver fails upon bogus file names.
1526     rm -f conftest.$ac_objext libconftest.a
1527     AC_TRY_EVAL([lt_ar_try])
1528     if test "$ac_status" -ne 0; then
1529     lt_cv_ar_at_file=@
1530     fi
1531     fi
1532     rm -f conftest.* libconftest.a
1533     ])
1534     ])
1535    
1536     if test "x$lt_cv_ar_at_file" = xno; then
1537     archiver_list_spec=
1538     else
1539     archiver_list_spec=$lt_cv_ar_at_file
1540     fi
1541     _LT_DECL([], [archiver_list_spec], [1],
1542     [How to feed a file listing to the archiver])
1543     ])# _LT_PROG_AR
1544    
1545    
1546 michael 945 # _LT_CMD_OLD_ARCHIVE
1547     # -------------------
1548     m4_defun([_LT_CMD_OLD_ARCHIVE],
1549 michael 1106 [_LT_PROG_AR
1550 michael 912
1551 michael 945 AC_CHECK_TOOL(STRIP, strip, :)
1552     test -z "$STRIP" && STRIP=:
1553     _LT_DECL([], [STRIP], [1], [A symbol stripping program])
1554    
1555     AC_CHECK_TOOL(RANLIB, ranlib, :)
1556     test -z "$RANLIB" && RANLIB=:
1557     _LT_DECL([], [RANLIB], [1],
1558     [Commands used to install an old-style archive])
1559    
1560     # Determine commands to create old-style static archives.
1561     old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1562     old_postinstall_cmds='chmod 644 $oldlib'
1563     old_postuninstall_cmds=
1564    
1565     if test -n "$RANLIB"; then
1566     case $host_os in
1567     openbsd*)
1568 michael 1257 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
1569 michael 945 ;;
1570     *)
1571 michael 1257 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
1572 michael 945 ;;
1573     esac
1574 michael 1257 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
1575 michael 945 fi
1576 michael 1094
1577     case $host_os in
1578     darwin*)
1579     lock_old_archive_extraction=yes ;;
1580     *)
1581     lock_old_archive_extraction=no ;;
1582     esac
1583 michael 945 _LT_DECL([], [old_postinstall_cmds], [2])
1584     _LT_DECL([], [old_postuninstall_cmds], [2])
1585     _LT_TAGDECL([], [old_archive_cmds], [2],
1586     [Commands used to build an old-style archive])
1587 michael 1094 _LT_DECL([], [lock_old_archive_extraction], [0],
1588     [Whether to use a lock for old archive extraction])
1589 michael 945 ])# _LT_CMD_OLD_ARCHIVE
1590    
1591    
1592     # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1593 michael 912 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1594     # ----------------------------------------------------------------
1595     # Check whether the given compiler option works
1596 michael 945 AC_DEFUN([_LT_COMPILER_OPTION],
1597     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1598     m4_require([_LT_DECL_SED])dnl
1599 michael 912 AC_CACHE_CHECK([$1], [$2],
1600     [$2=no
1601 michael 945 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1602 michael 912 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1603     lt_compiler_flag="$3"
1604     # Insert the option either (1) after the last *FLAGS variable, or
1605     # (2) before a word containing "conftest.", or (3) at the end.
1606     # Note that $ac_compile itself does not contain backslashes and begins
1607     # with a dollar sign (not a hyphen), so the echo should work correctly.
1608     # The option is referenced via a variable to avoid confusing sed.
1609     lt_compile=`echo "$ac_compile" | $SED \
1610     -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1611     -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1612     -e 's:$: $lt_compiler_flag:'`
1613 michael 1094 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1614 michael 912 (eval "$lt_compile" 2>conftest.err)
1615     ac_status=$?
1616     cat conftest.err >&AS_MESSAGE_LOG_FD
1617 michael 1094 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1618 michael 912 if (exit $ac_status) && test -s "$ac_outfile"; then
1619     # The compiler can only warn and ignore the option if not recognized
1620     # So say no if there are warnings other than the usual output.
1621 michael 1094 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
1622 michael 912 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1623     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1624     $2=yes
1625     fi
1626     fi
1627 michael 945 $RM conftest*
1628 michael 912 ])
1629    
1630     if test x"[$]$2" = xyes; then
1631 michael 945 m4_if([$5], , :, [$5])
1632 michael 912 else
1633 michael 945 m4_if([$6], , :, [$6])
1634 michael 912 fi
1635 michael 945 ])# _LT_COMPILER_OPTION
1636 michael 912
1637 michael 945 # Old name:
1638     AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
1639     dnl aclocal-1.4 backwards compatibility:
1640     dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
1641 michael 912
1642 michael 945
1643     # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1644     # [ACTION-SUCCESS], [ACTION-FAILURE])
1645     # ----------------------------------------------------
1646     # Check whether the given linker option works
1647     AC_DEFUN([_LT_LINKER_OPTION],
1648     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1649     m4_require([_LT_DECL_SED])dnl
1650 michael 912 AC_CACHE_CHECK([$1], [$2],
1651     [$2=no
1652     save_LDFLAGS="$LDFLAGS"
1653     LDFLAGS="$LDFLAGS $3"
1654     echo "$lt_simple_link_test_code" > conftest.$ac_ext
1655     if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1656     # The linker can only warn and ignore the option if not recognized
1657     # So say no if there are warnings
1658     if test -s conftest.err; then
1659     # Append any errors to the config.log.
1660     cat conftest.err 1>&AS_MESSAGE_LOG_FD
1661 michael 1094 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
1662 michael 912 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1663     if diff conftest.exp conftest.er2 >/dev/null; then
1664     $2=yes
1665     fi
1666     else
1667     $2=yes
1668     fi
1669     fi
1670 michael 945 $RM -r conftest*
1671 michael 912 LDFLAGS="$save_LDFLAGS"
1672     ])
1673    
1674     if test x"[$]$2" = xyes; then
1675 michael 945 m4_if([$4], , :, [$4])
1676 michael 912 else
1677 michael 945 m4_if([$5], , :, [$5])
1678 michael 912 fi
1679 michael 945 ])# _LT_LINKER_OPTION
1680 michael 912
1681 michael 945 # Old name:
1682     AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
1683     dnl aclocal-1.4 backwards compatibility:
1684     dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
1685 michael 912
1686 michael 945
1687     # LT_CMD_MAX_LEN
1688     #---------------
1689     AC_DEFUN([LT_CMD_MAX_LEN],
1690     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1691     # find the maximum length of command line arguments
1692 michael 912 AC_MSG_CHECKING([the maximum length of command line arguments])
1693     AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1694     i=0
1695     teststring="ABCD"
1696    
1697     case $build_os in
1698     msdosdjgpp*)
1699     # On DJGPP, this test can blow up pretty badly due to problems in libc
1700     # (any single argument exceeding 2000 bytes causes a buffer overrun
1701     # during glob expansion). Even if it were fixed, the result of this
1702     # check would be larger than it should be.
1703     lt_cv_sys_max_cmd_len=12288; # 12K is about right
1704     ;;
1705    
1706     gnu*)
1707     # Under GNU Hurd, this test is not required because there is
1708     # no limit to the length of command line arguments.
1709     # Libtool will interpret -1 as no limit whatsoever
1710     lt_cv_sys_max_cmd_len=-1;
1711     ;;
1712    
1713 michael 945 cygwin* | mingw* | cegcc*)
1714 michael 912 # On Win9x/ME, this test blows up -- it succeeds, but takes
1715     # about 5 minutes as the teststring grows exponentially.
1716     # Worse, since 9x/ME are not pre-emptively multitasking,
1717     # you end up with a "frozen" computer, even though with patience
1718     # the test eventually succeeds (with a max line length of 256k).
1719     # Instead, let's just punt: use the minimum linelength reported by
1720     # all of the supported platforms: 8192 (on NT/2K/XP).
1721     lt_cv_sys_max_cmd_len=8192;
1722     ;;
1723    
1724 michael 1094 mint*)
1725     # On MiNT this can take a long time and run out of memory.
1726     lt_cv_sys_max_cmd_len=8192;
1727     ;;
1728    
1729 michael 912 amigaos*)
1730     # On AmigaOS with pdksh, this test takes hours, literally.
1731     # So we just punt and use a minimum line length of 8192.
1732     lt_cv_sys_max_cmd_len=8192;
1733     ;;
1734    
1735     netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1736     # This has been around since 386BSD, at least. Likely further.
1737     if test -x /sbin/sysctl; then
1738     lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1739     elif test -x /usr/sbin/sysctl; then
1740     lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1741     else
1742     lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1743     fi
1744     # And add a safety zone
1745     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1746     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1747     ;;
1748    
1749     interix*)
1750     # We know the value 262144 and hardcode it with a safety zone (like BSD)
1751     lt_cv_sys_max_cmd_len=196608
1752     ;;
1753    
1754 michael 1257 os2*)
1755     # The test takes a long time on OS/2.
1756     lt_cv_sys_max_cmd_len=8192
1757     ;;
1758    
1759 michael 912 osf*)
1760     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1761     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1762     # nice to cause kernel panics so lets avoid the loop below.
1763     # First set a reasonable default.
1764     lt_cv_sys_max_cmd_len=16384
1765     #
1766     if test -x /sbin/sysconfig; then
1767     case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1768     *1*) lt_cv_sys_max_cmd_len=-1 ;;
1769     esac
1770     fi
1771     ;;
1772     sco3.2v5*)
1773     lt_cv_sys_max_cmd_len=102400
1774     ;;
1775     sysv5* | sco5v6* | sysv4.2uw2*)
1776     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1777     if test -n "$kargmax"; then
1778 michael 945 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1779 michael 912 else
1780     lt_cv_sys_max_cmd_len=32768
1781     fi
1782     ;;
1783     *)
1784     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1785     if test -n "$lt_cv_sys_max_cmd_len"; then
1786     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1787     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1788     else
1789 michael 945 # Make teststring a little bigger before we do anything with it.
1790     # a 1K string should be a reasonable start.
1791     for i in 1 2 3 4 5 6 7 8 ; do
1792     teststring=$teststring$teststring
1793     done
1794 michael 912 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1795 michael 945 # If test is not a shell built-in, we'll probably end up computing a
1796     # maximum length that is only half of the actual maximum length, but
1797     # we can't tell.
1798 michael 1257 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
1799 michael 1094 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
1800 michael 912 test $i != 17 # 1/2 MB should be enough
1801     do
1802     i=`expr $i + 1`
1803     teststring=$teststring$teststring
1804     done
1805 michael 945 # Only check the string length outside the loop.
1806     lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
1807 michael 912 teststring=
1808 michael 945 # Add a significant safety factor because C++ compilers can tack on
1809     # massive amounts of additional arguments before passing them to the
1810     # linker. It appears as though 1/2 is a usable value.
1811 michael 912 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1812     fi
1813     ;;
1814     esac
1815     ])
1816     if test -n $lt_cv_sys_max_cmd_len ; then
1817     AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1818     else
1819     AC_MSG_RESULT(none)
1820     fi
1821 michael 945 max_cmd_len=$lt_cv_sys_max_cmd_len
1822     _LT_DECL([], [max_cmd_len], [0],
1823     [What is the maximum length of a command?])
1824     ])# LT_CMD_MAX_LEN
1825 michael 912
1826 michael 945 # Old name:
1827     AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
1828     dnl aclocal-1.4 backwards compatibility:
1829     dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
1830 michael 912
1831    
1832 michael 945 # _LT_HEADER_DLFCN
1833     # ----------------
1834     m4_defun([_LT_HEADER_DLFCN],
1835     [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
1836     ])# _LT_HEADER_DLFCN
1837 michael 912
1838 michael 945
1839     # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1840     # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1841     # ----------------------------------------------------------------
1842     m4_defun([_LT_TRY_DLOPEN_SELF],
1843     [m4_require([_LT_HEADER_DLFCN])dnl
1844 michael 912 if test "$cross_compiling" = yes; then :
1845     [$4]
1846     else
1847     lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1848     lt_status=$lt_dlunknown
1849 michael 945 cat > conftest.$ac_ext <<_LT_EOF
1850 michael 1094 [#line $LINENO "configure"
1851 michael 912 #include "confdefs.h"
1852    
1853     #if HAVE_DLFCN_H
1854     #include <dlfcn.h>
1855     #endif
1856    
1857     #include <stdio.h>
1858    
1859     #ifdef RTLD_GLOBAL
1860     # define LT_DLGLOBAL RTLD_GLOBAL
1861     #else
1862     # ifdef DL_GLOBAL
1863     # define LT_DLGLOBAL DL_GLOBAL
1864     # else
1865     # define LT_DLGLOBAL 0
1866     # endif
1867     #endif
1868    
1869     /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1870     find out it does not work in some platform. */
1871     #ifndef LT_DLLAZY_OR_NOW
1872     # ifdef RTLD_LAZY
1873     # define LT_DLLAZY_OR_NOW RTLD_LAZY
1874     # else
1875     # ifdef DL_LAZY
1876     # define LT_DLLAZY_OR_NOW DL_LAZY
1877     # else
1878     # ifdef RTLD_NOW
1879     # define LT_DLLAZY_OR_NOW RTLD_NOW
1880     # else
1881     # ifdef DL_NOW
1882     # define LT_DLLAZY_OR_NOW DL_NOW
1883     # else
1884     # define LT_DLLAZY_OR_NOW 0
1885     # endif
1886     # endif
1887     # endif
1888     # endif
1889     #endif
1890    
1891 michael 1094 /* When -fvisbility=hidden is used, assume the code has been annotated
1892     correspondingly for the symbols needed. */
1893     #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1894 michael 1106 int fnord () __attribute__((visibility("default")));
1895 michael 1094 #endif
1896    
1897 michael 1106 int fnord () { return 42; }
1898 michael 912 int main ()
1899     {
1900     void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1901     int status = $lt_dlunknown;
1902    
1903     if (self)
1904     {
1905     if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1906 michael 1094 else
1907     {
1908     if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1909     else puts (dlerror ());
1910     }
1911 michael 912 /* dlclose (self); */
1912     }
1913     else
1914     puts (dlerror ());
1915    
1916 michael 945 return status;
1917 michael 912 }]
1918 michael 945 _LT_EOF
1919 michael 912 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1920     (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1921     lt_status=$?
1922     case x$lt_status in
1923     x$lt_dlno_uscore) $1 ;;
1924     x$lt_dlneed_uscore) $2 ;;
1925     x$lt_dlunknown|x*) $3 ;;
1926     esac
1927     else :
1928     # compilation failed
1929     $3
1930     fi
1931     fi
1932     rm -fr conftest*
1933 michael 945 ])# _LT_TRY_DLOPEN_SELF
1934 michael 912
1935    
1936 michael 945 # LT_SYS_DLOPEN_SELF
1937     # ------------------
1938     AC_DEFUN([LT_SYS_DLOPEN_SELF],
1939     [m4_require([_LT_HEADER_DLFCN])dnl
1940 michael 912 if test "x$enable_dlopen" != xyes; then
1941     enable_dlopen=unknown
1942     enable_dlopen_self=unknown
1943     enable_dlopen_self_static=unknown
1944     else
1945     lt_cv_dlopen=no
1946     lt_cv_dlopen_libs=
1947    
1948     case $host_os in
1949     beos*)
1950     lt_cv_dlopen="load_add_on"
1951     lt_cv_dlopen_libs=
1952     lt_cv_dlopen_self=yes
1953     ;;
1954    
1955 michael 945 mingw* | pw32* | cegcc*)
1956 michael 912 lt_cv_dlopen="LoadLibrary"
1957     lt_cv_dlopen_libs=
1958 michael 945 ;;
1959 michael 912
1960     cygwin*)
1961     lt_cv_dlopen="dlopen"
1962     lt_cv_dlopen_libs=
1963 michael 945 ;;
1964 michael 912
1965     darwin*)
1966     # if libdl is installed we need to link against it
1967     AC_CHECK_LIB([dl], [dlopen],
1968     [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1969     lt_cv_dlopen="dyld"
1970     lt_cv_dlopen_libs=
1971     lt_cv_dlopen_self=yes
1972     ])
1973 michael 945 ;;
1974 michael 912
1975     *)
1976     AC_CHECK_FUNC([shl_load],
1977     [lt_cv_dlopen="shl_load"],
1978     [AC_CHECK_LIB([dld], [shl_load],
1979 db 941 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1980 michael 912 [AC_CHECK_FUNC([dlopen],
1981     [lt_cv_dlopen="dlopen"],
1982     [AC_CHECK_LIB([dl], [dlopen],
1983     [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1984     [AC_CHECK_LIB([svld], [dlopen],
1985     [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1986     [AC_CHECK_LIB([dld], [dld_link],
1987 db 941 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1988 michael 912 ])
1989     ])
1990     ])
1991     ])
1992     ])
1993     ;;
1994     esac
1995    
1996     if test "x$lt_cv_dlopen" != xno; then
1997     enable_dlopen=yes
1998     else
1999     enable_dlopen=no
2000     fi
2001    
2002     case $lt_cv_dlopen in
2003     dlopen)
2004     save_CPPFLAGS="$CPPFLAGS"
2005     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2006    
2007     save_LDFLAGS="$LDFLAGS"
2008     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2009    
2010     save_LIBS="$LIBS"
2011     LIBS="$lt_cv_dlopen_libs $LIBS"
2012    
2013     AC_CACHE_CHECK([whether a program can dlopen itself],
2014     lt_cv_dlopen_self, [dnl
2015 michael 945 _LT_TRY_DLOPEN_SELF(
2016 michael 912 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2017     lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2018     ])
2019    
2020     if test "x$lt_cv_dlopen_self" = xyes; then
2021     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2022     AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2023 michael 945 lt_cv_dlopen_self_static, [dnl
2024     _LT_TRY_DLOPEN_SELF(
2025 michael 912 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2026     lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2027     ])
2028     fi
2029    
2030     CPPFLAGS="$save_CPPFLAGS"
2031     LDFLAGS="$save_LDFLAGS"
2032     LIBS="$save_LIBS"
2033     ;;
2034     esac
2035    
2036     case $lt_cv_dlopen_self in
2037     yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2038     *) enable_dlopen_self=unknown ;;
2039     esac
2040    
2041     case $lt_cv_dlopen_self_static in
2042     yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2043     *) enable_dlopen_self_static=unknown ;;
2044     esac
2045     fi
2046 michael 945 _LT_DECL([dlopen_support], [enable_dlopen], [0],
2047     [Whether dlopen is supported])
2048     _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2049     [Whether dlopen of programs is supported])
2050     _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2051     [Whether dlopen of statically linked programs is supported])
2052     ])# LT_SYS_DLOPEN_SELF
2053 michael 912
2054 michael 945 # Old name:
2055     AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2056     dnl aclocal-1.4 backwards compatibility:
2057     dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2058 michael 912
2059 michael 945
2060     # _LT_COMPILER_C_O([TAGNAME])
2061     # ---------------------------
2062     # Check to see if options -c and -o are simultaneously supported by compiler.
2063     # This macro does not hard code the compiler like AC_PROG_CC_C_O.
2064     m4_defun([_LT_COMPILER_C_O],
2065     [m4_require([_LT_DECL_SED])dnl
2066     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2067     m4_require([_LT_TAG_COMPILER])dnl
2068 michael 912 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2069 michael 945 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2070     [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2071     $RM -r conftest 2>/dev/null
2072 michael 912 mkdir conftest
2073     cd conftest
2074     mkdir out
2075     echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2076    
2077     lt_compiler_flag="-o out/conftest2.$ac_objext"
2078     # Insert the option either (1) after the last *FLAGS variable, or
2079     # (2) before a word containing "conftest.", or (3) at the end.
2080     # Note that $ac_compile itself does not contain backslashes and begins
2081     # with a dollar sign (not a hyphen), so the echo should work correctly.
2082     lt_compile=`echo "$ac_compile" | $SED \
2083     -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2084     -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2085     -e 's:$: $lt_compiler_flag:'`
2086 michael 1094 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2087 michael 912 (eval "$lt_compile" 2>out/conftest.err)
2088     ac_status=$?
2089     cat out/conftest.err >&AS_MESSAGE_LOG_FD
2090 michael 1094 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2091 michael 912 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2092     then
2093     # The compiler can only warn and ignore the option if not recognized
2094     # So say no if there are warnings
2095 michael 1094 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
2096 michael 912 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2097     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2098 michael 945 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2099 michael 912 fi
2100     fi
2101     chmod u+w . 2>&AS_MESSAGE_LOG_FD
2102 michael 945 $RM conftest*
2103 michael 912 # SGI C++ compiler will create directory out/ii_files/ for
2104     # template instantiation
2105 michael 945 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2106     $RM out/* && rmdir out
2107 michael 912 cd ..
2108 michael 945 $RM -r conftest
2109     $RM conftest*
2110 michael 912 ])
2111 michael 945 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2112     [Does compiler simultaneously support -c and -o options?])
2113     ])# _LT_COMPILER_C_O
2114 michael 912
2115    
2116 michael 945 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
2117     # ----------------------------------
2118 michael 912 # Check to see if we can do hard links to lock some files if needed
2119 michael 945 m4_defun([_LT_COMPILER_FILE_LOCKS],
2120     [m4_require([_LT_ENABLE_LOCK])dnl
2121     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2122     _LT_COMPILER_C_O([$1])
2123 michael 912
2124     hard_links="nottested"
2125 michael 945 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2126 michael 912 # do not overwrite the value of need_locks provided by the user
2127     AC_MSG_CHECKING([if we can lock with hard links])
2128     hard_links=yes
2129 michael 945 $RM conftest*
2130 michael 912 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2131     touch conftest.a
2132     ln conftest.a conftest.b 2>&5 || hard_links=no
2133     ln conftest.a conftest.b 2>/dev/null && hard_links=no
2134     AC_MSG_RESULT([$hard_links])
2135     if test "$hard_links" = no; then
2136     AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2137     need_locks=warn
2138     fi
2139     else
2140     need_locks=no
2141     fi
2142 michael 945 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2143     ])# _LT_COMPILER_FILE_LOCKS
2144 michael 912
2145    
2146 michael 945 # _LT_CHECK_OBJDIR
2147     # ----------------
2148     m4_defun([_LT_CHECK_OBJDIR],
2149 michael 912 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2150     [rm -f .libs 2>/dev/null
2151     mkdir .libs 2>/dev/null
2152     if test -d .libs; then
2153     lt_cv_objdir=.libs
2154     else
2155     # MS-DOS does not allow filenames that begin with a dot.
2156     lt_cv_objdir=_libs
2157     fi
2158     rmdir .libs 2>/dev/null])
2159     objdir=$lt_cv_objdir
2160 michael 945 _LT_DECL([], [objdir], [0],
2161     [The name of the directory that contains temporary libtool files])dnl
2162     m4_pattern_allow([LT_OBJDIR])dnl
2163     AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2164     [Define to the sub-directory in which libtool stores uninstalled libraries.])
2165     ])# _LT_CHECK_OBJDIR
2166 michael 912
2167    
2168 michael 945 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2169     # --------------------------------------
2170 michael 912 # Check hardcoding attributes.
2171 michael 945 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2172 michael 912 [AC_MSG_CHECKING([how to hardcode library paths into programs])
2173 michael 945 _LT_TAGVAR(hardcode_action, $1)=
2174     if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2175     test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2176     test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2177 michael 912
2178 michael 945 # We can hardcode non-existent directories.
2179     if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2180 michael 912 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2181     # have to relink, otherwise we might link with an installed library
2182     # when we should be linking with a yet-to-be-installed one
2183 michael 945 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2184     test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2185 michael 912 # Linking always hardcodes the temporary library directory.
2186 michael 945 _LT_TAGVAR(hardcode_action, $1)=relink
2187 michael 912 else
2188     # We can link without hardcoding, and we can hardcode nonexisting dirs.
2189 michael 945 _LT_TAGVAR(hardcode_action, $1)=immediate
2190 michael 912 fi
2191     else
2192     # We cannot hardcode anything, or else we can only hardcode existing
2193     # directories.
2194 michael 945 _LT_TAGVAR(hardcode_action, $1)=unsupported
2195 michael 912 fi
2196 michael 945 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2197 michael 912
2198 michael 945 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2199     test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2200 michael 912 # Fast installation is not supported
2201     enable_fast_install=no
2202     elif test "$shlibpath_overrides_runpath" = yes ||
2203     test "$enable_shared" = no; then
2204     # Fast installation is not necessary
2205     enable_fast_install=needless
2206     fi
2207 michael 945 _LT_TAGDECL([], [hardcode_action], [0],
2208     [How to hardcode a shared library path into an executable])
2209     ])# _LT_LINKER_HARDCODE_LIBPATH
2210 michael 912
2211    
2212 michael 945 # _LT_CMD_STRIPLIB
2213     # ----------------
2214     m4_defun([_LT_CMD_STRIPLIB],
2215     [m4_require([_LT_DECL_EGREP])
2216     striplib=
2217 michael 912 old_striplib=
2218     AC_MSG_CHECKING([whether stripping libraries is possible])
2219 michael 945 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2220 michael 912 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2221     test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2222     AC_MSG_RESULT([yes])
2223     else
2224     # FIXME - insert some real tests, host_os isn't really good enough
2225     case $host_os in
2226 michael 945 darwin*)
2227     if test -n "$STRIP" ; then
2228     striplib="$STRIP -x"
2229     old_striplib="$STRIP -S"
2230     AC_MSG_RESULT([yes])
2231     else
2232     AC_MSG_RESULT([no])
2233     fi
2234 michael 912 ;;
2235 michael 945 *)
2236     AC_MSG_RESULT([no])
2237     ;;
2238 michael 912 esac
2239     fi
2240 michael 945 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2241     _LT_DECL([], [striplib], [1])
2242     ])# _LT_CMD_STRIPLIB
2243 michael 912
2244    
2245 michael 945 # _LT_SYS_DYNAMIC_LINKER([TAG])
2246 michael 912 # -----------------------------
2247     # PORTME Fill in your ld.so characteristics
2248 michael 945 m4_defun([_LT_SYS_DYNAMIC_LINKER],
2249     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2250     m4_require([_LT_DECL_EGREP])dnl
2251     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2252     m4_require([_LT_DECL_OBJDUMP])dnl
2253     m4_require([_LT_DECL_SED])dnl
2254 michael 1094 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2255 michael 912 AC_MSG_CHECKING([dynamic linker characteristics])
2256 michael 945 m4_if([$1],
2257     [], [
2258 michael 912 if test "$GCC" = yes; then
2259     case $host_os in
2260     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2261     *) lt_awk_arg="/^libraries:/" ;;
2262     esac
2263 michael 1094 case $host_os in
2264     mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
2265     *) lt_sed_strip_eq="s,=/,/,g" ;;
2266     esac
2267     lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
2268     case $lt_search_path_spec in
2269     *\;*)
2270 michael 912 # if the path contains ";" then we assume it to be the separator
2271     # otherwise default to the standard path separator (i.e. ":") - it is
2272     # assumed that no part of a normal pathname contains ";" but that should
2273     # okay in the real world where ";" in dirpaths is itself problematic.
2274 michael 1094 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
2275     ;;
2276     *)
2277     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
2278     ;;
2279     esac
2280 michael 912 # Ok, now we have the path, separated by spaces, we can step through it
2281     # and add multilib dir if necessary.
2282     lt_tmp_lt_search_path_spec=
2283     lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2284     for lt_sys_path in $lt_search_path_spec; do
2285     if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2286     lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2287     else
2288     test -d "$lt_sys_path" && \
2289     lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2290     fi
2291     done
2292 michael 1094 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2293 michael 912 BEGIN {RS=" "; FS="/|\n";} {
2294     lt_foo="";
2295     lt_count=0;
2296     for (lt_i = NF; lt_i > 0; lt_i--) {
2297     if ($lt_i != "" && $lt_i != ".") {
2298     if ($lt_i == "..") {
2299     lt_count++;
2300     } else {
2301     if (lt_count == 0) {
2302     lt_foo="/" $lt_i lt_foo;
2303     } else {
2304     lt_count--;
2305     }
2306     }
2307     }
2308     }
2309     if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2310     if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2311     }'`
2312 michael 1094 # AWK program above erroneously prepends '/' to C:/dos/paths
2313     # for these hosts.
2314     case $host_os in
2315     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
2316     $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
2317     esac
2318     sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
2319 michael 912 else
2320     sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2321     fi])
2322 michael 945 library_names_spec=
2323     libname_spec='lib$name'
2324     soname_spec=
2325     shrext_cmds=".so"
2326     postinstall_cmds=
2327     postuninstall_cmds=
2328     finish_cmds=
2329     finish_eval=
2330     shlibpath_var=
2331     shlibpath_overrides_runpath=unknown
2332     version_type=none
2333     dynamic_linker="$host_os ld.so"
2334     sys_lib_dlsearch_path_spec="/lib /usr/lib"
2335 michael 912 need_lib_prefix=unknown
2336     hardcode_into_libs=no
2337    
2338     # when you set need_version to no, make sure it does not cause -set_version
2339     # flags to be left without arguments
2340     need_version=unknown
2341    
2342     case $host_os in
2343     aix3*)
2344 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2345 michael 912 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2346     shlibpath_var=LIBPATH
2347    
2348     # AIX 3 has no versioning support, so we append a major version to the name.
2349     soname_spec='${libname}${release}${shared_ext}$major'
2350     ;;
2351    
2352 db 941 aix[[4-9]]*)
2353 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2354 michael 912 need_lib_prefix=no
2355     need_version=no
2356     hardcode_into_libs=yes
2357     if test "$host_cpu" = ia64; then
2358     # AIX 5 supports IA64
2359     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2360     shlibpath_var=LD_LIBRARY_PATH
2361     else
2362     # With GCC up to 2.95.x, collect2 would create an import file
2363     # for dependence libraries. The import file would start with
2364     # the line `#! .'. This would cause the generated library to
2365     # depend on `.', always an invalid library. This was fixed in
2366     # development snapshots of GCC prior to 3.0.
2367     case $host_os in
2368     aix4 | aix4.[[01]] | aix4.[[01]].*)
2369     if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2370     echo ' yes '
2371 michael 945 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2372 michael 912 :
2373     else
2374     can_build_shared=no
2375     fi
2376     ;;
2377     esac
2378     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2379     # soname into executable. Probably we can add versioning support to
2380     # collect2, so additional links can be useful in future.
2381     if test "$aix_use_runtimelinking" = yes; then
2382     # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2383     # instead of lib<name>.a to let people know that these are not
2384     # typical AIX shared libraries.
2385     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2386     else
2387     # We preserve .a as extension for shared libraries through AIX4.2
2388     # and later when we are not doing run time linking.
2389     library_names_spec='${libname}${release}.a $libname.a'
2390     soname_spec='${libname}${release}${shared_ext}$major'
2391     fi
2392     shlibpath_var=LIBPATH
2393     fi
2394     ;;
2395    
2396     amigaos*)
2397 michael 945 case $host_cpu in
2398     powerpc)
2399     # Since July 2007 AmigaOS4 officially supports .so libraries.
2400     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2401     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2402     ;;
2403     m68k)
2404     library_names_spec='$libname.ixlibrary $libname.a'
2405     # Create ${libname}_ixlibrary.a entries in /sys/libs.
2406 michael 1094 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2407 michael 945 ;;
2408     esac
2409 michael 912 ;;
2410    
2411     beos*)
2412     library_names_spec='${libname}${shared_ext}'
2413     dynamic_linker="$host_os ld.so"
2414     shlibpath_var=LIBRARY_PATH
2415     ;;
2416    
2417     bsdi[[45]]*)
2418 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2419 michael 912 need_version=no
2420     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2421     soname_spec='${libname}${release}${shared_ext}$major'
2422     finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2423     shlibpath_var=LD_LIBRARY_PATH
2424     sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2425     sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2426     # the default ld.so.conf also contains /usr/contrib/lib and
2427     # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2428     # libtool to hard-code these into programs
2429     ;;
2430    
2431 michael 945 cygwin* | mingw* | pw32* | cegcc*)
2432 michael 912 version_type=windows
2433     shrext_cmds=".dll"
2434     need_version=no
2435     need_lib_prefix=no
2436    
2437 michael 1106 case $GCC,$cc_basename in
2438     yes,*)
2439     # gcc
2440 michael 912 library_names_spec='$libname.dll.a'
2441     # DLL is installed to $(libdir)/../bin by postinstall_cmds
2442     postinstall_cmds='base_file=`basename \${file}`~
2443 michael 945 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2444 michael 912 dldir=$destdir/`dirname \$dlpath`~
2445     test -d \$dldir || mkdir -p \$dldir~
2446     $install_prog $dir/$dlname \$dldir/$dlname~
2447 michael 945 chmod a+x \$dldir/$dlname~
2448     if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2449     eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2450     fi'
2451 michael 912 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2452     dlpath=$dir/\$dldll~
2453 michael 945 $RM \$dlpath'
2454 michael 912 shlibpath_overrides_runpath=yes
2455    
2456     case $host_os in
2457     cygwin*)
2458     # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2459     soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2460 michael 1094 m4_if([$1], [],[
2461     sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
2462 michael 912 ;;
2463 michael 945 mingw* | cegcc*)
2464 michael 912 # MinGW DLLs use traditional 'lib' prefix
2465     soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2466     ;;
2467     pw32*)
2468     # pw32 DLLs use 'pw' prefix rather than 'lib'
2469     library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2470     ;;
2471     esac
2472 michael 1106 dynamic_linker='Win32 ld.exe'
2473 michael 912 ;;
2474    
2475 michael 1106 *,cl*)
2476     # Native MSVC
2477     libname_spec='$name'
2478     soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2479     library_names_spec='${libname}.dll.lib'
2480    
2481     case $build_os in
2482     mingw*)
2483     sys_lib_search_path_spec=
2484     lt_save_ifs=$IFS
2485     IFS=';'
2486     for lt_path in $LIB
2487     do
2488     IFS=$lt_save_ifs
2489     # Let DOS variable expansion print the short 8.3 style file name.
2490     lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
2491     sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
2492     done
2493     IFS=$lt_save_ifs
2494     # Convert to MSYS style.
2495     sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
2496     ;;
2497     cygwin*)
2498     # Convert to unix form, then to dos form, then back to unix form
2499     # but this time dos style (no spaces!) so that the unix form looks
2500     # like /cygdrive/c/PROGRA~1:/cygdr...
2501     sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
2502     sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
2503     sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2504     ;;
2505     *)
2506     sys_lib_search_path_spec="$LIB"
2507     if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2508     # It is most probably a Windows format PATH.
2509     sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2510     else
2511     sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2512     fi
2513     # FIXME: find the short name or the path components, as spaces are
2514     # common. (e.g. "Program Files" -> "PROGRA~1")
2515     ;;
2516     esac
2517    
2518     # DLL is installed to $(libdir)/../bin by postinstall_cmds
2519     postinstall_cmds='base_file=`basename \${file}`~
2520     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2521     dldir=$destdir/`dirname \$dlpath`~
2522     test -d \$dldir || mkdir -p \$dldir~
2523     $install_prog $dir/$dlname \$dldir/$dlname'
2524     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2525     dlpath=$dir/\$dldll~
2526     $RM \$dlpath'
2527     shlibpath_overrides_runpath=yes
2528     dynamic_linker='Win32 link.exe'
2529     ;;
2530    
2531 michael 912 *)
2532 michael 1106 # Assume MSVC wrapper
2533 michael 912 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2534 michael 1106 dynamic_linker='Win32 ld.exe'
2535 michael 912 ;;
2536     esac
2537     # FIXME: first we should search . and the directory the executable is in
2538     shlibpath_var=PATH
2539     ;;
2540    
2541     darwin* | rhapsody*)
2542     dynamic_linker="$host_os dyld"
2543     version_type=darwin
2544     need_lib_prefix=no
2545     need_version=no
2546 michael 945 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2547 michael 912 soname_spec='${libname}${release}${major}$shared_ext'
2548     shlibpath_overrides_runpath=yes
2549     shlibpath_var=DYLD_LIBRARY_PATH
2550     shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2551 michael 945 m4_if([$1], [],[
2552     sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2553 michael 912 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2554     ;;
2555    
2556     dgux*)
2557 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2558 michael 912 need_lib_prefix=no
2559     need_version=no
2560     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2561     soname_spec='${libname}${release}${shared_ext}$major'
2562     shlibpath_var=LD_LIBRARY_PATH
2563     ;;
2564    
2565     freebsd* | dragonfly*)
2566     # DragonFly does not have aout. When/if they implement a new
2567     # versioning mechanism, adjust this.
2568     if test -x /usr/bin/objformat; then
2569     objformat=`/usr/bin/objformat`
2570     else
2571     case $host_os in
2572 michael 1257 freebsd[[23]].*) objformat=aout ;;
2573 michael 912 *) objformat=elf ;;
2574     esac
2575     fi
2576     version_type=freebsd-$objformat
2577     case $version_type in
2578     freebsd-elf*)
2579     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2580     need_version=no
2581     need_lib_prefix=no
2582     ;;
2583     freebsd-*)
2584     library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2585     need_version=yes
2586     ;;
2587     esac
2588     shlibpath_var=LD_LIBRARY_PATH
2589     case $host_os in
2590 michael 1257 freebsd2.*)
2591 michael 912 shlibpath_overrides_runpath=yes
2592     ;;
2593     freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2594     shlibpath_overrides_runpath=yes
2595     hardcode_into_libs=yes
2596     ;;
2597     freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2598     freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2599     shlibpath_overrides_runpath=no
2600     hardcode_into_libs=yes
2601     ;;
2602     *) # from 4.6 on, and DragonFly
2603     shlibpath_overrides_runpath=yes
2604     hardcode_into_libs=yes
2605     ;;
2606     esac
2607     ;;
2608    
2609     gnu*)
2610 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2611 michael 912 need_lib_prefix=no
2612     need_version=no
2613     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2614     soname_spec='${libname}${release}${shared_ext}$major'
2615     shlibpath_var=LD_LIBRARY_PATH
2616 michael 1257 shlibpath_overrides_runpath=no
2617 michael 912 hardcode_into_libs=yes
2618     ;;
2619    
2620 michael 1094 haiku*)
2621 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2622 michael 1094 need_lib_prefix=no
2623     need_version=no
2624     dynamic_linker="$host_os runtime_loader"
2625     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2626     soname_spec='${libname}${release}${shared_ext}$major'
2627     shlibpath_var=LIBRARY_PATH
2628     shlibpath_overrides_runpath=yes
2629     sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
2630     hardcode_into_libs=yes
2631     ;;
2632    
2633 michael 912 hpux9* | hpux10* | hpux11*)
2634     # Give a soname corresponding to the major version so that dld.sl refuses to
2635     # link against other versions.
2636     version_type=sunos
2637     need_lib_prefix=no
2638     need_version=no
2639     case $host_cpu in
2640     ia64*)
2641     shrext_cmds='.so'
2642     hardcode_into_libs=yes
2643     dynamic_linker="$host_os dld.so"
2644     shlibpath_var=LD_LIBRARY_PATH
2645     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2646     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2647     soname_spec='${libname}${release}${shared_ext}$major'
2648     if test "X$HPUX_IA64_MODE" = X32; then
2649     sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2650     else
2651     sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2652     fi
2653     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2654     ;;
2655 michael 945 hppa*64*)
2656 michael 912 shrext_cmds='.sl'
2657 michael 945 hardcode_into_libs=yes
2658 michael 912 dynamic_linker="$host_os dld.sl"
2659 michael 945 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2660     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2661     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2662     soname_spec='${libname}${release}${shared_ext}$major'
2663     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2664     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2665     ;;
2666     *)
2667     shrext_cmds='.sl'
2668     dynamic_linker="$host_os dld.sl"
2669 michael 912 shlibpath_var=SHLIB_PATH
2670     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2671     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2672     soname_spec='${libname}${release}${shared_ext}$major'
2673     ;;
2674     esac
2675 michael 1094 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
2676 michael 912 postinstall_cmds='chmod 555 $lib'
2677 michael 1094 # or fails outright, so override atomically:
2678     install_override_mode=555
2679 michael 912 ;;
2680    
2681     interix[[3-9]]*)
2682 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2683 michael 912 need_lib_prefix=no
2684     need_version=no
2685     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2686     soname_spec='${libname}${release}${shared_ext}$major'
2687     dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2688     shlibpath_var=LD_LIBRARY_PATH
2689     shlibpath_overrides_runpath=no
2690     hardcode_into_libs=yes
2691     ;;
2692    
2693     irix5* | irix6* | nonstopux*)
2694     case $host_os in
2695     nonstopux*) version_type=nonstopux ;;
2696     *)
2697     if test "$lt_cv_prog_gnu_ld" = yes; then
2698 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2699 michael 912 else
2700     version_type=irix
2701     fi ;;
2702     esac
2703     need_lib_prefix=no
2704     need_version=no
2705     soname_spec='${libname}${release}${shared_ext}$major'
2706     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2707     case $host_os in
2708     irix5* | nonstopux*)
2709     libsuff= shlibsuff=
2710     ;;
2711     *)
2712     case $LD in # libtool.m4 will add one of these switches to LD
2713     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2714     libsuff= shlibsuff= libmagic=32-bit;;
2715     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2716     libsuff=32 shlibsuff=N32 libmagic=N32;;
2717     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2718     libsuff=64 shlibsuff=64 libmagic=64-bit;;
2719     *) libsuff= shlibsuff= libmagic=never-match;;
2720     esac
2721     ;;
2722     esac
2723     shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2724     shlibpath_overrides_runpath=no
2725     sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2726     sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2727     hardcode_into_libs=yes
2728     ;;
2729    
2730     # No shared lib support for Linux oldld, aout, or coff.
2731     linux*oldld* | linux*aout* | linux*coff*)
2732     dynamic_linker=no
2733     ;;
2734    
2735 michael 1257 # This must be glibc/ELF.
2736 michael 1094 linux* | k*bsd*-gnu | kopensolaris*-gnu)
2737 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2738 michael 912 need_lib_prefix=no
2739     need_version=no
2740     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2741     soname_spec='${libname}${release}${shared_ext}$major'
2742     finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2743     shlibpath_var=LD_LIBRARY_PATH
2744     shlibpath_overrides_runpath=no
2745 michael 1094
2746 michael 945 # Some binutils ld are patched to set DT_RUNPATH
2747 michael 1094 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
2748     [lt_cv_shlibpath_overrides_runpath=no
2749     save_LDFLAGS=$LDFLAGS
2750     save_libdir=$libdir
2751     eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
2752     LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
2753     AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2754     [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
2755     [lt_cv_shlibpath_overrides_runpath=yes])])
2756     LDFLAGS=$save_LDFLAGS
2757     libdir=$save_libdir
2758     ])
2759     shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
2760 michael 945
2761 michael 912 # This implies no fast_install, which is unacceptable.
2762     # Some rework will be needed to allow for fast_install
2763     # before this can be enabled.
2764     hardcode_into_libs=yes
2765    
2766     # Append ld.so.conf contents to the search path
2767     if test -f /etc/ld.so.conf; then
2768 michael 1094 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
2769 michael 1084 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2770 michael 912 fi
2771    
2772     # We used to test for /lib/ld.so.1 and disable shared libraries on
2773     # powerpc, because MkLinux only supported shared libraries with the
2774     # GNU dynamic linker. Since this was broken with cross compilers,
2775     # most powerpc-linux boxes support dynamic linking these days and
2776     # people can always --disable-shared, the test was removed, and we
2777     # assume the GNU/Linux dynamic linker is in use.
2778     dynamic_linker='GNU/Linux ld.so'
2779     ;;
2780    
2781     netbsd*)
2782     version_type=sunos
2783     need_lib_prefix=no
2784     need_version=no
2785 michael 945 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2786 michael 912 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2787     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2788     dynamic_linker='NetBSD (a.out) ld.so'
2789     else
2790     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2791     soname_spec='${libname}${release}${shared_ext}$major'
2792     dynamic_linker='NetBSD ld.elf_so'
2793     fi
2794     shlibpath_var=LD_LIBRARY_PATH
2795     shlibpath_overrides_runpath=yes
2796     hardcode_into_libs=yes
2797     ;;
2798    
2799     newsos6)
2800 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2801 michael 912 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2802     shlibpath_var=LD_LIBRARY_PATH
2803     shlibpath_overrides_runpath=yes
2804     ;;
2805    
2806 michael 945 *nto* | *qnx*)
2807     version_type=qnx
2808 michael 912 need_lib_prefix=no
2809     need_version=no
2810     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2811     soname_spec='${libname}${release}${shared_ext}$major'
2812     shlibpath_var=LD_LIBRARY_PATH
2813 michael 945 shlibpath_overrides_runpath=no
2814     hardcode_into_libs=yes
2815     dynamic_linker='ldqnx.so'
2816 michael 912 ;;
2817    
2818     openbsd*)
2819     version_type=sunos
2820     sys_lib_dlsearch_path_spec="/usr/lib"
2821     need_lib_prefix=no
2822     # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2823     case $host_os in
2824 michael 945 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2825     *) need_version=no ;;
2826 michael 912 esac
2827     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2828     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2829     shlibpath_var=LD_LIBRARY_PATH
2830 michael 945 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2831 michael 912 case $host_os in
2832     openbsd2.[[89]] | openbsd2.[[89]].*)
2833     shlibpath_overrides_runpath=no
2834     ;;
2835     *)
2836     shlibpath_overrides_runpath=yes
2837     ;;
2838     esac
2839     else
2840     shlibpath_overrides_runpath=yes
2841     fi
2842     ;;
2843    
2844     os2*)
2845     libname_spec='$name'
2846     shrext_cmds=".dll"
2847     need_lib_prefix=no
2848     library_names_spec='$libname${shared_ext} $libname.a'
2849     dynamic_linker='OS/2 ld.exe'
2850     shlibpath_var=LIBPATH
2851     ;;
2852    
2853     osf3* | osf4* | osf5*)
2854     version_type=osf
2855     need_lib_prefix=no
2856     need_version=no
2857     soname_spec='${libname}${release}${shared_ext}$major'
2858     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2859     shlibpath_var=LD_LIBRARY_PATH
2860     sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2861     sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2862     ;;
2863    
2864     rdos*)
2865     dynamic_linker=no
2866     ;;
2867    
2868     solaris*)
2869 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2870 michael 912 need_lib_prefix=no
2871     need_version=no
2872     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2873     soname_spec='${libname}${release}${shared_ext}$major'
2874     shlibpath_var=LD_LIBRARY_PATH
2875     shlibpath_overrides_runpath=yes
2876     hardcode_into_libs=yes
2877     # ldd complains unless libraries are executable
2878     postinstall_cmds='chmod +x $lib'
2879     ;;
2880    
2881     sunos4*)
2882     version_type=sunos
2883     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2884     finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2885     shlibpath_var=LD_LIBRARY_PATH
2886     shlibpath_overrides_runpath=yes
2887     if test "$with_gnu_ld" = yes; then
2888     need_lib_prefix=no
2889     fi
2890     need_version=yes
2891     ;;
2892    
2893     sysv4 | sysv4.3*)
2894 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2895 michael 912 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2896     soname_spec='${libname}${release}${shared_ext}$major'
2897     shlibpath_var=LD_LIBRARY_PATH
2898     case $host_vendor in
2899     sni)
2900     shlibpath_overrides_runpath=no
2901     need_lib_prefix=no
2902     runpath_var=LD_RUN_PATH
2903     ;;
2904     siemens)
2905     need_lib_prefix=no
2906     ;;
2907     motorola)
2908     need_lib_prefix=no
2909     need_version=no
2910     shlibpath_overrides_runpath=no
2911     sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2912     ;;
2913     esac
2914     ;;
2915    
2916     sysv4*MP*)
2917     if test -d /usr/nec ;then
2918 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2919 michael 912 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2920     soname_spec='$libname${shared_ext}.$major'
2921     shlibpath_var=LD_LIBRARY_PATH
2922     fi
2923     ;;
2924    
2925     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2926     version_type=freebsd-elf
2927     need_lib_prefix=no
2928     need_version=no
2929     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2930     soname_spec='${libname}${release}${shared_ext}$major'
2931     shlibpath_var=LD_LIBRARY_PATH
2932 michael 945 shlibpath_overrides_runpath=yes
2933 michael 912 hardcode_into_libs=yes
2934     if test "$with_gnu_ld" = yes; then
2935     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2936     else
2937     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2938     case $host_os in
2939     sco3.2v5*)
2940     sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2941     ;;
2942     esac
2943     fi
2944     sys_lib_dlsearch_path_spec='/usr/lib'
2945     ;;
2946    
2947 michael 945 tpf*)
2948     # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
2949 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2950 michael 945 need_lib_prefix=no
2951     need_version=no
2952     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2953     shlibpath_var=LD_LIBRARY_PATH
2954     shlibpath_overrides_runpath=no
2955     hardcode_into_libs=yes
2956     ;;
2957    
2958 michael 912 uts4*)
2959 michael 1257 version_type=linux # correct to gnu/linux during the next big refactor
2960 michael 912 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2961     soname_spec='${libname}${release}${shared_ext}$major'
2962     shlibpath_var=LD_LIBRARY_PATH
2963     ;;
2964    
2965     *)
2966     dynamic_linker=no
2967     ;;
2968     esac
2969     AC_MSG_RESULT([$dynamic_linker])
2970     test "$dynamic_linker" = no && can_build_shared=no
2971    
2972     variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2973     if test "$GCC" = yes; then
2974     variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2975     fi
2976    
2977 michael 945 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
2978     sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
2979 michael 912 fi
2980 michael 945 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
2981     sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
2982     fi
2983 michael 912
2984 michael 945 _LT_DECL([], [variables_saved_for_relink], [1],
2985     [Variables whose values should be saved in libtool wrapper scripts and
2986     restored at link time])
2987     _LT_DECL([], [need_lib_prefix], [0],
2988     [Do we need the "lib" prefix for modules?])
2989     _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
2990     _LT_DECL([], [version_type], [0], [Library versioning type])
2991     _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
2992     _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
2993     _LT_DECL([], [shlibpath_overrides_runpath], [0],
2994     [Is shlibpath searched before the hard-coded library search path?])
2995     _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
2996     _LT_DECL([], [library_names_spec], [1],
2997     [[List of archive names. First name is the real one, the rest are links.
2998     The last name is the one that the linker finds with -lNAME]])
2999     _LT_DECL([], [soname_spec], [1],
3000     [[The coded name of the library, if different from the real name]])
3001 michael 1094 _LT_DECL([], [install_override_mode], [1],
3002     [Permission mode override for installation of shared libraries])
3003 michael 945 _LT_DECL([], [postinstall_cmds], [2],
3004     [Command to use after installation of a shared archive])
3005     _LT_DECL([], [postuninstall_cmds], [2],
3006     [Command to use after uninstallation of a shared archive])
3007     _LT_DECL([], [finish_cmds], [2],
3008     [Commands used to finish a libtool library installation in a directory])
3009     _LT_DECL([], [finish_eval], [1],
3010     [[As "finish_cmds", except a single script fragment to be evaled but
3011     not shown]])
3012     _LT_DECL([], [hardcode_into_libs], [0],
3013     [Whether we should hardcode library paths into libraries])
3014     _LT_DECL([], [sys_lib_search_path_spec], [2],
3015     [Compile-time system search path for libraries])
3016     _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3017     [Run-time system search path for libraries])
3018     ])# _LT_SYS_DYNAMIC_LINKER
3019 michael 912
3020    
3021 michael 945 # _LT_PATH_TOOL_PREFIX(TOOL)
3022 michael 912 # --------------------------
3023     # find a file program which can recognize shared library
3024 michael 945 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3025     [m4_require([_LT_DECL_EGREP])dnl
3026 michael 912 AC_MSG_CHECKING([for $1])
3027     AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3028     [case $MAGIC_CMD in
3029     [[\\/*] | ?:[\\/]*])
3030     lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3031     ;;
3032     *)
3033     lt_save_MAGIC_CMD="$MAGIC_CMD"
3034     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3035     dnl $ac_dummy forces splitting on constant user-supplied paths.
3036     dnl POSIX.2 word splitting is done only on the output of word expansions,
3037     dnl not every word. This closes a longstanding sh security hole.
3038 michael 945 ac_dummy="m4_if([$2], , $PATH, [$2])"
3039 michael 912 for ac_dir in $ac_dummy; do
3040     IFS="$lt_save_ifs"
3041     test -z "$ac_dir" && ac_dir=.
3042     if test -f $ac_dir/$1; then
3043     lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3044     if test -n "$file_magic_test_file"; then
3045     case $deplibs_check_method in
3046     "file_magic "*)
3047     file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3048     MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3049     if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3050     $EGREP "$file_magic_regex" > /dev/null; then
3051     :
3052     else
3053 michael 945 cat <<_LT_EOF 1>&2
3054 michael 912
3055     *** Warning: the command libtool uses to detect shared libraries,
3056     *** $file_magic_cmd, produces output that libtool cannot recognize.
3057     *** The result is that libtool may fail to recognize shared libraries
3058     *** as such. This will affect the creation of libtool libraries that
3059     *** depend on shared libraries, but programs linked with such libtool
3060     *** libraries will work regardless of this problem. Nevertheless, you
3061     *** may want to report the problem to your system manager and/or to
3062     *** bug-libtool@gnu.org
3063    
3064 michael 945 _LT_EOF
3065 michael 912 fi ;;
3066     esac
3067     fi
3068     break
3069     fi
3070     done
3071     IFS="$lt_save_ifs"
3072     MAGIC_CMD="$lt_save_MAGIC_CMD"
3073     ;;
3074     esac])
3075     MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3076     if test -n "$MAGIC_CMD"; then
3077     AC_MSG_RESULT($MAGIC_CMD)
3078     else
3079     AC_MSG_RESULT(no)
3080     fi
3081 michael 945 _LT_DECL([], [MAGIC_CMD], [0],
3082     [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3083     ])# _LT_PATH_TOOL_PREFIX
3084 michael 912
3085 michael 945 # Old name:
3086     AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3087     dnl aclocal-1.4 backwards compatibility:
3088     dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3089 michael 912
3090 michael 945
3091     # _LT_PATH_MAGIC
3092     # --------------
3093 michael 912 # find a file program which can recognize a shared library
3094 michael 945 m4_defun([_LT_PATH_MAGIC],
3095     [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3096 michael 912 if test -z "$lt_cv_path_MAGIC_CMD"; then
3097     if test -n "$ac_tool_prefix"; then
3098 michael 945 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3099 michael 912 else
3100     MAGIC_CMD=:
3101     fi
3102     fi
3103 michael 945 ])# _LT_PATH_MAGIC
3104 michael 912
3105    
3106 michael 945 # LT_PATH_LD
3107 michael 912 # ----------
3108     # find the pathname to the GNU or non-GNU linker
3109 michael 945 AC_DEFUN([LT_PATH_LD],
3110     [AC_REQUIRE([AC_PROG_CC])dnl
3111     AC_REQUIRE([AC_CANONICAL_HOST])dnl
3112     AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3113     m4_require([_LT_DECL_SED])dnl
3114     m4_require([_LT_DECL_EGREP])dnl
3115 michael 1094 m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
3116 michael 945
3117     AC_ARG_WITH([gnu-ld],
3118     [AS_HELP_STRING([--with-gnu-ld],
3119 michael 912 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3120     [test "$withval" = no || with_gnu_ld=yes],
3121 michael 945 [with_gnu_ld=no])dnl
3122    
3123 michael 912 ac_prog=ld
3124     if test "$GCC" = yes; then
3125     # Check if gcc -print-prog-name=ld gives a path.
3126     AC_MSG_CHECKING([for ld used by $CC])
3127     case $host in
3128     *-*-mingw*)
3129     # gcc leaves a trailing carriage return which upsets mingw
3130     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3131     *)
3132     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3133     esac
3134     case $ac_prog in
3135     # Accept absolute paths.
3136     [[\\/]]* | ?:[[\\/]]*)
3137     re_direlt='/[[^/]][[^/]]*/\.\./'
3138     # Canonicalize the pathname of ld
3139 michael 945 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3140     while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3141     ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3142 michael 912 done
3143     test -z "$LD" && LD="$ac_prog"
3144     ;;
3145     "")
3146     # If it fails, then pretend we aren't using GCC.
3147     ac_prog=ld
3148     ;;
3149     *)
3150     # If it is relative, then search for the first ld in PATH.
3151     with_gnu_ld=unknown
3152     ;;
3153     esac
3154     elif test "$with_gnu_ld" = yes; then
3155     AC_MSG_CHECKING([for GNU ld])
3156     else
3157     AC_MSG_CHECKING([for non-GNU ld])
3158     fi
3159     AC_CACHE_VAL(lt_cv_path_LD,
3160     [if test -z "$LD"; then
3161     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3162     for ac_dir in $PATH; do
3163     IFS="$lt_save_ifs"
3164     test -z "$ac_dir" && ac_dir=.
3165     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3166     lt_cv_path_LD="$ac_dir/$ac_prog"
3167     # Check to see if the program is GNU ld. I'd rather use --version,
3168     # but apparently some variants of GNU ld only accept -v.
3169     # Break only if it was the GNU/non-GNU ld that we prefer.
3170     case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3171     *GNU* | *'with BFD'*)
3172     test "$with_gnu_ld" != no && break
3173     ;;
3174     *)
3175     test "$with_gnu_ld" != yes && break
3176     ;;
3177     esac
3178     fi
3179     done
3180     IFS="$lt_save_ifs"
3181     else
3182     lt_cv_path_LD="$LD" # Let the user override the test with a path.
3183     fi])
3184     LD="$lt_cv_path_LD"
3185     if test -n "$LD"; then
3186     AC_MSG_RESULT($LD)
3187     else
3188     AC_MSG_RESULT(no)
3189     fi
3190     test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3191 michael 945 _LT_PATH_LD_GNU
3192     AC_SUBST([LD])
3193 michael 912
3194 michael 945 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3195     ])# LT_PATH_LD
3196 michael 912
3197 michael 945 # Old names:
3198     AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3199     AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3200     dnl aclocal-1.4 backwards compatibility:
3201     dnl AC_DEFUN([AM_PROG_LD], [])
3202     dnl AC_DEFUN([AC_PROG_LD], [])
3203    
3204    
3205     # _LT_PATH_LD_GNU
3206     #- --------------
3207     m4_defun([_LT_PATH_LD_GNU],
3208     [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3209 michael 912 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
3210     case `$LD -v 2>&1 </dev/null` in
3211     *GNU* | *'with BFD'*)
3212     lt_cv_prog_gnu_ld=yes
3213     ;;
3214     *)
3215     lt_cv_prog_gnu_ld=no
3216     ;;
3217     esac])
3218     with_gnu_ld=$lt_cv_prog_gnu_ld
3219 michael 945 ])# _LT_PATH_LD_GNU
3220 michael 912
3221    
3222 michael 945 # _LT_CMD_RELOAD
3223     # --------------
3224 michael 912 # find reload flag for linker
3225     # -- PORTME Some linkers may need a different reload flag.
3226 michael 945 m4_defun([_LT_CMD_RELOAD],
3227 michael 912 [AC_CACHE_CHECK([for $LD option to reload object files],
3228     lt_cv_ld_reload_flag,
3229     [lt_cv_ld_reload_flag='-r'])
3230     reload_flag=$lt_cv_ld_reload_flag
3231     case $reload_flag in
3232     "" | " "*) ;;
3233     *) reload_flag=" $reload_flag" ;;
3234     esac
3235     reload_cmds='$LD$reload_flag -o $output$reload_objs'
3236     case $host_os in
3237 michael 1106 cygwin* | mingw* | pw32* | cegcc*)
3238     if test "$GCC" != yes; then
3239     reload_cmds=false
3240     fi
3241     ;;
3242 michael 912 darwin*)
3243     if test "$GCC" = yes; then
3244     reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3245     else
3246     reload_cmds='$LD$reload_flag -o $output$reload_objs'
3247     fi
3248     ;;
3249     esac
3250 michael 1094 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3251     _LT_TAGDECL([], [reload_cmds], [2])dnl
3252 michael 945 ])# _LT_CMD_RELOAD
3253 michael 912
3254    
3255 michael 945 # _LT_CHECK_MAGIC_METHOD
3256     # ----------------------
3257 michael 912 # how to check for library dependencies
3258     # -- PORTME fill in with the dynamic library characteristics
3259 michael 945 m4_defun([_LT_CHECK_MAGIC_METHOD],
3260     [m4_require([_LT_DECL_EGREP])
3261     m4_require([_LT_DECL_OBJDUMP])
3262     AC_CACHE_CHECK([how to recognize dependent libraries],
3263 michael 912 lt_cv_deplibs_check_method,
3264     [lt_cv_file_magic_cmd='$MAGIC_CMD'
3265     lt_cv_file_magic_test_file=
3266     lt_cv_deplibs_check_method='unknown'
3267     # Need to set the preceding variable on all platforms that support
3268     # interlibrary dependencies.
3269     # 'none' -- dependencies not supported.
3270     # `unknown' -- same as none, but documents that we really don't know.
3271     # 'pass_all' -- all dependencies passed with no checks.
3272     # 'test_compile' -- check by making test program.
3273     # 'file_magic [[regex]]' -- check by looking for files in library path
3274     # which responds to the $file_magic_cmd with a given extended regex.
3275     # If you have `file' or equivalent on your system and you're not sure
3276     # whether `pass_all' will *always* work, you probably want this one.
3277    
3278     case $host_os in
3279 db 941 aix[[4-9]]*)
3280 michael 912 lt_cv_deplibs_check_method=pass_all
3281     ;;
3282    
3283     beos*)
3284     lt_cv_deplibs_check_method=pass_all
3285     ;;
3286    
3287     bsdi[[45]]*)
3288     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3289     lt_cv_file_magic_cmd='/usr/bin/file -L'
3290     lt_cv_file_magic_test_file=/shlib/libc.so
3291     ;;
3292    
3293     cygwin*)
3294     # func_win32_libid is a shell function defined in ltmain.sh
3295     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3296     lt_cv_file_magic_cmd='func_win32_libid'
3297     ;;
3298    
3299     mingw* | pw32*)
3300     # Base MSYS/MinGW do not provide the 'file' command needed by
3301     # func_win32_libid shell function, so use a weaker test based on 'objdump',
3302     # unless we find 'file', for example because we are cross-compiling.
3303 michael 1094 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
3304     if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
3305 michael 912 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3306     lt_cv_file_magic_cmd='func_win32_libid'
3307     else
3308 michael 1094 # Keep this pattern in sync with the one in func_win32_libid.
3309     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
3310 michael 912 lt_cv_file_magic_cmd='$OBJDUMP -f'
3311     fi
3312     ;;
3313    
3314 michael 1094 cegcc*)
3315 michael 945 # use the weaker test based on 'objdump'. See mingw*.
3316     lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3317     lt_cv_file_magic_cmd='$OBJDUMP -f'
3318     ;;
3319    
3320 michael 912 darwin* | rhapsody*)
3321     lt_cv_deplibs_check_method=pass_all
3322     ;;
3323    
3324     freebsd* | dragonfly*)
3325 michael 945 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3326 michael 912 case $host_cpu in
3327     i*86 )
3328     # Not sure whether the presence of OpenBSD here was a mistake.
3329     # Let's accept both of them until this is cleared up.
3330     lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3331     lt_cv_file_magic_cmd=/usr/bin/file
3332     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3333     ;;
3334     esac
3335     else
3336     lt_cv_deplibs_check_method=pass_all
3337     fi
3338     ;;
3339    
3340     gnu*)
3341     lt_cv_deplibs_check_method=pass_all
3342     ;;
3343    
3344 michael 1094 haiku*)
3345     lt_cv_deplibs_check_method=pass_all
3346     ;;
3347    
3348 michael 912 hpux10.20* | hpux11*)
3349     lt_cv_file_magic_cmd=/usr/bin/file
3350     case $host_cpu in
3351     ia64*)
3352     lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3353     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3354     ;;
3355     hppa*64*)
3356 michael 1094 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
3357 michael 912 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3358     ;;
3359     *)
3360 michael 1094 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
3361 michael 912 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3362     ;;
3363     esac
3364     ;;
3365    
3366     interix[[3-9]]*)
3367     # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3368     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3369     ;;
3370    
3371     irix5* | irix6* | nonstopux*)
3372     case $LD in
3373     *-32|*"-32 ") libmagic=32-bit;;
3374     *-n32|*"-n32 ") libmagic=N32;;
3375     *-64|*"-64 ") libmagic=64-bit;;
3376     *) libmagic=never-match;;
3377     esac
3378     lt_cv_deplibs_check_method=pass_all
3379     ;;
3380    
3381 michael 1257 # This must be glibc/ELF.
3382 michael 1094 linux* | k*bsd*-gnu | kopensolaris*-gnu)
3383 michael 912 lt_cv_deplibs_check_method=pass_all
3384     ;;
3385    
3386     netbsd*)
3387 michael 945 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3388 michael 912 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3389     else
3390     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3391     fi
3392     ;;
3393    
3394     newos6*)
3395     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3396     lt_cv_file_magic_cmd=/usr/bin/file
3397     lt_cv_file_magic_test_file=/usr/lib/libnls.so
3398     ;;
3399    
3400 michael 945 *nto* | *qnx*)
3401     lt_cv_deplibs_check_method=pass_all
3402 michael 912 ;;
3403    
3404     openbsd*)
3405 michael 945 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3406 michael 912 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3407     else
3408     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3409     fi
3410     ;;
3411    
3412     osf3* | osf4* | osf5*)
3413     lt_cv_deplibs_check_method=pass_all
3414     ;;
3415    
3416     rdos*)
3417     lt_cv_deplibs_check_method=pass_all
3418     ;;
3419    
3420     solaris*)
3421     lt_cv_deplibs_check_method=pass_all
3422     ;;
3423    
3424 michael 945 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3425     lt_cv_deplibs_check_method=pass_all
3426     ;;
3427    
3428 michael 912 sysv4 | sysv4.3*)
3429     case $host_vendor in
3430     motorola)
3431     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]]'
3432     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3433     ;;
3434     ncr)
3435     lt_cv_deplibs_check_method=pass_all
3436     ;;
3437     sequent)
3438     lt_cv_file_magic_cmd='/bin/file'
3439     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3440     ;;
3441     sni)
3442     lt_cv_file_magic_cmd='/bin/file'
3443     lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3444     lt_cv_file_magic_test_file=/lib/libc.so
3445     ;;
3446     siemens)
3447     lt_cv_deplibs_check_method=pass_all
3448     ;;
3449     pc)
3450     lt_cv_deplibs_check_method=pass_all
3451     ;;
3452     esac
3453     ;;
3454    
3455 michael 945 tpf*)
3456 michael 912 lt_cv_deplibs_check_method=pass_all
3457     ;;
3458     esac
3459     ])
3460 michael 1106
3461     file_magic_glob=
3462     want_nocaseglob=no
3463     if test "$build" = "$host"; then
3464     case $host_os in
3465     mingw* | pw32*)
3466     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
3467     want_nocaseglob=yes
3468     else
3469     file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
3470     fi
3471     ;;
3472     esac
3473     fi
3474    
3475 michael 912 file_magic_cmd=$lt_cv_file_magic_cmd
3476     deplibs_check_method=$lt_cv_deplibs_check_method
3477     test -z "$deplibs_check_method" && deplibs_check_method=unknown
3478    
3479 michael 945 _LT_DECL([], [deplibs_check_method], [1],
3480     [Method to check whether dependent libraries are shared objects])
3481     _LT_DECL([], [file_magic_cmd], [1],
3482 michael 1106 [Command to use when deplibs_check_method = "file_magic"])
3483     _LT_DECL([], [file_magic_glob], [1],
3484     [How to find potential files when deplibs_check_method = "file_magic"])
3485     _LT_DECL([], [want_nocaseglob], [1],
3486     [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
3487 michael 945 ])# _LT_CHECK_MAGIC_METHOD
3488 michael 912
3489 michael 945
3490     # LT_PATH_NM
3491 michael 912 # ----------
3492 michael 945 # find the pathname to a BSD- or MS-compatible name lister
3493     AC_DEFUN([LT_PATH_NM],
3494     [AC_REQUIRE([AC_PROG_CC])dnl
3495     AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
3496 michael 912 [if test -n "$NM"; then
3497     # Let the user override the test.
3498     lt_cv_path_NM="$NM"
3499     else
3500     lt_nm_to_check="${ac_tool_prefix}nm"
3501     if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3502     lt_nm_to_check="$lt_nm_to_check nm"
3503     fi
3504     for lt_tmp_nm in $lt_nm_to_check; do
3505     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3506     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3507     IFS="$lt_save_ifs"
3508     test -z "$ac_dir" && ac_dir=.
3509     tmp_nm="$ac_dir/$lt_tmp_nm"
3510     if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3511     # Check to see if the nm accepts a BSD-compat flag.
3512     # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3513     # nm: unknown option "B" ignored
3514     # Tru64's nm complains that /dev/null is an invalid object file
3515     case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3516     */dev/null* | *'Invalid file or object type'*)
3517     lt_cv_path_NM="$tmp_nm -B"
3518     break
3519     ;;
3520     *)
3521     case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3522     */dev/null*)
3523     lt_cv_path_NM="$tmp_nm -p"
3524     break
3525     ;;
3526     *)
3527     lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3528     continue # so that we can try to find one that supports BSD flags
3529     ;;
3530     esac
3531     ;;
3532     esac
3533     fi
3534     done
3535     IFS="$lt_save_ifs"
3536     done
3537 michael 945 : ${lt_cv_path_NM=no}
3538 michael 912 fi])
3539 michael 945 if test "$lt_cv_path_NM" != "no"; then
3540     NM="$lt_cv_path_NM"
3541     else
3542     # Didn't find any BSD compatible name lister, look for dumpbin.
3543 michael 1094 if test -n "$DUMPBIN"; then :
3544     # Let the user override the test.
3545     else
3546     AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
3547     case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
3548     *COFF*)
3549     DUMPBIN="$DUMPBIN -symbols"
3550     ;;
3551     *)
3552     DUMPBIN=:
3553     ;;
3554     esac
3555     fi
3556 michael 945 AC_SUBST([DUMPBIN])
3557     if test "$DUMPBIN" != ":"; then
3558     NM="$DUMPBIN"
3559     fi
3560     fi
3561     test -z "$NM" && NM=nm
3562     AC_SUBST([NM])
3563     _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
3564 michael 912
3565 michael 945 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3566     [lt_cv_nm_interface="BSD nm"
3567     echo "int some_variable = 0;" > conftest.$ac_ext
3568 michael 1094 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3569 michael 945 (eval "$ac_compile" 2>conftest.err)
3570     cat conftest.err >&AS_MESSAGE_LOG_FD
3571 michael 1094 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3572 michael 945 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3573     cat conftest.err >&AS_MESSAGE_LOG_FD
3574 michael 1094 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
3575 michael 945 cat conftest.out >&AS_MESSAGE_LOG_FD
3576     if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3577     lt_cv_nm_interface="MS dumpbin"
3578     fi
3579     rm -f conftest*])
3580     ])# LT_PATH_NM
3581 michael 912
3582 michael 945 # Old names:
3583     AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
3584     AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
3585     dnl aclocal-1.4 backwards compatibility:
3586     dnl AC_DEFUN([AM_PROG_NM], [])
3587     dnl AC_DEFUN([AC_PROG_NM], [])
3588    
3589 michael 1106 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
3590     # --------------------------------
3591     # how to determine the name of the shared library
3592     # associated with a specific link library.
3593     # -- PORTME fill in with the dynamic library characteristics
3594     m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
3595     [m4_require([_LT_DECL_EGREP])
3596     m4_require([_LT_DECL_OBJDUMP])
3597     m4_require([_LT_DECL_DLLTOOL])
3598     AC_CACHE_CHECK([how to associate runtime and link libraries],
3599     lt_cv_sharedlib_from_linklib_cmd,
3600     [lt_cv_sharedlib_from_linklib_cmd='unknown'
3601 michael 945
3602 michael 1106 case $host_os in
3603     cygwin* | mingw* | pw32* | cegcc*)
3604     # two different shell functions defined in ltmain.sh
3605     # decide which to use based on capabilities of $DLLTOOL
3606     case `$DLLTOOL --help 2>&1` in
3607     *--identify-strict*)
3608     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
3609     ;;
3610     *)
3611     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
3612     ;;
3613     esac
3614     ;;
3615     *)
3616     # fallback: assume linklib IS sharedlib
3617     lt_cv_sharedlib_from_linklib_cmd="$ECHO"
3618     ;;
3619     esac
3620     ])
3621     sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
3622     test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
3623    
3624     _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
3625     [Command to associate shared and link libraries])
3626     ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
3627    
3628    
3629     # _LT_PATH_MANIFEST_TOOL
3630     # ----------------------
3631     # locate the manifest tool
3632     m4_defun([_LT_PATH_MANIFEST_TOOL],
3633     [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
3634     test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
3635     AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
3636     [lt_cv_path_mainfest_tool=no
3637     echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
3638     $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
3639     cat conftest.err >&AS_MESSAGE_LOG_FD
3640     if $GREP 'Manifest Tool' conftest.out > /dev/null; then
3641     lt_cv_path_mainfest_tool=yes
3642     fi
3643     rm -f conftest*])
3644     if test "x$lt_cv_path_mainfest_tool" != xyes; then
3645     MANIFEST_TOOL=:
3646     fi
3647     _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
3648     ])# _LT_PATH_MANIFEST_TOOL
3649    
3650    
3651 michael 945 # LT_LIB_M
3652     # --------
3653 michael 912 # check for math library
3654 michael 945 AC_DEFUN([LT_LIB_M],
3655 michael 912 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3656     LIBM=
3657     case $host in
3658 michael 1094 *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
3659 michael 912 # These system don't have libm, or don't need it
3660     ;;
3661     *-ncr-sysv4.3*)
3662     AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3663     AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3664     ;;
3665     *)
3666     AC_CHECK_LIB(m, cos, LIBM="-lm")
3667     ;;
3668     esac
3669 michael 945 AC_SUBST([LIBM])
3670     ])# LT_LIB_M
3671 michael 912
3672 michael 945 # Old name:
3673     AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
3674     dnl aclocal-1.4 backwards compatibility:
3675     dnl AC_DEFUN([AC_CHECK_LIBM], [])
3676 michael 912
3677    
3678 michael 945 # _LT_COMPILER_NO_RTTI([TAGNAME])
3679     # -------------------------------
3680     m4_defun([_LT_COMPILER_NO_RTTI],
3681     [m4_require([_LT_TAG_COMPILER])dnl
3682 michael 912
3683 michael 945 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3684 michael 912
3685     if test "$GCC" = yes; then
3686 michael 1094 case $cc_basename in
3687     nvcc*)
3688     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
3689     *)
3690     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
3691     esac
3692 michael 912
3693 michael 945 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
3694 michael 912 lt_cv_prog_compiler_rtti_exceptions,
3695     [-fno-rtti -fno-exceptions], [],
3696 michael 945 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
3697 michael 912 fi
3698 michael 945 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
3699     [Compiler flag to turn off builtin functions])
3700     ])# _LT_COMPILER_NO_RTTI
3701 michael 912
3702    
3703 michael 945 # _LT_CMD_GLOBAL_SYMBOLS
3704     # ----------------------
3705     m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
3706     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3707     AC_REQUIRE([AC_PROG_CC])dnl
3708 michael 1094 AC_REQUIRE([AC_PROG_AWK])dnl
3709 michael 945 AC_REQUIRE([LT_PATH_NM])dnl
3710     AC_REQUIRE([LT_PATH_LD])dnl
3711     m4_require([_LT_DECL_SED])dnl
3712     m4_require([_LT_DECL_EGREP])dnl
3713     m4_require([_LT_TAG_COMPILER])dnl
3714    
3715 michael 912 # Check for command to grab the raw symbol name followed by C symbol from nm.
3716     AC_MSG_CHECKING([command to parse $NM output from $compiler object])
3717     AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
3718     [
3719     # These are sane defaults that work on at least a few old systems.
3720     # [They come from Ultrix. What could be older than Ultrix?!! ;)]
3721    
3722     # Character class describing NM global symbol codes.
3723     symcode='[[BCDEGRST]]'
3724    
3725     # Regexp to match symbols that can be accessed directly from C.
3726     sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
3727    
3728     # Define system-specific variables.
3729     case $host_os in
3730     aix*)
3731     symcode='[[BCDT]]'
3732     ;;
3733 michael 945 cygwin* | mingw* | pw32* | cegcc*)
3734 michael 912 symcode='[[ABCDGISTW]]'
3735     ;;
3736 michael 945 hpux*)
3737 michael 912 if test "$host_cpu" = ia64; then
3738     symcode='[[ABCDEGRST]]'
3739     fi
3740     ;;
3741     irix* | nonstopux*)
3742     symcode='[[BCDEGRST]]'
3743     ;;
3744     osf*)
3745     symcode='[[BCDEGQRST]]'
3746     ;;
3747     solaris*)
3748     symcode='[[BDRT]]'
3749     ;;
3750     sco3.2v5*)
3751     symcode='[[DT]]'
3752     ;;
3753     sysv4.2uw2*)
3754     symcode='[[DT]]'
3755     ;;
3756     sysv5* | sco5v6* | unixware* | OpenUNIX*)
3757     symcode='[[ABDT]]'
3758     ;;
3759     sysv4)
3760     symcode='[[DFNSTU]]'
3761     ;;
3762     esac
3763    
3764 michael 945 # If we're using GNU nm, then use its standard symbol codes.
3765     case `$NM -V 2>&1` in
3766     *GNU* | *'with BFD'*)
3767     symcode='[[ABCDGIRSTW]]' ;;
3768     esac
3769    
3770     # Transform an extracted symbol line into a proper C declaration.
3771     # Some systems (esp. on ia64) link data and code symbols differently,
3772     # so use this general approach.
3773     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
3774    
3775     # Transform an extracted symbol line into symbol name and symbol address
3776 michael 1106 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
3777     lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
3778 michael 945
3779 michael 912 # Handle CRLF in mingw tool chain
3780     opt_cr=
3781     case $build_os in
3782     mingw*)
3783 michael 945 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
3784 michael 912 ;;
3785     esac
3786    
3787 michael 945 # Try without a prefix underscore, then with it.
3788 michael 912 for ac_symprfx in "" "_"; do
3789    
3790     # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
3791     symxfrm="\\1 $ac_symprfx\\2 \\2"
3792    
3793     # Write the raw and C identifiers.
3794 michael 945 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3795     # Fake it for dumpbin and say T for any non-static function
3796     # and D for any global variable.
3797     # Also find C++ and __fastcall symbols from MSVC++,
3798     # which start with @ or ?.
3799     lt_cv_sys_global_symbol_pipe="$AWK ['"\
3800     " {last_section=section; section=\$ 3};"\
3801 michael 1257 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
3802 michael 945 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
3803     " \$ 0!~/External *\|/{next};"\
3804     " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
3805     " {if(hide[section]) next};"\
3806     " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
3807     " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
3808     " s[1]~/^[@?]/{print s[1], s[1]; next};"\
3809     " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
3810     " ' prfx=^$ac_symprfx]"
3811     else
3812     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
3813     fi
3814 michael 1106 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
3815 michael 912
3816     # Check to see that the pipe works correctly.
3817     pipe_works=no
3818    
3819     rm -f conftest*
3820 michael 945 cat > conftest.$ac_ext <<_LT_EOF
3821 michael 912 #ifdef __cplusplus
3822     extern "C" {
3823     #endif
3824     char nm_test_var;
3825 michael 945 void nm_test_func(void);
3826     void nm_test_func(void){}
3827 michael 912 #ifdef __cplusplus
3828     }
3829     #endif
3830     int main(){nm_test_var='a';nm_test_func();return(0);}
3831 michael 945 _LT_EOF
3832 michael 912
3833     if AC_TRY_EVAL(ac_compile); then
3834     # Now try to grab the symbols.
3835     nlist=conftest.nm
3836 michael 1094 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
3837 michael 912 # Try sorting and uniquifying the output.
3838     if sort "$nlist" | uniq > "$nlist"T; then
3839     mv -f "$nlist"T "$nlist"
3840     else
3841     rm -f "$nlist"T
3842     fi
3843    
3844     # Make sure that we snagged all the symbols we need.
3845 michael 945 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
3846     if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
3847     cat <<_LT_EOF > conftest.$ac_ext
3848 michael 1106 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3849     #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3850     /* DATA imports from DLLs on WIN32 con't be const, because runtime
3851     relocations are performed -- see ld's documentation on pseudo-relocs. */
3852     # define LT@&t@_DLSYM_CONST
3853     #elif defined(__osf__)
3854     /* This system does not cope well with relocations in const data. */
3855     # define LT@&t@_DLSYM_CONST
3856     #else
3857     # define LT@&t@_DLSYM_CONST const
3858     #endif
3859    
3860 michael 912 #ifdef __cplusplus
3861     extern "C" {
3862     #endif
3863    
3864 michael 945 _LT_EOF
3865 michael 912 # Now generate the symbol file.
3866 michael 945 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
3867 michael 912
3868 michael 945 cat <<_LT_EOF >> conftest.$ac_ext
3869 michael 912
3870 michael 945 /* The mapping between symbol names and symbols. */
3871 michael 1106 LT@&t@_DLSYM_CONST struct {
3872 michael 912 const char *name;
3873 michael 945 void *address;
3874 michael 912 }
3875 michael 945 lt__PROGRAM__LTX_preloaded_symbols[[]] =
3876 michael 912 {
3877 michael 945 { "@PROGRAM@", (void *) 0 },
3878     _LT_EOF
3879     $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
3880     cat <<\_LT_EOF >> conftest.$ac_ext
3881     {0, (void *) 0}
3882 michael 912 };
3883    
3884 michael 945 /* This works around a problem in FreeBSD linker */
3885     #ifdef FREEBSD_WORKAROUND
3886     static const void *lt_preloaded_setup() {
3887     return lt__PROGRAM__LTX_preloaded_symbols;
3888     }
3889     #endif
3890    
3891 michael 912 #ifdef __cplusplus
3892     }
3893     #endif
3894 michael 945 _LT_EOF
3895 michael 912 # Now try linking the two files.
3896     mv conftest.$ac_objext conftstm.$ac_objext
3897 michael 1106 lt_globsym_save_LIBS=$LIBS
3898     lt_globsym_save_CFLAGS=$CFLAGS
3899 michael 912 LIBS="conftstm.$ac_objext"
3900 michael 945 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
3901 michael 912 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
3902     pipe_works=yes
3903     fi
3904 michael 1106 LIBS=$lt_globsym_save_LIBS
3905     CFLAGS=$lt_globsym_save_CFLAGS
3906 michael 912 else
3907     echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
3908     fi
3909     else
3910     echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
3911     fi
3912     else
3913     echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
3914     fi
3915     else
3916     echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
3917     cat conftest.$ac_ext >&5
3918     fi
3919 db 941 rm -rf conftest* conftst*
3920 michael 912
3921     # Do not use the global_symbol_pipe unless it works.
3922     if test "$pipe_works" = yes; then
3923     break
3924     else
3925     lt_cv_sys_global_symbol_pipe=
3926     fi
3927     done
3928     ])
3929     if test -z "$lt_cv_sys_global_symbol_pipe"; then
3930     lt_cv_sys_global_symbol_to_cdecl=
3931     fi
3932     if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
3933     AC_MSG_RESULT(failed)
3934     else
3935     AC_MSG_RESULT(ok)
3936     fi
3937    
3938 michael 1106 # Response file support.
3939     if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3940     nm_file_list_spec='@'
3941     elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
3942     nm_file_list_spec='@'
3943     fi
3944    
3945 michael 945 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
3946     [Take the output of nm and produce a listing of raw symbols and C names])
3947     _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
3948     [Transform the output of nm in a proper C declaration])
3949     _LT_DECL([global_symbol_to_c_name_address],
3950     [lt_cv_sys_global_symbol_to_c_name_address], [1],
3951     [Transform the output of nm in a C name address pair])
3952     _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
3953     [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
3954     [Transform the output of nm in a C name address pair when lib prefix is needed])
3955 michael 1106 _LT_DECL([], [nm_file_list_spec], [1],
3956     [Specify filename containing input files for $NM])
3957 michael 945 ]) # _LT_CMD_GLOBAL_SYMBOLS
3958 michael 912
3959    
3960 michael 945 # _LT_COMPILER_PIC([TAGNAME])
3961     # ---------------------------
3962     m4_defun([_LT_COMPILER_PIC],
3963     [m4_require([_LT_TAG_COMPILER])dnl
3964     _LT_TAGVAR(lt_prog_compiler_wl, $1)=
3965     _LT_TAGVAR(lt_prog_compiler_pic, $1)=
3966     _LT_TAGVAR(lt_prog_compiler_static, $1)=
3967    
3968     m4_if([$1], [CXX], [
3969 michael 912 # C++ specific cases for pic, static, wl, etc.
3970     if test "$GXX" = yes; then
3971 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
3972     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
3973 michael 912
3974     case $host_os in
3975     aix*)
3976     # All AIX code is PIC.
3977     if test "$host_cpu" = ia64; then
3978     # AIX 5 now supports IA64 processor
3979 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
3980 michael 912 fi
3981     ;;
3982 michael 945
3983 michael 912 amigaos*)
3984 michael 945 case $host_cpu in
3985     powerpc)
3986     # see comment about AmigaOS4 .so support
3987     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
3988     ;;
3989     m68k)
3990     # FIXME: we need at least 68020 code to build shared libraries, but
3991     # adding the `-m68020' flag to GCC prevents building anything better,
3992     # like `-m68040'.
3993     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
3994     ;;
3995     esac
3996 michael 912 ;;
3997 michael 945
3998 michael 912 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
3999     # PIC is the default for these OSes.
4000     ;;
4001 michael 945 mingw* | cygwin* | os2* | pw32* | cegcc*)
4002 michael 912 # This hack is so that the source file can tell whether it is being
4003     # built for inclusion in a dll (and should export symbols for example).
4004     # Although the cygwin gcc ignores -fPIC, still need this for old-style
4005     # (--disable-auto-import) libraries
4006 db 941 m4_if([$1], [GCJ], [],
4007 michael 945 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4008 michael 912 ;;
4009     darwin* | rhapsody*)
4010     # PIC is the default on this platform
4011     # Common symbols not allowed in MH_DYLIB files
4012 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4013 michael 912 ;;
4014     *djgpp*)
4015     # DJGPP does not support shared libraries at all
4016 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4017 michael 912 ;;
4018 michael 1094 haiku*)
4019     # PIC is the default for Haiku.
4020     # The "-static" flag exists, but is broken.
4021     _LT_TAGVAR(lt_prog_compiler_static, $1)=
4022     ;;
4023 michael 912 interix[[3-9]]*)
4024     # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4025     # Instead, we relocate shared libraries at runtime.
4026     ;;
4027     sysv4*MP*)
4028     if test -d /usr/nec; then
4029 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4030 michael 912 fi
4031     ;;
4032     hpux*)
4033 michael 945 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4034     # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4035     # sets the default TLS model and affects inlining.
4036 michael 912 case $host_cpu in
4037 michael 945 hppa*64*)
4038 michael 912 ;;
4039     *)
4040 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4041 michael 912 ;;
4042     esac
4043     ;;
4044 michael 945 *qnx* | *nto*)
4045     # QNX uses GNU C++, but need to define -shared option too, otherwise
4046     # it will coredump.
4047     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4048     ;;
4049 michael 912 *)
4050 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4051 michael 912 ;;
4052     esac
4053     else
4054     case $host_os in
4055 db 941 aix[[4-9]]*)
4056 michael 912 # All AIX code is PIC.
4057     if test "$host_cpu" = ia64; then
4058     # AIX 5 now supports IA64 processor
4059 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4060 michael 912 else
4061 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4062 michael 912 fi
4063     ;;
4064     chorus*)
4065     case $cc_basename in
4066     cxch68*)
4067     # Green Hills C++ Compiler
4068 michael 945 # _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"
4069 michael 912 ;;
4070     esac
4071     ;;
4072 michael 1106 mingw* | cygwin* | os2* | pw32* | cegcc*)
4073     # This hack is so that the source file can tell whether it is being
4074     # built for inclusion in a dll (and should export symbols for example).
4075     m4_if([$1], [GCJ], [],
4076     [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4077     ;;
4078 michael 912 dgux*)
4079     case $cc_basename in
4080     ec++*)
4081 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4082 michael 912 ;;
4083     ghcx*)
4084     # Green Hills C++ Compiler
4085 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4086 michael 912 ;;
4087     *)
4088     ;;
4089     esac
4090     ;;
4091     freebsd* | dragonfly*)
4092     # FreeBSD uses GNU C++
4093     ;;
4094     hpux9* | hpux10* | hpux11*)
4095     case $cc_basename in
4096     CC*)
4097 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4098     _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4099 michael 912 if test "$host_cpu" != ia64; then
4100 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4101 michael 912 fi
4102     ;;
4103     aCC*)
4104 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4105     _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4106 michael 912 case $host_cpu in
4107     hppa*64*|ia64*)
4108     # +Z the default
4109     ;;
4110     *)
4111 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4112 michael 912 ;;
4113     esac
4114     ;;
4115     *)
4116     ;;
4117     esac
4118     ;;
4119     interix*)
4120     # This is c89, which is MS Visual C++ (no shared libs)
4121     # Anyone wants to do a port?
4122     ;;
4123     irix5* | irix6* | nonstopux*)
4124     case $cc_basename in
4125     CC*)
4126 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4127     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4128 michael 912 # CC pic flag -KPIC is the default.
4129     ;;
4130     *)
4131     ;;
4132     esac
4133     ;;
4134 michael 1094 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4135 michael 912 case $cc_basename in
4136     KCC*)
4137     # KAI C++ Compiler
4138 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4139     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4140 michael 912 ;;
4141 michael 945 ecpc* )
4142     # old Intel C++ for x86_64 which still supported -KPIC.
4143     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4144     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4145     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4146 michael 912 ;;
4147 michael 945 icpc* )
4148     # Intel C++, used to be incompatible with GCC.
4149     # ICC 10 doesn't accept -KPIC any more.
4150     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4151     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4152     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4153     ;;
4154 db 941 pgCC* | pgcpp*)
4155 michael 945 # Portland Group C++ compiler
4156     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4157     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4158     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4159 michael 912 ;;
4160     cxx*)
4161     # Compaq C++
4162     # Make sure the PIC flag is empty. It appears that all Alpha
4163     # Linux and Compaq Tru64 Unix objects are PIC.
4164 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4165     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4166 michael 912 ;;
4167 michael 1094 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
4168     # IBM XL 8.0, 9.0 on PPC and BlueGene
4169 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4170     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4171     _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4172     ;;
4173 michael 912 *)
4174     case `$CC -V 2>&1 | sed 5q` in
4175     *Sun\ C*)
4176     # Sun C++ 5.9
4177 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4178     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4179     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4180 michael 912 ;;
4181     esac
4182     ;;
4183     esac
4184     ;;
4185     lynxos*)
4186     ;;
4187     m88k*)
4188     ;;
4189     mvs*)
4190     case $cc_basename in
4191     cxx*)
4192 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4193 michael 912 ;;
4194     *)
4195     ;;
4196     esac
4197     ;;
4198     netbsd*)
4199     ;;
4200 michael 945 *qnx* | *nto*)
4201     # QNX uses GNU C++, but need to define -shared option too, otherwise
4202     # it will coredump.
4203     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4204     ;;
4205 michael 912 osf3* | osf4* | osf5*)
4206     case $cc_basename in
4207     KCC*)
4208 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4209 michael 912 ;;
4210     RCC*)
4211     # Rational C++ 2.4.1
4212 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4213 michael 912 ;;
4214     cxx*)
4215     # Digital/Compaq C++
4216 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4217 michael 912 # Make sure the PIC flag is empty. It appears that all Alpha
4218     # Linux and Compaq Tru64 Unix objects are PIC.
4219 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4220     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4221 michael 912 ;;
4222     *)
4223     ;;
4224     esac
4225     ;;
4226     psos*)
4227     ;;
4228     solaris*)
4229     case $cc_basename in
4230 michael 1094 CC* | sunCC*)
4231 michael 912 # Sun C++ 4.2, 5.x and Centerline C++
4232 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4233     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4234     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4235 michael 912 ;;
4236     gcx*)
4237     # Green Hills C++ Compiler
4238 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4239 michael 912 ;;
4240     *)
4241     ;;
4242     esac
4243     ;;
4244     sunos4*)
4245     case $cc_basename in
4246     CC*)
4247     # Sun C++ 4.x
4248 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4249     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4250 michael 912 ;;
4251     lcc*)
4252     # Lucid
4253 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4254 michael 912 ;;
4255     *)
4256     ;;
4257     esac
4258     ;;
4259 michael 945 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4260     case $cc_basename in
4261     CC*)
4262     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4263     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4264     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4265     ;;
4266     esac
4267     ;;
4268 michael 912 tandem*)
4269     case $cc_basename in
4270     NCC*)
4271     # NonStop-UX NCC 3.20
4272 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4273 michael 912 ;;
4274     *)
4275     ;;
4276     esac
4277     ;;
4278     vxworks*)
4279     ;;
4280     *)
4281 michael 945 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4282 michael 912 ;;
4283     esac
4284     fi
4285     ],
4286     [
4287     if test "$GCC" = yes; then
4288 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4289     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4290 michael 912
4291     case $host_os in
4292     aix*)
4293     # All AIX code is PIC.
4294     if test "$host_cpu" = ia64; then
4295     # AIX 5 now supports IA64 processor
4296 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4297 michael 912 fi
4298     ;;
4299    
4300     amigaos*)
4301 michael 945 case $host_cpu in
4302     powerpc)
4303     # see comment about AmigaOS4 .so support
4304     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4305     ;;
4306     m68k)
4307     # FIXME: we need at least 68020 code to build shared libraries, but
4308     # adding the `-m68020' flag to GCC prevents building anything better,
4309     # like `-m68040'.
4310     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4311     ;;
4312     esac
4313 michael 912 ;;
4314    
4315     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4316     # PIC is the default for these OSes.
4317     ;;
4318    
4319 michael 945 mingw* | cygwin* | pw32* | os2* | cegcc*)
4320 michael 912 # This hack is so that the source file can tell whether it is being
4321     # built for inclusion in a dll (and should export symbols for example).
4322     # Although the cygwin gcc ignores -fPIC, still need this for old-style
4323     # (--disable-auto-import) libraries
4324 db 941 m4_if([$1], [GCJ], [],
4325 michael 945 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4326 michael 912 ;;
4327    
4328     darwin* | rhapsody*)
4329     # PIC is the default on this platform
4330     # Common symbols not allowed in MH_DYLIB files
4331 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4332 michael 912 ;;
4333    
4334 michael 1094 haiku*)
4335     # PIC is the default for Haiku.
4336     # The "-static" flag exists, but is broken.
4337     _LT_TAGVAR(lt_prog_compiler_static, $1)=
4338     ;;
4339    
4340 michael 945 hpux*)
4341     # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4342     # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4343     # sets the default TLS model and affects inlining.
4344     case $host_cpu in
4345     hppa*64*)
4346     # +Z the default
4347     ;;
4348     *)
4349     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4350     ;;
4351     esac
4352     ;;
4353    
4354 michael 912 interix[[3-9]]*)
4355     # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4356     # Instead, we relocate shared libraries at runtime.
4357     ;;
4358    
4359     msdosdjgpp*)
4360     # Just because we use GCC doesn't mean we suddenly get shared libraries
4361     # on systems that don't support them.
4362 michael 945 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4363 michael 912 enable_shared=no
4364     ;;
4365    
4366 michael 945 *nto* | *qnx*)
4367     # QNX uses GNU C++, but need to define -shared option too, otherwise
4368     # it will coredump.
4369     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4370     ;;
4371    
4372 michael 912 sysv4*MP*)
4373     if test -d /usr/nec; then
4374 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4375 michael 912 fi
4376     ;;
4377    
4378     *)
4379 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4380 michael 912 ;;
4381     esac
4382 michael 1094
4383     case $cc_basename in
4384     nvcc*) # Cuda Compiler Driver 2.2
4385     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
4386 michael 1257 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4387     _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
4388     fi
4389 michael 1094 ;;
4390     esac
4391 michael 912 else
4392     # PORTME Check for flag to pass linker flags through the system compiler.
4393     case $host_os in
4394     aix*)
4395 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4396 michael 912 if test "$host_cpu" = ia64; then
4397     # AIX 5 now supports IA64 processor
4398 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4399 michael 912 else
4400 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4401 michael 912 fi
4402     ;;
4403    
4404 michael 945 mingw* | cygwin* | pw32* | os2* | cegcc*)
4405 michael 912 # This hack is so that the source file can tell whether it is being
4406     # built for inclusion in a dll (and should export symbols for example).
4407 db 941 m4_if([$1], [GCJ], [],
4408 michael 945 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4409 michael 912 ;;
4410    
4411     hpux9* | hpux10* | hpux11*)
4412 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4413 michael 912 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4414     # not for PA HP-UX.
4415     case $host_cpu in
4416     hppa*64*|ia64*)
4417     # +Z the default
4418     ;;
4419     *)
4420 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4421 michael 912 ;;
4422     esac
4423     # Is there a better lt_prog_compiler_static that works with the bundled CC?
4424 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4425 michael 912 ;;
4426    
4427     irix5* | irix6* | nonstopux*)
4428 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4429 michael 912 # PIC (with -KPIC) is the default.
4430 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4431 michael 912 ;;
4432    
4433 michael 1094 linux* | k*bsd*-gnu | kopensolaris*-gnu)
4434 michael 912 case $cc_basename in
4435 michael 945 # old Intel for x86_64 which still supported -KPIC.
4436     ecc*)
4437     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4438     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4439     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4440 michael 912 ;;
4441 michael 945 # icc used to be incompatible with GCC.
4442     # ICC 10 doesn't accept -KPIC any more.
4443     icc* | ifort*)
4444     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4445     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4446     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4447     ;;
4448     # Lahey Fortran 8.1.
4449     lf95*)
4450     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4451     _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
4452     _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
4453     ;;
4454 michael 1106 nagfor*)
4455     # NAG Fortran compiler
4456     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
4457     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4458     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4459     ;;
4460 michael 1094 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
4461 michael 912 # Portland Group compilers (*not* the Pentium gcc compiler,
4462     # which looks to be a dead project)
4463 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4464     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4465     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4466 michael 912 ;;
4467     ccc*)
4468 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4469 michael 912 # All Alpha code is PIC.
4470 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4471 michael 912 ;;
4472 michael 1094 xl* | bgxl* | bgf* | mpixl*)
4473     # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
4474 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4475     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4476     _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4477     ;;
4478 michael 912 *)
4479 michael 945 case `$CC -V 2>&1 | sed 5q` in
4480 michael 1257 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
4481 michael 1094 # Sun Fortran 8.3 passes all unrecognized flags to the linker
4482     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4483     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4484     _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4485     ;;
4486 michael 1257 *Sun\ F* | *Sun*Fortran*)
4487     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4488     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4489     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4490     ;;
4491 michael 912 *Sun\ C*)
4492     # Sun C 5.9
4493 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4494     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4495     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4496 michael 912 ;;
4497 michael 1257 *Intel*\ [[CF]]*Compiler*)
4498     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4499     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4500     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4501     ;;
4502     *Portland\ Group*)
4503     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4504     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4505     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4506     ;;
4507 michael 912 esac
4508     ;;
4509     esac
4510     ;;
4511    
4512 michael 945 newsos6)
4513     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4514     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4515     ;;
4516    
4517     *nto* | *qnx*)
4518     # QNX uses GNU C++, but need to define -shared option too, otherwise
4519     # it will coredump.
4520     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4521     ;;
4522    
4523 michael 912 osf3* | osf4* | osf5*)
4524 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4525 michael 912 # All OSF/1 code is PIC.
4526 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4527 michael 912 ;;
4528    
4529     rdos*)
4530 michael 945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4531 michael 912 ;;
4532    
4533     solaris*)
4534 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4535     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4536 michael 912 case $cc_basename in
4537 michael 1094 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
4538 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4539 michael 912 *)
4540 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4541 michael 912 esac
4542     ;;
4543    
4544     sunos4*)
4545 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4546     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4547     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4548 michael 912 ;;
4549    
4550     sysv4 | sysv4.2uw2* | sysv4.3*)
4551 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4552     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4553     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4554 michael 912 ;;
4555    
4556     sysv4*MP*)
4557     if test -d /usr/nec ;then
4558 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
4559     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4560 michael 912 fi
4561     ;;
4562    
4563     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4564 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4565     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4566     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4567 michael 912 ;;
4568    
4569     unicos*)
4570 michael 945 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4571     _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4572 michael 912 ;;
4573    
4574     uts4*)
4575 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4576     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4577 michael 912 ;;
4578    
4579     *)
4580 michael 945 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4581 michael 912 ;;
4582     esac
4583     fi
4584     ])
4585     case $host_os in
4586     # For platforms which do not support PIC, -DPIC is meaningless:
4587     *djgpp*)
4588 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4589 michael 912 ;;
4590     *)
4591 michael 945 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4592 michael 912 ;;
4593     esac
4594    
4595 michael 1106 AC_CACHE_CHECK([for $compiler option to produce PIC],
4596     [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
4597     [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4598     _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
4599    
4600 michael 912 #
4601 michael 945 # Check to make sure the PIC flag actually works.
4602     #
4603     if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4604     _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
4605     [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
4606     [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
4607     [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
4608     "" | " "*) ;;
4609     *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
4610     esac],
4611     [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4612     _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
4613     fi
4614     _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4615     [Additional compiler flags for building library objects])
4616    
4617 michael 1106 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4618     [How to pass a linker flag through the compiler])
4619 michael 945 #
4620 michael 912 # Check to make sure the static flag actually works.
4621     #
4622 michael 945 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
4623     _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
4624     _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
4625 michael 912 $lt_tmp_static_flag,
4626     [],
4627 michael 945 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
4628     _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
4629     [Compiler flag to prevent dynamic linking])
4630     ])# _LT_COMPILER_PIC
4631 michael 912
4632    
4633 michael 945 # _LT_LINKER_SHLIBS([TAGNAME])
4634     # ----------------------------
4635 michael 912 # See if the linker supports building shared libraries.
4636 michael 945 m4_defun([_LT_LINKER_SHLIBS],
4637     [AC_REQUIRE([LT_PATH_LD])dnl
4638     AC_REQUIRE([LT_PATH_NM])dnl
4639 michael 1106 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
4640 michael 945 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4641     m4_require([_LT_DECL_EGREP])dnl
4642     m4_require([_LT_DECL_SED])dnl
4643     m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
4644     m4_require([_LT_TAG_COMPILER])dnl
4645 michael 912 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4646 michael 945 m4_if([$1], [CXX], [
4647     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4648 michael 1106 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4649 michael 912 case $host_os in
4650 db 941 aix[[4-9]]*)
4651 michael 912 # If we're using GNU nm, then we don't want the "-C" option.
4652     # -C means demangle to AIX nm, but means don't demangle with GNU nm
4653 michael 1094 # Also, AIX nm treats weak defined symbols like other global defined
4654     # symbols, whereas GNU nm marks them as "W".
4655 michael 945 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4656 michael 1094 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4657 michael 912 else
4658 michael 945 _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'
4659 michael 912 fi
4660     ;;
4661     pw32*)
4662 michael 945 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4663 michael 1106 ;;
4664 michael 945 cygwin* | mingw* | cegcc*)
4665 michael 1106 case $cc_basename in
4666 michael 1257 cl*)
4667     _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
4668     ;;
4669 michael 1106 *)
4670     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4671     _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
4672     ;;
4673     esac
4674     ;;
4675 michael 912 *)
4676 michael 945 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4677 michael 1106 ;;
4678 michael 912 esac
4679 michael 945 ], [
4680 michael 912 runpath_var=
4681 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=
4682     _LT_TAGVAR(always_export_symbols, $1)=no
4683     _LT_TAGVAR(archive_cmds, $1)=
4684     _LT_TAGVAR(archive_expsym_cmds, $1)=
4685     _LT_TAGVAR(compiler_needs_object, $1)=no
4686     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4687     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
4688     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4689     _LT_TAGVAR(hardcode_automatic, $1)=no
4690     _LT_TAGVAR(hardcode_direct, $1)=no
4691     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
4692     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4693     _LT_TAGVAR(hardcode_libdir_separator, $1)=
4694     _LT_TAGVAR(hardcode_minus_L, $1)=no
4695     _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4696     _LT_TAGVAR(inherit_rpath, $1)=no
4697     _LT_TAGVAR(link_all_deplibs, $1)=unknown
4698     _LT_TAGVAR(module_cmds, $1)=
4699     _LT_TAGVAR(module_expsym_cmds, $1)=
4700     _LT_TAGVAR(old_archive_from_new_cmds, $1)=
4701     _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
4702     _LT_TAGVAR(thread_safe_flag_spec, $1)=
4703     _LT_TAGVAR(whole_archive_flag_spec, $1)=
4704 michael 912 # include_expsyms should be a list of space-separated symbols to be *always*
4705     # included in the symbol list
4706 michael 945 _LT_TAGVAR(include_expsyms, $1)=
4707 michael 912 # exclude_expsyms can be an extended regexp of symbols to exclude
4708     # it will be wrapped by ` (' and `)$', so one must not match beginning or
4709     # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4710     # as well as any symbol that contains `d'.
4711 michael 945 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4712 michael 912 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4713     # platforms (ab)use it in PIC code, but their linkers get confused if
4714     # the symbol is explicitly referenced. Since portable code cannot
4715     # rely on this symbol name, it's probably fine to never include it in
4716     # preloaded symbol tables.
4717 db 941 # Exclude shared library initialization/finalization symbols.
4718     dnl Note also adjust exclude_expsyms for C++ above.
4719 michael 912 extract_expsyms_cmds=
4720 michael 945
4721 michael 912 case $host_os in
4722 michael 945 cygwin* | mingw* | pw32* | cegcc*)
4723 michael 912 # FIXME: the MSVC++ port hasn't been tested in a loooong time
4724     # When not using gcc, we currently assume that we are using
4725     # Microsoft Visual C++.
4726     if test "$GCC" != yes; then
4727     with_gnu_ld=no
4728     fi
4729     ;;
4730     interix*)
4731     # we just hope/assume this is gcc and not c89 (= MSVC++)
4732     with_gnu_ld=yes
4733     ;;
4734     openbsd*)
4735     with_gnu_ld=no
4736     ;;
4737     esac
4738    
4739 michael 945 _LT_TAGVAR(ld_shlibs, $1)=yes
4740 michael 1094
4741     # On some targets, GNU ld is compatible enough with the native linker
4742     # that we're better off using the native interface for both.
4743     lt_use_gnu_ld_interface=no
4744 michael 912 if test "$with_gnu_ld" = yes; then
4745 michael 1094 case $host_os in
4746     aix*)
4747     # The AIX port of GNU ld has always aspired to compatibility
4748     # with the native linker. However, as the warning in the GNU ld
4749     # block says, versions before 2.19.5* couldn't really create working
4750     # shared libraries, regardless of the interface used.
4751     case `$LD -v 2>&1` in
4752     *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
4753     *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
4754     *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
4755     *)
4756     lt_use_gnu_ld_interface=yes
4757     ;;
4758     esac
4759     ;;
4760     *)
4761     lt_use_gnu_ld_interface=yes
4762     ;;
4763     esac
4764     fi
4765    
4766     if test "$lt_use_gnu_ld_interface" = yes; then
4767 michael 912 # If archive_cmds runs LD, not CC, wlarc should be empty
4768     wlarc='${wl}'
4769    
4770     # Set some defaults for GNU ld with shared library support. These
4771     # are reset later if shared libraries are not supported. Putting them
4772     # here allows them to be overridden if necessary.
4773     runpath_var=LD_RUN_PATH
4774 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4775     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4776 michael 912 # ancient GNU ld didn't support --whole-archive et. al.
4777 michael 945 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
4778     _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4779     else
4780     _LT_TAGVAR(whole_archive_flag_spec, $1)=
4781 michael 912 fi
4782     supports_anon_versioning=no
4783 michael 945 case `$LD -v 2>&1` in
4784 michael 1094 *GNU\ gold*) supports_anon_versioning=yes ;;
4785 michael 912 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
4786     *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
4787     *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
4788     *\ 2.11.*) ;; # other 2.11 versions
4789     *) supports_anon_versioning=yes ;;
4790     esac
4791    
4792     # See if GNU ld supports shared libraries.
4793     case $host_os in
4794 db 941 aix[[3-9]]*)
4795 michael 912 # On AIX/PPC, the GNU linker is very broken
4796     if test "$host_cpu" != ia64; then
4797 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
4798     cat <<_LT_EOF 1>&2
4799 michael 912
4800 michael 1094 *** Warning: the GNU linker, at least up to release 2.19, is reported
4801 michael 912 *** to be unable to reliably create shared libraries on AIX.
4802     *** Therefore, libtool is disabling shared libraries support. If you
4803 michael 1094 *** really care for shared libraries, you may want to install binutils
4804     *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
4805     *** You will then need to restart the configuration process.
4806 michael 912
4807 michael 945 _LT_EOF
4808 michael 912 fi
4809     ;;
4810    
4811     amigaos*)
4812 michael 945 case $host_cpu in
4813     powerpc)
4814     # see comment about AmigaOS4 .so support
4815     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4816     _LT_TAGVAR(archive_expsym_cmds, $1)=''
4817     ;;
4818     m68k)
4819     _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)'
4820     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4821     _LT_TAGVAR(hardcode_minus_L, $1)=yes
4822     ;;
4823     esac
4824 michael 912 ;;
4825    
4826     beos*)
4827 michael 945 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4828     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4829 michael 912 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
4830     # support --undefined. This deserves some investigation. FIXME
4831 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4832 michael 912 else
4833 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
4834 michael 912 fi
4835     ;;
4836    
4837 michael 945 cygwin* | mingw* | pw32* | cegcc*)
4838     # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4839 michael 912 # as there is no search path for DLLs.
4840 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4841 michael 1094 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
4842 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4843     _LT_TAGVAR(always_export_symbols, $1)=no
4844     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4845 michael 1106 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4846     _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
4847 michael 912
4848 michael 945 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
4849     _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'
4850 michael 912 # If the export-symbols file already is a .def file (1st line
4851     # is EXPORTS), use it as is; otherwise, prepend...
4852 michael 945 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
4853 michael 912 cp $export_symbols $output_objdir/$soname.def;
4854     else
4855     echo EXPORTS > $output_objdir/$soname.def;
4856     cat $export_symbols >> $output_objdir/$soname.def;
4857     fi~
4858     $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4859     else
4860 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
4861 michael 912 fi
4862     ;;
4863    
4864 michael 1094 haiku*)
4865     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4866     _LT_TAGVAR(link_all_deplibs, $1)=yes
4867     ;;
4868    
4869 michael 912 interix[[3-9]]*)
4870 michael 945 _LT_TAGVAR(hardcode_direct, $1)=no
4871     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4872     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4873     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4874 michael 912 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4875     # Instead, shared libraries are loaded at an image base (0x10000000 by
4876     # default) and relocated if they conflict, which is a slow very memory
4877     # consuming and fragmenting process. To avoid this, we pick a random,
4878     # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4879     # time. Moving up from 0x10000000 also allows more sbrk(2) space.
4880 michael 945 _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'
4881     _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'
4882 michael 912 ;;
4883    
4884 michael 1094 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
4885 michael 945 tmp_diet=no
4886     if test "$host_os" = linux-dietlibc; then
4887     case $cc_basename in
4888     diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
4889     esac
4890     fi
4891     if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
4892     && test "$tmp_diet" = no
4893     then
4894 michael 1106 tmp_addflag=' $pic_flag'
4895 michael 945 tmp_sharedflag='-shared'
4896 michael 912 case $cc_basename,$host_cpu in
4897 michael 945 pgcc*) # Portland Group C compiler
4898 michael 1094 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4899 michael 912 tmp_addflag=' $pic_flag'
4900     ;;
4901 michael 1094 pgf77* | pgf90* | pgf95* | pgfortran*)
4902     # Portland Group f77 and f90 compilers
4903     _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4904 michael 912 tmp_addflag=' $pic_flag -Mnomain' ;;
4905 michael 945 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
4906 michael 912 tmp_addflag=' -i_dynamic' ;;
4907     efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
4908     tmp_addflag=' -i_dynamic -nofor_main' ;;
4909     ifc* | ifort*) # Intel Fortran compiler
4910     tmp_addflag=' -nofor_main' ;;
4911 michael 945 lf95*) # Lahey Fortran 8.1
4912     _LT_TAGVAR(whole_archive_flag_spec, $1)=
4913     tmp_sharedflag='--shared' ;;
4914 michael 1094 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
4915 michael 945 tmp_sharedflag='-qmkshrobj'
4916     tmp_addflag= ;;
4917 michael 1094 nvcc*) # Cuda Compiler Driver 2.2
4918     _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4919     _LT_TAGVAR(compiler_needs_object, $1)=yes
4920     ;;
4921 michael 912 esac
4922     case `$CC -V 2>&1 | sed 5q` in
4923     *Sun\ C*) # Sun C 5.9
4924 michael 1094 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
4925 michael 945 _LT_TAGVAR(compiler_needs_object, $1)=yes
4926 michael 912 tmp_sharedflag='-G' ;;
4927     *Sun\ F*) # Sun Fortran 8.3
4928     tmp_sharedflag='-G' ;;
4929     esac
4930 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4931 michael 912
4932 michael 945 if test "x$supports_anon_versioning" = xyes; then
4933     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4934     cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4935     echo "local: *; };" >> $output_objdir/$libname.ver~
4936     $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
4937     fi
4938    
4939     case $cc_basename in
4940 michael 1094 xlf* | bgf* | bgxlf* | mpixlf*)
4941 michael 945 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
4942     _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
4943 michael 1257 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4944 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
4945 michael 945 if test "x$supports_anon_versioning" = xyes; then
4946     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4947     cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4948     echo "local: *; };" >> $output_objdir/$libname.ver~
4949 michael 1094 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
4950 michael 945 fi
4951     ;;
4952     esac
4953 michael 912 else
4954 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
4955 michael 912 fi
4956     ;;
4957    
4958     netbsd*)
4959 michael 945 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4960     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
4961 michael 912 wlarc=
4962     else
4963 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4964     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4965 michael 912 fi
4966     ;;
4967    
4968     solaris*)
4969 michael 945 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
4970     _LT_TAGVAR(ld_shlibs, $1)=no
4971     cat <<_LT_EOF 1>&2
4972 michael 912
4973     *** Warning: The releases 2.8.* of the GNU linker cannot reliably
4974     *** create shared libraries on Solaris systems. Therefore, libtool
4975     *** is disabling shared libraries support. We urge you to upgrade GNU
4976     *** binutils to release 2.9.1 or newer. Another option is to modify
4977     *** your PATH or compiler configuration so that the native linker is
4978     *** used, and then restart.
4979    
4980 michael 945 _LT_EOF
4981     elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4982 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4983     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4984 michael 912 else
4985 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
4986 michael 912 fi
4987     ;;
4988    
4989     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
4990     case `$LD -v 2>&1` in
4991     *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
4992 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
4993 michael 912 cat <<_LT_EOF 1>&2
4994    
4995     *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
4996     *** reliably create shared libraries on SCO systems. Therefore, libtool
4997     *** is disabling shared libraries support. We urge you to upgrade GNU
4998     *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
4999     *** your PATH or compiler configuration so that the native linker is
5000     *** used, and then restart.
5001    
5002     _LT_EOF
5003     ;;
5004     *)
5005 michael 945 # For security reasons, it is highly recommended that you always
5006     # use absolute paths for naming shared libraries, and exclude the
5007     # DT_RUNPATH tag from executables and libraries. But doing so
5008     # requires that you compile everything twice, which is a pain.
5009     if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5010     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5011     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5012     _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'
5013 michael 912 else
5014 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
5015 michael 912 fi
5016     ;;
5017     esac
5018     ;;
5019    
5020     sunos4*)
5021 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5022 michael 912 wlarc=
5023 michael 945 _LT_TAGVAR(hardcode_direct, $1)=yes
5024     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5025 michael 912 ;;
5026    
5027     *)
5028 michael 945 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5029 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5030     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5031 michael 912 else
5032 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
5033 michael 912 fi
5034     ;;
5035     esac
5036    
5037 michael 945 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
5038 michael 912 runpath_var=
5039 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5040     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5041     _LT_TAGVAR(whole_archive_flag_spec, $1)=
5042 michael 912 fi
5043     else
5044     # PORTME fill in a description of your system's linker (not GNU ld)
5045     case $host_os in
5046     aix3*)
5047 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5048     _LT_TAGVAR(always_export_symbols, $1)=yes
5049     _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'
5050 michael 912 # Note: this linker hardcodes the directories in LIBPATH if there
5051     # are no directories specified by -L.
5052 michael 945 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5053 michael 912 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5054     # Neither direct hardcoding nor static linking is supported with a
5055     # broken collect2.
5056 michael 945 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5057 michael 912 fi
5058     ;;
5059    
5060 db 941 aix[[4-9]]*)
5061 michael 912 if test "$host_cpu" = ia64; then
5062     # On IA64, the linker does run time linking by default, so we don't
5063     # have to do anything special.
5064     aix_use_runtimelinking=no
5065     exp_sym_flag='-Bexport'
5066     no_entry_flag=""
5067     else
5068     # If we're using GNU nm, then we don't want the "-C" option.
5069     # -C means demangle to AIX nm, but means don't demangle with GNU nm
5070 michael 1094 # Also, AIX nm treats weak defined symbols like other global
5071     # defined symbols, whereas GNU nm marks them as "W".
5072 michael 945 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5073 michael 1094 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5074 michael 912 else
5075 michael 945 _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'
5076 michael 912 fi
5077     aix_use_runtimelinking=no
5078    
5079     # Test if we are trying to use run time linking or normal
5080     # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5081     # need to do runtime linking.
5082 db 941 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5083 michael 912 for ld_flag in $LDFLAGS; do
5084 michael 945 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5085     aix_use_runtimelinking=yes
5086     break
5087     fi
5088 michael 912 done
5089     ;;
5090     esac
5091    
5092     exp_sym_flag='-bexport'
5093     no_entry_flag='-bnoentry'
5094     fi
5095    
5096     # When large executables or shared objects are built, AIX ld can
5097     # have problems creating the table of contents. If linking a library
5098     # or program results in "error TOC overflow" add -mminimal-toc to
5099     # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5100     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5101    
5102 michael 945 _LT_TAGVAR(archive_cmds, $1)=''
5103     _LT_TAGVAR(hardcode_direct, $1)=yes
5104     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5105     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5106     _LT_TAGVAR(link_all_deplibs, $1)=yes
5107     _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5108 michael 912
5109     if test "$GCC" = yes; then
5110     case $host_os in aix4.[[012]]|aix4.[[012]].*)
5111     # We only want to do this on AIX 4.2 and lower, the check
5112     # below for broken collect2 doesn't work under 4.3+
5113     collect2name=`${CC} -print-prog-name=collect2`
5114 michael 945 if test -f "$collect2name" &&
5115     strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5116 michael 912 then
5117 michael 945 # We have reworked collect2
5118     :
5119 michael 912 else
5120 michael 945 # We have old collect2
5121     _LT_TAGVAR(hardcode_direct, $1)=unsupported
5122     # It fails to find uninstalled libraries when the uninstalled
5123     # path is not listed in the libpath. Setting hardcode_minus_L
5124     # to unsupported forces relinking
5125     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5126     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5127     _LT_TAGVAR(hardcode_libdir_separator, $1)=
5128 michael 912 fi
5129     ;;
5130     esac
5131     shared_flag='-shared'
5132     if test "$aix_use_runtimelinking" = yes; then
5133     shared_flag="$shared_flag "'${wl}-G'
5134     fi
5135     else
5136     # not using gcc
5137     if test "$host_cpu" = ia64; then
5138 michael 945 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5139     # chokes on -Wl,-G. The following line is correct:
5140 michael 912 shared_flag='-G'
5141     else
5142     if test "$aix_use_runtimelinking" = yes; then
5143     shared_flag='${wl}-G'
5144     else
5145     shared_flag='${wl}-bM:SRE'
5146     fi
5147     fi
5148     fi
5149    
5150 michael 945 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
5151 michael 912 # It seems that -bexpall does not export symbols beginning with
5152     # underscore (_), so it is better to generate a list of symbols to export.
5153 michael 945 _LT_TAGVAR(always_export_symbols, $1)=yes
5154 michael 912 if test "$aix_use_runtimelinking" = yes; then
5155     # Warning - without using the other runtime loading flags (-brtl),
5156     # -berok will link without error, but may produce a broken library.
5157 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5158     # Determine the default libpath from the value encoded in an
5159     # empty executable.
5160 michael 1106 _LT_SYS_MODULE_PATH_AIX([$1])
5161 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5162 michael 1094 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5163 michael 945 else
5164 michael 912 if test "$host_cpu" = ia64; then
5165 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5166     _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5167     _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"
5168 michael 912 else
5169 michael 945 # Determine the default libpath from the value encoded in an
5170     # empty executable.
5171 michael 1106 _LT_SYS_MODULE_PATH_AIX([$1])
5172 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5173 michael 912 # Warning - without using the other run time loading flags,
5174     # -berok will link without error, but may produce a broken library.
5175 michael 945 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5176     _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5177 michael 1094 if test "$with_gnu_ld" = yes; then
5178     # We only use this code for GNU lds that support --whole-archive.
5179     _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
5180     else
5181     # Exported symbols can be pulled into shared objects from archives
5182     _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5183     fi
5184 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5185 michael 912 # This is similar to how AIX traditionally builds its shared libraries.
5186 michael 945 _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'
5187 michael 912 fi
5188     fi
5189     ;;
5190    
5191     amigaos*)
5192 michael 945 case $host_cpu in
5193     powerpc)
5194     # see comment about AmigaOS4 .so support
5195     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5196     _LT_TAGVAR(archive_expsym_cmds, $1)=''
5197     ;;
5198     m68k)
5199     _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)'
5200     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5201     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5202     ;;
5203     esac
5204 michael 912 ;;
5205    
5206     bsdi[[45]]*)
5207 michael 945 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5208 michael 912 ;;
5209    
5210 michael 945 cygwin* | mingw* | pw32* | cegcc*)
5211 michael 912 # When not using gcc, we currently assume that we are using
5212     # Microsoft Visual C++.
5213     # hardcode_libdir_flag_spec is actually meaningless, as there is
5214     # no search path for DLLs.
5215 michael 1106 case $cc_basename in
5216     cl*)
5217     # Native MSVC
5218     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5219     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5220     _LT_TAGVAR(always_export_symbols, $1)=yes
5221     _LT_TAGVAR(file_list_spec, $1)='@'
5222     # Tell ltmain to make .lib files, not .a files.
5223     libext=lib
5224     # Tell ltmain to make .dll files, not .so files.
5225     shrext_cmds=".dll"
5226     # FIXME: Setting linknames here is a bad hack.
5227     _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
5228     _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5229     sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
5230     else
5231     sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
5232     fi~
5233     $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
5234     linknames='
5235     # The linker will not automatically build a static lib if we build a DLL.
5236     # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5237     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5238 michael 1257 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5239 michael 1106 _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'
5240     # Don't use ranlib
5241     _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
5242     _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
5243     lt_tool_outputfile="@TOOL_OUTPUT@"~
5244     case $lt_outputfile in
5245     *.exe|*.EXE) ;;
5246     *)
5247     lt_outputfile="$lt_outputfile.exe"
5248     lt_tool_outputfile="$lt_tool_outputfile.exe"
5249     ;;
5250     esac~
5251     if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
5252     $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
5253     $RM "$lt_outputfile.manifest";
5254     fi'
5255     ;;
5256     *)
5257     # Assume MSVC wrapper
5258     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5259     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5260     # Tell ltmain to make .lib files, not .a files.
5261     libext=lib
5262     # Tell ltmain to make .dll files, not .so files.
5263     shrext_cmds=".dll"
5264     # FIXME: Setting linknames here is a bad hack.
5265     _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
5266     # The linker will automatically build a .lib file if we build a DLL.
5267     _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5268     # FIXME: Should let the user specify the lib program.
5269     _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
5270     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5271     ;;
5272     esac
5273 michael 912 ;;
5274    
5275     darwin* | rhapsody*)
5276 michael 945 _LT_DARWIN_LINKER_FEATURES($1)
5277 michael 912 ;;
5278    
5279     dgux*)
5280 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5281     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5282     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5283 michael 912 ;;
5284    
5285     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
5286     # support. Future versions do this automatically, but an explicit c++rt0.o
5287     # does not break anything, and helps significantly (at the cost of a little
5288     # extra space).
5289     freebsd2.2*)
5290 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
5291     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5292     _LT_TAGVAR(hardcode_direct, $1)=yes
5293     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5294 michael 912 ;;
5295    
5296     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
5297 michael 1257 freebsd2.*)
5298 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5299     _LT_TAGVAR(hardcode_direct, $1)=yes
5300     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5301     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5302 michael 912 ;;
5303    
5304     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5305     freebsd* | dragonfly*)
5306 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5307 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5308     _LT_TAGVAR(hardcode_direct, $1)=yes
5309     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5310 michael 912 ;;
5311    
5312     hpux9*)
5313     if test "$GCC" = yes; then
5314 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5315 michael 912 else
5316 michael 945 _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'
5317 michael 912 fi
5318 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5319     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5320     _LT_TAGVAR(hardcode_direct, $1)=yes
5321 michael 912
5322     # hardcode_minus_L: Not really in the search PATH,
5323     # but as the default location of the library.
5324 michael 945 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5325     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5326 michael 912 ;;
5327    
5328     hpux10*)
5329 michael 1094 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
5330 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5331 michael 912 else
5332 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
5333 michael 912 fi
5334     if test "$with_gnu_ld" = no; then
5335 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5336     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5337     _LT_TAGVAR(hardcode_direct, $1)=yes
5338     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5339     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5340 michael 912 # hardcode_minus_L: Not really in the search PATH,
5341     # but as the default location of the library.
5342 michael 945 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5343 michael 912 fi
5344     ;;
5345    
5346     hpux11*)
5347 michael 1094 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
5348 michael 912 case $host_cpu in
5349     hppa*64*)
5350 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5351 michael 912 ;;
5352     ia64*)
5353 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5354 michael 912 ;;
5355     *)
5356 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5357 michael 912 ;;
5358     esac
5359     else
5360     case $host_cpu in
5361     hppa*64*)
5362 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5363 michael 912 ;;
5364     ia64*)
5365 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5366 michael 912 ;;
5367     *)
5368 michael 1094 m4_if($1, [], [
5369     # Older versions of the 11.00 compiler do not understand -b yet
5370     # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
5371     _LT_LINKER_OPTION([if $CC understands -b],
5372     _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
5373     [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
5374     [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
5375     [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
5376 michael 912 ;;
5377     esac
5378     fi
5379     if test "$with_gnu_ld" = no; then
5380 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5381     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5382 michael 912
5383     case $host_cpu in
5384     hppa*64*|ia64*)
5385 michael 945 _LT_TAGVAR(hardcode_direct, $1)=no
5386     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5387 michael 912 ;;
5388     *)
5389 michael 945 _LT_TAGVAR(hardcode_direct, $1)=yes
5390     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5391     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5392 michael 912
5393     # hardcode_minus_L: Not really in the search PATH,
5394     # but as the default location of the library.
5395 michael 945 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5396 michael 912 ;;
5397     esac
5398     fi
5399     ;;
5400    
5401     irix5* | irix6* | nonstopux*)
5402     if test "$GCC" = yes; then
5403 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5404 michael 945 # Try to use the -exported_symbol ld option, if it does not
5405     # work, assume that -exports_file does not work either and
5406     # implicitly export all symbols.
5407 michael 1106 # This should be the same for all languages, so no per-tag cache variable.
5408     AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
5409     [lt_cv_irix_exported_symbol],
5410     [save_LDFLAGS="$LDFLAGS"
5411     LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
5412     AC_LINK_IFELSE(
5413     [AC_LANG_SOURCE(
5414     [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
5415     [C++], [[int foo (void) { return 0; }]],
5416     [Fortran 77], [[
5417     subroutine foo
5418     end]],
5419     [Fortran], [[
5420     subroutine foo
5421     end]])])],
5422     [lt_cv_irix_exported_symbol=yes],
5423     [lt_cv_irix_exported_symbol=no])
5424     LDFLAGS="$save_LDFLAGS"])
5425     if test "$lt_cv_irix_exported_symbol" = yes; then
5426     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
5427     fi
5428 michael 912 else
5429 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5430     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
5431 michael 912 fi
5432 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5433     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5434     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5435     _LT_TAGVAR(inherit_rpath, $1)=yes
5436     _LT_TAGVAR(link_all_deplibs, $1)=yes
5437 michael 912 ;;
5438    
5439     netbsd*)
5440 michael 945 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5441     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
5442 michael 912 else
5443 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
5444 michael 912 fi
5445 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5446     _LT_TAGVAR(hardcode_direct, $1)=yes
5447     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5448 michael 912 ;;
5449    
5450     newsos6)
5451 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5452     _LT_TAGVAR(hardcode_direct, $1)=yes
5453     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5454     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5455     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5456 michael 912 ;;
5457    
5458 michael 945 *nto* | *qnx*)
5459     ;;
5460    
5461 michael 912 openbsd*)
5462     if test -f /usr/libexec/ld.so; then
5463 michael 945 _LT_TAGVAR(hardcode_direct, $1)=yes
5464     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5465     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5466     if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5467     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5468     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
5469     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5470     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5471 michael 912 else
5472     case $host_os in
5473     openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5474 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5475     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5476 michael 912 ;;
5477     *)
5478 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5479     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5480 michael 912 ;;
5481     esac
5482 michael 945 fi
5483 michael 912 else
5484 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
5485 michael 912 fi
5486     ;;
5487    
5488     os2*)
5489 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5490     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5491     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5492 michael 1094 _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'
5493 michael 945 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
5494 michael 912 ;;
5495    
5496     osf3*)
5497     if test "$GCC" = yes; then
5498 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5499 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5500 michael 912 else
5501 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5502 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5503 michael 912 fi
5504 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5505     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5506     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5507 michael 912 ;;
5508    
5509     osf4* | osf5*) # as osf3* with the addition of -msym flag
5510     if test "$GCC" = yes; then
5511 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5512 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5513 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5514 michael 912 else
5515 michael 945 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5516 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5517 michael 945 _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~
5518 michael 1094 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
5519 michael 912
5520     # Both c and cxx compiler support -rpath directly
5521 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
5522 michael 912 fi
5523 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5524     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5525 michael 912 ;;
5526    
5527     solaris*)
5528 michael 945 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5529 michael 912 if test "$GCC" = yes; then
5530     wlarc='${wl}'
5531 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5532 michael 945 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5533 michael 1106 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5534 michael 912 else
5535 michael 945 case `$CC -V 2>&1` in
5536     *"Compilers 5.0"*)
5537     wlarc=''
5538     _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
5539     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5540     $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
5541     ;;
5542     *)
5543     wlarc='${wl}'
5544     _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
5545     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5546     $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5547     ;;
5548     esac
5549 michael 912 fi
5550 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5551     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5552 michael 912 case $host_os in
5553     solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
5554     *)
5555     # The compiler driver will combine and reorder linker options,
5556     # but understands `-z linker_flag'. GCC discards it without `$wl',
5557     # but is careful enough not to reorder.
5558 michael 945 # Supported since Solaris 2.6 (maybe 2.5.1?)
5559 michael 912 if test "$GCC" = yes; then
5560 michael 945 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
5561 michael 912 else
5562 michael 945 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
5563 michael 912 fi
5564     ;;
5565     esac
5566 michael 945 _LT_TAGVAR(link_all_deplibs, $1)=yes
5567 michael 912 ;;
5568    
5569     sunos4*)
5570     if test "x$host_vendor" = xsequent; then
5571     # Use $CC to link under sequent, because it throws in some extra .o
5572     # files that make .init and .fini sections work.
5573 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
5574 michael 912 else
5575 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
5576 michael 912 fi
5577 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5578     _LT_TAGVAR(hardcode_direct, $1)=yes
5579     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5580     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5581 michael 912 ;;
5582    
5583     sysv4)
5584     case $host_vendor in
5585     sni)
5586 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5587     _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
5588 michael 912 ;;
5589     siemens)
5590     ## LD is ld it makes a PLAMLIB
5591     ## CC just makes a GrossModule.
5592 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
5593     _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
5594     _LT_TAGVAR(hardcode_direct, $1)=no
5595 michael 912 ;;
5596     motorola)
5597 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5598     _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
5599 michael 912 ;;
5600     esac
5601     runpath_var='LD_RUN_PATH'
5602 michael 945 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5603 michael 912 ;;
5604    
5605     sysv4.3*)
5606 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5607     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5608     _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
5609 michael 912 ;;
5610    
5611     sysv4*MP*)
5612     if test -d /usr/nec; then
5613 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5614     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5615 michael 912 runpath_var=LD_RUN_PATH
5616     hardcode_runpath_var=yes
5617 michael 945 _LT_TAGVAR(ld_shlibs, $1)=yes
5618 michael 912 fi
5619     ;;
5620    
5621     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
5622 michael 945 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5623     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5624     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5625 michael 912 runpath_var='LD_RUN_PATH'
5626    
5627     if test "$GCC" = yes; then
5628 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5629     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5630 michael 912 else
5631 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5632     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5633 michael 912 fi
5634     ;;
5635    
5636     sysv5* | sco3.2v5* | sco5v6*)
5637     # Note: We can NOT use -z defs as we might desire, because we do not
5638     # link with -lc, and that would cause any symbols used from libc to
5639     # always be unresolved, which means just about no library would
5640     # ever link correctly. If we're not using GNU ld we use -z text
5641     # though, which does catch some bad symbols but isn't as heavy-handed
5642     # as -z defs.
5643 michael 945 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5644     _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
5645     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5646     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5647     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
5648     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5649     _LT_TAGVAR(link_all_deplibs, $1)=yes
5650     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
5651 michael 912 runpath_var='LD_RUN_PATH'
5652    
5653     if test "$GCC" = yes; then
5654 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5655     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5656 michael 912 else
5657 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5658     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5659 michael 912 fi
5660     ;;
5661    
5662     uts4*)
5663 michael 945 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5664     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5665     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5666 michael 912 ;;
5667    
5668     *)
5669 michael 945 _LT_TAGVAR(ld_shlibs, $1)=no
5670 michael 912 ;;
5671     esac
5672 michael 945
5673     if test x$host_vendor = xsni; then
5674     case $host in
5675     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5676     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
5677     ;;
5678     esac
5679     fi
5680 michael 912 fi
5681     ])
5682 michael 945 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
5683     test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
5684 michael 912
5685 michael 945 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
5686    
5687     _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
5688     _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
5689     _LT_DECL([], [extract_expsyms_cmds], [2],
5690     [The commands to extract the exported symbol list from a shared archive])
5691    
5692 michael 912 #
5693     # Do we need to explicitly link libc?
5694     #
5695 michael 945 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
5696 michael 912 x|xyes)
5697     # Assume -lc should be added
5698 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5699 michael 912
5700     if test "$enable_shared" = yes && test "$GCC" = yes; then
5701 michael 945 case $_LT_TAGVAR(archive_cmds, $1) in
5702 michael 912 *'~'*)
5703     # FIXME: we may have to deal with multi-command sequences.
5704     ;;
5705     '$CC '*)
5706     # Test whether the compiler implicitly links with -lc since on some
5707     # systems, -lgcc has to come before -lc. If gcc already passes -lc
5708     # to ld, don't add -lc before -lgcc.
5709 michael 1094 AC_CACHE_CHECK([whether -lc should be explicitly linked in],
5710     [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
5711     [$RM conftest*
5712     echo "$lt_simple_compile_test_code" > conftest.$ac_ext
5713 michael 912
5714 michael 1094 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
5715     soname=conftest
5716     lib=conftest
5717     libobjs=conftest.$ac_objext
5718     deplibs=
5719     wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
5720     pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
5721     compiler_flags=-v
5722     linker_flags=-v
5723     verstring=
5724     output_objdir=.
5725     libname=conftest
5726     lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
5727     _LT_TAGVAR(allow_undefined_flag, $1)=
5728     if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
5729     then
5730     lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
5731     else
5732     lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5733     fi
5734     _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
5735     else
5736     cat conftest.err 1>&5
5737     fi
5738     $RM conftest*
5739     ])
5740     _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
5741 michael 912 ;;
5742     esac
5743     fi
5744     ;;
5745     esac
5746    
5747 michael 945 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
5748     [Whether or not to add -lc for building shared libraries])
5749     _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
5750     [enable_shared_with_static_runtimes], [0],
5751     [Whether or not to disallow shared libs when runtime libs are static])
5752     _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
5753     [Compiler flag to allow reflexive dlopens])
5754     _LT_TAGDECL([], [whole_archive_flag_spec], [1],
5755     [Compiler flag to generate shared objects directly from archives])
5756     _LT_TAGDECL([], [compiler_needs_object], [1],
5757     [Whether the compiler copes with passing no objects directly])
5758     _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
5759     [Create an old-style archive from a shared archive])
5760     _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
5761     [Create a temporary old-style archive to link instead of a shared archive])
5762     _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
5763     _LT_TAGDECL([], [archive_expsym_cmds], [2])
5764     _LT_TAGDECL([], [module_cmds], [2],
5765     [Commands used to build a loadable module if different from building
5766     a shared archive.])
5767     _LT_TAGDECL([], [module_expsym_cmds], [2])
5768     _LT_TAGDECL([], [with_gnu_ld], [1],
5769     [Whether we are building with GNU ld or not])
5770     _LT_TAGDECL([], [allow_undefined_flag], [1],
5771     [Flag that allows shared libraries with undefined symbols to be built])
5772     _LT_TAGDECL([], [no_undefined_flag], [1],
5773     [Flag that enforces no undefined symbols])
5774     _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
5775     [Flag to hardcode $libdir into a binary during linking.
5776     This must work even if $libdir does not exist])
5777     _LT_TAGDECL([], [hardcode_libdir_separator], [1],
5778     [Whether we need a single "-rpath" flag with a separated argument])
5779     _LT_TAGDECL([], [hardcode_direct], [0],
5780     [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5781     DIR into the resulting binary])
5782     _LT_TAGDECL([], [hardcode_direct_absolute], [0],
5783     [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5784     DIR into the resulting binary and the resulting library dependency is
5785     "absolute", i.e impossible to change by setting ${shlibpath_var} if the
5786     library is relocated])
5787     _LT_TAGDECL([], [hardcode_minus_L], [0],
5788     [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
5789     into the resulting binary])
5790     _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
5791     [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
5792     into the resulting binary])
5793     _LT_TAGDECL([], [hardcode_automatic], [0],
5794     [Set to "yes" if building a shared library automatically hardcodes DIR
5795     into the library and all subsequent libraries and executables linked
5796     against it])
5797     _LT_TAGDECL([], [inherit_rpath], [0],
5798     [Set to yes if linker adds runtime paths of dependent libraries
5799     to runtime path list])
5800     _LT_TAGDECL([], [link_all_deplibs], [0],
5801     [Whether libtool must link a program against all its dependency libraries])
5802     _LT_TAGDECL([], [always_export_symbols], [0],
5803     [Set to "yes" if exported symbols are required])
5804     _LT_TAGDECL([], [export_symbols_cmds], [2],
5805     [The commands to list exported symbols])
5806     _LT_TAGDECL([], [exclude_expsyms], [1],
5807     [Symbols that should not be listed in the preloaded symbols])
5808     _LT_TAGDECL([], [include_expsyms], [1],
5809     [Symbols that must always be exported])
5810     _LT_TAGDECL([], [prelink_cmds], [2],
5811     [Commands necessary for linking programs (against libraries) with templates])
5812 michael 1106 _LT_TAGDECL([], [postlink_cmds], [2],
5813     [Commands necessary for finishing linking programs])
5814 michael 945 _LT_TAGDECL([], [file_list_spec], [1],
5815     [Specify filename containing input files])
5816     dnl FIXME: Not yet implemented
5817     dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
5818     dnl [Compiler flag to generate thread safe objects])
5819     ])# _LT_LINKER_SHLIBS
5820 michael 912
5821    
5822 michael 945 # _LT_LANG_C_CONFIG([TAG])
5823     # ------------------------
5824     # Ensure that the configuration variables for a C compiler are suitably
5825     # defined. These variables are subsequently used by _LT_CONFIG to write
5826     # the compiler configuration to `libtool'.
5827     m4_defun([_LT_LANG_C_CONFIG],
5828     [m4_require([_LT_DECL_EGREP])dnl
5829     lt_save_CC="$CC"
5830     AC_LANG_PUSH(C)
5831 michael 912
5832 michael 945 # Source file extension for C test sources.
5833     ac_ext=c
5834 michael 912
5835 michael 945 # Object file extension for compiled C test sources.
5836     objext=o
5837     _LT_TAGVAR(objext, $1)=$objext
5838 michael 912
5839 michael 945 # Code to be used in simple compile tests
5840     lt_simple_compile_test_code="int some_variable = 0;"
5841 michael 912
5842 michael 945 # Code to be used in simple link tests
5843     lt_simple_link_test_code='int main(){return(0);}'
5844 michael 912
5845 michael 945 _LT_TAG_COMPILER
5846     # Save the default compiler, since it gets overwritten when the other
5847     # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
5848     compiler_DEFAULT=$CC
5849 michael 912
5850 michael 945 # save warnings/boilerplate of simple test code
5851     _LT_COMPILER_BOILERPLATE
5852     _LT_LINKER_BOILERPLATE
5853    
5854     if test -n "$compiler"; then
5855     _LT_COMPILER_NO_RTTI($1)
5856     _LT_COMPILER_PIC($1)
5857     _LT_COMPILER_C_O($1)
5858     _LT_COMPILER_FILE_LOCKS($1)
5859     _LT_LINKER_SHLIBS($1)
5860     _LT_SYS_DYNAMIC_LINKER($1)
5861     _LT_LINKER_HARDCODE_LIBPATH($1)
5862     LT_SYS_DLOPEN_SELF
5863     _LT_CMD_STRIPLIB
5864    
5865     # Report which library types will actually be built
5866     AC_MSG_CHECKING([if libtool supports shared libraries])
5867     AC_MSG_RESULT([$can_build_shared])
5868    
5869     AC_MSG_CHECKING([whether to build shared libraries])
5870     test "$can_build_shared" = "no" && enable_shared=no
5871    
5872     # On AIX, shared libraries and static libraries use the same namespace, and
5873     # are all built from PIC.
5874     case $host_os in
5875     aix3*)
5876     test "$enable_shared" = yes && enable_static=no
5877     if test -n "$RANLIB"; then
5878     archive_cmds="$archive_cmds~\$RANLIB \$lib"
5879     postinstall_cmds='$RANLIB $lib'
5880     fi
5881     ;;
5882    
5883     aix[[4-9]]*)
5884     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
5885     test "$enable_shared" = yes && enable_static=no
5886     fi
5887     ;;
5888     esac
5889     AC_MSG_RESULT([$enable_shared])
5890    
5891     AC_MSG_CHECKING([whether to build static libraries])
5892     # Make sure either enable_shared or enable_static is yes.
5893     test "$enable_shared" = yes || enable_static=yes
5894     AC_MSG_RESULT([$enable_static])
5895    
5896     _LT_CONFIG($1)
5897     fi
5898     AC_LANG_POP
5899     CC="$lt_save_CC"
5900     ])# _LT_LANG_C_CONFIG
5901    
5902    
5903 michael 1094 # _LT_LANG_CXX_CONFIG([TAG])
5904     # --------------------------
5905     # Ensure that the configuration variables for a C++ compiler are suitably
5906     # defined. These variables are subsequently used by _LT_CONFIG to write
5907     # the compiler configuration to `libtool'.
5908     m4_defun([_LT_LANG_CXX_CONFIG],
5909     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5910     m4_require([_LT_DECL_EGREP])dnl
5911 michael 1106 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5912 michael 945 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
5913     ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
5914     (test "X$CXX" != "Xg++"))) ; then
5915     AC_PROG_CXXCPP
5916     else
5917     _lt_caught_CXX_error=yes
5918     fi
5919    
5920     AC_LANG_PUSH(C++)
5921     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5922     _LT_TAGVAR(allow_undefined_flag, $1)=
5923     _LT_TAGVAR(always_export_symbols, $1)=no
5924     _LT_TAGVAR(archive_expsym_cmds, $1)=
5925     _LT_TAGVAR(compiler_needs_object, $1)=no
5926     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5927     _LT_TAGVAR(hardcode_direct, $1)=no
5928     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5929     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5930     _LT_TAGVAR(hardcode_libdir_separator, $1)=
5931     _LT_TAGVAR(hardcode_minus_L, $1)=no
5932     _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5933     _LT_TAGVAR(hardcode_automatic, $1)=no
5934     _LT_TAGVAR(inherit_rpath, $1)=no
5935     _LT_TAGVAR(module_cmds, $1)=
5936     _LT_TAGVAR(module_expsym_cmds, $1)=
5937     _LT_TAGVAR(link_all_deplibs, $1)=unknown
5938     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5939 michael 1094 _LT_TAGVAR(reload_flag, $1)=$reload_flag
5940     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
5941 michael 945 _LT_TAGVAR(no_undefined_flag, $1)=
5942     _LT_TAGVAR(whole_archive_flag_spec, $1)=
5943     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5944    
5945     # Source file extension for C++ test sources.
5946     ac_ext=cpp
5947    
5948     # Object file extension for compiled C++ test sources.
5949     objext=o
5950     _LT_TAGVAR(objext, $1)=$objext
5951    
5952     # No sense in running all these tests if we already determined that
5953     # the CXX compiler isn't working. Some variables (like enable_shared)
5954     # are currently assumed to apply to all compilers on this platform,
5955     # and will be corrupted by setting them based on a non-working compiler.
5956     if test "$_lt_caught_CXX_error" != yes; then
5957     # Code to be used in simple compile tests
5958     lt_simple_compile_test_code="int some_variable = 0;"
5959    
5960     # Code to be used in simple link tests
5961     lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
5962    
5963     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
5964     _LT_TAG_COMPILER
5965    
5966     # save warnings/boilerplate of simple test code
5967     _LT_COMPILER_BOILERPLATE
5968     _LT_LINKER_BOILERPLATE
5969    
5970     # Allow CC to be a program name with arguments.
5971     lt_save_CC=$CC
5972 michael 1106 lt_save_CFLAGS=$CFLAGS
5973 michael 945 lt_save_LD=$LD
5974     lt_save_GCC=$GCC
5975     GCC=$GXX
5976     lt_save_with_gnu_ld=$with_gnu_ld
5977     lt_save_path_LD=$lt_cv_path_LD
5978     if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
5979     lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
5980     else
5981     $as_unset lt_cv_prog_gnu_ld
5982     fi
5983     if test -n "${lt_cv_path_LDCXX+set}"; then
5984     lt_cv_path_LD=$lt_cv_path_LDCXX
5985     else
5986     $as_unset lt_cv_path_LD
5987     fi
5988     test -z "${LDCXX+set}" || LD=$LDCXX
5989     CC=${CXX-"c++"}
5990 michael 1106 CFLAGS=$CXXFLAGS
5991 michael 945 compiler=$CC
5992     _LT_TAGVAR(compiler, $1)=$CC
5993     _LT_CC_BASENAME([$compiler])
5994    
5995     if test -n "$compiler"; then
5996     # We don't want -fno-exception when compiling C++ code, so set the
5997     # no_builtin_flag separately
5998     if test "$GXX" = yes; then
5999     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
6000     else
6001     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
6002     fi
6003    
6004     if test "$GXX" = yes; then
6005     # Set up default GNU C++ configuration
6006    
6007     LT_PATH_LD
6008    
6009     # Check if GNU C++ uses GNU ld as the underlying linker, since the
6010     # archiving commands below assume that GNU ld is being used.
6011     if test "$with_gnu_ld" = yes; then
6012 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6013     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6014 michael 945
6015     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6016     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6017    
6018     # If archive_cmds runs LD, not CC, wlarc should be empty
6019     # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
6020     # investigate it a little bit more. (MM)
6021     wlarc='${wl}'
6022    
6023     # ancient GNU ld didn't support --whole-archive et. al.
6024     if eval "`$CC -print-prog-name=ld` --help 2>&1" |
6025     $GREP 'no-whole-archive' > /dev/null; then
6026     _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6027     else
6028     _LT_TAGVAR(whole_archive_flag_spec, $1)=
6029     fi
6030     else
6031     with_gnu_ld=no
6032     wlarc=
6033    
6034     # A generic and very simple default shared library creation
6035     # command for GNU C++ for the case where it uses the native
6036     # linker, instead of GNU ld. If possible, this setting should
6037     # overridden to take advantage of the native linker features on
6038     # the platform it is being used on.
6039     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6040     fi
6041    
6042     # Commands to make compiler produce verbose output that lists
6043     # what "hidden" libraries, object files and flags are used when
6044     # linking a shared library.
6045 michael 1094 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6046 michael 945
6047     else
6048     GXX=no
6049     with_gnu_ld=no
6050     wlarc=
6051     fi
6052    
6053     # PORTME: fill in a description of your system's C++ link characteristics
6054     AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6055     _LT_TAGVAR(ld_shlibs, $1)=yes
6056     case $host_os in
6057     aix3*)
6058     # FIXME: insert proper C++ library support
6059     _LT_TAGVAR(ld_shlibs, $1)=no
6060     ;;
6061     aix[[4-9]]*)
6062     if test "$host_cpu" = ia64; then
6063     # On IA64, the linker does run time linking by default, so we don't
6064     # have to do anything special.
6065     aix_use_runtimelinking=no
6066     exp_sym_flag='-Bexport'
6067     no_entry_flag=""
6068     else
6069     aix_use_runtimelinking=no
6070    
6071     # Test if we are trying to use run time linking or normal
6072     # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6073     # need to do runtime linking.
6074     case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6075     for ld_flag in $LDFLAGS; do
6076     case $ld_flag in
6077     *-brtl*)
6078     aix_use_runtimelinking=yes
6079     break
6080     ;;
6081     esac
6082     done
6083     ;;
6084     esac
6085    
6086     exp_sym_flag='-bexport'
6087     no_entry_flag='-bnoentry'
6088     fi
6089    
6090     # When large executables or shared objects are built, AIX ld can
6091     # have problems creating the table of contents. If linking a library
6092     # or program results in "error TOC overflow" add -mminimal-toc to
6093     # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6094     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6095    
6096     _LT_TAGVAR(archive_cmds, $1)=''
6097     _LT_TAGVAR(hardcode_direct, $1)=yes
6098     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6099     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6100     _LT_TAGVAR(link_all_deplibs, $1)=yes
6101     _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6102    
6103     if test "$GXX" = yes; then
6104     case $host_os in aix4.[[012]]|aix4.[[012]].*)
6105     # We only want to do this on AIX 4.2 and lower, the check
6106     # below for broken collect2 doesn't work under 4.3+
6107     collect2name=`${CC} -print-prog-name=collect2`
6108     if test -f "$collect2name" &&
6109     strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6110     then
6111     # We have reworked collect2
6112     :
6113     else
6114     # We have old collect2
6115     _LT_TAGVAR(hardcode_direct, $1)=unsupported
6116     # It fails to find uninstalled libraries when the uninstalled
6117     # path is not listed in the libpath. Setting hardcode_minus_L
6118     # to unsupported forces relinking
6119     _LT_TAGVAR(hardcode_minus_L, $1)=yes
6120     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6121     _LT_TAGVAR(hardcode_libdir_separator, $1)=
6122     fi
6123     esac
6124     shared_flag='-shared'
6125     if test "$aix_use_runtimelinking" = yes; then
6126     shared_flag="$shared_flag "'${wl}-G'
6127     fi
6128     else
6129     # not using gcc
6130     if test "$host_cpu" = ia64; then
6131     # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6132     # chokes on -Wl,-G. The following line is correct:
6133     shared_flag='-G'
6134     else
6135     if test "$aix_use_runtimelinking" = yes; then
6136     shared_flag='${wl}-G'
6137     else
6138     shared_flag='${wl}-bM:SRE'
6139     fi
6140     fi
6141     fi
6142    
6143     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6144     # It seems that -bexpall does not export symbols beginning with
6145     # underscore (_), so it is better to generate a list of symbols to
6146     # export.
6147     _LT_TAGVAR(always_export_symbols, $1)=yes
6148     if test "$aix_use_runtimelinking" = yes; then
6149     # Warning - without using the other runtime loading flags (-brtl),
6150     # -berok will link without error, but may produce a broken library.
6151     _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6152     # Determine the default libpath from the value encoded in an empty
6153     # executable.
6154 michael 1106 _LT_SYS_MODULE_PATH_AIX([$1])
6155 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6156    
6157 michael 1094 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6158 michael 945 else
6159     if test "$host_cpu" = ia64; then
6160     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6161     _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6162     _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"
6163     else
6164     # Determine the default libpath from the value encoded in an
6165     # empty executable.
6166 michael 1106 _LT_SYS_MODULE_PATH_AIX([$1])
6167 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6168     # Warning - without using the other run time loading flags,
6169     # -berok will link without error, but may produce a broken library.
6170     _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6171     _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6172 michael 1094 if test "$with_gnu_ld" = yes; then
6173     # We only use this code for GNU lds that support --whole-archive.
6174     _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6175     else
6176     # Exported symbols can be pulled into shared objects from archives
6177     _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6178     fi
6179 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6180     # This is similar to how AIX traditionally builds its shared
6181     # libraries.
6182     _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'
6183     fi
6184     fi
6185     ;;
6186    
6187     beos*)
6188     if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6189     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6190     # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6191     # support --undefined. This deserves some investigation. FIXME
6192     _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6193     else
6194     _LT_TAGVAR(ld_shlibs, $1)=no
6195     fi
6196     ;;
6197    
6198     chorus*)
6199     case $cc_basename in
6200     *)
6201     # FIXME: insert proper C++ library support
6202     _LT_TAGVAR(ld_shlibs, $1)=no
6203     ;;
6204     esac
6205     ;;
6206    
6207     cygwin* | mingw* | pw32* | cegcc*)
6208 michael 1106 case $GXX,$cc_basename in
6209     ,cl* | no,cl*)
6210     # Native MSVC
6211     # hardcode_libdir_flag_spec is actually meaningless, as there is
6212     # no search path for DLLs.
6213     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6214     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6215     _LT_TAGVAR(always_export_symbols, $1)=yes
6216     _LT_TAGVAR(file_list_spec, $1)='@'
6217     # Tell ltmain to make .lib files, not .a files.
6218     libext=lib
6219     # Tell ltmain to make .dll files, not .so files.
6220     shrext_cmds=".dll"
6221     # FIXME: Setting linknames here is a bad hack.
6222     _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
6223     _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6224     $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
6225     else
6226     $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
6227     fi~
6228     $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6229     linknames='
6230     # The linker will not automatically build a static lib if we build a DLL.
6231     # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6232     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6233     # Don't use ranlib
6234     _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6235     _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6236     lt_tool_outputfile="@TOOL_OUTPUT@"~
6237     case $lt_outputfile in
6238     *.exe|*.EXE) ;;
6239     *)
6240     lt_outputfile="$lt_outputfile.exe"
6241     lt_tool_outputfile="$lt_tool_outputfile.exe"
6242     ;;
6243     esac~
6244     func_to_tool_file "$lt_outputfile"~
6245     if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
6246     $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6247     $RM "$lt_outputfile.manifest";
6248     fi'
6249     ;;
6250     *)
6251     # g++
6252     # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6253     # as there is no search path for DLLs.
6254     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6255     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
6256     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6257     _LT_TAGVAR(always_export_symbols, $1)=no
6258     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6259 michael 945
6260 michael 1106 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
6261     _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'
6262     # If the export-symbols file already is a .def file (1st line
6263     # is EXPORTS), use it as is; otherwise, prepend...
6264     _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6265     cp $export_symbols $output_objdir/$soname.def;
6266     else
6267     echo EXPORTS > $output_objdir/$soname.def;
6268     cat $export_symbols >> $output_objdir/$soname.def;
6269     fi~
6270     $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'
6271     else
6272     _LT_TAGVAR(ld_shlibs, $1)=no
6273     fi
6274     ;;
6275     esac
6276     ;;
6277 michael 945 darwin* | rhapsody*)
6278     _LT_DARWIN_LINKER_FEATURES($1)
6279     ;;
6280    
6281     dgux*)
6282     case $cc_basename in
6283     ec++*)
6284     # FIXME: insert proper C++ library support
6285     _LT_TAGVAR(ld_shlibs, $1)=no
6286     ;;
6287     ghcx*)
6288     # Green Hills C++ Compiler
6289     # FIXME: insert proper C++ library support
6290     _LT_TAGVAR(ld_shlibs, $1)=no
6291     ;;
6292     *)
6293     # FIXME: insert proper C++ library support
6294     _LT_TAGVAR(ld_shlibs, $1)=no
6295     ;;
6296     esac
6297     ;;
6298    
6299 michael 1257 freebsd2.*)
6300 michael 945 # C++ shared libraries reported to be fairly broken before
6301     # switch to ELF
6302     _LT_TAGVAR(ld_shlibs, $1)=no
6303     ;;
6304    
6305     freebsd-elf*)
6306     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6307     ;;
6308    
6309     freebsd* | dragonfly*)
6310     # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
6311     # conventions
6312     _LT_TAGVAR(ld_shlibs, $1)=yes
6313     ;;
6314    
6315     gnu*)
6316     ;;
6317    
6318 michael 1094 haiku*)
6319     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6320     _LT_TAGVAR(link_all_deplibs, $1)=yes
6321     ;;
6322    
6323 michael 945 hpux9*)
6324     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6325     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6326     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6327     _LT_TAGVAR(hardcode_direct, $1)=yes
6328     _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6329     # but as the default
6330     # location of the library.
6331    
6332     case $cc_basename in
6333     CC*)
6334     # FIXME: insert proper C++ library support
6335     _LT_TAGVAR(ld_shlibs, $1)=no
6336     ;;
6337     aCC*)
6338     _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'
6339     # Commands to make compiler produce verbose output that lists
6340     # what "hidden" libraries, object files and flags are used when
6341     # linking a shared library.
6342     #
6343     # There doesn't appear to be a way to prevent this compiler from
6344     # explicitly linking system object files so we need to strip them
6345     # from the output so that they don't get included in the library
6346     # dependencies.
6347 michael 1094 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6348 michael 945 ;;
6349     *)
6350     if test "$GXX" = yes; then
6351 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6352 michael 945 else
6353     # FIXME: insert proper C++ library support
6354     _LT_TAGVAR(ld_shlibs, $1)=no
6355     fi
6356     ;;
6357     esac
6358     ;;
6359    
6360     hpux10*|hpux11*)
6361     if test $with_gnu_ld = no; then
6362     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6363     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6364    
6365     case $host_cpu in
6366     hppa*64*|ia64*)
6367     ;;
6368     *)
6369     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6370     ;;
6371     esac
6372     fi
6373     case $host_cpu in
6374     hppa*64*|ia64*)
6375     _LT_TAGVAR(hardcode_direct, $1)=no
6376     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6377     ;;
6378     *)
6379     _LT_TAGVAR(hardcode_direct, $1)=yes
6380     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6381     _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6382     # but as the default
6383     # location of the library.
6384     ;;
6385     esac
6386    
6387     case $cc_basename in
6388     CC*)
6389     # FIXME: insert proper C++ library support
6390     _LT_TAGVAR(ld_shlibs, $1)=no
6391     ;;
6392     aCC*)
6393     case $host_cpu in
6394     hppa*64*)
6395     _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6396     ;;
6397     ia64*)
6398     _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6399     ;;
6400     *)
6401     _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'
6402     ;;
6403     esac
6404     # Commands to make compiler produce verbose output that lists
6405     # what "hidden" libraries, object files and flags are used when
6406     # linking a shared library.
6407     #
6408     # There doesn't appear to be a way to prevent this compiler from
6409     # explicitly linking system object files so we need to strip them
6410     # from the output so that they don't get included in the library
6411     # dependencies.
6412 michael 1094 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6413 michael 945 ;;
6414     *)
6415     if test "$GXX" = yes; then
6416     if test $with_gnu_ld = no; then
6417     case $host_cpu in
6418     hppa*64*)
6419     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6420     ;;
6421     ia64*)
6422 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6423 michael 945 ;;
6424     *)
6425 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6426 michael 945 ;;
6427     esac
6428     fi
6429     else
6430     # FIXME: insert proper C++ library support
6431     _LT_TAGVAR(ld_shlibs, $1)=no
6432     fi
6433     ;;
6434     esac
6435     ;;
6436    
6437     interix[[3-9]]*)
6438     _LT_TAGVAR(hardcode_direct, $1)=no
6439     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6440     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6441     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6442     # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6443     # Instead, shared libraries are loaded at an image base (0x10000000 by
6444     # default) and relocated if they conflict, which is a slow very memory
6445     # consuming and fragmenting process. To avoid this, we pick a random,
6446     # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6447     # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6448     _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'
6449     _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'
6450     ;;
6451     irix5* | irix6*)
6452     case $cc_basename in
6453     CC*)
6454     # SGI C++
6455 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6456 michael 945
6457     # Archives containing C++ object files must be created using
6458     # "CC -ar", where "CC" is the IRIX C++ compiler. This is
6459     # necessary to make sure instantiated templates are included
6460     # in the archive.
6461     _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
6462     ;;
6463     *)
6464     if test "$GXX" = yes; then
6465     if test "$with_gnu_ld" = no; then
6466 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6467 michael 945 else
6468 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
6469 michael 945 fi
6470     fi
6471     _LT_TAGVAR(link_all_deplibs, $1)=yes
6472     ;;
6473     esac
6474     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6475     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6476     _LT_TAGVAR(inherit_rpath, $1)=yes
6477     ;;
6478    
6479 michael 1094 linux* | k*bsd*-gnu | kopensolaris*-gnu)
6480 michael 945 case $cc_basename in
6481     KCC*)
6482     # Kuck and Associates, Inc. (KAI) C++ Compiler
6483    
6484     # KCC will only create a shared library if the output file
6485     # ends with ".so" (or ".sl" for HP-UX), so rename the library
6486     # to its proper name (with version) after linking.
6487     _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'
6488     _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'
6489     # Commands to make compiler produce verbose output that lists
6490     # what "hidden" libraries, object files and flags are used when
6491     # linking a shared library.
6492     #
6493     # There doesn't appear to be a way to prevent this compiler from
6494     # explicitly linking system object files so we need to strip them
6495     # from the output so that they don't get included in the library
6496     # dependencies.
6497 michael 1094 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6498 michael 945
6499     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6500     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6501    
6502     # Archives containing C++ object files must be created using
6503     # "CC -Bstatic", where "CC" is the KAI C++ compiler.
6504     _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
6505     ;;
6506     icpc* | ecpc* )
6507     # Intel C++
6508     with_gnu_ld=yes
6509     # version 8.0 and above of icpc choke on multiply defined symbols
6510     # if we add $predep_objects and $postdep_objects, however 7.1 and
6511     # earlier do not add the objects themselves.
6512     case `$CC -V 2>&1` in
6513     *"Version 7."*)
6514     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6515     _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'
6516     ;;
6517     *) # Version 8.0 or newer
6518     tmp_idyn=
6519     case $host_cpu in
6520     ia64*) tmp_idyn=' -i_dynamic';;
6521     esac
6522     _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6523     _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'
6524     ;;
6525     esac
6526     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6527     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6528     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6529     _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6530     ;;
6531     pgCC* | pgcpp*)
6532     # Portland Group C++ compiler
6533     case `$CC -V` in
6534 michael 1094 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
6535 michael 945 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
6536     rm -rf $tpldir~
6537     $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6538 michael 1094 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
6539 michael 945 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
6540     rm -rf $tpldir~
6541     $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6542 michael 1094 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
6543 michael 945 $RANLIB $oldlib'
6544     _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6545     rm -rf $tpldir~
6546     $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6547 michael 1094 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6548 michael 945 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6549     rm -rf $tpldir~
6550     $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6551 michael 1094 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6552 michael 945 ;;
6553 michael 1094 *) # Version 6 and above use weak symbols
6554 michael 945 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6555     _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'
6556     ;;
6557     esac
6558    
6559     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6560     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6561 michael 1094 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6562 michael 945 ;;
6563     cxx*)
6564     # Compaq C++
6565     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6566     _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'
6567    
6568     runpath_var=LD_RUN_PATH
6569     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6570     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6571    
6572     # Commands to make compiler produce verbose output that lists
6573     # what "hidden" libraries, object files and flags are used when
6574     # linking a shared library.
6575     #
6576     # There doesn't appear to be a way to prevent this compiler from
6577     # explicitly linking system object files so we need to strip them
6578     # from the output so that they don't get included in the library
6579     # dependencies.
6580 michael 1094 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
6581 michael 945 ;;
6582 michael 1094 xl* | mpixl* | bgxl*)
6583 michael 945 # IBM XL 8.0 on PPC, with GNU ld
6584     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6585     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6586     _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6587     if test "x$supports_anon_versioning" = xyes; then
6588     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6589     cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6590     echo "local: *; };" >> $output_objdir/$libname.ver~
6591     $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6592     fi
6593     ;;
6594     *)
6595     case `$CC -V 2>&1 | sed 5q` in
6596     *Sun\ C*)
6597     # Sun C++ 5.9
6598     _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6599     _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6600     _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'
6601     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6602 michael 1094 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
6603 michael 945 _LT_TAGVAR(compiler_needs_object, $1)=yes
6604    
6605     # Not sure whether something based on
6606     # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
6607     # would be better.
6608 michael 1094 output_verbose_link_cmd='func_echo_all'
6609 michael 945
6610     # Archives containing C++ object files must be created using
6611     # "CC -xar", where "CC" is the Sun C++ compiler. This is
6612     # necessary to make sure instantiated templates are included
6613     # in the archive.
6614     _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6615     ;;
6616     esac
6617     ;;
6618     esac
6619     ;;
6620    
6621     lynxos*)
6622     # FIXME: insert proper C++ library support
6623     _LT_TAGVAR(ld_shlibs, $1)=no
6624     ;;
6625    
6626     m88k*)
6627     # FIXME: insert proper C++ library support
6628     _LT_TAGVAR(ld_shlibs, $1)=no
6629     ;;
6630    
6631     mvs*)
6632     case $cc_basename in
6633     cxx*)
6634     # FIXME: insert proper C++ library support
6635     _LT_TAGVAR(ld_shlibs, $1)=no
6636     ;;
6637     *)
6638     # FIXME: insert proper C++ library support
6639     _LT_TAGVAR(ld_shlibs, $1)=no
6640     ;;
6641     esac
6642     ;;
6643    
6644     netbsd*)
6645     if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6646     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
6647     wlarc=
6648     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6649     _LT_TAGVAR(hardcode_direct, $1)=yes
6650     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6651     fi
6652     # Workaround some broken pre-1.5 toolchains
6653     output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
6654     ;;
6655    
6656     *nto* | *qnx*)
6657     _LT_TAGVAR(ld_shlibs, $1)=yes
6658     ;;
6659    
6660     openbsd2*)
6661     # C++ shared libraries are fairly broken
6662     _LT_TAGVAR(ld_shlibs, $1)=no
6663     ;;
6664    
6665     openbsd*)
6666     if test -f /usr/libexec/ld.so; then
6667     _LT_TAGVAR(hardcode_direct, $1)=yes
6668     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6669     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6670     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6671     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6672     if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6673     _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'
6674     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6675     _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6676     fi
6677 michael 1094 output_verbose_link_cmd=func_echo_all
6678 michael 945 else
6679     _LT_TAGVAR(ld_shlibs, $1)=no
6680     fi
6681     ;;
6682    
6683     osf3* | osf4* | osf5*)
6684     case $cc_basename in
6685     KCC*)
6686     # Kuck and Associates, Inc. (KAI) C++ Compiler
6687    
6688     # KCC will only create a shared library if the output file
6689     # ends with ".so" (or ".sl" for HP-UX), so rename the library
6690     # to its proper name (with version) after linking.
6691     _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'
6692    
6693     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6694     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6695    
6696     # Archives containing C++ object files must be created using
6697     # the KAI C++ compiler.
6698     case $host in
6699     osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
6700     *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
6701     esac
6702     ;;
6703     RCC*)
6704     # Rational C++ 2.4.1
6705     # FIXME: insert proper C++ library support
6706     _LT_TAGVAR(ld_shlibs, $1)=no
6707     ;;
6708     cxx*)
6709     case $host in
6710     osf3*)
6711     _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6712 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6713 michael 945 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6714     ;;
6715     *)
6716     _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6717 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6718 michael 945 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
6719     echo "-hidden">> $lib.exp~
6720 michael 1094 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
6721 michael 945 $RM $lib.exp'
6722     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6723     ;;
6724     esac
6725    
6726     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6727    
6728     # Commands to make compiler produce verbose output that lists
6729     # what "hidden" libraries, object files and flags are used when
6730     # linking a shared library.
6731     #
6732     # There doesn't appear to be a way to prevent this compiler from
6733     # explicitly linking system object files so we need to strip them
6734     # from the output so that they don't get included in the library
6735     # dependencies.
6736 michael 1094 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6737 michael 945 ;;
6738     *)
6739     if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6740     _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6741     case $host in
6742     osf3*)
6743 michael 1094 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6744 michael 945 ;;
6745     *)
6746 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6747 michael 945 ;;
6748     esac
6749    
6750     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6751     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6752    
6753     # Commands to make compiler produce verbose output that lists
6754     # what "hidden" libraries, object files and flags are used when
6755     # linking a shared library.
6756 michael 1094 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6757 michael 945
6758     else
6759     # FIXME: insert proper C++ library support
6760     _LT_TAGVAR(ld_shlibs, $1)=no
6761     fi
6762     ;;
6763     esac
6764     ;;
6765    
6766     psos*)
6767     # FIXME: insert proper C++ library support
6768     _LT_TAGVAR(ld_shlibs, $1)=no
6769     ;;
6770    
6771     sunos4*)
6772     case $cc_basename in
6773     CC*)
6774     # Sun C++ 4.x
6775     # FIXME: insert proper C++ library support
6776     _LT_TAGVAR(ld_shlibs, $1)=no
6777     ;;
6778     lcc*)
6779     # Lucid
6780     # FIXME: insert proper C++ library support
6781     _LT_TAGVAR(ld_shlibs, $1)=no
6782     ;;
6783     *)
6784     # FIXME: insert proper C++ library support
6785     _LT_TAGVAR(ld_shlibs, $1)=no
6786     ;;
6787     esac
6788     ;;
6789    
6790     solaris*)
6791     case $cc_basename in
6792 michael 1094 CC* | sunCC*)
6793 michael 945 # Sun C++ 4.2, 5.x and Centerline C++
6794     _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
6795     _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6796     _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6797     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6798     $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'
6799    
6800     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6801     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6802     case $host_os in
6803     solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6804     *)
6805     # The compiler driver will combine and reorder linker options,
6806     # but understands `-z linker_flag'.
6807     # Supported since Solaris 2.6 (maybe 2.5.1?)
6808     _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6809     ;;
6810     esac
6811     _LT_TAGVAR(link_all_deplibs, $1)=yes
6812    
6813 michael 1094 output_verbose_link_cmd='func_echo_all'
6814 michael 945
6815     # Archives containing C++ object files must be created using
6816     # "CC -xar", where "CC" is the Sun C++ compiler. This is
6817     # necessary to make sure instantiated templates are included
6818     # in the archive.
6819     _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6820     ;;
6821     gcx*)
6822     # Green Hills C++ Compiler
6823     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6824    
6825     # The C++ compiler must be used to create the archive.
6826     _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
6827     ;;
6828     *)
6829     # GNU C++ compiler with Solaris linker
6830     if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6831     _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
6832     if $CC --version | $GREP -v '^2\.7' > /dev/null; then
6833 michael 1106 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6834 michael 945 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6835 michael 1106 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6836 michael 945
6837     # Commands to make compiler produce verbose output that lists
6838     # what "hidden" libraries, object files and flags are used when
6839     # linking a shared library.
6840 michael 1094 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6841 michael 945 else
6842     # g++ 2.7 appears to require `-G' NOT `-shared' on this
6843     # platform.
6844     _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6845     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6846     $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6847    
6848     # Commands to make compiler produce verbose output that lists
6849     # what "hidden" libraries, object files and flags are used when
6850     # linking a shared library.
6851 michael 1094 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6852 michael 945 fi
6853    
6854     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
6855     case $host_os in
6856     solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6857     *)
6858     _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6859     ;;
6860     esac
6861     fi
6862     ;;
6863     esac
6864     ;;
6865    
6866     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6867     _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6868     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6869     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6870     runpath_var='LD_RUN_PATH'
6871    
6872     case $cc_basename in
6873     CC*)
6874     _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6875     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6876     ;;
6877     *)
6878     _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6879     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6880     ;;
6881     esac
6882     ;;
6883    
6884     sysv5* | sco3.2v5* | sco5v6*)
6885     # Note: We can NOT use -z defs as we might desire, because we do not
6886     # link with -lc, and that would cause any symbols used from libc to
6887     # always be unresolved, which means just about no library would
6888     # ever link correctly. If we're not using GNU ld we use -z text
6889     # though, which does catch some bad symbols but isn't as heavy-handed
6890     # as -z defs.
6891     _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6892     _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6893     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6894     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6895     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6896     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6897     _LT_TAGVAR(link_all_deplibs, $1)=yes
6898     _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6899     runpath_var='LD_RUN_PATH'
6900    
6901     case $cc_basename in
6902     CC*)
6903     _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6904     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6905 michael 1094 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
6906     '"$_LT_TAGVAR(old_archive_cmds, $1)"
6907     _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
6908     '"$_LT_TAGVAR(reload_cmds, $1)"
6909 michael 945 ;;
6910     *)
6911     _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6912     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6913     ;;
6914     esac
6915     ;;
6916    
6917     tandem*)
6918     case $cc_basename in
6919     NCC*)
6920     # NonStop-UX NCC 3.20
6921     # FIXME: insert proper C++ library support
6922     _LT_TAGVAR(ld_shlibs, $1)=no
6923     ;;
6924     *)
6925     # FIXME: insert proper C++ library support
6926     _LT_TAGVAR(ld_shlibs, $1)=no
6927     ;;
6928     esac
6929     ;;
6930    
6931     vxworks*)
6932     # FIXME: insert proper C++ library support
6933     _LT_TAGVAR(ld_shlibs, $1)=no
6934     ;;
6935    
6936     *)
6937     # FIXME: insert proper C++ library support
6938     _LT_TAGVAR(ld_shlibs, $1)=no
6939     ;;
6940     esac
6941    
6942     AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6943     test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6944    
6945     _LT_TAGVAR(GCC, $1)="$GXX"
6946     _LT_TAGVAR(LD, $1)="$LD"
6947    
6948     ## CAVEAT EMPTOR:
6949     ## There is no encapsulation within the following macros, do not change
6950     ## the running order or otherwise move them around unless you know exactly
6951     ## what you are doing...
6952     _LT_SYS_HIDDEN_LIBDEPS($1)
6953     _LT_COMPILER_PIC($1)
6954     _LT_COMPILER_C_O($1)
6955     _LT_COMPILER_FILE_LOCKS($1)
6956     _LT_LINKER_SHLIBS($1)
6957     _LT_SYS_DYNAMIC_LINKER($1)
6958     _LT_LINKER_HARDCODE_LIBPATH($1)
6959    
6960     _LT_CONFIG($1)
6961     fi # test -n "$compiler"
6962    
6963     CC=$lt_save_CC
6964 michael 1106 CFLAGS=$lt_save_CFLAGS
6965 michael 945 LDCXX=$LD
6966     LD=$lt_save_LD
6967     GCC=$lt_save_GCC
6968     with_gnu_ld=$lt_save_with_gnu_ld
6969     lt_cv_path_LDCXX=$lt_cv_path_LD
6970     lt_cv_path_LD=$lt_save_path_LD
6971     lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
6972     lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
6973     fi # test "$_lt_caught_CXX_error" != yes
6974    
6975     AC_LANG_POP
6976     ])# _LT_LANG_CXX_CONFIG
6977    
6978    
6979 michael 1106 # _LT_FUNC_STRIPNAME_CNF
6980     # ----------------------
6981     # func_stripname_cnf prefix suffix name
6982     # strip PREFIX and SUFFIX off of NAME.
6983     # PREFIX and SUFFIX must not contain globbing or regex special
6984     # characters, hashes, percent signs, but SUFFIX may contain a leading
6985     # dot (in which case that matches only a dot).
6986     #
6987     # This function is identical to the (non-XSI) version of func_stripname,
6988     # except this one can be used by m4 code that may be executed by configure,
6989     # rather than the libtool script.
6990     m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
6991     AC_REQUIRE([_LT_DECL_SED])
6992     AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
6993     func_stripname_cnf ()
6994     {
6995     case ${2} in
6996     .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
6997     *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
6998     esac
6999     } # func_stripname_cnf
7000     ])# _LT_FUNC_STRIPNAME_CNF
7001    
7002 michael 945 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
7003     # ---------------------------------
7004     # Figure out "hidden" library dependencies from verbose
7005     # compiler output when linking a shared library.
7006     # Parse the compiler output and extract the necessary
7007     # objects, libraries and library flags.
7008     m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
7009     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7010 michael 1106 AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
7011 michael 945 # Dependencies to place before and after the object being linked:
7012     _LT_TAGVAR(predep_objects, $1)=
7013     _LT_TAGVAR(postdep_objects, $1)=
7014     _LT_TAGVAR(predeps, $1)=
7015     _LT_TAGVAR(postdeps, $1)=
7016     _LT_TAGVAR(compiler_lib_search_path, $1)=
7017    
7018     dnl we can't use the lt_simple_compile_test_code here,
7019     dnl because it contains code intended for an executable,
7020     dnl not a library. It's possible we should let each
7021     dnl tag define a new lt_????_link_test_code variable,
7022     dnl but it's only used here...
7023     m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
7024     int a;
7025     void foo (void) { a = 0; }
7026     _LT_EOF
7027     ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
7028     class Foo
7029     {
7030     public:
7031     Foo (void) { a = 0; }
7032     private:
7033     int a;
7034     };
7035     _LT_EOF
7036     ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
7037     subroutine foo
7038     implicit none
7039     integer*4 a
7040     a=0
7041     return
7042     end
7043     _LT_EOF
7044     ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
7045     subroutine foo
7046     implicit none
7047     integer a
7048     a=0
7049     return
7050     end
7051     _LT_EOF
7052     ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
7053     public class foo {
7054     private int a;
7055     public void bar (void) {
7056     a = 0;
7057     }
7058     };
7059     _LT_EOF
7060 michael 1257 ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
7061     package foo
7062     func foo() {
7063     }
7064     _LT_EOF
7065 michael 912 ])
7066 michael 1106
7067     _lt_libdeps_save_CFLAGS=$CFLAGS
7068     case "$CC $CFLAGS " in #(
7069     *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
7070     *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
7071 michael 1257 *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
7072 michael 1106 esac
7073    
7074 michael 945 dnl Parse the compiler output and extract the necessary
7075     dnl objects, libraries and library flags.
7076     if AC_TRY_EVAL(ac_compile); then
7077     # Parse the compiler output and extract the necessary
7078     # objects, libraries and library flags.
7079 michael 912
7080 michael 945 # Sentinel used to keep track of whether or not we are before
7081     # the conftest object file.
7082     pre_test_object_deps_done=no
7083 michael 912
7084 michael 945 for p in `eval "$output_verbose_link_cmd"`; do
7085 michael 1106 case ${prev}${p} in
7086 michael 912
7087 michael 945 -L* | -R* | -l*)
7088     # Some compilers place space between "-{L,R}" and the path.
7089     # Remove the space.
7090     if test $p = "-L" ||
7091     test $p = "-R"; then
7092     prev=$p
7093     continue
7094     fi
7095    
7096 michael 1106 # Expand the sysroot to ease extracting the directories later.
7097     if test -z "$prev"; then
7098     case $p in
7099     -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
7100     -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
7101     -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
7102     esac
7103     fi
7104     case $p in
7105     =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
7106     esac
7107 michael 945 if test "$pre_test_object_deps_done" = no; then
7108 michael 1106 case ${prev} in
7109     -L | -R)
7110 michael 945 # Internal compiler library paths should come after those
7111     # provided the user. The postdeps already come after the
7112     # user supplied libs so there is no need to process them.
7113     if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7114     _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
7115     else
7116     _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
7117     fi
7118     ;;
7119     # The "-l" case would never come before the object being
7120     # linked, so don't bother handling this case.
7121     esac
7122     else
7123     if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7124     _LT_TAGVAR(postdeps, $1)="${prev}${p}"
7125     else
7126     _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
7127     fi
7128     fi
7129 michael 1106 prev=
7130 michael 945 ;;
7131    
7132 michael 1106 *.lto.$objext) ;; # Ignore GCC LTO objects
7133 michael 945 *.$objext)
7134     # This assumes that the test object file only shows up
7135     # once in the compiler output.
7136     if test "$p" = "conftest.$objext"; then
7137     pre_test_object_deps_done=yes
7138     continue
7139     fi
7140    
7141     if test "$pre_test_object_deps_done" = no; then
7142     if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
7143     _LT_TAGVAR(predep_objects, $1)="$p"
7144     else
7145     _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
7146     fi
7147     else
7148     if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
7149     _LT_TAGVAR(postdep_objects, $1)="$p"
7150     else
7151     _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
7152     fi
7153     fi
7154     ;;
7155    
7156     *) ;; # Ignore the rest.
7157    
7158     esac
7159     done
7160    
7161     # Clean up.
7162     rm -f a.out a.exe
7163 michael 912 else
7164 michael 945 echo "libtool.m4: error: problem compiling $1 test program"
7165 michael 912 fi
7166    
7167 michael 945 $RM -f confest.$objext
7168 michael 1106 CFLAGS=$_lt_libdeps_save_CFLAGS
7169 michael 912
7170 michael 945 # PORTME: override above test on systems where it is broken
7171     m4_if([$1], [CXX],
7172     [case $host_os in
7173     interix[[3-9]]*)
7174     # Interix 3.5 installs completely hosed .la files for C++, so rather than
7175     # hack all around it, let's just trust "g++" to DTRT.
7176     _LT_TAGVAR(predep_objects,$1)=
7177     _LT_TAGVAR(postdep_objects,$1)=
7178     _LT_TAGVAR(postdeps,$1)=
7179     ;;
7180    
7181     linux*)
7182     case `$CC -V 2>&1 | sed 5q` in
7183     *Sun\ C*)
7184     # Sun C++ 5.9
7185    
7186     # The more standards-conforming stlport4 library is
7187     # incompatible with the Cstd library. Avoid specifying
7188     # it if it's in CXXFLAGS. Ignore libCrun as
7189     # -library=stlport4 depends on it.
7190     case " $CXX $CXXFLAGS " in
7191     *" -library=stlport4 "*)
7192     solaris_use_stlport4=yes
7193     ;;
7194     esac
7195    
7196     if test "$solaris_use_stlport4" != yes; then
7197     _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7198     fi
7199     ;;
7200     esac
7201     ;;
7202    
7203     solaris*)
7204     case $cc_basename in
7205 michael 1094 CC* | sunCC*)
7206 michael 945 # The more standards-conforming stlport4 library is
7207     # incompatible with the Cstd library. Avoid specifying
7208     # it if it's in CXXFLAGS. Ignore libCrun as
7209     # -library=stlport4 depends on it.
7210     case " $CXX $CXXFLAGS " in
7211     *" -library=stlport4 "*)
7212     solaris_use_stlport4=yes
7213     ;;
7214     esac
7215    
7216     # Adding this requires a known-good setup of shared libraries for
7217     # Sun compiler versions before 5.6, else PIC objects from an old
7218     # archive will be linked into the output, leading to subtle bugs.
7219     if test "$solaris_use_stlport4" != yes; then
7220     _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7221     fi
7222     ;;
7223     esac
7224     ;;
7225     esac
7226     ])
7227    
7228     case " $_LT_TAGVAR(postdeps, $1) " in
7229     *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
7230     esac
7231     _LT_TAGVAR(compiler_lib_search_dirs, $1)=
7232     if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
7233     _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
7234     fi
7235     _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
7236     [The directories searched by this compiler when creating a shared library])
7237     _LT_TAGDECL([], [predep_objects], [1],
7238     [Dependencies to place before and after the objects being linked to
7239     create a shared library])
7240     _LT_TAGDECL([], [postdep_objects], [1])
7241     _LT_TAGDECL([], [predeps], [1])
7242     _LT_TAGDECL([], [postdeps], [1])
7243     _LT_TAGDECL([], [compiler_lib_search_path], [1],
7244     [The library search path used internally by the compiler when linking
7245     a shared library])
7246     ])# _LT_SYS_HIDDEN_LIBDEPS
7247    
7248    
7249     # _LT_LANG_F77_CONFIG([TAG])
7250     # --------------------------
7251     # Ensure that the configuration variables for a Fortran 77 compiler are
7252     # suitably defined. These variables are subsequently used by _LT_CONFIG
7253     # to write the compiler configuration to `libtool'.
7254     m4_defun([_LT_LANG_F77_CONFIG],
7255 michael 1094 [AC_LANG_PUSH(Fortran 77)
7256     if test -z "$F77" || test "X$F77" = "Xno"; then
7257     _lt_disable_F77=yes
7258     fi
7259 michael 945
7260     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7261     _LT_TAGVAR(allow_undefined_flag, $1)=
7262     _LT_TAGVAR(always_export_symbols, $1)=no
7263     _LT_TAGVAR(archive_expsym_cmds, $1)=
7264     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7265     _LT_TAGVAR(hardcode_direct, $1)=no
7266     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7267     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7268     _LT_TAGVAR(hardcode_libdir_separator, $1)=
7269     _LT_TAGVAR(hardcode_minus_L, $1)=no
7270     _LT_TAGVAR(hardcode_automatic, $1)=no
7271     _LT_TAGVAR(inherit_rpath, $1)=no
7272     _LT_TAGVAR(module_cmds, $1)=
7273     _LT_TAGVAR(module_expsym_cmds, $1)=
7274     _LT_TAGVAR(link_all_deplibs, $1)=unknown
7275     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7276 michael 1094 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7277     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7278 michael 945 _LT_TAGVAR(no_undefined_flag, $1)=
7279     _LT_TAGVAR(whole_archive_flag_spec, $1)=
7280     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7281    
7282     # Source file extension for f77 test sources.
7283     ac_ext=f
7284    
7285     # Object file extension for compiled f77 test sources.
7286     objext=o
7287     _LT_TAGVAR(objext, $1)=$objext
7288    
7289     # No sense in running all these tests if we already determined that
7290     # the F77 compiler isn't working. Some variables (like enable_shared)
7291     # are currently assumed to apply to all compilers on this platform,
7292     # and will be corrupted by setting them based on a non-working compiler.
7293     if test "$_lt_disable_F77" != yes; then
7294     # Code to be used in simple compile tests
7295     lt_simple_compile_test_code="\
7296     subroutine t
7297     return
7298     end
7299     "
7300    
7301     # Code to be used in simple link tests
7302     lt_simple_link_test_code="\
7303     program t
7304     end
7305     "
7306    
7307     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7308     _LT_TAG_COMPILER
7309    
7310     # save warnings/boilerplate of simple test code
7311     _LT_COMPILER_BOILERPLATE
7312     _LT_LINKER_BOILERPLATE
7313    
7314     # Allow CC to be a program name with arguments.
7315     lt_save_CC="$CC"
7316     lt_save_GCC=$GCC
7317 michael 1106 lt_save_CFLAGS=$CFLAGS
7318 michael 945 CC=${F77-"f77"}
7319 michael 1106 CFLAGS=$FFLAGS
7320 michael 945 compiler=$CC
7321     _LT_TAGVAR(compiler, $1)=$CC
7322     _LT_CC_BASENAME([$compiler])
7323     GCC=$G77
7324     if test -n "$compiler"; then
7325     AC_MSG_CHECKING([if libtool supports shared libraries])
7326     AC_MSG_RESULT([$can_build_shared])
7327    
7328     AC_MSG_CHECKING([whether to build shared libraries])
7329     test "$can_build_shared" = "no" && enable_shared=no
7330    
7331     # On AIX, shared libraries and static libraries use the same namespace, and
7332     # are all built from PIC.
7333     case $host_os in
7334     aix3*)
7335     test "$enable_shared" = yes && enable_static=no
7336     if test -n "$RANLIB"; then
7337     archive_cmds="$archive_cmds~\$RANLIB \$lib"
7338     postinstall_cmds='$RANLIB $lib'
7339     fi
7340     ;;
7341     aix[[4-9]]*)
7342     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7343     test "$enable_shared" = yes && enable_static=no
7344     fi
7345     ;;
7346     esac
7347     AC_MSG_RESULT([$enable_shared])
7348    
7349     AC_MSG_CHECKING([whether to build static libraries])
7350     # Make sure either enable_shared or enable_static is yes.
7351     test "$enable_shared" = yes || enable_static=yes
7352     AC_MSG_RESULT([$enable_static])
7353    
7354     _LT_TAGVAR(GCC, $1)="$G77"
7355     _LT_TAGVAR(LD, $1)="$LD"
7356    
7357     ## CAVEAT EMPTOR:
7358     ## There is no encapsulation within the following macros, do not change
7359     ## the running order or otherwise move them around unless you know exactly
7360     ## what you are doing...
7361     _LT_COMPILER_PIC($1)
7362     _LT_COMPILER_C_O($1)
7363     _LT_COMPILER_FILE_LOCKS($1)
7364     _LT_LINKER_SHLIBS($1)
7365     _LT_SYS_DYNAMIC_LINKER($1)
7366     _LT_LINKER_HARDCODE_LIBPATH($1)
7367    
7368     _LT_CONFIG($1)
7369     fi # test -n "$compiler"
7370    
7371     GCC=$lt_save_GCC
7372     CC="$lt_save_CC"
7373 michael 1106 CFLAGS="$lt_save_CFLAGS"
7374 michael 945 fi # test "$_lt_disable_F77" != yes
7375    
7376     AC_LANG_POP
7377     ])# _LT_LANG_F77_CONFIG
7378    
7379    
7380     # _LT_LANG_FC_CONFIG([TAG])
7381     # -------------------------
7382     # Ensure that the configuration variables for a Fortran compiler are
7383     # suitably defined. These variables are subsequently used by _LT_CONFIG
7384     # to write the compiler configuration to `libtool'.
7385     m4_defun([_LT_LANG_FC_CONFIG],
7386 michael 1094 [AC_LANG_PUSH(Fortran)
7387 michael 945
7388 michael 1094 if test -z "$FC" || test "X$FC" = "Xno"; then
7389     _lt_disable_FC=yes
7390     fi
7391    
7392 michael 945 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7393     _LT_TAGVAR(allow_undefined_flag, $1)=
7394     _LT_TAGVAR(always_export_symbols, $1)=no
7395     _LT_TAGVAR(archive_expsym_cmds, $1)=
7396     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7397     _LT_TAGVAR(hardcode_direct, $1)=no
7398     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7399     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7400     _LT_TAGVAR(hardcode_libdir_separator, $1)=
7401     _LT_TAGVAR(hardcode_minus_L, $1)=no
7402     _LT_TAGVAR(hardcode_automatic, $1)=no
7403     _LT_TAGVAR(inherit_rpath, $1)=no
7404     _LT_TAGVAR(module_cmds, $1)=
7405     _LT_TAGVAR(module_expsym_cmds, $1)=
7406     _LT_TAGVAR(link_all_deplibs, $1)=unknown
7407     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7408 michael 1094 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7409     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7410 michael 945 _LT_TAGVAR(no_undefined_flag, $1)=
7411     _LT_TAGVAR(whole_archive_flag_spec, $1)=
7412     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7413    
7414     # Source file extension for fc test sources.
7415     ac_ext=${ac_fc_srcext-f}
7416    
7417     # Object file extension for compiled fc test sources.
7418     objext=o
7419     _LT_TAGVAR(objext, $1)=$objext
7420    
7421     # No sense in running all these tests if we already determined that
7422     # the FC compiler isn't working. Some variables (like enable_shared)
7423     # are currently assumed to apply to all compilers on this platform,
7424     # and will be corrupted by setting them based on a non-working compiler.
7425     if test "$_lt_disable_FC" != yes; then
7426     # Code to be used in simple compile tests
7427     lt_simple_compile_test_code="\
7428     subroutine t
7429     return
7430     end
7431     "
7432    
7433     # Code to be used in simple link tests
7434     lt_simple_link_test_code="\
7435     program t
7436     end
7437     "
7438    
7439     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7440     _LT_TAG_COMPILER
7441    
7442     # save warnings/boilerplate of simple test code
7443     _LT_COMPILER_BOILERPLATE
7444     _LT_LINKER_BOILERPLATE
7445    
7446     # Allow CC to be a program name with arguments.
7447     lt_save_CC="$CC"
7448     lt_save_GCC=$GCC
7449 michael 1106 lt_save_CFLAGS=$CFLAGS
7450 michael 945 CC=${FC-"f95"}
7451 michael 1106 CFLAGS=$FCFLAGS
7452 michael 945 compiler=$CC
7453     GCC=$ac_cv_fc_compiler_gnu
7454    
7455     _LT_TAGVAR(compiler, $1)=$CC
7456     _LT_CC_BASENAME([$compiler])
7457    
7458     if test -n "$compiler"; then
7459     AC_MSG_CHECKING([if libtool supports shared libraries])
7460     AC_MSG_RESULT([$can_build_shared])
7461    
7462     AC_MSG_CHECKING([whether to build shared libraries])
7463     test "$can_build_shared" = "no" && enable_shared=no
7464    
7465     # On AIX, shared libraries and static libraries use the same namespace, and
7466     # are all built from PIC.
7467     case $host_os in
7468     aix3*)
7469     test "$enable_shared" = yes && enable_static=no
7470     if test -n "$RANLIB"; then
7471     archive_cmds="$archive_cmds~\$RANLIB \$lib"
7472     postinstall_cmds='$RANLIB $lib'
7473     fi
7474     ;;
7475     aix[[4-9]]*)
7476     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7477     test "$enable_shared" = yes && enable_static=no
7478     fi
7479     ;;
7480     esac
7481     AC_MSG_RESULT([$enable_shared])
7482    
7483     AC_MSG_CHECKING([whether to build static libraries])
7484     # Make sure either enable_shared or enable_static is yes.
7485     test "$enable_shared" = yes || enable_static=yes
7486     AC_MSG_RESULT([$enable_static])
7487    
7488     _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
7489     _LT_TAGVAR(LD, $1)="$LD"
7490    
7491     ## CAVEAT EMPTOR:
7492     ## There is no encapsulation within the following macros, do not change
7493     ## the running order or otherwise move them around unless you know exactly
7494     ## what you are doing...
7495     _LT_SYS_HIDDEN_LIBDEPS($1)
7496     _LT_COMPILER_PIC($1)
7497     _LT_COMPILER_C_O($1)
7498     _LT_COMPILER_FILE_LOCKS($1)
7499     _LT_LINKER_SHLIBS($1)
7500     _LT_SYS_DYNAMIC_LINKER($1)
7501     _LT_LINKER_HARDCODE_LIBPATH($1)
7502    
7503     _LT_CONFIG($1)
7504     fi # test -n "$compiler"
7505    
7506     GCC=$lt_save_GCC
7507 michael 1106 CC=$lt_save_CC
7508     CFLAGS=$lt_save_CFLAGS
7509 michael 945 fi # test "$_lt_disable_FC" != yes
7510    
7511     AC_LANG_POP
7512     ])# _LT_LANG_FC_CONFIG
7513    
7514    
7515     # _LT_LANG_GCJ_CONFIG([TAG])
7516     # --------------------------
7517     # Ensure that the configuration variables for the GNU Java Compiler compiler
7518     # are suitably defined. These variables are subsequently used by _LT_CONFIG
7519     # to write the compiler configuration to `libtool'.
7520     m4_defun([_LT_LANG_GCJ_CONFIG],
7521     [AC_REQUIRE([LT_PROG_GCJ])dnl
7522     AC_LANG_SAVE
7523    
7524     # Source file extension for Java test sources.
7525     ac_ext=java
7526    
7527     # Object file extension for compiled Java test sources.
7528     objext=o
7529     _LT_TAGVAR(objext, $1)=$objext
7530    
7531     # Code to be used in simple compile tests
7532     lt_simple_compile_test_code="class foo {}"
7533    
7534     # Code to be used in simple link tests
7535     lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
7536    
7537     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7538     _LT_TAG_COMPILER
7539    
7540 michael 1072 # save warnings/boilerplate of simple test code
7541     _LT_COMPILER_BOILERPLATE
7542     _LT_LINKER_BOILERPLATE
7543    
7544 michael 945 # Allow CC to be a program name with arguments.
7545 michael 1106 lt_save_CC=$CC
7546     lt_save_CFLAGS=$CFLAGS
7547 michael 945 lt_save_GCC=$GCC
7548     GCC=yes
7549     CC=${GCJ-"gcj"}
7550 michael 1106 CFLAGS=$GCJFLAGS
7551 michael 945 compiler=$CC
7552     _LT_TAGVAR(compiler, $1)=$CC
7553     _LT_TAGVAR(LD, $1)="$LD"
7554     _LT_CC_BASENAME([$compiler])
7555    
7556     # GCJ did not exist at the time GCC didn't implicitly link libc in.
7557     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7558    
7559     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7560 michael 1094 _LT_TAGVAR(reload_flag, $1)=$reload_flag
7561     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7562 michael 945
7563     if test -n "$compiler"; then
7564     _LT_COMPILER_NO_RTTI($1)
7565     _LT_COMPILER_PIC($1)
7566     _LT_COMPILER_C_O($1)
7567     _LT_COMPILER_FILE_LOCKS($1)
7568     _LT_LINKER_SHLIBS($1)
7569     _LT_LINKER_HARDCODE_LIBPATH($1)
7570    
7571     _LT_CONFIG($1)
7572     fi
7573    
7574     AC_LANG_RESTORE
7575    
7576     GCC=$lt_save_GCC
7577 michael 1106 CC=$lt_save_CC
7578     CFLAGS=$lt_save_CFLAGS
7579 michael 945 ])# _LT_LANG_GCJ_CONFIG
7580    
7581    
7582 michael 1257 # _LT_LANG_GO_CONFIG([TAG])
7583     # --------------------------
7584     # Ensure that the configuration variables for the GNU Go compiler
7585     # are suitably defined. These variables are subsequently used by _LT_CONFIG
7586     # to write the compiler configuration to `libtool'.
7587     m4_defun([_LT_LANG_GO_CONFIG],
7588     [AC_REQUIRE([LT_PROG_GO])dnl
7589     AC_LANG_SAVE
7590    
7591     # Source file extension for Go test sources.
7592     ac_ext=go
7593    
7594     # Object file extension for compiled Go test sources.
7595     objext=o
7596     _LT_TAGVAR(objext, $1)=$objext
7597    
7598     # Code to be used in simple compile tests
7599     lt_simple_compile_test_code="package main; func main() { }"
7600    
7601     # Code to be used in simple link tests
7602     lt_simple_link_test_code='package main; func main() { }'
7603    
7604     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7605     _LT_TAG_COMPILER
7606    
7607     # save warnings/boilerplate of simple test code
7608     _LT_COMPILER_BOILERPLATE
7609     _LT_LINKER_BOILERPLATE
7610    
7611     # Allow CC to be a program name with arguments.
7612     lt_save_CC=$CC
7613     lt_save_CFLAGS=$CFLAGS
7614     lt_save_GCC=$GCC
7615     GCC=yes
7616     CC=${GOC-"gccgo"}
7617     CFLAGS=$GOFLAGS
7618     compiler=$CC
7619     _LT_TAGVAR(compiler, $1)=$CC
7620     _LT_TAGVAR(LD, $1)="$LD"
7621     _LT_CC_BASENAME([$compiler])
7622    
7623     # Go did not exist at the time GCC didn't implicitly link libc in.
7624     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7625    
7626     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7627     _LT_TAGVAR(reload_flag, $1)=$reload_flag
7628     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7629    
7630     if test -n "$compiler"; then
7631     _LT_COMPILER_NO_RTTI($1)
7632     _LT_COMPILER_PIC($1)
7633     _LT_COMPILER_C_O($1)
7634     _LT_COMPILER_FILE_LOCKS($1)
7635     _LT_LINKER_SHLIBS($1)
7636     _LT_LINKER_HARDCODE_LIBPATH($1)
7637    
7638     _LT_CONFIG($1)
7639     fi
7640    
7641     AC_LANG_RESTORE
7642    
7643     GCC=$lt_save_GCC
7644     CC=$lt_save_CC
7645     CFLAGS=$lt_save_CFLAGS
7646     ])# _LT_LANG_GO_CONFIG
7647    
7648    
7649 michael 945 # _LT_LANG_RC_CONFIG([TAG])
7650     # -------------------------
7651     # Ensure that the configuration variables for the Windows resource compiler
7652     # are suitably defined. These variables are subsequently used by _LT_CONFIG
7653     # to write the compiler configuration to `libtool'.
7654     m4_defun([_LT_LANG_RC_CONFIG],
7655     [AC_REQUIRE([LT_PROG_RC])dnl
7656     AC_LANG_SAVE
7657    
7658     # Source file extension for RC test sources.
7659     ac_ext=rc
7660    
7661     # Object file extension for compiled RC test sources.
7662     objext=o
7663     _LT_TAGVAR(objext, $1)=$objext
7664    
7665     # Code to be used in simple compile tests
7666     lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
7667    
7668     # Code to be used in simple link tests
7669     lt_simple_link_test_code="$lt_simple_compile_test_code"
7670    
7671     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7672     _LT_TAG_COMPILER
7673    
7674     # save warnings/boilerplate of simple test code
7675     _LT_COMPILER_BOILERPLATE
7676     _LT_LINKER_BOILERPLATE
7677    
7678     # Allow CC to be a program name with arguments.
7679     lt_save_CC="$CC"
7680 michael 1106 lt_save_CFLAGS=$CFLAGS
7681 michael 945 lt_save_GCC=$GCC
7682     GCC=
7683     CC=${RC-"windres"}
7684 michael 1106 CFLAGS=
7685 michael 945 compiler=$CC
7686     _LT_TAGVAR(compiler, $1)=$CC
7687     _LT_CC_BASENAME([$compiler])
7688     _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
7689    
7690     if test -n "$compiler"; then
7691     :
7692     _LT_CONFIG($1)
7693     fi
7694    
7695     GCC=$lt_save_GCC
7696     AC_LANG_RESTORE
7697 michael 1106 CC=$lt_save_CC
7698     CFLAGS=$lt_save_CFLAGS
7699 michael 945 ])# _LT_LANG_RC_CONFIG
7700    
7701    
7702     # LT_PROG_GCJ
7703     # -----------
7704     AC_DEFUN([LT_PROG_GCJ],
7705     [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
7706     [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
7707     [AC_CHECK_TOOL(GCJ, gcj,)
7708     test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7709     AC_SUBST(GCJFLAGS)])])[]dnl
7710     ])
7711    
7712     # Old name:
7713     AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
7714     dnl aclocal-1.4 backwards compatibility:
7715     dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
7716    
7717    
7718 michael 1257 # LT_PROG_GO
7719     # ----------
7720     AC_DEFUN([LT_PROG_GO],
7721     [AC_CHECK_TOOL(GOC, gccgo,)
7722     ])
7723    
7724    
7725 michael 945 # LT_PROG_RC
7726     # ----------
7727     AC_DEFUN([LT_PROG_RC],
7728     [AC_CHECK_TOOL(RC, windres,)
7729     ])
7730    
7731     # Old name:
7732     AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
7733     dnl aclocal-1.4 backwards compatibility:
7734     dnl AC_DEFUN([LT_AC_PROG_RC], [])
7735    
7736    
7737     # _LT_DECL_EGREP
7738     # --------------
7739     # If we don't have a new enough Autoconf to choose the best grep
7740     # available, choose the one first in the user's PATH.
7741     m4_defun([_LT_DECL_EGREP],
7742     [AC_REQUIRE([AC_PROG_EGREP])dnl
7743     AC_REQUIRE([AC_PROG_FGREP])dnl
7744     test -z "$GREP" && GREP=grep
7745     _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
7746     _LT_DECL([], [EGREP], [1], [An ERE matcher])
7747     _LT_DECL([], [FGREP], [1], [A literal string matcher])
7748     dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
7749     AC_SUBST([GREP])
7750     ])
7751    
7752    
7753     # _LT_DECL_OBJDUMP
7754     # --------------
7755     # If we don't have a new enough Autoconf to choose the best objdump
7756     # available, choose the one first in the user's PATH.
7757     m4_defun([_LT_DECL_OBJDUMP],
7758     [AC_CHECK_TOOL(OBJDUMP, objdump, false)
7759     test -z "$OBJDUMP" && OBJDUMP=objdump
7760     _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
7761     AC_SUBST([OBJDUMP])
7762     ])
7763    
7764 michael 1106 # _LT_DECL_DLLTOOL
7765     # ----------------
7766     # Ensure DLLTOOL variable is set.
7767     m4_defun([_LT_DECL_DLLTOOL],
7768     [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
7769     test -z "$DLLTOOL" && DLLTOOL=dlltool
7770     _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
7771     AC_SUBST([DLLTOOL])
7772     ])
7773 michael 945
7774     # _LT_DECL_SED
7775     # ------------
7776     # Check for a fully-functional sed program, that truncates
7777     # as few characters as possible. Prefer GNU sed if found.
7778     m4_defun([_LT_DECL_SED],
7779     [AC_PROG_SED
7780     test -z "$SED" && SED=sed
7781     Xsed="$SED -e 1s/^X//"
7782     _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
7783     _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
7784     [Sed that helps us avoid accidentally triggering echo(1) options like -n])
7785     ])# _LT_DECL_SED
7786    
7787     m4_ifndef([AC_PROG_SED], [
7788 michael 912 # NOTE: This macro has been submitted for inclusion into #
7789     # GNU Autoconf as AC_PROG_SED. When it is available in #
7790     # a released version of Autoconf we should remove this #
7791     # macro and use it instead. #
7792 michael 945
7793     m4_defun([AC_PROG_SED],
7794 michael 912 [AC_MSG_CHECKING([for a sed that does not truncate output])
7795     AC_CACHE_VAL(lt_cv_path_SED,
7796     [# Loop through the user's path and test for sed and gsed.
7797     # Then use that list of sed's as ones to test for truncation.
7798     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7799     for as_dir in $PATH
7800     do
7801     IFS=$as_save_IFS
7802     test -z "$as_dir" && as_dir=.
7803     for lt_ac_prog in sed gsed; do
7804     for ac_exec_ext in '' $ac_executable_extensions; do
7805 michael 945 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
7806 michael 912 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7807     fi
7808     done
7809     done
7810     done
7811     IFS=$as_save_IFS
7812     lt_ac_max=0
7813     lt_ac_count=0
7814     # Add /usr/xpg4/bin/sed as it is typically found on Solaris
7815     # along with /bin/sed that truncates output.
7816     for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7817     test ! -f $lt_ac_sed && continue
7818     cat /dev/null > conftest.in
7819     lt_ac_count=0
7820     echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7821     # Check for GNU sed and select it if it is found.
7822     if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7823     lt_cv_path_SED=$lt_ac_sed
7824     break
7825     fi
7826     while true; do
7827     cat conftest.in conftest.in >conftest.tmp
7828     mv conftest.tmp conftest.in
7829     cp conftest.in conftest.nl
7830     echo >>conftest.nl
7831     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7832     cmp -s conftest.out conftest.nl || break
7833     # 10000 chars as input seems more than enough
7834     test $lt_ac_count -gt 10 && break
7835     lt_ac_count=`expr $lt_ac_count + 1`
7836     if test $lt_ac_count -gt $lt_ac_max; then
7837     lt_ac_max=$lt_ac_count
7838     lt_cv_path_SED=$lt_ac_sed
7839     fi
7840     done
7841     done
7842     ])
7843     SED=$lt_cv_path_SED
7844     AC_SUBST([SED])
7845     AC_MSG_RESULT([$SED])
7846 michael 945 ])#AC_PROG_SED
7847     ])#m4_ifndef
7848    
7849     # Old name:
7850     AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
7851     dnl aclocal-1.4 backwards compatibility:
7852     dnl AC_DEFUN([LT_AC_PROG_SED], [])
7853    
7854    
7855     # _LT_CHECK_SHELL_FEATURES
7856     # ------------------------
7857     # Find out whether the shell is Bourne or XSI compatible,
7858     # or has some other useful features.
7859     m4_defun([_LT_CHECK_SHELL_FEATURES],
7860     [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
7861     # Try some XSI features
7862     xsi_shell=no
7863     ( _lt_dummy="a/b/c"
7864 michael 1106 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
7865     = c,a/b,b/c, \
7866 michael 945 && eval 'test $(( 1 + 1 )) -eq 2 \
7867     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7868     && xsi_shell=yes
7869     AC_MSG_RESULT([$xsi_shell])
7870     _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
7871    
7872     AC_MSG_CHECKING([whether the shell understands "+="])
7873     lt_shell_append=no
7874     ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
7875     >/dev/null 2>&1 \
7876     && lt_shell_append=yes
7877     AC_MSG_RESULT([$lt_shell_append])
7878     _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
7879    
7880     if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7881     lt_unset=unset
7882     else
7883     lt_unset=false
7884     fi
7885     _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
7886    
7887     # test EBCDIC or ASCII
7888     case `echo X|tr X '\101'` in
7889     A) # ASCII based system
7890     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7891     lt_SP2NL='tr \040 \012'
7892     lt_NL2SP='tr \015\012 \040\040'
7893     ;;
7894     *) # EBCDIC based system
7895     lt_SP2NL='tr \100 \n'
7896     lt_NL2SP='tr \r\n \100\100'
7897     ;;
7898     esac
7899     _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
7900     _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
7901     ])# _LT_CHECK_SHELL_FEATURES
7902    
7903    
7904 michael 1106 # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
7905     # ------------------------------------------------------
7906     # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
7907     # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
7908     m4_defun([_LT_PROG_FUNCTION_REPLACE],
7909     [dnl {
7910     sed -e '/^$1 ()$/,/^} # $1 /c\
7911     $1 ()\
7912     {\
7913     m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
7914     } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
7915     && mv -f "$cfgfile.tmp" "$cfgfile" \
7916     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7917     test 0 -eq $? || _lt_function_replace_fail=:
7918     ])
7919 michael 945
7920    
7921 michael 1106 # _LT_PROG_REPLACE_SHELLFNS
7922     # -------------------------
7923     # Replace existing portable implementations of several shell functions with
7924     # equivalent extended shell implementations where those features are available..
7925     m4_defun([_LT_PROG_REPLACE_SHELLFNS],
7926     [if test x"$xsi_shell" = xyes; then
7927     _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
7928     case ${1} in
7929     */*) func_dirname_result="${1%/*}${2}" ;;
7930     * ) func_dirname_result="${3}" ;;
7931     esac])
7932 michael 945
7933 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
7934     func_basename_result="${1##*/}"])
7935 michael 945
7936 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
7937     case ${1} in
7938     */*) func_dirname_result="${1%/*}${2}" ;;
7939     * ) func_dirname_result="${3}" ;;
7940     esac
7941     func_basename_result="${1##*/}"])
7942 michael 945
7943 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
7944     # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
7945     # positional parameters, so assign one to ordinary parameter first.
7946     func_stripname_result=${3}
7947     func_stripname_result=${func_stripname_result#"${1}"}
7948     func_stripname_result=${func_stripname_result%"${2}"}])
7949 michael 945
7950 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
7951     func_split_long_opt_name=${1%%=*}
7952     func_split_long_opt_arg=${1#*=}])
7953 michael 945
7954 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
7955     func_split_short_opt_arg=${1#??}
7956     func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
7957 michael 945
7958 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
7959     case ${1} in
7960     *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
7961     *) func_lo2o_result=${1} ;;
7962     esac])
7963 michael 945
7964 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
7965 michael 945
7966 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
7967 michael 945
7968 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
7969     fi
7970 michael 945
7971 michael 1106 if test x"$lt_shell_append" = xyes; then
7972     _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
7973 michael 945
7974 michael 1106 _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
7975     func_quote_for_eval "${2}"
7976     dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
7977     eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
7978 michael 945
7979 michael 1106 # Save a `func_append' function call where possible by direct use of '+='
7980     sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
7981     && mv -f "$cfgfile.tmp" "$cfgfile" \
7982     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7983     test 0 -eq $? || _lt_function_replace_fail=:
7984     else
7985     # Save a `func_append' function call even when '+=' is not available
7986     sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
7987     && mv -f "$cfgfile.tmp" "$cfgfile" \
7988     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7989     test 0 -eq $? || _lt_function_replace_fail=:
7990     fi
7991 michael 945
7992 michael 1106 if test x"$_lt_function_replace_fail" = x":"; then
7993     AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
7994     fi
7995     ])
7996 michael 945
7997 michael 1106 # _LT_PATH_CONVERSION_FUNCTIONS
7998     # -----------------------------
7999     # Determine which file name conversion functions should be used by
8000     # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
8001     # for certain cross-compile configurations and native mingw.
8002     m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
8003     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8004     AC_REQUIRE([AC_CANONICAL_BUILD])dnl
8005     AC_MSG_CHECKING([how to convert $build file names to $host format])
8006     AC_CACHE_VAL(lt_cv_to_host_file_cmd,
8007     [case $host in
8008     *-*-mingw* )
8009     case $build in
8010     *-*-mingw* ) # actually msys
8011     lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8012     ;;
8013     *-*-cygwin* )
8014     lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8015     ;;
8016     * ) # otherwise, assume *nix
8017     lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8018     ;;
8019     esac
8020     ;;
8021     *-*-cygwin* )
8022     case $build in
8023     *-*-mingw* ) # actually msys
8024     lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8025     ;;
8026     *-*-cygwin* )
8027     lt_cv_to_host_file_cmd=func_convert_file_noop
8028     ;;
8029     * ) # otherwise, assume *nix
8030     lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8031     ;;
8032     esac
8033     ;;
8034     * ) # unhandled hosts (and "normal" native builds)
8035     lt_cv_to_host_file_cmd=func_convert_file_noop
8036     ;;
8037 michael 945 esac
8038 michael 1106 ])
8039     to_host_file_cmd=$lt_cv_to_host_file_cmd
8040     AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
8041     _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
8042     [0], [convert $build file names to $host format])dnl
8043 michael 945
8044 michael 1106 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
8045     AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
8046     [#assume ordinary cross tools, or native build.
8047     lt_cv_to_tool_file_cmd=func_convert_file_noop
8048     case $host in
8049     *-*-mingw* )
8050     case $build in
8051     *-*-mingw* ) # actually msys
8052     lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8053     ;;
8054     esac
8055 michael 945 ;;
8056 michael 1106 esac
8057 michael 912 ])
8058 michael 1106 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8059     AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
8060     _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
8061     [0], [convert $build files to toolchain format])dnl
8062     ])# _LT_PATH_CONVERSION_FUNCTIONS
8063 michael 912
8064 michael 945 # ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*-
8065 michael 912 #
8066 michael 1257 # Copyright (C) 1999-2006, 2007, 2008, 2011 Free Software Foundation, Inc.
8067 michael 945 # Written by Thomas Tanner, 1999
8068     #
8069     # This file is free software; the Free Software Foundation gives
8070     # unlimited permission to copy and/or distribute it, with or without
8071     # modifications, as long as this notice is preserved.
8072    
8073 michael 1094 # serial 18 LTDL_INIT
8074 michael 945
8075     # LT_CONFIG_LTDL_DIR(DIRECTORY, [LTDL-MODE])
8076     # ------------------------------------------
8077     # DIRECTORY contains the libltdl sources. It is okay to call this
8078     # function multiple times, as long as the same DIRECTORY is always given.
8079     AC_DEFUN([LT_CONFIG_LTDL_DIR],
8080     [AC_BEFORE([$0], [LTDL_INIT])
8081     _$0($*)
8082     ])# LT_CONFIG_LTDL_DIR
8083    
8084     # We break this out into a separate macro, so that we can call it safely
8085     # internally without being caught accidentally by the sed scan in libtoolize.
8086     m4_defun([_LT_CONFIG_LTDL_DIR],
8087     [dnl remove trailing slashes
8088     m4_pushdef([_ARG_DIR], m4_bpatsubst([$1], [/*$]))
8089     m4_case(_LTDL_DIR,
8090     [], [dnl only set lt_ltdl_dir if _ARG_DIR is not simply `.'
8091     m4_if(_ARG_DIR, [.],
8092     [],
8093     [m4_define([_LTDL_DIR], _ARG_DIR)
8094     _LT_SHELL_INIT([lt_ltdl_dir=']_ARG_DIR['])])],
8095     [m4_if(_ARG_DIR, _LTDL_DIR,
8096     [],
8097     [m4_fatal([multiple libltdl directories: `]_LTDL_DIR[', `]_ARG_DIR['])])])
8098     m4_popdef([_ARG_DIR])
8099     ])# _LT_CONFIG_LTDL_DIR
8100    
8101     # Initialise:
8102     m4_define([_LTDL_DIR], [])
8103    
8104    
8105     # _LT_BUILD_PREFIX
8106     # ----------------
8107     # If Autoconf is new enough, expand to `${top_build_prefix}', otherwise
8108     # to `${top_builddir}/'.
8109     m4_define([_LT_BUILD_PREFIX],
8110     [m4_ifdef([AC_AUTOCONF_VERSION],
8111     [m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]), [2.62]),
8112     [-1], [m4_ifdef([_AC_HAVE_TOP_BUILD_PREFIX],
8113     [${top_build_prefix}],
8114     [${top_builddir}/])],
8115     [${top_build_prefix}])],
8116     [${top_builddir}/])[]dnl
8117     ])
8118    
8119    
8120     # LTDL_CONVENIENCE
8121     # ----------------
8122     # sets LIBLTDL to the link flags for the libltdl convenience library and
8123     # LTDLINCL to the include flags for the libltdl header and adds
8124     # --enable-ltdl-convenience to the configure arguments. Note that
8125     # AC_CONFIG_SUBDIRS is not called here. LIBLTDL will be prefixed with
8126     # '${top_build_prefix}' if available, otherwise with '${top_builddir}/',
8127     # and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single
8128     # quotes!). If your package is not flat and you're not using automake,
8129     # define top_build_prefix, top_builddir, and top_srcdir appropriately
8130     # in your Makefiles.
8131     AC_DEFUN([LTDL_CONVENIENCE],
8132     [AC_BEFORE([$0], [LTDL_INIT])dnl
8133     dnl Although the argument is deprecated and no longer documented,
8134     dnl LTDL_CONVENIENCE used to take a DIRECTORY orgument, if we have one
8135     dnl here make sure it is the same as any other declaration of libltdl's
8136     dnl location! This also ensures lt_ltdl_dir is set when configure.ac is
8137     dnl not yet using an explicit LT_CONFIG_LTDL_DIR.
8138     m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl
8139     _$0()
8140     ])# LTDL_CONVENIENCE
8141    
8142     # AC_LIBLTDL_CONVENIENCE accepted a directory argument in older libtools,
8143     # now we have LT_CONFIG_LTDL_DIR:
8144     AU_DEFUN([AC_LIBLTDL_CONVENIENCE],
8145     [_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])])
8146     _LTDL_CONVENIENCE])
8147    
8148     dnl aclocal-1.4 backwards compatibility:
8149     dnl AC_DEFUN([AC_LIBLTDL_CONVENIENCE], [])
8150    
8151    
8152     # _LTDL_CONVENIENCE
8153     # -----------------
8154     # Code shared by LTDL_CONVENIENCE and LTDL_INIT([convenience]).
8155     m4_defun([_LTDL_CONVENIENCE],
8156     [case $enable_ltdl_convenience in
8157     no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
8158     "") enable_ltdl_convenience=yes
8159     ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
8160     esac
8161     LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdlc.la"
8162     LTDLDEPS=$LIBLTDL
8163     LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}"
8164    
8165     AC_SUBST([LIBLTDL])
8166     AC_SUBST([LTDLDEPS])
8167     AC_SUBST([LTDLINCL])
8168    
8169     # For backwards non-gettext consistent compatibility...
8170     INCLTDL="$LTDLINCL"
8171     AC_SUBST([INCLTDL])
8172     ])# _LTDL_CONVENIENCE
8173    
8174    
8175     # LTDL_INSTALLABLE
8176     # ----------------
8177     # sets LIBLTDL to the link flags for the libltdl installable library
8178     # and LTDLINCL to the include flags for the libltdl header and adds
8179     # --enable-ltdl-install to the configure arguments. Note that
8180     # AC_CONFIG_SUBDIRS is not called from here. If an installed libltdl
8181     # is not found, LIBLTDL will be prefixed with '${top_build_prefix}' if
8182     # available, otherwise with '${top_builddir}/', and LTDLINCL will be
8183     # prefixed with '${top_srcdir}/' (note the single quotes!). If your
8184     # package is not flat and you're not using automake, define top_build_prefix,
8185     # top_builddir, and top_srcdir appropriately in your Makefiles.
8186     # In the future, this macro may have to be called after LT_INIT.
8187     AC_DEFUN([LTDL_INSTALLABLE],
8188     [AC_BEFORE([$0], [LTDL_INIT])dnl
8189     dnl Although the argument is deprecated and no longer documented,
8190     dnl LTDL_INSTALLABLE used to take a DIRECTORY orgument, if we have one
8191     dnl here make sure it is the same as any other declaration of libltdl's
8192     dnl location! This also ensures lt_ltdl_dir is set when configure.ac is
8193     dnl not yet using an explicit LT_CONFIG_LTDL_DIR.
8194     m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl
8195     _$0()
8196     ])# LTDL_INSTALLABLE
8197    
8198     # AC_LIBLTDL_INSTALLABLE accepted a directory argument in older libtools,
8199     # now we have LT_CONFIG_LTDL_DIR:
8200     AU_DEFUN([AC_LIBLTDL_INSTALLABLE],
8201     [_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])])
8202     _LTDL_INSTALLABLE])
8203    
8204     dnl aclocal-1.4 backwards compatibility:
8205     dnl AC_DEFUN([AC_LIBLTDL_INSTALLABLE], [])
8206    
8207    
8208     # _LTDL_INSTALLABLE
8209     # -----------------
8210     # Code shared by LTDL_INSTALLABLE and LTDL_INIT([installable]).
8211     m4_defun([_LTDL_INSTALLABLE],
8212 michael 1084 [if test -f $prefix/lib/libltdl.la; then
8213     lt_save_LDFLAGS="$LDFLAGS"
8214     LDFLAGS="-L$prefix/lib $LDFLAGS"
8215     AC_CHECK_LIB([ltdl], [lt_dlinit], [lt_lib_ltdl=yes])
8216     LDFLAGS="$lt_save_LDFLAGS"
8217 michael 945 if test x"${lt_lib_ltdl-no}" = xyes; then
8218     if test x"$enable_ltdl_install" != xyes; then
8219 michael 1084 # Don't overwrite $prefix/lib/libltdl.la without --enable-ltdl-install
8220     AC_MSG_WARN([not overwriting libltdl at $prefix, force with `--enable-ltdl-install'])
8221 michael 945 enable_ltdl_install=no
8222     fi
8223     elif test x"$enable_ltdl_install" = xno; then
8224     AC_MSG_WARN([libltdl not installed, but installation disabled])
8225     fi
8226 michael 1084 fi
8227 michael 945
8228     # If configure.ac declared an installable ltdl, and the user didn't override
8229     # with --disable-ltdl-install, we will install the shipped libltdl.
8230     case $enable_ltdl_install in
8231     no) ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
8232     LIBLTDL="-lltdl"
8233     LTDLDEPS=
8234     LTDLINCL=
8235     ;;
8236     *) enable_ltdl_install=yes
8237     ac_configure_args="$ac_configure_args --enable-ltdl-install"
8238     LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdl.la"
8239     LTDLDEPS=$LIBLTDL
8240     LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}"
8241     ;;
8242     esac
8243    
8244     AC_SUBST([LIBLTDL])
8245     AC_SUBST([LTDLDEPS])
8246     AC_SUBST([LTDLINCL])
8247    
8248     # For backwards non-gettext consistent compatibility...
8249     INCLTDL="$LTDLINCL"
8250     AC_SUBST([INCLTDL])
8251     ])# LTDL_INSTALLABLE
8252    
8253    
8254     # _LTDL_MODE_DISPATCH
8255     # -------------------
8256     m4_define([_LTDL_MODE_DISPATCH],
8257     [dnl If _LTDL_DIR is `.', then we are configuring libltdl itself:
8258     m4_if(_LTDL_DIR, [],
8259     [],
8260     dnl if _LTDL_MODE was not set already, the default value is `subproject':
8261     [m4_case(m4_default(_LTDL_MODE, [subproject]),
8262     [subproject], [AC_CONFIG_SUBDIRS(_LTDL_DIR)
8263     _LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"])],
8264     [nonrecursive], [_LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"; lt_libobj_prefix="$lt_ltdl_dir/"])],
8265     [recursive], [],
8266     [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])dnl
8267     dnl Be careful not to expand twice:
8268     m4_define([$0], [])
8269     ])# _LTDL_MODE_DISPATCH
8270    
8271    
8272     # _LT_LIBOBJ(MODULE_NAME)
8273     # -----------------------
8274     # Like AC_LIBOBJ, except that MODULE_NAME goes into _LT_LIBOBJS instead
8275     # of into LIBOBJS.
8276     AC_DEFUN([_LT_LIBOBJ], [
8277     m4_pattern_allow([^_LT_LIBOBJS$])
8278     _LT_LIBOBJS="$_LT_LIBOBJS $1.$ac_objext"
8279     ])# _LT_LIBOBJS
8280    
8281    
8282     # LTDL_INIT([OPTIONS])
8283     # --------------------
8284     # Clients of libltdl can use this macro to allow the installer to
8285     # choose between a shipped copy of the ltdl sources or a preinstalled
8286     # version of the library. If the shipped ltdl sources are not in a
8287     # subdirectory named libltdl, the directory name must be given by
8288     # LT_CONFIG_LTDL_DIR.
8289     AC_DEFUN([LTDL_INIT],
8290     [dnl Parse OPTIONS
8291     _LT_SET_OPTIONS([$0], [$1])
8292    
8293     dnl We need to keep our own list of libobjs separate from our parent project,
8294     dnl and the easiest way to do that is redefine the AC_LIBOBJs macro while
8295     dnl we look for our own LIBOBJs.
8296     m4_pushdef([AC_LIBOBJ], m4_defn([_LT_LIBOBJ]))
8297     m4_pushdef([AC_LIBSOURCES])
8298    
8299     dnl If not otherwise defined, default to the 1.5.x compatible subproject mode:
8300     m4_if(_LTDL_MODE, [],
8301     [m4_define([_LTDL_MODE], m4_default([$2], [subproject]))
8302     m4_if([-1], [m4_bregexp(_LTDL_MODE, [\(subproject\|\(non\)?recursive\)])],
8303     [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])
8304    
8305     AC_ARG_WITH([included_ltdl],
8306     [AS_HELP_STRING([--with-included-ltdl],
8307     [use the GNU ltdl sources included here])])
8308    
8309     if test "x$with_included_ltdl" != xyes; then
8310     # We are not being forced to use the included libltdl sources, so
8311     # decide whether there is a useful installed version we can use.
8312     AC_CHECK_HEADER([ltdl.h],
8313     [AC_CHECK_DECL([lt_dlinterface_register],
8314     [AC_CHECK_LIB([ltdl], [lt_dladvise_preload],
8315     [with_included_ltdl=no],
8316     [with_included_ltdl=yes])],
8317     [with_included_ltdl=yes],
8318     [AC_INCLUDES_DEFAULT
8319     #include <ltdl.h>])],
8320     [with_included_ltdl=yes],
8321     [AC_INCLUDES_DEFAULT]
8322     )
8323     fi
8324    
8325     dnl If neither LT_CONFIG_LTDL_DIR, LTDL_CONVENIENCE nor LTDL_INSTALLABLE
8326     dnl was called yet, then for old times' sake, we assume libltdl is in an
8327     dnl eponymous directory:
8328     AC_PROVIDE_IFELSE([LT_CONFIG_LTDL_DIR], [], [_LT_CONFIG_LTDL_DIR([libltdl])])
8329    
8330     AC_ARG_WITH([ltdl_include],
8331     [AS_HELP_STRING([--with-ltdl-include=DIR],
8332     [use the ltdl headers installed in DIR])])
8333    
8334     if test -n "$with_ltdl_include"; then
8335     if test -f "$with_ltdl_include/ltdl.h"; then :
8336     else
8337     AC_MSG_ERROR([invalid ltdl include directory: `$with_ltdl_include'])
8338     fi
8339     else
8340     with_ltdl_include=no
8341     fi
8342    
8343     AC_ARG_WITH([ltdl_lib],
8344     [AS_HELP_STRING([--with-ltdl-lib=DIR],
8345     [use the libltdl.la installed in DIR])])
8346    
8347     if test -n "$with_ltdl_lib"; then
8348     if test -f "$with_ltdl_lib/libltdl.la"; then :
8349     else
8350     AC_MSG_ERROR([invalid ltdl library directory: `$with_ltdl_lib'])
8351     fi
8352     else
8353     with_ltdl_lib=no
8354     fi
8355    
8356     case ,$with_included_ltdl,$with_ltdl_include,$with_ltdl_lib, in
8357     ,yes,no,no,)
8358     m4_case(m4_default(_LTDL_TYPE, [convenience]),
8359     [convenience], [_LTDL_CONVENIENCE],
8360     [installable], [_LTDL_INSTALLABLE],
8361     [m4_fatal([unknown libltdl build type: ]_LTDL_TYPE)])
8362     ;;
8363     ,no,no,no,)
8364     # If the included ltdl is not to be used, then use the
8365     # preinstalled libltdl we found.
8366     AC_DEFINE([HAVE_LTDL], [1],
8367     [Define this if a modern libltdl is already installed])
8368     LIBLTDL=-lltdl
8369     LTDLDEPS=
8370     LTDLINCL=
8371     ;;
8372     ,no*,no,*)
8373     AC_MSG_ERROR([`--with-ltdl-include' and `--with-ltdl-lib' options must be used together])
8374     ;;
8375     *) with_included_ltdl=no
8376     LIBLTDL="-L$with_ltdl_lib -lltdl"
8377     LTDLDEPS=
8378     LTDLINCL="-I$with_ltdl_include"
8379     ;;
8380     esac
8381     INCLTDL="$LTDLINCL"
8382    
8383     # Report our decision...
8384     AC_MSG_CHECKING([where to find libltdl headers])
8385     AC_MSG_RESULT([$LTDLINCL])
8386     AC_MSG_CHECKING([where to find libltdl library])
8387     AC_MSG_RESULT([$LIBLTDL])
8388    
8389     _LTDL_SETUP
8390    
8391     dnl restore autoconf definition.
8392     m4_popdef([AC_LIBOBJ])
8393     m4_popdef([AC_LIBSOURCES])
8394    
8395     AC_CONFIG_COMMANDS_PRE([
8396     _ltdl_libobjs=
8397     _ltdl_ltlibobjs=
8398     if test -n "$_LT_LIBOBJS"; then
8399     # Remove the extension.
8400     _lt_sed_drop_objext='s/\.o$//;s/\.obj$//'
8401     for i in `for i in $_LT_LIBOBJS; do echo "$i"; done | sed "$_lt_sed_drop_objext" | sort -u`; do
8402     _ltdl_libobjs="$_ltdl_libobjs $lt_libobj_prefix$i.$ac_objext"
8403     _ltdl_ltlibobjs="$_ltdl_ltlibobjs $lt_libobj_prefix$i.lo"
8404     done
8405     fi
8406     AC_SUBST([ltdl_LIBOBJS], [$_ltdl_libobjs])
8407     AC_SUBST([ltdl_LTLIBOBJS], [$_ltdl_ltlibobjs])
8408     ])
8409    
8410     # Only expand once:
8411     m4_define([LTDL_INIT])
8412     ])# LTDL_INIT
8413    
8414     # Old names:
8415     AU_DEFUN([AC_LIB_LTDL], [LTDL_INIT($@)])
8416     AU_DEFUN([AC_WITH_LTDL], [LTDL_INIT($@)])
8417     AU_DEFUN([LT_WITH_LTDL], [LTDL_INIT($@)])
8418     dnl aclocal-1.4 backwards compatibility:
8419     dnl AC_DEFUN([AC_LIB_LTDL], [])
8420     dnl AC_DEFUN([AC_WITH_LTDL], [])
8421     dnl AC_DEFUN([LT_WITH_LTDL], [])
8422    
8423    
8424     # _LTDL_SETUP
8425     # -----------
8426     # Perform all the checks necessary for compilation of the ltdl objects
8427     # -- including compiler checks and header checks. This is a public
8428     # interface mainly for the benefit of libltdl's own configure.ac, most
8429     # other users should call LTDL_INIT instead.
8430     AC_DEFUN([_LTDL_SETUP],
8431     [AC_REQUIRE([AC_PROG_CC])dnl
8432     AC_REQUIRE([LT_SYS_MODULE_EXT])dnl
8433     AC_REQUIRE([LT_SYS_MODULE_PATH])dnl
8434     AC_REQUIRE([LT_SYS_DLSEARCH_PATH])dnl
8435     AC_REQUIRE([LT_LIB_DLLOAD])dnl
8436     AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl
8437     AC_REQUIRE([LT_FUNC_DLSYM_USCORE])dnl
8438     AC_REQUIRE([LT_SYS_DLOPEN_DEPLIBS])dnl
8439     AC_REQUIRE([gl_FUNC_ARGZ])dnl
8440    
8441     m4_require([_LT_CHECK_OBJDIR])dnl
8442     m4_require([_LT_HEADER_DLFCN])dnl
8443     m4_require([_LT_CHECK_DLPREOPEN])dnl
8444     m4_require([_LT_DECL_SED])dnl
8445    
8446     dnl Don't require this, or it will be expanded earlier than the code
8447     dnl that sets the variables it relies on:
8448     _LT_ENABLE_INSTALL
8449    
8450     dnl _LTDL_MODE specific code must be called at least once:
8451     _LTDL_MODE_DISPATCH
8452    
8453     # In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS
8454     # the user used. This is so that ltdl.h can pick up the parent projects
8455     # config.h file, The first file in AC_CONFIG_HEADERS must contain the
8456     # definitions required by ltdl.c.
8457     # FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility).
8458     AC_CONFIG_COMMANDS_PRE([dnl
8459     m4_pattern_allow([^LT_CONFIG_H$])dnl
8460     m4_ifset([AH_HEADER],
8461     [LT_CONFIG_H=AH_HEADER],
8462     [m4_ifset([AC_LIST_HEADERS],
8463     [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's,^[[ ]]*,,;s,[[ :]].*$,,'`],
8464     [])])])
8465     AC_SUBST([LT_CONFIG_H])
8466    
8467     AC_CHECK_HEADERS([unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h dirent.h],
8468     [], [], [AC_INCLUDES_DEFAULT])
8469    
8470     AC_CHECK_FUNCS([closedir opendir readdir], [], [AC_LIBOBJ([lt__dirent])])
8471     AC_CHECK_FUNCS([strlcat strlcpy], [], [AC_LIBOBJ([lt__strl])])
8472    
8473 michael 1094 m4_pattern_allow([LT_LIBEXT])dnl
8474 michael 945 AC_DEFINE_UNQUOTED([LT_LIBEXT],["$libext"],[The archive extension])
8475    
8476 michael 1106 name=
8477     eval "lt_libprefix=\"$libname_spec\""
8478     m4_pattern_allow([LT_LIBPREFIX])dnl
8479     AC_DEFINE_UNQUOTED([LT_LIBPREFIX],["$lt_libprefix"],[The archive prefix])
8480    
8481 michael 945 name=ltdl
8482 michael 1106 eval "LTDLOPEN=\"$libname_spec\""
8483 michael 945 AC_SUBST([LTDLOPEN])
8484     ])# _LTDL_SETUP
8485    
8486    
8487     # _LT_ENABLE_INSTALL
8488     # ------------------
8489     m4_define([_LT_ENABLE_INSTALL],
8490     [AC_ARG_ENABLE([ltdl-install],
8491     [AS_HELP_STRING([--enable-ltdl-install], [install libltdl])])
8492    
8493     case ,${enable_ltdl_install},${enable_ltdl_convenience} in
8494     *yes*) ;;
8495     *) enable_ltdl_convenience=yes ;;
8496     esac
8497    
8498     m4_ifdef([AM_CONDITIONAL],
8499     [AM_CONDITIONAL(INSTALL_LTDL, test x"${enable_ltdl_install-no}" != xno)
8500     AM_CONDITIONAL(CONVENIENCE_LTDL, test x"${enable_ltdl_convenience-no}" != xno)])
8501     ])# _LT_ENABLE_INSTALL
8502    
8503    
8504     # LT_SYS_DLOPEN_DEPLIBS
8505     # ---------------------
8506     AC_DEFUN([LT_SYS_DLOPEN_DEPLIBS],
8507     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8508     AC_CACHE_CHECK([whether deplibs are loaded by dlopen],
8509     [lt_cv_sys_dlopen_deplibs],
8510     [# PORTME does your system automatically load deplibs for dlopen?
8511     # or its logical equivalent (e.g. shl_load for HP-UX < 11)
8512     # For now, we just catch OSes we know something about -- in the
8513     # future, we'll try test this programmatically.
8514     lt_cv_sys_dlopen_deplibs=unknown
8515     case $host_os in
8516     aix3*|aix4.1.*|aix4.2.*)
8517     # Unknown whether this is true for these versions of AIX, but
8518     # we want this `case' here to explicitly catch those versions.
8519     lt_cv_sys_dlopen_deplibs=unknown
8520     ;;
8521     aix[[4-9]]*)
8522     lt_cv_sys_dlopen_deplibs=yes
8523     ;;
8524     amigaos*)
8525     case $host_cpu in
8526     powerpc)
8527     lt_cv_sys_dlopen_deplibs=no
8528     ;;
8529     esac
8530     ;;
8531     darwin*)
8532     # Assuming the user has installed a libdl from somewhere, this is true
8533     # If you are looking for one http://www.opendarwin.org/projects/dlcompat
8534     lt_cv_sys_dlopen_deplibs=yes
8535     ;;
8536     freebsd* | dragonfly*)
8537     lt_cv_sys_dlopen_deplibs=yes
8538     ;;
8539 michael 1094 gnu* | linux* | k*bsd*-gnu | kopensolaris*-gnu)
8540 michael 945 # GNU and its variants, using gnu ld.so (Glibc)
8541     lt_cv_sys_dlopen_deplibs=yes
8542     ;;
8543     hpux10*|hpux11*)
8544     lt_cv_sys_dlopen_deplibs=yes
8545     ;;
8546     interix*)
8547     lt_cv_sys_dlopen_deplibs=yes
8548     ;;
8549     irix[[12345]]*|irix6.[[01]]*)
8550     # Catch all versions of IRIX before 6.2, and indicate that we don't
8551     # know how it worked for any of those versions.
8552     lt_cv_sys_dlopen_deplibs=unknown
8553     ;;
8554     irix*)
8555     # The case above catches anything before 6.2, and it's known that
8556     # at 6.2 and later dlopen does load deplibs.
8557     lt_cv_sys_dlopen_deplibs=yes
8558     ;;
8559     netbsd*)
8560     lt_cv_sys_dlopen_deplibs=yes
8561     ;;
8562     openbsd*)
8563     lt_cv_sys_dlopen_deplibs=yes
8564     ;;
8565     osf[[1234]]*)
8566     # dlopen did load deplibs (at least at 4.x), but until the 5.x series,
8567     # it did *not* use an RPATH in a shared library to find objects the
8568     # library depends on, so we explicitly say `no'.
8569     lt_cv_sys_dlopen_deplibs=no
8570     ;;
8571     osf5.0|osf5.0a|osf5.1)
8572     # dlopen *does* load deplibs and with the right loader patch applied
8573     # it even uses RPATH in a shared library to search for shared objects
8574     # that the library depends on, but there's no easy way to know if that
8575     # patch is installed. Since this is the case, all we can really
8576     # say is unknown -- it depends on the patch being installed. If
8577     # it is, this changes to `yes'. Without it, it would be `no'.
8578     lt_cv_sys_dlopen_deplibs=unknown
8579     ;;
8580     osf*)
8581     # the two cases above should catch all versions of osf <= 5.1. Read
8582     # the comments above for what we know about them.
8583     # At > 5.1, deplibs are loaded *and* any RPATH in a shared library
8584     # is used to find them so we can finally say `yes'.
8585     lt_cv_sys_dlopen_deplibs=yes
8586     ;;
8587     qnx*)
8588     lt_cv_sys_dlopen_deplibs=yes
8589     ;;
8590     solaris*)
8591     lt_cv_sys_dlopen_deplibs=yes
8592     ;;
8593     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8594     libltdl_cv_sys_dlopen_deplibs=yes
8595     ;;
8596     esac
8597     ])
8598     if test "$lt_cv_sys_dlopen_deplibs" != yes; then
8599     AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1],
8600     [Define if the OS needs help to load dependent libraries for dlopen().])
8601     fi
8602     ])# LT_SYS_DLOPEN_DEPLIBS
8603    
8604     # Old name:
8605     AU_ALIAS([AC_LTDL_SYS_DLOPEN_DEPLIBS], [LT_SYS_DLOPEN_DEPLIBS])
8606     dnl aclocal-1.4 backwards compatibility:
8607     dnl AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS], [])
8608    
8609    
8610     # LT_SYS_MODULE_EXT
8611     # -----------------
8612     AC_DEFUN([LT_SYS_MODULE_EXT],
8613     [m4_require([_LT_SYS_DYNAMIC_LINKER])dnl
8614     AC_CACHE_CHECK([which extension is used for runtime loadable modules],
8615     [libltdl_cv_shlibext],
8616     [
8617     module=yes
8618     eval libltdl_cv_shlibext=$shrext_cmds
8619 michael 1257 module=no
8620     eval libltdl_cv_shrext=$shrext_cmds
8621 michael 945 ])
8622     if test -n "$libltdl_cv_shlibext"; then
8623     m4_pattern_allow([LT_MODULE_EXT])dnl
8624     AC_DEFINE_UNQUOTED([LT_MODULE_EXT], ["$libltdl_cv_shlibext"],
8625     [Define to the extension used for runtime loadable modules, say, ".so".])
8626     fi
8627 michael 1257 if test "$libltdl_cv_shrext" != "$libltdl_cv_shlibext"; then
8628     m4_pattern_allow([LT_SHARED_EXT])dnl
8629     AC_DEFINE_UNQUOTED([LT_SHARED_EXT], ["$libltdl_cv_shrext"],
8630     [Define to the shared library suffix, say, ".dylib".])
8631     fi
8632 michael 945 ])# LT_SYS_MODULE_EXT
8633    
8634     # Old name:
8635     AU_ALIAS([AC_LTDL_SHLIBEXT], [LT_SYS_MODULE_EXT])
8636     dnl aclocal-1.4 backwards compatibility:
8637     dnl AC_DEFUN([AC_LTDL_SHLIBEXT], [])
8638    
8639    
8640     # LT_SYS_MODULE_PATH
8641     # ------------------
8642     AC_DEFUN([LT_SYS_MODULE_PATH],
8643     [m4_require([_LT_SYS_DYNAMIC_LINKER])dnl
8644     AC_CACHE_CHECK([which variable specifies run-time module search path],
8645     [lt_cv_module_path_var], [lt_cv_module_path_var="$shlibpath_var"])
8646     if test -n "$lt_cv_module_path_var"; then
8647     m4_pattern_allow([LT_MODULE_PATH_VAR])dnl
8648     AC_DEFINE_UNQUOTED([LT_MODULE_PATH_VAR], ["$lt_cv_module_path_var"],
8649     [Define to the name of the environment variable that determines the run-time module search path.])
8650     fi
8651     ])# LT_SYS_MODULE_PATH
8652    
8653     # Old name:
8654     AU_ALIAS([AC_LTDL_SHLIBPATH], [LT_SYS_MODULE_PATH])
8655     dnl aclocal-1.4 backwards compatibility:
8656     dnl AC_DEFUN([AC_LTDL_SHLIBPATH], [])
8657    
8658    
8659     # LT_SYS_DLSEARCH_PATH
8660     # --------------------
8661     AC_DEFUN([LT_SYS_DLSEARCH_PATH],
8662     [m4_require([_LT_SYS_DYNAMIC_LINKER])dnl
8663     AC_CACHE_CHECK([for the default library search path],
8664     [lt_cv_sys_dlsearch_path],
8665     [lt_cv_sys_dlsearch_path="$sys_lib_dlsearch_path_spec"])
8666     if test -n "$lt_cv_sys_dlsearch_path"; then
8667     sys_dlsearch_path=
8668     for dir in $lt_cv_sys_dlsearch_path; do
8669     if test -z "$sys_dlsearch_path"; then
8670     sys_dlsearch_path="$dir"
8671     else
8672     sys_dlsearch_path="$sys_dlsearch_path$PATH_SEPARATOR$dir"
8673     fi
8674     done
8675     m4_pattern_allow([LT_DLSEARCH_PATH])dnl
8676     AC_DEFINE_UNQUOTED([LT_DLSEARCH_PATH], ["$sys_dlsearch_path"],
8677     [Define to the system default library search path.])
8678     fi
8679     ])# LT_SYS_DLSEARCH_PATH
8680    
8681     # Old name:
8682     AU_ALIAS([AC_LTDL_SYSSEARCHPATH], [LT_SYS_DLSEARCH_PATH])
8683     dnl aclocal-1.4 backwards compatibility:
8684     dnl AC_DEFUN([AC_LTDL_SYSSEARCHPATH], [])
8685    
8686    
8687     # _LT_CHECK_DLPREOPEN
8688     # -------------------
8689     m4_defun([_LT_CHECK_DLPREOPEN],
8690     [m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
8691     AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen],
8692     [libltdl_cv_preloaded_symbols],
8693     [if test -n "$lt_cv_sys_global_symbol_pipe"; then
8694     libltdl_cv_preloaded_symbols=yes
8695     else
8696     libltdl_cv_preloaded_symbols=no
8697     fi
8698     ])
8699     if test x"$libltdl_cv_preloaded_symbols" = xyes; then
8700     AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1],
8701     [Define if libtool can extract symbol lists from object files.])
8702     fi
8703     ])# _LT_CHECK_DLPREOPEN
8704    
8705    
8706     # LT_LIB_DLLOAD
8707     # -------------
8708     AC_DEFUN([LT_LIB_DLLOAD],
8709     [m4_pattern_allow([^LT_DLLOADERS$])
8710     LT_DLLOADERS=
8711     AC_SUBST([LT_DLLOADERS])
8712    
8713     AC_LANG_PUSH([C])
8714    
8715     LIBADD_DLOPEN=
8716     AC_SEARCH_LIBS([dlopen], [dl],
8717     [AC_DEFINE([HAVE_LIBDL], [1],
8718     [Define if you have the libdl library or equivalent.])
8719     if test "$ac_cv_search_dlopen" != "none required" ; then
8720     LIBADD_DLOPEN="-ldl"
8721     fi
8722     libltdl_cv_lib_dl_dlopen="yes"
8723     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"],
8724     [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#if HAVE_DLFCN_H
8725     # include <dlfcn.h>
8726     #endif
8727     ]], [[dlopen(0, 0);]])],
8728     [AC_DEFINE([HAVE_LIBDL], [1],
8729     [Define if you have the libdl library or equivalent.])
8730     libltdl_cv_func_dlopen="yes"
8731     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"],
8732     [AC_CHECK_LIB([svld], [dlopen],
8733     [AC_DEFINE([HAVE_LIBDL], [1],
8734     [Define if you have the libdl library or equivalent.])
8735     LIBADD_DLOPEN="-lsvld" libltdl_cv_func_dlopen="yes"
8736     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"])])])
8737     if test x"$libltdl_cv_func_dlopen" = xyes || test x"$libltdl_cv_lib_dl_dlopen" = xyes
8738     then
8739     lt_save_LIBS="$LIBS"
8740     LIBS="$LIBS $LIBADD_DLOPEN"
8741     AC_CHECK_FUNCS([dlerror])
8742     LIBS="$lt_save_LIBS"
8743     fi
8744     AC_SUBST([LIBADD_DLOPEN])
8745    
8746     LIBADD_SHL_LOAD=
8747     AC_CHECK_FUNC([shl_load],
8748     [AC_DEFINE([HAVE_SHL_LOAD], [1],
8749     [Define if you have the shl_load function.])
8750     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"],
8751     [AC_CHECK_LIB([dld], [shl_load],
8752     [AC_DEFINE([HAVE_SHL_LOAD], [1],
8753     [Define if you have the shl_load function.])
8754     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"
8755     LIBADD_SHL_LOAD="-ldld"])])
8756     AC_SUBST([LIBADD_SHL_LOAD])
8757    
8758     case $host_os in
8759     darwin[[1567]].*)
8760     # We only want this for pre-Mac OS X 10.4.
8761     AC_CHECK_FUNC([_dyld_func_lookup],
8762     [AC_DEFINE([HAVE_DYLD], [1],
8763     [Define if you have the _dyld_func_lookup function.])
8764     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dyld.la"])
8765     ;;
8766     beos*)
8767     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}load_add_on.la"
8768     ;;
8769     cygwin* | mingw* | os2* | pw32*)
8770     AC_CHECK_DECLS([cygwin_conv_path], [], [], [[#include <sys/cygwin.h>]])
8771     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}loadlibrary.la"
8772     ;;
8773     esac
8774    
8775     AC_CHECK_LIB([dld], [dld_link],
8776     [AC_DEFINE([HAVE_DLD], [1],
8777     [Define if you have the GNU dld library.])
8778     LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dld_link.la"])
8779     AC_SUBST([LIBADD_DLD_LINK])
8780    
8781     m4_pattern_allow([^LT_DLPREOPEN$])
8782     LT_DLPREOPEN=
8783     if test -n "$LT_DLLOADERS"
8784     then
8785     for lt_loader in $LT_DLLOADERS; do
8786     LT_DLPREOPEN="$LT_DLPREOPEN-dlpreopen $lt_loader "
8787     done
8788     AC_DEFINE([HAVE_LIBDLLOADER], [1],
8789     [Define if libdlloader will be built on this platform])
8790     fi
8791     AC_SUBST([LT_DLPREOPEN])
8792    
8793     dnl This isn't used anymore, but set it for backwards compatibility
8794     LIBADD_DL="$LIBADD_DLOPEN $LIBADD_SHL_LOAD"
8795     AC_SUBST([LIBADD_DL])
8796    
8797     AC_LANG_POP
8798     ])# LT_LIB_DLLOAD
8799    
8800     # Old name:
8801     AU_ALIAS([AC_LTDL_DLLIB], [LT_LIB_DLLOAD])
8802     dnl aclocal-1.4 backwards compatibility:
8803     dnl AC_DEFUN([AC_LTDL_DLLIB], [])
8804    
8805    
8806     # LT_SYS_SYMBOL_USCORE
8807     # --------------------
8808     # does the compiler prefix global symbols with an underscore?
8809     AC_DEFUN([LT_SYS_SYMBOL_USCORE],
8810     [m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
8811     AC_CACHE_CHECK([for _ prefix in compiled symbols],
8812     [lt_cv_sys_symbol_underscore],
8813     [lt_cv_sys_symbol_underscore=no
8814     cat > conftest.$ac_ext <<_LT_EOF
8815     void nm_test_func(){}
8816     int main(){nm_test_func;return 0;}
8817     _LT_EOF
8818     if AC_TRY_EVAL(ac_compile); then
8819     # Now try to grab the symbols.
8820     ac_nlist=conftest.nm
8821     if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then
8822     # See whether the symbols have a leading underscore.
8823     if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then
8824     lt_cv_sys_symbol_underscore=yes
8825     else
8826     if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then
8827     :
8828     else
8829     echo "configure: cannot find nm_test_func in $ac_nlist" >&AS_MESSAGE_LOG_FD
8830     fi
8831     fi
8832     else
8833     echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
8834     fi
8835     else
8836     echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD
8837     cat conftest.c >&AS_MESSAGE_LOG_FD
8838     fi
8839     rm -rf conftest*
8840     ])
8841     sys_symbol_underscore=$lt_cv_sys_symbol_underscore
8842     AC_SUBST([sys_symbol_underscore])
8843     ])# LT_SYS_SYMBOL_USCORE
8844    
8845     # Old name:
8846     AU_ALIAS([AC_LTDL_SYMBOL_USCORE], [LT_SYS_SYMBOL_USCORE])
8847     dnl aclocal-1.4 backwards compatibility:
8848     dnl AC_DEFUN([AC_LTDL_SYMBOL_USCORE], [])
8849    
8850    
8851     # LT_FUNC_DLSYM_USCORE
8852     # --------------------
8853     AC_DEFUN([LT_FUNC_DLSYM_USCORE],
8854     [AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl
8855     if test x"$lt_cv_sys_symbol_underscore" = xyes; then
8856     if test x"$libltdl_cv_func_dlopen" = xyes ||
8857     test x"$libltdl_cv_lib_dl_dlopen" = xyes ; then
8858     AC_CACHE_CHECK([whether we have to add an underscore for dlsym],
8859     [libltdl_cv_need_uscore],
8860     [libltdl_cv_need_uscore=unknown
8861     save_LIBS="$LIBS"
8862     LIBS="$LIBS $LIBADD_DLOPEN"
8863     _LT_TRY_DLOPEN_SELF(
8864     [libltdl_cv_need_uscore=no], [libltdl_cv_need_uscore=yes],
8865     [], [libltdl_cv_need_uscore=cross])
8866     LIBS="$save_LIBS"
8867     ])
8868     fi
8869     fi
8870    
8871     if test x"$libltdl_cv_need_uscore" = xyes; then
8872     AC_DEFINE([NEED_USCORE], [1],
8873     [Define if dlsym() requires a leading underscore in symbol names.])
8874     fi
8875     ])# LT_FUNC_DLSYM_USCORE
8876    
8877     # Old name:
8878     AU_ALIAS([AC_LTDL_DLSYM_USCORE], [LT_FUNC_DLSYM_USCORE])
8879     dnl aclocal-1.4 backwards compatibility:
8880     dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], [])
8881    
8882     # Helper functions for option handling. -*- Autoconf -*-
8883     #
8884 michael 1094 # Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
8885     # Inc.
8886 michael 945 # Written by Gary V. Vaughan, 2004
8887     #
8888     # This file is free software; the Free Software Foundation gives
8889     # unlimited permission to copy and/or distribute it, with or without
8890     # modifications, as long as this notice is preserved.
8891    
8892 michael 1094 # serial 7 ltoptions.m4
8893 michael 945
8894     # This is to help aclocal find these macros, as it can't see m4_define.
8895     AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
8896    
8897    
8898     # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
8899     # ------------------------------------------
8900     m4_define([_LT_MANGLE_OPTION],
8901     [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
8902    
8903    
8904     # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
8905     # ---------------------------------------
8906     # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
8907     # matching handler defined, dispatch to it. Other OPTION-NAMEs are
8908     # saved as a flag.
8909     m4_define([_LT_SET_OPTION],
8910     [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
8911     m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
8912     _LT_MANGLE_DEFUN([$1], [$2]),
8913     [m4_warning([Unknown $1 option `$2'])])[]dnl
8914     ])
8915    
8916    
8917     # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
8918     # ------------------------------------------------------------
8919     # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
8920     m4_define([_LT_IF_OPTION],
8921     [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
8922    
8923    
8924     # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
8925     # -------------------------------------------------------
8926     # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
8927     # are set.
8928     m4_define([_LT_UNLESS_OPTIONS],
8929     [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8930     [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
8931     [m4_define([$0_found])])])[]dnl
8932     m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
8933     ])[]dnl
8934     ])
8935    
8936    
8937     # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
8938     # ----------------------------------------
8939     # OPTION-LIST is a space-separated list of Libtool options associated
8940     # with MACRO-NAME. If any OPTION has a matching handler declared with
8941     # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
8942     # the unknown option and exit.
8943     m4_defun([_LT_SET_OPTIONS],
8944     [# Set options
8945     m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8946     [_LT_SET_OPTION([$1], _LT_Option)])
8947    
8948     m4_if([$1],[LT_INIT],[
8949     dnl
8950     dnl Simply set some default values (i.e off) if boolean options were not
8951     dnl specified:
8952     _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
8953     ])
8954     _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
8955     ])
8956     dnl
8957     dnl If no reference was made to various pairs of opposing options, then
8958     dnl we run the default mode handler for the pair. For example, if neither
8959     dnl `shared' nor `disable-shared' was passed, we enable building of shared
8960     dnl archives by default:
8961     _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
8962     _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
8963     _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
8964     _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
8965     [_LT_ENABLE_FAST_INSTALL])
8966     ])
8967     ])# _LT_SET_OPTIONS
8968    
8969    
8970    
8971     # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
8972     # -----------------------------------------
8973     m4_define([_LT_MANGLE_DEFUN],
8974     [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
8975    
8976    
8977     # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
8978     # -----------------------------------------------
8979     m4_define([LT_OPTION_DEFINE],
8980     [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
8981     ])# LT_OPTION_DEFINE
8982    
8983    
8984     # dlopen
8985     # ------
8986     LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
8987     ])
8988    
8989     AU_DEFUN([AC_LIBTOOL_DLOPEN],
8990     [_LT_SET_OPTION([LT_INIT], [dlopen])
8991     AC_DIAGNOSE([obsolete],
8992     [$0: Remove this warning and the call to _LT_SET_OPTION when you
8993     put the `dlopen' option into LT_INIT's first parameter.])
8994     ])
8995    
8996     dnl aclocal-1.4 backwards compatibility:
8997     dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
8998    
8999    
9000     # win32-dll
9001     # ---------
9002     # Declare package support for building win32 dll's.
9003     LT_OPTION_DEFINE([LT_INIT], [win32-dll],
9004     [enable_win32_dll=yes
9005    
9006     case $host in
9007 michael 1094 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
9008 michael 945 AC_CHECK_TOOL(AS, as, false)
9009     AC_CHECK_TOOL(DLLTOOL, dlltool, false)
9010     AC_CHECK_TOOL(OBJDUMP, objdump, false)
9011     ;;
9012     esac
9013    
9014     test -z "$AS" && AS=as
9015 michael 1094 _LT_DECL([], [AS], [1], [Assembler program])dnl
9016 michael 945
9017     test -z "$DLLTOOL" && DLLTOOL=dlltool
9018 michael 1094 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
9019 michael 945
9020     test -z "$OBJDUMP" && OBJDUMP=objdump
9021 michael 1094 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
9022 michael 945 ])# win32-dll
9023    
9024     AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
9025     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
9026     _LT_SET_OPTION([LT_INIT], [win32-dll])
9027     AC_DIAGNOSE([obsolete],
9028     [$0: Remove this warning and the call to _LT_SET_OPTION when you
9029     put the `win32-dll' option into LT_INIT's first parameter.])
9030     ])
9031    
9032     dnl aclocal-1.4 backwards compatibility:
9033     dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
9034    
9035    
9036     # _LT_ENABLE_SHARED([DEFAULT])
9037     # ----------------------------
9038     # implement the --enable-shared flag, and supports the `shared' and
9039     # `disable-shared' LT_INIT options.
9040     # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9041     m4_define([_LT_ENABLE_SHARED],
9042     [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
9043     AC_ARG_ENABLE([shared],
9044     [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
9045     [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
9046     [p=${PACKAGE-default}
9047     case $enableval in
9048     yes) enable_shared=yes ;;
9049     no) enable_shared=no ;;
9050     *)
9051     enable_shared=no
9052     # Look at the argument we got. We use all the common list separators.
9053     lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9054     for pkg in $enableval; do
9055     IFS="$lt_save_ifs"
9056     if test "X$pkg" = "X$p"; then
9057     enable_shared=yes
9058     fi
9059     done
9060     IFS="$lt_save_ifs"
9061     ;;
9062     esac],
9063     [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
9064    
9065     _LT_DECL([build_libtool_libs], [enable_shared], [0],
9066     [Whether or not to build shared libraries])
9067     ])# _LT_ENABLE_SHARED
9068    
9069     LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
9070     LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
9071    
9072     # Old names:
9073     AC_DEFUN([AC_ENABLE_SHARED],
9074     [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
9075     ])
9076    
9077     AC_DEFUN([AC_DISABLE_SHARED],
9078     [_LT_SET_OPTION([LT_INIT], [disable-shared])
9079     ])
9080    
9081     AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
9082     AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
9083    
9084     dnl aclocal-1.4 backwards compatibility:
9085     dnl AC_DEFUN([AM_ENABLE_SHARED], [])
9086     dnl AC_DEFUN([AM_DISABLE_SHARED], [])
9087    
9088    
9089    
9090     # _LT_ENABLE_STATIC([DEFAULT])
9091     # ----------------------------
9092     # implement the --enable-static flag, and support the `static' and
9093     # `disable-static' LT_INIT options.
9094     # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9095     m4_define([_LT_ENABLE_STATIC],
9096     [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
9097     AC_ARG_ENABLE([static],
9098     [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
9099     [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
9100     [p=${PACKAGE-default}
9101     case $enableval in
9102     yes) enable_static=yes ;;
9103     no) enable_static=no ;;
9104     *)
9105     enable_static=no
9106     # Look at the argument we got. We use all the common list separators.
9107     lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9108     for pkg in $enableval; do
9109     IFS="$lt_save_ifs"
9110     if test "X$pkg" = "X$p"; then
9111     enable_static=yes
9112     fi
9113     done
9114     IFS="$lt_save_ifs"
9115     ;;
9116     esac],
9117     [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
9118    
9119     _LT_DECL([build_old_libs], [enable_static], [0],
9120     [Whether or not to build static libraries])
9121     ])# _LT_ENABLE_STATIC
9122    
9123     LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
9124     LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
9125    
9126     # Old names:
9127     AC_DEFUN([AC_ENABLE_STATIC],
9128     [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
9129     ])
9130    
9131     AC_DEFUN([AC_DISABLE_STATIC],
9132     [_LT_SET_OPTION([LT_INIT], [disable-static])
9133     ])
9134    
9135     AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
9136     AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
9137    
9138     dnl aclocal-1.4 backwards compatibility:
9139     dnl AC_DEFUN([AM_ENABLE_STATIC], [])
9140     dnl AC_DEFUN([AM_DISABLE_STATIC], [])
9141    
9142    
9143    
9144     # _LT_ENABLE_FAST_INSTALL([DEFAULT])
9145     # ----------------------------------
9146     # implement the --enable-fast-install flag, and support the `fast-install'
9147     # and `disable-fast-install' LT_INIT options.
9148     # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
9149     m4_define([_LT_ENABLE_FAST_INSTALL],
9150     [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
9151     AC_ARG_ENABLE([fast-install],
9152     [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
9153     [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
9154     [p=${PACKAGE-default}
9155     case $enableval in
9156     yes) enable_fast_install=yes ;;
9157     no) enable_fast_install=no ;;
9158     *)
9159     enable_fast_install=no
9160     # Look at the argument we got. We use all the common list separators.
9161     lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9162     for pkg in $enableval; do
9163     IFS="$lt_save_ifs"
9164     if test "X$pkg" = "X$p"; then
9165     enable_fast_install=yes
9166     fi
9167     done
9168     IFS="$lt_save_ifs"
9169     ;;
9170     esac],
9171     [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
9172    
9173     _LT_DECL([fast_install], [enable_fast_install], [0],
9174     [Whether or not to optimize for fast installation])dnl
9175     ])# _LT_ENABLE_FAST_INSTALL
9176    
9177     LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
9178     LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
9179    
9180     # Old names:
9181     AU_DEFUN([AC_ENABLE_FAST_INSTALL],
9182     [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
9183     AC_DIAGNOSE([obsolete],
9184     [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9185     the `fast-install' option into LT_INIT's first parameter.])
9186     ])
9187    
9188     AU_DEFUN([AC_DISABLE_FAST_INSTALL],
9189     [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
9190     AC_DIAGNOSE([obsolete],
9191     [$0: Remove this warning and the call to _LT_SET_OPTION when you put
9192     the `disable-fast-install' option into LT_INIT's first parameter.])
9193     ])
9194    
9195     dnl aclocal-1.4 backwards compatibility:
9196     dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
9197     dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
9198    
9199    
9200     # _LT_WITH_PIC([MODE])
9201     # --------------------
9202     # implement the --with-pic flag, and support the `pic-only' and `no-pic'
9203     # LT_INIT options.
9204     # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
9205     m4_define([_LT_WITH_PIC],
9206     [AC_ARG_WITH([pic],
9207 michael 1257 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
9208 michael 945 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
9209 michael 1257 [lt_p=${PACKAGE-default}
9210     case $withval in
9211     yes|no) pic_mode=$withval ;;
9212     *)
9213     pic_mode=default
9214     # Look at the argument we got. We use all the common list separators.
9215     lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
9216     for lt_pkg in $withval; do
9217     IFS="$lt_save_ifs"
9218     if test "X$lt_pkg" = "X$lt_p"; then
9219     pic_mode=yes
9220     fi
9221     done
9222     IFS="$lt_save_ifs"
9223     ;;
9224     esac],
9225 michael 945 [pic_mode=default])
9226    
9227     test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
9228    
9229     _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
9230     ])# _LT_WITH_PIC
9231    
9232     LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
9233     LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
9234    
9235     # Old name:
9236     AU_DEFUN([AC_LIBTOOL_PICMODE],
9237     [_LT_SET_OPTION([LT_INIT], [pic-only])
9238     AC_DIAGNOSE([obsolete],
9239     [$0: Remove this warning and the call to _LT_SET_OPTION when you
9240     put the `pic-only' option into LT_INIT's first parameter.])
9241     ])
9242    
9243     dnl aclocal-1.4 backwards compatibility:
9244     dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
9245    
9246    
9247     m4_define([_LTDL_MODE], [])
9248     LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
9249     [m4_define([_LTDL_MODE], [nonrecursive])])
9250     LT_OPTION_DEFINE([LTDL_INIT], [recursive],
9251     [m4_define([_LTDL_MODE], [recursive])])
9252     LT_OPTION_DEFINE([LTDL_INIT], [subproject],
9253     [m4_define([_LTDL_MODE], [subproject])])
9254    
9255     m4_define([_LTDL_TYPE], [])
9256     LT_OPTION_DEFINE([LTDL_INIT], [installable],
9257     [m4_define([_LTDL_TYPE], [installable])])
9258     LT_OPTION_DEFINE([LTDL_INIT], [convenience],
9259     [m4_define([_LTDL_TYPE], [convenience])])
9260    
9261     # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
9262     #
9263     # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
9264     # Written by Gary V. Vaughan, 2004
9265     #
9266     # This file is free software; the Free Software Foundation gives
9267     # unlimited permission to copy and/or distribute it, with or without
9268     # modifications, as long as this notice is preserved.
9269    
9270     # serial 6 ltsugar.m4
9271    
9272     # This is to help aclocal find these macros, as it can't see m4_define.
9273     AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
9274    
9275    
9276     # lt_join(SEP, ARG1, [ARG2...])
9277     # -----------------------------
9278     # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
9279     # associated separator.
9280     # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
9281     # versions in m4sugar had bugs.
9282     m4_define([lt_join],
9283     [m4_if([$#], [1], [],
9284     [$#], [2], [[$2]],
9285     [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
9286     m4_define([_lt_join],
9287     [m4_if([$#$2], [2], [],
9288     [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
9289    
9290    
9291     # lt_car(LIST)
9292     # lt_cdr(LIST)
9293     # ------------
9294     # Manipulate m4 lists.
9295     # These macros are necessary as long as will still need to support
9296     # Autoconf-2.59 which quotes differently.
9297     m4_define([lt_car], [[$1]])
9298     m4_define([lt_cdr],
9299     [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
9300     [$#], 1, [],
9301     [m4_dquote(m4_shift($@))])])
9302     m4_define([lt_unquote], $1)
9303    
9304    
9305     # lt_append(MACRO-NAME, STRING, [SEPARATOR])
9306     # ------------------------------------------
9307     # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
9308     # Note that neither SEPARATOR nor STRING are expanded; they are appended
9309     # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
9310     # No SEPARATOR is output if MACRO-NAME was previously undefined (different
9311     # than defined and empty).
9312     #
9313     # This macro is needed until we can rely on Autoconf 2.62, since earlier
9314     # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
9315     m4_define([lt_append],
9316     [m4_define([$1],
9317     m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
9318    
9319    
9320    
9321     # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
9322     # ----------------------------------------------------------
9323     # Produce a SEP delimited list of all paired combinations of elements of
9324     # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
9325     # has the form PREFIXmINFIXSUFFIXn.
9326     # Needed until we can rely on m4_combine added in Autoconf 2.62.
9327     m4_define([lt_combine],
9328     [m4_if(m4_eval([$# > 3]), [1],
9329     [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
9330     [[m4_foreach([_Lt_prefix], [$2],
9331     [m4_foreach([_Lt_suffix],
9332     ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
9333     [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
9334    
9335    
9336     # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
9337     # -----------------------------------------------------------------------
9338     # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
9339     # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
9340     m4_define([lt_if_append_uniq],
9341     [m4_ifdef([$1],
9342     [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
9343     [lt_append([$1], [$2], [$3])$4],
9344     [$5])],
9345     [lt_append([$1], [$2], [$3])$4])])
9346    
9347    
9348     # lt_dict_add(DICT, KEY, VALUE)
9349     # -----------------------------
9350     m4_define([lt_dict_add],
9351     [m4_define([$1($2)], [$3])])
9352    
9353    
9354     # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
9355     # --------------------------------------------
9356     m4_define([lt_dict_add_subkey],
9357     [m4_define([$1($2:$3)], [$4])])
9358    
9359    
9360     # lt_dict_fetch(DICT, KEY, [SUBKEY])
9361     # ----------------------------------
9362     m4_define([lt_dict_fetch],
9363     [m4_ifval([$3],
9364     m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
9365     m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
9366    
9367    
9368     # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
9369     # -----------------------------------------------------------------
9370     m4_define([lt_if_dict_fetch],
9371     [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
9372     [$5],
9373     [$6])])
9374    
9375    
9376     # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
9377     # --------------------------------------------------------------
9378     m4_define([lt_dict_filter],
9379     [m4_if([$5], [], [],
9380     [lt_join(m4_quote(m4_default([$4], [[, ]])),
9381     lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
9382     [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
9383     ])
9384    
9385     # ltversion.m4 -- version numbers -*- Autoconf -*-
9386     #
9387     # Copyright (C) 2004 Free Software Foundation, Inc.
9388     # Written by Scott James Remnant, 2004
9389     #
9390     # This file is free software; the Free Software Foundation gives
9391     # unlimited permission to copy and/or distribute it, with or without
9392     # modifications, as long as this notice is preserved.
9393    
9394 michael 1106 # @configure_input@
9395 michael 945
9396 michael 1257 # serial 3337 ltversion.m4
9397 michael 945 # This file is part of GNU Libtool
9398    
9399 michael 1257 m4_define([LT_PACKAGE_VERSION], [2.4.2])
9400     m4_define([LT_PACKAGE_REVISION], [1.3337])
9401 michael 945
9402     AC_DEFUN([LTVERSION_VERSION],
9403 michael 1257 [macro_version='2.4.2'
9404     macro_revision='1.3337'
9405 michael 945 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
9406     _LT_DECL(, macro_revision, 0)
9407     ])
9408    
9409     # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
9410     #
9411 michael 1094 # Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
9412 michael 945 # Written by Scott James Remnant, 2004.
9413     #
9414     # This file is free software; the Free Software Foundation gives
9415     # unlimited permission to copy and/or distribute it, with or without
9416     # modifications, as long as this notice is preserved.
9417    
9418 michael 1094 # serial 5 lt~obsolete.m4
9419 michael 945
9420     # These exist entirely to fool aclocal when bootstrapping libtool.
9421     #
9422     # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
9423     # which have later been changed to m4_define as they aren't part of the
9424     # exported API, or moved to Autoconf or Automake where they belong.
9425     #
9426     # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
9427     # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
9428     # using a macro with the same name in our local m4/libtool.m4 it'll
9429     # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
9430     # and doesn't know about Autoconf macros at all.)
9431     #
9432     # So we provide this file, which has a silly filename so it's always
9433     # included after everything else. This provides aclocal with the
9434     # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
9435     # because those macros already exist, or will be overwritten later.
9436     # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
9437     #
9438     # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
9439     # Yes, that means every name once taken will need to remain here until
9440     # we give up compatibility with versions before 1.7, at which point
9441     # we need to keep only those names which we still refer to.
9442    
9443     # This is to help aclocal find these macros, as it can't see m4_define.
9444     AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
9445    
9446     m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
9447     m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
9448     m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
9449     m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
9450     m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
9451     m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
9452     m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
9453     m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
9454     m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
9455     m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
9456     m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
9457     m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
9458     m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
9459     m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
9460     m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
9461     m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
9462     m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
9463     m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
9464     m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
9465     m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
9466     m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
9467     m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
9468     m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
9469     m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
9470     m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
9471     m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
9472     m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
9473     m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
9474     m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
9475     m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
9476     m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
9477     m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
9478     m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
9479     m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
9480     m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
9481     m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
9482     m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
9483     m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
9484     m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
9485     m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
9486     m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
9487     m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
9488     m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
9489     m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
9490     m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
9491     m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
9492     m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
9493     m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
9494     m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
9495     m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
9496     m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
9497     m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
9498     m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
9499     m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
9500 michael 1094 m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
9501     m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
9502     m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
9503     m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
9504     m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
9505     m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
9506     m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
9507 michael 945
9508 michael 1730 # Copyright (C) 2002-2013 Free Software Foundation, Inc.
9509 michael 945 #
9510 michael 912 # This file is free software; the Free Software Foundation
9511     # gives unlimited permission to copy and/or distribute it,
9512     # with or without modifications, as long as this notice is preserved.
9513    
9514     # AM_AUTOMAKE_VERSION(VERSION)
9515     # ----------------------------
9516     # Automake X.Y traces this macro to ensure aclocal.m4 has been
9517     # generated from the m4 files accompanying Automake X.Y.
9518     # (This private macro should not be called outside this file.)
9519     AC_DEFUN([AM_AUTOMAKE_VERSION],
9520 michael 1720 [am__api_version='1.13'
9521 michael 912 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
9522     dnl require some minimum version. Point them to the right macro.
9523 michael 2063 m4_if([$1], [1.13.2], [],
9524 michael 912 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
9525     ])
9526    
9527     # _AM_AUTOCONF_VERSION(VERSION)
9528     # -----------------------------
9529     # aclocal traces this macro to find the Autoconf version.
9530     # This is a private macro too. Using m4_define simplifies
9531     # the logic in aclocal, which can simply ignore this definition.
9532     m4_define([_AM_AUTOCONF_VERSION], [])
9533    
9534     # AM_SET_CURRENT_AUTOMAKE_VERSION
9535     # -------------------------------
9536     # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
9537 michael 945 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
9538 michael 912 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
9539 michael 2063 [AM_AUTOMAKE_VERSION([1.13.2])dnl
9540 db 941 m4_ifndef([AC_AUTOCONF_VERSION],
9541     [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
9542 michael 945 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
9543 michael 912
9544     # AM_AUX_DIR_EXPAND -*- Autoconf -*-
9545    
9546 michael 1730 # Copyright (C) 2001-2013 Free Software Foundation, Inc.
9547 michael 912 #
9548     # This file is free software; the Free Software Foundation
9549     # gives unlimited permission to copy and/or distribute it,
9550     # with or without modifications, as long as this notice is preserved.
9551    
9552     # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
9553 michael 1373 # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
9554     # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
9555 michael 912 #
9556     # Of course, Automake must honor this variable whenever it calls a
9557     # tool from the auxiliary directory. The problem is that $srcdir (and
9558     # therefore $ac_aux_dir as well) can be either absolute or relative,
9559     # depending on how configure is run. This is pretty annoying, since
9560     # it makes $ac_aux_dir quite unusable in subdirectories: in the top
9561     # source directory, any form will work fine, but in subdirectories a
9562     # relative path needs to be adjusted first.
9563     #
9564     # $ac_aux_dir/missing
9565     # fails when called from a subdirectory if $ac_aux_dir is relative
9566     # $top_srcdir/$ac_aux_dir/missing
9567     # fails if $ac_aux_dir is absolute,
9568     # fails when called from a subdirectory in a VPATH build with
9569     # a relative $ac_aux_dir
9570     #
9571     # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
9572     # are both prefixed by $srcdir. In an in-source build this is usually
9573 michael 1373 # harmless because $srcdir is '.', but things will broke when you
9574 michael 912 # start a VPATH build or use an absolute $srcdir.
9575     #
9576     # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
9577     # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
9578     # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
9579     # and then we would define $MISSING as
9580     # MISSING="\${SHELL} $am_aux_dir/missing"
9581     # This will work as long as MISSING is not called from configure, because
9582     # unfortunately $(top_srcdir) has no meaning in configure.
9583     # However there are other variables, like CC, which are often used in
9584     # configure, and could therefore not use this "fixed" $ac_aux_dir.
9585     #
9586     # Another solution, used here, is to always expand $ac_aux_dir to an
9587     # absolute PATH. The drawback is that using absolute paths prevent a
9588     # configured tree to be moved without reconfiguration.
9589    
9590     AC_DEFUN([AM_AUX_DIR_EXPAND],
9591     [dnl Rely on autoconf to set up CDPATH properly.
9592     AC_PREREQ([2.50])dnl
9593     # expand $ac_aux_dir to an absolute path
9594     am_aux_dir=`cd $ac_aux_dir && pwd`
9595     ])
9596    
9597     # AM_CONDITIONAL -*- Autoconf -*-
9598    
9599 michael 1730 # Copyright (C) 1997-2013 Free Software Foundation, Inc.
9600 michael 912 #
9601     # This file is free software; the Free Software Foundation
9602     # gives unlimited permission to copy and/or distribute it,
9603     # with or without modifications, as long as this notice is preserved.
9604    
9605     # AM_CONDITIONAL(NAME, SHELL-CONDITION)
9606     # -------------------------------------
9607     # Define a conditional.
9608     AC_DEFUN([AM_CONDITIONAL],
9609 michael 1373 [AC_PREREQ([2.52])dnl
9610     m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
9611     [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
9612 michael 912 AC_SUBST([$1_TRUE])dnl
9613     AC_SUBST([$1_FALSE])dnl
9614     _AM_SUBST_NOTMAKE([$1_TRUE])dnl
9615     _AM_SUBST_NOTMAKE([$1_FALSE])dnl
9616 michael 945 m4_define([_AM_COND_VALUE_$1], [$2])dnl
9617 michael 912 if $2; then
9618     $1_TRUE=
9619     $1_FALSE='#'
9620     else
9621     $1_TRUE='#'
9622     $1_FALSE=
9623     fi
9624     AC_CONFIG_COMMANDS_PRE(
9625     [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
9626     AC_MSG_ERROR([[conditional "$1" was never defined.
9627     Usually this means the macro was only invoked conditionally.]])
9628     fi])])
9629    
9630 michael 1730 # Copyright (C) 1999-2013 Free Software Foundation, Inc.
9631 michael 912 #
9632     # This file is free software; the Free Software Foundation
9633     # gives unlimited permission to copy and/or distribute it,
9634     # with or without modifications, as long as this notice is preserved.
9635    
9636    
9637 michael 1373 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
9638 michael 912 # written in clear, in which case automake, when reading aclocal.m4,
9639     # will think it sees a *use*, and therefore will trigger all it's
9640     # C support machinery. Also note that it means that autoscan, seeing
9641     # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
9642    
9643    
9644     # _AM_DEPENDENCIES(NAME)
9645     # ----------------------
9646     # See how the compiler implements dependency checking.
9647 michael 1425 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
9648 michael 912 # We try a few techniques and use that to set a single cache variable.
9649     #
9650     # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
9651     # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
9652     # dependency, and given that the user is not expected to run this macro,
9653     # just rely on AC_PROG_CC.
9654     AC_DEFUN([_AM_DEPENDENCIES],
9655     [AC_REQUIRE([AM_SET_DEPDIR])dnl
9656     AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
9657     AC_REQUIRE([AM_MAKE_INCLUDE])dnl
9658     AC_REQUIRE([AM_DEP_TRACK])dnl
9659    
9660 michael 1373 m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
9661     [$1], [CXX], [depcc="$CXX" am_compiler_list=],
9662     [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
9663 michael 1425 [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
9664 michael 1373 [$1], [UPC], [depcc="$UPC" am_compiler_list=],
9665     [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
9666     [depcc="$$1" am_compiler_list=])
9667 michael 912
9668     AC_CACHE_CHECK([dependency style of $depcc],
9669     [am_cv_$1_dependencies_compiler_type],
9670     [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
9671     # We make a subdir and do the tests there. Otherwise we can end up
9672     # making bogus files that we don't know about and never remove. For
9673     # instance it was reported that on HP-UX the gcc test will end up
9674 michael 1373 # making a dummy file named 'D' -- because '-MD' means "put the output
9675     # in D".
9676 michael 1257 rm -rf conftest.dir
9677 michael 912 mkdir conftest.dir
9678     # Copy depcomp to subdir because otherwise we won't find it if we're
9679     # using a relative directory.
9680     cp "$am_depcomp" conftest.dir
9681     cd conftest.dir
9682     # We will build objects and dependencies in a subdirectory because
9683     # it helps to detect inapplicable dependency modes. For instance
9684     # both Tru64's cc and ICC support -MD to output dependencies as a
9685     # side effect of compilation, but ICC will put the dependencies in
9686     # the current directory while Tru64 will put them in the object
9687     # directory.
9688     mkdir sub
9689    
9690     am_cv_$1_dependencies_compiler_type=none
9691     if test "$am_compiler_list" = ""; then
9692     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
9693     fi
9694 michael 945 am__universal=false
9695     m4_case([$1], [CC],
9696     [case " $depcc " in #(
9697     *\ -arch\ *\ -arch\ *) am__universal=true ;;
9698     esac],
9699     [CXX],
9700     [case " $depcc " in #(
9701     *\ -arch\ *\ -arch\ *) am__universal=true ;;
9702     esac])
9703    
9704 michael 912 for depmode in $am_compiler_list; do
9705     # Setup a source with many dependencies, because some compilers
9706     # like to wrap large dependency lists on column 80 (with \), and
9707     # we should not choose a depcomp mode which is confused by this.
9708     #
9709     # We need to recreate these files for each test, as the compiler may
9710     # overwrite some of them when testing with obscure command lines.
9711     # This happens at least with the AIX C compiler.
9712     : > sub/conftest.c
9713     for i in 1 2 3 4 5 6; do
9714     echo '#include "conftst'$i'.h"' >> sub/conftest.c
9715 michael 1373 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
9716     # Solaris 10 /bin/sh.
9717     echo '/* dummy */' > sub/conftst$i.h
9718 michael 912 done
9719     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
9720    
9721 michael 1373 # We check with '-c' and '-o' for the sake of the "dashmstdout"
9722 michael 945 # mode. It turns out that the SunPro C++ compiler does not properly
9723 michael 1373 # handle '-M -o', and we need to detect this. Also, some Intel
9724     # versions had trouble with output in subdirs.
9725 michael 945 am__obj=sub/conftest.${OBJEXT-o}
9726     am__minus_obj="-o $am__obj"
9727 michael 912 case $depmode in
9728 michael 945 gcc)
9729     # This depmode causes a compiler race in universal mode.
9730     test "$am__universal" = false || continue
9731     ;;
9732 michael 912 nosideeffect)
9733 michael 1373 # After this tag, mechanisms are not by side-effect, so they'll
9734     # only be used when explicitly requested.
9735 michael 912 if test "x$enable_dependency_tracking" = xyes; then
9736     continue
9737     else
9738     break
9739     fi
9740     ;;
9741 michael 1257 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
9742 michael 1373 # This compiler won't grok '-c -o', but also, the minuso test has
9743 michael 945 # not run yet. These depmodes are late enough in the game, and
9744     # so weak that their functioning should not be impacted.
9745     am__obj=conftest.${OBJEXT-o}
9746     am__minus_obj=
9747     ;;
9748 michael 912 none) break ;;
9749     esac
9750     if depmode=$depmode \
9751 michael 945 source=sub/conftest.c object=$am__obj \
9752 michael 912 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
9753 michael 945 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
9754 michael 912 >/dev/null 2>conftest.err &&
9755     grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
9756     grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
9757 michael 945 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
9758 michael 912 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
9759     # icc doesn't choke on unknown options, it will just issue warnings
9760     # or remarks (even with -Werror). So we grep stderr for any message
9761     # that says an option was ignored or not supported.
9762     # When given -MP, icc 7.0 and 7.1 complain thusly:
9763     # icc: Command line warning: ignoring option '-M'; no argument required
9764     # The diagnosis changed in icc 8.0:
9765     # icc: Command line remark: option '-MP' not supported
9766     if (grep 'ignoring option' conftest.err ||
9767     grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
9768     am_cv_$1_dependencies_compiler_type=$depmode
9769     break
9770     fi
9771     fi
9772     done
9773    
9774     cd ..
9775     rm -rf conftest.dir
9776     else
9777     am_cv_$1_dependencies_compiler_type=none
9778     fi
9779     ])
9780     AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
9781     AM_CONDITIONAL([am__fastdep$1], [
9782     test "x$enable_dependency_tracking" != xno \
9783     && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
9784     ])
9785    
9786    
9787     # AM_SET_DEPDIR
9788     # -------------
9789     # Choose a directory name for dependency files.
9790 michael 1373 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
9791 michael 912 AC_DEFUN([AM_SET_DEPDIR],
9792     [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
9793     AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
9794     ])
9795    
9796    
9797     # AM_DEP_TRACK
9798     # ------------
9799     AC_DEFUN([AM_DEP_TRACK],
9800 michael 1373 [AC_ARG_ENABLE([dependency-tracking], [dnl
9801     AS_HELP_STRING(
9802     [--enable-dependency-tracking],
9803     [do not reject slow dependency extractors])
9804     AS_HELP_STRING(
9805     [--disable-dependency-tracking],
9806     [speeds up one-time build])])
9807 michael 912 if test "x$enable_dependency_tracking" != xno; then
9808     am_depcomp="$ac_aux_dir/depcomp"
9809     AMDEPBACKSLASH='\'
9810 michael 1257 am__nodep='_no'
9811 michael 912 fi
9812     AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
9813     AC_SUBST([AMDEPBACKSLASH])dnl
9814     _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
9815 michael 1257 AC_SUBST([am__nodep])dnl
9816     _AM_SUBST_NOTMAKE([am__nodep])dnl
9817 michael 912 ])
9818    
9819     # Generate code to set up dependency tracking. -*- Autoconf -*-
9820    
9821 michael 1730 # Copyright (C) 1999-2013 Free Software Foundation, Inc.
9822 michael 912 #
9823     # This file is free software; the Free Software Foundation
9824     # gives unlimited permission to copy and/or distribute it,
9825     # with or without modifications, as long as this notice is preserved.
9826    
9827    
9828     # _AM_OUTPUT_DEPENDENCY_COMMANDS
9829     # ------------------------------
9830     AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
9831 michael 945 [{
9832 michael 1720 # Older Autoconf quotes --file arguments for eval, but not when files
9833 michael 945 # are listed without --file. Let's play safe and only enable the eval
9834     # if we detect the quoting.
9835     case $CONFIG_FILES in
9836     *\'*) eval set x "$CONFIG_FILES" ;;
9837     *) set x $CONFIG_FILES ;;
9838     esac
9839     shift
9840     for mf
9841     do
9842     # Strip MF so we end up with the name of the file.
9843     mf=`echo "$mf" | sed -e 's/:.*$//'`
9844     # Check whether this is an Automake generated Makefile or not.
9845 michael 1373 # We used to match only the files named 'Makefile.in', but
9846 michael 945 # some people rename them; so instead we look at the file content.
9847     # Grep'ing the first line is not enough: some people post-process
9848     # each Makefile.in and add a new line on top of each file to say so.
9849     # Grep'ing the whole file is not good either: AIX grep has a line
9850     # limit of 2048, but all sed's we know have understand at least 4000.
9851     if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
9852     dirpart=`AS_DIRNAME("$mf")`
9853     else
9854     continue
9855     fi
9856     # Extract the definition of DEPDIR, am__include, and am__quote
9857 michael 1373 # from the Makefile without running 'make'.
9858 michael 945 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
9859     test -z "$DEPDIR" && continue
9860     am__include=`sed -n 's/^am__include = //p' < "$mf"`
9861 michael 2063 test -z "$am__include" && continue
9862 michael 945 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
9863     # Find all dependency output files, they are included files with
9864     # $(DEPDIR) in their names. We invoke sed twice because it is the
9865     # simplest approach to changing $(DEPDIR) to its actual value in the
9866     # expansion.
9867     for file in `sed -n "
9868     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
9869 michael 1373 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
9870 michael 945 # Make sure the directory exists.
9871     test -f "$dirpart/$file" && continue
9872     fdir=`AS_DIRNAME(["$file"])`
9873     AS_MKDIR_P([$dirpart/$fdir])
9874     # echo "creating $dirpart/$file"
9875     echo '# dummy' > "$dirpart/$file"
9876     done
9877 michael 912 done
9878 michael 945 }
9879 michael 912 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
9880    
9881    
9882     # AM_OUTPUT_DEPENDENCY_COMMANDS
9883     # -----------------------------
9884     # This macro should only be invoked once -- use via AC_REQUIRE.
9885     #
9886     # This code is only required when automatic dependency tracking
9887 michael 1373 # is enabled. FIXME. This creates each '.P' file that we will
9888 michael 912 # need in order to bootstrap the dependency handling code.
9889     AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
9890     [AC_CONFIG_COMMANDS([depfiles],
9891     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
9892     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
9893     ])
9894    
9895     # Do all the work for Automake. -*- Autoconf -*-
9896    
9897 michael 1730 # Copyright (C) 1996-2013 Free Software Foundation, Inc.
9898 michael 912 #
9899     # This file is free software; the Free Software Foundation
9900     # gives unlimited permission to copy and/or distribute it,
9901     # with or without modifications, as long as this notice is preserved.
9902    
9903     # This macro actually does too much. Some checks are only needed if
9904     # your package does certain things. But this isn't really a big deal.
9905    
9906     # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
9907     # AM_INIT_AUTOMAKE([OPTIONS])
9908     # -----------------------------------------------
9909     # The call with PACKAGE and VERSION arguments is the old style
9910     # call (pre autoconf-2.50), which is being phased out. PACKAGE
9911     # and VERSION should now be passed to AC_INIT and removed from
9912     # the call to AM_INIT_AUTOMAKE.
9913     # We support both call styles for the transition. After
9914     # the next Automake release, Autoconf can make the AC_INIT
9915     # arguments mandatory, and then we can depend on a new Autoconf
9916     # release and drop the old call support.
9917     AC_DEFUN([AM_INIT_AUTOMAKE],
9918 michael 1720 [AC_PREREQ([2.65])dnl
9919 michael 912 dnl Autoconf wants to disallow AM_ names. We explicitly allow
9920     dnl the ones we care about.
9921     m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
9922     AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
9923     AC_REQUIRE([AC_PROG_INSTALL])dnl
9924     if test "`cd $srcdir && pwd`" != "`pwd`"; then
9925     # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
9926     # is not polluted with repeated "-I."
9927     AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
9928     # test to see if srcdir already configured
9929     if test -f $srcdir/config.status; then
9930     AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
9931     fi
9932     fi
9933    
9934     # test whether we have cygpath
9935     if test -z "$CYGPATH_W"; then
9936     if (cygpath --version) >/dev/null 2>/dev/null; then
9937     CYGPATH_W='cygpath -w'
9938     else
9939     CYGPATH_W=echo
9940     fi
9941     fi
9942     AC_SUBST([CYGPATH_W])
9943    
9944     # Define the identity of the package.
9945     dnl Distinguish between old-style and new-style calls.
9946     m4_ifval([$2],
9947 michael 1425 [AC_DIAGNOSE([obsolete],
9948 michael 1720 [$0: two- and three-arguments forms are deprecated.])
9949 michael 1425 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
9950 michael 912 AC_SUBST([PACKAGE], [$1])dnl
9951     AC_SUBST([VERSION], [$2])],
9952     [_AM_SET_OPTIONS([$1])dnl
9953     dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
9954 michael 1373 m4_if(
9955     m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
9956     [ok:ok],,
9957 michael 912 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
9958     AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
9959     AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
9960    
9961     _AM_IF_OPTION([no-define],,
9962 michael 1373 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
9963     AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
9964 michael 912
9965     # Some tools Automake needs.
9966     AC_REQUIRE([AM_SANITY_CHECK])dnl
9967     AC_REQUIRE([AC_ARG_PROGRAM])dnl
9968 michael 1373 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
9969     AM_MISSING_PROG([AUTOCONF], [autoconf])
9970     AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
9971     AM_MISSING_PROG([AUTOHEADER], [autoheader])
9972     AM_MISSING_PROG([MAKEINFO], [makeinfo])
9973 michael 945 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
9974     AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
9975 michael 1425 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
9976 michael 1462 # For better backward compatibility. To be removed once Automake 1.9.x
9977     # dies out for good. For more background, see:
9978     # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
9979     # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
9980     AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
9981 michael 912 # We need awk for the "check" target. The system "awk" is bad on
9982     # some platforms.
9983     AC_REQUIRE([AC_PROG_AWK])dnl
9984     AC_REQUIRE([AC_PROG_MAKE_SET])dnl
9985     AC_REQUIRE([AM_SET_LEADING_DOT])dnl
9986     _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
9987 michael 945 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
9988     [_AM_PROG_TAR([v7])])])
9989 michael 912 _AM_IF_OPTION([no-dependencies],,
9990     [AC_PROVIDE_IFELSE([AC_PROG_CC],
9991 michael 1373 [_AM_DEPENDENCIES([CC])],
9992 michael 1425 [m4_define([AC_PROG_CC],
9993     m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
9994 michael 912 AC_PROVIDE_IFELSE([AC_PROG_CXX],
9995 michael 1373 [_AM_DEPENDENCIES([CXX])],
9996 michael 1425 [m4_define([AC_PROG_CXX],
9997     m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
9998 michael 912 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
9999 michael 1373 [_AM_DEPENDENCIES([OBJC])],
10000 michael 1425 [m4_define([AC_PROG_OBJC],
10001     m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
10002 michael 1720 AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
10003 michael 1425 [_AM_DEPENDENCIES([OBJCXX])],
10004     [m4_define([AC_PROG_OBJCXX],
10005 michael 1720 m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
10006 michael 912 ])
10007 michael 1720 AC_REQUIRE([AM_SILENT_RULES])dnl
10008     dnl The testsuite driver may need to know about EXEEXT, so add the
10009     dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
10010     dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
10011 michael 945 AC_CONFIG_COMMANDS_PRE(dnl
10012     [m4_provide_if([_AM_COMPILER_EXEEXT],
10013     [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
10014 michael 912 ])
10015    
10016 michael 1373 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
10017 michael 945 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
10018     dnl mangled by Autoconf and run in a shell conditional statement.
10019     m4_define([_AC_COMPILER_EXEEXT],
10020     m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
10021 michael 912
10022 michael 945
10023 michael 912 # When config.status generates a header, we must update the stamp-h file.
10024     # This file resides in the same directory as the config header
10025     # that is generated. The stamp files are numbered to have different names.
10026    
10027     # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
10028     # loop where config.status creates the headers, so we can generate
10029     # our stamp files there.
10030     AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
10031     [# Compute $1's index in $config_headers.
10032 db 941 _am_arg=$1
10033 michael 912 _am_stamp_count=1
10034     for _am_header in $config_headers :; do
10035     case $_am_header in
10036 db 941 $_am_arg | $_am_arg:* )
10037 michael 912 break ;;
10038     * )
10039     _am_stamp_count=`expr $_am_stamp_count + 1` ;;
10040     esac
10041     done
10042 db 941 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
10043 michael 912
10044 michael 1730 # Copyright (C) 2001-2013 Free Software Foundation, Inc.
10045 michael 912 #
10046     # This file is free software; the Free Software Foundation
10047     # gives unlimited permission to copy and/or distribute it,
10048     # with or without modifications, as long as this notice is preserved.
10049    
10050     # AM_PROG_INSTALL_SH
10051     # ------------------
10052     # Define $install_sh.
10053     AC_DEFUN([AM_PROG_INSTALL_SH],
10054     [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10055 michael 945 if test x"${install_sh}" != xset; then
10056     case $am_aux_dir in
10057     *\ * | *\ *)
10058     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
10059     *)
10060     install_sh="\${SHELL} $am_aux_dir/install-sh"
10061     esac
10062     fi
10063 michael 1373 AC_SUBST([install_sh])])
10064 michael 912
10065 michael 1730 # Copyright (C) 2003-2013 Free Software Foundation, Inc.
10066 michael 912 #
10067     # This file is free software; the Free Software Foundation
10068     # gives unlimited permission to copy and/or distribute it,
10069     # with or without modifications, as long as this notice is preserved.
10070    
10071     # Check whether the underlying file-system supports filenames
10072     # with a leading dot. For instance MS-DOS doesn't.
10073     AC_DEFUN([AM_SET_LEADING_DOT],
10074     [rm -rf .tst 2>/dev/null
10075     mkdir .tst 2>/dev/null
10076     if test -d .tst; then
10077     am__leading_dot=.
10078     else
10079     am__leading_dot=_
10080     fi
10081     rmdir .tst 2>/dev/null
10082     AC_SUBST([am__leading_dot])])
10083    
10084 michael 1730 # Copyright (C) 1998-2013 Free Software Foundation, Inc.
10085 michael 912 #
10086     # This file is free software; the Free Software Foundation
10087     # gives unlimited permission to copy and/or distribute it,
10088     # with or without modifications, as long as this notice is preserved.
10089    
10090     # AM_PROG_LEX
10091     # -----------
10092     # Autoconf leaves LEX=: if lex or flex can't be found. Change that to a
10093     # "missing" invocation, for better error output.
10094     AC_DEFUN([AM_PROG_LEX],
10095 michael 1373 [AC_PREREQ([2.50])dnl
10096 michael 912 AC_REQUIRE([AM_MISSING_HAS_RUN])dnl
10097     AC_REQUIRE([AC_PROG_LEX])dnl
10098     if test "$LEX" = :; then
10099     LEX=${am_missing_run}flex
10100     fi])
10101    
10102     # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
10103     # From Jim Meyering
10104    
10105 michael 1730 # Copyright (C) 1996-2013 Free Software Foundation, Inc.
10106 michael 912 #
10107     # This file is free software; the Free Software Foundation
10108     # gives unlimited permission to copy and/or distribute it,
10109     # with or without modifications, as long as this notice is preserved.
10110    
10111 michael 945 # AM_MAINTAINER_MODE([DEFAULT-MODE])
10112     # ----------------------------------
10113     # Control maintainer-specific portions of Makefiles.
10114 michael 1373 # Default is to disable them, unless 'enable' is passed literally.
10115     # For symmetry, 'disable' may be passed as well. Anyway, the user
10116 michael 945 # can override the default with the --enable/--disable switch.
10117 michael 912 AC_DEFUN([AM_MAINTAINER_MODE],
10118 michael 945 [m4_case(m4_default([$1], [disable]),
10119     [enable], [m4_define([am_maintainer_other], [disable])],
10120     [disable], [m4_define([am_maintainer_other], [enable])],
10121     [m4_define([am_maintainer_other], [enable])
10122     m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
10123 michael 1257 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
10124 michael 945 dnl maintainer-mode's default is 'disable' unless 'enable' is passed
10125     AC_ARG_ENABLE([maintainer-mode],
10126 michael 1373 [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
10127     am_maintainer_other[ make rules and dependencies not useful
10128     (and sometimes confusing) to the casual installer])],
10129     [USE_MAINTAINER_MODE=$enableval],
10130     [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
10131 michael 912 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
10132 michael 945 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
10133 michael 912 MAINT=$MAINTAINER_MODE_TRUE
10134 michael 945 AC_SUBST([MAINT])dnl
10135 michael 912 ]
10136     )
10137    
10138     # Check to see how 'make' treats includes. -*- Autoconf -*-
10139    
10140 michael 1730 # Copyright (C) 2001-2013 Free Software Foundation, Inc.
10141 michael 912 #
10142     # This file is free software; the Free Software Foundation
10143     # gives unlimited permission to copy and/or distribute it,
10144     # with or without modifications, as long as this notice is preserved.
10145    
10146     # AM_MAKE_INCLUDE()
10147     # -----------------
10148     # Check to see how make treats includes.
10149     AC_DEFUN([AM_MAKE_INCLUDE],
10150     [am_make=${MAKE-make}
10151     cat > confinc << 'END'
10152     am__doit:
10153 michael 945 @echo this is the am__doit target
10154 michael 912 .PHONY: am__doit
10155     END
10156     # If we don't find an include directive, just comment out the code.
10157     AC_MSG_CHECKING([for style of include used by $am_make])
10158     am__include="#"
10159     am__quote=
10160     _am_result=none
10161     # First try GNU make style include.
10162     echo "include confinc" > confmf
10163 michael 1373 # Ignore all kinds of additional output from 'make'.
10164 michael 945 case `$am_make -s -f confmf 2> /dev/null` in #(
10165     *the\ am__doit\ target*)
10166     am__include=include
10167     am__quote=
10168     _am_result=GNU
10169     ;;
10170     esac
10171 michael 912 # Now try BSD make style include.
10172     if test "$am__include" = "#"; then
10173     echo '.include "confinc"' > confmf
10174 michael 945 case `$am_make -s -f confmf 2> /dev/null` in #(
10175     *the\ am__doit\ target*)
10176     am__include=.include
10177     am__quote="\""
10178     _am_result=BSD
10179     ;;
10180     esac
10181 michael 912 fi
10182     AC_SUBST([am__include])
10183     AC_SUBST([am__quote])
10184     AC_MSG_RESULT([$_am_result])
10185     rm -f confinc confmf
10186     ])
10187    
10188     # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
10189    
10190 michael 1730 # Copyright (C) 1997-2013 Free Software Foundation, Inc.
10191 michael 912 #
10192     # This file is free software; the Free Software Foundation
10193     # gives unlimited permission to copy and/or distribute it,
10194     # with or without modifications, as long as this notice is preserved.
10195    
10196     # AM_MISSING_PROG(NAME, PROGRAM)
10197     # ------------------------------
10198     AC_DEFUN([AM_MISSING_PROG],
10199     [AC_REQUIRE([AM_MISSING_HAS_RUN])
10200     $1=${$1-"${am_missing_run}$2"}
10201     AC_SUBST($1)])
10202    
10203     # AM_MISSING_HAS_RUN
10204     # ------------------
10205 michael 1720 # Define MISSING if not defined so far and test if it is modern enough.
10206     # If it is, set am_missing_run to use it, otherwise, to nothing.
10207 michael 912 AC_DEFUN([AM_MISSING_HAS_RUN],
10208     [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
10209     AC_REQUIRE_AUX_FILE([missing])dnl
10210 michael 945 if test x"${MISSING+set}" != xset; then
10211     case $am_aux_dir in
10212     *\ * | *\ *)
10213     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
10214     *)
10215     MISSING="\${SHELL} $am_aux_dir/missing" ;;
10216     esac
10217     fi
10218 michael 912 # Use eval to expand $SHELL
10219 michael 1720 if eval "$MISSING --is-lightweight"; then
10220     am_missing_run="$MISSING "
10221 michael 912 else
10222     am_missing_run=
10223 michael 1373 AC_MSG_WARN(['missing' script is too old or missing])
10224 michael 912 fi
10225     ])
10226    
10227     # Helper functions for option handling. -*- Autoconf -*-
10228    
10229 michael 1730 # Copyright (C) 2001-2013 Free Software Foundation, Inc.
10230 michael 912 #
10231     # This file is free software; the Free Software Foundation
10232     # gives unlimited permission to copy and/or distribute it,
10233     # with or without modifications, as long as this notice is preserved.
10234    
10235     # _AM_MANGLE_OPTION(NAME)
10236     # -----------------------
10237     AC_DEFUN([_AM_MANGLE_OPTION],
10238     [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
10239    
10240     # _AM_SET_OPTION(NAME)
10241 michael 1257 # --------------------
10242 michael 912 # Set option NAME. Presently that only means defining a flag for this option.
10243     AC_DEFUN([_AM_SET_OPTION],
10244 michael 1373 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
10245 michael 912
10246     # _AM_SET_OPTIONS(OPTIONS)
10247 michael 1257 # ------------------------
10248 michael 912 # OPTIONS is a space-separated list of Automake options.
10249     AC_DEFUN([_AM_SET_OPTIONS],
10250 michael 945 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
10251 michael 912
10252     # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
10253     # -------------------------------------------
10254     # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
10255     AC_DEFUN([_AM_IF_OPTION],
10256     [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
10257    
10258     # Check to make sure that the build environment is sane. -*- Autoconf -*-
10259    
10260 michael 1730 # Copyright (C) 1996-2013 Free Software Foundation, Inc.
10261 michael 912 #
10262     # This file is free software; the Free Software Foundation
10263     # gives unlimited permission to copy and/or distribute it,
10264     # with or without modifications, as long as this notice is preserved.
10265    
10266     # AM_SANITY_CHECK
10267     # ---------------
10268     AC_DEFUN([AM_SANITY_CHECK],
10269     [AC_MSG_CHECKING([whether build environment is sane])
10270 michael 945 # Reject unsafe characters in $srcdir or the absolute working directory
10271     # name. Accept space and tab only in the latter.
10272     am_lf='
10273     '
10274     case `pwd` in
10275     *[[\\\"\#\$\&\'\`$am_lf]]*)
10276     AC_MSG_ERROR([unsafe absolute working directory name]);;
10277     esac
10278     case $srcdir in
10279     *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
10280 michael 1373 AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
10281 michael 945 esac
10282    
10283 michael 1373 # Do 'set' in a subshell so we don't clobber the current shell's
10284 michael 912 # arguments. Must try -L first in case configure is actually a
10285     # symlink; some systems play weird games with the mod time of symlinks
10286     # (eg FreeBSD returns the mod time of the symlink's containing
10287     # directory).
10288     if (
10289 michael 1373 am_has_slept=no
10290     for am_try in 1 2; do
10291     echo "timestamp, slept: $am_has_slept" > conftest.file
10292     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
10293     if test "$[*]" = "X"; then
10294     # -L didn't work.
10295     set X `ls -t "$srcdir/configure" conftest.file`
10296     fi
10297     if test "$[*]" != "X $srcdir/configure conftest.file" \
10298     && test "$[*]" != "X conftest.file $srcdir/configure"; then
10299 michael 912
10300 michael 1373 # If neither matched, then we have a broken ls. This can happen
10301     # if, for instance, CONFIG_SHELL is bash and it inherits a
10302     # broken ls alias from the environment. This has actually
10303     # happened. Such a system could not be considered "sane".
10304     AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
10305     alias in your environment])
10306     fi
10307     if test "$[2]" = conftest.file || test $am_try -eq 2; then
10308     break
10309     fi
10310     # Just in case.
10311     sleep 1
10312     am_has_slept=yes
10313     done
10314 michael 912 test "$[2]" = conftest.file
10315     )
10316     then
10317     # Ok.
10318     :
10319     else
10320     AC_MSG_ERROR([newly created file is older than distributed files!
10321     Check your system clock])
10322     fi
10323 michael 1373 AC_MSG_RESULT([yes])
10324     # If we didn't sleep, we still need to ensure time stamps of config.status and
10325     # generated files are strictly newer.
10326     am_sleep_pid=
10327     if grep 'slept: no' conftest.file >/dev/null 2>&1; then
10328     ( sleep 1 ) &
10329     am_sleep_pid=$!
10330     fi
10331     AC_CONFIG_COMMANDS_PRE(
10332     [AC_MSG_CHECKING([that generated files are newer than configure])
10333     if test -n "$am_sleep_pid"; then
10334     # Hide warnings about reused PIDs.
10335     wait $am_sleep_pid 2>/dev/null
10336     fi
10337     AC_MSG_RESULT([done])])
10338     rm -f conftest.file
10339     ])
10340 michael 912
10341 michael 1730 # Copyright (C) 2009-2013 Free Software Foundation, Inc.
10342 michael 1720 #
10343     # This file is free software; the Free Software Foundation
10344     # gives unlimited permission to copy and/or distribute it,
10345     # with or without modifications, as long as this notice is preserved.
10346    
10347     # AM_SILENT_RULES([DEFAULT])
10348     # --------------------------
10349     # Enable less verbose build rules; with the default set to DEFAULT
10350     # ("yes" being less verbose, "no" or empty being verbose).
10351     AC_DEFUN([AM_SILENT_RULES],
10352     [AC_ARG_ENABLE([silent-rules], [dnl
10353     AS_HELP_STRING(
10354     [--enable-silent-rules],
10355     [less verbose build output (undo: "make V=1")])
10356     AS_HELP_STRING(
10357     [--disable-silent-rules],
10358     [verbose build output (undo: "make V=0")])dnl
10359     ])
10360     case $enable_silent_rules in @%:@ (((
10361     yes) AM_DEFAULT_VERBOSITY=0;;
10362     no) AM_DEFAULT_VERBOSITY=1;;
10363     *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
10364     esac
10365     dnl
10366     dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
10367     dnl do not support nested variable expansions.
10368     dnl See automake bug#9928 and bug#10237.
10369     am_make=${MAKE-make}
10370     AC_CACHE_CHECK([whether $am_make supports nested variables],
10371     [am_cv_make_support_nested_variables],
10372     [if AS_ECHO([['TRUE=$(BAR$(V))
10373     BAR0=false
10374     BAR1=true
10375     V=1
10376     am__doit:
10377     @$(TRUE)
10378     .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
10379     am_cv_make_support_nested_variables=yes
10380     else
10381     am_cv_make_support_nested_variables=no
10382     fi])
10383     if test $am_cv_make_support_nested_variables = yes; then
10384     dnl Using '$V' instead of '$(V)' breaks IRIX make.
10385     AM_V='$(V)'
10386     AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
10387     else
10388     AM_V=$AM_DEFAULT_VERBOSITY
10389     AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
10390     fi
10391     AC_SUBST([AM_V])dnl
10392     AM_SUBST_NOTMAKE([AM_V])dnl
10393     AC_SUBST([AM_DEFAULT_V])dnl
10394     AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
10395     AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
10396     AM_BACKSLASH='\'
10397     AC_SUBST([AM_BACKSLASH])dnl
10398     _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
10399     ])
10400    
10401 michael 1730 # Copyright (C) 2001-2013 Free Software Foundation, Inc.
10402 michael 912 #
10403     # This file is free software; the Free Software Foundation
10404     # gives unlimited permission to copy and/or distribute it,
10405     # with or without modifications, as long as this notice is preserved.
10406    
10407     # AM_PROG_INSTALL_STRIP
10408     # ---------------------
10409 michael 1373 # One issue with vendor 'install' (even GNU) is that you can't
10410 michael 912 # specify the program used to strip binaries. This is especially
10411     # annoying in cross-compiling environments, where the build's strip
10412     # is unlikely to handle the host's binaries.
10413     # Fortunately install-sh will honor a STRIPPROG variable, so we
10414 michael 1373 # always use install-sh in "make install-strip", and initialize
10415 michael 912 # STRIPPROG with the value of the STRIP variable (set by the user).
10416     AC_DEFUN([AM_PROG_INSTALL_STRIP],
10417     [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10418 michael 1373 # Installed binaries are usually stripped using 'strip' when the user
10419     # run "make install-strip". However 'strip' might not be the right
10420 michael 912 # tool to use in cross-compilation environments, therefore Automake
10421 michael 1373 # will honor the 'STRIP' environment variable to overrule this program.
10422     dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
10423 michael 912 if test "$cross_compiling" != no; then
10424     AC_CHECK_TOOL([STRIP], [strip], :)
10425     fi
10426     INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
10427     AC_SUBST([INSTALL_STRIP_PROGRAM])])
10428    
10429 michael 1730 # Copyright (C) 2006-2013 Free Software Foundation, Inc.
10430 michael 912 #
10431     # This file is free software; the Free Software Foundation
10432     # gives unlimited permission to copy and/or distribute it,
10433     # with or without modifications, as long as this notice is preserved.
10434    
10435     # _AM_SUBST_NOTMAKE(VARIABLE)
10436     # ---------------------------
10437 db 941 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
10438 michael 912 # This macro is traced by Automake.
10439     AC_DEFUN([_AM_SUBST_NOTMAKE])
10440    
10441 michael 945 # AM_SUBST_NOTMAKE(VARIABLE)
10442 michael 1257 # --------------------------
10443 michael 945 # Public sister of _AM_SUBST_NOTMAKE.
10444     AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
10445    
10446 michael 912 # Check how to create a tarball. -*- Autoconf -*-
10447    
10448 michael 1730 # Copyright (C) 2004-2013 Free Software Foundation, Inc.
10449 michael 912 #
10450     # This file is free software; the Free Software Foundation
10451     # gives unlimited permission to copy and/or distribute it,
10452     # with or without modifications, as long as this notice is preserved.
10453    
10454     # _AM_PROG_TAR(FORMAT)
10455     # --------------------
10456     # Check how to create a tarball in format FORMAT.
10457 michael 1373 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
10458 michael 912 #
10459     # Substitute a variable $(am__tar) that is a command
10460     # writing to stdout a FORMAT-tarball containing the directory
10461     # $tardir.
10462     # tardir=directory && $(am__tar) > result.tar
10463     #
10464     # Substitute a variable $(am__untar) that extract such
10465     # a tarball read from stdin.
10466     # $(am__untar) < result.tar
10467 michael 2063 #
10468 michael 912 AC_DEFUN([_AM_PROG_TAR],
10469 michael 1291 [# Always define AMTAR for backward compatibility. Yes, it's still used
10470     # in the wild :-( We should find a proper way to deprecate it ...
10471     AC_SUBST([AMTAR], ['$${TAR-tar}'])
10472 michael 2063
10473     # We'll loop over all known methods to create a tar archive until one works.
10474 michael 912 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
10475    
10476 michael 2063 m4_if([$1], [v7],
10477     [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
10478 michael 912
10479 michael 2063 [m4_case([$1],
10480     [ustar],
10481     [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
10482     # There is notably a 21 bits limit for the UID and the GID. In fact,
10483     # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
10484     # and bug#13588).
10485     am_max_uid=2097151 # 2^21 - 1
10486     am_max_gid=$am_max_uid
10487     # The $UID and $GID variables are not portable, so we need to resort
10488     # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
10489     # below are definitely unexpected, so allow the users to see them
10490     # (that is, avoid stderr redirection).
10491     am_uid=`id -u || echo unknown`
10492     am_gid=`id -g || echo unknown`
10493     AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
10494     if test $am_uid -le $am_max_uid; then
10495     AC_MSG_RESULT([yes])
10496     else
10497     AC_MSG_RESULT([no])
10498     _am_tools=none
10499     fi
10500     AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
10501     if test $am_gid -le $am_max_gid; then
10502     AC_MSG_RESULT([yes])
10503     else
10504     AC_MSG_RESULT([no])
10505     _am_tools=none
10506     fi],
10507    
10508     [pax],
10509     [],
10510    
10511     [m4_fatal([Unknown tar format])])
10512    
10513     AC_MSG_CHECKING([how to create a $1 tar archive])
10514    
10515     # Go ahead even if we have the value already cached. We do so because we
10516     # need to set the values for the 'am__tar' and 'am__untar' variables.
10517     _am_tools=${am_cv_prog_tar_$1-$_am_tools}
10518    
10519     for _am_tool in $_am_tools; do
10520     case $_am_tool in
10521     gnutar)
10522     for _am_tar in tar gnutar gtar; do
10523     AM_RUN_LOG([$_am_tar --version]) && break
10524     done
10525     am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
10526     am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
10527     am__untar="$_am_tar -xf -"
10528     ;;
10529     plaintar)
10530     # Must skip GNU tar: if it does not support --format= it doesn't create
10531     # ustar tarball either.
10532     (tar --version) >/dev/null 2>&1 && continue
10533     am__tar='tar chf - "$$tardir"'
10534     am__tar_='tar chf - "$tardir"'
10535     am__untar='tar xf -'
10536     ;;
10537     pax)
10538     am__tar='pax -L -x $1 -w "$$tardir"'
10539     am__tar_='pax -L -x $1 -w "$tardir"'
10540     am__untar='pax -r'
10541     ;;
10542     cpio)
10543     am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
10544     am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
10545     am__untar='cpio -i -H $1 -d'
10546     ;;
10547     none)
10548     am__tar=false
10549     am__tar_=false
10550     am__untar=false
10551     ;;
10552     esac
10553    
10554     # If the value was cached, stop now. We just wanted to have am__tar
10555     # and am__untar set.
10556     test -n "${am_cv_prog_tar_$1}" && break
10557    
10558     # tar/untar a dummy directory, and stop if the command works.
10559     rm -rf conftest.dir
10560     mkdir conftest.dir
10561     echo GrepMe > conftest.dir/file
10562     AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
10563     rm -rf conftest.dir
10564     if test -s conftest.tar; then
10565     AM_RUN_LOG([$am__untar <conftest.tar])
10566     AM_RUN_LOG([cat conftest.dir/file])
10567     grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
10568     fi
10569     done
10570 michael 912 rm -rf conftest.dir
10571    
10572 michael 2063 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
10573     AC_MSG_RESULT([$am_cv_prog_tar_$1])])
10574    
10575 michael 912 AC_SUBST([am__tar])
10576     AC_SUBST([am__untar])
10577     ]) # _AM_PROG_TAR
10578    
10579     m4_include([acinclude.m4])

Properties

Name Value
svn:eol-style native