1# generated automatically by aclocal 1.10.2 -*- Autoconf -*- 2 3# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 4# 2005, 2006, 2007, 2008 Free Software Foundation, Inc. 5# This file is free software; the Free Software Foundation 6# gives unlimited permission to copy and/or distribute it, 7# with or without modifications, as long as this notice is preserved. 8 9# This program is distributed in the hope that it will be useful, 10# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12# PARTICULAR PURPOSE. 13 14m4_ifndef([AC_AUTOCONF_VERSION], 15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 16m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.63],, 17[m4_warning([this file was generated for autoconf 2.63. 18You have another version of autoconf. It may work, but is not guaranteed to. 19If you have problems, you may need to regenerate the build system entirely. 20To do so, use the procedure documented by the package, typically `autoreconf'.])]) 21 22# Copyright (C) 1995-2002 Free Software Foundation, Inc. 23# Copyright (C) 2001-2003,2004 Red Hat, Inc. 24# 25# This file is free software, distributed under the terms of the GNU 26# General Public License. As a special exception to the GNU General 27# Public License, this file may be distributed as part of a program 28# that contains a configuration script generated by Autoconf, under 29# the same distribution terms as the rest of that program. 30# 31# This file can be copied and used freely without restrictions. It can 32# be used in projects which are not available under the GNU Public License 33# but which still want to provide support for the GNU gettext functionality. 34# 35# Macro to add for using GNU gettext. 36# Ulrich Drepper <drepper@cygnus.com>, 1995, 1996 37# 38# Modified to never use included libintl. 39# Owen Taylor <otaylor@redhat.com>, 12/15/1998 40# 41# Major rework to remove unused code 42# Owen Taylor <otaylor@redhat.com>, 12/11/2002 43# 44# Added better handling of ALL_LINGUAS from GNU gettext version 45# written by Bruno Haible, Owen Taylor <otaylor.redhat.com> 5/30/3002 46# 47# Modified to require ngettext 48# Matthias Clasen <mclasen@redhat.com> 08/06/2004 49# 50# We need this here as well, since someone might use autoconf-2.5x 51# to configure GLib then an older version to configure a package 52# using AM_GLIB_GNU_GETTEXT 53AC_PREREQ(2.53) 54 55dnl 56dnl We go to great lengths to make sure that aclocal won't 57dnl try to pull in the installed version of these macros 58dnl when running aclocal in the glib directory. 59dnl 60m4_copy([AC_DEFUN],[glib_DEFUN]) 61m4_copy([AC_REQUIRE],[glib_REQUIRE]) 62dnl 63dnl At the end, if we're not within glib, we'll define the public 64dnl definitions in terms of our private definitions. 65dnl 66 67# GLIB_LC_MESSAGES 68#-------------------- 69glib_DEFUN([GLIB_LC_MESSAGES], 70 [AC_CHECK_HEADERS([locale.h]) 71 if test $ac_cv_header_locale_h = yes; then 72 AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, 73 [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES], 74 am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) 75 if test $am_cv_val_LC_MESSAGES = yes; then 76 AC_DEFINE(HAVE_LC_MESSAGES, 1, 77 [Define if your <locale.h> file defines LC_MESSAGES.]) 78 fi 79 fi]) 80 81# GLIB_PATH_PROG_WITH_TEST 82#---------------------------- 83dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, 84dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) 85glib_DEFUN([GLIB_PATH_PROG_WITH_TEST], 86[# Extract the first word of "$2", so it can be a program name with args. 87set dummy $2; ac_word=[$]2 88AC_MSG_CHECKING([for $ac_word]) 89AC_CACHE_VAL(ac_cv_path_$1, 90[case "[$]$1" in 91 /*) 92 ac_cv_path_$1="[$]$1" # Let the user override the test with a path. 93 ;; 94 *) 95 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" 96 for ac_dir in ifelse([$5], , $PATH, [$5]); do 97 test -z "$ac_dir" && ac_dir=. 98 if test -f $ac_dir/$ac_word; then 99 if [$3]; then 100 ac_cv_path_$1="$ac_dir/$ac_word" 101 break 102 fi 103 fi 104 done 105 IFS="$ac_save_ifs" 106dnl If no 4th arg is given, leave the cache variable unset, 107dnl so AC_PATH_PROGS will keep looking. 108ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" 109])dnl 110 ;; 111esac])dnl 112$1="$ac_cv_path_$1" 113if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then 114 AC_MSG_RESULT([$]$1) 115else 116 AC_MSG_RESULT(no) 117fi 118AC_SUBST($1)dnl 119]) 120 121# GLIB_WITH_NLS 122#----------------- 123glib_DEFUN([GLIB_WITH_NLS], 124 dnl NLS is obligatory 125 [USE_NLS=yes 126 AC_SUBST(USE_NLS) 127 128 gt_cv_have_gettext=no 129 130 CATOBJEXT=NONE 131 XGETTEXT=: 132 INTLLIBS= 133 134 AC_CHECK_HEADER(libintl.h, 135 [gt_cv_func_dgettext_libintl="no" 136 libintl_extra_libs="" 137 138 # 139 # First check in libc 140 # 141 AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc, 142 [AC_TRY_LINK([ 143#include <libintl.h> 144], 145 [return !ngettext ("","", 1)], 146 gt_cv_func_ngettext_libc=yes, 147 gt_cv_func_ngettext_libc=no) 148 ]) 149 150 if test "$gt_cv_func_ngettext_libc" = "yes" ; then 151 AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc, 152 [AC_TRY_LINK([ 153#include <libintl.h> 154], 155 [return !dgettext ("","")], 156 gt_cv_func_dgettext_libc=yes, 157 gt_cv_func_dgettext_libc=no) 158 ]) 159 fi 160 161 if test "$gt_cv_func_ngettext_libc" = "yes" ; then 162 AC_CHECK_FUNCS(bind_textdomain_codeset) 163 fi 164 165 # 166 # If we don't have everything we want, check in libintl 167 # 168 if test "$gt_cv_func_dgettext_libc" != "yes" \ 169 || test "$gt_cv_func_ngettext_libc" != "yes" \ 170 || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then 171 172 AC_CHECK_LIB(intl, bindtextdomain, 173 [AC_CHECK_LIB(intl, ngettext, 174 [AC_CHECK_LIB(intl, dgettext, 175 gt_cv_func_dgettext_libintl=yes)])]) 176 177 if test "$gt_cv_func_dgettext_libintl" != "yes" ; then 178 AC_MSG_CHECKING([if -liconv is needed to use gettext]) 179 AC_MSG_RESULT([]) 180 AC_CHECK_LIB(intl, ngettext, 181 [AC_CHECK_LIB(intl, dcgettext, 182 [gt_cv_func_dgettext_libintl=yes 183 libintl_extra_libs=-liconv], 184 :,-liconv)], 185 :,-liconv) 186 fi 187 188 # 189 # If we found libintl, then check in it for bind_textdomain_codeset(); 190 # we'll prefer libc if neither have bind_textdomain_codeset(), 191 # and both have dgettext and ngettext 192 # 193 if test "$gt_cv_func_dgettext_libintl" = "yes" ; then 194 glib_save_LIBS="$LIBS" 195 LIBS="$LIBS -lintl $libintl_extra_libs" 196 unset ac_cv_func_bind_textdomain_codeset 197 AC_CHECK_FUNCS(bind_textdomain_codeset) 198 LIBS="$glib_save_LIBS" 199 200 if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then 201 gt_cv_func_dgettext_libc=no 202 else 203 if test "$gt_cv_func_dgettext_libc" = "yes" \ 204 && test "$gt_cv_func_ngettext_libc" = "yes"; then 205 gt_cv_func_dgettext_libintl=no 206 fi 207 fi 208 fi 209 fi 210 211 if test "$gt_cv_func_dgettext_libc" = "yes" \ 212 || test "$gt_cv_func_dgettext_libintl" = "yes"; then 213 gt_cv_have_gettext=yes 214 fi 215 216 if test "$gt_cv_func_dgettext_libintl" = "yes"; then 217 INTLLIBS="-lintl $libintl_extra_libs" 218 fi 219 220 if test "$gt_cv_have_gettext" = "yes"; then 221 AC_DEFINE(HAVE_GETTEXT,1, 222 [Define if the GNU gettext() function is already present or preinstalled.]) 223 GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, 224 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl 225 if test "$MSGFMT" != "no"; then 226 glib_save_LIBS="$LIBS" 227 LIBS="$LIBS $INTLLIBS" 228 AC_CHECK_FUNCS(dcgettext) 229 MSGFMT_OPTS= 230 AC_MSG_CHECKING([if msgfmt accepts -c]) 231 GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[ 232msgid "" 233msgstr "" 234"Content-Type: text/plain; charset=UTF-8\n" 235"Project-Id-Version: test 1.0\n" 236"PO-Revision-Date: 2007-02-15 12:01+0100\n" 237"Last-Translator: test <foo@bar.xx>\n" 238"Language-Team: C <LL@li.org>\n" 239"MIME-Version: 1.0\n" 240"Content-Transfer-Encoding: 8bit\n" 241], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])]) 242 AC_SUBST(MSGFMT_OPTS) 243 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) 244 GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, 245 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :) 246 AC_TRY_LINK(, [extern int _nl_msg_cat_cntr; 247 return _nl_msg_cat_cntr], 248 [CATOBJEXT=.gmo 249 DATADIRNAME=share], 250 [case $host in 251 *-*-solaris*) 252 dnl On Solaris, if bind_textdomain_codeset is in libc, 253 dnl GNU format message catalog is always supported, 254 dnl since both are added to the libc all together. 255 dnl Hence, we'd like to go with DATADIRNAME=share and 256 dnl and CATOBJEXT=.gmo in this case. 257 AC_CHECK_FUNC(bind_textdomain_codeset, 258 [CATOBJEXT=.gmo 259 DATADIRNAME=share], 260 [CATOBJEXT=.mo 261 DATADIRNAME=lib]) 262 ;; 263 *) 264 CATOBJEXT=.mo 265 DATADIRNAME=lib 266 ;; 267 esac]) 268 LIBS="$glib_save_LIBS" 269 INSTOBJEXT=.mo 270 else 271 gt_cv_have_gettext=no 272 fi 273 fi 274 ]) 275 276 if test "$gt_cv_have_gettext" = "yes" ; then 277 AC_DEFINE(ENABLE_NLS, 1, 278 [always defined to indicate that i18n is enabled]) 279 fi 280 281 dnl Test whether we really found GNU xgettext. 282 if test "$XGETTEXT" != ":"; then 283 dnl If it is not GNU xgettext we define it as : so that the 284 dnl Makefiles still can work. 285 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then 286 : ; 287 else 288 AC_MSG_RESULT( 289 [found xgettext program is not GNU xgettext; ignore it]) 290 XGETTEXT=":" 291 fi 292 fi 293 294 # We need to process the po/ directory. 295 POSUB=po 296 297 AC_OUTPUT_COMMANDS( 298 [case "$CONFIG_FILES" in *po/Makefile.in*) 299 sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile 300 esac]) 301 302 dnl These rules are solely for the distribution goal. While doing this 303 dnl we only have to keep exactly one list of the available catalogs 304 dnl in configure.in. 305 for lang in $ALL_LINGUAS; do 306 GMOFILES="$GMOFILES $lang.gmo" 307 POFILES="$POFILES $lang.po" 308 done 309 310 dnl Make all variables we use known to autoconf. 311 AC_SUBST(CATALOGS) 312 AC_SUBST(CATOBJEXT) 313 AC_SUBST(DATADIRNAME) 314 AC_SUBST(GMOFILES) 315 AC_SUBST(INSTOBJEXT) 316 AC_SUBST(INTLLIBS) 317 AC_SUBST(PO_IN_DATADIR_TRUE) 318 AC_SUBST(PO_IN_DATADIR_FALSE) 319 AC_SUBST(POFILES) 320 AC_SUBST(POSUB) 321 ]) 322 323# AM_GLIB_GNU_GETTEXT 324# ------------------- 325# Do checks necessary for use of gettext. If a suitable implementation 326# of gettext is found in either in libintl or in the C library, 327# it will set INTLLIBS to the libraries needed for use of gettext 328# and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable 329# gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST() 330# on various variables needed by the Makefile.in.in installed by 331# glib-gettextize. 332dnl 333glib_DEFUN([GLIB_GNU_GETTEXT], 334 [AC_REQUIRE([AC_PROG_CC])dnl 335 AC_REQUIRE([AC_HEADER_STDC])dnl 336 337 GLIB_LC_MESSAGES 338 GLIB_WITH_NLS 339 340 if test "$gt_cv_have_gettext" = "yes"; then 341 if test "x$ALL_LINGUAS" = "x"; then 342 LINGUAS= 343 else 344 AC_MSG_CHECKING(for catalogs to be installed) 345 NEW_LINGUAS= 346 for presentlang in $ALL_LINGUAS; do 347 useit=no 348 if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then 349 desiredlanguages="$LINGUAS" 350 else 351 desiredlanguages="$ALL_LINGUAS" 352 fi 353 for desiredlang in $desiredlanguages; do 354 # Use the presentlang catalog if desiredlang is 355 # a. equal to presentlang, or 356 # b. a variant of presentlang (because in this case, 357 # presentlang can be used as a fallback for messages 358 # which are not translated in the desiredlang catalog). 359 case "$desiredlang" in 360 "$presentlang"*) useit=yes;; 361 esac 362 done 363 if test $useit = yes; then 364 NEW_LINGUAS="$NEW_LINGUAS $presentlang" 365 fi 366 done 367 LINGUAS=$NEW_LINGUAS 368 AC_MSG_RESULT($LINGUAS) 369 fi 370 371 dnl Construct list of names of catalog files to be constructed. 372 if test -n "$LINGUAS"; then 373 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done 374 fi 375 fi 376 377 dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly 378 dnl find the mkinstalldirs script in another subdir but ($top_srcdir). 379 dnl Try to locate is. 380 MKINSTALLDIRS= 381 if test -n "$ac_aux_dir"; then 382 MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" 383 fi 384 if test -z "$MKINSTALLDIRS"; then 385 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" 386 fi 387 AC_SUBST(MKINSTALLDIRS) 388 389 dnl Generate list of files to be processed by xgettext which will 390 dnl be included in po/Makefile. 391 test -d po || mkdir po 392 if test "x$srcdir" != "x."; then 393 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then 394 posrcprefix="$srcdir/" 395 else 396 posrcprefix="../$srcdir/" 397 fi 398 else 399 posrcprefix="../" 400 fi 401 rm -f po/POTFILES 402 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ 403 < $srcdir/po/POTFILES.in > po/POTFILES 404 ]) 405 406# AM_GLIB_DEFINE_LOCALEDIR(VARIABLE) 407# ------------------------------- 408# Define VARIABLE to the location where catalog files will 409# be installed by po/Makefile. 410glib_DEFUN([GLIB_DEFINE_LOCALEDIR], 411[glib_REQUIRE([GLIB_GNU_GETTEXT])dnl 412glib_save_prefix="$prefix" 413glib_save_exec_prefix="$exec_prefix" 414glib_save_datarootdir="$datarootdir" 415test "x$prefix" = xNONE && prefix=$ac_default_prefix 416test "x$exec_prefix" = xNONE && exec_prefix=$prefix 417datarootdir=`eval echo "${datarootdir}"` 418if test "x$CATOBJEXT" = "x.mo" ; then 419 localedir=`eval echo "${libdir}/locale"` 420else 421 localedir=`eval echo "${datadir}/locale"` 422fi 423prefix="$glib_save_prefix" 424exec_prefix="$glib_save_exec_prefix" 425datarootdir="$glib_save_datarootdir" 426AC_DEFINE_UNQUOTED($1, "$localedir", 427 [Define the location where the catalogs will be installed]) 428]) 429 430dnl 431dnl Now the definitions that aclocal will find 432dnl 433ifdef(glib_configure_in,[],[ 434AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)]) 435AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)]) 436])dnl 437 438# GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL]) 439# 440# Create a temporary file with TEST-FILE as its contents and pass the 441# file name to PROGRAM. Perform ACTION-IF-PASS if PROGRAM exits with 442# 0 and perform ACTION-IF-FAIL for any other exit status. 443AC_DEFUN([GLIB_RUN_PROG], 444[cat >conftest.foo <<_ACEOF 445$2 446_ACEOF 447if AC_RUN_LOG([$1 conftest.foo]); then 448 m4_ifval([$3], [$3], [:]) 449m4_ifvaln([$4], [else $4])dnl 450echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD 451sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD 452fi]) 453 454 455dnl Do not call GNOME_DOC_DEFINES directly. It is split out from 456dnl GNOME_DOC_INIT to allow gnome-doc-utils to bootstrap off itself. 457AC_DEFUN([GNOME_DOC_DEFINES], 458[ 459AC_ARG_WITH([help-dir], 460 AC_HELP_STRING([--with-help-dir=DIR], [path to help docs]),, 461 [with_help_dir='${datadir}/gnome/help']) 462HELP_DIR="$with_help_dir" 463AC_SUBST(HELP_DIR) 464 465AC_ARG_WITH([omf-dir], 466 AC_HELP_STRING([--with-omf-dir=DIR], [path to OMF files]),, 467 [with_omf_dir='${datadir}/omf']) 468OMF_DIR="$with_omf_dir" 469AC_SUBST(OMF_DIR) 470 471AC_ARG_WITH([help-formats], 472 AC_HELP_STRING([--with-help-formats=FORMATS], [list of formats]),, 473 [with_help_formats='']) 474DOC_USER_FORMATS="$with_help_formats" 475AC_SUBST(DOC_USER_FORMATS) 476 477AC_ARG_ENABLE([scrollkeeper], 478 [AC_HELP_STRING([--disable-scrollkeeper], 479 [do not make updates to the scrollkeeper database])],, 480 enable_scrollkeeper=yes) 481AM_CONDITIONAL([ENABLE_SK],[test "$gdu_cv_have_gdu" = "yes" -a "$enable_scrollkeeper" = "yes"]) 482 483dnl disable scrollkeeper automatically for distcheck 484DISTCHECK_CONFIGURE_FLAGS="--disable-scrollkeeper $DISTCHECK_CONFIGURE_FLAGS" 485AC_SUBST(DISTCHECK_CONFIGURE_FLAGS) 486 487AM_CONDITIONAL([HAVE_GNOME_DOC_UTILS],[test "$gdu_cv_have_gdu" = "yes"]) 488]) 489 490# GNOME_DOC_INIT ([MINIMUM-VERSION],[ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND]) 491# 492AC_DEFUN([GNOME_DOC_INIT], 493[AC_REQUIRE([AC_PROG_LN_S])dnl 494 495ifelse([$1],,[gdu_cv_version_required=0.3.2],[gdu_cv_version_required=$1]) 496 497PKG_CHECK_EXISTS([gnome-doc-utils >= $gdu_cv_version_required], 498 [gdu_cv_have_gdu=yes],[gdu_cv_have_gdu=no]) 499 500if test "$gdu_cv_have_gdu" = "yes"; then 501 ifelse([$2],,[:],[$2]) 502else 503 ifelse([$3],,[AC_MSG_ERROR([gnome-doc-utils >= $gdu_cv_version_required not found])],[$3]) 504fi 505 506GNOME_DOC_DEFINES 507]) 508 509# Configure paths for GTK+ 510# Owen Taylor 1997-2001 511 512dnl AM_PATH_GTK_2_0([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]]) 513dnl Test for GTK+, and define GTK_CFLAGS and GTK_LIBS, if gthread is specified in MODULES, 514dnl pass to pkg-config 515dnl 516AC_DEFUN([AM_PATH_GTK_2_0], 517[dnl 518dnl Get the cflags and libraries from pkg-config 519dnl 520AC_ARG_ENABLE(gtktest, [ --disable-gtktest do not try to compile and run a test GTK+ program], 521 , enable_gtktest=yes) 522 523 pkg_config_args=gtk+-2.0 524 for module in . $4 525 do 526 case "$module" in 527 gthread) 528 pkg_config_args="$pkg_config_args gthread-2.0" 529 ;; 530 esac 531 done 532 533 no_gtk="" 534 535 AC_PATH_PROG(PKG_CONFIG, pkg-config, no) 536 537 if test x$PKG_CONFIG != xno ; then 538 if pkg-config --atleast-pkgconfig-version 0.7 ; then 539 : 540 else 541 echo "*** pkg-config too old; version 0.7 or better required." 542 no_gtk=yes 543 PKG_CONFIG=no 544 fi 545 else 546 no_gtk=yes 547 fi 548 549 min_gtk_version=ifelse([$1], ,2.0.0,$1) 550 AC_MSG_CHECKING(for GTK+ - version >= $min_gtk_version) 551 552 if test x$PKG_CONFIG != xno ; then 553 ## don't try to run the test against uninstalled libtool libs 554 if $PKG_CONFIG --uninstalled $pkg_config_args; then 555 echo "Will use uninstalled version of GTK+ found in PKG_CONFIG_PATH" 556 enable_gtktest=no 557 fi 558 559 if $PKG_CONFIG --atleast-version $min_gtk_version $pkg_config_args; then 560 : 561 else 562 no_gtk=yes 563 fi 564 fi 565 566 if test x"$no_gtk" = x ; then 567 GTK_CFLAGS=`$PKG_CONFIG $pkg_config_args --cflags` 568 GTK_LIBS=`$PKG_CONFIG $pkg_config_args --libs` 569 gtk_config_major_version=`$PKG_CONFIG --modversion gtk+-2.0 | \ 570 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` 571 gtk_config_minor_version=`$PKG_CONFIG --modversion gtk+-2.0 | \ 572 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` 573 gtk_config_micro_version=`$PKG_CONFIG --modversion gtk+-2.0 | \ 574 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` 575 if test "x$enable_gtktest" = "xyes" ; then 576 ac_save_CFLAGS="$CFLAGS" 577 ac_save_LIBS="$LIBS" 578 CFLAGS="$CFLAGS $GTK_CFLAGS" 579 LIBS="$GTK_LIBS $LIBS" 580dnl 581dnl Now check if the installed GTK+ is sufficiently new. (Also sanity 582dnl checks the results of pkg-config to some extent) 583dnl 584 rm -f conf.gtktest 585 AC_TRY_RUN([ 586#include <gtk/gtk.h> 587#include <stdio.h> 588#include <stdlib.h> 589 590int 591main () 592{ 593 int major, minor, micro; 594 char *tmp_version; 595 596 system ("touch conf.gtktest"); 597 598 /* HP/UX 9 (%@#!) writes to sscanf strings */ 599 tmp_version = g_strdup("$min_gtk_version"); 600 if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { 601 printf("%s, bad version string\n", "$min_gtk_version"); 602 exit(1); 603 } 604 605 if ((gtk_major_version != $gtk_config_major_version) || 606 (gtk_minor_version != $gtk_config_minor_version) || 607 (gtk_micro_version != $gtk_config_micro_version)) 608 { 609 printf("\n*** 'pkg-config --modversion gtk+-2.0' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n", 610 $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version, 611 gtk_major_version, gtk_minor_version, gtk_micro_version); 612 printf ("*** was found! If pkg-config was correct, then it is best\n"); 613 printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n"); 614 printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n"); 615 printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n"); 616 printf("*** required on your system.\n"); 617 printf("*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH\n"); 618 printf("*** to point to the correct configuration files\n"); 619 } 620 else if ((gtk_major_version != GTK_MAJOR_VERSION) || 621 (gtk_minor_version != GTK_MINOR_VERSION) || 622 (gtk_micro_version != GTK_MICRO_VERSION)) 623 { 624 printf("*** GTK+ header files (version %d.%d.%d) do not match\n", 625 GTK_MAJOR_VERSION, GTK_MINOR_VERSION, GTK_MICRO_VERSION); 626 printf("*** library (version %d.%d.%d)\n", 627 gtk_major_version, gtk_minor_version, gtk_micro_version); 628 } 629 else 630 { 631 if ((gtk_major_version > major) || 632 ((gtk_major_version == major) && (gtk_minor_version > minor)) || 633 ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro))) 634 { 635 return 0; 636 } 637 else 638 { 639 printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n", 640 gtk_major_version, gtk_minor_version, gtk_micro_version); 641 printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n", 642 major, minor, micro); 643 printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n"); 644 printf("***\n"); 645 printf("*** If you have already installed a sufficiently new version, this error\n"); 646 printf("*** probably means that the wrong copy of the pkg-config shell script is\n"); 647 printf("*** being found. The easiest way to fix this is to remove the old version\n"); 648 printf("*** of GTK+, but you can also set the PKG_CONFIG environment to point to the\n"); 649 printf("*** correct copy of pkg-config. (In this case, you will have to\n"); 650 printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); 651 printf("*** so that the correct libraries are found at run-time))\n"); 652 } 653 } 654 return 1; 655} 656],, no_gtk=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) 657 CFLAGS="$ac_save_CFLAGS" 658 LIBS="$ac_save_LIBS" 659 fi 660 fi 661 if test "x$no_gtk" = x ; then 662 AC_MSG_RESULT(yes (version $gtk_config_major_version.$gtk_config_minor_version.$gtk_config_micro_version)) 663 ifelse([$2], , :, [$2]) 664 else 665 AC_MSG_RESULT(no) 666 if test "$PKG_CONFIG" = "no" ; then 667 echo "*** A new enough version of pkg-config was not found." 668 echo "*** See http://pkgconfig.sourceforge.net" 669 else 670 if test -f conf.gtktest ; then 671 : 672 else 673 echo "*** Could not run GTK+ test program, checking why..." 674 ac_save_CFLAGS="$CFLAGS" 675 ac_save_LIBS="$LIBS" 676 CFLAGS="$CFLAGS $GTK_CFLAGS" 677 LIBS="$LIBS $GTK_LIBS" 678 AC_TRY_LINK([ 679#include <gtk/gtk.h> 680#include <stdio.h> 681], [ return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version)); ], 682 [ echo "*** The test program compiled, but did not run. This usually means" 683 echo "*** that the run-time linker is not finding GTK+ or finding the wrong" 684 echo "*** version of GTK+. If it is not finding GTK+, you'll need to set your" 685 echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" 686 echo "*** to the installed location Also, make sure you have run ldconfig if that" 687 echo "*** is required on your system" 688 echo "***" 689 echo "*** If you have an old version installed, it is best to remove it, although" 690 echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], 691 [ echo "*** The test program failed to compile or link. See the file config.log for the" 692 echo "*** exact error that occured. This usually means GTK+ is incorrectly installed."]) 693 CFLAGS="$ac_save_CFLAGS" 694 LIBS="$ac_save_LIBS" 695 fi 696 fi 697 GTK_CFLAGS="" 698 GTK_LIBS="" 699 ifelse([$3], , :, [$3]) 700 fi 701 AC_SUBST(GTK_CFLAGS) 702 AC_SUBST(GTK_LIBS) 703 rm -f conf.gtktest 704]) 705 706 707dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml]) 708# serial 40 IT_PROG_INTLTOOL 709AC_DEFUN([IT_PROG_INTLTOOL], [ 710AC_PREREQ([2.50])dnl 711AC_REQUIRE([AM_NLS])dnl 712 713case "$am__api_version" in 714 1.[01234]) 715 AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool]) 716 ;; 717 *) 718 ;; 719esac 720 721if test -n "$1"; then 722 AC_MSG_CHECKING([for intltool >= $1]) 723 724 INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'` 725 INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3` 726 [INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'` 727 ] 728 AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found]) 729 test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" || 730 AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.]) 731fi 732 733AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update]) 734AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge]) 735AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract]) 736if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then 737 AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.]) 738fi 739 740 INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 741INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 742 INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 743 INTLTOOL_PROP_RULE='%.prop: %.prop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 744 INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -p $(top_srcdir)/po $< [$]@' 745 INTLTOOL_PONG_RULE='%.pong: %.pong.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 746 INTLTOOL_SERVER_RULE='%.server: %.server.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 747 INTLTOOL_SHEET_RULE='%.sheet: %.sheet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 748INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 749 INTLTOOL_UI_RULE='%.ui: %.ui.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 750 INTLTOOL_XML_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 751 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< [$]@' 752 INTLTOOL_XAM_RULE='%.xam: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 753 INTLTOOL_KBD_RULE='%.kbd: %.kbd.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 754 INTLTOOL_CAVES_RULE='%.caves: %.caves.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 755 INTLTOOL_SCHEMAS_RULE='%.schemas: %.schemas.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 756 INTLTOOL_THEME_RULE='%.theme: %.theme.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 757 INTLTOOL_SERVICE_RULE='%.service: %.service.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 758 INTLTOOL_POLICY_RULE='%.policy: %.policy.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 759 760_IT_SUBST(INTLTOOL_DESKTOP_RULE) 761_IT_SUBST(INTLTOOL_DIRECTORY_RULE) 762_IT_SUBST(INTLTOOL_KEYS_RULE) 763_IT_SUBST(INTLTOOL_PROP_RULE) 764_IT_SUBST(INTLTOOL_OAF_RULE) 765_IT_SUBST(INTLTOOL_PONG_RULE) 766_IT_SUBST(INTLTOOL_SERVER_RULE) 767_IT_SUBST(INTLTOOL_SHEET_RULE) 768_IT_SUBST(INTLTOOL_SOUNDLIST_RULE) 769_IT_SUBST(INTLTOOL_UI_RULE) 770_IT_SUBST(INTLTOOL_XAM_RULE) 771_IT_SUBST(INTLTOOL_KBD_RULE) 772_IT_SUBST(INTLTOOL_XML_RULE) 773_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE) 774_IT_SUBST(INTLTOOL_CAVES_RULE) 775_IT_SUBST(INTLTOOL_SCHEMAS_RULE) 776_IT_SUBST(INTLTOOL_THEME_RULE) 777_IT_SUBST(INTLTOOL_SERVICE_RULE) 778_IT_SUBST(INTLTOOL_POLICY_RULE) 779 780# Check the gettext tools to make sure they are GNU 781AC_PATH_PROG(XGETTEXT, xgettext) 782AC_PATH_PROG(MSGMERGE, msgmerge) 783AC_PATH_PROG(MSGFMT, msgfmt) 784AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) 785if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then 786 AC_MSG_ERROR([GNU gettext tools not found; required for intltool]) 787fi 788xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`" 789mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`" 790mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`" 791if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then 792 AC_MSG_ERROR([GNU gettext tools not found; required for intltool]) 793fi 794 795AC_PATH_PROG(INTLTOOL_PERL, perl) 796if test -z "$INTLTOOL_PERL"; then 797 AC_MSG_ERROR([perl not found]) 798fi 799AC_MSG_CHECKING([for perl >= 5.8.1]) 800$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1 801if test $? -ne 0; then 802 AC_MSG_ERROR([perl 5.8.1 is required for intltool]) 803else 804 IT_PERL_VERSION="`$INTLTOOL_PERL -e \"printf '%vd', $^V\"`" 805 AC_MSG_RESULT([$IT_PERL_VERSION]) 806fi 807if test "x$2" != "xno-xml"; then 808 AC_MSG_CHECKING([for XML::Parser]) 809 if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then 810 AC_MSG_RESULT([ok]) 811 else 812 AC_MSG_ERROR([XML::Parser perl module is required for intltool]) 813 fi 814fi 815 816# Substitute ALL_LINGUAS so we can use it in po/Makefile 817AC_SUBST(ALL_LINGUAS) 818 819# Set DATADIRNAME correctly if it is not set yet 820# (copied from glib-gettext.m4) 821if test -z "$DATADIRNAME"; then 822 AC_LINK_IFELSE( 823 [AC_LANG_PROGRAM([[]], 824 [[extern int _nl_msg_cat_cntr; 825 return _nl_msg_cat_cntr]])], 826 [DATADIRNAME=share], 827 [case $host in 828 *-*-solaris*) 829 dnl On Solaris, if bind_textdomain_codeset is in libc, 830 dnl GNU format message catalog is always supported, 831 dnl since both are added to the libc all together. 832 dnl Hence, we'd like to go with DATADIRNAME=share 833 dnl in this case. 834 AC_CHECK_FUNC(bind_textdomain_codeset, 835 [DATADIRNAME=share], [DATADIRNAME=lib]) 836 ;; 837 *) 838 [DATADIRNAME=lib] 839 ;; 840 esac]) 841fi 842AC_SUBST(DATADIRNAME) 843 844IT_PO_SUBDIR([po]) 845 846]) 847 848 849# IT_PO_SUBDIR(DIRNAME) 850# --------------------- 851# All po subdirs have to be declared with this macro; the subdir "po" is 852# declared by IT_PROG_INTLTOOL. 853# 854AC_DEFUN([IT_PO_SUBDIR], 855[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS. 856dnl 857dnl The following CONFIG_COMMANDS should be exetuted at the very end 858dnl of config.status. 859AC_CONFIG_COMMANDS_PRE([ 860 AC_CONFIG_COMMANDS([$1/stamp-it], [ 861 if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then 862 AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.]) 863 fi 864 rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp" 865 >"$1/stamp-it.tmp" 866 [sed '/^#/d 867 s/^[[].*] *// 868 /^[ ]*$/d 869 '"s|^| $ac_top_srcdir/|" \ 870 "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES" 871 ] 872 [sed '/^POTFILES =/,/[^\\]$/ { 873 /^POTFILES =/!d 874 r $1/POTFILES 875 } 876 ' "$1/Makefile.in" >"$1/Makefile"] 877 rm -f "$1/Makefile.tmp" 878 mv "$1/stamp-it.tmp" "$1/stamp-it" 879 ]) 880])dnl 881]) 882 883# _IT_SUBST(VARIABLE) 884# ------------------- 885# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST 886# 887AC_DEFUN([_IT_SUBST], 888[ 889AC_SUBST([$1]) 890m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])]) 891] 892) 893 894# deprecated macros 895AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL]) 896# A hint is needed for aclocal from Automake <= 1.9.4: 897# AC_DEFUN([AC_PROG_INTLTOOL], ...) 898 899 900# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 901# 902# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 903# 2006, 2007, 2008 Free Software Foundation, Inc. 904# Written by Gordon Matzigkeit, 1996 905# 906# This file is free software; the Free Software Foundation gives 907# unlimited permission to copy and/or distribute it, with or without 908# modifications, as long as this notice is preserved. 909 910m4_define([_LT_COPYING], [dnl 911# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 912# 2006, 2007, 2008 Free Software Foundation, Inc. 913# Written by Gordon Matzigkeit, 1996 914# 915# This file is part of GNU Libtool. 916# 917# GNU Libtool is free software; you can redistribute it and/or 918# modify it under the terms of the GNU General Public License as 919# published by the Free Software Foundation; either version 2 of 920# the License, or (at your option) any later version. 921# 922# As a special exception to the GNU General Public License, 923# if you distribute this file as part of a program or library that 924# is built using GNU Libtool, you may include this file under the 925# same distribution terms that you use for the rest of that program. 926# 927# GNU Libtool is distributed in the hope that it will be useful, 928# but WITHOUT ANY WARRANTY; without even the implied warranty of 929# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 930# GNU General Public License for more details. 931# 932# You should have received a copy of the GNU General Public License 933# along with GNU Libtool; see the file COPYING. If not, a copy 934# can be downloaded from http://www.gnu.org/licenses/gpl.html, or 935# obtained by writing to the Free Software Foundation, Inc., 936# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 937]) 938 939# serial 56 LT_INIT 940 941 942# LT_PREREQ(VERSION) 943# ------------------ 944# Complain and exit if this libtool version is less that VERSION. 945m4_defun([LT_PREREQ], 946[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 947 [m4_default([$3], 948 [m4_fatal([Libtool version $1 or higher is required], 949 63)])], 950 [$2])]) 951 952 953# _LT_CHECK_BUILDDIR 954# ------------------ 955# Complain if the absolute build directory name contains unusual characters 956m4_defun([_LT_CHECK_BUILDDIR], 957[case `pwd` in 958 *\ * | *\ *) 959 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 960esac 961]) 962 963 964# LT_INIT([OPTIONS]) 965# ------------------ 966AC_DEFUN([LT_INIT], 967[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT 968AC_BEFORE([$0], [LT_LANG])dnl 969AC_BEFORE([$0], [LT_OUTPUT])dnl 970AC_BEFORE([$0], [LTDL_INIT])dnl 971m4_require([_LT_CHECK_BUILDDIR])dnl 972 973dnl Autoconf doesn't catch unexpanded LT_ macros by default: 974m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 975m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 976dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 977dnl unless we require an AC_DEFUNed macro: 978AC_REQUIRE([LTOPTIONS_VERSION])dnl 979AC_REQUIRE([LTSUGAR_VERSION])dnl 980AC_REQUIRE([LTVERSION_VERSION])dnl 981AC_REQUIRE([LTOBSOLETE_VERSION])dnl 982m4_require([_LT_PROG_LTMAIN])dnl 983 984dnl Parse OPTIONS 985_LT_SET_OPTIONS([$0], [$1]) 986 987# This can be used to rebuild libtool when needed 988LIBTOOL_DEPS="$ltmain" 989 990# Always use our own libtool. 991LIBTOOL='$(SHELL) $(top_builddir)/libtool' 992AC_SUBST(LIBTOOL)dnl 993 994_LT_SETUP 995 996# Only expand once: 997m4_define([LT_INIT]) 998])# LT_INIT 999 1000# Old names: 1001AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 1002AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 1003dnl aclocal-1.4 backwards compatibility: 1004dnl AC_DEFUN([AC_PROG_LIBTOOL], []) 1005dnl AC_DEFUN([AM_PROG_LIBTOOL], []) 1006 1007 1008# _LT_CC_BASENAME(CC) 1009# ------------------- 1010# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 1011m4_defun([_LT_CC_BASENAME], 1012[for cc_temp in $1""; do 1013 case $cc_temp in 1014 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 1015 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 1016 \-*) ;; 1017 *) break;; 1018 esac 1019done 1020cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` 1021]) 1022 1023 1024# _LT_FILEUTILS_DEFAULTS 1025# ---------------------- 1026# It is okay to use these file commands and assume they have been set 1027# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. 1028m4_defun([_LT_FILEUTILS_DEFAULTS], 1029[: ${CP="cp -f"} 1030: ${MV="mv -f"} 1031: ${RM="rm -f"} 1032])# _LT_FILEUTILS_DEFAULTS 1033 1034 1035# _LT_SETUP 1036# --------- 1037m4_defun([_LT_SETUP], 1038[AC_REQUIRE([AC_CANONICAL_HOST])dnl 1039AC_REQUIRE([AC_CANONICAL_BUILD])dnl 1040_LT_DECL([], [host_alias], [0], [The host system])dnl 1041_LT_DECL([], [host], [0])dnl 1042_LT_DECL([], [host_os], [0])dnl 1043dnl 1044_LT_DECL([], [build_alias], [0], [The build system])dnl 1045_LT_DECL([], [build], [0])dnl 1046_LT_DECL([], [build_os], [0])dnl 1047dnl 1048AC_REQUIRE([AC_PROG_CC])dnl 1049AC_REQUIRE([LT_PATH_LD])dnl 1050AC_REQUIRE([LT_PATH_NM])dnl 1051dnl 1052AC_REQUIRE([AC_PROG_LN_S])dnl 1053test -z "$LN_S" && LN_S="ln -s" 1054_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 1055dnl 1056AC_REQUIRE([LT_CMD_MAX_LEN])dnl 1057_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 1058_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 1059dnl 1060m4_require([_LT_FILEUTILS_DEFAULTS])dnl 1061m4_require([_LT_CHECK_SHELL_FEATURES])dnl 1062m4_require([_LT_CMD_RELOAD])dnl 1063m4_require([_LT_CHECK_MAGIC_METHOD])dnl 1064m4_require([_LT_CMD_OLD_ARCHIVE])dnl 1065m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 1066 1067_LT_CONFIG_LIBTOOL_INIT([ 1068# See if we are running on zsh, and set the options which allow our 1069# commands through without removal of \ escapes INIT. 1070if test -n "\${ZSH_VERSION+set}" ; then 1071 setopt NO_GLOB_SUBST 1072fi 1073]) 1074if test -n "${ZSH_VERSION+set}" ; then 1075 setopt NO_GLOB_SUBST 1076fi 1077 1078_LT_CHECK_OBJDIR 1079 1080m4_require([_LT_TAG_COMPILER])dnl 1081_LT_PROG_ECHO_BACKSLASH 1082 1083case $host_os in 1084aix3*) 1085 # AIX sometimes has problems with the GCC collect2 program. For some 1086 # reason, if we set the COLLECT_NAMES environment variable, the problems 1087 # vanish in a puff of smoke. 1088 if test "X${COLLECT_NAMES+set}" != Xset; then 1089 COLLECT_NAMES= 1090 export COLLECT_NAMES 1091 fi 1092 ;; 1093esac 1094 1095# Sed substitution that helps us do robust quoting. It backslashifies 1096# metacharacters that are still active within double-quoted strings. 1097sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 1098 1099# Same as above, but do not quote variable references. 1100double_quote_subst='s/\([["`\\]]\)/\\\1/g' 1101 1102# Sed substitution to delay expansion of an escaped shell variable in a 1103# double_quote_subst'ed string. 1104delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 1105 1106# Sed substitution to delay expansion of an escaped single quote. 1107delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 1108 1109# Sed substitution to avoid accidental globbing in evaled expressions 1110no_glob_subst='s/\*/\\\*/g' 1111 1112# Global variables: 1113ofile=libtool 1114can_build_shared=yes 1115 1116# All known linkers require a `.a' archive for static linking (except MSVC, 1117# which needs '.lib'). 1118libext=a 1119 1120with_gnu_ld="$lt_cv_prog_gnu_ld" 1121 1122old_CC="$CC" 1123old_CFLAGS="$CFLAGS" 1124 1125# Set sane defaults for various variables 1126test -z "$CC" && CC=cc 1127test -z "$LTCC" && LTCC=$CC 1128test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 1129test -z "$LD" && LD=ld 1130test -z "$ac_objext" && ac_objext=o 1131 1132_LT_CC_BASENAME([$compiler]) 1133 1134# Only perform the check for file, if the check method requires it 1135test -z "$MAGIC_CMD" && MAGIC_CMD=file 1136case $deplibs_check_method in 1137file_magic*) 1138 if test "$file_magic_cmd" = '$MAGIC_CMD'; then 1139 _LT_PATH_MAGIC 1140 fi 1141 ;; 1142esac 1143 1144# Use C for the default configuration in the libtool script 1145LT_SUPPORTED_TAG([CC]) 1146_LT_LANG_C_CONFIG 1147_LT_LANG_DEFAULT_CONFIG 1148_LT_CONFIG_COMMANDS 1149])# _LT_SETUP 1150 1151 1152# _LT_PROG_LTMAIN 1153# --------------- 1154# Note that this code is called both from `configure', and `config.status' 1155# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 1156# `config.status' has no value for ac_aux_dir unless we are using Automake, 1157# so we pass a copy along to make sure it has a sensible value anyway. 1158m4_defun([_LT_PROG_LTMAIN], 1159[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 1160_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 1161ltmain="$ac_aux_dir/ltmain.sh" 1162])# _LT_PROG_LTMAIN 1163 1164 1165 1166# So that we can recreate a full libtool script including additional 1167# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 1168# in macros and then make a single call at the end using the `libtool' 1169# label. 1170 1171 1172# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 1173# ---------------------------------------- 1174# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 1175m4_define([_LT_CONFIG_LIBTOOL_INIT], 1176[m4_ifval([$1], 1177 [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 1178 [$1 1179])])]) 1180 1181# Initialize. 1182m4_define([_LT_OUTPUT_LIBTOOL_INIT]) 1183 1184 1185# _LT_CONFIG_LIBTOOL([COMMANDS]) 1186# ------------------------------ 1187# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 1188m4_define([_LT_CONFIG_LIBTOOL], 1189[m4_ifval([$1], 1190 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 1191 [$1 1192])])]) 1193 1194# Initialize. 1195m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 1196 1197 1198# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 1199# ----------------------------------------------------- 1200m4_defun([_LT_CONFIG_SAVE_COMMANDS], 1201[_LT_CONFIG_LIBTOOL([$1]) 1202_LT_CONFIG_LIBTOOL_INIT([$2]) 1203]) 1204 1205 1206# _LT_FORMAT_COMMENT([COMMENT]) 1207# ----------------------------- 1208# Add leading comment marks to the start of each line, and a trailing 1209# full-stop to the whole comment if one is not present already. 1210m4_define([_LT_FORMAT_COMMENT], 1211[m4_ifval([$1], [ 1212m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 1213 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 1214)]) 1215 1216 1217 1218 1219 1220# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 1221# ------------------------------------------------------------------- 1222# CONFIGNAME is the name given to the value in the libtool script. 1223# VARNAME is the (base) name used in the configure script. 1224# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 1225# VARNAME. Any other value will be used directly. 1226m4_define([_LT_DECL], 1227[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 1228 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 1229 [m4_ifval([$1], [$1], [$2])]) 1230 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 1231 m4_ifval([$4], 1232 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 1233 lt_dict_add_subkey([lt_decl_dict], [$2], 1234 [tagged?], [m4_ifval([$5], [yes], [no])])]) 1235]) 1236 1237 1238# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 1239# -------------------------------------------------------- 1240m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 1241 1242 1243# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 1244# ------------------------------------------------ 1245m4_define([lt_decl_tag_varnames], 1246[_lt_decl_filter([tagged?], [yes], $@)]) 1247 1248 1249# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 1250# --------------------------------------------------------- 1251m4_define([_lt_decl_filter], 1252[m4_case([$#], 1253 [0], [m4_fatal([$0: too few arguments: $#])], 1254 [1], [m4_fatal([$0: too few arguments: $#: $1])], 1255 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 1256 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 1257 [lt_dict_filter([lt_decl_dict], $@)])[]dnl 1258]) 1259 1260 1261# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 1262# -------------------------------------------------- 1263m4_define([lt_decl_quote_varnames], 1264[_lt_decl_filter([value], [1], $@)]) 1265 1266 1267# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 1268# --------------------------------------------------- 1269m4_define([lt_decl_dquote_varnames], 1270[_lt_decl_filter([value], [2], $@)]) 1271 1272 1273# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 1274# --------------------------------------------------- 1275m4_define([lt_decl_varnames_tagged], 1276[m4_assert([$# <= 2])dnl 1277_$0(m4_quote(m4_default([$1], [[, ]])), 1278 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 1279 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 1280m4_define([_lt_decl_varnames_tagged], 1281[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 1282 1283 1284# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 1285# ------------------------------------------------ 1286m4_define([lt_decl_all_varnames], 1287[_$0(m4_quote(m4_default([$1], [[, ]])), 1288 m4_if([$2], [], 1289 m4_quote(lt_decl_varnames), 1290 m4_quote(m4_shift($@))))[]dnl 1291]) 1292m4_define([_lt_decl_all_varnames], 1293[lt_join($@, lt_decl_varnames_tagged([$1], 1294 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 1295]) 1296 1297 1298# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 1299# ------------------------------------ 1300# Quote a variable value, and forward it to `config.status' so that its 1301# declaration there will have the same value as in `configure'. VARNAME 1302# must have a single quote delimited value for this to work. 1303m4_define([_LT_CONFIG_STATUS_DECLARE], 1304[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`']) 1305 1306 1307# _LT_CONFIG_STATUS_DECLARATIONS 1308# ------------------------------ 1309# We delimit libtool config variables with single quotes, so when 1310# we write them to config.status, we have to be sure to quote all 1311# embedded single quotes properly. In configure, this macro expands 1312# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 1313# 1314# <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`' 1315m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 1316[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 1317 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 1318 1319 1320# _LT_LIBTOOL_TAGS 1321# ---------------- 1322# Output comment and list of tags supported by the script 1323m4_defun([_LT_LIBTOOL_TAGS], 1324[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 1325available_tags="_LT_TAGS"dnl 1326]) 1327 1328 1329# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 1330# ----------------------------------- 1331# Extract the dictionary values for VARNAME (optionally with TAG) and 1332# expand to a commented shell variable setting: 1333# 1334# # Some comment about what VAR is for. 1335# visible_name=$lt_internal_name 1336m4_define([_LT_LIBTOOL_DECLARE], 1337[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 1338 [description])))[]dnl 1339m4_pushdef([_libtool_name], 1340 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 1341m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 1342 [0], [_libtool_name=[$]$1], 1343 [1], [_libtool_name=$lt_[]$1], 1344 [2], [_libtool_name=$lt_[]$1], 1345 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 1346m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 1347]) 1348 1349 1350# _LT_LIBTOOL_CONFIG_VARS 1351# ----------------------- 1352# Produce commented declarations of non-tagged libtool config variables 1353# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' 1354# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 1355# section) are produced by _LT_LIBTOOL_TAG_VARS. 1356m4_defun([_LT_LIBTOOL_CONFIG_VARS], 1357[m4_foreach([_lt_var], 1358 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 1359 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 1360 1361 1362# _LT_LIBTOOL_TAG_VARS(TAG) 1363# ------------------------- 1364m4_define([_LT_LIBTOOL_TAG_VARS], 1365[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 1366 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 1367 1368 1369# _LT_TAGVAR(VARNAME, [TAGNAME]) 1370# ------------------------------ 1371m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 1372 1373 1374# _LT_CONFIG_COMMANDS 1375# ------------------- 1376# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 1377# variables for single and double quote escaping we saved from calls 1378# to _LT_DECL, we can put quote escaped variables declarations 1379# into `config.status', and then the shell code to quote escape them in 1380# for loops in `config.status'. Finally, any additional code accumulated 1381# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 1382m4_defun([_LT_CONFIG_COMMANDS], 1383[AC_PROVIDE_IFELSE([LT_OUTPUT], 1384 dnl If the libtool generation code has been placed in $CONFIG_LT, 1385 dnl instead of duplicating it all over again into config.status, 1386 dnl then we will have config.status run $CONFIG_LT later, so it 1387 dnl needs to know what name is stored there: 1388 [AC_CONFIG_COMMANDS([libtool], 1389 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 1390 dnl If the libtool generation code is destined for config.status, 1391 dnl expand the accumulated commands and init code now: 1392 [AC_CONFIG_COMMANDS([libtool], 1393 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 1394])#_LT_CONFIG_COMMANDS 1395 1396 1397# Initialize. 1398m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 1399[ 1400 1401# The HP-UX ksh and POSIX shell print the target directory to stdout 1402# if CDPATH is set. 1403(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 1404 1405sed_quote_subst='$sed_quote_subst' 1406double_quote_subst='$double_quote_subst' 1407delay_variable_subst='$delay_variable_subst' 1408_LT_CONFIG_STATUS_DECLARATIONS 1409LTCC='$LTCC' 1410LTCFLAGS='$LTCFLAGS' 1411compiler='$compiler_DEFAULT' 1412 1413# Quote evaled strings. 1414for var in lt_decl_all_varnames([[ \ 1415]], lt_decl_quote_varnames); do 1416 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in 1417 *[[\\\\\\\`\\"\\\$]]*) 1418 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" 1419 ;; 1420 *) 1421 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 1422 ;; 1423 esac 1424done 1425 1426# Double-quote double-evaled strings. 1427for var in lt_decl_all_varnames([[ \ 1428]], lt_decl_dquote_varnames); do 1429 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in 1430 *[[\\\\\\\`\\"\\\$]]*) 1431 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" 1432 ;; 1433 *) 1434 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 1435 ;; 1436 esac 1437done 1438 1439# Fix-up fallback echo if it was mangled by the above quoting rules. 1440case \$lt_ECHO in 1441*'\\\[$]0 --fallback-echo"')dnl " 1442 lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\` 1443 ;; 1444esac 1445 1446_LT_OUTPUT_LIBTOOL_INIT 1447]) 1448 1449 1450# LT_OUTPUT 1451# --------- 1452# This macro allows early generation of the libtool script (before 1453# AC_OUTPUT is called), incase it is used in configure for compilation 1454# tests. 1455AC_DEFUN([LT_OUTPUT], 1456[: ${CONFIG_LT=./config.lt} 1457AC_MSG_NOTICE([creating $CONFIG_LT]) 1458cat >"$CONFIG_LT" <<_LTEOF 1459#! $SHELL 1460# Generated by $as_me. 1461# Run this file to recreate a libtool stub with the current configuration. 1462 1463lt_cl_silent=false 1464SHELL=\${CONFIG_SHELL-$SHELL} 1465_LTEOF 1466 1467cat >>"$CONFIG_LT" <<\_LTEOF 1468AS_SHELL_SANITIZE 1469_AS_PREPARE 1470 1471exec AS_MESSAGE_FD>&1 1472exec AS_MESSAGE_LOG_FD>>config.log 1473{ 1474 echo 1475 AS_BOX([Running $as_me.]) 1476} >&AS_MESSAGE_LOG_FD 1477 1478lt_cl_help="\ 1479\`$as_me' creates a local libtool stub from the current configuration, 1480for use in further configure time tests before the real libtool is 1481generated. 1482 1483Usage: $[0] [[OPTIONS]] 1484 1485 -h, --help print this help, then exit 1486 -V, --version print version number, then exit 1487 -q, --quiet do not print progress messages 1488 -d, --debug don't remove temporary files 1489 1490Report bugs to <bug-libtool@gnu.org>." 1491 1492lt_cl_version="\ 1493m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 1494m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 1495configured by $[0], generated by m4_PACKAGE_STRING. 1496 1497Copyright (C) 2008 Free Software Foundation, Inc. 1498This config.lt script is free software; the Free Software Foundation 1499gives unlimited permision to copy, distribute and modify it." 1500 1501while test $[#] != 0 1502do 1503 case $[1] in 1504 --version | --v* | -V ) 1505 echo "$lt_cl_version"; exit 0 ;; 1506 --help | --h* | -h ) 1507 echo "$lt_cl_help"; exit 0 ;; 1508 --debug | --d* | -d ) 1509 debug=: ;; 1510 --quiet | --q* | --silent | --s* | -q ) 1511 lt_cl_silent=: ;; 1512 1513 -*) AC_MSG_ERROR([unrecognized option: $[1] 1514Try \`$[0] --help' for more information.]) ;; 1515 1516 *) AC_MSG_ERROR([unrecognized argument: $[1] 1517Try \`$[0] --help' for more information.]) ;; 1518 esac 1519 shift 1520done 1521 1522if $lt_cl_silent; then 1523 exec AS_MESSAGE_FD>/dev/null 1524fi 1525_LTEOF 1526 1527cat >>"$CONFIG_LT" <<_LTEOF 1528_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 1529_LTEOF 1530 1531cat >>"$CONFIG_LT" <<\_LTEOF 1532AC_MSG_NOTICE([creating $ofile]) 1533_LT_OUTPUT_LIBTOOL_COMMANDS 1534AS_EXIT(0) 1535_LTEOF 1536chmod +x "$CONFIG_LT" 1537 1538# configure is writing to config.log, but config.lt does its own redirection, 1539# appending to config.log, which fails on DOS, as config.log is still kept 1540# open by configure. Here we exec the FD to /dev/null, effectively closing 1541# config.log, so it can be properly (re)opened and appended to by config.lt. 1542if test "$no_create" != yes; then 1543 lt_cl_success=: 1544 test "$silent" = yes && 1545 lt_config_lt_args="$lt_config_lt_args --quiet" 1546 exec AS_MESSAGE_LOG_FD>/dev/null 1547 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 1548 exec AS_MESSAGE_LOG_FD>>config.log 1549 $lt_cl_success || AS_EXIT(1) 1550fi 1551])# LT_OUTPUT 1552 1553 1554# _LT_CONFIG(TAG) 1555# --------------- 1556# If TAG is the built-in tag, create an initial libtool script with a 1557# default configuration from the untagged config vars. Otherwise add code 1558# to config.status for appending the configuration named by TAG from the 1559# matching tagged config vars. 1560m4_defun([_LT_CONFIG], 1561[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 1562_LT_CONFIG_SAVE_COMMANDS([ 1563 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 1564 m4_if(_LT_TAG, [C], [ 1565 # See if we are running on zsh, and set the options which allow our 1566 # commands through without removal of \ escapes. 1567 if test -n "${ZSH_VERSION+set}" ; then 1568 setopt NO_GLOB_SUBST 1569 fi 1570 1571 cfgfile="${ofile}T" 1572 trap "$RM \"$cfgfile\"; exit 1" 1 2 15 1573 $RM "$cfgfile" 1574 1575 cat <<_LT_EOF >> "$cfgfile" 1576#! $SHELL 1577 1578# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 1579# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION 1580# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 1581# NOTE: Changes made to this file will be lost: look at ltmain.sh. 1582# 1583_LT_COPYING 1584_LT_LIBTOOL_TAGS 1585 1586# ### BEGIN LIBTOOL CONFIG 1587_LT_LIBTOOL_CONFIG_VARS 1588_LT_LIBTOOL_TAG_VARS 1589# ### END LIBTOOL CONFIG 1590 1591_LT_EOF 1592 1593 case $host_os in 1594 aix3*) 1595 cat <<\_LT_EOF >> "$cfgfile" 1596# AIX sometimes has problems with the GCC collect2 program. For some 1597# reason, if we set the COLLECT_NAMES environment variable, the problems 1598# vanish in a puff of smoke. 1599if test "X${COLLECT_NAMES+set}" != Xset; then 1600 COLLECT_NAMES= 1601 export COLLECT_NAMES 1602fi 1603_LT_EOF 1604 ;; 1605 esac 1606 1607 _LT_PROG_LTMAIN 1608 1609 # We use sed instead of cat because bash on DJGPP gets confused if 1610 # if finds mixed CR/LF and LF-only lines. Since sed operates in 1611 # text mode, it properly converts lines to CR/LF. This bash problem 1612 # is reportedly fixed, but why not run on old versions too? 1613 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ 1614 || (rm -f "$cfgfile"; exit 1) 1615 1616 _LT_PROG_XSI_SHELLFNS 1617 1618 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ 1619 || (rm -f "$cfgfile"; exit 1) 1620 1621 mv -f "$cfgfile" "$ofile" || 1622 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 1623 chmod +x "$ofile" 1624], 1625[cat <<_LT_EOF >> "$ofile" 1626 1627dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 1628dnl in a comment (ie after a #). 1629# ### BEGIN LIBTOOL TAG CONFIG: $1 1630_LT_LIBTOOL_TAG_VARS(_LT_TAG) 1631# ### END LIBTOOL TAG CONFIG: $1 1632_LT_EOF 1633])dnl /m4_if 1634], 1635[m4_if([$1], [], [ 1636 PACKAGE='$PACKAGE' 1637 VERSION='$VERSION' 1638 TIMESTAMP='$TIMESTAMP' 1639 RM='$RM' 1640 ofile='$ofile'], []) 1641])dnl /_LT_CONFIG_SAVE_COMMANDS 1642])# _LT_CONFIG 1643 1644 1645# LT_SUPPORTED_TAG(TAG) 1646# --------------------- 1647# Trace this macro to discover what tags are supported by the libtool 1648# --tag option, using: 1649# autoconf --trace 'LT_SUPPORTED_TAG:$1' 1650AC_DEFUN([LT_SUPPORTED_TAG], []) 1651 1652 1653# C support is built-in for now 1654m4_define([_LT_LANG_C_enabled], []) 1655m4_define([_LT_TAGS], []) 1656 1657 1658# LT_LANG(LANG) 1659# ------------- 1660# Enable libtool support for the given language if not already enabled. 1661AC_DEFUN([LT_LANG], 1662[AC_BEFORE([$0], [LT_OUTPUT])dnl 1663m4_case([$1], 1664 [C], [_LT_LANG(C)], 1665 [C++], [_LT_LANG(CXX)], 1666 [Java], [_LT_LANG(GCJ)], 1667 [Fortran 77], [_LT_LANG(F77)], 1668 [Fortran], [_LT_LANG(FC)], 1669 [Windows Resource], [_LT_LANG(RC)], 1670 [m4_ifdef([_LT_LANG_]$1[_CONFIG], 1671 [_LT_LANG($1)], 1672 [m4_fatal([$0: unsupported language: "$1"])])])dnl 1673])# LT_LANG 1674 1675 1676# _LT_LANG(LANGNAME) 1677# ------------------ 1678m4_defun([_LT_LANG], 1679[m4_ifdef([_LT_LANG_]$1[_enabled], [], 1680 [LT_SUPPORTED_TAG([$1])dnl 1681 m4_append([_LT_TAGS], [$1 ])dnl 1682 m4_define([_LT_LANG_]$1[_enabled], [])dnl 1683 _LT_LANG_$1_CONFIG($1)])dnl 1684])# _LT_LANG 1685 1686 1687# _LT_LANG_DEFAULT_CONFIG 1688# ----------------------- 1689m4_defun([_LT_LANG_DEFAULT_CONFIG], 1690[AC_PROVIDE_IFELSE([AC_PROG_CXX], 1691 [LT_LANG(CXX)], 1692 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 1693 1694AC_PROVIDE_IFELSE([AC_PROG_F77], 1695 [LT_LANG(F77)], 1696 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 1697 1698AC_PROVIDE_IFELSE([AC_PROG_FC], 1699 [LT_LANG(FC)], 1700 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 1701 1702dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 1703dnl pulling things in needlessly. 1704AC_PROVIDE_IFELSE([AC_PROG_GCJ], 1705 [LT_LANG(GCJ)], 1706 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 1707 [LT_LANG(GCJ)], 1708 [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 1709 [LT_LANG(GCJ)], 1710 [m4_ifdef([AC_PROG_GCJ], 1711 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 1712 m4_ifdef([A][M_PROG_GCJ], 1713 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 1714 m4_ifdef([LT_PROG_GCJ], 1715 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 1716 1717AC_PROVIDE_IFELSE([LT_PROG_RC], 1718 [LT_LANG(RC)], 1719 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 1720])# _LT_LANG_DEFAULT_CONFIG 1721 1722# Obsolete macros: 1723AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 1724AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 1725AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 1726AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 1727dnl aclocal-1.4 backwards compatibility: 1728dnl AC_DEFUN([AC_LIBTOOL_CXX], []) 1729dnl AC_DEFUN([AC_LIBTOOL_F77], []) 1730dnl AC_DEFUN([AC_LIBTOOL_FC], []) 1731dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 1732 1733 1734# _LT_TAG_COMPILER 1735# ---------------- 1736m4_defun([_LT_TAG_COMPILER], 1737[AC_REQUIRE([AC_PROG_CC])dnl 1738 1739_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 1740_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 1741_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 1742_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 1743 1744# If no C compiler was specified, use CC. 1745LTCC=${LTCC-"$CC"} 1746 1747# If no C compiler flags were specified, use CFLAGS. 1748LTCFLAGS=${LTCFLAGS-"$CFLAGS"} 1749 1750# Allow CC to be a program name with arguments. 1751compiler=$CC 1752])# _LT_TAG_COMPILER 1753 1754 1755# _LT_COMPILER_BOILERPLATE 1756# ------------------------ 1757# Check for compiler boilerplate output or warnings with 1758# the simple compiler test code. 1759m4_defun([_LT_COMPILER_BOILERPLATE], 1760[m4_require([_LT_DECL_SED])dnl 1761ac_outfile=conftest.$ac_objext 1762echo "$lt_simple_compile_test_code" >conftest.$ac_ext 1763eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 1764_lt_compiler_boilerplate=`cat conftest.err` 1765$RM conftest* 1766])# _LT_COMPILER_BOILERPLATE 1767 1768 1769# _LT_LINKER_BOILERPLATE 1770# ---------------------- 1771# Check for linker boilerplate output or warnings with 1772# the simple link test code. 1773m4_defun([_LT_LINKER_BOILERPLATE], 1774[m4_require([_LT_DECL_SED])dnl 1775ac_outfile=conftest.$ac_objext 1776echo "$lt_simple_link_test_code" >conftest.$ac_ext 1777eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 1778_lt_linker_boilerplate=`cat conftest.err` 1779$RM -r conftest* 1780])# _LT_LINKER_BOILERPLATE 1781 1782# _LT_REQUIRED_DARWIN_CHECKS 1783# ------------------------- 1784m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 1785 case $host_os in 1786 rhapsody* | darwin*) 1787 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 1788 AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 1789 AC_CHECK_TOOL([LIPO], [lipo], [:]) 1790 AC_CHECK_TOOL([OTOOL], [otool], [:]) 1791 AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 1792 _LT_DECL([], [DSYMUTIL], [1], 1793 [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 1794 _LT_DECL([], [NMEDIT], [1], 1795 [Tool to change global to local symbols on Mac OS X]) 1796 _LT_DECL([], [LIPO], [1], 1797 [Tool to manipulate fat objects and archives on Mac OS X]) 1798 _LT_DECL([], [OTOOL], [1], 1799 [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 1800 _LT_DECL([], [OTOOL64], [1], 1801 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 1802 1803 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 1804 [lt_cv_apple_cc_single_mod=no 1805 if test -z "${LT_MULTI_MODULE}"; then 1806 # By default we will add the -single_module flag. You can override 1807 # by either setting the environment variable LT_MULTI_MODULE 1808 # non-empty at configure time, or by adding -multi_module to the 1809 # link flags. 1810 rm -rf libconftest.dylib* 1811 echo "int foo(void){return 1;}" > conftest.c 1812 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 1813-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 1814 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 1815 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 1816 _lt_result=$? 1817 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then 1818 lt_cv_apple_cc_single_mod=yes 1819 else 1820 cat conftest.err >&AS_MESSAGE_LOG_FD 1821 fi 1822 rm -rf libconftest.dylib* 1823 rm -f conftest.* 1824 fi]) 1825 AC_CACHE_CHECK([for -exported_symbols_list linker flag], 1826 [lt_cv_ld_exported_symbols_list], 1827 [lt_cv_ld_exported_symbols_list=no 1828 save_LDFLAGS=$LDFLAGS 1829 echo "_main" > conftest.sym 1830 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 1831 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 1832 [lt_cv_ld_exported_symbols_list=yes], 1833 [lt_cv_ld_exported_symbols_list=no]) 1834 LDFLAGS="$save_LDFLAGS" 1835 ]) 1836 case $host_os in 1837 rhapsody* | darwin1.[[012]]) 1838 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 1839 darwin1.*) 1840 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 1841 darwin*) # darwin 5.x on 1842 # if running on 10.5 or later, the deployment target defaults 1843 # to the OS version, if on x86, and 10.4, the deployment 1844 # target defaults to 10.4. Don't you love it? 1845 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 1846 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 1847 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 1848 10.[[012]]*) 1849 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 1850 10.*) 1851 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 1852 esac 1853 ;; 1854 esac 1855 if test "$lt_cv_apple_cc_single_mod" = "yes"; then 1856 _lt_dar_single_mod='$single_module' 1857 fi 1858 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 1859 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 1860 else 1861 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' 1862 fi 1863 if test "$DSYMUTIL" != ":"; then 1864 _lt_dsymutil='~$DSYMUTIL $lib || :' 1865 else 1866 _lt_dsymutil= 1867 fi 1868 ;; 1869 esac 1870]) 1871 1872 1873# _LT_DARWIN_LINKER_FEATURES 1874# -------------------------- 1875# Checks for linker and compiler features on darwin 1876m4_defun([_LT_DARWIN_LINKER_FEATURES], 1877[ 1878 m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 1879 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 1880 _LT_TAGVAR(hardcode_direct, $1)=no 1881 _LT_TAGVAR(hardcode_automatic, $1)=yes 1882 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 1883 _LT_TAGVAR(whole_archive_flag_spec, $1)='' 1884 _LT_TAGVAR(link_all_deplibs, $1)=yes 1885 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 1886 case $cc_basename in 1887 ifort*) _lt_dar_can_shared=yes ;; 1888 *) _lt_dar_can_shared=$GCC ;; 1889 esac 1890 if test "$_lt_dar_can_shared" = "yes"; then 1891 output_verbose_link_cmd=echo 1892 _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" 1893 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 1894 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" 1895 _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" 1896 m4_if([$1], [CXX], 1897[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then 1898 _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" 1899 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" 1900 fi 1901],[]) 1902 else 1903 _LT_TAGVAR(ld_shlibs, $1)=no 1904 fi 1905]) 1906 1907# _LT_SYS_MODULE_PATH_AIX 1908# ----------------------- 1909# Links a minimal program and checks the executable 1910# for the system default hardcoded library path. In most cases, 1911# this is /usr/lib:/lib, but when the MPI compilers are used 1912# the location of the communication and MPI libs are included too. 1913# If we don't find anything, use the default library path according 1914# to the aix ld manual. 1915m4_defun([_LT_SYS_MODULE_PATH_AIX], 1916[m4_require([_LT_DECL_SED])dnl 1917AC_LINK_IFELSE(AC_LANG_PROGRAM,[ 1918lt_aix_libpath_sed=' 1919 /Import File Strings/,/^$/ { 1920 /^0/ { 1921 s/^0 *\(.*\)$/\1/ 1922 p 1923 } 1924 }' 1925aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 1926# Check for a 64-bit object if we didn't find anything. 1927if test -z "$aix_libpath"; then 1928 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 1929fi],[]) 1930if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 1931])# _LT_SYS_MODULE_PATH_AIX 1932 1933 1934# _LT_SHELL_INIT(ARG) 1935# ------------------- 1936m4_define([_LT_SHELL_INIT], 1937[ifdef([AC_DIVERSION_NOTICE], 1938 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], 1939 [AC_DIVERT_PUSH(NOTICE)]) 1940$1 1941AC_DIVERT_POP 1942])# _LT_SHELL_INIT 1943 1944 1945# _LT_PROG_ECHO_BACKSLASH 1946# ----------------------- 1947# Add some code to the start of the generated configure script which 1948# will find an echo command which doesn't interpret backslashes. 1949m4_defun([_LT_PROG_ECHO_BACKSLASH], 1950[_LT_SHELL_INIT([ 1951# Check that we are running under the correct shell. 1952SHELL=${CONFIG_SHELL-/bin/sh} 1953 1954case X$lt_ECHO in 1955X*--fallback-echo) 1956 # Remove one level of quotation (which was required for Make). 1957 ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` 1958 ;; 1959esac 1960 1961ECHO=${lt_ECHO-echo} 1962if test "X[$]1" = X--no-reexec; then 1963 # Discard the --no-reexec flag, and continue. 1964 shift 1965elif test "X[$]1" = X--fallback-echo; then 1966 # Avoid inline document here, it may be left over 1967 : 1968elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then 1969 # Yippee, $ECHO works! 1970 : 1971else 1972 # Restart under the correct shell. 1973 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} 1974fi 1975 1976if test "X[$]1" = X--fallback-echo; then 1977 # used as fallback echo 1978 shift 1979 cat <<_LT_EOF 1980[$]* 1981_LT_EOF 1982 exit 0 1983fi 1984 1985# The HP-UX ksh and POSIX shell print the target directory to stdout 1986# if CDPATH is set. 1987(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 1988 1989if test -z "$lt_ECHO"; then 1990 if test "X${echo_test_string+set}" != Xset; then 1991 # find a string as large as possible, as long as the shell can cope with it 1992 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do 1993 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... 1994 if { echo_test_string=`eval $cmd`; } 2>/dev/null && 1995 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null 1996 then 1997 break 1998 fi 1999 done 2000 fi 2001 2002 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && 2003 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && 2004 test "X$echo_testing_string" = "X$echo_test_string"; then 2005 : 2006 else 2007 # The Solaris, AIX, and Digital Unix default echo programs unquote 2008 # backslashes. This makes it impossible to quote backslashes using 2009 # echo "$something" | sed 's/\\/\\\\/g' 2010 # 2011 # So, first we look for a working echo in the user's PATH. 2012 2013 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2014 for dir in $PATH /usr/ucb; do 2015 IFS="$lt_save_ifs" 2016 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && 2017 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && 2018 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && 2019 test "X$echo_testing_string" = "X$echo_test_string"; then 2020 ECHO="$dir/echo" 2021 break 2022 fi 2023 done 2024 IFS="$lt_save_ifs" 2025 2026 if test "X$ECHO" = Xecho; then 2027 # We didn't find a better echo, so look for alternatives. 2028 if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' && 2029 echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` && 2030 test "X$echo_testing_string" = "X$echo_test_string"; then 2031 # This shell has a builtin print -r that does the trick. 2032 ECHO='print -r' 2033 elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } && 2034 test "X$CONFIG_SHELL" != X/bin/ksh; then 2035 # If we have ksh, try running configure again with it. 2036 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} 2037 export ORIGINAL_CONFIG_SHELL 2038 CONFIG_SHELL=/bin/ksh 2039 export CONFIG_SHELL 2040 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} 2041 else 2042 # Try using printf. 2043 ECHO='printf %s\n' 2044 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && 2045 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && 2046 test "X$echo_testing_string" = "X$echo_test_string"; then 2047 # Cool, printf works 2048 : 2049 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 2050 test "X$echo_testing_string" = 'X\t' && 2051 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 2052 test "X$echo_testing_string" = "X$echo_test_string"; then 2053 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL 2054 export CONFIG_SHELL 2055 SHELL="$CONFIG_SHELL" 2056 export SHELL 2057 ECHO="$CONFIG_SHELL [$]0 --fallback-echo" 2058 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 2059 test "X$echo_testing_string" = 'X\t' && 2060 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 2061 test "X$echo_testing_string" = "X$echo_test_string"; then 2062 ECHO="$CONFIG_SHELL [$]0 --fallback-echo" 2063 else 2064 # maybe with a smaller string... 2065 prev=: 2066 2067 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do 2068 if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null 2069 then 2070 break 2071 fi 2072 prev="$cmd" 2073 done 2074 2075 if test "$prev" != 'sed 50q "[$]0"'; then 2076 echo_test_string=`eval $prev` 2077 export echo_test_string 2078 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} 2079 else 2080 # Oops. We lost completely, so just stick with echo. 2081 ECHO=echo 2082 fi 2083 fi 2084 fi 2085 fi 2086 fi 2087fi 2088 2089# Copy echo and quote the copy suitably for passing to libtool from 2090# the Makefile, instead of quoting the original, which is used later. 2091lt_ECHO=$ECHO 2092if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then 2093 lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" 2094fi 2095 2096AC_SUBST(lt_ECHO) 2097]) 2098_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 2099_LT_DECL([], [ECHO], [1], 2100 [An echo program that does not interpret backslashes]) 2101])# _LT_PROG_ECHO_BACKSLASH 2102 2103 2104# _LT_ENABLE_LOCK 2105# --------------- 2106m4_defun([_LT_ENABLE_LOCK], 2107[AC_ARG_ENABLE([libtool-lock], 2108 [AS_HELP_STRING([--disable-libtool-lock], 2109 [avoid locking (might break parallel builds)])]) 2110test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 2111 2112# Some flags need to be propagated to the compiler or linker for good 2113# libtool support. 2114case $host in 2115ia64-*-hpux*) 2116 # Find out which ABI we are using. 2117 echo 'int i;' > conftest.$ac_ext 2118 if AC_TRY_EVAL(ac_compile); then 2119 case `/usr/bin/file conftest.$ac_objext` in 2120 *ELF-32*) 2121 HPUX_IA64_MODE="32" 2122 ;; 2123 *ELF-64*) 2124 HPUX_IA64_MODE="64" 2125 ;; 2126 esac 2127 fi 2128 rm -rf conftest* 2129 ;; 2130*-*-irix6*) 2131 # Find out which ABI we are using. 2132 echo '[#]line __oline__ "configure"' > conftest.$ac_ext 2133 if AC_TRY_EVAL(ac_compile); then 2134 if test "$lt_cv_prog_gnu_ld" = yes; then 2135 case `/usr/bin/file conftest.$ac_objext` in 2136 *32-bit*) 2137 LD="${LD-ld} -melf32bsmip" 2138 ;; 2139 *N32*) 2140 LD="${LD-ld} -melf32bmipn32" 2141 ;; 2142 *64-bit*) 2143 LD="${LD-ld} -melf64bmip" 2144 ;; 2145 esac 2146 else 2147 case `/usr/bin/file conftest.$ac_objext` in 2148 *32-bit*) 2149 LD="${LD-ld} -32" 2150 ;; 2151 *N32*) 2152 LD="${LD-ld} -n32" 2153 ;; 2154 *64-bit*) 2155 LD="${LD-ld} -64" 2156 ;; 2157 esac 2158 fi 2159 fi 2160 rm -rf conftest* 2161 ;; 2162 2163x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 2164s390*-*linux*|s390*-*tpf*|sparc*-*linux*) 2165 # Find out which ABI we are using. 2166 echo 'int i;' > conftest.$ac_ext 2167 if AC_TRY_EVAL(ac_compile); then 2168 case `/usr/bin/file conftest.o` in 2169 *32-bit*) 2170 case $host in 2171 x86_64-*kfreebsd*-gnu) 2172 LD="${LD-ld} -m elf_i386_fbsd" 2173 ;; 2174 x86_64-*linux*) 2175 LD="${LD-ld} -m elf_i386" 2176 ;; 2177 ppc64-*linux*|powerpc64-*linux*) 2178 LD="${LD-ld} -m elf32ppclinux" 2179 ;; 2180 s390x-*linux*) 2181 LD="${LD-ld} -m elf_s390" 2182 ;; 2183 sparc64-*linux*) 2184 LD="${LD-ld} -m elf32_sparc" 2185 ;; 2186 esac 2187 ;; 2188 *64-bit*) 2189 case $host in 2190 x86_64-*kfreebsd*-gnu) 2191 LD="${LD-ld} -m elf_x86_64_fbsd" 2192 ;; 2193 x86_64-*linux*) 2194 LD="${LD-ld} -m elf_x86_64" 2195 ;; 2196 ppc*-*linux*|powerpc*-*linux*) 2197 LD="${LD-ld} -m elf64ppc" 2198 ;; 2199 s390*-*linux*|s390*-*tpf*) 2200 LD="${LD-ld} -m elf64_s390" 2201 ;; 2202 sparc*-*linux*) 2203 LD="${LD-ld} -m elf64_sparc" 2204 ;; 2205 esac 2206 ;; 2207 esac 2208 fi 2209 rm -rf conftest* 2210 ;; 2211 2212*-*-sco3.2v5*) 2213 # On SCO OpenServer 5, we need -belf to get full-featured binaries. 2214 SAVE_CFLAGS="$CFLAGS" 2215 CFLAGS="$CFLAGS -belf" 2216 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 2217 [AC_LANG_PUSH(C) 2218 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 2219 AC_LANG_POP]) 2220 if test x"$lt_cv_cc_needs_belf" != x"yes"; then 2221 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 2222 CFLAGS="$SAVE_CFLAGS" 2223 fi 2224 ;; 2225sparc*-*solaris*) 2226 # Find out which ABI we are using. 2227 echo 'int i;' > conftest.$ac_ext 2228 if AC_TRY_EVAL(ac_compile); then 2229 case `/usr/bin/file conftest.o` in 2230 *64-bit*) 2231 case $lt_cv_prog_gnu_ld in 2232 yes*) LD="${LD-ld} -m elf64_sparc" ;; 2233 *) 2234 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 2235 LD="${LD-ld} -64" 2236 fi 2237 ;; 2238 esac 2239 ;; 2240 esac 2241 fi 2242 rm -rf conftest* 2243 ;; 2244esac 2245 2246need_locks="$enable_libtool_lock" 2247])# _LT_ENABLE_LOCK 2248 2249 2250# _LT_CMD_OLD_ARCHIVE 2251# ------------------- 2252m4_defun([_LT_CMD_OLD_ARCHIVE], 2253[AC_CHECK_TOOL(AR, ar, false) 2254test -z "$AR" && AR=ar 2255test -z "$AR_FLAGS" && AR_FLAGS=cru 2256_LT_DECL([], [AR], [1], [The archiver]) 2257_LT_DECL([], [AR_FLAGS], [1]) 2258 2259AC_CHECK_TOOL(STRIP, strip, :) 2260test -z "$STRIP" && STRIP=: 2261_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 2262 2263AC_CHECK_TOOL(RANLIB, ranlib, :) 2264test -z "$RANLIB" && RANLIB=: 2265_LT_DECL([], [RANLIB], [1], 2266 [Commands used to install an old-style archive]) 2267 2268# Determine commands to create old-style static archives. 2269old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 2270old_postinstall_cmds='chmod 644 $oldlib' 2271old_postuninstall_cmds= 2272 2273if test -n "$RANLIB"; then 2274 case $host_os in 2275 openbsd*) 2276 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 2277 ;; 2278 *) 2279 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 2280 ;; 2281 esac 2282 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 2283fi 2284_LT_DECL([], [old_postinstall_cmds], [2]) 2285_LT_DECL([], [old_postuninstall_cmds], [2]) 2286_LT_TAGDECL([], [old_archive_cmds], [2], 2287 [Commands used to build an old-style archive]) 2288])# _LT_CMD_OLD_ARCHIVE 2289 2290 2291# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 2292# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 2293# ---------------------------------------------------------------- 2294# Check whether the given compiler option works 2295AC_DEFUN([_LT_COMPILER_OPTION], 2296[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2297m4_require([_LT_DECL_SED])dnl 2298AC_CACHE_CHECK([$1], [$2], 2299 [$2=no 2300 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 2301 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 2302 lt_compiler_flag="$3" 2303 # Insert the option either (1) after the last *FLAGS variable, or 2304 # (2) before a word containing "conftest.", or (3) at the end. 2305 # Note that $ac_compile itself does not contain backslashes and begins 2306 # with a dollar sign (not a hyphen), so the echo should work correctly. 2307 # The option is referenced via a variable to avoid confusing sed. 2308 lt_compile=`echo "$ac_compile" | $SED \ 2309 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 2310 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 2311 -e 's:$: $lt_compiler_flag:'` 2312 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 2313 (eval "$lt_compile" 2>conftest.err) 2314 ac_status=$? 2315 cat conftest.err >&AS_MESSAGE_LOG_FD 2316 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 2317 if (exit $ac_status) && test -s "$ac_outfile"; then 2318 # The compiler can only warn and ignore the option if not recognized 2319 # So say no if there are warnings other than the usual output. 2320 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp 2321 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 2322 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 2323 $2=yes 2324 fi 2325 fi 2326 $RM conftest* 2327]) 2328 2329if test x"[$]$2" = xyes; then 2330 m4_if([$5], , :, [$5]) 2331else 2332 m4_if([$6], , :, [$6]) 2333fi 2334])# _LT_COMPILER_OPTION 2335 2336# Old name: 2337AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 2338dnl aclocal-1.4 backwards compatibility: 2339dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 2340 2341 2342# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 2343# [ACTION-SUCCESS], [ACTION-FAILURE]) 2344# ---------------------------------------------------- 2345# Check whether the given linker option works 2346AC_DEFUN([_LT_LINKER_OPTION], 2347[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2348m4_require([_LT_DECL_SED])dnl 2349AC_CACHE_CHECK([$1], [$2], 2350 [$2=no 2351 save_LDFLAGS="$LDFLAGS" 2352 LDFLAGS="$LDFLAGS $3" 2353 echo "$lt_simple_link_test_code" > conftest.$ac_ext 2354 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 2355 # The linker can only warn and ignore the option if not recognized 2356 # So say no if there are warnings 2357 if test -s conftest.err; then 2358 # Append any errors to the config.log. 2359 cat conftest.err 1>&AS_MESSAGE_LOG_FD 2360 $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp 2361 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 2362 if diff conftest.exp conftest.er2 >/dev/null; then 2363 $2=yes 2364 fi 2365 else 2366 $2=yes 2367 fi 2368 fi 2369 $RM -r conftest* 2370 LDFLAGS="$save_LDFLAGS" 2371]) 2372 2373if test x"[$]$2" = xyes; then 2374 m4_if([$4], , :, [$4]) 2375else 2376 m4_if([$5], , :, [$5]) 2377fi 2378])# _LT_LINKER_OPTION 2379 2380# Old name: 2381AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 2382dnl aclocal-1.4 backwards compatibility: 2383dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 2384 2385 2386# LT_CMD_MAX_LEN 2387#--------------- 2388AC_DEFUN([LT_CMD_MAX_LEN], 2389[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2390# find the maximum length of command line arguments 2391AC_MSG_CHECKING([the maximum length of command line arguments]) 2392AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 2393 i=0 2394 teststring="ABCD" 2395 2396 case $build_os in 2397 msdosdjgpp*) 2398 # On DJGPP, this test can blow up pretty badly due to problems in libc 2399 # (any single argument exceeding 2000 bytes causes a buffer overrun 2400 # during glob expansion). Even if it were fixed, the result of this 2401 # check would be larger than it should be. 2402 lt_cv_sys_max_cmd_len=12288; # 12K is about right 2403 ;; 2404 2405 gnu*) 2406 # Under GNU Hurd, this test is not required because there is 2407 # no limit to the length of command line arguments. 2408 # Libtool will interpret -1 as no limit whatsoever 2409 lt_cv_sys_max_cmd_len=-1; 2410 ;; 2411 2412 cygwin* | mingw* | cegcc*) 2413 # On Win9x/ME, this test blows up -- it succeeds, but takes 2414 # about 5 minutes as the teststring grows exponentially. 2415 # Worse, since 9x/ME are not pre-emptively multitasking, 2416 # you end up with a "frozen" computer, even though with patience 2417 # the test eventually succeeds (with a max line length of 256k). 2418 # Instead, let's just punt: use the minimum linelength reported by 2419 # all of the supported platforms: 8192 (on NT/2K/XP). 2420 lt_cv_sys_max_cmd_len=8192; 2421 ;; 2422 2423 amigaos*) 2424 # On AmigaOS with pdksh, this test takes hours, literally. 2425 # So we just punt and use a minimum line length of 8192. 2426 lt_cv_sys_max_cmd_len=8192; 2427 ;; 2428 2429 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 2430 # This has been around since 386BSD, at least. Likely further. 2431 if test -x /sbin/sysctl; then 2432 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 2433 elif test -x /usr/sbin/sysctl; then 2434 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 2435 else 2436 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 2437 fi 2438 # And add a safety zone 2439 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 2440 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 2441 ;; 2442 2443 interix*) 2444 # We know the value 262144 and hardcode it with a safety zone (like BSD) 2445 lt_cv_sys_max_cmd_len=196608 2446 ;; 2447 2448 osf*) 2449 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 2450 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 2451 # nice to cause kernel panics so lets avoid the loop below. 2452 # First set a reasonable default. 2453 lt_cv_sys_max_cmd_len=16384 2454 # 2455 if test -x /sbin/sysconfig; then 2456 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 2457 *1*) lt_cv_sys_max_cmd_len=-1 ;; 2458 esac 2459 fi 2460 ;; 2461 sco3.2v5*) 2462 lt_cv_sys_max_cmd_len=102400 2463 ;; 2464 sysv5* | sco5v6* | sysv4.2uw2*) 2465 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 2466 if test -n "$kargmax"; then 2467 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 2468 else 2469 lt_cv_sys_max_cmd_len=32768 2470 fi 2471 ;; 2472 *) 2473 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 2474 if test -n "$lt_cv_sys_max_cmd_len"; then 2475 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 2476 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 2477 else 2478 # Make teststring a little bigger before we do anything with it. 2479 # a 1K string should be a reasonable start. 2480 for i in 1 2 3 4 5 6 7 8 ; do 2481 teststring=$teststring$teststring 2482 done 2483 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 2484 # If test is not a shell built-in, we'll probably end up computing a 2485 # maximum length that is only half of the actual maximum length, but 2486 # we can't tell. 2487 while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \ 2488 = "XX$teststring$teststring"; } >/dev/null 2>&1 && 2489 test $i != 17 # 1/2 MB should be enough 2490 do 2491 i=`expr $i + 1` 2492 teststring=$teststring$teststring 2493 done 2494 # Only check the string length outside the loop. 2495 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 2496 teststring= 2497 # Add a significant safety factor because C++ compilers can tack on 2498 # massive amounts of additional arguments before passing them to the 2499 # linker. It appears as though 1/2 is a usable value. 2500 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 2501 fi 2502 ;; 2503 esac 2504]) 2505if test -n $lt_cv_sys_max_cmd_len ; then 2506 AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 2507else 2508 AC_MSG_RESULT(none) 2509fi 2510max_cmd_len=$lt_cv_sys_max_cmd_len 2511_LT_DECL([], [max_cmd_len], [0], 2512 [What is the maximum length of a command?]) 2513])# LT_CMD_MAX_LEN 2514 2515# Old name: 2516AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 2517dnl aclocal-1.4 backwards compatibility: 2518dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 2519 2520 2521# _LT_HEADER_DLFCN 2522# ---------------- 2523m4_defun([_LT_HEADER_DLFCN], 2524[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 2525])# _LT_HEADER_DLFCN 2526 2527 2528# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 2529# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 2530# ---------------------------------------------------------------- 2531m4_defun([_LT_TRY_DLOPEN_SELF], 2532[m4_require([_LT_HEADER_DLFCN])dnl 2533if test "$cross_compiling" = yes; then : 2534 [$4] 2535else 2536 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 2537 lt_status=$lt_dlunknown 2538 cat > conftest.$ac_ext <<_LT_EOF 2539[#line __oline__ "configure" 2540#include "confdefs.h" 2541 2542#if HAVE_DLFCN_H 2543#include <dlfcn.h> 2544#endif 2545 2546#include <stdio.h> 2547 2548#ifdef RTLD_GLOBAL 2549# define LT_DLGLOBAL RTLD_GLOBAL 2550#else 2551# ifdef DL_GLOBAL 2552# define LT_DLGLOBAL DL_GLOBAL 2553# else 2554# define LT_DLGLOBAL 0 2555# endif 2556#endif 2557 2558/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 2559 find out it does not work in some platform. */ 2560#ifndef LT_DLLAZY_OR_NOW 2561# ifdef RTLD_LAZY 2562# define LT_DLLAZY_OR_NOW RTLD_LAZY 2563# else 2564# ifdef DL_LAZY 2565# define LT_DLLAZY_OR_NOW DL_LAZY 2566# else 2567# ifdef RTLD_NOW 2568# define LT_DLLAZY_OR_NOW RTLD_NOW 2569# else 2570# ifdef DL_NOW 2571# define LT_DLLAZY_OR_NOW DL_NOW 2572# else 2573# define LT_DLLAZY_OR_NOW 0 2574# endif 2575# endif 2576# endif 2577# endif 2578#endif 2579 2580void fnord() { int i=42;} 2581int main () 2582{ 2583 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 2584 int status = $lt_dlunknown; 2585 2586 if (self) 2587 { 2588 if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 2589 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 2590 /* dlclose (self); */ 2591 } 2592 else 2593 puts (dlerror ()); 2594 2595 return status; 2596}] 2597_LT_EOF 2598 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 2599 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 2600 lt_status=$? 2601 case x$lt_status in 2602 x$lt_dlno_uscore) $1 ;; 2603 x$lt_dlneed_uscore) $2 ;; 2604 x$lt_dlunknown|x*) $3 ;; 2605 esac 2606 else : 2607 # compilation failed 2608 $3 2609 fi 2610fi 2611rm -fr conftest* 2612])# _LT_TRY_DLOPEN_SELF 2613 2614 2615# LT_SYS_DLOPEN_SELF 2616# ------------------ 2617AC_DEFUN([LT_SYS_DLOPEN_SELF], 2618[m4_require([_LT_HEADER_DLFCN])dnl 2619if test "x$enable_dlopen" != xyes; then 2620 enable_dlopen=unknown 2621 enable_dlopen_self=unknown 2622 enable_dlopen_self_static=unknown 2623else 2624 lt_cv_dlopen=no 2625 lt_cv_dlopen_libs= 2626 2627 case $host_os in 2628 beos*) 2629 lt_cv_dlopen="load_add_on" 2630 lt_cv_dlopen_libs= 2631 lt_cv_dlopen_self=yes 2632 ;; 2633 2634 mingw* | pw32* | cegcc*) 2635 lt_cv_dlopen="LoadLibrary" 2636 lt_cv_dlopen_libs= 2637 ;; 2638 2639 cygwin*) 2640 lt_cv_dlopen="dlopen" 2641 lt_cv_dlopen_libs= 2642 ;; 2643 2644 darwin*) 2645 # if libdl is installed we need to link against it 2646 AC_CHECK_LIB([dl], [dlopen], 2647 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 2648 lt_cv_dlopen="dyld" 2649 lt_cv_dlopen_libs= 2650 lt_cv_dlopen_self=yes 2651 ]) 2652 ;; 2653 2654 *) 2655 AC_CHECK_FUNC([shl_load], 2656 [lt_cv_dlopen="shl_load"], 2657 [AC_CHECK_LIB([dld], [shl_load], 2658 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 2659 [AC_CHECK_FUNC([dlopen], 2660 [lt_cv_dlopen="dlopen"], 2661 [AC_CHECK_LIB([dl], [dlopen], 2662 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 2663 [AC_CHECK_LIB([svld], [dlopen], 2664 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 2665 [AC_CHECK_LIB([dld], [dld_link], 2666 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 2667 ]) 2668 ]) 2669 ]) 2670 ]) 2671 ]) 2672 ;; 2673 esac 2674 2675 if test "x$lt_cv_dlopen" != xno; then 2676 enable_dlopen=yes 2677 else 2678 enable_dlopen=no 2679 fi 2680 2681 case $lt_cv_dlopen in 2682 dlopen) 2683 save_CPPFLAGS="$CPPFLAGS" 2684 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 2685 2686 save_LDFLAGS="$LDFLAGS" 2687 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 2688 2689 save_LIBS="$LIBS" 2690 LIBS="$lt_cv_dlopen_libs $LIBS" 2691 2692 AC_CACHE_CHECK([whether a program can dlopen itself], 2693 lt_cv_dlopen_self, [dnl 2694 _LT_TRY_DLOPEN_SELF( 2695 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 2696 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 2697 ]) 2698 2699 if test "x$lt_cv_dlopen_self" = xyes; then 2700 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 2701 AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 2702 lt_cv_dlopen_self_static, [dnl 2703 _LT_TRY_DLOPEN_SELF( 2704 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 2705 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 2706 ]) 2707 fi 2708 2709 CPPFLAGS="$save_CPPFLAGS" 2710 LDFLAGS="$save_LDFLAGS" 2711 LIBS="$save_LIBS" 2712 ;; 2713 esac 2714 2715 case $lt_cv_dlopen_self in 2716 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 2717 *) enable_dlopen_self=unknown ;; 2718 esac 2719 2720 case $lt_cv_dlopen_self_static in 2721 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 2722 *) enable_dlopen_self_static=unknown ;; 2723 esac 2724fi 2725_LT_DECL([dlopen_support], [enable_dlopen], [0], 2726 [Whether dlopen is supported]) 2727_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 2728 [Whether dlopen of programs is supported]) 2729_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 2730 [Whether dlopen of statically linked programs is supported]) 2731])# LT_SYS_DLOPEN_SELF 2732 2733# Old name: 2734AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 2735dnl aclocal-1.4 backwards compatibility: 2736dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 2737 2738 2739# _LT_COMPILER_C_O([TAGNAME]) 2740# --------------------------- 2741# Check to see if options -c and -o are simultaneously supported by compiler. 2742# This macro does not hard code the compiler like AC_PROG_CC_C_O. 2743m4_defun([_LT_COMPILER_C_O], 2744[m4_require([_LT_DECL_SED])dnl 2745m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2746m4_require([_LT_TAG_COMPILER])dnl 2747AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 2748 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 2749 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 2750 $RM -r conftest 2>/dev/null 2751 mkdir conftest 2752 cd conftest 2753 mkdir out 2754 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 2755 2756 lt_compiler_flag="-o out/conftest2.$ac_objext" 2757 # Insert the option either (1) after the last *FLAGS variable, or 2758 # (2) before a word containing "conftest.", or (3) at the end. 2759 # Note that $ac_compile itself does not contain backslashes and begins 2760 # with a dollar sign (not a hyphen), so the echo should work correctly. 2761 lt_compile=`echo "$ac_compile" | $SED \ 2762 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 2763 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 2764 -e 's:$: $lt_compiler_flag:'` 2765 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 2766 (eval "$lt_compile" 2>out/conftest.err) 2767 ac_status=$? 2768 cat out/conftest.err >&AS_MESSAGE_LOG_FD 2769 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 2770 if (exit $ac_status) && test -s out/conftest2.$ac_objext 2771 then 2772 # The compiler can only warn and ignore the option if not recognized 2773 # So say no if there are warnings 2774 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp 2775 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 2776 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 2777 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 2778 fi 2779 fi 2780 chmod u+w . 2>&AS_MESSAGE_LOG_FD 2781 $RM conftest* 2782 # SGI C++ compiler will create directory out/ii_files/ for 2783 # template instantiation 2784 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 2785 $RM out/* && rmdir out 2786 cd .. 2787 $RM -r conftest 2788 $RM conftest* 2789]) 2790_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 2791 [Does compiler simultaneously support -c and -o options?]) 2792])# _LT_COMPILER_C_O 2793 2794 2795# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 2796# ---------------------------------- 2797# Check to see if we can do hard links to lock some files if needed 2798m4_defun([_LT_COMPILER_FILE_LOCKS], 2799[m4_require([_LT_ENABLE_LOCK])dnl 2800m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2801_LT_COMPILER_C_O([$1]) 2802 2803hard_links="nottested" 2804if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 2805 # do not overwrite the value of need_locks provided by the user 2806 AC_MSG_CHECKING([if we can lock with hard links]) 2807 hard_links=yes 2808 $RM conftest* 2809 ln conftest.a conftest.b 2>/dev/null && hard_links=no 2810 touch conftest.a 2811 ln conftest.a conftest.b 2>&5 || hard_links=no 2812 ln conftest.a conftest.b 2>/dev/null && hard_links=no 2813 AC_MSG_RESULT([$hard_links]) 2814 if test "$hard_links" = no; then 2815 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 2816 need_locks=warn 2817 fi 2818else 2819 need_locks=no 2820fi 2821_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 2822])# _LT_COMPILER_FILE_LOCKS 2823 2824 2825# _LT_CHECK_OBJDIR 2826# ---------------- 2827m4_defun([_LT_CHECK_OBJDIR], 2828[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 2829[rm -f .libs 2>/dev/null 2830mkdir .libs 2>/dev/null 2831if test -d .libs; then 2832 lt_cv_objdir=.libs 2833else 2834 # MS-DOS does not allow filenames that begin with a dot. 2835 lt_cv_objdir=_libs 2836fi 2837rmdir .libs 2>/dev/null]) 2838objdir=$lt_cv_objdir 2839_LT_DECL([], [objdir], [0], 2840 [The name of the directory that contains temporary libtool files])dnl 2841m4_pattern_allow([LT_OBJDIR])dnl 2842AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", 2843 [Define to the sub-directory in which libtool stores uninstalled libraries.]) 2844])# _LT_CHECK_OBJDIR 2845 2846 2847# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 2848# -------------------------------------- 2849# Check hardcoding attributes. 2850m4_defun([_LT_LINKER_HARDCODE_LIBPATH], 2851[AC_MSG_CHECKING([how to hardcode library paths into programs]) 2852_LT_TAGVAR(hardcode_action, $1)= 2853if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 2854 test -n "$_LT_TAGVAR(runpath_var, $1)" || 2855 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 2856 2857 # We can hardcode non-existent directories. 2858 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && 2859 # If the only mechanism to avoid hardcoding is shlibpath_var, we 2860 # have to relink, otherwise we might link with an installed library 2861 # when we should be linking with a yet-to-be-installed one 2862 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && 2863 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then 2864 # Linking always hardcodes the temporary library directory. 2865 _LT_TAGVAR(hardcode_action, $1)=relink 2866 else 2867 # We can link without hardcoding, and we can hardcode nonexisting dirs. 2868 _LT_TAGVAR(hardcode_action, $1)=immediate 2869 fi 2870else 2871 # We cannot hardcode anything, or else we can only hardcode existing 2872 # directories. 2873 _LT_TAGVAR(hardcode_action, $1)=unsupported 2874fi 2875AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 2876 2877if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || 2878 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then 2879 # Fast installation is not supported 2880 enable_fast_install=no 2881elif test "$shlibpath_overrides_runpath" = yes || 2882 test "$enable_shared" = no; then 2883 # Fast installation is not necessary 2884 enable_fast_install=needless 2885fi 2886_LT_TAGDECL([], [hardcode_action], [0], 2887 [How to hardcode a shared library path into an executable]) 2888])# _LT_LINKER_HARDCODE_LIBPATH 2889 2890 2891# _LT_CMD_STRIPLIB 2892# ---------------- 2893m4_defun([_LT_CMD_STRIPLIB], 2894[m4_require([_LT_DECL_EGREP]) 2895striplib= 2896old_striplib= 2897AC_MSG_CHECKING([whether stripping libraries is possible]) 2898if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 2899 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 2900 test -z "$striplib" && striplib="$STRIP --strip-unneeded" 2901 AC_MSG_RESULT([yes]) 2902else 2903# FIXME - insert some real tests, host_os isn't really good enough 2904 case $host_os in 2905 darwin*) 2906 if test -n "$STRIP" ; then 2907 striplib="$STRIP -x" 2908 old_striplib="$STRIP -S" 2909 AC_MSG_RESULT([yes]) 2910 else 2911 AC_MSG_RESULT([no]) 2912 fi 2913 ;; 2914 *) 2915 AC_MSG_RESULT([no]) 2916 ;; 2917 esac 2918fi 2919_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 2920_LT_DECL([], [striplib], [1]) 2921])# _LT_CMD_STRIPLIB 2922 2923 2924# _LT_SYS_DYNAMIC_LINKER([TAG]) 2925# ----------------------------- 2926# PORTME Fill in your ld.so characteristics 2927m4_defun([_LT_SYS_DYNAMIC_LINKER], 2928[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2929m4_require([_LT_DECL_EGREP])dnl 2930m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2931m4_require([_LT_DECL_OBJDUMP])dnl 2932m4_require([_LT_DECL_SED])dnl 2933AC_MSG_CHECKING([dynamic linker characteristics]) 2934m4_if([$1], 2935 [], [ 2936if test "$GCC" = yes; then 2937 case $host_os in 2938 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 2939 *) lt_awk_arg="/^libraries:/" ;; 2940 esac 2941 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` 2942 if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then 2943 # if the path contains ";" then we assume it to be the separator 2944 # otherwise default to the standard path separator (i.e. ":") - it is 2945 # assumed that no part of a normal pathname contains ";" but that should 2946 # okay in the real world where ";" in dirpaths is itself problematic. 2947 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'` 2948 else 2949 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 2950 fi 2951 # Ok, now we have the path, separated by spaces, we can step through it 2952 # and add multilib dir if necessary. 2953 lt_tmp_lt_search_path_spec= 2954 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 2955 for lt_sys_path in $lt_search_path_spec; do 2956 if test -d "$lt_sys_path/$lt_multi_os_dir"; then 2957 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 2958 else 2959 test -d "$lt_sys_path" && \ 2960 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 2961 fi 2962 done 2963 lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk ' 2964BEGIN {RS=" "; FS="/|\n";} { 2965 lt_foo=""; 2966 lt_count=0; 2967 for (lt_i = NF; lt_i > 0; lt_i--) { 2968 if ($lt_i != "" && $lt_i != ".") { 2969 if ($lt_i == "..") { 2970 lt_count++; 2971 } else { 2972 if (lt_count == 0) { 2973 lt_foo="/" $lt_i lt_foo; 2974 } else { 2975 lt_count--; 2976 } 2977 } 2978 } 2979 } 2980 if (lt_foo != "") { lt_freq[[lt_foo]]++; } 2981 if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 2982}'` 2983 sys_lib_search_path_spec=`$ECHO $lt_search_path_spec` 2984else 2985 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 2986fi]) 2987library_names_spec= 2988libname_spec='lib$name' 2989soname_spec= 2990shrext_cmds=".so" 2991postinstall_cmds= 2992postuninstall_cmds= 2993finish_cmds= 2994finish_eval= 2995shlibpath_var= 2996shlibpath_overrides_runpath=unknown 2997version_type=none 2998dynamic_linker="$host_os ld.so" 2999sys_lib_dlsearch_path_spec="/lib /usr/lib" 3000need_lib_prefix=unknown 3001hardcode_into_libs=no 3002 3003# when you set need_version to no, make sure it does not cause -set_version 3004# flags to be left without arguments 3005need_version=unknown 3006 3007case $host_os in 3008aix3*) 3009 version_type=linux 3010 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 3011 shlibpath_var=LIBPATH 3012 3013 # AIX 3 has no versioning support, so we append a major version to the name. 3014 soname_spec='${libname}${release}${shared_ext}$major' 3015 ;; 3016 3017aix[[4-9]]*) 3018 version_type=linux 3019 need_lib_prefix=no 3020 need_version=no 3021 hardcode_into_libs=yes 3022 if test "$host_cpu" = ia64; then 3023 # AIX 5 supports IA64 3024 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 3025 shlibpath_var=LD_LIBRARY_PATH 3026 else 3027 # With GCC up to 2.95.x, collect2 would create an import file 3028 # for dependence libraries. The import file would start with 3029 # the line `#! .'. This would cause the generated library to 3030 # depend on `.', always an invalid library. This was fixed in 3031 # development snapshots of GCC prior to 3.0. 3032 case $host_os in 3033 aix4 | aix4.[[01]] | aix4.[[01]].*) 3034 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 3035 echo ' yes ' 3036 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then 3037 : 3038 else 3039 can_build_shared=no 3040 fi 3041 ;; 3042 esac 3043 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 3044 # soname into executable. Probably we can add versioning support to 3045 # collect2, so additional links can be useful in future. 3046 if test "$aix_use_runtimelinking" = yes; then 3047 # If using run time linking (on AIX 4.2 or later) use lib<name>.so 3048 # instead of lib<name>.a to let people know that these are not 3049 # typical AIX shared libraries. 3050 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3051 else 3052 # We preserve .a as extension for shared libraries through AIX4.2 3053 # and later when we are not doing run time linking. 3054 library_names_spec='${libname}${release}.a $libname.a' 3055 soname_spec='${libname}${release}${shared_ext}$major' 3056 fi 3057 shlibpath_var=LIBPATH 3058 fi 3059 ;; 3060 3061amigaos*) 3062 case $host_cpu in 3063 powerpc) 3064 # Since July 2007 AmigaOS4 officially supports .so libraries. 3065 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 3066 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3067 ;; 3068 m68k) 3069 library_names_spec='$libname.ixlibrary $libname.a' 3070 # Create ${libname}_ixlibrary.a entries in /sys/libs. 3071 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' 3072 ;; 3073 esac 3074 ;; 3075 3076beos*) 3077 library_names_spec='${libname}${shared_ext}' 3078 dynamic_linker="$host_os ld.so" 3079 shlibpath_var=LIBRARY_PATH 3080 ;; 3081 3082bsdi[[45]]*) 3083 version_type=linux 3084 need_version=no 3085 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3086 soname_spec='${libname}${release}${shared_ext}$major' 3087 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 3088 shlibpath_var=LD_LIBRARY_PATH 3089 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 3090 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 3091 # the default ld.so.conf also contains /usr/contrib/lib and 3092 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 3093 # libtool to hard-code these into programs 3094 ;; 3095 3096cygwin* | mingw* | pw32* | cegcc*) 3097 version_type=windows 3098 shrext_cmds=".dll" 3099 need_version=no 3100 need_lib_prefix=no 3101 3102 case $GCC,$host_os in 3103 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) 3104 library_names_spec='$libname.dll.a' 3105 # DLL is installed to $(libdir)/../bin by postinstall_cmds 3106 postinstall_cmds='base_file=`basename \${file}`~ 3107 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 3108 dldir=$destdir/`dirname \$dlpath`~ 3109 test -d \$dldir || mkdir -p \$dldir~ 3110 $install_prog $dir/$dlname \$dldir/$dlname~ 3111 chmod a+x \$dldir/$dlname~ 3112 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 3113 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 3114 fi' 3115 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 3116 dlpath=$dir/\$dldll~ 3117 $RM \$dlpath' 3118 shlibpath_overrides_runpath=yes 3119 3120 case $host_os in 3121 cygwin*) 3122 # Cygwin DLLs use 'cyg' prefix rather than 'lib' 3123 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 3124 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" 3125 ;; 3126 mingw* | cegcc*) 3127 # MinGW DLLs use traditional 'lib' prefix 3128 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 3129 sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` 3130 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then 3131 # It is most probably a Windows format PATH printed by 3132 # mingw gcc, but we are running on Cygwin. Gcc prints its search 3133 # path with ; separators, and with drive letters. We can handle the 3134 # drive letters (cygwin fileutils understands them), so leave them, 3135 # especially as we might pass files found there to a mingw objdump, 3136 # which wouldn't understand a cygwinified path. Ahh. 3137 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 3138 else 3139 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 3140 fi 3141 ;; 3142 pw32*) 3143 # pw32 DLLs use 'pw' prefix rather than 'lib' 3144 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 3145 ;; 3146 esac 3147 ;; 3148 3149 *) 3150 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 3151 ;; 3152 esac 3153 dynamic_linker='Win32 ld.exe' 3154 # FIXME: first we should search . and the directory the executable is in 3155 shlibpath_var=PATH 3156 ;; 3157 3158darwin* | rhapsody*) 3159 dynamic_linker="$host_os dyld" 3160 version_type=darwin 3161 need_lib_prefix=no 3162 need_version=no 3163 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' 3164 soname_spec='${libname}${release}${major}$shared_ext' 3165 shlibpath_overrides_runpath=yes 3166 shlibpath_var=DYLD_LIBRARY_PATH 3167 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 3168m4_if([$1], [],[ 3169 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 3170 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 3171 ;; 3172 3173dgux*) 3174 version_type=linux 3175 need_lib_prefix=no 3176 need_version=no 3177 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 3178 soname_spec='${libname}${release}${shared_ext}$major' 3179 shlibpath_var=LD_LIBRARY_PATH 3180 ;; 3181 3182freebsd1*) 3183 dynamic_linker=no 3184 ;; 3185 3186freebsd* | dragonfly*) 3187 # DragonFly does not have aout. When/if they implement a new 3188 # versioning mechanism, adjust this. 3189 if test -x /usr/bin/objformat; then 3190 objformat=`/usr/bin/objformat` 3191 else 3192 case $host_os in 3193 freebsd[[123]]*) objformat=aout ;; 3194 *) objformat=elf ;; 3195 esac 3196 fi 3197 version_type=freebsd-$objformat 3198 case $version_type in 3199 freebsd-elf*) 3200 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 3201 need_version=no 3202 need_lib_prefix=no 3203 ;; 3204 freebsd-*) 3205 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 3206 need_version=yes 3207 ;; 3208 esac 3209 shlibpath_var=LD_LIBRARY_PATH 3210 case $host_os in 3211 freebsd2*) 3212 shlibpath_overrides_runpath=yes 3213 ;; 3214 freebsd3.[[01]]* | freebsdelf3.[[01]]*) 3215 shlibpath_overrides_runpath=yes 3216 hardcode_into_libs=yes 3217 ;; 3218 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 3219 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 3220 shlibpath_overrides_runpath=no 3221 hardcode_into_libs=yes 3222 ;; 3223 *) # from 4.6 on, and DragonFly 3224 shlibpath_overrides_runpath=yes 3225 hardcode_into_libs=yes 3226 ;; 3227 esac 3228 ;; 3229 3230gnu*) 3231 version_type=linux 3232 need_lib_prefix=no 3233 need_version=no 3234 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 3235 soname_spec='${libname}${release}${shared_ext}$major' 3236 shlibpath_var=LD_LIBRARY_PATH 3237 hardcode_into_libs=yes 3238 ;; 3239 3240hpux9* | hpux10* | hpux11*) 3241 # Give a soname corresponding to the major version so that dld.sl refuses to 3242 # link against other versions. 3243 version_type=sunos 3244 need_lib_prefix=no 3245 need_version=no 3246 case $host_cpu in 3247 ia64*) 3248 shrext_cmds='.so' 3249 hardcode_into_libs=yes 3250 dynamic_linker="$host_os dld.so" 3251 shlibpath_var=LD_LIBRARY_PATH 3252 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 3253 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3254 soname_spec='${libname}${release}${shared_ext}$major' 3255 if test "X$HPUX_IA64_MODE" = X32; then 3256 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 3257 else 3258 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 3259 fi 3260 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 3261 ;; 3262 hppa*64*) 3263 shrext_cmds='.sl' 3264 hardcode_into_libs=yes 3265 dynamic_linker="$host_os dld.sl" 3266 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 3267 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 3268 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3269 soname_spec='${libname}${release}${shared_ext}$major' 3270 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 3271 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 3272 ;; 3273 *) 3274 shrext_cmds='.sl' 3275 dynamic_linker="$host_os dld.sl" 3276 shlibpath_var=SHLIB_PATH 3277 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 3278 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3279 soname_spec='${libname}${release}${shared_ext}$major' 3280 ;; 3281 esac 3282 # HP-UX runs *really* slowly unless shared libraries are mode 555. 3283 postinstall_cmds='chmod 555 $lib' 3284 ;; 3285 3286interix[[3-9]]*) 3287 version_type=linux 3288 need_lib_prefix=no 3289 need_version=no 3290 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 3291 soname_spec='${libname}${release}${shared_ext}$major' 3292 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 3293 shlibpath_var=LD_LIBRARY_PATH 3294 shlibpath_overrides_runpath=no 3295 hardcode_into_libs=yes 3296 ;; 3297 3298irix5* | irix6* | nonstopux*) 3299 case $host_os in 3300 nonstopux*) version_type=nonstopux ;; 3301 *) 3302 if test "$lt_cv_prog_gnu_ld" = yes; then 3303 version_type=linux 3304 else 3305 version_type=irix 3306 fi ;; 3307 esac 3308 need_lib_prefix=no 3309 need_version=no 3310 soname_spec='${libname}${release}${shared_ext}$major' 3311 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 3312 case $host_os in 3313 irix5* | nonstopux*) 3314 libsuff= shlibsuff= 3315 ;; 3316 *) 3317 case $LD in # libtool.m4 will add one of these switches to LD 3318 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 3319 libsuff= shlibsuff= libmagic=32-bit;; 3320 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 3321 libsuff=32 shlibsuff=N32 libmagic=N32;; 3322 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 3323 libsuff=64 shlibsuff=64 libmagic=64-bit;; 3324 *) libsuff= shlibsuff= libmagic=never-match;; 3325 esac 3326 ;; 3327 esac 3328 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 3329 shlibpath_overrides_runpath=no 3330 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 3331 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 3332 hardcode_into_libs=yes 3333 ;; 3334 3335# No shared lib support for Linux oldld, aout, or coff. 3336linux*oldld* | linux*aout* | linux*coff*) 3337 dynamic_linker=no 3338 ;; 3339 3340# This must be Linux ELF. 3341linux* | k*bsd*-gnu) 3342 version_type=linux 3343 need_lib_prefix=no 3344 need_version=no 3345 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3346 soname_spec='${libname}${release}${shared_ext}$major' 3347 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 3348 shlibpath_var=LD_LIBRARY_PATH 3349 shlibpath_overrides_runpath=no 3350 # Some binutils ld are patched to set DT_RUNPATH 3351 save_LDFLAGS=$LDFLAGS 3352 save_libdir=$libdir 3353 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 3354 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 3355 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 3356 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 3357 [shlibpath_overrides_runpath=yes])]) 3358 LDFLAGS=$save_LDFLAGS 3359 libdir=$save_libdir 3360 3361 # This implies no fast_install, which is unacceptable. 3362 # Some rework will be needed to allow for fast_install 3363 # before this can be enabled. 3364 hardcode_into_libs=yes 3365 3366 # Append ld.so.conf contents to the search path 3367 if test -f /etc/ld.so.conf; then 3368 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` 3369 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 3370 fi 3371 3372 # We used to test for /lib/ld.so.1 and disable shared libraries on 3373 # powerpc, because MkLinux only supported shared libraries with the 3374 # GNU dynamic linker. Since this was broken with cross compilers, 3375 # most powerpc-linux boxes support dynamic linking these days and 3376 # people can always --disable-shared, the test was removed, and we 3377 # assume the GNU/Linux dynamic linker is in use. 3378 dynamic_linker='GNU/Linux ld.so' 3379 ;; 3380 3381netbsdelf*-gnu) 3382 version_type=linux 3383 need_lib_prefix=no 3384 need_version=no 3385 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 3386 soname_spec='${libname}${release}${shared_ext}$major' 3387 shlibpath_var=LD_LIBRARY_PATH 3388 shlibpath_overrides_runpath=no 3389 hardcode_into_libs=yes 3390 dynamic_linker='NetBSD ld.elf_so' 3391 ;; 3392 3393netbsd*) 3394 version_type=sunos 3395 need_lib_prefix=no 3396 need_version=no 3397 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 3398 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 3399 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 3400 dynamic_linker='NetBSD (a.out) ld.so' 3401 else 3402 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 3403 soname_spec='${libname}${release}${shared_ext}$major' 3404 dynamic_linker='NetBSD ld.elf_so' 3405 fi 3406 shlibpath_var=LD_LIBRARY_PATH 3407 shlibpath_overrides_runpath=yes 3408 hardcode_into_libs=yes 3409 ;; 3410 3411newsos6) 3412 version_type=linux 3413 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3414 shlibpath_var=LD_LIBRARY_PATH 3415 shlibpath_overrides_runpath=yes 3416 ;; 3417 3418*nto* | *qnx*) 3419 version_type=qnx 3420 need_lib_prefix=no 3421 need_version=no 3422 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3423 soname_spec='${libname}${release}${shared_ext}$major' 3424 shlibpath_var=LD_LIBRARY_PATH 3425 shlibpath_overrides_runpath=no 3426 hardcode_into_libs=yes 3427 dynamic_linker='ldqnx.so' 3428 ;; 3429 3430openbsd*) 3431 version_type=sunos 3432 sys_lib_dlsearch_path_spec="/usr/lib" 3433 need_lib_prefix=no 3434 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 3435 case $host_os in 3436 openbsd3.3 | openbsd3.3.*) need_version=yes ;; 3437 *) need_version=no ;; 3438 esac 3439 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 3440 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 3441 shlibpath_var=LD_LIBRARY_PATH 3442 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 3443 case $host_os in 3444 openbsd2.[[89]] | openbsd2.[[89]].*) 3445 shlibpath_overrides_runpath=no 3446 ;; 3447 *) 3448 shlibpath_overrides_runpath=yes 3449 ;; 3450 esac 3451 else 3452 shlibpath_overrides_runpath=yes 3453 fi 3454 ;; 3455 3456os2*) 3457 libname_spec='$name' 3458 shrext_cmds=".dll" 3459 need_lib_prefix=no 3460 library_names_spec='$libname${shared_ext} $libname.a' 3461 dynamic_linker='OS/2 ld.exe' 3462 shlibpath_var=LIBPATH 3463 ;; 3464 3465osf3* | osf4* | osf5*) 3466 version_type=osf 3467 need_lib_prefix=no 3468 need_version=no 3469 soname_spec='${libname}${release}${shared_ext}$major' 3470 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3471 shlibpath_var=LD_LIBRARY_PATH 3472 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 3473 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 3474 ;; 3475 3476rdos*) 3477 dynamic_linker=no 3478 ;; 3479 3480solaris*) 3481 version_type=linux 3482 need_lib_prefix=no 3483 need_version=no 3484 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3485 soname_spec='${libname}${release}${shared_ext}$major' 3486 shlibpath_var=LD_LIBRARY_PATH 3487 shlibpath_overrides_runpath=yes 3488 hardcode_into_libs=yes 3489 # ldd complains unless libraries are executable 3490 postinstall_cmds='chmod +x $lib' 3491 ;; 3492 3493sunos4*) 3494 version_type=sunos 3495 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 3496 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 3497 shlibpath_var=LD_LIBRARY_PATH 3498 shlibpath_overrides_runpath=yes 3499 if test "$with_gnu_ld" = yes; then 3500 need_lib_prefix=no 3501 fi 3502 need_version=yes 3503 ;; 3504 3505sysv4 | sysv4.3*) 3506 version_type=linux 3507 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3508 soname_spec='${libname}${release}${shared_ext}$major' 3509 shlibpath_var=LD_LIBRARY_PATH 3510 case $host_vendor in 3511 sni) 3512 shlibpath_overrides_runpath=no 3513 need_lib_prefix=no 3514 runpath_var=LD_RUN_PATH 3515 ;; 3516 siemens) 3517 need_lib_prefix=no 3518 ;; 3519 motorola) 3520 need_lib_prefix=no 3521 need_version=no 3522 shlibpath_overrides_runpath=no 3523 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 3524 ;; 3525 esac 3526 ;; 3527 3528sysv4*MP*) 3529 if test -d /usr/nec ;then 3530 version_type=linux 3531 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 3532 soname_spec='$libname${shared_ext}.$major' 3533 shlibpath_var=LD_LIBRARY_PATH 3534 fi 3535 ;; 3536 3537sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 3538 version_type=freebsd-elf 3539 need_lib_prefix=no 3540 need_version=no 3541 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 3542 soname_spec='${libname}${release}${shared_ext}$major' 3543 shlibpath_var=LD_LIBRARY_PATH 3544 shlibpath_overrides_runpath=yes 3545 hardcode_into_libs=yes 3546 if test "$with_gnu_ld" = yes; then 3547 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 3548 else 3549 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 3550 case $host_os in 3551 sco3.2v5*) 3552 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 3553 ;; 3554 esac 3555 fi 3556 sys_lib_dlsearch_path_spec='/usr/lib' 3557 ;; 3558 3559tpf*) 3560 # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 3561 version_type=linux 3562 need_lib_prefix=no 3563 need_version=no 3564 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3565 shlibpath_var=LD_LIBRARY_PATH 3566 shlibpath_overrides_runpath=no 3567 hardcode_into_libs=yes 3568 ;; 3569 3570uts4*) 3571 version_type=linux 3572 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3573 soname_spec='${libname}${release}${shared_ext}$major' 3574 shlibpath_var=LD_LIBRARY_PATH 3575 ;; 3576 3577*) 3578 dynamic_linker=no 3579 ;; 3580esac 3581AC_MSG_RESULT([$dynamic_linker]) 3582test "$dynamic_linker" = no && can_build_shared=no 3583 3584variables_saved_for_relink="PATH $shlibpath_var $runpath_var" 3585if test "$GCC" = yes; then 3586 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 3587fi 3588 3589if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then 3590 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 3591fi 3592if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then 3593 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 3594fi 3595 3596_LT_DECL([], [variables_saved_for_relink], [1], 3597 [Variables whose values should be saved in libtool wrapper scripts and 3598 restored at link time]) 3599_LT_DECL([], [need_lib_prefix], [0], 3600 [Do we need the "lib" prefix for modules?]) 3601_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 3602_LT_DECL([], [version_type], [0], [Library versioning type]) 3603_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 3604_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 3605_LT_DECL([], [shlibpath_overrides_runpath], [0], 3606 [Is shlibpath searched before the hard-coded library search path?]) 3607_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 3608_LT_DECL([], [library_names_spec], [1], 3609 [[List of archive names. First name is the real one, the rest are links. 3610 The last name is the one that the linker finds with -lNAME]]) 3611_LT_DECL([], [soname_spec], [1], 3612 [[The coded name of the library, if different from the real name]]) 3613_LT_DECL([], [postinstall_cmds], [2], 3614 [Command to use after installation of a shared archive]) 3615_LT_DECL([], [postuninstall_cmds], [2], 3616 [Command to use after uninstallation of a shared archive]) 3617_LT_DECL([], [finish_cmds], [2], 3618 [Commands used to finish a libtool library installation in a directory]) 3619_LT_DECL([], [finish_eval], [1], 3620 [[As "finish_cmds", except a single script fragment to be evaled but 3621 not shown]]) 3622_LT_DECL([], [hardcode_into_libs], [0], 3623 [Whether we should hardcode library paths into libraries]) 3624_LT_DECL([], [sys_lib_search_path_spec], [2], 3625 [Compile-time system search path for libraries]) 3626_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], 3627 [Run-time system search path for libraries]) 3628])# _LT_SYS_DYNAMIC_LINKER 3629 3630 3631# _LT_PATH_TOOL_PREFIX(TOOL) 3632# -------------------------- 3633# find a file program which can recognize shared library 3634AC_DEFUN([_LT_PATH_TOOL_PREFIX], 3635[m4_require([_LT_DECL_EGREP])dnl 3636AC_MSG_CHECKING([for $1]) 3637AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 3638[case $MAGIC_CMD in 3639[[\\/*] | ?:[\\/]*]) 3640 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 3641 ;; 3642*) 3643 lt_save_MAGIC_CMD="$MAGIC_CMD" 3644 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 3645dnl $ac_dummy forces splitting on constant user-supplied paths. 3646dnl POSIX.2 word splitting is done only on the output of word expansions, 3647dnl not every word. This closes a longstanding sh security hole. 3648 ac_dummy="m4_if([$2], , $PATH, [$2])" 3649 for ac_dir in $ac_dummy; do 3650 IFS="$lt_save_ifs" 3651 test -z "$ac_dir" && ac_dir=. 3652 if test -f $ac_dir/$1; then 3653 lt_cv_path_MAGIC_CMD="$ac_dir/$1" 3654 if test -n "$file_magic_test_file"; then 3655 case $deplibs_check_method in 3656 "file_magic "*) 3657 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 3658 MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 3659 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 3660 $EGREP "$file_magic_regex" > /dev/null; then 3661 : 3662 else 3663 cat <<_LT_EOF 1>&2 3664 3665*** Warning: the command libtool uses to detect shared libraries, 3666*** $file_magic_cmd, produces output that libtool cannot recognize. 3667*** The result is that libtool may fail to recognize shared libraries 3668*** as such. This will affect the creation of libtool libraries that 3669*** depend on shared libraries, but programs linked with such libtool 3670*** libraries will work regardless of this problem. Nevertheless, you 3671*** may want to report the problem to your system manager and/or to 3672*** bug-libtool@gnu.org 3673 3674_LT_EOF 3675 fi ;; 3676 esac 3677 fi 3678 break 3679 fi 3680 done 3681 IFS="$lt_save_ifs" 3682 MAGIC_CMD="$lt_save_MAGIC_CMD" 3683 ;; 3684esac]) 3685MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 3686if test -n "$MAGIC_CMD"; then 3687 AC_MSG_RESULT($MAGIC_CMD) 3688else 3689 AC_MSG_RESULT(no) 3690fi 3691_LT_DECL([], [MAGIC_CMD], [0], 3692 [Used to examine libraries when file_magic_cmd begins with "file"])dnl 3693])# _LT_PATH_TOOL_PREFIX 3694 3695# Old name: 3696AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 3697dnl aclocal-1.4 backwards compatibility: 3698dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 3699 3700 3701# _LT_PATH_MAGIC 3702# -------------- 3703# find a file program which can recognize a shared library 3704m4_defun([_LT_PATH_MAGIC], 3705[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 3706if test -z "$lt_cv_path_MAGIC_CMD"; then 3707 if test -n "$ac_tool_prefix"; then 3708 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 3709 else 3710 MAGIC_CMD=: 3711 fi 3712fi 3713])# _LT_PATH_MAGIC 3714 3715 3716# LT_PATH_LD 3717# ---------- 3718# find the pathname to the GNU or non-GNU linker 3719AC_DEFUN([LT_PATH_LD], 3720[AC_REQUIRE([AC_PROG_CC])dnl 3721AC_REQUIRE([AC_CANONICAL_HOST])dnl 3722AC_REQUIRE([AC_CANONICAL_BUILD])dnl 3723m4_require([_LT_DECL_SED])dnl 3724m4_require([_LT_DECL_EGREP])dnl 3725 3726AC_ARG_WITH([gnu-ld], 3727 [AS_HELP_STRING([--with-gnu-ld], 3728 [assume the C compiler uses GNU ld @<:@default=no@:>@])], 3729 [test "$withval" = no || with_gnu_ld=yes], 3730 [with_gnu_ld=no])dnl 3731 3732ac_prog=ld 3733if test "$GCC" = yes; then 3734 # Check if gcc -print-prog-name=ld gives a path. 3735 AC_MSG_CHECKING([for ld used by $CC]) 3736 case $host in 3737 *-*-mingw*) 3738 # gcc leaves a trailing carriage return which upsets mingw 3739 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 3740 *) 3741 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 3742 esac 3743 case $ac_prog in 3744 # Accept absolute paths. 3745 [[\\/]]* | ?:[[\\/]]*) 3746 re_direlt='/[[^/]][[^/]]*/\.\./' 3747 # Canonicalize the pathname of ld 3748 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 3749 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 3750 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 3751 done 3752 test -z "$LD" && LD="$ac_prog" 3753 ;; 3754 "") 3755 # If it fails, then pretend we aren't using GCC. 3756 ac_prog=ld 3757 ;; 3758 *) 3759 # If it is relative, then search for the first ld in PATH. 3760 with_gnu_ld=unknown 3761 ;; 3762 esac 3763elif test "$with_gnu_ld" = yes; then 3764 AC_MSG_CHECKING([for GNU ld]) 3765else 3766 AC_MSG_CHECKING([for non-GNU ld]) 3767fi 3768AC_CACHE_VAL(lt_cv_path_LD, 3769[if test -z "$LD"; then 3770 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 3771 for ac_dir in $PATH; do 3772 IFS="$lt_save_ifs" 3773 test -z "$ac_dir" && ac_dir=. 3774 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 3775 lt_cv_path_LD="$ac_dir/$ac_prog" 3776 # Check to see if the program is GNU ld. I'd rather use --version, 3777 # but apparently some variants of GNU ld only accept -v. 3778 # Break only if it was the GNU/non-GNU ld that we prefer. 3779 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 3780 *GNU* | *'with BFD'*) 3781 test "$with_gnu_ld" != no && break 3782 ;; 3783 *) 3784 test "$with_gnu_ld" != yes && break 3785 ;; 3786 esac 3787 fi 3788 done 3789 IFS="$lt_save_ifs" 3790else 3791 lt_cv_path_LD="$LD" # Let the user override the test with a path. 3792fi]) 3793LD="$lt_cv_path_LD" 3794if test -n "$LD"; then 3795 AC_MSG_RESULT($LD) 3796else 3797 AC_MSG_RESULT(no) 3798fi 3799test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 3800_LT_PATH_LD_GNU 3801AC_SUBST([LD]) 3802 3803_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 3804])# LT_PATH_LD 3805 3806# Old names: 3807AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 3808AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 3809dnl aclocal-1.4 backwards compatibility: 3810dnl AC_DEFUN([AM_PROG_LD], []) 3811dnl AC_DEFUN([AC_PROG_LD], []) 3812 3813 3814# _LT_PATH_LD_GNU 3815#- -------------- 3816m4_defun([_LT_PATH_LD_GNU], 3817[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 3818[# I'd rather use --version here, but apparently some GNU lds only accept -v. 3819case `$LD -v 2>&1 </dev/null` in 3820*GNU* | *'with BFD'*) 3821 lt_cv_prog_gnu_ld=yes 3822 ;; 3823*) 3824 lt_cv_prog_gnu_ld=no 3825 ;; 3826esac]) 3827with_gnu_ld=$lt_cv_prog_gnu_ld 3828])# _LT_PATH_LD_GNU 3829 3830 3831# _LT_CMD_RELOAD 3832# -------------- 3833# find reload flag for linker 3834# -- PORTME Some linkers may need a different reload flag. 3835m4_defun([_LT_CMD_RELOAD], 3836[AC_CACHE_CHECK([for $LD option to reload object files], 3837 lt_cv_ld_reload_flag, 3838 [lt_cv_ld_reload_flag='-r']) 3839reload_flag=$lt_cv_ld_reload_flag 3840case $reload_flag in 3841"" | " "*) ;; 3842*) reload_flag=" $reload_flag" ;; 3843esac 3844reload_cmds='$LD$reload_flag -o $output$reload_objs' 3845case $host_os in 3846 darwin*) 3847 if test "$GCC" = yes; then 3848 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 3849 else 3850 reload_cmds='$LD$reload_flag -o $output$reload_objs' 3851 fi 3852 ;; 3853esac 3854_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl 3855_LT_DECL([], [reload_cmds], [2])dnl 3856])# _LT_CMD_RELOAD 3857 3858 3859# _LT_CHECK_MAGIC_METHOD 3860# ---------------------- 3861# how to check for library dependencies 3862# -- PORTME fill in with the dynamic library characteristics 3863m4_defun([_LT_CHECK_MAGIC_METHOD], 3864[m4_require([_LT_DECL_EGREP]) 3865m4_require([_LT_DECL_OBJDUMP]) 3866AC_CACHE_CHECK([how to recognize dependent libraries], 3867lt_cv_deplibs_check_method, 3868[lt_cv_file_magic_cmd='$MAGIC_CMD' 3869lt_cv_file_magic_test_file= 3870lt_cv_deplibs_check_method='unknown' 3871# Need to set the preceding variable on all platforms that support 3872# interlibrary dependencies. 3873# 'none' -- dependencies not supported. 3874# `unknown' -- same as none, but documents that we really don't know. 3875# 'pass_all' -- all dependencies passed with no checks. 3876# 'test_compile' -- check by making test program. 3877# 'file_magic [[regex]]' -- check by looking for files in library path 3878# which responds to the $file_magic_cmd with a given extended regex. 3879# If you have `file' or equivalent on your system and you're not sure 3880# whether `pass_all' will *always* work, you probably want this one. 3881 3882case $host_os in 3883aix[[4-9]]*) 3884 lt_cv_deplibs_check_method=pass_all 3885 ;; 3886 3887beos*) 3888 lt_cv_deplibs_check_method=pass_all 3889 ;; 3890 3891bsdi[[45]]*) 3892 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 3893 lt_cv_file_magic_cmd='/usr/bin/file -L' 3894 lt_cv_file_magic_test_file=/shlib/libc.so 3895 ;; 3896 3897cygwin*) 3898 # func_win32_libid is a shell function defined in ltmain.sh 3899 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 3900 lt_cv_file_magic_cmd='func_win32_libid' 3901 ;; 3902 3903mingw* | pw32*) 3904 # Base MSYS/MinGW do not provide the 'file' command needed by 3905 # func_win32_libid shell function, so use a weaker test based on 'objdump', 3906 # unless we find 'file', for example because we are cross-compiling. 3907 if ( file / ) >/dev/null 2>&1; then 3908 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 3909 lt_cv_file_magic_cmd='func_win32_libid' 3910 else 3911 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' 3912 lt_cv_file_magic_cmd='$OBJDUMP -f' 3913 fi 3914 ;; 3915 3916cegcc) 3917 # use the weaker test based on 'objdump'. See mingw*. 3918 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 3919 lt_cv_file_magic_cmd='$OBJDUMP -f' 3920 ;; 3921 3922darwin* | rhapsody*) 3923 lt_cv_deplibs_check_method=pass_all 3924 ;; 3925 3926freebsd* | dragonfly*) 3927 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 3928 case $host_cpu in 3929 i*86 ) 3930 # Not sure whether the presence of OpenBSD here was a mistake. 3931 # Let's accept both of them until this is cleared up. 3932 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 3933 lt_cv_file_magic_cmd=/usr/bin/file 3934 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 3935 ;; 3936 esac 3937 else 3938 lt_cv_deplibs_check_method=pass_all 3939 fi 3940 ;; 3941 3942gnu*) 3943 lt_cv_deplibs_check_method=pass_all 3944 ;; 3945 3946hpux10.20* | hpux11*) 3947 lt_cv_file_magic_cmd=/usr/bin/file 3948 case $host_cpu in 3949 ia64*) 3950 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 3951 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 3952 ;; 3953 hppa*64*) 3954 [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]'] 3955 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 3956 ;; 3957 *) 3958 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' 3959 lt_cv_file_magic_test_file=/usr/lib/libc.sl 3960 ;; 3961 esac 3962 ;; 3963 3964interix[[3-9]]*) 3965 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 3966 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 3967 ;; 3968 3969irix5* | irix6* | nonstopux*) 3970 case $LD in 3971 *-32|*"-32 ") libmagic=32-bit;; 3972 *-n32|*"-n32 ") libmagic=N32;; 3973 *-64|*"-64 ") libmagic=64-bit;; 3974 *) libmagic=never-match;; 3975 esac 3976 lt_cv_deplibs_check_method=pass_all 3977 ;; 3978 3979# This must be Linux ELF. 3980linux* | k*bsd*-gnu) 3981 lt_cv_deplibs_check_method=pass_all 3982 ;; 3983 3984netbsd* | netbsdelf*-gnu) 3985 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 3986 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 3987 else 3988 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 3989 fi 3990 ;; 3991 3992newos6*) 3993 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 3994 lt_cv_file_magic_cmd=/usr/bin/file 3995 lt_cv_file_magic_test_file=/usr/lib/libnls.so 3996 ;; 3997 3998*nto* | *qnx*) 3999 lt_cv_deplibs_check_method=pass_all 4000 ;; 4001 4002openbsd*) 4003 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 4004 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 4005 else 4006 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 4007 fi 4008 ;; 4009 4010osf3* | osf4* | osf5*) 4011 lt_cv_deplibs_check_method=pass_all 4012 ;; 4013 4014rdos*) 4015 lt_cv_deplibs_check_method=pass_all 4016 ;; 4017 4018solaris*) 4019 lt_cv_deplibs_check_method=pass_all 4020 ;; 4021 4022sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 4023 lt_cv_deplibs_check_method=pass_all 4024 ;; 4025 4026sysv4 | sysv4.3*) 4027 case $host_vendor in 4028 motorola) 4029 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]]' 4030 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 4031 ;; 4032 ncr) 4033 lt_cv_deplibs_check_method=pass_all 4034 ;; 4035 sequent) 4036 lt_cv_file_magic_cmd='/bin/file' 4037 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 4038 ;; 4039 sni) 4040 lt_cv_file_magic_cmd='/bin/file' 4041 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 4042 lt_cv_file_magic_test_file=/lib/libc.so 4043 ;; 4044 siemens) 4045 lt_cv_deplibs_check_method=pass_all 4046 ;; 4047 pc) 4048 lt_cv_deplibs_check_method=pass_all 4049 ;; 4050 esac 4051 ;; 4052 4053tpf*) 4054 lt_cv_deplibs_check_method=pass_all 4055 ;; 4056esac 4057]) 4058file_magic_cmd=$lt_cv_file_magic_cmd 4059deplibs_check_method=$lt_cv_deplibs_check_method 4060test -z "$deplibs_check_method" && deplibs_check_method=unknown 4061 4062_LT_DECL([], [deplibs_check_method], [1], 4063 [Method to check whether dependent libraries are shared objects]) 4064_LT_DECL([], [file_magic_cmd], [1], 4065 [Command to use when deplibs_check_method == "file_magic"]) 4066])# _LT_CHECK_MAGIC_METHOD 4067 4068 4069# LT_PATH_NM 4070# ---------- 4071# find the pathname to a BSD- or MS-compatible name lister 4072AC_DEFUN([LT_PATH_NM], 4073[AC_REQUIRE([AC_PROG_CC])dnl 4074AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 4075[if test -n "$NM"; then 4076 # Let the user override the test. 4077 lt_cv_path_NM="$NM" 4078else 4079 lt_nm_to_check="${ac_tool_prefix}nm" 4080 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 4081 lt_nm_to_check="$lt_nm_to_check nm" 4082 fi 4083 for lt_tmp_nm in $lt_nm_to_check; do 4084 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 4085 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 4086 IFS="$lt_save_ifs" 4087 test -z "$ac_dir" && ac_dir=. 4088 tmp_nm="$ac_dir/$lt_tmp_nm" 4089 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 4090 # Check to see if the nm accepts a BSD-compat flag. 4091 # Adding the `sed 1q' prevents false positives on HP-UX, which says: 4092 # nm: unknown option "B" ignored 4093 # Tru64's nm complains that /dev/null is an invalid object file 4094 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 4095 */dev/null* | *'Invalid file or object type'*) 4096 lt_cv_path_NM="$tmp_nm -B" 4097 break 4098 ;; 4099 *) 4100 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 4101 */dev/null*) 4102 lt_cv_path_NM="$tmp_nm -p" 4103 break 4104 ;; 4105 *) 4106 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 4107 continue # so that we can try to find one that supports BSD flags 4108 ;; 4109 esac 4110 ;; 4111 esac 4112 fi 4113 done 4114 IFS="$lt_save_ifs" 4115 done 4116 : ${lt_cv_path_NM=no} 4117fi]) 4118if test "$lt_cv_path_NM" != "no"; then 4119 NM="$lt_cv_path_NM" 4120else 4121 # Didn't find any BSD compatible name lister, look for dumpbin. 4122 AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :) 4123 AC_SUBST([DUMPBIN]) 4124 if test "$DUMPBIN" != ":"; then 4125 NM="$DUMPBIN" 4126 fi 4127fi 4128test -z "$NM" && NM=nm 4129AC_SUBST([NM]) 4130_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 4131 4132AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 4133 [lt_cv_nm_interface="BSD nm" 4134 echo "int some_variable = 0;" > conftest.$ac_ext 4135 (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 4136 (eval "$ac_compile" 2>conftest.err) 4137 cat conftest.err >&AS_MESSAGE_LOG_FD 4138 (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 4139 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 4140 cat conftest.err >&AS_MESSAGE_LOG_FD 4141 (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD) 4142 cat conftest.out >&AS_MESSAGE_LOG_FD 4143 if $GREP 'External.*some_variable' conftest.out > /dev/null; then 4144 lt_cv_nm_interface="MS dumpbin" 4145 fi 4146 rm -f conftest*]) 4147])# LT_PATH_NM 4148 4149# Old names: 4150AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 4151AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 4152dnl aclocal-1.4 backwards compatibility: 4153dnl AC_DEFUN([AM_PROG_NM], []) 4154dnl AC_DEFUN([AC_PROG_NM], []) 4155 4156 4157# LT_LIB_M 4158# -------- 4159# check for math library 4160AC_DEFUN([LT_LIB_M], 4161[AC_REQUIRE([AC_CANONICAL_HOST])dnl 4162LIBM= 4163case $host in 4164*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) 4165 # These system don't have libm, or don't need it 4166 ;; 4167*-ncr-sysv4.3*) 4168 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 4169 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 4170 ;; 4171*) 4172 AC_CHECK_LIB(m, cos, LIBM="-lm") 4173 ;; 4174esac 4175AC_SUBST([LIBM]) 4176])# LT_LIB_M 4177 4178# Old name: 4179AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 4180dnl aclocal-1.4 backwards compatibility: 4181dnl AC_DEFUN([AC_CHECK_LIBM], []) 4182 4183 4184# _LT_COMPILER_NO_RTTI([TAGNAME]) 4185# ------------------------------- 4186m4_defun([_LT_COMPILER_NO_RTTI], 4187[m4_require([_LT_TAG_COMPILER])dnl 4188 4189_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 4190 4191if test "$GCC" = yes; then 4192 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 4193 4194 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 4195 lt_cv_prog_compiler_rtti_exceptions, 4196 [-fno-rtti -fno-exceptions], [], 4197 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 4198fi 4199_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 4200 [Compiler flag to turn off builtin functions]) 4201])# _LT_COMPILER_NO_RTTI 4202 4203 4204# _LT_CMD_GLOBAL_SYMBOLS 4205# ---------------------- 4206m4_defun([_LT_CMD_GLOBAL_SYMBOLS], 4207[AC_REQUIRE([AC_CANONICAL_HOST])dnl 4208AC_REQUIRE([AC_PROG_CC])dnl 4209AC_REQUIRE([LT_PATH_NM])dnl 4210AC_REQUIRE([LT_PATH_LD])dnl 4211m4_require([_LT_DECL_SED])dnl 4212m4_require([_LT_DECL_EGREP])dnl 4213m4_require([_LT_TAG_COMPILER])dnl 4214 4215# Check for command to grab the raw symbol name followed by C symbol from nm. 4216AC_MSG_CHECKING([command to parse $NM output from $compiler object]) 4217AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 4218[ 4219# These are sane defaults that work on at least a few old systems. 4220# [They come from Ultrix. What could be older than Ultrix?!! ;)] 4221 4222# Character class describing NM global symbol codes. 4223symcode='[[BCDEGRST]]' 4224 4225# Regexp to match symbols that can be accessed directly from C. 4226sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 4227 4228# Define system-specific variables. 4229case $host_os in 4230aix*) 4231 symcode='[[BCDT]]' 4232 ;; 4233cygwin* | mingw* | pw32* | cegcc*) 4234 symcode='[[ABCDGISTW]]' 4235 ;; 4236hpux*) 4237 if test "$host_cpu" = ia64; then 4238 symcode='[[ABCDEGRST]]' 4239 fi 4240 ;; 4241irix* | nonstopux*) 4242 symcode='[[BCDEGRST]]' 4243 ;; 4244osf*) 4245 symcode='[[BCDEGQRST]]' 4246 ;; 4247solaris*) 4248 symcode='[[BDRT]]' 4249 ;; 4250sco3.2v5*) 4251 symcode='[[DT]]' 4252 ;; 4253sysv4.2uw2*) 4254 symcode='[[DT]]' 4255 ;; 4256sysv5* | sco5v6* | unixware* | OpenUNIX*) 4257 symcode='[[ABDT]]' 4258 ;; 4259sysv4) 4260 symcode='[[DFNSTU]]' 4261 ;; 4262esac 4263 4264# If we're using GNU nm, then use its standard symbol codes. 4265case `$NM -V 2>&1` in 4266*GNU* | *'with BFD'*) 4267 symcode='[[ABCDGIRSTW]]' ;; 4268esac 4269 4270# Transform an extracted symbol line into a proper C declaration. 4271# Some systems (esp. on ia64) link data and code symbols differently, 4272# so use this general approach. 4273lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 4274 4275# Transform an extracted symbol line into symbol name and symbol address 4276lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" 4277lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" 4278 4279# Handle CRLF in mingw tool chain 4280opt_cr= 4281case $build_os in 4282mingw*) 4283 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 4284 ;; 4285esac 4286 4287# Try without a prefix underscore, then with it. 4288for ac_symprfx in "" "_"; do 4289 4290 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 4291 symxfrm="\\1 $ac_symprfx\\2 \\2" 4292 4293 # Write the raw and C identifiers. 4294 if test "$lt_cv_nm_interface" = "MS dumpbin"; then 4295 # Fake it for dumpbin and say T for any non-static function 4296 # and D for any global variable. 4297 # Also find C++ and __fastcall symbols from MSVC++, 4298 # which start with @ or ?. 4299 lt_cv_sys_global_symbol_pipe="$AWK ['"\ 4300" {last_section=section; section=\$ 3};"\ 4301" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 4302" \$ 0!~/External *\|/{next};"\ 4303" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 4304" {if(hide[section]) next};"\ 4305" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ 4306" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ 4307" s[1]~/^[@?]/{print s[1], s[1]; next};"\ 4308" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ 4309" ' prfx=^$ac_symprfx]" 4310 else 4311 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 4312 fi 4313 4314 # Check to see that the pipe works correctly. 4315 pipe_works=no 4316 4317 rm -f conftest* 4318 cat > conftest.$ac_ext <<_LT_EOF 4319#ifdef __cplusplus 4320extern "C" { 4321#endif 4322char nm_test_var; 4323void nm_test_func(void); 4324void nm_test_func(void){} 4325#ifdef __cplusplus 4326} 4327#endif 4328int main(){nm_test_var='a';nm_test_func();return(0);} 4329_LT_EOF 4330 4331 if AC_TRY_EVAL(ac_compile); then 4332 # Now try to grab the symbols. 4333 nlist=conftest.nm 4334 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then 4335 # Try sorting and uniquifying the output. 4336 if sort "$nlist" | uniq > "$nlist"T; then 4337 mv -f "$nlist"T "$nlist" 4338 else 4339 rm -f "$nlist"T 4340 fi 4341 4342 # Make sure that we snagged all the symbols we need. 4343 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 4344 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 4345 cat <<_LT_EOF > conftest.$ac_ext 4346#ifdef __cplusplus 4347extern "C" { 4348#endif 4349 4350_LT_EOF 4351 # Now generate the symbol file. 4352 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 4353 4354 cat <<_LT_EOF >> conftest.$ac_ext 4355 4356/* The mapping between symbol names and symbols. */ 4357const struct { 4358 const char *name; 4359 void *address; 4360} 4361lt__PROGRAM__LTX_preloaded_symbols[[]] = 4362{ 4363 { "@PROGRAM@", (void *) 0 }, 4364_LT_EOF 4365 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 4366 cat <<\_LT_EOF >> conftest.$ac_ext 4367 {0, (void *) 0} 4368}; 4369 4370/* This works around a problem in FreeBSD linker */ 4371#ifdef FREEBSD_WORKAROUND 4372static const void *lt_preloaded_setup() { 4373 return lt__PROGRAM__LTX_preloaded_symbols; 4374} 4375#endif 4376 4377#ifdef __cplusplus 4378} 4379#endif 4380_LT_EOF 4381 # Now try linking the two files. 4382 mv conftest.$ac_objext conftstm.$ac_objext 4383 lt_save_LIBS="$LIBS" 4384 lt_save_CFLAGS="$CFLAGS" 4385 LIBS="conftstm.$ac_objext" 4386 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 4387 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 4388 pipe_works=yes 4389 fi 4390 LIBS="$lt_save_LIBS" 4391 CFLAGS="$lt_save_CFLAGS" 4392 else 4393 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 4394 fi 4395 else 4396 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 4397 fi 4398 else 4399 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 4400 fi 4401 else 4402 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 4403 cat conftest.$ac_ext >&5 4404 fi 4405 rm -rf conftest* conftst* 4406 4407 # Do not use the global_symbol_pipe unless it works. 4408 if test "$pipe_works" = yes; then 4409 break 4410 else 4411 lt_cv_sys_global_symbol_pipe= 4412 fi 4413done 4414]) 4415if test -z "$lt_cv_sys_global_symbol_pipe"; then 4416 lt_cv_sys_global_symbol_to_cdecl= 4417fi 4418if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 4419 AC_MSG_RESULT(failed) 4420else 4421 AC_MSG_RESULT(ok) 4422fi 4423 4424_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 4425 [Take the output of nm and produce a listing of raw symbols and C names]) 4426_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 4427 [Transform the output of nm in a proper C declaration]) 4428_LT_DECL([global_symbol_to_c_name_address], 4429 [lt_cv_sys_global_symbol_to_c_name_address], [1], 4430 [Transform the output of nm in a C name address pair]) 4431_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 4432 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 4433 [Transform the output of nm in a C name address pair when lib prefix is needed]) 4434]) # _LT_CMD_GLOBAL_SYMBOLS 4435 4436 4437# _LT_COMPILER_PIC([TAGNAME]) 4438# --------------------------- 4439m4_defun([_LT_COMPILER_PIC], 4440[m4_require([_LT_TAG_COMPILER])dnl 4441_LT_TAGVAR(lt_prog_compiler_wl, $1)= 4442_LT_TAGVAR(lt_prog_compiler_pic, $1)= 4443_LT_TAGVAR(lt_prog_compiler_static, $1)= 4444 4445AC_MSG_CHECKING([for $compiler option to produce PIC]) 4446m4_if([$1], [CXX], [ 4447 # C++ specific cases for pic, static, wl, etc. 4448 if test "$GXX" = yes; then 4449 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4450 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4451 4452 case $host_os in 4453 aix*) 4454 # All AIX code is PIC. 4455 if test "$host_cpu" = ia64; then 4456 # AIX 5 now supports IA64 processor 4457 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4458 fi 4459 ;; 4460 4461 amigaos*) 4462 case $host_cpu in 4463 powerpc) 4464 # see comment about AmigaOS4 .so support 4465 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4466 ;; 4467 m68k) 4468 # FIXME: we need at least 68020 code to build shared libraries, but 4469 # adding the `-m68020' flag to GCC prevents building anything better, 4470 # like `-m68040'. 4471 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 4472 ;; 4473 esac 4474 ;; 4475 4476 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 4477 # PIC is the default for these OSes. 4478 ;; 4479 mingw* | cygwin* | os2* | pw32* | cegcc*) 4480 # This hack is so that the source file can tell whether it is being 4481 # built for inclusion in a dll (and should export symbols for example). 4482 # Although the cygwin gcc ignores -fPIC, still need this for old-style 4483 # (--disable-auto-import) libraries 4484 m4_if([$1], [GCJ], [], 4485 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 4486 ;; 4487 darwin* | rhapsody*) 4488 # PIC is the default on this platform 4489 # Common symbols not allowed in MH_DYLIB files 4490 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 4491 ;; 4492 *djgpp*) 4493 # DJGPP does not support shared libraries at all 4494 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4495 ;; 4496 interix[[3-9]]*) 4497 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 4498 # Instead, we relocate shared libraries at runtime. 4499 ;; 4500 sysv4*MP*) 4501 if test -d /usr/nec; then 4502 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 4503 fi 4504 ;; 4505 hpux*) 4506 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 4507 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 4508 # sets the default TLS model and affects inlining. 4509 case $host_cpu in 4510 hppa*64*) 4511 ;; 4512 *) 4513 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4514 ;; 4515 esac 4516 ;; 4517 *qnx* | *nto*) 4518 # QNX uses GNU C++, but need to define -shared option too, otherwise 4519 # it will coredump. 4520 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4521 ;; 4522 *) 4523 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4524 ;; 4525 esac 4526 else 4527 case $host_os in 4528 aix[[4-9]]*) 4529 # All AIX code is PIC. 4530 if test "$host_cpu" = ia64; then 4531 # AIX 5 now supports IA64 processor 4532 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4533 else 4534 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 4535 fi 4536 ;; 4537 chorus*) 4538 case $cc_basename in 4539 cxch68*) 4540 # Green Hills C++ Compiler 4541 # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" 4542 ;; 4543 esac 4544 ;; 4545 dgux*) 4546 case $cc_basename in 4547 ec++*) 4548 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4549 ;; 4550 ghcx*) 4551 # Green Hills C++ Compiler 4552 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4553 ;; 4554 *) 4555 ;; 4556 esac 4557 ;; 4558 freebsd* | dragonfly*) 4559 # FreeBSD uses GNU C++ 4560 ;; 4561 hpux9* | hpux10* | hpux11*) 4562 case $cc_basename in 4563 CC*) 4564 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4565 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 4566 if test "$host_cpu" != ia64; then 4567 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4568 fi 4569 ;; 4570 aCC*) 4571 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4572 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 4573 case $host_cpu in 4574 hppa*64*|ia64*) 4575 # +Z the default 4576 ;; 4577 *) 4578 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4579 ;; 4580 esac 4581 ;; 4582 *) 4583 ;; 4584 esac 4585 ;; 4586 interix*) 4587 # This is c89, which is MS Visual C++ (no shared libs) 4588 # Anyone wants to do a port? 4589 ;; 4590 irix5* | irix6* | nonstopux*) 4591 case $cc_basename in 4592 CC*) 4593 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4594 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4595 # CC pic flag -KPIC is the default. 4596 ;; 4597 *) 4598 ;; 4599 esac 4600 ;; 4601 linux* | k*bsd*-gnu) 4602 case $cc_basename in 4603 KCC*) 4604 # KAI C++ Compiler 4605 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 4606 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4607 ;; 4608 ecpc* ) 4609 # old Intel C++ for x86_64 which still supported -KPIC. 4610 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4611 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4612 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4613 ;; 4614 icpc* ) 4615 # Intel C++, used to be incompatible with GCC. 4616 # ICC 10 doesn't accept -KPIC any more. 4617 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4618 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4619 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4620 ;; 4621 pgCC* | pgcpp*) 4622 # Portland Group C++ compiler 4623 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4624 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 4625 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4626 ;; 4627 cxx*) 4628 # Compaq C++ 4629 # Make sure the PIC flag is empty. It appears that all Alpha 4630 # Linux and Compaq Tru64 Unix objects are PIC. 4631 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4632 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4633 ;; 4634 xlc* | xlC*) 4635 # IBM XL 8.0 on PPC 4636 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4637 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 4638 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 4639 ;; 4640 *) 4641 case `$CC -V 2>&1 | sed 5q` in 4642 *Sun\ C*) 4643 # Sun C++ 5.9 4644 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4645 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4646 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4647 ;; 4648 esac 4649 ;; 4650 esac 4651 ;; 4652 lynxos*) 4653 ;; 4654 m88k*) 4655 ;; 4656 mvs*) 4657 case $cc_basename in 4658 cxx*) 4659 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 4660 ;; 4661 *) 4662 ;; 4663 esac 4664 ;; 4665 netbsd* | netbsdelf*-gnu) 4666 ;; 4667 *qnx* | *nto*) 4668 # QNX uses GNU C++, but need to define -shared option too, otherwise 4669 # it will coredump. 4670 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4671 ;; 4672 osf3* | osf4* | osf5*) 4673 case $cc_basename in 4674 KCC*) 4675 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 4676 ;; 4677 RCC*) 4678 # Rational C++ 2.4.1 4679 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4680 ;; 4681 cxx*) 4682 # Digital/Compaq C++ 4683 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4684 # Make sure the PIC flag is empty. It appears that all Alpha 4685 # Linux and Compaq Tru64 Unix objects are PIC. 4686 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4687 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4688 ;; 4689 *) 4690 ;; 4691 esac 4692 ;; 4693 psos*) 4694 ;; 4695 solaris*) 4696 case $cc_basename in 4697 CC*) 4698 # Sun C++ 4.2, 5.x and Centerline C++ 4699 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4700 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4701 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4702 ;; 4703 gcx*) 4704 # Green Hills C++ Compiler 4705 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4706 ;; 4707 *) 4708 ;; 4709 esac 4710 ;; 4711 sunos4*) 4712 case $cc_basename in 4713 CC*) 4714 # Sun C++ 4.x 4715 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4716 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4717 ;; 4718 lcc*) 4719 # Lucid 4720 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4721 ;; 4722 *) 4723 ;; 4724 esac 4725 ;; 4726 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 4727 case $cc_basename in 4728 CC*) 4729 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4730 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4731 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4732 ;; 4733 esac 4734 ;; 4735 tandem*) 4736 case $cc_basename in 4737 NCC*) 4738 # NonStop-UX NCC 3.20 4739 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4740 ;; 4741 *) 4742 ;; 4743 esac 4744 ;; 4745 vxworks*) 4746 ;; 4747 *) 4748 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4749 ;; 4750 esac 4751 fi 4752], 4753[ 4754 if test "$GCC" = yes; then 4755 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4756 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4757 4758 case $host_os in 4759 aix*) 4760 # All AIX code is PIC. 4761 if test "$host_cpu" = ia64; then 4762 # AIX 5 now supports IA64 processor 4763 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4764 fi 4765 ;; 4766 4767 amigaos*) 4768 case $host_cpu in 4769 powerpc) 4770 # see comment about AmigaOS4 .so support 4771 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4772 ;; 4773 m68k) 4774 # FIXME: we need at least 68020 code to build shared libraries, but 4775 # adding the `-m68020' flag to GCC prevents building anything better, 4776 # like `-m68040'. 4777 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 4778 ;; 4779 esac 4780 ;; 4781 4782 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 4783 # PIC is the default for these OSes. 4784 ;; 4785 4786 mingw* | cygwin* | pw32* | os2* | cegcc*) 4787 # This hack is so that the source file can tell whether it is being 4788 # built for inclusion in a dll (and should export symbols for example). 4789 # Although the cygwin gcc ignores -fPIC, still need this for old-style 4790 # (--disable-auto-import) libraries 4791 m4_if([$1], [GCJ], [], 4792 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 4793 ;; 4794 4795 darwin* | rhapsody*) 4796 # PIC is the default on this platform 4797 # Common symbols not allowed in MH_DYLIB files 4798 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 4799 ;; 4800 4801 hpux*) 4802 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 4803 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 4804 # sets the default TLS model and affects inlining. 4805 case $host_cpu in 4806 hppa*64*) 4807 # +Z the default 4808 ;; 4809 *) 4810 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4811 ;; 4812 esac 4813 ;; 4814 4815 interix[[3-9]]*) 4816 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 4817 # Instead, we relocate shared libraries at runtime. 4818 ;; 4819 4820 msdosdjgpp*) 4821 # Just because we use GCC doesn't mean we suddenly get shared libraries 4822 # on systems that don't support them. 4823 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4824 enable_shared=no 4825 ;; 4826 4827 *nto* | *qnx*) 4828 # QNX uses GNU C++, but need to define -shared option too, otherwise 4829 # it will coredump. 4830 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4831 ;; 4832 4833 sysv4*MP*) 4834 if test -d /usr/nec; then 4835 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 4836 fi 4837 ;; 4838 4839 *) 4840 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4841 ;; 4842 esac 4843 else 4844 # PORTME Check for flag to pass linker flags through the system compiler. 4845 case $host_os in 4846 aix*) 4847 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4848 if test "$host_cpu" = ia64; then 4849 # AIX 5 now supports IA64 processor 4850 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4851 else 4852 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 4853 fi 4854 ;; 4855 4856 mingw* | cygwin* | pw32* | os2* | cegcc*) 4857 # This hack is so that the source file can tell whether it is being 4858 # built for inclusion in a dll (and should export symbols for example). 4859 m4_if([$1], [GCJ], [], 4860 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 4861 ;; 4862 4863 hpux9* | hpux10* | hpux11*) 4864 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4865 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 4866 # not for PA HP-UX. 4867 case $host_cpu in 4868 hppa*64*|ia64*) 4869 # +Z the default 4870 ;; 4871 *) 4872 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4873 ;; 4874 esac 4875 # Is there a better lt_prog_compiler_static that works with the bundled CC? 4876 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 4877 ;; 4878 4879 irix5* | irix6* | nonstopux*) 4880 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4881 # PIC (with -KPIC) is the default. 4882 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4883 ;; 4884 4885 linux* | k*bsd*-gnu) 4886 case $cc_basename in 4887 # old Intel for x86_64 which still supported -KPIC. 4888 ecc*) 4889 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4890 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4891 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4892 ;; 4893 # icc used to be incompatible with GCC. 4894 # ICC 10 doesn't accept -KPIC any more. 4895 icc* | ifort*) 4896 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4897 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4898 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4899 ;; 4900 # Lahey Fortran 8.1. 4901 lf95*) 4902 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4903 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 4904 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 4905 ;; 4906 pgcc* | pgf77* | pgf90* | pgf95*) 4907 # Portland Group compilers (*not* the Pentium gcc compiler, 4908 # which looks to be a dead project) 4909 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4910 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 4911 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4912 ;; 4913 ccc*) 4914 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4915 # All Alpha code is PIC. 4916 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4917 ;; 4918 xl*) 4919 # IBM XL C 8.0/Fortran 10.1 on PPC 4920 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4921 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 4922 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 4923 ;; 4924 *) 4925 case `$CC -V 2>&1 | sed 5q` in 4926 *Sun\ C*) 4927 # Sun C 5.9 4928 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4929 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4930 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4931 ;; 4932 *Sun\ F*) 4933 # Sun Fortran 8.3 passes all unrecognized flags to the linker 4934 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4935 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4936 _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 4937 ;; 4938 esac 4939 ;; 4940 esac 4941 ;; 4942 4943 newsos6) 4944 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4945 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4946 ;; 4947 4948 *nto* | *qnx*) 4949 # QNX uses GNU C++, but need to define -shared option too, otherwise 4950 # it will coredump. 4951 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4952 ;; 4953 4954 osf3* | osf4* | osf5*) 4955 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4956 # All OSF/1 code is PIC. 4957 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4958 ;; 4959 4960 rdos*) 4961 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4962 ;; 4963 4964 solaris*) 4965 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4966 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4967 case $cc_basename in 4968 f77* | f90* | f95*) 4969 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 4970 *) 4971 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 4972 esac 4973 ;; 4974 4975 sunos4*) 4976 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4977 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4978 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4979 ;; 4980 4981 sysv4 | sysv4.2uw2* | sysv4.3*) 4982 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4983 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4984 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4985 ;; 4986 4987 sysv4*MP*) 4988 if test -d /usr/nec ;then 4989 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 4990 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4991 fi 4992 ;; 4993 4994 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 4995 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4996 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4997 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4998 ;; 4999 5000 unicos*) 5001 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 5002 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 5003 ;; 5004 5005 uts4*) 5006 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 5007 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 5008 ;; 5009 5010 *) 5011 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 5012 ;; 5013 esac 5014 fi 5015]) 5016case $host_os in 5017 # For platforms which do not support PIC, -DPIC is meaningless: 5018 *djgpp*) 5019 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 5020 ;; 5021 *) 5022 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 5023 ;; 5024esac 5025AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 5026_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 5027 [How to pass a linker flag through the compiler]) 5028 5029# 5030# Check to make sure the PIC flag actually works. 5031# 5032if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 5033 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 5034 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 5035 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 5036 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 5037 "" | " "*) ;; 5038 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 5039 esac], 5040 [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 5041 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 5042fi 5043_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 5044 [Additional compiler flags for building library objects]) 5045 5046# 5047# Check to make sure the static flag actually works. 5048# 5049wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 5050_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 5051 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 5052 $lt_tmp_static_flag, 5053 [], 5054 [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 5055_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 5056 [Compiler flag to prevent dynamic linking]) 5057])# _LT_COMPILER_PIC 5058 5059 5060# _LT_LINKER_SHLIBS([TAGNAME]) 5061# ---------------------------- 5062# See if the linker supports building shared libraries. 5063m4_defun([_LT_LINKER_SHLIBS], 5064[AC_REQUIRE([LT_PATH_LD])dnl 5065AC_REQUIRE([LT_PATH_NM])dnl 5066m4_require([_LT_FILEUTILS_DEFAULTS])dnl 5067m4_require([_LT_DECL_EGREP])dnl 5068m4_require([_LT_DECL_SED])dnl 5069m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 5070m4_require([_LT_TAG_COMPILER])dnl 5071AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 5072m4_if([$1], [CXX], [ 5073 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 5074 case $host_os in 5075 aix[[4-9]]*) 5076 # If we're using GNU nm, then we don't want the "-C" option. 5077 # -C means demangle to AIX nm, but means don't demangle with GNU nm 5078 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 5079 _LT_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' 5080 else 5081 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 5082 fi 5083 ;; 5084 pw32*) 5085 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 5086 ;; 5087 cygwin* | mingw* | cegcc*) 5088 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' 5089 ;; 5090 linux* | k*bsd*-gnu) 5091 _LT_TAGVAR(link_all_deplibs, $1)=no 5092 ;; 5093 *) 5094 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 5095 ;; 5096 esac 5097 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 5098], [ 5099 runpath_var= 5100 _LT_TAGVAR(allow_undefined_flag, $1)= 5101 _LT_TAGVAR(always_export_symbols, $1)=no 5102 _LT_TAGVAR(archive_cmds, $1)= 5103 _LT_TAGVAR(archive_expsym_cmds, $1)= 5104 _LT_TAGVAR(compiler_needs_object, $1)=no 5105 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 5106 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 5107 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 5108 _LT_TAGVAR(hardcode_automatic, $1)=no 5109 _LT_TAGVAR(hardcode_direct, $1)=no 5110 _LT_TAGVAR(hardcode_direct_absolute, $1)=no 5111 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 5112 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 5113 _LT_TAGVAR(hardcode_libdir_separator, $1)= 5114 _LT_TAGVAR(hardcode_minus_L, $1)=no 5115 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 5116 _LT_TAGVAR(inherit_rpath, $1)=no 5117 _LT_TAGVAR(link_all_deplibs, $1)=unknown 5118 _LT_TAGVAR(module_cmds, $1)= 5119 _LT_TAGVAR(module_expsym_cmds, $1)= 5120 _LT_TAGVAR(old_archive_from_new_cmds, $1)= 5121 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 5122 _LT_TAGVAR(thread_safe_flag_spec, $1)= 5123 _LT_TAGVAR(whole_archive_flag_spec, $1)= 5124 # include_expsyms should be a list of space-separated symbols to be *always* 5125 # included in the symbol list 5126 _LT_TAGVAR(include_expsyms, $1)= 5127 # exclude_expsyms can be an extended regexp of symbols to exclude 5128 # it will be wrapped by ` (' and `)$', so one must not match beginning or 5129 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 5130 # as well as any symbol that contains `d'. 5131 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 5132 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 5133 # platforms (ab)use it in PIC code, but their linkers get confused if 5134 # the symbol is explicitly referenced. Since portable code cannot 5135 # rely on this symbol name, it's probably fine to never include it in 5136 # preloaded symbol tables. 5137 # Exclude shared library initialization/finalization symbols. 5138dnl Note also adjust exclude_expsyms for C++ above. 5139 extract_expsyms_cmds= 5140 5141 case $host_os in 5142 cygwin* | mingw* | pw32* | cegcc*) 5143 # FIXME: the MSVC++ port hasn't been tested in a loooong time 5144 # When not using gcc, we currently assume that we are using 5145 # Microsoft Visual C++. 5146 if test "$GCC" != yes; then 5147 with_gnu_ld=no 5148 fi 5149 ;; 5150 interix*) 5151 # we just hope/assume this is gcc and not c89 (= MSVC++) 5152 with_gnu_ld=yes 5153 ;; 5154 openbsd*) 5155 with_gnu_ld=no 5156 ;; 5157 esac 5158 5159 _LT_TAGVAR(ld_shlibs, $1)=yes 5160 if test "$with_gnu_ld" = yes; then 5161 # If archive_cmds runs LD, not CC, wlarc should be empty 5162 wlarc='${wl}' 5163 5164 # Set some defaults for GNU ld with shared library support. These 5165 # are reset later if shared libraries are not supported. Putting them 5166 # here allows them to be overridden if necessary. 5167 runpath_var=LD_RUN_PATH 5168 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5169 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5170 # ancient GNU ld didn't support --whole-archive et. al. 5171 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 5172 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 5173 else 5174 _LT_TAGVAR(whole_archive_flag_spec, $1)= 5175 fi 5176 supports_anon_versioning=no 5177 case `$LD -v 2>&1` in 5178 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 5179 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 5180 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 5181 *\ 2.11.*) ;; # other 2.11 versions 5182 *) supports_anon_versioning=yes ;; 5183 esac 5184 5185 # See if GNU ld supports shared libraries. 5186 case $host_os in 5187 aix[[3-9]]*) 5188 # On AIX/PPC, the GNU linker is very broken 5189 if test "$host_cpu" != ia64; then 5190 _LT_TAGVAR(ld_shlibs, $1)=no 5191 cat <<_LT_EOF 1>&2 5192 5193*** Warning: the GNU linker, at least up to release 2.9.1, is reported 5194*** to be unable to reliably create shared libraries on AIX. 5195*** Therefore, libtool is disabling shared libraries support. If you 5196*** really care for shared libraries, you may want to modify your PATH 5197*** so that a non-GNU linker is found, and then restart. 5198 5199_LT_EOF 5200 fi 5201 ;; 5202 5203 amigaos*) 5204 case $host_cpu in 5205 powerpc) 5206 # see comment about AmigaOS4 .so support 5207 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5208 _LT_TAGVAR(archive_expsym_cmds, $1)='' 5209 ;; 5210 m68k) 5211 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' 5212 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5213 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5214 ;; 5215 esac 5216 ;; 5217 5218 beos*) 5219 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 5220 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5221 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 5222 # support --undefined. This deserves some investigation. FIXME 5223 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5224 else 5225 _LT_TAGVAR(ld_shlibs, $1)=no 5226 fi 5227 ;; 5228 5229 cygwin* | mingw* | pw32* | cegcc*) 5230 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 5231 # as there is no search path for DLLs. 5232 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5233 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5234 _LT_TAGVAR(always_export_symbols, $1)=no 5235 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5236 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' 5237 5238 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 5239 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 5240 # If the export-symbols file already is a .def file (1st line 5241 # is EXPORTS), use it as is; otherwise, prepend... 5242 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 5243 cp $export_symbols $output_objdir/$soname.def; 5244 else 5245 echo EXPORTS > $output_objdir/$soname.def; 5246 cat $export_symbols >> $output_objdir/$soname.def; 5247 fi~ 5248 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 5249 else 5250 _LT_TAGVAR(ld_shlibs, $1)=no 5251 fi 5252 ;; 5253 5254 interix[[3-9]]*) 5255 _LT_TAGVAR(hardcode_direct, $1)=no 5256 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5257 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5258 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5259 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 5260 # Instead, shared libraries are loaded at an image base (0x10000000 by 5261 # default) and relocated if they conflict, which is a slow very memory 5262 # consuming and fragmenting process. To avoid this, we pick a random, 5263 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 5264 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 5265 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 5266 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 5267 ;; 5268 5269 gnu* | linux* | tpf* | k*bsd*-gnu) 5270 tmp_diet=no 5271 if test "$host_os" = linux-dietlibc; then 5272 case $cc_basename in 5273 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 5274 esac 5275 fi 5276 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 5277 && test "$tmp_diet" = no 5278 then 5279 tmp_addflag= 5280 tmp_sharedflag='-shared' 5281 case $cc_basename,$host_cpu in 5282 pgcc*) # Portland Group C compiler 5283 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 5284 tmp_addflag=' $pic_flag' 5285 ;; 5286 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers 5287 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 5288 tmp_addflag=' $pic_flag -Mnomain' ;; 5289 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 5290 tmp_addflag=' -i_dynamic' ;; 5291 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 5292 tmp_addflag=' -i_dynamic -nofor_main' ;; 5293 ifc* | ifort*) # Intel Fortran compiler 5294 tmp_addflag=' -nofor_main' ;; 5295 lf95*) # Lahey Fortran 8.1 5296 _LT_TAGVAR(whole_archive_flag_spec, $1)= 5297 tmp_sharedflag='--shared' ;; 5298 xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 5299 tmp_sharedflag='-qmkshrobj' 5300 tmp_addflag= ;; 5301 esac 5302 case `$CC -V 2>&1 | sed 5q` in 5303 *Sun\ C*) # Sun C 5.9 5304 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 5305 _LT_TAGVAR(compiler_needs_object, $1)=yes 5306 tmp_sharedflag='-G' ;; 5307 *Sun\ F*) # Sun Fortran 8.3 5308 tmp_sharedflag='-G' ;; 5309 esac 5310 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5311 5312 if test "x$supports_anon_versioning" = xyes; then 5313 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 5314 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 5315 echo "local: *; };" >> $output_objdir/$libname.ver~ 5316 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 5317 fi 5318 5319 case $cc_basename in 5320 xlf*) 5321 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 5322 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 5323 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 5324 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 5325 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib' 5326 if test "x$supports_anon_versioning" = xyes; then 5327 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 5328 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 5329 echo "local: *; };" >> $output_objdir/$libname.ver~ 5330 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 5331 fi 5332 ;; 5333 esac 5334 else 5335 _LT_TAGVAR(ld_shlibs, $1)=no 5336 fi 5337 ;; 5338 5339 netbsd* | netbsdelf*-gnu) 5340 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 5341 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 5342 wlarc= 5343 else 5344 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5345 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 5346 fi 5347 ;; 5348 5349 solaris*) 5350 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 5351 _LT_TAGVAR(ld_shlibs, $1)=no 5352 cat <<_LT_EOF 1>&2 5353 5354*** Warning: The releases 2.8.* of the GNU linker cannot reliably 5355*** create shared libraries on Solaris systems. Therefore, libtool 5356*** is disabling shared libraries support. We urge you to upgrade GNU 5357*** binutils to release 2.9.1 or newer. Another option is to modify 5358*** your PATH or compiler configuration so that the native linker is 5359*** used, and then restart. 5360 5361_LT_EOF 5362 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 5363 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5364 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 5365 else 5366 _LT_TAGVAR(ld_shlibs, $1)=no 5367 fi 5368 ;; 5369 5370 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 5371 case `$LD -v 2>&1` in 5372 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 5373 _LT_TAGVAR(ld_shlibs, $1)=no 5374 cat <<_LT_EOF 1>&2 5375 5376*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 5377*** reliably create shared libraries on SCO systems. Therefore, libtool 5378*** is disabling shared libraries support. We urge you to upgrade GNU 5379*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 5380*** your PATH or compiler configuration so that the native linker is 5381*** used, and then restart. 5382 5383_LT_EOF 5384 ;; 5385 *) 5386 # For security reasons, it is highly recommended that you always 5387 # use absolute paths for naming shared libraries, and exclude the 5388 # DT_RUNPATH tag from executables and libraries. But doing so 5389 # requires that you compile everything twice, which is a pain. 5390 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 5391 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5392 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5393 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 5394 else 5395 _LT_TAGVAR(ld_shlibs, $1)=no 5396 fi 5397 ;; 5398 esac 5399 ;; 5400 5401 sunos4*) 5402 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5403 wlarc= 5404 _LT_TAGVAR(hardcode_direct, $1)=yes 5405 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5406 ;; 5407 5408 *) 5409 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 5410 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5411 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 5412 else 5413 _LT_TAGVAR(ld_shlibs, $1)=no 5414 fi 5415 ;; 5416 esac 5417 5418 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then 5419 runpath_var= 5420 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 5421 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 5422 _LT_TAGVAR(whole_archive_flag_spec, $1)= 5423 fi 5424 else 5425 # PORTME fill in a description of your system's linker (not GNU ld) 5426 case $host_os in 5427 aix3*) 5428 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5429 _LT_TAGVAR(always_export_symbols, $1)=yes 5430 _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' 5431 # Note: this linker hardcodes the directories in LIBPATH if there 5432 # are no directories specified by -L. 5433 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5434 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 5435 # Neither direct hardcoding nor static linking is supported with a 5436 # broken collect2. 5437 _LT_TAGVAR(hardcode_direct, $1)=unsupported 5438 fi 5439 ;; 5440 5441 aix[[4-9]]*) 5442 if test "$host_cpu" = ia64; then 5443 # On IA64, the linker does run time linking by default, so we don't 5444 # have to do anything special. 5445 aix_use_runtimelinking=no 5446 exp_sym_flag='-Bexport' 5447 no_entry_flag="" 5448 else 5449 # If we're using GNU nm, then we don't want the "-C" option. 5450 # -C means demangle to AIX nm, but means don't demangle with GNU nm 5451 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 5452 _LT_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' 5453 else 5454 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 5455 fi 5456 aix_use_runtimelinking=no 5457 5458 # Test if we are trying to use run time linking or normal 5459 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 5460 # need to do runtime linking. 5461 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 5462 for ld_flag in $LDFLAGS; do 5463 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 5464 aix_use_runtimelinking=yes 5465 break 5466 fi 5467 done 5468 ;; 5469 esac 5470 5471 exp_sym_flag='-bexport' 5472 no_entry_flag='-bnoentry' 5473 fi 5474 5475 # When large executables or shared objects are built, AIX ld can 5476 # have problems creating the table of contents. If linking a library 5477 # or program results in "error TOC overflow" add -mminimal-toc to 5478 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 5479 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 5480 5481 _LT_TAGVAR(archive_cmds, $1)='' 5482 _LT_TAGVAR(hardcode_direct, $1)=yes 5483 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5484 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 5485 _LT_TAGVAR(link_all_deplibs, $1)=yes 5486 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 5487 5488 if test "$GCC" = yes; then 5489 case $host_os in aix4.[[012]]|aix4.[[012]].*) 5490 # We only want to do this on AIX 4.2 and lower, the check 5491 # below for broken collect2 doesn't work under 4.3+ 5492 collect2name=`${CC} -print-prog-name=collect2` 5493 if test -f "$collect2name" && 5494 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 5495 then 5496 # We have reworked collect2 5497 : 5498 else 5499 # We have old collect2 5500 _LT_TAGVAR(hardcode_direct, $1)=unsupported 5501 # It fails to find uninstalled libraries when the uninstalled 5502 # path is not listed in the libpath. Setting hardcode_minus_L 5503 # to unsupported forces relinking 5504 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5505 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5506 _LT_TAGVAR(hardcode_libdir_separator, $1)= 5507 fi 5508 ;; 5509 esac 5510 shared_flag='-shared' 5511 if test "$aix_use_runtimelinking" = yes; then 5512 shared_flag="$shared_flag "'${wl}-G' 5513 fi 5514 _LT_TAGVAR(link_all_deplibs, $1)=no 5515 else 5516 # not using gcc 5517 if test "$host_cpu" = ia64; then 5518 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 5519 # chokes on -Wl,-G. The following line is correct: 5520 shared_flag='-G' 5521 else 5522 if test "$aix_use_runtimelinking" = yes; then 5523 shared_flag='${wl}-G' 5524 else 5525 shared_flag='${wl}-bM:SRE' 5526 fi 5527 fi 5528 fi 5529 5530 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 5531 # It seems that -bexpall does not export symbols beginning with 5532 # underscore (_), so it is better to generate a list of symbols to export. 5533 _LT_TAGVAR(always_export_symbols, $1)=yes 5534 if test "$aix_use_runtimelinking" = yes; then 5535 # Warning - without using the other runtime loading flags (-brtl), 5536 # -berok will link without error, but may produce a broken library. 5537 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 5538 # Determine the default libpath from the value encoded in an 5539 # empty executable. 5540 _LT_SYS_MODULE_PATH_AIX 5541 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5542 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 5543 else 5544 if test "$host_cpu" = ia64; then 5545 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 5546 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 5547 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" 5548 else 5549 # Determine the default libpath from the value encoded in an 5550 # empty executable. 5551 _LT_SYS_MODULE_PATH_AIX 5552 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5553 # Warning - without using the other run time loading flags, 5554 # -berok will link without error, but may produce a broken library. 5555 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 5556 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 5557 # Exported symbols can be pulled into shared objects from archives 5558 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 5559 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5560 # This is similar to how AIX traditionally builds its shared libraries. 5561 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 5562 fi 5563 fi 5564 ;; 5565 5566 amigaos*) 5567 case $host_cpu in 5568 powerpc) 5569 # see comment about AmigaOS4 .so support 5570 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5571 _LT_TAGVAR(archive_expsym_cmds, $1)='' 5572 ;; 5573 m68k) 5574 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' 5575 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5576 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5577 ;; 5578 esac 5579 ;; 5580 5581 bsdi[[45]]*) 5582 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 5583 ;; 5584 5585 cygwin* | mingw* | pw32* | cegcc*) 5586 # When not using gcc, we currently assume that we are using 5587 # Microsoft Visual C++. 5588 # hardcode_libdir_flag_spec is actually meaningless, as there is 5589 # no search path for DLLs. 5590 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 5591 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5592 # Tell ltmain to make .lib files, not .a files. 5593 libext=lib 5594 # Tell ltmain to make .dll files, not .so files. 5595 shrext_cmds=".dll" 5596 # FIXME: Setting linknames here is a bad hack. 5597 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames=' 5598 # The linker will automatically build a .lib file if we build a DLL. 5599 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 5600 # FIXME: Should let the user specify the lib program. 5601 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 5602 _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' 5603 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5604 ;; 5605 5606 darwin* | rhapsody*) 5607 _LT_DARWIN_LINKER_FEATURES($1) 5608 ;; 5609 5610 dgux*) 5611 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5612 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5613 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5614 ;; 5615 5616 freebsd1*) 5617 _LT_TAGVAR(ld_shlibs, $1)=no 5618 ;; 5619 5620 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 5621 # support. Future versions do this automatically, but an explicit c++rt0.o 5622 # does not break anything, and helps significantly (at the cost of a little 5623 # extra space). 5624 freebsd2.2*) 5625 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 5626 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5627 _LT_TAGVAR(hardcode_direct, $1)=yes 5628 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5629 ;; 5630 5631 # Unfortunately, older versions of FreeBSD 2 do not have this feature. 5632 freebsd2*) 5633 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5634 _LT_TAGVAR(hardcode_direct, $1)=yes 5635 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5636 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5637 ;; 5638 5639 # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 5640 freebsd* | dragonfly*) 5641 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 5642 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5643 _LT_TAGVAR(hardcode_direct, $1)=yes 5644 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5645 ;; 5646 5647 hpux9*) 5648 if test "$GCC" = yes; then 5649 _LT_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' 5650 else 5651 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 5652 fi 5653 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5654 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5655 _LT_TAGVAR(hardcode_direct, $1)=yes 5656 5657 # hardcode_minus_L: Not really in the search PATH, 5658 # but as the default location of the library. 5659 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5660 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5661 ;; 5662 5663 hpux10*) 5664 if test "$GCC" = yes -a "$with_gnu_ld" = no; then 5665 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 5666 else 5667 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 5668 fi 5669 if test "$with_gnu_ld" = no; then 5670 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5671 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 5672 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5673 _LT_TAGVAR(hardcode_direct, $1)=yes 5674 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5675 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5676 # hardcode_minus_L: Not really in the search PATH, 5677 # but as the default location of the library. 5678 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5679 fi 5680 ;; 5681 5682 hpux11*) 5683 if test "$GCC" = yes -a "$with_gnu_ld" = no; then 5684 case $host_cpu in 5685 hppa*64*) 5686 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5687 ;; 5688 ia64*) 5689 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 5690 ;; 5691 *) 5692 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 5693 ;; 5694 esac 5695 else 5696 case $host_cpu in 5697 hppa*64*) 5698 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5699 ;; 5700 ia64*) 5701 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 5702 ;; 5703 *) 5704 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 5705 ;; 5706 esac 5707 fi 5708 if test "$with_gnu_ld" = no; then 5709 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5710 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5711 5712 case $host_cpu in 5713 hppa*64*|ia64*) 5714 _LT_TAGVAR(hardcode_direct, $1)=no 5715 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5716 ;; 5717 *) 5718 _LT_TAGVAR(hardcode_direct, $1)=yes 5719 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5720 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5721 5722 # hardcode_minus_L: Not really in the search PATH, 5723 # but as the default location of the library. 5724 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5725 ;; 5726 esac 5727 fi 5728 ;; 5729 5730 irix5* | irix6* | nonstopux*) 5731 if test "$GCC" = yes; then 5732 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5733 # Try to use the -exported_symbol ld option, if it does not 5734 # work, assume that -exports_file does not work either and 5735 # implicitly export all symbols. 5736 save_LDFLAGS="$LDFLAGS" 5737 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" 5738 AC_LINK_IFELSE(int foo(void) {}, 5739 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' 5740 ) 5741 LDFLAGS="$save_LDFLAGS" 5742 else 5743 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 5744 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' 5745 fi 5746 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 5747 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5748 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5749 _LT_TAGVAR(inherit_rpath, $1)=yes 5750 _LT_TAGVAR(link_all_deplibs, $1)=yes 5751 ;; 5752 5753 netbsd* | netbsdelf*-gnu) 5754 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 5755 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 5756 else 5757 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 5758 fi 5759 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5760 _LT_TAGVAR(hardcode_direct, $1)=yes 5761 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5762 ;; 5763 5764 newsos6) 5765 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5766 _LT_TAGVAR(hardcode_direct, $1)=yes 5767 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5768 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5769 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5770 ;; 5771 5772 *nto* | *qnx*) 5773 ;; 5774 5775 openbsd*) 5776 if test -f /usr/libexec/ld.so; then 5777 _LT_TAGVAR(hardcode_direct, $1)=yes 5778 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5779 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5780 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5781 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5782 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 5783 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5784 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5785 else 5786 case $host_os in 5787 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 5788 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5789 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5790 ;; 5791 *) 5792 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5793 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5794 ;; 5795 esac 5796 fi 5797 else 5798 _LT_TAGVAR(ld_shlibs, $1)=no 5799 fi 5800 ;; 5801 5802 os2*) 5803 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5804 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5805 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5806 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' 5807 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 5808 ;; 5809 5810 osf3*) 5811 if test "$GCC" = yes; then 5812 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5813 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5814 else 5815 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5816 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 5817 fi 5818 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 5819 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5820 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5821 ;; 5822 5823 osf4* | osf5*) # as osf3* with the addition of -msym flag 5824 if test "$GCC" = yes; then 5825 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5826 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5827 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5828 else 5829 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5830 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 5831 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ 5832 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' 5833 5834 # Both c and cxx compiler support -rpath directly 5835 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 5836 fi 5837 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 5838 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5839 ;; 5840 5841 solaris*) 5842 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 5843 if test "$GCC" = yes; then 5844 wlarc='${wl}' 5845 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5846 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 5847 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 5848 else 5849 case `$CC -V 2>&1` in 5850 *"Compilers 5.0"*) 5851 wlarc='' 5852 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 5853 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 5854 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 5855 ;; 5856 *) 5857 wlarc='${wl}' 5858 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' 5859 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 5860 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 5861 ;; 5862 esac 5863 fi 5864 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5865 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5866 case $host_os in 5867 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 5868 *) 5869 # The compiler driver will combine and reorder linker options, 5870 # but understands `-z linker_flag'. GCC discards it without `$wl', 5871 # but is careful enough not to reorder. 5872 # Supported since Solaris 2.6 (maybe 2.5.1?) 5873 if test "$GCC" = yes; then 5874 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 5875 else 5876 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 5877 fi 5878 ;; 5879 esac 5880 _LT_TAGVAR(link_all_deplibs, $1)=yes 5881 ;; 5882 5883 sunos4*) 5884 if test "x$host_vendor" = xsequent; then 5885 # Use $CC to link under sequent, because it throws in some extra .o 5886 # files that make .init and .fini sections work. 5887 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 5888 else 5889 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 5890 fi 5891 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5892 _LT_TAGVAR(hardcode_direct, $1)=yes 5893 _LT_TAGVAR(hardcode_minus_L, $1)=yes 5894 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5895 ;; 5896 5897 sysv4) 5898 case $host_vendor in 5899 sni) 5900 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5901 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 5902 ;; 5903 siemens) 5904 ## LD is ld it makes a PLAMLIB 5905 ## CC just makes a GrossModule. 5906 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 5907 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 5908 _LT_TAGVAR(hardcode_direct, $1)=no 5909 ;; 5910 motorola) 5911 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5912 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 5913 ;; 5914 esac 5915 runpath_var='LD_RUN_PATH' 5916 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5917 ;; 5918 5919 sysv4.3*) 5920 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5921 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5922 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 5923 ;; 5924 5925 sysv4*MP*) 5926 if test -d /usr/nec; then 5927 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5928 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5929 runpath_var=LD_RUN_PATH 5930 hardcode_runpath_var=yes 5931 _LT_TAGVAR(ld_shlibs, $1)=yes 5932 fi 5933 ;; 5934 5935 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 5936 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5937 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5938 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5939 runpath_var='LD_RUN_PATH' 5940 5941 if test "$GCC" = yes; then 5942 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5943 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5944 else 5945 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5946 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5947 fi 5948 ;; 5949 5950 sysv5* | sco3.2v5* | sco5v6*) 5951 # Note: We can NOT use -z defs as we might desire, because we do not 5952 # link with -lc, and that would cause any symbols used from libc to 5953 # always be unresolved, which means just about no library would 5954 # ever link correctly. If we're not using GNU ld we use -z text 5955 # though, which does catch some bad symbols but isn't as heavy-handed 5956 # as -z defs. 5957 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5958 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 5959 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5960 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5961 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 5962 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 5963 _LT_TAGVAR(link_all_deplibs, $1)=yes 5964 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 5965 runpath_var='LD_RUN_PATH' 5966 5967 if test "$GCC" = yes; then 5968 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5969 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5970 else 5971 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5972 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5973 fi 5974 ;; 5975 5976 uts4*) 5977 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5978 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5979 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5980 ;; 5981 5982 *) 5983 _LT_TAGVAR(ld_shlibs, $1)=no 5984 ;; 5985 esac 5986 5987 if test x$host_vendor = xsni; then 5988 case $host in 5989 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 5990 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' 5991 ;; 5992 esac 5993 fi 5994 fi 5995]) 5996AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 5997test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 5998 5999_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 6000 6001_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 6002_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 6003_LT_DECL([], [extract_expsyms_cmds], [2], 6004 [The commands to extract the exported symbol list from a shared archive]) 6005 6006# 6007# Do we need to explicitly link libc? 6008# 6009case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 6010x|xyes) 6011 # Assume -lc should be added 6012 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 6013 6014 if test "$enable_shared" = yes && test "$GCC" = yes; then 6015 case $_LT_TAGVAR(archive_cmds, $1) in 6016 *'~'*) 6017 # FIXME: we may have to deal with multi-command sequences. 6018 ;; 6019 '$CC '*) 6020 # Test whether the compiler implicitly links with -lc since on some 6021 # systems, -lgcc has to come before -lc. If gcc already passes -lc 6022 # to ld, don't add -lc before -lgcc. 6023 AC_MSG_CHECKING([whether -lc should be explicitly linked in]) 6024 $RM conftest* 6025 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 6026 6027 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 6028 soname=conftest 6029 lib=conftest 6030 libobjs=conftest.$ac_objext 6031 deplibs= 6032 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 6033 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 6034 compiler_flags=-v 6035 linker_flags=-v 6036 verstring= 6037 output_objdir=. 6038 libname=conftest 6039 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 6040 _LT_TAGVAR(allow_undefined_flag, $1)= 6041 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 6042 then 6043 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6044 else 6045 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 6046 fi 6047 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 6048 else 6049 cat conftest.err 1>&5 6050 fi 6051 $RM conftest* 6052 AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)]) 6053 ;; 6054 esac 6055 fi 6056 ;; 6057esac 6058 6059_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 6060 [Whether or not to add -lc for building shared libraries]) 6061_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 6062 [enable_shared_with_static_runtimes], [0], 6063 [Whether or not to disallow shared libs when runtime libs are static]) 6064_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 6065 [Compiler flag to allow reflexive dlopens]) 6066_LT_TAGDECL([], [whole_archive_flag_spec], [1], 6067 [Compiler flag to generate shared objects directly from archives]) 6068_LT_TAGDECL([], [compiler_needs_object], [1], 6069 [Whether the compiler copes with passing no objects directly]) 6070_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 6071 [Create an old-style archive from a shared archive]) 6072_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 6073 [Create a temporary old-style archive to link instead of a shared archive]) 6074_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 6075_LT_TAGDECL([], [archive_expsym_cmds], [2]) 6076_LT_TAGDECL([], [module_cmds], [2], 6077 [Commands used to build a loadable module if different from building 6078 a shared archive.]) 6079_LT_TAGDECL([], [module_expsym_cmds], [2]) 6080_LT_TAGDECL([], [with_gnu_ld], [1], 6081 [Whether we are building with GNU ld or not]) 6082_LT_TAGDECL([], [allow_undefined_flag], [1], 6083 [Flag that allows shared libraries with undefined symbols to be built]) 6084_LT_TAGDECL([], [no_undefined_flag], [1], 6085 [Flag that enforces no undefined symbols]) 6086_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 6087 [Flag to hardcode $libdir into a binary during linking. 6088 This must work even if $libdir does not exist]) 6089_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], 6090 [[If ld is used when linking, flag to hardcode $libdir into a binary 6091 during linking. This must work even if $libdir does not exist]]) 6092_LT_TAGDECL([], [hardcode_libdir_separator], [1], 6093 [Whether we need a single "-rpath" flag with a separated argument]) 6094_LT_TAGDECL([], [hardcode_direct], [0], 6095 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 6096 DIR into the resulting binary]) 6097_LT_TAGDECL([], [hardcode_direct_absolute], [0], 6098 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 6099 DIR into the resulting binary and the resulting library dependency is 6100 "absolute", i.e impossible to change by setting ${shlibpath_var} if the 6101 library is relocated]) 6102_LT_TAGDECL([], [hardcode_minus_L], [0], 6103 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 6104 into the resulting binary]) 6105_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 6106 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 6107 into the resulting binary]) 6108_LT_TAGDECL([], [hardcode_automatic], [0], 6109 [Set to "yes" if building a shared library automatically hardcodes DIR 6110 into the library and all subsequent libraries and executables linked 6111 against it]) 6112_LT_TAGDECL([], [inherit_rpath], [0], 6113 [Set to yes if linker adds runtime paths of dependent libraries 6114 to runtime path list]) 6115_LT_TAGDECL([], [link_all_deplibs], [0], 6116 [Whether libtool must link a program against all its dependency libraries]) 6117_LT_TAGDECL([], [fix_srcfile_path], [1], 6118 [Fix the shell variable $srcfile for the compiler]) 6119_LT_TAGDECL([], [always_export_symbols], [0], 6120 [Set to "yes" if exported symbols are required]) 6121_LT_TAGDECL([], [export_symbols_cmds], [2], 6122 [The commands to list exported symbols]) 6123_LT_TAGDECL([], [exclude_expsyms], [1], 6124 [Symbols that should not be listed in the preloaded symbols]) 6125_LT_TAGDECL([], [include_expsyms], [1], 6126 [Symbols that must always be exported]) 6127_LT_TAGDECL([], [prelink_cmds], [2], 6128 [Commands necessary for linking programs (against libraries) with templates]) 6129_LT_TAGDECL([], [file_list_spec], [1], 6130 [Specify filename containing input files]) 6131dnl FIXME: Not yet implemented 6132dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 6133dnl [Compiler flag to generate thread safe objects]) 6134])# _LT_LINKER_SHLIBS 6135 6136 6137# _LT_LANG_C_CONFIG([TAG]) 6138# ------------------------ 6139# Ensure that the configuration variables for a C compiler are suitably 6140# defined. These variables are subsequently used by _LT_CONFIG to write 6141# the compiler configuration to `libtool'. 6142m4_defun([_LT_LANG_C_CONFIG], 6143[m4_require([_LT_DECL_EGREP])dnl 6144lt_save_CC="$CC" 6145AC_LANG_PUSH(C) 6146 6147# Source file extension for C test sources. 6148ac_ext=c 6149 6150# Object file extension for compiled C test sources. 6151objext=o 6152_LT_TAGVAR(objext, $1)=$objext 6153 6154# Code to be used in simple compile tests 6155lt_simple_compile_test_code="int some_variable = 0;" 6156 6157# Code to be used in simple link tests 6158lt_simple_link_test_code='int main(){return(0);}' 6159 6160_LT_TAG_COMPILER 6161# Save the default compiler, since it gets overwritten when the other 6162# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 6163compiler_DEFAULT=$CC 6164 6165# save warnings/boilerplate of simple test code 6166_LT_COMPILER_BOILERPLATE 6167_LT_LINKER_BOILERPLATE 6168 6169if test -n "$compiler"; then 6170 _LT_COMPILER_NO_RTTI($1) 6171 _LT_COMPILER_PIC($1) 6172 _LT_COMPILER_C_O($1) 6173 _LT_COMPILER_FILE_LOCKS($1) 6174 _LT_LINKER_SHLIBS($1) 6175 _LT_SYS_DYNAMIC_LINKER($1) 6176 _LT_LINKER_HARDCODE_LIBPATH($1) 6177 LT_SYS_DLOPEN_SELF 6178 _LT_CMD_STRIPLIB 6179 6180 # Report which library types will actually be built 6181 AC_MSG_CHECKING([if libtool supports shared libraries]) 6182 AC_MSG_RESULT([$can_build_shared]) 6183 6184 AC_MSG_CHECKING([whether to build shared libraries]) 6185 test "$can_build_shared" = "no" && enable_shared=no 6186 6187 # On AIX, shared libraries and static libraries use the same namespace, and 6188 # are all built from PIC. 6189 case $host_os in 6190 aix3*) 6191 test "$enable_shared" = yes && enable_static=no 6192 if test -n "$RANLIB"; then 6193 archive_cmds="$archive_cmds~\$RANLIB \$lib" 6194 postinstall_cmds='$RANLIB $lib' 6195 fi 6196 ;; 6197 6198 aix[[4-9]]*) 6199 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 6200 test "$enable_shared" = yes && enable_static=no 6201 fi 6202 ;; 6203 esac 6204 AC_MSG_RESULT([$enable_shared]) 6205 6206 AC_MSG_CHECKING([whether to build static libraries]) 6207 # Make sure either enable_shared or enable_static is yes. 6208 test "$enable_shared" = yes || enable_static=yes 6209 AC_MSG_RESULT([$enable_static]) 6210 6211 _LT_CONFIG($1) 6212fi 6213AC_LANG_POP 6214CC="$lt_save_CC" 6215])# _LT_LANG_C_CONFIG 6216 6217 6218# _LT_PROG_CXX 6219# ------------ 6220# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++ 6221# compiler, we have our own version here. 6222m4_defun([_LT_PROG_CXX], 6223[ 6224pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes]) 6225AC_PROG_CXX 6226if test -n "$CXX" && ( test "X$CXX" != "Xno" && 6227 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 6228 (test "X$CXX" != "Xg++"))) ; then 6229 AC_PROG_CXXCPP 6230else 6231 _lt_caught_CXX_error=yes 6232fi 6233popdef([AC_MSG_ERROR]) 6234])# _LT_PROG_CXX 6235 6236dnl aclocal-1.4 backwards compatibility: 6237dnl AC_DEFUN([_LT_PROG_CXX], []) 6238 6239 6240# _LT_LANG_CXX_CONFIG([TAG]) 6241# -------------------------- 6242# Ensure that the configuration variables for a C++ compiler are suitably 6243# defined. These variables are subsequently used by _LT_CONFIG to write 6244# the compiler configuration to `libtool'. 6245m4_defun([_LT_LANG_CXX_CONFIG], 6246[AC_REQUIRE([_LT_PROG_CXX])dnl 6247m4_require([_LT_FILEUTILS_DEFAULTS])dnl 6248m4_require([_LT_DECL_EGREP])dnl 6249 6250AC_LANG_PUSH(C++) 6251_LT_TAGVAR(archive_cmds_need_lc, $1)=no 6252_LT_TAGVAR(allow_undefined_flag, $1)= 6253_LT_TAGVAR(always_export_symbols, $1)=no 6254_LT_TAGVAR(archive_expsym_cmds, $1)= 6255_LT_TAGVAR(compiler_needs_object, $1)=no 6256_LT_TAGVAR(export_dynamic_flag_spec, $1)= 6257_LT_TAGVAR(hardcode_direct, $1)=no 6258_LT_TAGVAR(hardcode_direct_absolute, $1)=no 6259_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6260_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 6261_LT_TAGVAR(hardcode_libdir_separator, $1)= 6262_LT_TAGVAR(hardcode_minus_L, $1)=no 6263_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 6264_LT_TAGVAR(hardcode_automatic, $1)=no 6265_LT_TAGVAR(inherit_rpath, $1)=no 6266_LT_TAGVAR(module_cmds, $1)= 6267_LT_TAGVAR(module_expsym_cmds, $1)= 6268_LT_TAGVAR(link_all_deplibs, $1)=unknown 6269_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 6270_LT_TAGVAR(no_undefined_flag, $1)= 6271_LT_TAGVAR(whole_archive_flag_spec, $1)= 6272_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 6273 6274# Source file extension for C++ test sources. 6275ac_ext=cpp 6276 6277# Object file extension for compiled C++ test sources. 6278objext=o 6279_LT_TAGVAR(objext, $1)=$objext 6280 6281# No sense in running all these tests if we already determined that 6282# the CXX compiler isn't working. Some variables (like enable_shared) 6283# are currently assumed to apply to all compilers on this platform, 6284# and will be corrupted by setting them based on a non-working compiler. 6285if test "$_lt_caught_CXX_error" != yes; then 6286 # Code to be used in simple compile tests 6287 lt_simple_compile_test_code="int some_variable = 0;" 6288 6289 # Code to be used in simple link tests 6290 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 6291 6292 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 6293 _LT_TAG_COMPILER 6294 6295 # save warnings/boilerplate of simple test code 6296 _LT_COMPILER_BOILERPLATE 6297 _LT_LINKER_BOILERPLATE 6298 6299 # Allow CC to be a program name with arguments. 6300 lt_save_CC=$CC 6301 lt_save_LD=$LD 6302 lt_save_GCC=$GCC 6303 GCC=$GXX 6304 lt_save_with_gnu_ld=$with_gnu_ld 6305 lt_save_path_LD=$lt_cv_path_LD 6306 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 6307 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 6308 else 6309 $as_unset lt_cv_prog_gnu_ld 6310 fi 6311 if test -n "${lt_cv_path_LDCXX+set}"; then 6312 lt_cv_path_LD=$lt_cv_path_LDCXX 6313 else 6314 $as_unset lt_cv_path_LD 6315 fi 6316 test -z "${LDCXX+set}" || LD=$LDCXX 6317 CC=${CXX-"c++"} 6318 compiler=$CC 6319 _LT_TAGVAR(compiler, $1)=$CC 6320 _LT_CC_BASENAME([$compiler]) 6321 6322 if test -n "$compiler"; then 6323 # We don't want -fno-exception when compiling C++ code, so set the 6324 # no_builtin_flag separately 6325 if test "$GXX" = yes; then 6326 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 6327 else 6328 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 6329 fi 6330 6331 if test "$GXX" = yes; then 6332 # Set up default GNU C++ configuration 6333 6334 LT_PATH_LD 6335 6336 # Check if GNU C++ uses GNU ld as the underlying linker, since the 6337 # archiving commands below assume that GNU ld is being used. 6338 if test "$with_gnu_ld" = yes; then 6339 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 6340 _LT_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' 6341 6342 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6343 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6344 6345 # If archive_cmds runs LD, not CC, wlarc should be empty 6346 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 6347 # investigate it a little bit more. (MM) 6348 wlarc='${wl}' 6349 6350 # ancient GNU ld didn't support --whole-archive et. al. 6351 if eval "`$CC -print-prog-name=ld` --help 2>&1" | 6352 $GREP 'no-whole-archive' > /dev/null; then 6353 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6354 else 6355 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6356 fi 6357 else 6358 with_gnu_ld=no 6359 wlarc= 6360 6361 # A generic and very simple default shared library creation 6362 # command for GNU C++ for the case where it uses the native 6363 # linker, instead of GNU ld. If possible, this setting should 6364 # overridden to take advantage of the native linker features on 6365 # the platform it is being used on. 6366 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 6367 fi 6368 6369 # Commands to make compiler produce verbose output that lists 6370 # what "hidden" libraries, object files and flags are used when 6371 # linking a shared library. 6372 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 6373 6374 else 6375 GXX=no 6376 with_gnu_ld=no 6377 wlarc= 6378 fi 6379 6380 # PORTME: fill in a description of your system's C++ link characteristics 6381 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 6382 _LT_TAGVAR(ld_shlibs, $1)=yes 6383 case $host_os in 6384 aix3*) 6385 # FIXME: insert proper C++ library support 6386 _LT_TAGVAR(ld_shlibs, $1)=no 6387 ;; 6388 aix[[4-9]]*) 6389 if test "$host_cpu" = ia64; then 6390 # On IA64, the linker does run time linking by default, so we don't 6391 # have to do anything special. 6392 aix_use_runtimelinking=no 6393 exp_sym_flag='-Bexport' 6394 no_entry_flag="" 6395 else 6396 aix_use_runtimelinking=no 6397 6398 # Test if we are trying to use run time linking or normal 6399 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 6400 # need to do runtime linking. 6401 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 6402 for ld_flag in $LDFLAGS; do 6403 case $ld_flag in 6404 *-brtl*) 6405 aix_use_runtimelinking=yes 6406 break 6407 ;; 6408 esac 6409 done 6410 ;; 6411 esac 6412 6413 exp_sym_flag='-bexport' 6414 no_entry_flag='-bnoentry' 6415 fi 6416 6417 # When large executables or shared objects are built, AIX ld can 6418 # have problems creating the table of contents. If linking a library 6419 # or program results in "error TOC overflow" add -mminimal-toc to 6420 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 6421 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 6422 6423 _LT_TAGVAR(archive_cmds, $1)='' 6424 _LT_TAGVAR(hardcode_direct, $1)=yes 6425 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 6426 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 6427 _LT_TAGVAR(link_all_deplibs, $1)=yes 6428 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 6429 6430 if test "$GXX" = yes; then 6431 case $host_os in aix4.[[012]]|aix4.[[012]].*) 6432 # We only want to do this on AIX 4.2 and lower, the check 6433 # below for broken collect2 doesn't work under 4.3+ 6434 collect2name=`${CC} -print-prog-name=collect2` 6435 if test -f "$collect2name" && 6436 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 6437 then 6438 # We have reworked collect2 6439 : 6440 else 6441 # We have old collect2 6442 _LT_TAGVAR(hardcode_direct, $1)=unsupported 6443 # It fails to find uninstalled libraries when the uninstalled 6444 # path is not listed in the libpath. Setting hardcode_minus_L 6445 # to unsupported forces relinking 6446 _LT_TAGVAR(hardcode_minus_L, $1)=yes 6447 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6448 _LT_TAGVAR(hardcode_libdir_separator, $1)= 6449 fi 6450 esac 6451 shared_flag='-shared' 6452 if test "$aix_use_runtimelinking" = yes; then 6453 shared_flag="$shared_flag "'${wl}-G' 6454 fi 6455 else 6456 # not using gcc 6457 if test "$host_cpu" = ia64; then 6458 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 6459 # chokes on -Wl,-G. The following line is correct: 6460 shared_flag='-G' 6461 else 6462 if test "$aix_use_runtimelinking" = yes; then 6463 shared_flag='${wl}-G' 6464 else 6465 shared_flag='${wl}-bM:SRE' 6466 fi 6467 fi 6468 fi 6469 6470 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 6471 # It seems that -bexpall does not export symbols beginning with 6472 # underscore (_), so it is better to generate a list of symbols to 6473 # export. 6474 _LT_TAGVAR(always_export_symbols, $1)=yes 6475 if test "$aix_use_runtimelinking" = yes; then 6476 # Warning - without using the other runtime loading flags (-brtl), 6477 # -berok will link without error, but may produce a broken library. 6478 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 6479 # Determine the default libpath from the value encoded in an empty 6480 # executable. 6481 _LT_SYS_MODULE_PATH_AIX 6482 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 6483 6484 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 6485 else 6486 if test "$host_cpu" = ia64; then 6487 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 6488 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 6489 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" 6490 else 6491 # Determine the default libpath from the value encoded in an 6492 # empty executable. 6493 _LT_SYS_MODULE_PATH_AIX 6494 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 6495 # Warning - without using the other run time loading flags, 6496 # -berok will link without error, but may produce a broken library. 6497 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 6498 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 6499 # Exported symbols can be pulled into shared objects from archives 6500 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 6501 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 6502 # This is similar to how AIX traditionally builds its shared 6503 # libraries. 6504 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 6505 fi 6506 fi 6507 ;; 6508 6509 beos*) 6510 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6511 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6512 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 6513 # support --undefined. This deserves some investigation. FIXME 6514 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6515 else 6516 _LT_TAGVAR(ld_shlibs, $1)=no 6517 fi 6518 ;; 6519 6520 chorus*) 6521 case $cc_basename in 6522 *) 6523 # FIXME: insert proper C++ library support 6524 _LT_TAGVAR(ld_shlibs, $1)=no 6525 ;; 6526 esac 6527 ;; 6528 6529 cygwin* | mingw* | pw32* | cegcc*) 6530 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 6531 # as there is no search path for DLLs. 6532 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6533 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6534 _LT_TAGVAR(always_export_symbols, $1)=no 6535 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6536 6537 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 6538 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 6539 # If the export-symbols file already is a .def file (1st line 6540 # is EXPORTS), use it as is; otherwise, prepend... 6541 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 6542 cp $export_symbols $output_objdir/$soname.def; 6543 else 6544 echo EXPORTS > $output_objdir/$soname.def; 6545 cat $export_symbols >> $output_objdir/$soname.def; 6546 fi~ 6547 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 6548 else 6549 _LT_TAGVAR(ld_shlibs, $1)=no 6550 fi 6551 ;; 6552 darwin* | rhapsody*) 6553 _LT_DARWIN_LINKER_FEATURES($1) 6554 ;; 6555 6556 dgux*) 6557 case $cc_basename in 6558 ec++*) 6559 # FIXME: insert proper C++ library support 6560 _LT_TAGVAR(ld_shlibs, $1)=no 6561 ;; 6562 ghcx*) 6563 # Green Hills C++ Compiler 6564 # FIXME: insert proper C++ library support 6565 _LT_TAGVAR(ld_shlibs, $1)=no 6566 ;; 6567 *) 6568 # FIXME: insert proper C++ library support 6569 _LT_TAGVAR(ld_shlibs, $1)=no 6570 ;; 6571 esac 6572 ;; 6573 6574 freebsd[[12]]*) 6575 # C++ shared libraries reported to be fairly broken before 6576 # switch to ELF 6577 _LT_TAGVAR(ld_shlibs, $1)=no 6578 ;; 6579 6580 freebsd-elf*) 6581 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6582 ;; 6583 6584 freebsd* | dragonfly*) 6585 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 6586 # conventions 6587 _LT_TAGVAR(ld_shlibs, $1)=yes 6588 ;; 6589 6590 gnu*) 6591 ;; 6592 6593 hpux9*) 6594 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 6595 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6596 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6597 _LT_TAGVAR(hardcode_direct, $1)=yes 6598 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 6599 # but as the default 6600 # location of the library. 6601 6602 case $cc_basename in 6603 CC*) 6604 # FIXME: insert proper C++ library support 6605 _LT_TAGVAR(ld_shlibs, $1)=no 6606 ;; 6607 aCC*) 6608 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 6609 # Commands to make compiler produce verbose output that lists 6610 # what "hidden" libraries, object files and flags are used when 6611 # linking a shared library. 6612 # 6613 # There doesn't appear to be a way to prevent this compiler from 6614 # explicitly linking system object files so we need to strip them 6615 # from the output so that they don't get included in the library 6616 # dependencies. 6617 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 "X$list" | $Xsed' 6618 ;; 6619 *) 6620 if test "$GXX" = yes; then 6621 _LT_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' 6622 else 6623 # FIXME: insert proper C++ library support 6624 _LT_TAGVAR(ld_shlibs, $1)=no 6625 fi 6626 ;; 6627 esac 6628 ;; 6629 6630 hpux10*|hpux11*) 6631 if test $with_gnu_ld = no; then 6632 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 6633 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6634 6635 case $host_cpu in 6636 hppa*64*|ia64*) 6637 ;; 6638 *) 6639 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6640 ;; 6641 esac 6642 fi 6643 case $host_cpu in 6644 hppa*64*|ia64*) 6645 _LT_TAGVAR(hardcode_direct, $1)=no 6646 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6647 ;; 6648 *) 6649 _LT_TAGVAR(hardcode_direct, $1)=yes 6650 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 6651 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 6652 # but as the default 6653 # location of the library. 6654 ;; 6655 esac 6656 6657 case $cc_basename in 6658 CC*) 6659 # FIXME: insert proper C++ library support 6660 _LT_TAGVAR(ld_shlibs, $1)=no 6661 ;; 6662 aCC*) 6663 case $host_cpu in 6664 hppa*64*) 6665 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6666 ;; 6667 ia64*) 6668 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6669 ;; 6670 *) 6671 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6672 ;; 6673 esac 6674 # Commands to make compiler produce verbose output that lists 6675 # what "hidden" libraries, object files and flags are used when 6676 # linking a shared library. 6677 # 6678 # There doesn't appear to be a way to prevent this compiler from 6679 # explicitly linking system object files so we need to strip them 6680 # from the output so that they don't get included in the library 6681 # dependencies. 6682 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 "X$list" | $Xsed' 6683 ;; 6684 *) 6685 if test "$GXX" = yes; then 6686 if test $with_gnu_ld = no; then 6687 case $host_cpu in 6688 hppa*64*) 6689 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6690 ;; 6691 ia64*) 6692 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6693 ;; 6694 *) 6695 _LT_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' 6696 ;; 6697 esac 6698 fi 6699 else 6700 # FIXME: insert proper C++ library support 6701 _LT_TAGVAR(ld_shlibs, $1)=no 6702 fi 6703 ;; 6704 esac 6705 ;; 6706 6707 interix[[3-9]]*) 6708 _LT_TAGVAR(hardcode_direct, $1)=no 6709 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6710 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6711 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6712 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 6713 # Instead, shared libraries are loaded at an image base (0x10000000 by 6714 # default) and relocated if they conflict, which is a slow very memory 6715 # consuming and fragmenting process. To avoid this, we pick a random, 6716 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 6717 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 6718 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 6719 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 6720 ;; 6721 irix5* | irix6*) 6722 case $cc_basename in 6723 CC*) 6724 # SGI C++ 6725 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 6726 6727 # Archives containing C++ object files must be created using 6728 # "CC -ar", where "CC" is the IRIX C++ compiler. This is 6729 # necessary to make sure instantiated templates are included 6730 # in the archive. 6731 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 6732 ;; 6733 *) 6734 if test "$GXX" = yes; then 6735 if test "$with_gnu_ld" = no; then 6736 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 6737 else 6738 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib' 6739 fi 6740 fi 6741 _LT_TAGVAR(link_all_deplibs, $1)=yes 6742 ;; 6743 esac 6744 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6745 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6746 _LT_TAGVAR(inherit_rpath, $1)=yes 6747 ;; 6748 6749 linux* | k*bsd*-gnu) 6750 case $cc_basename in 6751 KCC*) 6752 # Kuck and Associates, Inc. (KAI) C++ Compiler 6753 6754 # KCC will only create a shared library if the output file 6755 # ends with ".so" (or ".sl" for HP-UX), so rename the library 6756 # to its proper name (with version) after linking. 6757 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' 6758 _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' 6759 # Commands to make compiler produce verbose output that lists 6760 # what "hidden" libraries, object files and flags are used when 6761 # linking a shared library. 6762 # 6763 # There doesn't appear to be a way to prevent this compiler from 6764 # explicitly linking system object files so we need to strip them 6765 # from the output so that they don't get included in the library 6766 # dependencies. 6767 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 "X$list" | $Xsed' 6768 6769 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6770 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6771 6772 # Archives containing C++ object files must be created using 6773 # "CC -Bstatic", where "CC" is the KAI C++ compiler. 6774 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 6775 ;; 6776 icpc* | ecpc* ) 6777 # Intel C++ 6778 with_gnu_ld=yes 6779 # version 8.0 and above of icpc choke on multiply defined symbols 6780 # if we add $predep_objects and $postdep_objects, however 7.1 and 6781 # earlier do not add the objects themselves. 6782 case `$CC -V 2>&1` in 6783 *"Version 7."*) 6784 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 6785 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6786 ;; 6787 *) # Version 8.0 or newer 6788 tmp_idyn= 6789 case $host_cpu in 6790 ia64*) tmp_idyn=' -i_dynamic';; 6791 esac 6792 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6793 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6794 ;; 6795 esac 6796 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6797 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6798 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6799 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 6800 ;; 6801 pgCC* | pgcpp*) 6802 # Portland Group C++ compiler 6803 case `$CC -V` in 6804 *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*) 6805 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 6806 rm -rf $tpldir~ 6807 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 6808 compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"' 6809 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 6810 rm -rf $tpldir~ 6811 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 6812 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~ 6813 $RANLIB $oldlib' 6814 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 6815 rm -rf $tpldir~ 6816 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 6817 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 6818 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 6819 rm -rf $tpldir~ 6820 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 6821 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' 6822 ;; 6823 *) # Version 6 will use weak symbols 6824 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 6825 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' 6826 ;; 6827 esac 6828 6829 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 6830 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6831 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 6832 ;; 6833 cxx*) 6834 # Compaq C++ 6835 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 6836 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' 6837 6838 runpath_var=LD_RUN_PATH 6839 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 6840 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6841 6842 # Commands to make compiler produce verbose output that lists 6843 # what "hidden" libraries, object files and flags are used when 6844 # linking a shared library. 6845 # 6846 # There doesn't appear to be a way to prevent this compiler from 6847 # explicitly linking system object files so we need to strip them 6848 # from the output so that they don't get included in the library 6849 # dependencies. 6850 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "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 "X$list" | $Xsed' 6851 ;; 6852 xl*) 6853 # IBM XL 8.0 on PPC, with GNU ld 6854 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6855 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6856 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6857 if test "x$supports_anon_versioning" = xyes; then 6858 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6859 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6860 echo "local: *; };" >> $output_objdir/$libname.ver~ 6861 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 6862 fi 6863 ;; 6864 *) 6865 case `$CC -V 2>&1 | sed 5q` in 6866 *Sun\ C*) 6867 # Sun C++ 5.9 6868 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 6869 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6870 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' 6871 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6872 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 6873 _LT_TAGVAR(compiler_needs_object, $1)=yes 6874 6875 # Not sure whether something based on 6876 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 6877 # would be better. 6878 output_verbose_link_cmd='echo' 6879 6880 # Archives containing C++ object files must be created using 6881 # "CC -xar", where "CC" is the Sun C++ compiler. This is 6882 # necessary to make sure instantiated templates are included 6883 # in the archive. 6884 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 6885 ;; 6886 esac 6887 ;; 6888 esac 6889 ;; 6890 6891 lynxos*) 6892 # FIXME: insert proper C++ library support 6893 _LT_TAGVAR(ld_shlibs, $1)=no 6894 ;; 6895 6896 m88k*) 6897 # FIXME: insert proper C++ library support 6898 _LT_TAGVAR(ld_shlibs, $1)=no 6899 ;; 6900 6901 mvs*) 6902 case $cc_basename in 6903 cxx*) 6904 # FIXME: insert proper C++ library support 6905 _LT_TAGVAR(ld_shlibs, $1)=no 6906 ;; 6907 *) 6908 # FIXME: insert proper C++ library support 6909 _LT_TAGVAR(ld_shlibs, $1)=no 6910 ;; 6911 esac 6912 ;; 6913 6914 netbsd*) 6915 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 6916 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 6917 wlarc= 6918 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6919 _LT_TAGVAR(hardcode_direct, $1)=yes 6920 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6921 fi 6922 # Workaround some broken pre-1.5 toolchains 6923 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 6924 ;; 6925 6926 *nto* | *qnx*) 6927 _LT_TAGVAR(ld_shlibs, $1)=yes 6928 ;; 6929 6930 openbsd2*) 6931 # C++ shared libraries are fairly broken 6932 _LT_TAGVAR(ld_shlibs, $1)=no 6933 ;; 6934 6935 openbsd*) 6936 if test -f /usr/libexec/ld.so; then 6937 _LT_TAGVAR(hardcode_direct, $1)=yes 6938 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6939 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 6940 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 6941 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6942 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 6943 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' 6944 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6945 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6946 fi 6947 output_verbose_link_cmd=echo 6948 else 6949 _LT_TAGVAR(ld_shlibs, $1)=no 6950 fi 6951 ;; 6952 6953 osf3* | osf4* | osf5*) 6954 case $cc_basename in 6955 KCC*) 6956 # Kuck and Associates, Inc. (KAI) C++ Compiler 6957 6958 # KCC will only create a shared library if the output file 6959 # ends with ".so" (or ".sl" for HP-UX), so rename the library 6960 # to its proper name (with version) after linking. 6961 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' 6962 6963 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6964 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6965 6966 # Archives containing C++ object files must be created using 6967 # the KAI C++ compiler. 6968 case $host in 6969 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 6970 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 6971 esac 6972 ;; 6973 RCC*) 6974 # Rational C++ 2.4.1 6975 # FIXME: insert proper C++ library support 6976 _LT_TAGVAR(ld_shlibs, $1)=no 6977 ;; 6978 cxx*) 6979 case $host in 6980 osf3*) 6981 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 6982 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 6983 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6984 ;; 6985 *) 6986 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 6987 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 6988 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 6989 echo "-hidden">> $lib.exp~ 6990 $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 "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~ 6991 $RM $lib.exp' 6992 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 6993 ;; 6994 esac 6995 6996 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6997 6998 # Commands to make compiler produce verbose output that lists 6999 # what "hidden" libraries, object files and flags are used when 7000 # linking a shared library. 7001 # 7002 # There doesn't appear to be a way to prevent this compiler from 7003 # explicitly linking system object files so we need to strip them 7004 # from the output so that they don't get included in the library 7005 # dependencies. 7006 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "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 "X$list" | $Xsed' 7007 ;; 7008 *) 7009 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 7010 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7011 case $host in 7012 osf3*) 7013 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7014 ;; 7015 *) 7016 _LT_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" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7017 ;; 7018 esac 7019 7020 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7021 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7022 7023 # Commands to make compiler produce verbose output that lists 7024 # what "hidden" libraries, object files and flags are used when 7025 # linking a shared library. 7026 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 7027 7028 else 7029 # FIXME: insert proper C++ library support 7030 _LT_TAGVAR(ld_shlibs, $1)=no 7031 fi 7032 ;; 7033 esac 7034 ;; 7035 7036 psos*) 7037 # FIXME: insert proper C++ library support 7038 _LT_TAGVAR(ld_shlibs, $1)=no 7039 ;; 7040 7041 sunos4*) 7042 case $cc_basename in 7043 CC*) 7044 # Sun C++ 4.x 7045 # FIXME: insert proper C++ library support 7046 _LT_TAGVAR(ld_shlibs, $1)=no 7047 ;; 7048 lcc*) 7049 # Lucid 7050 # FIXME: insert proper C++ library support 7051 _LT_TAGVAR(ld_shlibs, $1)=no 7052 ;; 7053 *) 7054 # FIXME: insert proper C++ library support 7055 _LT_TAGVAR(ld_shlibs, $1)=no 7056 ;; 7057 esac 7058 ;; 7059 7060 solaris*) 7061 case $cc_basename in 7062 CC*) 7063 # Sun C++ 4.2, 5.x and Centerline C++ 7064 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 7065 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 7066 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 7067 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7068 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 7069 7070 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7071 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7072 case $host_os in 7073 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 7074 *) 7075 # The compiler driver will combine and reorder linker options, 7076 # but understands `-z linker_flag'. 7077 # Supported since Solaris 2.6 (maybe 2.5.1?) 7078 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 7079 ;; 7080 esac 7081 _LT_TAGVAR(link_all_deplibs, $1)=yes 7082 7083 output_verbose_link_cmd='echo' 7084 7085 # Archives containing C++ object files must be created using 7086 # "CC -xar", where "CC" is the Sun C++ compiler. This is 7087 # necessary to make sure instantiated templates are included 7088 # in the archive. 7089 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 7090 ;; 7091 gcx*) 7092 # Green Hills C++ Compiler 7093 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 7094 7095 # The C++ compiler must be used to create the archive. 7096 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 7097 ;; 7098 *) 7099 # GNU C++ compiler with Solaris linker 7100 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 7101 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 7102 if $CC --version | $GREP -v '^2\.7' > /dev/null; then 7103 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 7104 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7105 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 7106 7107 # Commands to make compiler produce verbose output that lists 7108 # what "hidden" libraries, object files and flags are used when 7109 # linking a shared library. 7110 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 7111 else 7112 # g++ 2.7 appears to require `-G' NOT `-shared' on this 7113 # platform. 7114 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 7115 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7116 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 7117 7118 # Commands to make compiler produce verbose output that lists 7119 # what "hidden" libraries, object files and flags are used when 7120 # linking a shared library. 7121 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 7122 fi 7123 7124 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 7125 case $host_os in 7126 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 7127 *) 7128 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 7129 ;; 7130 esac 7131 fi 7132 ;; 7133 esac 7134 ;; 7135 7136 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 7137 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7138 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7139 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7140 runpath_var='LD_RUN_PATH' 7141 7142 case $cc_basename in 7143 CC*) 7144 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7145 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7146 ;; 7147 *) 7148 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7149 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7150 ;; 7151 esac 7152 ;; 7153 7154 sysv5* | sco3.2v5* | sco5v6*) 7155 # Note: We can NOT use -z defs as we might desire, because we do not 7156 # link with -lc, and that would cause any symbols used from libc to 7157 # always be unresolved, which means just about no library would 7158 # ever link correctly. If we're not using GNU ld we use -z text 7159 # though, which does catch some bad symbols but isn't as heavy-handed 7160 # as -z defs. 7161 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7162 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 7163 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7164 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7165 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 7166 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7167 _LT_TAGVAR(link_all_deplibs, $1)=yes 7168 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 7169 runpath_var='LD_RUN_PATH' 7170 7171 case $cc_basename in 7172 CC*) 7173 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7174 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7175 ;; 7176 *) 7177 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7178 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7179 ;; 7180 esac 7181 ;; 7182 7183 tandem*) 7184 case $cc_basename in 7185 NCC*) 7186 # NonStop-UX NCC 3.20 7187 # FIXME: insert proper C++ library support 7188 _LT_TAGVAR(ld_shlibs, $1)=no 7189 ;; 7190 *) 7191 # FIXME: insert proper C++ library support 7192 _LT_TAGVAR(ld_shlibs, $1)=no 7193 ;; 7194 esac 7195 ;; 7196 7197 vxworks*) 7198 # FIXME: insert proper C++ library support 7199 _LT_TAGVAR(ld_shlibs, $1)=no 7200 ;; 7201 7202 *) 7203 # FIXME: insert proper C++ library support 7204 _LT_TAGVAR(ld_shlibs, $1)=no 7205 ;; 7206 esac 7207 7208 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 7209 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 7210 7211 _LT_TAGVAR(GCC, $1)="$GXX" 7212 _LT_TAGVAR(LD, $1)="$LD" 7213 7214 ## CAVEAT EMPTOR: 7215 ## There is no encapsulation within the following macros, do not change 7216 ## the running order or otherwise move them around unless you know exactly 7217 ## what you are doing... 7218 _LT_SYS_HIDDEN_LIBDEPS($1) 7219 _LT_COMPILER_PIC($1) 7220 _LT_COMPILER_C_O($1) 7221 _LT_COMPILER_FILE_LOCKS($1) 7222 _LT_LINKER_SHLIBS($1) 7223 _LT_SYS_DYNAMIC_LINKER($1) 7224 _LT_LINKER_HARDCODE_LIBPATH($1) 7225 7226 _LT_CONFIG($1) 7227 fi # test -n "$compiler" 7228 7229 CC=$lt_save_CC 7230 LDCXX=$LD 7231 LD=$lt_save_LD 7232 GCC=$lt_save_GCC 7233 with_gnu_ld=$lt_save_with_gnu_ld 7234 lt_cv_path_LDCXX=$lt_cv_path_LD 7235 lt_cv_path_LD=$lt_save_path_LD 7236 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 7237 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 7238fi # test "$_lt_caught_CXX_error" != yes 7239 7240AC_LANG_POP 7241])# _LT_LANG_CXX_CONFIG 7242 7243 7244# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 7245# --------------------------------- 7246# Figure out "hidden" library dependencies from verbose 7247# compiler output when linking a shared library. 7248# Parse the compiler output and extract the necessary 7249# objects, libraries and library flags. 7250m4_defun([_LT_SYS_HIDDEN_LIBDEPS], 7251[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 7252# Dependencies to place before and after the object being linked: 7253_LT_TAGVAR(predep_objects, $1)= 7254_LT_TAGVAR(postdep_objects, $1)= 7255_LT_TAGVAR(predeps, $1)= 7256_LT_TAGVAR(postdeps, $1)= 7257_LT_TAGVAR(compiler_lib_search_path, $1)= 7258 7259dnl we can't use the lt_simple_compile_test_code here, 7260dnl because it contains code intended for an executable, 7261dnl not a library. It's possible we should let each 7262dnl tag define a new lt_????_link_test_code variable, 7263dnl but it's only used here... 7264m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 7265int a; 7266void foo (void) { a = 0; } 7267_LT_EOF 7268], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 7269class Foo 7270{ 7271public: 7272 Foo (void) { a = 0; } 7273private: 7274 int a; 7275}; 7276_LT_EOF 7277], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 7278 subroutine foo 7279 implicit none 7280 integer*4 a 7281 a=0 7282 return 7283 end 7284_LT_EOF 7285], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 7286 subroutine foo 7287 implicit none 7288 integer a 7289 a=0 7290 return 7291 end 7292_LT_EOF 7293], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 7294public class foo { 7295 private int a; 7296 public void bar (void) { 7297 a = 0; 7298 } 7299}; 7300_LT_EOF 7301]) 7302dnl Parse the compiler output and extract the necessary 7303dnl objects, libraries and library flags. 7304if AC_TRY_EVAL(ac_compile); then 7305 # Parse the compiler output and extract the necessary 7306 # objects, libraries and library flags. 7307 7308 # Sentinel used to keep track of whether or not we are before 7309 # the conftest object file. 7310 pre_test_object_deps_done=no 7311 7312 for p in `eval "$output_verbose_link_cmd"`; do 7313 case $p in 7314 7315 -L* | -R* | -l*) 7316 # Some compilers place space between "-{L,R}" and the path. 7317 # Remove the space. 7318 if test $p = "-L" || 7319 test $p = "-R"; then 7320 prev=$p 7321 continue 7322 else 7323 prev= 7324 fi 7325 7326 if test "$pre_test_object_deps_done" = no; then 7327 case $p in 7328 -L* | -R*) 7329 # Internal compiler library paths should come after those 7330 # provided the user. The postdeps already come after the 7331 # user supplied libs so there is no need to process them. 7332 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 7333 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 7334 else 7335 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 7336 fi 7337 ;; 7338 # The "-l" case would never come before the object being 7339 # linked, so don't bother handling this case. 7340 esac 7341 else 7342 if test -z "$_LT_TAGVAR(postdeps, $1)"; then 7343 _LT_TAGVAR(postdeps, $1)="${prev}${p}" 7344 else 7345 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" 7346 fi 7347 fi 7348 ;; 7349 7350 *.$objext) 7351 # This assumes that the test object file only shows up 7352 # once in the compiler output. 7353 if test "$p" = "conftest.$objext"; then 7354 pre_test_object_deps_done=yes 7355 continue 7356 fi 7357 7358 if test "$pre_test_object_deps_done" = no; then 7359 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 7360 _LT_TAGVAR(predep_objects, $1)="$p" 7361 else 7362 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 7363 fi 7364 else 7365 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 7366 _LT_TAGVAR(postdep_objects, $1)="$p" 7367 else 7368 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 7369 fi 7370 fi 7371 ;; 7372 7373 *) ;; # Ignore the rest. 7374 7375 esac 7376 done 7377 7378 # Clean up. 7379 rm -f a.out a.exe 7380else 7381 echo "libtool.m4: error: problem compiling $1 test program" 7382fi 7383 7384$RM -f confest.$objext 7385 7386# PORTME: override above test on systems where it is broken 7387m4_if([$1], [CXX], 7388[case $host_os in 7389interix[[3-9]]*) 7390 # Interix 3.5 installs completely hosed .la files for C++, so rather than 7391 # hack all around it, let's just trust "g++" to DTRT. 7392 _LT_TAGVAR(predep_objects,$1)= 7393 _LT_TAGVAR(postdep_objects,$1)= 7394 _LT_TAGVAR(postdeps,$1)= 7395 ;; 7396 7397linux*) 7398 case `$CC -V 2>&1 | sed 5q` in 7399 *Sun\ C*) 7400 # Sun C++ 5.9 7401 7402 # The more standards-conforming stlport4 library is 7403 # incompatible with the Cstd library. Avoid specifying 7404 # it if it's in CXXFLAGS. Ignore libCrun as 7405 # -library=stlport4 depends on it. 7406 case " $CXX $CXXFLAGS " in 7407 *" -library=stlport4 "*) 7408 solaris_use_stlport4=yes 7409 ;; 7410 esac 7411 7412 if test "$solaris_use_stlport4" != yes; then 7413 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 7414 fi 7415 ;; 7416 esac 7417 ;; 7418 7419solaris*) 7420 case $cc_basename in 7421 CC*) 7422 # The more standards-conforming stlport4 library is 7423 # incompatible with the Cstd library. Avoid specifying 7424 # it if it's in CXXFLAGS. Ignore libCrun as 7425 # -library=stlport4 depends on it. 7426 case " $CXX $CXXFLAGS " in 7427 *" -library=stlport4 "*) 7428 solaris_use_stlport4=yes 7429 ;; 7430 esac 7431 7432 # Adding this requires a known-good setup of shared libraries for 7433 # Sun compiler versions before 5.6, else PIC objects from an old 7434 # archive will be linked into the output, leading to subtle bugs. 7435 if test "$solaris_use_stlport4" != yes; then 7436 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 7437 fi 7438 ;; 7439 esac 7440 ;; 7441esac 7442]) 7443 7444case " $_LT_TAGVAR(postdeps, $1) " in 7445*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 7446esac 7447 _LT_TAGVAR(compiler_lib_search_dirs, $1)= 7448if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 7449 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 7450fi 7451_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 7452 [The directories searched by this compiler when creating a shared library]) 7453_LT_TAGDECL([], [predep_objects], [1], 7454 [Dependencies to place before and after the objects being linked to 7455 create a shared library]) 7456_LT_TAGDECL([], [postdep_objects], [1]) 7457_LT_TAGDECL([], [predeps], [1]) 7458_LT_TAGDECL([], [postdeps], [1]) 7459_LT_TAGDECL([], [compiler_lib_search_path], [1], 7460 [The library search path used internally by the compiler when linking 7461 a shared library]) 7462])# _LT_SYS_HIDDEN_LIBDEPS 7463 7464 7465# _LT_PROG_F77 7466# ------------ 7467# Since AC_PROG_F77 is broken, in that it returns the empty string 7468# if there is no fortran compiler, we have our own version here. 7469m4_defun([_LT_PROG_F77], 7470[ 7471pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes]) 7472AC_PROG_F77 7473if test -z "$F77" || test "X$F77" = "Xno"; then 7474 _lt_disable_F77=yes 7475fi 7476popdef([AC_MSG_ERROR]) 7477])# _LT_PROG_F77 7478 7479dnl aclocal-1.4 backwards compatibility: 7480dnl AC_DEFUN([_LT_PROG_F77], []) 7481 7482 7483# _LT_LANG_F77_CONFIG([TAG]) 7484# -------------------------- 7485# Ensure that the configuration variables for a Fortran 77 compiler are 7486# suitably defined. These variables are subsequently used by _LT_CONFIG 7487# to write the compiler configuration to `libtool'. 7488m4_defun([_LT_LANG_F77_CONFIG], 7489[AC_REQUIRE([_LT_PROG_F77])dnl 7490AC_LANG_PUSH(Fortran 77) 7491 7492_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7493_LT_TAGVAR(allow_undefined_flag, $1)= 7494_LT_TAGVAR(always_export_symbols, $1)=no 7495_LT_TAGVAR(archive_expsym_cmds, $1)= 7496_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7497_LT_TAGVAR(hardcode_direct, $1)=no 7498_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7499_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7500_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7501_LT_TAGVAR(hardcode_libdir_separator, $1)= 7502_LT_TAGVAR(hardcode_minus_L, $1)=no 7503_LT_TAGVAR(hardcode_automatic, $1)=no 7504_LT_TAGVAR(inherit_rpath, $1)=no 7505_LT_TAGVAR(module_cmds, $1)= 7506_LT_TAGVAR(module_expsym_cmds, $1)= 7507_LT_TAGVAR(link_all_deplibs, $1)=unknown 7508_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7509_LT_TAGVAR(no_undefined_flag, $1)= 7510_LT_TAGVAR(whole_archive_flag_spec, $1)= 7511_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7512 7513# Source file extension for f77 test sources. 7514ac_ext=f 7515 7516# Object file extension for compiled f77 test sources. 7517objext=o 7518_LT_TAGVAR(objext, $1)=$objext 7519 7520# No sense in running all these tests if we already determined that 7521# the F77 compiler isn't working. Some variables (like enable_shared) 7522# are currently assumed to apply to all compilers on this platform, 7523# and will be corrupted by setting them based on a non-working compiler. 7524if test "$_lt_disable_F77" != yes; then 7525 # Code to be used in simple compile tests 7526 lt_simple_compile_test_code="\ 7527 subroutine t 7528 return 7529 end 7530" 7531 7532 # Code to be used in simple link tests 7533 lt_simple_link_test_code="\ 7534 program t 7535 end 7536" 7537 7538 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7539 _LT_TAG_COMPILER 7540 7541 # save warnings/boilerplate of simple test code 7542 _LT_COMPILER_BOILERPLATE 7543 _LT_LINKER_BOILERPLATE 7544 7545 # Allow CC to be a program name with arguments. 7546 lt_save_CC="$CC" 7547 lt_save_GCC=$GCC 7548 CC=${F77-"f77"} 7549 compiler=$CC 7550 _LT_TAGVAR(compiler, $1)=$CC 7551 _LT_CC_BASENAME([$compiler]) 7552 GCC=$G77 7553 if test -n "$compiler"; then 7554 AC_MSG_CHECKING([if libtool supports shared libraries]) 7555 AC_MSG_RESULT([$can_build_shared]) 7556 7557 AC_MSG_CHECKING([whether to build shared libraries]) 7558 test "$can_build_shared" = "no" && enable_shared=no 7559 7560 # On AIX, shared libraries and static libraries use the same namespace, and 7561 # are all built from PIC. 7562 case $host_os in 7563 aix3*) 7564 test "$enable_shared" = yes && enable_static=no 7565 if test -n "$RANLIB"; then 7566 archive_cmds="$archive_cmds~\$RANLIB \$lib" 7567 postinstall_cmds='$RANLIB $lib' 7568 fi 7569 ;; 7570 aix[[4-9]]*) 7571 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7572 test "$enable_shared" = yes && enable_static=no 7573 fi 7574 ;; 7575 esac 7576 AC_MSG_RESULT([$enable_shared]) 7577 7578 AC_MSG_CHECKING([whether to build static libraries]) 7579 # Make sure either enable_shared or enable_static is yes. 7580 test "$enable_shared" = yes || enable_static=yes 7581 AC_MSG_RESULT([$enable_static]) 7582 7583 _LT_TAGVAR(GCC, $1)="$G77" 7584 _LT_TAGVAR(LD, $1)="$LD" 7585 7586 ## CAVEAT EMPTOR: 7587 ## There is no encapsulation within the following macros, do not change 7588 ## the running order or otherwise move them around unless you know exactly 7589 ## what you are doing... 7590 _LT_COMPILER_PIC($1) 7591 _LT_COMPILER_C_O($1) 7592 _LT_COMPILER_FILE_LOCKS($1) 7593 _LT_LINKER_SHLIBS($1) 7594 _LT_SYS_DYNAMIC_LINKER($1) 7595 _LT_LINKER_HARDCODE_LIBPATH($1) 7596 7597 _LT_CONFIG($1) 7598 fi # test -n "$compiler" 7599 7600 GCC=$lt_save_GCC 7601 CC="$lt_save_CC" 7602fi # test "$_lt_disable_F77" != yes 7603 7604AC_LANG_POP 7605])# _LT_LANG_F77_CONFIG 7606 7607 7608# _LT_PROG_FC 7609# ----------- 7610# Since AC_PROG_FC is broken, in that it returns the empty string 7611# if there is no fortran compiler, we have our own version here. 7612m4_defun([_LT_PROG_FC], 7613[ 7614pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes]) 7615AC_PROG_FC 7616if test -z "$FC" || test "X$FC" = "Xno"; then 7617 _lt_disable_FC=yes 7618fi 7619popdef([AC_MSG_ERROR]) 7620])# _LT_PROG_FC 7621 7622dnl aclocal-1.4 backwards compatibility: 7623dnl AC_DEFUN([_LT_PROG_FC], []) 7624 7625 7626# _LT_LANG_FC_CONFIG([TAG]) 7627# ------------------------- 7628# Ensure that the configuration variables for a Fortran compiler are 7629# suitably defined. These variables are subsequently used by _LT_CONFIG 7630# to write the compiler configuration to `libtool'. 7631m4_defun([_LT_LANG_FC_CONFIG], 7632[AC_REQUIRE([_LT_PROG_FC])dnl 7633AC_LANG_PUSH(Fortran) 7634 7635_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7636_LT_TAGVAR(allow_undefined_flag, $1)= 7637_LT_TAGVAR(always_export_symbols, $1)=no 7638_LT_TAGVAR(archive_expsym_cmds, $1)= 7639_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7640_LT_TAGVAR(hardcode_direct, $1)=no 7641_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7642_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7643_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7644_LT_TAGVAR(hardcode_libdir_separator, $1)= 7645_LT_TAGVAR(hardcode_minus_L, $1)=no 7646_LT_TAGVAR(hardcode_automatic, $1)=no 7647_LT_TAGVAR(inherit_rpath, $1)=no 7648_LT_TAGVAR(module_cmds, $1)= 7649_LT_TAGVAR(module_expsym_cmds, $1)= 7650_LT_TAGVAR(link_all_deplibs, $1)=unknown 7651_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7652_LT_TAGVAR(no_undefined_flag, $1)= 7653_LT_TAGVAR(whole_archive_flag_spec, $1)= 7654_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7655 7656# Source file extension for fc test sources. 7657ac_ext=${ac_fc_srcext-f} 7658 7659# Object file extension for compiled fc test sources. 7660objext=o 7661_LT_TAGVAR(objext, $1)=$objext 7662 7663# No sense in running all these tests if we already determined that 7664# the FC compiler isn't working. Some variables (like enable_shared) 7665# are currently assumed to apply to all compilers on this platform, 7666# and will be corrupted by setting them based on a non-working compiler. 7667if test "$_lt_disable_FC" != yes; then 7668 # Code to be used in simple compile tests 7669 lt_simple_compile_test_code="\ 7670 subroutine t 7671 return 7672 end 7673" 7674 7675 # Code to be used in simple link tests 7676 lt_simple_link_test_code="\ 7677 program t 7678 end 7679" 7680 7681 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7682 _LT_TAG_COMPILER 7683 7684 # save warnings/boilerplate of simple test code 7685 _LT_COMPILER_BOILERPLATE 7686 _LT_LINKER_BOILERPLATE 7687 7688 # Allow CC to be a program name with arguments. 7689 lt_save_CC="$CC" 7690 lt_save_GCC=$GCC 7691 CC=${FC-"f95"} 7692 compiler=$CC 7693 GCC=$ac_cv_fc_compiler_gnu 7694 7695 _LT_TAGVAR(compiler, $1)=$CC 7696 _LT_CC_BASENAME([$compiler]) 7697 7698 if test -n "$compiler"; then 7699 AC_MSG_CHECKING([if libtool supports shared libraries]) 7700 AC_MSG_RESULT([$can_build_shared]) 7701 7702 AC_MSG_CHECKING([whether to build shared libraries]) 7703 test "$can_build_shared" = "no" && enable_shared=no 7704 7705 # On AIX, shared libraries and static libraries use the same namespace, and 7706 # are all built from PIC. 7707 case $host_os in 7708 aix3*) 7709 test "$enable_shared" = yes && enable_static=no 7710 if test -n "$RANLIB"; then 7711 archive_cmds="$archive_cmds~\$RANLIB \$lib" 7712 postinstall_cmds='$RANLIB $lib' 7713 fi 7714 ;; 7715 aix[[4-9]]*) 7716 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7717 test "$enable_shared" = yes && enable_static=no 7718 fi 7719 ;; 7720 esac 7721 AC_MSG_RESULT([$enable_shared]) 7722 7723 AC_MSG_CHECKING([whether to build static libraries]) 7724 # Make sure either enable_shared or enable_static is yes. 7725 test "$enable_shared" = yes || enable_static=yes 7726 AC_MSG_RESULT([$enable_static]) 7727 7728 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" 7729 _LT_TAGVAR(LD, $1)="$LD" 7730 7731 ## CAVEAT EMPTOR: 7732 ## There is no encapsulation within the following macros, do not change 7733 ## the running order or otherwise move them around unless you know exactly 7734 ## what you are doing... 7735 _LT_SYS_HIDDEN_LIBDEPS($1) 7736 _LT_COMPILER_PIC($1) 7737 _LT_COMPILER_C_O($1) 7738 _LT_COMPILER_FILE_LOCKS($1) 7739 _LT_LINKER_SHLIBS($1) 7740 _LT_SYS_DYNAMIC_LINKER($1) 7741 _LT_LINKER_HARDCODE_LIBPATH($1) 7742 7743 _LT_CONFIG($1) 7744 fi # test -n "$compiler" 7745 7746 GCC=$lt_save_GCC 7747 CC="$lt_save_CC" 7748fi # test "$_lt_disable_FC" != yes 7749 7750AC_LANG_POP 7751])# _LT_LANG_FC_CONFIG 7752 7753 7754# _LT_LANG_GCJ_CONFIG([TAG]) 7755# -------------------------- 7756# Ensure that the configuration variables for the GNU Java Compiler compiler 7757# are suitably defined. These variables are subsequently used by _LT_CONFIG 7758# to write the compiler configuration to `libtool'. 7759m4_defun([_LT_LANG_GCJ_CONFIG], 7760[AC_REQUIRE([LT_PROG_GCJ])dnl 7761AC_LANG_SAVE 7762 7763# Source file extension for Java test sources. 7764ac_ext=java 7765 7766# Object file extension for compiled Java test sources. 7767objext=o 7768_LT_TAGVAR(objext, $1)=$objext 7769 7770# Code to be used in simple compile tests 7771lt_simple_compile_test_code="class foo {}" 7772 7773# Code to be used in simple link tests 7774lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 7775 7776# ltmain only uses $CC for tagged configurations so make sure $CC is set. 7777_LT_TAG_COMPILER 7778 7779# save warnings/boilerplate of simple test code 7780_LT_COMPILER_BOILERPLATE 7781_LT_LINKER_BOILERPLATE 7782 7783# Allow CC to be a program name with arguments. 7784lt_save_CC="$CC" 7785lt_save_GCC=$GCC 7786GCC=yes 7787CC=${GCJ-"gcj"} 7788compiler=$CC 7789_LT_TAGVAR(compiler, $1)=$CC 7790_LT_TAGVAR(LD, $1)="$LD" 7791_LT_CC_BASENAME([$compiler]) 7792 7793# GCJ did not exist at the time GCC didn't implicitly link libc in. 7794_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7795 7796_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7797 7798if test -n "$compiler"; then 7799 _LT_COMPILER_NO_RTTI($1) 7800 _LT_COMPILER_PIC($1) 7801 _LT_COMPILER_C_O($1) 7802 _LT_COMPILER_FILE_LOCKS($1) 7803 _LT_LINKER_SHLIBS($1) 7804 _LT_LINKER_HARDCODE_LIBPATH($1) 7805 7806 _LT_CONFIG($1) 7807fi 7808 7809AC_LANG_RESTORE 7810 7811GCC=$lt_save_GCC 7812CC="$lt_save_CC" 7813])# _LT_LANG_GCJ_CONFIG 7814 7815 7816# _LT_LANG_RC_CONFIG([TAG]) 7817# ------------------------- 7818# Ensure that the configuration variables for the Windows resource compiler 7819# are suitably defined. These variables are subsequently used by _LT_CONFIG 7820# to write the compiler configuration to `libtool'. 7821m4_defun([_LT_LANG_RC_CONFIG], 7822[AC_REQUIRE([LT_PROG_RC])dnl 7823AC_LANG_SAVE 7824 7825# Source file extension for RC test sources. 7826ac_ext=rc 7827 7828# Object file extension for compiled RC test sources. 7829objext=o 7830_LT_TAGVAR(objext, $1)=$objext 7831 7832# Code to be used in simple compile tests 7833lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 7834 7835# Code to be used in simple link tests 7836lt_simple_link_test_code="$lt_simple_compile_test_code" 7837 7838# ltmain only uses $CC for tagged configurations so make sure $CC is set. 7839_LT_TAG_COMPILER 7840 7841# save warnings/boilerplate of simple test code 7842_LT_COMPILER_BOILERPLATE 7843_LT_LINKER_BOILERPLATE 7844 7845# Allow CC to be a program name with arguments. 7846lt_save_CC="$CC" 7847lt_save_GCC=$GCC 7848GCC= 7849CC=${RC-"windres"} 7850compiler=$CC 7851_LT_TAGVAR(compiler, $1)=$CC 7852_LT_CC_BASENAME([$compiler]) 7853_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 7854 7855if test -n "$compiler"; then 7856 : 7857 _LT_CONFIG($1) 7858fi 7859 7860GCC=$lt_save_GCC 7861AC_LANG_RESTORE 7862CC="$lt_save_CC" 7863])# _LT_LANG_RC_CONFIG 7864 7865 7866# LT_PROG_GCJ 7867# ----------- 7868AC_DEFUN([LT_PROG_GCJ], 7869[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 7870 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 7871 [AC_CHECK_TOOL(GCJ, gcj,) 7872 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 7873 AC_SUBST(GCJFLAGS)])])[]dnl 7874]) 7875 7876# Old name: 7877AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 7878dnl aclocal-1.4 backwards compatibility: 7879dnl AC_DEFUN([LT_AC_PROG_GCJ], []) 7880 7881 7882# LT_PROG_RC 7883# ---------- 7884AC_DEFUN([LT_PROG_RC], 7885[AC_CHECK_TOOL(RC, windres,) 7886]) 7887 7888# Old name: 7889AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 7890dnl aclocal-1.4 backwards compatibility: 7891dnl AC_DEFUN([LT_AC_PROG_RC], []) 7892 7893 7894# _LT_DECL_EGREP 7895# -------------- 7896# If we don't have a new enough Autoconf to choose the best grep 7897# available, choose the one first in the user's PATH. 7898m4_defun([_LT_DECL_EGREP], 7899[AC_REQUIRE([AC_PROG_EGREP])dnl 7900AC_REQUIRE([AC_PROG_FGREP])dnl 7901test -z "$GREP" && GREP=grep 7902_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 7903_LT_DECL([], [EGREP], [1], [An ERE matcher]) 7904_LT_DECL([], [FGREP], [1], [A literal string matcher]) 7905dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 7906AC_SUBST([GREP]) 7907]) 7908 7909 7910# _LT_DECL_OBJDUMP 7911# -------------- 7912# If we don't have a new enough Autoconf to choose the best objdump 7913# available, choose the one first in the user's PATH. 7914m4_defun([_LT_DECL_OBJDUMP], 7915[AC_CHECK_TOOL(OBJDUMP, objdump, false) 7916test -z "$OBJDUMP" && OBJDUMP=objdump 7917_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 7918AC_SUBST([OBJDUMP]) 7919]) 7920 7921 7922# _LT_DECL_SED 7923# ------------ 7924# Check for a fully-functional sed program, that truncates 7925# as few characters as possible. Prefer GNU sed if found. 7926m4_defun([_LT_DECL_SED], 7927[AC_PROG_SED 7928test -z "$SED" && SED=sed 7929Xsed="$SED -e 1s/^X//" 7930_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 7931_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 7932 [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 7933])# _LT_DECL_SED 7934 7935m4_ifndef([AC_PROG_SED], [ 7936# NOTE: This macro has been submitted for inclusion into # 7937# GNU Autoconf as AC_PROG_SED. When it is available in # 7938# a released version of Autoconf we should remove this # 7939# macro and use it instead. # 7940 7941m4_defun([AC_PROG_SED], 7942[AC_MSG_CHECKING([for a sed that does not truncate output]) 7943AC_CACHE_VAL(lt_cv_path_SED, 7944[# Loop through the user's path and test for sed and gsed. 7945# Then use that list of sed's as ones to test for truncation. 7946as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7947for as_dir in $PATH 7948do 7949 IFS=$as_save_IFS 7950 test -z "$as_dir" && as_dir=. 7951 for lt_ac_prog in sed gsed; do 7952 for ac_exec_ext in '' $ac_executable_extensions; do 7953 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 7954 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 7955 fi 7956 done 7957 done 7958done 7959IFS=$as_save_IFS 7960lt_ac_max=0 7961lt_ac_count=0 7962# Add /usr/xpg4/bin/sed as it is typically found on Solaris 7963# along with /bin/sed that truncates output. 7964for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 7965 test ! -f $lt_ac_sed && continue 7966 cat /dev/null > conftest.in 7967 lt_ac_count=0 7968 echo $ECHO_N "0123456789$ECHO_C" >conftest.in 7969 # Check for GNU sed and select it if it is found. 7970 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 7971 lt_cv_path_SED=$lt_ac_sed 7972 break 7973 fi 7974 while true; do 7975 cat conftest.in conftest.in >conftest.tmp 7976 mv conftest.tmp conftest.in 7977 cp conftest.in conftest.nl 7978 echo >>conftest.nl 7979 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 7980 cmp -s conftest.out conftest.nl || break 7981 # 10000 chars as input seems more than enough 7982 test $lt_ac_count -gt 10 && break 7983 lt_ac_count=`expr $lt_ac_count + 1` 7984 if test $lt_ac_count -gt $lt_ac_max; then 7985 lt_ac_max=$lt_ac_count 7986 lt_cv_path_SED=$lt_ac_sed 7987 fi 7988 done 7989done 7990]) 7991SED=$lt_cv_path_SED 7992AC_SUBST([SED]) 7993AC_MSG_RESULT([$SED]) 7994])#AC_PROG_SED 7995])#m4_ifndef 7996 7997# Old name: 7998AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 7999dnl aclocal-1.4 backwards compatibility: 8000dnl AC_DEFUN([LT_AC_PROG_SED], []) 8001 8002 8003# _LT_CHECK_SHELL_FEATURES 8004# ------------------------ 8005# Find out whether the shell is Bourne or XSI compatible, 8006# or has some other useful features. 8007m4_defun([_LT_CHECK_SHELL_FEATURES], 8008[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) 8009# Try some XSI features 8010xsi_shell=no 8011( _lt_dummy="a/b/c" 8012 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ 8013 = c,a/b,, \ 8014 && eval 'test $(( 1 + 1 )) -eq 2 \ 8015 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ 8016 && xsi_shell=yes 8017AC_MSG_RESULT([$xsi_shell]) 8018_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) 8019 8020AC_MSG_CHECKING([whether the shell understands "+="]) 8021lt_shell_append=no 8022( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ 8023 >/dev/null 2>&1 \ 8024 && lt_shell_append=yes 8025AC_MSG_RESULT([$lt_shell_append]) 8026_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) 8027 8028if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 8029 lt_unset=unset 8030else 8031 lt_unset=false 8032fi 8033_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 8034 8035# test EBCDIC or ASCII 8036case `echo X|tr X '\101'` in 8037 A) # ASCII based system 8038 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 8039 lt_SP2NL='tr \040 \012' 8040 lt_NL2SP='tr \015\012 \040\040' 8041 ;; 8042 *) # EBCDIC based system 8043 lt_SP2NL='tr \100 \n' 8044 lt_NL2SP='tr \r\n \100\100' 8045 ;; 8046esac 8047_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 8048_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 8049])# _LT_CHECK_SHELL_FEATURES 8050 8051 8052# _LT_PROG_XSI_SHELLFNS 8053# --------------------- 8054# Bourne and XSI compatible variants of some useful shell functions. 8055m4_defun([_LT_PROG_XSI_SHELLFNS], 8056[case $xsi_shell in 8057 yes) 8058 cat << \_LT_EOF >> "$cfgfile" 8059 8060# func_dirname file append nondir_replacement 8061# Compute the dirname of FILE. If nonempty, add APPEND to the result, 8062# otherwise set result to NONDIR_REPLACEMENT. 8063func_dirname () 8064{ 8065 case ${1} in 8066 */*) func_dirname_result="${1%/*}${2}" ;; 8067 * ) func_dirname_result="${3}" ;; 8068 esac 8069} 8070 8071# func_basename file 8072func_basename () 8073{ 8074 func_basename_result="${1##*/}" 8075} 8076 8077# func_dirname_and_basename file append nondir_replacement 8078# perform func_basename and func_dirname in a single function 8079# call: 8080# dirname: Compute the dirname of FILE. If nonempty, 8081# add APPEND to the result, otherwise set result 8082# to NONDIR_REPLACEMENT. 8083# value returned in "$func_dirname_result" 8084# basename: Compute filename of FILE. 8085# value retuned in "$func_basename_result" 8086# Implementation must be kept synchronized with func_dirname 8087# and func_basename. For efficiency, we do not delegate to 8088# those functions but instead duplicate the functionality here. 8089func_dirname_and_basename () 8090{ 8091 case ${1} in 8092 */*) func_dirname_result="${1%/*}${2}" ;; 8093 * ) func_dirname_result="${3}" ;; 8094 esac 8095 func_basename_result="${1##*/}" 8096} 8097 8098# func_stripname prefix suffix name 8099# strip PREFIX and SUFFIX off of NAME. 8100# PREFIX and SUFFIX must not contain globbing or regex special 8101# characters, hashes, percent signs, but SUFFIX may contain a leading 8102# dot (in which case that matches only a dot). 8103func_stripname () 8104{ 8105 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are 8106 # positional parameters, so assign one to ordinary parameter first. 8107 func_stripname_result=${3} 8108 func_stripname_result=${func_stripname_result#"${1}"} 8109 func_stripname_result=${func_stripname_result%"${2}"} 8110} 8111 8112# func_opt_split 8113func_opt_split () 8114{ 8115 func_opt_split_opt=${1%%=*} 8116 func_opt_split_arg=${1#*=} 8117} 8118 8119# func_lo2o object 8120func_lo2o () 8121{ 8122 case ${1} in 8123 *.lo) func_lo2o_result=${1%.lo}.${objext} ;; 8124 *) func_lo2o_result=${1} ;; 8125 esac 8126} 8127 8128# func_xform libobj-or-source 8129func_xform () 8130{ 8131 func_xform_result=${1%.*}.lo 8132} 8133 8134# func_arith arithmetic-term... 8135func_arith () 8136{ 8137 func_arith_result=$(( $[*] )) 8138} 8139 8140# func_len string 8141# STRING may not start with a hyphen. 8142func_len () 8143{ 8144 func_len_result=${#1} 8145} 8146 8147_LT_EOF 8148 ;; 8149 *) # Bourne compatible functions. 8150 cat << \_LT_EOF >> "$cfgfile" 8151 8152# func_dirname file append nondir_replacement 8153# Compute the dirname of FILE. If nonempty, add APPEND to the result, 8154# otherwise set result to NONDIR_REPLACEMENT. 8155func_dirname () 8156{ 8157 # Extract subdirectory from the argument. 8158 func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"` 8159 if test "X$func_dirname_result" = "X${1}"; then 8160 func_dirname_result="${3}" 8161 else 8162 func_dirname_result="$func_dirname_result${2}" 8163 fi 8164} 8165 8166# func_basename file 8167func_basename () 8168{ 8169 func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"` 8170} 8171 8172dnl func_dirname_and_basename 8173dnl A portable version of this function is already defined in general.m4sh 8174dnl so there is no need for it here. 8175 8176# func_stripname prefix suffix name 8177# strip PREFIX and SUFFIX off of NAME. 8178# PREFIX and SUFFIX must not contain globbing or regex special 8179# characters, hashes, percent signs, but SUFFIX may contain a leading 8180# dot (in which case that matches only a dot). 8181# func_strip_suffix prefix name 8182func_stripname () 8183{ 8184 case ${2} in 8185 .*) func_stripname_result=`$ECHO "X${3}" \ 8186 | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;; 8187 *) func_stripname_result=`$ECHO "X${3}" \ 8188 | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;; 8189 esac 8190} 8191 8192# sed scripts: 8193my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' 8194my_sed_long_arg='1s/^-[[^=]]*=//' 8195 8196# func_opt_split 8197func_opt_split () 8198{ 8199 func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"` 8200 func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"` 8201} 8202 8203# func_lo2o object 8204func_lo2o () 8205{ 8206 func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"` 8207} 8208 8209# func_xform libobj-or-source 8210func_xform () 8211{ 8212 func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'` 8213} 8214 8215# func_arith arithmetic-term... 8216func_arith () 8217{ 8218 func_arith_result=`expr "$[@]"` 8219} 8220 8221# func_len string 8222# STRING may not start with a hyphen. 8223func_len () 8224{ 8225 func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len` 8226} 8227 8228_LT_EOF 8229esac 8230 8231case $lt_shell_append in 8232 yes) 8233 cat << \_LT_EOF >> "$cfgfile" 8234 8235# func_append var value 8236# Append VALUE to the end of shell variable VAR. 8237func_append () 8238{ 8239 eval "$[1]+=\$[2]" 8240} 8241_LT_EOF 8242 ;; 8243 *) 8244 cat << \_LT_EOF >> "$cfgfile" 8245 8246# func_append var value 8247# Append VALUE to the end of shell variable VAR. 8248func_append () 8249{ 8250 eval "$[1]=\$$[1]\$[2]" 8251} 8252 8253_LT_EOF 8254 ;; 8255 esac 8256]) 8257 8258# Helper functions for option handling. -*- Autoconf -*- 8259# 8260# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 8261# Written by Gary V. Vaughan, 2004 8262# 8263# This file is free software; the Free Software Foundation gives 8264# unlimited permission to copy and/or distribute it, with or without 8265# modifications, as long as this notice is preserved. 8266 8267# serial 6 ltoptions.m4 8268 8269# This is to help aclocal find these macros, as it can't see m4_define. 8270AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 8271 8272 8273# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 8274# ------------------------------------------ 8275m4_define([_LT_MANGLE_OPTION], 8276[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 8277 8278 8279# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 8280# --------------------------------------- 8281# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 8282# matching handler defined, dispatch to it. Other OPTION-NAMEs are 8283# saved as a flag. 8284m4_define([_LT_SET_OPTION], 8285[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 8286m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 8287 _LT_MANGLE_DEFUN([$1], [$2]), 8288 [m4_warning([Unknown $1 option `$2'])])[]dnl 8289]) 8290 8291 8292# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 8293# ------------------------------------------------------------ 8294# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 8295m4_define([_LT_IF_OPTION], 8296[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 8297 8298 8299# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 8300# ------------------------------------------------------- 8301# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 8302# are set. 8303m4_define([_LT_UNLESS_OPTIONS], 8304[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 8305 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 8306 [m4_define([$0_found])])])[]dnl 8307m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 8308])[]dnl 8309]) 8310 8311 8312# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 8313# ---------------------------------------- 8314# OPTION-LIST is a space-separated list of Libtool options associated 8315# with MACRO-NAME. If any OPTION has a matching handler declared with 8316# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 8317# the unknown option and exit. 8318m4_defun([_LT_SET_OPTIONS], 8319[# Set options 8320m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 8321 [_LT_SET_OPTION([$1], _LT_Option)]) 8322 8323m4_if([$1],[LT_INIT],[ 8324 dnl 8325 dnl Simply set some default values (i.e off) if boolean options were not 8326 dnl specified: 8327 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 8328 ]) 8329 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 8330 ]) 8331 dnl 8332 dnl If no reference was made to various pairs of opposing options, then 8333 dnl we run the default mode handler for the pair. For example, if neither 8334 dnl `shared' nor `disable-shared' was passed, we enable building of shared 8335 dnl archives by default: 8336 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 8337 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 8338 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 8339 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 8340 [_LT_ENABLE_FAST_INSTALL]) 8341 ]) 8342])# _LT_SET_OPTIONS 8343 8344 8345 8346# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 8347# ----------------------------------------- 8348m4_define([_LT_MANGLE_DEFUN], 8349[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 8350 8351 8352# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 8353# ----------------------------------------------- 8354m4_define([LT_OPTION_DEFINE], 8355[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 8356])# LT_OPTION_DEFINE 8357 8358 8359# dlopen 8360# ------ 8361LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 8362]) 8363 8364AU_DEFUN([AC_LIBTOOL_DLOPEN], 8365[_LT_SET_OPTION([LT_INIT], [dlopen]) 8366AC_DIAGNOSE([obsolete], 8367[$0: Remove this warning and the call to _LT_SET_OPTION when you 8368put the `dlopen' option into LT_INIT's first parameter.]) 8369]) 8370 8371dnl aclocal-1.4 backwards compatibility: 8372dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 8373 8374 8375# win32-dll 8376# --------- 8377# Declare package support for building win32 dll's. 8378LT_OPTION_DEFINE([LT_INIT], [win32-dll], 8379[enable_win32_dll=yes 8380 8381case $host in 8382*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*) 8383 AC_CHECK_TOOL(AS, as, false) 8384 AC_CHECK_TOOL(DLLTOOL, dlltool, false) 8385 AC_CHECK_TOOL(OBJDUMP, objdump, false) 8386 ;; 8387esac 8388 8389test -z "$AS" && AS=as 8390_LT_DECL([], [AS], [0], [Assembler program])dnl 8391 8392test -z "$DLLTOOL" && DLLTOOL=dlltool 8393_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl 8394 8395test -z "$OBJDUMP" && OBJDUMP=objdump 8396_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl 8397])# win32-dll 8398 8399AU_DEFUN([AC_LIBTOOL_WIN32_DLL], 8400[AC_REQUIRE([AC_CANONICAL_HOST])dnl 8401_LT_SET_OPTION([LT_INIT], [win32-dll]) 8402AC_DIAGNOSE([obsolete], 8403[$0: Remove this warning and the call to _LT_SET_OPTION when you 8404put the `win32-dll' option into LT_INIT's first parameter.]) 8405]) 8406 8407dnl aclocal-1.4 backwards compatibility: 8408dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 8409 8410 8411# _LT_ENABLE_SHARED([DEFAULT]) 8412# ---------------------------- 8413# implement the --enable-shared flag, and supports the `shared' and 8414# `disable-shared' LT_INIT options. 8415# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 8416m4_define([_LT_ENABLE_SHARED], 8417[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 8418AC_ARG_ENABLE([shared], 8419 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 8420 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 8421 [p=${PACKAGE-default} 8422 case $enableval in 8423 yes) enable_shared=yes ;; 8424 no) enable_shared=no ;; 8425 *) 8426 enable_shared=no 8427 # Look at the argument we got. We use all the common list separators. 8428 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 8429 for pkg in $enableval; do 8430 IFS="$lt_save_ifs" 8431 if test "X$pkg" = "X$p"; then 8432 enable_shared=yes 8433 fi 8434 done 8435 IFS="$lt_save_ifs" 8436 ;; 8437 esac], 8438 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 8439 8440 _LT_DECL([build_libtool_libs], [enable_shared], [0], 8441 [Whether or not to build shared libraries]) 8442])# _LT_ENABLE_SHARED 8443 8444LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 8445LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 8446 8447# Old names: 8448AC_DEFUN([AC_ENABLE_SHARED], 8449[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 8450]) 8451 8452AC_DEFUN([AC_DISABLE_SHARED], 8453[_LT_SET_OPTION([LT_INIT], [disable-shared]) 8454]) 8455 8456AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 8457AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 8458 8459dnl aclocal-1.4 backwards compatibility: 8460dnl AC_DEFUN([AM_ENABLE_SHARED], []) 8461dnl AC_DEFUN([AM_DISABLE_SHARED], []) 8462 8463 8464 8465# _LT_ENABLE_STATIC([DEFAULT]) 8466# ---------------------------- 8467# implement the --enable-static flag, and support the `static' and 8468# `disable-static' LT_INIT options. 8469# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 8470m4_define([_LT_ENABLE_STATIC], 8471[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 8472AC_ARG_ENABLE([static], 8473 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 8474 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 8475 [p=${PACKAGE-default} 8476 case $enableval in 8477 yes) enable_static=yes ;; 8478 no) enable_static=no ;; 8479 *) 8480 enable_static=no 8481 # Look at the argument we got. We use all the common list separators. 8482 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 8483 for pkg in $enableval; do 8484 IFS="$lt_save_ifs" 8485 if test "X$pkg" = "X$p"; then 8486 enable_static=yes 8487 fi 8488 done 8489 IFS="$lt_save_ifs" 8490 ;; 8491 esac], 8492 [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 8493 8494 _LT_DECL([build_old_libs], [enable_static], [0], 8495 [Whether or not to build static libraries]) 8496])# _LT_ENABLE_STATIC 8497 8498LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 8499LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 8500 8501# Old names: 8502AC_DEFUN([AC_ENABLE_STATIC], 8503[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 8504]) 8505 8506AC_DEFUN([AC_DISABLE_STATIC], 8507[_LT_SET_OPTION([LT_INIT], [disable-static]) 8508]) 8509 8510AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 8511AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 8512 8513dnl aclocal-1.4 backwards compatibility: 8514dnl AC_DEFUN([AM_ENABLE_STATIC], []) 8515dnl AC_DEFUN([AM_DISABLE_STATIC], []) 8516 8517 8518 8519# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 8520# ---------------------------------- 8521# implement the --enable-fast-install flag, and support the `fast-install' 8522# and `disable-fast-install' LT_INIT options. 8523# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 8524m4_define([_LT_ENABLE_FAST_INSTALL], 8525[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 8526AC_ARG_ENABLE([fast-install], 8527 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 8528 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 8529 [p=${PACKAGE-default} 8530 case $enableval in 8531 yes) enable_fast_install=yes ;; 8532 no) enable_fast_install=no ;; 8533 *) 8534 enable_fast_install=no 8535 # Look at the argument we got. We use all the common list separators. 8536 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 8537 for pkg in $enableval; do 8538 IFS="$lt_save_ifs" 8539 if test "X$pkg" = "X$p"; then 8540 enable_fast_install=yes 8541 fi 8542 done 8543 IFS="$lt_save_ifs" 8544 ;; 8545 esac], 8546 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 8547 8548_LT_DECL([fast_install], [enable_fast_install], [0], 8549 [Whether or not to optimize for fast installation])dnl 8550])# _LT_ENABLE_FAST_INSTALL 8551 8552LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 8553LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 8554 8555# Old names: 8556AU_DEFUN([AC_ENABLE_FAST_INSTALL], 8557[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 8558AC_DIAGNOSE([obsolete], 8559[$0: Remove this warning and the call to _LT_SET_OPTION when you put 8560the `fast-install' option into LT_INIT's first parameter.]) 8561]) 8562 8563AU_DEFUN([AC_DISABLE_FAST_INSTALL], 8564[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 8565AC_DIAGNOSE([obsolete], 8566[$0: Remove this warning and the call to _LT_SET_OPTION when you put 8567the `disable-fast-install' option into LT_INIT's first parameter.]) 8568]) 8569 8570dnl aclocal-1.4 backwards compatibility: 8571dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 8572dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 8573 8574 8575# _LT_WITH_PIC([MODE]) 8576# -------------------- 8577# implement the --with-pic flag, and support the `pic-only' and `no-pic' 8578# LT_INIT options. 8579# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 8580m4_define([_LT_WITH_PIC], 8581[AC_ARG_WITH([pic], 8582 [AS_HELP_STRING([--with-pic], 8583 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 8584 [pic_mode="$withval"], 8585 [pic_mode=default]) 8586 8587test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) 8588 8589_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 8590])# _LT_WITH_PIC 8591 8592LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 8593LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 8594 8595# Old name: 8596AU_DEFUN([AC_LIBTOOL_PICMODE], 8597[_LT_SET_OPTION([LT_INIT], [pic-only]) 8598AC_DIAGNOSE([obsolete], 8599[$0: Remove this warning and the call to _LT_SET_OPTION when you 8600put the `pic-only' option into LT_INIT's first parameter.]) 8601]) 8602 8603dnl aclocal-1.4 backwards compatibility: 8604dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 8605 8606 8607m4_define([_LTDL_MODE], []) 8608LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 8609 [m4_define([_LTDL_MODE], [nonrecursive])]) 8610LT_OPTION_DEFINE([LTDL_INIT], [recursive], 8611 [m4_define([_LTDL_MODE], [recursive])]) 8612LT_OPTION_DEFINE([LTDL_INIT], [subproject], 8613 [m4_define([_LTDL_MODE], [subproject])]) 8614 8615m4_define([_LTDL_TYPE], []) 8616LT_OPTION_DEFINE([LTDL_INIT], [installable], 8617 [m4_define([_LTDL_TYPE], [installable])]) 8618LT_OPTION_DEFINE([LTDL_INIT], [convenience], 8619 [m4_define([_LTDL_TYPE], [convenience])]) 8620 8621# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 8622# 8623# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 8624# Written by Gary V. Vaughan, 2004 8625# 8626# This file is free software; the Free Software Foundation gives 8627# unlimited permission to copy and/or distribute it, with or without 8628# modifications, as long as this notice is preserved. 8629 8630# serial 6 ltsugar.m4 8631 8632# This is to help aclocal find these macros, as it can't see m4_define. 8633AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 8634 8635 8636# lt_join(SEP, ARG1, [ARG2...]) 8637# ----------------------------- 8638# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 8639# associated separator. 8640# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 8641# versions in m4sugar had bugs. 8642m4_define([lt_join], 8643[m4_if([$#], [1], [], 8644 [$#], [2], [[$2]], 8645 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 8646m4_define([_lt_join], 8647[m4_if([$#$2], [2], [], 8648 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 8649 8650 8651# lt_car(LIST) 8652# lt_cdr(LIST) 8653# ------------ 8654# Manipulate m4 lists. 8655# These macros are necessary as long as will still need to support 8656# Autoconf-2.59 which quotes differently. 8657m4_define([lt_car], [[$1]]) 8658m4_define([lt_cdr], 8659[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 8660 [$#], 1, [], 8661 [m4_dquote(m4_shift($@))])]) 8662m4_define([lt_unquote], $1) 8663 8664 8665# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 8666# ------------------------------------------ 8667# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. 8668# Note that neither SEPARATOR nor STRING are expanded; they are appended 8669# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 8670# No SEPARATOR is output if MACRO-NAME was previously undefined (different 8671# than defined and empty). 8672# 8673# This macro is needed until we can rely on Autoconf 2.62, since earlier 8674# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 8675m4_define([lt_append], 8676[m4_define([$1], 8677 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 8678 8679 8680 8681# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 8682# ---------------------------------------------------------- 8683# Produce a SEP delimited list of all paired combinations of elements of 8684# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 8685# has the form PREFIXmINFIXSUFFIXn. 8686# Needed until we can rely on m4_combine added in Autoconf 2.62. 8687m4_define([lt_combine], 8688[m4_if(m4_eval([$# > 3]), [1], 8689 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 8690[[m4_foreach([_Lt_prefix], [$2], 8691 [m4_foreach([_Lt_suffix], 8692 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 8693 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 8694 8695 8696# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 8697# ----------------------------------------------------------------------- 8698# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 8699# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 8700m4_define([lt_if_append_uniq], 8701[m4_ifdef([$1], 8702 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 8703 [lt_append([$1], [$2], [$3])$4], 8704 [$5])], 8705 [lt_append([$1], [$2], [$3])$4])]) 8706 8707 8708# lt_dict_add(DICT, KEY, VALUE) 8709# ----------------------------- 8710m4_define([lt_dict_add], 8711[m4_define([$1($2)], [$3])]) 8712 8713 8714# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 8715# -------------------------------------------- 8716m4_define([lt_dict_add_subkey], 8717[m4_define([$1($2:$3)], [$4])]) 8718 8719 8720# lt_dict_fetch(DICT, KEY, [SUBKEY]) 8721# ---------------------------------- 8722m4_define([lt_dict_fetch], 8723[m4_ifval([$3], 8724 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 8725 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 8726 8727 8728# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 8729# ----------------------------------------------------------------- 8730m4_define([lt_if_dict_fetch], 8731[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 8732 [$5], 8733 [$6])]) 8734 8735 8736# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 8737# -------------------------------------------------------------- 8738m4_define([lt_dict_filter], 8739[m4_if([$5], [], [], 8740 [lt_join(m4_quote(m4_default([$4], [[, ]])), 8741 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 8742 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 8743]) 8744 8745# ltversion.m4 -- version numbers -*- Autoconf -*- 8746# 8747# Copyright (C) 2004 Free Software Foundation, Inc. 8748# Written by Scott James Remnant, 2004 8749# 8750# This file is free software; the Free Software Foundation gives 8751# unlimited permission to copy and/or distribute it, with or without 8752# modifications, as long as this notice is preserved. 8753 8754# Generated from ltversion.in. 8755 8756# serial 3012 ltversion.m4 8757# This file is part of GNU Libtool 8758 8759m4_define([LT_PACKAGE_VERSION], [2.2.6]) 8760m4_define([LT_PACKAGE_REVISION], [1.3012]) 8761 8762AC_DEFUN([LTVERSION_VERSION], 8763[macro_version='2.2.6' 8764macro_revision='1.3012' 8765_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 8766_LT_DECL(, macro_revision, 0) 8767]) 8768 8769# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 8770# 8771# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. 8772# Written by Scott James Remnant, 2004. 8773# 8774# This file is free software; the Free Software Foundation gives 8775# unlimited permission to copy and/or distribute it, with or without 8776# modifications, as long as this notice is preserved. 8777 8778# serial 4 lt~obsolete.m4 8779 8780# These exist entirely to fool aclocal when bootstrapping libtool. 8781# 8782# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) 8783# which have later been changed to m4_define as they aren't part of the 8784# exported API, or moved to Autoconf or Automake where they belong. 8785# 8786# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 8787# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 8788# using a macro with the same name in our local m4/libtool.m4 it'll 8789# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 8790# and doesn't know about Autoconf macros at all.) 8791# 8792# So we provide this file, which has a silly filename so it's always 8793# included after everything else. This provides aclocal with the 8794# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 8795# because those macros already exist, or will be overwritten later. 8796# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 8797# 8798# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 8799# Yes, that means every name once taken will need to remain here until 8800# we give up compatibility with versions before 1.7, at which point 8801# we need to keep only those names which we still refer to. 8802 8803# This is to help aclocal find these macros, as it can't see m4_define. 8804AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 8805 8806m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 8807m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 8808m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 8809m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 8810m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 8811m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 8812m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 8813m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 8814m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 8815m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 8816m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 8817m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 8818m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 8819m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 8820m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 8821m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 8822m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 8823m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 8824m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 8825m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 8826m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 8827m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 8828m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 8829m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 8830m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 8831m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 8832m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 8833m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 8834m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 8835m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 8836m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 8837m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 8838m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 8839m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 8840m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 8841m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 8842m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 8843m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 8844m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 8845m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 8846m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 8847m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 8848m4_ifndef([AC_LIBTOOL_RC], [AC_DEFUN([AC_LIBTOOL_RC])]) 8849m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 8850m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 8851m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 8852m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 8853m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 8854m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 8855m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 8856m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 8857m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 8858m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 8859m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 8860m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 8861 8862# nls.m4 serial 3 (gettext-0.15) 8863dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc. 8864dnl This file is free software; the Free Software Foundation 8865dnl gives unlimited permission to copy and/or distribute it, 8866dnl with or without modifications, as long as this notice is preserved. 8867dnl 8868dnl This file can can be used in projects which are not available under 8869dnl the GNU General Public License or the GNU Library General Public 8870dnl License but which still want to provide support for the GNU gettext 8871dnl functionality. 8872dnl Please note that the actual code of the GNU gettext library is covered 8873dnl by the GNU Library General Public License, and the rest of the GNU 8874dnl gettext package package is covered by the GNU General Public License. 8875dnl They are *not* in the public domain. 8876 8877dnl Authors: 8878dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000. 8879dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003. 8880 8881AC_PREREQ(2.50) 8882 8883AC_DEFUN([AM_NLS], 8884[ 8885 AC_MSG_CHECKING([whether NLS is requested]) 8886 dnl Default is enabled NLS 8887 AC_ARG_ENABLE(nls, 8888 [ --disable-nls do not use Native Language Support], 8889 USE_NLS=$enableval, USE_NLS=yes) 8890 AC_MSG_RESULT($USE_NLS) 8891 AC_SUBST(USE_NLS) 8892]) 8893 8894# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 8895# 8896# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 8897# 8898# This program is free software; you can redistribute it and/or modify 8899# it under the terms of the GNU General Public License as published by 8900# the Free Software Foundation; either version 2 of the License, or 8901# (at your option) any later version. 8902# 8903# This program is distributed in the hope that it will be useful, but 8904# WITHOUT ANY WARRANTY; without even the implied warranty of 8905# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 8906# General Public License for more details. 8907# 8908# You should have received a copy of the GNU General Public License 8909# along with this program; if not, write to the Free Software 8910# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 8911# 8912# As a special exception to the GNU General Public License, if you 8913# distribute this file as part of a program that contains a 8914# configuration script generated by Autoconf, you may include it under 8915# the same distribution terms that you use for the rest of that program. 8916 8917# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 8918# ---------------------------------- 8919AC_DEFUN([PKG_PROG_PKG_CONFIG], 8920[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 8921m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) 8922AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl 8923if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 8924 AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 8925fi 8926if test -n "$PKG_CONFIG"; then 8927 _pkg_min_version=m4_default([$1], [0.9.0]) 8928 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 8929 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 8930 AC_MSG_RESULT([yes]) 8931 else 8932 AC_MSG_RESULT([no]) 8933 PKG_CONFIG="" 8934 fi 8935 8936fi[]dnl 8937])# PKG_PROG_PKG_CONFIG 8938 8939# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 8940# 8941# Check to see whether a particular set of modules exists. Similar 8942# to PKG_CHECK_MODULES(), but does not set variables or print errors. 8943# 8944# 8945# Similar to PKG_CHECK_MODULES, make sure that the first instance of 8946# this or PKG_CHECK_MODULES is called, or make sure to call 8947# PKG_CHECK_EXISTS manually 8948# -------------------------------------------------------------- 8949AC_DEFUN([PKG_CHECK_EXISTS], 8950[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 8951if test -n "$PKG_CONFIG" && \ 8952 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 8953 m4_ifval([$2], [$2], [:]) 8954m4_ifvaln([$3], [else 8955 $3])dnl 8956fi]) 8957 8958 8959# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 8960# --------------------------------------------- 8961m4_define([_PKG_CONFIG], 8962[if test -n "$PKG_CONFIG"; then 8963 if test -n "$$1"; then 8964 pkg_cv_[]$1="$$1" 8965 else 8966 PKG_CHECK_EXISTS([$3], 8967 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], 8968 [pkg_failed=yes]) 8969 fi 8970else 8971 pkg_failed=untried 8972fi[]dnl 8973])# _PKG_CONFIG 8974 8975# _PKG_SHORT_ERRORS_SUPPORTED 8976# ----------------------------- 8977AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 8978[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 8979if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 8980 _pkg_short_errors_supported=yes 8981else 8982 _pkg_short_errors_supported=no 8983fi[]dnl 8984])# _PKG_SHORT_ERRORS_SUPPORTED 8985 8986 8987# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 8988# [ACTION-IF-NOT-FOUND]) 8989# 8990# 8991# Note that if there is a possibility the first call to 8992# PKG_CHECK_MODULES might not happen, you should be sure to include an 8993# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 8994# 8995# 8996# -------------------------------------------------------------- 8997AC_DEFUN([PKG_CHECK_MODULES], 8998[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 8999AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 9000AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 9001 9002pkg_failed=no 9003AC_MSG_CHECKING([for $1]) 9004 9005_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 9006_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 9007 9008m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 9009and $1[]_LIBS to avoid the need to call pkg-config. 9010See the pkg-config man page for more details.]) 9011 9012if test $pkg_failed = yes; then 9013 _PKG_SHORT_ERRORS_SUPPORTED 9014 if test $_pkg_short_errors_supported = yes; then 9015 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$2"` 9016 else 9017 $1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"` 9018 fi 9019 # Put the nasty error message in config.log where it belongs 9020 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 9021 9022 ifelse([$4], , [AC_MSG_ERROR(dnl 9023[Package requirements ($2) were not met: 9024 9025$$1_PKG_ERRORS 9026 9027Consider adjusting the PKG_CONFIG_PATH environment variable if you 9028installed software in a non-standard prefix. 9029 9030_PKG_TEXT 9031])], 9032 [AC_MSG_RESULT([no]) 9033 $4]) 9034elif test $pkg_failed = untried; then 9035 ifelse([$4], , [AC_MSG_FAILURE(dnl 9036[The pkg-config script could not be found or is too old. Make sure it 9037is in your PATH or set the PKG_CONFIG environment variable to the full 9038path to pkg-config. 9039 9040_PKG_TEXT 9041 9042To get pkg-config, see <http://pkg-config.freedesktop.org/>.])], 9043 [$4]) 9044else 9045 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 9046 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 9047 AC_MSG_RESULT([yes]) 9048 ifelse([$3], , :, [$3]) 9049fi[]dnl 9050])# PKG_CHECK_MODULES 9051 9052# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. 9053# 9054# This file is free software; the Free Software Foundation 9055# gives unlimited permission to copy and/or distribute it, 9056# with or without modifications, as long as this notice is preserved. 9057 9058# AM_AUTOMAKE_VERSION(VERSION) 9059# ---------------------------- 9060# Automake X.Y traces this macro to ensure aclocal.m4 has been 9061# generated from the m4 files accompanying Automake X.Y. 9062# (This private macro should not be called outside this file.) 9063AC_DEFUN([AM_AUTOMAKE_VERSION], 9064[am__api_version='1.10' 9065dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 9066dnl require some minimum version. Point them to the right macro. 9067m4_if([$1], [1.10.2], [], 9068 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 9069]) 9070 9071# _AM_AUTOCONF_VERSION(VERSION) 9072# ----------------------------- 9073# aclocal traces this macro to find the Autoconf version. 9074# This is a private macro too. Using m4_define simplifies 9075# the logic in aclocal, which can simply ignore this definition. 9076m4_define([_AM_AUTOCONF_VERSION], []) 9077 9078# AM_SET_CURRENT_AUTOMAKE_VERSION 9079# ------------------------------- 9080# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 9081# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 9082AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 9083[AM_AUTOMAKE_VERSION([1.10.2])dnl 9084m4_ifndef([AC_AUTOCONF_VERSION], 9085 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 9086_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 9087 9088# AM_AUX_DIR_EXPAND -*- Autoconf -*- 9089 9090# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 9091# 9092# This file is free software; the Free Software Foundation 9093# gives unlimited permission to copy and/or distribute it, 9094# with or without modifications, as long as this notice is preserved. 9095 9096# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 9097# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 9098# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 9099# 9100# Of course, Automake must honor this variable whenever it calls a 9101# tool from the auxiliary directory. The problem is that $srcdir (and 9102# therefore $ac_aux_dir as well) can be either absolute or relative, 9103# depending on how configure is run. This is pretty annoying, since 9104# it makes $ac_aux_dir quite unusable in subdirectories: in the top 9105# source directory, any form will work fine, but in subdirectories a 9106# relative path needs to be adjusted first. 9107# 9108# $ac_aux_dir/missing 9109# fails when called from a subdirectory if $ac_aux_dir is relative 9110# $top_srcdir/$ac_aux_dir/missing 9111# fails if $ac_aux_dir is absolute, 9112# fails when called from a subdirectory in a VPATH build with 9113# a relative $ac_aux_dir 9114# 9115# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 9116# are both prefixed by $srcdir. In an in-source build this is usually 9117# harmless because $srcdir is `.', but things will broke when you 9118# start a VPATH build or use an absolute $srcdir. 9119# 9120# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 9121# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 9122# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 9123# and then we would define $MISSING as 9124# MISSING="\${SHELL} $am_aux_dir/missing" 9125# This will work as long as MISSING is not called from configure, because 9126# unfortunately $(top_srcdir) has no meaning in configure. 9127# However there are other variables, like CC, which are often used in 9128# configure, and could therefore not use this "fixed" $ac_aux_dir. 9129# 9130# Another solution, used here, is to always expand $ac_aux_dir to an 9131# absolute PATH. The drawback is that using absolute paths prevent a 9132# configured tree to be moved without reconfiguration. 9133 9134AC_DEFUN([AM_AUX_DIR_EXPAND], 9135[dnl Rely on autoconf to set up CDPATH properly. 9136AC_PREREQ([2.50])dnl 9137# expand $ac_aux_dir to an absolute path 9138am_aux_dir=`cd $ac_aux_dir && pwd` 9139]) 9140 9141# AM_CONDITIONAL -*- Autoconf -*- 9142 9143# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006 9144# Free Software Foundation, Inc. 9145# 9146# This file is free software; the Free Software Foundation 9147# gives unlimited permission to copy and/or distribute it, 9148# with or without modifications, as long as this notice is preserved. 9149 9150# serial 8 9151 9152# AM_CONDITIONAL(NAME, SHELL-CONDITION) 9153# ------------------------------------- 9154# Define a conditional. 9155AC_DEFUN([AM_CONDITIONAL], 9156[AC_PREREQ(2.52)dnl 9157 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 9158 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 9159AC_SUBST([$1_TRUE])dnl 9160AC_SUBST([$1_FALSE])dnl 9161_AM_SUBST_NOTMAKE([$1_TRUE])dnl 9162_AM_SUBST_NOTMAKE([$1_FALSE])dnl 9163if $2; then 9164 $1_TRUE= 9165 $1_FALSE='#' 9166else 9167 $1_TRUE='#' 9168 $1_FALSE= 9169fi 9170AC_CONFIG_COMMANDS_PRE( 9171[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 9172 AC_MSG_ERROR([[conditional "$1" was never defined. 9173Usually this means the macro was only invoked conditionally.]]) 9174fi])]) 9175 9176# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 9177# Free Software Foundation, Inc. 9178# 9179# This file is free software; the Free Software Foundation 9180# gives unlimited permission to copy and/or distribute it, 9181# with or without modifications, as long as this notice is preserved. 9182 9183# serial 9 9184 9185# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 9186# written in clear, in which case automake, when reading aclocal.m4, 9187# will think it sees a *use*, and therefore will trigger all it's 9188# C support machinery. Also note that it means that autoscan, seeing 9189# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 9190 9191 9192# _AM_DEPENDENCIES(NAME) 9193# ---------------------- 9194# See how the compiler implements dependency checking. 9195# NAME is "CC", "CXX", "GCJ", or "OBJC". 9196# We try a few techniques and use that to set a single cache variable. 9197# 9198# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 9199# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 9200# dependency, and given that the user is not expected to run this macro, 9201# just rely on AC_PROG_CC. 9202AC_DEFUN([_AM_DEPENDENCIES], 9203[AC_REQUIRE([AM_SET_DEPDIR])dnl 9204AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 9205AC_REQUIRE([AM_MAKE_INCLUDE])dnl 9206AC_REQUIRE([AM_DEP_TRACK])dnl 9207 9208ifelse([$1], CC, [depcc="$CC" am_compiler_list=], 9209 [$1], CXX, [depcc="$CXX" am_compiler_list=], 9210 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 9211 [$1], UPC, [depcc="$UPC" am_compiler_list=], 9212 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 9213 [depcc="$$1" am_compiler_list=]) 9214 9215AC_CACHE_CHECK([dependency style of $depcc], 9216 [am_cv_$1_dependencies_compiler_type], 9217[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 9218 # We make a subdir and do the tests there. Otherwise we can end up 9219 # making bogus files that we don't know about and never remove. For 9220 # instance it was reported that on HP-UX the gcc test will end up 9221 # making a dummy file named `D' -- because `-MD' means `put the output 9222 # in D'. 9223 mkdir conftest.dir 9224 # Copy depcomp to subdir because otherwise we won't find it if we're 9225 # using a relative directory. 9226 cp "$am_depcomp" conftest.dir 9227 cd conftest.dir 9228 # We will build objects and dependencies in a subdirectory because 9229 # it helps to detect inapplicable dependency modes. For instance 9230 # both Tru64's cc and ICC support -MD to output dependencies as a 9231 # side effect of compilation, but ICC will put the dependencies in 9232 # the current directory while Tru64 will put them in the object 9233 # directory. 9234 mkdir sub 9235 9236 am_cv_$1_dependencies_compiler_type=none 9237 if test "$am_compiler_list" = ""; then 9238 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 9239 fi 9240 for depmode in $am_compiler_list; do 9241 # Setup a source with many dependencies, because some compilers 9242 # like to wrap large dependency lists on column 80 (with \), and 9243 # we should not choose a depcomp mode which is confused by this. 9244 # 9245 # We need to recreate these files for each test, as the compiler may 9246 # overwrite some of them when testing with obscure command lines. 9247 # This happens at least with the AIX C compiler. 9248 : > sub/conftest.c 9249 for i in 1 2 3 4 5 6; do 9250 echo '#include "conftst'$i'.h"' >> sub/conftest.c 9251 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with 9252 # Solaris 8's {/usr,}/bin/sh. 9253 touch sub/conftst$i.h 9254 done 9255 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 9256 9257 case $depmode in 9258 nosideeffect) 9259 # after this tag, mechanisms are not by side-effect, so they'll 9260 # only be used when explicitly requested 9261 if test "x$enable_dependency_tracking" = xyes; then 9262 continue 9263 else 9264 break 9265 fi 9266 ;; 9267 none) break ;; 9268 esac 9269 # We check with `-c' and `-o' for the sake of the "dashmstdout" 9270 # mode. It turns out that the SunPro C++ compiler does not properly 9271 # handle `-M -o', and we need to detect this. 9272 if depmode=$depmode \ 9273 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ 9274 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 9275 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ 9276 >/dev/null 2>conftest.err && 9277 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 9278 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 9279 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && 9280 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 9281 # icc doesn't choke on unknown options, it will just issue warnings 9282 # or remarks (even with -Werror). So we grep stderr for any message 9283 # that says an option was ignored or not supported. 9284 # When given -MP, icc 7.0 and 7.1 complain thusly: 9285 # icc: Command line warning: ignoring option '-M'; no argument required 9286 # The diagnosis changed in icc 8.0: 9287 # icc: Command line remark: option '-MP' not supported 9288 if (grep 'ignoring option' conftest.err || 9289 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 9290 am_cv_$1_dependencies_compiler_type=$depmode 9291 break 9292 fi 9293 fi 9294 done 9295 9296 cd .. 9297 rm -rf conftest.dir 9298else 9299 am_cv_$1_dependencies_compiler_type=none 9300fi 9301]) 9302AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 9303AM_CONDITIONAL([am__fastdep$1], [ 9304 test "x$enable_dependency_tracking" != xno \ 9305 && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 9306]) 9307 9308 9309# AM_SET_DEPDIR 9310# ------------- 9311# Choose a directory name for dependency files. 9312# This macro is AC_REQUIREd in _AM_DEPENDENCIES 9313AC_DEFUN([AM_SET_DEPDIR], 9314[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 9315AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 9316]) 9317 9318 9319# AM_DEP_TRACK 9320# ------------ 9321AC_DEFUN([AM_DEP_TRACK], 9322[AC_ARG_ENABLE(dependency-tracking, 9323[ --disable-dependency-tracking speeds up one-time build 9324 --enable-dependency-tracking do not reject slow dependency extractors]) 9325if test "x$enable_dependency_tracking" != xno; then 9326 am_depcomp="$ac_aux_dir/depcomp" 9327 AMDEPBACKSLASH='\' 9328fi 9329AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 9330AC_SUBST([AMDEPBACKSLASH])dnl 9331_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 9332]) 9333 9334# Generate code to set up dependency tracking. -*- Autoconf -*- 9335 9336# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 9337# Free Software Foundation, Inc. 9338# 9339# This file is free software; the Free Software Foundation 9340# gives unlimited permission to copy and/or distribute it, 9341# with or without modifications, as long as this notice is preserved. 9342 9343#serial 4 9344 9345# _AM_OUTPUT_DEPENDENCY_COMMANDS 9346# ------------------------------ 9347AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 9348[# Autoconf 2.62 quotes --file arguments for eval, but not when files 9349# are listed without --file. Let's play safe and only enable the eval 9350# if we detect the quoting. 9351case $CONFIG_FILES in 9352*\'*) eval set x "$CONFIG_FILES" ;; 9353*) set x $CONFIG_FILES ;; 9354esac 9355shift 9356for mf 9357do 9358 # Strip MF so we end up with the name of the file. 9359 mf=`echo "$mf" | sed -e 's/:.*$//'` 9360 # Check whether this is an Automake generated Makefile or not. 9361 # We used to match only the files named `Makefile.in', but 9362 # some people rename them; so instead we look at the file content. 9363 # Grep'ing the first line is not enough: some people post-process 9364 # each Makefile.in and add a new line on top of each file to say so. 9365 # Grep'ing the whole file is not good either: AIX grep has a line 9366 # limit of 2048, but all sed's we know have understand at least 4000. 9367 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then 9368 dirpart=`AS_DIRNAME("$mf")` 9369 else 9370 continue 9371 fi 9372 # Extract the definition of DEPDIR, am__include, and am__quote 9373 # from the Makefile without running `make'. 9374 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 9375 test -z "$DEPDIR" && continue 9376 am__include=`sed -n 's/^am__include = //p' < "$mf"` 9377 test -z "am__include" && continue 9378 am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 9379 # When using ansi2knr, U may be empty or an underscore; expand it 9380 U=`sed -n 's/^U = //p' < "$mf"` 9381 # Find all dependency output files, they are included files with 9382 # $(DEPDIR) in their names. We invoke sed twice because it is the 9383 # simplest approach to changing $(DEPDIR) to its actual value in the 9384 # expansion. 9385 for file in `sed -n " 9386 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 9387 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 9388 # Make sure the directory exists. 9389 test -f "$dirpart/$file" && continue 9390 fdir=`AS_DIRNAME(["$file"])` 9391 AS_MKDIR_P([$dirpart/$fdir]) 9392 # echo "creating $dirpart/$file" 9393 echo '# dummy' > "$dirpart/$file" 9394 done 9395done 9396])# _AM_OUTPUT_DEPENDENCY_COMMANDS 9397 9398 9399# AM_OUTPUT_DEPENDENCY_COMMANDS 9400# ----------------------------- 9401# This macro should only be invoked once -- use via AC_REQUIRE. 9402# 9403# This code is only required when automatic dependency tracking 9404# is enabled. FIXME. This creates each `.P' file that we will 9405# need in order to bootstrap the dependency handling code. 9406AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 9407[AC_CONFIG_COMMANDS([depfiles], 9408 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 9409 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 9410]) 9411 9412# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 9413# Free Software Foundation, Inc. 9414# 9415# This file is free software; the Free Software Foundation 9416# gives unlimited permission to copy and/or distribute it, 9417# with or without modifications, as long as this notice is preserved. 9418 9419# serial 8 9420 9421# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. 9422AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) 9423 9424# Do all the work for Automake. -*- Autoconf -*- 9425 9426# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 9427# 2005, 2006, 2008 Free Software Foundation, Inc. 9428# 9429# This file is free software; the Free Software Foundation 9430# gives unlimited permission to copy and/or distribute it, 9431# with or without modifications, as long as this notice is preserved. 9432 9433# serial 13 9434 9435# This macro actually does too much. Some checks are only needed if 9436# your package does certain things. But this isn't really a big deal. 9437 9438# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 9439# AM_INIT_AUTOMAKE([OPTIONS]) 9440# ----------------------------------------------- 9441# The call with PACKAGE and VERSION arguments is the old style 9442# call (pre autoconf-2.50), which is being phased out. PACKAGE 9443# and VERSION should now be passed to AC_INIT and removed from 9444# the call to AM_INIT_AUTOMAKE. 9445# We support both call styles for the transition. After 9446# the next Automake release, Autoconf can make the AC_INIT 9447# arguments mandatory, and then we can depend on a new Autoconf 9448# release and drop the old call support. 9449AC_DEFUN([AM_INIT_AUTOMAKE], 9450[AC_PREREQ([2.60])dnl 9451dnl Autoconf wants to disallow AM_ names. We explicitly allow 9452dnl the ones we care about. 9453m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 9454AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 9455AC_REQUIRE([AC_PROG_INSTALL])dnl 9456if test "`cd $srcdir && pwd`" != "`pwd`"; then 9457 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 9458 # is not polluted with repeated "-I." 9459 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 9460 # test to see if srcdir already configured 9461 if test -f $srcdir/config.status; then 9462 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 9463 fi 9464fi 9465 9466# test whether we have cygpath 9467if test -z "$CYGPATH_W"; then 9468 if (cygpath --version) >/dev/null 2>/dev/null; then 9469 CYGPATH_W='cygpath -w' 9470 else 9471 CYGPATH_W=echo 9472 fi 9473fi 9474AC_SUBST([CYGPATH_W]) 9475 9476# Define the identity of the package. 9477dnl Distinguish between old-style and new-style calls. 9478m4_ifval([$2], 9479[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 9480 AC_SUBST([PACKAGE], [$1])dnl 9481 AC_SUBST([VERSION], [$2])], 9482[_AM_SET_OPTIONS([$1])dnl 9483dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 9484m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 9485 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 9486 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 9487 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 9488 9489_AM_IF_OPTION([no-define],, 9490[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 9491 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 9492 9493# Some tools Automake needs. 9494AC_REQUIRE([AM_SANITY_CHECK])dnl 9495AC_REQUIRE([AC_ARG_PROGRAM])dnl 9496AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 9497AM_MISSING_PROG(AUTOCONF, autoconf) 9498AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 9499AM_MISSING_PROG(AUTOHEADER, autoheader) 9500AM_MISSING_PROG(MAKEINFO, makeinfo) 9501AM_PROG_INSTALL_SH 9502AM_PROG_INSTALL_STRIP 9503AC_REQUIRE([AM_PROG_MKDIR_P])dnl 9504# We need awk for the "check" target. The system "awk" is bad on 9505# some platforms. 9506AC_REQUIRE([AC_PROG_AWK])dnl 9507AC_REQUIRE([AC_PROG_MAKE_SET])dnl 9508AC_REQUIRE([AM_SET_LEADING_DOT])dnl 9509_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 9510 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 9511 [_AM_PROG_TAR([v7])])]) 9512_AM_IF_OPTION([no-dependencies],, 9513[AC_PROVIDE_IFELSE([AC_PROG_CC], 9514 [_AM_DEPENDENCIES(CC)], 9515 [define([AC_PROG_CC], 9516 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 9517AC_PROVIDE_IFELSE([AC_PROG_CXX], 9518 [_AM_DEPENDENCIES(CXX)], 9519 [define([AC_PROG_CXX], 9520 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 9521AC_PROVIDE_IFELSE([AC_PROG_OBJC], 9522 [_AM_DEPENDENCIES(OBJC)], 9523 [define([AC_PROG_OBJC], 9524 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 9525]) 9526]) 9527 9528 9529# When config.status generates a header, we must update the stamp-h file. 9530# This file resides in the same directory as the config header 9531# that is generated. The stamp files are numbered to have different names. 9532 9533# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 9534# loop where config.status creates the headers, so we can generate 9535# our stamp files there. 9536AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 9537[# Compute $1's index in $config_headers. 9538_am_arg=$1 9539_am_stamp_count=1 9540for _am_header in $config_headers :; do 9541 case $_am_header in 9542 $_am_arg | $_am_arg:* ) 9543 break ;; 9544 * ) 9545 _am_stamp_count=`expr $_am_stamp_count + 1` ;; 9546 esac 9547done 9548echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 9549 9550# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 9551# 9552# This file is free software; the Free Software Foundation 9553# gives unlimited permission to copy and/or distribute it, 9554# with or without modifications, as long as this notice is preserved. 9555 9556# AM_PROG_INSTALL_SH 9557# ------------------ 9558# Define $install_sh. 9559AC_DEFUN([AM_PROG_INSTALL_SH], 9560[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 9561install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"} 9562AC_SUBST(install_sh)]) 9563 9564# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 9565# 9566# This file is free software; the Free Software Foundation 9567# gives unlimited permission to copy and/or distribute it, 9568# with or without modifications, as long as this notice is preserved. 9569 9570# serial 2 9571 9572# Check whether the underlying file-system supports filenames 9573# with a leading dot. For instance MS-DOS doesn't. 9574AC_DEFUN([AM_SET_LEADING_DOT], 9575[rm -rf .tst 2>/dev/null 9576mkdir .tst 2>/dev/null 9577if test -d .tst; then 9578 am__leading_dot=. 9579else 9580 am__leading_dot=_ 9581fi 9582rmdir .tst 2>/dev/null 9583AC_SUBST([am__leading_dot])]) 9584 9585# Check to see how 'make' treats includes. -*- Autoconf -*- 9586 9587# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. 9588# 9589# This file is free software; the Free Software Foundation 9590# gives unlimited permission to copy and/or distribute it, 9591# with or without modifications, as long as this notice is preserved. 9592 9593# serial 3 9594 9595# AM_MAKE_INCLUDE() 9596# ----------------- 9597# Check to see how make treats includes. 9598AC_DEFUN([AM_MAKE_INCLUDE], 9599[am_make=${MAKE-make} 9600cat > confinc << 'END' 9601am__doit: 9602 @echo done 9603.PHONY: am__doit 9604END 9605# If we don't find an include directive, just comment out the code. 9606AC_MSG_CHECKING([for style of include used by $am_make]) 9607am__include="#" 9608am__quote= 9609_am_result=none 9610# First try GNU make style include. 9611echo "include confinc" > confmf 9612# We grep out `Entering directory' and `Leaving directory' 9613# messages which can occur if `w' ends up in MAKEFLAGS. 9614# In particular we don't look at `^make:' because GNU make might 9615# be invoked under some other name (usually "gmake"), in which 9616# case it prints its new name instead of `make'. 9617if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then 9618 am__include=include 9619 am__quote= 9620 _am_result=GNU 9621fi 9622# Now try BSD make style include. 9623if test "$am__include" = "#"; then 9624 echo '.include "confinc"' > confmf 9625 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then 9626 am__include=.include 9627 am__quote="\"" 9628 _am_result=BSD 9629 fi 9630fi 9631AC_SUBST([am__include]) 9632AC_SUBST([am__quote]) 9633AC_MSG_RESULT([$_am_result]) 9634rm -f confinc confmf 9635]) 9636 9637# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 9638 9639# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005 9640# Free Software Foundation, Inc. 9641# 9642# This file is free software; the Free Software Foundation 9643# gives unlimited permission to copy and/or distribute it, 9644# with or without modifications, as long as this notice is preserved. 9645 9646# serial 5 9647 9648# AM_MISSING_PROG(NAME, PROGRAM) 9649# ------------------------------ 9650AC_DEFUN([AM_MISSING_PROG], 9651[AC_REQUIRE([AM_MISSING_HAS_RUN]) 9652$1=${$1-"${am_missing_run}$2"} 9653AC_SUBST($1)]) 9654 9655 9656# AM_MISSING_HAS_RUN 9657# ------------------ 9658# Define MISSING if not defined so far and test if it supports --run. 9659# If it does, set am_missing_run to use it, otherwise, to nothing. 9660AC_DEFUN([AM_MISSING_HAS_RUN], 9661[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 9662AC_REQUIRE_AUX_FILE([missing])dnl 9663test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" 9664# Use eval to expand $SHELL 9665if eval "$MISSING --run true"; then 9666 am_missing_run="$MISSING --run " 9667else 9668 am_missing_run= 9669 AC_MSG_WARN([`missing' script is too old or missing]) 9670fi 9671]) 9672 9673# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 9674# 9675# This file is free software; the Free Software Foundation 9676# gives unlimited permission to copy and/or distribute it, 9677# with or without modifications, as long as this notice is preserved. 9678 9679# AM_PROG_MKDIR_P 9680# --------------- 9681# Check for `mkdir -p'. 9682AC_DEFUN([AM_PROG_MKDIR_P], 9683[AC_PREREQ([2.60])dnl 9684AC_REQUIRE([AC_PROG_MKDIR_P])dnl 9685dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 9686dnl while keeping a definition of mkdir_p for backward compatibility. 9687dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 9688dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 9689dnl Makefile.ins that do not define MKDIR_P, so we do our own 9690dnl adjustment using top_builddir (which is defined more often than 9691dnl MKDIR_P). 9692AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 9693case $mkdir_p in 9694 [[\\/$]]* | ?:[[\\/]]*) ;; 9695 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 9696esac 9697]) 9698 9699# Helper functions for option handling. -*- Autoconf -*- 9700 9701# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. 9702# 9703# This file is free software; the Free Software Foundation 9704# gives unlimited permission to copy and/or distribute it, 9705# with or without modifications, as long as this notice is preserved. 9706 9707# serial 4 9708 9709# _AM_MANGLE_OPTION(NAME) 9710# ----------------------- 9711AC_DEFUN([_AM_MANGLE_OPTION], 9712[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 9713 9714# _AM_SET_OPTION(NAME) 9715# ------------------------------ 9716# Set option NAME. Presently that only means defining a flag for this option. 9717AC_DEFUN([_AM_SET_OPTION], 9718[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 9719 9720# _AM_SET_OPTIONS(OPTIONS) 9721# ---------------------------------- 9722# OPTIONS is a space-separated list of Automake options. 9723AC_DEFUN([_AM_SET_OPTIONS], 9724[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 9725 9726# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 9727# ------------------------------------------- 9728# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 9729AC_DEFUN([_AM_IF_OPTION], 9730[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 9731 9732# Check to make sure that the build environment is sane. -*- Autoconf -*- 9733 9734# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 9735# Free Software Foundation, Inc. 9736# 9737# This file is free software; the Free Software Foundation 9738# gives unlimited permission to copy and/or distribute it, 9739# with or without modifications, as long as this notice is preserved. 9740 9741# serial 4 9742 9743# AM_SANITY_CHECK 9744# --------------- 9745AC_DEFUN([AM_SANITY_CHECK], 9746[AC_MSG_CHECKING([whether build environment is sane]) 9747# Just in case 9748sleep 1 9749echo timestamp > conftest.file 9750# Do `set' in a subshell so we don't clobber the current shell's 9751# arguments. Must try -L first in case configure is actually a 9752# symlink; some systems play weird games with the mod time of symlinks 9753# (eg FreeBSD returns the mod time of the symlink's containing 9754# directory). 9755if ( 9756 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` 9757 if test "$[*]" = "X"; then 9758 # -L didn't work. 9759 set X `ls -t $srcdir/configure conftest.file` 9760 fi 9761 rm -f conftest.file 9762 if test "$[*]" != "X $srcdir/configure conftest.file" \ 9763 && test "$[*]" != "X conftest.file $srcdir/configure"; then 9764 9765 # If neither matched, then we have a broken ls. This can happen 9766 # if, for instance, CONFIG_SHELL is bash and it inherits a 9767 # broken ls alias from the environment. This has actually 9768 # happened. Such a system could not be considered "sane". 9769 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 9770alias in your environment]) 9771 fi 9772 9773 test "$[2]" = conftest.file 9774 ) 9775then 9776 # Ok. 9777 : 9778else 9779 AC_MSG_ERROR([newly created file is older than distributed files! 9780Check your system clock]) 9781fi 9782AC_MSG_RESULT(yes)]) 9783 9784# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 9785# 9786# This file is free software; the Free Software Foundation 9787# gives unlimited permission to copy and/or distribute it, 9788# with or without modifications, as long as this notice is preserved. 9789 9790# AM_PROG_INSTALL_STRIP 9791# --------------------- 9792# One issue with vendor `install' (even GNU) is that you can't 9793# specify the program used to strip binaries. This is especially 9794# annoying in cross-compiling environments, where the build's strip 9795# is unlikely to handle the host's binaries. 9796# Fortunately install-sh will honor a STRIPPROG variable, so we 9797# always use install-sh in `make install-strip', and initialize 9798# STRIPPROG with the value of the STRIP variable (set by the user). 9799AC_DEFUN([AM_PROG_INSTALL_STRIP], 9800[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 9801# Installed binaries are usually stripped using `strip' when the user 9802# run `make install-strip'. However `strip' might not be the right 9803# tool to use in cross-compilation environments, therefore Automake 9804# will honor the `STRIP' environment variable to overrule this program. 9805dnl Don't test for $cross_compiling = yes, because it might be `maybe'. 9806if test "$cross_compiling" != no; then 9807 AC_CHECK_TOOL([STRIP], [strip], :) 9808fi 9809INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 9810AC_SUBST([INSTALL_STRIP_PROGRAM])]) 9811 9812# Copyright (C) 2006 Free Software Foundation, Inc. 9813# 9814# This file is free software; the Free Software Foundation 9815# gives unlimited permission to copy and/or distribute it, 9816# with or without modifications, as long as this notice is preserved. 9817 9818# _AM_SUBST_NOTMAKE(VARIABLE) 9819# --------------------------- 9820# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 9821# This macro is traced by Automake. 9822AC_DEFUN([_AM_SUBST_NOTMAKE]) 9823 9824# Check how to create a tarball. -*- Autoconf -*- 9825 9826# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 9827# 9828# This file is free software; the Free Software Foundation 9829# gives unlimited permission to copy and/or distribute it, 9830# with or without modifications, as long as this notice is preserved. 9831 9832# serial 2 9833 9834# _AM_PROG_TAR(FORMAT) 9835# -------------------- 9836# Check how to create a tarball in format FORMAT. 9837# FORMAT should be one of `v7', `ustar', or `pax'. 9838# 9839# Substitute a variable $(am__tar) that is a command 9840# writing to stdout a FORMAT-tarball containing the directory 9841# $tardir. 9842# tardir=directory && $(am__tar) > result.tar 9843# 9844# Substitute a variable $(am__untar) that extract such 9845# a tarball read from stdin. 9846# $(am__untar) < result.tar 9847AC_DEFUN([_AM_PROG_TAR], 9848[# Always define AMTAR for backward compatibility. 9849AM_MISSING_PROG([AMTAR], [tar]) 9850m4_if([$1], [v7], 9851 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 9852 [m4_case([$1], [ustar],, [pax],, 9853 [m4_fatal([Unknown tar format])]) 9854AC_MSG_CHECKING([how to create a $1 tar archive]) 9855# Loop over all known methods to create a tar archive until one works. 9856_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 9857_am_tools=${am_cv_prog_tar_$1-$_am_tools} 9858# Do not fold the above two line into one, because Tru64 sh and 9859# Solaris sh will not grok spaces in the rhs of `-'. 9860for _am_tool in $_am_tools 9861do 9862 case $_am_tool in 9863 gnutar) 9864 for _am_tar in tar gnutar gtar; 9865 do 9866 AM_RUN_LOG([$_am_tar --version]) && break 9867 done 9868 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 9869 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 9870 am__untar="$_am_tar -xf -" 9871 ;; 9872 plaintar) 9873 # Must skip GNU tar: if it does not support --format= it doesn't create 9874 # ustar tarball either. 9875 (tar --version) >/dev/null 2>&1 && continue 9876 am__tar='tar chf - "$$tardir"' 9877 am__tar_='tar chf - "$tardir"' 9878 am__untar='tar xf -' 9879 ;; 9880 pax) 9881 am__tar='pax -L -x $1 -w "$$tardir"' 9882 am__tar_='pax -L -x $1 -w "$tardir"' 9883 am__untar='pax -r' 9884 ;; 9885 cpio) 9886 am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 9887 am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 9888 am__untar='cpio -i -H $1 -d' 9889 ;; 9890 none) 9891 am__tar=false 9892 am__tar_=false 9893 am__untar=false 9894 ;; 9895 esac 9896 9897 # If the value was cached, stop now. We just wanted to have am__tar 9898 # and am__untar set. 9899 test -n "${am_cv_prog_tar_$1}" && break 9900 9901 # tar/untar a dummy directory, and stop if the command works 9902 rm -rf conftest.dir 9903 mkdir conftest.dir 9904 echo GrepMe > conftest.dir/file 9905 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 9906 rm -rf conftest.dir 9907 if test -s conftest.tar; then 9908 AM_RUN_LOG([$am__untar <conftest.tar]) 9909 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 9910 fi 9911done 9912rm -rf conftest.dir 9913 9914AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 9915AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 9916AC_SUBST([am__tar]) 9917AC_SUBST([am__untar]) 9918]) # _AM_PROG_TAR 9919 9920