fix leak, enhance error values
[ltt-control.git] / trunk / lttng-xenomai / ltt-control-0.24-xenoltt / aclocal.m4
CommitLineData
df4efff7 1# generated automatically by aclocal 1.7.9 -*- Autoconf -*-
2
3# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002
4# Free Software Foundation, Inc.
5# 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# Do all the work for Automake. -*- Autoconf -*-
15
16# This macro actually does too much some checks are only needed if
17# your package does certain things. But this isn't really a big deal.
18
19# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
20# Free Software Foundation, Inc.
21
22# This program is free software; you can redistribute it and/or modify
23# it under the terms of the GNU General Public License as published by
24# the Free Software Foundation; either version 2, or (at your option)
25# any later version.
26
27# This program is distributed in the hope that it will be useful,
28# but WITHOUT ANY WARRANTY; without even the implied warranty of
29# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30# GNU General Public License for more details.
31
32# You should have received a copy of the GNU General Public License
33# along with this program; if not, write to the Free Software
34# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
35# 02111-1307, USA.
36
37# serial 10
38
39AC_PREREQ([2.54])
40
41# Autoconf 2.50 wants to disallow AM_ names. We explicitly allow
42# the ones we care about.
43m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
44
45# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
46# AM_INIT_AUTOMAKE([OPTIONS])
47# -----------------------------------------------
48# The call with PACKAGE and VERSION arguments is the old style
49# call (pre autoconf-2.50), which is being phased out. PACKAGE
50# and VERSION should now be passed to AC_INIT and removed from
51# the call to AM_INIT_AUTOMAKE.
52# We support both call styles for the transition. After
53# the next Automake release, Autoconf can make the AC_INIT
54# arguments mandatory, and then we can depend on a new Autoconf
55# release and drop the old call support.
56AC_DEFUN([AM_INIT_AUTOMAKE],
57[AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
58 AC_REQUIRE([AC_PROG_INSTALL])dnl
59# test to see if srcdir already configured
60if test "`cd $srcdir && pwd`" != "`pwd`" &&
61 test -f $srcdir/config.status; then
62 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
63fi
64
65# test whether we have cygpath
66if test -z "$CYGPATH_W"; then
67 if (cygpath --version) >/dev/null 2>/dev/null; then
68 CYGPATH_W='cygpath -w'
69 else
70 CYGPATH_W=echo
71 fi
72fi
73AC_SUBST([CYGPATH_W])
74
75# Define the identity of the package.
76dnl Distinguish between old-style and new-style calls.
77m4_ifval([$2],
78[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
79 AC_SUBST([PACKAGE], [$1])dnl
80 AC_SUBST([VERSION], [$2])],
81[_AM_SET_OPTIONS([$1])dnl
82 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
83 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
84
85_AM_IF_OPTION([no-define],,
86[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
87 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
88
89# Some tools Automake needs.
90AC_REQUIRE([AM_SANITY_CHECK])dnl
91AC_REQUIRE([AC_ARG_PROGRAM])dnl
92AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
93AM_MISSING_PROG(AUTOCONF, autoconf)
94AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
95AM_MISSING_PROG(AUTOHEADER, autoheader)
96AM_MISSING_PROG(MAKEINFO, makeinfo)
97AM_MISSING_PROG(AMTAR, tar)
98AM_PROG_INSTALL_SH
99AM_PROG_INSTALL_STRIP
100# We need awk for the "check" target. The system "awk" is bad on
101# some platforms.
102AC_REQUIRE([AC_PROG_AWK])dnl
103AC_REQUIRE([AC_PROG_MAKE_SET])dnl
104AC_REQUIRE([AM_SET_LEADING_DOT])dnl
105
106_AM_IF_OPTION([no-dependencies],,
107[AC_PROVIDE_IFELSE([AC_PROG_CC],
108 [_AM_DEPENDENCIES(CC)],
109 [define([AC_PROG_CC],
110 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
111AC_PROVIDE_IFELSE([AC_PROG_CXX],
112 [_AM_DEPENDENCIES(CXX)],
113 [define([AC_PROG_CXX],
114 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
115])
116])
117
118
119# When config.status generates a header, we must update the stamp-h file.
120# This file resides in the same directory as the config header
121# that is generated. The stamp files are numbered to have different names.
122
123# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
124# loop where config.status creates the headers, so we can generate
125# our stamp files there.
126AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
127[# Compute $1's index in $config_headers.
128_am_stamp_count=1
129for _am_header in $config_headers :; do
130 case $_am_header in
131 $1 | $1:* )
132 break ;;
133 * )
134 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
135 esac
136done
137echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
138
139# Copyright 2002 Free Software Foundation, Inc.
140
141# This program is free software; you can redistribute it and/or modify
142# it under the terms of the GNU General Public License as published by
143# the Free Software Foundation; either version 2, or (at your option)
144# any later version.
145
146# This program is distributed in the hope that it will be useful,
147# but WITHOUT ANY WARRANTY; without even the implied warranty of
148# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
149# GNU General Public License for more details.
150
151# You should have received a copy of the GNU General Public License
152# along with this program; if not, write to the Free Software
153# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
154
155# AM_AUTOMAKE_VERSION(VERSION)
156# ----------------------------
157# Automake X.Y traces this macro to ensure aclocal.m4 has been
158# generated from the m4 files accompanying Automake X.Y.
159AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.7"])
160
161# AM_SET_CURRENT_AUTOMAKE_VERSION
162# -------------------------------
163# Call AM_AUTOMAKE_VERSION so it can be traced.
164# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
165AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
166 [AM_AUTOMAKE_VERSION([1.7.9])])
167
168# Helper functions for option handling. -*- Autoconf -*-
169
170# Copyright 2001, 2002 Free Software Foundation, Inc.
171
172# This program is free software; you can redistribute it and/or modify
173# it under the terms of the GNU General Public License as published by
174# the Free Software Foundation; either version 2, or (at your option)
175# any later version.
176
177# This program is distributed in the hope that it will be useful,
178# but WITHOUT ANY WARRANTY; without even the implied warranty of
179# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
180# GNU General Public License for more details.
181
182# You should have received a copy of the GNU General Public License
183# along with this program; if not, write to the Free Software
184# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
185# 02111-1307, USA.
186
187# serial 2
188
189# _AM_MANGLE_OPTION(NAME)
190# -----------------------
191AC_DEFUN([_AM_MANGLE_OPTION],
192[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
193
194# _AM_SET_OPTION(NAME)
195# ------------------------------
196# Set option NAME. Presently that only means defining a flag for this option.
197AC_DEFUN([_AM_SET_OPTION],
198[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
199
200# _AM_SET_OPTIONS(OPTIONS)
201# ----------------------------------
202# OPTIONS is a space-separated list of Automake options.
203AC_DEFUN([_AM_SET_OPTIONS],
204[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
205
206# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
207# -------------------------------------------
208# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
209AC_DEFUN([_AM_IF_OPTION],
210[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
211
212#
213# Check to make sure that the build environment is sane.
214#
215
216# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
217
218# This program is free software; you can redistribute it and/or modify
219# it under the terms of the GNU General Public License as published by
220# the Free Software Foundation; either version 2, or (at your option)
221# any later version.
222
223# This program is distributed in the hope that it will be useful,
224# but WITHOUT ANY WARRANTY; without even the implied warranty of
225# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
226# GNU General Public License for more details.
227
228# You should have received a copy of the GNU General Public License
229# along with this program; if not, write to the Free Software
230# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
231# 02111-1307, USA.
232
233# serial 3
234
235# AM_SANITY_CHECK
236# ---------------
237AC_DEFUN([AM_SANITY_CHECK],
238[AC_MSG_CHECKING([whether build environment is sane])
239# Just in case
240sleep 1
241echo timestamp > conftest.file
242# Do `set' in a subshell so we don't clobber the current shell's
243# arguments. Must try -L first in case configure is actually a
244# symlink; some systems play weird games with the mod time of symlinks
245# (eg FreeBSD returns the mod time of the symlink's containing
246# directory).
247if (
248 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
249 if test "$[*]" = "X"; then
250 # -L didn't work.
251 set X `ls -t $srcdir/configure conftest.file`
252 fi
253 rm -f conftest.file
254 if test "$[*]" != "X $srcdir/configure conftest.file" \
255 && test "$[*]" != "X conftest.file $srcdir/configure"; then
256
257 # If neither matched, then we have a broken ls. This can happen
258 # if, for instance, CONFIG_SHELL is bash and it inherits a
259 # broken ls alias from the environment. This has actually
260 # happened. Such a system could not be considered "sane".
261 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
262alias in your environment])
263 fi
264
265 test "$[2]" = conftest.file
266 )
267then
268 # Ok.
269 :
270else
271 AC_MSG_ERROR([newly created file is older than distributed files!
272Check your system clock])
273fi
274AC_MSG_RESULT(yes)])
275
276# -*- Autoconf -*-
277
278
279# Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
280
281# This program is free software; you can redistribute it and/or modify
282# it under the terms of the GNU General Public License as published by
283# the Free Software Foundation; either version 2, or (at your option)
284# any later version.
285
286# This program is distributed in the hope that it will be useful,
287# but WITHOUT ANY WARRANTY; without even the implied warranty of
288# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
289# GNU General Public License for more details.
290
291# You should have received a copy of the GNU General Public License
292# along with this program; if not, write to the Free Software
293# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
294# 02111-1307, USA.
295
296# serial 3
297
298# AM_MISSING_PROG(NAME, PROGRAM)
299# ------------------------------
300AC_DEFUN([AM_MISSING_PROG],
301[AC_REQUIRE([AM_MISSING_HAS_RUN])
302$1=${$1-"${am_missing_run}$2"}
303AC_SUBST($1)])
304
305
306# AM_MISSING_HAS_RUN
307# ------------------
308# Define MISSING if not defined so far and test if it supports --run.
309# If it does, set am_missing_run to use it, otherwise, to nothing.
310AC_DEFUN([AM_MISSING_HAS_RUN],
311[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
312test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
313# Use eval to expand $SHELL
314if eval "$MISSING --run true"; then
315 am_missing_run="$MISSING --run "
316else
317 am_missing_run=
318 AC_MSG_WARN([`missing' script is too old or missing])
319fi
320])
321
322# AM_AUX_DIR_EXPAND
323
324# Copyright 2001 Free Software Foundation, Inc.
325
326# This program is free software; you can redistribute it and/or modify
327# it under the terms of the GNU General Public License as published by
328# the Free Software Foundation; either version 2, or (at your option)
329# any later version.
330
331# This program is distributed in the hope that it will be useful,
332# but WITHOUT ANY WARRANTY; without even the implied warranty of
333# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
334# GNU General Public License for more details.
335
336# You should have received a copy of the GNU General Public License
337# along with this program; if not, write to the Free Software
338# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
339# 02111-1307, USA.
340
341# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
342# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
343# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
344#
345# Of course, Automake must honor this variable whenever it calls a
346# tool from the auxiliary directory. The problem is that $srcdir (and
347# therefore $ac_aux_dir as well) can be either absolute or relative,
348# depending on how configure is run. This is pretty annoying, since
349# it makes $ac_aux_dir quite unusable in subdirectories: in the top
350# source directory, any form will work fine, but in subdirectories a
351# relative path needs to be adjusted first.
352#
353# $ac_aux_dir/missing
354# fails when called from a subdirectory if $ac_aux_dir is relative
355# $top_srcdir/$ac_aux_dir/missing
356# fails if $ac_aux_dir is absolute,
357# fails when called from a subdirectory in a VPATH build with
358# a relative $ac_aux_dir
359#
360# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
361# are both prefixed by $srcdir. In an in-source build this is usually
362# harmless because $srcdir is `.', but things will broke when you
363# start a VPATH build or use an absolute $srcdir.
364#
365# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
366# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
367# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
368# and then we would define $MISSING as
369# MISSING="\${SHELL} $am_aux_dir/missing"
370# This will work as long as MISSING is not called from configure, because
371# unfortunately $(top_srcdir) has no meaning in configure.
372# However there are other variables, like CC, which are often used in
373# configure, and could therefore not use this "fixed" $ac_aux_dir.
374#
375# Another solution, used here, is to always expand $ac_aux_dir to an
376# absolute PATH. The drawback is that using absolute paths prevent a
377# configured tree to be moved without reconfiguration.
378
379# Rely on autoconf to set up CDPATH properly.
380AC_PREREQ([2.50])
381
382AC_DEFUN([AM_AUX_DIR_EXPAND], [
383# expand $ac_aux_dir to an absolute path
384am_aux_dir=`cd $ac_aux_dir && pwd`
385])
386
387# AM_PROG_INSTALL_SH
388# ------------------
389# Define $install_sh.
390
391# Copyright 2001 Free Software Foundation, Inc.
392
393# This program is free software; you can redistribute it and/or modify
394# it under the terms of the GNU General Public License as published by
395# the Free Software Foundation; either version 2, or (at your option)
396# any later version.
397
398# This program is distributed in the hope that it will be useful,
399# but WITHOUT ANY WARRANTY; without even the implied warranty of
400# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
401# GNU General Public License for more details.
402
403# You should have received a copy of the GNU General Public License
404# along with this program; if not, write to the Free Software
405# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
406# 02111-1307, USA.
407
408AC_DEFUN([AM_PROG_INSTALL_SH],
409[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
410install_sh=${install_sh-"$am_aux_dir/install-sh"}
411AC_SUBST(install_sh)])
412
413# AM_PROG_INSTALL_STRIP
414
415# Copyright 2001 Free Software Foundation, Inc.
416
417# This program is free software; you can redistribute it and/or modify
418# it under the terms of the GNU General Public License as published by
419# the Free Software Foundation; either version 2, or (at your option)
420# any later version.
421
422# This program is distributed in the hope that it will be useful,
423# but WITHOUT ANY WARRANTY; without even the implied warranty of
424# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
425# GNU General Public License for more details.
426
427# You should have received a copy of the GNU General Public License
428# along with this program; if not, write to the Free Software
429# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
430# 02111-1307, USA.
431
432# One issue with vendor `install' (even GNU) is that you can't
433# specify the program used to strip binaries. This is especially
434# annoying in cross-compiling environments, where the build's strip
435# is unlikely to handle the host's binaries.
436# Fortunately install-sh will honor a STRIPPROG variable, so we
437# always use install-sh in `make install-strip', and initialize
438# STRIPPROG with the value of the STRIP variable (set by the user).
439AC_DEFUN([AM_PROG_INSTALL_STRIP],
440[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
441# Installed binaries are usually stripped using `strip' when the user
442# run `make install-strip'. However `strip' might not be the right
443# tool to use in cross-compilation environments, therefore Automake
444# will honor the `STRIP' environment variable to overrule this program.
445dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
446if test "$cross_compiling" != no; then
447 AC_CHECK_TOOL([STRIP], [strip], :)
448fi
449INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
450AC_SUBST([INSTALL_STRIP_PROGRAM])])
451
452# -*- Autoconf -*-
453# Copyright (C) 2003 Free Software Foundation, Inc.
454
455# This program is free software; you can redistribute it and/or modify
456# it under the terms of the GNU General Public License as published by
457# the Free Software Foundation; either version 2, or (at your option)
458# any later version.
459
460# This program is distributed in the hope that it will be useful,
461# but WITHOUT ANY WARRANTY; without even the implied warranty of
462# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
463# GNU General Public License for more details.
464
465# You should have received a copy of the GNU General Public License
466# along with this program; if not, write to the Free Software
467# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
468# 02111-1307, USA.
469
470# serial 1
471
472# Check whether the underlying file-system supports filenames
473# with a leading dot. For instance MS-DOS doesn't.
474AC_DEFUN([AM_SET_LEADING_DOT],
475[rm -rf .tst 2>/dev/null
476mkdir .tst 2>/dev/null
477if test -d .tst; then
478 am__leading_dot=.
479else
480 am__leading_dot=_
481fi
482rmdir .tst 2>/dev/null
483AC_SUBST([am__leading_dot])])
484
485# serial 5 -*- Autoconf -*-
486
487# Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
488
489# This program is free software; you can redistribute it and/or modify
490# it under the terms of the GNU General Public License as published by
491# the Free Software Foundation; either version 2, or (at your option)
492# any later version.
493
494# This program is distributed in the hope that it will be useful,
495# but WITHOUT ANY WARRANTY; without even the implied warranty of
496# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
497# GNU General Public License for more details.
498
499# You should have received a copy of the GNU General Public License
500# along with this program; if not, write to the Free Software
501# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
502# 02111-1307, USA.
503
504
505# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
506# written in clear, in which case automake, when reading aclocal.m4,
507# will think it sees a *use*, and therefore will trigger all it's
508# C support machinery. Also note that it means that autoscan, seeing
509# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
510
511
512
513# _AM_DEPENDENCIES(NAME)
514# ----------------------
515# See how the compiler implements dependency checking.
516# NAME is "CC", "CXX", "GCJ", or "OBJC".
517# We try a few techniques and use that to set a single cache variable.
518#
519# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
520# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
521# dependency, and given that the user is not expected to run this macro,
522# just rely on AC_PROG_CC.
523AC_DEFUN([_AM_DEPENDENCIES],
524[AC_REQUIRE([AM_SET_DEPDIR])dnl
525AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
526AC_REQUIRE([AM_MAKE_INCLUDE])dnl
527AC_REQUIRE([AM_DEP_TRACK])dnl
528
529ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
530 [$1], CXX, [depcc="$CXX" am_compiler_list=],
531 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
532 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
533 [depcc="$$1" am_compiler_list=])
534
535AC_CACHE_CHECK([dependency style of $depcc],
536 [am_cv_$1_dependencies_compiler_type],
537[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
538 # We make a subdir and do the tests there. Otherwise we can end up
539 # making bogus files that we don't know about and never remove. For
540 # instance it was reported that on HP-UX the gcc test will end up
541 # making a dummy file named `D' -- because `-MD' means `put the output
542 # in D'.
543 mkdir conftest.dir
544 # Copy depcomp to subdir because otherwise we won't find it if we're
545 # using a relative directory.
546 cp "$am_depcomp" conftest.dir
547 cd conftest.dir
548 # We will build objects and dependencies in a subdirectory because
549 # it helps to detect inapplicable dependency modes. For instance
550 # both Tru64's cc and ICC support -MD to output dependencies as a
551 # side effect of compilation, but ICC will put the dependencies in
552 # the current directory while Tru64 will put them in the object
553 # directory.
554 mkdir sub
555
556 am_cv_$1_dependencies_compiler_type=none
557 if test "$am_compiler_list" = ""; then
558 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
559 fi
560 for depmode in $am_compiler_list; do
561 # Setup a source with many dependencies, because some compilers
562 # like to wrap large dependency lists on column 80 (with \), and
563 # we should not choose a depcomp mode which is confused by this.
564 #
565 # We need to recreate these files for each test, as the compiler may
566 # overwrite some of them when testing with obscure command lines.
567 # This happens at least with the AIX C compiler.
568 : > sub/conftest.c
569 for i in 1 2 3 4 5 6; do
570 echo '#include "conftst'$i'.h"' >> sub/conftest.c
571 : > sub/conftst$i.h
572 done
573 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
574
575 case $depmode in
576 nosideeffect)
577 # after this tag, mechanisms are not by side-effect, so they'll
578 # only be used when explicitly requested
579 if test "x$enable_dependency_tracking" = xyes; then
580 continue
581 else
582 break
583 fi
584 ;;
585 none) break ;;
586 esac
587 # We check with `-c' and `-o' for the sake of the "dashmstdout"
588 # mode. It turns out that the SunPro C++ compiler does not properly
589 # handle `-M -o', and we need to detect this.
590 if depmode=$depmode \
591 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
592 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
593 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
594 >/dev/null 2>conftest.err &&
595 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
596 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
597 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
598 # icc doesn't choke on unknown options, it will just issue warnings
599 # (even with -Werror). So we grep stderr for any message
600 # that says an option was ignored.
601 if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
602 am_cv_$1_dependencies_compiler_type=$depmode
603 break
604 fi
605 fi
606 done
607
608 cd ..
609 rm -rf conftest.dir
610else
611 am_cv_$1_dependencies_compiler_type=none
612fi
613])
614AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
615AM_CONDITIONAL([am__fastdep$1], [
616 test "x$enable_dependency_tracking" != xno \
617 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
618])
619
620
621# AM_SET_DEPDIR
622# -------------
623# Choose a directory name for dependency files.
624# This macro is AC_REQUIREd in _AM_DEPENDENCIES
625AC_DEFUN([AM_SET_DEPDIR],
626[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
627AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
628])
629
630
631# AM_DEP_TRACK
632# ------------
633AC_DEFUN([AM_DEP_TRACK],
634[AC_ARG_ENABLE(dependency-tracking,
635[ --disable-dependency-tracking Speeds up one-time builds
636 --enable-dependency-tracking Do not reject slow dependency extractors])
637if test "x$enable_dependency_tracking" != xno; then
638 am_depcomp="$ac_aux_dir/depcomp"
639 AMDEPBACKSLASH='\'
640fi
641AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
642AC_SUBST([AMDEPBACKSLASH])
643])
644
645# Generate code to set up dependency tracking. -*- Autoconf -*-
646
647# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
648
649# This program is free software; you can redistribute it and/or modify
650# it under the terms of the GNU General Public License as published by
651# the Free Software Foundation; either version 2, or (at your option)
652# any later version.
653
654# This program is distributed in the hope that it will be useful,
655# but WITHOUT ANY WARRANTY; without even the implied warranty of
656# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
657# GNU General Public License for more details.
658
659# You should have received a copy of the GNU General Public License
660# along with this program; if not, write to the Free Software
661# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
662# 02111-1307, USA.
663
664#serial 2
665
666# _AM_OUTPUT_DEPENDENCY_COMMANDS
667# ------------------------------
668AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
669[for mf in $CONFIG_FILES; do
670 # Strip MF so we end up with the name of the file.
671 mf=`echo "$mf" | sed -e 's/:.*$//'`
672 # Check whether this is an Automake generated Makefile or not.
673 # We used to match only the files named `Makefile.in', but
674 # some people rename them; so instead we look at the file content.
675 # Grep'ing the first line is not enough: some people post-process
676 # each Makefile.in and add a new line on top of each file to say so.
677 # So let's grep whole file.
678 if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
679 dirpart=`AS_DIRNAME("$mf")`
680 else
681 continue
682 fi
683 grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
684 # Extract the definition of DEP_FILES from the Makefile without
685 # running `make'.
686 DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
687 test -z "$DEPDIR" && continue
688 # When using ansi2knr, U may be empty or an underscore; expand it
689 U=`sed -n -e '/^U = / s///p' < "$mf"`
690 test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
691 # We invoke sed twice because it is the simplest approach to
692 # changing $(DEPDIR) to its actual value in the expansion.
693 for file in `sed -n -e '
694 /^DEP_FILES = .*\\\\$/ {
695 s/^DEP_FILES = //
696 :loop
697 s/\\\\$//
698 p
699 n
700 /\\\\$/ b loop
701 p
702 }
703 /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
704 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
705 # Make sure the directory exists.
706 test -f "$dirpart/$file" && continue
707 fdir=`AS_DIRNAME(["$file"])`
708 AS_MKDIR_P([$dirpart/$fdir])
709 # echo "creating $dirpart/$file"
710 echo '# dummy' > "$dirpart/$file"
711 done
712done
713])# _AM_OUTPUT_DEPENDENCY_COMMANDS
714
715
716# AM_OUTPUT_DEPENDENCY_COMMANDS
717# -----------------------------
718# This macro should only be invoked once -- use via AC_REQUIRE.
719#
720# This code is only required when automatic dependency tracking
721# is enabled. FIXME. This creates each `.P' file that we will
722# need in order to bootstrap the dependency handling code.
723AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
724[AC_CONFIG_COMMANDS([depfiles],
725 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
726 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
727])
728
729# Check to see how 'make' treats includes. -*- Autoconf -*-
730
731# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
732
733# This program is free software; you can redistribute it and/or modify
734# it under the terms of the GNU General Public License as published by
735# the Free Software Foundation; either version 2, or (at your option)
736# any later version.
737
738# This program is distributed in the hope that it will be useful,
739# but WITHOUT ANY WARRANTY; without even the implied warranty of
740# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
741# GNU General Public License for more details.
742
743# You should have received a copy of the GNU General Public License
744# along with this program; if not, write to the Free Software
745# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
746# 02111-1307, USA.
747
748# serial 2
749
750# AM_MAKE_INCLUDE()
751# -----------------
752# Check to see how make treats includes.
753AC_DEFUN([AM_MAKE_INCLUDE],
754[am_make=${MAKE-make}
755cat > confinc << 'END'
756am__doit:
757 @echo done
758.PHONY: am__doit
759END
760# If we don't find an include directive, just comment out the code.
761AC_MSG_CHECKING([for style of include used by $am_make])
762am__include="#"
763am__quote=
764_am_result=none
765# First try GNU make style include.
766echo "include confinc" > confmf
767# We grep out `Entering directory' and `Leaving directory'
768# messages which can occur if `w' ends up in MAKEFLAGS.
769# In particular we don't look at `^make:' because GNU make might
770# be invoked under some other name (usually "gmake"), in which
771# case it prints its new name instead of `make'.
772if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
773 am__include=include
774 am__quote=
775 _am_result=GNU
776fi
777# Now try BSD make style include.
778if test "$am__include" = "#"; then
779 echo '.include "confinc"' > confmf
780 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
781 am__include=.include
782 am__quote="\""
783 _am_result=BSD
784 fi
785fi
786AC_SUBST([am__include])
787AC_SUBST([am__quote])
788AC_MSG_RESULT([$_am_result])
789rm -f confinc confmf
790])
791
792# AM_CONDITIONAL -*- Autoconf -*-
793
794# Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
795
796# This program is free software; you can redistribute it and/or modify
797# it under the terms of the GNU General Public License as published by
798# the Free Software Foundation; either version 2, or (at your option)
799# any later version.
800
801# This program is distributed in the hope that it will be useful,
802# but WITHOUT ANY WARRANTY; without even the implied warranty of
803# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
804# GNU General Public License for more details.
805
806# You should have received a copy of the GNU General Public License
807# along with this program; if not, write to the Free Software
808# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
809# 02111-1307, USA.
810
811# serial 5
812
813AC_PREREQ(2.52)
814
815# AM_CONDITIONAL(NAME, SHELL-CONDITION)
816# -------------------------------------
817# Define a conditional.
818AC_DEFUN([AM_CONDITIONAL],
819[ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
820 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
821AC_SUBST([$1_TRUE])
822AC_SUBST([$1_FALSE])
823if $2; then
824 $1_TRUE=
825 $1_FALSE='#'
826else
827 $1_TRUE='#'
828 $1_FALSE=
829fi
830AC_CONFIG_COMMANDS_PRE(
831[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
832 AC_MSG_ERROR([conditional "$1" was never defined.
833Usually this means the macro was only invoked conditionally.])
834fi])])
835
836# Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
837
838# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
839
840# This program is free software; you can redistribute it and/or modify
841# it under the terms of the GNU General Public License as published by
842# the Free Software Foundation; either version 2, or (at your option)
843# any later version.
844
845# This program is distributed in the hope that it will be useful,
846# but WITHOUT ANY WARRANTY; without even the implied warranty of
847# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
848# GNU General Public License for more details.
849
850# You should have received a copy of the GNU General Public License
851# along with this program; if not, write to the Free Software
852# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
853# 02111-1307, USA.
854
855AC_PREREQ([2.52])
856
857# serial 6
858
859# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS.
860AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
861
862# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
863
864# serial 48 Debian 1.5.22-4 AC_PROG_LIBTOOL
865
866
867# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
868# -----------------------------------------------------------
869# If this macro is not defined by Autoconf, define it here.
870m4_ifdef([AC_PROVIDE_IFELSE],
871 [],
872 [m4_define([AC_PROVIDE_IFELSE],
873 [m4_ifdef([AC_PROVIDE_$1],
874 [$2], [$3])])])
875
876
877# AC_PROG_LIBTOOL
878# ---------------
879AC_DEFUN([AC_PROG_LIBTOOL],
880[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
881dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
882dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
883 AC_PROVIDE_IFELSE([AC_PROG_CXX],
884 [AC_LIBTOOL_CXX],
885 [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
886 ])])
887dnl And a similar setup for Fortran 77 support
888 AC_PROVIDE_IFELSE([AC_PROG_F77],
889 [AC_LIBTOOL_F77],
890 [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
891])])
892
893dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
894dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
895dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
896 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
897 [AC_LIBTOOL_GCJ],
898 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
899 [AC_LIBTOOL_GCJ],
900 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
901 [AC_LIBTOOL_GCJ],
902 [ifdef([AC_PROG_GCJ],
903 [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
904 ifdef([A][M_PROG_GCJ],
905 [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
906 ifdef([LT_AC_PROG_GCJ],
907 [define([LT_AC_PROG_GCJ],
908 defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
909])])# AC_PROG_LIBTOOL
910
911
912# _AC_PROG_LIBTOOL
913# ----------------
914AC_DEFUN([_AC_PROG_LIBTOOL],
915[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
916AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
917AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
918AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
919
920# This can be used to rebuild libtool when needed
921LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
922
923# Always use our own libtool.
924LIBTOOL='$(SHELL) $(top_builddir)/libtool'
925AC_SUBST(LIBTOOL)dnl
926
927# Prevent multiple expansion
928define([AC_PROG_LIBTOOL], [])
929])# _AC_PROG_LIBTOOL
930
931
932# AC_LIBTOOL_SETUP
933# ----------------
934AC_DEFUN([AC_LIBTOOL_SETUP],
935[AC_PREREQ(2.50)dnl
936AC_REQUIRE([AC_ENABLE_SHARED])dnl
937AC_REQUIRE([AC_ENABLE_STATIC])dnl
938AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
939AC_REQUIRE([AC_CANONICAL_HOST])dnl
940AC_REQUIRE([AC_CANONICAL_BUILD])dnl
941AC_REQUIRE([AC_PROG_CC])dnl
942AC_REQUIRE([AC_PROG_LD])dnl
943AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
944AC_REQUIRE([AC_PROG_NM])dnl
945
946AC_REQUIRE([AC_PROG_LN_S])dnl
947AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
948# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
949AC_REQUIRE([AC_OBJEXT])dnl
950AC_REQUIRE([AC_EXEEXT])dnl
951dnl
952
953AC_LIBTOOL_SYS_MAX_CMD_LEN
954AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
955AC_LIBTOOL_OBJDIR
956
957AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
958_LT_AC_PROG_ECHO_BACKSLASH
959
960case $host_os in
961aix3*)
962 # AIX sometimes has problems with the GCC collect2 program. For some
963 # reason, if we set the COLLECT_NAMES environment variable, the problems
964 # vanish in a puff of smoke.
965 if test "X${COLLECT_NAMES+set}" != Xset; then
966 COLLECT_NAMES=
967 export COLLECT_NAMES
968 fi
969 ;;
970esac
971
972# Sed substitution that helps us do robust quoting. It backslashifies
973# metacharacters that are still active within double-quoted strings.
974Xsed='sed -e 1s/^X//'
975[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
976
977# Same as above, but do not quote variable references.
978[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
979
980# Sed substitution to delay expansion of an escaped shell variable in a
981# double_quote_subst'ed string.
982delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
983
984# Sed substitution to avoid accidental globbing in evaled expressions
985no_glob_subst='s/\*/\\\*/g'
986
987# Constants:
988rm="rm -f"
989
990# Global variables:
991default_ofile=libtool
992can_build_shared=yes
993
994# All known linkers require a `.a' archive for static linking (except MSVC,
995# which needs '.lib').
996libext=a
997ltmain="$ac_aux_dir/ltmain.sh"
998ofile="$default_ofile"
999with_gnu_ld="$lt_cv_prog_gnu_ld"
1000
1001AC_CHECK_TOOL(AR, ar, false)
1002AC_CHECK_TOOL(RANLIB, ranlib, :)
1003AC_CHECK_TOOL(STRIP, strip, :)
1004
1005old_CC="$CC"
1006old_CFLAGS="$CFLAGS"
1007
1008# Set sane defaults for various variables
1009test -z "$AR" && AR=ar
1010test -z "$AR_FLAGS" && AR_FLAGS=cru
1011test -z "$AS" && AS=as
1012test -z "$CC" && CC=cc
1013test -z "$LTCC" && LTCC=$CC
1014test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1015test -z "$DLLTOOL" && DLLTOOL=dlltool
1016test -z "$LD" && LD=ld
1017test -z "$LN_S" && LN_S="ln -s"
1018test -z "$MAGIC_CMD" && MAGIC_CMD=file
1019test -z "$NM" && NM=nm
1020test -z "$SED" && SED=sed
1021test -z "$OBJDUMP" && OBJDUMP=objdump
1022test -z "$RANLIB" && RANLIB=:
1023test -z "$STRIP" && STRIP=:
1024test -z "$ac_objext" && ac_objext=o
1025
1026# Determine commands to create old-style static archives.
1027old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
1028old_postinstall_cmds='chmod 644 $oldlib'
1029old_postuninstall_cmds=
1030
1031if test -n "$RANLIB"; then
1032 case $host_os in
1033 openbsd*)
1034 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
1035 ;;
1036 *)
1037 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
1038 ;;
1039 esac
1040 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
1041fi
1042
1043_LT_CC_BASENAME([$compiler])
1044
1045# Only perform the check for file, if the check method requires it
1046case $deplibs_check_method in
1047file_magic*)
1048 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1049 AC_PATH_MAGIC
1050 fi
1051 ;;
1052esac
1053
1054AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
1055AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1056enable_win32_dll=yes, enable_win32_dll=no)
1057
1058AC_ARG_ENABLE([libtool-lock],
1059 [AC_HELP_STRING([--disable-libtool-lock],
1060 [avoid locking (might break parallel builds)])])
1061test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1062
1063AC_ARG_WITH([pic],
1064 [AC_HELP_STRING([--with-pic],
1065 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
1066 [pic_mode="$withval"],
1067 [pic_mode=default])
1068test -z "$pic_mode" && pic_mode=default
1069
1070# Use C for the default configuration in the libtool script
1071tagname=
1072AC_LIBTOOL_LANG_C_CONFIG
1073_LT_AC_TAGCONFIG
1074])# AC_LIBTOOL_SETUP
1075
1076
1077# _LT_AC_SYS_COMPILER
1078# -------------------
1079AC_DEFUN([_LT_AC_SYS_COMPILER],
1080[AC_REQUIRE([AC_PROG_CC])dnl
1081
1082# If no C compiler was specified, use CC.
1083LTCC=${LTCC-"$CC"}
1084
1085# If no C compiler flags were specified, use CFLAGS.
1086LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1087
1088# Allow CC to be a program name with arguments.
1089compiler=$CC
1090])# _LT_AC_SYS_COMPILER
1091
1092
1093# _LT_CC_BASENAME(CC)
1094# -------------------
1095# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
1096AC_DEFUN([_LT_CC_BASENAME],
1097[for cc_temp in $1""; do
1098 case $cc_temp in
1099 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1100 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1101 \-*) ;;
1102 *) break;;
1103 esac
1104done
1105cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
1106])
1107
1108
1109# _LT_COMPILER_BOILERPLATE
1110# ------------------------
1111# Check for compiler boilerplate output or warnings with
1112# the simple compiler test code.
1113AC_DEFUN([_LT_COMPILER_BOILERPLATE],
1114[ac_outfile=conftest.$ac_objext
1115printf "$lt_simple_compile_test_code" >conftest.$ac_ext
1116eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1117_lt_compiler_boilerplate=`cat conftest.err`
1118$rm conftest*
1119])# _LT_COMPILER_BOILERPLATE
1120
1121
1122# _LT_LINKER_BOILERPLATE
1123# ----------------------
1124# Check for linker boilerplate output or warnings with
1125# the simple link test code.
1126AC_DEFUN([_LT_LINKER_BOILERPLATE],
1127[ac_outfile=conftest.$ac_objext
1128printf "$lt_simple_link_test_code" >conftest.$ac_ext
1129eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1130_lt_linker_boilerplate=`cat conftest.err`
1131$rm conftest*
1132])# _LT_LINKER_BOILERPLATE
1133
1134
1135# _LT_AC_SYS_LIBPATH_AIX
1136# ----------------------
1137# Links a minimal program and checks the executable
1138# for the system default hardcoded library path. In most cases,
1139# this is /usr/lib:/lib, but when the MPI compilers are used
1140# the location of the communication and MPI libs are included too.
1141# If we don't find anything, use the default library path according
1142# to the aix ld manual.
1143AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
1144[AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1145aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
1146}'`
1147# Check for a 64-bit object if we didn't find anything.
1148if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
1149}'`; fi],[])
1150if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1151])# _LT_AC_SYS_LIBPATH_AIX
1152
1153
1154# _LT_AC_SHELL_INIT(ARG)
1155# ----------------------
1156AC_DEFUN([_LT_AC_SHELL_INIT],
1157[ifdef([AC_DIVERSION_NOTICE],
1158 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1159 [AC_DIVERT_PUSH(NOTICE)])
1160$1
1161AC_DIVERT_POP
1162])# _LT_AC_SHELL_INIT
1163
1164
1165# _LT_AC_PROG_ECHO_BACKSLASH
1166# --------------------------
1167# Add some code to the start of the generated configure script which
1168# will find an echo command which doesn't interpret backslashes.
1169AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
1170[_LT_AC_SHELL_INIT([
1171# Check that we are running under the correct shell.
1172SHELL=${CONFIG_SHELL-/bin/sh}
1173
1174case X$ECHO in
1175X*--fallback-echo)
1176 # Remove one level of quotation (which was required for Make).
1177 ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1178 ;;
1179esac
1180
1181echo=${ECHO-echo}
1182if test "X[$]1" = X--no-reexec; then
1183 # Discard the --no-reexec flag, and continue.
1184 shift
1185elif test "X[$]1" = X--fallback-echo; then
1186 # Avoid inline document here, it may be left over
1187 :
1188elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
1189 # Yippee, $echo works!
1190 :
1191else
1192 # Restart under the correct shell.
1193 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1194fi
1195
1196if test "X[$]1" = X--fallback-echo; then
1197 # used as fallback echo
1198 shift
1199 cat <<EOF
1200[$]*
1201EOF
1202 exit 0
1203fi
1204
1205# The HP-UX ksh and POSIX shell print the target directory to stdout
1206# if CDPATH is set.
1207(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1208
1209if test -z "$ECHO"; then
1210if test "X${echo_test_string+set}" != Xset; then
1211# find a string as large as possible, as long as the shell can cope with it
1212 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1213 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1214 if (echo_test_string=`eval $cmd`) 2>/dev/null &&
1215 echo_test_string=`eval $cmd` &&
1216 (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
1217 then
1218 break
1219 fi
1220 done
1221fi
1222
1223if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1224 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1225 test "X$echo_testing_string" = "X$echo_test_string"; then
1226 :
1227else
1228 # The Solaris, AIX, and Digital Unix default echo programs unquote
1229 # backslashes. This makes it impossible to quote backslashes using
1230 # echo "$something" | sed 's/\\/\\\\/g'
1231 #
1232 # So, first we look for a working echo in the user's PATH.
1233
1234 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1235 for dir in $PATH /usr/ucb; do
1236 IFS="$lt_save_ifs"
1237 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1238 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1239 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1240 test "X$echo_testing_string" = "X$echo_test_string"; then
1241 echo="$dir/echo"
1242 break
1243 fi
1244 done
1245 IFS="$lt_save_ifs"
1246
1247 if test "X$echo" = Xecho; then
1248 # We didn't find a better echo, so look for alternatives.
1249 if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
1250 echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
1251 test "X$echo_testing_string" = "X$echo_test_string"; then
1252 # This shell has a builtin print -r that does the trick.
1253 echo='print -r'
1254 elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
1255 test "X$CONFIG_SHELL" != X/bin/ksh; then
1256 # If we have ksh, try running configure again with it.
1257 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1258 export ORIGINAL_CONFIG_SHELL
1259 CONFIG_SHELL=/bin/ksh
1260 export CONFIG_SHELL
1261 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1262 else
1263 # Try using printf.
1264 echo='printf %s\n'
1265 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1266 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1267 test "X$echo_testing_string" = "X$echo_test_string"; then
1268 # Cool, printf works
1269 :
1270 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1271 test "X$echo_testing_string" = 'X\t' &&
1272 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1273 test "X$echo_testing_string" = "X$echo_test_string"; then
1274 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1275 export CONFIG_SHELL
1276 SHELL="$CONFIG_SHELL"
1277 export SHELL
1278 echo="$CONFIG_SHELL [$]0 --fallback-echo"
1279 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1280 test "X$echo_testing_string" = 'X\t' &&
1281 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1282 test "X$echo_testing_string" = "X$echo_test_string"; then
1283 echo="$CONFIG_SHELL [$]0 --fallback-echo"
1284 else
1285 # maybe with a smaller string...
1286 prev=:
1287
1288 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1289 if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
1290 then
1291 break
1292 fi
1293 prev="$cmd"
1294 done
1295
1296 if test "$prev" != 'sed 50q "[$]0"'; then
1297 echo_test_string=`eval $prev`
1298 export echo_test_string
1299 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1300 else
1301 # Oops. We lost completely, so just stick with echo.
1302 echo=echo
1303 fi
1304 fi
1305 fi
1306 fi
1307fi
1308fi
1309
1310# Copy echo and quote the copy suitably for passing to libtool from
1311# the Makefile, instead of quoting the original, which is used later.
1312ECHO=$echo
1313if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1314 ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1315fi
1316
1317AC_SUBST(ECHO)
1318])])# _LT_AC_PROG_ECHO_BACKSLASH
1319
1320
1321# _LT_AC_LOCK
1322# -----------
1323AC_DEFUN([_LT_AC_LOCK],
1324[AC_ARG_ENABLE([libtool-lock],
1325 [AC_HELP_STRING([--disable-libtool-lock],
1326 [avoid locking (might break parallel builds)])])
1327test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1328
1329# Some flags need to be propagated to the compiler or linker for good
1330# libtool support.
1331case $host in
1332ia64-*-hpux*)
1333 # Find out which ABI we are using.
1334 echo 'int i;' > conftest.$ac_ext
1335 if AC_TRY_EVAL(ac_compile); then
1336 case `/usr/bin/file conftest.$ac_objext` in
1337 *ELF-32*)
1338 HPUX_IA64_MODE="32"
1339 ;;
1340 *ELF-64*)
1341 HPUX_IA64_MODE="64"
1342 ;;
1343 esac
1344 fi
1345 rm -rf conftest*
1346 ;;
1347*-*-irix6*)
1348 # Find out which ABI we are using.
1349 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1350 if AC_TRY_EVAL(ac_compile); then
1351 if test "$lt_cv_prog_gnu_ld" = yes; then
1352 case `/usr/bin/file conftest.$ac_objext` in
1353 *32-bit*)
1354 LD="${LD-ld} -melf32bsmip"
1355 ;;
1356 *N32*)
1357 LD="${LD-ld} -melf32bmipn32"
1358 ;;
1359 *64-bit*)
1360 LD="${LD-ld} -melf64bmip"
1361 ;;
1362 esac
1363 else
1364 case `/usr/bin/file conftest.$ac_objext` in
1365 *32-bit*)
1366 LD="${LD-ld} -32"
1367 ;;
1368 *N32*)
1369 LD="${LD-ld} -n32"
1370 ;;
1371 *64-bit*)
1372 LD="${LD-ld} -64"
1373 ;;
1374 esac
1375 fi
1376 fi
1377 rm -rf conftest*
1378 ;;
1379
1380x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
1381 # Find out which ABI we are using.
1382 echo 'int i;' > conftest.$ac_ext
1383 if AC_TRY_EVAL(ac_compile); then
1384 case `/usr/bin/file conftest.o` in
1385 *32-bit*)
1386 case $host in
1387 x86_64-*linux*)
1388 LD="${LD-ld} -m elf_i386"
1389 ;;
1390 ppc64-*linux*|powerpc64-*linux*)
1391 LD="${LD-ld} -m elf32ppclinux"
1392 ;;
1393 s390x-*linux*)
1394 LD="${LD-ld} -m elf_s390"
1395 ;;
1396 sparc64-*linux*)
1397 LD="${LD-ld} -m elf32_sparc"
1398 ;;
1399 esac
1400 ;;
1401 *64-bit*)
1402 case $host in
1403 x86_64-*linux*)
1404 LD="${LD-ld} -m elf_x86_64"
1405 ;;
1406 ppc*-*linux*|powerpc*-*linux*)
1407 LD="${LD-ld} -m elf64ppc"
1408 ;;
1409 s390*-*linux*)
1410 LD="${LD-ld} -m elf64_s390"
1411 ;;
1412 sparc*-*linux*)
1413 LD="${LD-ld} -m elf64_sparc"
1414 ;;
1415 esac
1416 ;;
1417 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 SAVE_CFLAGS="$CFLAGS"
1425 CFLAGS="$CFLAGS -belf"
1426 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1427 [AC_LANG_PUSH(C)
1428 AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1429 AC_LANG_POP])
1430 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1431 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1432 CFLAGS="$SAVE_CFLAGS"
1433 fi
1434 ;;
1435sparc*-*solaris*)
1436 # Find out which ABI we are using.
1437 echo 'int i;' > conftest.$ac_ext
1438 if AC_TRY_EVAL(ac_compile); then
1439 case `/usr/bin/file conftest.o` in
1440 *64-bit*)
1441 case $lt_cv_prog_gnu_ld in
1442 yes*) LD="${LD-ld} -m elf64_sparc" ;;
1443 *) LD="${LD-ld} -64" ;;
1444 esac
1445 ;;
1446 esac
1447 fi
1448 rm -rf conftest*
1449 ;;
1450
1451AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1452[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
1453 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
1454 AC_CHECK_TOOL(AS, as, false)
1455 AC_CHECK_TOOL(OBJDUMP, objdump, false)
1456 ;;
1457 ])
1458esac
1459
1460need_locks="$enable_libtool_lock"
1461
1462])# _LT_AC_LOCK
1463
1464
1465# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1466# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1467# ----------------------------------------------------------------
1468# Check whether the given compiler option works
1469AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
1470[AC_REQUIRE([LT_AC_PROG_SED])
1471AC_CACHE_CHECK([$1], [$2],
1472 [$2=no
1473 ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1474 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1475 lt_compiler_flag="$3"
1476 # Insert the option either (1) after the last *FLAGS variable, or
1477 # (2) before a word containing "conftest.", or (3) at the end.
1478 # Note that $ac_compile itself does not contain backslashes and begins
1479 # with a dollar sign (not a hyphen), so the echo should work correctly.
1480 # The option is referenced via a variable to avoid confusing sed.
1481 lt_compile=`echo "$ac_compile" | $SED \
1482 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1483 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1484 -e 's:$: $lt_compiler_flag:'`
1485 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1486 (eval "$lt_compile" 2>conftest.err)
1487 ac_status=$?
1488 cat conftest.err >&AS_MESSAGE_LOG_FD
1489 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1490 if (exit $ac_status) && test -s "$ac_outfile"; then
1491 # The compiler can only warn and ignore the option if not recognized
1492 # So say no if there are warnings other than the usual output.
1493 $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
1494 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1495 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1496 $2=yes
1497 fi
1498 fi
1499 $rm conftest*
1500])
1501
1502if test x"[$]$2" = xyes; then
1503 ifelse([$5], , :, [$5])
1504else
1505 ifelse([$6], , :, [$6])
1506fi
1507])# AC_LIBTOOL_COMPILER_OPTION
1508
1509
1510# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1511# [ACTION-SUCCESS], [ACTION-FAILURE])
1512# ------------------------------------------------------------
1513# Check whether the given compiler option works
1514AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
1515[AC_CACHE_CHECK([$1], [$2],
1516 [$2=no
1517 save_LDFLAGS="$LDFLAGS"
1518 LDFLAGS="$LDFLAGS $3"
1519 printf "$lt_simple_link_test_code" > conftest.$ac_ext
1520 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1521 # The linker can only warn and ignore the option if not recognized
1522 # So say no if there are warnings
1523 if test -s conftest.err; then
1524 # Append any errors to the config.log.
1525 cat conftest.err 1>&AS_MESSAGE_LOG_FD
1526 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
1527 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1528 if diff conftest.exp conftest.er2 >/dev/null; then
1529 $2=yes
1530 fi
1531 else
1532 $2=yes
1533 fi
1534 fi
1535 $rm conftest*
1536 LDFLAGS="$save_LDFLAGS"
1537])
1538
1539if test x"[$]$2" = xyes; then
1540 ifelse([$4], , :, [$4])
1541else
1542 ifelse([$5], , :, [$5])
1543fi
1544])# AC_LIBTOOL_LINKER_OPTION
1545
1546
1547# AC_LIBTOOL_SYS_MAX_CMD_LEN
1548# --------------------------
1549AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
1550[# find the maximum length of command line arguments
1551AC_MSG_CHECKING([the maximum length of command line arguments])
1552AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1553 i=0
1554 teststring="ABCD"
1555
1556 case $build_os in
1557 msdosdjgpp*)
1558 # On DJGPP, this test can blow up pretty badly due to problems in libc
1559 # (any single argument exceeding 2000 bytes causes a buffer overrun
1560 # during glob expansion). Even if it were fixed, the result of this
1561 # check would be larger than it should be.
1562 lt_cv_sys_max_cmd_len=12288; # 12K is about right
1563 ;;
1564
1565 gnu*)
1566 # Under GNU Hurd, this test is not required because there is
1567 # no limit to the length of command line arguments.
1568 # Libtool will interpret -1 as no limit whatsoever
1569 lt_cv_sys_max_cmd_len=-1;
1570 ;;
1571
1572 cygwin* | mingw*)
1573 # On Win9x/ME, this test blows up -- it succeeds, but takes
1574 # about 5 minutes as the teststring grows exponentially.
1575 # Worse, since 9x/ME are not pre-emptively multitasking,
1576 # you end up with a "frozen" computer, even though with patience
1577 # the test eventually succeeds (with a max line length of 256k).
1578 # Instead, let's just punt: use the minimum linelength reported by
1579 # all of the supported platforms: 8192 (on NT/2K/XP).
1580 lt_cv_sys_max_cmd_len=8192;
1581 ;;
1582
1583 amigaos*)
1584 # On AmigaOS with pdksh, this test takes hours, literally.
1585 # So we just punt and use a minimum line length of 8192.
1586 lt_cv_sys_max_cmd_len=8192;
1587 ;;
1588
1589 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1590 # This has been around since 386BSD, at least. Likely further.
1591 if test -x /sbin/sysctl; then
1592 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1593 elif test -x /usr/sbin/sysctl; then
1594 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1595 else
1596 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1597 fi
1598 # And add a safety zone
1599 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1600 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1601 ;;
1602
1603 interix*)
1604 # We know the value 262144 and hardcode it with a safety zone (like BSD)
1605 lt_cv_sys_max_cmd_len=196608
1606 ;;
1607
1608 osf*)
1609 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1610 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1611 # nice to cause kernel panics so lets avoid the loop below.
1612 # First set a reasonable default.
1613 lt_cv_sys_max_cmd_len=16384
1614 #
1615 if test -x /sbin/sysconfig; then
1616 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1617 *1*) lt_cv_sys_max_cmd_len=-1 ;;
1618 esac
1619 fi
1620 ;;
1621 sco3.2v5*)
1622 lt_cv_sys_max_cmd_len=102400
1623 ;;
1624 sysv5* | sco5v6* | sysv4.2uw2*)
1625 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1626 if test -n "$kargmax"; then
1627 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1628 else
1629 lt_cv_sys_max_cmd_len=32768
1630 fi
1631 ;;
1632 *)
1633 # If test is not a shell built-in, we'll probably end up computing a
1634 # maximum length that is only half of the actual maximum length, but
1635 # we can't tell.
1636 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1637 while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
1638 = "XX$teststring") >/dev/null 2>&1 &&
1639 new_result=`expr "X$teststring" : ".*" 2>&1` &&
1640 lt_cv_sys_max_cmd_len=$new_result &&
1641 test $i != 17 # 1/2 MB should be enough
1642 do
1643 i=`expr $i + 1`
1644 teststring=$teststring$teststring
1645 done
1646 teststring=
1647 # Add a significant safety factor because C++ compilers can tack on massive
1648 # amounts of additional arguments before passing them to the linker.
1649 # It appears as though 1/2 is a usable value.
1650 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1651 ;;
1652 esac
1653])
1654if test -n $lt_cv_sys_max_cmd_len ; then
1655 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1656else
1657 AC_MSG_RESULT(none)
1658fi
1659])# AC_LIBTOOL_SYS_MAX_CMD_LEN
1660
1661
1662# _LT_AC_CHECK_DLFCN
1663# ------------------
1664AC_DEFUN([_LT_AC_CHECK_DLFCN],
1665[AC_CHECK_HEADERS(dlfcn.h)dnl
1666])# _LT_AC_CHECK_DLFCN
1667
1668
1669# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1670# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1671# ---------------------------------------------------------------------
1672AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
1673[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1674if test "$cross_compiling" = yes; then :
1675 [$4]
1676else
1677 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1678 lt_status=$lt_dlunknown
1679 cat > conftest.$ac_ext <<EOF
1680[#line __oline__ "configure"
1681#include "confdefs.h"
1682
1683#if HAVE_DLFCN_H
1684#include <dlfcn.h>
1685#endif
1686
1687#include <stdio.h>
1688
1689#ifdef RTLD_GLOBAL
1690# define LT_DLGLOBAL RTLD_GLOBAL
1691#else
1692# ifdef DL_GLOBAL
1693# define LT_DLGLOBAL DL_GLOBAL
1694# else
1695# define LT_DLGLOBAL 0
1696# endif
1697#endif
1698
1699/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1700 find out it does not work in some platform. */
1701#ifndef LT_DLLAZY_OR_NOW
1702# ifdef RTLD_LAZY
1703# define LT_DLLAZY_OR_NOW RTLD_LAZY
1704# else
1705# ifdef DL_LAZY
1706# define LT_DLLAZY_OR_NOW DL_LAZY
1707# else
1708# ifdef RTLD_NOW
1709# define LT_DLLAZY_OR_NOW RTLD_NOW
1710# else
1711# ifdef DL_NOW
1712# define LT_DLLAZY_OR_NOW DL_NOW
1713# else
1714# define LT_DLLAZY_OR_NOW 0
1715# endif
1716# endif
1717# endif
1718# endif
1719#endif
1720
1721#ifdef __cplusplus
1722extern "C" void exit (int);
1723#endif
1724
1725void fnord() { int i=42;}
1726int main ()
1727{
1728 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1729 int status = $lt_dlunknown;
1730
1731 if (self)
1732 {
1733 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1734 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1735 /* dlclose (self); */
1736 }
1737 else
1738 puts (dlerror ());
1739
1740 exit (status);
1741}]
1742EOF
1743 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1744 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1745 lt_status=$?
1746 case x$lt_status in
1747 x$lt_dlno_uscore) $1 ;;
1748 x$lt_dlneed_uscore) $2 ;;
1749 x$lt_dlunknown|x*) $3 ;;
1750 esac
1751 else :
1752 # compilation failed
1753 $3
1754 fi
1755fi
1756rm -fr conftest*
1757])# _LT_AC_TRY_DLOPEN_SELF
1758
1759
1760# AC_LIBTOOL_DLOPEN_SELF
1761# ----------------------
1762AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
1763[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1764if test "x$enable_dlopen" != xyes; then
1765 enable_dlopen=unknown
1766 enable_dlopen_self=unknown
1767 enable_dlopen_self_static=unknown
1768else
1769 lt_cv_dlopen=no
1770 lt_cv_dlopen_libs=
1771
1772 case $host_os in
1773 beos*)
1774 lt_cv_dlopen="load_add_on"
1775 lt_cv_dlopen_libs=
1776 lt_cv_dlopen_self=yes
1777 ;;
1778
1779 mingw* | pw32*)
1780 lt_cv_dlopen="LoadLibrary"
1781 lt_cv_dlopen_libs=
1782 ;;
1783
1784 cygwin*)
1785 lt_cv_dlopen="dlopen"
1786 lt_cv_dlopen_libs=
1787 ;;
1788
1789 darwin*)
1790 # if libdl is installed we need to link against it
1791 AC_CHECK_LIB([dl], [dlopen],
1792 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1793 lt_cv_dlopen="dyld"
1794 lt_cv_dlopen_libs=
1795 lt_cv_dlopen_self=yes
1796 ])
1797 ;;
1798
1799 *)
1800 AC_CHECK_FUNC([shl_load],
1801 [lt_cv_dlopen="shl_load"],
1802 [AC_CHECK_LIB([dld], [shl_load],
1803 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
1804 [AC_CHECK_FUNC([dlopen],
1805 [lt_cv_dlopen="dlopen"],
1806 [AC_CHECK_LIB([dl], [dlopen],
1807 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1808 [AC_CHECK_LIB([svld], [dlopen],
1809 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1810 [AC_CHECK_LIB([dld], [dld_link],
1811 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
1812 ])
1813 ])
1814 ])
1815 ])
1816 ])
1817 ;;
1818 esac
1819
1820 if test "x$lt_cv_dlopen" != xno; then
1821 enable_dlopen=yes
1822 else
1823 enable_dlopen=no
1824 fi
1825
1826 case $lt_cv_dlopen in
1827 dlopen)
1828 save_CPPFLAGS="$CPPFLAGS"
1829 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1830
1831 save_LDFLAGS="$LDFLAGS"
1832 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1833
1834 save_LIBS="$LIBS"
1835 LIBS="$lt_cv_dlopen_libs $LIBS"
1836
1837 AC_CACHE_CHECK([whether a program can dlopen itself],
1838 lt_cv_dlopen_self, [dnl
1839 _LT_AC_TRY_DLOPEN_SELF(
1840 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1841 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1842 ])
1843
1844 if test "x$lt_cv_dlopen_self" = xyes; then
1845 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1846 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1847 lt_cv_dlopen_self_static, [dnl
1848 _LT_AC_TRY_DLOPEN_SELF(
1849 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1850 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1851 ])
1852 fi
1853
1854 CPPFLAGS="$save_CPPFLAGS"
1855 LDFLAGS="$save_LDFLAGS"
1856 LIBS="$save_LIBS"
1857 ;;
1858 esac
1859
1860 case $lt_cv_dlopen_self in
1861 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1862 *) enable_dlopen_self=unknown ;;
1863 esac
1864
1865 case $lt_cv_dlopen_self_static in
1866 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1867 *) enable_dlopen_self_static=unknown ;;
1868 esac
1869fi
1870])# AC_LIBTOOL_DLOPEN_SELF
1871
1872
1873# AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1874# ---------------------------------
1875# Check to see if options -c and -o are simultaneously supported by compiler
1876AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1877[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1878AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1879 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1880 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1881 $rm -r conftest 2>/dev/null
1882 mkdir conftest
1883 cd conftest
1884 mkdir out
1885 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1886
1887 lt_compiler_flag="-o out/conftest2.$ac_objext"
1888 # Insert the option either (1) after the last *FLAGS variable, or
1889 # (2) before a word containing "conftest.", or (3) at the end.
1890 # Note that $ac_compile itself does not contain backslashes and begins
1891 # with a dollar sign (not a hyphen), so the echo should work correctly.
1892 lt_compile=`echo "$ac_compile" | $SED \
1893 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1894 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1895 -e 's:$: $lt_compiler_flag:'`
1896 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1897 (eval "$lt_compile" 2>out/conftest.err)
1898 ac_status=$?
1899 cat out/conftest.err >&AS_MESSAGE_LOG_FD
1900 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1901 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1902 then
1903 # The compiler can only warn and ignore the option if not recognized
1904 # So say no if there are warnings
1905 $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
1906 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
1907 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1908 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1909 fi
1910 fi
1911 chmod u+w . 2>&AS_MESSAGE_LOG_FD
1912 $rm conftest*
1913 # SGI C++ compiler will create directory out/ii_files/ for
1914 # template instantiation
1915 test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
1916 $rm out/* && rmdir out
1917 cd ..
1918 rmdir conftest
1919 $rm conftest*
1920])
1921])# AC_LIBTOOL_PROG_CC_C_O
1922
1923
1924# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
1925# -----------------------------------------
1926# Check to see if we can do hard links to lock some files if needed
1927AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
1928[AC_REQUIRE([_LT_AC_LOCK])dnl
1929
1930hard_links="nottested"
1931if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1932 # do not overwrite the value of need_locks provided by the user
1933 AC_MSG_CHECKING([if we can lock with hard links])
1934 hard_links=yes
1935 $rm conftest*
1936 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1937 touch conftest.a
1938 ln conftest.a conftest.b 2>&5 || hard_links=no
1939 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1940 AC_MSG_RESULT([$hard_links])
1941 if test "$hard_links" = no; then
1942 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1943 need_locks=warn
1944 fi
1945else
1946 need_locks=no
1947fi
1948])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
1949
1950
1951# AC_LIBTOOL_OBJDIR
1952# -----------------
1953AC_DEFUN([AC_LIBTOOL_OBJDIR],
1954[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
1955[rm -f .libs 2>/dev/null
1956mkdir .libs 2>/dev/null
1957if test -d .libs; then
1958 lt_cv_objdir=.libs
1959else
1960 # MS-DOS does not allow filenames that begin with a dot.
1961 lt_cv_objdir=_libs
1962fi
1963rmdir .libs 2>/dev/null])
1964objdir=$lt_cv_objdir
1965])# AC_LIBTOOL_OBJDIR
1966
1967
1968# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
1969# ----------------------------------------------
1970# Check hardcoding attributes.
1971AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
1972[AC_MSG_CHECKING([how to hardcode library paths into programs])
1973_LT_AC_TAGVAR(hardcode_action, $1)=
1974if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
1975 test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
1976 test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
1977
1978 # We can hardcode non-existant directories.
1979 if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
1980 # If the only mechanism to avoid hardcoding is shlibpath_var, we
1981 # have to relink, otherwise we might link with an installed library
1982 # when we should be linking with a yet-to-be-installed one
1983 ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
1984 test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
1985 # Linking always hardcodes the temporary library directory.
1986 _LT_AC_TAGVAR(hardcode_action, $1)=relink
1987 else
1988 # We can link without hardcoding, and we can hardcode nonexisting dirs.
1989 _LT_AC_TAGVAR(hardcode_action, $1)=immediate
1990 fi
1991else
1992 # We cannot hardcode anything, or else we can only hardcode existing
1993 # directories.
1994 _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
1995fi
1996AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
1997
1998if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
1999 # Fast installation is not supported
2000 enable_fast_install=no
2001elif test "$shlibpath_overrides_runpath" = yes ||
2002 test "$enable_shared" = no; then
2003 # Fast installation is not necessary
2004 enable_fast_install=needless
2005fi
2006])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
2007
2008
2009# AC_LIBTOOL_SYS_LIB_STRIP
2010# ------------------------
2011AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
2012[striplib=
2013old_striplib=
2014AC_MSG_CHECKING([whether stripping libraries is possible])
2015if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
2016 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2017 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2018 AC_MSG_RESULT([yes])
2019else
2020# FIXME - insert some real tests, host_os isn't really good enough
2021 case $host_os in
2022 darwin*)
2023 if test -n "$STRIP" ; then
2024 striplib="$STRIP -x"
2025 AC_MSG_RESULT([yes])
2026 else
2027 AC_MSG_RESULT([no])
2028fi
2029 ;;
2030 *)
2031 AC_MSG_RESULT([no])
2032 ;;
2033 esac
2034fi
2035])# AC_LIBTOOL_SYS_LIB_STRIP
2036
2037
2038# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2039# -----------------------------
2040# PORTME Fill in your ld.so characteristics
2041AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
2042[AC_MSG_CHECKING([dynamic linker characteristics])
2043library_names_spec=
2044libname_spec='lib$name'
2045soname_spec=
2046shrext_cmds=".so"
2047postinstall_cmds=
2048postuninstall_cmds=
2049finish_cmds=
2050finish_eval=
2051shlibpath_var=
2052shlibpath_overrides_runpath=unknown
2053version_type=none
2054dynamic_linker="$host_os ld.so"
2055sys_lib_dlsearch_path_spec="/lib /usr/lib"
2056if test "$GCC" = yes; then
2057 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2058 if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
2059 # if the path contains ";" then we assume it to be the separator
2060 # otherwise default to the standard path separator (i.e. ":") - it is
2061 # assumed that no part of a normal pathname contains ";" but that should
2062 # okay in the real world where ";" in dirpaths is itself problematic.
2063 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2064 else
2065 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2066 fi
2067else
2068 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2069fi
2070need_lib_prefix=unknown
2071hardcode_into_libs=no
2072
2073# when you set need_version to no, make sure it does not cause -set_version
2074# flags to be left without arguments
2075need_version=unknown
2076
2077case $host_os in
2078aix3*)
2079 version_type=linux
2080 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2081 shlibpath_var=LIBPATH
2082
2083 # AIX 3 has no versioning support, so we append a major version to the name.
2084 soname_spec='${libname}${release}${shared_ext}$major'
2085 ;;
2086
2087aix4* | aix5*)
2088 version_type=linux
2089 need_lib_prefix=no
2090 need_version=no
2091 hardcode_into_libs=yes
2092 if test "$host_cpu" = ia64; then
2093 # AIX 5 supports IA64
2094 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2095 shlibpath_var=LD_LIBRARY_PATH
2096 else
2097 # With GCC up to 2.95.x, collect2 would create an import file
2098 # for dependence libraries. The import file would start with
2099 # the line `#! .'. This would cause the generated library to
2100 # depend on `.', always an invalid library. This was fixed in
2101 # development snapshots of GCC prior to 3.0.
2102 case $host_os in
2103 aix4 | aix4.[[01]] | aix4.[[01]].*)
2104 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2105 echo ' yes '
2106 echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
2107 :
2108 else
2109 can_build_shared=no
2110 fi
2111 ;;
2112 esac
2113 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2114 # soname into executable. Probably we can add versioning support to
2115 # collect2, so additional links can be useful in future.
2116 if test "$aix_use_runtimelinking" = yes; then
2117 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2118 # instead of lib<name>.a to let people know that these are not
2119 # typical AIX shared libraries.
2120 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2121 else
2122 # We preserve .a as extension for shared libraries through AIX4.2
2123 # and later when we are not doing run time linking.
2124 library_names_spec='${libname}${release}.a $libname.a'
2125 soname_spec='${libname}${release}${shared_ext}$major'
2126 fi
2127 shlibpath_var=LIBPATH
2128 fi
2129 ;;
2130
2131amigaos*)
2132 library_names_spec='$libname.ixlibrary $libname.a'
2133 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2134 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2135 ;;
2136
2137beos*)
2138 library_names_spec='${libname}${shared_ext}'
2139 dynamic_linker="$host_os ld.so"
2140 shlibpath_var=LIBRARY_PATH
2141 ;;
2142
2143bsdi[[45]]*)
2144 version_type=linux
2145 need_version=no
2146 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2147 soname_spec='${libname}${release}${shared_ext}$major'
2148 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2149 shlibpath_var=LD_LIBRARY_PATH
2150 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2151 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2152 # the default ld.so.conf also contains /usr/contrib/lib and
2153 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2154 # libtool to hard-code these into programs
2155 ;;
2156
2157cygwin* | mingw* | pw32*)
2158 version_type=windows
2159 shrext_cmds=".dll"
2160 need_version=no
2161 need_lib_prefix=no
2162
2163 case $GCC,$host_os in
2164 yes,cygwin* | yes,mingw* | yes,pw32*)
2165 library_names_spec='$libname.dll.a'
2166 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2167 postinstall_cmds='base_file=`basename \${file}`~
2168 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
2169 dldir=$destdir/`dirname \$dlpath`~
2170 test -d \$dldir || mkdir -p \$dldir~
2171 $install_prog $dir/$dlname \$dldir/$dlname~
2172 chmod a+x \$dldir/$dlname'
2173 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2174 dlpath=$dir/\$dldll~
2175 $rm \$dlpath'
2176 shlibpath_overrides_runpath=yes
2177
2178 case $host_os in
2179 cygwin*)
2180 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2181 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2182 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2183 ;;
2184 mingw*)
2185 # MinGW DLLs use traditional 'lib' prefix
2186 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2187 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2188 if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
2189 # It is most probably a Windows format PATH printed by
2190 # mingw gcc, but we are running on Cygwin. Gcc prints its search
2191 # path with ; separators, and with drive letters. We can handle the
2192 # drive letters (cygwin fileutils understands them), so leave them,
2193 # especially as we might pass files found there to a mingw objdump,
2194 # which wouldn't understand a cygwinified path. Ahh.
2195 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2196 else
2197 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2198 fi
2199 ;;
2200 pw32*)
2201 # pw32 DLLs use 'pw' prefix rather than 'lib'
2202 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2203 ;;
2204 esac
2205 ;;
2206
2207 *)
2208 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2209 ;;
2210 esac
2211 dynamic_linker='Win32 ld.exe'
2212 # FIXME: first we should search . and the directory the executable is in
2213 shlibpath_var=PATH
2214 ;;
2215
2216darwin* | rhapsody*)
2217 dynamic_linker="$host_os dyld"
2218 version_type=darwin
2219 need_lib_prefix=no
2220 need_version=no
2221 library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2222 soname_spec='${libname}${release}${major}$shared_ext'
2223 shlibpath_overrides_runpath=yes
2224 shlibpath_var=DYLD_LIBRARY_PATH
2225 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2226 # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
2227 if test "$GCC" = yes; then
2228 sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
2229 else
2230 sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
2231 fi
2232 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2233 ;;
2234
2235dgux*)
2236 version_type=linux
2237 need_lib_prefix=no
2238 need_version=no
2239 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2240 soname_spec='${libname}${release}${shared_ext}$major'
2241 shlibpath_var=LD_LIBRARY_PATH
2242 ;;
2243
2244freebsd1*)
2245 dynamic_linker=no
2246 ;;
2247
2248freebsd* | dragonfly*)
2249 # DragonFly does not have aout. When/if they implement a new
2250 # versioning mechanism, adjust this.
2251 if test -x /usr/bin/objformat; then
2252 objformat=`/usr/bin/objformat`
2253 else
2254 case $host_os in
2255 freebsd[[123]]*) objformat=aout ;;
2256 *) objformat=elf ;;
2257 esac
2258 fi
2259 version_type=freebsd-$objformat
2260 case $version_type in
2261 freebsd-elf*)
2262 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2263 need_version=no
2264 need_lib_prefix=no
2265 ;;
2266 freebsd-*)
2267 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2268 need_version=yes
2269 ;;
2270 esac
2271 shlibpath_var=LD_LIBRARY_PATH
2272 case $host_os in
2273 freebsd2*)
2274 shlibpath_overrides_runpath=yes
2275 ;;
2276 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2277 shlibpath_overrides_runpath=yes
2278 hardcode_into_libs=yes
2279 ;;
2280 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2281 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2282 shlibpath_overrides_runpath=no
2283 hardcode_into_libs=yes
2284 ;;
2285 freebsd*) # from 4.6 on
2286 shlibpath_overrides_runpath=yes
2287 hardcode_into_libs=yes
2288 ;;
2289 esac
2290 ;;
2291
2292gnu*)
2293 version_type=linux
2294 need_lib_prefix=no
2295 need_version=no
2296 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2297 soname_spec='${libname}${release}${shared_ext}$major'
2298 shlibpath_var=LD_LIBRARY_PATH
2299 hardcode_into_libs=yes
2300 ;;
2301
2302hpux9* | hpux10* | hpux11*)
2303 # Give a soname corresponding to the major version so that dld.sl refuses to
2304 # link against other versions.
2305 version_type=sunos
2306 need_lib_prefix=no
2307 need_version=no
2308 case $host_cpu in
2309 ia64*)
2310 shrext_cmds='.so'
2311 hardcode_into_libs=yes
2312 dynamic_linker="$host_os dld.so"
2313 shlibpath_var=LD_LIBRARY_PATH
2314 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2315 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2316 soname_spec='${libname}${release}${shared_ext}$major'
2317 if test "X$HPUX_IA64_MODE" = X32; then
2318 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2319 else
2320 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2321 fi
2322 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2323 ;;
2324 hppa*64*)
2325 shrext_cmds='.sl'
2326 hardcode_into_libs=yes
2327 dynamic_linker="$host_os dld.sl"
2328 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2329 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2330 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2331 soname_spec='${libname}${release}${shared_ext}$major'
2332 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2333 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2334 ;;
2335 *)
2336 shrext_cmds='.sl'
2337 dynamic_linker="$host_os dld.sl"
2338 shlibpath_var=SHLIB_PATH
2339 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2340 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2341 soname_spec='${libname}${release}${shared_ext}$major'
2342 ;;
2343 esac
2344 # HP-UX runs *really* slowly unless shared libraries are mode 555.
2345 postinstall_cmds='chmod 555 $lib'
2346 ;;
2347
2348interix3*)
2349 version_type=linux
2350 need_lib_prefix=no
2351 need_version=no
2352 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2353 soname_spec='${libname}${release}${shared_ext}$major'
2354 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2355 shlibpath_var=LD_LIBRARY_PATH
2356 shlibpath_overrides_runpath=no
2357 hardcode_into_libs=yes
2358 ;;
2359
2360irix5* | irix6* | nonstopux*)
2361 case $host_os in
2362 nonstopux*) version_type=nonstopux ;;
2363 *)
2364 if test "$lt_cv_prog_gnu_ld" = yes; then
2365 version_type=linux
2366 else
2367 version_type=irix
2368 fi ;;
2369 esac
2370 need_lib_prefix=no
2371 need_version=no
2372 soname_spec='${libname}${release}${shared_ext}$major'
2373 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2374 case $host_os in
2375 irix5* | nonstopux*)
2376 libsuff= shlibsuff=
2377 ;;
2378 *)
2379 case $LD in # libtool.m4 will add one of these switches to LD
2380 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2381 libsuff= shlibsuff= libmagic=32-bit;;
2382 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2383 libsuff=32 shlibsuff=N32 libmagic=N32;;
2384 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2385 libsuff=64 shlibsuff=64 libmagic=64-bit;;
2386 *) libsuff= shlibsuff= libmagic=never-match;;
2387 esac
2388 ;;
2389 esac
2390 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2391 shlibpath_overrides_runpath=no
2392 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2393 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2394 hardcode_into_libs=yes
2395 ;;
2396
2397# No shared lib support for Linux oldld, aout, or coff.
2398linux*oldld* | linux*aout* | linux*coff*)
2399 dynamic_linker=no
2400 ;;
2401
2402# This must be Linux ELF.
2403linux* | k*bsd*-gnu)
2404 version_type=linux
2405 need_lib_prefix=no
2406 need_version=no
2407 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2408 soname_spec='${libname}${release}${shared_ext}$major'
2409 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2410 shlibpath_var=LD_LIBRARY_PATH
2411 shlibpath_overrides_runpath=no
2412 # This implies no fast_install, which is unacceptable.
2413 # Some rework will be needed to allow for fast_install
2414 # before this can be enabled.
2415 hardcode_into_libs=yes
2416
2417 # Append ld.so.conf contents to the search path
2418 if test -f /etc/ld.so.conf; then
2419 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
2420 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2421 fi
2422
2423 # We used to test for /lib/ld.so.1 and disable shared libraries on
2424 # powerpc, because MkLinux only supported shared libraries with the
2425 # GNU dynamic linker. Since this was broken with cross compilers,
2426 # most powerpc-linux boxes support dynamic linking these days and
2427 # people can always --disable-shared, the test was removed, and we
2428 # assume the GNU/Linux dynamic linker is in use.
2429 dynamic_linker='GNU/Linux ld.so'
2430 ;;
2431
2432netbsdelf*-gnu)
2433 version_type=linux
2434 need_lib_prefix=no
2435 need_version=no
2436 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2437 soname_spec='${libname}${release}${shared_ext}$major'
2438 shlibpath_var=LD_LIBRARY_PATH
2439 shlibpath_overrides_runpath=no
2440 hardcode_into_libs=yes
2441 dynamic_linker='NetBSD ld.elf_so'
2442 ;;
2443
2444netbsd*)
2445 version_type=sunos
2446 need_lib_prefix=no
2447 need_version=no
2448 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
2449 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2450 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2451 dynamic_linker='NetBSD (a.out) ld.so'
2452 else
2453 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2454 soname_spec='${libname}${release}${shared_ext}$major'
2455 dynamic_linker='NetBSD ld.elf_so'
2456 fi
2457 shlibpath_var=LD_LIBRARY_PATH
2458 shlibpath_overrides_runpath=yes
2459 hardcode_into_libs=yes
2460 ;;
2461
2462newsos6)
2463 version_type=linux
2464 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2465 shlibpath_var=LD_LIBRARY_PATH
2466 shlibpath_overrides_runpath=yes
2467 ;;
2468
2469nto-qnx*)
2470 version_type=linux
2471 need_lib_prefix=no
2472 need_version=no
2473 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2474 soname_spec='${libname}${release}${shared_ext}$major'
2475 shlibpath_var=LD_LIBRARY_PATH
2476 shlibpath_overrides_runpath=yes
2477 ;;
2478
2479openbsd*)
2480 version_type=sunos
2481 sys_lib_dlsearch_path_spec="/usr/lib"
2482 need_lib_prefix=no
2483 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2484 case $host_os in
2485 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2486 *) need_version=no ;;
2487 esac
2488 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2489 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2490 shlibpath_var=LD_LIBRARY_PATH
2491 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2492 case $host_os in
2493 openbsd2.[[89]] | openbsd2.[[89]].*)
2494 shlibpath_overrides_runpath=no
2495 ;;
2496 *)
2497 shlibpath_overrides_runpath=yes
2498 ;;
2499 esac
2500 else
2501 shlibpath_overrides_runpath=yes
2502 fi
2503 ;;
2504
2505os2*)
2506 libname_spec='$name'
2507 shrext_cmds=".dll"
2508 need_lib_prefix=no
2509 library_names_spec='$libname${shared_ext} $libname.a'
2510 dynamic_linker='OS/2 ld.exe'
2511 shlibpath_var=LIBPATH
2512 ;;
2513
2514osf3* | osf4* | osf5*)
2515 version_type=osf
2516 need_lib_prefix=no
2517 need_version=no
2518 soname_spec='${libname}${release}${shared_ext}$major'
2519 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2520 shlibpath_var=LD_LIBRARY_PATH
2521 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2522 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2523 ;;
2524
2525solaris*)
2526 version_type=linux
2527 need_lib_prefix=no
2528 need_version=no
2529 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2530 soname_spec='${libname}${release}${shared_ext}$major'
2531 shlibpath_var=LD_LIBRARY_PATH
2532 shlibpath_overrides_runpath=yes
2533 hardcode_into_libs=yes
2534 # ldd complains unless libraries are executable
2535 postinstall_cmds='chmod +x $lib'
2536 ;;
2537
2538sunos4*)
2539 version_type=sunos
2540 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2541 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2542 shlibpath_var=LD_LIBRARY_PATH
2543 shlibpath_overrides_runpath=yes
2544 if test "$with_gnu_ld" = yes; then
2545 need_lib_prefix=no
2546 fi
2547 need_version=yes
2548 ;;
2549
2550sysv4 | sysv4.3*)
2551 version_type=linux
2552 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2553 soname_spec='${libname}${release}${shared_ext}$major'
2554 shlibpath_var=LD_LIBRARY_PATH
2555 case $host_vendor in
2556 sni)
2557 shlibpath_overrides_runpath=no
2558 need_lib_prefix=no
2559 export_dynamic_flag_spec='${wl}-Blargedynsym'
2560 runpath_var=LD_RUN_PATH
2561 ;;
2562 siemens)
2563 need_lib_prefix=no
2564 ;;
2565 motorola)
2566 need_lib_prefix=no
2567 need_version=no
2568 shlibpath_overrides_runpath=no
2569 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2570 ;;
2571 esac
2572 ;;
2573
2574sysv4*MP*)
2575 if test -d /usr/nec ;then
2576 version_type=linux
2577 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2578 soname_spec='$libname${shared_ext}.$major'
2579 shlibpath_var=LD_LIBRARY_PATH
2580 fi
2581 ;;
2582
2583sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2584 version_type=freebsd-elf
2585 need_lib_prefix=no
2586 need_version=no
2587 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2588 soname_spec='${libname}${release}${shared_ext}$major'
2589 shlibpath_var=LD_LIBRARY_PATH
2590 hardcode_into_libs=yes
2591 if test "$with_gnu_ld" = yes; then
2592 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2593 shlibpath_overrides_runpath=no
2594 else
2595 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2596 shlibpath_overrides_runpath=yes
2597 case $host_os in
2598 sco3.2v5*)
2599 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2600 ;;
2601 esac
2602 fi
2603 sys_lib_dlsearch_path_spec='/usr/lib'
2604 ;;
2605
2606uts4*)
2607 version_type=linux
2608 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2609 soname_spec='${libname}${release}${shared_ext}$major'
2610 shlibpath_var=LD_LIBRARY_PATH
2611 ;;
2612
2613*)
2614 dynamic_linker=no
2615 ;;
2616esac
2617AC_MSG_RESULT([$dynamic_linker])
2618test "$dynamic_linker" = no && can_build_shared=no
2619
2620variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2621if test "$GCC" = yes; then
2622 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2623fi
2624])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2625
2626
2627# _LT_AC_TAGCONFIG
2628# ----------------
2629AC_DEFUN([_LT_AC_TAGCONFIG],
2630[AC_ARG_WITH([tags],
2631 [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2632 [include additional configurations @<:@automatic@:>@])],
2633 [tagnames="$withval"])
2634
2635if test -f "$ltmain" && test -n "$tagnames"; then
2636 if test ! -f "${ofile}"; then
2637 AC_MSG_WARN([output file `$ofile' does not exist])
2638 fi
2639
2640 if test -z "$LTCC"; then
2641 eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2642 if test -z "$LTCC"; then
2643 AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2644 else
2645 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2646 fi
2647 fi
2648 if test -z "$LTCFLAGS"; then
2649 eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
2650 fi
2651
2652 # Extract list of available tagged configurations in $ofile.
2653 # Note that this assumes the entire list is on one line.
2654 available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2655
2656 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2657 for tagname in $tagnames; do
2658 IFS="$lt_save_ifs"
2659 # Check whether tagname contains only valid characters
2660 case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2661 "") ;;
2662 *) AC_MSG_ERROR([invalid tag name: $tagname])
2663 ;;
2664 esac
2665
2666 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2667 then
2668 AC_MSG_ERROR([tag name \"$tagname\" already exists])
2669 fi
2670
2671 # Update the list of available tags.
2672 if test -n "$tagname"; then
2673 echo appending configuration tag \"$tagname\" to $ofile
2674
2675 case $tagname in
2676 CXX)
2677 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2678 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2679 (test "X$CXX" != "Xg++"))) ; then
2680 AC_LIBTOOL_LANG_CXX_CONFIG
2681 else
2682 tagname=""
2683 fi
2684 ;;
2685
2686 F77)
2687 if test -n "$F77" && test "X$F77" != "Xno"; then
2688 AC_LIBTOOL_LANG_F77_CONFIG
2689 else
2690 tagname=""
2691 fi
2692 ;;
2693
2694 GCJ)
2695 if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2696 AC_LIBTOOL_LANG_GCJ_CONFIG
2697 else
2698 tagname=""
2699 fi
2700 ;;
2701
2702 RC)
2703 AC_LIBTOOL_LANG_RC_CONFIG
2704 ;;
2705
2706 *)
2707 AC_MSG_ERROR([Unsupported tag name: $tagname])
2708 ;;
2709 esac
2710
2711 # Append the new tag name to the list of available tags.
2712 if test -n "$tagname" ; then
2713 available_tags="$available_tags $tagname"
2714 fi
2715 fi
2716 done
2717 IFS="$lt_save_ifs"
2718
2719 # Now substitute the updated list of available tags.
2720 if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2721 mv "${ofile}T" "$ofile"
2722 chmod +x "$ofile"
2723 else
2724 rm -f "${ofile}T"
2725 AC_MSG_ERROR([unable to update list of available tagged configurations.])
2726 fi
2727fi
2728])# _LT_AC_TAGCONFIG
2729
2730
2731# AC_LIBTOOL_DLOPEN
2732# -----------------
2733# enable checks for dlopen support
2734AC_DEFUN([AC_LIBTOOL_DLOPEN],
2735 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2736])# AC_LIBTOOL_DLOPEN
2737
2738
2739# AC_LIBTOOL_WIN32_DLL
2740# --------------------
2741# declare package support for building win32 DLLs
2742AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2743[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2744])# AC_LIBTOOL_WIN32_DLL
2745
2746
2747# AC_ENABLE_SHARED([DEFAULT])
2748# ---------------------------
2749# implement the --enable-shared flag
2750# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2751AC_DEFUN([AC_ENABLE_SHARED],
2752[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2753AC_ARG_ENABLE([shared],
2754 [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2755 [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2756 [p=${PACKAGE-default}
2757 case $enableval in
2758 yes) enable_shared=yes ;;
2759 no) enable_shared=no ;;
2760 *)
2761 enable_shared=no
2762 # Look at the argument we got. We use all the common list separators.
2763 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2764 for pkg in $enableval; do
2765 IFS="$lt_save_ifs"
2766 if test "X$pkg" = "X$p"; then
2767 enable_shared=yes
2768 fi
2769 done
2770 IFS="$lt_save_ifs"
2771 ;;
2772 esac],
2773 [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2774])# AC_ENABLE_SHARED
2775
2776
2777# AC_DISABLE_SHARED
2778# -----------------
2779# set the default shared flag to --disable-shared
2780AC_DEFUN([AC_DISABLE_SHARED],
2781[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2782AC_ENABLE_SHARED(no)
2783])# AC_DISABLE_SHARED
2784
2785
2786# AC_ENABLE_STATIC([DEFAULT])
2787# ---------------------------
2788# implement the --enable-static flag
2789# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2790AC_DEFUN([AC_ENABLE_STATIC],
2791[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2792AC_ARG_ENABLE([static],
2793 [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2794 [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2795 [p=${PACKAGE-default}
2796 case $enableval in
2797 yes) enable_static=yes ;;
2798 no) enable_static=no ;;
2799 *)
2800 enable_static=no
2801 # Look at the argument we got. We use all the common list separators.
2802 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2803 for pkg in $enableval; do
2804 IFS="$lt_save_ifs"
2805 if test "X$pkg" = "X$p"; then
2806 enable_static=yes
2807 fi
2808 done
2809 IFS="$lt_save_ifs"
2810 ;;
2811 esac],
2812 [enable_static=]AC_ENABLE_STATIC_DEFAULT)
2813])# AC_ENABLE_STATIC
2814
2815
2816# AC_DISABLE_STATIC
2817# -----------------
2818# set the default static flag to --disable-static
2819AC_DEFUN([AC_DISABLE_STATIC],
2820[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2821AC_ENABLE_STATIC(no)
2822])# AC_DISABLE_STATIC
2823
2824
2825# AC_ENABLE_FAST_INSTALL([DEFAULT])
2826# ---------------------------------
2827# implement the --enable-fast-install flag
2828# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2829AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2830[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2831AC_ARG_ENABLE([fast-install],
2832 [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2833 [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2834 [p=${PACKAGE-default}
2835 case $enableval in
2836 yes) enable_fast_install=yes ;;
2837 no) enable_fast_install=no ;;
2838 *)
2839 enable_fast_install=no
2840 # Look at the argument we got. We use all the common list separators.
2841 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2842 for pkg in $enableval; do
2843 IFS="$lt_save_ifs"
2844 if test "X$pkg" = "X$p"; then
2845 enable_fast_install=yes
2846 fi
2847 done
2848 IFS="$lt_save_ifs"
2849 ;;
2850 esac],
2851 [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2852])# AC_ENABLE_FAST_INSTALL
2853
2854
2855# AC_DISABLE_FAST_INSTALL
2856# -----------------------
2857# set the default to --disable-fast-install
2858AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2859[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2860AC_ENABLE_FAST_INSTALL(no)
2861])# AC_DISABLE_FAST_INSTALL
2862
2863
2864# AC_LIBTOOL_PICMODE([MODE])
2865# --------------------------
2866# implement the --with-pic flag
2867# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
2868AC_DEFUN([AC_LIBTOOL_PICMODE],
2869[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2870pic_mode=ifelse($#,1,$1,default)
2871])# AC_LIBTOOL_PICMODE
2872
2873
2874# AC_PROG_EGREP
2875# -------------
2876# This is predefined starting with Autoconf 2.54, so this conditional
2877# definition can be removed once we require Autoconf 2.54 or later.
2878m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
2879[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
2880 [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2881 then ac_cv_prog_egrep='grep -E'
2882 else ac_cv_prog_egrep='egrep'
2883 fi])
2884 EGREP=$ac_cv_prog_egrep
2885 AC_SUBST([EGREP])
2886])])
2887
2888
2889# AC_PATH_TOOL_PREFIX
2890# -------------------
2891# find a file program which can recognise shared library
2892AC_DEFUN([AC_PATH_TOOL_PREFIX],
2893[AC_REQUIRE([AC_PROG_EGREP])dnl
2894AC_MSG_CHECKING([for $1])
2895AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2896[case $MAGIC_CMD in
2897[[\\/*] | ?:[\\/]*])
2898 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2899 ;;
2900*)
2901 lt_save_MAGIC_CMD="$MAGIC_CMD"
2902 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2903dnl $ac_dummy forces splitting on constant user-supplied paths.
2904dnl POSIX.2 word splitting is done only on the output of word expansions,
2905dnl not every word. This closes a longstanding sh security hole.
2906 ac_dummy="ifelse([$2], , $PATH, [$2])"
2907 for ac_dir in $ac_dummy; do
2908 IFS="$lt_save_ifs"
2909 test -z "$ac_dir" && ac_dir=.
2910 if test -f $ac_dir/$1; then
2911 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2912 if test -n "$file_magic_test_file"; then
2913 case $deplibs_check_method in
2914 "file_magic "*)
2915 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
2916 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2917 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2918 $EGREP "$file_magic_regex" > /dev/null; then
2919 :
2920 else
2921 cat <<EOF 1>&2
2922
2923*** Warning: the command libtool uses to detect shared libraries,
2924*** $file_magic_cmd, produces output that libtool cannot recognize.
2925*** The result is that libtool may fail to recognize shared libraries
2926*** as such. This will affect the creation of libtool libraries that
2927*** depend on shared libraries, but programs linked with such libtool
2928*** libraries will work regardless of this problem. Nevertheless, you
2929*** may want to report the problem to your system manager and/or to
2930*** bug-libtool@gnu.org
2931
2932EOF
2933 fi ;;
2934 esac
2935 fi
2936 break
2937 fi
2938 done
2939 IFS="$lt_save_ifs"
2940 MAGIC_CMD="$lt_save_MAGIC_CMD"
2941 ;;
2942esac])
2943MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2944if test -n "$MAGIC_CMD"; then
2945 AC_MSG_RESULT($MAGIC_CMD)
2946else
2947 AC_MSG_RESULT(no)
2948fi
2949])# AC_PATH_TOOL_PREFIX
2950
2951
2952# AC_PATH_MAGIC
2953# -------------
2954# find a file program which can recognise a shared library
2955AC_DEFUN([AC_PATH_MAGIC],
2956[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2957if test -z "$lt_cv_path_MAGIC_CMD"; then
2958 if test -n "$ac_tool_prefix"; then
2959 AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2960 else
2961 MAGIC_CMD=:
2962 fi
2963fi
2964])# AC_PATH_MAGIC
2965
2966
2967# AC_PROG_LD
2968# ----------
2969# find the pathname to the GNU or non-GNU linker
2970AC_DEFUN([AC_PROG_LD],
2971[AC_ARG_WITH([gnu-ld],
2972 [AC_HELP_STRING([--with-gnu-ld],
2973 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
2974 [test "$withval" = no || with_gnu_ld=yes],
2975 [with_gnu_ld=no])
2976AC_REQUIRE([LT_AC_PROG_SED])dnl
2977AC_REQUIRE([AC_PROG_CC])dnl
2978AC_REQUIRE([AC_CANONICAL_HOST])dnl
2979AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2980ac_prog=ld
2981if test "$GCC" = yes; then
2982 # Check if gcc -print-prog-name=ld gives a path.
2983 AC_MSG_CHECKING([for ld used by $CC])
2984 case $host in
2985 *-*-mingw*)
2986 # gcc leaves a trailing carriage return which upsets mingw
2987 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2988 *)
2989 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2990 esac
2991 case $ac_prog in
2992 # Accept absolute paths.
2993 [[\\/]]* | ?:[[\\/]]*)
2994 re_direlt='/[[^/]][[^/]]*/\.\./'
2995 # Canonicalize the pathname of ld
2996 ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
2997 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2998 ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
2999 done
3000 test -z "$LD" && LD="$ac_prog"
3001 ;;
3002 "")
3003 # If it fails, then pretend we aren't using GCC.
3004 ac_prog=ld
3005 ;;
3006 *)
3007 # If it is relative, then search for the first ld in PATH.
3008 with_gnu_ld=unknown
3009 ;;
3010 esac
3011elif test "$with_gnu_ld" = yes; then
3012 AC_MSG_CHECKING([for GNU ld])
3013else
3014 AC_MSG_CHECKING([for non-GNU ld])
3015fi
3016AC_CACHE_VAL(lt_cv_path_LD,
3017[if test -z "$LD"; then
3018 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3019 for ac_dir in $PATH; do
3020 IFS="$lt_save_ifs"
3021 test -z "$ac_dir" && ac_dir=.
3022 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3023 lt_cv_path_LD="$ac_dir/$ac_prog"
3024 # Check to see if the program is GNU ld. I'd rather use --version,
3025 # but apparently some variants of GNU ld only accept -v.
3026 # Break only if it was the GNU/non-GNU ld that we prefer.
3027 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3028 *GNU* | *'with BFD'*)
3029 test "$with_gnu_ld" != no && break
3030 ;;
3031 *)
3032 test "$with_gnu_ld" != yes && break
3033 ;;
3034 esac
3035 fi
3036 done
3037 IFS="$lt_save_ifs"
3038else
3039 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3040fi])
3041LD="$lt_cv_path_LD"
3042if test -n "$LD"; then
3043 AC_MSG_RESULT($LD)
3044else
3045 AC_MSG_RESULT(no)
3046fi
3047test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3048AC_PROG_LD_GNU
3049])# AC_PROG_LD
3050
3051
3052# AC_PROG_LD_GNU
3053# --------------
3054AC_DEFUN([AC_PROG_LD_GNU],
3055[AC_REQUIRE([AC_PROG_EGREP])dnl
3056AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3057[# I'd rather use --version here, but apparently some GNU lds only accept -v.
3058case `$LD -v 2>&1 </dev/null` in
3059*GNU* | *'with BFD'*)
3060 lt_cv_prog_gnu_ld=yes
3061 ;;
3062*)
3063 lt_cv_prog_gnu_ld=no
3064 ;;
3065esac])
3066with_gnu_ld=$lt_cv_prog_gnu_ld
3067])# AC_PROG_LD_GNU
3068
3069
3070# AC_PROG_LD_RELOAD_FLAG
3071# ----------------------
3072# find reload flag for linker
3073# -- PORTME Some linkers may need a different reload flag.
3074AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
3075[AC_CACHE_CHECK([for $LD option to reload object files],
3076 lt_cv_ld_reload_flag,
3077 [lt_cv_ld_reload_flag='-r'])
3078reload_flag=$lt_cv_ld_reload_flag
3079case $reload_flag in
3080"" | " "*) ;;
3081*) reload_flag=" $reload_flag" ;;
3082esac
3083reload_cmds='$LD$reload_flag -o $output$reload_objs'
3084case $host_os in
3085 darwin*)
3086 if test "$GCC" = yes; then
3087 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3088 else
3089 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3090 fi
3091 ;;
3092esac
3093])# AC_PROG_LD_RELOAD_FLAG
3094
3095
3096# AC_DEPLIBS_CHECK_METHOD
3097# -----------------------
3098# how to check for library dependencies
3099# -- PORTME fill in with the dynamic library characteristics
3100AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
3101[AC_CACHE_CHECK([how to recognise dependent libraries],
3102lt_cv_deplibs_check_method,
3103[lt_cv_file_magic_cmd='$MAGIC_CMD'
3104lt_cv_file_magic_test_file=
3105lt_cv_deplibs_check_method='unknown'
3106# Need to set the preceding variable on all platforms that support
3107# interlibrary dependencies.
3108# 'none' -- dependencies not supported.
3109# `unknown' -- same as none, but documents that we really don't know.
3110# 'pass_all' -- all dependencies passed with no checks.
3111# 'test_compile' -- check by making test program.
3112# 'file_magic [[regex]]' -- check by looking for files in library path
3113# which responds to the $file_magic_cmd with a given extended regex.
3114# If you have `file' or equivalent on your system and you're not sure
3115# whether `pass_all' will *always* work, you probably want this one.
3116
3117case $host_os in
3118aix4* | aix5*)
3119 lt_cv_deplibs_check_method=pass_all
3120 ;;
3121
3122beos*)
3123 lt_cv_deplibs_check_method=pass_all
3124 ;;
3125
3126bsdi[[45]]*)
3127 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3128 lt_cv_file_magic_cmd='/usr/bin/file -L'
3129 lt_cv_file_magic_test_file=/shlib/libc.so
3130 ;;
3131
3132cygwin*)
3133 # func_win32_libid is a shell function defined in ltmain.sh
3134 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3135 lt_cv_file_magic_cmd='func_win32_libid'
3136 ;;
3137
3138mingw* | pw32*)
3139 # Base MSYS/MinGW do not provide the 'file' command needed by
3140 # func_win32_libid shell function, so use a weaker test based on 'objdump'.
3141 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3142 lt_cv_file_magic_cmd='$OBJDUMP -f'
3143 ;;
3144
3145darwin* | rhapsody*)
3146 lt_cv_deplibs_check_method=pass_all
3147 ;;
3148
3149freebsd* | dragonfly*)
3150 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3151 case $host_cpu in
3152 i*86 )
3153 # Not sure whether the presence of OpenBSD here was a mistake.
3154 # Let's accept both of them until this is cleared up.
3155 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3156 lt_cv_file_magic_cmd=/usr/bin/file
3157 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3158 ;;
3159 esac
3160 else
3161 lt_cv_deplibs_check_method=pass_all
3162 fi
3163 ;;
3164
3165gnu*)
3166 lt_cv_deplibs_check_method=pass_all
3167 ;;
3168
3169hpux10.20* | hpux11*)
3170 lt_cv_file_magic_cmd=/usr/bin/file
3171 case $host_cpu in
3172 ia64*)
3173 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3174 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3175 ;;
3176 hppa*64*)
3177 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
3178 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3179 ;;
3180 *)
3181 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3182 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3183 ;;
3184 esac
3185 ;;
3186
3187interix3*)
3188 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3189 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3190 ;;
3191
3192irix5* | irix6* | nonstopux*)
3193 case $LD in
3194 *-32|*"-32 ") libmagic=32-bit;;
3195 *-n32|*"-n32 ") libmagic=N32;;
3196 *-64|*"-64 ") libmagic=64-bit;;
3197 *) libmagic=never-match;;
3198 esac
3199 lt_cv_deplibs_check_method=pass_all
3200 ;;
3201
3202# This must be Linux ELF.
3203linux* | k*bsd*-gnu)
3204 lt_cv_deplibs_check_method=pass_all
3205 ;;
3206
3207netbsd* | netbsdelf*-gnu)
3208 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3209 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3210 else
3211 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3212 fi
3213 ;;
3214
3215newos6*)
3216 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3217 lt_cv_file_magic_cmd=/usr/bin/file
3218 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3219 ;;
3220
3221nto-qnx*)
3222 lt_cv_deplibs_check_method=unknown
3223 ;;
3224
3225openbsd*)
3226 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3227 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3228 else
3229 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3230 fi
3231 ;;
3232
3233osf3* | osf4* | osf5*)
3234 lt_cv_deplibs_check_method=pass_all
3235 ;;
3236
3237solaris*)
3238 lt_cv_deplibs_check_method=pass_all
3239 ;;
3240
3241sysv4 | sysv4.3*)
3242 case $host_vendor in
3243 motorola)
3244 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]]'
3245 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3246 ;;
3247 ncr)
3248 lt_cv_deplibs_check_method=pass_all
3249 ;;
3250 sequent)
3251 lt_cv_file_magic_cmd='/bin/file'
3252 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3253 ;;
3254 sni)
3255 lt_cv_file_magic_cmd='/bin/file'
3256 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3257 lt_cv_file_magic_test_file=/lib/libc.so
3258 ;;
3259 siemens)
3260 lt_cv_deplibs_check_method=pass_all
3261 ;;
3262 pc)
3263 lt_cv_deplibs_check_method=pass_all
3264 ;;
3265 esac
3266 ;;
3267
3268sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3269 lt_cv_deplibs_check_method=pass_all
3270 ;;
3271esac
3272])
3273file_magic_cmd=$lt_cv_file_magic_cmd
3274deplibs_check_method=$lt_cv_deplibs_check_method
3275test -z "$deplibs_check_method" && deplibs_check_method=unknown
3276])# AC_DEPLIBS_CHECK_METHOD
3277
3278
3279# AC_PROG_NM
3280# ----------
3281# find the pathname to a BSD-compatible name lister
3282AC_DEFUN([AC_PROG_NM],
3283[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
3284[if test -n "$NM"; then
3285 # Let the user override the test.
3286 lt_cv_path_NM="$NM"
3287else
3288 lt_nm_to_check="${ac_tool_prefix}nm"
3289 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3290 lt_nm_to_check="$lt_nm_to_check nm"
3291 fi
3292 for lt_tmp_nm in $lt_nm_to_check; do
3293 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3294 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3295 IFS="$lt_save_ifs"
3296 test -z "$ac_dir" && ac_dir=.
3297 tmp_nm="$ac_dir/$lt_tmp_nm"
3298 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3299 # Check to see if the nm accepts a BSD-compat flag.
3300 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3301 # nm: unknown option "B" ignored
3302 # Tru64's nm complains that /dev/null is an invalid object file
3303 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3304 */dev/null* | *'Invalid file or object type'*)
3305 lt_cv_path_NM="$tmp_nm -B"
3306 break
3307 ;;
3308 *)
3309 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3310 */dev/null*)
3311 lt_cv_path_NM="$tmp_nm -p"
3312 break
3313 ;;
3314 *)
3315 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3316 continue # so that we can try to find one that supports BSD flags
3317 ;;
3318 esac
3319 ;;
3320 esac
3321 fi
3322 done
3323 IFS="$lt_save_ifs"
3324 done
3325 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3326fi])
3327NM="$lt_cv_path_NM"
3328])# AC_PROG_NM
3329
3330
3331# AC_CHECK_LIBM
3332# -------------
3333# check for math library
3334AC_DEFUN([AC_CHECK_LIBM],
3335[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3336LIBM=
3337case $host in
3338*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3339 # These system don't have libm, or don't need it
3340 ;;
3341*-ncr-sysv4.3*)
3342 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3343 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3344 ;;
3345*)
3346 AC_CHECK_LIB(m, cos, LIBM="-lm")
3347 ;;
3348esac
3349])# AC_CHECK_LIBM
3350
3351
3352# AC_LIBLTDL_CONVENIENCE([DIRECTORY])
3353# -----------------------------------
3354# sets LIBLTDL to the link flags for the libltdl convenience library and
3355# LTDLINCL to the include flags for the libltdl header and adds
3356# --enable-ltdl-convenience to the configure arguments. Note that
3357# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3358# it is assumed to be `libltdl'. LIBLTDL will be prefixed with
3359# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
3360# (note the single quotes!). If your package is not flat and you're not
3361# using automake, define top_builddir and top_srcdir appropriately in
3362# the Makefiles.
3363AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3364[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3365 case $enable_ltdl_convenience in
3366 no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3367 "") enable_ltdl_convenience=yes
3368 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3369 esac
3370 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3371 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3372 # For backwards non-gettext consistent compatibility...
3373 INCLTDL="$LTDLINCL"
3374])# AC_LIBLTDL_CONVENIENCE
3375
3376
3377# AC_LIBLTDL_INSTALLABLE([DIRECTORY])
3378# -----------------------------------
3379# sets LIBLTDL to the link flags for the libltdl installable library and
3380# LTDLINCL to the include flags for the libltdl header and adds
3381# --enable-ltdl-install to the configure arguments. Note that
3382# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3383# and an installed libltdl is not found, it is assumed to be `libltdl'.
3384# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
3385# '${top_srcdir}/' (note the single quotes!). If your package is not
3386# flat and you're not using automake, define top_builddir and top_srcdir
3387# appropriately in the Makefiles.
3388# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3389AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3390[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3391 AC_CHECK_LIB(ltdl, lt_dlinit,
3392 [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3393 [if test x"$enable_ltdl_install" = xno; then
3394 AC_MSG_WARN([libltdl not installed, but installation disabled])
3395 else
3396 enable_ltdl_install=yes
3397 fi
3398 ])
3399 if test x"$enable_ltdl_install" = x"yes"; then
3400 ac_configure_args="$ac_configure_args --enable-ltdl-install"
3401 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3402 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3403 else
3404 ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
3405 LIBLTDL="-lltdl"
3406 LTDLINCL=
3407 fi
3408 # For backwards non-gettext consistent compatibility...
3409 INCLTDL="$LTDLINCL"
3410])# AC_LIBLTDL_INSTALLABLE
3411
3412
3413# AC_LIBTOOL_CXX
3414# --------------
3415# enable support for C++ libraries
3416AC_DEFUN([AC_LIBTOOL_CXX],
3417[AC_REQUIRE([_LT_AC_LANG_CXX])
3418])# AC_LIBTOOL_CXX
3419
3420
3421# _LT_AC_LANG_CXX
3422# ---------------
3423AC_DEFUN([_LT_AC_LANG_CXX],
3424[AC_REQUIRE([AC_PROG_CXX])
3425AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3426_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
3427])# _LT_AC_LANG_CXX
3428
3429# _LT_AC_PROG_CXXCPP
3430# ------------------
3431AC_DEFUN([_LT_AC_PROG_CXXCPP],
3432[
3433AC_REQUIRE([AC_PROG_CXX])
3434if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
3435 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
3436 (test "X$CXX" != "Xg++"))) ; then
3437 AC_PROG_CXXCPP
3438fi
3439])# _LT_AC_PROG_CXXCPP
3440
3441# AC_LIBTOOL_F77
3442# --------------
3443# enable support for Fortran 77 libraries
3444AC_DEFUN([AC_LIBTOOL_F77],
3445[AC_REQUIRE([_LT_AC_LANG_F77])
3446])# AC_LIBTOOL_F77
3447
3448
3449# _LT_AC_LANG_F77
3450# ---------------
3451AC_DEFUN([_LT_AC_LANG_F77],
3452[AC_REQUIRE([AC_PROG_F77])
3453_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
3454])# _LT_AC_LANG_F77
3455
3456
3457# AC_LIBTOOL_GCJ
3458# --------------
3459# enable support for GCJ libraries
3460AC_DEFUN([AC_LIBTOOL_GCJ],
3461[AC_REQUIRE([_LT_AC_LANG_GCJ])
3462])# AC_LIBTOOL_GCJ
3463
3464
3465# _LT_AC_LANG_GCJ
3466# ---------------
3467AC_DEFUN([_LT_AC_LANG_GCJ],
3468[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
3469 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
3470 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
3471 [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
3472 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
3473 [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
3474_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
3475])# _LT_AC_LANG_GCJ
3476
3477
3478# AC_LIBTOOL_RC
3479# -------------
3480# enable support for Windows resource files
3481AC_DEFUN([AC_LIBTOOL_RC],
3482[AC_REQUIRE([LT_AC_PROG_RC])
3483_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
3484])# AC_LIBTOOL_RC
3485
3486
3487# AC_LIBTOOL_LANG_C_CONFIG
3488# ------------------------
3489# Ensure that the configuration vars for the C compiler are
3490# suitably defined. Those variables are subsequently used by
3491# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3492AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
3493AC_DEFUN([_LT_AC_LANG_C_CONFIG],
3494[lt_save_CC="$CC"
3495AC_LANG_PUSH(C)
3496
3497# Source file extension for C test sources.
3498ac_ext=c
3499
3500# Object file extension for compiled C test sources.
3501objext=o
3502_LT_AC_TAGVAR(objext, $1)=$objext
3503
3504# Code to be used in simple compile tests
3505lt_simple_compile_test_code="int some_variable = 0;\n"
3506
3507# Code to be used in simple link tests
3508lt_simple_link_test_code='int main(){return(0);}\n'
3509
3510_LT_AC_SYS_COMPILER
3511
3512# save warnings/boilerplate of simple test code
3513_LT_COMPILER_BOILERPLATE
3514_LT_LINKER_BOILERPLATE
3515
3516AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
3517AC_LIBTOOL_PROG_COMPILER_PIC($1)
3518AC_LIBTOOL_PROG_CC_C_O($1)
3519AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3520AC_LIBTOOL_PROG_LD_SHLIBS($1)
3521AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3522AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3523AC_LIBTOOL_SYS_LIB_STRIP
3524AC_LIBTOOL_DLOPEN_SELF
3525
3526# Report which library types will actually be built
3527AC_MSG_CHECKING([if libtool supports shared libraries])
3528AC_MSG_RESULT([$can_build_shared])
3529
3530AC_MSG_CHECKING([whether to build shared libraries])
3531test "$can_build_shared" = "no" && enable_shared=no
3532
3533# On AIX, shared libraries and static libraries use the same namespace, and
3534# are all built from PIC.
3535case $host_os in
3536aix3*)
3537 test "$enable_shared" = yes && enable_static=no
3538 if test -n "$RANLIB"; then
3539 archive_cmds="$archive_cmds~\$RANLIB \$lib"
3540 postinstall_cmds='$RANLIB $lib'
3541 fi
3542 ;;
3543
3544aix4* | aix5*)
3545 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3546 test "$enable_shared" = yes && enable_static=no
3547 fi
3548 ;;
3549esac
3550AC_MSG_RESULT([$enable_shared])
3551
3552AC_MSG_CHECKING([whether to build static libraries])
3553# Make sure either enable_shared or enable_static is yes.
3554test "$enable_shared" = yes || enable_static=yes
3555AC_MSG_RESULT([$enable_static])
3556
3557AC_LIBTOOL_CONFIG($1)
3558
3559AC_LANG_POP
3560CC="$lt_save_CC"
3561])# AC_LIBTOOL_LANG_C_CONFIG
3562
3563
3564# AC_LIBTOOL_LANG_CXX_CONFIG
3565# --------------------------
3566# Ensure that the configuration vars for the C compiler are
3567# suitably defined. Those variables are subsequently used by
3568# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3569AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
3570AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
3571[AC_LANG_PUSH(C++)
3572AC_REQUIRE([AC_PROG_CXX])
3573AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3574
3575_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3576_LT_AC_TAGVAR(allow_undefined_flag, $1)=
3577_LT_AC_TAGVAR(always_export_symbols, $1)=no
3578_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3579_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3580_LT_AC_TAGVAR(hardcode_direct, $1)=no
3581_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3582_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3583_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3584_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3585_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3586_LT_AC_TAGVAR(hardcode_automatic, $1)=no
3587_LT_AC_TAGVAR(module_cmds, $1)=
3588_LT_AC_TAGVAR(module_expsym_cmds, $1)=
3589_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3590_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3591_LT_AC_TAGVAR(no_undefined_flag, $1)=
3592_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3593_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3594
3595# Dependencies to place before and after the object being linked:
3596_LT_AC_TAGVAR(predep_objects, $1)=
3597_LT_AC_TAGVAR(postdep_objects, $1)=
3598_LT_AC_TAGVAR(predeps, $1)=
3599_LT_AC_TAGVAR(postdeps, $1)=
3600_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3601
3602# Source file extension for C++ test sources.
3603ac_ext=cpp
3604
3605# Object file extension for compiled C++ test sources.
3606objext=o
3607_LT_AC_TAGVAR(objext, $1)=$objext
3608
3609# Code to be used in simple compile tests
3610lt_simple_compile_test_code="int some_variable = 0;\n"
3611
3612# Code to be used in simple link tests
3613lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }\n'
3614
3615# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3616_LT_AC_SYS_COMPILER
3617
3618# save warnings/boilerplate of simple test code
3619_LT_COMPILER_BOILERPLATE
3620_LT_LINKER_BOILERPLATE
3621
3622# Allow CC to be a program name with arguments.
3623lt_save_CC=$CC
3624lt_save_LD=$LD
3625lt_save_GCC=$GCC
3626GCC=$GXX
3627lt_save_with_gnu_ld=$with_gnu_ld
3628lt_save_path_LD=$lt_cv_path_LD
3629if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3630 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3631else
3632 $as_unset lt_cv_prog_gnu_ld
3633fi
3634if test -n "${lt_cv_path_LDCXX+set}"; then
3635 lt_cv_path_LD=$lt_cv_path_LDCXX
3636else
3637 $as_unset lt_cv_path_LD
3638fi
3639test -z "${LDCXX+set}" || LD=$LDCXX
3640CC=${CXX-"c++"}
3641compiler=$CC
3642_LT_AC_TAGVAR(compiler, $1)=$CC
3643_LT_CC_BASENAME([$compiler])
3644
3645# We don't want -fno-exception wen compiling C++ code, so set the
3646# no_builtin_flag separately
3647if test "$GXX" = yes; then
3648 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3649else
3650 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3651fi
3652
3653if test "$GXX" = yes; then
3654 # Set up default GNU C++ configuration
3655
3656 AC_PROG_LD
3657
3658 # Check if GNU C++ uses GNU ld as the underlying linker, since the
3659 # archiving commands below assume that GNU ld is being used.
3660 if test "$with_gnu_ld" = yes; then
3661 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3662 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3663
3664 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3665 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3666
3667 # If archive_cmds runs LD, not CC, wlarc should be empty
3668 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3669 # investigate it a little bit more. (MM)
3670 wlarc='${wl}'
3671
3672 # ancient GNU ld didn't support --whole-archive et. al.
3673 if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3674 grep 'no-whole-archive' > /dev/null; then
3675 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3676 else
3677 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3678 fi
3679 else
3680 with_gnu_ld=no
3681 wlarc=
3682
3683 # A generic and very simple default shared library creation
3684 # command for GNU C++ for the case where it uses the native
3685 # linker, instead of GNU ld. If possible, this setting should
3686 # overridden to take advantage of the native linker features on
3687 # the platform it is being used on.
3688 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3689 fi
3690
3691 # Commands to make compiler produce verbose output that lists
3692 # what "hidden" libraries, object files and flags are used when
3693 # linking a shared library.
3694 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3695
3696else
3697 GXX=no
3698 with_gnu_ld=no
3699 wlarc=
3700fi
3701
3702# PORTME: fill in a description of your system's C++ link characteristics
3703AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3704_LT_AC_TAGVAR(ld_shlibs, $1)=yes
3705case $host_os in
3706 aix3*)
3707 # FIXME: insert proper C++ library support
3708 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3709 ;;
3710 aix4* | aix5*)
3711 if test "$host_cpu" = ia64; then
3712 # On IA64, the linker does run time linking by default, so we don't
3713 # have to do anything special.
3714 aix_use_runtimelinking=no
3715 exp_sym_flag='-Bexport'
3716 no_entry_flag=""
3717 else
3718 aix_use_runtimelinking=no
3719
3720 # Test if we are trying to use run time linking or normal
3721 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
3722 # need to do runtime linking.
3723 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
3724 for ld_flag in $LDFLAGS; do
3725 case $ld_flag in
3726 *-brtl*)
3727 aix_use_runtimelinking=yes
3728 break
3729 ;;
3730 esac
3731 done
3732 ;;
3733 esac
3734
3735 exp_sym_flag='-bexport'
3736 no_entry_flag='-bnoentry'
3737 fi
3738
3739 # When large executables or shared objects are built, AIX ld can
3740 # have problems creating the table of contents. If linking a library
3741 # or program results in "error TOC overflow" add -mminimal-toc to
3742 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
3743 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3744
3745 _LT_AC_TAGVAR(archive_cmds, $1)=''
3746 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3747 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3748 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3749
3750 if test "$GXX" = yes; then
3751 case $host_os in aix4.[[012]]|aix4.[[012]].*)
3752 # We only want to do this on AIX 4.2 and lower, the check
3753 # below for broken collect2 doesn't work under 4.3+
3754 collect2name=`${CC} -print-prog-name=collect2`
3755 if test -f "$collect2name" && \
3756 strings "$collect2name" | grep resolve_lib_name >/dev/null
3757 then
3758 # We have reworked collect2
3759 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3760 else
3761 # We have old collect2
3762 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3763 # It fails to find uninstalled libraries when the uninstalled
3764 # path is not listed in the libpath. Setting hardcode_minus_L
3765 # to unsupported forces relinking
3766 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3767 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3768 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3769 fi
3770 ;;
3771 esac
3772 shared_flag='-shared'
3773 if test "$aix_use_runtimelinking" = yes; then
3774 shared_flag="$shared_flag "'${wl}-G'
3775 fi
3776 else
3777 # not using gcc
3778 if test "$host_cpu" = ia64; then
3779 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3780 # chokes on -Wl,-G. The following line is correct:
3781 shared_flag='-G'
3782 else
3783 if test "$aix_use_runtimelinking" = yes; then
3784 shared_flag='${wl}-G'
3785 else
3786 shared_flag='${wl}-bM:SRE'
3787 fi
3788 fi
3789 fi
3790
3791 # It seems that -bexpall does not export symbols beginning with
3792 # underscore (_), so it is better to generate a list of symbols to export.
3793 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3794 if test "$aix_use_runtimelinking" = yes; then
3795 # Warning - without using the other runtime loading flags (-brtl),
3796 # -berok will link without error, but may produce a broken library.
3797 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3798 # Determine the default libpath from the value encoded in an empty executable.
3799 _LT_AC_SYS_LIBPATH_AIX
3800 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3801
3802 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3803 else
3804 if test "$host_cpu" = ia64; then
3805 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3806 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3807 _LT_AC_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"
3808 else
3809 # Determine the default libpath from the value encoded in an empty executable.
3810 _LT_AC_SYS_LIBPATH_AIX
3811 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3812 # Warning - without using the other run time loading flags,
3813 # -berok will link without error, but may produce a broken library.
3814 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3815 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3816 # Exported symbols can be pulled into shared objects from archives
3817 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
3818 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3819 # This is similar to how AIX traditionally builds its shared libraries.
3820 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
3821 fi
3822 fi
3823 ;;
3824
3825 beos*)
3826 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
3827 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3828 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
3829 # support --undefined. This deserves some investigation. FIXME
3830 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
3831 else
3832 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3833 fi
3834 ;;
3835
3836 chorus*)
3837 case $cc_basename in
3838 *)
3839 # FIXME: insert proper C++ library support
3840 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3841 ;;
3842 esac
3843 ;;
3844
3845 cygwin* | mingw* | pw32*)
3846 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3847 # as there is no search path for DLLs.
3848 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3849 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3850 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3851 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3852
3853 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3854 _LT_AC_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'
3855 # If the export-symbols file already is a .def file (1st line
3856 # is EXPORTS), use it as is; otherwise, prepend...
3857 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3858 cp $export_symbols $output_objdir/$soname.def;
3859 else
3860 echo EXPORTS > $output_objdir/$soname.def;
3861 cat $export_symbols >> $output_objdir/$soname.def;
3862 fi~
3863 $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'
3864 else
3865 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3866 fi
3867 ;;
3868 darwin* | rhapsody*)
3869 case $host_os in
3870 rhapsody* | darwin1.[[012]])
3871 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
3872 ;;
3873 *) # Darwin 1.3 on
3874 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
3875 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
3876 else
3877 case ${MACOSX_DEPLOYMENT_TARGET} in
3878 10.[[012]])
3879 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
3880 ;;
3881 10.*)
3882 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
3883 ;;
3884 esac
3885 fi
3886 ;;
3887 esac
3888 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3889 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3890 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3891 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3892 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
3893 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3894
3895 if test "$GXX" = yes ; then
3896 lt_int_apple_cc_single_mod=no
3897 output_verbose_link_cmd='echo'
3898 if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
3899 lt_int_apple_cc_single_mod=yes
3900 fi
3901 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3902 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
3903 else
3904 _LT_AC_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'
3905 fi
3906 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3907 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
3908 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3909 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3910 else
3911 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3912 fi
3913 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3914 else
3915 case $cc_basename in
3916 xlc*)
3917 output_verbose_link_cmd='echo'
3918 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
3919 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3920 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
3921 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3922 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3923 ;;
3924 *)
3925 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3926 ;;
3927 esac
3928 fi
3929 ;;
3930
3931 dgux*)
3932 case $cc_basename in
3933 ec++*)
3934 # FIXME: insert proper C++ library support
3935 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3936 ;;
3937 ghcx*)
3938 # Green Hills C++ Compiler
3939 # FIXME: insert proper C++ library support
3940 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3941 ;;
3942 *)
3943 # FIXME: insert proper C++ library support
3944 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3945 ;;
3946 esac
3947 ;;
3948 freebsd[[12]]*)
3949 # C++ shared libraries reported to be fairly broken before switch to ELF
3950 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3951 ;;
3952 freebsd-elf*)
3953 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3954 ;;
3955 freebsd* | dragonfly*)
3956 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3957 # conventions
3958 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3959 ;;
3960 gnu*)
3961 ;;
3962 hpux9*)
3963 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3964 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3965 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3966 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3967 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3968 # but as the default
3969 # location of the library.
3970
3971 case $cc_basename in
3972 CC*)
3973 # FIXME: insert proper C++ library support
3974 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3975 ;;
3976 aCC*)
3977 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3978 # Commands to make compiler produce verbose output that lists
3979 # what "hidden" libraries, object files and flags are used when
3980 # linking a shared library.
3981 #
3982 # There doesn't appear to be a way to prevent this compiler from
3983 # explicitly linking system object files so we need to strip them
3984 # from the output so that they don't get included in the library
3985 # dependencies.
3986 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3987 ;;
3988 *)
3989 if test "$GXX" = yes; then
3990 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3991 else
3992 # FIXME: insert proper C++ library support
3993 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3994 fi
3995 ;;
3996 esac
3997 ;;
3998 hpux10*|hpux11*)
3999 if test $with_gnu_ld = no; then
4000 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4001 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4002
4003 case $host_cpu in
4004 hppa*64*|ia64*)
4005 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
4006 ;;
4007 *)
4008 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4009 ;;
4010 esac
4011 fi
4012 case $host_cpu in
4013 hppa*64*|ia64*)
4014 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4015 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4016 ;;
4017 *)
4018 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4019 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4020 # but as the default
4021 # location of the library.
4022 ;;
4023 esac
4024
4025 case $cc_basename in
4026 CC*)
4027 # FIXME: insert proper C++ library support
4028 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4029 ;;
4030 aCC*)
4031 case $host_cpu in
4032 hppa*64*)
4033 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4034 ;;
4035 ia64*)
4036 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4037 ;;
4038 *)
4039 _LT_AC_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'
4040 ;;
4041 esac
4042 # Commands to make compiler produce verbose output that lists
4043 # what "hidden" libraries, object files and flags are used when
4044 # linking a shared library.
4045 #
4046 # There doesn't appear to be a way to prevent this compiler from
4047 # explicitly linking system object files so we need to strip them
4048 # from the output so that they don't get included in the library
4049 # dependencies.
4050 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4051 ;;
4052 *)
4053 if test "$GXX" = yes; then
4054 if test $with_gnu_ld = no; then
4055 case $host_cpu in
4056 hppa*64*)
4057 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4058 ;;
4059 ia64*)
4060 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4061 ;;
4062 *)
4063 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4064 ;;
4065 esac
4066 fi
4067 else
4068 # FIXME: insert proper C++ library support
4069 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4070 fi
4071 ;;
4072 esac
4073 ;;
4074 interix3*)
4075 _LT_AC_TAGVAR(hardcode_direct, $1)=no
4076 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4077 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4078 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4079 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4080 # Instead, shared libraries are loaded at an image base (0x10000000 by
4081 # default) and relocated if they conflict, which is a slow very memory
4082 # consuming and fragmenting process. To avoid this, we pick a random,
4083 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4084 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
4085 _LT_AC_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'
4086 _LT_AC_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'
4087 ;;
4088 irix5* | irix6*)
4089 case $cc_basename in
4090 CC*)
4091 # SGI C++
4092 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4093
4094 # Archives containing C++ object files must be created using
4095 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
4096 # necessary to make sure instantiated templates are included
4097 # in the archive.
4098 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
4099 ;;
4100 *)
4101 if test "$GXX" = yes; then
4102 if test "$with_gnu_ld" = no; then
4103 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4104 else
4105 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
4106 fi
4107 fi
4108 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4109 ;;
4110 esac
4111 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4112 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4113 ;;
4114 linux* | k*bsd*-gnu)
4115 case $cc_basename in
4116 KCC*)
4117 # Kuck and Associates, Inc. (KAI) C++ Compiler
4118
4119 # KCC will only create a shared library if the output file
4120 # ends with ".so" (or ".sl" for HP-UX), so rename the library
4121 # to its proper name (with version) after linking.
4122 _LT_AC_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'
4123 _LT_AC_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'
4124 # Commands to make compiler produce verbose output that lists
4125 # what "hidden" libraries, object files and flags are used when
4126 # linking a shared library.
4127 #
4128 # There doesn't appear to be a way to prevent this compiler from
4129 # explicitly linking system object files so we need to strip them
4130 # from the output so that they don't get included in the library
4131 # dependencies.
4132 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4133
4134 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
4135 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4136
4137 # Archives containing C++ object files must be created using
4138 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
4139 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4140 ;;
4141 icpc*)
4142 # Intel C++
4143 with_gnu_ld=yes
4144 # version 8.0 and above of icpc choke on multiply defined symbols
4145 # if we add $predep_objects and $postdep_objects, however 7.1 and
4146 # earlier do not add the objects themselves.
4147 case `$CC -V 2>&1` in
4148 *"Version 7."*)
4149 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4150 _LT_AC_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'
4151 ;;
4152 *) # Version 8.0 or newer
4153 tmp_idyn=
4154 case $host_cpu in
4155 ia64*) tmp_idyn=' -i_dynamic';;
4156 esac
4157 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4158 _LT_AC_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'
4159 ;;
4160 esac
4161 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4162 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4163 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4164 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
4165 ;;
4166 pgCC*)
4167 # Portland Group C++ compiler
4168 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
4169 _LT_AC_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'
4170
4171 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
4172 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4173 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
4174 ;;
4175 cxx*)
4176 # Compaq C++
4177 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4178 _LT_AC_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'
4179
4180 runpath_var=LD_RUN_PATH
4181 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4182 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4183
4184 # Commands to make compiler produce verbose output that lists
4185 # what "hidden" libraries, object files and flags are used when
4186 # linking a shared library.
4187 #
4188 # There doesn't appear to be a way to prevent this compiler from
4189 # explicitly linking system object files so we need to strip them
4190 # from the output so that they don't get included in the library
4191 # dependencies.
4192 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $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; echo $list'
4193 ;;
4194 esac
4195 ;;
4196 lynxos*)
4197 # FIXME: insert proper C++ library support
4198 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4199 ;;
4200 m88k*)
4201 # FIXME: insert proper C++ library support
4202 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4203 ;;
4204 mvs*)
4205 case $cc_basename in
4206 cxx*)
4207 # FIXME: insert proper C++ library support
4208 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4209 ;;
4210 *)
4211 # FIXME: insert proper C++ library support
4212 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4213 ;;
4214 esac
4215 ;;
4216 netbsd* | netbsdelf*-gnu)
4217 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4218 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
4219 wlarc=
4220 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4221 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4222 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4223 fi
4224 # Workaround some broken pre-1.5 toolchains
4225 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
4226 ;;
4227 openbsd2*)
4228 # C++ shared libraries are fairly broken
4229 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4230 ;;
4231 openbsd*)
4232 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
4233 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4234 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
4235 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4236 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4237 _LT_AC_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'
4238 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4239 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4240 fi
4241 output_verbose_link_cmd='echo'
4242 ;;
4243 osf3*)
4244 case $cc_basename in
4245 KCC*)
4246 # Kuck and Associates, Inc. (KAI) C++ Compiler
4247
4248 # KCC will only create a shared library if the output file
4249 # ends with ".so" (or ".sl" for HP-UX), so rename the library
4250 # to its proper name (with version) after linking.
4251 _LT_AC_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'
4252
4253 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4254 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4255
4256 # Archives containing C++ object files must be created using
4257 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
4258 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4259
4260 ;;
4261 RCC*)
4262 # Rational C++ 2.4.1
4263 # FIXME: insert proper C++ library support
4264 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4265 ;;
4266 cxx*)
4267 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4268 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4269
4270 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4271 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4272
4273 # Commands to make compiler produce verbose output that lists
4274 # what "hidden" libraries, object files and flags are used when
4275 # linking a shared library.
4276 #
4277 # There doesn't appear to be a way to prevent this compiler from
4278 # explicitly linking system object files so we need to strip them
4279 # from the output so that they don't get included in the library
4280 # dependencies.
4281 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $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; echo $list'
4282 ;;
4283 *)
4284 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4285 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4286 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4287
4288 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4289 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4290
4291 # Commands to make compiler produce verbose output that lists
4292 # what "hidden" libraries, object files and flags are used when
4293 # linking a shared library.
4294 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4295
4296 else
4297 # FIXME: insert proper C++ library support
4298 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4299 fi
4300 ;;
4301 esac
4302 ;;
4303 osf4* | osf5*)
4304 case $cc_basename in
4305 KCC*)
4306 # Kuck and Associates, Inc. (KAI) C++ Compiler
4307
4308 # KCC will only create a shared library if the output file
4309 # ends with ".so" (or ".sl" for HP-UX), so rename the library
4310 # to its proper name (with version) after linking.
4311 _LT_AC_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'
4312
4313 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4314 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4315
4316 # Archives containing C++ object files must be created using
4317 # the KAI C++ compiler.
4318 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
4319 ;;
4320 RCC*)
4321 # Rational C++ 2.4.1
4322 # FIXME: insert proper C++ library support
4323 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4324 ;;
4325 cxx*)
4326 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
4327 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4328 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
4329 echo "-hidden">> $lib.exp~
4330 $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~
4331 $rm $lib.exp'
4332
4333 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4334 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4335
4336 # Commands to make compiler produce verbose output that lists
4337 # what "hidden" libraries, object files and flags are used when
4338 # linking a shared library.
4339 #
4340 # There doesn't appear to be a way to prevent this compiler from
4341 # explicitly linking system object files so we need to strip them
4342 # from the output so that they don't get included in the library
4343 # dependencies.
4344 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $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; echo $list'
4345 ;;
4346 *)
4347 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4348 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4349 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4350
4351 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4352 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4353
4354 # Commands to make compiler produce verbose output that lists
4355 # what "hidden" libraries, object files and flags are used when
4356 # linking a shared library.
4357 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4358
4359 else
4360 # FIXME: insert proper C++ library support
4361 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4362 fi
4363 ;;
4364 esac
4365 ;;
4366 psos*)
4367 # FIXME: insert proper C++ library support
4368 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4369 ;;
4370 sunos4*)
4371 case $cc_basename in
4372 CC*)
4373 # Sun C++ 4.x
4374 # FIXME: insert proper C++ library support
4375 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4376 ;;
4377 lcc*)
4378 # Lucid
4379 # FIXME: insert proper C++ library support
4380 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4381 ;;
4382 *)
4383 # FIXME: insert proper C++ library support
4384 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4385 ;;
4386 esac
4387 ;;
4388 solaris*)
4389 case $cc_basename in
4390 CC*)
4391 # Sun C++ 4.2, 5.x and Centerline C++
4392 _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
4393 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4394 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4395 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4396 $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'
4397
4398 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4399 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4400 case $host_os in
4401 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
4402 *)
4403 # The C++ compiler is used as linker so we must use $wl
4404 # flag to pass the commands to the underlying system
4405 # linker. We must also pass each convience library through
4406 # to the system linker between allextract/defaultextract.
4407 # The C++ compiler will combine linker options so we
4408 # cannot just pass the convience library names through
4409 # without $wl.
4410 # Supported since Solaris 2.6 (maybe 2.5.1?)
4411 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
4412 ;;
4413 esac
4414 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4415
4416 output_verbose_link_cmd='echo'
4417
4418 # Archives containing C++ object files must be created using
4419 # "CC -xar", where "CC" is the Sun C++ compiler. This is
4420 # necessary to make sure instantiated templates are included
4421 # in the archive.
4422 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4423 ;;
4424 gcx*)
4425 # Green Hills C++ Compiler
4426 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4427
4428 # The C++ compiler must be used to create the archive.
4429 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
4430 ;;
4431 *)
4432 # GNU C++ compiler with Solaris linker
4433 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4434 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
4435 if $CC --version | grep -v '^2\.7' > /dev/null; then
4436 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4437 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4438 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4439
4440 # Commands to make compiler produce verbose output that lists
4441 # what "hidden" libraries, object files and flags are used when
4442 # linking a shared library.
4443 output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4444 else
4445 # g++ 2.7 appears to require `-G' NOT `-shared' on this
4446 # platform.
4447 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4448 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4449 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4450
4451 # Commands to make compiler produce verbose output that lists
4452 # what "hidden" libraries, object files and flags are used when
4453 # linking a shared library.
4454 output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4455 fi
4456
4457 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
4458 fi
4459 ;;
4460 esac
4461 ;;
4462 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
4463 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4464 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4465 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4466 runpath_var='LD_RUN_PATH'
4467
4468 case $cc_basename in
4469 CC*)
4470 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4471 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4472 ;;
4473 *)
4474 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4475 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4476 ;;
4477 esac
4478 ;;
4479 sysv5* | sco3.2v5* | sco5v6*)
4480 # Note: We can NOT use -z defs as we might desire, because we do not
4481 # link with -lc, and that would cause any symbols used from libc to
4482 # always be unresolved, which means just about no library would
4483 # ever link correctly. If we're not using GNU ld we use -z text
4484 # though, which does catch some bad symbols but isn't as heavy-handed
4485 # as -z defs.
4486 # For security reasons, it is highly recommended that you always
4487 # use absolute paths for naming shared libraries, and exclude the
4488 # DT_RUNPATH tag from executables and libraries. But doing so
4489 # requires that you compile everything twice, which is a pain.
4490 # So that behaviour is only enabled if SCOABSPATH is set to a
4491 # non-empty value in the environment. Most likely only useful for
4492 # creating official distributions of packages.
4493 # This is a hack until libtool officially supports absolute path
4494 # names for shared libraries.
4495 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4496 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
4497 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4498 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4499 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
4500 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
4501 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4502 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
4503 runpath_var='LD_RUN_PATH'
4504
4505 case $cc_basename in
4506 CC*)
4507 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4508 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4509 ;;
4510 *)
4511 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4512 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4513 ;;
4514 esac
4515 ;;
4516 tandem*)
4517 case $cc_basename in
4518 NCC*)
4519 # NonStop-UX NCC 3.20
4520 # FIXME: insert proper C++ library support
4521 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4522 ;;
4523 *)
4524 # FIXME: insert proper C++ library support
4525 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4526 ;;
4527 esac
4528 ;;
4529 vxworks*)
4530 # FIXME: insert proper C++ library support
4531 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4532 ;;
4533 *)
4534 # FIXME: insert proper C++ library support
4535 _LT_AC_TAGVAR(ld_shlibs, $1)=no
4536 ;;
4537esac
4538AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
4539test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4540
4541_LT_AC_TAGVAR(GCC, $1)="$GXX"
4542_LT_AC_TAGVAR(LD, $1)="$LD"
4543
4544AC_LIBTOOL_POSTDEP_PREDEP($1)
4545AC_LIBTOOL_PROG_COMPILER_PIC($1)
4546AC_LIBTOOL_PROG_CC_C_O($1)
4547AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4548AC_LIBTOOL_PROG_LD_SHLIBS($1)
4549AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4550AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4551
4552AC_LIBTOOL_CONFIG($1)
4553
4554AC_LANG_POP
4555CC=$lt_save_CC
4556LDCXX=$LD
4557LD=$lt_save_LD
4558GCC=$lt_save_GCC
4559with_gnu_ldcxx=$with_gnu_ld
4560with_gnu_ld=$lt_save_with_gnu_ld
4561lt_cv_path_LDCXX=$lt_cv_path_LD
4562lt_cv_path_LD=$lt_save_path_LD
4563lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
4564lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
4565])# AC_LIBTOOL_LANG_CXX_CONFIG
4566
4567# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
4568# ------------------------------------
4569# Figure out "hidden" library dependencies from verbose
4570# compiler output when linking a shared library.
4571# Parse the compiler output and extract the necessary
4572# objects, libraries and library flags.
4573AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
4574dnl we can't use the lt_simple_compile_test_code here,
4575dnl because it contains code intended for an executable,
4576dnl not a library. It's possible we should let each
4577dnl tag define a new lt_????_link_test_code variable,
4578dnl but it's only used here...
4579ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
4580int a;
4581void foo (void) { a = 0; }
4582EOF
4583],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
4584class Foo
4585{
4586public:
4587 Foo (void) { a = 0; }
4588private:
4589 int a;
4590};
4591EOF
4592],[$1],[F77],[cat > conftest.$ac_ext <<EOF
4593 subroutine foo
4594 implicit none
4595 integer*4 a
4596 a=0
4597 return
4598 end
4599EOF
4600],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
4601public class foo {
4602 private int a;
4603 public void bar (void) {
4604 a = 0;
4605 }
4606};
4607EOF
4608])
4609dnl Parse the compiler output and extract the necessary
4610dnl objects, libraries and library flags.
4611if AC_TRY_EVAL(ac_compile); then
4612 # Parse the compiler output and extract the necessary
4613 # objects, libraries and library flags.
4614
4615 # Sentinel used to keep track of whether or not we are before
4616 # the conftest object file.
4617 pre_test_object_deps_done=no
4618
4619 # The `*' in the case matches for architectures that use `case' in
4620 # $output_verbose_cmd can trigger glob expansion during the loop
4621 # eval without this substitution.
4622 output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
4623
4624 for p in `eval $output_verbose_link_cmd`; do
4625 case $p in
4626
4627 -L* | -R* | -l*)
4628 # Some compilers place space between "-{L,R}" and the path.
4629 # Remove the space.
4630 if test $p = "-L" \
4631 || test $p = "-R"; then
4632 prev=$p
4633 continue
4634 else
4635 prev=
4636 fi
4637
4638 if test "$pre_test_object_deps_done" = no; then
4639 case $p in
4640 -L* | -R*)
4641 # Internal compiler library paths should come after those
4642 # provided the user. The postdeps already come after the
4643 # user supplied libs so there is no need to process them.
4644 if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4645 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
4646 else
4647 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
4648 fi
4649 ;;
4650 # The "-l" case would never come before the object being
4651 # linked, so don't bother handling this case.
4652 esac
4653 else
4654 if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
4655 _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
4656 else
4657 _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
4658 fi
4659 fi
4660 ;;
4661
4662 *.$objext)
4663 # This assumes that the test object file only shows up
4664 # once in the compiler output.
4665 if test "$p" = "conftest.$objext"; then
4666 pre_test_object_deps_done=yes
4667 continue
4668 fi
4669
4670 if test "$pre_test_object_deps_done" = no; then
4671 if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
4672 _LT_AC_TAGVAR(predep_objects, $1)="$p"
4673 else
4674 _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
4675 fi
4676 else
4677 if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
4678 _LT_AC_TAGVAR(postdep_objects, $1)="$p"
4679 else
4680 _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
4681 fi
4682 fi
4683 ;;
4684
4685 *) ;; # Ignore the rest.
4686
4687 esac
4688 done
4689
4690 # Clean up.
4691 rm -f a.out a.exe
4692else
4693 echo "libtool.m4: error: problem compiling $1 test program"
4694fi
4695
4696$rm -f confest.$objext
4697
4698# PORTME: override above test on systems where it is broken
4699ifelse([$1],[CXX],
4700[case $host_os in
4701interix3*)
4702 # Interix 3.5 installs completely hosed .la files for C++, so rather than
4703 # hack all around it, let's just trust "g++" to DTRT.
4704 _LT_AC_TAGVAR(predep_objects,$1)=
4705 _LT_AC_TAGVAR(postdep_objects,$1)=
4706 _LT_AC_TAGVAR(postdeps,$1)=
4707 ;;
4708
4709solaris*)
4710 case $cc_basename in
4711 CC*)
4712 # Adding this requires a known-good setup of shared libraries for
4713 # Sun compiler versions before 5.6, else PIC objects from an old
4714 # archive will be linked into the output, leading to subtle bugs.
4715 _LT_AC_TAGVAR(postdeps,$1)='-lCstd -lCrun'
4716 ;;
4717 esac
4718 ;;
4719esac
4720])
4721
4722case " $_LT_AC_TAGVAR(postdeps, $1) " in
4723*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4724esac
4725])# AC_LIBTOOL_POSTDEP_PREDEP
4726
4727# AC_LIBTOOL_LANG_F77_CONFIG
4728# --------------------------
4729# Ensure that the configuration vars for the C compiler are
4730# suitably defined. Those variables are subsequently used by
4731# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4732AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4733AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4734[AC_REQUIRE([AC_PROG_F77])
4735AC_LANG_PUSH(Fortran 77)
4736
4737_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4738_LT_AC_TAGVAR(allow_undefined_flag, $1)=
4739_LT_AC_TAGVAR(always_export_symbols, $1)=no
4740_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
4741_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
4742_LT_AC_TAGVAR(hardcode_direct, $1)=no
4743_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
4744_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4745_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
4746_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
4747_LT_AC_TAGVAR(hardcode_automatic, $1)=no
4748_LT_AC_TAGVAR(module_cmds, $1)=
4749_LT_AC_TAGVAR(module_expsym_cmds, $1)=
4750_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
4751_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4752_LT_AC_TAGVAR(no_undefined_flag, $1)=
4753_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
4754_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4755
4756# Source file extension for f77 test sources.
4757ac_ext=f
4758
4759# Object file extension for compiled f77 test sources.
4760objext=o
4761_LT_AC_TAGVAR(objext, $1)=$objext
4762
4763# Code to be used in simple compile tests
4764lt_simple_compile_test_code=" subroutine t\n return\n end\n"
4765
4766# Code to be used in simple link tests
4767lt_simple_link_test_code=" program t\n end\n"
4768
4769# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4770_LT_AC_SYS_COMPILER
4771
4772# save warnings/boilerplate of simple test code
4773_LT_COMPILER_BOILERPLATE
4774_LT_LINKER_BOILERPLATE
4775
4776# Allow CC to be a program name with arguments.
4777lt_save_CC="$CC"
4778CC=${F77-"f77"}
4779compiler=$CC
4780_LT_AC_TAGVAR(compiler, $1)=$CC
4781_LT_CC_BASENAME([$compiler])
4782
4783AC_MSG_CHECKING([if libtool supports shared libraries])
4784AC_MSG_RESULT([$can_build_shared])
4785
4786AC_MSG_CHECKING([whether to build shared libraries])
4787test "$can_build_shared" = "no" && enable_shared=no
4788
4789# On AIX, shared libraries and static libraries use the same namespace, and
4790# are all built from PIC.
4791case $host_os in
4792aix3*)
4793 test "$enable_shared" = yes && enable_static=no
4794 if test -n "$RANLIB"; then
4795 archive_cmds="$archive_cmds~\$RANLIB \$lib"
4796 postinstall_cmds='$RANLIB $lib'
4797 fi
4798 ;;
4799aix4* | aix5*)
4800 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
4801 test "$enable_shared" = yes && enable_static=no
4802 fi
4803 ;;
4804esac
4805AC_MSG_RESULT([$enable_shared])
4806
4807AC_MSG_CHECKING([whether to build static libraries])
4808# Make sure either enable_shared or enable_static is yes.
4809test "$enable_shared" = yes || enable_static=yes
4810AC_MSG_RESULT([$enable_static])
4811
4812_LT_AC_TAGVAR(GCC, $1)="$G77"
4813_LT_AC_TAGVAR(LD, $1)="$LD"
4814
4815AC_LIBTOOL_PROG_COMPILER_PIC($1)
4816AC_LIBTOOL_PROG_CC_C_O($1)
4817AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4818AC_LIBTOOL_PROG_LD_SHLIBS($1)
4819AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4820AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4821
4822AC_LIBTOOL_CONFIG($1)
4823
4824AC_LANG_POP
4825CC="$lt_save_CC"
4826])# AC_LIBTOOL_LANG_F77_CONFIG
4827
4828
4829# AC_LIBTOOL_LANG_GCJ_CONFIG
4830# --------------------------
4831# Ensure that the configuration vars for the C compiler are
4832# suitably defined. Those variables are subsequently used by
4833# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4834AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4835AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4836[AC_LANG_SAVE
4837
4838# Source file extension for Java test sources.
4839ac_ext=java
4840
4841# Object file extension for compiled Java test sources.
4842objext=o
4843_LT_AC_TAGVAR(objext, $1)=$objext
4844
4845# Code to be used in simple compile tests
4846lt_simple_compile_test_code="class foo {}\n"
4847
4848# Code to be used in simple link tests
4849lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
4850
4851# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4852_LT_AC_SYS_COMPILER
4853
4854# save warnings/boilerplate of simple test code
4855_LT_COMPILER_BOILERPLATE
4856_LT_LINKER_BOILERPLATE
4857
4858# Allow CC to be a program name with arguments.
4859lt_save_CC="$CC"
4860CC=${GCJ-"gcj"}
4861compiler=$CC
4862_LT_AC_TAGVAR(compiler, $1)=$CC
4863_LT_CC_BASENAME([$compiler])
4864
4865# GCJ did not exist at the time GCC didn't implicitly link libc in.
4866_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4867
4868_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4869
4870AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4871AC_LIBTOOL_PROG_COMPILER_PIC($1)
4872AC_LIBTOOL_PROG_CC_C_O($1)
4873AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4874AC_LIBTOOL_PROG_LD_SHLIBS($1)
4875AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4876AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4877
4878AC_LIBTOOL_CONFIG($1)
4879
4880AC_LANG_RESTORE
4881CC="$lt_save_CC"
4882])# AC_LIBTOOL_LANG_GCJ_CONFIG
4883
4884
4885# AC_LIBTOOL_LANG_RC_CONFIG
4886# -------------------------
4887# Ensure that the configuration vars for the Windows resource compiler are
4888# suitably defined. Those variables are subsequently used by
4889# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4890AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4891AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4892[AC_LANG_SAVE
4893
4894# Source file extension for RC test sources.
4895ac_ext=rc
4896
4897# Object file extension for compiled RC test sources.
4898objext=o
4899_LT_AC_TAGVAR(objext, $1)=$objext
4900
4901# Code to be used in simple compile tests
4902lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
4903
4904# Code to be used in simple link tests
4905lt_simple_link_test_code="$lt_simple_compile_test_code"
4906
4907# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4908_LT_AC_SYS_COMPILER
4909
4910# save warnings/boilerplate of simple test code
4911_LT_COMPILER_BOILERPLATE
4912_LT_LINKER_BOILERPLATE
4913
4914# Allow CC to be a program name with arguments.
4915lt_save_CC="$CC"
4916CC=${RC-"windres"}
4917compiler=$CC
4918_LT_AC_TAGVAR(compiler, $1)=$CC
4919_LT_CC_BASENAME([$compiler])
4920_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4921
4922AC_LIBTOOL_CONFIG($1)
4923
4924AC_LANG_RESTORE
4925CC="$lt_save_CC"
4926])# AC_LIBTOOL_LANG_RC_CONFIG
4927
4928
4929# AC_LIBTOOL_CONFIG([TAGNAME])
4930# ----------------------------
4931# If TAGNAME is not passed, then create an initial libtool script
4932# with a default configuration from the untagged config vars. Otherwise
4933# add code to config.status for appending the configuration named by
4934# TAGNAME from the matching tagged config vars.
4935AC_DEFUN([AC_LIBTOOL_CONFIG],
4936[# The else clause should only fire when bootstrapping the
4937# libtool distribution, otherwise you forgot to ship ltmain.sh
4938# with your package, and you will get complaints that there are
4939# no rules to generate ltmain.sh.
4940if test -f "$ltmain"; then
4941 # See if we are running on zsh, and set the options which allow our commands through
4942 # without removal of \ escapes.
4943 if test -n "${ZSH_VERSION+set}" ; then
4944 setopt NO_GLOB_SUBST
4945 fi
4946 # Now quote all the things that may contain metacharacters while being
4947 # careful not to overquote the AC_SUBSTed values. We take copies of the
4948 # variables and quote the copies for generation of the libtool script.
4949 for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
4950 SED SHELL STRIP \
4951 libname_spec library_names_spec soname_spec extract_expsyms_cmds \
4952 old_striplib striplib file_magic_cmd finish_cmds finish_eval \
4953 deplibs_check_method reload_flag reload_cmds need_locks \
4954 lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
4955 lt_cv_sys_global_symbol_to_c_name_address \
4956 sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
4957 old_postinstall_cmds old_postuninstall_cmds \
4958 _LT_AC_TAGVAR(compiler, $1) \
4959 _LT_AC_TAGVAR(CC, $1) \
4960 _LT_AC_TAGVAR(LD, $1) \
4961 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
4962 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
4963 _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
4964 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
4965 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
4966 _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
4967 _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
4968 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
4969 _LT_AC_TAGVAR(old_archive_cmds, $1) \
4970 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
4971 _LT_AC_TAGVAR(predep_objects, $1) \
4972 _LT_AC_TAGVAR(postdep_objects, $1) \
4973 _LT_AC_TAGVAR(predeps, $1) \
4974 _LT_AC_TAGVAR(postdeps, $1) \
4975 _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
4976 _LT_AC_TAGVAR(archive_cmds, $1) \
4977 _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
4978 _LT_AC_TAGVAR(postinstall_cmds, $1) \
4979 _LT_AC_TAGVAR(postuninstall_cmds, $1) \
4980 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
4981 _LT_AC_TAGVAR(allow_undefined_flag, $1) \
4982 _LT_AC_TAGVAR(no_undefined_flag, $1) \
4983 _LT_AC_TAGVAR(export_symbols_cmds, $1) \
4984 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
4985 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
4986 _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
4987 _LT_AC_TAGVAR(hardcode_automatic, $1) \
4988 _LT_AC_TAGVAR(module_cmds, $1) \
4989 _LT_AC_TAGVAR(module_expsym_cmds, $1) \
4990 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
4991 _LT_AC_TAGVAR(exclude_expsyms, $1) \
4992 _LT_AC_TAGVAR(include_expsyms, $1); do
4993
4994 case $var in
4995 _LT_AC_TAGVAR(old_archive_cmds, $1) | \
4996 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
4997 _LT_AC_TAGVAR(archive_cmds, $1) | \
4998 _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
4999 _LT_AC_TAGVAR(module_cmds, $1) | \
5000 _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
5001 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
5002 _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
5003 extract_expsyms_cmds | reload_cmds | finish_cmds | \
5004 postinstall_cmds | postuninstall_cmds | \
5005 old_postinstall_cmds | old_postuninstall_cmds | \
5006 sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
5007 # Double-quote double-evaled strings.
5008 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
5009 ;;
5010 *)
5011 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
5012 ;;
5013 esac
5014 done
5015
5016 case $lt_echo in
5017 *'\[$]0 --fallback-echo"')
5018 lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
5019 ;;
5020 esac
5021
5022ifelse([$1], [],
5023 [cfgfile="${ofile}T"
5024 trap "$rm \"$cfgfile\"; exit 1" 1 2 15
5025 $rm -f "$cfgfile"
5026 AC_MSG_NOTICE([creating $ofile])],
5027 [cfgfile="$ofile"])
5028
5029 cat <<__EOF__ >> "$cfgfile"
5030ifelse([$1], [],
5031[#! $SHELL
5032
5033# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
5034# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
5035# NOTE: Changes made to this file will be lost: look at ltmain.sh.
5036#
5037# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
5038# Free Software Foundation, Inc.
5039#
5040# This file is part of GNU Libtool:
5041# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
5042#
5043# This program is free software; you can redistribute it and/or modify
5044# it under the terms of the GNU General Public License as published by
5045# the Free Software Foundation; either version 2 of the License, or
5046# (at your option) any later version.
5047#
5048# This program is distributed in the hope that it will be useful, but
5049# WITHOUT ANY WARRANTY; without even the implied warranty of
5050# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5051# General Public License for more details.
5052#
5053# You should have received a copy of the GNU General Public License
5054# along with this program; if not, write to the Free Software
5055# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
5056#
5057# As a special exception to the GNU General Public License, if you
5058# distribute this file as part of a program that contains a
5059# configuration script generated by Autoconf, you may include it under
5060# the same distribution terms that you use for the rest of that program.
5061
5062# A sed program that does not truncate output.
5063SED=$lt_SED
5064
5065# Sed that helps us avoid accidentally triggering echo(1) options like -n.
5066Xsed="$SED -e 1s/^X//"
5067
5068# The HP-UX ksh and POSIX shell print the target directory to stdout
5069# if CDPATH is set.
5070(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
5071
5072# The names of the tagged configurations supported by this script.
5073available_tags=
5074
5075# ### BEGIN LIBTOOL CONFIG],
5076[# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
5077
5078# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5079
5080# Shell to use when invoking shell scripts.
5081SHELL=$lt_SHELL
5082
5083# Whether or not to build shared libraries.
5084build_libtool_libs=$enable_shared
5085
5086# Whether or not to build static libraries.
5087build_old_libs=$enable_static
5088
5089# Whether or not to add -lc for building shared libraries.
5090build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
5091
5092# Whether or not to disallow shared libs when runtime libs are static
5093allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
5094
5095# Whether or not to optimize for fast installation.
5096fast_install=$enable_fast_install
5097
5098# The host system.
5099host_alias=$host_alias
5100host=$host
5101host_os=$host_os
5102
5103# The build system.
5104build_alias=$build_alias
5105build=$build
5106build_os=$build_os
5107
5108# An echo program that does not interpret backslashes.
5109echo=$lt_echo
5110
5111# The archiver.
5112AR=$lt_AR
5113AR_FLAGS=$lt_AR_FLAGS
5114
5115# A C compiler.
5116LTCC=$lt_LTCC
5117
5118# LTCC compiler flags.
5119LTCFLAGS=$lt_LTCFLAGS
5120
5121# A language-specific compiler.
5122CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
5123
5124# Is the compiler the GNU C compiler?
5125with_gcc=$_LT_AC_TAGVAR(GCC, $1)
5126
5127# An ERE matcher.
5128EGREP=$lt_EGREP
5129
5130# The linker used to build libraries.
5131LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
5132
5133# Whether we need hard or soft links.
5134LN_S=$lt_LN_S
5135
5136# A BSD-compatible nm program.
5137NM=$lt_NM
5138
5139# A symbol stripping program
5140STRIP=$lt_STRIP
5141
5142# Used to examine libraries when file_magic_cmd begins "file"
5143MAGIC_CMD=$MAGIC_CMD
5144
5145# Used on cygwin: DLL creation program.
5146DLLTOOL="$DLLTOOL"
5147
5148# Used on cygwin: object dumper.
5149OBJDUMP="$OBJDUMP"
5150
5151# Used on cygwin: assembler.
5152AS="$AS"
5153
5154# The name of the directory that contains temporary libtool files.
5155objdir=$objdir
5156
5157# How to create reloadable object files.
5158reload_flag=$lt_reload_flag
5159reload_cmds=$lt_reload_cmds
5160
5161# How to pass a linker flag through the compiler.
5162wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
5163
5164# Object file suffix (normally "o").
5165objext="$ac_objext"
5166
5167# Old archive suffix (normally "a").
5168libext="$libext"
5169
5170# Shared library suffix (normally ".so").
5171shrext_cmds='$shrext_cmds'
5172
5173# Executable file suffix (normally "").
5174exeext="$exeext"
5175
5176# Additional compiler flags for building library objects.
5177pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
5178pic_mode=$pic_mode
5179
5180# What is the maximum length of a command?
5181max_cmd_len=$lt_cv_sys_max_cmd_len
5182
5183# Does compiler simultaneously support -c and -o options?
5184compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
5185
5186# Must we lock files when doing compilation?
5187need_locks=$lt_need_locks
5188
5189# Do we need the lib prefix for modules?
5190need_lib_prefix=$need_lib_prefix
5191
5192# Do we need a version for libraries?
5193need_version=$need_version
5194
5195# Whether dlopen is supported.
5196dlopen_support=$enable_dlopen
5197
5198# Whether dlopen of programs is supported.
5199dlopen_self=$enable_dlopen_self
5200
5201# Whether dlopen of statically linked programs is supported.
5202dlopen_self_static=$enable_dlopen_self_static
5203
5204# Compiler flag to prevent dynamic linking.
5205link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
5206
5207# Compiler flag to turn off builtin functions.
5208no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
5209
5210# Compiler flag to allow reflexive dlopens.
5211export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
5212
5213# Compiler flag to generate shared objects directly from archives.
5214whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
5215
5216# Compiler flag to generate thread-safe objects.
5217thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
5218
5219# Library versioning type.
5220version_type=$version_type
5221
5222# Format of library name prefix.
5223libname_spec=$lt_libname_spec
5224
5225# List of archive names. First name is the real one, the rest are links.
5226# The last name is the one that the linker finds with -lNAME.
5227library_names_spec=$lt_library_names_spec
5228
5229# The coded name of the library, if different from the real name.
5230soname_spec=$lt_soname_spec
5231
5232# Commands used to build and install an old-style archive.
5233RANLIB=$lt_RANLIB
5234old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
5235old_postinstall_cmds=$lt_old_postinstall_cmds
5236old_postuninstall_cmds=$lt_old_postuninstall_cmds
5237
5238# Create an old-style archive from a shared archive.
5239old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
5240
5241# Create a temporary old-style archive to link instead of a shared archive.
5242old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
5243
5244# Commands used to build and install a shared archive.
5245archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
5246archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
5247postinstall_cmds=$lt_postinstall_cmds
5248postuninstall_cmds=$lt_postuninstall_cmds
5249
5250# Commands used to build a loadable module (assumed same as above if empty)
5251module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
5252module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
5253
5254# Commands to strip libraries.
5255old_striplib=$lt_old_striplib
5256striplib=$lt_striplib
5257
5258# Dependencies to place before the objects being linked to create a
5259# shared library.
5260predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
5261
5262# Dependencies to place after the objects being linked to create a
5263# shared library.
5264postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
5265
5266# Dependencies to place before the objects being linked to create a
5267# shared library.
5268predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
5269
5270# Dependencies to place after the objects being linked to create a
5271# shared library.
5272postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
5273
5274# The library search path used internally by the compiler when linking
5275# a shared library.
5276compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
5277
5278# Method to check whether dependent libraries are shared objects.
5279deplibs_check_method=$lt_deplibs_check_method
5280
5281# Command to use when deplibs_check_method == file_magic.
5282file_magic_cmd=$lt_file_magic_cmd
5283
5284# Flag that allows shared libraries with undefined symbols to be built.
5285allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
5286
5287# Flag that forces no undefined symbols.
5288no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
5289
5290# Commands used to finish a libtool library installation in a directory.
5291finish_cmds=$lt_finish_cmds
5292
5293# Same as above, but a single script fragment to be evaled but not shown.
5294finish_eval=$lt_finish_eval
5295
5296# Take the output of nm and produce a listing of raw symbols and C names.
5297global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
5298
5299# Transform the output of nm in a proper C declaration
5300global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
5301
5302# Transform the output of nm in a C name address pair
5303global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
5304
5305# This is the shared library runtime path variable.
5306runpath_var=$runpath_var
5307
5308# This is the shared library path variable.
5309shlibpath_var=$shlibpath_var
5310
5311# Is shlibpath searched before the hard-coded library search path?
5312shlibpath_overrides_runpath=$shlibpath_overrides_runpath
5313
5314# How to hardcode a shared library path into an executable.
5315hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
5316
5317# Whether we should hardcode library paths into libraries.
5318hardcode_into_libs=$hardcode_into_libs
5319
5320# Flag to hardcode \$libdir into a binary during linking.
5321# This must work even if \$libdir does not exist.
5322hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
5323
5324# If ld is used when linking, flag to hardcode \$libdir into
5325# a binary during linking. This must work even if \$libdir does
5326# not exist.
5327hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
5328
5329# Whether we need a single -rpath flag with a separated argument.
5330hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
5331
5332# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
5333# resulting binary.
5334hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
5335
5336# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
5337# resulting binary.
5338hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
5339
5340# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
5341# the resulting binary.
5342hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
5343
5344# Set to yes if building a shared library automatically hardcodes DIR into the library
5345# and all subsequent libraries and executables linked against it.
5346hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
5347
5348# Variables whose values should be saved in libtool wrapper scripts and
5349# restored at relink time.
5350variables_saved_for_relink="$variables_saved_for_relink"
5351
5352# Whether libtool must link a program against all its dependency libraries.
5353link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
5354
5355# Compile-time system search path for libraries
5356sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
5357
5358# Run-time system search path for libraries
5359sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
5360
5361# Fix the shell variable \$srcfile for the compiler.
5362fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
5363
5364# Set to yes if exported symbols are required.
5365always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
5366
5367# The commands to list exported symbols.
5368export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
5369
5370# The commands to extract the exported symbol list from a shared archive.
5371extract_expsyms_cmds=$lt_extract_expsyms_cmds
5372
5373# Symbols that should not be listed in the preloaded symbols.
5374exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
5375
5376# Symbols that must always be exported.
5377include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
5378
5379ifelse([$1],[],
5380[# ### END LIBTOOL CONFIG],
5381[# ### END LIBTOOL TAG CONFIG: $tagname])
5382
5383__EOF__
5384
5385ifelse([$1],[], [
5386 case $host_os in
5387 aix3*)
5388 cat <<\EOF >> "$cfgfile"
5389
5390# AIX sometimes has problems with the GCC collect2 program. For some
5391# reason, if we set the COLLECT_NAMES environment variable, the problems
5392# vanish in a puff of smoke.
5393if test "X${COLLECT_NAMES+set}" != Xset; then
5394 COLLECT_NAMES=
5395 export COLLECT_NAMES
5396fi
5397EOF
5398 ;;
5399 esac
5400
5401 # We use sed instead of cat because bash on DJGPP gets confused if
5402 # if finds mixed CR/LF and LF-only lines. Since sed operates in
5403 # text mode, it properly converts lines to CR/LF. This bash problem
5404 # is reportedly fixed, but why not run on old versions too?
5405 sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
5406
5407 mv -f "$cfgfile" "$ofile" || \
5408 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
5409 chmod +x "$ofile"
5410])
5411else
5412 # If there is no Makefile yet, we rely on a make rule to execute
5413 # `config.status --recheck' to rerun these tests and create the
5414 # libtool script then.
5415 ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
5416 if test -f "$ltmain_in"; then
5417 test -f Makefile && make "$ltmain"
5418 fi
5419fi
5420])# AC_LIBTOOL_CONFIG
5421
5422
5423# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
5424# -------------------------------------------
5425AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
5426[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
5427
5428_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5429
5430if test "$GCC" = yes; then
5431 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5432
5433 AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
5434 lt_cv_prog_compiler_rtti_exceptions,
5435 [-fno-rtti -fno-exceptions], [],
5436 [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
5437fi
5438])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
5439
5440
5441# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5442# ---------------------------------
5443AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
5444[AC_REQUIRE([AC_CANONICAL_HOST])
5445AC_REQUIRE([AC_PROG_NM])
5446AC_REQUIRE([AC_OBJEXT])
5447# Check for command to grab the raw symbol name followed by C symbol from nm.
5448AC_MSG_CHECKING([command to parse $NM output from $compiler object])
5449AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
5450[
5451# These are sane defaults that work on at least a few old systems.
5452# [They come from Ultrix. What could be older than Ultrix?!! ;)]
5453
5454# Character class describing NM global symbol codes.
5455symcode='[[BCDEGRST]]'
5456
5457# Regexp to match symbols that can be accessed directly from C.
5458sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
5459
5460# Transform an extracted symbol line into a proper C declaration
5461lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
5462
5463# Transform an extracted symbol line into symbol name and symbol address
5464lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5465
5466# Define system-specific variables.
5467case $host_os in
5468aix*)
5469 symcode='[[BCDT]]'
5470 ;;
5471cygwin* | mingw* | pw32*)
5472 symcode='[[ABCDGISTW]]'
5473 ;;
5474hpux*) # Its linker distinguishes data from code symbols
5475 if test "$host_cpu" = ia64; then
5476 symcode='[[ABCDEGRST]]'
5477 fi
5478 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5479 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5480 ;;
5481linux* | k*bsd*-gnu)
5482 if test "$host_cpu" = ia64; then
5483 symcode='[[ABCDGIRSTW]]'
5484 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5485 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5486 fi
5487 ;;
5488irix* | nonstopux*)
5489 symcode='[[BCDEGRST]]'
5490 ;;
5491osf*)
5492 symcode='[[BCDEGQRST]]'
5493 ;;
5494solaris*)
5495 symcode='[[BDRT]]'
5496 ;;
5497sco3.2v5*)
5498 symcode='[[DT]]'
5499 ;;
5500sysv4.2uw2*)
5501 symcode='[[DT]]'
5502 ;;
5503sysv5* | sco5v6* | unixware* | OpenUNIX*)
5504 symcode='[[ABDT]]'
5505 ;;
5506sysv4)
5507 symcode='[[DFNSTU]]'
5508 ;;
5509esac
5510
5511# Handle CRLF in mingw tool chain
5512opt_cr=
5513case $build_os in
5514mingw*)
5515 opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5516 ;;
5517esac
5518
5519# If we're using GNU nm, then use its standard symbol codes.
5520case `$NM -V 2>&1` in
5521*GNU* | *'with BFD'*)
5522 symcode='[[ABCDGIRSTW]]' ;;
5523esac
5524
5525# Try without a prefix undercore, then with it.
5526for ac_symprfx in "" "_"; do
5527
5528 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5529 symxfrm="\\1 $ac_symprfx\\2 \\2"
5530
5531 # Write the raw and C identifiers.
5532 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5533
5534 # Check to see that the pipe works correctly.
5535 pipe_works=no
5536
5537 rm -f conftest*
5538 cat > conftest.$ac_ext <<EOF
5539#ifdef __cplusplus
5540extern "C" {
5541#endif
5542char nm_test_var;
5543void nm_test_func(){}
5544#ifdef __cplusplus
5545}
5546#endif
5547int main(){nm_test_var='a';nm_test_func();return(0);}
5548EOF
5549
5550 if AC_TRY_EVAL(ac_compile); then
5551 # Now try to grab the symbols.
5552 nlist=conftest.nm
5553 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5554 # Try sorting and uniquifying the output.
5555 if sort "$nlist" | uniq > "$nlist"T; then
5556 mv -f "$nlist"T "$nlist"
5557 else
5558 rm -f "$nlist"T
5559 fi
5560
5561 # Make sure that we snagged all the symbols we need.
5562 if grep ' nm_test_var$' "$nlist" >/dev/null; then
5563 if grep ' nm_test_func$' "$nlist" >/dev/null; then
5564 cat <<EOF > conftest.$ac_ext
5565#ifdef __cplusplus
5566extern "C" {
5567#endif
5568
5569EOF
5570 # Now generate the symbol file.
5571 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
5572
5573 cat <<EOF >> conftest.$ac_ext
5574#if defined (__STDC__) && __STDC__
5575# define lt_ptr_t void *
5576#else
5577# define lt_ptr_t char *
5578# define const
5579#endif
5580
5581/* The mapping between symbol names and symbols. */
5582const struct {
5583 const char *name;
5584 lt_ptr_t address;
5585}
5586lt_preloaded_symbols[[]] =
5587{
5588EOF
5589 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
5590 cat <<\EOF >> conftest.$ac_ext
5591 {0, (lt_ptr_t) 0}
5592};
5593
5594#ifdef __cplusplus
5595}
5596#endif
5597EOF
5598 # Now try linking the two files.
5599 mv conftest.$ac_objext conftstm.$ac_objext
5600 lt_save_LIBS="$LIBS"
5601 lt_save_CFLAGS="$CFLAGS"
5602 LIBS="conftstm.$ac_objext"
5603 CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5604 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5605 pipe_works=yes
5606 fi
5607 LIBS="$lt_save_LIBS"
5608 CFLAGS="$lt_save_CFLAGS"
5609 else
5610 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5611 fi
5612 else
5613 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5614 fi
5615 else
5616 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5617 fi
5618 else
5619 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5620 cat conftest.$ac_ext >&5
5621 fi
5622 rm -f conftest* conftst*
5623
5624 # Do not use the global_symbol_pipe unless it works.
5625 if test "$pipe_works" = yes; then
5626 break
5627 else
5628 lt_cv_sys_global_symbol_pipe=
5629 fi
5630done
5631])
5632if test -z "$lt_cv_sys_global_symbol_pipe"; then
5633 lt_cv_sys_global_symbol_to_cdecl=
5634fi
5635if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5636 AC_MSG_RESULT(failed)
5637else
5638 AC_MSG_RESULT(ok)
5639fi
5640]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5641
5642
5643# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
5644# ---------------------------------------
5645AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
5646[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
5647_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5648_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
5649
5650AC_MSG_CHECKING([for $compiler option to produce PIC])
5651 ifelse([$1],[CXX],[
5652 # C++ specific cases for pic, static, wl, etc.
5653 if test "$GXX" = yes; then
5654 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5655 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5656
5657 case $host_os in
5658 aix*)
5659 # All AIX code is PIC.
5660 if test "$host_cpu" = ia64; then
5661 # AIX 5 now supports IA64 processor
5662 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5663 fi
5664 ;;
5665 amigaos*)
5666 # FIXME: we need at least 68020 code to build shared libraries, but
5667 # adding the `-m68020' flag to GCC prevents building anything better,
5668 # like `-m68040'.
5669 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5670 ;;
5671 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5672 # PIC is the default for these OSes.
5673 ;;
5674 mingw* | os2* | pw32*)
5675 # This hack is so that the source file can tell whether it is being
5676 # built for inclusion in a dll (and should export symbols for example).
5677 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5678 ;;
5679 darwin* | rhapsody*)
5680 # PIC is the default on this platform
5681 # Common symbols not allowed in MH_DYLIB files
5682 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5683 ;;
5684 *djgpp*)
5685 # DJGPP does not support shared libraries at all
5686 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5687 ;;
5688 interix3*)
5689 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5690 # Instead, we relocate shared libraries at runtime.
5691 ;;
5692 sysv4*MP*)
5693 if test -d /usr/nec; then
5694 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5695 fi
5696 ;;
5697 hpux*)
5698 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5699 # not for PA HP-UX.
5700 case $host_cpu in
5701 hppa*64*|ia64*)
5702 ;;
5703 *)
5704 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5705 ;;
5706 esac
5707 ;;
5708 *)
5709 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5710 ;;
5711 esac
5712 else
5713 case $host_os in
5714 aix4* | aix5*)
5715 # All AIX code is PIC.
5716 if test "$host_cpu" = ia64; then
5717 # AIX 5 now supports IA64 processor
5718 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5719 else
5720 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5721 fi
5722 ;;
5723 chorus*)
5724 case $cc_basename in
5725 cxch68*)
5726 # Green Hills C++ Compiler
5727 # _LT_AC_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"
5728 ;;
5729 esac
5730 ;;
5731 darwin*)
5732 # PIC is the default on this platform
5733 # Common symbols not allowed in MH_DYLIB files
5734 case $cc_basename in
5735 xlc*)
5736 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
5737 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5738 ;;
5739 esac
5740 ;;
5741 dgux*)
5742 case $cc_basename in
5743 ec++*)
5744 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5745 ;;
5746 ghcx*)
5747 # Green Hills C++ Compiler
5748 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5749 ;;
5750 *)
5751 ;;
5752 esac
5753 ;;
5754 freebsd* | dragonfly*)
5755 # FreeBSD uses GNU C++
5756 ;;
5757 hpux9* | hpux10* | hpux11*)
5758 case $cc_basename in
5759 CC*)
5760 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5761 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5762 if test "$host_cpu" != ia64; then
5763 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5764 fi
5765 ;;
5766 aCC*)
5767 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5768 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5769 case $host_cpu in
5770 hppa*64*|ia64*)
5771 # +Z the default
5772 ;;
5773 *)
5774 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5775 ;;
5776 esac
5777 ;;
5778 *)
5779 ;;
5780 esac
5781 ;;
5782 interix*)
5783 # This is c89, which is MS Visual C++ (no shared libs)
5784 # Anyone wants to do a port?
5785 ;;
5786 irix5* | irix6* | nonstopux*)
5787 case $cc_basename in
5788 CC*)
5789 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5790 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5791 # CC pic flag -KPIC is the default.
5792 ;;
5793 *)
5794 ;;
5795 esac
5796 ;;
5797 linux* | k*bsd*-gnu)
5798 case $cc_basename in
5799 KCC*)
5800 # KAI C++ Compiler
5801 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5802 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5803 ;;
5804 icpc* | ecpc*)
5805 # Intel C++
5806 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5807 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5808 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5809 ;;
5810 pgCC*)
5811 # Portland Group C++ compiler.
5812 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5813 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5814 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5815 ;;
5816 cxx*)
5817 # Compaq C++
5818 # Make sure the PIC flag is empty. It appears that all Alpha
5819 # Linux and Compaq Tru64 Unix objects are PIC.
5820 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5821 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5822 ;;
5823 *)
5824 ;;
5825 esac
5826 ;;
5827 lynxos*)
5828 ;;
5829 m88k*)
5830 ;;
5831 mvs*)
5832 case $cc_basename in
5833 cxx*)
5834 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5835 ;;
5836 *)
5837 ;;
5838 esac
5839 ;;
5840 netbsd* | netbsdelf*-gnu)
5841 ;;
5842 osf3* | osf4* | osf5*)
5843 case $cc_basename in
5844 KCC*)
5845 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5846 ;;
5847 RCC*)
5848 # Rational C++ 2.4.1
5849 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5850 ;;
5851 cxx*)
5852 # Digital/Compaq C++
5853 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5854 # Make sure the PIC flag is empty. It appears that all Alpha
5855 # Linux and Compaq Tru64 Unix objects are PIC.
5856 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5857 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5858 ;;
5859 *)
5860 ;;
5861 esac
5862 ;;
5863 psos*)
5864 ;;
5865 solaris*)
5866 case $cc_basename in
5867 CC*)
5868 # Sun C++ 4.2, 5.x and Centerline C++
5869 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5870 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5871 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5872 ;;
5873 gcx*)
5874 # Green Hills C++ Compiler
5875 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5876 ;;
5877 *)
5878 ;;
5879 esac
5880 ;;
5881 sunos4*)
5882 case $cc_basename in
5883 CC*)
5884 # Sun C++ 4.x
5885 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5886 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5887 ;;
5888 lcc*)
5889 # Lucid
5890 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5891 ;;
5892 *)
5893 ;;
5894 esac
5895 ;;
5896 tandem*)
5897 case $cc_basename in
5898 NCC*)
5899 # NonStop-UX NCC 3.20
5900 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5901 ;;
5902 *)
5903 ;;
5904 esac
5905 ;;
5906 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
5907 case $cc_basename in
5908 CC*)
5909 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5910 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5911 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5912 ;;
5913 esac
5914 ;;
5915 vxworks*)
5916 ;;
5917 *)
5918 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5919 ;;
5920 esac
5921 fi
5922],
5923[
5924 if test "$GCC" = yes; then
5925 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5926 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5927
5928 case $host_os in
5929 aix*)
5930 # All AIX code is PIC.
5931 if test "$host_cpu" = ia64; then
5932 # AIX 5 now supports IA64 processor
5933 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5934 fi
5935 ;;
5936
5937 amigaos*)
5938 # FIXME: we need at least 68020 code to build shared libraries, but
5939 # adding the `-m68020' flag to GCC prevents building anything better,
5940 # like `-m68040'.
5941 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5942 ;;
5943
5944 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5945 # PIC is the default for these OSes.
5946 ;;
5947
5948 mingw* | pw32* | os2*)
5949 # This hack is so that the source file can tell whether it is being
5950 # built for inclusion in a dll (and should export symbols for example).
5951 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5952 ;;
5953
5954 darwin* | rhapsody*)
5955 # PIC is the default on this platform
5956 # Common symbols not allowed in MH_DYLIB files
5957 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5958 ;;
5959
5960 interix3*)
5961 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
5962 # Instead, we relocate shared libraries at runtime.
5963 ;;
5964
5965 msdosdjgpp*)
5966 # Just because we use GCC doesn't mean we suddenly get shared libraries
5967 # on systems that don't support them.
5968 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5969 enable_shared=no
5970 ;;
5971
5972 sysv4*MP*)
5973 if test -d /usr/nec; then
5974 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5975 fi
5976 ;;
5977
5978 hpux*)
5979 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5980 # not for PA HP-UX.
5981 case $host_cpu in
5982 hppa*64*|ia64*)
5983 # +Z the default
5984 ;;
5985 *)
5986 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5987 ;;
5988 esac
5989 ;;
5990
5991 *)
5992 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5993 ;;
5994 esac
5995 else
5996 # PORTME Check for flag to pass linker flags through the system compiler.
5997 case $host_os in
5998 aix*)
5999 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6000 if test "$host_cpu" = ia64; then
6001 # AIX 5 now supports IA64 processor
6002 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6003 else
6004 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
6005 fi
6006 ;;
6007 darwin*)
6008 # PIC is the default on this platform
6009 # Common symbols not allowed in MH_DYLIB files
6010 case $cc_basename in
6011 xlc*)
6012 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
6013 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6014 ;;
6015 esac
6016 ;;
6017
6018 mingw* | pw32* | os2*)
6019 # This hack is so that the source file can tell whether it is being
6020 # built for inclusion in a dll (and should export symbols for example).
6021 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
6022 ;;
6023
6024 hpux9* | hpux10* | hpux11*)
6025 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6026 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6027 # not for PA HP-UX.
6028 case $host_cpu in
6029 hppa*64*|ia64*)
6030 # +Z the default
6031 ;;
6032 *)
6033 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6034 ;;
6035 esac
6036 # Is there a better lt_prog_compiler_static that works with the bundled CC?
6037 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6038 ;;
6039
6040 irix5* | irix6* | nonstopux*)
6041 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6042 # PIC (with -KPIC) is the default.
6043 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6044 ;;
6045
6046 newsos6)
6047 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6048 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6049 ;;
6050
6051 linux* | k*bsd*-gnu)
6052 case $cc_basename in
6053 icc* | ecc*)
6054 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6055 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6056 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6057 ;;
6058 pgcc* | pgf77* | pgf90* | pgf95*)
6059 # Portland Group compilers (*not* the Pentium gcc compiler,
6060 # which looks to be a dead project)
6061 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6062 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
6063 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6064 ;;
6065 ccc*)
6066 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6067 # All Alpha code is PIC.
6068 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6069 ;;
6070 esac
6071 ;;
6072
6073 osf3* | osf4* | osf5*)
6074 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6075 # All OSF/1 code is PIC.
6076 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6077 ;;
6078
6079 solaris*)
6080 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6081 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6082 case $cc_basename in
6083 f77* | f90* | f95*)
6084 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
6085 *)
6086 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
6087 esac
6088 ;;
6089
6090 sunos4*)
6091 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6092 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6093 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6094 ;;
6095
6096 sysv4 | sysv4.2uw2* | sysv4.3*)
6097 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6098 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6099 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6100 ;;
6101
6102 sysv4*MP*)
6103 if test -d /usr/nec ;then
6104 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
6105 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6106 fi
6107 ;;
6108
6109 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6110 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6111 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6112 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6113 ;;
6114
6115 unicos*)
6116 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6117 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6118 ;;
6119
6120 uts4*)
6121 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6122 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6123 ;;
6124
6125 *)
6126 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6127 ;;
6128 esac
6129 fi
6130])
6131AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
6132
6133#
6134# Check to make sure the PIC flag actually works.
6135#
6136if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
6137 AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
6138 _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
6139 [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
6140 [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
6141 "" | " "*) ;;
6142 *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
6143 esac],
6144 [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6145 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
6146fi
6147case $host_os in
6148 # For platforms which do not support PIC, -DPIC is meaningless:
6149 *djgpp*)
6150 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6151 ;;
6152 *)
6153 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
6154 ;;
6155esac
6156
6157#
6158# Check to make sure the static flag actually works.
6159#
6160wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
6161AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
6162 _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
6163 $lt_tmp_static_flag,
6164 [],
6165 [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
6166])
6167
6168
6169# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
6170# ------------------------------------
6171# See if the linker supports building shared libraries.
6172AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
6173[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6174ifelse([$1],[CXX],[
6175 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6176 case $host_os in
6177 aix4* | aix5*)
6178 # If we're using GNU nm, then we don't want the "-C" option.
6179 # -C means demangle to AIX nm, but means don't demangle with GNU nm
6180 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6181 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6182 else
6183 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6184 fi
6185 ;;
6186 pw32*)
6187 _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
6188 ;;
6189 cygwin* | mingw*)
6190 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
6191 ;;
6192 linux* | k*bsd*-gnu)
6193 _LT_AC_TAGVAR(link_all_deplibs, $1)=no
6194 ;;
6195 *)
6196 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6197 ;;
6198 esac
6199],[
6200 runpath_var=
6201 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
6202 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6203 _LT_AC_TAGVAR(archive_cmds, $1)=
6204 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
6205 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
6206 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
6207 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6208 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6209 _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
6210 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6211 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6212 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6213 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6214 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6215 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6216 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
6217 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
6218 _LT_AC_TAGVAR(module_cmds, $1)=
6219 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
6220 _LT_AC_TAGVAR(always_export_symbols, $1)=no
6221 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6222 # include_expsyms should be a list of space-separated symbols to be *always*
6223 # included in the symbol list
6224 _LT_AC_TAGVAR(include_expsyms, $1)=
6225 # exclude_expsyms can be an extended regexp of symbols to exclude
6226 # it will be wrapped by ` (' and `)$', so one must not match beginning or
6227 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
6228 # as well as any symbol that contains `d'.
6229 _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
6230 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
6231 # platforms (ab)use it in PIC code, but their linkers get confused if
6232 # the symbol is explicitly referenced. Since portable code cannot
6233 # rely on this symbol name, it's probably fine to never include it in
6234 # preloaded symbol tables.
6235 extract_expsyms_cmds=
6236 # Just being paranoid about ensuring that cc_basename is set.
6237 _LT_CC_BASENAME([$compiler])
6238 case $host_os in
6239 cygwin* | mingw* | pw32*)
6240 # FIXME: the MSVC++ port hasn't been tested in a loooong time
6241 # When not using gcc, we currently assume that we are using
6242 # Microsoft Visual C++.
6243 if test "$GCC" != yes; then
6244 with_gnu_ld=no
6245 fi
6246 ;;
6247 interix*)
6248 # we just hope/assume this is gcc and not c89 (= MSVC++)
6249 with_gnu_ld=yes
6250 ;;
6251 openbsd*)
6252 with_gnu_ld=no
6253 ;;
6254 esac
6255
6256 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
6257 if test "$with_gnu_ld" = yes; then
6258 # If archive_cmds runs LD, not CC, wlarc should be empty
6259 wlarc='${wl}'
6260
6261 # Set some defaults for GNU ld with shared library support. These
6262 # are reset later if shared libraries are not supported. Putting them
6263 # here allows them to be overridden if necessary.
6264 runpath_var=LD_RUN_PATH
6265 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6266 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6267 # ancient GNU ld didn't support --whole-archive et. al.
6268 if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
6269 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6270 else
6271 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6272 fi
6273 supports_anon_versioning=no
6274 case `$LD -v 2>/dev/null` in
6275 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6276 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6277 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6278 *\ 2.11.*) ;; # other 2.11 versions
6279 *) supports_anon_versioning=yes ;;
6280 esac
6281
6282 # See if GNU ld supports shared libraries.
6283 case $host_os in
6284 aix3* | aix4* | aix5*)
6285 # On AIX/PPC, the GNU linker is very broken
6286 if test "$host_cpu" != ia64; then
6287 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6288 cat <<EOF 1>&2
6289
6290*** Warning: the GNU linker, at least up to release 2.9.1, is reported
6291*** to be unable to reliably create shared libraries on AIX.
6292*** Therefore, libtool is disabling shared libraries support. If you
6293*** really care for shared libraries, you may want to modify your PATH
6294*** so that a non-GNU linker is found, and then restart.
6295
6296EOF
6297 fi
6298 ;;
6299
6300 amigaos*)
6301 _LT_AC_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)'
6302 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6303 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6304
6305 # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
6306 # that the semantics of dynamic libraries on AmigaOS, at least up
6307 # to version 4, is to share data among multiple programs linked
6308 # with the same dynamic library. Since this doesn't match the
6309 # behavior of shared libraries on other platforms, we can't use
6310 # them.
6311 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6312 ;;
6313
6314 beos*)
6315 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6316 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6317 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6318 # support --undefined. This deserves some investigation. FIXME
6319 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6320 else
6321 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6322 fi
6323 ;;
6324
6325 cygwin* | mingw* | pw32*)
6326 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6327 # as there is no search path for DLLs.
6328 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6329 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6330 _LT_AC_TAGVAR(always_export_symbols, $1)=no
6331 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6332 _LT_AC_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'
6333
6334 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
6335 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6336 # If the export-symbols file already is a .def file (1st line
6337 # is EXPORTS), use it as is; otherwise, prepend...
6338 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6339 cp $export_symbols $output_objdir/$soname.def;
6340 else
6341 echo EXPORTS > $output_objdir/$soname.def;
6342 cat $export_symbols >> $output_objdir/$soname.def;
6343 fi~
6344 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6345 else
6346 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6347 fi
6348 ;;
6349
6350 interix3*)
6351 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6352 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6353 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6354 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6355 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6356 # Instead, shared libraries are loaded at an image base (0x10000000 by
6357 # default) and relocated if they conflict, which is a slow very memory
6358 # consuming and fragmenting process. To avoid this, we pick a random,
6359 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6360 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6361 _LT_AC_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'
6362 _LT_AC_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'
6363 ;;
6364
6365 linux* | k*bsd*-gnu)
6366 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6367 tmp_addflag=
6368 case $cc_basename,$host_cpu in
6369 pgcc*) # Portland Group C compiler
6370 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6371 tmp_addflag=' $pic_flag'
6372 ;;
6373 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
6374 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6375 tmp_addflag=' $pic_flag -Mnomain' ;;
6376 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
6377 tmp_addflag=' -i_dynamic' ;;
6378 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
6379 tmp_addflag=' -i_dynamic -nofor_main' ;;
6380 ifc* | ifort*) # Intel Fortran compiler
6381 tmp_addflag=' -nofor_main' ;;
6382 esac
6383 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6384
6385 if test $supports_anon_versioning = yes; then
6386 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
6387 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6388 $echo "local: *; };" >> $output_objdir/$libname.ver~
6389 $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6390 fi
6391 _LT_AC_TAGVAR(link_all_deplibs, $1)=no
6392 else
6393 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6394 fi
6395 ;;
6396
6397 netbsd* | netbsdelf*-gnu)
6398 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6399 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6400 wlarc=
6401 else
6402 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6403 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6404 fi
6405 ;;
6406
6407 solaris*)
6408 if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
6409 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6410 cat <<EOF 1>&2
6411
6412*** Warning: The releases 2.8.* of the GNU linker cannot reliably
6413*** create shared libraries on Solaris systems. Therefore, libtool
6414*** is disabling shared libraries support. We urge you to upgrade GNU
6415*** binutils to release 2.9.1 or newer. Another option is to modify
6416*** your PATH or compiler configuration so that the native linker is
6417*** used, and then restart.
6418
6419EOF
6420 elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6421 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6422 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6423 else
6424 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6425 fi
6426 ;;
6427
6428 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
6429 case `$LD -v 2>&1` in
6430 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
6431 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6432 cat <<_LT_EOF 1>&2
6433
6434*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
6435*** reliably create shared libraries on SCO systems. Therefore, libtool
6436*** is disabling shared libraries support. We urge you to upgrade GNU
6437*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
6438*** your PATH or compiler configuration so that the native linker is
6439*** used, and then restart.
6440
6441_LT_EOF
6442 ;;
6443 *)
6444 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6445 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
6446 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
6447 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
6448 else
6449 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6450 fi
6451 ;;
6452 esac
6453 ;;
6454
6455 sunos4*)
6456 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6457 wlarc=
6458 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6459 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6460 ;;
6461
6462 *)
6463 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6464 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6465 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6466 else
6467 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6468 fi
6469 ;;
6470 esac
6471
6472 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
6473 runpath_var=
6474 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6475 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6476 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6477 fi
6478 else
6479 # PORTME fill in a description of your system's linker (not GNU ld)
6480 case $host_os in
6481 aix3*)
6482 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6483 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6484 _LT_AC_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'
6485 # Note: this linker hardcodes the directories in LIBPATH if there
6486 # are no directories specified by -L.
6487 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6488 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
6489 # Neither direct hardcoding nor static linking is supported with a
6490 # broken collect2.
6491 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6492 fi
6493 ;;
6494
6495 aix4* | aix5*)
6496 if test "$host_cpu" = ia64; then
6497 # On IA64, the linker does run time linking by default, so we don't
6498 # have to do anything special.
6499 aix_use_runtimelinking=no
6500 exp_sym_flag='-Bexport'
6501 no_entry_flag=""
6502 else
6503 # If we're using GNU nm, then we don't want the "-C" option.
6504 # -C means demangle to AIX nm, but means don't demangle with GNU nm
6505 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6506 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6507 else
6508 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6509 fi
6510 aix_use_runtimelinking=no
6511
6512 # Test if we are trying to use run time linking or normal
6513 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6514 # need to do runtime linking.
6515 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
6516 for ld_flag in $LDFLAGS; do
6517 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6518 aix_use_runtimelinking=yes
6519 break
6520 fi
6521 done
6522 ;;
6523 esac
6524
6525 exp_sym_flag='-bexport'
6526 no_entry_flag='-bnoentry'
6527 fi
6528
6529 # When large executables or shared objects are built, AIX ld can
6530 # have problems creating the table of contents. If linking a library
6531 # or program results in "error TOC overflow" add -mminimal-toc to
6532 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6533 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6534
6535 _LT_AC_TAGVAR(archive_cmds, $1)=''
6536 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6537 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6538 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6539
6540 if test "$GCC" = yes; then
6541 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6542 # We only want to do this on AIX 4.2 and lower, the check
6543 # below for broken collect2 doesn't work under 4.3+
6544 collect2name=`${CC} -print-prog-name=collect2`
6545 if test -f "$collect2name" && \
6546 strings "$collect2name" | grep resolve_lib_name >/dev/null
6547 then
6548 # We have reworked collect2
6549 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6550 else
6551 # We have old collect2
6552 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6553 # It fails to find uninstalled libraries when the uninstalled
6554 # path is not listed in the libpath. Setting hardcode_minus_L
6555 # to unsupported forces relinking
6556 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6557 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6558 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6559 fi
6560 ;;
6561 esac
6562 shared_flag='-shared'
6563 if test "$aix_use_runtimelinking" = yes; then
6564 shared_flag="$shared_flag "'${wl}-G'
6565 fi
6566 else
6567 # not using gcc
6568 if test "$host_cpu" = ia64; then
6569 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6570 # chokes on -Wl,-G. The following line is correct:
6571 shared_flag='-G'
6572 else
6573 if test "$aix_use_runtimelinking" = yes; then
6574 shared_flag='${wl}-G'
6575 else
6576 shared_flag='${wl}-bM:SRE'
6577 fi
6578 fi
6579 fi
6580
6581 # It seems that -bexpall does not export symbols beginning with
6582 # underscore (_), so it is better to generate a list of symbols to export.
6583 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
6584 if test "$aix_use_runtimelinking" = yes; then
6585 # Warning - without using the other runtime loading flags (-brtl),
6586 # -berok will link without error, but may produce a broken library.
6587 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
6588 # Determine the default libpath from the value encoded in an empty executable.
6589 _LT_AC_SYS_LIBPATH_AIX
6590 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6591 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6592 else
6593 if test "$host_cpu" = ia64; then
6594 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6595 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6596 _LT_AC_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"
6597 else
6598 # Determine the default libpath from the value encoded in an empty executable.
6599 _LT_AC_SYS_LIBPATH_AIX
6600 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6601 # Warning - without using the other run time loading flags,
6602 # -berok will link without error, but may produce a broken library.
6603 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6604 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6605 # Exported symbols can be pulled into shared objects from archives
6606 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6607 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6608 # This is similar to how AIX traditionally builds its shared libraries.
6609 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6610 fi
6611 fi
6612 ;;
6613
6614 amigaos*)
6615 _LT_AC_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)'
6616 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6617 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6618 # see comment about different semantics on the GNU ld section
6619 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6620 ;;
6621
6622 bsdi[[45]]*)
6623 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6624 ;;
6625
6626 cygwin* | mingw* | pw32*)
6627 # When not using gcc, we currently assume that we are using
6628 # Microsoft Visual C++.
6629 # hardcode_libdir_flag_spec is actually meaningless, as there is
6630 # no search path for DLLs.
6631 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6632 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6633 # Tell ltmain to make .lib files, not .a files.
6634 libext=lib
6635 # Tell ltmain to make .dll files, not .so files.
6636 shrext_cmds=".dll"
6637 # FIXME: Setting linknames here is a bad hack.
6638 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
6639 # The linker will automatically build a .lib file if we build a DLL.
6640 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
6641 # FIXME: Should let the user specify the lib program.
6642 _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
6643 _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
6644 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6645 ;;
6646
6647 darwin* | rhapsody*)
6648 case $host_os in
6649 rhapsody* | darwin1.[[012]])
6650 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
6651 ;;
6652 *) # Darwin 1.3 on
6653 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
6654 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6655 else
6656 case ${MACOSX_DEPLOYMENT_TARGET} in
6657 10.[[012]])
6658 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6659 ;;
6660 10.*)
6661 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
6662 ;;
6663 esac
6664 fi
6665 ;;
6666 esac
6667 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6668 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6669 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
6670 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6671 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
6672 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6673 if test "$GCC" = yes ; then
6674 output_verbose_link_cmd='echo'
6675 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
6676 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6677 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
6678 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6679 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6680 else
6681 case $cc_basename in
6682 xlc*)
6683 output_verbose_link_cmd='echo'
6684 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
6685 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6686 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
6687 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6688 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
6689 ;;
6690 *)
6691 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6692 ;;
6693 esac
6694 fi
6695 ;;
6696
6697 dgux*)
6698 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6699 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6700 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6701 ;;
6702
6703 freebsd1*)
6704 _LT_AC_TAGVAR(ld_shlibs, $1)=no
6705 ;;
6706
6707 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6708 # support. Future versions do this automatically, but an explicit c++rt0.o
6709 # does not break anything, and helps significantly (at the cost of a little
6710 # extra space).
6711 freebsd2.2*)
6712 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6713 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6714 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6715 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6716 ;;
6717
6718 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
6719 freebsd2*)
6720 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6721 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6722 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6723 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6724 ;;
6725
6726 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6727 freebsd* | dragonfly*)
6728 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
6729 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6730 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6731 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6732 ;;
6733
6734 hpux9*)
6735 if test "$GCC" = yes; then
6736 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6737 else
6738 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6739 fi
6740 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6741 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6742 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6743
6744 # hardcode_minus_L: Not really in the search PATH,
6745 # but as the default location of the library.
6746 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6747 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6748 ;;
6749
6750 hpux10*)
6751 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6752 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6753 else
6754 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6755 fi
6756 if test "$with_gnu_ld" = no; then
6757 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6758 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6759
6760 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6761 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6762
6763 # hardcode_minus_L: Not really in the search PATH,
6764 # but as the default location of the library.
6765 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6766 fi
6767 ;;
6768
6769 hpux11*)
6770 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6771 case $host_cpu in
6772 hppa*64*)
6773 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6774 ;;
6775 ia64*)
6776 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6777 ;;
6778 *)
6779 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6780 ;;
6781 esac
6782 else
6783 case $host_cpu in
6784 hppa*64*)
6785 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6786 ;;
6787 ia64*)
6788 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
6789 ;;
6790 *)
6791 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6792 ;;
6793 esac
6794 fi
6795 if test "$with_gnu_ld" = no; then
6796 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6797 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6798
6799 case $host_cpu in
6800 hppa*64*|ia64*)
6801 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
6802 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6803 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6804 ;;
6805 *)
6806 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6807 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6808
6809 # hardcode_minus_L: Not really in the search PATH,
6810 # but as the default location of the library.
6811 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6812 ;;
6813 esac
6814 fi
6815 ;;
6816
6817 irix5* | irix6* | nonstopux*)
6818 if test "$GCC" = yes; then
6819 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6820 else
6821 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6822 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6823 fi
6824 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6825 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6826 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6827 ;;
6828
6829 netbsd* | netbsdelf*-gnu)
6830 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6831 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6832 else
6833 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6834 fi
6835 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6836 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6837 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6838 ;;
6839
6840 newsos6)
6841 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6842 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6843 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6844 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6845 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6846 ;;
6847
6848 openbsd*)
6849 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6850 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6851 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6852 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6853 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6854 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6855 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6856 else
6857 case $host_os in
6858 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6859 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6860 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6861 ;;
6862 *)
6863 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6864 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6865 ;;
6866 esac
6867 fi
6868 ;;
6869
6870 os2*)
6871 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6872 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6873 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6874 _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
6875 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6876 ;;
6877
6878 osf3*)
6879 if test "$GCC" = yes; then
6880 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6881 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6882 else
6883 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6884 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6885 fi
6886 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6887 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6888 ;;
6889
6890 osf4* | osf5*) # as osf3* with the addition of -msym flag
6891 if test "$GCC" = yes; then
6892 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6893 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6894 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6895 else
6896 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6897 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
6898 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
6899 $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
6900
6901 # Both c and cxx compiler support -rpath directly
6902 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6903 fi
6904 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6905 ;;
6906
6907 solaris*)
6908 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6909 if test "$GCC" = yes; then
6910 wlarc='${wl}'
6911 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6912 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6913 $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
6914 else
6915 wlarc=''
6916 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6917 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6918 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6919 fi
6920 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6921 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6922 case $host_os in
6923 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6924 *)
6925 # The compiler driver will combine linker options so we
6926 # cannot just pass the convience library names through
6927 # without $wl, iff we do not link with $LD.
6928 # Luckily, gcc supports the same syntax we need for Sun Studio.
6929 # Supported since Solaris 2.6 (maybe 2.5.1?)
6930 case $wlarc in
6931 '')
6932 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
6933 *)
6934 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
6935 esac ;;
6936 esac
6937 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6938 ;;
6939
6940 sunos4*)
6941 if test "x$host_vendor" = xsequent; then
6942 # Use $CC to link under sequent, because it throws in some extra .o
6943 # files that make .init and .fini sections work.
6944 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6945 else
6946 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6947 fi
6948 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6949 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
6950 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6951 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6952 ;;
6953
6954 sysv4)
6955 case $host_vendor in
6956 sni)
6957 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6958 _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6959 ;;
6960 siemens)
6961 ## LD is ld it makes a PLAMLIB
6962 ## CC just makes a GrossModule.
6963 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6964 _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6965 _LT_AC_TAGVAR(hardcode_direct, $1)=no
6966 ;;
6967 motorola)
6968 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6969 _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6970 ;;
6971 esac
6972 runpath_var='LD_RUN_PATH'
6973 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6974 ;;
6975
6976 sysv4.3*)
6977 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6978 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6979 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6980 ;;
6981
6982 sysv4*MP*)
6983 if test -d /usr/nec; then
6984 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6985 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6986 runpath_var=LD_RUN_PATH
6987 hardcode_runpath_var=yes
6988 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
6989 fi
6990 ;;
6991
6992 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7*)
6993 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6994 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6995 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6996 runpath_var='LD_RUN_PATH'
6997
6998 if test "$GCC" = yes; then
6999 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7000 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7001 else
7002 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7003 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7004 fi
7005 ;;
7006
7007 sysv5* | sco3.2v5* | sco5v6*)
7008 # Note: We can NOT use -z defs as we might desire, because we do not
7009 # link with -lc, and that would cause any symbols used from libc to
7010 # always be unresolved, which means just about no library would
7011 # ever link correctly. If we're not using GNU ld we use -z text
7012 # though, which does catch some bad symbols but isn't as heavy-handed
7013 # as -z defs.
7014 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7015 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7016 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7017 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7018 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
7019 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
7020 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7021 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7022 runpath_var='LD_RUN_PATH'
7023
7024 if test "$GCC" = yes; then
7025 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7026 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7027 else
7028 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7029 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7030 fi
7031 ;;
7032
7033 uts4*)
7034 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7035 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7036 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7037 ;;
7038
7039 *)
7040 _LT_AC_TAGVAR(ld_shlibs, $1)=no
7041 ;;
7042 esac
7043 fi
7044])
7045AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
7046test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7047
7048#
7049# Do we need to explicitly link libc?
7050#
7051case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
7052x|xyes)
7053 # Assume -lc should be added
7054 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7055
7056 if test "$enable_shared" = yes && test "$GCC" = yes; then
7057 case $_LT_AC_TAGVAR(archive_cmds, $1) in
7058 *'~'*)
7059 # FIXME: we may have to deal with multi-command sequences.
7060 ;;
7061 '$CC '*)
7062 # Test whether the compiler implicitly links with -lc since on some
7063 # systems, -lgcc has to come before -lc. If gcc already passes -lc
7064 # to ld, don't add -lc before -lgcc.
7065 AC_MSG_CHECKING([whether -lc should be explicitly linked in])
7066 $rm conftest*
7067 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7068
7069 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
7070 soname=conftest
7071 lib=conftest
7072 libobjs=conftest.$ac_objext
7073 deplibs=
7074 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
7075 pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
7076 compiler_flags=-v
7077 linker_flags=-v
7078 verstring=
7079 output_objdir=.
7080 libname=conftest
7081 lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
7082 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
7083 if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
7084 then
7085 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7086 else
7087 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7088 fi
7089 _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
7090 else
7091 cat conftest.err 1>&5
7092 fi
7093 $rm conftest*
7094 AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
7095 ;;
7096 esac
7097 fi
7098 ;;
7099esac
7100])# AC_LIBTOOL_PROG_LD_SHLIBS
7101
7102
7103# _LT_AC_FILE_LTDLL_C
7104# -------------------
7105# Be careful that the start marker always follows a newline.
7106AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
7107# /* ltdll.c starts here */
7108# #define WIN32_LEAN_AND_MEAN
7109# #include <windows.h>
7110# #undef WIN32_LEAN_AND_MEAN
7111# #include <stdio.h>
7112#
7113# #ifndef __CYGWIN__
7114# # ifdef __CYGWIN32__
7115# # define __CYGWIN__ __CYGWIN32__
7116# # endif
7117# #endif
7118#
7119# #ifdef __cplusplus
7120# extern "C" {
7121# #endif
7122# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
7123# #ifdef __cplusplus
7124# }
7125# #endif
7126#
7127# #ifdef __CYGWIN__
7128# #include <cygwin/cygwin_dll.h>
7129# DECLARE_CYGWIN_DLL( DllMain );
7130# #endif
7131# HINSTANCE __hDllInstance_base;
7132#
7133# BOOL APIENTRY
7134# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
7135# {
7136# __hDllInstance_base = hInst;
7137# return TRUE;
7138# }
7139# /* ltdll.c ends here */
7140])# _LT_AC_FILE_LTDLL_C
7141
7142
7143# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
7144# ---------------------------------
7145AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
7146
7147
7148# old names
7149AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
7150AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
7151AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
7152AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
7153AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
7154AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
7155AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
7156
7157# This is just to silence aclocal about the macro not being used
7158ifelse([AC_DISABLE_FAST_INSTALL])
7159
7160AC_DEFUN([LT_AC_PROG_GCJ],
7161[AC_CHECK_TOOL(GCJ, gcj, no)
7162 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7163 AC_SUBST(GCJFLAGS)
7164])
7165
7166AC_DEFUN([LT_AC_PROG_RC],
7167[AC_CHECK_TOOL(RC, windres, no)
7168])
7169
7170# NOTE: This macro has been submitted for inclusion into #
7171# GNU Autoconf as AC_PROG_SED. When it is available in #
7172# a released version of Autoconf we should remove this #
7173# macro and use it instead. #
7174# LT_AC_PROG_SED
7175# --------------
7176# Check for a fully-functional sed program, that truncates
7177# as few characters as possible. Prefer GNU sed if found.
7178AC_DEFUN([LT_AC_PROG_SED],
7179[AC_MSG_CHECKING([for a sed that does not truncate output])
7180AC_CACHE_VAL(lt_cv_path_SED,
7181[# Loop through the user's path and test for sed and gsed.
7182# Then use that list of sed's as ones to test for truncation.
7183as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7184for as_dir in $PATH
7185do
7186 IFS=$as_save_IFS
7187 test -z "$as_dir" && as_dir=.
7188 for lt_ac_prog in sed gsed; do
7189 for ac_exec_ext in '' $ac_executable_extensions; do
7190 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
7191 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7192 fi
7193 done
7194 done
7195done
7196lt_ac_max=0
7197lt_ac_count=0
7198# Add /usr/xpg4/bin/sed as it is typically found on Solaris
7199# along with /bin/sed that truncates output.
7200for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7201 test ! -f $lt_ac_sed && continue
7202 cat /dev/null > conftest.in
7203 lt_ac_count=0
7204 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7205 # Check for GNU sed and select it if it is found.
7206 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7207 lt_cv_path_SED=$lt_ac_sed
7208 break
7209 fi
7210 while true; do
7211 cat conftest.in conftest.in >conftest.tmp
7212 mv conftest.tmp conftest.in
7213 cp conftest.in conftest.nl
7214 echo >>conftest.nl
7215 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7216 cmp -s conftest.out conftest.nl || break
7217 # 10000 chars as input seems more than enough
7218 test $lt_ac_count -gt 10 && break
7219 lt_ac_count=`expr $lt_ac_count + 1`
7220 if test $lt_ac_count -gt $lt_ac_max; then
7221 lt_ac_max=$lt_ac_count
7222 lt_cv_path_SED=$lt_ac_sed
7223 fi
7224 done
7225done
7226])
7227SED=$lt_cv_path_SED
7228AC_MSG_RESULT([$SED])
7229])
7230
7231# isc-posix.m4 serial 2 (gettext-0.11.2)
7232dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
7233dnl This file is free software; the Free Software Foundation
7234dnl gives unlimited permission to copy and/or distribute it,
7235dnl with or without modifications, as long as this notice is preserved.
7236
7237# This file is not needed with autoconf-2.53 and newer. Remove it in 2005.
7238
7239# This test replaces the one in autoconf.
7240# Currently this macro should have the same name as the autoconf macro
7241# because gettext's gettext.m4 (distributed in the automake package)
7242# still uses it. Otherwise, the use in gettext.m4 makes autoheader
7243# give these diagnostics:
7244# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
7245# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
7246
7247undefine([AC_ISC_POSIX])
7248
7249AC_DEFUN([AC_ISC_POSIX],
7250 [
7251 dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
7252 AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
7253 ]
7254)
7255
7256
7257# Copyright 1996, 1997, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
7258
7259# This program is free software; you can redistribute it and/or modify
7260# it under the terms of the GNU General Public License as published by
7261# the Free Software Foundation; either version 2, or (at your option)
7262# any later version.
7263
7264# This program is distributed in the hope that it will be useful,
7265# but WITHOUT ANY WARRANTY; without even the implied warranty of
7266# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
7267# GNU General Public License for more details.
7268
7269# You should have received a copy of the GNU General Public License
7270# along with this program; if not, write to the Free Software
7271# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
7272# 02111-1307, USA.
7273
7274# serial 2
7275
7276# @defmac AC_PROG_CC_STDC
7277# @maindex PROG_CC_STDC
7278# @ovindex CC
7279# If the C compiler in not in ANSI C mode by default, try to add an option
7280# to output variable @code{CC} to make it so. This macro tries various
7281# options that select ANSI C on some system or another. It considers the
7282# compiler to be in ANSI C mode if it handles function prototypes correctly.
7283#
7284# If you use this macro, you should check after calling it whether the C
7285# compiler has been set to accept ANSI C; if not, the shell variable
7286# @code{am_cv_prog_cc_stdc} is set to @samp{no}. If you wrote your source
7287# code in ANSI C, you can make an un-ANSIfied copy of it by using the
7288# program @code{ansi2knr}, which comes with Ghostscript.
7289# @end defmac
7290
7291AC_DEFUN([AM_PROG_CC_STDC],
7292[AC_REQUIRE([AC_PROG_CC])
7293AC_BEFORE([$0], [AC_C_INLINE])
7294AC_BEFORE([$0], [AC_C_CONST])
7295dnl Force this before AC_PROG_CPP. Some cpp's, eg on HPUX, require
7296dnl a magic option to avoid problems with ANSI preprocessor commands
7297dnl like #elif.
7298dnl FIXME: can't do this because then AC_AIX won't work due to a
7299dnl circular dependency.
7300dnl AC_BEFORE([$0], [AC_PROG_CPP])
7301AC_MSG_CHECKING([for ${CC-cc} option to accept ANSI C])
7302AC_CACHE_VAL(am_cv_prog_cc_stdc,
7303[am_cv_prog_cc_stdc=no
7304ac_save_CC="$CC"
7305# Don't try gcc -ansi; that turns off useful extensions and
7306# breaks some systems' header files.
7307# AIX -qlanglvl=ansi
7308# Ultrix and OSF/1 -std1
7309# HP-UX 10.20 and later -Ae
7310# HP-UX older versions -Aa -D_HPUX_SOURCE
7311# SVR4 -Xc -D__EXTENSIONS__
7312for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7313do
7314 CC="$ac_save_CC $ac_arg"
7315 AC_TRY_COMPILE(
7316[#include <stdarg.h>
7317#include <stdio.h>
7318#include <sys/types.h>
7319#include <sys/stat.h>
7320/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7321struct buf { int x; };
7322FILE * (*rcsopen) (struct buf *, struct stat *, int);
7323static char *e (p, i)
7324 char **p;
7325 int i;
7326{
7327 return p[i];
7328}
7329static char *f (char * (*g) (char **, int), char **p, ...)
7330{
7331 char *s;
7332 va_list v;
7333 va_start (v,p);
7334 s = g (p, va_arg (v,int));
7335 va_end (v);
7336 return s;
7337}
7338int test (int i, double x);
7339struct s1 {int (*f) (int a);};
7340struct s2 {int (*f) (double a);};
7341int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7342int argc;
7343char **argv;
7344], [
7345return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7346],
7347[am_cv_prog_cc_stdc="$ac_arg"; break])
7348done
7349CC="$ac_save_CC"
7350])
7351if test -z "$am_cv_prog_cc_stdc"; then
7352 AC_MSG_RESULT([none needed])
7353else
7354 AC_MSG_RESULT([$am_cv_prog_cc_stdc])
7355fi
7356case "x$am_cv_prog_cc_stdc" in
7357 x|xno) ;;
7358 *) CC="$CC $am_cv_prog_cc_stdc" ;;
7359esac
7360])
7361
7362AU_DEFUN([fp_PROG_CC_STDC], [AM_PROG_CC_STDC])
7363
This page took 0.278793 seconds and 4 git commands to generate.