106
297
AC_MSG_ERROR([newly created file is older than distributed files!
107
298
Check your system clock])
110
300
AC_MSG_RESULT(yes)])
112
dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
113
dnl The program must properly implement --version.
305
# Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
307
# This program is free software; you can redistribute it and/or modify
308
# it under the terms of the GNU General Public License as published by
309
# the Free Software Foundation; either version 2, or (at your option)
312
# This program is distributed in the hope that it will be useful,
313
# but WITHOUT ANY WARRANTY; without even the implied warranty of
314
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
315
# GNU General Public License for more details.
317
# You should have received a copy of the GNU General Public License
318
# along with this program; if not, write to the Free Software
319
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
324
# AM_MISSING_PROG(NAME, PROGRAM)
325
# ------------------------------
114
326
AC_DEFUN([AM_MISSING_PROG],
115
[AC_MSG_CHECKING(for working $2)
116
# Run test in a subshell; some versions of sh will print an error if
117
# an executable is not found, even if stderr is redirected.
118
# Redirect stdin to placate older versions of autoconf. Sigh.
119
if ($2 --version) < /dev/null > /dev/null 2>&1; then
124
AC_MSG_RESULT(missing)
327
[AC_REQUIRE([AM_MISSING_HAS_RUN])
328
$1=${$1-"${am_missing_run}$2"}
334
# Define MISSING if not defined so far and test if it supports --run.
335
# If it does, set am_missing_run to use it, otherwise, to nothing.
336
AC_DEFUN([AM_MISSING_HAS_RUN],
337
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
338
test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
339
# Use eval to expand $SHELL
340
if eval "$MISSING --run true"; then
341
am_missing_run="$MISSING --run "
344
AC_MSG_WARN([`missing' script is too old or missing])
350
# Copyright 2001 Free Software Foundation, Inc.
352
# This program is free software; you can redistribute it and/or modify
353
# it under the terms of the GNU General Public License as published by
354
# the Free Software Foundation; either version 2, or (at your option)
357
# This program is distributed in the hope that it will be useful,
358
# but WITHOUT ANY WARRANTY; without even the implied warranty of
359
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
360
# GNU General Public License for more details.
362
# You should have received a copy of the GNU General Public License
363
# along with this program; if not, write to the Free Software
364
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
367
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
368
# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
369
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
371
# Of course, Automake must honor this variable whenever it calls a
372
# tool from the auxiliary directory. The problem is that $srcdir (and
373
# therefore $ac_aux_dir as well) can be either absolute or relative,
374
# depending on how configure is run. This is pretty annoying, since
375
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
376
# source directory, any form will work fine, but in subdirectories a
377
# relative path needs to be adjusted first.
379
# $ac_aux_dir/missing
380
# fails when called from a subdirectory if $ac_aux_dir is relative
381
# $top_srcdir/$ac_aux_dir/missing
382
# fails if $ac_aux_dir is absolute,
383
# fails when called from a subdirectory in a VPATH build with
384
# a relative $ac_aux_dir
386
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
387
# are both prefixed by $srcdir. In an in-source build this is usually
388
# harmless because $srcdir is `.', but things will broke when you
389
# start a VPATH build or use an absolute $srcdir.
391
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
392
# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
393
# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
394
# and then we would define $MISSING as
395
# MISSING="\${SHELL} $am_aux_dir/missing"
396
# This will work as long as MISSING is not called from configure, because
397
# unfortunately $(top_srcdir) has no meaning in configure.
398
# However there are other variables, like CC, which are often used in
399
# configure, and could therefore not use this "fixed" $ac_aux_dir.
401
# Another solution, used here, is to always expand $ac_aux_dir to an
402
# absolute PATH. The drawback is that using absolute paths prevent a
403
# configured tree to be moved without reconfiguration.
405
# Rely on autoconf to set up CDPATH properly.
408
AC_DEFUN([AM_AUX_DIR_EXPAND], [
409
# expand $ac_aux_dir to an absolute path
410
am_aux_dir=`cd $ac_aux_dir && pwd`
415
# Define $install_sh.
417
# Copyright 2001 Free Software Foundation, Inc.
419
# This program is free software; you can redistribute it and/or modify
420
# it under the terms of the GNU General Public License as published by
421
# the Free Software Foundation; either version 2, or (at your option)
424
# This program is distributed in the hope that it will be useful,
425
# but WITHOUT ANY WARRANTY; without even the implied warranty of
426
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
427
# GNU General Public License for more details.
429
# You should have received a copy of the GNU General Public License
430
# along with this program; if not, write to the Free Software
431
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
434
AC_DEFUN([AM_PROG_INSTALL_SH],
435
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
436
install_sh=${install_sh-"$am_aux_dir/install-sh"}
437
AC_SUBST(install_sh)])
439
# AM_PROG_INSTALL_STRIP
441
# Copyright 2001 Free Software Foundation, Inc.
443
# This program is free software; you can redistribute it and/or modify
444
# it under the terms of the GNU General Public License as published by
445
# the Free Software Foundation; either version 2, or (at your option)
448
# This program is distributed in the hope that it will be useful,
449
# but WITHOUT ANY WARRANTY; without even the implied warranty of
450
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
451
# GNU General Public License for more details.
453
# You should have received a copy of the GNU General Public License
454
# along with this program; if not, write to the Free Software
455
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
458
# One issue with vendor `install' (even GNU) is that you can't
459
# specify the program used to strip binaries. This is especially
460
# annoying in cross-compiling environments, where the build's strip
461
# is unlikely to handle the host's binaries.
462
# Fortunately install-sh will honor a STRIPPROG variable, so we
463
# always use install-sh in `make install-strip', and initialize
464
# STRIPPROG with the value of the STRIP variable (set by the user).
465
AC_DEFUN([AM_PROG_INSTALL_STRIP],
466
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
467
# Installed binaries are usually stripped using `strip' when the user
468
# run `make install-strip'. However `strip' might not be the right
469
# tool to use in cross-compilation environments, therefore Automake
470
# will honor the `STRIP' environment variable to overrule this program.
471
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
472
if test "$cross_compiling" != no; then
473
AC_CHECK_TOOL([STRIP], [strip], :)
475
INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
476
AC_SUBST([INSTALL_STRIP_PROGRAM])])
479
# Copyright (C) 2003 Free Software Foundation, Inc.
481
# This program is free software; you can redistribute it and/or modify
482
# it under the terms of the GNU General Public License as published by
483
# the Free Software Foundation; either version 2, or (at your option)
486
# This program is distributed in the hope that it will be useful,
487
# but WITHOUT ANY WARRANTY; without even the implied warranty of
488
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
489
# GNU General Public License for more details.
491
# You should have received a copy of the GNU General Public License
492
# along with this program; if not, write to the Free Software
493
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
498
# Check whether the underlying file-system supports filenames
499
# with a leading dot. For instance MS-DOS doesn't.
500
AC_DEFUN([AM_SET_LEADING_DOT],
501
[rm -rf .tst 2>/dev/null
502
mkdir .tst 2>/dev/null
503
if test -d .tst; then
508
rmdir .tst 2>/dev/null
509
AC_SUBST([am__leading_dot])])
511
# serial 5 -*- Autoconf -*-
513
# Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
515
# This program is free software; you can redistribute it and/or modify
516
# it under the terms of the GNU General Public License as published by
517
# the Free Software Foundation; either version 2, or (at your option)
520
# This program is distributed in the hope that it will be useful,
521
# but WITHOUT ANY WARRANTY; without even the implied warranty of
522
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
523
# GNU General Public License for more details.
525
# You should have received a copy of the GNU General Public License
526
# along with this program; if not, write to the Free Software
527
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
531
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
532
# written in clear, in which case automake, when reading aclocal.m4,
533
# will think it sees a *use*, and therefore will trigger all it's
534
# C support machinery. Also note that it means that autoscan, seeing
535
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
539
# _AM_DEPENDENCIES(NAME)
540
# ----------------------
541
# See how the compiler implements dependency checking.
542
# NAME is "CC", "CXX", "GCJ", or "OBJC".
543
# We try a few techniques and use that to set a single cache variable.
545
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
546
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
547
# dependency, and given that the user is not expected to run this macro,
548
# just rely on AC_PROG_CC.
549
AC_DEFUN([_AM_DEPENDENCIES],
550
[AC_REQUIRE([AM_SET_DEPDIR])dnl
551
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
552
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
553
AC_REQUIRE([AM_DEP_TRACK])dnl
555
ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
556
[$1], CXX, [depcc="$CXX" am_compiler_list=],
557
[$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
558
[$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
559
[depcc="$$1" am_compiler_list=])
561
AC_CACHE_CHECK([dependency style of $depcc],
562
[am_cv_$1_dependencies_compiler_type],
563
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
564
# We make a subdir and do the tests there. Otherwise we can end up
565
# making bogus files that we don't know about and never remove. For
566
# instance it was reported that on HP-UX the gcc test will end up
567
# making a dummy file named `D' -- because `-MD' means `put the output
570
# Copy depcomp to subdir because otherwise we won't find it if we're
571
# using a relative directory.
572
cp "$am_depcomp" conftest.dir
574
# We will build objects and dependencies in a subdirectory because
575
# it helps to detect inapplicable dependency modes. For instance
576
# both Tru64's cc and ICC support -MD to output dependencies as a
577
# side effect of compilation, but ICC will put the dependencies in
578
# the current directory while Tru64 will put them in the object
582
am_cv_$1_dependencies_compiler_type=none
583
if test "$am_compiler_list" = ""; then
584
am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
586
for depmode in $am_compiler_list; do
587
# Setup a source with many dependencies, because some compilers
588
# like to wrap large dependency lists on column 80 (with \), and
589
# we should not choose a depcomp mode which is confused by this.
591
# We need to recreate these files for each test, as the compiler may
592
# overwrite some of them when testing with obscure command lines.
593
# This happens at least with the AIX C compiler.
595
for i in 1 2 3 4 5 6; do
596
echo '#include "conftst'$i'.h"' >> sub/conftest.c
599
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
603
# after this tag, mechanisms are not by side-effect, so they'll
604
# only be used when explicitly requested
605
if test "x$enable_dependency_tracking" = xyes; then
613
# We check with `-c' and `-o' for the sake of the "dashmstdout"
614
# mode. It turns out that the SunPro C++ compiler does not properly
615
# handle `-M -o', and we need to detect this.
616
if depmode=$depmode \
617
source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
618
depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
619
$SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
620
>/dev/null 2>conftest.err &&
621
grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
622
grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
623
${MAKE-make} -s -f confmf > /dev/null 2>&1; then
624
# icc doesn't choke on unknown options, it will just issue warnings
625
# (even with -Werror). So we grep stderr for any message
626
# that says an option was ignored.
627
if grep 'ignoring option' conftest.err >/dev/null 2>&1; then :; else
628
am_cv_$1_dependencies_compiler_type=$depmode
637
am_cv_$1_dependencies_compiler_type=none
640
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
641
AM_CONDITIONAL([am__fastdep$1], [
642
test "x$enable_dependency_tracking" != xno \
643
&& test "$am_cv_$1_dependencies_compiler_type" = gcc3])
649
# Choose a directory name for dependency files.
650
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
651
AC_DEFUN([AM_SET_DEPDIR],
652
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
653
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
659
AC_DEFUN([AM_DEP_TRACK],
660
[AC_ARG_ENABLE(dependency-tracking,
661
[ --disable-dependency-tracking Speeds up one-time builds
662
--enable-dependency-tracking Do not reject slow dependency extractors])
663
if test "x$enable_dependency_tracking" != xno; then
664
am_depcomp="$ac_aux_dir/depcomp"
667
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
668
AC_SUBST([AMDEPBACKSLASH])
671
# Generate code to set up dependency tracking. -*- Autoconf -*-
673
# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
675
# This program is free software; you can redistribute it and/or modify
676
# it under the terms of the GNU General Public License as published by
677
# the Free Software Foundation; either version 2, or (at your option)
680
# This program is distributed in the hope that it will be useful,
681
# but WITHOUT ANY WARRANTY; without even the implied warranty of
682
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
683
# GNU General Public License for more details.
685
# You should have received a copy of the GNU General Public License
686
# along with this program; if not, write to the Free Software
687
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
692
# _AM_OUTPUT_DEPENDENCY_COMMANDS
693
# ------------------------------
694
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
695
[for mf in $CONFIG_FILES; do
696
# Strip MF so we end up with the name of the file.
697
mf=`echo "$mf" | sed -e 's/:.*$//'`
698
# Check whether this is an Automake generated Makefile or not.
699
# We used to match only the files named `Makefile.in', but
700
# some people rename them; so instead we look at the file content.
701
# Grep'ing the first line is not enough: some people post-process
702
# each Makefile.in and add a new line on top of each file to say so.
703
# So let's grep whole file.
704
if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
705
dirpart=`AS_DIRNAME("$mf")`
709
grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
710
# Extract the definition of DEP_FILES from the Makefile without
712
DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
713
test -z "$DEPDIR" && continue
714
# When using ansi2knr, U may be empty or an underscore; expand it
715
U=`sed -n -e '/^U = / s///p' < "$mf"`
716
test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
717
# We invoke sed twice because it is the simplest approach to
718
# changing $(DEPDIR) to its actual value in the expansion.
719
for file in `sed -n -e '
720
/^DEP_FILES = .*\\\\$/ {
729
/^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
730
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
731
# Make sure the directory exists.
732
test -f "$dirpart/$file" && continue
733
fdir=`AS_DIRNAME(["$file"])`
734
AS_MKDIR_P([$dirpart/$fdir])
735
# echo "creating $dirpart/$file"
736
echo '# dummy' > "$dirpart/$file"
739
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
742
# AM_OUTPUT_DEPENDENCY_COMMANDS
743
# -----------------------------
744
# This macro should only be invoked once -- use via AC_REQUIRE.
746
# This code is only required when automatic dependency tracking
747
# is enabled. FIXME. This creates each `.P' file that we will
748
# need in order to bootstrap the dependency handling code.
749
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
750
[AC_CONFIG_COMMANDS([depfiles],
751
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
752
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
755
# Check to see how 'make' treats includes. -*- Autoconf -*-
757
# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
759
# This program is free software; you can redistribute it and/or modify
760
# it under the terms of the GNU General Public License as published by
761
# the Free Software Foundation; either version 2, or (at your option)
764
# This program is distributed in the hope that it will be useful,
765
# but WITHOUT ANY WARRANTY; without even the implied warranty of
766
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
767
# GNU General Public License for more details.
769
# You should have received a copy of the GNU General Public License
770
# along with this program; if not, write to the Free Software
771
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
778
# Check to see how make treats includes.
779
AC_DEFUN([AM_MAKE_INCLUDE],
780
[am_make=${MAKE-make}
781
cat > confinc << 'END'
786
# If we don't find an include directive, just comment out the code.
787
AC_MSG_CHECKING([for style of include used by $am_make])
791
# First try GNU make style include.
792
echo "include confinc" > confmf
793
# We grep out `Entering directory' and `Leaving directory'
794
# messages which can occur if `w' ends up in MAKEFLAGS.
795
# In particular we don't look at `^make:' because GNU make might
796
# be invoked under some other name (usually "gmake"), in which
797
# case it prints its new name instead of `make'.
798
if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
803
# Now try BSD make style include.
804
if test "$am__include" = "#"; then
805
echo '.include "confinc"' > confmf
806
if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
812
AC_SUBST([am__include])
813
AC_SUBST([am__quote])
814
AC_MSG_RESULT([$_am_result])
818
# AM_CONDITIONAL -*- Autoconf -*-
820
# Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
822
# This program is free software; you can redistribute it and/or modify
823
# it under the terms of the GNU General Public License as published by
824
# the Free Software Foundation; either version 2, or (at your option)
827
# This program is distributed in the hope that it will be useful,
828
# but WITHOUT ANY WARRANTY; without even the implied warranty of
829
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
830
# GNU General Public License for more details.
832
# You should have received a copy of the GNU General Public License
833
# along with this program; if not, write to the Free Software
834
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
841
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
842
# -------------------------------------
843
# Define a conditional.
844
AC_DEFUN([AM_CONDITIONAL],
845
[ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
846
[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
856
AC_CONFIG_COMMANDS_PRE(
857
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
858
AC_MSG_ERROR([conditional "$1" was never defined.
859
Usually this means the macro was only invoked conditionally.])
128
862
# Add --enable-maintainer-mode option to configure.
129
863
# From Jim Meyering
865
# Copyright 1996, 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
867
# This program is free software; you can redistribute it and/or modify
868
# it under the terms of the GNU General Public License as published by
869
# the Free Software Foundation; either version 2, or (at your option)
872
# This program is distributed in the hope that it will be useful,
873
# but WITHOUT ANY WARRANTY; without even the implied warranty of
874
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
875
# GNU General Public License for more details.
877
# You should have received a copy of the GNU General Public License
878
# along with this program; if not, write to the Free Software
879
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
133
884
AC_DEFUN([AM_MAINTAINER_MODE],
134
885
[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
1357
2125
ln conftest.a conftest.b 2>/dev/null && hard_links=no
1358
2126
AC_MSG_RESULT([$hard_links])
1359
2127
if test "$hard_links" = no; then
1360
AC_MSG_WARN([\`$CC' does not support \`-c -o', so \`make -j' may be unsafe])
2128
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1361
2129
need_locks=warn
1367
if test "$GCC" = yes; then
1368
# Check to see if options -fno-rtti -fno-exceptions are supported by compiler
1369
AC_MSG_CHECKING([if $compiler supports -fno-rtti -fno-exceptions])
1370
echo "int some_variable = 0;" > conftest.$ac_ext
1371
save_CFLAGS="$CFLAGS"
1372
CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.$ac_ext"
1373
compiler_rtti_exceptions=no
1374
AC_TRY_COMPILE([], [int some_variable = 0;], [dnl
1375
# The compiler can only warn and ignore the option if not recognized
1376
# So say no if there are warnings
1377
if test -s conftest.err; then
1378
compiler_rtti_exceptions=no
1380
compiler_rtti_exceptions=yes
1383
CFLAGS="$save_CFLAGS"
1384
AC_MSG_RESULT([$compiler_rtti_exceptions])
1386
if test "$compiler_rtti_exceptions" = "yes"; then
1387
no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions'
1389
no_builtin_flag=' -fno-builtin'
1393
# See if the linker supports building shared libraries.
1394
AC_MSG_CHECKING([whether the linker ($LD) supports shared libraries])
1396
allow_undefined_flag=
1398
need_lib_prefix=unknown
1399
need_version=unknown
1400
# when you set need_version to no, make sure it does not cause -set_version
1401
# flags to be left without arguments
1403
archive_expsym_cmds=
1404
old_archive_from_new_cmds=
1405
old_archive_from_expsyms_cmds=
1406
export_dynamic_flag_spec=
1407
whole_archive_flag_spec=
1408
thread_safe_flag_spec=
1409
hardcode_into_libs=no
1410
hardcode_libdir_flag_spec=
1411
hardcode_libdir_separator=
1414
hardcode_shlibpath_var=unsupported
1416
link_all_deplibs=unknown
1417
always_export_symbols=no
1418
export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
1419
# include_expsyms should be a list of space-separated symbols to be *always*
1420
# included in the symbol list
1422
# exclude_expsyms can be an egrep regular expression of symbols to exclude
1423
# it will be wrapped by ` (' and `)$', so one must not match beginning or
1424
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
1425
# as well as any symbol that contains `d'.
1426
exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
1427
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
1428
# platforms (ab)use it in PIC code, but their linkers get confused if
1429
# the symbol is explicitly referenced. Since portable code cannot
1430
# rely on this symbol name, it's probably fine to never include it in
1431
# preloaded symbol tables.
1432
extract_expsyms_cmds=
1435
cygwin* | mingw* | pw32* )
1436
# FIXME: the MSVC++ port hasn't been tested in a loooong time
1437
# When not using gcc, we currently assume that we are using
1438
# Microsoft Visual C++.
1439
if test "$GCC" != yes; then
1447
if test "$with_gnu_ld" = yes; then
1448
# If archive_cmds runs LD, not CC, wlarc should be empty
1451
# See if GNU ld supports shared libraries.
1453
aix3* | aix4* | aix5*)
1454
# On AIX, the GNU linker is very broken
1455
# Note:Check GNU linker on AIX 5-IA64 when/if it becomes available.
1459
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
1460
*** to be unable to reliably create shared libraries on AIX.
1461
*** Therefore, libtool is disabling shared libraries support. If you
1462
*** really care for shared libraries, you may want to modify your PATH
1463
*** so that a non-GNU linker is found, and then restart.
1469
archive_cmds='$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)'
1470
hardcode_libdir_flag_spec='-L$libdir'
1471
hardcode_minus_L=yes
1473
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
1474
# that the semantics of dynamic libraries on AmigaOS, at least up
1475
# to version 4, is to share data among multiple programs linked
1476
# with the same dynamic library. Since this doesn't match the
1477
# behavior of shared libraries on other platforms, we can use
1483
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
1484
allow_undefined_flag=unsupported
1485
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
1486
# support --undefined. This deserves some investigation. FIXME
1487
archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
1493
cygwin* | mingw* | pw32*)
1494
# hardcode_libdir_flag_spec is actually meaningless, as there is
1495
# no search path for DLLs.
1496
hardcode_libdir_flag_spec='-L$libdir'
1497
allow_undefined_flag=unsupported
1498
always_export_symbols=yes
1500
extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
1501
sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
1502
test -f $output_objdir/impgen.exe || (cd $output_objdir && \
1503
if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
1504
else $CC -o impgen impgen.c ; fi)~
1505
$output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
1507
old_archive_from_expsyms_cmds='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
1509
# cygwin and mingw dlls have different entry points and sets of symbols
1511
# FIXME: what about values for MSVC?
1512
dll_entry=__cygwin_dll_entry@12
1513
dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
1517
dll_entry=_DllMainCRTStartup@12
1518
dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
1522
# mingw and cygwin differ, and it's simplest to just exclude the union
1523
# of the two symbol sets.
1524
dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
1526
# recent cygwin and mingw systems supply a stub DllMain which the user
1527
# can override, but on older systems we have to supply one (in ltdll.c)
1528
if test "x$lt_cv_need_dllmain" = "xyes"; then
1529
ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
1530
ltdll_cmds='test -f $output_objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < [$]0 > $output_objdir/$soname-ltdll.c~
1531
test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
1537
# Extract the symbol export list from an `--export-all' def file,
1538
# then regenerate the def file from the symbol export list, so that
1539
# the compiled dll only exports the symbol export list.
1540
# Be careful not to strip the DATA tag left be newer dlltools.
1541
export_symbols_cmds="$ltdll_cmds"'
1542
$DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
1543
[sed -e "1,/EXPORTS/d" -e "s/ @ [0-9]*//" -e "s/ *;.*$//"] < $output_objdir/$soname-def > $export_symbols'
1545
# If the export-symbols file already is a .def file (1st line
1546
# is EXPORTS), use it as is.
1547
# If DATA tags from a recent dlltool are present, honour them!
1548
archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
1549
cp $export_symbols $output_objdir/$soname-def;
1551
echo EXPORTS > $output_objdir/$soname-def;
1553
cat $export_symbols | while read symbol; do
1556
2) echo " \[$]2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
1557
*) echo " \[$]2 @ \$_lt_hint \[$]3 ; " >> $output_objdir/$soname-def;;
1559
_lt_hint=`expr 1 + \$_lt_hint`;
1563
$CC -Wl,--base-file,$output_objdir/$soname-base '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
1564
$DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp~
1565
$CC -Wl,--base-file,$output_objdir/$soname-base $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
1566
$DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp --output-lib $output_objdir/$libname.dll.a~
1567
$CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
1571
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
1572
archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
1575
archive_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
1576
archive_expsym_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1581
if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
1585
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
1586
*** create shared libraries on Solaris systems. Therefore, libtool
1587
*** is disabling shared libraries support. We urge you to upgrade GNU
1588
*** binutils to release 2.9.1 or newer. Another option is to modify
1589
*** your PATH or compiler configuration so that the native linker is
1590
*** used, and then restart.
1593
elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
1594
archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
1595
archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1602
archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
1605
hardcode_shlibpath_var=no
1609
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
1610
archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
1611
archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
1618
if test "$ld_shlibs" = yes; then
1619
runpath_var=LD_RUN_PATH
1620
hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
1621
export_dynamic_flag_spec='${wl}--export-dynamic'
1623
cygwin* | mingw* | pw32*)
1624
# dlltool doesn't understand --whole-archive et. al.
1625
whole_archive_flag_spec=
1628
# ancient GNU ld didn't support --whole-archive et. al.
1629
if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
1630
whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
1632
whole_archive_flag_spec=
2134
])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
2139
AC_DEFUN([AC_LIBTOOL_OBJDIR],
2140
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2141
[rm -f .libs 2>/dev/null
2142
mkdir .libs 2>/dev/null
2143
if test -d .libs; then
1638
# PORTME fill in a description of your system's linker (not GNU ld)
1641
allow_undefined_flag=unsupported
1642
always_export_symbols=yes
1643
archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
1644
# Note: this linker hardcodes the directories in LIBPATH if there
1645
# are no directories specified by -L.
1646
hardcode_minus_L=yes
1647
if test "$GCC" = yes && test -z "$link_static_flag"; then
1648
# Neither direct hardcoding nor static linking is supported with a
1650
hardcode_direct=unsupported
1655
# When large executables or shared objects are built, AIX ld can
1656
# have problems creating the table of contents. If linking a library
1657
# or program results in "error TOC overflow" add -mminimal-toc to
1658
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
1659
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
1662
hardcode_libdir_separator=':'
1663
if test "$GCC" = yes; then
1664
collect2name=`${CC} -print-prog-name=collect2`
1665
if test -f "$collect2name" && \
1666
strings "$collect2name" | grep resolve_lib_name >/dev/null
1668
# We have reworked collect2
1671
# We have old collect2
1672
hardcode_direct=unsupported
1673
# It fails to find uninstalled libraries when the uninstalled
1674
# path is not listed in the libpath. Setting hardcode_minus_L
1675
# to unsupported forces relinking
1676
hardcode_minus_L=yes
1677
hardcode_libdir_flag_spec='-L$libdir'
1678
hardcode_libdir_separator=
1680
shared_flag='-shared'
1682
if test "$host_cpu" = ia64; then
1685
shared_flag='${wl}-bM:SRE'
1690
if test "$host_cpu" = ia64; then
1691
# On IA64, the linker does run time linking by default, so we don't
1692
# have to do anything special.
1693
aix_use_runtimelinking=no
1694
exp_sym_flag='-Bexport'
1697
# Test if we are trying to use run time linking, or normal AIX style linking.
1698
# If -brtl is somewhere in LDFLAGS, we need to do run time linking.
1699
aix_use_runtimelinking=no
1700
for ld_flag in $LDFLAGS; do
1701
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl" ); then
1702
aix_use_runtimelinking=yes
1706
exp_sym_flag='-bexport'
1707
no_entry_flag='-bnoentry'
1709
# It seems that -bexpall can do strange things, so it is better to
1710
# generate a list of symbols to export.
1711
always_export_symbols=yes
1712
if test "$aix_use_runtimelinking" = yes; then
1713
hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
1714
allow_undefined_flag=' -Wl,-G'
1715
archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
1717
if test "$host_cpu" = ia64; then
1718
hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
1719
allow_undefined_flag="-znodefs"
1720
archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname ${wl}-h$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
1722
hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
1723
# Warning - without using the other run time loading flags, -berok will
1724
# link without error, but may produce a broken library.
1725
allow_undefined_flag='${wl}-berok"
1726
# This is a bit strange, but is similar to how AIX traditionally builds
1727
# it's shared libraries.
1728
archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"' ~$AR -crlo $objdir/$libname$release.a $objdir/$soname'
1734
archive_cmds='$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)'
1735
hardcode_libdir_flag_spec='-L$libdir'
1736
hardcode_minus_L=yes
1737
# see comment about different semantics on the GNU ld section
1741
cygwin* | mingw* | pw32*)
1742
# When not using gcc, we currently assume that we are using
1743
# Microsoft Visual C++.
1744
# hardcode_libdir_flag_spec is actually meaningless, as there is
1745
# no search path for DLLs.
1746
hardcode_libdir_flag_spec=' '
1747
allow_undefined_flag=unsupported
1748
# Tell ltmain to make .lib files, not .a files.
1750
# FIXME: Setting linknames here is a bad hack.
1751
archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
1752
# The linker will automatically build a .lib file if we build a DLL.
1753
old_archive_from_new_cmds='true'
1754
# FIXME: Should let the user specify the lib program.
1755
old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
1756
fix_srcfile_path='`cygpath -w "$srcfile"`'
1759
darwin* | rhapsody*)
1760
allow_undefined_flag='-undefined suppress'
1761
# FIXME: Relying on posixy $() will cause problems for
1762
# cross-compilation, but unfortunately the echo tests do not
1763
# yet detect zsh echo's removal of \ escapes.
1764
archive_cmds='$CC $(test .$module = .yes && echo -bundle || echo -dynamiclib) $allow_undefined_flag -o $lib $libobjs $deplibs$linkopts -install_name $rpath/$soname $(test -n "$verstring" -a x$verstring != x0.0 && echo $verstring)'
1765
# We need to add '_' to the symbols in $export_symbols first
1766
#archive_expsym_cmds="$archive_cmds"' && strip -s $export_symbols'
1768
hardcode_shlibpath_var=no
1769
whole_archive_flag_spec='-all_load $convenience'
1776
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
1777
# support. Future versions do this automatically, but an explicit c++rt0.o
1778
# does not break anything, and helps significantly (at the cost of a little
1781
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
1782
hardcode_libdir_flag_spec='-R$libdir'
1784
hardcode_shlibpath_var=no
1787
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
1789
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
1791
hardcode_minus_L=yes
1792
hardcode_shlibpath_var=no
1795
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
1797
archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
1798
hardcode_libdir_flag_spec='-R$libdir'
1800
hardcode_shlibpath_var=no
1803
hpux9* | hpux10* | hpux11*)
1805
hpux9*) archive_cmds='$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' ;;
1806
*) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
1808
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
1809
hardcode_libdir_separator=:
1811
hardcode_minus_L=yes # Not in the search PATH, but as the default
1812
# location of the library.
1813
export_dynamic_flag_spec='${wl}-E'
1817
if test "$GCC" = yes; then
1818
archive_cmds='$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'
1820
archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
1822
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1823
hardcode_libdir_separator=:
1824
link_all_deplibs=yes
1828
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
1829
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
1831
archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
1833
hardcode_libdir_flag_spec='-R$libdir'
1835
hardcode_shlibpath_var=no
1839
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts'
1841
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1842
hardcode_libdir_separator=:
1843
hardcode_shlibpath_var=no
1847
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
1848
hardcode_libdir_flag_spec='-R$libdir'
1850
hardcode_shlibpath_var=no
1854
hardcode_libdir_flag_spec='-L$libdir'
1855
hardcode_minus_L=yes
1856
allow_undefined_flag=unsupported
1857
archive_cmds='$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'
1858
old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
1862
if test "$GCC" = yes; then
1863
allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
1864
archive_cmds='$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'
1866
allow_undefined_flag=' -expect_unresolved \*'
1867
archive_cmds='$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'
1869
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1870
hardcode_libdir_separator=:
1873
osf4* | osf5*) # as osf3* with the addition of -msym flag
1874
if test "$GCC" = yes; then
1875
allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
1876
archive_cmds='$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'
1877
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
1879
allow_undefined_flag=' -expect_unresolved \*'
1880
archive_cmds='$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'
1881
archive_expsym_cmds='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
1882
$LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
1884
#Both c and cxx compiler support -rpath directly
1885
hardcode_libdir_flag_spec='-rpath $libdir'
1887
hardcode_libdir_separator=:
1891
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1892
hardcode_shlibpath_var=no
1893
runpath_var=LD_RUN_PATH
1894
hardcode_runpath_var=yes
1898
no_undefined_flag=' -z defs'
1899
# $CC -shared without GNU ld will not create a library from C++
1900
# object files and a static libstdc++, better avoid it by now
1901
archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
1902
archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
1903
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
1904
hardcode_libdir_flag_spec='-R$libdir'
1905
hardcode_shlibpath_var=no
1907
[solaris2.[0-5] | solaris2.[0-5].*]) ;;
1908
*) # Supported since Solaris 2.6 (maybe 2.5.1?)
1909
whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
1911
link_all_deplibs=yes
1915
if test "x$host_vendor" = xsequent; then
1916
# Use $CC to link under sequent, because it throws in some extra .o
1917
# files that make .init and .fini sections work.
1918
archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
1920
archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
1922
hardcode_libdir_flag_spec='-L$libdir'
1924
hardcode_minus_L=yes
1925
hardcode_shlibpath_var=no
1929
if test "x$host_vendor" = xsno; then
1930
archive_cmds='$LD -G -Bsymbolic -h $soname -o $lib $libobjs $deplibs $linkopts'
1931
hardcode_direct=yes # is this really true???
1933
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1934
hardcode_direct=no #Motorola manual says yes, but my tests say they lie
1936
runpath_var='LD_RUN_PATH'
1937
hardcode_shlibpath_var=no
1941
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1942
hardcode_shlibpath_var=no
1943
export_dynamic_flag_spec='-Bexport'
1947
no_undefined_flag=' -z text'
1948
# $CC -shared without GNU ld will not create a library from C++
1949
# object files and a static libstdc++, better avoid it by now
1950
archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
1951
archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
1952
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
1953
hardcode_libdir_flag_spec=
1954
hardcode_shlibpath_var=no
1955
runpath_var='LD_RUN_PATH'
1959
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1960
hardcode_libdir_flag_spec='-L$libdir'
1961
hardcode_shlibpath_var=no
1965
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1966
hardcode_libdir_flag_spec='-L$libdir'
1967
hardcode_shlibpath_var=no
1971
if test -d /usr/nec; then
1972
archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1973
hardcode_shlibpath_var=no
1974
runpath_var=LD_RUN_PATH
1975
hardcode_runpath_var=yes
1981
archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
1984
hardcode_shlibpath_var=no
1985
hardcode_runpath_var=yes
1986
runpath_var=LD_RUN_PATH
1989
sysv5uw7* | unixware7*)
1990
no_undefined_flag='${wl}-z ${wl}text'
1991
if test "$GCC" = yes; then
1992
archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
1994
archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
1996
runpath_var='LD_RUN_PATH'
1997
hardcode_shlibpath_var=no
2146
# MS-DOS does not allow filenames that begin with a dot.
2005
AC_MSG_RESULT([$ld_shlibs])
2006
test "$ld_shlibs" = no && can_build_shared=no
2149
rmdir .libs 2>/dev/null])
2150
objdir=$lt_cv_objdir
2151
])# AC_LIBTOOL_OBJDIR
2154
# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
2155
# ----------------------------------------------
2008
2156
# Check hardcoding attributes.
2009
AC_MSG_CHECKING([how to hardcode library paths into programs])
2011
if test -n "$hardcode_libdir_flag_spec" || \
2012
test -n "$runpath_var"; then
2157
AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
2158
[AC_MSG_CHECKING([how to hardcode library paths into programs])
2159
_LT_AC_TAGVAR(hardcode_action, $1)=
2160
if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
2161
test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
2162
test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2014
2164
# We can hardcode non-existant directories.
2015
if test "$hardcode_direct" != no &&
2165
if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
2016
2166
# If the only mechanism to avoid hardcoding is shlibpath_var, we
2017
2167
# have to relink, otherwise we might link with an installed library
2018
2168
# when we should be linking with a yet-to-be-installed one
2019
## test "$hardcode_shlibpath_var" != no &&
2020
test "$hardcode_minus_L" != no; then
2169
## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2170
test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
2021
2171
# Linking always hardcodes the temporary library directory.
2022
hardcode_action=relink
2172
_LT_AC_TAGVAR(hardcode_action, $1)=relink
2024
2174
# We can link without hardcoding, and we can hardcode nonexisting dirs.
2025
hardcode_action=immediate
2175
_LT_AC_TAGVAR(hardcode_action, $1)=immediate
2028
2178
# We cannot hardcode anything, or else we can only hardcode existing
2030
hardcode_action=unsupported
2032
AC_MSG_RESULT([$hardcode_action])
2180
_LT_AC_TAGVAR(hardcode_action, $1)=unsupported
2182
AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
2184
if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
2185
# Fast installation is not supported
2186
enable_fast_install=no
2187
elif test "$shlibpath_overrides_runpath" = yes ||
2188
test "$enable_shared" = no; then
2189
# Fast installation is not necessary
2190
enable_fast_install=needless
2192
])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
2195
# AC_LIBTOOL_SYS_LIB_STRIP
2196
# ------------------------
2197
AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
2036
2200
AC_MSG_CHECKING([whether stripping libraries is possible])
2037
2201
if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
2403
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
2404
soname_spec='${libname}${release}.so$major'
2405
shlibpath_var=LD_LIBRARY_PATH
2412
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
2413
soname_spec='${libname}${release}.so$major'
2414
shlibpath_var=LD_LIBRARY_PATH
2418
2765
if test -d /usr/nec ;then
2419
2766
version_type=linux
2420
library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
2421
soname_spec='$libname.so.$major'
2767
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2768
soname_spec='$libname${shared_ext}.$major'
2422
2769
shlibpath_var=LD_LIBRARY_PATH
2775
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2776
soname_spec='${libname}${release}${shared_ext}$major'
2777
shlibpath_var=LD_LIBRARY_PATH
2427
2781
dynamic_linker=no
2430
2784
AC_MSG_RESULT([$dynamic_linker])
2431
2785
test "$dynamic_linker" = no && can_build_shared=no
2433
# Report the final consequences.
2434
AC_MSG_CHECKING([if libtool supports shared libraries])
2435
AC_MSG_RESULT([$can_build_shared])
2437
if test "$hardcode_action" = relink; then
2438
# Fast installation is not supported
2439
enable_fast_install=no
2440
elif test "$shlibpath_overrides_runpath" = yes ||
2441
test "$enable_shared" = no; then
2442
# Fast installation is not necessary
2443
enable_fast_install=needless
2446
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2447
if test "$GCC" = yes; then
2448
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2451
AC_LIBTOOL_DLOPEN_SELF
2453
if test "$enable_shared" = yes && test "$GCC" = yes; then
2454
case $archive_cmds in
2456
# FIXME: we may have to deal with multi-command sequences.
2459
# Test whether the compiler implicitly links with -lc since on some
2460
# systems, -lgcc has to come before -lc. If gcc already passes -lc
2461
# to ld, don't add -lc before -lgcc.
2462
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
2463
AC_CACHE_VAL([lt_cv_archive_cmds_need_lc],
2465
echo 'static int dummy;' > conftest.$ac_ext
2467
if AC_TRY_EVAL(ac_compile); then
2470
libobjs=conftest.$ac_objext
2472
wl=$lt_cv_prog_cc_wl
2478
save_allow_undefined_flag=$allow_undefined_flag
2479
allow_undefined_flag=
2480
if AC_TRY_EVAL(archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
2482
lt_cv_archive_cmds_need_lc=no
2484
lt_cv_archive_cmds_need_lc=yes
2486
allow_undefined_flag=$save_allow_undefined_flag
2786
])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2791
AC_DEFUN([_LT_AC_TAGCONFIG],
2792
[AC_ARG_WITH([tags],
2793
[AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2794
[include additional configurations @<:@automatic@:>@])],
2795
[tagnames="$withval"])
2797
if test -f "$ltmain" && test -n "$tagnames"; then
2798
if test ! -f "${ofile}"; then
2799
AC_MSG_WARN([output file `$ofile' does not exist])
2802
if test -z "$LTCC"; then
2803
eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2804
if test -z "$LTCC"; then
2805
AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2488
cat conftest.err 1>&5
2807
AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2811
# Extract list of available tagged configurations in $ofile.
2812
# Note that this assumes the entire list is on one line.
2813
available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2815
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2816
for tagname in $tagnames; do
2818
# Check whether tagname contains only valid characters
2819
case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2821
*) AC_MSG_ERROR([invalid tag name: $tagname])
2825
if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2827
AC_MSG_ERROR([tag name \"$tagname\" already exists])
2830
# Update the list of available tags.
2831
if test -n "$tagname"; then
2832
echo appending configuration tag \"$tagname\" to $ofile
2836
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2837
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2838
(test "X$CXX" != "Xg++"))) ; then
2839
AC_LIBTOOL_LANG_CXX_CONFIG
2846
if test -n "$F77" && test "X$F77" != "Xno"; then
2847
AC_LIBTOOL_LANG_F77_CONFIG
2854
if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2855
AC_LIBTOOL_LANG_GCJ_CONFIG
2862
AC_LIBTOOL_LANG_RC_CONFIG
2866
AC_MSG_ERROR([Unsupported tag name: $tagname])
2870
# Append the new tag name to the list of available tags.
2871
if test -n "$tagname" ; then
2872
available_tags="$available_tags $tagname"
2878
# Now substitute the updated list of available tags.
2879
if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2880
mv "${ofile}T" "$ofile"
2884
AC_MSG_ERROR([unable to update list of available tagged configurations.])
2887
])# _LT_AC_TAGCONFIG
2892
# enable checks for dlopen support
2893
AC_DEFUN([AC_LIBTOOL_DLOPEN],
2894
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2895
])# AC_LIBTOOL_DLOPEN
2898
# AC_LIBTOOL_WIN32_DLL
2899
# --------------------
2900
# declare package support for building win32 dll's
2901
AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2902
[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2903
])# AC_LIBTOOL_WIN32_DLL
2906
# AC_ENABLE_SHARED([DEFAULT])
2907
# ---------------------------
2908
# implement the --enable-shared flag
2909
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2910
AC_DEFUN([AC_ENABLE_SHARED],
2911
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2912
AC_ARG_ENABLE([shared],
2913
[AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2914
[build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2915
[p=${PACKAGE-default}
2917
yes) enable_shared=yes ;;
2918
no) enable_shared=no ;;
2921
# Look at the argument we got. We use all the common list separators.
2922
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2923
for pkg in $enableval; do
2925
if test "X$pkg" = "X$p"; then
2932
[enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2933
])# AC_ENABLE_SHARED
2938
#- set the default shared flag to --disable-shared
2939
AC_DEFUN([AC_DISABLE_SHARED],
2940
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2941
AC_ENABLE_SHARED(no)
2942
])# AC_DISABLE_SHARED
2945
# AC_ENABLE_STATIC([DEFAULT])
2946
# ---------------------------
2947
# implement the --enable-static flag
2948
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2949
AC_DEFUN([AC_ENABLE_STATIC],
2950
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2951
AC_ARG_ENABLE([static],
2952
[AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2953
[build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2954
[p=${PACKAGE-default}
2956
yes) enable_static=yes ;;
2957
no) enable_static=no ;;
2960
# Look at the argument we got. We use all the common list separators.
2961
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2962
for pkg in $enableval; do
2964
if test "X$pkg" = "X$p"; then
2971
[enable_static=]AC_ENABLE_STATIC_DEFAULT)
2972
])# AC_ENABLE_STATIC
2977
# set the default static flag to --disable-static
2978
AC_DEFUN([AC_DISABLE_STATIC],
2979
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2980
AC_ENABLE_STATIC(no)
2981
])# AC_DISABLE_STATIC
2984
# AC_ENABLE_FAST_INSTALL([DEFAULT])
2985
# ---------------------------------
2986
# implement the --enable-fast-install flag
2987
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2988
AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2989
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2990
AC_ARG_ENABLE([fast-install],
2991
[AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2992
[optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2993
[p=${PACKAGE-default}
2995
yes) enable_fast_install=yes ;;
2996
no) enable_fast_install=no ;;
2998
enable_fast_install=no
2999
# Look at the argument we got. We use all the common list separators.
3000
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3001
for pkg in $enableval; do
3003
if test "X$pkg" = "X$p"; then
3004
enable_fast_install=yes
3010
[enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
3011
])# AC_ENABLE_FAST_INSTALL
3014
# AC_DISABLE_FAST_INSTALL
3015
# -----------------------
3016
# set the default to --disable-fast-install
3017
AC_DEFUN([AC_DISABLE_FAST_INSTALL],
3018
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3019
AC_ENABLE_FAST_INSTALL(no)
3020
])# AC_DISABLE_FAST_INSTALL
3023
# AC_LIBTOOL_PICMODE([MODE])
3024
# --------------------------
3025
# implement the --with-pic flag
3026
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
3027
AC_DEFUN([AC_LIBTOOL_PICMODE],
3028
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3029
pic_mode=ifelse($#,1,$1,default)
3030
])# AC_LIBTOOL_PICMODE
3035
# This is predefined starting with Autoconf 2.54, so this conditional
3036
# definition can be removed once we require Autoconf 2.54 or later.
3037
m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
3038
[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
3039
[if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3040
then ac_cv_prog_egrep='grep -E'
3041
else ac_cv_prog_egrep='egrep'
2490
AC_MSG_RESULT([$lt_cv_archive_cmds_need_lc])
2494
need_lc=${lt_cv_archive_cmds_need_lc-yes}
2496
# The second clause should only fire when bootstrapping the
3043
EGREP=$ac_cv_prog_egrep
3048
# AC_PATH_TOOL_PREFIX
3049
# -------------------
3050
# find a file program which can recognise shared library
3051
AC_DEFUN([AC_PATH_TOOL_PREFIX],
3052
[AC_REQUIRE([AC_PROG_EGREP])dnl
3053
AC_MSG_CHECKING([for $1])
3054
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3056
[[\\/*] | ?:[\\/]*])
3057
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3060
lt_save_MAGIC_CMD="$MAGIC_CMD"
3061
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3062
dnl $ac_dummy forces splitting on constant user-supplied paths.
3063
dnl POSIX.2 word splitting is done only on the output of word expansions,
3064
dnl not every word. This closes a longstanding sh security hole.
3065
ac_dummy="ifelse([$2], , $PATH, [$2])"
3066
for ac_dir in $ac_dummy; do
3068
test -z "$ac_dir" && ac_dir=.
3069
if test -f $ac_dir/$1; then
3070
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3071
if test -n "$file_magic_test_file"; then
3072
case $deplibs_check_method in
3074
file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3075
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3076
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3077
$EGREP "$file_magic_regex" > /dev/null; then
3082
*** Warning: the command libtool uses to detect shared libraries,
3083
*** $file_magic_cmd, produces output that libtool cannot recognize.
3084
*** The result is that libtool may fail to recognize shared libraries
3085
*** as such. This will affect the creation of libtool libraries that
3086
*** depend on shared libraries, but programs linked with such libtool
3087
*** libraries will work regardless of this problem. Nevertheless, you
3088
*** may want to report the problem to your system manager and/or to
3089
*** bug-libtool@gnu.org
3099
MAGIC_CMD="$lt_save_MAGIC_CMD"
3102
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3103
if test -n "$MAGIC_CMD"; then
3104
AC_MSG_RESULT($MAGIC_CMD)
3108
])# AC_PATH_TOOL_PREFIX
3113
# find a file program which can recognise a shared library
3114
AC_DEFUN([AC_PATH_MAGIC],
3115
[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3116
if test -z "$lt_cv_path_MAGIC_CMD"; then
3117
if test -n "$ac_tool_prefix"; then
3118
AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3128
# find the pathname to the GNU or non-GNU linker
3129
AC_DEFUN([AC_PROG_LD],
3130
[AC_ARG_WITH([gnu-ld],
3131
[AC_HELP_STRING([--with-gnu-ld],
3132
[assume the C compiler uses GNU ld @<:@default=no@:>@])],
3133
[test "$withval" = no || with_gnu_ld=yes],
3135
AC_REQUIRE([LT_AC_PROG_SED])dnl
3136
AC_REQUIRE([AC_PROG_CC])dnl
3137
AC_REQUIRE([AC_CANONICAL_HOST])dnl
3138
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3140
if test "$GCC" = yes; then
3141
# Check if gcc -print-prog-name=ld gives a path.
3142
AC_MSG_CHECKING([for ld used by $CC])
3145
# gcc leaves a trailing carriage return which upsets mingw
3146
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3148
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3151
# Accept absolute paths.
3152
[[\\/]]* | ?:[[\\/]]*)
3153
re_direlt='/[[^/]][[^/]]*/\.\./'
3154
# Canonicalize the pathname of ld
3155
ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
3156
while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3157
ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
3159
test -z "$LD" && LD="$ac_prog"
3162
# If it fails, then pretend we aren't using GCC.
3166
# If it is relative, then search for the first ld in PATH.
3170
elif test "$with_gnu_ld" = yes; then
3171
AC_MSG_CHECKING([for GNU ld])
3173
AC_MSG_CHECKING([for non-GNU ld])
3175
AC_CACHE_VAL(lt_cv_path_LD,
3176
[if test -z "$LD"; then
3177
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3178
for ac_dir in $PATH; do
3180
test -z "$ac_dir" && ac_dir=.
3181
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3182
lt_cv_path_LD="$ac_dir/$ac_prog"
3183
# Check to see if the program is GNU ld. I'd rather use --version,
3184
# but apparently some GNU ld's only accept -v.
3185
# Break only if it was the GNU/non-GNU ld that we prefer.
3186
case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3187
*GNU* | *'with BFD'*)
3188
test "$with_gnu_ld" != no && break
3191
test "$with_gnu_ld" != yes && break
3198
lt_cv_path_LD="$LD" # Let the user override the test with a path.
3201
if test -n "$LD"; then
3206
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3213
AC_DEFUN([AC_PROG_LD_GNU],
3214
[AC_REQUIRE([AC_PROG_EGREP])dnl
3215
AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3216
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
3217
case `$LD -v 2>&1 </dev/null` in
3218
*GNU* | *'with BFD'*)
3219
lt_cv_prog_gnu_ld=yes
3222
lt_cv_prog_gnu_ld=no
3225
with_gnu_ld=$lt_cv_prog_gnu_ld
3229
# AC_PROG_LD_RELOAD_FLAG
3230
# ----------------------
3231
# find reload flag for linker
3232
# -- PORTME Some linkers may need a different reload flag.
3233
AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
3234
[AC_CACHE_CHECK([for $LD option to reload object files],
3235
lt_cv_ld_reload_flag,
3236
[lt_cv_ld_reload_flag='-r'])
3237
reload_flag=$lt_cv_ld_reload_flag
3238
case $reload_flag in
3240
*) reload_flag=" $reload_flag" ;;
3242
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3245
if test "$GCC" = yes; then
3246
reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
3248
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3252
])# AC_PROG_LD_RELOAD_FLAG
3255
# AC_DEPLIBS_CHECK_METHOD
3256
# -----------------------
3257
# how to check for library dependencies
3258
# -- PORTME fill in with the dynamic library characteristics
3259
AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
3260
[AC_CACHE_CHECK([how to recognise dependent libraries],
3261
lt_cv_deplibs_check_method,
3262
[lt_cv_file_magic_cmd='$MAGIC_CMD'
3263
lt_cv_file_magic_test_file=
3264
lt_cv_deplibs_check_method='unknown'
3265
# Need to set the preceding variable on all platforms that support
3266
# interlibrary dependencies.
3267
# 'none' -- dependencies not supported.
3268
# `unknown' -- same as none, but documents that we really don't know.
3269
# 'pass_all' -- all dependencies passed with no checks.
3270
# 'test_compile' -- check by making test program.
3271
# 'file_magic [[regex]]' -- check by looking for files in library path
3272
# which responds to the $file_magic_cmd with a given extended regex.
3273
# If you have `file' or equivalent on your system and you're not sure
3274
# whether `pass_all' will *always* work, you probably want this one.
3278
lt_cv_deplibs_check_method=pass_all
3282
lt_cv_deplibs_check_method=pass_all
3286
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3287
lt_cv_file_magic_cmd='/usr/bin/file -L'
3288
lt_cv_file_magic_test_file=/shlib/libc.so
3292
# func_win32_libid is a shell function defined in ltmain.sh
3293
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3294
lt_cv_file_magic_cmd='func_win32_libid'
3298
# Base MSYS/MinGW do not provide the 'file' command needed by
3299
# func_win32_libid shell function, so use a weaker test based on 'objdump'.
3300
lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3301
lt_cv_file_magic_cmd='$OBJDUMP -f'
3304
darwin* | rhapsody*)
3305
lt_cv_deplibs_check_method=pass_all
3308
freebsd* | kfreebsd*-gnu)
3309
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3312
# Not sure whether the presence of OpenBSD here was a mistake.
3313
# Let's accept both of them until this is cleared up.
3314
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[[3-9]]86 (compact )?demand paged shared library'
3315
lt_cv_file_magic_cmd=/usr/bin/file
3316
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3320
lt_cv_deplibs_check_method=pass_all
3325
lt_cv_deplibs_check_method=pass_all
3328
hpux10.20* | hpux11*)
3329
lt_cv_file_magic_cmd=/usr/bin/file
3332
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3333
lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3336
[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]']
3337
lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3340
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3341
lt_cv_file_magic_test_file=/usr/lib/libc.sl
3346
irix5* | irix6* | nonstopux*)
3348
*-32|*"-32 ") libmagic=32-bit;;
3349
*-n32|*"-n32 ") libmagic=N32;;
3350
*-64|*"-64 ") libmagic=64-bit;;
3351
*) libmagic=never-match;;
3353
lt_cv_deplibs_check_method=pass_all
3356
# This must be Linux ELF.
3358
lt_cv_deplibs_check_method=pass_all
3362
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3363
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3365
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3370
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3371
lt_cv_file_magic_cmd=/usr/bin/file
3372
lt_cv_file_magic_test_file=/usr/lib/libnls.so
3376
lt_cv_deplibs_check_method=unknown
3380
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3381
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3383
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3387
osf3* | osf4* | osf5*)
3388
lt_cv_deplibs_check_method=pass_all
3392
lt_cv_deplibs_check_method=pass_all
3396
lt_cv_deplibs_check_method=pass_all
3399
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
3400
case $host_vendor in
3402
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]]'
3403
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3406
lt_cv_deplibs_check_method=pass_all
3409
lt_cv_file_magic_cmd='/bin/file'
3410
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3413
lt_cv_file_magic_cmd='/bin/file'
3414
lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3415
lt_cv_file_magic_test_file=/lib/libc.so
3418
lt_cv_deplibs_check_method=pass_all
3423
sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
3424
lt_cv_deplibs_check_method=pass_all
3428
file_magic_cmd=$lt_cv_file_magic_cmd
3429
deplibs_check_method=$lt_cv_deplibs_check_method
3430
test -z "$deplibs_check_method" && deplibs_check_method=unknown
3431
])# AC_DEPLIBS_CHECK_METHOD
3436
# find the pathname to a BSD-compatible name lister
3437
AC_DEFUN([AC_PROG_NM],
3438
[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
3439
[if test -n "$NM"; then
3440
# Let the user override the test.
3443
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3444
for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
3446
test -z "$ac_dir" && ac_dir=.
3447
tmp_nm="$ac_dir/${ac_tool_prefix}nm"
3448
if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3449
# Check to see if the nm accepts a BSD-compat flag.
3450
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
3451
# nm: unknown option "B" ignored
3452
# Tru64's nm complains that /dev/null is an invalid object file
3453
case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3454
*/dev/null* | *'Invalid file or object type'*)
3455
lt_cv_path_NM="$tmp_nm -B"
3459
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3461
lt_cv_path_NM="$tmp_nm -p"
3465
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3466
continue # so that we can try to find one that supports BSD flags
3473
test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3481
# check for math library
3482
AC_DEFUN([AC_CHECK_LIBM],
3483
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3486
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3487
# These system don't have libm, or don't need it
3490
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3491
AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3494
AC_CHECK_LIB(m, cos, LIBM="-lm")
3500
# AC_LIBLTDL_CONVENIENCE([DIRECTORY])
3501
# -----------------------------------
3502
# sets LIBLTDL to the link flags for the libltdl convenience library and
3503
# LTDLINCL to the include flags for the libltdl header and adds
3504
# --enable-ltdl-convenience to the configure arguments. Note that LIBLTDL
3505
# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If
3506
# DIRECTORY is not provided, it is assumed to be `libltdl'. LIBLTDL will
3507
# be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed with
3508
# '${top_srcdir}/' (note the single quotes!). If your package is not
3509
# flat and you're not using automake, define top_builddir and
3510
# top_srcdir appropriately in the Makefiles.
3511
AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3512
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3513
case $enable_ltdl_convenience in
3514
no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3515
"") enable_ltdl_convenience=yes
3516
ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3518
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3519
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3520
# For backwards non-gettext consistent compatibility...
3522
])# AC_LIBLTDL_CONVENIENCE
3525
# AC_LIBLTDL_INSTALLABLE([DIRECTORY])
3526
# -----------------------------------
3527
# sets LIBLTDL to the link flags for the libltdl installable library and
3528
# LTDLINCL to the include flags for the libltdl header and adds
3529
# --enable-ltdl-install to the configure arguments. Note that LIBLTDL
3530
# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If
3531
# DIRECTORY is not provided and an installed libltdl is not found, it is
3532
# assumed to be `libltdl'. LIBLTDL will be prefixed with '${top_builddir}/'
3533
# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single
3534
# quotes!). If your package is not flat and you're not using automake,
3535
# define top_builddir and top_srcdir appropriately in the Makefiles.
3536
# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3537
AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3538
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3539
AC_CHECK_LIB(ltdl, lt_dlinit,
3540
[test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3541
[if test x"$enable_ltdl_install" = xno; then
3542
AC_MSG_WARN([libltdl not installed, but installation disabled])
3544
enable_ltdl_install=yes
3547
if test x"$enable_ltdl_install" = x"yes"; then
3548
ac_configure_args="$ac_configure_args --enable-ltdl-install"
3549
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3550
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3552
ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
3556
# For backwards non-gettext consistent compatibility...
3558
])# AC_LIBLTDL_INSTALLABLE
3563
# enable support for C++ libraries
3564
AC_DEFUN([AC_LIBTOOL_CXX],
3565
[AC_REQUIRE([_LT_AC_LANG_CXX])
3571
AC_DEFUN([_LT_AC_LANG_CXX],
3572
[AC_REQUIRE([AC_PROG_CXX])
3573
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3574
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
3577
# _LT_AC_PROG_CXXCPP
3579
AC_DEFUN([_LT_AC_PROG_CXXCPP],
3581
AC_REQUIRE([AC_PROG_CXX])
3582
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
3583
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
3584
(test "X$CXX" != "Xg++"))) ; then
3587
])# _LT_AC_PROG_CXXCPP
3591
# enable support for Fortran 77 libraries
3592
AC_DEFUN([AC_LIBTOOL_F77],
3593
[AC_REQUIRE([_LT_AC_LANG_F77])
3599
AC_DEFUN([_LT_AC_LANG_F77],
3600
[AC_REQUIRE([AC_PROG_F77])
3601
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
3607
# enable support for GCJ libraries
3608
AC_DEFUN([AC_LIBTOOL_GCJ],
3609
[AC_REQUIRE([_LT_AC_LANG_GCJ])
3615
AC_DEFUN([_LT_AC_LANG_GCJ],
3616
[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
3617
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
3618
[AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
3619
[ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
3620
[ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
3621
[AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
3622
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
3628
# enable support for Windows resource files
3629
AC_DEFUN([AC_LIBTOOL_RC],
3630
[AC_REQUIRE([LT_AC_PROG_RC])
3631
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
3635
# AC_LIBTOOL_LANG_C_CONFIG
3636
# ------------------------
3637
# Ensure that the configuration vars for the C compiler are
3638
# suitably defined. Those variables are subsequently used by
3639
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3640
AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
3641
AC_DEFUN([_LT_AC_LANG_C_CONFIG],
3645
# Source file extension for C test sources.
3648
# Object file extension for compiled C test sources.
3650
_LT_AC_TAGVAR(objext, $1)=$objext
3652
# Code to be used in simple compile tests
3653
lt_simple_compile_test_code="int some_variable = 0;\n"
3655
# Code to be used in simple link tests
3656
lt_simple_link_test_code='int main(){return(0);}\n'
3661
# Check for any special shared library compilation flags.
3663
_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
3664
if test "$GCC" = no; then
3667
_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
3671
if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
3672
AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
3673
if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then :
3675
AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
3676
_LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
3682
# Check to make sure the static flag actually works.
3684
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
3685
_LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
3686
$_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
3688
[_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
3691
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
3692
AC_LIBTOOL_PROG_COMPILER_PIC($1)
3693
AC_LIBTOOL_PROG_CC_C_O($1)
3694
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3695
AC_LIBTOOL_PROG_LD_SHLIBS($1)
3696
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3697
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3698
AC_LIBTOOL_SYS_LIB_STRIP
3699
AC_LIBTOOL_DLOPEN_SELF($1)
3701
# Report which librarie types wil actually be built
3702
AC_MSG_CHECKING([if libtool supports shared libraries])
3703
AC_MSG_RESULT([$can_build_shared])
3705
AC_MSG_CHECKING([whether to build shared libraries])
3706
test "$can_build_shared" = "no" && enable_shared=no
3708
# On AIX, shared libraries and static libraries use the same namespace, and
3709
# are all built from PIC.
3712
test "$enable_shared" = yes && enable_static=no
3713
if test -n "$RANLIB"; then
3714
archive_cmds="$archive_cmds~\$RANLIB \$lib"
3715
postinstall_cmds='$RANLIB $lib'
3720
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3721
test "$enable_shared" = yes && enable_static=no
3725
AC_MSG_RESULT([$enable_shared])
3727
AC_MSG_CHECKING([whether to build static libraries])
3728
# Make sure either enable_shared or enable_static is yes.
3729
test "$enable_shared" = yes || enable_static=yes
3730
AC_MSG_RESULT([$enable_static])
3732
AC_LIBTOOL_CONFIG($1)
3736
])# AC_LIBTOOL_LANG_C_CONFIG
3739
# AC_LIBTOOL_LANG_CXX_CONFIG
3740
# --------------------------
3741
# Ensure that the configuration vars for the C compiler are
3742
# suitably defined. Those variables are subsequently used by
3743
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3744
AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
3745
AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
3747
AC_REQUIRE([AC_PROG_CXX])
3748
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3750
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3751
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
3752
_LT_AC_TAGVAR(always_export_symbols, $1)=no
3753
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3754
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3755
_LT_AC_TAGVAR(hardcode_direct, $1)=no
3756
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3757
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3758
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3759
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3760
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
3761
_LT_AC_TAGVAR(module_cmds, $1)=
3762
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
3763
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3764
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3765
_LT_AC_TAGVAR(no_undefined_flag, $1)=
3766
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3767
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3769
# Dependencies to place before and after the object being linked:
3770
_LT_AC_TAGVAR(predep_objects, $1)=
3771
_LT_AC_TAGVAR(postdep_objects, $1)=
3772
_LT_AC_TAGVAR(predeps, $1)=
3773
_LT_AC_TAGVAR(postdeps, $1)=
3774
_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3776
# Source file extension for C++ test sources.
3779
# Object file extension for compiled C++ test sources.
3781
_LT_AC_TAGVAR(objext, $1)=$objext
3783
# Code to be used in simple compile tests
3784
lt_simple_compile_test_code="int some_variable = 0;\n"
3786
# Code to be used in simple link tests
3787
lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
3789
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3792
# Allow CC to be a program name with arguments.
3797
lt_save_with_gnu_ld=$with_gnu_ld
3798
lt_save_path_LD=$lt_cv_path_LD
3799
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3800
lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3802
unset lt_cv_prog_gnu_ld
3804
if test -n "${lt_cv_path_LDCXX+set}"; then
3805
lt_cv_path_LD=$lt_cv_path_LDCXX
3809
test -z "${LDCXX+set}" || LD=$LDCXX
3812
_LT_AC_TAGVAR(compiler, $1)=$CC
3813
cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
3815
# We don't want -fno-exception wen compiling C++ code, so set the
3816
# no_builtin_flag separately
3817
if test "$GXX" = yes; then
3818
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3820
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3823
if test "$GXX" = yes; then
3824
# Set up default GNU C++ configuration
3828
# Check if GNU C++ uses GNU ld as the underlying linker, since the
3829
# archiving commands below assume that GNU ld is being used.
3830
if test "$with_gnu_ld" = yes; then
3831
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3832
_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'
3834
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3835
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3837
# If archive_cmds runs LD, not CC, wlarc should be empty
3838
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3839
# investigate it a little bit more. (MM)
3842
# ancient GNU ld didn't support --whole-archive et. al.
3843
if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3844
grep 'no-whole-archive' > /dev/null; then
3845
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3847
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3853
# A generic and very simple default shared library creation
3854
# command for GNU C++ for the case where it uses the native
3855
# linker, instead of GNU ld. If possible, this setting should
3856
# overridden to take advantage of the native linker features on
3857
# the platform it is being used on.
3858
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3861
# Commands to make compiler produce verbose output that lists
3862
# what "hidden" libraries, object files and flags are used when
3863
# linking a shared library.
3864
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3872
# PORTME: fill in a description of your system's C++ link characteristics
3873
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3874
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
3877
# FIXME: insert proper C++ library support
3878
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3881
if test "$host_cpu" = ia64; then
3882
# On IA64, the linker does run time linking by default, so we don't
3883
# have to do anything special.
3884
aix_use_runtimelinking=no
3885
exp_sym_flag='-Bexport'
3888
aix_use_runtimelinking=no
3890
# Test if we are trying to use run time linking or normal
3891
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
3892
# need to do runtime linking.
3893
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
3894
for ld_flag in $LDFLAGS; do
3897
aix_use_runtimelinking=yes
3904
exp_sym_flag='-bexport'
3905
no_entry_flag='-bnoentry'
3908
# When large executables or shared objects are built, AIX ld can
3909
# have problems creating the table of contents. If linking a library
3910
# or program results in "error TOC overflow" add -mminimal-toc to
3911
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
3912
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3914
_LT_AC_TAGVAR(archive_cmds, $1)=''
3915
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
3916
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3917
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3919
if test "$GXX" = yes; then
3920
case $host_os in aix4.[012]|aix4.[012].*)
3921
# We only want to do this on AIX 4.2 and lower, the check
3922
# below for broken collect2 doesn't work under 4.3+
3923
collect2name=`${CC} -print-prog-name=collect2`
3924
if test -f "$collect2name" && \
3925
strings "$collect2name" | grep resolve_lib_name >/dev/null
3927
# We have reworked collect2
3928
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
3930
# We have old collect2
3931
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3932
# It fails to find uninstalled libraries when the uninstalled
3933
# path is not listed in the libpath. Setting hardcode_minus_L
3934
# to unsupported forces relinking
3935
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3936
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3937
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3940
shared_flag='-shared'
3943
if test "$host_cpu" = ia64; then
3944
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3945
# chokes on -Wl,-G. The following line is correct:
3948
if test "$aix_use_runtimelinking" = yes; then
3949
shared_flag='${wl}-G'
3951
shared_flag='${wl}-bM:SRE'
3956
# It seems that -bexpall does not export symbols beginning with
3957
# underscore (_), so it is better to generate a list of symbols to export.
3958
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
3959
if test "$aix_use_runtimelinking" = yes; then
3960
# Warning - without using the other runtime loading flags (-brtl),
3961
# -berok will link without error, but may produce a broken library.
3962
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3963
# Determine the default libpath from the value encoded in an empty executable.
3964
_LT_AC_SYS_LIBPATH_AIX
3965
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3967
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3969
if test "$host_cpu" = ia64; then
3970
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3971
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3972
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
3974
# Determine the default libpath from the value encoded in an empty executable.
3975
_LT_AC_SYS_LIBPATH_AIX
3976
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3977
# Warning - without using the other run time loading flags,
3978
# -berok will link without error, but may produce a broken library.
3979
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3980
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3981
# -bexpall does not export symbols beginning with underscore (_)
3982
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
3983
# Exported symbols can be pulled into shared objects from archives
3984
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
3985
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3986
# This is similar to how AIX traditionally builds it's shared libraries.
3987
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
3992
case $cc_basename in
3994
# FIXME: insert proper C++ library support
3995
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4001
cygwin* | mingw* | pw32*)
4002
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4003
# as there is no search path for DLLs.
4004
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4005
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
4006
_LT_AC_TAGVAR(always_export_symbols, $1)=no
4007
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4009
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
4010
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
4011
# If the export-symbols file already is a .def file (1st line
4012
# is EXPORTS), use it as is; otherwise, prepend...
4013
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
4014
cp $export_symbols $output_objdir/$soname.def;
4016
echo EXPORTS > $output_objdir/$soname.def;
4017
cat $export_symbols >> $output_objdir/$soname.def;
4019
$CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
4021
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4024
darwin* | rhapsody*)
4026
rhapsody* | darwin1.[[012]])
4027
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
4030
if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
4031
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
4033
case ${MACOSX_DEPLOYMENT_TARGET} in
4035
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
4038
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
4044
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4045
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4046
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
4047
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4048
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
4049
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4051
if test "$GXX" = yes ; then
4052
lt_int_apple_cc_single_mod=no
4053
output_verbose_link_cmd='echo'
4054
if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
4055
lt_int_apple_cc_single_mod=yes
4057
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
4058
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
4060
_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'
4062
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
4063
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
4064
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
4065
_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}'
4067
_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}'
4069
_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}'
4071
case "$cc_basename" in
4073
output_verbose_link_cmd='echo'
4074
_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'
4075
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
4076
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
4077
_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}'
4078
_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}'
4081
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4088
case $cc_basename in
4090
# FIXME: insert proper C++ library support
4091
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4094
# Green Hills C++ Compiler
4095
# FIXME: insert proper C++ library support
4096
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4099
# FIXME: insert proper C++ library support
4100
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4105
# C++ shared libraries reported to be fairly broken before switch to ELF
4106
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4109
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4111
freebsd* | kfreebsd*-gnu)
4112
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
4114
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
4119
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4120
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4121
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4122
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4123
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4124
# but as the default
4125
# location of the library.
4127
case $cc_basename in
4129
# FIXME: insert proper C++ library support
4130
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4133
_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'
4134
# Commands to make compiler produce verbose output that lists
4135
# what "hidden" libraries, object files and flags are used when
4136
# linking a shared library.
4138
# There doesn't appear to be a way to prevent this compiler from
4139
# explicitly linking system object files so we need to strip them
4140
# from the output so that they don't get included in the library
4142
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'
4145
if test "$GXX" = yes; then
4146
_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'
4148
# FIXME: insert proper C++ library support
4149
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4155
if test $with_gnu_ld = no; then
4158
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4159
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
4160
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4163
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4166
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4167
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4168
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4174
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4175
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4178
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4179
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4180
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4181
# but as the default
4182
# location of the library.
4185
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4186
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4187
# but as the default
4188
# location of the library.
4192
case $cc_basename in
4194
# FIXME: insert proper C++ library support
4195
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4200
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
4203
_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'
4206
# Commands to make compiler produce verbose output that lists
4207
# what "hidden" libraries, object files and flags are used when
4208
# linking a shared library.
4210
# There doesn't appear to be a way to prevent this compiler from
4211
# explicitly linking system object files so we need to strip them
4212
# from the output so that they don't get included in the library
4214
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'
4217
if test "$GXX" = yes; then
4218
if test $with_gnu_ld = no; then
4221
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
4224
_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'
4229
# FIXME: insert proper C++ library support
4230
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4236
case $cc_basename in
4239
_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 ${objdir}/so_locations -o $lib'
4241
# Archives containing C++ object files must be created using
4242
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
4243
# necessary to make sure instantiated templates are included
4245
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
4248
if test "$GXX" = yes; then
4249
if test "$with_gnu_ld" = no; then
4250
_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}${objdir}/so_locations -o $lib'
4252
_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'
4255
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4258
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4259
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4262
case $cc_basename in
4264
# Kuck and Associates, Inc. (KAI) C++ Compiler
4266
# KCC will only create a shared library if the output file
4267
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4268
# to its proper name (with version) after linking.
4269
_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'
4270
_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'
4271
# Commands to make compiler produce verbose output that lists
4272
# what "hidden" libraries, object files and flags are used when
4273
# linking a shared library.
4275
# There doesn't appear to be a way to prevent this compiler from
4276
# explicitly linking system object files so we need to strip them
4277
# from the output so that they don't get included in the library
4279
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'
4281
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
4282
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4284
# Archives containing C++ object files must be created using
4285
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
4286
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4291
# version 8.0 and above of icpc choke on multiply defined symbols
4292
# if we add $predep_objects and $postdep_objects, however 7.1 and
4293
# earlier do not add the objects themselves.
4294
case `$CC -V 2>&1` in
4296
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4297
_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'
4299
*) # Version 8.0 or newer
4300
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4301
_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'
4304
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4305
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4306
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4307
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
4311
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4312
_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'
4314
runpath_var=LD_RUN_PATH
4315
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4316
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4318
# Commands to make compiler produce verbose output that lists
4319
# what "hidden" libraries, object files and flags are used when
4320
# linking a shared library.
4322
# There doesn't appear to be a way to prevent this compiler from
4323
# explicitly linking system object files so we need to strip them
4324
# from the output so that they don't get included in the library
4326
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'
4331
# FIXME: insert proper C++ library support
4332
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4335
# FIXME: insert proper C++ library support
4336
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4339
case $cc_basename in
4341
# FIXME: insert proper C++ library support
4342
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4345
# FIXME: insert proper C++ library support
4346
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4351
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4352
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
4354
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4355
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4356
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4358
# Workaround some broken pre-1.5 toolchains
4359
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
4362
# C++ shared libraries are fairly broken
4363
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4366
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4367
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4368
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
4369
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4370
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4371
_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'
4372
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4373
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4375
output_verbose_link_cmd='echo'
4378
case $cc_basename in
4380
# Kuck and Associates, Inc. (KAI) C++ Compiler
4382
# KCC will only create a shared library if the output file
4383
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4384
# to its proper name (with version) after linking.
4385
_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'
4387
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4388
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4390
# Archives containing C++ object files must be created using
4391
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
4392
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4396
# Rational C++ 2.4.1
4397
# FIXME: insert proper C++ library support
4398
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4401
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4402
_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 ${objdir}/so_locations -o $lib'
4404
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4405
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4407
# Commands to make compiler produce verbose output that lists
4408
# what "hidden" libraries, object files and flags are used when
4409
# linking a shared library.
4411
# There doesn't appear to be a way to prevent this compiler from
4412
# explicitly linking system object files so we need to strip them
4413
# from the output so that they don't get included in the library
4415
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'
4418
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4419
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4420
_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}${objdir}/so_locations -o $lib'
4422
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4423
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4425
# Commands to make compiler produce verbose output that lists
4426
# what "hidden" libraries, object files and flags are used when
4427
# linking a shared library.
4428
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4431
# FIXME: insert proper C++ library support
4432
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4438
case $cc_basename in
4440
# Kuck and Associates, Inc. (KAI) C++ Compiler
4442
# KCC will only create a shared library if the output file
4443
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4444
# to its proper name (with version) after linking.
4445
_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'
4447
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4448
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4450
# Archives containing C++ object files must be created using
4451
# the KAI C++ compiler.
4452
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
4455
# Rational C++ 2.4.1
4456
# FIXME: insert proper C++ library support
4457
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4460
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
4461
_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 ${objdir}/so_locations -o $lib'
4462
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
4463
echo "-hidden">> $lib.exp~
4464
$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 $objdir/so_locations -o $lib~
4467
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4468
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4470
# Commands to make compiler produce verbose output that lists
4471
# what "hidden" libraries, object files and flags are used when
4472
# linking a shared library.
4474
# There doesn't appear to be a way to prevent this compiler from
4475
# explicitly linking system object files so we need to strip them
4476
# from the output so that they don't get included in the library
4478
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'
4481
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4482
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4483
_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}${objdir}/so_locations -o $lib'
4485
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4486
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4488
# Commands to make compiler produce verbose output that lists
4489
# what "hidden" libraries, object files and flags are used when
4490
# linking a shared library.
4491
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4494
# FIXME: insert proper C++ library support
4495
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4501
# FIXME: insert proper C++ library support
4502
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4505
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4506
case $cc_basename in
4508
# FIXME: insert proper C++ library support
4509
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4512
# FIXME: insert proper C++ library support
4513
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4518
case $cc_basename in
4521
# FIXME: insert proper C++ library support
4522
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4526
# FIXME: insert proper C++ library support
4527
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4530
# FIXME: insert proper C++ library support
4531
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4536
case $cc_basename in
4538
# Sun C++ 4.2, 5.x and Centerline C++
4539
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4540
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4541
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4542
$CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4544
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4545
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4547
solaris2.[0-5] | solaris2.[0-5].*) ;;
4549
# The C++ compiler is used as linker so we must use $wl
4550
# flag to pass the commands to the underlying system
4552
# Supported since Solaris 2.6 (maybe 2.5.1?)
4553
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
4556
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4558
# Commands to make compiler produce verbose output that lists
4559
# what "hidden" libraries, object files and flags are used when
4560
# linking a shared library.
4562
# There doesn't appear to be a way to prevent this compiler from
4563
# explicitly linking system object files so we need to strip them
4564
# from the output so that they don't get included in the library
4566
output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4568
# Archives containing C++ object files must be created using
4569
# "CC -xar", where "CC" is the Sun C++ compiler. This is
4570
# necessary to make sure instantiated templates are included
4572
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4575
# Green Hills C++ Compiler
4576
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4578
# The C++ compiler must be used to create the archive.
4579
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
4582
# GNU C++ compiler with Solaris linker
4583
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4584
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
4585
if $CC --version | grep -v '^2\.7' > /dev/null; then
4586
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4587
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4588
$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4590
# Commands to make compiler produce verbose output that lists
4591
# what "hidden" libraries, object files and flags are used when
4592
# linking a shared library.
4593
output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4595
# g++ 2.7 appears to require `-G' NOT `-shared' on this
4597
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4598
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4599
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4601
# Commands to make compiler produce verbose output that lists
4602
# what "hidden" libraries, object files and flags are used when
4603
# linking a shared library.
4604
output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4607
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
4612
sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
4613
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4616
case $cc_basename in
4618
# NonStop-UX NCC 3.20
4619
# FIXME: insert proper C++ library support
4620
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4623
# FIXME: insert proper C++ library support
4624
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4629
# FIXME: insert proper C++ library support
4630
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4633
# FIXME: insert proper C++ library support
4634
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4637
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
4638
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4640
_LT_AC_TAGVAR(GCC, $1)="$GXX"
4641
_LT_AC_TAGVAR(LD, $1)="$LD"
4643
AC_LIBTOOL_POSTDEP_PREDEP($1)
4644
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4645
AC_LIBTOOL_PROG_CC_C_O($1)
4646
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4647
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4648
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4649
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4650
AC_LIBTOOL_SYS_LIB_STRIP
4651
AC_LIBTOOL_DLOPEN_SELF($1)
4653
AC_LIBTOOL_CONFIG($1)
4660
with_gnu_ldcxx=$with_gnu_ld
4661
with_gnu_ld=$lt_save_with_gnu_ld
4662
lt_cv_path_LDCXX=$lt_cv_path_LD
4663
lt_cv_path_LD=$lt_save_path_LD
4664
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
4665
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
4666
])# AC_LIBTOOL_LANG_CXX_CONFIG
4668
# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
4669
# ------------------------
4670
# Figure out "hidden" library dependencies from verbose
4671
# compiler output when linking a shared library.
4672
# Parse the compiler output and extract the necessary
4673
# objects, libraries and library flags.
4674
AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
4675
dnl we can't use the lt_simple_compile_test_code here,
4676
dnl because it contains code intended for an executable,
4677
dnl not a library. It's possible we should let each
4678
dnl tag define a new lt_????_link_test_code variable,
4679
dnl but it's only used here...
4680
ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
4682
void foo (void) { a = 0; }
4684
],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
4688
Foo (void) { a = 0; }
4693
],[$1],[F77],[cat > conftest.$ac_ext <<EOF
4701
],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
4704
public void bar (void) {
4710
dnl Parse the compiler output and extract the necessary
4711
dnl objects, libraries and library flags.
4712
if AC_TRY_EVAL(ac_compile); then
4713
# Parse the compiler output and extract the necessary
4714
# objects, libraries and library flags.
4716
# Sentinel used to keep track of whether or not we are before
4717
# the conftest object file.
4718
pre_test_object_deps_done=no
4720
# The `*' in the case matches for architectures that use `case' in
4721
# $output_verbose_cmd can trigger glob expansion during the loop
4722
# eval without this substitution.
4723
output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`"
4725
for p in `eval $output_verbose_link_cmd`; do
4729
# Some compilers place space between "-{L,R}" and the path.
4732
|| test $p = "-R"; then
4739
if test "$pre_test_object_deps_done" = no; then
4742
# Internal compiler library paths should come after those
4743
# provided the user. The postdeps already come after the
4744
# user supplied libs so there is no need to process them.
4745
if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4746
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
4748
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
4751
# The "-l" case would never come before the object being
4752
# linked, so don't bother handling this case.
4755
if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
4756
_LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
4758
_LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
4764
# This assumes that the test object file only shows up
4765
# once in the compiler output.
4766
if test "$p" = "conftest.$objext"; then
4767
pre_test_object_deps_done=yes
4771
if test "$pre_test_object_deps_done" = no; then
4772
if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
4773
_LT_AC_TAGVAR(predep_objects, $1)="$p"
4775
_LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
4778
if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
4779
_LT_AC_TAGVAR(postdep_objects, $1)="$p"
4781
_LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
4786
*) ;; # Ignore the rest.
4794
echo "libtool.m4: error: problem compiling $1 test program"
4797
$rm -f confest.$objext
4799
case " $_LT_AC_TAGVAR(postdeps, $1) " in
4800
*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4802
])# AC_LIBTOOL_POSTDEP_PREDEP
4804
# AC_LIBTOOL_LANG_F77_CONFIG
4805
# ------------------------
4806
# Ensure that the configuration vars for the C compiler are
4807
# suitably defined. Those variables are subsequently used by
4808
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4809
AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4810
AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4811
[AC_REQUIRE([AC_PROG_F77])
4812
AC_LANG_PUSH(Fortran 77)
4814
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4815
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
4816
_LT_AC_TAGVAR(always_export_symbols, $1)=no
4817
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
4818
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
4819
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4820
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
4821
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4822
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
4823
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
4824
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
4825
_LT_AC_TAGVAR(module_cmds, $1)=
4826
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
4827
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
4828
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4829
_LT_AC_TAGVAR(no_undefined_flag, $1)=
4830
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
4831
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4833
# Source file extension for f77 test sources.
4836
# Object file extension for compiled f77 test sources.
4838
_LT_AC_TAGVAR(objext, $1)=$objext
4840
# Code to be used in simple compile tests
4841
lt_simple_compile_test_code=" subroutine t\n return\n end\n"
4843
# Code to be used in simple link tests
4844
lt_simple_link_test_code=" program t\n end\n"
4846
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4849
# Allow CC to be a program name with arguments.
4853
_LT_AC_TAGVAR(compiler, $1)=$CC
4854
cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
4856
AC_MSG_CHECKING([if libtool supports shared libraries])
4857
AC_MSG_RESULT([$can_build_shared])
4859
AC_MSG_CHECKING([whether to build shared libraries])
4860
test "$can_build_shared" = "no" && enable_shared=no
4862
# On AIX, shared libraries and static libraries use the same namespace, and
4863
# are all built from PIC.
4866
test "$enable_shared" = yes && enable_static=no
4867
if test -n "$RANLIB"; then
4868
archive_cmds="$archive_cmds~\$RANLIB \$lib"
4869
postinstall_cmds='$RANLIB $lib'
4873
test "$enable_shared" = yes && enable_static=no
4876
AC_MSG_RESULT([$enable_shared])
4878
AC_MSG_CHECKING([whether to build static libraries])
4879
# Make sure either enable_shared or enable_static is yes.
4880
test "$enable_shared" = yes || enable_static=yes
4881
AC_MSG_RESULT([$enable_static])
4883
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4885
_LT_AC_TAGVAR(GCC, $1)="$G77"
4886
_LT_AC_TAGVAR(LD, $1)="$LD"
4888
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4889
AC_LIBTOOL_PROG_CC_C_O($1)
4890
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4891
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4892
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4893
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4894
AC_LIBTOOL_SYS_LIB_STRIP
4897
AC_LIBTOOL_CONFIG($1)
4901
])# AC_LIBTOOL_LANG_F77_CONFIG
4904
# AC_LIBTOOL_LANG_GCJ_CONFIG
4905
# --------------------------
4906
# Ensure that the configuration vars for the C compiler are
4907
# suitably defined. Those variables are subsequently used by
4908
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4909
AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4910
AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4913
# Source file extension for Java test sources.
4916
# Object file extension for compiled Java test sources.
4918
_LT_AC_TAGVAR(objext, $1)=$objext
4920
# Code to be used in simple compile tests
4921
lt_simple_compile_test_code="class foo {}\n"
4923
# Code to be used in simple link tests
4924
lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n'
4926
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4929
# Allow CC to be a program name with arguments.
4933
_LT_AC_TAGVAR(compiler, $1)=$CC
4935
# GCJ did not exist at the time GCC didn't implicitly link libc in.
4936
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4938
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4939
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4940
AC_LIBTOOL_PROG_CC_C_O($1)
4941
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4942
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4943
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4944
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4945
AC_LIBTOOL_SYS_LIB_STRIP
4946
AC_LIBTOOL_DLOPEN_SELF($1)
4948
AC_LIBTOOL_CONFIG($1)
4952
])# AC_LIBTOOL_LANG_GCJ_CONFIG
4955
# AC_LIBTOOL_LANG_RC_CONFIG
4956
# --------------------------
4957
# Ensure that the configuration vars for the Windows resource compiler are
4958
# suitably defined. Those variables are subsequently used by
4959
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4960
AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4961
AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4964
# Source file extension for RC test sources.
4967
# Object file extension for compiled RC test sources.
4969
_LT_AC_TAGVAR(objext, $1)=$objext
4971
# Code to be used in simple compile tests
4972
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
4974
# Code to be used in simple link tests
4975
lt_simple_link_test_code="$lt_simple_compile_test_code"
4977
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
4980
# Allow CC to be a program name with arguments.
4984
_LT_AC_TAGVAR(compiler, $1)=$CC
4985
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4987
AC_LIBTOOL_CONFIG($1)
4991
])# AC_LIBTOOL_LANG_RC_CONFIG
4994
# AC_LIBTOOL_CONFIG([TAGNAME])
4995
# ----------------------------
4996
# If TAGNAME is not passed, then create an initial libtool script
4997
# with a default configuration from the untagged config vars. Otherwise
4998
# add code to config.status for appending the configuration named by
4999
# TAGNAME from the matching tagged config vars.
5000
AC_DEFUN([AC_LIBTOOL_CONFIG],
5001
[# The else clause should only fire when bootstrapping the
2497
5002
# libtool distribution, otherwise you forgot to ship ltmain.sh
2498
5003
# with your package, and you will get complaints that there are
2499
5004
# no rules to generate ltmain.sh.
2500
5005
if test -f "$ltmain"; then
2503
# If there is no Makefile yet, we rely on a make rule to execute
2504
# `config.status --recheck' to rerun these tests and create the
2505
# libtool script then.
2506
test -f Makefile && make "$ltmain"
2509
if test -f "$ltmain"; then
2510
trap "$rm \"${ofile}T\"; exit 1" 1 2 15
2513
echo creating $ofile
5006
# See if we are running on zsh, and set the options which allow our commands through
5007
# without removal of \ escapes.
5008
if test -n "${ZSH_VERSION+set}" ; then
5009
setopt NO_GLOB_SUBST
2515
5011
# Now quote all the things that may contain metacharacters while being
2516
5012
# careful not to overquote the AC_SUBSTed values. We take copies of the
2517
5013
# variables and quote the copies for generation of the libtool script.
2518
for var in echo old_CC old_CFLAGS \
2519
AR AR_FLAGS CC LD LN_S NM SHELL \
2520
reload_flag reload_cmds wl \
2521
pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \
2522
thread_safe_flag_spec whole_archive_flag_spec libname_spec \
2523
library_names_spec soname_spec \
2524
RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \
2525
old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds \
2526
postuninstall_cmds extract_expsyms_cmds old_archive_from_expsyms_cmds \
2527
old_striplib striplib file_magic_cmd export_symbols_cmds \
2528
deplibs_check_method allow_undefined_flag no_undefined_flag \
2529
finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
2530
hardcode_libdir_flag_spec hardcode_libdir_separator \
5014
for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
5016
libname_spec library_names_spec soname_spec extract_expsyms_cmds \
5017
old_striplib striplib file_magic_cmd finish_cmds finish_eval \
5018
deplibs_check_method reload_flag reload_cmds need_locks \
5019
lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
5020
lt_cv_sys_global_symbol_to_c_name_address \
2531
5021
sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
2532
compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
5022
old_postinstall_cmds old_postuninstall_cmds \
5023
_LT_AC_TAGVAR(compiler, $1) \
5024
_LT_AC_TAGVAR(CC, $1) \
5025
_LT_AC_TAGVAR(LD, $1) \
5026
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
5027
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
5028
_LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
5029
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
5030
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
5031
_LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
5032
_LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
5033
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
5034
_LT_AC_TAGVAR(old_archive_cmds, $1) \
5035
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
5036
_LT_AC_TAGVAR(predep_objects, $1) \
5037
_LT_AC_TAGVAR(postdep_objects, $1) \
5038
_LT_AC_TAGVAR(predeps, $1) \
5039
_LT_AC_TAGVAR(postdeps, $1) \
5040
_LT_AC_TAGVAR(compiler_lib_search_path, $1) \
5041
_LT_AC_TAGVAR(archive_cmds, $1) \
5042
_LT_AC_TAGVAR(archive_expsym_cmds, $1) \
5043
_LT_AC_TAGVAR(postinstall_cmds, $1) \
5044
_LT_AC_TAGVAR(postuninstall_cmds, $1) \
5045
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
5046
_LT_AC_TAGVAR(allow_undefined_flag, $1) \
5047
_LT_AC_TAGVAR(no_undefined_flag, $1) \
5048
_LT_AC_TAGVAR(export_symbols_cmds, $1) \
5049
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
5050
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
5051
_LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
5052
_LT_AC_TAGVAR(hardcode_automatic, $1) \
5053
_LT_AC_TAGVAR(module_cmds, $1) \
5054
_LT_AC_TAGVAR(module_expsym_cmds, $1) \
5055
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
5056
_LT_AC_TAGVAR(exclude_expsyms, $1) \
5057
_LT_AC_TAGVAR(include_expsyms, $1); do
2535
reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
5060
_LT_AC_TAGVAR(old_archive_cmds, $1) | \
5061
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
5062
_LT_AC_TAGVAR(archive_cmds, $1) | \
5063
_LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
5064
_LT_AC_TAGVAR(module_cmds, $1) | \
5065
_LT_AC_TAGVAR(module_expsym_cmds, $1) | \
5066
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
5067
_LT_AC_TAGVAR(export_symbols_cmds, $1) | \
5068
extract_expsyms_cmds | reload_cmds | finish_cmds | \
5069
postinstall_cmds | postuninstall_cmds | \
2536
5070
old_postinstall_cmds | old_postuninstall_cmds | \
2537
export_symbols_cmds | archive_cmds | archive_expsym_cmds | \
2538
extract_expsyms_cmds | old_archive_from_expsyms_cmds | \
2539
postinstall_cmds | postuninstall_cmds | \
2540
finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
5071
sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
2541
5072
# Double-quote double-evaled strings.
2542
5073
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
2852
cygwin* | mingw* | pw32* | os2*)
2853
cat <<'EOF' >> "${ofile}T"
2854
# This is a source program that is used to create dlls on Windows
2855
# Don't remove nor modify the starting and closing comments
5457
# We use sed instead of cat because bash on DJGPP gets confused if
5458
# if finds mixed CR/LF and LF-only lines. Since sed operates in
5459
# text mode, it properly converts lines to CR/LF. This bash problem
5460
# is reportedly fixed, but why not run on old versions too?
5461
sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
5463
mv -f "$cfgfile" "$ofile" || \
5464
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
5468
# If there is no Makefile yet, we rely on a make rule to execute
5469
# `config.status --recheck' to rerun these tests and create the
5470
# libtool script then.
5471
ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
5472
if test -f "$ltmain_in"; then
5473
test -f Makefile && make "$ltmain"
5476
])# AC_LIBTOOL_CONFIG
5479
# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
5480
# -------------------------------------------
5481
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
5482
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
5484
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5486
if test "$GCC" = yes; then
5487
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5489
AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
5490
lt_cv_prog_compiler_rtti_exceptions,
5491
[-fno-rtti -fno-exceptions], [],
5492
[_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
5494
])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
5497
# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5498
# ---------------------------------
5499
AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
5500
[AC_REQUIRE([AC_CANONICAL_HOST])
5501
AC_REQUIRE([AC_PROG_NM])
5502
AC_REQUIRE([AC_OBJEXT])
5503
# Check for command to grab the raw symbol name followed by C symbol from nm.
5504
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
5505
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
5507
# These are sane defaults that work on at least a few old systems.
5508
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
5510
# Character class describing NM global symbol codes.
5511
symcode='[[BCDEGRST]]'
5513
# Regexp to match symbols that can be accessed directly from C.
5514
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
5516
# Transform the above into a raw symbol and a C symbol.
5517
symxfrm='\1 \2\3 \3'
5519
# Transform an extracted symbol line into a proper C declaration
5520
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
5522
# Transform an extracted symbol line into symbol name and symbol address
5523
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'"
5525
# Define system-specific variables.
5530
cygwin* | mingw* | pw32*)
5531
symcode='[[ABCDGISTW]]'
5533
hpux*) # Its linker distinguishes data from code symbols
5534
if test "$host_cpu" = ia64; then
5535
symcode='[[ABCDEGRST]]'
5537
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5538
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'"
5541
if test "$host_cpu" = ia64; then
5542
symcode='[[ABCDGIRSTW]]'
5543
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5544
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'"
5548
symcode='[[BCDEGRST]]'
5551
symcode='[[BCDEGQRST]]'
5557
symcode='[[DFNSTU]]'
5561
# Handle CRLF in mingw tool chain
5565
opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5569
# If we're using GNU nm, then use its standard symbol codes.
5570
case `$NM -V 2>&1` in
5571
*GNU* | *'with BFD'*)
5572
symcode='[[ABCDGIRSTW]]' ;;
5575
# Try without a prefix undercore, then with it.
5576
for ac_symprfx in "" "_"; do
5578
# Write the raw and C identifiers.
5579
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
5581
# Check to see that the pipe works correctly.
5585
cat > conftest.$ac_ext <<EOF
5590
void nm_test_func(){}
5594
int main(){nm_test_var='a';nm_test_func();return(0);}
5597
if AC_TRY_EVAL(ac_compile); then
5598
# Now try to grab the symbols.
5600
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5601
# Try sorting and uniquifying the output.
5602
if sort "$nlist" | uniq > "$nlist"T; then
5603
mv -f "$nlist"T "$nlist"
5608
# Make sure that we snagged all the symbols we need.
5609
if grep ' nm_test_var$' "$nlist" >/dev/null; then
5610
if grep ' nm_test_func$' "$nlist" >/dev/null; then
5611
cat <<EOF > conftest.$ac_ext
5617
# Now generate the symbol file.
5618
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
5620
cat <<EOF >> conftest.$ac_ext
5621
#if defined (__STDC__) && __STDC__
5622
# define lt_ptr_t void *
5624
# define lt_ptr_t char *
5628
/* The mapping between symbol names and symbols. */
5633
lt_preloaded_symbols[[]] =
5636
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
5637
cat <<\EOF >> conftest.$ac_ext
5645
# Now try linking the two files.
5646
mv conftest.$ac_objext conftstm.$ac_objext
5647
lt_save_LIBS="$LIBS"
5648
lt_save_CFLAGS="$CFLAGS"
5649
LIBS="conftstm.$ac_objext"
5650
CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5651
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5654
LIBS="$lt_save_LIBS"
5655
CFLAGS="$lt_save_CFLAGS"
5657
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5660
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5663
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5666
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5667
cat conftest.$ac_ext >&5
5669
rm -f conftest* conftst*
5671
# Do not use the global_symbol_pipe unless it works.
5672
if test "$pipe_works" = yes; then
5675
lt_cv_sys_global_symbol_pipe=
5679
if test -z "$lt_cv_sys_global_symbol_pipe"; then
5680
lt_cv_sys_global_symbol_to_cdecl=
5682
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5683
AC_MSG_RESULT(failed)
5687
]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5690
# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
5691
# ---------------------------------------
5692
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
5693
[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
5694
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5695
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
5697
AC_MSG_CHECKING([for $compiler option to produce PIC])
5699
# C++ specific cases for pic, static, wl, etc.
5700
if test "$GXX" = yes; then
5701
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5702
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5706
# All AIX code is PIC.
5707
if test "$host_cpu" = ia64; then
5708
# AIX 5 now supports IA64 processor
5709
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5713
# FIXME: we need at least 68020 code to build shared libraries, but
5714
# adding the `-m68020' flag to GCC prevents building anything better,
5716
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5718
beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5719
# PIC is the default for these OSes.
5721
mingw* | os2* | pw32*)
5722
# This hack is so that the source file can tell whether it is being
5723
# built for inclusion in a dll (and should export symbols for example).
5724
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5726
darwin* | rhapsody*)
5727
# PIC is the default on this platform
5728
# Common symbols not allowed in MH_DYLIB files
5729
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5732
# DJGPP does not support shared libraries at all
5733
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5736
if test -d /usr/nec; then
5737
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5741
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5747
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5752
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5758
# All AIX code is PIC.
5759
if test "$host_cpu" = ia64; then
5760
# AIX 5 now supports IA64 processor
5761
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5763
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5767
case $cc_basename in
5769
# Green Hills C++ Compiler
5770
# _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"
5775
# PIC is the default on this platform
5776
# Common symbols not allowed in MH_DYLIB files
5777
case "$cc_basename" in
5779
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
5780
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5785
case $cc_basename in
5787
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5790
# Green Hills C++ Compiler
5791
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5797
freebsd* | kfreebsd*-gnu)
5798
# FreeBSD uses GNU C++
5800
hpux9* | hpux10* | hpux11*)
5801
case $cc_basename in
5803
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5804
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
5805
if test "$host_cpu" != ia64; then
5806
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5810
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5811
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
5817
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5825
irix5* | irix6* | nonstopux*)
5826
case $cc_basename in
5828
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5829
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5830
# CC pic flag -KPIC is the default.
5837
case $cc_basename in
5840
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5841
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5845
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5846
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5847
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5851
# Make sure the PIC flag is empty. It appears that all Alpha
5852
# Linux and Compaq Tru64 Unix objects are PIC.
5853
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5854
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5865
case $cc_basename in
5867
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
5875
osf3* | osf4* | osf5*)
5876
case $cc_basename in
5878
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5881
# Rational C++ 2.4.1
5882
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5885
# Digital/Compaq C++
5886
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5887
# Make sure the PIC flag is empty. It appears that all Alpha
5888
# Linux and Compaq Tru64 Unix objects are PIC.
5889
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5890
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5899
case $cc_basename in
5901
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5908
case $cc_basename in
5910
# Sun C++ 4.2, 5.x and Centerline C++
5911
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5912
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5913
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5916
# Green Hills C++ Compiler
5917
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5924
case $cc_basename in
5927
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5928
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5932
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5939
case $cc_basename in
5941
# NonStop-UX NCC 3.20
5942
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5953
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5959
if test "$GCC" = yes; then
5960
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5961
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5965
# All AIX code is PIC.
5966
if test "$host_cpu" = ia64; then
5967
# AIX 5 now supports IA64 processor
5968
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5973
# FIXME: we need at least 68020 code to build shared libraries, but
5974
# adding the `-m68020' flag to GCC prevents building anything better,
5976
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5979
beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5980
# PIC is the default for these OSes.
5983
mingw* | pw32* | os2*)
5984
# This hack is so that the source file can tell whether it is being
5985
# built for inclusion in a dll (and should export symbols for example).
5986
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5989
darwin* | rhapsody*)
5990
# PIC is the default on this platform
5991
# Common symbols not allowed in MH_DYLIB files
5992
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5996
# Just because we use GCC doesn't mean we suddenly get shared libraries
5997
# on systems that don't support them.
5998
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6003
if test -d /usr/nec; then
6004
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
6009
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6016
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6022
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6026
# PORTME Check for flag to pass linker flags through the system compiler.
6029
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6030
if test "$host_cpu" = ia64; then
6031
# AIX 5 now supports IA64 processor
6032
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6034
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
6038
# PIC is the default on this platform
6039
# Common symbols not allowed in MH_DYLIB files
6040
case "$cc_basename" in
6042
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
6043
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6048
mingw* | pw32* | os2*)
6049
# This hack is so that the source file can tell whether it is being
6050
# built for inclusion in a dll (and should export symbols for example).
6051
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
6054
hpux9* | hpux10* | hpux11*)
6055
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6056
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6063
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6066
# Is there a better lt_prog_compiler_static that works with the bundled CC?
6067
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6070
irix5* | irix6* | nonstopux*)
6071
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6072
# PIC (with -KPIC) is the default.
6073
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6077
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6078
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6084
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6085
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6086
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6089
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6090
# All Alpha code is PIC.
6091
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6096
osf3* | osf4* | osf5*)
6097
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6098
# All OSF/1 code is PIC.
6099
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6103
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
6104
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
6108
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6109
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6110
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6114
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6115
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6116
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6119
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6120
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6121
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6122
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6126
if test -d /usr/nec ;then
6127
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
6128
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6133
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6134
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6138
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6143
AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
6146
# Check to make sure the PIC flag actually works.
6148
if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
6149
AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
6150
_LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
6151
[$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
6152
[case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
6154
*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
6156
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6157
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
6160
# For platforms which do not support PIC, -DPIC is meaningless:
6162
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6165
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
6171
# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
6172
# ------------------------------------
6173
# See if the linker supports building shared libraries.
6174
AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
6175
[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6177
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6180
# If we're using GNU nm, then we don't want the "-C" option.
6181
# -C means demangle to AIX nm, but means don't demangle with GNU nm
6182
if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6183
_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'
6185
_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'
6189
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
6192
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
6195
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6200
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
6201
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6202
_LT_AC_TAGVAR(archive_cmds, $1)=
6203
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
6204
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
6205
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
6206
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6207
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6208
_LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
6209
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6210
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6211
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6212
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6213
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6214
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6215
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
6216
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
6217
_LT_AC_TAGVAR(module_cmds, $1)=
6218
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
6219
_LT_AC_TAGVAR(always_export_symbols, $1)=no
6220
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6221
# include_expsyms should be a list of space-separated symbols to be *always*
6222
# included in the symbol list
6223
_LT_AC_TAGVAR(include_expsyms, $1)=
6224
# exclude_expsyms can be an extended regexp of symbols to exclude
6225
# it will be wrapped by ` (' and `)$', so one must not match beginning or
6226
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
6227
# as well as any symbol that contains `d'.
6228
_LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
6229
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
6230
# platforms (ab)use it in PIC code, but their linkers get confused if
6231
# the symbol is explicitly referenced. Since portable code cannot
6232
# rely on this symbol name, it's probably fine to never include it in
6233
# preloaded symbol tables.
6234
extract_expsyms_cmds=
6237
cygwin* | mingw* | pw32*)
6238
# FIXME: the MSVC++ port hasn't been tested in a loooong time
6239
# When not using gcc, we currently assume that we are using
6240
# Microsoft Visual C++.
6241
if test "$GCC" != yes; then
6250
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
6251
if test "$with_gnu_ld" = yes; then
6252
# If archive_cmds runs LD, not CC, wlarc should be empty
6255
# See if GNU ld supports shared libraries.
6257
aix3* | aix4* | aix5*)
6258
# On AIX/PPC, the GNU linker is very broken
6259
if test "$host_cpu" != ia64; then
6260
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6263
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
6264
*** to be unable to reliably create shared libraries on AIX.
6265
*** Therefore, libtool is disabling shared libraries support. If you
6266
*** really care for shared libraries, you may want to modify your PATH
6267
*** so that a non-GNU linker is found, and then restart.
6274
_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)'
6275
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6276
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6278
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
6279
# that the semantics of dynamic libraries on AmigaOS, at least up
6280
# to version 4, is to share data among multiple programs linked
6281
# with the same dynamic library. Since this doesn't match the
6282
# behavior of shared libraries on other platforms, we can't use
6284
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6288
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6289
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6290
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6291
# support --undefined. This deserves some investigation. FIXME
6292
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6294
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6298
cygwin* | mingw* | pw32*)
6299
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6300
# as there is no search path for DLLs.
6301
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6302
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6303
_LT_AC_TAGVAR(always_export_symbols, $1)=no
6304
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6305
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
6307
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
6308
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
6309
# If the export-symbols file already is a .def file (1st line
6310
# is EXPORTS), use it as is; otherwise, prepend...
6311
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6312
cp $export_symbols $output_objdir/$soname.def;
6314
echo EXPORTS > $output_objdir/$soname.def;
6315
cat $export_symbols >> $output_objdir/$soname.def;
6317
$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
6324
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6325
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6328
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6329
_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'
6334
if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
6335
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6338
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
6339
*** create shared libraries on Solaris systems. Therefore, libtool
6340
*** is disabling shared libraries support. We urge you to upgrade GNU
6341
*** binutils to release 2.9.1 or newer. Another option is to modify
6342
*** your PATH or compiler configuration so that the native linker is
6343
*** used, and then restart.
6346
elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6347
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6348
_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'
6350
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6355
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6357
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6358
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6362
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6363
tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6364
_LT_AC_TAGVAR(archive_cmds, $1)="$tmp_archive_cmds"
6365
supports_anon_versioning=no
6366
case `$LD -v 2>/dev/null` in
6367
*\ [01].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6368
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6369
*\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6370
*\ 2.11.*) ;; # other 2.11 versions
6371
*) supports_anon_versioning=yes ;;
6373
if test $supports_anon_versioning = yes; then
6374
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
6375
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6376
$echo "local: *; };" >> $output_objdir/$libname.ver~
6377
$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6379
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="$tmp_archive_cmds"
6382
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6387
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6388
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6389
_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'
6391
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6396
if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = yes; then
6397
runpath_var=LD_RUN_PATH
6398
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6399
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6400
# ancient GNU ld didn't support --whole-archive et. al.
6401
if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
6402
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6404
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6408
# PORTME fill in a description of your system's linker (not GNU ld)
6411
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6412
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6413
_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'
6414
# Note: this linker hardcodes the directories in LIBPATH if there
6415
# are no directories specified by -L.
6416
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6417
if test "$GCC" = yes && test -z "$link_static_flag"; then
6418
# Neither direct hardcoding nor static linking is supported with a
6420
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6425
if test "$host_cpu" = ia64; then
6426
# On IA64, the linker does run time linking by default, so we don't
6427
# have to do anything special.
6428
aix_use_runtimelinking=no
6429
exp_sym_flag='-Bexport'
6432
# If we're using GNU nm, then we don't want the "-C" option.
6433
# -C means demangle to AIX nm, but means don't demangle with GNU nm
6434
if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6435
_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'
6437
_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'
6439
aix_use_runtimelinking=no
6441
# Test if we are trying to use run time linking or normal
6442
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
6443
# need to do runtime linking.
6444
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
6445
for ld_flag in $LDFLAGS; do
6446
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6447
aix_use_runtimelinking=yes
6453
exp_sym_flag='-bexport'
6454
no_entry_flag='-bnoentry'
6457
# When large executables or shared objects are built, AIX ld can
6458
# have problems creating the table of contents. If linking a library
6459
# or program results in "error TOC overflow" add -mminimal-toc to
6460
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6461
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6463
_LT_AC_TAGVAR(archive_cmds, $1)=''
6464
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6465
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6466
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6468
if test "$GCC" = yes; then
6469
case $host_os in aix4.[012]|aix4.[012].*)
6470
# We only want to do this on AIX 4.2 and lower, the check
6471
# below for broken collect2 doesn't work under 4.3+
6472
collect2name=`${CC} -print-prog-name=collect2`
6473
if test -f "$collect2name" && \
6474
strings "$collect2name" | grep resolve_lib_name >/dev/null
6476
# We have reworked collect2
6477
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6479
# We have old collect2
6480
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6481
# It fails to find uninstalled libraries when the uninstalled
6482
# path is not listed in the libpath. Setting hardcode_minus_L
6483
# to unsupported forces relinking
6484
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6485
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6486
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6489
shared_flag='-shared'
6492
if test "$host_cpu" = ia64; then
6493
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6494
# chokes on -Wl,-G. The following line is correct:
6497
if test "$aix_use_runtimelinking" = yes; then
6498
shared_flag='${wl}-G'
6500
shared_flag='${wl}-bM:SRE'
6505
# It seems that -bexpall does not export symbols beginning with
6506
# underscore (_), so it is better to generate a list of symbols to export.
6507
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6508
if test "$aix_use_runtimelinking" = yes; then
6509
# Warning - without using the other runtime loading flags (-brtl),
6510
# -berok will link without error, but may produce a broken library.
6511
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
6512
# Determine the default libpath from the value encoded in an empty executable.
6513
_LT_AC_SYS_LIBPATH_AIX
6514
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6515
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6517
if test "$host_cpu" = ia64; then
6518
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6519
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6520
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
6522
# Determine the default libpath from the value encoded in an empty executable.
6523
_LT_AC_SYS_LIBPATH_AIX
6524
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6525
# Warning - without using the other run time loading flags,
6526
# -berok will link without error, but may produce a broken library.
6527
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6528
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6529
# -bexpall does not export symbols beginning with underscore (_)
6530
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6531
# Exported symbols can be pulled into shared objects from archives
6532
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
6533
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6534
# This is similar to how AIX traditionally builds it's shared libraries.
6535
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6541
_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)'
6542
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6543
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6544
# see comment about different semantics on the GNU ld section
6545
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6549
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6552
cygwin* | mingw* | pw32*)
6553
# When not using gcc, we currently assume that we are using
6554
# Microsoft Visual C++.
6555
# hardcode_libdir_flag_spec is actually meaningless, as there is
6556
# no search path for DLLs.
6557
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6558
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6559
# Tell ltmain to make .lib files, not .a files.
6561
# Tell ltmain to make .dll files, not .so files.
6563
# FIXME: Setting linknames here is a bad hack.
6564
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
6565
# The linker will automatically build a .lib file if we build a DLL.
6566
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
6567
# FIXME: Should let the user specify the lib program.
6568
_LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
6569
fix_srcfile_path='`cygpath -w "$srcfile"`'
6570
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6573
darwin* | rhapsody*)
6575
rhapsody* | darwin1.[[012]])
6576
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
6579
if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
6580
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6582
case ${MACOSX_DEPLOYMENT_TARGET} in
6584
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6587
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
6593
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6594
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6595
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
6596
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6597
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
6598
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6599
if test "$GCC" = yes ; then
6600
output_verbose_link_cmd='echo'
6601
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
6602
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6603
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
6604
_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}'
6605
_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}'
6607
case "$cc_basename" in
6609
output_verbose_link_cmd='echo'
6610
_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'
6611
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
6612
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
6613
_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}'
6614
_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}'
6617
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6624
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6625
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6626
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6630
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6633
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
6634
# support. Future versions do this automatically, but an explicit c++rt0.o
6635
# does not break anything, and helps significantly (at the cost of a little
6638
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
6639
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6640
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6641
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6644
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
6646
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6647
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6648
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6649
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6652
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
6653
freebsd* | kfreebsd*-gnu)
6654
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
6655
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6656
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6657
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6661
if test "$GCC" = yes; then
6662
_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'
6664
_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'
6666
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6667
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6668
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6670
# hardcode_minus_L: Not really in the search PATH,
6671
# but as the default location of the library.
6672
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6673
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6677
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
6680
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6683
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
6689
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
6692
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
6696
if test "$with_gnu_ld" = no; then
6699
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6700
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
6701
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6702
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6703
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6706
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6707
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6708
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6710
# hardcode_minus_L: Not really in the search PATH,
6711
# but as the default location of the library.
6712
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6715
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6716
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6717
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6718
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6720
# hardcode_minus_L: Not really in the search PATH,
6721
# but as the default location of the library.
6722
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6728
irix5* | irix6* | nonstopux*)
6729
if test "$GCC" = yes; then
6730
_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'
6732
_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'
6733
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
6735
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6736
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6737
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6741
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6742
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
6744
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
6746
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6747
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6748
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6752
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6753
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6754
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6755
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6756
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6760
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6761
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6762
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6763
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6764
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
6765
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6766
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6769
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
6770
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6771
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6774
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
6775
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6782
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6783
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6784
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6785
_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'
6786
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
6790
if test "$GCC" = yes; then
6791
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6792
_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'
6794
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6795
_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'
6797
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6798
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6801
osf4* | osf5*) # as osf3* with the addition of -msym flag
6802
if test "$GCC" = yes; then
6803
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6804
_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'
6805
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6807
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6808
_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'
6809
_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~
6810
$LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
6812
# Both c and cxx compiler support -rpath directly
6813
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6815
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
6819
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6820
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6821
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6822
runpath_var=LD_RUN_PATH
6823
hardcode_runpath_var=yes
6827
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6828
if test "$GCC" = yes; then
6829
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6830
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6831
$CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
6833
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6834
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6835
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6837
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6838
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6840
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6841
*) # Supported since Solaris 2.6 (maybe 2.5.1?)
6842
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
6844
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6848
if test "x$host_vendor" = xsequent; then
6849
# Use $CC to link under sequent, because it throws in some extra .o
6850
# files that make .init and .fini sections work.
6851
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
6853
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
6855
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6856
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6857
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6858
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6862
case $host_vendor in
6864
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6865
_LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
6868
## LD is ld it makes a PLAMLIB
6869
## CC just makes a GrossModule.
6870
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6871
_LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
6872
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6875
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6876
_LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
6879
runpath_var='LD_RUN_PATH'
6880
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6884
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6885
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6886
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
6890
if test -d /usr/nec; then
6891
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6892
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6893
runpath_var=LD_RUN_PATH
6894
hardcode_runpath_var=yes
6895
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
6900
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
6901
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6902
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6903
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6904
hardcode_runpath_var=yes
6905
runpath_var=LD_RUN_PATH
6908
sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
6909
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
6910
if test "$GCC" = yes; then
6911
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6913
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
6915
runpath_var='LD_RUN_PATH'
6916
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6920
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
6921
# $CC -shared without GNU ld will not create a library from C++
6922
# object files and a static libstdc++, better avoid it by now
6923
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
6924
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
6925
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
6926
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6927
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6928
runpath_var='LD_RUN_PATH'
6932
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
6933
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6934
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6938
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6943
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
6944
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6946
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
6947
if test "$GCC" = yes; then
6948
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
6952
# Do we need to explicitly link libc?
6954
case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
6956
# Assume -lc should be added
6957
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6959
if test "$enable_shared" = yes && test "$GCC" = yes; then
6960
case $_LT_AC_TAGVAR(archive_cmds, $1) in
6962
# FIXME: we may have to deal with multi-command sequences.
6965
# Test whether the compiler implicitly links with -lc since on some
6966
# systems, -lgcc has to come before -lc. If gcc already passes -lc
6967
# to ld, don't add -lc before -lgcc.
6968
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
6970
printf "$lt_simple_compile_test_code" > conftest.$ac_ext
6972
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
6975
libobjs=conftest.$ac_objext
6977
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
6983
lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
6984
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
6985
if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
6987
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6989
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6991
_LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
6993
cat conftest.err 1>&5
6996
AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
7002
])# AC_LIBTOOL_PROG_LD_SHLIBS
7005
# _LT_AC_FILE_LTDLL_C
7006
# -------------------
7007
# Be careful that the start marker always follows a newline.
7008
AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
2856
7009
# /* ltdll.c starts here */
2857
7010
# #define WIN32_LEAN_AND_MEAN
2858
7011
# #include <windows.h>
2888
7041
# /* ltdll.c ends here */
2889
# This is a source program that is used to create import libraries
2890
# on Windows for dlls which lack them. Don't remove nor modify the
2891
# starting and closing comments
2892
# /* impgen.c starts here */
2893
# /* Copyright (C) 1999-2000 Free Software Foundation, Inc.
2895
# This file is part of GNU libtool.
2897
# This program is free software; you can redistribute it and/or modify
2898
# it under the terms of the GNU General Public License as published by
2899
# the Free Software Foundation; either version 2 of the License, or
2900
# (at your option) any later version.
2902
# This program is distributed in the hope that it will be useful,
2903
# but WITHOUT ANY WARRANTY; without even the implied warranty of
2904
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2905
# GNU General Public License for more details.
2907
# You should have received a copy of the GNU General Public License
2908
# along with this program; if not, write to the Free Software
2909
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
2912
# #include <stdio.h> /* for printf() */
2913
# #include <unistd.h> /* for open(), lseek(), read() */
2914
# #include <fcntl.h> /* for O_RDONLY, O_BINARY */
2915
# #include <string.h> /* for strdup() */
2917
# /* O_BINARY isn't required (or even defined sometimes) under Unix */
2919
# #define O_BINARY 0
2922
# static unsigned int
2923
# pe_get16 (fd, offset)
2927
# unsigned char b[2];
2928
# lseek (fd, offset, SEEK_SET);
2930
# return b[0] + (b[1]<<8);
2933
# static unsigned int
2934
# pe_get32 (fd, offset)
2938
# unsigned char b[4];
2939
# lseek (fd, offset, SEEK_SET);
2941
# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
2944
# static unsigned int
2948
# unsigned char *b = ptr;
2949
# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
2958
# unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
2959
# unsigned long export_rva, export_size, nsections, secptr, expptr;
2960
# unsigned long name_rvas, nexp;
2961
# unsigned char *expdata, *erva;
2962
# char *filename, *dll_name;
2964
# filename = argv[1];
2966
# dll = open(filename, O_RDONLY|O_BINARY);
2970
# dll_name = filename;
2972
# for (i=0; filename[i]; i++)
2973
# if (filename[i] == '/' || filename[i] == '\\' || filename[i] == ':')
2974
# dll_name = filename + i +1;
2976
# pe_header_offset = pe_get32 (dll, 0x3c);
2977
# opthdr_ofs = pe_header_offset + 4 + 20;
2978
# num_entries = pe_get32 (dll, opthdr_ofs + 92);
2980
# if (num_entries < 1) /* no exports */
2983
# export_rva = pe_get32 (dll, opthdr_ofs + 96);
2984
# export_size = pe_get32 (dll, opthdr_ofs + 100);
2985
# nsections = pe_get16 (dll, pe_header_offset + 4 +2);
2986
# secptr = (pe_header_offset + 4 + 20 +
2987
# pe_get16 (dll, pe_header_offset + 4 + 16));
2990
# for (i = 0; i < nsections; i++)
2993
# unsigned long secptr1 = secptr + 40 * i;
2994
# unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
2995
# unsigned long vsize = pe_get32 (dll, secptr1 + 16);
2996
# unsigned long fptr = pe_get32 (dll, secptr1 + 20);
2997
# lseek(dll, secptr1, SEEK_SET);
2998
# read(dll, sname, 8);
2999
# if (vaddr <= export_rva && vaddr+vsize > export_rva)
3001
# expptr = fptr + (export_rva - vaddr);
3002
# if (export_rva + export_size > vaddr + vsize)
3003
# export_size = vsize - (export_rva - vaddr);
3008
# expdata = (unsigned char*)malloc(export_size);
3009
# lseek (dll, expptr, SEEK_SET);
3010
# read (dll, expdata, export_size);
3011
# erva = expdata - export_rva;
3013
# nexp = pe_as32 (expdata+24);
3014
# name_rvas = pe_as32 (expdata+32);
3016
# printf ("EXPORTS\n");
3017
# for (i = 0; i<nexp; i++)
3019
# unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
3020
# printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
3025
# /* impgen.c ends here */
3031
# We use sed instead of cat because bash on DJGPP gets confused if
3032
# if finds mixed CR/LF and LF-only lines. Since sed operates in
3033
# text mode, it properly converts lines to CR/LF. This bash problem
3034
# is reportedly fixed, but why not run on old versions too?
3035
sed '$q' "$ltmain" >> "${ofile}T" || (rm -f "${ofile}T"; exit 1)
3037
mv -f "${ofile}T" "$ofile" || \
3038
(rm -f "$ofile" && cp "${ofile}T" "$ofile" && rm -f "${ofile}T")
3042
])# _LT_AC_LTCONFIG_HACK
3044
# AC_LIBTOOL_DLOPEN - enable checks for dlopen support
3045
AC_DEFUN([AC_LIBTOOL_DLOPEN], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])])
3047
# AC_LIBTOOL_WIN32_DLL - declare package support for building win32 dll's
3048
AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])])
3050
# AC_ENABLE_SHARED - implement the --enable-shared flag
3051
# Usage: AC_ENABLE_SHARED[(DEFAULT)]
3052
# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
3054
AC_DEFUN([AC_ENABLE_SHARED],
3055
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
3056
AC_ARG_ENABLE(shared,
3057
changequote(<<, >>)dnl
3058
<< --enable-shared[=PKGS] build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
3059
changequote([, ])dnl
3060
[p=${PACKAGE-default}
3062
yes) enable_shared=yes ;;
3063
no) enable_shared=no ;;
3066
# Look at the argument we got. We use all the common list separators.
3067
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3068
for pkg in $enableval; do
3069
if test "X$pkg" = "X$p"; then
3076
enable_shared=AC_ENABLE_SHARED_DEFAULT)dnl
3079
# AC_DISABLE_SHARED - set the default shared flag to --disable-shared
3080
AC_DEFUN([AC_DISABLE_SHARED],
3081
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3082
AC_ENABLE_SHARED(no)])
3084
# AC_ENABLE_STATIC - implement the --enable-static flag
3085
# Usage: AC_ENABLE_STATIC[(DEFAULT)]
3086
# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
3088
AC_DEFUN([AC_ENABLE_STATIC],
3089
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
3090
AC_ARG_ENABLE(static,
3091
changequote(<<, >>)dnl
3092
<< --enable-static[=PKGS] build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
3093
changequote([, ])dnl
3094
[p=${PACKAGE-default}
3096
yes) enable_static=yes ;;
3097
no) enable_static=no ;;
3100
# Look at the argument we got. We use all the common list separators.
3101
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3102
for pkg in $enableval; do
3103
if test "X$pkg" = "X$p"; then
3110
enable_static=AC_ENABLE_STATIC_DEFAULT)dnl
3113
# AC_DISABLE_STATIC - set the default static flag to --disable-static
3114
AC_DEFUN([AC_DISABLE_STATIC],
3115
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3116
AC_ENABLE_STATIC(no)])
3119
# AC_ENABLE_FAST_INSTALL - implement the --enable-fast-install flag
3120
# Usage: AC_ENABLE_FAST_INSTALL[(DEFAULT)]
3121
# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
3123
AC_DEFUN([AC_ENABLE_FAST_INSTALL],
3124
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
3125
AC_ARG_ENABLE(fast-install,
3126
changequote(<<, >>)dnl
3127
<< --enable-fast-install[=PKGS] optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
3128
changequote([, ])dnl
3129
[p=${PACKAGE-default}
3131
yes) enable_fast_install=yes ;;
3132
no) enable_fast_install=no ;;
3134
enable_fast_install=no
3135
# Look at the argument we got. We use all the common list separators.
3136
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3137
for pkg in $enableval; do
3138
if test "X$pkg" = "X$p"; then
3139
enable_fast_install=yes
3145
enable_fast_install=AC_ENABLE_FAST_INSTALL_DEFAULT)dnl
3148
# AC_DISABLE_FAST_INSTALL - set the default to --disable-fast-install
3149
AC_DEFUN([AC_DISABLE_FAST_INSTALL],
3150
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3151
AC_ENABLE_FAST_INSTALL(no)])
3153
# AC_LIBTOOL_PICMODE - implement the --with-pic flag
3154
# Usage: AC_LIBTOOL_PICMODE[(MODE)]
3155
# Where MODE is either `yes' or `no'. If omitted, it defaults to
3157
AC_DEFUN([AC_LIBTOOL_PICMODE],
3158
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3159
pic_mode=ifelse($#,1,$1,default)])
3162
# AC_PATH_TOOL_PREFIX - find a file program which can recognise shared library
3163
AC_DEFUN([AC_PATH_TOOL_PREFIX],
3164
[AC_MSG_CHECKING([for $1])
3165
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3168
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3171
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3174
ac_save_MAGIC_CMD="$MAGIC_CMD"
3175
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3176
dnl $ac_dummy forces splitting on constant user-supplied paths.
3177
dnl POSIX.2 word splitting is done only on the output of word expansions,
3178
dnl not every word. This closes a longstanding sh security hole.
3179
ac_dummy="ifelse([$2], , $PATH, [$2])"
3180
for ac_dir in $ac_dummy; do
3181
test -z "$ac_dir" && ac_dir=.
3182
if test -f $ac_dir/$1; then
3183
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3184
if test -n "$file_magic_test_file"; then
3185
case $deplibs_check_method in
3187
file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3188
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3189
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3190
egrep "$file_magic_regex" > /dev/null; then
3195
*** Warning: the command libtool uses to detect shared libraries,
3196
*** $file_magic_cmd, produces output that libtool cannot recognize.
3197
*** The result is that libtool may fail to recognize shared libraries
3198
*** as such. This will affect the creation of libtool libraries that
3199
*** depend on shared libraries, but programs linked with such libtool
3200
*** libraries will work regardless of this problem. Nevertheless, you
3201
*** may want to report the problem to your system manager and/or to
3202
*** bug-libtool@gnu.org
3212
MAGIC_CMD="$ac_save_MAGIC_CMD"
3215
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3216
if test -n "$MAGIC_CMD"; then
3217
AC_MSG_RESULT($MAGIC_CMD)
3224
# AC_PATH_MAGIC - find a file program which can recognise a shared library
3225
AC_DEFUN([AC_PATH_MAGIC],
3226
[AC_REQUIRE([AC_CHECK_TOOL_PREFIX])dnl
3227
AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin:$PATH)
3228
if test -z "$lt_cv_path_MAGIC_CMD"; then
3229
if test -n "$ac_tool_prefix"; then
3230
AC_PATH_TOOL_PREFIX(file, /usr/bin:$PATH)
3238
# AC_PROG_LD - find the path to the GNU or non-GNU linker
3239
AC_DEFUN([AC_PROG_LD],
3240
[AC_ARG_WITH(gnu-ld,
3241
[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
3242
test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
3243
AC_REQUIRE([AC_PROG_CC])dnl
3244
AC_REQUIRE([AC_CANONICAL_HOST])dnl
3245
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3247
if test "$GCC" = yes; then
3248
# Check if gcc -print-prog-name=ld gives a path.
3249
AC_MSG_CHECKING([for ld used by GCC])
3252
# gcc leaves a trailing carriage return which upsets mingw
3253
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3255
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3258
# Accept absolute paths.
3259
[[\\/]* | [A-Za-z]:[\\/]*)]
3260
[re_direlt='/[^/][^/]*/\.\./']
3261
# Canonicalize the path of ld
3262
ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
3263
while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3264
ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
3266
test -z "$LD" && LD="$ac_prog"
3269
# If it fails, then pretend we aren't using GCC.
3273
# If it is relative, then search for the first ld in PATH.
3277
elif test "$with_gnu_ld" = yes; then
3278
AC_MSG_CHECKING([for GNU ld])
3280
AC_MSG_CHECKING([for non-GNU ld])
3282
AC_CACHE_VAL(lt_cv_path_LD,
3283
[if test -z "$LD"; then
3284
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
3285
for ac_dir in $PATH; do
3286
test -z "$ac_dir" && ac_dir=.
3287
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3288
lt_cv_path_LD="$ac_dir/$ac_prog"
3289
# Check to see if the program is GNU ld. I'd rather use --version,
3290
# but apparently some GNU ld's only accept -v.
3291
# Break only if it was the GNU/non-GNU ld that we prefer.
3292
if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
3293
test "$with_gnu_ld" != no && break
3295
test "$with_gnu_ld" != yes && break
3301
lt_cv_path_LD="$LD" # Let the user override the test with a path.
3304
if test -n "$LD"; then
3309
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3314
AC_DEFUN([AC_PROG_LD_GNU],
3315
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3316
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
3317
if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
3318
lt_cv_prog_gnu_ld=yes
3320
lt_cv_prog_gnu_ld=no
3322
with_gnu_ld=$lt_cv_prog_gnu_ld
3325
# AC_PROG_LD_RELOAD_FLAG - find reload flag for linker
3326
# -- PORTME Some linkers may need a different reload flag.
3327
AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
3328
[AC_CACHE_CHECK([for $LD option to reload object files], lt_cv_ld_reload_flag,
3329
[lt_cv_ld_reload_flag='-r'])
3330
reload_flag=$lt_cv_ld_reload_flag
3331
test -n "$reload_flag" && reload_flag=" $reload_flag"
3334
# AC_DEPLIBS_CHECK_METHOD - how to check for library dependencies
3335
# -- PORTME fill in with the dynamic library characteristics
3336
AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
3337
[AC_CACHE_CHECK([how to recognise dependant libraries],
3338
lt_cv_deplibs_check_method,
3339
[lt_cv_file_magic_cmd='$MAGIC_CMD'
3340
lt_cv_file_magic_test_file=
3341
lt_cv_deplibs_check_method='unknown'
3342
# Need to set the preceding variable on all platforms that support
3343
# interlibrary dependencies.
3344
# 'none' -- dependencies not supported.
3345
# `unknown' -- same as none, but documents that we really don't know.
3346
# 'pass_all' -- all dependencies passed with no checks.
3347
# 'test_compile' -- check by making test program.
3348
# ['file_magic [regex]'] -- check by looking for files in library path
3349
# which responds to the $file_magic_cmd with a given egrep regex.
3350
# If you have `file' or equivalent on your system and you're not sure
3351
# whether `pass_all' will *always* work, you probably want this one.
3355
lt_cv_deplibs_check_method=pass_all
3359
lt_cv_deplibs_check_method=pass_all
3363
[lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)']
3364
lt_cv_file_magic_cmd='/usr/bin/file -L'
3365
lt_cv_file_magic_test_file=/shlib/libc.so
3368
cygwin* | mingw* | pw32*)
3369
lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3370
lt_cv_file_magic_cmd='$OBJDUMP -f'
3373
darwin* | rhapsody*)
3374
lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
3375
lt_cv_file_magic_cmd='/usr/bin/file -L'
3377
rhapsody* | darwin1.[012])
3378
lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1`
3381
lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
3387
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3390
# Not sure whether the presence of OpenBSD here was a mistake.
3391
# Let's accept both of them until this is cleared up.
3392
[lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library']
3393
lt_cv_file_magic_cmd=/usr/bin/file
3394
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3398
lt_cv_deplibs_check_method=pass_all
3403
lt_cv_deplibs_check_method=pass_all
3407
[lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library']
3408
lt_cv_file_magic_cmd=/usr/bin/file
3409
lt_cv_file_magic_test_file=/usr/lib/libc.sl
3415
# this will be overridden with pass_all, but let us keep it just in case
3416
lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
3420
*-32|*"-32 ") libmagic=32-bit;;
3421
*-n32|*"-n32 ") libmagic=N32;;
3422
*-64|*"-64 ") libmagic=64-bit;;
3423
*) libmagic=never-match;;
3425
# this will be overridden with pass_all, but let us keep it just in case
3426
[lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"]
3429
lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
3430
lt_cv_deplibs_check_method=pass_all
3433
# This must be Linux ELF.
3436
alpha* | i*86 | powerpc* | sparc* | ia64* )
3437
lt_cv_deplibs_check_method=pass_all ;;
3439
# glibc up to 2.1.1 does not perform some relocations on ARM
3440
[lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;]
3442
lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
3446
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3447
[lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$']
3449
[lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$']
3454
[lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)']
3455
lt_cv_file_magic_cmd=/usr/bin/file
3456
lt_cv_file_magic_test_file=/usr/lib/libnls.so
3459
osf3* | osf4* | osf5*)
3460
# this will be overridden with pass_all, but let us keep it just in case
3461
lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
3462
lt_cv_file_magic_test_file=/shlib/libc.so
3463
lt_cv_deplibs_check_method=pass_all
3467
lt_cv_deplibs_check_method=pass_all
3471
lt_cv_deplibs_check_method=pass_all
3472
lt_cv_file_magic_test_file=/lib/libc.so
3475
[sysv5uw[78]* | sysv4*uw2*)]
3476
lt_cv_deplibs_check_method=pass_all
3479
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
3480
case $host_vendor in
3482
[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]']
3483
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3486
lt_cv_deplibs_check_method=pass_all
3489
lt_cv_file_magic_cmd='/bin/file'
3490
[lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )']
3493
lt_cv_file_magic_cmd='/bin/file'
3494
[lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"]
3495
lt_cv_file_magic_test_file=/lib/libc.so
3501
file_magic_cmd=$lt_cv_file_magic_cmd
3502
deplibs_check_method=$lt_cv_deplibs_check_method
3506
# AC_PROG_NM - find the path to a BSD-compatible name lister
3507
AC_DEFUN([AC_PROG_NM],
3508
[AC_MSG_CHECKING([for BSD-compatible nm])
3509
AC_CACHE_VAL(lt_cv_path_NM,
3510
[if test -n "$NM"; then
3511
# Let the user override the test.
3514
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
3515
for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
3516
test -z "$ac_dir" && ac_dir=.
3517
tmp_nm=$ac_dir/${ac_tool_prefix}nm
3518
if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
3519
# Check to see if the nm accepts a BSD-compat flag.
3520
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
3521
# nm: unknown option "B" ignored
3522
# Tru64's nm complains that /dev/null is an invalid object file
3523
if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
3524
lt_cv_path_NM="$tmp_nm -B"
3526
elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
3527
lt_cv_path_NM="$tmp_nm -p"
3530
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3531
continue # so that we can try to find one that supports BSD flags
3536
test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3539
AC_MSG_RESULT([$NM])
3542
# AC_CHECK_LIBM - check for math library
3543
AC_DEFUN([AC_CHECK_LIBM],
3544
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3547
*-*-beos* | *-*-cygwin* | *-*-pw32*)
3548
# These system don't have libm
3551
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3552
AC_CHECK_LIB(m, main, LIBM="$LIBM -lm")
3555
AC_CHECK_LIB(m, main, LIBM="-lm")
3560
# AC_LIBLTDL_CONVENIENCE[(dir)] - sets LIBLTDL to the link flags for
3561
# the libltdl convenience library and INCLTDL to the include flags for
3562
# the libltdl header and adds --enable-ltdl-convenience to the
3563
# configure arguments. Note that LIBLTDL and INCLTDL are not
3564
# AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If DIR is not
3565
# provided, it is assumed to be `libltdl'. LIBLTDL will be prefixed
3566
# with '${top_builddir}/' and INCLTDL will be prefixed with
3567
# '${top_srcdir}/' (note the single quotes!). If your package is not
3568
# flat and you're not using automake, define top_builddir and
3569
# top_srcdir appropriately in the Makefiles.
3570
AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3571
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3572
case $enable_ltdl_convenience in
3573
no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3574
"") enable_ltdl_convenience=yes
3575
ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3577
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3578
INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3581
# AC_LIBLTDL_INSTALLABLE[(dir)] - sets LIBLTDL to the link flags for
3582
# the libltdl installable library and INCLTDL to the include flags for
3583
# the libltdl header and adds --enable-ltdl-install to the configure
3584
# arguments. Note that LIBLTDL and INCLTDL are not AC_SUBSTed, nor is
3585
# AC_CONFIG_SUBDIRS called. If DIR is not provided and an installed
3586
# libltdl is not found, it is assumed to be `libltdl'. LIBLTDL will
3587
# be prefixed with '${top_builddir}/' and INCLTDL will be prefixed
3588
# with '${top_srcdir}/' (note the single quotes!). If your package is
3589
# not flat and you're not using automake, define top_builddir and
3590
# top_srcdir appropriately in the Makefiles.
3591
# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3592
AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3593
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3594
AC_CHECK_LIB(ltdl, main,
3595
[test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3596
[if test x"$enable_ltdl_install" = xno; then
3597
AC_MSG_WARN([libltdl not installed, but installation disabled])
3599
enable_ltdl_install=yes
3602
if test x"$enable_ltdl_install" = x"yes"; then
3603
ac_configure_args="$ac_configure_args --enable-ltdl-install"
3604
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3605
INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3607
ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
7042
])# _LT_AC_FILE_LTDLL_C
7045
# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
7046
# ---------------------------------
7047
AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
3614
7051
AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])