~ubuntu-branches/ubuntu/hoary/eterm/hoary

« back to all changes in this revision

Viewing changes to aclocal.m4

  • Committer: Bazaar Package Importer
  • Author(s): Laurence J. Lane
  • Date: 2004-05-04 09:30:14 UTC
  • Revision ID: james.westby@ubuntu.com-20040504093014-1028s5aqsnrhh2gu
Tags: 0.9.2-8
src/startup.c: disable use of ~/user.cfg, patch provdided by Michael
Jennings. Thanks.

Show diffs side-by-side

added added

removed removed

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