ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/hopm/releases/1.0.4/aclocal.m4
Revision: 5353
Committed: Sun Jan 11 13:26:39 2015 UTC (9 years, 3 months ago) by michael
Original Path: hopm/branches/1.0.x/aclocal.m4
File size: 372503 byte(s)
Log Message:
- automake 1.15

File Contents

# User Rev Content
1 michael 5353 # generated automatically by aclocal 1.15 -*- Autoconf -*-
2 michael 5052
3 michael 5353 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
4 michael 5059
5 michael 5052 # 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 5059 m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
15     m4_ifndef([AC_AUTOCONF_VERSION],
16     [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
17     m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
18     [m4_warning([this file was generated for autoconf 2.69.
19     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     To do so, use the procedure documented by the package, typically 'autoreconf'.])])
22    
23 michael 5052 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
24 michael 5059 #
25     # Copyright (C) 1996-2001, 2003-2014 Free Software Foundation, Inc.
26     # Written by Gordon Matzigkeit, 1996
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 michael 5052
32 michael 5059 m4_define([_LT_COPYING], [dnl
33     # Copyright (C) 2014 Free Software Foundation, Inc.
34     # This is free software; see the source for copying conditions. There is NO
35     # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
36 michael 5052
37 michael 5059 # GNU Libtool is free software; you can redistribute it and/or modify
38     # it under the terms of the GNU General Public License as published by
39     # the Free Software Foundation; either version 2 of of the License, or
40     # (at your option) any later version.
41     #
42     # As a special exception to the GNU General Public License, if you
43     # distribute this file as part of a program or library that is built
44     # using GNU Libtool, you may include this file under the same
45     # distribution terms that you use for the rest of that program.
46     #
47     # GNU Libtool is distributed in the hope that it will be useful, but
48     # WITHOUT ANY WARRANTY; without even the implied warranty of
49     # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
50     # GNU General Public License for more details.
51     #
52     # You should have received a copy of the GNU General Public License
53     # along with this program. If not, see <http://www.gnu.org/licenses/>.
54     ])
55 michael 5052
56 michael 5059 # serial 58 LT_INIT
57 michael 5052
58    
59 michael 5059 # LT_PREREQ(VERSION)
60     # ------------------
61     # Complain and exit if this libtool version is less that VERSION.
62     m4_defun([LT_PREREQ],
63     [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
64     [m4_default([$3],
65     [m4_fatal([Libtool version $1 or higher is required],
66     63)])],
67     [$2])])
68 michael 5052
69    
70 michael 5059 # _LT_CHECK_BUILDDIR
71     # ------------------
72     # Complain if the absolute build directory name contains unusual characters
73     m4_defun([_LT_CHECK_BUILDDIR],
74     [case `pwd` in
75     *\ * | *\ *)
76     AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
77     esac
78     ])
79 michael 5052
80    
81 michael 5059 # LT_INIT([OPTIONS])
82     # ------------------
83     AC_DEFUN([LT_INIT],
84     [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK
85     AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
86     AC_BEFORE([$0], [LT_LANG])dnl
87     AC_BEFORE([$0], [LT_OUTPUT])dnl
88     AC_BEFORE([$0], [LTDL_INIT])dnl
89     m4_require([_LT_CHECK_BUILDDIR])dnl
90    
91     dnl Autoconf doesn't catch unexpanded LT_ macros by default:
92     m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
93     m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
94     dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
95     dnl unless we require an AC_DEFUNed macro:
96     AC_REQUIRE([LTOPTIONS_VERSION])dnl
97     AC_REQUIRE([LTSUGAR_VERSION])dnl
98     AC_REQUIRE([LTVERSION_VERSION])dnl
99     AC_REQUIRE([LTOBSOLETE_VERSION])dnl
100     m4_require([_LT_PROG_LTMAIN])dnl
101    
102     _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
103    
104     dnl Parse OPTIONS
105     _LT_SET_OPTIONS([$0], [$1])
106    
107 michael 5052 # This can be used to rebuild libtool when needed
108 michael 5059 LIBTOOL_DEPS=$ltmain
109 michael 5052
110     # Always use our own libtool.
111     LIBTOOL='$(SHELL) $(top_builddir)/libtool'
112     AC_SUBST(LIBTOOL)dnl
113    
114 michael 5059 _LT_SETUP
115 michael 5052
116 michael 5059 # Only expand once:
117     m4_define([LT_INIT])
118     ])# LT_INIT
119 michael 5052
120 michael 5059 # Old names:
121     AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
122     AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
123     dnl aclocal-1.4 backwards compatibility:
124     dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
125     dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
126    
127    
128     # _LT_CC_BASENAME(CC)
129     # -------------------
130     # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
131     m4_defun([_LT_CC_BASENAME],
132     [for cc_temp in $1""; do
133     case $cc_temp in
134     compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
135     distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
136     \-*) ;;
137     *) break;;
138     esac
139     done
140     cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
141     ])
142    
143    
144     # _LT_FILEUTILS_DEFAULTS
145     # ----------------------
146     # It is okay to use these file commands and assume they have been set
147     # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'.
148     m4_defun([_LT_FILEUTILS_DEFAULTS],
149     [: ${CP="cp -f"}
150     : ${MV="mv -f"}
151     : ${RM="rm -f"}
152     ])# _LT_FILEUTILS_DEFAULTS
153    
154    
155     # _LT_SETUP
156     # ---------
157     m4_defun([_LT_SETUP],
158     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
159 michael 5052 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
160 michael 5059 AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
161     AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
162    
163     _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
164     dnl
165     _LT_DECL([], [host_alias], [0], [The host system])dnl
166     _LT_DECL([], [host], [0])dnl
167     _LT_DECL([], [host_os], [0])dnl
168     dnl
169     _LT_DECL([], [build_alias], [0], [The build system])dnl
170     _LT_DECL([], [build], [0])dnl
171     _LT_DECL([], [build_os], [0])dnl
172     dnl
173 michael 5052 AC_REQUIRE([AC_PROG_CC])dnl
174 michael 5059 AC_REQUIRE([LT_PATH_LD])dnl
175     AC_REQUIRE([LT_PATH_NM])dnl
176     dnl
177 michael 5052 AC_REQUIRE([AC_PROG_LN_S])dnl
178 michael 5059 test -z "$LN_S" && LN_S="ln -s"
179     _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
180 michael 5052 dnl
181 michael 5059 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
182     _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
183     _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
184     dnl
185     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
186     m4_require([_LT_CHECK_SHELL_FEATURES])dnl
187     m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
188     m4_require([_LT_CMD_RELOAD])dnl
189     m4_require([_LT_CHECK_MAGIC_METHOD])dnl
190     m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
191     m4_require([_LT_CMD_OLD_ARCHIVE])dnl
192     m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
193     m4_require([_LT_WITH_SYSROOT])dnl
194     m4_require([_LT_CMD_TRUNCATE])dnl
195 michael 5052
196 michael 5059 _LT_CONFIG_LIBTOOL_INIT([
197     # See if we are running on zsh, and set the options that allow our
198     # commands through without removal of \ escapes INIT.
199     if test -n "\${ZSH_VERSION+set}"; then
200     setopt NO_GLOB_SUBST
201     fi
202     ])
203     if test -n "${ZSH_VERSION+set}"; then
204     setopt NO_GLOB_SUBST
205     fi
206 michael 5052
207 michael 5059 _LT_CHECK_OBJDIR
208 michael 5052
209 michael 5059 m4_require([_LT_TAG_COMPILER])dnl
210    
211 michael 5052 case $host_os in
212     aix3*)
213     # AIX sometimes has problems with the GCC collect2 program. For some
214     # reason, if we set the COLLECT_NAMES environment variable, the problems
215     # vanish in a puff of smoke.
216 michael 5059 if test set != "${COLLECT_NAMES+set}"; then
217 michael 5052 COLLECT_NAMES=
218     export COLLECT_NAMES
219     fi
220     ;;
221     esac
222    
223     # Global variables:
224 michael 5059 ofile=libtool
225 michael 5052 can_build_shared=yes
226    
227 michael 5059 # All known linkers require a '.a' archive for static linking (except MSVC,
228 michael 5052 # which needs '.lib').
229     libext=a
230    
231 michael 5059 with_gnu_ld=$lt_cv_prog_gnu_ld
232 michael 5052
233 michael 5059 old_CC=$CC
234     old_CFLAGS=$CFLAGS
235 michael 5052
236     # Set sane defaults for various variables
237     test -z "$CC" && CC=cc
238     test -z "$LTCC" && LTCC=$CC
239     test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
240     test -z "$LD" && LD=ld
241     test -z "$ac_objext" && ac_objext=o
242    
243     _LT_CC_BASENAME([$compiler])
244    
245     # Only perform the check for file, if the check method requires it
246 michael 5059 test -z "$MAGIC_CMD" && MAGIC_CMD=file
247 michael 5052 case $deplibs_check_method in
248     file_magic*)
249     if test "$file_magic_cmd" = '$MAGIC_CMD'; then
250 michael 5059 _LT_PATH_MAGIC
251 michael 5052 fi
252     ;;
253     esac
254    
255 michael 5059 # Use C for the default configuration in the libtool script
256     LT_SUPPORTED_TAG([CC])
257     _LT_LANG_C_CONFIG
258     _LT_LANG_DEFAULT_CONFIG
259     _LT_CONFIG_COMMANDS
260     ])# _LT_SETUP
261 michael 5052
262    
263 michael 5059 # _LT_PREPARE_SED_QUOTE_VARS
264     # --------------------------
265     # Define a few sed substitution that help us do robust quoting.
266     m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
267     [# Backslashify metacharacters that are still active within
268     # double-quoted strings.
269     sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
270 michael 5052
271 michael 5059 # Same as above, but do not quote variable references.
272     double_quote_subst='s/\([["`\\]]\)/\\\1/g'
273 michael 5052
274 michael 5059 # Sed substitution to delay expansion of an escaped shell variable in a
275     # double_quote_subst'ed string.
276     delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
277 michael 5052
278 michael 5059 # Sed substitution to delay expansion of an escaped single quote.
279     delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
280    
281     # Sed substitution to avoid accidental globbing in evaled expressions
282     no_glob_subst='s/\*/\\\*/g'
283     ])
284    
285     # _LT_PROG_LTMAIN
286     # ---------------
287     # Note that this code is called both from 'configure', and 'config.status'
288     # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
289     # 'config.status' has no value for ac_aux_dir unless we are using Automake,
290     # so we pass a copy along to make sure it has a sensible value anyway.
291     m4_defun([_LT_PROG_LTMAIN],
292     [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
293     _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
294     ltmain=$ac_aux_dir/ltmain.sh
295     ])# _LT_PROG_LTMAIN
296    
297    
298    
299     # So that we can recreate a full libtool script including additional
300     # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
301     # in macros and then make a single call at the end using the 'libtool'
302     # label.
303    
304    
305     # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
306     # ----------------------------------------
307     # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
308     m4_define([_LT_CONFIG_LIBTOOL_INIT],
309     [m4_ifval([$1],
310     [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
311     [$1
312     ])])])
313    
314     # Initialize.
315     m4_define([_LT_OUTPUT_LIBTOOL_INIT])
316    
317    
318     # _LT_CONFIG_LIBTOOL([COMMANDS])
319     # ------------------------------
320     # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
321     m4_define([_LT_CONFIG_LIBTOOL],
322     [m4_ifval([$1],
323     [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
324     [$1
325     ])])])
326    
327     # Initialize.
328     m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
329    
330    
331     # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
332     # -----------------------------------------------------
333     m4_defun([_LT_CONFIG_SAVE_COMMANDS],
334     [_LT_CONFIG_LIBTOOL([$1])
335     _LT_CONFIG_LIBTOOL_INIT([$2])
336     ])
337    
338    
339     # _LT_FORMAT_COMMENT([COMMENT])
340     # -----------------------------
341     # Add leading comment marks to the start of each line, and a trailing
342     # full-stop to the whole comment if one is not present already.
343     m4_define([_LT_FORMAT_COMMENT],
344     [m4_ifval([$1], [
345     m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
346     [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
347     )])
348    
349    
350    
351    
352    
353     # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
354     # -------------------------------------------------------------------
355     # CONFIGNAME is the name given to the value in the libtool script.
356     # VARNAME is the (base) name used in the configure script.
357     # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
358     # VARNAME. Any other value will be used directly.
359     m4_define([_LT_DECL],
360     [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
361     [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
362     [m4_ifval([$1], [$1], [$2])])
363     lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
364     m4_ifval([$4],
365     [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
366     lt_dict_add_subkey([lt_decl_dict], [$2],
367     [tagged?], [m4_ifval([$5], [yes], [no])])])
368     ])
369    
370    
371     # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
372     # --------------------------------------------------------
373     m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
374    
375    
376     # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
377     # ------------------------------------------------
378     m4_define([lt_decl_tag_varnames],
379     [_lt_decl_filter([tagged?], [yes], $@)])
380    
381    
382     # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
383     # ---------------------------------------------------------
384     m4_define([_lt_decl_filter],
385     [m4_case([$#],
386     [0], [m4_fatal([$0: too few arguments: $#])],
387     [1], [m4_fatal([$0: too few arguments: $#: $1])],
388     [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
389     [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
390     [lt_dict_filter([lt_decl_dict], $@)])[]dnl
391     ])
392    
393    
394     # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
395     # --------------------------------------------------
396     m4_define([lt_decl_quote_varnames],
397     [_lt_decl_filter([value], [1], $@)])
398    
399    
400     # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
401     # ---------------------------------------------------
402     m4_define([lt_decl_dquote_varnames],
403     [_lt_decl_filter([value], [2], $@)])
404    
405    
406     # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
407     # ---------------------------------------------------
408     m4_define([lt_decl_varnames_tagged],
409     [m4_assert([$# <= 2])dnl
410     _$0(m4_quote(m4_default([$1], [[, ]])),
411     m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
412     m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
413     m4_define([_lt_decl_varnames_tagged],
414     [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
415    
416    
417     # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
418     # ------------------------------------------------
419     m4_define([lt_decl_all_varnames],
420     [_$0(m4_quote(m4_default([$1], [[, ]])),
421     m4_if([$2], [],
422     m4_quote(lt_decl_varnames),
423     m4_quote(m4_shift($@))))[]dnl
424     ])
425     m4_define([_lt_decl_all_varnames],
426     [lt_join($@, lt_decl_varnames_tagged([$1],
427     lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
428     ])
429    
430    
431     # _LT_CONFIG_STATUS_DECLARE([VARNAME])
432     # ------------------------------------
433     # Quote a variable value, and forward it to 'config.status' so that its
434     # declaration there will have the same value as in 'configure'. VARNAME
435     # must have a single quote delimited value for this to work.
436     m4_define([_LT_CONFIG_STATUS_DECLARE],
437     [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
438    
439    
440     # _LT_CONFIG_STATUS_DECLARATIONS
441     # ------------------------------
442     # We delimit libtool config variables with single quotes, so when
443     # we write them to config.status, we have to be sure to quote all
444     # embedded single quotes properly. In configure, this macro expands
445     # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
446     #
447     # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
448     m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
449     [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
450     [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
451    
452    
453     # _LT_LIBTOOL_TAGS
454     # ----------------
455     # Output comment and list of tags supported by the script
456     m4_defun([_LT_LIBTOOL_TAGS],
457     [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
458     available_tags='_LT_TAGS'dnl
459     ])
460    
461    
462     # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
463     # -----------------------------------
464     # Extract the dictionary values for VARNAME (optionally with TAG) and
465     # expand to a commented shell variable setting:
466     #
467     # # Some comment about what VAR is for.
468     # visible_name=$lt_internal_name
469     m4_define([_LT_LIBTOOL_DECLARE],
470     [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
471     [description])))[]dnl
472     m4_pushdef([_libtool_name],
473     m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
474     m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
475     [0], [_libtool_name=[$]$1],
476     [1], [_libtool_name=$lt_[]$1],
477     [2], [_libtool_name=$lt_[]$1],
478     [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
479     m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
480     ])
481    
482    
483     # _LT_LIBTOOL_CONFIG_VARS
484     # -----------------------
485     # Produce commented declarations of non-tagged libtool config variables
486     # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool'
487     # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
488     # section) are produced by _LT_LIBTOOL_TAG_VARS.
489     m4_defun([_LT_LIBTOOL_CONFIG_VARS],
490     [m4_foreach([_lt_var],
491     m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
492     [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
493    
494    
495     # _LT_LIBTOOL_TAG_VARS(TAG)
496     # -------------------------
497     m4_define([_LT_LIBTOOL_TAG_VARS],
498     [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
499     [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
500    
501    
502     # _LT_TAGVAR(VARNAME, [TAGNAME])
503     # ------------------------------
504     m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
505    
506    
507     # _LT_CONFIG_COMMANDS
508 michael 5052 # -------------------
509 michael 5059 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
510     # variables for single and double quote escaping we saved from calls
511     # to _LT_DECL, we can put quote escaped variables declarations
512     # into 'config.status', and then the shell code to quote escape them in
513     # for loops in 'config.status'. Finally, any additional code accumulated
514     # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
515     m4_defun([_LT_CONFIG_COMMANDS],
516     [AC_PROVIDE_IFELSE([LT_OUTPUT],
517     dnl If the libtool generation code has been placed in $CONFIG_LT,
518     dnl instead of duplicating it all over again into config.status,
519     dnl then we will have config.status run $CONFIG_LT later, so it
520     dnl needs to know what name is stored there:
521     [AC_CONFIG_COMMANDS([libtool],
522     [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
523     dnl If the libtool generation code is destined for config.status,
524     dnl expand the accumulated commands and init code now:
525     [AC_CONFIG_COMMANDS([libtool],
526     [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
527     ])#_LT_CONFIG_COMMANDS
528    
529    
530     # Initialize.
531     m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
532     [
533    
534     # The HP-UX ksh and POSIX shell print the target directory to stdout
535     # if CDPATH is set.
536     (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
537    
538     sed_quote_subst='$sed_quote_subst'
539     double_quote_subst='$double_quote_subst'
540     delay_variable_subst='$delay_variable_subst'
541     _LT_CONFIG_STATUS_DECLARATIONS
542     LTCC='$LTCC'
543     LTCFLAGS='$LTCFLAGS'
544     compiler='$compiler_DEFAULT'
545    
546     # A function that is used when there is no print builtin or printf.
547     func_fallback_echo ()
548     {
549     eval 'cat <<_LTECHO_EOF
550     \$[]1
551     _LTECHO_EOF'
552     }
553    
554     # Quote evaled strings.
555     for var in lt_decl_all_varnames([[ \
556     ]], lt_decl_quote_varnames); do
557     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
558     *[[\\\\\\\`\\"\\\$]]*)
559     eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
560     ;;
561     *)
562     eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
563     ;;
564     esac
565     done
566    
567     # Double-quote double-evaled strings.
568     for var in lt_decl_all_varnames([[ \
569     ]], lt_decl_dquote_varnames); do
570     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
571     *[[\\\\\\\`\\"\\\$]]*)
572     eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
573     ;;
574     *)
575     eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
576     ;;
577     esac
578     done
579    
580     _LT_OUTPUT_LIBTOOL_INIT
581     ])
582    
583     # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
584     # ------------------------------------
585     # Generate a child script FILE with all initialization necessary to
586     # reuse the environment learned by the parent script, and make the
587     # file executable. If COMMENT is supplied, it is inserted after the
588     # '#!' sequence but before initialization text begins. After this
589     # macro, additional text can be appended to FILE to form the body of
590     # the child script. The macro ends with non-zero status if the
591     # file could not be fully written (such as if the disk is full).
592     m4_ifdef([AS_INIT_GENERATED],
593     [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
594     [m4_defun([_LT_GENERATED_FILE_INIT],
595     [m4_require([AS_PREPARE])]dnl
596     [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
597     [lt_write_fail=0
598     cat >$1 <<_ASEOF || lt_write_fail=1
599     #! $SHELL
600     # Generated by $as_me.
601     $2
602     SHELL=\${CONFIG_SHELL-$SHELL}
603     export SHELL
604     _ASEOF
605     cat >>$1 <<\_ASEOF || lt_write_fail=1
606     AS_SHELL_SANITIZE
607     _AS_PREPARE
608     exec AS_MESSAGE_FD>&1
609     _ASEOF
610     test 0 = "$lt_write_fail" && chmod +x $1[]dnl
611     m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
612    
613     # LT_OUTPUT
614     # ---------
615     # This macro allows early generation of the libtool script (before
616     # AC_OUTPUT is called), incase it is used in configure for compilation
617     # tests.
618     AC_DEFUN([LT_OUTPUT],
619     [: ${CONFIG_LT=./config.lt}
620     AC_MSG_NOTICE([creating $CONFIG_LT])
621     _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
622     [# Run this file to recreate a libtool stub with the current configuration.])
623    
624     cat >>"$CONFIG_LT" <<\_LTEOF
625     lt_cl_silent=false
626     exec AS_MESSAGE_LOG_FD>>config.log
627     {
628     echo
629     AS_BOX([Running $as_me.])
630     } >&AS_MESSAGE_LOG_FD
631    
632     lt_cl_help="\
633     '$as_me' creates a local libtool stub from the current configuration,
634     for use in further configure time tests before the real libtool is
635     generated.
636    
637     Usage: $[0] [[OPTIONS]]
638    
639     -h, --help print this help, then exit
640     -V, --version print version number, then exit
641     -q, --quiet do not print progress messages
642     -d, --debug don't remove temporary files
643    
644     Report bugs to <bug-libtool@gnu.org>."
645    
646     lt_cl_version="\
647     m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
648     m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
649     configured by $[0], generated by m4_PACKAGE_STRING.
650    
651     Copyright (C) 2011 Free Software Foundation, Inc.
652     This config.lt script is free software; the Free Software Foundation
653     gives unlimited permision to copy, distribute and modify it."
654    
655     while test 0 != $[#]
656     do
657     case $[1] in
658     --version | --v* | -V )
659     echo "$lt_cl_version"; exit 0 ;;
660     --help | --h* | -h )
661     echo "$lt_cl_help"; exit 0 ;;
662     --debug | --d* | -d )
663     debug=: ;;
664     --quiet | --q* | --silent | --s* | -q )
665     lt_cl_silent=: ;;
666    
667     -*) AC_MSG_ERROR([unrecognized option: $[1]
668     Try '$[0] --help' for more information.]) ;;
669    
670     *) AC_MSG_ERROR([unrecognized argument: $[1]
671     Try '$[0] --help' for more information.]) ;;
672     esac
673     shift
674     done
675    
676     if $lt_cl_silent; then
677     exec AS_MESSAGE_FD>/dev/null
678     fi
679     _LTEOF
680    
681     cat >>"$CONFIG_LT" <<_LTEOF
682     _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
683     _LTEOF
684    
685     cat >>"$CONFIG_LT" <<\_LTEOF
686     AC_MSG_NOTICE([creating $ofile])
687     _LT_OUTPUT_LIBTOOL_COMMANDS
688     AS_EXIT(0)
689     _LTEOF
690     chmod +x "$CONFIG_LT"
691    
692     # configure is writing to config.log, but config.lt does its own redirection,
693     # appending to config.log, which fails on DOS, as config.log is still kept
694     # open by configure. Here we exec the FD to /dev/null, effectively closing
695     # config.log, so it can be properly (re)opened and appended to by config.lt.
696     lt_cl_success=:
697     test yes = "$silent" &&
698     lt_config_lt_args="$lt_config_lt_args --quiet"
699     exec AS_MESSAGE_LOG_FD>/dev/null
700     $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
701     exec AS_MESSAGE_LOG_FD>>config.log
702     $lt_cl_success || AS_EXIT(1)
703     ])# LT_OUTPUT
704    
705    
706     # _LT_CONFIG(TAG)
707     # ---------------
708     # If TAG is the built-in tag, create an initial libtool script with a
709     # default configuration from the untagged config vars. Otherwise add code
710     # to config.status for appending the configuration named by TAG from the
711     # matching tagged config vars.
712     m4_defun([_LT_CONFIG],
713     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
714     _LT_CONFIG_SAVE_COMMANDS([
715     m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
716     m4_if(_LT_TAG, [C], [
717     # See if we are running on zsh, and set the options that allow our
718     # commands through without removal of \ escapes.
719     if test -n "${ZSH_VERSION+set}"; then
720     setopt NO_GLOB_SUBST
721     fi
722    
723     cfgfile=${ofile}T
724     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
725     $RM "$cfgfile"
726    
727     cat <<_LT_EOF >> "$cfgfile"
728     #! $SHELL
729     # Generated automatically by $as_me ($PACKAGE) $VERSION
730     # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
731     # NOTE: Changes made to this file will be lost: look at ltmain.sh.
732    
733     # Provide generalized library-building support services.
734     # Written by Gordon Matzigkeit, 1996
735    
736     _LT_COPYING
737     _LT_LIBTOOL_TAGS
738    
739     # ### BEGIN LIBTOOL CONFIG
740     _LT_LIBTOOL_CONFIG_VARS
741     _LT_LIBTOOL_TAG_VARS
742     # ### END LIBTOOL CONFIG
743    
744     _LT_EOF
745    
746     case $host_os in
747     aix3*)
748     cat <<\_LT_EOF >> "$cfgfile"
749     # AIX sometimes has problems with the GCC collect2 program. For some
750     # reason, if we set the COLLECT_NAMES environment variable, the problems
751     # vanish in a puff of smoke.
752     if test set != "${COLLECT_NAMES+set}"; then
753     COLLECT_NAMES=
754     export COLLECT_NAMES
755     fi
756     _LT_EOF
757     ;;
758     esac
759    
760     _LT_PROG_LTMAIN
761    
762     # We use sed instead of cat because bash on DJGPP gets confused if
763     # if finds mixed CR/LF and LF-only lines. Since sed operates in
764     # text mode, it properly converts lines to CR/LF. This bash problem
765     # is reportedly fixed, but why not run on old versions too?
766     sed '$q' "$ltmain" >> "$cfgfile" \
767     || (rm -f "$cfgfile"; exit 1)
768    
769     mv -f "$cfgfile" "$ofile" ||
770     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
771     chmod +x "$ofile"
772     ],
773     [cat <<_LT_EOF >> "$ofile"
774    
775     dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
776     dnl in a comment (ie after a #).
777     # ### BEGIN LIBTOOL TAG CONFIG: $1
778     _LT_LIBTOOL_TAG_VARS(_LT_TAG)
779     # ### END LIBTOOL TAG CONFIG: $1
780     _LT_EOF
781     ])dnl /m4_if
782     ],
783     [m4_if([$1], [], [
784     PACKAGE='$PACKAGE'
785     VERSION='$VERSION'
786     RM='$RM'
787     ofile='$ofile'], [])
788     ])dnl /_LT_CONFIG_SAVE_COMMANDS
789     ])# _LT_CONFIG
790    
791    
792     # LT_SUPPORTED_TAG(TAG)
793     # ---------------------
794     # Trace this macro to discover what tags are supported by the libtool
795     # --tag option, using:
796     # autoconf --trace 'LT_SUPPORTED_TAG:$1'
797     AC_DEFUN([LT_SUPPORTED_TAG], [])
798    
799    
800     # C support is built-in for now
801     m4_define([_LT_LANG_C_enabled], [])
802     m4_define([_LT_TAGS], [])
803    
804    
805     # LT_LANG(LANG)
806     # -------------
807     # Enable libtool support for the given language if not already enabled.
808     AC_DEFUN([LT_LANG],
809     [AC_BEFORE([$0], [LT_OUTPUT])dnl
810     m4_case([$1],
811     [C], [_LT_LANG(C)],
812     [C++], [_LT_LANG(CXX)],
813     [Go], [_LT_LANG(GO)],
814     [Java], [_LT_LANG(GCJ)],
815     [Fortran 77], [_LT_LANG(F77)],
816     [Fortran], [_LT_LANG(FC)],
817     [Windows Resource], [_LT_LANG(RC)],
818     [m4_ifdef([_LT_LANG_]$1[_CONFIG],
819     [_LT_LANG($1)],
820     [m4_fatal([$0: unsupported language: "$1"])])])dnl
821     ])# LT_LANG
822    
823    
824     # _LT_LANG(LANGNAME)
825     # ------------------
826     m4_defun([_LT_LANG],
827     [m4_ifdef([_LT_LANG_]$1[_enabled], [],
828     [LT_SUPPORTED_TAG([$1])dnl
829     m4_append([_LT_TAGS], [$1 ])dnl
830     m4_define([_LT_LANG_]$1[_enabled], [])dnl
831     _LT_LANG_$1_CONFIG($1)])dnl
832     ])# _LT_LANG
833    
834    
835     m4_ifndef([AC_PROG_GO], [
836     # NOTE: This macro has been submitted for inclusion into #
837     # GNU Autoconf as AC_PROG_GO. When it is available in #
838     # a released version of Autoconf we should remove this #
839     # macro and use it instead. #
840     m4_defun([AC_PROG_GO],
841     [AC_LANG_PUSH(Go)dnl
842     AC_ARG_VAR([GOC], [Go compiler command])dnl
843     AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
844     _AC_ARG_VAR_LDFLAGS()dnl
845     AC_CHECK_TOOL(GOC, gccgo)
846     if test -z "$GOC"; then
847     if test -n "$ac_tool_prefix"; then
848     AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
849     fi
850     fi
851     if test -z "$GOC"; then
852     AC_CHECK_PROG(GOC, gccgo, gccgo, false)
853     fi
854     ])#m4_defun
855     ])#m4_ifndef
856    
857    
858     # _LT_LANG_DEFAULT_CONFIG
859     # -----------------------
860     m4_defun([_LT_LANG_DEFAULT_CONFIG],
861     [AC_PROVIDE_IFELSE([AC_PROG_CXX],
862     [LT_LANG(CXX)],
863     [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
864    
865     AC_PROVIDE_IFELSE([AC_PROG_F77],
866     [LT_LANG(F77)],
867     [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
868    
869     AC_PROVIDE_IFELSE([AC_PROG_FC],
870     [LT_LANG(FC)],
871     [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
872    
873     dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
874     dnl pulling things in needlessly.
875     AC_PROVIDE_IFELSE([AC_PROG_GCJ],
876     [LT_LANG(GCJ)],
877     [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
878     [LT_LANG(GCJ)],
879     [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
880     [LT_LANG(GCJ)],
881     [m4_ifdef([AC_PROG_GCJ],
882     [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
883     m4_ifdef([A][M_PROG_GCJ],
884     [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
885     m4_ifdef([LT_PROG_GCJ],
886     [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
887    
888     AC_PROVIDE_IFELSE([AC_PROG_GO],
889     [LT_LANG(GO)],
890     [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
891    
892     AC_PROVIDE_IFELSE([LT_PROG_RC],
893     [LT_LANG(RC)],
894     [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
895     ])# _LT_LANG_DEFAULT_CONFIG
896    
897     # Obsolete macros:
898     AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
899     AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
900     AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
901     AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
902     AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
903     dnl aclocal-1.4 backwards compatibility:
904     dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
905     dnl AC_DEFUN([AC_LIBTOOL_F77], [])
906     dnl AC_DEFUN([AC_LIBTOOL_FC], [])
907     dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
908     dnl AC_DEFUN([AC_LIBTOOL_RC], [])
909    
910    
911     # _LT_TAG_COMPILER
912     # ----------------
913     m4_defun([_LT_TAG_COMPILER],
914 michael 5052 [AC_REQUIRE([AC_PROG_CC])dnl
915    
916 michael 5059 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
917     _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
918     _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
919     _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
920    
921 michael 5052 # If no C compiler was specified, use CC.
922     LTCC=${LTCC-"$CC"}
923    
924     # If no C compiler flags were specified, use CFLAGS.
925     LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
926    
927     # Allow CC to be a program name with arguments.
928     compiler=$CC
929 michael 5059 ])# _LT_TAG_COMPILER
930 michael 5052
931    
932     # _LT_COMPILER_BOILERPLATE
933     # ------------------------
934     # Check for compiler boilerplate output or warnings with
935     # the simple compiler test code.
936 michael 5059 m4_defun([_LT_COMPILER_BOILERPLATE],
937     [m4_require([_LT_DECL_SED])dnl
938     ac_outfile=conftest.$ac_objext
939     echo "$lt_simple_compile_test_code" >conftest.$ac_ext
940 michael 5052 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
941     _lt_compiler_boilerplate=`cat conftest.err`
942 michael 5059 $RM conftest*
943 michael 5052 ])# _LT_COMPILER_BOILERPLATE
944    
945    
946     # _LT_LINKER_BOILERPLATE
947     # ----------------------
948     # Check for linker boilerplate output or warnings with
949     # the simple link test code.
950 michael 5059 m4_defun([_LT_LINKER_BOILERPLATE],
951     [m4_require([_LT_DECL_SED])dnl
952     ac_outfile=conftest.$ac_objext
953     echo "$lt_simple_link_test_code" >conftest.$ac_ext
954 michael 5052 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
955     _lt_linker_boilerplate=`cat conftest.err`
956 michael 5059 $RM -r conftest*
957 michael 5052 ])# _LT_LINKER_BOILERPLATE
958    
959 michael 5059 # _LT_REQUIRED_DARWIN_CHECKS
960     # -------------------------
961     m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
962     case $host_os in
963     rhapsody* | darwin*)
964     AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
965     AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
966     AC_CHECK_TOOL([LIPO], [lipo], [:])
967     AC_CHECK_TOOL([OTOOL], [otool], [:])
968     AC_CHECK_TOOL([OTOOL64], [otool64], [:])
969     _LT_DECL([], [DSYMUTIL], [1],
970     [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
971     _LT_DECL([], [NMEDIT], [1],
972     [Tool to change global to local symbols on Mac OS X])
973     _LT_DECL([], [LIPO], [1],
974     [Tool to manipulate fat objects and archives on Mac OS X])
975     _LT_DECL([], [OTOOL], [1],
976     [ldd/readelf like tool for Mach-O binaries on Mac OS X])
977     _LT_DECL([], [OTOOL64], [1],
978     [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
979 michael 5052
980 michael 5059 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
981     [lt_cv_apple_cc_single_mod=no
982     if test -z "$LT_MULTI_MODULE"; then
983     # By default we will add the -single_module flag. You can override
984     # by either setting the environment variable LT_MULTI_MODULE
985     # non-empty at configure time, or by adding -multi_module to the
986     # link flags.
987     rm -rf libconftest.dylib*
988     echo "int foo(void){return 1;}" > conftest.c
989     echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
990     -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
991     $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
992     -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
993     _lt_result=$?
994     # If there is a non-empty error log, and "single_module"
995     # appears in it, assume the flag caused a linker warning
996     if test -s conftest.err && $GREP single_module conftest.err; then
997     cat conftest.err >&AS_MESSAGE_LOG_FD
998     # Otherwise, if the output was created with a 0 exit code from
999     # the compiler, it worked.
1000     elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
1001     lt_cv_apple_cc_single_mod=yes
1002     else
1003     cat conftest.err >&AS_MESSAGE_LOG_FD
1004     fi
1005     rm -rf libconftest.dylib*
1006     rm -f conftest.*
1007     fi])
1008    
1009     AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1010     [lt_cv_ld_exported_symbols_list],
1011     [lt_cv_ld_exported_symbols_list=no
1012     save_LDFLAGS=$LDFLAGS
1013     echo "_main" > conftest.sym
1014     LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1015     AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1016     [lt_cv_ld_exported_symbols_list=yes],
1017     [lt_cv_ld_exported_symbols_list=no])
1018     LDFLAGS=$save_LDFLAGS
1019     ])
1020    
1021     AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
1022     [lt_cv_ld_force_load=no
1023     cat > conftest.c << _LT_EOF
1024     int forced_loaded() { return 2;}
1025     _LT_EOF
1026     echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1027     $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1028     echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1029     $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1030     echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1031     $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1032     cat > conftest.c << _LT_EOF
1033     int main() { return 0;}
1034     _LT_EOF
1035     echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
1036     $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
1037     _lt_result=$?
1038     if test -s conftest.err && $GREP force_load conftest.err; then
1039     cat conftest.err >&AS_MESSAGE_LOG_FD
1040     elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
1041     lt_cv_ld_force_load=yes
1042     else
1043     cat conftest.err >&AS_MESSAGE_LOG_FD
1044     fi
1045     rm -f conftest.err libconftest.a conftest conftest.c
1046     rm -rf conftest.dSYM
1047     ])
1048     case $host_os in
1049     rhapsody* | darwin1.[[012]])
1050     _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
1051     darwin1.*)
1052     _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
1053     darwin*) # darwin 5.x on
1054     # if running on 10.5 or later, the deployment target defaults
1055     # to the OS version, if on x86, and 10.4, the deployment
1056     # target defaults to 10.4. Don't you love it?
1057     case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1058     10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1059     _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
1060     10.[[012]][[,.]]*)
1061     _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
1062     10.*)
1063     _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
1064     esac
1065     ;;
1066     esac
1067     if test yes = "$lt_cv_apple_cc_single_mod"; then
1068     _lt_dar_single_mod='$single_module'
1069     fi
1070     if test yes = "$lt_cv_ld_exported_symbols_list"; then
1071     _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
1072     else
1073     _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
1074     fi
1075     if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
1076     _lt_dsymutil='~$DSYMUTIL $lib || :'
1077     else
1078     _lt_dsymutil=
1079     fi
1080     ;;
1081     esac
1082     ])
1083    
1084    
1085     # _LT_DARWIN_LINKER_FEATURES([TAG])
1086     # ---------------------------------
1087     # Checks for linker and compiler features on darwin
1088     m4_defun([_LT_DARWIN_LINKER_FEATURES],
1089     [
1090     m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1091     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1092     _LT_TAGVAR(hardcode_direct, $1)=no
1093     _LT_TAGVAR(hardcode_automatic, $1)=yes
1094     _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1095     if test yes = "$lt_cv_ld_force_load"; then
1096     _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\"`'
1097     m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
1098     [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
1099     else
1100     _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1101     fi
1102     _LT_TAGVAR(link_all_deplibs, $1)=yes
1103     _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined
1104     case $cc_basename in
1105     ifort*|nagfor*) _lt_dar_can_shared=yes ;;
1106     *) _lt_dar_can_shared=$GCC ;;
1107     esac
1108     if test yes = "$_lt_dar_can_shared"; then
1109     output_verbose_link_cmd=func_echo_all
1110     _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"
1111     _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
1112     _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"
1113     _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"
1114     m4_if([$1], [CXX],
1115     [ if test yes != "$lt_cv_apple_cc_single_mod"; then
1116     _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"
1117     _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"
1118     fi
1119     ],[])
1120     else
1121     _LT_TAGVAR(ld_shlibs, $1)=no
1122     fi
1123     ])
1124    
1125     # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
1126     # ----------------------------------
1127 michael 5052 # Links a minimal program and checks the executable
1128     # for the system default hardcoded library path. In most cases,
1129     # this is /usr/lib:/lib, but when the MPI compilers are used
1130     # the location of the communication and MPI libs are included too.
1131     # If we don't find anything, use the default library path according
1132     # to the aix ld manual.
1133 michael 5059 # Store the results from the different compilers for each TAGNAME.
1134     # Allow to override them for all tags through lt_cv_aix_libpath.
1135     m4_defun([_LT_SYS_MODULE_PATH_AIX],
1136     [m4_require([_LT_DECL_SED])dnl
1137     if test set = "${lt_cv_aix_libpath+set}"; then
1138     aix_libpath=$lt_cv_aix_libpath
1139     else
1140     AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
1141     [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
1142     lt_aix_libpath_sed='[
1143     /Import File Strings/,/^$/ {
1144     /^0/ {
1145     s/^0 *\([^ ]*\) *$/\1/
1146     p
1147     }
1148     }]'
1149     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1150     # Check for a 64-bit object if we didn't find anything.
1151     if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1152     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1153     fi],[])
1154     if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1155     _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib
1156     fi
1157     ])
1158     aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
1159     fi
1160     ])# _LT_SYS_MODULE_PATH_AIX
1161 michael 5052
1162    
1163 michael 5059 # _LT_SHELL_INIT(ARG)
1164     # -------------------
1165     m4_define([_LT_SHELL_INIT],
1166     [m4_divert_text([M4SH-INIT], [$1
1167     ])])# _LT_SHELL_INIT
1168 michael 5052
1169    
1170    
1171 michael 5059 # _LT_PROG_ECHO_BACKSLASH
1172     # -----------------------
1173     # Find how we can fake an echo command that does not interpret backslash.
1174     # In particular, with Autoconf 2.60 or later we add some code to the start
1175     # of the generated configure script that will find a shell with a builtin
1176     # printf (that we can use as an echo command).
1177     m4_defun([_LT_PROG_ECHO_BACKSLASH],
1178     [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1179     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1180     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1181 michael 5052
1182 michael 5059 AC_MSG_CHECKING([how to print strings])
1183     # Test print first, because it will be a builtin if present.
1184     if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
1185     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
1186     ECHO='print -r --'
1187     elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
1188     ECHO='printf %s\n'
1189 michael 5052 else
1190 michael 5059 # Use this function as a fallback that always works.
1191     func_fallback_echo ()
1192     {
1193     eval 'cat <<_LTECHO_EOF
1194     $[]1
1195     _LTECHO_EOF'
1196     }
1197     ECHO='func_fallback_echo'
1198 michael 5052 fi
1199    
1200 michael 5059 # func_echo_all arg...
1201     # Invoke $ECHO with all args, space-separated.
1202     func_echo_all ()
1203     {
1204     $ECHO "$*"
1205     }
1206 michael 5052
1207 michael 5059 case $ECHO in
1208     printf*) AC_MSG_RESULT([printf]) ;;
1209     print*) AC_MSG_RESULT([print -r]) ;;
1210     *) AC_MSG_RESULT([cat]) ;;
1211     esac
1212 michael 5052
1213 michael 5059 m4_ifdef([_AS_DETECT_SUGGESTED],
1214     [_AS_DETECT_SUGGESTED([
1215     test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
1216     ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1217     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1218     ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1219     PATH=/empty FPATH=/empty; export PATH FPATH
1220     test "X`printf %s $ECHO`" = "X$ECHO" \
1221     || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
1222 michael 5052
1223 michael 5059 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1224     _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1225     ])# _LT_PROG_ECHO_BACKSLASH
1226 michael 5052
1227    
1228 michael 5059 # _LT_WITH_SYSROOT
1229     # ----------------
1230     AC_DEFUN([_LT_WITH_SYSROOT],
1231     [AC_MSG_CHECKING([for sysroot])
1232     AC_ARG_WITH([sysroot],
1233     [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@],
1234     [Search for dependent libraries within DIR (or the compiler's sysroot
1235     if not specified).])],
1236     [], [with_sysroot=no])
1237 michael 5052
1238 michael 5059 dnl lt_sysroot will always be passed unquoted. We quote it here
1239     dnl in case the user passed a directory name.
1240     lt_sysroot=
1241     case $with_sysroot in #(
1242     yes)
1243     if test yes = "$GCC"; then
1244     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
1245     fi
1246     ;; #(
1247     /*)
1248     lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
1249     ;; #(
1250     no|'')
1251     ;; #(
1252     *)
1253     AC_MSG_RESULT([$with_sysroot])
1254     AC_MSG_ERROR([The sysroot must be an absolute path.])
1255     ;;
1256     esac
1257 michael 5052
1258 michael 5059 AC_MSG_RESULT([${lt_sysroot:-no}])
1259     _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
1260     [dependent libraries, and where our libraries should be installed.])])
1261 michael 5052
1262 michael 5059 # _LT_ENABLE_LOCK
1263     # ---------------
1264     m4_defun([_LT_ENABLE_LOCK],
1265 michael 5052 [AC_ARG_ENABLE([libtool-lock],
1266 michael 5059 [AS_HELP_STRING([--disable-libtool-lock],
1267     [avoid locking (might break parallel builds)])])
1268     test no = "$enable_libtool_lock" || enable_libtool_lock=yes
1269 michael 5052
1270     # Some flags need to be propagated to the compiler or linker for good
1271     # libtool support.
1272     case $host in
1273     ia64-*-hpux*)
1274 michael 5059 # Find out what ABI is being produced by ac_compile, and set mode
1275     # options accordingly.
1276 michael 5052 echo 'int i;' > conftest.$ac_ext
1277     if AC_TRY_EVAL(ac_compile); then
1278     case `/usr/bin/file conftest.$ac_objext` in
1279 michael 5059 *ELF-32*)
1280     HPUX_IA64_MODE=32
1281     ;;
1282     *ELF-64*)
1283     HPUX_IA64_MODE=64
1284     ;;
1285 michael 5052 esac
1286     fi
1287     rm -rf conftest*
1288     ;;
1289     *-*-irix6*)
1290 michael 5059 # Find out what ABI is being produced by ac_compile, and set linker
1291     # options accordingly.
1292     echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1293 michael 5052 if AC_TRY_EVAL(ac_compile); then
1294 michael 5059 if test yes = "$lt_cv_prog_gnu_ld"; then
1295     case `/usr/bin/file conftest.$ac_objext` in
1296     *32-bit*)
1297     LD="${LD-ld} -melf32bsmip"
1298     ;;
1299     *N32*)
1300     LD="${LD-ld} -melf32bmipn32"
1301     ;;
1302     *64-bit*)
1303     LD="${LD-ld} -melf64bmip"
1304     ;;
1305     esac
1306     else
1307     case `/usr/bin/file conftest.$ac_objext` in
1308     *32-bit*)
1309     LD="${LD-ld} -32"
1310     ;;
1311     *N32*)
1312     LD="${LD-ld} -n32"
1313     ;;
1314     *64-bit*)
1315     LD="${LD-ld} -64"
1316     ;;
1317     esac
1318     fi
1319     fi
1320     rm -rf conftest*
1321     ;;
1322    
1323     mips64*-*linux*)
1324     # Find out what ABI is being produced by ac_compile, and set linker
1325     # options accordingly.
1326     echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1327     if AC_TRY_EVAL(ac_compile); then
1328     emul=elf
1329 michael 5052 case `/usr/bin/file conftest.$ac_objext` in
1330 michael 5059 *32-bit*)
1331     emul="${emul}32"
1332     ;;
1333     *64-bit*)
1334     emul="${emul}64"
1335     ;;
1336 michael 5052 esac
1337     case `/usr/bin/file conftest.$ac_objext` in
1338 michael 5059 *MSB*)
1339     emul="${emul}btsmip"
1340     ;;
1341     *LSB*)
1342     emul="${emul}ltsmip"
1343     ;;
1344 michael 5052 esac
1345 michael 5059 case `/usr/bin/file conftest.$ac_objext` in
1346     *N32*)
1347     emul="${emul}n32"
1348     ;;
1349     esac
1350     LD="${LD-ld} -m $emul"
1351 michael 5052 fi
1352     rm -rf conftest*
1353     ;;
1354    
1355 michael 5059 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
1356     s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1357     # Find out what ABI is being produced by ac_compile, and set linker
1358     # options accordingly. Note that the listed cases only cover the
1359     # situations where additional linker options are needed (such as when
1360     # doing 32-bit compilation for a host where ld defaults to 64-bit, or
1361     # vice versa); the common cases where no linker options are needed do
1362     # not appear in the list.
1363 michael 5052 echo 'int i;' > conftest.$ac_ext
1364     if AC_TRY_EVAL(ac_compile); then
1365     case `/usr/bin/file conftest.o` in
1366 michael 5059 *32-bit*)
1367     case $host in
1368     x86_64-*kfreebsd*-gnu)
1369     LD="${LD-ld} -m elf_i386_fbsd"
1370     ;;
1371     x86_64-*linux*)
1372     case `/usr/bin/file conftest.o` in
1373     *x86-64*)
1374     LD="${LD-ld} -m elf32_x86_64"
1375     ;;
1376     *)
1377     LD="${LD-ld} -m elf_i386"
1378     ;;
1379     esac
1380     ;;
1381     powerpc64le-*linux*)
1382     LD="${LD-ld} -m elf32lppclinux"
1383     ;;
1384     powerpc64-*linux*)
1385     LD="${LD-ld} -m elf32ppclinux"
1386     ;;
1387     s390x-*linux*)
1388     LD="${LD-ld} -m elf_s390"
1389     ;;
1390     sparc64-*linux*)
1391     LD="${LD-ld} -m elf32_sparc"
1392     ;;
1393     esac
1394     ;;
1395     *64-bit*)
1396     case $host in
1397     x86_64-*kfreebsd*-gnu)
1398     LD="${LD-ld} -m elf_x86_64_fbsd"
1399     ;;
1400     x86_64-*linux*)
1401     LD="${LD-ld} -m elf_x86_64"
1402     ;;
1403     powerpcle-*linux*)
1404     LD="${LD-ld} -m elf64lppc"
1405     ;;
1406     powerpc-*linux*)
1407     LD="${LD-ld} -m elf64ppc"
1408     ;;
1409     s390*-*linux*|s390*-*tpf*)
1410     LD="${LD-ld} -m elf64_s390"
1411     ;;
1412     sparc*-*linux*)
1413     LD="${LD-ld} -m elf64_sparc"
1414     ;;
1415     esac
1416     ;;
1417 michael 5052 esac
1418     fi
1419     rm -rf conftest*
1420     ;;
1421    
1422     *-*-sco3.2v5*)
1423     # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1424 michael 5059 SAVE_CFLAGS=$CFLAGS
1425 michael 5052 CFLAGS="$CFLAGS -belf"
1426     AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1427     [AC_LANG_PUSH(C)
1428 michael 5059 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1429 michael 5052 AC_LANG_POP])
1430 michael 5059 if test yes != "$lt_cv_cc_needs_belf"; then
1431 michael 5052 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1432 michael 5059 CFLAGS=$SAVE_CFLAGS
1433 michael 5052 fi
1434     ;;
1435 michael 5059 *-*solaris*)
1436     # Find out what ABI is being produced by ac_compile, and set linker
1437     # options accordingly.
1438 michael 5052 echo 'int i;' > conftest.$ac_ext
1439     if AC_TRY_EVAL(ac_compile); then
1440     case `/usr/bin/file conftest.o` in
1441     *64-bit*)
1442     case $lt_cv_prog_gnu_ld in
1443 michael 5059 yes*)
1444     case $host in
1445     i?86-*-solaris*|x86_64-*-solaris*)
1446     LD="${LD-ld} -m elf_x86_64"
1447     ;;
1448     sparc*-*-solaris*)
1449     LD="${LD-ld} -m elf64_sparc"
1450     ;;
1451     esac
1452     # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
1453     if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
1454     LD=${LD-ld}_sol2
1455     fi
1456     ;;
1457     *)
1458     if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1459     LD="${LD-ld} -64"
1460     fi
1461     ;;
1462 michael 5052 esac
1463     ;;
1464     esac
1465     fi
1466     rm -rf conftest*
1467     ;;
1468 michael 5059 esac
1469 michael 5052
1470 michael 5059 need_locks=$enable_libtool_lock
1471     ])# _LT_ENABLE_LOCK
1472    
1473    
1474     # _LT_PROG_AR
1475     # -----------
1476     m4_defun([_LT_PROG_AR],
1477     [AC_CHECK_TOOLS(AR, [ar], false)
1478     : ${AR=ar}
1479     : ${AR_FLAGS=cru}
1480     _LT_DECL([], [AR], [1], [The archiver])
1481     _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
1482    
1483     AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
1484     [lt_cv_ar_at_file=no
1485     AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
1486     [echo conftest.$ac_objext > conftest.lst
1487     lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
1488     AC_TRY_EVAL([lt_ar_try])
1489     if test 0 -eq "$ac_status"; then
1490     # Ensure the archiver fails upon bogus file names.
1491     rm -f conftest.$ac_objext libconftest.a
1492     AC_TRY_EVAL([lt_ar_try])
1493     if test 0 -ne "$ac_status"; then
1494     lt_cv_ar_at_file=@
1495     fi
1496     fi
1497     rm -f conftest.* libconftest.a
1498     ])
1499 michael 5052 ])
1500    
1501 michael 5059 if test no = "$lt_cv_ar_at_file"; then
1502     archiver_list_spec=
1503     else
1504     archiver_list_spec=$lt_cv_ar_at_file
1505     fi
1506     _LT_DECL([], [archiver_list_spec], [1],
1507     [How to feed a file listing to the archiver])
1508     ])# _LT_PROG_AR
1509 michael 5052
1510    
1511 michael 5059 # _LT_CMD_OLD_ARCHIVE
1512     # -------------------
1513     m4_defun([_LT_CMD_OLD_ARCHIVE],
1514     [_LT_PROG_AR
1515 michael 5052
1516 michael 5059 AC_CHECK_TOOL(STRIP, strip, :)
1517     test -z "$STRIP" && STRIP=:
1518     _LT_DECL([], [STRIP], [1], [A symbol stripping program])
1519    
1520     AC_CHECK_TOOL(RANLIB, ranlib, :)
1521     test -z "$RANLIB" && RANLIB=:
1522     _LT_DECL([], [RANLIB], [1],
1523     [Commands used to install an old-style archive])
1524    
1525     # Determine commands to create old-style static archives.
1526     old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1527     old_postinstall_cmds='chmod 644 $oldlib'
1528     old_postuninstall_cmds=
1529    
1530     if test -n "$RANLIB"; then
1531     case $host_os in
1532     bitrig* | openbsd*)
1533     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
1534     ;;
1535     *)
1536     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
1537     ;;
1538     esac
1539     old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
1540     fi
1541    
1542     case $host_os in
1543     darwin*)
1544     lock_old_archive_extraction=yes ;;
1545     *)
1546     lock_old_archive_extraction=no ;;
1547     esac
1548     _LT_DECL([], [old_postinstall_cmds], [2])
1549     _LT_DECL([], [old_postuninstall_cmds], [2])
1550     _LT_TAGDECL([], [old_archive_cmds], [2],
1551     [Commands used to build an old-style archive])
1552     _LT_DECL([], [lock_old_archive_extraction], [0],
1553     [Whether to use a lock for old archive extraction])
1554     ])# _LT_CMD_OLD_ARCHIVE
1555    
1556    
1557     # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1558 michael 5052 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1559     # ----------------------------------------------------------------
1560     # Check whether the given compiler option works
1561 michael 5059 AC_DEFUN([_LT_COMPILER_OPTION],
1562     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1563     m4_require([_LT_DECL_SED])dnl
1564 michael 5052 AC_CACHE_CHECK([$1], [$2],
1565     [$2=no
1566 michael 5059 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1567     echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1568     lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment
1569 michael 5052 # Insert the option either (1) after the last *FLAGS variable, or
1570     # (2) before a word containing "conftest.", or (3) at the end.
1571     # Note that $ac_compile itself does not contain backslashes and begins
1572     # with a dollar sign (not a hyphen), so the echo should work correctly.
1573     # The option is referenced via a variable to avoid confusing sed.
1574     lt_compile=`echo "$ac_compile" | $SED \
1575     -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1576     -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1577     -e 's:$: $lt_compiler_flag:'`
1578 michael 5059 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1579 michael 5052 (eval "$lt_compile" 2>conftest.err)
1580     ac_status=$?
1581     cat conftest.err >&AS_MESSAGE_LOG_FD
1582 michael 5059 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1583 michael 5052 if (exit $ac_status) && test -s "$ac_outfile"; then
1584     # The compiler can only warn and ignore the option if not recognized
1585     # So say no if there are warnings other than the usual output.
1586 michael 5059 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
1587 michael 5052 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1588     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1589     $2=yes
1590     fi
1591     fi
1592 michael 5059 $RM conftest*
1593 michael 5052 ])
1594    
1595 michael 5059 if test yes = "[$]$2"; then
1596     m4_if([$5], , :, [$5])
1597 michael 5052 else
1598 michael 5059 m4_if([$6], , :, [$6])
1599 michael 5052 fi
1600 michael 5059 ])# _LT_COMPILER_OPTION
1601 michael 5052
1602 michael 5059 # Old name:
1603     AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
1604     dnl aclocal-1.4 backwards compatibility:
1605     dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
1606 michael 5052
1607 michael 5059
1608     # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1609     # [ACTION-SUCCESS], [ACTION-FAILURE])
1610     # ----------------------------------------------------
1611     # Check whether the given linker option works
1612     AC_DEFUN([_LT_LINKER_OPTION],
1613     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1614     m4_require([_LT_DECL_SED])dnl
1615     AC_CACHE_CHECK([$1], [$2],
1616 michael 5052 [$2=no
1617 michael 5059 save_LDFLAGS=$LDFLAGS
1618 michael 5052 LDFLAGS="$LDFLAGS $3"
1619 michael 5059 echo "$lt_simple_link_test_code" > conftest.$ac_ext
1620 michael 5052 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1621     # The linker can only warn and ignore the option if not recognized
1622     # So say no if there are warnings
1623     if test -s conftest.err; then
1624     # Append any errors to the config.log.
1625     cat conftest.err 1>&AS_MESSAGE_LOG_FD
1626 michael 5059 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
1627 michael 5052 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1628     if diff conftest.exp conftest.er2 >/dev/null; then
1629     $2=yes
1630     fi
1631     else
1632     $2=yes
1633     fi
1634     fi
1635 michael 5059 $RM -r conftest*
1636     LDFLAGS=$save_LDFLAGS
1637 michael 5052 ])
1638    
1639 michael 5059 if test yes = "[$]$2"; then
1640     m4_if([$4], , :, [$4])
1641 michael 5052 else
1642 michael 5059 m4_if([$5], , :, [$5])
1643 michael 5052 fi
1644 michael 5059 ])# _LT_LINKER_OPTION
1645 michael 5052
1646 michael 5059 # Old name:
1647     AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
1648     dnl aclocal-1.4 backwards compatibility:
1649     dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
1650 michael 5052
1651 michael 5059
1652     # LT_CMD_MAX_LEN
1653     #---------------
1654     AC_DEFUN([LT_CMD_MAX_LEN],
1655     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
1656     # find the maximum length of command line arguments
1657 michael 5052 AC_MSG_CHECKING([the maximum length of command line arguments])
1658     AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1659     i=0
1660 michael 5059 teststring=ABCD
1661 michael 5052
1662     case $build_os in
1663     msdosdjgpp*)
1664     # On DJGPP, this test can blow up pretty badly due to problems in libc
1665     # (any single argument exceeding 2000 bytes causes a buffer overrun
1666     # during glob expansion). Even if it were fixed, the result of this
1667     # check would be larger than it should be.
1668     lt_cv_sys_max_cmd_len=12288; # 12K is about right
1669     ;;
1670    
1671     gnu*)
1672     # Under GNU Hurd, this test is not required because there is
1673     # no limit to the length of command line arguments.
1674     # Libtool will interpret -1 as no limit whatsoever
1675     lt_cv_sys_max_cmd_len=-1;
1676     ;;
1677    
1678 michael 5059 cygwin* | mingw* | cegcc*)
1679 michael 5052 # On Win9x/ME, this test blows up -- it succeeds, but takes
1680     # about 5 minutes as the teststring grows exponentially.
1681     # Worse, since 9x/ME are not pre-emptively multitasking,
1682     # you end up with a "frozen" computer, even though with patience
1683     # the test eventually succeeds (with a max line length of 256k).
1684     # Instead, let's just punt: use the minimum linelength reported by
1685     # all of the supported platforms: 8192 (on NT/2K/XP).
1686     lt_cv_sys_max_cmd_len=8192;
1687     ;;
1688    
1689 michael 5059 mint*)
1690     # On MiNT this can take a long time and run out of memory.
1691     lt_cv_sys_max_cmd_len=8192;
1692     ;;
1693    
1694 michael 5052 amigaos*)
1695     # On AmigaOS with pdksh, this test takes hours, literally.
1696     # So we just punt and use a minimum line length of 8192.
1697     lt_cv_sys_max_cmd_len=8192;
1698     ;;
1699    
1700 michael 5059 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
1701 michael 5052 # This has been around since 386BSD, at least. Likely further.
1702     if test -x /sbin/sysctl; then
1703     lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1704     elif test -x /usr/sbin/sysctl; then
1705     lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1706     else
1707     lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1708     fi
1709     # And add a safety zone
1710     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1711     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1712     ;;
1713    
1714     interix*)
1715     # We know the value 262144 and hardcode it with a safety zone (like BSD)
1716     lt_cv_sys_max_cmd_len=196608
1717     ;;
1718    
1719 michael 5059 os2*)
1720     # The test takes a long time on OS/2.
1721     lt_cv_sys_max_cmd_len=8192
1722     ;;
1723    
1724 michael 5052 osf*)
1725     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1726     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1727     # nice to cause kernel panics so lets avoid the loop below.
1728     # First set a reasonable default.
1729     lt_cv_sys_max_cmd_len=16384
1730     #
1731     if test -x /sbin/sysconfig; then
1732     case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1733     *1*) lt_cv_sys_max_cmd_len=-1 ;;
1734     esac
1735     fi
1736     ;;
1737     sco3.2v5*)
1738     lt_cv_sys_max_cmd_len=102400
1739     ;;
1740     sysv5* | sco5v6* | sysv4.2uw2*)
1741     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1742     if test -n "$kargmax"; then
1743 michael 5059 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1744 michael 5052 else
1745     lt_cv_sys_max_cmd_len=32768
1746     fi
1747     ;;
1748     *)
1749 michael 5059 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1750     if test -n "$lt_cv_sys_max_cmd_len" && \
1751     test undefined != "$lt_cv_sys_max_cmd_len"; then
1752     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1753     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1754     else
1755     # Make teststring a little bigger before we do anything with it.
1756     # a 1K string should be a reasonable start.
1757     for i in 1 2 3 4 5 6 7 8; do
1758     teststring=$teststring$teststring
1759     done
1760     SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1761     # If test is not a shell built-in, we'll probably end up computing a
1762     # maximum length that is only half of the actual maximum length, but
1763     # we can't tell.
1764     while { test X`env echo "$teststring$teststring" 2>/dev/null` \
1765     = "X$teststring$teststring"; } >/dev/null 2>&1 &&
1766     test 17 != "$i" # 1/2 MB should be enough
1767     do
1768     i=`expr $i + 1`
1769     teststring=$teststring$teststring
1770     done
1771     # Only check the string length outside the loop.
1772     lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
1773     teststring=
1774     # Add a significant safety factor because C++ compilers can tack on
1775     # massive amounts of additional arguments before passing them to the
1776     # linker. It appears as though 1/2 is a usable value.
1777     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1778     fi
1779 michael 5052 ;;
1780     esac
1781     ])
1782 michael 5059 if test -n "$lt_cv_sys_max_cmd_len"; then
1783 michael 5052 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1784     else
1785     AC_MSG_RESULT(none)
1786     fi
1787 michael 5059 max_cmd_len=$lt_cv_sys_max_cmd_len
1788     _LT_DECL([], [max_cmd_len], [0],
1789     [What is the maximum length of a command?])
1790     ])# LT_CMD_MAX_LEN
1791 michael 5052
1792 michael 5059 # Old name:
1793     AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
1794     dnl aclocal-1.4 backwards compatibility:
1795     dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
1796 michael 5052
1797    
1798 michael 5059 # _LT_HEADER_DLFCN
1799     # ----------------
1800     m4_defun([_LT_HEADER_DLFCN],
1801     [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
1802     ])# _LT_HEADER_DLFCN
1803 michael 5052
1804 michael 5059
1805     # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1806     # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1807     # ----------------------------------------------------------------
1808     m4_defun([_LT_TRY_DLOPEN_SELF],
1809     [m4_require([_LT_HEADER_DLFCN])dnl
1810     if test yes = "$cross_compiling"; then :
1811 michael 5052 [$4]
1812     else
1813     lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1814     lt_status=$lt_dlunknown
1815 michael 5059 cat > conftest.$ac_ext <<_LT_EOF
1816     [#line $LINENO "configure"
1817 michael 5052 #include "confdefs.h"
1818    
1819     #if HAVE_DLFCN_H
1820     #include <dlfcn.h>
1821     #endif
1822    
1823     #include <stdio.h>
1824    
1825     #ifdef RTLD_GLOBAL
1826     # define LT_DLGLOBAL RTLD_GLOBAL
1827     #else
1828     # ifdef DL_GLOBAL
1829     # define LT_DLGLOBAL DL_GLOBAL
1830     # else
1831     # define LT_DLGLOBAL 0
1832     # endif
1833     #endif
1834    
1835     /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1836     find out it does not work in some platform. */
1837     #ifndef LT_DLLAZY_OR_NOW
1838     # ifdef RTLD_LAZY
1839     # define LT_DLLAZY_OR_NOW RTLD_LAZY
1840     # else
1841     # ifdef DL_LAZY
1842     # define LT_DLLAZY_OR_NOW DL_LAZY
1843     # else
1844     # ifdef RTLD_NOW
1845     # define LT_DLLAZY_OR_NOW RTLD_NOW
1846     # else
1847     # ifdef DL_NOW
1848     # define LT_DLLAZY_OR_NOW DL_NOW
1849     # else
1850     # define LT_DLLAZY_OR_NOW 0
1851     # endif
1852     # endif
1853     # endif
1854     # endif
1855     #endif
1856    
1857 michael 5059 /* When -fvisibility=hidden is used, assume the code has been annotated
1858     correspondingly for the symbols needed. */
1859     #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1860     int fnord () __attribute__((visibility("default")));
1861 michael 5052 #endif
1862    
1863 michael 5059 int fnord () { return 42; }
1864 michael 5052 int main ()
1865     {
1866     void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1867     int status = $lt_dlunknown;
1868    
1869     if (self)
1870     {
1871     if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1872 michael 5059 else
1873     {
1874     if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1875     else puts (dlerror ());
1876     }
1877 michael 5052 /* dlclose (self); */
1878     }
1879     else
1880     puts (dlerror ());
1881    
1882 michael 5059 return status;
1883 michael 5052 }]
1884 michael 5059 _LT_EOF
1885     if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then
1886 michael 5052 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1887     lt_status=$?
1888     case x$lt_status in
1889     x$lt_dlno_uscore) $1 ;;
1890     x$lt_dlneed_uscore) $2 ;;
1891     x$lt_dlunknown|x*) $3 ;;
1892     esac
1893     else :
1894     # compilation failed
1895     $3
1896     fi
1897     fi
1898     rm -fr conftest*
1899 michael 5059 ])# _LT_TRY_DLOPEN_SELF
1900 michael 5052
1901    
1902 michael 5059 # LT_SYS_DLOPEN_SELF
1903     # ------------------
1904     AC_DEFUN([LT_SYS_DLOPEN_SELF],
1905     [m4_require([_LT_HEADER_DLFCN])dnl
1906     if test yes != "$enable_dlopen"; then
1907 michael 5052 enable_dlopen=unknown
1908     enable_dlopen_self=unknown
1909     enable_dlopen_self_static=unknown
1910     else
1911     lt_cv_dlopen=no
1912     lt_cv_dlopen_libs=
1913    
1914     case $host_os in
1915     beos*)
1916 michael 5059 lt_cv_dlopen=load_add_on
1917 michael 5052 lt_cv_dlopen_libs=
1918     lt_cv_dlopen_self=yes
1919     ;;
1920    
1921 michael 5059 mingw* | pw32* | cegcc*)
1922     lt_cv_dlopen=LoadLibrary
1923 michael 5052 lt_cv_dlopen_libs=
1924 michael 5059 ;;
1925 michael 5052
1926     cygwin*)
1927 michael 5059 lt_cv_dlopen=dlopen
1928 michael 5052 lt_cv_dlopen_libs=
1929 michael 5059 ;;
1930 michael 5052
1931     darwin*)
1932 michael 5059 # if libdl is installed we need to link against it
1933 michael 5052 AC_CHECK_LIB([dl], [dlopen],
1934 michael 5059 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[
1935     lt_cv_dlopen=dyld
1936 michael 5052 lt_cv_dlopen_libs=
1937     lt_cv_dlopen_self=yes
1938     ])
1939 michael 5059 ;;
1940 michael 5052
1941 michael 5059 tpf*)
1942     # Don't try to run any link tests for TPF. We know it's impossible
1943     # because TPF is a cross-compiler, and we know how we open DSOs.
1944     lt_cv_dlopen=dlopen
1945     lt_cv_dlopen_libs=
1946     lt_cv_dlopen_self=no
1947     ;;
1948    
1949 michael 5052 *)
1950     AC_CHECK_FUNC([shl_load],
1951 michael 5059 [lt_cv_dlopen=shl_load],
1952 michael 5052 [AC_CHECK_LIB([dld], [shl_load],
1953 michael 5059 [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld],
1954 michael 5052 [AC_CHECK_FUNC([dlopen],
1955 michael 5059 [lt_cv_dlopen=dlopen],
1956 michael 5052 [AC_CHECK_LIB([dl], [dlopen],
1957 michael 5059 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],
1958 michael 5052 [AC_CHECK_LIB([svld], [dlopen],
1959 michael 5059 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld],
1960 michael 5052 [AC_CHECK_LIB([dld], [dld_link],
1961 michael 5059 [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld])
1962 michael 5052 ])
1963     ])
1964     ])
1965     ])
1966     ])
1967     ;;
1968     esac
1969    
1970 michael 5059 if test no = "$lt_cv_dlopen"; then
1971     enable_dlopen=no
1972     else
1973 michael 5052 enable_dlopen=yes
1974     fi
1975    
1976     case $lt_cv_dlopen in
1977     dlopen)
1978 michael 5059 save_CPPFLAGS=$CPPFLAGS
1979     test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1980 michael 5052
1981 michael 5059 save_LDFLAGS=$LDFLAGS
1982 michael 5052 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1983    
1984 michael 5059 save_LIBS=$LIBS
1985 michael 5052 LIBS="$lt_cv_dlopen_libs $LIBS"
1986    
1987     AC_CACHE_CHECK([whether a program can dlopen itself],
1988     lt_cv_dlopen_self, [dnl
1989 michael 5059 _LT_TRY_DLOPEN_SELF(
1990 michael 5052 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1991     lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1992     ])
1993    
1994 michael 5059 if test yes = "$lt_cv_dlopen_self"; then
1995 michael 5052 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1996     AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1997 michael 5059 lt_cv_dlopen_self_static, [dnl
1998     _LT_TRY_DLOPEN_SELF(
1999 michael 5052 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2000     lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2001     ])
2002     fi
2003    
2004 michael 5059 CPPFLAGS=$save_CPPFLAGS
2005     LDFLAGS=$save_LDFLAGS
2006     LIBS=$save_LIBS
2007 michael 5052 ;;
2008     esac
2009    
2010     case $lt_cv_dlopen_self in
2011     yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2012     *) enable_dlopen_self=unknown ;;
2013     esac
2014    
2015     case $lt_cv_dlopen_self_static in
2016     yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2017     *) enable_dlopen_self_static=unknown ;;
2018     esac
2019     fi
2020 michael 5059 _LT_DECL([dlopen_support], [enable_dlopen], [0],
2021     [Whether dlopen is supported])
2022     _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2023     [Whether dlopen of programs is supported])
2024     _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2025     [Whether dlopen of statically linked programs is supported])
2026     ])# LT_SYS_DLOPEN_SELF
2027 michael 5052
2028 michael 5059 # Old name:
2029     AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2030     dnl aclocal-1.4 backwards compatibility:
2031     dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2032 michael 5052
2033 michael 5059
2034     # _LT_COMPILER_C_O([TAGNAME])
2035     # ---------------------------
2036     # Check to see if options -c and -o are simultaneously supported by compiler.
2037     # This macro does not hard code the compiler like AC_PROG_CC_C_O.
2038     m4_defun([_LT_COMPILER_C_O],
2039     [m4_require([_LT_DECL_SED])dnl
2040     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2041     m4_require([_LT_TAG_COMPILER])dnl
2042 michael 5052 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2043 michael 5059 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2044     [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2045     $RM -r conftest 2>/dev/null
2046 michael 5052 mkdir conftest
2047     cd conftest
2048     mkdir out
2049 michael 5059 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2050 michael 5052
2051     lt_compiler_flag="-o out/conftest2.$ac_objext"
2052     # Insert the option either (1) after the last *FLAGS variable, or
2053     # (2) before a word containing "conftest.", or (3) at the end.
2054     # Note that $ac_compile itself does not contain backslashes and begins
2055     # with a dollar sign (not a hyphen), so the echo should work correctly.
2056     lt_compile=`echo "$ac_compile" | $SED \
2057     -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2058     -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2059     -e 's:$: $lt_compiler_flag:'`
2060 michael 5059 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2061 michael 5052 (eval "$lt_compile" 2>out/conftest.err)
2062     ac_status=$?
2063     cat out/conftest.err >&AS_MESSAGE_LOG_FD
2064 michael 5059 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2065 michael 5052 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2066     then
2067     # The compiler can only warn and ignore the option if not recognized
2068     # So say no if there are warnings
2069 michael 5059 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
2070 michael 5052 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2071     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2072 michael 5059 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2073 michael 5052 fi
2074     fi
2075     chmod u+w . 2>&AS_MESSAGE_LOG_FD
2076 michael 5059 $RM conftest*
2077 michael 5052 # SGI C++ compiler will create directory out/ii_files/ for
2078     # template instantiation
2079 michael 5059 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2080     $RM out/* && rmdir out
2081 michael 5052 cd ..
2082 michael 5059 $RM -r conftest
2083     $RM conftest*
2084 michael 5052 ])
2085 michael 5059 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2086     [Does compiler simultaneously support -c and -o options?])
2087     ])# _LT_COMPILER_C_O
2088 michael 5052
2089    
2090 michael 5059 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
2091     # ----------------------------------
2092 michael 5052 # Check to see if we can do hard links to lock some files if needed
2093 michael 5059 m4_defun([_LT_COMPILER_FILE_LOCKS],
2094     [m4_require([_LT_ENABLE_LOCK])dnl
2095     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2096     _LT_COMPILER_C_O([$1])
2097 michael 5052
2098 michael 5059 hard_links=nottested
2099     if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then
2100 michael 5052 # do not overwrite the value of need_locks provided by the user
2101     AC_MSG_CHECKING([if we can lock with hard links])
2102     hard_links=yes
2103 michael 5059 $RM conftest*
2104 michael 5052 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2105     touch conftest.a
2106     ln conftest.a conftest.b 2>&5 || hard_links=no
2107     ln conftest.a conftest.b 2>/dev/null && hard_links=no
2108     AC_MSG_RESULT([$hard_links])
2109 michael 5059 if test no = "$hard_links"; then
2110     AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe])
2111 michael 5052 need_locks=warn
2112     fi
2113     else
2114     need_locks=no
2115     fi
2116 michael 5059 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2117     ])# _LT_COMPILER_FILE_LOCKS
2118 michael 5052
2119    
2120 michael 5059 # _LT_CHECK_OBJDIR
2121     # ----------------
2122     m4_defun([_LT_CHECK_OBJDIR],
2123 michael 5052 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2124     [rm -f .libs 2>/dev/null
2125     mkdir .libs 2>/dev/null
2126     if test -d .libs; then
2127     lt_cv_objdir=.libs
2128     else
2129     # MS-DOS does not allow filenames that begin with a dot.
2130     lt_cv_objdir=_libs
2131     fi
2132     rmdir .libs 2>/dev/null])
2133     objdir=$lt_cv_objdir
2134 michael 5059 _LT_DECL([], [objdir], [0],
2135     [The name of the directory that contains temporary libtool files])dnl
2136     m4_pattern_allow([LT_OBJDIR])dnl
2137     AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/",
2138     [Define to the sub-directory where libtool stores uninstalled libraries.])
2139     ])# _LT_CHECK_OBJDIR
2140 michael 5052
2141    
2142 michael 5059 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2143     # --------------------------------------
2144 michael 5052 # Check hardcoding attributes.
2145 michael 5059 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2146 michael 5052 [AC_MSG_CHECKING([how to hardcode library paths into programs])
2147 michael 5059 _LT_TAGVAR(hardcode_action, $1)=
2148     if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2149     test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2150     test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then
2151 michael 5052
2152 michael 5059 # We can hardcode non-existent directories.
2153     if test no != "$_LT_TAGVAR(hardcode_direct, $1)" &&
2154 michael 5052 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2155     # have to relink, otherwise we might link with an installed library
2156     # when we should be linking with a yet-to-be-installed one
2157 michael 5059 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" &&
2158     test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then
2159 michael 5052 # Linking always hardcodes the temporary library directory.
2160 michael 5059 _LT_TAGVAR(hardcode_action, $1)=relink
2161 michael 5052 else
2162     # We can link without hardcoding, and we can hardcode nonexisting dirs.
2163 michael 5059 _LT_TAGVAR(hardcode_action, $1)=immediate
2164 michael 5052 fi
2165     else
2166     # We cannot hardcode anything, or else we can only hardcode existing
2167     # directories.
2168 michael 5059 _LT_TAGVAR(hardcode_action, $1)=unsupported
2169 michael 5052 fi
2170 michael 5059 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2171 michael 5052
2172 michael 5059 if test relink = "$_LT_TAGVAR(hardcode_action, $1)" ||
2173     test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then
2174 michael 5052 # Fast installation is not supported
2175     enable_fast_install=no
2176 michael 5059 elif test yes = "$shlibpath_overrides_runpath" ||
2177     test no = "$enable_shared"; then
2178 michael 5052 # Fast installation is not necessary
2179     enable_fast_install=needless
2180     fi
2181 michael 5059 _LT_TAGDECL([], [hardcode_action], [0],
2182     [How to hardcode a shared library path into an executable])
2183     ])# _LT_LINKER_HARDCODE_LIBPATH
2184 michael 5052
2185    
2186 michael 5059 # _LT_CMD_STRIPLIB
2187     # ----------------
2188     m4_defun([_LT_CMD_STRIPLIB],
2189     [m4_require([_LT_DECL_EGREP])
2190     striplib=
2191 michael 5052 old_striplib=
2192     AC_MSG_CHECKING([whether stripping libraries is possible])
2193 michael 5059 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2194 michael 5052 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2195     test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2196     AC_MSG_RESULT([yes])
2197     else
2198     # FIXME - insert some real tests, host_os isn't really good enough
2199     case $host_os in
2200 michael 5059 darwin*)
2201     if test -n "$STRIP"; then
2202     striplib="$STRIP -x"
2203     old_striplib="$STRIP -S"
2204     AC_MSG_RESULT([yes])
2205     else
2206     AC_MSG_RESULT([no])
2207     fi
2208 michael 5052 ;;
2209 michael 5059 *)
2210     AC_MSG_RESULT([no])
2211     ;;
2212 michael 5052 esac
2213     fi
2214 michael 5059 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2215     _LT_DECL([], [striplib], [1])
2216     ])# _LT_CMD_STRIPLIB
2217 michael 5052
2218    
2219 michael 5059 # _LT_SYS_DYNAMIC_LINKER([TAG])
2220 michael 5052 # -----------------------------
2221     # PORTME Fill in your ld.so characteristics
2222 michael 5059 m4_defun([_LT_SYS_DYNAMIC_LINKER],
2223     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2224     m4_require([_LT_DECL_EGREP])dnl
2225     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2226     m4_require([_LT_DECL_OBJDUMP])dnl
2227     m4_require([_LT_DECL_SED])dnl
2228     m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2229     AC_MSG_CHECKING([dynamic linker characteristics])
2230     m4_if([$1],
2231     [], [
2232     if test yes = "$GCC"; then
2233     case $host_os in
2234     darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
2235     *) lt_awk_arg='/^libraries:/' ;;
2236     esac
2237     case $host_os in
2238     mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;;
2239     *) lt_sed_strip_eq='s|=/|/|g' ;;
2240     esac
2241     lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
2242     case $lt_search_path_spec in
2243     *\;*)
2244     # if the path contains ";" then we assume it to be the separator
2245     # otherwise default to the standard path separator (i.e. ":") - it is
2246     # assumed that no part of a normal pathname contains ";" but that should
2247     # okay in the real world where ";" in dirpaths is itself problematic.
2248     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
2249     ;;
2250     *)
2251     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
2252     ;;
2253     esac
2254     # Ok, now we have the path, separated by spaces, we can step through it
2255     # and add multilib dir if necessary...
2256     lt_tmp_lt_search_path_spec=
2257     lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2258     # ...but if some path component already ends with the multilib dir we assume
2259     # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
2260     case "$lt_multi_os_dir; $lt_search_path_spec " in
2261     "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
2262     lt_multi_os_dir=
2263     ;;
2264     esac
2265     for lt_sys_path in $lt_search_path_spec; do
2266     if test -d "$lt_sys_path$lt_multi_os_dir"; then
2267     lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
2268     elif test -n "$lt_multi_os_dir"; then
2269     test -d "$lt_sys_path" && \
2270     lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2271     fi
2272     done
2273     lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2274     BEGIN {RS = " "; FS = "/|\n";} {
2275     lt_foo = "";
2276     lt_count = 0;
2277     for (lt_i = NF; lt_i > 0; lt_i--) {
2278     if ($lt_i != "" && $lt_i != ".") {
2279     if ($lt_i == "..") {
2280     lt_count++;
2281     } else {
2282     if (lt_count == 0) {
2283     lt_foo = "/" $lt_i lt_foo;
2284     } else {
2285     lt_count--;
2286     }
2287     }
2288     }
2289     }
2290     if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2291     if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2292     }'`
2293     # AWK program above erroneously prepends '/' to C:/dos/paths
2294     # for these hosts.
2295     case $host_os in
2296     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
2297     $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;;
2298     esac
2299     sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
2300     else
2301     sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2302     fi])
2303 michael 5052 library_names_spec=
2304     libname_spec='lib$name'
2305     soname_spec=
2306 michael 5059 shrext_cmds=.so
2307 michael 5052 postinstall_cmds=
2308     postuninstall_cmds=
2309     finish_cmds=
2310     finish_eval=
2311     shlibpath_var=
2312     shlibpath_overrides_runpath=unknown
2313     version_type=none
2314     dynamic_linker="$host_os ld.so"
2315     sys_lib_dlsearch_path_spec="/lib /usr/lib"
2316     need_lib_prefix=unknown
2317     hardcode_into_libs=no
2318    
2319     # when you set need_version to no, make sure it does not cause -set_version
2320     # flags to be left without arguments
2321     need_version=unknown
2322    
2323     case $host_os in
2324     aix3*)
2325 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
2326     library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
2327 michael 5052 shlibpath_var=LIBPATH
2328    
2329     # AIX 3 has no versioning support, so we append a major version to the name.
2330 michael 5059 soname_spec='$libname$release$shared_ext$major'
2331 michael 5052 ;;
2332    
2333 michael 5059 aix[[4-9]]*)
2334     version_type=linux # correct to gnu/linux during the next big refactor
2335 michael 5052 need_lib_prefix=no
2336     need_version=no
2337     hardcode_into_libs=yes
2338 michael 5059 if test ia64 = "$host_cpu"; then
2339 michael 5052 # AIX 5 supports IA64
2340 michael 5059 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
2341 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2342     else
2343     # With GCC up to 2.95.x, collect2 would create an import file
2344     # for dependence libraries. The import file would start with
2345 michael 5059 # the line '#! .'. This would cause the generated library to
2346     # depend on '.', always an invalid library. This was fixed in
2347 michael 5052 # development snapshots of GCC prior to 3.0.
2348     case $host_os in
2349     aix4 | aix4.[[01]] | aix4.[[01]].*)
2350     if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2351     echo ' yes '
2352 michael 5059 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
2353 michael 5052 :
2354     else
2355     can_build_shared=no
2356     fi
2357     ;;
2358     esac
2359 michael 5059 # Using Import Files as archive members, it is possible to support
2360     # filename-based versioning of shared library archives on AIX. While
2361     # this would work for both with and without runtime linking, it will
2362     # prevent static linking of such archives. So we do filename-based
2363     # shared library versioning with .so extension only, which is used
2364     # when both runtime linking and shared linking is enabled.
2365     # Unfortunately, runtime linking may impact performance, so we do
2366     # not want this to be the default eventually. Also, we use the
2367     # versioned .so libs for executables only if there is the -brtl
2368     # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
2369     # To allow for filename-based versioning support, we need to create
2370     # libNAME.so.V as an archive file, containing:
2371     # *) an Import File, referring to the versioned filename of the
2372     # archive as well as the shared archive member, telling the
2373     # bitwidth (32 or 64) of that shared object, and providing the
2374     # list of exported symbols of that shared object, eventually
2375     # decorated with the 'weak' keyword
2376     # *) the shared object with the F_LOADONLY flag set, to really avoid
2377     # it being seen by the linker.
2378     # At run time we better use the real file rather than another symlink,
2379     # but for link time we create the symlink libNAME.so -> libNAME.so.V
2380    
2381     case $with_aix_soname,$aix_use_runtimelinking in
2382     # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
2383 michael 5052 # soname into executable. Probably we can add versioning support to
2384     # collect2, so additional links can be useful in future.
2385 michael 5059 aix,yes) # traditional libtool
2386     dynamic_linker='AIX unversionable lib.so'
2387 michael 5052 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2388     # instead of lib<name>.a to let people know that these are not
2389     # typical AIX shared libraries.
2390 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2391     ;;
2392     aix,no) # traditional AIX only
2393     dynamic_linker='AIX lib.a[(]lib.so.V[)]'
2394 michael 5052 # We preserve .a as extension for shared libraries through AIX4.2
2395     # and later when we are not doing run time linking.
2396 michael 5059 library_names_spec='$libname$release.a $libname.a'
2397     soname_spec='$libname$release$shared_ext$major'
2398     ;;
2399     svr4,*) # full svr4 only
2400     dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]"
2401     library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
2402     # We do not specify a path in Import Files, so LIBPATH fires.
2403     shlibpath_overrides_runpath=yes
2404     ;;
2405     *,yes) # both, prefer svr4
2406     dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]"
2407     library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
2408     # unpreferred sharedlib libNAME.a needs extra handling
2409     postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
2410     postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
2411     # We do not specify a path in Import Files, so LIBPATH fires.
2412     shlibpath_overrides_runpath=yes
2413     ;;
2414     *,no) # both, prefer aix
2415     dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]"
2416     library_names_spec='$libname$release.a $libname.a'
2417     soname_spec='$libname$release$shared_ext$major'
2418     # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
2419     postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
2420     postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
2421     ;;
2422     esac
2423 michael 5052 shlibpath_var=LIBPATH
2424     fi
2425     ;;
2426    
2427     amigaos*)
2428 michael 5059 case $host_cpu in
2429     powerpc)
2430     # Since July 2007 AmigaOS4 officially supports .so libraries.
2431     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2432     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2433     ;;
2434     m68k)
2435     library_names_spec='$libname.ixlibrary $libname.a'
2436     # Create ${libname}_ixlibrary.a entries in /sys/libs.
2437     finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $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'
2438     ;;
2439     esac
2440 michael 5052 ;;
2441    
2442     beos*)
2443 michael 5059 library_names_spec='$libname$shared_ext'
2444 michael 5052 dynamic_linker="$host_os ld.so"
2445     shlibpath_var=LIBRARY_PATH
2446     ;;
2447    
2448     bsdi[[45]]*)
2449 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
2450 michael 5052 need_version=no
2451 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2452     soname_spec='$libname$release$shared_ext$major'
2453 michael 5052 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2454     shlibpath_var=LD_LIBRARY_PATH
2455     sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2456     sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2457     # the default ld.so.conf also contains /usr/contrib/lib and
2458     # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2459     # libtool to hard-code these into programs
2460     ;;
2461    
2462 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
2463 michael 5052 version_type=windows
2464 michael 5059 shrext_cmds=.dll
2465 michael 5052 need_version=no
2466     need_lib_prefix=no
2467    
2468 michael 5059 case $GCC,$cc_basename in
2469     yes,*)
2470     # gcc
2471 michael 5052 library_names_spec='$libname.dll.a'
2472     # DLL is installed to $(libdir)/../bin by postinstall_cmds
2473 michael 5059 postinstall_cmds='base_file=`basename \$file`~
2474     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
2475 michael 5052 dldir=$destdir/`dirname \$dlpath`~
2476     test -d \$dldir || mkdir -p \$dldir~
2477     $install_prog $dir/$dlname \$dldir/$dlname~
2478 michael 5059 chmod a+x \$dldir/$dlname~
2479     if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2480     eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2481     fi'
2482 michael 5052 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2483     dlpath=$dir/\$dldll~
2484 michael 5059 $RM \$dlpath'
2485 michael 5052 shlibpath_overrides_runpath=yes
2486    
2487     case $host_os in
2488     cygwin*)
2489     # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2490 michael 5059 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2491     m4_if([$1], [],[
2492     sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
2493 michael 5052 ;;
2494 michael 5059 mingw* | cegcc*)
2495 michael 5052 # MinGW DLLs use traditional 'lib' prefix
2496 michael 5059 soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2497 michael 5052 ;;
2498     pw32*)
2499     # pw32 DLLs use 'pw' prefix rather than 'lib'
2500 michael 5059 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2501 michael 5052 ;;
2502     esac
2503 michael 5059 dynamic_linker='Win32 ld.exe'
2504 michael 5052 ;;
2505    
2506 michael 5059 *,cl*)
2507     # Native MSVC
2508     libname_spec='$name'
2509     soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2510     library_names_spec='$libname.dll.lib'
2511    
2512     case $build_os in
2513     mingw*)
2514     sys_lib_search_path_spec=
2515     lt_save_ifs=$IFS
2516     IFS=';'
2517     for lt_path in $LIB
2518     do
2519     IFS=$lt_save_ifs
2520     # Let DOS variable expansion print the short 8.3 style file name.
2521     lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
2522     sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
2523     done
2524     IFS=$lt_save_ifs
2525     # Convert to MSYS style.
2526     sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
2527     ;;
2528     cygwin*)
2529     # Convert to unix form, then to dos form, then back to unix form
2530     # but this time dos style (no spaces!) so that the unix form looks
2531     # like /cygdrive/c/PROGRA~1:/cygdr...
2532     sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
2533     sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
2534     sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2535     ;;
2536     *)
2537     sys_lib_search_path_spec=$LIB
2538     if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2539     # It is most probably a Windows format PATH.
2540     sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2541     else
2542     sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2543     fi
2544     # FIXME: find the short name or the path components, as spaces are
2545     # common. (e.g. "Program Files" -> "PROGRA~1")
2546     ;;
2547     esac
2548    
2549     # DLL is installed to $(libdir)/../bin by postinstall_cmds
2550     postinstall_cmds='base_file=`basename \$file`~
2551     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
2552     dldir=$destdir/`dirname \$dlpath`~
2553     test -d \$dldir || mkdir -p \$dldir~
2554     $install_prog $dir/$dlname \$dldir/$dlname'
2555     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2556     dlpath=$dir/\$dldll~
2557     $RM \$dlpath'
2558     shlibpath_overrides_runpath=yes
2559     dynamic_linker='Win32 link.exe'
2560     ;;
2561    
2562 michael 5052 *)
2563 michael 5059 # Assume MSVC wrapper
2564     library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib'
2565     dynamic_linker='Win32 ld.exe'
2566 michael 5052 ;;
2567     esac
2568     # FIXME: first we should search . and the directory the executable is in
2569     shlibpath_var=PATH
2570     ;;
2571    
2572     darwin* | rhapsody*)
2573     dynamic_linker="$host_os dyld"
2574     version_type=darwin
2575     need_lib_prefix=no
2576     need_version=no
2577 michael 5059 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
2578     soname_spec='$libname$release$major$shared_ext'
2579 michael 5052 shlibpath_overrides_runpath=yes
2580     shlibpath_var=DYLD_LIBRARY_PATH
2581     shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2582 michael 5059 m4_if([$1], [],[
2583     sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2584 michael 5052 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2585     ;;
2586    
2587     dgux*)
2588 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
2589 michael 5052 need_lib_prefix=no
2590     need_version=no
2591 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2592     soname_spec='$libname$release$shared_ext$major'
2593 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2594     ;;
2595    
2596     freebsd* | dragonfly*)
2597     # DragonFly does not have aout. When/if they implement a new
2598     # versioning mechanism, adjust this.
2599     if test -x /usr/bin/objformat; then
2600     objformat=`/usr/bin/objformat`
2601     else
2602     case $host_os in
2603 michael 5059 freebsd[[23]].*) objformat=aout ;;
2604 michael 5052 *) objformat=elf ;;
2605     esac
2606     fi
2607     version_type=freebsd-$objformat
2608     case $version_type in
2609     freebsd-elf*)
2610 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2611 michael 5052 need_version=no
2612     need_lib_prefix=no
2613     ;;
2614     freebsd-*)
2615 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2616 michael 5052 need_version=yes
2617     ;;
2618     esac
2619     shlibpath_var=LD_LIBRARY_PATH
2620     case $host_os in
2621 michael 5059 freebsd2.*)
2622 michael 5052 shlibpath_overrides_runpath=yes
2623     ;;
2624     freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2625     shlibpath_overrides_runpath=yes
2626     hardcode_into_libs=yes
2627     ;;
2628     freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2629     freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2630     shlibpath_overrides_runpath=no
2631     hardcode_into_libs=yes
2632     ;;
2633 michael 5059 *) # from 4.6 on, and DragonFly
2634 michael 5052 shlibpath_overrides_runpath=yes
2635     hardcode_into_libs=yes
2636     ;;
2637     esac
2638     ;;
2639    
2640 michael 5059 haiku*)
2641     version_type=linux # correct to gnu/linux during the next big refactor
2642 michael 5052 need_lib_prefix=no
2643     need_version=no
2644 michael 5059 dynamic_linker="$host_os runtime_loader"
2645     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2646     soname_spec='$libname$release$shared_ext$major'
2647     shlibpath_var=LIBRARY_PATH
2648     shlibpath_overrides_runpath=no
2649     sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
2650 michael 5052 hardcode_into_libs=yes
2651     ;;
2652    
2653     hpux9* | hpux10* | hpux11*)
2654     # Give a soname corresponding to the major version so that dld.sl refuses to
2655     # link against other versions.
2656     version_type=sunos
2657     need_lib_prefix=no
2658     need_version=no
2659     case $host_cpu in
2660     ia64*)
2661     shrext_cmds='.so'
2662     hardcode_into_libs=yes
2663     dynamic_linker="$host_os dld.so"
2664     shlibpath_var=LD_LIBRARY_PATH
2665     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2666 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2667     soname_spec='$libname$release$shared_ext$major'
2668     if test 32 = "$HPUX_IA64_MODE"; then
2669 michael 5052 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2670     else
2671     sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2672     fi
2673     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2674     ;;
2675 michael 5059 hppa*64*)
2676 michael 5052 shrext_cmds='.sl'
2677 michael 5059 hardcode_into_libs=yes
2678 michael 5052 dynamic_linker="$host_os dld.sl"
2679 michael 5059 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2680     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2681     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2682     soname_spec='$libname$release$shared_ext$major'
2683     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2684     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2685     ;;
2686     *)
2687     shrext_cmds='.sl'
2688     dynamic_linker="$host_os dld.sl"
2689 michael 5052 shlibpath_var=SHLIB_PATH
2690     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2691 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2692     soname_spec='$libname$release$shared_ext$major'
2693 michael 5052 ;;
2694     esac
2695 michael 5059 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
2696 michael 5052 postinstall_cmds='chmod 555 $lib'
2697 michael 5059 # or fails outright, so override atomically:
2698     install_override_mode=555
2699 michael 5052 ;;
2700    
2701 michael 5059 interix[[3-9]]*)
2702     version_type=linux # correct to gnu/linux during the next big refactor
2703 michael 5052 need_lib_prefix=no
2704     need_version=no
2705 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2706     soname_spec='$libname$release$shared_ext$major'
2707 michael 5052 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2708     shlibpath_var=LD_LIBRARY_PATH
2709     shlibpath_overrides_runpath=no
2710     hardcode_into_libs=yes
2711     ;;
2712    
2713     irix5* | irix6* | nonstopux*)
2714     case $host_os in
2715     nonstopux*) version_type=nonstopux ;;
2716     *)
2717 michael 5059 if test yes = "$lt_cv_prog_gnu_ld"; then
2718     version_type=linux # correct to gnu/linux during the next big refactor
2719 michael 5052 else
2720     version_type=irix
2721     fi ;;
2722     esac
2723     need_lib_prefix=no
2724     need_version=no
2725 michael 5059 soname_spec='$libname$release$shared_ext$major'
2726     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
2727 michael 5052 case $host_os in
2728     irix5* | nonstopux*)
2729     libsuff= shlibsuff=
2730     ;;
2731     *)
2732     case $LD in # libtool.m4 will add one of these switches to LD
2733     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2734     libsuff= shlibsuff= libmagic=32-bit;;
2735     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2736     libsuff=32 shlibsuff=N32 libmagic=N32;;
2737     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2738     libsuff=64 shlibsuff=64 libmagic=64-bit;;
2739     *) libsuff= shlibsuff= libmagic=never-match;;
2740     esac
2741     ;;
2742     esac
2743     shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2744     shlibpath_overrides_runpath=no
2745 michael 5059 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
2746     sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
2747 michael 5052 hardcode_into_libs=yes
2748     ;;
2749    
2750     # No shared lib support for Linux oldld, aout, or coff.
2751     linux*oldld* | linux*aout* | linux*coff*)
2752     dynamic_linker=no
2753     ;;
2754    
2755 michael 5059 linux*android*)
2756     version_type=none # Android doesn't support versioned libraries.
2757 michael 5052 need_lib_prefix=no
2758     need_version=no
2759 michael 5059 library_names_spec='$libname$release$shared_ext'
2760     soname_spec='$libname$release$shared_ext'
2761     finish_cmds=
2762     shlibpath_var=LD_LIBRARY_PATH
2763     shlibpath_overrides_runpath=yes
2764    
2765     # This implies no fast_install, which is unacceptable.
2766     # Some rework will be needed to allow for fast_install
2767     # before this can be enabled.
2768     hardcode_into_libs=yes
2769    
2770     dynamic_linker='Android linker'
2771     # Don't embed -rpath directories since the linker doesn't support them.
2772     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
2773     ;;
2774    
2775     # This must be glibc/ELF.
2776     linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
2777     version_type=linux # correct to gnu/linux during the next big refactor
2778     need_lib_prefix=no
2779     need_version=no
2780     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2781     soname_spec='$libname$release$shared_ext$major'
2782 michael 5052 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2783     shlibpath_var=LD_LIBRARY_PATH
2784     shlibpath_overrides_runpath=no
2785 michael 5059
2786     # Some binutils ld are patched to set DT_RUNPATH
2787     AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
2788     [lt_cv_shlibpath_overrides_runpath=no
2789     save_LDFLAGS=$LDFLAGS
2790     save_libdir=$libdir
2791     eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
2792     LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
2793     AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
2794     [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
2795     [lt_cv_shlibpath_overrides_runpath=yes])])
2796     LDFLAGS=$save_LDFLAGS
2797     libdir=$save_libdir
2798     ])
2799     shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
2800    
2801 michael 5052 # This implies no fast_install, which is unacceptable.
2802     # Some rework will be needed to allow for fast_install
2803     # before this can be enabled.
2804     hardcode_into_libs=yes
2805    
2806     # Append ld.so.conf contents to the search path
2807     if test -f /etc/ld.so.conf; then
2808 michael 5059 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' ' '`
2809 michael 5052 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2810     fi
2811    
2812     # We used to test for /lib/ld.so.1 and disable shared libraries on
2813     # powerpc, because MkLinux only supported shared libraries with the
2814     # GNU dynamic linker. Since this was broken with cross compilers,
2815     # most powerpc-linux boxes support dynamic linking these days and
2816     # people can always --disable-shared, the test was removed, and we
2817     # assume the GNU/Linux dynamic linker is in use.
2818     dynamic_linker='GNU/Linux ld.so'
2819     ;;
2820    
2821     netbsd*)
2822     version_type=sunos
2823     need_lib_prefix=no
2824     need_version=no
2825 michael 5059 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2826     library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2827 michael 5052 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2828     dynamic_linker='NetBSD (a.out) ld.so'
2829     else
2830 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2831     soname_spec='$libname$release$shared_ext$major'
2832 michael 5052 dynamic_linker='NetBSD ld.elf_so'
2833     fi
2834     shlibpath_var=LD_LIBRARY_PATH
2835     shlibpath_overrides_runpath=yes
2836     hardcode_into_libs=yes
2837     ;;
2838    
2839     newsos6)
2840 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
2841     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2842 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2843     shlibpath_overrides_runpath=yes
2844     ;;
2845    
2846 michael 5059 *nto* | *qnx*)
2847     version_type=qnx
2848 michael 5052 need_lib_prefix=no
2849     need_version=no
2850 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2851     soname_spec='$libname$release$shared_ext$major'
2852 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2853 michael 5059 shlibpath_overrides_runpath=no
2854     hardcode_into_libs=yes
2855     dynamic_linker='ldqnx.so'
2856 michael 5052 ;;
2857    
2858 michael 5059 openbsd* | bitrig*)
2859 michael 5052 version_type=sunos
2860 michael 5059 sys_lib_dlsearch_path_spec=/usr/lib
2861 michael 5052 need_lib_prefix=no
2862 michael 5059 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
2863     need_version=no
2864     else
2865     need_version=yes
2866     fi
2867     library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2868 michael 5052 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2869     shlibpath_var=LD_LIBRARY_PATH
2870 michael 5059 shlibpath_overrides_runpath=yes
2871 michael 5052 ;;
2872    
2873     os2*)
2874     libname_spec='$name'
2875 michael 5059 version_type=windows
2876     shrext_cmds=.dll
2877     need_version=no
2878 michael 5052 need_lib_prefix=no
2879 michael 5059 # OS/2 can only load a DLL with a base name of 8 characters or less.
2880     soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
2881     v=$($ECHO $release$versuffix | tr -d .-);
2882     n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
2883     $ECHO $n$v`$shared_ext'
2884     library_names_spec='${libname}_dll.$libext'
2885 michael 5052 dynamic_linker='OS/2 ld.exe'
2886 michael 5059 shlibpath_var=BEGINLIBPATH
2887     sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2888     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2889     postinstall_cmds='base_file=`basename \$file`~
2890     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
2891     dldir=$destdir/`dirname \$dlpath`~
2892     test -d \$dldir || mkdir -p \$dldir~
2893     $install_prog $dir/$dlname \$dldir/$dlname~
2894     chmod a+x \$dldir/$dlname~
2895     if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2896     eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2897     fi'
2898     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
2899     dlpath=$dir/\$dldll~
2900     $RM \$dlpath'
2901 michael 5052 ;;
2902    
2903     osf3* | osf4* | osf5*)
2904     version_type=osf
2905     need_lib_prefix=no
2906     need_version=no
2907 michael 5059 soname_spec='$libname$release$shared_ext$major'
2908     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2909 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2910     sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2911 michael 5059 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2912 michael 5052 ;;
2913    
2914 michael 5059 rdos*)
2915     dynamic_linker=no
2916     ;;
2917    
2918 michael 5052 solaris*)
2919 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
2920 michael 5052 need_lib_prefix=no
2921     need_version=no
2922 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2923     soname_spec='$libname$release$shared_ext$major'
2924 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2925     shlibpath_overrides_runpath=yes
2926     hardcode_into_libs=yes
2927     # ldd complains unless libraries are executable
2928     postinstall_cmds='chmod +x $lib'
2929     ;;
2930    
2931     sunos4*)
2932     version_type=sunos
2933 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2934 michael 5052 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2935     shlibpath_var=LD_LIBRARY_PATH
2936     shlibpath_overrides_runpath=yes
2937 michael 5059 if test yes = "$with_gnu_ld"; then
2938 michael 5052 need_lib_prefix=no
2939     fi
2940     need_version=yes
2941     ;;
2942    
2943     sysv4 | sysv4.3*)
2944 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
2945     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2946     soname_spec='$libname$release$shared_ext$major'
2947 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2948     case $host_vendor in
2949     sni)
2950     shlibpath_overrides_runpath=no
2951     need_lib_prefix=no
2952     runpath_var=LD_RUN_PATH
2953     ;;
2954     siemens)
2955     need_lib_prefix=no
2956     ;;
2957     motorola)
2958     need_lib_prefix=no
2959     need_version=no
2960     shlibpath_overrides_runpath=no
2961     sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2962     ;;
2963     esac
2964     ;;
2965    
2966     sysv4*MP*)
2967 michael 5059 if test -d /usr/nec; then
2968     version_type=linux # correct to gnu/linux during the next big refactor
2969     library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
2970     soname_spec='$libname$shared_ext.$major'
2971 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2972     fi
2973     ;;
2974    
2975     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2976 michael 5059 version_type=sco
2977 michael 5052 need_lib_prefix=no
2978     need_version=no
2979 michael 5059 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
2980     soname_spec='$libname$release$shared_ext$major'
2981 michael 5052 shlibpath_var=LD_LIBRARY_PATH
2982 michael 5059 shlibpath_overrides_runpath=yes
2983 michael 5052 hardcode_into_libs=yes
2984 michael 5059 if test yes = "$with_gnu_ld"; then
2985 michael 5052 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2986     else
2987     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2988     case $host_os in
2989     sco3.2v5*)
2990     sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2991     ;;
2992     esac
2993     fi
2994     sys_lib_dlsearch_path_spec='/usr/lib'
2995     ;;
2996    
2997 michael 5059 tpf*)
2998     # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
2999     version_type=linux # correct to gnu/linux during the next big refactor
3000     need_lib_prefix=no
3001     need_version=no
3002     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3003     shlibpath_var=LD_LIBRARY_PATH
3004     shlibpath_overrides_runpath=no
3005     hardcode_into_libs=yes
3006     ;;
3007    
3008 michael 5052 uts4*)
3009 michael 5059 version_type=linux # correct to gnu/linux during the next big refactor
3010     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3011     soname_spec='$libname$release$shared_ext$major'
3012 michael 5052 shlibpath_var=LD_LIBRARY_PATH
3013     ;;
3014    
3015     *)
3016     dynamic_linker=no
3017     ;;
3018     esac
3019     AC_MSG_RESULT([$dynamic_linker])
3020 michael 5059 test no = "$dynamic_linker" && can_build_shared=no
3021 michael 5052
3022     variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3023 michael 5059 if test yes = "$GCC"; then
3024 michael 5052 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3025     fi
3026    
3027 michael 5059 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
3028     sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
3029 michael 5052 fi
3030 michael 5059 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
3031     sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
3032     fi
3033 michael 5052
3034 michael 5059 _LT_DECL([], [variables_saved_for_relink], [1],
3035     [Variables whose values should be saved in libtool wrapper scripts and
3036     restored at link time])
3037     _LT_DECL([], [need_lib_prefix], [0],
3038     [Do we need the "lib" prefix for modules?])
3039     _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3040     _LT_DECL([], [version_type], [0], [Library versioning type])
3041     _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3042     _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3043     _LT_DECL([], [shlibpath_overrides_runpath], [0],
3044     [Is shlibpath searched before the hard-coded library search path?])
3045     _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3046     _LT_DECL([], [library_names_spec], [1],
3047     [[List of archive names. First name is the real one, the rest are links.
3048     The last name is the one that the linker finds with -lNAME]])
3049     _LT_DECL([], [soname_spec], [1],
3050     [[The coded name of the library, if different from the real name]])
3051     _LT_DECL([], [install_override_mode], [1],
3052     [Permission mode override for installation of shared libraries])
3053     _LT_DECL([], [postinstall_cmds], [2],
3054     [Command to use after installation of a shared archive])
3055     _LT_DECL([], [postuninstall_cmds], [2],
3056     [Command to use after uninstallation of a shared archive])
3057     _LT_DECL([], [finish_cmds], [2],
3058     [Commands used to finish a libtool library installation in a directory])
3059     _LT_DECL([], [finish_eval], [1],
3060     [[As "finish_cmds", except a single script fragment to be evaled but
3061     not shown]])
3062     _LT_DECL([], [hardcode_into_libs], [0],
3063     [Whether we should hardcode library paths into libraries])
3064     _LT_DECL([], [sys_lib_search_path_spec], [2],
3065     [Compile-time system search path for libraries])
3066     _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3067     [Run-time system search path for libraries])
3068     ])# _LT_SYS_DYNAMIC_LINKER
3069 michael 5052
3070    
3071 michael 5059 # _LT_PATH_TOOL_PREFIX(TOOL)
3072 michael 5052 # --------------------------
3073 michael 5059 # find a file program that can recognize shared library
3074     AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3075     [m4_require([_LT_DECL_EGREP])dnl
3076 michael 5052 AC_MSG_CHECKING([for $1])
3077     AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3078     [case $MAGIC_CMD in
3079     [[\\/*] | ?:[\\/]*])
3080 michael 5059 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
3081 michael 5052 ;;
3082     *)
3083 michael 5059 lt_save_MAGIC_CMD=$MAGIC_CMD
3084     lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
3085 michael 5052 dnl $ac_dummy forces splitting on constant user-supplied paths.
3086     dnl POSIX.2 word splitting is done only on the output of word expansions,
3087     dnl not every word. This closes a longstanding sh security hole.
3088 michael 5059 ac_dummy="m4_if([$2], , $PATH, [$2])"
3089 michael 5052 for ac_dir in $ac_dummy; do
3090 michael 5059 IFS=$lt_save_ifs
3091 michael 5052 test -z "$ac_dir" && ac_dir=.
3092 michael 5059 if test -f "$ac_dir/$1"; then
3093     lt_cv_path_MAGIC_CMD=$ac_dir/"$1"
3094 michael 5052 if test -n "$file_magic_test_file"; then
3095     case $deplibs_check_method in
3096     "file_magic "*)
3097     file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3098 michael 5059 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
3099 michael 5052 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3100     $EGREP "$file_magic_regex" > /dev/null; then
3101     :
3102     else
3103 michael 5059 cat <<_LT_EOF 1>&2
3104 michael 5052
3105     *** Warning: the command libtool uses to detect shared libraries,
3106     *** $file_magic_cmd, produces output that libtool cannot recognize.
3107     *** The result is that libtool may fail to recognize shared libraries
3108     *** as such. This will affect the creation of libtool libraries that
3109     *** depend on shared libraries, but programs linked with such libtool
3110     *** libraries will work regardless of this problem. Nevertheless, you
3111     *** may want to report the problem to your system manager and/or to
3112     *** bug-libtool@gnu.org
3113    
3114 michael 5059 _LT_EOF
3115 michael 5052 fi ;;
3116     esac
3117     fi
3118     break
3119     fi
3120     done
3121 michael 5059 IFS=$lt_save_ifs
3122     MAGIC_CMD=$lt_save_MAGIC_CMD
3123 michael 5052 ;;
3124     esac])
3125 michael 5059 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
3126 michael 5052 if test -n "$MAGIC_CMD"; then
3127     AC_MSG_RESULT($MAGIC_CMD)
3128     else
3129     AC_MSG_RESULT(no)
3130     fi
3131 michael 5059 _LT_DECL([], [MAGIC_CMD], [0],
3132     [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3133     ])# _LT_PATH_TOOL_PREFIX
3134 michael 5052
3135 michael 5059 # Old name:
3136     AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3137     dnl aclocal-1.4 backwards compatibility:
3138     dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3139 michael 5052
3140 michael 5059
3141     # _LT_PATH_MAGIC
3142     # --------------
3143     # find a file program that can recognize a shared library
3144     m4_defun([_LT_PATH_MAGIC],
3145     [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3146 michael 5052 if test -z "$lt_cv_path_MAGIC_CMD"; then
3147     if test -n "$ac_tool_prefix"; then
3148 michael 5059 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3149 michael 5052 else
3150     MAGIC_CMD=:
3151     fi
3152     fi
3153 michael 5059 ])# _LT_PATH_MAGIC
3154 michael 5052
3155    
3156 michael 5059 # LT_PATH_LD
3157 michael 5052 # ----------
3158     # find the pathname to the GNU or non-GNU linker
3159 michael 5059 AC_DEFUN([LT_PATH_LD],
3160     [AC_REQUIRE([AC_PROG_CC])dnl
3161 michael 5052 AC_REQUIRE([AC_CANONICAL_HOST])dnl
3162     AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3163 michael 5059 m4_require([_LT_DECL_SED])dnl
3164     m4_require([_LT_DECL_EGREP])dnl
3165     m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
3166    
3167     AC_ARG_WITH([gnu-ld],
3168     [AS_HELP_STRING([--with-gnu-ld],
3169     [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3170     [test no = "$withval" || with_gnu_ld=yes],
3171     [with_gnu_ld=no])dnl
3172    
3173 michael 5052 ac_prog=ld
3174 michael 5059 if test yes = "$GCC"; then
3175 michael 5052 # Check if gcc -print-prog-name=ld gives a path.
3176     AC_MSG_CHECKING([for ld used by $CC])
3177     case $host in
3178     *-*-mingw*)
3179 michael 5059 # gcc leaves a trailing carriage return, which upsets mingw
3180 michael 5052 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3181     *)
3182     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3183     esac
3184     case $ac_prog in
3185     # Accept absolute paths.
3186     [[\\/]]* | ?:[[\\/]]*)
3187     re_direlt='/[[^/]][[^/]]*/\.\./'
3188     # Canonicalize the pathname of ld
3189 michael 5059 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3190     while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3191     ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3192 michael 5052 done
3193 michael 5059 test -z "$LD" && LD=$ac_prog
3194 michael 5052 ;;
3195     "")
3196     # If it fails, then pretend we aren't using GCC.
3197     ac_prog=ld
3198     ;;
3199     *)
3200     # If it is relative, then search for the first ld in PATH.
3201     with_gnu_ld=unknown
3202     ;;
3203     esac
3204 michael 5059 elif test yes = "$with_gnu_ld"; then
3205 michael 5052 AC_MSG_CHECKING([for GNU ld])
3206     else
3207     AC_MSG_CHECKING([for non-GNU ld])
3208     fi
3209     AC_CACHE_VAL(lt_cv_path_LD,
3210     [if test -z "$LD"; then
3211 michael 5059 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
3212 michael 5052 for ac_dir in $PATH; do
3213 michael 5059 IFS=$lt_save_ifs
3214 michael 5052 test -z "$ac_dir" && ac_dir=.
3215     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3216 michael 5059 lt_cv_path_LD=$ac_dir/$ac_prog
3217 michael 5052 # Check to see if the program is GNU ld. I'd rather use --version,
3218     # but apparently some variants of GNU ld only accept -v.
3219     # Break only if it was the GNU/non-GNU ld that we prefer.
3220     case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3221     *GNU* | *'with BFD'*)
3222 michael 5059 test no != "$with_gnu_ld" && break
3223 michael 5052 ;;
3224     *)
3225 michael 5059 test yes != "$with_gnu_ld" && break
3226 michael 5052 ;;
3227     esac
3228     fi
3229     done
3230 michael 5059 IFS=$lt_save_ifs
3231 michael 5052 else
3232 michael 5059 lt_cv_path_LD=$LD # Let the user override the test with a path.
3233 michael 5052 fi])
3234 michael 5059 LD=$lt_cv_path_LD
3235 michael 5052 if test -n "$LD"; then
3236     AC_MSG_RESULT($LD)
3237     else
3238     AC_MSG_RESULT(no)
3239     fi
3240     test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3241 michael 5059 _LT_PATH_LD_GNU
3242     AC_SUBST([LD])
3243 michael 5052
3244 michael 5059 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3245     ])# LT_PATH_LD
3246 michael 5052
3247 michael 5059 # Old names:
3248     AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3249     AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3250     dnl aclocal-1.4 backwards compatibility:
3251     dnl AC_DEFUN([AM_PROG_LD], [])
3252     dnl AC_DEFUN([AC_PROG_LD], [])
3253    
3254    
3255     # _LT_PATH_LD_GNU
3256     #- --------------
3257     m4_defun([_LT_PATH_LD_GNU],
3258     [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3259 michael 5052 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
3260     case `$LD -v 2>&1 </dev/null` in
3261     *GNU* | *'with BFD'*)
3262     lt_cv_prog_gnu_ld=yes
3263     ;;
3264     *)
3265     lt_cv_prog_gnu_ld=no
3266     ;;
3267     esac])
3268     with_gnu_ld=$lt_cv_prog_gnu_ld
3269 michael 5059 ])# _LT_PATH_LD_GNU
3270 michael 5052
3271    
3272 michael 5059 # _LT_CMD_RELOAD
3273     # --------------
3274 michael 5052 # find reload flag for linker
3275     # -- PORTME Some linkers may need a different reload flag.
3276 michael 5059 m4_defun([_LT_CMD_RELOAD],
3277 michael 5052 [AC_CACHE_CHECK([for $LD option to reload object files],
3278     lt_cv_ld_reload_flag,
3279     [lt_cv_ld_reload_flag='-r'])
3280     reload_flag=$lt_cv_ld_reload_flag
3281     case $reload_flag in
3282     "" | " "*) ;;
3283     *) reload_flag=" $reload_flag" ;;
3284     esac
3285     reload_cmds='$LD$reload_flag -o $output$reload_objs'
3286     case $host_os in
3287 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
3288     if test yes != "$GCC"; then
3289     reload_cmds=false
3290     fi
3291     ;;
3292 michael 5052 darwin*)
3293 michael 5059 if test yes = "$GCC"; then
3294     reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
3295 michael 5052 else
3296     reload_cmds='$LD$reload_flag -o $output$reload_objs'
3297     fi
3298     ;;
3299     esac
3300 michael 5059 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3301     _LT_TAGDECL([], [reload_cmds], [2])dnl
3302     ])# _LT_CMD_RELOAD
3303 michael 5052
3304    
3305 michael 5059 # _LT_PATH_DD
3306     # -----------
3307     # find a working dd
3308     m4_defun([_LT_PATH_DD],
3309     [AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD],
3310     [printf 0123456789abcdef0123456789abcdef >conftest.i
3311     cat conftest.i conftest.i >conftest2.i
3312     : ${lt_DD:=$DD}
3313     AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd],
3314     [if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
3315     cmp -s conftest.i conftest.out \
3316     && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
3317     fi])
3318     rm -f conftest.i conftest2.i conftest.out])
3319     ])# _LT_PATH_DD
3320    
3321    
3322     # _LT_CMD_TRUNCATE
3323     # ----------------
3324     # find command to truncate a binary pipe
3325     m4_defun([_LT_CMD_TRUNCATE],
3326     [m4_require([_LT_PATH_DD])
3327     AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin],
3328     [printf 0123456789abcdef0123456789abcdef >conftest.i
3329     cat conftest.i conftest.i >conftest2.i
3330     lt_cv_truncate_bin=
3331     if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
3332     cmp -s conftest.i conftest.out \
3333     && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
3334     fi
3335     rm -f conftest.i conftest2.i conftest.out
3336     test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"])
3337     _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1],
3338     [Command to truncate a binary pipe])
3339     ])# _LT_CMD_TRUNCATE
3340    
3341    
3342     # _LT_CHECK_MAGIC_METHOD
3343     # ----------------------
3344 michael 5052 # how to check for library dependencies
3345     # -- PORTME fill in with the dynamic library characteristics
3346 michael 5059 m4_defun([_LT_CHECK_MAGIC_METHOD],
3347     [m4_require([_LT_DECL_EGREP])
3348     m4_require([_LT_DECL_OBJDUMP])
3349     AC_CACHE_CHECK([how to recognize dependent libraries],
3350 michael 5052 lt_cv_deplibs_check_method,
3351     [lt_cv_file_magic_cmd='$MAGIC_CMD'
3352     lt_cv_file_magic_test_file=
3353     lt_cv_deplibs_check_method='unknown'
3354     # Need to set the preceding variable on all platforms that support
3355     # interlibrary dependencies.
3356     # 'none' -- dependencies not supported.
3357 michael 5059 # 'unknown' -- same as none, but documents that we really don't know.
3358 michael 5052 # 'pass_all' -- all dependencies passed with no checks.
3359     # 'test_compile' -- check by making test program.
3360     # 'file_magic [[regex]]' -- check by looking for files in library path
3361 michael 5059 # that responds to the $file_magic_cmd with a given extended regex.
3362     # If you have 'file' or equivalent on your system and you're not sure
3363     # whether 'pass_all' will *always* work, you probably want this one.
3364 michael 5052
3365     case $host_os in
3366 michael 5059 aix[[4-9]]*)
3367 michael 5052 lt_cv_deplibs_check_method=pass_all
3368     ;;
3369    
3370     beos*)
3371     lt_cv_deplibs_check_method=pass_all
3372     ;;
3373    
3374     bsdi[[45]]*)
3375     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3376     lt_cv_file_magic_cmd='/usr/bin/file -L'
3377     lt_cv_file_magic_test_file=/shlib/libc.so
3378     ;;
3379    
3380     cygwin*)
3381     # func_win32_libid is a shell function defined in ltmain.sh
3382     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3383     lt_cv_file_magic_cmd='func_win32_libid'
3384     ;;
3385    
3386     mingw* | pw32*)
3387     # Base MSYS/MinGW do not provide the 'file' command needed by
3388 michael 5059 # func_win32_libid shell function, so use a weaker test based on 'objdump',
3389     # unless we find 'file', for example because we are cross-compiling.
3390     if ( file / ) >/dev/null 2>&1; then
3391     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3392     lt_cv_file_magic_cmd='func_win32_libid'
3393     else
3394     # Keep this pattern in sync with the one in func_win32_libid.
3395     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
3396     lt_cv_file_magic_cmd='$OBJDUMP -f'
3397     fi
3398     ;;
3399    
3400     cegcc*)
3401     # use the weaker test based on 'objdump'. See mingw*.
3402     lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3403 michael 5052 lt_cv_file_magic_cmd='$OBJDUMP -f'
3404     ;;
3405    
3406     darwin* | rhapsody*)
3407     lt_cv_deplibs_check_method=pass_all
3408     ;;
3409    
3410     freebsd* | dragonfly*)
3411 michael 5059 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3412 michael 5052 case $host_cpu in
3413     i*86 )
3414     # Not sure whether the presence of OpenBSD here was a mistake.
3415     # Let's accept both of them until this is cleared up.
3416     lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3417     lt_cv_file_magic_cmd=/usr/bin/file
3418     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3419     ;;
3420     esac
3421     else
3422     lt_cv_deplibs_check_method=pass_all
3423     fi
3424     ;;
3425    
3426 michael 5059 haiku*)
3427 michael 5052 lt_cv_deplibs_check_method=pass_all
3428     ;;
3429    
3430     hpux10.20* | hpux11*)
3431     lt_cv_file_magic_cmd=/usr/bin/file
3432     case $host_cpu in
3433     ia64*)
3434     lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3435     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3436     ;;
3437     hppa*64*)
3438 michael 5059 [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]']
3439 michael 5052 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3440     ;;
3441     *)
3442 michael 5059 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
3443 michael 5052 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3444     ;;
3445     esac
3446     ;;
3447    
3448 michael 5059 interix[[3-9]]*)
3449 michael 5052 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3450     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3451     ;;
3452    
3453     irix5* | irix6* | nonstopux*)
3454     case $LD in
3455     *-32|*"-32 ") libmagic=32-bit;;
3456     *-n32|*"-n32 ") libmagic=N32;;
3457     *-64|*"-64 ") libmagic=64-bit;;
3458     *) libmagic=never-match;;
3459     esac
3460     lt_cv_deplibs_check_method=pass_all
3461     ;;
3462    
3463 michael 5059 # This must be glibc/ELF.
3464     linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3465 michael 5052 lt_cv_deplibs_check_method=pass_all
3466     ;;
3467    
3468 michael 5059 netbsd*)
3469     if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3470 michael 5052 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3471     else
3472     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3473     fi
3474     ;;
3475    
3476     newos6*)
3477     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3478     lt_cv_file_magic_cmd=/usr/bin/file
3479     lt_cv_file_magic_test_file=/usr/lib/libnls.so
3480     ;;
3481    
3482 michael 5059 *nto* | *qnx*)
3483     lt_cv_deplibs_check_method=pass_all
3484 michael 5052 ;;
3485    
3486 michael 5059 openbsd* | bitrig*)
3487     if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
3488 michael 5052 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3489     else
3490     lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3491     fi
3492     ;;
3493    
3494     osf3* | osf4* | osf5*)
3495     lt_cv_deplibs_check_method=pass_all
3496     ;;
3497    
3498 michael 5059 rdos*)
3499     lt_cv_deplibs_check_method=pass_all
3500     ;;
3501    
3502 michael 5052 solaris*)
3503     lt_cv_deplibs_check_method=pass_all
3504     ;;
3505    
3506 michael 5059 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3507     lt_cv_deplibs_check_method=pass_all
3508     ;;
3509    
3510 michael 5052 sysv4 | sysv4.3*)
3511     case $host_vendor in
3512     motorola)
3513     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]]'
3514     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3515     ;;
3516     ncr)
3517     lt_cv_deplibs_check_method=pass_all
3518     ;;
3519     sequent)
3520     lt_cv_file_magic_cmd='/bin/file'
3521     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3522     ;;
3523     sni)
3524     lt_cv_file_magic_cmd='/bin/file'
3525     lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3526     lt_cv_file_magic_test_file=/lib/libc.so
3527     ;;
3528     siemens)
3529     lt_cv_deplibs_check_method=pass_all
3530     ;;
3531     pc)
3532     lt_cv_deplibs_check_method=pass_all
3533     ;;
3534     esac
3535     ;;
3536    
3537 michael 5059 tpf*)
3538 michael 5052 lt_cv_deplibs_check_method=pass_all
3539     ;;
3540 michael 5059 os2*)
3541     lt_cv_deplibs_check_method=pass_all
3542     ;;
3543 michael 5052 esac
3544     ])
3545 michael 5059
3546     file_magic_glob=
3547     want_nocaseglob=no
3548     if test "$build" = "$host"; then
3549     case $host_os in
3550     mingw* | pw32*)
3551     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
3552     want_nocaseglob=yes
3553     else
3554     file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
3555     fi
3556     ;;
3557     esac
3558     fi
3559    
3560 michael 5052 file_magic_cmd=$lt_cv_file_magic_cmd
3561     deplibs_check_method=$lt_cv_deplibs_check_method
3562     test -z "$deplibs_check_method" && deplibs_check_method=unknown
3563    
3564 michael 5059 _LT_DECL([], [deplibs_check_method], [1],
3565     [Method to check whether dependent libraries are shared objects])
3566     _LT_DECL([], [file_magic_cmd], [1],
3567     [Command to use when deplibs_check_method = "file_magic"])
3568     _LT_DECL([], [file_magic_glob], [1],
3569     [How to find potential files when deplibs_check_method = "file_magic"])
3570     _LT_DECL([], [want_nocaseglob], [1],
3571     [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
3572     ])# _LT_CHECK_MAGIC_METHOD
3573 michael 5052
3574 michael 5059
3575     # LT_PATH_NM
3576 michael 5052 # ----------
3577 michael 5059 # find the pathname to a BSD- or MS-compatible name lister
3578     AC_DEFUN([LT_PATH_NM],
3579     [AC_REQUIRE([AC_PROG_CC])dnl
3580     AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
3581 michael 5052 [if test -n "$NM"; then
3582     # Let the user override the test.
3583 michael 5059 lt_cv_path_NM=$NM
3584 michael 5052 else
3585 michael 5059 lt_nm_to_check=${ac_tool_prefix}nm
3586     if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3587 michael 5052 lt_nm_to_check="$lt_nm_to_check nm"
3588     fi
3589     for lt_tmp_nm in $lt_nm_to_check; do
3590 michael 5059 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
3591 michael 5052 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3592 michael 5059 IFS=$lt_save_ifs
3593 michael 5052 test -z "$ac_dir" && ac_dir=.
3594 michael 5059 tmp_nm=$ac_dir/$lt_tmp_nm
3595     if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
3596 michael 5052 # Check to see if the nm accepts a BSD-compat flag.
3597 michael 5059 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
3598 michael 5052 # nm: unknown option "B" ignored
3599     # Tru64's nm complains that /dev/null is an invalid object file
3600 michael 5059 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
3601     case $build_os in
3602     mingw*) lt_bad_file=conftest.nm/nofile ;;
3603     *) lt_bad_file=/dev/null ;;
3604     esac
3605     case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
3606     *$lt_bad_file* | *'Invalid file or object type'*)
3607 michael 5052 lt_cv_path_NM="$tmp_nm -B"
3608 michael 5059 break 2
3609 michael 5052 ;;
3610     *)
3611     case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3612     */dev/null*)
3613     lt_cv_path_NM="$tmp_nm -p"
3614 michael 5059 break 2
3615 michael 5052 ;;
3616     *)
3617     lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3618     continue # so that we can try to find one that supports BSD flags
3619     ;;
3620     esac
3621     ;;
3622     esac
3623     fi
3624     done
3625 michael 5059 IFS=$lt_save_ifs
3626 michael 5052 done
3627 michael 5059 : ${lt_cv_path_NM=no}
3628 michael 5052 fi])
3629 michael 5059 if test no != "$lt_cv_path_NM"; then
3630     NM=$lt_cv_path_NM
3631     else
3632     # Didn't find any BSD compatible name lister, look for dumpbin.
3633     if test -n "$DUMPBIN"; then :
3634     # Let the user override the test.
3635 michael 5052 else
3636 michael 5059 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
3637     case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
3638     *COFF*)
3639     DUMPBIN="$DUMPBIN -symbols -headers"
3640     ;;
3641     *)
3642     DUMPBIN=:
3643     ;;
3644     esac
3645 michael 5052 fi
3646 michael 5059 AC_SUBST([DUMPBIN])
3647     if test : != "$DUMPBIN"; then
3648     NM=$DUMPBIN
3649 michael 5052 fi
3650     fi
3651 michael 5059 test -z "$NM" && NM=nm
3652     AC_SUBST([NM])
3653     _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
3654 michael 5052
3655 michael 5059 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3656     [lt_cv_nm_interface="BSD nm"
3657     echo "int some_variable = 0;" > conftest.$ac_ext
3658     (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3659     (eval "$ac_compile" 2>conftest.err)
3660     cat conftest.err >&AS_MESSAGE_LOG_FD
3661     (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3662     (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3663     cat conftest.err >&AS_MESSAGE_LOG_FD
3664     (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
3665     cat conftest.out >&AS_MESSAGE_LOG_FD
3666     if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3667     lt_cv_nm_interface="MS dumpbin"
3668 michael 5052 fi
3669 michael 5059 rm -f conftest*])
3670     ])# LT_PATH_NM
3671 michael 5052
3672 michael 5059 # Old names:
3673     AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
3674     AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
3675     dnl aclocal-1.4 backwards compatibility:
3676     dnl AC_DEFUN([AM_PROG_NM], [])
3677     dnl AC_DEFUN([AC_PROG_NM], [])
3678 michael 5052
3679 michael 5059 # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
3680     # --------------------------------
3681     # how to determine the name of the shared library
3682     # associated with a specific link library.
3683     # -- PORTME fill in with the dynamic library characteristics
3684     m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
3685     [m4_require([_LT_DECL_EGREP])
3686     m4_require([_LT_DECL_OBJDUMP])
3687     m4_require([_LT_DECL_DLLTOOL])
3688     AC_CACHE_CHECK([how to associate runtime and link libraries],
3689     lt_cv_sharedlib_from_linklib_cmd,
3690     [lt_cv_sharedlib_from_linklib_cmd='unknown'
3691 michael 5052
3692     case $host_os in
3693 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
3694     # two different shell functions defined in ltmain.sh;
3695     # decide which one to use based on capabilities of $DLLTOOL
3696     case `$DLLTOOL --help 2>&1` in
3697     *--identify-strict*)
3698     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
3699 michael 5052 ;;
3700     *)
3701 michael 5059 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
3702 michael 5052 ;;
3703     esac
3704     ;;
3705 michael 5059 *)
3706     # fallback: assume linklib IS sharedlib
3707     lt_cv_sharedlib_from_linklib_cmd=$ECHO
3708     ;;
3709 michael 5052 esac
3710     ])
3711 michael 5059 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
3712     test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
3713 michael 5052
3714 michael 5059 _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
3715     [Command to associate shared and link libraries])
3716     ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
3717 michael 5052
3718    
3719 michael 5059 # _LT_PATH_MANIFEST_TOOL
3720     # ----------------------
3721     # locate the manifest tool
3722     m4_defun([_LT_PATH_MANIFEST_TOOL],
3723     [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
3724     test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
3725     AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
3726     [lt_cv_path_mainfest_tool=no
3727     echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
3728     $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
3729     cat conftest.err >&AS_MESSAGE_LOG_FD
3730     if $GREP 'Manifest Tool' conftest.out > /dev/null; then
3731     lt_cv_path_mainfest_tool=yes
3732     fi
3733     rm -f conftest*])
3734     if test yes != "$lt_cv_path_mainfest_tool"; then
3735     MANIFEST_TOOL=:
3736     fi
3737     _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
3738     ])# _LT_PATH_MANIFEST_TOOL
3739 michael 5052
3740    
3741 michael 5059 # _LT_DLL_DEF_P([FILE])
3742     # ---------------------
3743     # True iff FILE is a Windows DLL '.def' file.
3744     # Keep in sync with func_dll_def_p in the libtool script
3745     AC_DEFUN([_LT_DLL_DEF_P],
3746     [dnl
3747     test DEF = "`$SED -n dnl
3748     -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace
3749     -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments
3750     -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl
3751     -e q dnl Only consider the first "real" line
3752     $1`" dnl
3753     ])# _LT_DLL_DEF_P
3754 michael 5052
3755    
3756 michael 5059 # LT_LIB_M
3757     # --------
3758     # check for math library
3759     AC_DEFUN([LT_LIB_M],
3760     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3761     LIBM=
3762     case $host in
3763     *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
3764     # These system don't have libm, or don't need it
3765 michael 5052 ;;
3766 michael 5059 *-ncr-sysv4.3*)
3767     AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw)
3768     AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3769 michael 5052 ;;
3770 michael 5059 *)
3771     AC_CHECK_LIB(m, cos, LIBM=-lm)
3772     ;;
3773 michael 5052 esac
3774 michael 5059 AC_SUBST([LIBM])
3775     ])# LT_LIB_M
3776 michael 5052
3777 michael 5059 # Old name:
3778     AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
3779     dnl aclocal-1.4 backwards compatibility:
3780     dnl AC_DEFUN([AC_CHECK_LIBM], [])
3781 michael 5052
3782    
3783 michael 5059 # _LT_COMPILER_NO_RTTI([TAGNAME])
3784     # -------------------------------
3785     m4_defun([_LT_COMPILER_NO_RTTI],
3786     [m4_require([_LT_TAG_COMPILER])dnl
3787 michael 5052
3788 michael 5059 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3789 michael 5052
3790 michael 5059 if test yes = "$GCC"; then
3791     case $cc_basename in
3792     nvcc*)
3793     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
3794     *)
3795     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
3796 michael 5052 esac
3797    
3798 michael 5059 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
3799 michael 5052 lt_cv_prog_compiler_rtti_exceptions,
3800     [-fno-rtti -fno-exceptions], [],
3801 michael 5059 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
3802 michael 5052 fi
3803 michael 5059 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
3804     [Compiler flag to turn off builtin functions])
3805     ])# _LT_COMPILER_NO_RTTI
3806 michael 5052
3807    
3808 michael 5059 # _LT_CMD_GLOBAL_SYMBOLS
3809     # ----------------------
3810     m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
3811     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3812     AC_REQUIRE([AC_PROG_CC])dnl
3813     AC_REQUIRE([AC_PROG_AWK])dnl
3814     AC_REQUIRE([LT_PATH_NM])dnl
3815     AC_REQUIRE([LT_PATH_LD])dnl
3816     m4_require([_LT_DECL_SED])dnl
3817     m4_require([_LT_DECL_EGREP])dnl
3818     m4_require([_LT_TAG_COMPILER])dnl
3819    
3820 michael 5052 # Check for command to grab the raw symbol name followed by C symbol from nm.
3821     AC_MSG_CHECKING([command to parse $NM output from $compiler object])
3822     AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
3823     [
3824     # These are sane defaults that work on at least a few old systems.
3825     # [They come from Ultrix. What could be older than Ultrix?!! ;)]
3826    
3827     # Character class describing NM global symbol codes.
3828     symcode='[[BCDEGRST]]'
3829    
3830     # Regexp to match symbols that can be accessed directly from C.
3831     sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
3832    
3833     # Define system-specific variables.
3834     case $host_os in
3835     aix*)
3836     symcode='[[BCDT]]'
3837     ;;
3838 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
3839 michael 5052 symcode='[[ABCDGISTW]]'
3840     ;;
3841 michael 5059 hpux*)
3842     if test ia64 = "$host_cpu"; then
3843 michael 5052 symcode='[[ABCDEGRST]]'
3844     fi
3845     ;;
3846     irix* | nonstopux*)
3847     symcode='[[BCDEGRST]]'
3848     ;;
3849     osf*)
3850     symcode='[[BCDEGQRST]]'
3851     ;;
3852     solaris*)
3853     symcode='[[BDRT]]'
3854     ;;
3855     sco3.2v5*)
3856     symcode='[[DT]]'
3857     ;;
3858     sysv4.2uw2*)
3859     symcode='[[DT]]'
3860     ;;
3861     sysv5* | sco5v6* | unixware* | OpenUNIX*)
3862     symcode='[[ABDT]]'
3863     ;;
3864     sysv4)
3865     symcode='[[DFNSTU]]'
3866     ;;
3867     esac
3868    
3869 michael 5059 # If we're using GNU nm, then use its standard symbol codes.
3870     case `$NM -V 2>&1` in
3871     *GNU* | *'with BFD'*)
3872     symcode='[[ABCDGIRSTW]]' ;;
3873     esac
3874    
3875     if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3876     # Gets list of data symbols to import.
3877     lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
3878     # Adjust the below global symbol transforms to fixup imported variables.
3879     lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
3880     lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
3881     lt_c_name_lib_hook="\
3882     -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
3883     -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
3884     else
3885     # Disable hooks by default.
3886     lt_cv_sys_global_symbol_to_import=
3887     lt_cdecl_hook=
3888     lt_c_name_hook=
3889     lt_c_name_lib_hook=
3890     fi
3891    
3892     # Transform an extracted symbol line into a proper C declaration.
3893     # Some systems (esp. on ia64) link data and code symbols differently,
3894     # so use this general approach.
3895     lt_cv_sys_global_symbol_to_cdecl="sed -n"\
3896     $lt_cdecl_hook\
3897     " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
3898     " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
3899    
3900     # Transform an extracted symbol line into symbol name and symbol address
3901     lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
3902     $lt_c_name_hook\
3903     " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
3904     " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
3905    
3906     # Transform an extracted symbol line into symbol name with lib prefix and
3907     # symbol address.
3908     lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
3909     $lt_c_name_lib_hook\
3910     " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
3911     " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
3912     " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
3913    
3914 michael 5052 # Handle CRLF in mingw tool chain
3915     opt_cr=
3916     case $build_os in
3917     mingw*)
3918 michael 5059 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
3919 michael 5052 ;;
3920     esac
3921    
3922 michael 5059 # Try without a prefix underscore, then with it.
3923 michael 5052 for ac_symprfx in "" "_"; do
3924    
3925     # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
3926     symxfrm="\\1 $ac_symprfx\\2 \\2"
3927    
3928     # Write the raw and C identifiers.
3929 michael 5059 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3930     # Fake it for dumpbin and say T for any non-static function,
3931     # D for any global variable and I for any imported variable.
3932     # Also find C++ and __fastcall symbols from MSVC++,
3933     # which start with @ or ?.
3934     lt_cv_sys_global_symbol_pipe="$AWK ['"\
3935     " {last_section=section; section=\$ 3};"\
3936     " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
3937     " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
3938     " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
3939     " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
3940     " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
3941     " \$ 0!~/External *\|/{next};"\
3942     " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
3943     " {if(hide[section]) next};"\
3944     " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
3945     " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
3946     " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
3947     " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
3948     " ' prfx=^$ac_symprfx]"
3949     else
3950     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
3951     fi
3952     lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
3953 michael 5052
3954     # Check to see that the pipe works correctly.
3955     pipe_works=no
3956    
3957     rm -f conftest*
3958 michael 5059 cat > conftest.$ac_ext <<_LT_EOF
3959 michael 5052 #ifdef __cplusplus
3960     extern "C" {
3961     #endif
3962     char nm_test_var;
3963 michael 5059 void nm_test_func(void);
3964     void nm_test_func(void){}
3965 michael 5052 #ifdef __cplusplus
3966     }
3967     #endif
3968     int main(){nm_test_var='a';nm_test_func();return(0);}
3969 michael 5059 _LT_EOF
3970 michael 5052
3971     if AC_TRY_EVAL(ac_compile); then
3972     # Now try to grab the symbols.
3973     nlist=conftest.nm
3974 michael 5059 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
3975 michael 5052 # Try sorting and uniquifying the output.
3976     if sort "$nlist" | uniq > "$nlist"T; then
3977     mv -f "$nlist"T "$nlist"
3978     else
3979     rm -f "$nlist"T
3980     fi
3981    
3982     # Make sure that we snagged all the symbols we need.
3983 michael 5059 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
3984     if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
3985     cat <<_LT_EOF > conftest.$ac_ext
3986     /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3987     #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
3988     /* DATA imports from DLLs on WIN32 can't be const, because runtime
3989     relocations are performed -- see ld's documentation on pseudo-relocs. */
3990     # define LT@&t@_DLSYM_CONST
3991     #elif defined __osf__
3992     /* This system does not cope well with relocations in const data. */
3993     # define LT@&t@_DLSYM_CONST
3994     #else
3995     # define LT@&t@_DLSYM_CONST const
3996     #endif
3997    
3998 michael 5052 #ifdef __cplusplus
3999     extern "C" {
4000     #endif
4001    
4002 michael 5059 _LT_EOF
4003 michael 5052 # Now generate the symbol file.
4004 michael 5059 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
4005 michael 5052
4006 michael 5059 cat <<_LT_EOF >> conftest.$ac_ext
4007 michael 5052
4008 michael 5059 /* The mapping between symbol names and symbols. */
4009     LT@&t@_DLSYM_CONST struct {
4010 michael 5052 const char *name;
4011 michael 5059 void *address;
4012 michael 5052 }
4013 michael 5059 lt__PROGRAM__LTX_preloaded_symbols[[]] =
4014 michael 5052 {
4015 michael 5059 { "@PROGRAM@", (void *) 0 },
4016     _LT_EOF
4017     $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4018     cat <<\_LT_EOF >> conftest.$ac_ext
4019     {0, (void *) 0}
4020 michael 5052 };
4021    
4022 michael 5059 /* This works around a problem in FreeBSD linker */
4023     #ifdef FREEBSD_WORKAROUND
4024     static const void *lt_preloaded_setup() {
4025     return lt__PROGRAM__LTX_preloaded_symbols;
4026     }
4027     #endif
4028    
4029 michael 5052 #ifdef __cplusplus
4030     }
4031     #endif
4032 michael 5059 _LT_EOF
4033 michael 5052 # Now try linking the two files.
4034     mv conftest.$ac_objext conftstm.$ac_objext
4035 michael 5059 lt_globsym_save_LIBS=$LIBS
4036     lt_globsym_save_CFLAGS=$CFLAGS
4037     LIBS=conftstm.$ac_objext
4038     CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4039     if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then
4040 michael 5052 pipe_works=yes
4041     fi
4042 michael 5059 LIBS=$lt_globsym_save_LIBS
4043     CFLAGS=$lt_globsym_save_CFLAGS
4044 michael 5052 else
4045     echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4046     fi
4047     else
4048     echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4049     fi
4050     else
4051     echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4052     fi
4053     else
4054     echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4055     cat conftest.$ac_ext >&5
4056     fi
4057 michael 5059 rm -rf conftest* conftst*
4058 michael 5052
4059     # Do not use the global_symbol_pipe unless it works.
4060 michael 5059 if test yes = "$pipe_works"; then
4061 michael 5052 break
4062     else
4063     lt_cv_sys_global_symbol_pipe=
4064     fi
4065     done
4066     ])
4067     if test -z "$lt_cv_sys_global_symbol_pipe"; then
4068     lt_cv_sys_global_symbol_to_cdecl=
4069     fi
4070     if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4071     AC_MSG_RESULT(failed)
4072     else
4073     AC_MSG_RESULT(ok)
4074     fi
4075    
4076 michael 5059 # Response file support.
4077     if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4078     nm_file_list_spec='@'
4079     elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
4080     nm_file_list_spec='@'
4081     fi
4082 michael 5052
4083 michael 5059 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
4084     [Take the output of nm and produce a listing of raw symbols and C names])
4085     _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
4086     [Transform the output of nm in a proper C declaration])
4087     _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1],
4088     [Transform the output of nm into a list of symbols to manually relocate])
4089     _LT_DECL([global_symbol_to_c_name_address],
4090     [lt_cv_sys_global_symbol_to_c_name_address], [1],
4091     [Transform the output of nm in a C name address pair])
4092     _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
4093     [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
4094     [Transform the output of nm in a C name address pair when lib prefix is needed])
4095     _LT_DECL([nm_interface], [lt_cv_nm_interface], [1],
4096     [The name lister interface])
4097     _LT_DECL([], [nm_file_list_spec], [1],
4098     [Specify filename containing input files for $NM])
4099     ]) # _LT_CMD_GLOBAL_SYMBOLS
4100 michael 5052
4101 michael 5059
4102     # _LT_COMPILER_PIC([TAGNAME])
4103     # ---------------------------
4104     m4_defun([_LT_COMPILER_PIC],
4105     [m4_require([_LT_TAG_COMPILER])dnl
4106     _LT_TAGVAR(lt_prog_compiler_wl, $1)=
4107     _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4108     _LT_TAGVAR(lt_prog_compiler_static, $1)=
4109    
4110     m4_if([$1], [CXX], [
4111 michael 5052 # C++ specific cases for pic, static, wl, etc.
4112 michael 5059 if test yes = "$GXX"; then
4113     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4114     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4115 michael 5052
4116     case $host_os in
4117     aix*)
4118     # All AIX code is PIC.
4119 michael 5059 if test ia64 = "$host_cpu"; then
4120 michael 5052 # AIX 5 now supports IA64 processor
4121 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4122 michael 5052 fi
4123 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4124 michael 5052 ;;
4125 michael 5059
4126 michael 5052 amigaos*)
4127 michael 5059 case $host_cpu in
4128     powerpc)
4129     # see comment about AmigaOS4 .so support
4130     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4131     ;;
4132     m68k)
4133     # FIXME: we need at least 68020 code to build shared libraries, but
4134     # adding the '-m68020' flag to GCC prevents building anything better,
4135     # like '-m68040'.
4136     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4137     ;;
4138     esac
4139 michael 5052 ;;
4140 michael 5059
4141     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4142 michael 5052 # PIC is the default for these OSes.
4143     ;;
4144 michael 5059 mingw* | cygwin* | os2* | pw32* | cegcc*)
4145 michael 5052 # This hack is so that the source file can tell whether it is being
4146     # built for inclusion in a dll (and should export symbols for example).
4147 michael 5059 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4148     # (--disable-auto-import) libraries
4149     m4_if([$1], [GCJ], [],
4150     [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4151     case $host_os in
4152     os2*)
4153     _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4154     ;;
4155     esac
4156 michael 5052 ;;
4157     darwin* | rhapsody*)
4158     # PIC is the default on this platform
4159     # Common symbols not allowed in MH_DYLIB files
4160 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4161 michael 5052 ;;
4162     *djgpp*)
4163     # DJGPP does not support shared libraries at all
4164 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4165 michael 5052 ;;
4166 michael 5059 haiku*)
4167     # PIC is the default for Haiku.
4168     # The "-static" flag exists, but is broken.
4169     _LT_TAGVAR(lt_prog_compiler_static, $1)=
4170     ;;
4171     interix[[3-9]]*)
4172 michael 5052 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4173     # Instead, we relocate shared libraries at runtime.
4174     ;;
4175     sysv4*MP*)
4176     if test -d /usr/nec; then
4177 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4178 michael 5052 fi
4179     ;;
4180     hpux*)
4181 michael 5059 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4182     # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4183     # sets the default TLS model and affects inlining.
4184 michael 5052 case $host_cpu in
4185 michael 5059 hppa*64*)
4186 michael 5052 ;;
4187     *)
4188 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4189 michael 5052 ;;
4190     esac
4191     ;;
4192 michael 5059 *qnx* | *nto*)
4193     # QNX uses GNU C++, but need to define -shared option too, otherwise
4194     # it will coredump.
4195     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4196     ;;
4197 michael 5052 *)
4198 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4199 michael 5052 ;;
4200     esac
4201     else
4202     case $host_os in
4203 michael 5059 aix[[4-9]]*)
4204 michael 5052 # All AIX code is PIC.
4205 michael 5059 if test ia64 = "$host_cpu"; then
4206 michael 5052 # AIX 5 now supports IA64 processor
4207 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4208 michael 5052 else
4209 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4210 michael 5052 fi
4211     ;;
4212     chorus*)
4213     case $cc_basename in
4214     cxch68*)
4215     # Green Hills C++ Compiler
4216 michael 5059 # _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"
4217 michael 5052 ;;
4218     esac
4219     ;;
4220 michael 5059 mingw* | cygwin* | os2* | pw32* | cegcc*)
4221     # This hack is so that the source file can tell whether it is being
4222     # built for inclusion in a dll (and should export symbols for example).
4223     m4_if([$1], [GCJ], [],
4224     [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4225     ;;
4226 michael 5052 dgux*)
4227     case $cc_basename in
4228     ec++*)
4229 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4230 michael 5052 ;;
4231     ghcx*)
4232     # Green Hills C++ Compiler
4233 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4234 michael 5052 ;;
4235     *)
4236     ;;
4237     esac
4238     ;;
4239     freebsd* | dragonfly*)
4240     # FreeBSD uses GNU C++
4241     ;;
4242     hpux9* | hpux10* | hpux11*)
4243     case $cc_basename in
4244     CC*)
4245 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4246     _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
4247     if test ia64 != "$host_cpu"; then
4248     _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4249 michael 5052 fi
4250     ;;
4251     aCC*)
4252 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4253     _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
4254 michael 5052 case $host_cpu in
4255     hppa*64*|ia64*)
4256     # +Z the default
4257     ;;
4258     *)
4259 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4260 michael 5052 ;;
4261     esac
4262     ;;
4263     *)
4264     ;;
4265     esac
4266     ;;
4267     interix*)
4268     # This is c89, which is MS Visual C++ (no shared libs)
4269     # Anyone wants to do a port?
4270     ;;
4271     irix5* | irix6* | nonstopux*)
4272     case $cc_basename in
4273     CC*)
4274 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4275     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4276 michael 5052 # CC pic flag -KPIC is the default.
4277     ;;
4278     *)
4279     ;;
4280     esac
4281     ;;
4282 michael 5059 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4283 michael 5052 case $cc_basename in
4284     KCC*)
4285     # KAI C++ Compiler
4286 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4287     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4288 michael 5052 ;;
4289 michael 5059 ecpc* )
4290     # old Intel C++ for x86_64, which still supported -KPIC.
4291     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4292     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4293     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4294 michael 5052 ;;
4295 michael 5059 icpc* )
4296     # Intel C++, used to be incompatible with GCC.
4297     # ICC 10 doesn't accept -KPIC any more.
4298     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4299     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4300     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4301 michael 5052 ;;
4302 michael 5059 pgCC* | pgcpp*)
4303     # Portland Group C++ compiler
4304     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4305     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4306     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4307     ;;
4308 michael 5052 cxx*)
4309     # Compaq C++
4310     # Make sure the PIC flag is empty. It appears that all Alpha
4311     # Linux and Compaq Tru64 Unix objects are PIC.
4312 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4313     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4314 michael 5052 ;;
4315 michael 5059 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
4316     # IBM XL 8.0, 9.0 on PPC and BlueGene
4317     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4318     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4319     _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4320     ;;
4321 michael 5052 *)
4322 michael 5059 case `$CC -V 2>&1 | sed 5q` in
4323     *Sun\ C*)
4324     # Sun C++ 5.9
4325     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4326     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4327     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4328     ;;
4329     esac
4330 michael 5052 ;;
4331     esac
4332     ;;
4333     lynxos*)
4334     ;;
4335     m88k*)
4336     ;;
4337     mvs*)
4338     case $cc_basename in
4339     cxx*)
4340 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4341 michael 5052 ;;
4342     *)
4343     ;;
4344     esac
4345     ;;
4346 michael 5059 netbsd*)
4347 michael 5052 ;;
4348 michael 5059 *qnx* | *nto*)
4349     # QNX uses GNU C++, but need to define -shared option too, otherwise
4350     # it will coredump.
4351     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4352     ;;
4353 michael 5052 osf3* | osf4* | osf5*)
4354     case $cc_basename in
4355     KCC*)
4356 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4357 michael 5052 ;;
4358     RCC*)
4359     # Rational C++ 2.4.1
4360 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4361 michael 5052 ;;
4362     cxx*)
4363     # Digital/Compaq C++
4364 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4365 michael 5052 # Make sure the PIC flag is empty. It appears that all Alpha
4366     # Linux and Compaq Tru64 Unix objects are PIC.
4367 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4368     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4369 michael 5052 ;;
4370     *)
4371     ;;
4372     esac
4373     ;;
4374     psos*)
4375     ;;
4376     solaris*)
4377     case $cc_basename in
4378 michael 5059 CC* | sunCC*)
4379 michael 5052 # Sun C++ 4.2, 5.x and Centerline C++
4380 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4381     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4382     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4383 michael 5052 ;;
4384     gcx*)
4385     # Green Hills C++ Compiler
4386 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4387 michael 5052 ;;
4388     *)
4389     ;;
4390     esac
4391     ;;
4392     sunos4*)
4393     case $cc_basename in
4394     CC*)
4395     # Sun C++ 4.x
4396 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4397     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4398 michael 5052 ;;
4399     lcc*)
4400     # Lucid
4401 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4402 michael 5052 ;;
4403     *)
4404     ;;
4405     esac
4406     ;;
4407 michael 5059 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4408     case $cc_basename in
4409     CC*)
4410     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4411     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4412     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4413     ;;
4414     esac
4415     ;;
4416 michael 5052 tandem*)
4417     case $cc_basename in
4418     NCC*)
4419     # NonStop-UX NCC 3.20
4420 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4421 michael 5052 ;;
4422     *)
4423     ;;
4424     esac
4425     ;;
4426     vxworks*)
4427     ;;
4428     *)
4429 michael 5059 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4430 michael 5052 ;;
4431     esac
4432     fi
4433     ],
4434     [
4435 michael 5059 if test yes = "$GCC"; then
4436     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4437     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4438 michael 5052
4439     case $host_os in
4440     aix*)
4441     # All AIX code is PIC.
4442 michael 5059 if test ia64 = "$host_cpu"; then
4443 michael 5052 # AIX 5 now supports IA64 processor
4444 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4445 michael 5052 fi
4446 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4447 michael 5052 ;;
4448    
4449     amigaos*)
4450 michael 5059 case $host_cpu in
4451     powerpc)
4452     # see comment about AmigaOS4 .so support
4453     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4454     ;;
4455     m68k)
4456     # FIXME: we need at least 68020 code to build shared libraries, but
4457     # adding the '-m68020' flag to GCC prevents building anything better,
4458     # like '-m68040'.
4459     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4460     ;;
4461     esac
4462 michael 5052 ;;
4463    
4464 michael 5059 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4465 michael 5052 # PIC is the default for these OSes.
4466     ;;
4467    
4468 michael 5059 mingw* | cygwin* | pw32* | os2* | cegcc*)
4469 michael 5052 # This hack is so that the source file can tell whether it is being
4470     # built for inclusion in a dll (and should export symbols for example).
4471 michael 5059 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4472     # (--disable-auto-import) libraries
4473     m4_if([$1], [GCJ], [],
4474     [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4475     case $host_os in
4476     os2*)
4477     _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4478     ;;
4479     esac
4480 michael 5052 ;;
4481    
4482     darwin* | rhapsody*)
4483     # PIC is the default on this platform
4484     # Common symbols not allowed in MH_DYLIB files
4485 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4486 michael 5052 ;;
4487    
4488 michael 5059 haiku*)
4489     # PIC is the default for Haiku.
4490     # The "-static" flag exists, but is broken.
4491     _LT_TAGVAR(lt_prog_compiler_static, $1)=
4492     ;;
4493    
4494     hpux*)
4495     # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
4496     # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
4497     # sets the default TLS model and affects inlining.
4498     case $host_cpu in
4499     hppa*64*)
4500     # +Z the default
4501     ;;
4502     *)
4503     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4504     ;;
4505     esac
4506     ;;
4507    
4508     interix[[3-9]]*)
4509 michael 5052 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4510     # Instead, we relocate shared libraries at runtime.
4511     ;;
4512    
4513     msdosdjgpp*)
4514     # Just because we use GCC doesn't mean we suddenly get shared libraries
4515     # on systems that don't support them.
4516 michael 5059 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4517 michael 5052 enable_shared=no
4518     ;;
4519    
4520 michael 5059 *nto* | *qnx*)
4521     # QNX uses GNU C++, but need to define -shared option too, otherwise
4522     # it will coredump.
4523     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4524     ;;
4525    
4526 michael 5052 sysv4*MP*)
4527     if test -d /usr/nec; then
4528 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4529 michael 5052 fi
4530     ;;
4531    
4532 michael 5059 *)
4533     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4534 michael 5052 ;;
4535 michael 5059 esac
4536 michael 5052
4537 michael 5059 case $cc_basename in
4538     nvcc*) # Cuda Compiler Driver 2.2
4539     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
4540     if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4541     _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
4542     fi
4543 michael 5052 ;;
4544     esac
4545     else
4546     # PORTME Check for flag to pass linker flags through the system compiler.
4547     case $host_os in
4548     aix*)
4549 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4550     if test ia64 = "$host_cpu"; then
4551 michael 5052 # AIX 5 now supports IA64 processor
4552 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4553 michael 5052 else
4554 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4555 michael 5052 fi
4556     ;;
4557    
4558 michael 5059 darwin* | rhapsody*)
4559     # PIC is the default on this platform
4560     # Common symbols not allowed in MH_DYLIB files
4561     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4562     case $cc_basename in
4563     nagfor*)
4564     # NAG Fortran compiler
4565     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
4566     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4567     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4568     ;;
4569     esac
4570     ;;
4571    
4572     mingw* | cygwin* | pw32* | os2* | cegcc*)
4573 michael 5052 # This hack is so that the source file can tell whether it is being
4574     # built for inclusion in a dll (and should export symbols for example).
4575 michael 5059 m4_if([$1], [GCJ], [],
4576     [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4577     case $host_os in
4578     os2*)
4579     _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4580     ;;
4581     esac
4582 michael 5052 ;;
4583    
4584     hpux9* | hpux10* | hpux11*)
4585 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4586 michael 5052 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4587     # not for PA HP-UX.
4588     case $host_cpu in
4589     hppa*64*|ia64*)
4590     # +Z the default
4591     ;;
4592     *)
4593 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4594 michael 5052 ;;
4595     esac
4596     # Is there a better lt_prog_compiler_static that works with the bundled CC?
4597 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
4598 michael 5052 ;;
4599    
4600     irix5* | irix6* | nonstopux*)
4601 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4602 michael 5052 # PIC (with -KPIC) is the default.
4603 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4604 michael 5052 ;;
4605    
4606 michael 5059 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4607 michael 5052 case $cc_basename in
4608 michael 5059 # old Intel for x86_64, which still supported -KPIC.
4609     ecc*)
4610     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4611     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4612     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4613 michael 5052 ;;
4614 michael 5059 # icc used to be incompatible with GCC.
4615     # ICC 10 doesn't accept -KPIC any more.
4616     icc* | ifort*)
4617     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4618     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4619     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4620     ;;
4621     # Lahey Fortran 8.1.
4622     lf95*)
4623     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4624     _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
4625     _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
4626     ;;
4627     nagfor*)
4628     # NAG Fortran compiler
4629     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
4630     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4631     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4632     ;;
4633     tcc*)
4634     # Fabrice Bellard et al's Tiny C Compiler
4635     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4636     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4637     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4638     ;;
4639     pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
4640 michael 5052 # Portland Group compilers (*not* the Pentium gcc compiler,
4641     # which looks to be a dead project)
4642 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4643     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4644     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4645 michael 5052 ;;
4646     ccc*)
4647 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4648 michael 5052 # All Alpha code is PIC.
4649 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4650 michael 5052 ;;
4651 michael 5059 xl* | bgxl* | bgf* | mpixl*)
4652     # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
4653     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4654     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4655     _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4656     ;;
4657     *)
4658     case `$CC -V 2>&1 | sed 5q` in
4659     *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
4660     # Sun Fortran 8.3 passes all unrecognized flags to the linker
4661     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4662     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4663     _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4664     ;;
4665     *Sun\ F* | *Sun*Fortran*)
4666     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4667     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4668     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4669     ;;
4670     *Sun\ C*)
4671     # Sun C 5.9
4672     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4673     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4674     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4675     ;;
4676     *Intel*\ [[CF]]*Compiler*)
4677     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4678     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4679     _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4680     ;;
4681     *Portland\ Group*)
4682     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4683     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4684     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4685     ;;
4686     esac
4687     ;;
4688 michael 5052 esac
4689     ;;
4690    
4691 michael 5059 newsos6)
4692     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4693     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4694     ;;
4695    
4696     *nto* | *qnx*)
4697     # QNX uses GNU C++, but need to define -shared option too, otherwise
4698     # it will coredump.
4699     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4700     ;;
4701    
4702 michael 5052 osf3* | osf4* | osf5*)
4703 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4704 michael 5052 # All OSF/1 code is PIC.
4705 michael 5059 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4706 michael 5052 ;;
4707    
4708 michael 5059 rdos*)
4709     _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4710     ;;
4711    
4712 michael 5052 solaris*)
4713 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4714     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4715 michael 5052 case $cc_basename in
4716 michael 5059 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
4717     _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4718 michael 5052 *)
4719 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4720 michael 5052 esac
4721     ;;
4722    
4723     sunos4*)
4724 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4725     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4726     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4727 michael 5052 ;;
4728    
4729     sysv4 | sysv4.2uw2* | sysv4.3*)
4730 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4731     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4732     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4733 michael 5052 ;;
4734    
4735     sysv4*MP*)
4736 michael 5059 if test -d /usr/nec; then
4737     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
4738     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4739 michael 5052 fi
4740     ;;
4741    
4742     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4743 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4744     _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4745     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4746 michael 5052 ;;
4747    
4748     unicos*)
4749 michael 5059 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4750     _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4751 michael 5052 ;;
4752    
4753     uts4*)
4754 michael 5059 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4755     _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4756 michael 5052 ;;
4757    
4758     *)
4759 michael 5059 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4760 michael 5052 ;;
4761     esac
4762     fi
4763     ])
4764 michael 5059 case $host_os in
4765     # For platforms that do not support PIC, -DPIC is meaningless:
4766     *djgpp*)
4767     _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4768     ;;
4769     *)
4770     _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4771     ;;
4772     esac
4773 michael 5052
4774 michael 5059 AC_CACHE_CHECK([for $compiler option to produce PIC],
4775     [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
4776     [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4777     _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
4778    
4779 michael 5052 #
4780     # Check to make sure the PIC flag actually works.
4781     #
4782 michael 5059 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4783     _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
4784     [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
4785     [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
4786     [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
4787 michael 5052 "" | " "*) ;;
4788 michael 5059 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
4789 michael 5052 esac],
4790 michael 5059 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4791     _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
4792 michael 5052 fi
4793 michael 5059 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4794     [Additional compiler flags for building library objects])
4795 michael 5052
4796 michael 5059 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4797     [How to pass a linker flag through the compiler])
4798 michael 5052 #
4799     # Check to make sure the static flag actually works.
4800     #
4801 michael 5059 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
4802     _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
4803     _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
4804 michael 5052 $lt_tmp_static_flag,
4805     [],
4806 michael 5059 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
4807     _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
4808     [Compiler flag to prevent dynamic linking])
4809     ])# _LT_COMPILER_PIC
4810 michael 5052
4811    
4812 michael 5059 # _LT_LINKER_SHLIBS([TAGNAME])
4813     # ----------------------------
4814 michael 5052 # See if the linker supports building shared libraries.
4815 michael 5059 m4_defun([_LT_LINKER_SHLIBS],
4816     [AC_REQUIRE([LT_PATH_LD])dnl
4817     AC_REQUIRE([LT_PATH_NM])dnl
4818     m4_require([_LT_PATH_MANIFEST_TOOL])dnl
4819     m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4820     m4_require([_LT_DECL_EGREP])dnl
4821     m4_require([_LT_DECL_SED])dnl
4822     m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
4823     m4_require([_LT_TAG_COMPILER])dnl
4824     AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4825     m4_if([$1], [CXX], [
4826     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4827     _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4828 michael 5052 case $host_os in
4829 michael 5059 aix[[4-9]]*)
4830 michael 5052 # If we're using GNU nm, then we don't want the "-C" option.
4831 michael 5059 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
4832     # Without the "-l" option, or with the "-B" option, AIX nm treats
4833     # weak defined symbols like other global defined symbols, whereas
4834     # GNU nm marks them as "W".
4835     # While the 'weak' keyword is ignored in the Export File, we need
4836     # it in the Import File for the 'aix-soname' feature, so we have
4837     # to replace the "-B" option with "-P" for AIX nm.
4838     if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4839     _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
4840 michael 5052 else
4841 michael 5059 _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
4842 michael 5052 fi
4843     ;;
4844     pw32*)
4845 michael 5059 _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds
4846     ;;
4847     cygwin* | mingw* | cegcc*)
4848     case $cc_basename in
4849     cl*)
4850     _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
4851     ;;
4852     *)
4853     _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'
4854     _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
4855     ;;
4856     esac
4857     ;;
4858 michael 5052 *)
4859 michael 5059 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4860     ;;
4861 michael 5052 esac
4862 michael 5059 ], [
4863 michael 5052 runpath_var=
4864 michael 5059 _LT_TAGVAR(allow_undefined_flag, $1)=
4865     _LT_TAGVAR(always_export_symbols, $1)=no
4866     _LT_TAGVAR(archive_cmds, $1)=
4867     _LT_TAGVAR(archive_expsym_cmds, $1)=
4868     _LT_TAGVAR(compiler_needs_object, $1)=no
4869     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4870     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
4871     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4872     _LT_TAGVAR(hardcode_automatic, $1)=no
4873     _LT_TAGVAR(hardcode_direct, $1)=no
4874     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
4875     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4876     _LT_TAGVAR(hardcode_libdir_separator, $1)=
4877     _LT_TAGVAR(hardcode_minus_L, $1)=no
4878     _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4879     _LT_TAGVAR(inherit_rpath, $1)=no
4880     _LT_TAGVAR(link_all_deplibs, $1)=unknown
4881     _LT_TAGVAR(module_cmds, $1)=
4882     _LT_TAGVAR(module_expsym_cmds, $1)=
4883     _LT_TAGVAR(old_archive_from_new_cmds, $1)=
4884     _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
4885     _LT_TAGVAR(thread_safe_flag_spec, $1)=
4886     _LT_TAGVAR(whole_archive_flag_spec, $1)=
4887 michael 5052 # include_expsyms should be a list of space-separated symbols to be *always*
4888     # included in the symbol list
4889 michael 5059 _LT_TAGVAR(include_expsyms, $1)=
4890 michael 5052 # exclude_expsyms can be an extended regexp of symbols to exclude
4891 michael 5059 # it will be wrapped by ' (' and ')$', so one must not match beginning or
4892     # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
4893     # as well as any symbol that contains 'd'.
4894     _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4895 michael 5052 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4896     # platforms (ab)use it in PIC code, but their linkers get confused if
4897     # the symbol is explicitly referenced. Since portable code cannot
4898     # rely on this symbol name, it's probably fine to never include it in
4899     # preloaded symbol tables.
4900 michael 5059 # Exclude shared library initialization/finalization symbols.
4901     dnl Note also adjust exclude_expsyms for C++ above.
4902 michael 5052 extract_expsyms_cmds=
4903 michael 5059
4904 michael 5052 case $host_os in
4905 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
4906 michael 5052 # FIXME: the MSVC++ port hasn't been tested in a loooong time
4907     # When not using gcc, we currently assume that we are using
4908     # Microsoft Visual C++.
4909 michael 5059 if test yes != "$GCC"; then
4910 michael 5052 with_gnu_ld=no
4911     fi
4912     ;;
4913     interix*)
4914     # we just hope/assume this is gcc and not c89 (= MSVC++)
4915     with_gnu_ld=yes
4916     ;;
4917 michael 5059 openbsd* | bitrig*)
4918 michael 5052 with_gnu_ld=no
4919     ;;
4920     esac
4921    
4922 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=yes
4923    
4924     # On some targets, GNU ld is compatible enough with the native linker
4925     # that we're better off using the native interface for both.
4926     lt_use_gnu_ld_interface=no
4927     if test yes = "$with_gnu_ld"; then
4928     case $host_os in
4929     aix*)
4930     # The AIX port of GNU ld has always aspired to compatibility
4931     # with the native linker. However, as the warning in the GNU ld
4932     # block says, versions before 2.19.5* couldn't really create working
4933     # shared libraries, regardless of the interface used.
4934     case `$LD -v 2>&1` in
4935     *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
4936     *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
4937     *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
4938     *)
4939     lt_use_gnu_ld_interface=yes
4940     ;;
4941     esac
4942     ;;
4943     *)
4944     lt_use_gnu_ld_interface=yes
4945     ;;
4946     esac
4947     fi
4948    
4949     if test yes = "$lt_use_gnu_ld_interface"; then
4950 michael 5052 # If archive_cmds runs LD, not CC, wlarc should be empty
4951 michael 5059 wlarc='$wl'
4952 michael 5052
4953     # Set some defaults for GNU ld with shared library support. These
4954     # are reset later if shared libraries are not supported. Putting them
4955     # here allows them to be overridden if necessary.
4956     runpath_var=LD_RUN_PATH
4957 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
4958     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
4959 michael 5052 # ancient GNU ld didn't support --whole-archive et. al.
4960 michael 5059 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
4961     _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
4962     else
4963     _LT_TAGVAR(whole_archive_flag_spec, $1)=
4964 michael 5052 fi
4965     supports_anon_versioning=no
4966 michael 5059 case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in
4967     *GNU\ gold*) supports_anon_versioning=yes ;;
4968 michael 5052 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
4969     *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
4970     *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
4971     *\ 2.11.*) ;; # other 2.11 versions
4972     *) supports_anon_versioning=yes ;;
4973     esac
4974    
4975     # See if GNU ld supports shared libraries.
4976     case $host_os in
4977 michael 5059 aix[[3-9]]*)
4978 michael 5052 # On AIX/PPC, the GNU linker is very broken
4979 michael 5059 if test ia64 != "$host_cpu"; then
4980     _LT_TAGVAR(ld_shlibs, $1)=no
4981     cat <<_LT_EOF 1>&2
4982 michael 5052
4983 michael 5059 *** Warning: the GNU linker, at least up to release 2.19, is reported
4984 michael 5052 *** to be unable to reliably create shared libraries on AIX.
4985     *** Therefore, libtool is disabling shared libraries support. If you
4986 michael 5059 *** really care for shared libraries, you may want to install binutils
4987     *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
4988     *** You will then need to restart the configuration process.
4989 michael 5052
4990 michael 5059 _LT_EOF
4991 michael 5052 fi
4992     ;;
4993    
4994     amigaos*)
4995 michael 5059 case $host_cpu in
4996     powerpc)
4997     # see comment about AmigaOS4 .so support
4998     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
4999     _LT_TAGVAR(archive_expsym_cmds, $1)=''
5000     ;;
5001     m68k)
5002     _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)'
5003     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5004     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5005     ;;
5006     esac
5007 michael 5052 ;;
5008    
5009     beos*)
5010 michael 5059 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5011     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5012 michael 5052 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5013     # support --undefined. This deserves some investigation. FIXME
5014 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5015 michael 5052 else
5016 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5017 michael 5052 fi
5018     ;;
5019    
5020 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
5021     # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5022 michael 5052 # as there is no search path for DLLs.
5023 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5024     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
5025     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5026     _LT_TAGVAR(always_export_symbols, $1)=no
5027     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5028     _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'
5029     _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
5030 michael 5052
5031 michael 5059 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
5032     _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'
5033     # If the export-symbols file already is a .def file, use it as
5034     # is; otherwise, prepend EXPORTS...
5035     _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
5036     cp $export_symbols $output_objdir/$soname.def;
5037     else
5038     echo EXPORTS > $output_objdir/$soname.def;
5039     cat $export_symbols >> $output_objdir/$soname.def;
5040     fi~
5041     $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5042 michael 5052 else
5043 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5044 michael 5052 fi
5045     ;;
5046    
5047 michael 5059 haiku*)
5048     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5049     _LT_TAGVAR(link_all_deplibs, $1)=yes
5050     ;;
5051    
5052     os2*)
5053     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5054     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5055     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5056     shrext_cmds=.dll
5057     _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5058     $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5059     $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5060     $ECHO EXPORTS >> $output_objdir/$libname.def~
5061     emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
5062     $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5063     emximp -o $lib $output_objdir/$libname.def'
5064     _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5065     $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5066     $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5067     $ECHO EXPORTS >> $output_objdir/$libname.def~
5068     prefix_cmds="$SED"~
5069     if test EXPORTS = "`$SED 1q $export_symbols`"; then
5070     prefix_cmds="$prefix_cmds -e 1d";
5071     fi~
5072     prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
5073     cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
5074     $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5075     emximp -o $lib $output_objdir/$libname.def'
5076     _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
5077     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5078     ;;
5079    
5080     interix[[3-9]]*)
5081     _LT_TAGVAR(hardcode_direct, $1)=no
5082     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5083     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
5084     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
5085 michael 5052 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
5086     # Instead, shared libraries are loaded at an image base (0x10000000 by
5087     # default) and relocated if they conflict, which is a slow very memory
5088     # consuming and fragmenting process. To avoid this, we pick a random,
5089     # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
5090     # time. Moving up from 0x10000000 also allows more sbrk(2) space.
5091 michael 5059 _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'
5092     _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'
5093 michael 5052 ;;
5094    
5095 michael 5059 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
5096     tmp_diet=no
5097     if test linux-dietlibc = "$host_os"; then
5098     case $cc_basename in
5099     diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
5100     esac
5101     fi
5102     if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
5103     && test no = "$tmp_diet"
5104     then
5105     tmp_addflag=' $pic_flag'
5106     tmp_sharedflag='-shared'
5107 michael 5052 case $cc_basename,$host_cpu in
5108 michael 5059 pgcc*) # Portland Group C compiler
5109     _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'
5110 michael 5052 tmp_addflag=' $pic_flag'
5111     ;;
5112 michael 5059 pgf77* | pgf90* | pgf95* | pgfortran*)
5113     # Portland Group f77 and f90 compilers
5114     _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'
5115 michael 5052 tmp_addflag=' $pic_flag -Mnomain' ;;
5116 michael 5059 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5117 michael 5052 tmp_addflag=' -i_dynamic' ;;
5118     efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5119     tmp_addflag=' -i_dynamic -nofor_main' ;;
5120     ifc* | ifort*) # Intel Fortran compiler
5121     tmp_addflag=' -nofor_main' ;;
5122 michael 5059 lf95*) # Lahey Fortran 8.1
5123     _LT_TAGVAR(whole_archive_flag_spec, $1)=
5124     tmp_sharedflag='--shared' ;;
5125     nagfor*) # NAGFOR 5.3
5126     tmp_sharedflag='-Wl,-shared' ;;
5127     xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
5128     tmp_sharedflag='-qmkshrobj'
5129     tmp_addflag= ;;
5130     nvcc*) # Cuda Compiler Driver 2.2
5131     _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'
5132     _LT_TAGVAR(compiler_needs_object, $1)=yes
5133     ;;
5134 michael 5052 esac
5135 michael 5059 case `$CC -V 2>&1 | sed 5q` in
5136     *Sun\ C*) # Sun C 5.9
5137     _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'
5138     _LT_TAGVAR(compiler_needs_object, $1)=yes
5139     tmp_sharedflag='-G' ;;
5140     *Sun\ F*) # Sun Fortran 8.3
5141     tmp_sharedflag='-G' ;;
5142     esac
5143     _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5144 michael 5052
5145 michael 5059 if test yes = "$supports_anon_versioning"; then
5146     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5147     cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5148     echo "local: *; };" >> $output_objdir/$libname.ver~
5149     $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
5150     fi
5151    
5152     case $cc_basename in
5153     tcc*)
5154     _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic'
5155     ;;
5156     xlf* | bgf* | bgxlf* | mpixlf*)
5157     # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
5158     _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
5159     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5160     _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
5161     if test yes = "$supports_anon_versioning"; then
5162     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5163     cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5164     echo "local: *; };" >> $output_objdir/$libname.ver~
5165     $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5166     fi
5167     ;;
5168     esac
5169 michael 5052 else
5170 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5171 michael 5052 fi
5172     ;;
5173    
5174 michael 5059 netbsd*)
5175     if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5176     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5177 michael 5052 wlarc=
5178     else
5179 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5180     _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'
5181 michael 5052 fi
5182     ;;
5183    
5184     solaris*)
5185 michael 5059 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
5186     _LT_TAGVAR(ld_shlibs, $1)=no
5187     cat <<_LT_EOF 1>&2
5188 michael 5052
5189     *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5190     *** create shared libraries on Solaris systems. Therefore, libtool
5191     *** is disabling shared libraries support. We urge you to upgrade GNU
5192     *** binutils to release 2.9.1 or newer. Another option is to modify
5193     *** your PATH or compiler configuration so that the native linker is
5194     *** used, and then restart.
5195    
5196 michael 5059 _LT_EOF
5197     elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5198     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5199     _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'
5200 michael 5052 else
5201 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5202 michael 5052 fi
5203     ;;
5204    
5205     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5206     case `$LD -v 2>&1` in
5207 michael 5059 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5208     _LT_TAGVAR(ld_shlibs, $1)=no
5209 michael 5052 cat <<_LT_EOF 1>&2
5210    
5211 michael 5059 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
5212 michael 5052 *** reliably create shared libraries on SCO systems. Therefore, libtool
5213     *** is disabling shared libraries support. We urge you to upgrade GNU
5214     *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5215     *** your PATH or compiler configuration so that the native linker is
5216     *** used, and then restart.
5217    
5218     _LT_EOF
5219     ;;
5220     *)
5221 michael 5059 # For security reasons, it is highly recommended that you always
5222     # use absolute paths for naming shared libraries, and exclude the
5223     # DT_RUNPATH tag from executables and libraries. But doing so
5224     # requires that you compile everything twice, which is a pain.
5225     if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5226     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5227     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5228     _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'
5229 michael 5052 else
5230 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5231 michael 5052 fi
5232     ;;
5233     esac
5234     ;;
5235    
5236     sunos4*)
5237 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5238 michael 5052 wlarc=
5239 michael 5059 _LT_TAGVAR(hardcode_direct, $1)=yes
5240     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5241 michael 5052 ;;
5242    
5243     *)
5244 michael 5059 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5245     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5246     _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'
5247 michael 5052 else
5248 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5249 michael 5052 fi
5250     ;;
5251     esac
5252    
5253 michael 5059 if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then
5254 michael 5052 runpath_var=
5255 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5256     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5257     _LT_TAGVAR(whole_archive_flag_spec, $1)=
5258 michael 5052 fi
5259     else
5260     # PORTME fill in a description of your system's linker (not GNU ld)
5261     case $host_os in
5262     aix3*)
5263 michael 5059 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5264     _LT_TAGVAR(always_export_symbols, $1)=yes
5265     _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'
5266 michael 5052 # Note: this linker hardcodes the directories in LIBPATH if there
5267     # are no directories specified by -L.
5268 michael 5059 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5269     if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
5270 michael 5052 # Neither direct hardcoding nor static linking is supported with a
5271     # broken collect2.
5272 michael 5059 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5273 michael 5052 fi
5274     ;;
5275    
5276 michael 5059 aix[[4-9]]*)
5277     if test ia64 = "$host_cpu"; then
5278 michael 5052 # On IA64, the linker does run time linking by default, so we don't
5279     # have to do anything special.
5280     aix_use_runtimelinking=no
5281     exp_sym_flag='-Bexport'
5282 michael 5059 no_entry_flag=
5283 michael 5052 else
5284     # If we're using GNU nm, then we don't want the "-C" option.
5285 michael 5059 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
5286     # Without the "-l" option, or with the "-B" option, AIX nm treats
5287     # weak defined symbols like other global defined symbols, whereas
5288     # GNU nm marks them as "W".
5289     # While the 'weak' keyword is ignored in the Export File, we need
5290     # it in the Import File for the 'aix-soname' feature, so we have
5291     # to replace the "-B" option with "-P" for AIX nm.
5292     if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5293     _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
5294 michael 5052 else
5295 michael 5059 _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
5296 michael 5052 fi
5297     aix_use_runtimelinking=no
5298    
5299     # Test if we are trying to use run time linking or normal
5300     # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5301 michael 5059 # have runtime linking enabled, and use it for executables.
5302     # For shared libraries, we enable/disable runtime linking
5303     # depending on the kind of the shared library created -
5304     # when "with_aix_soname,aix_use_runtimelinking" is:
5305     # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
5306     # "aix,yes" lib.so shared, rtl:yes, for executables
5307     # lib.a static archive
5308     # "both,no" lib.so.V(shr.o) shared, rtl:yes
5309     # lib.a(lib.so.V) shared, rtl:no, for executables
5310     # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
5311     # lib.a(lib.so.V) shared, rtl:no
5312     # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
5313     # lib.a static archive
5314     case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5315 michael 5052 for ld_flag in $LDFLAGS; do
5316 michael 5059 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
5317     aix_use_runtimelinking=yes
5318     break
5319     fi
5320 michael 5052 done
5321 michael 5059 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
5322     # With aix-soname=svr4, we create the lib.so.V shared archives only,
5323     # so we don't have lib.a shared libs to link our executables.
5324     # We have to force runtime linking in this case.
5325     aix_use_runtimelinking=yes
5326     LDFLAGS="$LDFLAGS -Wl,-brtl"
5327     fi
5328 michael 5052 ;;
5329     esac
5330    
5331     exp_sym_flag='-bexport'
5332     no_entry_flag='-bnoentry'
5333     fi
5334    
5335     # When large executables or shared objects are built, AIX ld can
5336     # have problems creating the table of contents. If linking a library
5337     # or program results in "error TOC overflow" add -mminimal-toc to
5338     # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5339     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5340    
5341 michael 5059 _LT_TAGVAR(archive_cmds, $1)=''
5342     _LT_TAGVAR(hardcode_direct, $1)=yes
5343     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5344     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5345     _LT_TAGVAR(link_all_deplibs, $1)=yes
5346     _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
5347     case $with_aix_soname,$aix_use_runtimelinking in
5348     aix,*) ;; # traditional, no import file
5349     svr4,* | *,yes) # use import file
5350     # The Import File defines what to hardcode.
5351     _LT_TAGVAR(hardcode_direct, $1)=no
5352     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5353     ;;
5354     esac
5355 michael 5052
5356 michael 5059 if test yes = "$GCC"; then
5357 michael 5052 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5358     # We only want to do this on AIX 4.2 and lower, the check
5359     # below for broken collect2 doesn't work under 4.3+
5360 michael 5059 collect2name=`$CC -print-prog-name=collect2`
5361     if test -f "$collect2name" &&
5362     strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5363 michael 5052 then
5364 michael 5059 # We have reworked collect2
5365     :
5366 michael 5052 else
5367 michael 5059 # We have old collect2
5368     _LT_TAGVAR(hardcode_direct, $1)=unsupported
5369     # It fails to find uninstalled libraries when the uninstalled
5370     # path is not listed in the libpath. Setting hardcode_minus_L
5371     # to unsupported forces relinking
5372     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5373     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5374     _LT_TAGVAR(hardcode_libdir_separator, $1)=
5375 michael 5052 fi
5376     ;;
5377     esac
5378     shared_flag='-shared'
5379 michael 5059 if test yes = "$aix_use_runtimelinking"; then
5380     shared_flag="$shared_flag "'$wl-G'
5381 michael 5052 fi
5382 michael 5059 # Need to ensure runtime linking is disabled for the traditional
5383     # shared library, or the linker may eventually find shared libraries
5384     # /with/ Import File - we do not want to mix them.
5385     shared_flag_aix='-shared'
5386     shared_flag_svr4='-shared $wl-G'
5387 michael 5052 else
5388     # not using gcc
5389 michael 5059 if test ia64 = "$host_cpu"; then
5390     # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5391     # chokes on -Wl,-G. The following line is correct:
5392 michael 5052 shared_flag='-G'
5393     else
5394 michael 5059 if test yes = "$aix_use_runtimelinking"; then
5395     shared_flag='$wl-G'
5396 michael 5052 else
5397 michael 5059 shared_flag='$wl-bM:SRE'
5398 michael 5052 fi
5399 michael 5059 shared_flag_aix='$wl-bM:SRE'
5400     shared_flag_svr4='$wl-G'
5401 michael 5052 fi
5402     fi
5403    
5404 michael 5059 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
5405 michael 5052 # It seems that -bexpall does not export symbols beginning with
5406     # underscore (_), so it is better to generate a list of symbols to export.
5407 michael 5059 _LT_TAGVAR(always_export_symbols, $1)=yes
5408     if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
5409 michael 5052 # Warning - without using the other runtime loading flags (-brtl),
5410     # -berok will link without error, but may produce a broken library.
5411 michael 5059 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5412     # Determine the default libpath from the value encoded in an
5413     # empty executable.
5414     _LT_SYS_MODULE_PATH_AIX([$1])
5415     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
5416     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
5417     else
5418     if test ia64 = "$host_cpu"; then
5419     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
5420     _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5421     _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"
5422 michael 5052 else
5423 michael 5059 # Determine the default libpath from the value encoded in an
5424     # empty executable.
5425     _LT_SYS_MODULE_PATH_AIX([$1])
5426     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
5427 michael 5052 # Warning - without using the other run time loading flags,
5428     # -berok will link without error, but may produce a broken library.
5429 michael 5059 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
5430     _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
5431     if test yes = "$with_gnu_ld"; then
5432     # We only use this code for GNU lds that support --whole-archive.
5433     _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
5434     else
5435     # Exported symbols can be pulled into shared objects from archives
5436     _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5437     fi
5438     _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5439     _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
5440     # -brtl affects multiple linker settings, -berok does not and is overridden later
5441     compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
5442     if test svr4 != "$with_aix_soname"; then
5443     # This is similar to how AIX traditionally builds its shared libraries.
5444     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
5445     fi
5446     if test aix != "$with_aix_soname"; then
5447     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
5448     else
5449     # used by -dlpreopen to get the symbols
5450     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
5451     fi
5452     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
5453 michael 5052 fi
5454     fi
5455     ;;
5456    
5457     amigaos*)
5458 michael 5059 case $host_cpu in
5459     powerpc)
5460     # see comment about AmigaOS4 .so support
5461     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5462     _LT_TAGVAR(archive_expsym_cmds, $1)=''
5463     ;;
5464     m68k)
5465     _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)'
5466     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5467     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5468     ;;
5469     esac
5470 michael 5052 ;;
5471    
5472     bsdi[[45]]*)
5473 michael 5059 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5474 michael 5052 ;;
5475    
5476 michael 5059 cygwin* | mingw* | pw32* | cegcc*)
5477 michael 5052 # When not using gcc, we currently assume that we are using
5478     # Microsoft Visual C++.
5479     # hardcode_libdir_flag_spec is actually meaningless, as there is
5480     # no search path for DLLs.
5481 michael 5059 case $cc_basename in
5482     cl*)
5483     # Native MSVC
5484     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5485     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5486     _LT_TAGVAR(always_export_symbols, $1)=yes
5487     _LT_TAGVAR(file_list_spec, $1)='@'
5488     # Tell ltmain to make .lib files, not .a files.
5489     libext=lib
5490     # Tell ltmain to make .dll files, not .so files.
5491     shrext_cmds=.dll
5492     # FIXME: Setting linknames here is a bad hack.
5493     _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
5494     _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
5495     cp "$export_symbols" "$output_objdir/$soname.def";
5496     echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
5497     else
5498     $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
5499     fi~
5500     $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
5501     linknames='
5502     # The linker will not automatically build a static lib if we build a DLL.
5503     # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5504     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5505     _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
5506     _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'
5507     # Don't use ranlib
5508     _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
5509     _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
5510     lt_tool_outputfile="@TOOL_OUTPUT@"~
5511     case $lt_outputfile in
5512     *.exe|*.EXE) ;;
5513     *)
5514     lt_outputfile=$lt_outputfile.exe
5515     lt_tool_outputfile=$lt_tool_outputfile.exe
5516     ;;
5517     esac~
5518     if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
5519     $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
5520     $RM "$lt_outputfile.manifest";
5521     fi'
5522     ;;
5523     *)
5524     # Assume MSVC wrapper
5525     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5526     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5527     # Tell ltmain to make .lib files, not .a files.
5528     libext=lib
5529     # Tell ltmain to make .dll files, not .so files.
5530     shrext_cmds=.dll
5531     # FIXME: Setting linknames here is a bad hack.
5532     _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
5533     # The linker will automatically build a .lib file if we build a DLL.
5534     _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5535     # FIXME: Should let the user specify the lib program.
5536     _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
5537     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5538     ;;
5539     esac
5540 michael 5052 ;;
5541    
5542     darwin* | rhapsody*)
5543 michael 5059 _LT_DARWIN_LINKER_FEATURES($1)
5544 michael 5052 ;;
5545    
5546     dgux*)
5547 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5548     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5549     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5550 michael 5052 ;;
5551    
5552     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
5553     # support. Future versions do this automatically, but an explicit c++rt0.o
5554     # does not break anything, and helps significantly (at the cost of a little
5555     # extra space).
5556     freebsd2.2*)
5557 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
5558     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5559     _LT_TAGVAR(hardcode_direct, $1)=yes
5560     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5561 michael 5052 ;;
5562    
5563     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
5564 michael 5059 freebsd2.*)
5565     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5566     _LT_TAGVAR(hardcode_direct, $1)=yes
5567     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5568     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5569 michael 5052 ;;
5570    
5571     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5572     freebsd* | dragonfly*)
5573 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5574     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5575     _LT_TAGVAR(hardcode_direct, $1)=yes
5576     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5577 michael 5052 ;;
5578    
5579     hpux9*)
5580 michael 5059 if test yes = "$GCC"; then
5581     _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 "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
5582 michael 5052 else
5583 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
5584 michael 5052 fi
5585 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
5586     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5587     _LT_TAGVAR(hardcode_direct, $1)=yes
5588 michael 5052
5589     # hardcode_minus_L: Not really in the search PATH,
5590     # but as the default location of the library.
5591 michael 5059 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5592     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
5593 michael 5052 ;;
5594    
5595     hpux10*)
5596 michael 5059 if test yes,no = "$GCC,$with_gnu_ld"; then
5597     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5598 michael 5052 else
5599 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
5600 michael 5052 fi
5601 michael 5059 if test no = "$with_gnu_ld"; then
5602     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
5603     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5604     _LT_TAGVAR(hardcode_direct, $1)=yes
5605     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5606     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
5607 michael 5052 # hardcode_minus_L: Not really in the search PATH,
5608     # but as the default location of the library.
5609 michael 5059 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5610 michael 5052 fi
5611     ;;
5612    
5613     hpux11*)
5614 michael 5059 if test yes,no = "$GCC,$with_gnu_ld"; then
5615 michael 5052 case $host_cpu in
5616     hppa*64*)
5617 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
5618 michael 5052 ;;
5619     ia64*)
5620 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5621 michael 5052 ;;
5622     *)
5623 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5624 michael 5052 ;;
5625     esac
5626     else
5627     case $host_cpu in
5628     hppa*64*)
5629 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
5630 michael 5052 ;;
5631     ia64*)
5632 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5633 michael 5052 ;;
5634     *)
5635 michael 5059 m4_if($1, [], [
5636     # Older versions of the 11.00 compiler do not understand -b yet
5637     # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
5638     _LT_LINKER_OPTION([if $CC understands -b],
5639     _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
5640     [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
5641     [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
5642     [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
5643 michael 5052 ;;
5644     esac
5645     fi
5646 michael 5059 if test no = "$with_gnu_ld"; then
5647     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
5648     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5649 michael 5052
5650     case $host_cpu in
5651     hppa*64*|ia64*)
5652 michael 5059 _LT_TAGVAR(hardcode_direct, $1)=no
5653     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5654 michael 5052 ;;
5655     *)
5656 michael 5059 _LT_TAGVAR(hardcode_direct, $1)=yes
5657     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5658     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
5659 michael 5052
5660     # hardcode_minus_L: Not really in the search PATH,
5661     # but as the default location of the library.
5662 michael 5059 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5663 michael 5052 ;;
5664     esac
5665     fi
5666     ;;
5667    
5668     irix5* | irix6* | nonstopux*)
5669 michael 5059 if test yes = "$GCC"; then
5670     _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'
5671     # Try to use the -exported_symbol ld option, if it does not
5672     # work, assume that -exports_file does not work either and
5673     # implicitly export all symbols.
5674     # This should be the same for all languages, so no per-tag cache variable.
5675     AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
5676     [lt_cv_irix_exported_symbol],
5677     [save_LDFLAGS=$LDFLAGS
5678     LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
5679     AC_LINK_IFELSE(
5680     [AC_LANG_SOURCE(
5681     [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
5682     [C++], [[int foo (void) { return 0; }]],
5683     [Fortran 77], [[
5684     subroutine foo
5685     end]],
5686     [Fortran], [[
5687     subroutine foo
5688     end]])])],
5689     [lt_cv_irix_exported_symbol=yes],
5690     [lt_cv_irix_exported_symbol=no])
5691     LDFLAGS=$save_LDFLAGS])
5692     if test yes = "$lt_cv_irix_exported_symbol"; then
5693     _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'
5694     fi
5695 michael 5052 else
5696 michael 5059 _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'
5697     _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'
5698 michael 5052 fi
5699 michael 5059 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5700     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5701     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5702     _LT_TAGVAR(inherit_rpath, $1)=yes
5703     _LT_TAGVAR(link_all_deplibs, $1)=yes
5704 michael 5052 ;;
5705    
5706 michael 5059 linux*)
5707     case $cc_basename in
5708     tcc*)
5709     # Fabrice Bellard et al's Tiny C Compiler
5710     _LT_TAGVAR(ld_shlibs, $1)=yes
5711     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5712     ;;
5713     esac
5714     ;;
5715    
5716     netbsd*)
5717     if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5718     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
5719 michael 5052 else
5720 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
5721 michael 5052 fi
5722 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5723     _LT_TAGVAR(hardcode_direct, $1)=yes
5724     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5725 michael 5052 ;;
5726    
5727     newsos6)
5728 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5729     _LT_TAGVAR(hardcode_direct, $1)=yes
5730     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5731     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5732     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5733 michael 5052 ;;
5734    
5735 michael 5059 *nto* | *qnx*)
5736     ;;
5737    
5738     openbsd* | bitrig*)
5739     if test -f /usr/libexec/ld.so; then
5740     _LT_TAGVAR(hardcode_direct, $1)=yes
5741     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5742     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5743     if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
5744     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5745     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
5746     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
5747     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
5748     else
5749     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5750     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
5751     fi
5752 michael 5052 else
5753 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5754 michael 5052 fi
5755     ;;
5756    
5757     os2*)
5758 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5759     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5760     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5761     shrext_cmds=.dll
5762     _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5763     $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5764     $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5765     $ECHO EXPORTS >> $output_objdir/$libname.def~
5766     emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
5767     $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5768     emximp -o $lib $output_objdir/$libname.def'
5769     _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5770     $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5771     $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5772     $ECHO EXPORTS >> $output_objdir/$libname.def~
5773     prefix_cmds="$SED"~
5774     if test EXPORTS = "`$SED 1q $export_symbols`"; then
5775     prefix_cmds="$prefix_cmds -e 1d";
5776     fi~
5777     prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
5778     cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
5779     $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5780     emximp -o $lib $output_objdir/$libname.def'
5781     _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
5782     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5783 michael 5052 ;;
5784    
5785     osf3*)
5786 michael 5059 if test yes = "$GCC"; then
5787     _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
5788     _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'
5789 michael 5052 else
5790 michael 5059 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5791     _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'
5792 michael 5052 fi
5793 michael 5059 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5794     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5795     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5796 michael 5052 ;;
5797    
5798     osf4* | osf5*) # as osf3* with the addition of -msym flag
5799 michael 5059 if test yes = "$GCC"; then
5800     _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
5801     _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'
5802     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5803 michael 5052 else
5804 michael 5059 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5805     _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'
5806     _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~
5807     $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'
5808 michael 5052
5809     # Both c and cxx compiler support -rpath directly
5810 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
5811 michael 5052 fi
5812 michael 5059 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5813     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5814 michael 5052 ;;
5815    
5816     solaris*)
5817 michael 5059 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5818     if test yes = "$GCC"; then
5819     wlarc='$wl'
5820     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
5821     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5822     $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'
5823 michael 5052 else
5824 michael 5059 case `$CC -V 2>&1` in
5825     *"Compilers 5.0"*)
5826     wlarc=''
5827     _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
5828     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5829     $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
5830     ;;
5831     *)
5832     wlarc='$wl'
5833     _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
5834     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5835     $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5836     ;;
5837     esac
5838 michael 5052 fi
5839 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5840     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5841 michael 5052 case $host_os in
5842     solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
5843     *)
5844 michael 5059 # The compiler driver will combine and reorder linker options,
5845     # but understands '-z linker_flag'. GCC discards it without '$wl',
5846     # but is careful enough not to reorder.
5847     # Supported since Solaris 2.6 (maybe 2.5.1?)
5848     if test yes = "$GCC"; then
5849     _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
5850     else
5851     _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
5852     fi
5853     ;;
5854 michael 5052 esac
5855 michael 5059 _LT_TAGVAR(link_all_deplibs, $1)=yes
5856 michael 5052 ;;
5857    
5858     sunos4*)
5859 michael 5059 if test sequent = "$host_vendor"; then
5860 michael 5052 # Use $CC to link under sequent, because it throws in some extra .o
5861     # files that make .init and .fini sections work.
5862 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
5863 michael 5052 else
5864 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
5865 michael 5052 fi
5866 michael 5059 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5867     _LT_TAGVAR(hardcode_direct, $1)=yes
5868     _LT_TAGVAR(hardcode_minus_L, $1)=yes
5869     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5870 michael 5052 ;;
5871    
5872     sysv4)
5873     case $host_vendor in
5874     sni)
5875 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5876     _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
5877 michael 5052 ;;
5878     siemens)
5879     ## LD is ld it makes a PLAMLIB
5880     ## CC just makes a GrossModule.
5881 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
5882     _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
5883     _LT_TAGVAR(hardcode_direct, $1)=no
5884 michael 5052 ;;
5885     motorola)
5886 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5887     _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
5888 michael 5052 ;;
5889     esac
5890     runpath_var='LD_RUN_PATH'
5891 michael 5059 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5892 michael 5052 ;;
5893    
5894     sysv4.3*)
5895 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5896     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5897     _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
5898 michael 5052 ;;
5899    
5900     sysv4*MP*)
5901     if test -d /usr/nec; then
5902 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5903     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5904 michael 5052 runpath_var=LD_RUN_PATH
5905     hardcode_runpath_var=yes
5906 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=yes
5907 michael 5052 fi
5908     ;;
5909    
5910 michael 5059 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
5911     _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
5912     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5913     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5914 michael 5052 runpath_var='LD_RUN_PATH'
5915    
5916 michael 5059 if test yes = "$GCC"; then
5917     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5918     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5919 michael 5052 else
5920 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5921     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5922 michael 5052 fi
5923     ;;
5924    
5925     sysv5* | sco3.2v5* | sco5v6*)
5926 michael 5059 # Note: We CANNOT use -z defs as we might desire, because we do not
5927 michael 5052 # link with -lc, and that would cause any symbols used from libc to
5928     # always be unresolved, which means just about no library would
5929     # ever link correctly. If we're not using GNU ld we use -z text
5930     # though, which does catch some bad symbols but isn't as heavy-handed
5931     # as -z defs.
5932 michael 5059 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
5933     _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
5934     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5935     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5936     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
5937     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5938     _LT_TAGVAR(link_all_deplibs, $1)=yes
5939     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
5940 michael 5052 runpath_var='LD_RUN_PATH'
5941    
5942 michael 5059 if test yes = "$GCC"; then
5943     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5944     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5945 michael 5052 else
5946 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5947     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5948 michael 5052 fi
5949     ;;
5950    
5951     uts4*)
5952 michael 5059 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5953     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5954     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5955 michael 5052 ;;
5956    
5957     *)
5958 michael 5059 _LT_TAGVAR(ld_shlibs, $1)=no
5959 michael 5052 ;;
5960     esac
5961 michael 5059
5962     if test sni = "$host_vendor"; then
5963     case $host in
5964     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5965     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym'
5966     ;;
5967     esac
5968     fi
5969 michael 5052 fi
5970     ])
5971 michael 5059 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
5972     test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
5973 michael 5052
5974 michael 5059 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
5975    
5976     _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
5977     _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
5978     _LT_DECL([], [extract_expsyms_cmds], [2],
5979     [The commands to extract the exported symbol list from a shared archive])
5980    
5981 michael 5052 #
5982     # Do we need to explicitly link libc?
5983     #
5984 michael 5059 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
5985 michael 5052 x|xyes)
5986     # Assume -lc should be added
5987 michael 5059 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5988 michael 5052
5989 michael 5059 if test yes,yes = "$GCC,$enable_shared"; then
5990     case $_LT_TAGVAR(archive_cmds, $1) in
5991 michael 5052 *'~'*)
5992     # FIXME: we may have to deal with multi-command sequences.
5993     ;;
5994     '$CC '*)
5995     # Test whether the compiler implicitly links with -lc since on some
5996     # systems, -lgcc has to come before -lc. If gcc already passes -lc
5997     # to ld, don't add -lc before -lgcc.
5998 michael 5059 AC_CACHE_CHECK([whether -lc should be explicitly linked in],
5999     [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
6000     [$RM conftest*
6001     echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6002 michael 5052
6003 michael 5059 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6004     soname=conftest
6005     lib=conftest
6006     libobjs=conftest.$ac_objext
6007     deplibs=
6008     wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
6009     pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
6010     compiler_flags=-v
6011     linker_flags=-v
6012     verstring=
6013     output_objdir=.
6014     libname=conftest
6015     lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
6016     _LT_TAGVAR(allow_undefined_flag, $1)=
6017     if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
6018     then
6019     lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
6020     else
6021     lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6022     fi
6023     _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6024     else
6025     cat conftest.err 1>&5
6026     fi
6027     $RM conftest*
6028     ])
6029     _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
6030     ;;
6031     esac
6032     fi
6033     ;;
6034     esac
6035    
6036     _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
6037     [Whether or not to add -lc for building shared libraries])
6038     _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
6039     [enable_shared_with_static_runtimes], [0],
6040     [Whether or not to disallow shared libs when runtime libs are static])
6041     _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
6042     [Compiler flag to allow reflexive dlopens])
6043     _LT_TAGDECL([], [whole_archive_flag_spec], [1],
6044     [Compiler flag to generate shared objects directly from archives])
6045     _LT_TAGDECL([], [compiler_needs_object], [1],
6046     [Whether the compiler copes with passing no objects directly])
6047     _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
6048     [Create an old-style archive from a shared archive])
6049     _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
6050     [Create a temporary old-style archive to link instead of a shared archive])
6051     _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
6052     _LT_TAGDECL([], [archive_expsym_cmds], [2])
6053     _LT_TAGDECL([], [module_cmds], [2],
6054     [Commands used to build a loadable module if different from building
6055     a shared archive.])
6056     _LT_TAGDECL([], [module_expsym_cmds], [2])
6057     _LT_TAGDECL([], [with_gnu_ld], [1],
6058     [Whether we are building with GNU ld or not])
6059     _LT_TAGDECL([], [allow_undefined_flag], [1],
6060     [Flag that allows shared libraries with undefined symbols to be built])
6061     _LT_TAGDECL([], [no_undefined_flag], [1],
6062     [Flag that enforces no undefined symbols])
6063     _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
6064     [Flag to hardcode $libdir into a binary during linking.
6065     This must work even if $libdir does not exist])
6066     _LT_TAGDECL([], [hardcode_libdir_separator], [1],
6067     [Whether we need a single "-rpath" flag with a separated argument])
6068     _LT_TAGDECL([], [hardcode_direct], [0],
6069     [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
6070     DIR into the resulting binary])
6071     _LT_TAGDECL([], [hardcode_direct_absolute], [0],
6072     [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
6073     DIR into the resulting binary and the resulting library dependency is
6074     "absolute", i.e impossible to change by setting $shlibpath_var if the
6075     library is relocated])
6076     _LT_TAGDECL([], [hardcode_minus_L], [0],
6077     [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
6078     into the resulting binary])
6079     _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
6080     [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
6081     into the resulting binary])
6082     _LT_TAGDECL([], [hardcode_automatic], [0],
6083     [Set to "yes" if building a shared library automatically hardcodes DIR
6084     into the library and all subsequent libraries and executables linked
6085     against it])
6086     _LT_TAGDECL([], [inherit_rpath], [0],
6087     [Set to yes if linker adds runtime paths of dependent libraries
6088     to runtime path list])
6089     _LT_TAGDECL([], [link_all_deplibs], [0],
6090     [Whether libtool must link a program against all its dependency libraries])
6091     _LT_TAGDECL([], [always_export_symbols], [0],
6092     [Set to "yes" if exported symbols are required])
6093     _LT_TAGDECL([], [export_symbols_cmds], [2],
6094     [The commands to list exported symbols])
6095     _LT_TAGDECL([], [exclude_expsyms], [1],
6096     [Symbols that should not be listed in the preloaded symbols])
6097     _LT_TAGDECL([], [include_expsyms], [1],
6098     [Symbols that must always be exported])
6099     _LT_TAGDECL([], [prelink_cmds], [2],
6100     [Commands necessary for linking programs (against libraries) with templates])
6101     _LT_TAGDECL([], [postlink_cmds], [2],
6102     [Commands necessary for finishing linking programs])
6103     _LT_TAGDECL([], [file_list_spec], [1],
6104     [Specify filename containing input files])
6105     dnl FIXME: Not yet implemented
6106     dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
6107     dnl [Compiler flag to generate thread safe objects])
6108     ])# _LT_LINKER_SHLIBS
6109    
6110    
6111     # _LT_LANG_C_CONFIG([TAG])
6112     # ------------------------
6113     # Ensure that the configuration variables for a C compiler are suitably
6114     # defined. These variables are subsequently used by _LT_CONFIG to write
6115     # the compiler configuration to 'libtool'.
6116     m4_defun([_LT_LANG_C_CONFIG],
6117     [m4_require([_LT_DECL_EGREP])dnl
6118     lt_save_CC=$CC
6119     AC_LANG_PUSH(C)
6120    
6121     # Source file extension for C test sources.
6122     ac_ext=c
6123    
6124     # Object file extension for compiled C test sources.
6125     objext=o
6126     _LT_TAGVAR(objext, $1)=$objext
6127    
6128     # Code to be used in simple compile tests
6129     lt_simple_compile_test_code="int some_variable = 0;"
6130    
6131     # Code to be used in simple link tests
6132     lt_simple_link_test_code='int main(){return(0);}'
6133    
6134     _LT_TAG_COMPILER
6135     # Save the default compiler, since it gets overwritten when the other
6136     # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
6137     compiler_DEFAULT=$CC
6138    
6139     # save warnings/boilerplate of simple test code
6140     _LT_COMPILER_BOILERPLATE
6141     _LT_LINKER_BOILERPLATE
6142    
6143     if test -n "$compiler"; then
6144     _LT_COMPILER_NO_RTTI($1)
6145     _LT_COMPILER_PIC($1)
6146     _LT_COMPILER_C_O($1)
6147     _LT_COMPILER_FILE_LOCKS($1)
6148     _LT_LINKER_SHLIBS($1)
6149     _LT_SYS_DYNAMIC_LINKER($1)
6150     _LT_LINKER_HARDCODE_LIBPATH($1)
6151     LT_SYS_DLOPEN_SELF
6152     _LT_CMD_STRIPLIB
6153    
6154     # Report what library types will actually be built
6155     AC_MSG_CHECKING([if libtool supports shared libraries])
6156     AC_MSG_RESULT([$can_build_shared])
6157    
6158     AC_MSG_CHECKING([whether to build shared libraries])
6159     test no = "$can_build_shared" && enable_shared=no
6160    
6161     # On AIX, shared libraries and static libraries use the same namespace, and
6162     # are all built from PIC.
6163     case $host_os in
6164     aix3*)
6165     test yes = "$enable_shared" && enable_static=no
6166     if test -n "$RANLIB"; then
6167     archive_cmds="$archive_cmds~\$RANLIB \$lib"
6168     postinstall_cmds='$RANLIB $lib'
6169     fi
6170     ;;
6171    
6172     aix[[4-9]]*)
6173     if test ia64 != "$host_cpu"; then
6174     case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
6175     yes,aix,yes) ;; # shared object as lib.so file only
6176     yes,svr4,*) ;; # shared object as lib.so archive member only
6177     yes,*) enable_static=no ;; # shared object in lib.a archive as well
6178     esac
6179     fi
6180     ;;
6181     esac
6182     AC_MSG_RESULT([$enable_shared])
6183    
6184     AC_MSG_CHECKING([whether to build static libraries])
6185     # Make sure either enable_shared or enable_static is yes.
6186     test yes = "$enable_shared" || enable_static=yes
6187     AC_MSG_RESULT([$enable_static])
6188    
6189     _LT_CONFIG($1)
6190     fi
6191     AC_LANG_POP
6192     CC=$lt_save_CC
6193     ])# _LT_LANG_C_CONFIG
6194    
6195    
6196     # _LT_LANG_CXX_CONFIG([TAG])
6197     # --------------------------
6198     # Ensure that the configuration variables for a C++ compiler are suitably
6199     # defined. These variables are subsequently used by _LT_CONFIG to write
6200     # the compiler configuration to 'libtool'.
6201     m4_defun([_LT_LANG_CXX_CONFIG],
6202     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6203     m4_require([_LT_DECL_EGREP])dnl
6204     m4_require([_LT_PATH_MANIFEST_TOOL])dnl
6205     if test -n "$CXX" && ( test no != "$CXX" &&
6206     ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) ||
6207     (test g++ != "$CXX"))); then
6208     AC_PROG_CXXCPP
6209     else
6210     _lt_caught_CXX_error=yes
6211     fi
6212    
6213     AC_LANG_PUSH(C++)
6214     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6215     _LT_TAGVAR(allow_undefined_flag, $1)=
6216     _LT_TAGVAR(always_export_symbols, $1)=no
6217     _LT_TAGVAR(archive_expsym_cmds, $1)=
6218     _LT_TAGVAR(compiler_needs_object, $1)=no
6219     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
6220     _LT_TAGVAR(hardcode_direct, $1)=no
6221     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6222     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
6223     _LT_TAGVAR(hardcode_libdir_separator, $1)=
6224     _LT_TAGVAR(hardcode_minus_L, $1)=no
6225     _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6226     _LT_TAGVAR(hardcode_automatic, $1)=no
6227     _LT_TAGVAR(inherit_rpath, $1)=no
6228     _LT_TAGVAR(module_cmds, $1)=
6229     _LT_TAGVAR(module_expsym_cmds, $1)=
6230     _LT_TAGVAR(link_all_deplibs, $1)=unknown
6231     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
6232     _LT_TAGVAR(reload_flag, $1)=$reload_flag
6233     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
6234     _LT_TAGVAR(no_undefined_flag, $1)=
6235     _LT_TAGVAR(whole_archive_flag_spec, $1)=
6236     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6237    
6238     # Source file extension for C++ test sources.
6239     ac_ext=cpp
6240    
6241     # Object file extension for compiled C++ test sources.
6242     objext=o
6243     _LT_TAGVAR(objext, $1)=$objext
6244    
6245     # No sense in running all these tests if we already determined that
6246     # the CXX compiler isn't working. Some variables (like enable_shared)
6247     # are currently assumed to apply to all compilers on this platform,
6248     # and will be corrupted by setting them based on a non-working compiler.
6249     if test yes != "$_lt_caught_CXX_error"; then
6250     # Code to be used in simple compile tests
6251     lt_simple_compile_test_code="int some_variable = 0;"
6252    
6253     # Code to be used in simple link tests
6254     lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
6255    
6256     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
6257     _LT_TAG_COMPILER
6258    
6259     # save warnings/boilerplate of simple test code
6260     _LT_COMPILER_BOILERPLATE
6261     _LT_LINKER_BOILERPLATE
6262    
6263     # Allow CC to be a program name with arguments.
6264     lt_save_CC=$CC
6265     lt_save_CFLAGS=$CFLAGS
6266     lt_save_LD=$LD
6267     lt_save_GCC=$GCC
6268     GCC=$GXX
6269     lt_save_with_gnu_ld=$with_gnu_ld
6270     lt_save_path_LD=$lt_cv_path_LD
6271     if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
6272     lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
6273     else
6274     $as_unset lt_cv_prog_gnu_ld
6275     fi
6276     if test -n "${lt_cv_path_LDCXX+set}"; then
6277     lt_cv_path_LD=$lt_cv_path_LDCXX
6278     else
6279     $as_unset lt_cv_path_LD
6280     fi
6281     test -z "${LDCXX+set}" || LD=$LDCXX
6282     CC=${CXX-"c++"}
6283     CFLAGS=$CXXFLAGS
6284     compiler=$CC
6285     _LT_TAGVAR(compiler, $1)=$CC
6286     _LT_CC_BASENAME([$compiler])
6287    
6288     if test -n "$compiler"; then
6289     # We don't want -fno-exception when compiling C++ code, so set the
6290     # no_builtin_flag separately
6291     if test yes = "$GXX"; then
6292     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
6293     else
6294     _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
6295     fi
6296    
6297     if test yes = "$GXX"; then
6298     # Set up default GNU C++ configuration
6299    
6300     LT_PATH_LD
6301    
6302     # Check if GNU C++ uses GNU ld as the underlying linker, since the
6303     # archiving commands below assume that GNU ld is being used.
6304     if test yes = "$with_gnu_ld"; then
6305     _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6306     _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'
6307    
6308     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6309     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6310    
6311     # If archive_cmds runs LD, not CC, wlarc should be empty
6312     # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
6313     # investigate it a little bit more. (MM)
6314     wlarc='$wl'
6315    
6316     # ancient GNU ld didn't support --whole-archive et. al.
6317     if eval "`$CC -print-prog-name=ld` --help 2>&1" |
6318     $GREP 'no-whole-archive' > /dev/null; then
6319     _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
6320 michael 5052 else
6321 michael 5059 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6322 michael 5052 fi
6323     else
6324 michael 5059 with_gnu_ld=no
6325     wlarc=
6326    
6327     # A generic and very simple default shared library creation
6328     # command for GNU C++ for the case where it uses the native
6329     # linker, instead of GNU ld. If possible, this setting should
6330     # overridden to take advantage of the native linker features on
6331     # the platform it is being used on.
6332     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6333 michael 5052 fi
6334 michael 5059
6335     # Commands to make compiler produce verbose output that lists
6336     # what "hidden" libraries, object files and flags are used when
6337     # linking a shared library.
6338     output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
6339    
6340     else
6341     GXX=no
6342     with_gnu_ld=no
6343     wlarc=
6344     fi
6345    
6346     # PORTME: fill in a description of your system's C++ link characteristics
6347     AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6348     _LT_TAGVAR(ld_shlibs, $1)=yes
6349     case $host_os in
6350     aix3*)
6351     # FIXME: insert proper C++ library support
6352     _LT_TAGVAR(ld_shlibs, $1)=no
6353     ;;
6354     aix[[4-9]]*)
6355     if test ia64 = "$host_cpu"; then
6356     # On IA64, the linker does run time linking by default, so we don't
6357     # have to do anything special.
6358     aix_use_runtimelinking=no
6359     exp_sym_flag='-Bexport'
6360     no_entry_flag=
6361     else
6362     aix_use_runtimelinking=no
6363    
6364     # Test if we are trying to use run time linking or normal
6365     # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6366     # have runtime linking enabled, and use it for executables.
6367     # For shared libraries, we enable/disable runtime linking
6368     # depending on the kind of the shared library created -
6369     # when "with_aix_soname,aix_use_runtimelinking" is:
6370     # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
6371     # "aix,yes" lib.so shared, rtl:yes, for executables
6372     # lib.a static archive
6373     # "both,no" lib.so.V(shr.o) shared, rtl:yes
6374     # lib.a(lib.so.V) shared, rtl:no, for executables
6375     # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
6376     # lib.a(lib.so.V) shared, rtl:no
6377     # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
6378     # lib.a static archive
6379     case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6380     for ld_flag in $LDFLAGS; do
6381     case $ld_flag in
6382     *-brtl*)
6383     aix_use_runtimelinking=yes
6384     break
6385     ;;
6386     esac
6387     done
6388     if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
6389     # With aix-soname=svr4, we create the lib.so.V shared archives only,
6390     # so we don't have lib.a shared libs to link our executables.
6391     # We have to force runtime linking in this case.
6392     aix_use_runtimelinking=yes
6393     LDFLAGS="$LDFLAGS -Wl,-brtl"
6394     fi
6395     ;;
6396     esac
6397    
6398     exp_sym_flag='-bexport'
6399     no_entry_flag='-bnoentry'
6400     fi
6401    
6402     # When large executables or shared objects are built, AIX ld can
6403     # have problems creating the table of contents. If linking a library
6404     # or program results in "error TOC overflow" add -mminimal-toc to
6405     # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6406     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6407    
6408     _LT_TAGVAR(archive_cmds, $1)=''
6409     _LT_TAGVAR(hardcode_direct, $1)=yes
6410     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6411     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6412     _LT_TAGVAR(link_all_deplibs, $1)=yes
6413     _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
6414     case $with_aix_soname,$aix_use_runtimelinking in
6415     aix,*) ;; # no import file
6416     svr4,* | *,yes) # use import file
6417     # The Import File defines what to hardcode.
6418     _LT_TAGVAR(hardcode_direct, $1)=no
6419     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6420     ;;
6421     esac
6422    
6423     if test yes = "$GXX"; then
6424     case $host_os in aix4.[[012]]|aix4.[[012]].*)
6425     # We only want to do this on AIX 4.2 and lower, the check
6426     # below for broken collect2 doesn't work under 4.3+
6427     collect2name=`$CC -print-prog-name=collect2`
6428     if test -f "$collect2name" &&
6429     strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6430     then
6431     # We have reworked collect2
6432     :
6433     else
6434     # We have old collect2
6435     _LT_TAGVAR(hardcode_direct, $1)=unsupported
6436     # It fails to find uninstalled libraries when the uninstalled
6437     # path is not listed in the libpath. Setting hardcode_minus_L
6438     # to unsupported forces relinking
6439     _LT_TAGVAR(hardcode_minus_L, $1)=yes
6440     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6441     _LT_TAGVAR(hardcode_libdir_separator, $1)=
6442     fi
6443     esac
6444     shared_flag='-shared'
6445     if test yes = "$aix_use_runtimelinking"; then
6446     shared_flag=$shared_flag' $wl-G'
6447     fi
6448     # Need to ensure runtime linking is disabled for the traditional
6449     # shared library, or the linker may eventually find shared libraries
6450     # /with/ Import File - we do not want to mix them.
6451     shared_flag_aix='-shared'
6452     shared_flag_svr4='-shared $wl-G'
6453     else
6454     # not using gcc
6455     if test ia64 = "$host_cpu"; then
6456     # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6457     # chokes on -Wl,-G. The following line is correct:
6458     shared_flag='-G'
6459     else
6460     if test yes = "$aix_use_runtimelinking"; then
6461     shared_flag='$wl-G'
6462     else
6463     shared_flag='$wl-bM:SRE'
6464     fi
6465     shared_flag_aix='$wl-bM:SRE'
6466     shared_flag_svr4='$wl-G'
6467     fi
6468     fi
6469    
6470     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
6471     # It seems that -bexpall does not export symbols beginning with
6472     # underscore (_), so it is better to generate a list of symbols to
6473     # export.
6474     _LT_TAGVAR(always_export_symbols, $1)=yes
6475     if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
6476     # Warning - without using the other runtime loading flags (-brtl),
6477     # -berok will link without error, but may produce a broken library.
6478     # The "-G" linker flag allows undefined symbols.
6479     _LT_TAGVAR(no_undefined_flag, $1)='-bernotok'
6480     # Determine the default libpath from the value encoded in an empty
6481     # executable.
6482     _LT_SYS_MODULE_PATH_AIX([$1])
6483     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
6484    
6485     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
6486     else
6487     if test ia64 = "$host_cpu"; then
6488     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
6489     _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6490     _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"
6491     else
6492     # Determine the default libpath from the value encoded in an
6493     # empty executable.
6494     _LT_SYS_MODULE_PATH_AIX([$1])
6495     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
6496     # Warning - without using the other run time loading flags,
6497     # -berok will link without error, but may produce a broken library.
6498     _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
6499     _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
6500     if test yes = "$with_gnu_ld"; then
6501     # We only use this code for GNU lds that support --whole-archive.
6502     _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
6503     else
6504     # Exported symbols can be pulled into shared objects from archives
6505     _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6506     fi
6507     _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6508     _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
6509     # -brtl affects multiple linker settings, -berok does not and is overridden later
6510     compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
6511     if test svr4 != "$with_aix_soname"; then
6512     # This is similar to how AIX traditionally builds its shared
6513     # libraries. Need -bnortl late, we may have -brtl in LDFLAGS.
6514     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
6515     fi
6516     if test aix != "$with_aix_soname"; then
6517     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
6518     else
6519     # used by -dlpreopen to get the symbols
6520     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
6521     fi
6522     _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
6523     fi
6524     fi
6525     ;;
6526    
6527     beos*)
6528     if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6529     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6530     # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6531     # support --undefined. This deserves some investigation. FIXME
6532     _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
6533     else
6534     _LT_TAGVAR(ld_shlibs, $1)=no
6535     fi
6536     ;;
6537    
6538     chorus*)
6539     case $cc_basename in
6540     *)
6541     # FIXME: insert proper C++ library support
6542     _LT_TAGVAR(ld_shlibs, $1)=no
6543     ;;
6544     esac
6545     ;;
6546    
6547     cygwin* | mingw* | pw32* | cegcc*)
6548     case $GXX,$cc_basename in
6549     ,cl* | no,cl*)
6550     # Native MSVC
6551     # hardcode_libdir_flag_spec is actually meaningless, as there is
6552     # no search path for DLLs.
6553     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6554     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6555     _LT_TAGVAR(always_export_symbols, $1)=yes
6556     _LT_TAGVAR(file_list_spec, $1)='@'
6557     # Tell ltmain to make .lib files, not .a files.
6558     libext=lib
6559     # Tell ltmain to make .dll files, not .so files.
6560     shrext_cmds=.dll
6561     # FIXME: Setting linknames here is a bad hack.
6562     _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
6563     _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
6564     cp "$export_symbols" "$output_objdir/$soname.def";
6565     echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
6566     else
6567     $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
6568     fi~
6569     $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6570     linknames='
6571     # The linker will not automatically build a static lib if we build a DLL.
6572     # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
6573     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6574     # Don't use ranlib
6575     _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
6576     _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6577     lt_tool_outputfile="@TOOL_OUTPUT@"~
6578     case $lt_outputfile in
6579     *.exe|*.EXE) ;;
6580     *)
6581     lt_outputfile=$lt_outputfile.exe
6582     lt_tool_outputfile=$lt_tool_outputfile.exe
6583     ;;
6584     esac~
6585     func_to_tool_file "$lt_outputfile"~
6586     if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
6587     $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6588     $RM "$lt_outputfile.manifest";
6589     fi'
6590     ;;
6591     *)
6592     # g++
6593     # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6594     # as there is no search path for DLLs.
6595     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6596     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
6597     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6598     _LT_TAGVAR(always_export_symbols, $1)=no
6599     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6600    
6601     if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
6602     _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'
6603     # If the export-symbols file already is a .def file, use it as
6604     # is; otherwise, prepend EXPORTS...
6605     _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
6606     cp $export_symbols $output_objdir/$soname.def;
6607     else
6608     echo EXPORTS > $output_objdir/$soname.def;
6609     cat $export_symbols >> $output_objdir/$soname.def;
6610     fi~
6611     $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'
6612     else
6613     _LT_TAGVAR(ld_shlibs, $1)=no
6614     fi
6615     ;;
6616     esac
6617     ;;
6618     darwin* | rhapsody*)
6619     _LT_DARWIN_LINKER_FEATURES($1)
6620     ;;
6621    
6622     os2*)
6623     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6624     _LT_TAGVAR(hardcode_minus_L, $1)=yes
6625     _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6626     shrext_cmds=.dll
6627     _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
6628     $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
6629     $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
6630     $ECHO EXPORTS >> $output_objdir/$libname.def~
6631     emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
6632     $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
6633     emximp -o $lib $output_objdir/$libname.def'
6634     _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
6635     $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
6636     $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
6637     $ECHO EXPORTS >> $output_objdir/$libname.def~
6638     prefix_cmds="$SED"~
6639     if test EXPORTS = "`$SED 1q $export_symbols`"; then
6640     prefix_cmds="$prefix_cmds -e 1d";
6641     fi~
6642     prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
6643     cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
6644     $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
6645     emximp -o $lib $output_objdir/$libname.def'
6646     _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
6647     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6648     ;;
6649    
6650     dgux*)
6651     case $cc_basename in
6652     ec++*)
6653     # FIXME: insert proper C++ library support
6654     _LT_TAGVAR(ld_shlibs, $1)=no
6655     ;;
6656     ghcx*)
6657     # Green Hills C++ Compiler
6658     # FIXME: insert proper C++ library support
6659     _LT_TAGVAR(ld_shlibs, $1)=no
6660     ;;
6661     *)
6662     # FIXME: insert proper C++ library support
6663     _LT_TAGVAR(ld_shlibs, $1)=no
6664     ;;
6665     esac
6666     ;;
6667    
6668     freebsd2.*)
6669     # C++ shared libraries reported to be fairly broken before
6670     # switch to ELF
6671     _LT_TAGVAR(ld_shlibs, $1)=no
6672     ;;
6673    
6674     freebsd-elf*)
6675     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6676     ;;
6677    
6678     freebsd* | dragonfly*)
6679     # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
6680     # conventions
6681     _LT_TAGVAR(ld_shlibs, $1)=yes
6682     ;;
6683    
6684     haiku*)
6685     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
6686     _LT_TAGVAR(link_all_deplibs, $1)=yes
6687     ;;
6688    
6689     hpux9*)
6690     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
6691     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6692     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6693     _LT_TAGVAR(hardcode_direct, $1)=yes
6694     _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6695     # but as the default
6696     # location of the library.
6697    
6698     case $cc_basename in
6699     CC*)
6700     # FIXME: insert proper C++ library support
6701     _LT_TAGVAR(ld_shlibs, $1)=no
6702     ;;
6703     aCC*)
6704     _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 "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
6705     # Commands to make compiler produce verbose output that lists
6706     # what "hidden" libraries, object files and flags are used when
6707     # linking a shared library.
6708     #
6709     # There doesn't appear to be a way to prevent this compiler from
6710     # explicitly linking system object files so we need to strip them
6711     # from the output so that they don't get included in the library
6712     # dependencies.
6713     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"'
6714     ;;
6715     *)
6716     if test yes = "$GXX"; then
6717     _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 "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
6718     else
6719     # FIXME: insert proper C++ library support
6720     _LT_TAGVAR(ld_shlibs, $1)=no
6721     fi
6722     ;;
6723     esac
6724     ;;
6725    
6726     hpux10*|hpux11*)
6727     if test no = "$with_gnu_ld"; then
6728     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
6729     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6730    
6731     case $host_cpu in
6732     hppa*64*|ia64*)
6733     ;;
6734     *)
6735     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6736     ;;
6737     esac
6738     fi
6739     case $host_cpu in
6740     hppa*64*|ia64*)
6741     _LT_TAGVAR(hardcode_direct, $1)=no
6742     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6743     ;;
6744     *)
6745     _LT_TAGVAR(hardcode_direct, $1)=yes
6746     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6747     _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6748     # but as the default
6749     # location of the library.
6750     ;;
6751     esac
6752    
6753     case $cc_basename in
6754     CC*)
6755     # FIXME: insert proper C++ library support
6756     _LT_TAGVAR(ld_shlibs, $1)=no
6757     ;;
6758     aCC*)
6759     case $host_cpu in
6760     hppa*64*)
6761     _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6762     ;;
6763     ia64*)
6764     _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6765     ;;
6766     *)
6767     _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'
6768     ;;
6769     esac
6770     # Commands to make compiler produce verbose output that lists
6771     # what "hidden" libraries, object files and flags are used when
6772     # linking a shared library.
6773     #
6774     # There doesn't appear to be a way to prevent this compiler from
6775     # explicitly linking system object files so we need to strip them
6776     # from the output so that they don't get included in the library
6777     # dependencies.
6778     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"'
6779     ;;
6780     *)
6781     if test yes = "$GXX"; then
6782     if test no = "$with_gnu_ld"; then
6783     case $host_cpu in
6784     hppa*64*)
6785     _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6786     ;;
6787     ia64*)
6788     _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'
6789     ;;
6790     *)
6791     _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'
6792     ;;
6793     esac
6794     fi
6795     else
6796     # FIXME: insert proper C++ library support
6797     _LT_TAGVAR(ld_shlibs, $1)=no
6798     fi
6799     ;;
6800     esac
6801     ;;
6802    
6803     interix[[3-9]]*)
6804     _LT_TAGVAR(hardcode_direct, $1)=no
6805     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6806     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6807     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
6808     # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6809     # Instead, shared libraries are loaded at an image base (0x10000000 by
6810     # default) and relocated if they conflict, which is a slow very memory
6811     # consuming and fragmenting process. To avoid this, we pick a random,
6812     # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6813     # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6814     _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'
6815     _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'
6816     ;;
6817     irix5* | irix6*)
6818     case $cc_basename in
6819     CC*)
6820     # SGI C++
6821     _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'
6822    
6823     # Archives containing C++ object files must be created using
6824     # "CC -ar", where "CC" is the IRIX C++ compiler. This is
6825     # necessary to make sure instantiated templates are included
6826     # in the archive.
6827     _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
6828     ;;
6829     *)
6830     if test yes = "$GXX"; then
6831     if test no = "$with_gnu_ld"; then
6832     _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'
6833     else
6834     _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'
6835     fi
6836     fi
6837     _LT_TAGVAR(link_all_deplibs, $1)=yes
6838     ;;
6839     esac
6840     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6841     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6842     _LT_TAGVAR(inherit_rpath, $1)=yes
6843     ;;
6844    
6845     linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
6846     case $cc_basename in
6847     KCC*)
6848     # Kuck and Associates, Inc. (KAI) C++ Compiler
6849    
6850     # KCC will only create a shared library if the output file
6851     # ends with ".so" (or ".sl" for HP-UX), so rename the library
6852     # to its proper name (with version) after linking.
6853     _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'
6854     _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'
6855     # Commands to make compiler produce verbose output that lists
6856     # what "hidden" libraries, object files and flags are used when
6857     # linking a shared library.
6858     #
6859     # There doesn't appear to be a way to prevent this compiler from
6860     # explicitly linking system object files so we need to strip them
6861     # from the output so that they don't get included in the library
6862     # dependencies.
6863     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"'
6864    
6865     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6866     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6867    
6868     # Archives containing C++ object files must be created using
6869     # "CC -Bstatic", where "CC" is the KAI C++ compiler.
6870     _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
6871     ;;
6872     icpc* | ecpc* )
6873     # Intel C++
6874     with_gnu_ld=yes
6875     # version 8.0 and above of icpc choke on multiply defined symbols
6876     # if we add $predep_objects and $postdep_objects, however 7.1 and
6877     # earlier do not add the objects themselves.
6878     case `$CC -V 2>&1` in
6879     *"Version 7."*)
6880     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6881     _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'
6882     ;;
6883     *) # Version 8.0 or newer
6884     tmp_idyn=
6885     case $host_cpu in
6886     ia64*) tmp_idyn=' -i_dynamic';;
6887     esac
6888     _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
6889     _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'
6890     ;;
6891     esac
6892     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6893     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6894     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6895     _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
6896     ;;
6897     pgCC* | pgcpp*)
6898     # Portland Group C++ compiler
6899     case `$CC -V` in
6900     *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
6901     _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
6902     rm -rf $tpldir~
6903     $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6904     compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
6905     _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
6906     rm -rf $tpldir~
6907     $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6908     $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
6909     $RANLIB $oldlib'
6910     _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6911     rm -rf $tpldir~
6912     $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6913     $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6914     _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6915     rm -rf $tpldir~
6916     $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6917     $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'
6918     ;;
6919     *) # Version 6 and above use weak symbols
6920     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6921     _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'
6922     ;;
6923     esac
6924    
6925     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir'
6926     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6927     _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'
6928     ;;
6929     cxx*)
6930     # Compaq C++
6931     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6932     _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'
6933    
6934     runpath_var=LD_RUN_PATH
6935     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6936     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6937    
6938     # Commands to make compiler produce verbose output that lists
6939     # what "hidden" libraries, object files and flags are used when
6940     # linking a shared library.
6941     #
6942     # There doesn't appear to be a way to prevent this compiler from
6943     # explicitly linking system object files so we need to strip them
6944     # from the output so that they don't get included in the library
6945     # dependencies.
6946     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'
6947     ;;
6948     xl* | mpixl* | bgxl*)
6949     # IBM XL 8.0 on PPC, with GNU ld
6950     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6951     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6952     _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
6953     if test yes = "$supports_anon_versioning"; then
6954     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6955     cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6956     echo "local: *; };" >> $output_objdir/$libname.ver~
6957     $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
6958     fi
6959     ;;
6960     *)
6961     case `$CC -V 2>&1 | sed 5q` in
6962     *Sun\ C*)
6963     # Sun C++ 5.9
6964     _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6965     _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6966     _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'
6967     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6968     _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'
6969     _LT_TAGVAR(compiler_needs_object, $1)=yes
6970    
6971     # Not sure whether something based on
6972     # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
6973     # would be better.
6974     output_verbose_link_cmd='func_echo_all'
6975    
6976     # Archives containing C++ object files must be created using
6977     # "CC -xar", where "CC" is the Sun C++ compiler. This is
6978     # necessary to make sure instantiated templates are included
6979     # in the archive.
6980     _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6981     ;;
6982     esac
6983     ;;
6984     esac
6985     ;;
6986    
6987     lynxos*)
6988     # FIXME: insert proper C++ library support
6989     _LT_TAGVAR(ld_shlibs, $1)=no
6990     ;;
6991    
6992     m88k*)
6993     # FIXME: insert proper C++ library support
6994     _LT_TAGVAR(ld_shlibs, $1)=no
6995     ;;
6996    
6997     mvs*)
6998     case $cc_basename in
6999     cxx*)
7000     # FIXME: insert proper C++ library support
7001     _LT_TAGVAR(ld_shlibs, $1)=no
7002     ;;
7003     *)
7004     # FIXME: insert proper C++ library support
7005     _LT_TAGVAR(ld_shlibs, $1)=no
7006     ;;
7007     esac
7008     ;;
7009    
7010     netbsd*)
7011     if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
7012     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
7013     wlarc=
7014     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7015     _LT_TAGVAR(hardcode_direct, $1)=yes
7016     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7017     fi
7018     # Workaround some broken pre-1.5 toolchains
7019     output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
7020     ;;
7021    
7022     *nto* | *qnx*)
7023     _LT_TAGVAR(ld_shlibs, $1)=yes
7024     ;;
7025    
7026     openbsd* | bitrig*)
7027     if test -f /usr/libexec/ld.so; then
7028     _LT_TAGVAR(hardcode_direct, $1)=yes
7029     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7030     _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
7031     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7032     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7033     if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then
7034     _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'
7035     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
7036     _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
7037     fi
7038     output_verbose_link_cmd=func_echo_all
7039     else
7040     _LT_TAGVAR(ld_shlibs, $1)=no
7041     fi
7042     ;;
7043    
7044     osf3* | osf4* | osf5*)
7045     case $cc_basename in
7046     KCC*)
7047     # Kuck and Associates, Inc. (KAI) C++ Compiler
7048    
7049     # KCC will only create a shared library if the output file
7050     # ends with ".so" (or ".sl" for HP-UX), so rename the library
7051     # to its proper name (with version) after linking.
7052     _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'
7053    
7054     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7055     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7056    
7057     # Archives containing C++ object files must be created using
7058     # the KAI C++ compiler.
7059     case $host in
7060     osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
7061     *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
7062     esac
7063     ;;
7064     RCC*)
7065     # Rational C++ 2.4.1
7066     # FIXME: insert proper C++ library support
7067     _LT_TAGVAR(ld_shlibs, $1)=no
7068     ;;
7069     cxx*)
7070     case $host in
7071     osf3*)
7072     _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
7073     _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'
7074     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7075     ;;
7076     *)
7077     _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7078     _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'
7079     _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
7080     echo "-hidden">> $lib.exp~
7081     $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~
7082     $RM $lib.exp'
7083     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7084     ;;
7085     esac
7086    
7087     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7088    
7089     # Commands to make compiler produce verbose output that lists
7090     # what "hidden" libraries, object files and flags are used when
7091     # linking a shared library.
7092     #
7093     # There doesn't appear to be a way to prevent this compiler from
7094     # explicitly linking system object files so we need to strip them
7095     # from the output so that they don't get included in the library
7096     # dependencies.
7097     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"'
7098     ;;
7099     *)
7100     if test yes,no = "$GXX,$with_gnu_ld"; then
7101     _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
7102     case $host in
7103     osf3*)
7104     _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'
7105     ;;
7106     *)
7107     _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'
7108     ;;
7109     esac
7110    
7111     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7112     _LT_TAGVAR(hardcode_libdir_separator, $1)=:
7113    
7114     # Commands to make compiler produce verbose output that lists
7115     # what "hidden" libraries, object files and flags are used when
7116     # linking a shared library.
7117     output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7118    
7119     else
7120     # FIXME: insert proper C++ library support
7121     _LT_TAGVAR(ld_shlibs, $1)=no
7122     fi
7123     ;;
7124     esac
7125     ;;
7126    
7127     psos*)
7128     # FIXME: insert proper C++ library support
7129     _LT_TAGVAR(ld_shlibs, $1)=no
7130     ;;
7131    
7132     sunos4*)
7133     case $cc_basename in
7134     CC*)
7135     # Sun C++ 4.x
7136     # FIXME: insert proper C++ library support
7137     _LT_TAGVAR(ld_shlibs, $1)=no
7138     ;;
7139     lcc*)
7140     # Lucid
7141     # FIXME: insert proper C++ library support
7142     _LT_TAGVAR(ld_shlibs, $1)=no
7143     ;;
7144     *)
7145     # FIXME: insert proper C++ library support
7146     _LT_TAGVAR(ld_shlibs, $1)=no
7147     ;;
7148     esac
7149     ;;
7150    
7151     solaris*)
7152     case $cc_basename in
7153     CC* | sunCC*)
7154     # Sun C++ 4.2, 5.x and Centerline C++
7155     _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
7156     _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
7157     _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7158     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7159     $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'
7160    
7161     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7162     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7163     case $host_os in
7164     solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7165     *)
7166     # The compiler driver will combine and reorder linker options,
7167     # but understands '-z linker_flag'.
7168     # Supported since Solaris 2.6 (maybe 2.5.1?)
7169     _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7170     ;;
7171     esac
7172     _LT_TAGVAR(link_all_deplibs, $1)=yes
7173    
7174     output_verbose_link_cmd='func_echo_all'
7175    
7176     # Archives containing C++ object files must be created using
7177     # "CC -xar", where "CC" is the Sun C++ compiler. This is
7178     # necessary to make sure instantiated templates are included
7179     # in the archive.
7180     _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
7181     ;;
7182     gcx*)
7183     # Green Hills C++ Compiler
7184     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
7185    
7186     # The C++ compiler must be used to create the archive.
7187     _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
7188     ;;
7189     *)
7190     # GNU C++ compiler with Solaris linker
7191     if test yes,no = "$GXX,$with_gnu_ld"; then
7192     _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs'
7193     if $CC --version | $GREP -v '^2\.7' > /dev/null; then
7194     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
7195     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7196     $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7197    
7198     # Commands to make compiler produce verbose output that lists
7199     # what "hidden" libraries, object files and flags are used when
7200     # linking a shared library.
7201     output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7202     else
7203     # g++ 2.7 appears to require '-G' NOT '-shared' on this
7204     # platform.
7205     _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
7206     _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
7207     $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7208    
7209     # Commands to make compiler produce verbose output that lists
7210     # what "hidden" libraries, object files and flags are used when
7211     # linking a shared library.
7212     output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
7213     fi
7214    
7215     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir'
7216     case $host_os in
7217     solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7218     *)
7219     _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
7220     ;;
7221     esac
7222     fi
7223     ;;
7224     esac
7225     ;;
7226    
7227     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7228     _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
7229     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7230     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7231     runpath_var='LD_RUN_PATH'
7232    
7233     case $cc_basename in
7234     CC*)
7235     _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7236     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7237     ;;
7238     *)
7239     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7240     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7241     ;;
7242     esac
7243 michael 5052 ;;
7244 michael 5059
7245     sysv5* | sco3.2v5* | sco5v6*)
7246     # Note: We CANNOT use -z defs as we might desire, because we do not
7247     # link with -lc, and that would cause any symbols used from libc to
7248     # always be unresolved, which means just about no library would
7249     # ever link correctly. If we're not using GNU ld we use -z text
7250     # though, which does catch some bad symbols but isn't as heavy-handed
7251     # as -z defs.
7252     _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
7253     _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
7254     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7255     _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
7256     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
7257     _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
7258     _LT_TAGVAR(link_all_deplibs, $1)=yes
7259     _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
7260     runpath_var='LD_RUN_PATH'
7261    
7262     case $cc_basename in
7263     CC*)
7264     _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7265     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7266     _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
7267     '"$_LT_TAGVAR(old_archive_cmds, $1)"
7268     _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
7269     '"$_LT_TAGVAR(reload_cmds, $1)"
7270     ;;
7271     *)
7272     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7273     _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7274     ;;
7275     esac
7276     ;;
7277    
7278     tandem*)
7279     case $cc_basename in
7280     NCC*)
7281     # NonStop-UX NCC 3.20
7282     # FIXME: insert proper C++ library support
7283     _LT_TAGVAR(ld_shlibs, $1)=no
7284     ;;
7285     *)
7286     # FIXME: insert proper C++ library support
7287     _LT_TAGVAR(ld_shlibs, $1)=no
7288     ;;
7289     esac
7290     ;;
7291    
7292     vxworks*)
7293     # FIXME: insert proper C++ library support
7294     _LT_TAGVAR(ld_shlibs, $1)=no
7295     ;;
7296    
7297     *)
7298     # FIXME: insert proper C++ library support
7299     _LT_TAGVAR(ld_shlibs, $1)=no
7300     ;;
7301 michael 5052 esac
7302 michael 5059
7303     AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
7304     test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
7305    
7306     _LT_TAGVAR(GCC, $1)=$GXX
7307     _LT_TAGVAR(LD, $1)=$LD
7308    
7309     ## CAVEAT EMPTOR:
7310     ## There is no encapsulation within the following macros, do not change
7311     ## the running order or otherwise move them around unless you know exactly
7312     ## what you are doing...
7313     _LT_SYS_HIDDEN_LIBDEPS($1)
7314     _LT_COMPILER_PIC($1)
7315     _LT_COMPILER_C_O($1)
7316     _LT_COMPILER_FILE_LOCKS($1)
7317     _LT_LINKER_SHLIBS($1)
7318     _LT_SYS_DYNAMIC_LINKER($1)
7319     _LT_LINKER_HARDCODE_LIBPATH($1)
7320    
7321     _LT_CONFIG($1)
7322     fi # test -n "$compiler"
7323    
7324     CC=$lt_save_CC
7325     CFLAGS=$lt_save_CFLAGS
7326     LDCXX=$LD
7327     LD=$lt_save_LD
7328     GCC=$lt_save_GCC
7329     with_gnu_ld=$lt_save_with_gnu_ld
7330     lt_cv_path_LDCXX=$lt_cv_path_LD
7331     lt_cv_path_LD=$lt_save_path_LD
7332     lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
7333     lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
7334     fi # test yes != "$_lt_caught_CXX_error"
7335    
7336     AC_LANG_POP
7337     ])# _LT_LANG_CXX_CONFIG
7338    
7339    
7340     # _LT_FUNC_STRIPNAME_CNF
7341     # ----------------------
7342     # func_stripname_cnf prefix suffix name
7343     # strip PREFIX and SUFFIX off of NAME.
7344     # PREFIX and SUFFIX must not contain globbing or regex special
7345     # characters, hashes, percent signs, but SUFFIX may contain a leading
7346     # dot (in which case that matches only a dot).
7347     #
7348     # This function is identical to the (non-XSI) version of func_stripname,
7349     # except this one can be used by m4 code that may be executed by configure,
7350     # rather than the libtool script.
7351     m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
7352     AC_REQUIRE([_LT_DECL_SED])
7353     AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
7354     func_stripname_cnf ()
7355     {
7356     case @S|@2 in
7357     .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;;
7358     *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;;
7359     esac
7360     } # func_stripname_cnf
7361     ])# _LT_FUNC_STRIPNAME_CNF
7362    
7363     # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
7364     # ---------------------------------
7365     # Figure out "hidden" library dependencies from verbose
7366     # compiler output when linking a shared library.
7367     # Parse the compiler output and extract the necessary
7368     # objects, libraries and library flags.
7369     m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
7370     [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
7371     AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
7372     # Dependencies to place before and after the object being linked:
7373     _LT_TAGVAR(predep_objects, $1)=
7374     _LT_TAGVAR(postdep_objects, $1)=
7375     _LT_TAGVAR(predeps, $1)=
7376     _LT_TAGVAR(postdeps, $1)=
7377     _LT_TAGVAR(compiler_lib_search_path, $1)=
7378    
7379     dnl we can't use the lt_simple_compile_test_code here,
7380     dnl because it contains code intended for an executable,
7381     dnl not a library. It's possible we should let each
7382     dnl tag define a new lt_????_link_test_code variable,
7383     dnl but it's only used here...
7384     m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
7385     int a;
7386     void foo (void) { a = 0; }
7387     _LT_EOF
7388     ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
7389     class Foo
7390     {
7391     public:
7392     Foo (void) { a = 0; }
7393     private:
7394     int a;
7395     };
7396     _LT_EOF
7397     ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
7398     subroutine foo
7399     implicit none
7400     integer*4 a
7401     a=0
7402     return
7403     end
7404     _LT_EOF
7405     ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
7406     subroutine foo
7407     implicit none
7408     integer a
7409     a=0
7410     return
7411     end
7412     _LT_EOF
7413     ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
7414     public class foo {
7415     private int a;
7416     public void bar (void) {
7417     a = 0;
7418     }
7419     };
7420     _LT_EOF
7421     ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
7422     package foo
7423     func foo() {
7424     }
7425     _LT_EOF
7426     ])
7427    
7428     _lt_libdeps_save_CFLAGS=$CFLAGS
7429     case "$CC $CFLAGS " in #(
7430     *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
7431     *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
7432     *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
7433     esac
7434    
7435     dnl Parse the compiler output and extract the necessary
7436     dnl objects, libraries and library flags.
7437     if AC_TRY_EVAL(ac_compile); then
7438     # Parse the compiler output and extract the necessary
7439     # objects, libraries and library flags.
7440    
7441     # Sentinel used to keep track of whether or not we are before
7442     # the conftest object file.
7443     pre_test_object_deps_done=no
7444    
7445     for p in `eval "$output_verbose_link_cmd"`; do
7446     case $prev$p in
7447    
7448     -L* | -R* | -l*)
7449     # Some compilers place space between "-{L,R}" and the path.
7450     # Remove the space.
7451     if test x-L = "$p" ||
7452     test x-R = "$p"; then
7453     prev=$p
7454     continue
7455     fi
7456    
7457     # Expand the sysroot to ease extracting the directories later.
7458     if test -z "$prev"; then
7459     case $p in
7460     -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
7461     -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
7462     -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
7463     esac
7464     fi
7465     case $p in
7466     =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
7467     esac
7468     if test no = "$pre_test_object_deps_done"; then
7469     case $prev in
7470     -L | -R)
7471     # Internal compiler library paths should come after those
7472     # provided the user. The postdeps already come after the
7473     # user supplied libs so there is no need to process them.
7474     if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7475     _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p
7476     else
7477     _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p"
7478     fi
7479     ;;
7480     # The "-l" case would never come before the object being
7481     # linked, so don't bother handling this case.
7482     esac
7483     else
7484     if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7485     _LT_TAGVAR(postdeps, $1)=$prev$p
7486     else
7487     _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p"
7488     fi
7489     fi
7490     prev=
7491     ;;
7492    
7493     *.lto.$objext) ;; # Ignore GCC LTO objects
7494     *.$objext)
7495     # This assumes that the test object file only shows up
7496     # once in the compiler output.
7497     if test "$p" = "conftest.$objext"; then
7498     pre_test_object_deps_done=yes
7499     continue
7500     fi
7501    
7502     if test no = "$pre_test_object_deps_done"; then
7503     if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
7504     _LT_TAGVAR(predep_objects, $1)=$p
7505     else
7506     _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
7507     fi
7508     else
7509     if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
7510     _LT_TAGVAR(postdep_objects, $1)=$p
7511     else
7512     _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
7513     fi
7514     fi
7515     ;;
7516    
7517     *) ;; # Ignore the rest.
7518    
7519     esac
7520     done
7521    
7522     # Clean up.
7523     rm -f a.out a.exe
7524     else
7525     echo "libtool.m4: error: problem compiling $1 test program"
7526     fi
7527    
7528     $RM -f confest.$objext
7529     CFLAGS=$_lt_libdeps_save_CFLAGS
7530    
7531     # PORTME: override above test on systems where it is broken
7532     m4_if([$1], [CXX],
7533     [case $host_os in
7534     interix[[3-9]]*)
7535     # Interix 3.5 installs completely hosed .la files for C++, so rather than
7536     # hack all around it, let's just trust "g++" to DTRT.
7537     _LT_TAGVAR(predep_objects,$1)=
7538     _LT_TAGVAR(postdep_objects,$1)=
7539     _LT_TAGVAR(postdeps,$1)=
7540 michael 5052 ;;
7541 michael 5059
7542     linux*)
7543     case `$CC -V 2>&1 | sed 5q` in
7544     *Sun\ C*)
7545     # Sun C++ 5.9
7546    
7547     # The more standards-conforming stlport4 library is
7548     # incompatible with the Cstd library. Avoid specifying
7549     # it if it's in CXXFLAGS. Ignore libCrun as
7550     # -library=stlport4 depends on it.
7551     case " $CXX $CXXFLAGS " in
7552     *" -library=stlport4 "*)
7553     solaris_use_stlport4=yes
7554     ;;
7555     esac
7556    
7557     if test yes != "$solaris_use_stlport4"; then
7558     _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7559     fi
7560     ;;
7561     esac
7562     ;;
7563    
7564     solaris*)
7565     case $cc_basename in
7566     CC* | sunCC*)
7567     # The more standards-conforming stlport4 library is
7568     # incompatible with the Cstd library. Avoid specifying
7569     # it if it's in CXXFLAGS. Ignore libCrun as
7570     # -library=stlport4 depends on it.
7571     case " $CXX $CXXFLAGS " in
7572     *" -library=stlport4 "*)
7573     solaris_use_stlport4=yes
7574     ;;
7575     esac
7576    
7577     # Adding this requires a known-good setup of shared libraries for
7578     # Sun compiler versions before 5.6, else PIC objects from an old
7579     # archive will be linked into the output, leading to subtle bugs.
7580     if test yes != "$solaris_use_stlport4"; then
7581     _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7582     fi
7583     ;;
7584     esac
7585     ;;
7586 michael 5052 esac
7587 michael 5059 ])
7588 michael 5052
7589 michael 5059 case " $_LT_TAGVAR(postdeps, $1) " in
7590     *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
7591     esac
7592     _LT_TAGVAR(compiler_lib_search_dirs, $1)=
7593     if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
7594     _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'`
7595     fi
7596     _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
7597     [The directories searched by this compiler when creating a shared library])
7598     _LT_TAGDECL([], [predep_objects], [1],
7599     [Dependencies to place before and after the objects being linked to
7600     create a shared library])
7601     _LT_TAGDECL([], [postdep_objects], [1])
7602     _LT_TAGDECL([], [predeps], [1])
7603     _LT_TAGDECL([], [postdeps], [1])
7604     _LT_TAGDECL([], [compiler_lib_search_path], [1],
7605     [The library search path used internally by the compiler when linking
7606     a shared library])
7607     ])# _LT_SYS_HIDDEN_LIBDEPS
7608 michael 5052
7609    
7610 michael 5059 # _LT_LANG_F77_CONFIG([TAG])
7611     # --------------------------
7612     # Ensure that the configuration variables for a Fortran 77 compiler are
7613     # suitably defined. These variables are subsequently used by _LT_CONFIG
7614     # to write the compiler configuration to 'libtool'.
7615     m4_defun([_LT_LANG_F77_CONFIG],
7616     [AC_LANG_PUSH(Fortran 77)
7617     if test -z "$F77" || test no = "$F77"; then
7618     _lt_disable_F77=yes
7619     fi
7620 michael 5052
7621 michael 5059 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7622     _LT_TAGVAR(allow_undefined_flag, $1)=
7623     _LT_TAGVAR(always_export_symbols, $1)=no
7624     _LT_TAGVAR(archive_expsym_cmds, $1)=
7625     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7626     _LT_TAGVAR(hardcode_direct, $1)=no
7627     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7628     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7629     _LT_TAGVAR(hardcode_libdir_separator, $1)=
7630     _LT_TAGVAR(hardcode_minus_L, $1)=no
7631     _LT_TAGVAR(hardcode_automatic, $1)=no
7632     _LT_TAGVAR(inherit_rpath, $1)=no
7633     _LT_TAGVAR(module_cmds, $1)=
7634     _LT_TAGVAR(module_expsym_cmds, $1)=
7635     _LT_TAGVAR(link_all_deplibs, $1)=unknown
7636     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7637     _LT_TAGVAR(reload_flag, $1)=$reload_flag
7638     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7639     _LT_TAGVAR(no_undefined_flag, $1)=
7640     _LT_TAGVAR(whole_archive_flag_spec, $1)=
7641     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7642 michael 5052
7643 michael 5059 # Source file extension for f77 test sources.
7644     ac_ext=f
7645 michael 5052
7646 michael 5059 # Object file extension for compiled f77 test sources.
7647     objext=o
7648     _LT_TAGVAR(objext, $1)=$objext
7649 michael 5052
7650 michael 5059 # No sense in running all these tests if we already determined that
7651     # the F77 compiler isn't working. Some variables (like enable_shared)
7652     # are currently assumed to apply to all compilers on this platform,
7653     # and will be corrupted by setting them based on a non-working compiler.
7654     if test yes != "$_lt_disable_F77"; then
7655     # Code to be used in simple compile tests
7656     lt_simple_compile_test_code="\
7657     subroutine t
7658     return
7659     end
7660     "
7661 michael 5052
7662 michael 5059 # Code to be used in simple link tests
7663     lt_simple_link_test_code="\
7664     program t
7665     end
7666     "
7667    
7668     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7669     _LT_TAG_COMPILER
7670    
7671     # save warnings/boilerplate of simple test code
7672     _LT_COMPILER_BOILERPLATE
7673     _LT_LINKER_BOILERPLATE
7674    
7675     # Allow CC to be a program name with arguments.
7676     lt_save_CC=$CC
7677     lt_save_GCC=$GCC
7678     lt_save_CFLAGS=$CFLAGS
7679     CC=${F77-"f77"}
7680     CFLAGS=$FFLAGS
7681     compiler=$CC
7682     _LT_TAGVAR(compiler, $1)=$CC
7683     _LT_CC_BASENAME([$compiler])
7684     GCC=$G77
7685     if test -n "$compiler"; then
7686     AC_MSG_CHECKING([if libtool supports shared libraries])
7687     AC_MSG_RESULT([$can_build_shared])
7688    
7689     AC_MSG_CHECKING([whether to build shared libraries])
7690     test no = "$can_build_shared" && enable_shared=no
7691    
7692     # On AIX, shared libraries and static libraries use the same namespace, and
7693     # are all built from PIC.
7694     case $host_os in
7695     aix3*)
7696     test yes = "$enable_shared" && enable_static=no
7697     if test -n "$RANLIB"; then
7698     archive_cmds="$archive_cmds~\$RANLIB \$lib"
7699     postinstall_cmds='$RANLIB $lib'
7700     fi
7701     ;;
7702     aix[[4-9]]*)
7703     if test ia64 != "$host_cpu"; then
7704     case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
7705     yes,aix,yes) ;; # shared object as lib.so file only
7706     yes,svr4,*) ;; # shared object as lib.so archive member only
7707     yes,*) enable_static=no ;; # shared object in lib.a archive as well
7708     esac
7709     fi
7710     ;;
7711     esac
7712     AC_MSG_RESULT([$enable_shared])
7713    
7714     AC_MSG_CHECKING([whether to build static libraries])
7715     # Make sure either enable_shared or enable_static is yes.
7716     test yes = "$enable_shared" || enable_static=yes
7717     AC_MSG_RESULT([$enable_static])
7718    
7719     _LT_TAGVAR(GCC, $1)=$G77
7720     _LT_TAGVAR(LD, $1)=$LD
7721    
7722     ## CAVEAT EMPTOR:
7723     ## There is no encapsulation within the following macros, do not change
7724     ## the running order or otherwise move them around unless you know exactly
7725     ## what you are doing...
7726     _LT_COMPILER_PIC($1)
7727     _LT_COMPILER_C_O($1)
7728     _LT_COMPILER_FILE_LOCKS($1)
7729     _LT_LINKER_SHLIBS($1)
7730     _LT_SYS_DYNAMIC_LINKER($1)
7731     _LT_LINKER_HARDCODE_LIBPATH($1)
7732    
7733     _LT_CONFIG($1)
7734     fi # test -n "$compiler"
7735    
7736     GCC=$lt_save_GCC
7737     CC=$lt_save_CC
7738     CFLAGS=$lt_save_CFLAGS
7739     fi # test yes != "$_lt_disable_F77"
7740    
7741     AC_LANG_POP
7742     ])# _LT_LANG_F77_CONFIG
7743    
7744    
7745     # _LT_LANG_FC_CONFIG([TAG])
7746     # -------------------------
7747     # Ensure that the configuration variables for a Fortran compiler are
7748     # suitably defined. These variables are subsequently used by _LT_CONFIG
7749     # to write the compiler configuration to 'libtool'.
7750     m4_defun([_LT_LANG_FC_CONFIG],
7751     [AC_LANG_PUSH(Fortran)
7752    
7753     if test -z "$FC" || test no = "$FC"; then
7754     _lt_disable_FC=yes
7755     fi
7756    
7757     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7758     _LT_TAGVAR(allow_undefined_flag, $1)=
7759     _LT_TAGVAR(always_export_symbols, $1)=no
7760     _LT_TAGVAR(archive_expsym_cmds, $1)=
7761     _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7762     _LT_TAGVAR(hardcode_direct, $1)=no
7763     _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7764     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7765     _LT_TAGVAR(hardcode_libdir_separator, $1)=
7766     _LT_TAGVAR(hardcode_minus_L, $1)=no
7767     _LT_TAGVAR(hardcode_automatic, $1)=no
7768     _LT_TAGVAR(inherit_rpath, $1)=no
7769     _LT_TAGVAR(module_cmds, $1)=
7770     _LT_TAGVAR(module_expsym_cmds, $1)=
7771     _LT_TAGVAR(link_all_deplibs, $1)=unknown
7772     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7773     _LT_TAGVAR(reload_flag, $1)=$reload_flag
7774     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7775     _LT_TAGVAR(no_undefined_flag, $1)=
7776     _LT_TAGVAR(whole_archive_flag_spec, $1)=
7777     _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7778    
7779     # Source file extension for fc test sources.
7780     ac_ext=${ac_fc_srcext-f}
7781    
7782     # Object file extension for compiled fc test sources.
7783     objext=o
7784     _LT_TAGVAR(objext, $1)=$objext
7785    
7786     # No sense in running all these tests if we already determined that
7787     # the FC compiler isn't working. Some variables (like enable_shared)
7788     # are currently assumed to apply to all compilers on this platform,
7789     # and will be corrupted by setting them based on a non-working compiler.
7790     if test yes != "$_lt_disable_FC"; then
7791     # Code to be used in simple compile tests
7792     lt_simple_compile_test_code="\
7793     subroutine t
7794     return
7795     end
7796     "
7797    
7798     # Code to be used in simple link tests
7799     lt_simple_link_test_code="\
7800     program t
7801     end
7802     "
7803    
7804     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7805     _LT_TAG_COMPILER
7806    
7807     # save warnings/boilerplate of simple test code
7808     _LT_COMPILER_BOILERPLATE
7809     _LT_LINKER_BOILERPLATE
7810    
7811     # Allow CC to be a program name with arguments.
7812     lt_save_CC=$CC
7813     lt_save_GCC=$GCC
7814     lt_save_CFLAGS=$CFLAGS
7815     CC=${FC-"f95"}
7816     CFLAGS=$FCFLAGS
7817     compiler=$CC
7818     GCC=$ac_cv_fc_compiler_gnu
7819    
7820     _LT_TAGVAR(compiler, $1)=$CC
7821     _LT_CC_BASENAME([$compiler])
7822    
7823     if test -n "$compiler"; then
7824     AC_MSG_CHECKING([if libtool supports shared libraries])
7825     AC_MSG_RESULT([$can_build_shared])
7826    
7827     AC_MSG_CHECKING([whether to build shared libraries])
7828     test no = "$can_build_shared" && enable_shared=no
7829    
7830     # On AIX, shared libraries and static libraries use the same namespace, and
7831     # are all built from PIC.
7832     case $host_os in
7833     aix3*)
7834     test yes = "$enable_shared" && enable_static=no
7835     if test -n "$RANLIB"; then
7836     archive_cmds="$archive_cmds~\$RANLIB \$lib"
7837     postinstall_cmds='$RANLIB $lib'
7838     fi
7839     ;;
7840     aix[[4-9]]*)
7841     if test ia64 != "$host_cpu"; then
7842     case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
7843     yes,aix,yes) ;; # shared object as lib.so file only
7844     yes,svr4,*) ;; # shared object as lib.so archive member only
7845     yes,*) enable_static=no ;; # shared object in lib.a archive as well
7846     esac
7847     fi
7848     ;;
7849     esac
7850     AC_MSG_RESULT([$enable_shared])
7851    
7852     AC_MSG_CHECKING([whether to build static libraries])
7853     # Make sure either enable_shared or enable_static is yes.
7854     test yes = "$enable_shared" || enable_static=yes
7855     AC_MSG_RESULT([$enable_static])
7856    
7857     _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu
7858     _LT_TAGVAR(LD, $1)=$LD
7859    
7860     ## CAVEAT EMPTOR:
7861     ## There is no encapsulation within the following macros, do not change
7862     ## the running order or otherwise move them around unless you know exactly
7863     ## what you are doing...
7864     _LT_SYS_HIDDEN_LIBDEPS($1)
7865     _LT_COMPILER_PIC($1)
7866     _LT_COMPILER_C_O($1)
7867     _LT_COMPILER_FILE_LOCKS($1)
7868     _LT_LINKER_SHLIBS($1)
7869     _LT_SYS_DYNAMIC_LINKER($1)
7870     _LT_LINKER_HARDCODE_LIBPATH($1)
7871    
7872     _LT_CONFIG($1)
7873     fi # test -n "$compiler"
7874    
7875     GCC=$lt_save_GCC
7876     CC=$lt_save_CC
7877     CFLAGS=$lt_save_CFLAGS
7878     fi # test yes != "$_lt_disable_FC"
7879    
7880     AC_LANG_POP
7881     ])# _LT_LANG_FC_CONFIG
7882    
7883    
7884     # _LT_LANG_GCJ_CONFIG([TAG])
7885     # --------------------------
7886     # Ensure that the configuration variables for the GNU Java Compiler compiler
7887     # are suitably defined. These variables are subsequently used by _LT_CONFIG
7888     # to write the compiler configuration to 'libtool'.
7889     m4_defun([_LT_LANG_GCJ_CONFIG],
7890     [AC_REQUIRE([LT_PROG_GCJ])dnl
7891     AC_LANG_SAVE
7892    
7893     # Source file extension for Java test sources.
7894     ac_ext=java
7895    
7896     # Object file extension for compiled Java test sources.
7897     objext=o
7898     _LT_TAGVAR(objext, $1)=$objext
7899    
7900     # Code to be used in simple compile tests
7901     lt_simple_compile_test_code="class foo {}"
7902    
7903     # Code to be used in simple link tests
7904     lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
7905    
7906     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7907     _LT_TAG_COMPILER
7908    
7909     # save warnings/boilerplate of simple test code
7910     _LT_COMPILER_BOILERPLATE
7911     _LT_LINKER_BOILERPLATE
7912    
7913     # Allow CC to be a program name with arguments.
7914     lt_save_CC=$CC
7915     lt_save_CFLAGS=$CFLAGS
7916     lt_save_GCC=$GCC
7917     GCC=yes
7918     CC=${GCJ-"gcj"}
7919     CFLAGS=$GCJFLAGS
7920     compiler=$CC
7921     _LT_TAGVAR(compiler, $1)=$CC
7922     _LT_TAGVAR(LD, $1)=$LD
7923     _LT_CC_BASENAME([$compiler])
7924    
7925     # GCJ did not exist at the time GCC didn't implicitly link libc in.
7926     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7927    
7928     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7929     _LT_TAGVAR(reload_flag, $1)=$reload_flag
7930     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7931    
7932     if test -n "$compiler"; then
7933     _LT_COMPILER_NO_RTTI($1)
7934     _LT_COMPILER_PIC($1)
7935     _LT_COMPILER_C_O($1)
7936     _LT_COMPILER_FILE_LOCKS($1)
7937     _LT_LINKER_SHLIBS($1)
7938     _LT_LINKER_HARDCODE_LIBPATH($1)
7939    
7940     _LT_CONFIG($1)
7941     fi
7942    
7943     AC_LANG_RESTORE
7944    
7945     GCC=$lt_save_GCC
7946     CC=$lt_save_CC
7947     CFLAGS=$lt_save_CFLAGS
7948     ])# _LT_LANG_GCJ_CONFIG
7949    
7950    
7951     # _LT_LANG_GO_CONFIG([TAG])
7952     # --------------------------
7953     # Ensure that the configuration variables for the GNU Go compiler
7954     # are suitably defined. These variables are subsequently used by _LT_CONFIG
7955     # to write the compiler configuration to 'libtool'.
7956     m4_defun([_LT_LANG_GO_CONFIG],
7957     [AC_REQUIRE([LT_PROG_GO])dnl
7958     AC_LANG_SAVE
7959    
7960     # Source file extension for Go test sources.
7961     ac_ext=go
7962    
7963     # Object file extension for compiled Go test sources.
7964     objext=o
7965     _LT_TAGVAR(objext, $1)=$objext
7966    
7967     # Code to be used in simple compile tests
7968     lt_simple_compile_test_code="package main; func main() { }"
7969    
7970     # Code to be used in simple link tests
7971     lt_simple_link_test_code='package main; func main() { }'
7972    
7973     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7974     _LT_TAG_COMPILER
7975    
7976     # save warnings/boilerplate of simple test code
7977     _LT_COMPILER_BOILERPLATE
7978     _LT_LINKER_BOILERPLATE
7979    
7980     # Allow CC to be a program name with arguments.
7981     lt_save_CC=$CC
7982     lt_save_CFLAGS=$CFLAGS
7983     lt_save_GCC=$GCC
7984     GCC=yes
7985     CC=${GOC-"gccgo"}
7986     CFLAGS=$GOFLAGS
7987     compiler=$CC
7988     _LT_TAGVAR(compiler, $1)=$CC
7989     _LT_TAGVAR(LD, $1)=$LD
7990     _LT_CC_BASENAME([$compiler])
7991    
7992     # Go did not exist at the time GCC didn't implicitly link libc in.
7993     _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7994    
7995     _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7996     _LT_TAGVAR(reload_flag, $1)=$reload_flag
7997     _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
7998    
7999     if test -n "$compiler"; then
8000     _LT_COMPILER_NO_RTTI($1)
8001     _LT_COMPILER_PIC($1)
8002     _LT_COMPILER_C_O($1)
8003     _LT_COMPILER_FILE_LOCKS($1)
8004     _LT_LINKER_SHLIBS($1)
8005     _LT_LINKER_HARDCODE_LIBPATH($1)
8006    
8007     _LT_CONFIG($1)
8008     fi
8009    
8010     AC_LANG_RESTORE
8011    
8012     GCC=$lt_save_GCC
8013     CC=$lt_save_CC
8014     CFLAGS=$lt_save_CFLAGS
8015     ])# _LT_LANG_GO_CONFIG
8016    
8017    
8018     # _LT_LANG_RC_CONFIG([TAG])
8019     # -------------------------
8020     # Ensure that the configuration variables for the Windows resource compiler
8021     # are suitably defined. These variables are subsequently used by _LT_CONFIG
8022     # to write the compiler configuration to 'libtool'.
8023     m4_defun([_LT_LANG_RC_CONFIG],
8024     [AC_REQUIRE([LT_PROG_RC])dnl
8025     AC_LANG_SAVE
8026    
8027     # Source file extension for RC test sources.
8028     ac_ext=rc
8029    
8030     # Object file extension for compiled RC test sources.
8031     objext=o
8032     _LT_TAGVAR(objext, $1)=$objext
8033    
8034     # Code to be used in simple compile tests
8035     lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8036    
8037     # Code to be used in simple link tests
8038     lt_simple_link_test_code=$lt_simple_compile_test_code
8039    
8040     # ltmain only uses $CC for tagged configurations so make sure $CC is set.
8041     _LT_TAG_COMPILER
8042    
8043     # save warnings/boilerplate of simple test code
8044     _LT_COMPILER_BOILERPLATE
8045     _LT_LINKER_BOILERPLATE
8046    
8047     # Allow CC to be a program name with arguments.
8048     lt_save_CC=$CC
8049     lt_save_CFLAGS=$CFLAGS
8050     lt_save_GCC=$GCC
8051     GCC=
8052     CC=${RC-"windres"}
8053     CFLAGS=
8054     compiler=$CC
8055     _LT_TAGVAR(compiler, $1)=$CC
8056     _LT_CC_BASENAME([$compiler])
8057     _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8058    
8059     if test -n "$compiler"; then
8060     :
8061     _LT_CONFIG($1)
8062     fi
8063    
8064     GCC=$lt_save_GCC
8065     AC_LANG_RESTORE
8066     CC=$lt_save_CC
8067     CFLAGS=$lt_save_CFLAGS
8068     ])# _LT_LANG_RC_CONFIG
8069    
8070    
8071     # LT_PROG_GCJ
8072     # -----------
8073     AC_DEFUN([LT_PROG_GCJ],
8074     [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
8075     [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
8076     [AC_CHECK_TOOL(GCJ, gcj,)
8077     test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2"
8078     AC_SUBST(GCJFLAGS)])])[]dnl
8079 michael 5052 ])
8080    
8081 michael 5059 # Old name:
8082     AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
8083     dnl aclocal-1.4 backwards compatibility:
8084     dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
8085    
8086    
8087     # LT_PROG_GO
8088     # ----------
8089     AC_DEFUN([LT_PROG_GO],
8090     [AC_CHECK_TOOL(GOC, gccgo,)
8091 michael 5052 ])
8092    
8093 michael 5059
8094     # LT_PROG_RC
8095     # ----------
8096     AC_DEFUN([LT_PROG_RC],
8097     [AC_CHECK_TOOL(RC, windres,)
8098     ])
8099    
8100     # Old name:
8101     AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
8102     dnl aclocal-1.4 backwards compatibility:
8103     dnl AC_DEFUN([LT_AC_PROG_RC], [])
8104    
8105    
8106     # _LT_DECL_EGREP
8107     # --------------
8108     # If we don't have a new enough Autoconf to choose the best grep
8109     # available, choose the one first in the user's PATH.
8110     m4_defun([_LT_DECL_EGREP],
8111     [AC_REQUIRE([AC_PROG_EGREP])dnl
8112     AC_REQUIRE([AC_PROG_FGREP])dnl
8113     test -z "$GREP" && GREP=grep
8114     _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
8115     _LT_DECL([], [EGREP], [1], [An ERE matcher])
8116     _LT_DECL([], [FGREP], [1], [A literal string matcher])
8117     dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
8118     AC_SUBST([GREP])
8119     ])
8120    
8121    
8122     # _LT_DECL_OBJDUMP
8123     # --------------
8124     # If we don't have a new enough Autoconf to choose the best objdump
8125     # available, choose the one first in the user's PATH.
8126     m4_defun([_LT_DECL_OBJDUMP],
8127     [AC_CHECK_TOOL(OBJDUMP, objdump, false)
8128     test -z "$OBJDUMP" && OBJDUMP=objdump
8129     _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
8130     AC_SUBST([OBJDUMP])
8131     ])
8132    
8133     # _LT_DECL_DLLTOOL
8134     # ----------------
8135     # Ensure DLLTOOL variable is set.
8136     m4_defun([_LT_DECL_DLLTOOL],
8137     [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8138     test -z "$DLLTOOL" && DLLTOOL=dlltool
8139     _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
8140     AC_SUBST([DLLTOOL])
8141     ])
8142    
8143     # _LT_DECL_SED
8144     # ------------
8145     # Check for a fully-functional sed program, that truncates
8146     # as few characters as possible. Prefer GNU sed if found.
8147     m4_defun([_LT_DECL_SED],
8148     [AC_PROG_SED
8149     test -z "$SED" && SED=sed
8150     Xsed="$SED -e 1s/^X//"
8151     _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
8152     _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
8153     [Sed that helps us avoid accidentally triggering echo(1) options like -n])
8154     ])# _LT_DECL_SED
8155    
8156     m4_ifndef([AC_PROG_SED], [
8157 michael 5052 # NOTE: This macro has been submitted for inclusion into #
8158     # GNU Autoconf as AC_PROG_SED. When it is available in #
8159     # a released version of Autoconf we should remove this #
8160     # macro and use it instead. #
8161 michael 5059
8162     m4_defun([AC_PROG_SED],
8163 michael 5052 [AC_MSG_CHECKING([for a sed that does not truncate output])
8164     AC_CACHE_VAL(lt_cv_path_SED,
8165     [# Loop through the user's path and test for sed and gsed.
8166     # Then use that list of sed's as ones to test for truncation.
8167     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8168     for as_dir in $PATH
8169     do
8170     IFS=$as_save_IFS
8171     test -z "$as_dir" && as_dir=.
8172     for lt_ac_prog in sed gsed; do
8173     for ac_exec_ext in '' $ac_executable_extensions; do
8174     if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
8175     lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
8176     fi
8177     done
8178     done
8179     done
8180 michael 5059 IFS=$as_save_IFS
8181 michael 5052 lt_ac_max=0
8182     lt_ac_count=0
8183     # Add /usr/xpg4/bin/sed as it is typically found on Solaris
8184     # along with /bin/sed that truncates output.
8185     for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
8186 michael 5059 test ! -f "$lt_ac_sed" && continue
8187 michael 5052 cat /dev/null > conftest.in
8188     lt_ac_count=0
8189     echo $ECHO_N "0123456789$ECHO_C" >conftest.in
8190     # Check for GNU sed and select it if it is found.
8191     if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
8192     lt_cv_path_SED=$lt_ac_sed
8193     break
8194     fi
8195     while true; do
8196     cat conftest.in conftest.in >conftest.tmp
8197     mv conftest.tmp conftest.in
8198     cp conftest.in conftest.nl
8199     echo >>conftest.nl
8200     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
8201     cmp -s conftest.out conftest.nl || break
8202     # 10000 chars as input seems more than enough
8203 michael 5059 test 10 -lt "$lt_ac_count" && break
8204 michael 5052 lt_ac_count=`expr $lt_ac_count + 1`
8205 michael 5059 if test "$lt_ac_count" -gt "$lt_ac_max"; then
8206 michael 5052 lt_ac_max=$lt_ac_count
8207     lt_cv_path_SED=$lt_ac_sed
8208     fi
8209     done
8210     done
8211     ])
8212     SED=$lt_cv_path_SED
8213 michael 5059 AC_SUBST([SED])
8214 michael 5052 AC_MSG_RESULT([$SED])
8215 michael 5059 ])#AC_PROG_SED
8216     ])#m4_ifndef
8217    
8218     # Old name:
8219     AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
8220     dnl aclocal-1.4 backwards compatibility:
8221     dnl AC_DEFUN([LT_AC_PROG_SED], [])
8222    
8223    
8224     # _LT_CHECK_SHELL_FEATURES
8225     # ------------------------
8226     # Find out whether the shell is Bourne or XSI compatible,
8227     # or has some other useful features.
8228     m4_defun([_LT_CHECK_SHELL_FEATURES],
8229     [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8230     lt_unset=unset
8231     else
8232     lt_unset=false
8233     fi
8234     _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
8235    
8236     # test EBCDIC or ASCII
8237     case `echo X|tr X '\101'` in
8238     A) # ASCII based system
8239     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8240     lt_SP2NL='tr \040 \012'
8241     lt_NL2SP='tr \015\012 \040\040'
8242     ;;
8243     *) # EBCDIC based system
8244     lt_SP2NL='tr \100 \n'
8245     lt_NL2SP='tr \r\n \100\100'
8246     ;;
8247     esac
8248     _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
8249     _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
8250     ])# _LT_CHECK_SHELL_FEATURES
8251    
8252    
8253     # _LT_PATH_CONVERSION_FUNCTIONS
8254     # -----------------------------
8255     # Determine what file name conversion functions should be used by
8256     # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
8257     # for certain cross-compile configurations and native mingw.
8258     m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
8259     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8260     AC_REQUIRE([AC_CANONICAL_BUILD])dnl
8261     AC_MSG_CHECKING([how to convert $build file names to $host format])
8262     AC_CACHE_VAL(lt_cv_to_host_file_cmd,
8263     [case $host in
8264     *-*-mingw* )
8265     case $build in
8266     *-*-mingw* ) # actually msys
8267     lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8268     ;;
8269     *-*-cygwin* )
8270     lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8271     ;;
8272     * ) # otherwise, assume *nix
8273     lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8274     ;;
8275     esac
8276     ;;
8277     *-*-cygwin* )
8278     case $build in
8279     *-*-mingw* ) # actually msys
8280     lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8281     ;;
8282     *-*-cygwin* )
8283     lt_cv_to_host_file_cmd=func_convert_file_noop
8284     ;;
8285     * ) # otherwise, assume *nix
8286     lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8287     ;;
8288     esac
8289     ;;
8290     * ) # unhandled hosts (and "normal" native builds)
8291     lt_cv_to_host_file_cmd=func_convert_file_noop
8292     ;;
8293     esac
8294 michael 5052 ])
8295 michael 5059 to_host_file_cmd=$lt_cv_to_host_file_cmd
8296     AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
8297     _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
8298     [0], [convert $build file names to $host format])dnl
8299 michael 5052
8300 michael 5059 AC_MSG_CHECKING([how to convert $build file names to toolchain format])
8301     AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
8302     [#assume ordinary cross tools, or native build.
8303     lt_cv_to_tool_file_cmd=func_convert_file_noop
8304     case $host in
8305     *-*-mingw* )
8306     case $build in
8307     *-*-mingw* ) # actually msys
8308     lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8309     ;;
8310     esac
8311     ;;
8312     esac
8313     ])
8314     to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8315     AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
8316     _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
8317     [0], [convert $build files to toolchain format])dnl
8318     ])# _LT_PATH_CONVERSION_FUNCTIONS
8319    
8320     # Helper functions for option handling. -*- Autoconf -*-
8321 michael 5052 #
8322 michael 5059 # Copyright (C) 2004-2005, 2007-2009, 2011-2014 Free Software
8323     # Foundation, Inc.
8324     # Written by Gary V. Vaughan, 2004
8325     #
8326     # This file is free software; the Free Software Foundation gives
8327     # unlimited permission to copy and/or distribute it, with or without
8328     # modifications, as long as this notice is preserved.
8329    
8330     # serial 8 ltoptions.m4
8331    
8332     # This is to help aclocal find these macros, as it can't see m4_define.
8333     AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
8334    
8335    
8336     # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
8337     # ------------------------------------------
8338     m4_define([_LT_MANGLE_OPTION],
8339     [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
8340    
8341    
8342     # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
8343     # ---------------------------------------
8344     # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
8345     # matching handler defined, dispatch to it. Other OPTION-NAMEs are
8346     # saved as a flag.
8347     m4_define([_LT_SET_OPTION],
8348     [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
8349     m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
8350     _LT_MANGLE_DEFUN([$1], [$2]),
8351     [m4_warning([Unknown $1 option '$2'])])[]dnl
8352     ])
8353    
8354    
8355     # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
8356     # ------------------------------------------------------------
8357     # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
8358     m4_define([_LT_IF_OPTION],
8359     [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
8360    
8361    
8362     # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
8363     # -------------------------------------------------------
8364     # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
8365     # are set.
8366     m4_define([_LT_UNLESS_OPTIONS],
8367     [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8368     [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
8369     [m4_define([$0_found])])])[]dnl
8370     m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
8371     ])[]dnl
8372     ])
8373    
8374    
8375     # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
8376     # ----------------------------------------
8377     # OPTION-LIST is a space-separated list of Libtool options associated
8378     # with MACRO-NAME. If any OPTION has a matching handler declared with
8379     # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
8380     # the unknown option and exit.
8381     m4_defun([_LT_SET_OPTIONS],
8382     [# Set options
8383     m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8384     [_LT_SET_OPTION([$1], _LT_Option)])
8385    
8386     m4_if([$1],[LT_INIT],[
8387     dnl
8388     dnl Simply set some default values (i.e off) if boolean options were not
8389     dnl specified:
8390     _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
8391     ])
8392     _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
8393     ])
8394     dnl
8395     dnl If no reference was made to various pairs of opposing options, then
8396     dnl we run the default mode handler for the pair. For example, if neither
8397     dnl 'shared' nor 'disable-shared' was passed, we enable building of shared
8398     dnl archives by default:
8399     _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
8400     _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
8401     _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
8402     _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
8403     [_LT_ENABLE_FAST_INSTALL])
8404     _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4],
8405     [_LT_WITH_AIX_SONAME([aix])])
8406     ])
8407     ])# _LT_SET_OPTIONS
8408    
8409    
8410    
8411     # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
8412     # -----------------------------------------
8413     m4_define([_LT_MANGLE_DEFUN],
8414     [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
8415    
8416    
8417     # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
8418     # -----------------------------------------------
8419     m4_define([LT_OPTION_DEFINE],
8420     [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
8421     ])# LT_OPTION_DEFINE
8422    
8423    
8424     # dlopen
8425     # ------
8426     LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
8427     ])
8428    
8429     AU_DEFUN([AC_LIBTOOL_DLOPEN],
8430     [_LT_SET_OPTION([LT_INIT], [dlopen])
8431     AC_DIAGNOSE([obsolete],
8432     [$0: Remove this warning and the call to _LT_SET_OPTION when you
8433     put the 'dlopen' option into LT_INIT's first parameter.])
8434     ])
8435    
8436     dnl aclocal-1.4 backwards compatibility:
8437     dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
8438    
8439    
8440     # win32-dll
8441     # ---------
8442     # Declare package support for building win32 dll's.
8443     LT_OPTION_DEFINE([LT_INIT], [win32-dll],
8444     [enable_win32_dll=yes
8445    
8446     case $host in
8447     *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
8448     AC_CHECK_TOOL(AS, as, false)
8449     AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8450     AC_CHECK_TOOL(OBJDUMP, objdump, false)
8451     ;;
8452     esac
8453    
8454     test -z "$AS" && AS=as
8455     _LT_DECL([], [AS], [1], [Assembler program])dnl
8456    
8457     test -z "$DLLTOOL" && DLLTOOL=dlltool
8458     _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
8459    
8460     test -z "$OBJDUMP" && OBJDUMP=objdump
8461     _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
8462     ])# win32-dll
8463    
8464     AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
8465     [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8466     _LT_SET_OPTION([LT_INIT], [win32-dll])
8467     AC_DIAGNOSE([obsolete],
8468     [$0: Remove this warning and the call to _LT_SET_OPTION when you
8469     put the 'win32-dll' option into LT_INIT's first parameter.])
8470     ])
8471    
8472     dnl aclocal-1.4 backwards compatibility:
8473     dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
8474    
8475    
8476     # _LT_ENABLE_SHARED([DEFAULT])
8477     # ----------------------------
8478     # implement the --enable-shared flag, and supports the 'shared' and
8479     # 'disable-shared' LT_INIT options.
8480     # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
8481     m4_define([_LT_ENABLE_SHARED],
8482     [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
8483     AC_ARG_ENABLE([shared],
8484     [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
8485     [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
8486     [p=${PACKAGE-default}
8487     case $enableval in
8488     yes) enable_shared=yes ;;
8489     no) enable_shared=no ;;
8490     *)
8491     enable_shared=no
8492     # Look at the argument we got. We use all the common list separators.
8493     lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
8494     for pkg in $enableval; do
8495     IFS=$lt_save_ifs
8496     if test "X$pkg" = "X$p"; then
8497     enable_shared=yes
8498     fi
8499     done
8500     IFS=$lt_save_ifs
8501     ;;
8502     esac],
8503     [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
8504    
8505     _LT_DECL([build_libtool_libs], [enable_shared], [0],
8506     [Whether or not to build shared libraries])
8507     ])# _LT_ENABLE_SHARED
8508    
8509     LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
8510     LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
8511    
8512     # Old names:
8513     AC_DEFUN([AC_ENABLE_SHARED],
8514     [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
8515     ])
8516    
8517     AC_DEFUN([AC_DISABLE_SHARED],
8518     [_LT_SET_OPTION([LT_INIT], [disable-shared])
8519     ])
8520    
8521     AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
8522     AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
8523    
8524     dnl aclocal-1.4 backwards compatibility:
8525     dnl AC_DEFUN([AM_ENABLE_SHARED], [])
8526     dnl AC_DEFUN([AM_DISABLE_SHARED], [])
8527    
8528    
8529    
8530     # _LT_ENABLE_STATIC([DEFAULT])
8531     # ----------------------------
8532     # implement the --enable-static flag, and support the 'static' and
8533     # 'disable-static' LT_INIT options.
8534     # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
8535     m4_define([_LT_ENABLE_STATIC],
8536     [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
8537     AC_ARG_ENABLE([static],
8538     [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
8539     [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
8540     [p=${PACKAGE-default}
8541     case $enableval in
8542     yes) enable_static=yes ;;
8543     no) enable_static=no ;;
8544     *)
8545     enable_static=no
8546     # Look at the argument we got. We use all the common list separators.
8547     lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
8548     for pkg in $enableval; do
8549     IFS=$lt_save_ifs
8550     if test "X$pkg" = "X$p"; then
8551     enable_static=yes
8552     fi
8553     done
8554     IFS=$lt_save_ifs
8555     ;;
8556     esac],
8557     [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
8558    
8559     _LT_DECL([build_old_libs], [enable_static], [0],
8560     [Whether or not to build static libraries])
8561     ])# _LT_ENABLE_STATIC
8562    
8563     LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
8564     LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
8565    
8566     # Old names:
8567     AC_DEFUN([AC_ENABLE_STATIC],
8568     [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
8569     ])
8570    
8571     AC_DEFUN([AC_DISABLE_STATIC],
8572     [_LT_SET_OPTION([LT_INIT], [disable-static])
8573     ])
8574    
8575     AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
8576     AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
8577    
8578     dnl aclocal-1.4 backwards compatibility:
8579     dnl AC_DEFUN([AM_ENABLE_STATIC], [])
8580     dnl AC_DEFUN([AM_DISABLE_STATIC], [])
8581    
8582    
8583    
8584     # _LT_ENABLE_FAST_INSTALL([DEFAULT])
8585     # ----------------------------------
8586     # implement the --enable-fast-install flag, and support the 'fast-install'
8587     # and 'disable-fast-install' LT_INIT options.
8588     # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
8589     m4_define([_LT_ENABLE_FAST_INSTALL],
8590     [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
8591     AC_ARG_ENABLE([fast-install],
8592     [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
8593     [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
8594     [p=${PACKAGE-default}
8595     case $enableval in
8596     yes) enable_fast_install=yes ;;
8597     no) enable_fast_install=no ;;
8598     *)
8599     enable_fast_install=no
8600     # Look at the argument we got. We use all the common list separators.
8601     lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
8602     for pkg in $enableval; do
8603     IFS=$lt_save_ifs
8604     if test "X$pkg" = "X$p"; then
8605     enable_fast_install=yes
8606     fi
8607     done
8608     IFS=$lt_save_ifs
8609     ;;
8610     esac],
8611     [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
8612    
8613     _LT_DECL([fast_install], [enable_fast_install], [0],
8614     [Whether or not to optimize for fast installation])dnl
8615     ])# _LT_ENABLE_FAST_INSTALL
8616    
8617     LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
8618     LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
8619    
8620     # Old names:
8621     AU_DEFUN([AC_ENABLE_FAST_INSTALL],
8622     [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
8623     AC_DIAGNOSE([obsolete],
8624     [$0: Remove this warning and the call to _LT_SET_OPTION when you put
8625     the 'fast-install' option into LT_INIT's first parameter.])
8626     ])
8627    
8628     AU_DEFUN([AC_DISABLE_FAST_INSTALL],
8629     [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
8630     AC_DIAGNOSE([obsolete],
8631     [$0: Remove this warning and the call to _LT_SET_OPTION when you put
8632     the 'disable-fast-install' option into LT_INIT's first parameter.])
8633     ])
8634    
8635     dnl aclocal-1.4 backwards compatibility:
8636     dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
8637     dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
8638    
8639    
8640     # _LT_WITH_AIX_SONAME([DEFAULT])
8641     # ----------------------------------
8642     # implement the --with-aix-soname flag, and support the `aix-soname=aix'
8643     # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT
8644     # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'.
8645     m4_define([_LT_WITH_AIX_SONAME],
8646     [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl
8647     shared_archive_member_spec=
8648     case $host,$enable_shared in
8649     power*-*-aix[[5-9]]*,yes)
8650     AC_MSG_CHECKING([which variant of shared library versioning to provide])
8651     AC_ARG_WITH([aix-soname],
8652     [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
8653     [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])],
8654     [case $withval in
8655     aix|svr4|both)
8656     ;;
8657     *)
8658     AC_MSG_ERROR([Unknown argument to --with-aix-soname])
8659     ;;
8660     esac
8661     lt_cv_with_aix_soname=$with_aix_soname],
8662     [AC_CACHE_VAL([lt_cv_with_aix_soname],
8663     [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)
8664     with_aix_soname=$lt_cv_with_aix_soname])
8665     AC_MSG_RESULT([$with_aix_soname])
8666     if test aix != "$with_aix_soname"; then
8667     # For the AIX way of multilib, we name the shared archive member
8668     # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
8669     # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
8670     # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
8671     # the AIX toolchain works better with OBJECT_MODE set (default 32).
8672     if test 64 = "${OBJECT_MODE-32}"; then
8673     shared_archive_member_spec=shr_64
8674     else
8675     shared_archive_member_spec=shr
8676     fi
8677     fi
8678     ;;
8679     *)
8680     with_aix_soname=aix
8681     ;;
8682     esac
8683    
8684     _LT_DECL([], [shared_archive_member_spec], [0],
8685     [Shared archive member basename, for filename based shared library versioning on AIX])dnl
8686     ])# _LT_WITH_AIX_SONAME
8687    
8688     LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])])
8689     LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])])
8690     LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])])
8691    
8692    
8693     # _LT_WITH_PIC([MODE])
8694     # --------------------
8695     # implement the --with-pic flag, and support the 'pic-only' and 'no-pic'
8696     # LT_INIT options.
8697     # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'.
8698     m4_define([_LT_WITH_PIC],
8699     [AC_ARG_WITH([pic],
8700     [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
8701     [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
8702     [lt_p=${PACKAGE-default}
8703     case $withval in
8704     yes|no) pic_mode=$withval ;;
8705     *)
8706     pic_mode=default
8707     # Look at the argument we got. We use all the common list separators.
8708     lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
8709     for lt_pkg in $withval; do
8710     IFS=$lt_save_ifs
8711     if test "X$lt_pkg" = "X$lt_p"; then
8712     pic_mode=yes
8713     fi
8714     done
8715     IFS=$lt_save_ifs
8716     ;;
8717     esac],
8718     [pic_mode=m4_default([$1], [default])])
8719    
8720     _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
8721     ])# _LT_WITH_PIC
8722    
8723     LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
8724     LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
8725    
8726     # Old name:
8727     AU_DEFUN([AC_LIBTOOL_PICMODE],
8728     [_LT_SET_OPTION([LT_INIT], [pic-only])
8729     AC_DIAGNOSE([obsolete],
8730     [$0: Remove this warning and the call to _LT_SET_OPTION when you
8731     put the 'pic-only' option into LT_INIT's first parameter.])
8732     ])
8733    
8734     dnl aclocal-1.4 backwards compatibility:
8735     dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
8736    
8737    
8738     m4_define([_LTDL_MODE], [])
8739     LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
8740     [m4_define([_LTDL_MODE], [nonrecursive])])
8741     LT_OPTION_DEFINE([LTDL_INIT], [recursive],
8742     [m4_define([_LTDL_MODE], [recursive])])
8743     LT_OPTION_DEFINE([LTDL_INIT], [subproject],
8744     [m4_define([_LTDL_MODE], [subproject])])
8745    
8746     m4_define([_LTDL_TYPE], [])
8747     LT_OPTION_DEFINE([LTDL_INIT], [installable],
8748     [m4_define([_LTDL_TYPE], [installable])])
8749     LT_OPTION_DEFINE([LTDL_INIT], [convenience],
8750     [m4_define([_LTDL_TYPE], [convenience])])
8751    
8752     # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
8753     #
8754     # Copyright (C) 2004-2005, 2007-2008, 2011-2014 Free Software
8755     # Foundation, Inc.
8756     # Written by Gary V. Vaughan, 2004
8757     #
8758     # This file is free software; the Free Software Foundation gives
8759     # unlimited permission to copy and/or distribute it, with or without
8760     # modifications, as long as this notice is preserved.
8761    
8762     # serial 6 ltsugar.m4
8763    
8764     # This is to help aclocal find these macros, as it can't see m4_define.
8765     AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
8766    
8767    
8768     # lt_join(SEP, ARG1, [ARG2...])
8769     # -----------------------------
8770     # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
8771     # associated separator.
8772     # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
8773     # versions in m4sugar had bugs.
8774     m4_define([lt_join],
8775     [m4_if([$#], [1], [],
8776     [$#], [2], [[$2]],
8777     [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
8778     m4_define([_lt_join],
8779     [m4_if([$#$2], [2], [],
8780     [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
8781    
8782    
8783     # lt_car(LIST)
8784     # lt_cdr(LIST)
8785     # ------------
8786     # Manipulate m4 lists.
8787     # These macros are necessary as long as will still need to support
8788     # Autoconf-2.59, which quotes differently.
8789     m4_define([lt_car], [[$1]])
8790     m4_define([lt_cdr],
8791     [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
8792     [$#], 1, [],
8793     [m4_dquote(m4_shift($@))])])
8794     m4_define([lt_unquote], $1)
8795    
8796    
8797     # lt_append(MACRO-NAME, STRING, [SEPARATOR])
8798     # ------------------------------------------
8799     # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'.
8800     # Note that neither SEPARATOR nor STRING are expanded; they are appended
8801     # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
8802     # No SEPARATOR is output if MACRO-NAME was previously undefined (different
8803     # than defined and empty).
8804     #
8805     # This macro is needed until we can rely on Autoconf 2.62, since earlier
8806     # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
8807     m4_define([lt_append],
8808     [m4_define([$1],
8809     m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
8810    
8811    
8812    
8813     # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
8814     # ----------------------------------------------------------
8815     # Produce a SEP delimited list of all paired combinations of elements of
8816     # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
8817     # has the form PREFIXmINFIXSUFFIXn.
8818     # Needed until we can rely on m4_combine added in Autoconf 2.62.
8819     m4_define([lt_combine],
8820     [m4_if(m4_eval([$# > 3]), [1],
8821     [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
8822     [[m4_foreach([_Lt_prefix], [$2],
8823     [m4_foreach([_Lt_suffix],
8824     ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
8825     [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
8826    
8827    
8828     # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
8829     # -----------------------------------------------------------------------
8830     # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
8831     # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
8832     m4_define([lt_if_append_uniq],
8833     [m4_ifdef([$1],
8834     [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
8835     [lt_append([$1], [$2], [$3])$4],
8836     [$5])],
8837     [lt_append([$1], [$2], [$3])$4])])
8838    
8839    
8840     # lt_dict_add(DICT, KEY, VALUE)
8841     # -----------------------------
8842     m4_define([lt_dict_add],
8843     [m4_define([$1($2)], [$3])])
8844    
8845    
8846     # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
8847     # --------------------------------------------
8848     m4_define([lt_dict_add_subkey],
8849     [m4_define([$1($2:$3)], [$4])])
8850    
8851    
8852     # lt_dict_fetch(DICT, KEY, [SUBKEY])
8853     # ----------------------------------
8854     m4_define([lt_dict_fetch],
8855     [m4_ifval([$3],
8856     m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
8857     m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
8858    
8859    
8860     # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
8861     # -----------------------------------------------------------------
8862     m4_define([lt_if_dict_fetch],
8863     [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
8864     [$5],
8865     [$6])])
8866    
8867    
8868     # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
8869     # --------------------------------------------------------------
8870     m4_define([lt_dict_filter],
8871     [m4_if([$5], [], [],
8872     [lt_join(m4_quote(m4_default([$4], [[, ]])),
8873     lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
8874     [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
8875     ])
8876    
8877     # ltversion.m4 -- version numbers -*- Autoconf -*-
8878     #
8879     # Copyright (C) 2004, 2011-2014 Free Software Foundation, Inc.
8880     # Written by Scott James Remnant, 2004
8881     #
8882     # This file is free software; the Free Software Foundation gives
8883     # unlimited permission to copy and/or distribute it, with or without
8884     # modifications, as long as this notice is preserved.
8885    
8886     # @configure_input@
8887    
8888     # serial 4151 ltversion.m4
8889     # This file is part of GNU Libtool
8890    
8891     m4_define([LT_PACKAGE_VERSION], [2.4.4])
8892     m4_define([LT_PACKAGE_REVISION], [2.4.4])
8893    
8894     AC_DEFUN([LTVERSION_VERSION],
8895     [macro_version='2.4.4'
8896     macro_revision='2.4.4'
8897     _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
8898     _LT_DECL(, macro_revision, 0)
8899     ])
8900    
8901     # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
8902     #
8903     # Copyright (C) 2004-2005, 2007, 2009, 2011-2014 Free Software
8904     # Foundation, Inc.
8905     # Written by Scott James Remnant, 2004.
8906     #
8907     # This file is free software; the Free Software Foundation gives
8908     # unlimited permission to copy and/or distribute it, with or without
8909     # modifications, as long as this notice is preserved.
8910    
8911     # serial 5 lt~obsolete.m4
8912    
8913     # These exist entirely to fool aclocal when bootstrapping libtool.
8914     #
8915     # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN),
8916     # which have later been changed to m4_define as they aren't part of the
8917     # exported API, or moved to Autoconf or Automake where they belong.
8918     #
8919     # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
8920     # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
8921     # using a macro with the same name in our local m4/libtool.m4 it'll
8922     # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
8923     # and doesn't know about Autoconf macros at all.)
8924     #
8925     # So we provide this file, which has a silly filename so it's always
8926     # included after everything else. This provides aclocal with the
8927     # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
8928     # because those macros already exist, or will be overwritten later.
8929     # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
8930     #
8931     # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
8932     # Yes, that means every name once taken will need to remain here until
8933     # we give up compatibility with versions before 1.7, at which point
8934     # we need to keep only those names which we still refer to.
8935    
8936     # This is to help aclocal find these macros, as it can't see m4_define.
8937     AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
8938    
8939     m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
8940     m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
8941     m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
8942     m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
8943     m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
8944     m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
8945     m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
8946     m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
8947     m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
8948     m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
8949     m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
8950     m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
8951     m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
8952     m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
8953     m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
8954     m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
8955     m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
8956     m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
8957     m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
8958     m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
8959     m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
8960     m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
8961     m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
8962     m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
8963     m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
8964     m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
8965     m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
8966     m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
8967     m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
8968     m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
8969     m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
8970     m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
8971     m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
8972     m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
8973     m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
8974     m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
8975     m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
8976     m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
8977     m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
8978     m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
8979     m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
8980     m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
8981     m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
8982     m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
8983     m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
8984     m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
8985     m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
8986     m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
8987     m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
8988     m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
8989     m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
8990     m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
8991     m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
8992     m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
8993     m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
8994     m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
8995     m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
8996     m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
8997     m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
8998     m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
8999     m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
9000    
9001 michael 5353 # Copyright (C) 2002-2014 Free Software Foundation, Inc.
9002 michael 5059 #
9003 michael 5052 # This file is free software; the Free Software Foundation
9004     # gives unlimited permission to copy and/or distribute it,
9005     # with or without modifications, as long as this notice is preserved.
9006    
9007     # AM_AUTOMAKE_VERSION(VERSION)
9008     # ----------------------------
9009     # Automake X.Y traces this macro to ensure aclocal.m4 has been
9010     # generated from the m4 files accompanying Automake X.Y.
9011 michael 5059 # (This private macro should not be called outside this file.)
9012     AC_DEFUN([AM_AUTOMAKE_VERSION],
9013 michael 5353 [am__api_version='1.15'
9014 michael 5059 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
9015     dnl require some minimum version. Point them to the right macro.
9016 michael 5353 m4_if([$1], [1.15], [],
9017 michael 5059 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
9018     ])
9019 michael 5052
9020 michael 5059 # _AM_AUTOCONF_VERSION(VERSION)
9021     # -----------------------------
9022     # aclocal traces this macro to find the Autoconf version.
9023     # This is a private macro too. Using m4_define simplifies
9024     # the logic in aclocal, which can simply ignore this definition.
9025     m4_define([_AM_AUTOCONF_VERSION], [])
9026    
9027 michael 5052 # AM_SET_CURRENT_AUTOMAKE_VERSION
9028     # -------------------------------
9029 michael 5059 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
9030     # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
9031 michael 5052 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
9032 michael 5353 [AM_AUTOMAKE_VERSION([1.15])dnl
9033 michael 5059 m4_ifndef([AC_AUTOCONF_VERSION],
9034     [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
9035     _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
9036 michael 5052
9037     # AM_AUX_DIR_EXPAND -*- Autoconf -*-
9038    
9039 michael 5353 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
9040 michael 5052 #
9041     # This file is free software; the Free Software Foundation
9042     # gives unlimited permission to copy and/or distribute it,
9043     # with or without modifications, as long as this notice is preserved.
9044    
9045     # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
9046 michael 5059 # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
9047     # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
9048 michael 5052 #
9049     # Of course, Automake must honor this variable whenever it calls a
9050     # tool from the auxiliary directory. The problem is that $srcdir (and
9051     # therefore $ac_aux_dir as well) can be either absolute or relative,
9052     # depending on how configure is run. This is pretty annoying, since
9053     # it makes $ac_aux_dir quite unusable in subdirectories: in the top
9054     # source directory, any form will work fine, but in subdirectories a
9055     # relative path needs to be adjusted first.
9056     #
9057     # $ac_aux_dir/missing
9058     # fails when called from a subdirectory if $ac_aux_dir is relative
9059     # $top_srcdir/$ac_aux_dir/missing
9060     # fails if $ac_aux_dir is absolute,
9061     # fails when called from a subdirectory in a VPATH build with
9062     # a relative $ac_aux_dir
9063     #
9064     # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
9065     # are both prefixed by $srcdir. In an in-source build this is usually
9066 michael 5059 # harmless because $srcdir is '.', but things will broke when you
9067 michael 5052 # start a VPATH build or use an absolute $srcdir.
9068     #
9069     # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
9070     # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
9071     # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
9072     # and then we would define $MISSING as
9073     # MISSING="\${SHELL} $am_aux_dir/missing"
9074     # This will work as long as MISSING is not called from configure, because
9075     # unfortunately $(top_srcdir) has no meaning in configure.
9076     # However there are other variables, like CC, which are often used in
9077     # configure, and could therefore not use this "fixed" $ac_aux_dir.
9078     #
9079     # Another solution, used here, is to always expand $ac_aux_dir to an
9080     # absolute PATH. The drawback is that using absolute paths prevent a
9081     # configured tree to be moved without reconfiguration.
9082    
9083     AC_DEFUN([AM_AUX_DIR_EXPAND],
9084 michael 5353 [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
9085     # Expand $ac_aux_dir to an absolute path.
9086     am_aux_dir=`cd "$ac_aux_dir" && pwd`
9087 michael 5052 ])
9088    
9089     # AM_CONDITIONAL -*- Autoconf -*-
9090    
9091 michael 5353 # Copyright (C) 1997-2014 Free Software Foundation, Inc.
9092 michael 5052 #
9093     # This file is free software; the Free Software Foundation
9094     # gives unlimited permission to copy and/or distribute it,
9095     # with or without modifications, as long as this notice is preserved.
9096    
9097     # AM_CONDITIONAL(NAME, SHELL-CONDITION)
9098     # -------------------------------------
9099     # Define a conditional.
9100     AC_DEFUN([AM_CONDITIONAL],
9101 michael 5059 [AC_PREREQ([2.52])dnl
9102     m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
9103     [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
9104     AC_SUBST([$1_TRUE])dnl
9105     AC_SUBST([$1_FALSE])dnl
9106     _AM_SUBST_NOTMAKE([$1_TRUE])dnl
9107     _AM_SUBST_NOTMAKE([$1_FALSE])dnl
9108     m4_define([_AM_COND_VALUE_$1], [$2])dnl
9109 michael 5052 if $2; then
9110     $1_TRUE=
9111     $1_FALSE='#'
9112     else
9113     $1_TRUE='#'
9114     $1_FALSE=
9115     fi
9116     AC_CONFIG_COMMANDS_PRE(
9117     [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
9118     AC_MSG_ERROR([[conditional "$1" was never defined.
9119     Usually this means the macro was only invoked conditionally.]])
9120     fi])])
9121    
9122 michael 5353 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
9123 michael 5052 #
9124     # This file is free software; the Free Software Foundation
9125     # gives unlimited permission to copy and/or distribute it,
9126     # with or without modifications, as long as this notice is preserved.
9127    
9128    
9129 michael 5059 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
9130 michael 5052 # written in clear, in which case automake, when reading aclocal.m4,
9131     # will think it sees a *use*, and therefore will trigger all it's
9132     # C support machinery. Also note that it means that autoscan, seeing
9133     # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
9134    
9135    
9136     # _AM_DEPENDENCIES(NAME)
9137     # ----------------------
9138     # See how the compiler implements dependency checking.
9139 michael 5059 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
9140 michael 5052 # We try a few techniques and use that to set a single cache variable.
9141     #
9142     # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
9143     # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
9144     # dependency, and given that the user is not expected to run this macro,
9145     # just rely on AC_PROG_CC.
9146     AC_DEFUN([_AM_DEPENDENCIES],
9147     [AC_REQUIRE([AM_SET_DEPDIR])dnl
9148     AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
9149     AC_REQUIRE([AM_MAKE_INCLUDE])dnl
9150     AC_REQUIRE([AM_DEP_TRACK])dnl
9151    
9152 michael 5059 m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
9153     [$1], [CXX], [depcc="$CXX" am_compiler_list=],
9154     [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
9155     [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
9156     [$1], [UPC], [depcc="$UPC" am_compiler_list=],
9157     [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
9158     [depcc="$$1" am_compiler_list=])
9159 michael 5052
9160     AC_CACHE_CHECK([dependency style of $depcc],
9161     [am_cv_$1_dependencies_compiler_type],
9162     [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
9163     # We make a subdir and do the tests there. Otherwise we can end up
9164     # making bogus files that we don't know about and never remove. For
9165     # instance it was reported that on HP-UX the gcc test will end up
9166 michael 5059 # making a dummy file named 'D' -- because '-MD' means "put the output
9167     # in D".
9168     rm -rf conftest.dir
9169 michael 5052 mkdir conftest.dir
9170     # Copy depcomp to subdir because otherwise we won't find it if we're
9171     # using a relative directory.
9172     cp "$am_depcomp" conftest.dir
9173     cd conftest.dir
9174     # We will build objects and dependencies in a subdirectory because
9175     # it helps to detect inapplicable dependency modes. For instance
9176     # both Tru64's cc and ICC support -MD to output dependencies as a
9177     # side effect of compilation, but ICC will put the dependencies in
9178     # the current directory while Tru64 will put them in the object
9179     # directory.
9180     mkdir sub
9181    
9182     am_cv_$1_dependencies_compiler_type=none
9183     if test "$am_compiler_list" = ""; then
9184     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
9185     fi
9186 michael 5059 am__universal=false
9187     m4_case([$1], [CC],
9188     [case " $depcc " in #(
9189     *\ -arch\ *\ -arch\ *) am__universal=true ;;
9190     esac],
9191     [CXX],
9192     [case " $depcc " in #(
9193     *\ -arch\ *\ -arch\ *) am__universal=true ;;
9194     esac])
9195    
9196 michael 5052 for depmode in $am_compiler_list; do
9197     # Setup a source with many dependencies, because some compilers
9198     # like to wrap large dependency lists on column 80 (with \), and
9199     # we should not choose a depcomp mode which is confused by this.
9200     #
9201     # We need to recreate these files for each test, as the compiler may
9202     # overwrite some of them when testing with obscure command lines.
9203     # This happens at least with the AIX C compiler.
9204     : > sub/conftest.c
9205     for i in 1 2 3 4 5 6; do
9206     echo '#include "conftst'$i'.h"' >> sub/conftest.c
9207 michael 5059 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
9208     # Solaris 10 /bin/sh.
9209     echo '/* dummy */' > sub/conftst$i.h
9210 michael 5052 done
9211     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
9212    
9213 michael 5059 # We check with '-c' and '-o' for the sake of the "dashmstdout"
9214     # mode. It turns out that the SunPro C++ compiler does not properly
9215     # handle '-M -o', and we need to detect this. Also, some Intel
9216     # versions had trouble with output in subdirs.
9217     am__obj=sub/conftest.${OBJEXT-o}
9218     am__minus_obj="-o $am__obj"
9219 michael 5052 case $depmode in
9220 michael 5059 gcc)
9221     # This depmode causes a compiler race in universal mode.
9222     test "$am__universal" = false || continue
9223     ;;
9224 michael 5052 nosideeffect)
9225 michael 5059 # After this tag, mechanisms are not by side-effect, so they'll
9226     # only be used when explicitly requested.
9227 michael 5052 if test "x$enable_dependency_tracking" = xyes; then
9228     continue
9229     else
9230     break
9231     fi
9232     ;;
9233 michael 5059 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
9234     # This compiler won't grok '-c -o', but also, the minuso test has
9235     # not run yet. These depmodes are late enough in the game, and
9236     # so weak that their functioning should not be impacted.
9237     am__obj=conftest.${OBJEXT-o}
9238     am__minus_obj=
9239     ;;
9240 michael 5052 none) break ;;
9241     esac
9242     if depmode=$depmode \
9243 michael 5059 source=sub/conftest.c object=$am__obj \
9244 michael 5052 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
9245 michael 5059 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
9246 michael 5052 >/dev/null 2>conftest.err &&
9247 michael 5059 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
9248 michael 5052 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
9249 michael 5059 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
9250 michael 5052 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
9251     # icc doesn't choke on unknown options, it will just issue warnings
9252     # or remarks (even with -Werror). So we grep stderr for any message
9253     # that says an option was ignored or not supported.
9254     # When given -MP, icc 7.0 and 7.1 complain thusly:
9255     # icc: Command line warning: ignoring option '-M'; no argument required
9256     # The diagnosis changed in icc 8.0:
9257     # icc: Command line remark: option '-MP' not supported
9258     if (grep 'ignoring option' conftest.err ||
9259     grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
9260     am_cv_$1_dependencies_compiler_type=$depmode
9261     break
9262     fi
9263     fi
9264     done
9265    
9266     cd ..
9267     rm -rf conftest.dir
9268     else
9269     am_cv_$1_dependencies_compiler_type=none
9270     fi
9271     ])
9272     AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
9273     AM_CONDITIONAL([am__fastdep$1], [
9274     test "x$enable_dependency_tracking" != xno \
9275     && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
9276     ])
9277    
9278    
9279     # AM_SET_DEPDIR
9280     # -------------
9281     # Choose a directory name for dependency files.
9282 michael 5059 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
9283 michael 5052 AC_DEFUN([AM_SET_DEPDIR],
9284     [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
9285     AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
9286     ])
9287    
9288    
9289     # AM_DEP_TRACK
9290     # ------------
9291     AC_DEFUN([AM_DEP_TRACK],
9292 michael 5059 [AC_ARG_ENABLE([dependency-tracking], [dnl
9293     AS_HELP_STRING(
9294     [--enable-dependency-tracking],
9295     [do not reject slow dependency extractors])
9296     AS_HELP_STRING(
9297     [--disable-dependency-tracking],
9298     [speeds up one-time build])])
9299 michael 5052 if test "x$enable_dependency_tracking" != xno; then
9300     am_depcomp="$ac_aux_dir/depcomp"
9301     AMDEPBACKSLASH='\'
9302 michael 5059 am__nodep='_no'
9303 michael 5052 fi
9304     AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
9305 michael 5059 AC_SUBST([AMDEPBACKSLASH])dnl
9306     _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
9307     AC_SUBST([am__nodep])dnl
9308     _AM_SUBST_NOTMAKE([am__nodep])dnl
9309 michael 5052 ])
9310    
9311     # Generate code to set up dependency tracking. -*- Autoconf -*-
9312    
9313 michael 5353 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
9314 michael 5052 #
9315     # This file is free software; the Free Software Foundation
9316     # gives unlimited permission to copy and/or distribute it,
9317     # with or without modifications, as long as this notice is preserved.
9318    
9319    
9320     # _AM_OUTPUT_DEPENDENCY_COMMANDS
9321     # ------------------------------
9322     AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
9323 michael 5059 [{
9324     # Older Autoconf quotes --file arguments for eval, but not when files
9325     # are listed without --file. Let's play safe and only enable the eval
9326     # if we detect the quoting.
9327     case $CONFIG_FILES in
9328     *\'*) eval set x "$CONFIG_FILES" ;;
9329     *) set x $CONFIG_FILES ;;
9330     esac
9331     shift
9332     for mf
9333     do
9334     # Strip MF so we end up with the name of the file.
9335     mf=`echo "$mf" | sed -e 's/:.*$//'`
9336     # Check whether this is an Automake generated Makefile or not.
9337     # We used to match only the files named 'Makefile.in', but
9338     # some people rename them; so instead we look at the file content.
9339     # Grep'ing the first line is not enough: some people post-process
9340     # each Makefile.in and add a new line on top of each file to say so.
9341     # Grep'ing the whole file is not good either: AIX grep has a line
9342     # limit of 2048, but all sed's we know have understand at least 4000.
9343     if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
9344     dirpart=`AS_DIRNAME("$mf")`
9345     else
9346     continue
9347     fi
9348     # Extract the definition of DEPDIR, am__include, and am__quote
9349     # from the Makefile without running 'make'.
9350     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
9351     test -z "$DEPDIR" && continue
9352     am__include=`sed -n 's/^am__include = //p' < "$mf"`
9353     test -z "$am__include" && continue
9354     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
9355     # Find all dependency output files, they are included files with
9356     # $(DEPDIR) in their names. We invoke sed twice because it is the
9357     # simplest approach to changing $(DEPDIR) to its actual value in the
9358     # expansion.
9359     for file in `sed -n "
9360     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
9361     sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
9362     # Make sure the directory exists.
9363     test -f "$dirpart/$file" && continue
9364     fdir=`AS_DIRNAME(["$file"])`
9365     AS_MKDIR_P([$dirpart/$fdir])
9366     # echo "creating $dirpart/$file"
9367     echo '# dummy' > "$dirpart/$file"
9368     done
9369 michael 5052 done
9370 michael 5059 }
9371 michael 5052 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
9372    
9373    
9374     # AM_OUTPUT_DEPENDENCY_COMMANDS
9375     # -----------------------------
9376     # This macro should only be invoked once -- use via AC_REQUIRE.
9377     #
9378     # This code is only required when automatic dependency tracking
9379 michael 5059 # is enabled. FIXME. This creates each '.P' file that we will
9380 michael 5052 # need in order to bootstrap the dependency handling code.
9381     AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
9382     [AC_CONFIG_COMMANDS([depfiles],
9383     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
9384     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
9385     ])
9386    
9387     # Do all the work for Automake. -*- Autoconf -*-
9388    
9389 michael 5353 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
9390 michael 5052 #
9391     # This file is free software; the Free Software Foundation
9392     # gives unlimited permission to copy and/or distribute it,
9393     # with or without modifications, as long as this notice is preserved.
9394    
9395     # This macro actually does too much. Some checks are only needed if
9396     # your package does certain things. But this isn't really a big deal.
9397    
9398 michael 5059 dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
9399     m4_define([AC_PROG_CC],
9400     m4_defn([AC_PROG_CC])
9401     [_AM_PROG_CC_C_O
9402     ])
9403    
9404 michael 5052 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
9405     # AM_INIT_AUTOMAKE([OPTIONS])
9406     # -----------------------------------------------
9407     # The call with PACKAGE and VERSION arguments is the old style
9408     # call (pre autoconf-2.50), which is being phased out. PACKAGE
9409     # and VERSION should now be passed to AC_INIT and removed from
9410     # the call to AM_INIT_AUTOMAKE.
9411     # We support both call styles for the transition. After
9412     # the next Automake release, Autoconf can make the AC_INIT
9413     # arguments mandatory, and then we can depend on a new Autoconf
9414     # release and drop the old call support.
9415     AC_DEFUN([AM_INIT_AUTOMAKE],
9416 michael 5059 [AC_PREREQ([2.65])dnl
9417 michael 5052 dnl Autoconf wants to disallow AM_ names. We explicitly allow
9418     dnl the ones we care about.
9419     m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
9420     AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
9421     AC_REQUIRE([AC_PROG_INSTALL])dnl
9422 michael 5059 if test "`cd $srcdir && pwd`" != "`pwd`"; then
9423     # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
9424     # is not polluted with repeated "-I."
9425     AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
9426     # test to see if srcdir already configured
9427     if test -f $srcdir/config.status; then
9428     AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
9429     fi
9430 michael 5052 fi
9431    
9432     # test whether we have cygpath
9433     if test -z "$CYGPATH_W"; then
9434     if (cygpath --version) >/dev/null 2>/dev/null; then
9435     CYGPATH_W='cygpath -w'
9436     else
9437     CYGPATH_W=echo
9438     fi
9439     fi
9440     AC_SUBST([CYGPATH_W])
9441    
9442     # Define the identity of the package.
9443     dnl Distinguish between old-style and new-style calls.
9444     m4_ifval([$2],
9445 michael 5059 [AC_DIAGNOSE([obsolete],
9446     [$0: two- and three-arguments forms are deprecated.])
9447     m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
9448 michael 5052 AC_SUBST([PACKAGE], [$1])dnl
9449     AC_SUBST([VERSION], [$2])],
9450     [_AM_SET_OPTIONS([$1])dnl
9451 michael 5059 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
9452     m4_if(
9453     m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
9454     [ok:ok],,
9455     [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
9456 michael 5052 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
9457     AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
9458    
9459     _AM_IF_OPTION([no-define],,
9460 michael 5059 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
9461     AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
9462 michael 5052
9463     # Some tools Automake needs.
9464     AC_REQUIRE([AM_SANITY_CHECK])dnl
9465     AC_REQUIRE([AC_ARG_PROGRAM])dnl
9466 michael 5059 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
9467     AM_MISSING_PROG([AUTOCONF], [autoconf])
9468     AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
9469     AM_MISSING_PROG([AUTOHEADER], [autoheader])
9470     AM_MISSING_PROG([MAKEINFO], [makeinfo])
9471     AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
9472     AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
9473     AC_REQUIRE([AC_PROG_MKDIR_P])dnl
9474     # For better backward compatibility. To be removed once Automake 1.9.x
9475     # dies out for good. For more background, see:
9476     # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
9477     # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
9478     AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
9479 michael 5353 # We need awk for the "check" target (and possibly the TAP driver). The
9480     # system "awk" is bad on some platforms.
9481 michael 5052 AC_REQUIRE([AC_PROG_AWK])dnl
9482     AC_REQUIRE([AC_PROG_MAKE_SET])dnl
9483     AC_REQUIRE([AM_SET_LEADING_DOT])dnl
9484     _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
9485 michael 5059 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
9486     [_AM_PROG_TAR([v7])])])
9487 michael 5052 _AM_IF_OPTION([no-dependencies],,
9488     [AC_PROVIDE_IFELSE([AC_PROG_CC],
9489 michael 5059 [_AM_DEPENDENCIES([CC])],
9490     [m4_define([AC_PROG_CC],
9491     m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
9492 michael 5052 AC_PROVIDE_IFELSE([AC_PROG_CXX],
9493 michael 5059 [_AM_DEPENDENCIES([CXX])],
9494     [m4_define([AC_PROG_CXX],
9495     m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
9496     AC_PROVIDE_IFELSE([AC_PROG_OBJC],
9497     [_AM_DEPENDENCIES([OBJC])],
9498     [m4_define([AC_PROG_OBJC],
9499     m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
9500     AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
9501     [_AM_DEPENDENCIES([OBJCXX])],
9502     [m4_define([AC_PROG_OBJCXX],
9503     m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
9504 michael 5052 ])
9505 michael 5059 AC_REQUIRE([AM_SILENT_RULES])dnl
9506     dnl The testsuite driver may need to know about EXEEXT, so add the
9507     dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
9508     dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
9509     AC_CONFIG_COMMANDS_PRE(dnl
9510     [m4_provide_if([_AM_COMPILER_EXEEXT],
9511     [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
9512 michael 5052
9513 michael 5059 # POSIX will say in a future version that running "rm -f" with no argument
9514     # is OK; and we want to be able to make that assumption in our Makefile
9515     # recipes. So use an aggressive probe to check that the usage we want is
9516     # actually supported "in the wild" to an acceptable degree.
9517     # See automake bug#10828.
9518     # To make any issue more visible, cause the running configure to be aborted
9519     # by default if the 'rm' program in use doesn't match our expectations; the
9520     # user can still override this though.
9521     if rm -f && rm -fr && rm -rf; then : OK; else
9522     cat >&2 <<'END'
9523     Oops!
9524 michael 5052
9525 michael 5059 Your 'rm' program seems unable to run without file operands specified
9526     on the command line, even when the '-f' option is present. This is contrary
9527     to the behaviour of most rm programs out there, and not conforming with
9528     the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
9529    
9530     Please tell bug-automake@gnu.org about your system, including the value
9531     of your $PATH and any error possibly output before this message. This
9532     can help us improve future automake versions.
9533    
9534     END
9535     if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
9536     echo 'Configuration will proceed anyway, since you have set the' >&2
9537     echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
9538     echo >&2
9539     else
9540     cat >&2 <<'END'
9541     Aborting the configuration process, to ensure you take notice of the issue.
9542    
9543     You can download and install GNU coreutils to get an 'rm' implementation
9544     that behaves properly: <http://www.gnu.org/software/coreutils/>.
9545    
9546     If you want to complete the configuration process using your problematic
9547     'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
9548     to "yes", and re-run configure.
9549    
9550     END
9551     AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
9552     fi
9553 michael 5353 fi
9554     dnl The trailing newline in this macro's definition is deliberate, for
9555     dnl backward compatibility and to allow trailing 'dnl'-style comments
9556     dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
9557     ])
9558 michael 5059
9559     dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
9560     dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
9561     dnl mangled by Autoconf and run in a shell conditional statement.
9562     m4_define([_AC_COMPILER_EXEEXT],
9563     m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
9564    
9565 michael 5052 # When config.status generates a header, we must update the stamp-h file.
9566     # This file resides in the same directory as the config header
9567     # that is generated. The stamp files are numbered to have different names.
9568    
9569     # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
9570     # loop where config.status creates the headers, so we can generate
9571     # our stamp files there.
9572     AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
9573     [# Compute $1's index in $config_headers.
9574 michael 5059 _am_arg=$1
9575 michael 5052 _am_stamp_count=1
9576     for _am_header in $config_headers :; do
9577     case $_am_header in
9578 michael 5059 $_am_arg | $_am_arg:* )
9579 michael 5052 break ;;
9580     * )
9581     _am_stamp_count=`expr $_am_stamp_count + 1` ;;
9582     esac
9583     done
9584 michael 5059 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
9585 michael 5052
9586 michael 5353 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
9587 michael 5052 #
9588     # This file is free software; the Free Software Foundation
9589     # gives unlimited permission to copy and/or distribute it,
9590     # with or without modifications, as long as this notice is preserved.
9591    
9592     # AM_PROG_INSTALL_SH
9593     # ------------------
9594     # Define $install_sh.
9595     AC_DEFUN([AM_PROG_INSTALL_SH],
9596     [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9597 michael 5353 if test x"${install_sh+set}" != xset; then
9598 michael 5059 case $am_aux_dir in
9599     *\ * | *\ *)
9600     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
9601     *)
9602     install_sh="\${SHELL} $am_aux_dir/install-sh"
9603     esac
9604     fi
9605     AC_SUBST([install_sh])])
9606 michael 5052
9607 michael 5353 # Copyright (C) 2003-2014 Free Software Foundation, Inc.
9608 michael 5052 #
9609     # This file is free software; the Free Software Foundation
9610     # gives unlimited permission to copy and/or distribute it,
9611     # with or without modifications, as long as this notice is preserved.
9612    
9613     # Check whether the underlying file-system supports filenames
9614     # with a leading dot. For instance MS-DOS doesn't.
9615     AC_DEFUN([AM_SET_LEADING_DOT],
9616     [rm -rf .tst 2>/dev/null
9617     mkdir .tst 2>/dev/null
9618     if test -d .tst; then
9619     am__leading_dot=.
9620     else
9621     am__leading_dot=_
9622     fi
9623     rmdir .tst 2>/dev/null
9624     AC_SUBST([am__leading_dot])])
9625    
9626 michael 5353 # Copyright (C) 1998-2014 Free Software Foundation, Inc.
9627 michael 5052 #
9628     # This file is free software; the Free Software Foundation
9629     # gives unlimited permission to copy and/or distribute it,
9630     # with or without modifications, as long as this notice is preserved.
9631    
9632     # AM_PROG_LEX
9633     # -----------
9634     # Autoconf leaves LEX=: if lex or flex can't be found. Change that to a
9635     # "missing" invocation, for better error output.
9636     AC_DEFUN([AM_PROG_LEX],
9637 michael 5059 [AC_PREREQ([2.50])dnl
9638 michael 5052 AC_REQUIRE([AM_MISSING_HAS_RUN])dnl
9639     AC_REQUIRE([AC_PROG_LEX])dnl
9640     if test "$LEX" = :; then
9641     LEX=${am_missing_run}flex
9642     fi])
9643    
9644     # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
9645     # From Jim Meyering
9646    
9647 michael 5353 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
9648 michael 5052 #
9649     # This file is free software; the Free Software Foundation
9650     # gives unlimited permission to copy and/or distribute it,
9651     # with or without modifications, as long as this notice is preserved.
9652    
9653 michael 5059 # AM_MAINTAINER_MODE([DEFAULT-MODE])
9654     # ----------------------------------
9655     # Control maintainer-specific portions of Makefiles.
9656     # Default is to disable them, unless 'enable' is passed literally.
9657     # For symmetry, 'disable' may be passed as well. Anyway, the user
9658     # can override the default with the --enable/--disable switch.
9659 michael 5052 AC_DEFUN([AM_MAINTAINER_MODE],
9660 michael 5059 [m4_case(m4_default([$1], [disable]),
9661     [enable], [m4_define([am_maintainer_other], [disable])],
9662     [disable], [m4_define([am_maintainer_other], [enable])],
9663     [m4_define([am_maintainer_other], [enable])
9664     m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
9665     AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
9666     dnl maintainer-mode's default is 'disable' unless 'enable' is passed
9667     AC_ARG_ENABLE([maintainer-mode],
9668     [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
9669     am_maintainer_other[ make rules and dependencies not useful
9670     (and sometimes confusing) to the casual installer])],
9671     [USE_MAINTAINER_MODE=$enableval],
9672     [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
9673 michael 5052 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
9674 michael 5059 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
9675 michael 5052 MAINT=$MAINTAINER_MODE_TRUE
9676 michael 5059 AC_SUBST([MAINT])dnl
9677 michael 5052 ]
9678     )
9679    
9680     # Check to see how 'make' treats includes. -*- Autoconf -*-
9681    
9682 michael 5353 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
9683 michael 5052 #
9684     # This file is free software; the Free Software Foundation
9685     # gives unlimited permission to copy and/or distribute it,
9686     # with or without modifications, as long as this notice is preserved.
9687    
9688     # AM_MAKE_INCLUDE()
9689     # -----------------
9690     # Check to see how make treats includes.
9691     AC_DEFUN([AM_MAKE_INCLUDE],
9692     [am_make=${MAKE-make}
9693     cat > confinc << 'END'
9694     am__doit:
9695 michael 5059 @echo this is the am__doit target
9696 michael 5052 .PHONY: am__doit
9697     END
9698     # If we don't find an include directive, just comment out the code.
9699     AC_MSG_CHECKING([for style of include used by $am_make])
9700     am__include="#"
9701     am__quote=
9702     _am_result=none
9703     # First try GNU make style include.
9704     echo "include confinc" > confmf
9705 michael 5059 # Ignore all kinds of additional output from 'make'.
9706     case `$am_make -s -f confmf 2> /dev/null` in #(
9707     *the\ am__doit\ target*)
9708     am__include=include
9709     am__quote=
9710     _am_result=GNU
9711     ;;
9712     esac
9713 michael 5052 # Now try BSD make style include.
9714     if test "$am__include" = "#"; then
9715     echo '.include "confinc"' > confmf
9716 michael 5059 case `$am_make -s -f confmf 2> /dev/null` in #(
9717     *the\ am__doit\ target*)
9718     am__include=.include
9719     am__quote="\""
9720     _am_result=BSD
9721     ;;
9722     esac
9723 michael 5052 fi
9724     AC_SUBST([am__include])
9725     AC_SUBST([am__quote])
9726     AC_MSG_RESULT([$_am_result])
9727     rm -f confinc confmf
9728     ])
9729    
9730     # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
9731    
9732 michael 5353 # Copyright (C) 1997-2014 Free Software Foundation, Inc.
9733 michael 5052 #
9734     # This file is free software; the Free Software Foundation
9735     # gives unlimited permission to copy and/or distribute it,
9736     # with or without modifications, as long as this notice is preserved.
9737    
9738     # AM_MISSING_PROG(NAME, PROGRAM)
9739     # ------------------------------
9740     AC_DEFUN([AM_MISSING_PROG],
9741     [AC_REQUIRE([AM_MISSING_HAS_RUN])
9742     $1=${$1-"${am_missing_run}$2"}
9743     AC_SUBST($1)])
9744    
9745     # AM_MISSING_HAS_RUN
9746     # ------------------
9747 michael 5059 # Define MISSING if not defined so far and test if it is modern enough.
9748     # If it is, set am_missing_run to use it, otherwise, to nothing.
9749 michael 5052 AC_DEFUN([AM_MISSING_HAS_RUN],
9750     [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9751 michael 5059 AC_REQUIRE_AUX_FILE([missing])dnl
9752     if test x"${MISSING+set}" != xset; then
9753     case $am_aux_dir in
9754     *\ * | *\ *)
9755     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
9756     *)
9757     MISSING="\${SHELL} $am_aux_dir/missing" ;;
9758     esac
9759     fi
9760 michael 5052 # Use eval to expand $SHELL
9761 michael 5059 if eval "$MISSING --is-lightweight"; then
9762     am_missing_run="$MISSING "
9763 michael 5052 else
9764     am_missing_run=
9765 michael 5059 AC_MSG_WARN(['missing' script is too old or missing])
9766 michael 5052 fi
9767     ])
9768    
9769     # Helper functions for option handling. -*- Autoconf -*-
9770    
9771 michael 5353 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
9772 michael 5052 #
9773     # This file is free software; the Free Software Foundation
9774     # gives unlimited permission to copy and/or distribute it,
9775     # with or without modifications, as long as this notice is preserved.
9776    
9777     # _AM_MANGLE_OPTION(NAME)
9778     # -----------------------
9779     AC_DEFUN([_AM_MANGLE_OPTION],
9780     [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
9781    
9782     # _AM_SET_OPTION(NAME)
9783 michael 5059 # --------------------
9784 michael 5052 # Set option NAME. Presently that only means defining a flag for this option.
9785     AC_DEFUN([_AM_SET_OPTION],
9786 michael 5059 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
9787 michael 5052
9788     # _AM_SET_OPTIONS(OPTIONS)
9789 michael 5059 # ------------------------
9790 michael 5052 # OPTIONS is a space-separated list of Automake options.
9791     AC_DEFUN([_AM_SET_OPTIONS],
9792 michael 5059 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
9793 michael 5052
9794     # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
9795     # -------------------------------------------
9796     # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
9797     AC_DEFUN([_AM_IF_OPTION],
9798     [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
9799    
9800 michael 5353 # Copyright (C) 1999-2014 Free Software Foundation, Inc.
9801 michael 5059 #
9802     # This file is free software; the Free Software Foundation
9803     # gives unlimited permission to copy and/or distribute it,
9804     # with or without modifications, as long as this notice is preserved.
9805    
9806     # _AM_PROG_CC_C_O
9807     # ---------------
9808     # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
9809     # to automatically call this.
9810     AC_DEFUN([_AM_PROG_CC_C_O],
9811     [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9812     AC_REQUIRE_AUX_FILE([compile])dnl
9813     AC_LANG_PUSH([C])dnl
9814     AC_CACHE_CHECK(
9815     [whether $CC understands -c and -o together],
9816     [am_cv_prog_cc_c_o],
9817     [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
9818     # Make sure it works both with $CC and with simple cc.
9819     # Following AC_PROG_CC_C_O, we do the test twice because some
9820     # compilers refuse to overwrite an existing .o file with -o,
9821     # though they will create one.
9822     am_cv_prog_cc_c_o=yes
9823     for am_i in 1 2; do
9824     if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
9825     && test -f conftest2.$ac_objext; then
9826     : OK
9827     else
9828     am_cv_prog_cc_c_o=no
9829     break
9830     fi
9831     done
9832     rm -f core conftest*
9833     unset am_i])
9834     if test "$am_cv_prog_cc_c_o" != yes; then
9835     # Losing compiler, so override with the script.
9836     # FIXME: It is wrong to rewrite CC.
9837     # But if we don't then we get into trouble of one sort or another.
9838     # A longer-term fix would be to have automake use am__CC in this case,
9839     # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
9840     CC="$am_aux_dir/compile $CC"
9841     fi
9842     AC_LANG_POP([C])])
9843    
9844     # For backward compatibility.
9845     AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
9846    
9847 michael 5353 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
9848 michael 5059 #
9849     # This file is free software; the Free Software Foundation
9850     # gives unlimited permission to copy and/or distribute it,
9851     # with or without modifications, as long as this notice is preserved.
9852    
9853     # AM_RUN_LOG(COMMAND)
9854     # -------------------
9855     # Run COMMAND, save the exit status in ac_status, and log it.
9856     # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
9857     AC_DEFUN([AM_RUN_LOG],
9858     [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
9859     ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
9860     ac_status=$?
9861     echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
9862     (exit $ac_status); }])
9863    
9864 michael 5052 # Check to make sure that the build environment is sane. -*- Autoconf -*-
9865    
9866 michael 5353 # Copyright (C) 1996-2014 Free Software Foundation, Inc.
9867 michael 5052 #
9868     # This file is free software; the Free Software Foundation
9869     # gives unlimited permission to copy and/or distribute it,
9870     # with or without modifications, as long as this notice is preserved.
9871    
9872     # AM_SANITY_CHECK
9873     # ---------------
9874     AC_DEFUN([AM_SANITY_CHECK],
9875     [AC_MSG_CHECKING([whether build environment is sane])
9876 michael 5059 # Reject unsafe characters in $srcdir or the absolute working directory
9877     # name. Accept space and tab only in the latter.
9878     am_lf='
9879     '
9880     case `pwd` in
9881     *[[\\\"\#\$\&\'\`$am_lf]]*)
9882     AC_MSG_ERROR([unsafe absolute working directory name]);;
9883     esac
9884     case $srcdir in
9885     *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
9886     AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
9887     esac
9888    
9889     # Do 'set' in a subshell so we don't clobber the current shell's
9890 michael 5052 # arguments. Must try -L first in case configure is actually a
9891     # symlink; some systems play weird games with the mod time of symlinks
9892     # (eg FreeBSD returns the mod time of the symlink's containing
9893     # directory).
9894     if (
9895 michael 5059 am_has_slept=no
9896     for am_try in 1 2; do
9897     echo "timestamp, slept: $am_has_slept" > conftest.file
9898     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
9899     if test "$[*]" = "X"; then
9900     # -L didn't work.
9901     set X `ls -t "$srcdir/configure" conftest.file`
9902     fi
9903     if test "$[*]" != "X $srcdir/configure conftest.file" \
9904     && test "$[*]" != "X conftest.file $srcdir/configure"; then
9905 michael 5052
9906 michael 5059 # If neither matched, then we have a broken ls. This can happen
9907     # if, for instance, CONFIG_SHELL is bash and it inherits a
9908     # broken ls alias from the environment. This has actually
9909     # happened. Such a system could not be considered "sane".
9910     AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
9911     alias in your environment])
9912     fi
9913     if test "$[2]" = conftest.file || test $am_try -eq 2; then
9914     break
9915     fi
9916     # Just in case.
9917     sleep 1
9918     am_has_slept=yes
9919     done
9920 michael 5052 test "$[2]" = conftest.file
9921     )
9922     then
9923     # Ok.
9924     :
9925     else
9926     AC_MSG_ERROR([newly created file is older than distributed files!
9927     Check your system clock])
9928     fi
9929 michael 5059 AC_MSG_RESULT([yes])
9930     # If we didn't sleep, we still need to ensure time stamps of config.status and
9931     # generated files are strictly newer.
9932     am_sleep_pid=
9933     if grep 'slept: no' conftest.file >/dev/null 2>&1; then
9934     ( sleep 1 ) &
9935     am_sleep_pid=$!
9936     fi
9937     AC_CONFIG_COMMANDS_PRE(
9938     [AC_MSG_CHECKING([that generated files are newer than configure])
9939     if test -n "$am_sleep_pid"; then
9940     # Hide warnings about reused PIDs.
9941     wait $am_sleep_pid 2>/dev/null
9942     fi
9943     AC_MSG_RESULT([done])])
9944     rm -f conftest.file
9945     ])
9946 michael 5052
9947 michael 5353 # Copyright (C) 2009-2014 Free Software Foundation, Inc.
9948 michael 5052 #
9949     # This file is free software; the Free Software Foundation
9950     # gives unlimited permission to copy and/or distribute it,
9951     # with or without modifications, as long as this notice is preserved.
9952    
9953 michael 5059 # AM_SILENT_RULES([DEFAULT])
9954     # --------------------------
9955     # Enable less verbose build rules; with the default set to DEFAULT
9956     # ("yes" being less verbose, "no" or empty being verbose).
9957     AC_DEFUN([AM_SILENT_RULES],
9958     [AC_ARG_ENABLE([silent-rules], [dnl
9959     AS_HELP_STRING(
9960     [--enable-silent-rules],
9961     [less verbose build output (undo: "make V=1")])
9962     AS_HELP_STRING(
9963     [--disable-silent-rules],
9964     [verbose build output (undo: "make V=0")])dnl
9965     ])
9966     case $enable_silent_rules in @%:@ (((
9967     yes) AM_DEFAULT_VERBOSITY=0;;
9968     no) AM_DEFAULT_VERBOSITY=1;;
9969     *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
9970     esac
9971     dnl
9972     dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
9973     dnl do not support nested variable expansions.
9974     dnl See automake bug#9928 and bug#10237.
9975     am_make=${MAKE-make}
9976     AC_CACHE_CHECK([whether $am_make supports nested variables],
9977     [am_cv_make_support_nested_variables],
9978     [if AS_ECHO([['TRUE=$(BAR$(V))
9979     BAR0=false
9980     BAR1=true
9981     V=1
9982     am__doit:
9983     @$(TRUE)
9984     .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
9985     am_cv_make_support_nested_variables=yes
9986     else
9987     am_cv_make_support_nested_variables=no
9988     fi])
9989     if test $am_cv_make_support_nested_variables = yes; then
9990     dnl Using '$V' instead of '$(V)' breaks IRIX make.
9991     AM_V='$(V)'
9992     AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
9993     else
9994     AM_V=$AM_DEFAULT_VERBOSITY
9995     AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
9996     fi
9997     AC_SUBST([AM_V])dnl
9998     AM_SUBST_NOTMAKE([AM_V])dnl
9999     AC_SUBST([AM_DEFAULT_V])dnl
10000     AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
10001     AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
10002     AM_BACKSLASH='\'
10003     AC_SUBST([AM_BACKSLASH])dnl
10004     _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
10005     ])
10006    
10007 michael 5353 # Copyright (C) 2001-2014 Free Software Foundation, Inc.
10008 michael 5059 #
10009     # This file is free software; the Free Software Foundation
10010     # gives unlimited permission to copy and/or distribute it,
10011     # with or without modifications, as long as this notice is preserved.
10012    
10013 michael 5052 # AM_PROG_INSTALL_STRIP
10014     # ---------------------
10015 michael 5059 # One issue with vendor 'install' (even GNU) is that you can't
10016 michael 5052 # specify the program used to strip binaries. This is especially
10017     # annoying in cross-compiling environments, where the build's strip
10018     # is unlikely to handle the host's binaries.
10019     # Fortunately install-sh will honor a STRIPPROG variable, so we
10020 michael 5059 # always use install-sh in "make install-strip", and initialize
10021 michael 5052 # STRIPPROG with the value of the STRIP variable (set by the user).
10022     AC_DEFUN([AM_PROG_INSTALL_STRIP],
10023     [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
10024 michael 5059 # Installed binaries are usually stripped using 'strip' when the user
10025     # run "make install-strip". However 'strip' might not be the right
10026 michael 5052 # tool to use in cross-compilation environments, therefore Automake
10027 michael 5059 # will honor the 'STRIP' environment variable to overrule this program.
10028     dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
10029 michael 5052 if test "$cross_compiling" != no; then
10030     AC_CHECK_TOOL([STRIP], [strip], :)
10031     fi
10032 michael 5059 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
10033 michael 5052 AC_SUBST([INSTALL_STRIP_PROGRAM])])
10034    
10035 michael 5353 # Copyright (C) 2006-2014 Free Software Foundation, Inc.
10036 michael 5059 #
10037     # This file is free software; the Free Software Foundation
10038     # gives unlimited permission to copy and/or distribute it,
10039     # with or without modifications, as long as this notice is preserved.
10040    
10041     # _AM_SUBST_NOTMAKE(VARIABLE)
10042     # ---------------------------
10043     # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
10044     # This macro is traced by Automake.
10045     AC_DEFUN([_AM_SUBST_NOTMAKE])
10046    
10047     # AM_SUBST_NOTMAKE(VARIABLE)
10048     # --------------------------
10049     # Public sister of _AM_SUBST_NOTMAKE.
10050     AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
10051    
10052 michael 5052 # Check how to create a tarball. -*- Autoconf -*-
10053    
10054 michael 5353 # Copyright (C) 2004-2014 Free Software Foundation, Inc.
10055 michael 5052 #
10056     # This file is free software; the Free Software Foundation
10057     # gives unlimited permission to copy and/or distribute it,
10058     # with or without modifications, as long as this notice is preserved.
10059    
10060     # _AM_PROG_TAR(FORMAT)
10061     # --------------------
10062     # Check how to create a tarball in format FORMAT.
10063 michael 5059 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
10064 michael 5052 #
10065     # Substitute a variable $(am__tar) that is a command
10066     # writing to stdout a FORMAT-tarball containing the directory
10067     # $tardir.
10068     # tardir=directory && $(am__tar) > result.tar
10069     #
10070     # Substitute a variable $(am__untar) that extract such
10071     # a tarball read from stdin.
10072     # $(am__untar) < result.tar
10073 michael 5059 #
10074 michael 5052 AC_DEFUN([_AM_PROG_TAR],
10075 michael 5059 [# Always define AMTAR for backward compatibility. Yes, it's still used
10076     # in the wild :-( We should find a proper way to deprecate it ...
10077     AC_SUBST([AMTAR], ['$${TAR-tar}'])
10078    
10079     # We'll loop over all known methods to create a tar archive until one works.
10080 michael 5052 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
10081    
10082 michael 5059 m4_if([$1], [v7],
10083     [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
10084 michael 5052
10085 michael 5059 [m4_case([$1],
10086     [ustar],
10087     [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
10088     # There is notably a 21 bits limit for the UID and the GID. In fact,
10089     # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
10090     # and bug#13588).
10091     am_max_uid=2097151 # 2^21 - 1
10092     am_max_gid=$am_max_uid
10093     # The $UID and $GID variables are not portable, so we need to resort
10094     # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
10095     # below are definitely unexpected, so allow the users to see them
10096     # (that is, avoid stderr redirection).
10097     am_uid=`id -u || echo unknown`
10098     am_gid=`id -g || echo unknown`
10099     AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
10100     if test $am_uid -le $am_max_uid; then
10101     AC_MSG_RESULT([yes])
10102     else
10103     AC_MSG_RESULT([no])
10104     _am_tools=none
10105     fi
10106     AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
10107     if test $am_gid -le $am_max_gid; then
10108     AC_MSG_RESULT([yes])
10109     else
10110     AC_MSG_RESULT([no])
10111     _am_tools=none
10112     fi],
10113    
10114     [pax],
10115     [],
10116    
10117     [m4_fatal([Unknown tar format])])
10118    
10119     AC_MSG_CHECKING([how to create a $1 tar archive])
10120    
10121     # Go ahead even if we have the value already cached. We do so because we
10122     # need to set the values for the 'am__tar' and 'am__untar' variables.
10123     _am_tools=${am_cv_prog_tar_$1-$_am_tools}
10124    
10125     for _am_tool in $_am_tools; do
10126     case $_am_tool in
10127     gnutar)
10128     for _am_tar in tar gnutar gtar; do
10129     AM_RUN_LOG([$_am_tar --version]) && break
10130     done
10131     am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
10132     am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
10133     am__untar="$_am_tar -xf -"
10134     ;;
10135     plaintar)
10136     # Must skip GNU tar: if it does not support --format= it doesn't create
10137     # ustar tarball either.
10138     (tar --version) >/dev/null 2>&1 && continue
10139     am__tar='tar chf - "$$tardir"'
10140     am__tar_='tar chf - "$tardir"'
10141     am__untar='tar xf -'
10142     ;;
10143     pax)
10144     am__tar='pax -L -x $1 -w "$$tardir"'
10145     am__tar_='pax -L -x $1 -w "$tardir"'
10146     am__untar='pax -r'
10147     ;;
10148     cpio)
10149     am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
10150     am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
10151     am__untar='cpio -i -H $1 -d'
10152     ;;
10153     none)
10154     am__tar=false
10155     am__tar_=false
10156     am__untar=false
10157     ;;
10158     esac
10159    
10160     # If the value was cached, stop now. We just wanted to have am__tar
10161     # and am__untar set.
10162     test -n "${am_cv_prog_tar_$1}" && break
10163    
10164     # tar/untar a dummy directory, and stop if the command works.
10165     rm -rf conftest.dir
10166     mkdir conftest.dir
10167     echo GrepMe > conftest.dir/file
10168     AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
10169     rm -rf conftest.dir
10170     if test -s conftest.tar; then
10171     AM_RUN_LOG([$am__untar <conftest.tar])
10172     AM_RUN_LOG([cat conftest.dir/file])
10173     grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
10174     fi
10175     done
10176 michael 5052 rm -rf conftest.dir
10177    
10178 michael 5059 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
10179     AC_MSG_RESULT([$am_cv_prog_tar_$1])])
10180    
10181 michael 5052 AC_SUBST([am__tar])
10182     AC_SUBST([am__untar])
10183     ]) # _AM_PROG_TAR
10184    

Properties

Name Value
svn:eol-style native
svn:keywords Id