1# generated automatically by aclocal 1.14.1 -*- Autoconf -*- 2 3# Copyright (C) 1996-2013 Free Software Foundation, Inc. 4 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_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) 15m4_ifndef([AC_AUTOCONF_VERSION], 16 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 17m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, 18[m4_warning([this file was generated for autoconf 2.69. 19You have another version of autoconf. It may work, but is not guaranteed to. 20If you have problems, you may need to regenerate the build system entirely. 21To do so, use the procedure documented by the package, typically 'autoreconf'.])]) 22 23# gettext.m4 serial 66 (gettext-0.18.2) 24dnl Copyright (C) 1995-2014 Free Software Foundation, Inc. 25dnl This file is free software; the Free Software Foundation 26dnl gives unlimited permission to copy and/or distribute it, 27dnl with or without modifications, as long as this notice is preserved. 28dnl 29dnl This file can can be used in projects which are not available under 30dnl the GNU General Public License or the GNU Library General Public 31dnl License but which still want to provide support for the GNU gettext 32dnl functionality. 33dnl Please note that the actual code of the GNU gettext library is covered 34dnl by the GNU Library General Public License, and the rest of the GNU 35dnl gettext package package is covered by the GNU General Public License. 36dnl They are *not* in the public domain. 37 38dnl Authors: 39dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000. 40dnl Bruno Haible <haible@clisp.cons.org>, 2000-2006, 2008-2010. 41 42dnl Macro to add for using GNU gettext. 43 44dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]). 45dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The 46dnl default (if it is not specified or empty) is 'no-libtool'. 47dnl INTLSYMBOL should be 'external' for packages with no intl directory, 48dnl and 'no-libtool' or 'use-libtool' for packages with an intl directory. 49dnl If INTLSYMBOL is 'use-libtool', then a libtool library 50dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static, 51dnl depending on --{enable,disable}-{shared,static} and on the presence of 52dnl AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library 53dnl $(top_builddir)/intl/libintl.a will be created. 54dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext 55dnl implementations (in libc or libintl) without the ngettext() function 56dnl will be ignored. If NEEDSYMBOL is specified and is 57dnl 'need-formatstring-macros', then GNU gettext implementations that don't 58dnl support the ISO C 99 <inttypes.h> formatstring macros will be ignored. 59dnl INTLDIR is used to find the intl libraries. If empty, 60dnl the value '$(top_builddir)/intl/' is used. 61dnl 62dnl The result of the configuration is one of three cases: 63dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled 64dnl and used. 65dnl Catalog format: GNU --> install in $(datadir) 66dnl Catalog extension: .mo after installation, .gmo in source tree 67dnl 2) GNU gettext has been found in the system's C library. 68dnl Catalog format: GNU --> install in $(datadir) 69dnl Catalog extension: .mo after installation, .gmo in source tree 70dnl 3) No internationalization, always use English msgid. 71dnl Catalog format: none 72dnl Catalog extension: none 73dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur. 74dnl The use of .gmo is historical (it was needed to avoid overwriting the 75dnl GNU format catalogs when building on a platform with an X/Open gettext), 76dnl but we keep it in order not to force irrelevant filename changes on the 77dnl maintainers. 78dnl 79AC_DEFUN([AM_GNU_GETTEXT], 80[ 81 dnl Argument checking. 82 ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], , 83 [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT 84])])])])]) 85 ifelse(ifelse([$1], [], [old])[]ifelse([$1], [no-libtool], [old]), [old], 86 [AC_DIAGNOSE([obsolete], [Use of AM_GNU_GETTEXT without [external] argument is deprecated.])]) 87 ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], , 88 [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT 89])])])]) 90 define([gt_included_intl], 91 ifelse([$1], [external], 92 ifdef([AM_GNU_GETTEXT_][INTL_SUBDIR], [yes], [no]), 93 [yes])) 94 define([gt_libtool_suffix_prefix], ifelse([$1], [use-libtool], [l], [])) 95 gt_NEEDS_INIT 96 AM_GNU_GETTEXT_NEED([$2]) 97 98 AC_REQUIRE([AM_PO_SUBDIRS])dnl 99 ifelse(gt_included_intl, yes, [ 100 AC_REQUIRE([AM_INTL_SUBDIR])dnl 101 ]) 102 103 dnl Prerequisites of AC_LIB_LINKFLAGS_BODY. 104 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) 105 AC_REQUIRE([AC_LIB_RPATH]) 106 107 dnl Sometimes libintl requires libiconv, so first search for libiconv. 108 dnl Ideally we would do this search only after the 109 dnl if test "$USE_NLS" = "yes"; then 110 dnl if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then 111 dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT 112 dnl the configure script would need to contain the same shell code 113 dnl again, outside any 'if'. There are two solutions: 114 dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'. 115 dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE. 116 dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not 117 dnl documented, we avoid it. 118 ifelse(gt_included_intl, yes, , [ 119 AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) 120 ]) 121 122 dnl Sometimes, on Mac OS X, libintl requires linking with CoreFoundation. 123 gt_INTL_MACOSX 124 125 dnl Set USE_NLS. 126 AC_REQUIRE([AM_NLS]) 127 128 ifelse(gt_included_intl, yes, [ 129 BUILD_INCLUDED_LIBINTL=no 130 USE_INCLUDED_LIBINTL=no 131 ]) 132 LIBINTL= 133 LTLIBINTL= 134 POSUB= 135 136 dnl Add a version number to the cache macros. 137 case " $gt_needs " in 138 *" need-formatstring-macros "*) gt_api_version=3 ;; 139 *" need-ngettext "*) gt_api_version=2 ;; 140 *) gt_api_version=1 ;; 141 esac 142 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc" 143 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl" 144 145 dnl If we use NLS figure out what method 146 if test "$USE_NLS" = "yes"; then 147 gt_use_preinstalled_gnugettext=no 148 ifelse(gt_included_intl, yes, [ 149 AC_MSG_CHECKING([whether included gettext is requested]) 150 AC_ARG_WITH([included-gettext], 151 [ --with-included-gettext use the GNU gettext library included here], 152 nls_cv_force_use_gnu_gettext=$withval, 153 nls_cv_force_use_gnu_gettext=no) 154 AC_MSG_RESULT([$nls_cv_force_use_gnu_gettext]) 155 156 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" 157 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then 158 ]) 159 dnl User does not insist on using GNU NLS library. Figure out what 160 dnl to use. If GNU gettext is available we use this. Else we have 161 dnl to fall back to GNU NLS library. 162 163 if test $gt_api_version -ge 3; then 164 gt_revision_test_code=' 165#ifndef __GNU_GETTEXT_SUPPORTED_REVISION 166#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1) 167#endif 168changequote(,)dnl 169typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1]; 170changequote([,])dnl 171' 172 else 173 gt_revision_test_code= 174 fi 175 if test $gt_api_version -ge 2; then 176 gt_expression_test_code=' + * ngettext ("", "", 0)' 177 else 178 gt_expression_test_code= 179 fi 180 181 AC_CACHE_CHECK([for GNU gettext in libc], [$gt_func_gnugettext_libc], 182 [AC_LINK_IFELSE( 183 [AC_LANG_PROGRAM( 184 [[ 185#include <libintl.h> 186$gt_revision_test_code 187extern int _nl_msg_cat_cntr; 188extern int *_nl_domain_bindings; 189 ]], 190 [[ 191bindtextdomain ("", ""); 192return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings 193 ]])], 194 [eval "$gt_func_gnugettext_libc=yes"], 195 [eval "$gt_func_gnugettext_libc=no"])]) 196 197 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then 198 dnl Sometimes libintl requires libiconv, so first search for libiconv. 199 ifelse(gt_included_intl, yes, , [ 200 AM_ICONV_LINK 201 ]) 202 dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL 203 dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv]) 204 dnl because that would add "-liconv" to LIBINTL and LTLIBINTL 205 dnl even if libiconv doesn't exist. 206 AC_LIB_LINKFLAGS_BODY([intl]) 207 AC_CACHE_CHECK([for GNU gettext in libintl], 208 [$gt_func_gnugettext_libintl], 209 [gt_save_CPPFLAGS="$CPPFLAGS" 210 CPPFLAGS="$CPPFLAGS $INCINTL" 211 gt_save_LIBS="$LIBS" 212 LIBS="$LIBS $LIBINTL" 213 dnl Now see whether libintl exists and does not depend on libiconv. 214 AC_LINK_IFELSE( 215 [AC_LANG_PROGRAM( 216 [[ 217#include <libintl.h> 218$gt_revision_test_code 219extern int _nl_msg_cat_cntr; 220extern 221#ifdef __cplusplus 222"C" 223#endif 224const char *_nl_expand_alias (const char *); 225 ]], 226 [[ 227bindtextdomain ("", ""); 228return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("") 229 ]])], 230 [eval "$gt_func_gnugettext_libintl=yes"], 231 [eval "$gt_func_gnugettext_libintl=no"]) 232 dnl Now see whether libintl exists and depends on libiconv. 233 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then 234 LIBS="$LIBS $LIBICONV" 235 AC_LINK_IFELSE( 236 [AC_LANG_PROGRAM( 237 [[ 238#include <libintl.h> 239$gt_revision_test_code 240extern int _nl_msg_cat_cntr; 241extern 242#ifdef __cplusplus 243"C" 244#endif 245const char *_nl_expand_alias (const char *); 246 ]], 247 [[ 248bindtextdomain ("", ""); 249return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("") 250 ]])], 251 [LIBINTL="$LIBINTL $LIBICONV" 252 LTLIBINTL="$LTLIBINTL $LTLIBICONV" 253 eval "$gt_func_gnugettext_libintl=yes" 254 ]) 255 fi 256 CPPFLAGS="$gt_save_CPPFLAGS" 257 LIBS="$gt_save_LIBS"]) 258 fi 259 260 dnl If an already present or preinstalled GNU gettext() is found, 261 dnl use it. But if this macro is used in GNU gettext, and GNU 262 dnl gettext is already preinstalled in libintl, we update this 263 dnl libintl. (Cf. the install rule in intl/Makefile.in.) 264 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \ 265 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \ 266 && test "$PACKAGE" != gettext-runtime \ 267 && test "$PACKAGE" != gettext-tools; }; then 268 gt_use_preinstalled_gnugettext=yes 269 else 270 dnl Reset the values set by searching for libintl. 271 LIBINTL= 272 LTLIBINTL= 273 INCINTL= 274 fi 275 276 ifelse(gt_included_intl, yes, [ 277 if test "$gt_use_preinstalled_gnugettext" != "yes"; then 278 dnl GNU gettext is not found in the C library. 279 dnl Fall back on included GNU gettext library. 280 nls_cv_use_gnu_gettext=yes 281 fi 282 fi 283 284 if test "$nls_cv_use_gnu_gettext" = "yes"; then 285 dnl Mark actions used to generate GNU NLS library. 286 BUILD_INCLUDED_LIBINTL=yes 287 USE_INCLUDED_LIBINTL=yes 288 LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV $LIBTHREAD" 289 LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV $LTLIBTHREAD" 290 LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` 291 fi 292 293 CATOBJEXT= 294 if test "$gt_use_preinstalled_gnugettext" = "yes" \ 295 || test "$nls_cv_use_gnu_gettext" = "yes"; then 296 dnl Mark actions to use GNU gettext tools. 297 CATOBJEXT=.gmo 298 fi 299 ]) 300 301 if test -n "$INTL_MACOSX_LIBS"; then 302 if test "$gt_use_preinstalled_gnugettext" = "yes" \ 303 || test "$nls_cv_use_gnu_gettext" = "yes"; then 304 dnl Some extra flags are needed during linking. 305 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS" 306 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS" 307 fi 308 fi 309 310 if test "$gt_use_preinstalled_gnugettext" = "yes" \ 311 || test "$nls_cv_use_gnu_gettext" = "yes"; then 312 AC_DEFINE([ENABLE_NLS], [1], 313 [Define to 1 if translation of program messages to the user's native language 314 is requested.]) 315 else 316 USE_NLS=no 317 fi 318 fi 319 320 AC_MSG_CHECKING([whether to use NLS]) 321 AC_MSG_RESULT([$USE_NLS]) 322 if test "$USE_NLS" = "yes"; then 323 AC_MSG_CHECKING([where the gettext function comes from]) 324 if test "$gt_use_preinstalled_gnugettext" = "yes"; then 325 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then 326 gt_source="external libintl" 327 else 328 gt_source="libc" 329 fi 330 else 331 gt_source="included intl directory" 332 fi 333 AC_MSG_RESULT([$gt_source]) 334 fi 335 336 if test "$USE_NLS" = "yes"; then 337 338 if test "$gt_use_preinstalled_gnugettext" = "yes"; then 339 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then 340 AC_MSG_CHECKING([how to link with libintl]) 341 AC_MSG_RESULT([$LIBINTL]) 342 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL]) 343 fi 344 345 dnl For backward compatibility. Some packages may be using this. 346 AC_DEFINE([HAVE_GETTEXT], [1], 347 [Define if the GNU gettext() function is already present or preinstalled.]) 348 AC_DEFINE([HAVE_DCGETTEXT], [1], 349 [Define if the GNU dcgettext() function is already present or preinstalled.]) 350 fi 351 352 dnl We need to process the po/ directory. 353 POSUB=po 354 fi 355 356 ifelse(gt_included_intl, yes, [ 357 dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL 358 dnl to 'yes' because some of the testsuite requires it. 359 if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then 360 BUILD_INCLUDED_LIBINTL=yes 361 fi 362 363 dnl Make all variables we use known to autoconf. 364 AC_SUBST([BUILD_INCLUDED_LIBINTL]) 365 AC_SUBST([USE_INCLUDED_LIBINTL]) 366 AC_SUBST([CATOBJEXT]) 367 368 dnl For backward compatibility. Some configure.ins may be using this. 369 nls_cv_header_intl= 370 nls_cv_header_libgt= 371 372 dnl For backward compatibility. Some Makefiles may be using this. 373 DATADIRNAME=share 374 AC_SUBST([DATADIRNAME]) 375 376 dnl For backward compatibility. Some Makefiles may be using this. 377 INSTOBJEXT=.mo 378 AC_SUBST([INSTOBJEXT]) 379 380 dnl For backward compatibility. Some Makefiles may be using this. 381 GENCAT=gencat 382 AC_SUBST([GENCAT]) 383 384 dnl For backward compatibility. Some Makefiles may be using this. 385 INTLOBJS= 386 if test "$USE_INCLUDED_LIBINTL" = yes; then 387 INTLOBJS="\$(GETTOBJS)" 388 fi 389 AC_SUBST([INTLOBJS]) 390 391 dnl Enable libtool support if the surrounding package wishes it. 392 INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix 393 AC_SUBST([INTL_LIBTOOL_SUFFIX_PREFIX]) 394 ]) 395 396 dnl For backward compatibility. Some Makefiles may be using this. 397 INTLLIBS="$LIBINTL" 398 AC_SUBST([INTLLIBS]) 399 400 dnl Make all documented variables known to autoconf. 401 AC_SUBST([LIBINTL]) 402 AC_SUBST([LTLIBINTL]) 403 AC_SUBST([POSUB]) 404]) 405 406 407dnl gt_NEEDS_INIT ensures that the gt_needs variable is initialized. 408m4_define([gt_NEEDS_INIT], 409[ 410 m4_divert_text([DEFAULTS], [gt_needs=]) 411 m4_define([gt_NEEDS_INIT], []) 412]) 413 414 415dnl Usage: AM_GNU_GETTEXT_NEED([NEEDSYMBOL]) 416AC_DEFUN([AM_GNU_GETTEXT_NEED], 417[ 418 m4_divert_text([INIT_PREPARE], [gt_needs="$gt_needs $1"]) 419]) 420 421 422dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version]) 423AC_DEFUN([AM_GNU_GETTEXT_VERSION], []) 424 425dnl -*- mode: autoconf -*- 426 427# serial 2 428 429dnl Usage: 430dnl GTK_DOC_CHECK([minimum-gtk-doc-version]) 431AC_DEFUN([GTK_DOC_CHECK], 432[ 433 AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 434 AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first 435 AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first 436 437 ifelse([$1],[],[gtk_doc_requires="gtk-doc"],[gtk_doc_requires="gtk-doc >= $1"]) 438 AC_MSG_CHECKING([for gtk-doc]) 439 PKG_CHECK_EXISTS([$gtk_doc_requires],[have_gtk_doc=yes],[have_gtk_doc=no]) 440 AC_MSG_RESULT($have_gtk_doc) 441 442 if test "$have_gtk_doc" = "no"; then 443 AC_MSG_WARN([ 444 You will not be able to create source packages with 'make dist' 445 because $gtk_doc_requires is not found.]) 446 fi 447 448 dnl check for tools we added during development 449 dnl Use AC_CHECK_PROG to avoid the check target using an absolute path that 450 dnl may not be writable by the user. Currently, automake requires that the 451 dnl test name must end in '.test'. 452 dnl https://bugzilla.gnome.org/show_bug.cgi?id=701638 453 AC_CHECK_PROG([GTKDOC_CHECK],[gtkdoc-check],[gtkdoc-check.test]) 454 AC_PATH_PROG([GTKDOC_CHECK_PATH],[gtkdoc-check]) 455 AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true]) 456 AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf]) 457 458 dnl for overriding the documentation installation directory 459 AC_ARG_WITH([html-dir], 460 AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),, 461 [with_html_dir='${datadir}/gtk-doc/html']) 462 HTML_DIR="$with_html_dir" 463 AC_SUBST([HTML_DIR]) 464 465 dnl enable/disable documentation building 466 AC_ARG_ENABLE([gtk-doc], 467 AS_HELP_STRING([--enable-gtk-doc], 468 [use gtk-doc to build documentation [[default=no]]]),, 469 [enable_gtk_doc=no]) 470 471 AC_MSG_CHECKING([whether to build gtk-doc documentation]) 472 AC_MSG_RESULT($enable_gtk_doc) 473 474 if test "x$enable_gtk_doc" = "xyes" && test "$have_gtk_doc" = "no"; then 475 AC_MSG_ERROR([ 476 You must have $gtk_doc_requires installed to build documentation for 477 $PACKAGE_NAME. Please install gtk-doc or disable building the 478 documentation by adding '--disable-gtk-doc' to '[$]0'.]) 479 fi 480 481 dnl don't check for glib if we build glib 482 if test "x$PACKAGE_NAME" != "xglib"; then 483 dnl don't fail if someone does not have glib 484 PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0,,[:]) 485 fi 486 487 dnl enable/disable output formats 488 AC_ARG_ENABLE([gtk-doc-html], 489 AS_HELP_STRING([--enable-gtk-doc-html], 490 [build documentation in html format [[default=yes]]]),, 491 [enable_gtk_doc_html=yes]) 492 AC_ARG_ENABLE([gtk-doc-pdf], 493 AS_HELP_STRING([--enable-gtk-doc-pdf], 494 [build documentation in pdf format [[default=no]]]),, 495 [enable_gtk_doc_pdf=no]) 496 497 if test -z "$GTKDOC_MKPDF"; then 498 enable_gtk_doc_pdf=no 499 fi 500 501 if test -z "$AM_DEFAULT_VERBOSITY"; then 502 AM_DEFAULT_VERBOSITY=1 503 fi 504 AC_SUBST([AM_DEFAULT_VERBOSITY]) 505 506 AM_CONDITIONAL([HAVE_GTK_DOC], [test x$have_gtk_doc = xyes]) 507 AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes]) 508 AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes]) 509 AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes]) 510 AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"]) 511 AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"]) 512]) 513 514# iconv.m4 serial 19 (gettext-0.18.2) 515dnl Copyright (C) 2000-2002, 2007-2014 Free Software Foundation, Inc. 516dnl This file is free software; the Free Software Foundation 517dnl gives unlimited permission to copy and/or distribute it, 518dnl with or without modifications, as long as this notice is preserved. 519 520dnl From Bruno Haible. 521 522AC_DEFUN([AM_ICONV_LINKFLAGS_BODY], 523[ 524 dnl Prerequisites of AC_LIB_LINKFLAGS_BODY. 525 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) 526 AC_REQUIRE([AC_LIB_RPATH]) 527 528 dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV 529 dnl accordingly. 530 AC_LIB_LINKFLAGS_BODY([iconv]) 531]) 532 533AC_DEFUN([AM_ICONV_LINK], 534[ 535 dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and 536 dnl those with the standalone portable GNU libiconv installed). 537 AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles 538 539 dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV 540 dnl accordingly. 541 AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) 542 543 dnl Add $INCICONV to CPPFLAGS before performing the following checks, 544 dnl because if the user has installed libiconv and not disabled its use 545 dnl via --without-libiconv-prefix, he wants to use it. The first 546 dnl AC_LINK_IFELSE will then fail, the second AC_LINK_IFELSE will succeed. 547 am_save_CPPFLAGS="$CPPFLAGS" 548 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV]) 549 550 AC_CACHE_CHECK([for iconv], [am_cv_func_iconv], [ 551 am_cv_func_iconv="no, consider installing GNU libiconv" 552 am_cv_lib_iconv=no 553 AC_LINK_IFELSE( 554 [AC_LANG_PROGRAM( 555 [[ 556#include <stdlib.h> 557#include <iconv.h> 558 ]], 559 [[iconv_t cd = iconv_open("",""); 560 iconv(cd,NULL,NULL,NULL,NULL); 561 iconv_close(cd);]])], 562 [am_cv_func_iconv=yes]) 563 if test "$am_cv_func_iconv" != yes; then 564 am_save_LIBS="$LIBS" 565 LIBS="$LIBS $LIBICONV" 566 AC_LINK_IFELSE( 567 [AC_LANG_PROGRAM( 568 [[ 569#include <stdlib.h> 570#include <iconv.h> 571 ]], 572 [[iconv_t cd = iconv_open("",""); 573 iconv(cd,NULL,NULL,NULL,NULL); 574 iconv_close(cd);]])], 575 [am_cv_lib_iconv=yes] 576 [am_cv_func_iconv=yes]) 577 LIBS="$am_save_LIBS" 578 fi 579 ]) 580 if test "$am_cv_func_iconv" = yes; then 581 AC_CACHE_CHECK([for working iconv], [am_cv_func_iconv_works], [ 582 dnl This tests against bugs in AIX 5.1, AIX 6.1..7.1, HP-UX 11.11, 583 dnl Solaris 10. 584 am_save_LIBS="$LIBS" 585 if test $am_cv_lib_iconv = yes; then 586 LIBS="$LIBS $LIBICONV" 587 fi 588 am_cv_func_iconv_works=no 589 for ac_iconv_const in '' 'const'; do 590 AC_RUN_IFELSE( 591 [AC_LANG_PROGRAM( 592 [[ 593#include <iconv.h> 594#include <string.h> 595 596#ifndef ICONV_CONST 597# define ICONV_CONST $ac_iconv_const 598#endif 599 ]], 600 [[int result = 0; 601 /* Test against AIX 5.1 bug: Failures are not distinguishable from successful 602 returns. */ 603 { 604 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8"); 605 if (cd_utf8_to_88591 != (iconv_t)(-1)) 606 { 607 static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */ 608 char buf[10]; 609 ICONV_CONST char *inptr = input; 610 size_t inbytesleft = strlen (input); 611 char *outptr = buf; 612 size_t outbytesleft = sizeof (buf); 613 size_t res = iconv (cd_utf8_to_88591, 614 &inptr, &inbytesleft, 615 &outptr, &outbytesleft); 616 if (res == 0) 617 result |= 1; 618 iconv_close (cd_utf8_to_88591); 619 } 620 } 621 /* Test against Solaris 10 bug: Failures are not distinguishable from 622 successful returns. */ 623 { 624 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646"); 625 if (cd_ascii_to_88591 != (iconv_t)(-1)) 626 { 627 static ICONV_CONST char input[] = "\263"; 628 char buf[10]; 629 ICONV_CONST char *inptr = input; 630 size_t inbytesleft = strlen (input); 631 char *outptr = buf; 632 size_t outbytesleft = sizeof (buf); 633 size_t res = iconv (cd_ascii_to_88591, 634 &inptr, &inbytesleft, 635 &outptr, &outbytesleft); 636 if (res == 0) 637 result |= 2; 638 iconv_close (cd_ascii_to_88591); 639 } 640 } 641 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */ 642 { 643 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1"); 644 if (cd_88591_to_utf8 != (iconv_t)(-1)) 645 { 646 static ICONV_CONST char input[] = "\304"; 647 static char buf[2] = { (char)0xDE, (char)0xAD }; 648 ICONV_CONST char *inptr = input; 649 size_t inbytesleft = 1; 650 char *outptr = buf; 651 size_t outbytesleft = 1; 652 size_t res = iconv (cd_88591_to_utf8, 653 &inptr, &inbytesleft, 654 &outptr, &outbytesleft); 655 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD) 656 result |= 4; 657 iconv_close (cd_88591_to_utf8); 658 } 659 } 660#if 0 /* This bug could be worked around by the caller. */ 661 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */ 662 { 663 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591"); 664 if (cd_88591_to_utf8 != (iconv_t)(-1)) 665 { 666 static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337"; 667 char buf[50]; 668 ICONV_CONST char *inptr = input; 669 size_t inbytesleft = strlen (input); 670 char *outptr = buf; 671 size_t outbytesleft = sizeof (buf); 672 size_t res = iconv (cd_88591_to_utf8, 673 &inptr, &inbytesleft, 674 &outptr, &outbytesleft); 675 if ((int)res > 0) 676 result |= 8; 677 iconv_close (cd_88591_to_utf8); 678 } 679 } 680#endif 681 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is 682 provided. */ 683 if (/* Try standardized names. */ 684 iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1) 685 /* Try IRIX, OSF/1 names. */ 686 && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1) 687 /* Try AIX names. */ 688 && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1) 689 /* Try HP-UX names. */ 690 && iconv_open ("utf8", "eucJP") == (iconv_t)(-1)) 691 result |= 16; 692 return result; 693]])], 694 [am_cv_func_iconv_works=yes], , 695 [case "$host_os" in 696 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;; 697 *) am_cv_func_iconv_works="guessing yes" ;; 698 esac]) 699 test "$am_cv_func_iconv_works" = no || break 700 done 701 LIBS="$am_save_LIBS" 702 ]) 703 case "$am_cv_func_iconv_works" in 704 *no) am_func_iconv=no am_cv_lib_iconv=no ;; 705 *) am_func_iconv=yes ;; 706 esac 707 else 708 am_func_iconv=no am_cv_lib_iconv=no 709 fi 710 if test "$am_func_iconv" = yes; then 711 AC_DEFINE([HAVE_ICONV], [1], 712 [Define if you have the iconv() function and it works.]) 713 fi 714 if test "$am_cv_lib_iconv" = yes; then 715 AC_MSG_CHECKING([how to link with libiconv]) 716 AC_MSG_RESULT([$LIBICONV]) 717 else 718 dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV 719 dnl either. 720 CPPFLAGS="$am_save_CPPFLAGS" 721 LIBICONV= 722 LTLIBICONV= 723 fi 724 AC_SUBST([LIBICONV]) 725 AC_SUBST([LTLIBICONV]) 726]) 727 728dnl Define AM_ICONV using AC_DEFUN_ONCE for Autoconf >= 2.64, in order to 729dnl avoid warnings like 730dnl "warning: AC_REQUIRE: `AM_ICONV' was expanded before it was required". 731dnl This is tricky because of the way 'aclocal' is implemented: 732dnl - It requires defining an auxiliary macro whose name ends in AC_DEFUN. 733dnl Otherwise aclocal's initial scan pass would miss the macro definition. 734dnl - It requires a line break inside the AC_DEFUN_ONCE and AC_DEFUN expansions. 735dnl Otherwise aclocal would emit many "Use of uninitialized value $1" 736dnl warnings. 737m4_define([gl_iconv_AC_DEFUN], 738 m4_version_prereq([2.64], 739 [[AC_DEFUN_ONCE( 740 [$1], [$2])]], 741 [m4_ifdef([gl_00GNULIB], 742 [[AC_DEFUN_ONCE( 743 [$1], [$2])]], 744 [[AC_DEFUN( 745 [$1], [$2])]])])) 746gl_iconv_AC_DEFUN([AM_ICONV], 747[ 748 AM_ICONV_LINK 749 if test "$am_cv_func_iconv" = yes; then 750 AC_MSG_CHECKING([for iconv declaration]) 751 AC_CACHE_VAL([am_cv_proto_iconv], [ 752 AC_COMPILE_IFELSE( 753 [AC_LANG_PROGRAM( 754 [[ 755#include <stdlib.h> 756#include <iconv.h> 757extern 758#ifdef __cplusplus 759"C" 760#endif 761#if defined(__STDC__) || defined(_MSC_VER) || defined(__cplusplus) 762size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); 763#else 764size_t iconv(); 765#endif 766 ]], 767 [[]])], 768 [am_cv_proto_iconv_arg1=""], 769 [am_cv_proto_iconv_arg1="const"]) 770 am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"]) 771 am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` 772 AC_MSG_RESULT([ 773 $am_cv_proto_iconv]) 774 AC_DEFINE_UNQUOTED([ICONV_CONST], [$am_cv_proto_iconv_arg1], 775 [Define as const if the declaration of iconv() needs const.]) 776 dnl Also substitute ICONV_CONST in the gnulib generated <iconv.h>. 777 m4_ifdef([gl_ICONV_H_DEFAULTS], 778 [AC_REQUIRE([gl_ICONV_H_DEFAULTS]) 779 if test -n "$am_cv_proto_iconv_arg1"; then 780 ICONV_CONST="const" 781 fi 782 ]) 783 fi 784]) 785 786# intlmacosx.m4 serial 5 (gettext-0.18.2) 787dnl Copyright (C) 2004-2014 Free Software Foundation, Inc. 788dnl This file is free software; the Free Software Foundation 789dnl gives unlimited permission to copy and/or distribute it, 790dnl with or without modifications, as long as this notice is preserved. 791dnl 792dnl This file can can be used in projects which are not available under 793dnl the GNU General Public License or the GNU Library General Public 794dnl License but which still want to provide support for the GNU gettext 795dnl functionality. 796dnl Please note that the actual code of the GNU gettext library is covered 797dnl by the GNU Library General Public License, and the rest of the GNU 798dnl gettext package package is covered by the GNU General Public License. 799dnl They are *not* in the public domain. 800 801dnl Checks for special options needed on Mac OS X. 802dnl Defines INTL_MACOSX_LIBS. 803AC_DEFUN([gt_INTL_MACOSX], 804[ 805 dnl Check for API introduced in Mac OS X 10.2. 806 AC_CACHE_CHECK([for CFPreferencesCopyAppValue], 807 [gt_cv_func_CFPreferencesCopyAppValue], 808 [gt_save_LIBS="$LIBS" 809 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" 810 AC_LINK_IFELSE( 811 [AC_LANG_PROGRAM( 812 [[#include <CoreFoundation/CFPreferences.h>]], 813 [[CFPreferencesCopyAppValue(NULL, NULL)]])], 814 [gt_cv_func_CFPreferencesCopyAppValue=yes], 815 [gt_cv_func_CFPreferencesCopyAppValue=no]) 816 LIBS="$gt_save_LIBS"]) 817 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then 818 AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1], 819 [Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in the CoreFoundation framework.]) 820 fi 821 dnl Check for API introduced in Mac OS X 10.3. 822 AC_CACHE_CHECK([for CFLocaleCopyCurrent], [gt_cv_func_CFLocaleCopyCurrent], 823 [gt_save_LIBS="$LIBS" 824 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" 825 AC_LINK_IFELSE( 826 [AC_LANG_PROGRAM( 827 [[#include <CoreFoundation/CFLocale.h>]], 828 [[CFLocaleCopyCurrent();]])], 829 [gt_cv_func_CFLocaleCopyCurrent=yes], 830 [gt_cv_func_CFLocaleCopyCurrent=no]) 831 LIBS="$gt_save_LIBS"]) 832 if test $gt_cv_func_CFLocaleCopyCurrent = yes; then 833 AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], [1], 834 [Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the CoreFoundation framework.]) 835 fi 836 INTL_MACOSX_LIBS= 837 if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then 838 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" 839 fi 840 AC_SUBST([INTL_MACOSX_LIBS]) 841]) 842 843dnl -*- mode: autoconf -*- 844dnl Copyright 2009 Johan Dahlin 845dnl 846dnl This file is free software; the author(s) gives unlimited 847dnl permission to copy and/or distribute it, with or without 848dnl modifications, as long as this notice is preserved. 849dnl 850 851# serial 1 852 853m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL], 854[ 855 AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first 856 AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first 857 AC_BEFORE([LT_INIT],[$0])dnl setup libtool first 858 859 dnl enable/disable introspection 860 m4_if([$2], [require], 861 [dnl 862 enable_introspection=yes 863 ],[dnl 864 AC_ARG_ENABLE(introspection, 865 AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]], 866 [Enable introspection for this build]),, 867 [enable_introspection=auto]) 868 ])dnl 869 870 AC_MSG_CHECKING([for gobject-introspection]) 871 872 dnl presence/version checking 873 AS_CASE([$enable_introspection], 874 [no], [dnl 875 found_introspection="no (disabled, use --enable-introspection to enable)" 876 ],dnl 877 [yes],[dnl 878 PKG_CHECK_EXISTS([gobject-introspection-1.0],, 879 AC_MSG_ERROR([gobject-introspection-1.0 is not installed])) 880 PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], 881 found_introspection=yes, 882 AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME])) 883 ],dnl 884 [auto],[dnl 885 PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no) 886 dnl Canonicalize enable_introspection 887 enable_introspection=$found_introspection 888 ],dnl 889 [dnl 890 AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@]) 891 ])dnl 892 893 AC_MSG_RESULT([$found_introspection]) 894 895 INTROSPECTION_SCANNER= 896 INTROSPECTION_COMPILER= 897 INTROSPECTION_GENERATE= 898 INTROSPECTION_GIRDIR= 899 INTROSPECTION_TYPELIBDIR= 900 if test "x$found_introspection" = "xyes"; then 901 INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0` 902 INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0` 903 INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0` 904 INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0` 905 INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)" 906 INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0` 907 INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0` 908 INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection 909 fi 910 AC_SUBST(INTROSPECTION_SCANNER) 911 AC_SUBST(INTROSPECTION_COMPILER) 912 AC_SUBST(INTROSPECTION_GENERATE) 913 AC_SUBST(INTROSPECTION_GIRDIR) 914 AC_SUBST(INTROSPECTION_TYPELIBDIR) 915 AC_SUBST(INTROSPECTION_CFLAGS) 916 AC_SUBST(INTROSPECTION_LIBS) 917 AC_SUBST(INTROSPECTION_MAKEFILE) 918 919 AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes") 920]) 921 922 923dnl Usage: 924dnl GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version]) 925 926AC_DEFUN([GOBJECT_INTROSPECTION_CHECK], 927[ 928 _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1]) 929]) 930 931dnl Usage: 932dnl GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version]) 933 934 935AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE], 936[ 937 _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require]) 938]) 939 940# lib-ld.m4 serial 6 941dnl Copyright (C) 1996-2003, 2009-2014 Free Software Foundation, Inc. 942dnl This file is free software; the Free Software Foundation 943dnl gives unlimited permission to copy and/or distribute it, 944dnl with or without modifications, as long as this notice is preserved. 945 946dnl Subroutines of libtool.m4, 947dnl with replacements s/_*LT_PATH/AC_LIB_PROG/ and s/lt_/acl_/ to avoid 948dnl collision with libtool.m4. 949 950dnl From libtool-2.4. Sets the variable with_gnu_ld to yes or no. 951AC_DEFUN([AC_LIB_PROG_LD_GNU], 952[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], [acl_cv_prog_gnu_ld], 953[# I'd rather use --version here, but apparently some GNU lds only accept -v. 954case `$LD -v 2>&1 </dev/null` in 955*GNU* | *'with BFD'*) 956 acl_cv_prog_gnu_ld=yes 957 ;; 958*) 959 acl_cv_prog_gnu_ld=no 960 ;; 961esac]) 962with_gnu_ld=$acl_cv_prog_gnu_ld 963]) 964 965dnl From libtool-2.4. Sets the variable LD. 966AC_DEFUN([AC_LIB_PROG_LD], 967[AC_REQUIRE([AC_PROG_CC])dnl 968AC_REQUIRE([AC_CANONICAL_HOST])dnl 969 970AC_ARG_WITH([gnu-ld], 971 [AS_HELP_STRING([--with-gnu-ld], 972 [assume the C compiler uses GNU ld [default=no]])], 973 [test "$withval" = no || with_gnu_ld=yes], 974 [with_gnu_ld=no])dnl 975 976# Prepare PATH_SEPARATOR. 977# The user is always right. 978if test "${PATH_SEPARATOR+set}" != set; then 979 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which 980 # contains only /bin. Note that ksh looks also at the FPATH variable, 981 # so we have to set that as well for the test. 982 PATH_SEPARATOR=: 983 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \ 984 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \ 985 || PATH_SEPARATOR=';' 986 } 987fi 988 989ac_prog=ld 990if test "$GCC" = yes; then 991 # Check if gcc -print-prog-name=ld gives a path. 992 AC_MSG_CHECKING([for ld used by $CC]) 993 case $host in 994 *-*-mingw*) 995 # gcc leaves a trailing carriage return which upsets mingw 996 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 997 *) 998 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 999 esac 1000 case $ac_prog in 1001 # Accept absolute paths. 1002 [[\\/]]* | ?:[[\\/]]*) 1003 re_direlt='/[[^/]][[^/]]*/\.\./' 1004 # Canonicalize the pathname of ld 1005 ac_prog=`echo "$ac_prog"| sed 's%\\\\%/%g'` 1006 while echo "$ac_prog" | grep "$re_direlt" > /dev/null 2>&1; do 1007 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` 1008 done 1009 test -z "$LD" && LD="$ac_prog" 1010 ;; 1011 "") 1012 # If it fails, then pretend we aren't using GCC. 1013 ac_prog=ld 1014 ;; 1015 *) 1016 # If it is relative, then search for the first ld in PATH. 1017 with_gnu_ld=unknown 1018 ;; 1019 esac 1020elif test "$with_gnu_ld" = yes; then 1021 AC_MSG_CHECKING([for GNU ld]) 1022else 1023 AC_MSG_CHECKING([for non-GNU ld]) 1024fi 1025AC_CACHE_VAL([acl_cv_path_LD], 1026[if test -z "$LD"; then 1027 acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 1028 for ac_dir in $PATH; do 1029 IFS="$acl_save_ifs" 1030 test -z "$ac_dir" && ac_dir=. 1031 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 1032 acl_cv_path_LD="$ac_dir/$ac_prog" 1033 # Check to see if the program is GNU ld. I'd rather use --version, 1034 # but apparently some variants of GNU ld only accept -v. 1035 # Break only if it was the GNU/non-GNU ld that we prefer. 1036 case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in 1037 *GNU* | *'with BFD'*) 1038 test "$with_gnu_ld" != no && break 1039 ;; 1040 *) 1041 test "$with_gnu_ld" != yes && break 1042 ;; 1043 esac 1044 fi 1045 done 1046 IFS="$acl_save_ifs" 1047else 1048 acl_cv_path_LD="$LD" # Let the user override the test with a path. 1049fi]) 1050LD="$acl_cv_path_LD" 1051if test -n "$LD"; then 1052 AC_MSG_RESULT([$LD]) 1053else 1054 AC_MSG_RESULT([no]) 1055fi 1056test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 1057AC_LIB_PROG_LD_GNU 1058]) 1059 1060# lib-link.m4 serial 26 (gettext-0.18.2) 1061dnl Copyright (C) 2001-2014 Free Software Foundation, Inc. 1062dnl This file is free software; the Free Software Foundation 1063dnl gives unlimited permission to copy and/or distribute it, 1064dnl with or without modifications, as long as this notice is preserved. 1065 1066dnl From Bruno Haible. 1067 1068AC_PREREQ([2.54]) 1069 1070dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and 1071dnl the libraries corresponding to explicit and implicit dependencies. 1072dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and 1073dnl augments the CPPFLAGS variable. 1074dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname 1075dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem. 1076AC_DEFUN([AC_LIB_LINKFLAGS], 1077[ 1078 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) 1079 AC_REQUIRE([AC_LIB_RPATH]) 1080 pushdef([Name],[m4_translit([$1],[./+-], [____])]) 1081 pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-], 1082 [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])]) 1083 AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [ 1084 AC_LIB_LINKFLAGS_BODY([$1], [$2]) 1085 ac_cv_lib[]Name[]_libs="$LIB[]NAME" 1086 ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME" 1087 ac_cv_lib[]Name[]_cppflags="$INC[]NAME" 1088 ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX" 1089 ]) 1090 LIB[]NAME="$ac_cv_lib[]Name[]_libs" 1091 LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs" 1092 INC[]NAME="$ac_cv_lib[]Name[]_cppflags" 1093 LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix" 1094 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) 1095 AC_SUBST([LIB]NAME) 1096 AC_SUBST([LTLIB]NAME) 1097 AC_SUBST([LIB]NAME[_PREFIX]) 1098 dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the 1099 dnl results of this search when this library appears as a dependency. 1100 HAVE_LIB[]NAME=yes 1101 popdef([NAME]) 1102 popdef([Name]) 1103]) 1104 1105dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message]) 1106dnl searches for libname and the libraries corresponding to explicit and 1107dnl implicit dependencies, together with the specified include files and 1108dnl the ability to compile and link the specified testcode. The missing-message 1109dnl defaults to 'no' and may contain additional hints for the user. 1110dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} 1111dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and 1112dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs 1113dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. 1114dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname 1115dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem. 1116AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], 1117[ 1118 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) 1119 AC_REQUIRE([AC_LIB_RPATH]) 1120 pushdef([Name],[m4_translit([$1],[./+-], [____])]) 1121 pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-], 1122 [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])]) 1123 1124 dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME 1125 dnl accordingly. 1126 AC_LIB_LINKFLAGS_BODY([$1], [$2]) 1127 1128 dnl Add $INC[]NAME to CPPFLAGS before performing the following checks, 1129 dnl because if the user has installed lib[]Name and not disabled its use 1130 dnl via --without-lib[]Name-prefix, he wants to use it. 1131 ac_save_CPPFLAGS="$CPPFLAGS" 1132 AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) 1133 1134 AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [ 1135 ac_save_LIBS="$LIBS" 1136 dnl If $LIB[]NAME contains some -l options, add it to the end of LIBS, 1137 dnl because these -l options might require -L options that are present in 1138 dnl LIBS. -l options benefit only from the -L options listed before it. 1139 dnl Otherwise, add it to the front of LIBS, because it may be a static 1140 dnl library that depends on another static library that is present in LIBS. 1141 dnl Static libraries benefit only from the static libraries listed after 1142 dnl it. 1143 case " $LIB[]NAME" in 1144 *" -l"*) LIBS="$LIBS $LIB[]NAME" ;; 1145 *) LIBS="$LIB[]NAME $LIBS" ;; 1146 esac 1147 AC_LINK_IFELSE( 1148 [AC_LANG_PROGRAM([[$3]], [[$4]])], 1149 [ac_cv_lib[]Name=yes], 1150 [ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])']) 1151 LIBS="$ac_save_LIBS" 1152 ]) 1153 if test "$ac_cv_lib[]Name" = yes; then 1154 HAVE_LIB[]NAME=yes 1155 AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib][$1 library.]) 1156 AC_MSG_CHECKING([how to link with lib[]$1]) 1157 AC_MSG_RESULT([$LIB[]NAME]) 1158 else 1159 HAVE_LIB[]NAME=no 1160 dnl If $LIB[]NAME didn't lead to a usable library, we don't need 1161 dnl $INC[]NAME either. 1162 CPPFLAGS="$ac_save_CPPFLAGS" 1163 LIB[]NAME= 1164 LTLIB[]NAME= 1165 LIB[]NAME[]_PREFIX= 1166 fi 1167 AC_SUBST([HAVE_LIB]NAME) 1168 AC_SUBST([LIB]NAME) 1169 AC_SUBST([LTLIB]NAME) 1170 AC_SUBST([LIB]NAME[_PREFIX]) 1171 popdef([NAME]) 1172 popdef([Name]) 1173]) 1174 1175dnl Determine the platform dependent parameters needed to use rpath: 1176dnl acl_libext, 1177dnl acl_shlibext, 1178dnl acl_libname_spec, 1179dnl acl_library_names_spec, 1180dnl acl_hardcode_libdir_flag_spec, 1181dnl acl_hardcode_libdir_separator, 1182dnl acl_hardcode_direct, 1183dnl acl_hardcode_minus_L. 1184AC_DEFUN([AC_LIB_RPATH], 1185[ 1186 dnl Tell automake >= 1.10 to complain if config.rpath is missing. 1187 m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])]) 1188 AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS 1189 AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld 1190 AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host 1191 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir 1192 AC_CACHE_CHECK([for shared library run path origin], [acl_cv_rpath], [ 1193 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ 1194 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh 1195 . ./conftest.sh 1196 rm -f ./conftest.sh 1197 acl_cv_rpath=done 1198 ]) 1199 wl="$acl_cv_wl" 1200 acl_libext="$acl_cv_libext" 1201 acl_shlibext="$acl_cv_shlibext" 1202 acl_libname_spec="$acl_cv_libname_spec" 1203 acl_library_names_spec="$acl_cv_library_names_spec" 1204 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" 1205 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" 1206 acl_hardcode_direct="$acl_cv_hardcode_direct" 1207 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L" 1208 dnl Determine whether the user wants rpath handling at all. 1209 AC_ARG_ENABLE([rpath], 1210 [ --disable-rpath do not hardcode runtime library paths], 1211 :, enable_rpath=yes) 1212]) 1213 1214dnl AC_LIB_FROMPACKAGE(name, package) 1215dnl declares that libname comes from the given package. The configure file 1216dnl will then not have a --with-libname-prefix option but a 1217dnl --with-package-prefix option. Several libraries can come from the same 1218dnl package. This declaration must occur before an AC_LIB_LINKFLAGS or similar 1219dnl macro call that searches for libname. 1220AC_DEFUN([AC_LIB_FROMPACKAGE], 1221[ 1222 pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-], 1223 [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])]) 1224 define([acl_frompackage_]NAME, [$2]) 1225 popdef([NAME]) 1226 pushdef([PACK],[$2]) 1227 pushdef([PACKUP],[m4_translit(PACK,[abcdefghijklmnopqrstuvwxyz./+-], 1228 [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])]) 1229 define([acl_libsinpackage_]PACKUP, 1230 m4_ifdef([acl_libsinpackage_]PACKUP, [m4_defn([acl_libsinpackage_]PACKUP)[, ]],)[lib$1]) 1231 popdef([PACKUP]) 1232 popdef([PACK]) 1233]) 1234 1235dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and 1236dnl the libraries corresponding to explicit and implicit dependencies. 1237dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables. 1238dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found 1239dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem. 1240AC_DEFUN([AC_LIB_LINKFLAGS_BODY], 1241[ 1242 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) 1243 pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-], 1244 [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])]) 1245 pushdef([PACK],[m4_ifdef([acl_frompackage_]NAME, [acl_frompackage_]NAME, lib[$1])]) 1246 pushdef([PACKUP],[m4_translit(PACK,[abcdefghijklmnopqrstuvwxyz./+-], 1247 [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])]) 1248 pushdef([PACKLIBS],[m4_ifdef([acl_frompackage_]NAME, [acl_libsinpackage_]PACKUP, lib[$1])]) 1249 dnl Autoconf >= 2.61 supports dots in --with options. 1250 pushdef([P_A_C_K],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[m4_translit(PACK,[.],[_])],PACK)]) 1251 dnl By default, look in $includedir and $libdir. 1252 use_additional=yes 1253 AC_LIB_WITH_FINAL_PREFIX([ 1254 eval additional_includedir=\"$includedir\" 1255 eval additional_libdir=\"$libdir\" 1256 ]) 1257 AC_ARG_WITH(P_A_C_K[-prefix], 1258[[ --with-]]P_A_C_K[[-prefix[=DIR] search for ]PACKLIBS[ in DIR/include and DIR/lib 1259 --without-]]P_A_C_K[[-prefix don't search for ]PACKLIBS[ in includedir and libdir]], 1260[ 1261 if test "X$withval" = "Xno"; then 1262 use_additional=no 1263 else 1264 if test "X$withval" = "X"; then 1265 AC_LIB_WITH_FINAL_PREFIX([ 1266 eval additional_includedir=\"$includedir\" 1267 eval additional_libdir=\"$libdir\" 1268 ]) 1269 else 1270 additional_includedir="$withval/include" 1271 additional_libdir="$withval/$acl_libdirstem" 1272 if test "$acl_libdirstem2" != "$acl_libdirstem" \ 1273 && ! test -d "$withval/$acl_libdirstem"; then 1274 additional_libdir="$withval/$acl_libdirstem2" 1275 fi 1276 fi 1277 fi 1278]) 1279 dnl Search the library and its dependencies in $additional_libdir and 1280 dnl $LDFLAGS. Using breadth-first-seach. 1281 LIB[]NAME= 1282 LTLIB[]NAME= 1283 INC[]NAME= 1284 LIB[]NAME[]_PREFIX= 1285 dnl HAVE_LIB${NAME} is an indicator that LIB${NAME}, LTLIB${NAME} have been 1286 dnl computed. So it has to be reset here. 1287 HAVE_LIB[]NAME= 1288 rpathdirs= 1289 ltrpathdirs= 1290 names_already_handled= 1291 names_next_round='$1 $2' 1292 while test -n "$names_next_round"; do 1293 names_this_round="$names_next_round" 1294 names_next_round= 1295 for name in $names_this_round; do 1296 already_handled= 1297 for n in $names_already_handled; do 1298 if test "$n" = "$name"; then 1299 already_handled=yes 1300 break 1301 fi 1302 done 1303 if test -z "$already_handled"; then 1304 names_already_handled="$names_already_handled $name" 1305 dnl See if it was already located by an earlier AC_LIB_LINKFLAGS 1306 dnl or AC_LIB_HAVE_LINKFLAGS call. 1307 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'` 1308 eval value=\"\$HAVE_LIB$uppername\" 1309 if test -n "$value"; then 1310 if test "$value" = yes; then 1311 eval value=\"\$LIB$uppername\" 1312 test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value" 1313 eval value=\"\$LTLIB$uppername\" 1314 test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value" 1315 else 1316 dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined 1317 dnl that this library doesn't exist. So just drop it. 1318 : 1319 fi 1320 else 1321 dnl Search the library lib$name in $additional_libdir and $LDFLAGS 1322 dnl and the already constructed $LIBNAME/$LTLIBNAME. 1323 found_dir= 1324 found_la= 1325 found_so= 1326 found_a= 1327 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name 1328 if test -n "$acl_shlibext"; then 1329 shrext=".$acl_shlibext" # typically: shrext=.so 1330 else 1331 shrext= 1332 fi 1333 if test $use_additional = yes; then 1334 dir="$additional_libdir" 1335 dnl The same code as in the loop below: 1336 dnl First look for a shared library. 1337 if test -n "$acl_shlibext"; then 1338 if test -f "$dir/$libname$shrext"; then 1339 found_dir="$dir" 1340 found_so="$dir/$libname$shrext" 1341 else 1342 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then 1343 ver=`(cd "$dir" && \ 1344 for f in "$libname$shrext".*; do echo "$f"; done \ 1345 | sed -e "s,^$libname$shrext\\\\.,," \ 1346 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ 1347 | sed 1q ) 2>/dev/null` 1348 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then 1349 found_dir="$dir" 1350 found_so="$dir/$libname$shrext.$ver" 1351 fi 1352 else 1353 eval library_names=\"$acl_library_names_spec\" 1354 for f in $library_names; do 1355 if test -f "$dir/$f"; then 1356 found_dir="$dir" 1357 found_so="$dir/$f" 1358 break 1359 fi 1360 done 1361 fi 1362 fi 1363 fi 1364 dnl Then look for a static library. 1365 if test "X$found_dir" = "X"; then 1366 if test -f "$dir/$libname.$acl_libext"; then 1367 found_dir="$dir" 1368 found_a="$dir/$libname.$acl_libext" 1369 fi 1370 fi 1371 if test "X$found_dir" != "X"; then 1372 if test -f "$dir/$libname.la"; then 1373 found_la="$dir/$libname.la" 1374 fi 1375 fi 1376 fi 1377 if test "X$found_dir" = "X"; then 1378 for x in $LDFLAGS $LTLIB[]NAME; do 1379 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1380 case "$x" in 1381 -L*) 1382 dir=`echo "X$x" | sed -e 's/^X-L//'` 1383 dnl First look for a shared library. 1384 if test -n "$acl_shlibext"; then 1385 if test -f "$dir/$libname$shrext"; then 1386 found_dir="$dir" 1387 found_so="$dir/$libname$shrext" 1388 else 1389 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then 1390 ver=`(cd "$dir" && \ 1391 for f in "$libname$shrext".*; do echo "$f"; done \ 1392 | sed -e "s,^$libname$shrext\\\\.,," \ 1393 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ 1394 | sed 1q ) 2>/dev/null` 1395 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then 1396 found_dir="$dir" 1397 found_so="$dir/$libname$shrext.$ver" 1398 fi 1399 else 1400 eval library_names=\"$acl_library_names_spec\" 1401 for f in $library_names; do 1402 if test -f "$dir/$f"; then 1403 found_dir="$dir" 1404 found_so="$dir/$f" 1405 break 1406 fi 1407 done 1408 fi 1409 fi 1410 fi 1411 dnl Then look for a static library. 1412 if test "X$found_dir" = "X"; then 1413 if test -f "$dir/$libname.$acl_libext"; then 1414 found_dir="$dir" 1415 found_a="$dir/$libname.$acl_libext" 1416 fi 1417 fi 1418 if test "X$found_dir" != "X"; then 1419 if test -f "$dir/$libname.la"; then 1420 found_la="$dir/$libname.la" 1421 fi 1422 fi 1423 ;; 1424 esac 1425 if test "X$found_dir" != "X"; then 1426 break 1427 fi 1428 done 1429 fi 1430 if test "X$found_dir" != "X"; then 1431 dnl Found the library. 1432 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name" 1433 if test "X$found_so" != "X"; then 1434 dnl Linking with a shared library. We attempt to hardcode its 1435 dnl directory into the executable's runpath, unless it's the 1436 dnl standard /usr/lib. 1437 if test "$enable_rpath" = no \ 1438 || test "X$found_dir" = "X/usr/$acl_libdirstem" \ 1439 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then 1440 dnl No hardcoding is needed. 1441 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 1442 else 1443 dnl Use an explicit option to hardcode DIR into the resulting 1444 dnl binary. 1445 dnl Potentially add DIR to ltrpathdirs. 1446 dnl The ltrpathdirs will be appended to $LTLIBNAME at the end. 1447 haveit= 1448 for x in $ltrpathdirs; do 1449 if test "X$x" = "X$found_dir"; then 1450 haveit=yes 1451 break 1452 fi 1453 done 1454 if test -z "$haveit"; then 1455 ltrpathdirs="$ltrpathdirs $found_dir" 1456 fi 1457 dnl The hardcoding into $LIBNAME is system dependent. 1458 if test "$acl_hardcode_direct" = yes; then 1459 dnl Using DIR/libNAME.so during linking hardcodes DIR into the 1460 dnl resulting binary. 1461 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 1462 else 1463 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then 1464 dnl Use an explicit option to hardcode DIR into the resulting 1465 dnl binary. 1466 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 1467 dnl Potentially add DIR to rpathdirs. 1468 dnl The rpathdirs will be appended to $LIBNAME at the end. 1469 haveit= 1470 for x in $rpathdirs; do 1471 if test "X$x" = "X$found_dir"; then 1472 haveit=yes 1473 break 1474 fi 1475 done 1476 if test -z "$haveit"; then 1477 rpathdirs="$rpathdirs $found_dir" 1478 fi 1479 else 1480 dnl Rely on "-L$found_dir". 1481 dnl But don't add it if it's already contained in the LDFLAGS 1482 dnl or the already constructed $LIBNAME 1483 haveit= 1484 for x in $LDFLAGS $LIB[]NAME; do 1485 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1486 if test "X$x" = "X-L$found_dir"; then 1487 haveit=yes 1488 break 1489 fi 1490 done 1491 if test -z "$haveit"; then 1492 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir" 1493 fi 1494 if test "$acl_hardcode_minus_L" != no; then 1495 dnl FIXME: Not sure whether we should use 1496 dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" 1497 dnl here. 1498 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" 1499 else 1500 dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH 1501 dnl here, because this doesn't fit in flags passed to the 1502 dnl compiler. So give up. No hardcoding. This affects only 1503 dnl very old systems. 1504 dnl FIXME: Not sure whether we should use 1505 dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" 1506 dnl here. 1507 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name" 1508 fi 1509 fi 1510 fi 1511 fi 1512 else 1513 if test "X$found_a" != "X"; then 1514 dnl Linking with a static library. 1515 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a" 1516 else 1517 dnl We shouldn't come here, but anyway it's good to have a 1518 dnl fallback. 1519 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name" 1520 fi 1521 fi 1522 dnl Assume the include files are nearby. 1523 additional_includedir= 1524 case "$found_dir" in 1525 */$acl_libdirstem | */$acl_libdirstem/) 1526 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` 1527 if test "$name" = '$1'; then 1528 LIB[]NAME[]_PREFIX="$basedir" 1529 fi 1530 additional_includedir="$basedir/include" 1531 ;; 1532 */$acl_libdirstem2 | */$acl_libdirstem2/) 1533 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'` 1534 if test "$name" = '$1'; then 1535 LIB[]NAME[]_PREFIX="$basedir" 1536 fi 1537 additional_includedir="$basedir/include" 1538 ;; 1539 esac 1540 if test "X$additional_includedir" != "X"; then 1541 dnl Potentially add $additional_includedir to $INCNAME. 1542 dnl But don't add it 1543 dnl 1. if it's the standard /usr/include, 1544 dnl 2. if it's /usr/local/include and we are using GCC on Linux, 1545 dnl 3. if it's already present in $CPPFLAGS or the already 1546 dnl constructed $INCNAME, 1547 dnl 4. if it doesn't exist as a directory. 1548 if test "X$additional_includedir" != "X/usr/include"; then 1549 haveit= 1550 if test "X$additional_includedir" = "X/usr/local/include"; then 1551 if test -n "$GCC"; then 1552 case $host_os in 1553 linux* | gnu* | k*bsd*-gnu) haveit=yes;; 1554 esac 1555 fi 1556 fi 1557 if test -z "$haveit"; then 1558 for x in $CPPFLAGS $INC[]NAME; do 1559 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1560 if test "X$x" = "X-I$additional_includedir"; then 1561 haveit=yes 1562 break 1563 fi 1564 done 1565 if test -z "$haveit"; then 1566 if test -d "$additional_includedir"; then 1567 dnl Really add $additional_includedir to $INCNAME. 1568 INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir" 1569 fi 1570 fi 1571 fi 1572 fi 1573 fi 1574 dnl Look for dependencies. 1575 if test -n "$found_la"; then 1576 dnl Read the .la file. It defines the variables 1577 dnl dlname, library_names, old_library, dependency_libs, current, 1578 dnl age, revision, installed, dlopen, dlpreopen, libdir. 1579 save_libdir="$libdir" 1580 case "$found_la" in 1581 */* | *\\*) . "$found_la" ;; 1582 *) . "./$found_la" ;; 1583 esac 1584 libdir="$save_libdir" 1585 dnl We use only dependency_libs. 1586 for dep in $dependency_libs; do 1587 case "$dep" in 1588 -L*) 1589 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` 1590 dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME. 1591 dnl But don't add it 1592 dnl 1. if it's the standard /usr/lib, 1593 dnl 2. if it's /usr/local/lib and we are using GCC on Linux, 1594 dnl 3. if it's already present in $LDFLAGS or the already 1595 dnl constructed $LIBNAME, 1596 dnl 4. if it doesn't exist as a directory. 1597 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \ 1598 && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then 1599 haveit= 1600 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \ 1601 || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then 1602 if test -n "$GCC"; then 1603 case $host_os in 1604 linux* | gnu* | k*bsd*-gnu) haveit=yes;; 1605 esac 1606 fi 1607 fi 1608 if test -z "$haveit"; then 1609 haveit= 1610 for x in $LDFLAGS $LIB[]NAME; do 1611 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1612 if test "X$x" = "X-L$additional_libdir"; then 1613 haveit=yes 1614 break 1615 fi 1616 done 1617 if test -z "$haveit"; then 1618 if test -d "$additional_libdir"; then 1619 dnl Really add $additional_libdir to $LIBNAME. 1620 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir" 1621 fi 1622 fi 1623 haveit= 1624 for x in $LDFLAGS $LTLIB[]NAME; do 1625 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1626 if test "X$x" = "X-L$additional_libdir"; then 1627 haveit=yes 1628 break 1629 fi 1630 done 1631 if test -z "$haveit"; then 1632 if test -d "$additional_libdir"; then 1633 dnl Really add $additional_libdir to $LTLIBNAME. 1634 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir" 1635 fi 1636 fi 1637 fi 1638 fi 1639 ;; 1640 -R*) 1641 dir=`echo "X$dep" | sed -e 's/^X-R//'` 1642 if test "$enable_rpath" != no; then 1643 dnl Potentially add DIR to rpathdirs. 1644 dnl The rpathdirs will be appended to $LIBNAME at the end. 1645 haveit= 1646 for x in $rpathdirs; do 1647 if test "X$x" = "X$dir"; then 1648 haveit=yes 1649 break 1650 fi 1651 done 1652 if test -z "$haveit"; then 1653 rpathdirs="$rpathdirs $dir" 1654 fi 1655 dnl Potentially add DIR to ltrpathdirs. 1656 dnl The ltrpathdirs will be appended to $LTLIBNAME at the end. 1657 haveit= 1658 for x in $ltrpathdirs; do 1659 if test "X$x" = "X$dir"; then 1660 haveit=yes 1661 break 1662 fi 1663 done 1664 if test -z "$haveit"; then 1665 ltrpathdirs="$ltrpathdirs $dir" 1666 fi 1667 fi 1668 ;; 1669 -l*) 1670 dnl Handle this in the next round. 1671 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` 1672 ;; 1673 *.la) 1674 dnl Handle this in the next round. Throw away the .la's 1675 dnl directory; it is already contained in a preceding -L 1676 dnl option. 1677 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` 1678 ;; 1679 *) 1680 dnl Most likely an immediate library name. 1681 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep" 1682 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep" 1683 ;; 1684 esac 1685 done 1686 fi 1687 else 1688 dnl Didn't find the library; assume it is in the system directories 1689 dnl known to the linker and runtime loader. (All the system 1690 dnl directories known to the linker should also be known to the 1691 dnl runtime loader, otherwise the system is severely misconfigured.) 1692 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name" 1693 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name" 1694 fi 1695 fi 1696 fi 1697 done 1698 done 1699 if test "X$rpathdirs" != "X"; then 1700 if test -n "$acl_hardcode_libdir_separator"; then 1701 dnl Weird platform: only the last -rpath option counts, the user must 1702 dnl pass all path elements in one option. We can arrange that for a 1703 dnl single library, but not when more than one $LIBNAMEs are used. 1704 alldirs= 1705 for found_dir in $rpathdirs; do 1706 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir" 1707 done 1708 dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl. 1709 acl_save_libdir="$libdir" 1710 libdir="$alldirs" 1711 eval flag=\"$acl_hardcode_libdir_flag_spec\" 1712 libdir="$acl_save_libdir" 1713 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" 1714 else 1715 dnl The -rpath options are cumulative. 1716 for found_dir in $rpathdirs; do 1717 acl_save_libdir="$libdir" 1718 libdir="$found_dir" 1719 eval flag=\"$acl_hardcode_libdir_flag_spec\" 1720 libdir="$acl_save_libdir" 1721 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" 1722 done 1723 fi 1724 fi 1725 if test "X$ltrpathdirs" != "X"; then 1726 dnl When using libtool, the option that works for both libraries and 1727 dnl executables is -R. The -R options are cumulative. 1728 for found_dir in $ltrpathdirs; do 1729 LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir" 1730 done 1731 fi 1732 popdef([P_A_C_K]) 1733 popdef([PACKLIBS]) 1734 popdef([PACKUP]) 1735 popdef([PACK]) 1736 popdef([NAME]) 1737]) 1738 1739dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR, 1740dnl unless already present in VAR. 1741dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes 1742dnl contains two or three consecutive elements that belong together. 1743AC_DEFUN([AC_LIB_APPENDTOVAR], 1744[ 1745 for element in [$2]; do 1746 haveit= 1747 for x in $[$1]; do 1748 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1749 if test "X$x" = "X$element"; then 1750 haveit=yes 1751 break 1752 fi 1753 done 1754 if test -z "$haveit"; then 1755 [$1]="${[$1]}${[$1]:+ }$element" 1756 fi 1757 done 1758]) 1759 1760dnl For those cases where a variable contains several -L and -l options 1761dnl referring to unknown libraries and directories, this macro determines the 1762dnl necessary additional linker options for the runtime path. 1763dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL]) 1764dnl sets LDADDVAR to linker options needed together with LIBSVALUE. 1765dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed, 1766dnl otherwise linking without libtool is assumed. 1767AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS], 1768[ 1769 AC_REQUIRE([AC_LIB_RPATH]) 1770 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) 1771 $1= 1772 if test "$enable_rpath" != no; then 1773 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then 1774 dnl Use an explicit option to hardcode directories into the resulting 1775 dnl binary. 1776 rpathdirs= 1777 next= 1778 for opt in $2; do 1779 if test -n "$next"; then 1780 dir="$next" 1781 dnl No need to hardcode the standard /usr/lib. 1782 if test "X$dir" != "X/usr/$acl_libdirstem" \ 1783 && test "X$dir" != "X/usr/$acl_libdirstem2"; then 1784 rpathdirs="$rpathdirs $dir" 1785 fi 1786 next= 1787 else 1788 case $opt in 1789 -L) next=yes ;; 1790 -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'` 1791 dnl No need to hardcode the standard /usr/lib. 1792 if test "X$dir" != "X/usr/$acl_libdirstem" \ 1793 && test "X$dir" != "X/usr/$acl_libdirstem2"; then 1794 rpathdirs="$rpathdirs $dir" 1795 fi 1796 next= ;; 1797 *) next= ;; 1798 esac 1799 fi 1800 done 1801 if test "X$rpathdirs" != "X"; then 1802 if test -n ""$3""; then 1803 dnl libtool is used for linking. Use -R options. 1804 for dir in $rpathdirs; do 1805 $1="${$1}${$1:+ }-R$dir" 1806 done 1807 else 1808 dnl The linker is used for linking directly. 1809 if test -n "$acl_hardcode_libdir_separator"; then 1810 dnl Weird platform: only the last -rpath option counts, the user 1811 dnl must pass all path elements in one option. 1812 alldirs= 1813 for dir in $rpathdirs; do 1814 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir" 1815 done 1816 acl_save_libdir="$libdir" 1817 libdir="$alldirs" 1818 eval flag=\"$acl_hardcode_libdir_flag_spec\" 1819 libdir="$acl_save_libdir" 1820 $1="$flag" 1821 else 1822 dnl The -rpath options are cumulative. 1823 for dir in $rpathdirs; do 1824 acl_save_libdir="$libdir" 1825 libdir="$dir" 1826 eval flag=\"$acl_hardcode_libdir_flag_spec\" 1827 libdir="$acl_save_libdir" 1828 $1="${$1}${$1:+ }$flag" 1829 done 1830 fi 1831 fi 1832 fi 1833 fi 1834 fi 1835 AC_SUBST([$1]) 1836]) 1837 1838# lib-prefix.m4 serial 7 (gettext-0.18) 1839dnl Copyright (C) 2001-2005, 2008-2014 Free Software Foundation, Inc. 1840dnl This file is free software; the Free Software Foundation 1841dnl gives unlimited permission to copy and/or distribute it, 1842dnl with or without modifications, as long as this notice is preserved. 1843 1844dnl From Bruno Haible. 1845 1846dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and 1847dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't 1848dnl require excessive bracketing. 1849ifdef([AC_HELP_STRING], 1850[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])], 1851[AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])]) 1852 1853dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed 1854dnl to access previously installed libraries. The basic assumption is that 1855dnl a user will want packages to use other packages he previously installed 1856dnl with the same --prefix option. 1857dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate 1858dnl libraries, but is otherwise very convenient. 1859AC_DEFUN([AC_LIB_PREFIX], 1860[ 1861 AC_BEFORE([$0], [AC_LIB_LINKFLAGS]) 1862 AC_REQUIRE([AC_PROG_CC]) 1863 AC_REQUIRE([AC_CANONICAL_HOST]) 1864 AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) 1865 AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) 1866 dnl By default, look in $includedir and $libdir. 1867 use_additional=yes 1868 AC_LIB_WITH_FINAL_PREFIX([ 1869 eval additional_includedir=\"$includedir\" 1870 eval additional_libdir=\"$libdir\" 1871 ]) 1872 AC_LIB_ARG_WITH([lib-prefix], 1873[ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib 1874 --without-lib-prefix don't search for libraries in includedir and libdir], 1875[ 1876 if test "X$withval" = "Xno"; then 1877 use_additional=no 1878 else 1879 if test "X$withval" = "X"; then 1880 AC_LIB_WITH_FINAL_PREFIX([ 1881 eval additional_includedir=\"$includedir\" 1882 eval additional_libdir=\"$libdir\" 1883 ]) 1884 else 1885 additional_includedir="$withval/include" 1886 additional_libdir="$withval/$acl_libdirstem" 1887 fi 1888 fi 1889]) 1890 if test $use_additional = yes; then 1891 dnl Potentially add $additional_includedir to $CPPFLAGS. 1892 dnl But don't add it 1893 dnl 1. if it's the standard /usr/include, 1894 dnl 2. if it's already present in $CPPFLAGS, 1895 dnl 3. if it's /usr/local/include and we are using GCC on Linux, 1896 dnl 4. if it doesn't exist as a directory. 1897 if test "X$additional_includedir" != "X/usr/include"; then 1898 haveit= 1899 for x in $CPPFLAGS; do 1900 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1901 if test "X$x" = "X-I$additional_includedir"; then 1902 haveit=yes 1903 break 1904 fi 1905 done 1906 if test -z "$haveit"; then 1907 if test "X$additional_includedir" = "X/usr/local/include"; then 1908 if test -n "$GCC"; then 1909 case $host_os in 1910 linux* | gnu* | k*bsd*-gnu) haveit=yes;; 1911 esac 1912 fi 1913 fi 1914 if test -z "$haveit"; then 1915 if test -d "$additional_includedir"; then 1916 dnl Really add $additional_includedir to $CPPFLAGS. 1917 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir" 1918 fi 1919 fi 1920 fi 1921 fi 1922 dnl Potentially add $additional_libdir to $LDFLAGS. 1923 dnl But don't add it 1924 dnl 1. if it's the standard /usr/lib, 1925 dnl 2. if it's already present in $LDFLAGS, 1926 dnl 3. if it's /usr/local/lib and we are using GCC on Linux, 1927 dnl 4. if it doesn't exist as a directory. 1928 if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then 1929 haveit= 1930 for x in $LDFLAGS; do 1931 AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) 1932 if test "X$x" = "X-L$additional_libdir"; then 1933 haveit=yes 1934 break 1935 fi 1936 done 1937 if test -z "$haveit"; then 1938 if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then 1939 if test -n "$GCC"; then 1940 case $host_os in 1941 linux*) haveit=yes;; 1942 esac 1943 fi 1944 fi 1945 if test -z "$haveit"; then 1946 if test -d "$additional_libdir"; then 1947 dnl Really add $additional_libdir to $LDFLAGS. 1948 LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir" 1949 fi 1950 fi 1951 fi 1952 fi 1953 fi 1954]) 1955 1956dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix, 1957dnl acl_final_exec_prefix, containing the values to which $prefix and 1958dnl $exec_prefix will expand at the end of the configure script. 1959AC_DEFUN([AC_LIB_PREPARE_PREFIX], 1960[ 1961 dnl Unfortunately, prefix and exec_prefix get only finally determined 1962 dnl at the end of configure. 1963 if test "X$prefix" = "XNONE"; then 1964 acl_final_prefix="$ac_default_prefix" 1965 else 1966 acl_final_prefix="$prefix" 1967 fi 1968 if test "X$exec_prefix" = "XNONE"; then 1969 acl_final_exec_prefix='${prefix}' 1970 else 1971 acl_final_exec_prefix="$exec_prefix" 1972 fi 1973 acl_save_prefix="$prefix" 1974 prefix="$acl_final_prefix" 1975 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" 1976 prefix="$acl_save_prefix" 1977]) 1978 1979dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the 1980dnl variables prefix and exec_prefix bound to the values they will have 1981dnl at the end of the configure script. 1982AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX], 1983[ 1984 acl_save_prefix="$prefix" 1985 prefix="$acl_final_prefix" 1986 acl_save_exec_prefix="$exec_prefix" 1987 exec_prefix="$acl_final_exec_prefix" 1988 $1 1989 exec_prefix="$acl_save_exec_prefix" 1990 prefix="$acl_save_prefix" 1991]) 1992 1993dnl AC_LIB_PREPARE_MULTILIB creates 1994dnl - a variable acl_libdirstem, containing the basename of the libdir, either 1995dnl "lib" or "lib64" or "lib/64", 1996dnl - a variable acl_libdirstem2, as a secondary possible value for 1997dnl acl_libdirstem, either the same as acl_libdirstem or "lib/sparcv9" or 1998dnl "lib/amd64". 1999AC_DEFUN([AC_LIB_PREPARE_MULTILIB], 2000[ 2001 dnl There is no formal standard regarding lib and lib64. 2002 dnl On glibc systems, the current practice is that on a system supporting 2003 dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under 2004 dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. We determine 2005 dnl the compiler's default mode by looking at the compiler's library search 2006 dnl path. If at least one of its elements ends in /lib64 or points to a 2007 dnl directory whose absolute pathname ends in /lib64, we assume a 64-bit ABI. 2008 dnl Otherwise we use the default, namely "lib". 2009 dnl On Solaris systems, the current practice is that on a system supporting 2010 dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under 2011 dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or 2012 dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib. 2013 AC_REQUIRE([AC_CANONICAL_HOST]) 2014 acl_libdirstem=lib 2015 acl_libdirstem2= 2016 case "$host_os" in 2017 solaris*) 2018 dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment 2019 dnl <http://docs.sun.com/app/docs/doc/816-5138/dev-env?l=en&a=view>. 2020 dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link." 2021 dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the 2022 dnl symlink is missing, so we set acl_libdirstem2 too. 2023 AC_CACHE_CHECK([for 64-bit host], [gl_cv_solaris_64bit], 2024 [AC_EGREP_CPP([sixtyfour bits], [ 2025#ifdef _LP64 2026sixtyfour bits 2027#endif 2028 ], [gl_cv_solaris_64bit=yes], [gl_cv_solaris_64bit=no]) 2029 ]) 2030 if test $gl_cv_solaris_64bit = yes; then 2031 acl_libdirstem=lib/64 2032 case "$host_cpu" in 2033 sparc*) acl_libdirstem2=lib/sparcv9 ;; 2034 i*86 | x86_64) acl_libdirstem2=lib/amd64 ;; 2035 esac 2036 fi 2037 ;; 2038 *) 2039 searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'` 2040 if test -n "$searchpath"; then 2041 acl_save_IFS="${IFS= }"; IFS=":" 2042 for searchdir in $searchpath; do 2043 if test -d "$searchdir"; then 2044 case "$searchdir" in 2045 */lib64/ | */lib64 ) acl_libdirstem=lib64 ;; 2046 */../ | */.. ) 2047 # Better ignore directories of this form. They are misleading. 2048 ;; 2049 *) searchdir=`cd "$searchdir" && pwd` 2050 case "$searchdir" in 2051 */lib64 ) acl_libdirstem=lib64 ;; 2052 esac ;; 2053 esac 2054 fi 2055 done 2056 IFS="$acl_save_IFS" 2057 fi 2058 ;; 2059 esac 2060 test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem" 2061]) 2062 2063# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 2064# 2065# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2066# 2006, 2007, 2008, 2009, 2010, 2011 Free Software 2067# Foundation, Inc. 2068# Written by Gordon Matzigkeit, 1996 2069# 2070# This file is free software; the Free Software Foundation gives 2071# unlimited permission to copy and/or distribute it, with or without 2072# modifications, as long as this notice is preserved. 2073 2074m4_define([_LT_COPYING], [dnl 2075# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2076# 2006, 2007, 2008, 2009, 2010, 2011 Free Software 2077# Foundation, Inc. 2078# Written by Gordon Matzigkeit, 1996 2079# 2080# This file is part of GNU Libtool. 2081# 2082# GNU Libtool is free software; you can redistribute it and/or 2083# modify it under the terms of the GNU General Public License as 2084# published by the Free Software Foundation; either version 2 of 2085# the License, or (at your option) any later version. 2086# 2087# As a special exception to the GNU General Public License, 2088# if you distribute this file as part of a program or library that 2089# is built using GNU Libtool, you may include this file under the 2090# same distribution terms that you use for the rest of that program. 2091# 2092# GNU Libtool is distributed in the hope that it will be useful, 2093# but WITHOUT ANY WARRANTY; without even the implied warranty of 2094# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 2095# GNU General Public License for more details. 2096# 2097# You should have received a copy of the GNU General Public License 2098# along with GNU Libtool; see the file COPYING. If not, a copy 2099# can be downloaded from http://www.gnu.org/licenses/gpl.html, or 2100# obtained by writing to the Free Software Foundation, Inc., 2101# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 2102]) 2103 2104# serial 57 LT_INIT 2105 2106 2107# LT_PREREQ(VERSION) 2108# ------------------ 2109# Complain and exit if this libtool version is less that VERSION. 2110m4_defun([LT_PREREQ], 2111[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 2112 [m4_default([$3], 2113 [m4_fatal([Libtool version $1 or higher is required], 2114 63)])], 2115 [$2])]) 2116 2117 2118# _LT_CHECK_BUILDDIR 2119# ------------------ 2120# Complain if the absolute build directory name contains unusual characters 2121m4_defun([_LT_CHECK_BUILDDIR], 2122[case `pwd` in 2123 *\ * | *\ *) 2124 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 2125esac 2126]) 2127 2128 2129# LT_INIT([OPTIONS]) 2130# ------------------ 2131AC_DEFUN([LT_INIT], 2132[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT 2133AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 2134AC_BEFORE([$0], [LT_LANG])dnl 2135AC_BEFORE([$0], [LT_OUTPUT])dnl 2136AC_BEFORE([$0], [LTDL_INIT])dnl 2137m4_require([_LT_CHECK_BUILDDIR])dnl 2138 2139dnl Autoconf doesn't catch unexpanded LT_ macros by default: 2140m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 2141m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 2142dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 2143dnl unless we require an AC_DEFUNed macro: 2144AC_REQUIRE([LTOPTIONS_VERSION])dnl 2145AC_REQUIRE([LTSUGAR_VERSION])dnl 2146AC_REQUIRE([LTVERSION_VERSION])dnl 2147AC_REQUIRE([LTOBSOLETE_VERSION])dnl 2148m4_require([_LT_PROG_LTMAIN])dnl 2149 2150_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) 2151 2152dnl Parse OPTIONS 2153_LT_SET_OPTIONS([$0], [$1]) 2154 2155# This can be used to rebuild libtool when needed 2156LIBTOOL_DEPS="$ltmain" 2157 2158# Always use our own libtool. 2159LIBTOOL='$(SHELL) $(top_builddir)/libtool' 2160AC_SUBST(LIBTOOL)dnl 2161 2162_LT_SETUP 2163 2164# Only expand once: 2165m4_define([LT_INIT]) 2166])# LT_INIT 2167 2168# Old names: 2169AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 2170AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 2171dnl aclocal-1.4 backwards compatibility: 2172dnl AC_DEFUN([AC_PROG_LIBTOOL], []) 2173dnl AC_DEFUN([AM_PROG_LIBTOOL], []) 2174 2175 2176# _LT_CC_BASENAME(CC) 2177# ------------------- 2178# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 2179m4_defun([_LT_CC_BASENAME], 2180[for cc_temp in $1""; do 2181 case $cc_temp in 2182 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 2183 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 2184 \-*) ;; 2185 *) break;; 2186 esac 2187done 2188cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` 2189]) 2190 2191 2192# _LT_FILEUTILS_DEFAULTS 2193# ---------------------- 2194# It is okay to use these file commands and assume they have been set 2195# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. 2196m4_defun([_LT_FILEUTILS_DEFAULTS], 2197[: ${CP="cp -f"} 2198: ${MV="mv -f"} 2199: ${RM="rm -f"} 2200])# _LT_FILEUTILS_DEFAULTS 2201 2202 2203# _LT_SETUP 2204# --------- 2205m4_defun([_LT_SETUP], 2206[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2207AC_REQUIRE([AC_CANONICAL_BUILD])dnl 2208AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl 2209AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 2210 2211_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl 2212dnl 2213_LT_DECL([], [host_alias], [0], [The host system])dnl 2214_LT_DECL([], [host], [0])dnl 2215_LT_DECL([], [host_os], [0])dnl 2216dnl 2217_LT_DECL([], [build_alias], [0], [The build system])dnl 2218_LT_DECL([], [build], [0])dnl 2219_LT_DECL([], [build_os], [0])dnl 2220dnl 2221AC_REQUIRE([AC_PROG_CC])dnl 2222AC_REQUIRE([LT_PATH_LD])dnl 2223AC_REQUIRE([LT_PATH_NM])dnl 2224dnl 2225AC_REQUIRE([AC_PROG_LN_S])dnl 2226test -z "$LN_S" && LN_S="ln -s" 2227_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 2228dnl 2229AC_REQUIRE([LT_CMD_MAX_LEN])dnl 2230_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 2231_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 2232dnl 2233m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2234m4_require([_LT_CHECK_SHELL_FEATURES])dnl 2235m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl 2236m4_require([_LT_CMD_RELOAD])dnl 2237m4_require([_LT_CHECK_MAGIC_METHOD])dnl 2238m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl 2239m4_require([_LT_CMD_OLD_ARCHIVE])dnl 2240m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 2241m4_require([_LT_WITH_SYSROOT])dnl 2242 2243_LT_CONFIG_LIBTOOL_INIT([ 2244# See if we are running on zsh, and set the options which allow our 2245# commands through without removal of \ escapes INIT. 2246if test -n "\${ZSH_VERSION+set}" ; then 2247 setopt NO_GLOB_SUBST 2248fi 2249]) 2250if test -n "${ZSH_VERSION+set}" ; then 2251 setopt NO_GLOB_SUBST 2252fi 2253 2254_LT_CHECK_OBJDIR 2255 2256m4_require([_LT_TAG_COMPILER])dnl 2257 2258case $host_os in 2259aix3*) 2260 # AIX sometimes has problems with the GCC collect2 program. For some 2261 # reason, if we set the COLLECT_NAMES environment variable, the problems 2262 # vanish in a puff of smoke. 2263 if test "X${COLLECT_NAMES+set}" != Xset; then 2264 COLLECT_NAMES= 2265 export COLLECT_NAMES 2266 fi 2267 ;; 2268esac 2269 2270# Global variables: 2271ofile=libtool 2272can_build_shared=yes 2273 2274# All known linkers require a `.a' archive for static linking (except MSVC, 2275# which needs '.lib'). 2276libext=a 2277 2278with_gnu_ld="$lt_cv_prog_gnu_ld" 2279 2280old_CC="$CC" 2281old_CFLAGS="$CFLAGS" 2282 2283# Set sane defaults for various variables 2284test -z "$CC" && CC=cc 2285test -z "$LTCC" && LTCC=$CC 2286test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 2287test -z "$LD" && LD=ld 2288test -z "$ac_objext" && ac_objext=o 2289 2290_LT_CC_BASENAME([$compiler]) 2291 2292# Only perform the check for file, if the check method requires it 2293test -z "$MAGIC_CMD" && MAGIC_CMD=file 2294case $deplibs_check_method in 2295file_magic*) 2296 if test "$file_magic_cmd" = '$MAGIC_CMD'; then 2297 _LT_PATH_MAGIC 2298 fi 2299 ;; 2300esac 2301 2302# Use C for the default configuration in the libtool script 2303LT_SUPPORTED_TAG([CC]) 2304_LT_LANG_C_CONFIG 2305_LT_LANG_DEFAULT_CONFIG 2306_LT_CONFIG_COMMANDS 2307])# _LT_SETUP 2308 2309 2310# _LT_PREPARE_SED_QUOTE_VARS 2311# -------------------------- 2312# Define a few sed substitution that help us do robust quoting. 2313m4_defun([_LT_PREPARE_SED_QUOTE_VARS], 2314[# Backslashify metacharacters that are still active within 2315# double-quoted strings. 2316sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 2317 2318# Same as above, but do not quote variable references. 2319double_quote_subst='s/\([["`\\]]\)/\\\1/g' 2320 2321# Sed substitution to delay expansion of an escaped shell variable in a 2322# double_quote_subst'ed string. 2323delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 2324 2325# Sed substitution to delay expansion of an escaped single quote. 2326delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 2327 2328# Sed substitution to avoid accidental globbing in evaled expressions 2329no_glob_subst='s/\*/\\\*/g' 2330]) 2331 2332# _LT_PROG_LTMAIN 2333# --------------- 2334# Note that this code is called both from `configure', and `config.status' 2335# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 2336# `config.status' has no value for ac_aux_dir unless we are using Automake, 2337# so we pass a copy along to make sure it has a sensible value anyway. 2338m4_defun([_LT_PROG_LTMAIN], 2339[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 2340_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 2341ltmain="$ac_aux_dir/ltmain.sh" 2342])# _LT_PROG_LTMAIN 2343 2344 2345 2346# So that we can recreate a full libtool script including additional 2347# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 2348# in macros and then make a single call at the end using the `libtool' 2349# label. 2350 2351 2352# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 2353# ---------------------------------------- 2354# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 2355m4_define([_LT_CONFIG_LIBTOOL_INIT], 2356[m4_ifval([$1], 2357 [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 2358 [$1 2359])])]) 2360 2361# Initialize. 2362m4_define([_LT_OUTPUT_LIBTOOL_INIT]) 2363 2364 2365# _LT_CONFIG_LIBTOOL([COMMANDS]) 2366# ------------------------------ 2367# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 2368m4_define([_LT_CONFIG_LIBTOOL], 2369[m4_ifval([$1], 2370 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 2371 [$1 2372])])]) 2373 2374# Initialize. 2375m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 2376 2377 2378# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 2379# ----------------------------------------------------- 2380m4_defun([_LT_CONFIG_SAVE_COMMANDS], 2381[_LT_CONFIG_LIBTOOL([$1]) 2382_LT_CONFIG_LIBTOOL_INIT([$2]) 2383]) 2384 2385 2386# _LT_FORMAT_COMMENT([COMMENT]) 2387# ----------------------------- 2388# Add leading comment marks to the start of each line, and a trailing 2389# full-stop to the whole comment if one is not present already. 2390m4_define([_LT_FORMAT_COMMENT], 2391[m4_ifval([$1], [ 2392m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 2393 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 2394)]) 2395 2396 2397 2398 2399 2400# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 2401# ------------------------------------------------------------------- 2402# CONFIGNAME is the name given to the value in the libtool script. 2403# VARNAME is the (base) name used in the configure script. 2404# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 2405# VARNAME. Any other value will be used directly. 2406m4_define([_LT_DECL], 2407[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 2408 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 2409 [m4_ifval([$1], [$1], [$2])]) 2410 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 2411 m4_ifval([$4], 2412 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 2413 lt_dict_add_subkey([lt_decl_dict], [$2], 2414 [tagged?], [m4_ifval([$5], [yes], [no])])]) 2415]) 2416 2417 2418# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 2419# -------------------------------------------------------- 2420m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 2421 2422 2423# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 2424# ------------------------------------------------ 2425m4_define([lt_decl_tag_varnames], 2426[_lt_decl_filter([tagged?], [yes], $@)]) 2427 2428 2429# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 2430# --------------------------------------------------------- 2431m4_define([_lt_decl_filter], 2432[m4_case([$#], 2433 [0], [m4_fatal([$0: too few arguments: $#])], 2434 [1], [m4_fatal([$0: too few arguments: $#: $1])], 2435 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 2436 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 2437 [lt_dict_filter([lt_decl_dict], $@)])[]dnl 2438]) 2439 2440 2441# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 2442# -------------------------------------------------- 2443m4_define([lt_decl_quote_varnames], 2444[_lt_decl_filter([value], [1], $@)]) 2445 2446 2447# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 2448# --------------------------------------------------- 2449m4_define([lt_decl_dquote_varnames], 2450[_lt_decl_filter([value], [2], $@)]) 2451 2452 2453# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 2454# --------------------------------------------------- 2455m4_define([lt_decl_varnames_tagged], 2456[m4_assert([$# <= 2])dnl 2457_$0(m4_quote(m4_default([$1], [[, ]])), 2458 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 2459 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 2460m4_define([_lt_decl_varnames_tagged], 2461[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 2462 2463 2464# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 2465# ------------------------------------------------ 2466m4_define([lt_decl_all_varnames], 2467[_$0(m4_quote(m4_default([$1], [[, ]])), 2468 m4_if([$2], [], 2469 m4_quote(lt_decl_varnames), 2470 m4_quote(m4_shift($@))))[]dnl 2471]) 2472m4_define([_lt_decl_all_varnames], 2473[lt_join($@, lt_decl_varnames_tagged([$1], 2474 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 2475]) 2476 2477 2478# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 2479# ------------------------------------ 2480# Quote a variable value, and forward it to `config.status' so that its 2481# declaration there will have the same value as in `configure'. VARNAME 2482# must have a single quote delimited value for this to work. 2483m4_define([_LT_CONFIG_STATUS_DECLARE], 2484[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) 2485 2486 2487# _LT_CONFIG_STATUS_DECLARATIONS 2488# ------------------------------ 2489# We delimit libtool config variables with single quotes, so when 2490# we write them to config.status, we have to be sure to quote all 2491# embedded single quotes properly. In configure, this macro expands 2492# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 2493# 2494# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' 2495m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 2496[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 2497 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 2498 2499 2500# _LT_LIBTOOL_TAGS 2501# ---------------- 2502# Output comment and list of tags supported by the script 2503m4_defun([_LT_LIBTOOL_TAGS], 2504[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 2505available_tags="_LT_TAGS"dnl 2506]) 2507 2508 2509# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 2510# ----------------------------------- 2511# Extract the dictionary values for VARNAME (optionally with TAG) and 2512# expand to a commented shell variable setting: 2513# 2514# # Some comment about what VAR is for. 2515# visible_name=$lt_internal_name 2516m4_define([_LT_LIBTOOL_DECLARE], 2517[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 2518 [description])))[]dnl 2519m4_pushdef([_libtool_name], 2520 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 2521m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 2522 [0], [_libtool_name=[$]$1], 2523 [1], [_libtool_name=$lt_[]$1], 2524 [2], [_libtool_name=$lt_[]$1], 2525 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 2526m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 2527]) 2528 2529 2530# _LT_LIBTOOL_CONFIG_VARS 2531# ----------------------- 2532# Produce commented declarations of non-tagged libtool config variables 2533# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' 2534# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 2535# section) are produced by _LT_LIBTOOL_TAG_VARS. 2536m4_defun([_LT_LIBTOOL_CONFIG_VARS], 2537[m4_foreach([_lt_var], 2538 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 2539 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 2540 2541 2542# _LT_LIBTOOL_TAG_VARS(TAG) 2543# ------------------------- 2544m4_define([_LT_LIBTOOL_TAG_VARS], 2545[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 2546 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 2547 2548 2549# _LT_TAGVAR(VARNAME, [TAGNAME]) 2550# ------------------------------ 2551m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 2552 2553 2554# _LT_CONFIG_COMMANDS 2555# ------------------- 2556# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 2557# variables for single and double quote escaping we saved from calls 2558# to _LT_DECL, we can put quote escaped variables declarations 2559# into `config.status', and then the shell code to quote escape them in 2560# for loops in `config.status'. Finally, any additional code accumulated 2561# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 2562m4_defun([_LT_CONFIG_COMMANDS], 2563[AC_PROVIDE_IFELSE([LT_OUTPUT], 2564 dnl If the libtool generation code has been placed in $CONFIG_LT, 2565 dnl instead of duplicating it all over again into config.status, 2566 dnl then we will have config.status run $CONFIG_LT later, so it 2567 dnl needs to know what name is stored there: 2568 [AC_CONFIG_COMMANDS([libtool], 2569 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 2570 dnl If the libtool generation code is destined for config.status, 2571 dnl expand the accumulated commands and init code now: 2572 [AC_CONFIG_COMMANDS([libtool], 2573 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 2574])#_LT_CONFIG_COMMANDS 2575 2576 2577# Initialize. 2578m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 2579[ 2580 2581# The HP-UX ksh and POSIX shell print the target directory to stdout 2582# if CDPATH is set. 2583(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 2584 2585sed_quote_subst='$sed_quote_subst' 2586double_quote_subst='$double_quote_subst' 2587delay_variable_subst='$delay_variable_subst' 2588_LT_CONFIG_STATUS_DECLARATIONS 2589LTCC='$LTCC' 2590LTCFLAGS='$LTCFLAGS' 2591compiler='$compiler_DEFAULT' 2592 2593# A function that is used when there is no print builtin or printf. 2594func_fallback_echo () 2595{ 2596 eval 'cat <<_LTECHO_EOF 2597\$[]1 2598_LTECHO_EOF' 2599} 2600 2601# Quote evaled strings. 2602for var in lt_decl_all_varnames([[ \ 2603]], lt_decl_quote_varnames); do 2604 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 2605 *[[\\\\\\\`\\"\\\$]]*) 2606 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" 2607 ;; 2608 *) 2609 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 2610 ;; 2611 esac 2612done 2613 2614# Double-quote double-evaled strings. 2615for var in lt_decl_all_varnames([[ \ 2616]], lt_decl_dquote_varnames); do 2617 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 2618 *[[\\\\\\\`\\"\\\$]]*) 2619 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" 2620 ;; 2621 *) 2622 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 2623 ;; 2624 esac 2625done 2626 2627_LT_OUTPUT_LIBTOOL_INIT 2628]) 2629 2630# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) 2631# ------------------------------------ 2632# Generate a child script FILE with all initialization necessary to 2633# reuse the environment learned by the parent script, and make the 2634# file executable. If COMMENT is supplied, it is inserted after the 2635# `#!' sequence but before initialization text begins. After this 2636# macro, additional text can be appended to FILE to form the body of 2637# the child script. The macro ends with non-zero status if the 2638# file could not be fully written (such as if the disk is full). 2639m4_ifdef([AS_INIT_GENERATED], 2640[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], 2641[m4_defun([_LT_GENERATED_FILE_INIT], 2642[m4_require([AS_PREPARE])]dnl 2643[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl 2644[lt_write_fail=0 2645cat >$1 <<_ASEOF || lt_write_fail=1 2646#! $SHELL 2647# Generated by $as_me. 2648$2 2649SHELL=\${CONFIG_SHELL-$SHELL} 2650export SHELL 2651_ASEOF 2652cat >>$1 <<\_ASEOF || lt_write_fail=1 2653AS_SHELL_SANITIZE 2654_AS_PREPARE 2655exec AS_MESSAGE_FD>&1 2656_ASEOF 2657test $lt_write_fail = 0 && chmod +x $1[]dnl 2658m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT 2659 2660# LT_OUTPUT 2661# --------- 2662# This macro allows early generation of the libtool script (before 2663# AC_OUTPUT is called), incase it is used in configure for compilation 2664# tests. 2665AC_DEFUN([LT_OUTPUT], 2666[: ${CONFIG_LT=./config.lt} 2667AC_MSG_NOTICE([creating $CONFIG_LT]) 2668_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], 2669[# Run this file to recreate a libtool stub with the current configuration.]) 2670 2671cat >>"$CONFIG_LT" <<\_LTEOF 2672lt_cl_silent=false 2673exec AS_MESSAGE_LOG_FD>>config.log 2674{ 2675 echo 2676 AS_BOX([Running $as_me.]) 2677} >&AS_MESSAGE_LOG_FD 2678 2679lt_cl_help="\ 2680\`$as_me' creates a local libtool stub from the current configuration, 2681for use in further configure time tests before the real libtool is 2682generated. 2683 2684Usage: $[0] [[OPTIONS]] 2685 2686 -h, --help print this help, then exit 2687 -V, --version print version number, then exit 2688 -q, --quiet do not print progress messages 2689 -d, --debug don't remove temporary files 2690 2691Report bugs to <bug-libtool@gnu.org>." 2692 2693lt_cl_version="\ 2694m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 2695m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 2696configured by $[0], generated by m4_PACKAGE_STRING. 2697 2698Copyright (C) 2011 Free Software Foundation, Inc. 2699This config.lt script is free software; the Free Software Foundation 2700gives unlimited permision to copy, distribute and modify it." 2701 2702while test $[#] != 0 2703do 2704 case $[1] in 2705 --version | --v* | -V ) 2706 echo "$lt_cl_version"; exit 0 ;; 2707 --help | --h* | -h ) 2708 echo "$lt_cl_help"; exit 0 ;; 2709 --debug | --d* | -d ) 2710 debug=: ;; 2711 --quiet | --q* | --silent | --s* | -q ) 2712 lt_cl_silent=: ;; 2713 2714 -*) AC_MSG_ERROR([unrecognized option: $[1] 2715Try \`$[0] --help' for more information.]) ;; 2716 2717 *) AC_MSG_ERROR([unrecognized argument: $[1] 2718Try \`$[0] --help' for more information.]) ;; 2719 esac 2720 shift 2721done 2722 2723if $lt_cl_silent; then 2724 exec AS_MESSAGE_FD>/dev/null 2725fi 2726_LTEOF 2727 2728cat >>"$CONFIG_LT" <<_LTEOF 2729_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 2730_LTEOF 2731 2732cat >>"$CONFIG_LT" <<\_LTEOF 2733AC_MSG_NOTICE([creating $ofile]) 2734_LT_OUTPUT_LIBTOOL_COMMANDS 2735AS_EXIT(0) 2736_LTEOF 2737chmod +x "$CONFIG_LT" 2738 2739# configure is writing to config.log, but config.lt does its own redirection, 2740# appending to config.log, which fails on DOS, as config.log is still kept 2741# open by configure. Here we exec the FD to /dev/null, effectively closing 2742# config.log, so it can be properly (re)opened and appended to by config.lt. 2743lt_cl_success=: 2744test "$silent" = yes && 2745 lt_config_lt_args="$lt_config_lt_args --quiet" 2746exec AS_MESSAGE_LOG_FD>/dev/null 2747$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 2748exec AS_MESSAGE_LOG_FD>>config.log 2749$lt_cl_success || AS_EXIT(1) 2750])# LT_OUTPUT 2751 2752 2753# _LT_CONFIG(TAG) 2754# --------------- 2755# If TAG is the built-in tag, create an initial libtool script with a 2756# default configuration from the untagged config vars. Otherwise add code 2757# to config.status for appending the configuration named by TAG from the 2758# matching tagged config vars. 2759m4_defun([_LT_CONFIG], 2760[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2761_LT_CONFIG_SAVE_COMMANDS([ 2762 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 2763 m4_if(_LT_TAG, [C], [ 2764 # See if we are running on zsh, and set the options which allow our 2765 # commands through without removal of \ escapes. 2766 if test -n "${ZSH_VERSION+set}" ; then 2767 setopt NO_GLOB_SUBST 2768 fi 2769 2770 cfgfile="${ofile}T" 2771 trap "$RM \"$cfgfile\"; exit 1" 1 2 15 2772 $RM "$cfgfile" 2773 2774 cat <<_LT_EOF >> "$cfgfile" 2775#! $SHELL 2776 2777# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 2778# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION 2779# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 2780# NOTE: Changes made to this file will be lost: look at ltmain.sh. 2781# 2782_LT_COPYING 2783_LT_LIBTOOL_TAGS 2784 2785# ### BEGIN LIBTOOL CONFIG 2786_LT_LIBTOOL_CONFIG_VARS 2787_LT_LIBTOOL_TAG_VARS 2788# ### END LIBTOOL CONFIG 2789 2790_LT_EOF 2791 2792 case $host_os in 2793 aix3*) 2794 cat <<\_LT_EOF >> "$cfgfile" 2795# AIX sometimes has problems with the GCC collect2 program. For some 2796# reason, if we set the COLLECT_NAMES environment variable, the problems 2797# vanish in a puff of smoke. 2798if test "X${COLLECT_NAMES+set}" != Xset; then 2799 COLLECT_NAMES= 2800 export COLLECT_NAMES 2801fi 2802_LT_EOF 2803 ;; 2804 esac 2805 2806 _LT_PROG_LTMAIN 2807 2808 # We use sed instead of cat because bash on DJGPP gets confused if 2809 # if finds mixed CR/LF and LF-only lines. Since sed operates in 2810 # text mode, it properly converts lines to CR/LF. This bash problem 2811 # is reportedly fixed, but why not run on old versions too? 2812 sed '$q' "$ltmain" >> "$cfgfile" \ 2813 || (rm -f "$cfgfile"; exit 1) 2814 2815 _LT_PROG_REPLACE_SHELLFNS 2816 2817 mv -f "$cfgfile" "$ofile" || 2818 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 2819 chmod +x "$ofile" 2820], 2821[cat <<_LT_EOF >> "$ofile" 2822 2823dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 2824dnl in a comment (ie after a #). 2825# ### BEGIN LIBTOOL TAG CONFIG: $1 2826_LT_LIBTOOL_TAG_VARS(_LT_TAG) 2827# ### END LIBTOOL TAG CONFIG: $1 2828_LT_EOF 2829])dnl /m4_if 2830], 2831[m4_if([$1], [], [ 2832 PACKAGE='$PACKAGE' 2833 VERSION='$VERSION' 2834 TIMESTAMP='$TIMESTAMP' 2835 RM='$RM' 2836 ofile='$ofile'], []) 2837])dnl /_LT_CONFIG_SAVE_COMMANDS 2838])# _LT_CONFIG 2839 2840 2841# LT_SUPPORTED_TAG(TAG) 2842# --------------------- 2843# Trace this macro to discover what tags are supported by the libtool 2844# --tag option, using: 2845# autoconf --trace 'LT_SUPPORTED_TAG:$1' 2846AC_DEFUN([LT_SUPPORTED_TAG], []) 2847 2848 2849# C support is built-in for now 2850m4_define([_LT_LANG_C_enabled], []) 2851m4_define([_LT_TAGS], []) 2852 2853 2854# LT_LANG(LANG) 2855# ------------- 2856# Enable libtool support for the given language if not already enabled. 2857AC_DEFUN([LT_LANG], 2858[AC_BEFORE([$0], [LT_OUTPUT])dnl 2859m4_case([$1], 2860 [C], [_LT_LANG(C)], 2861 [C++], [_LT_LANG(CXX)], 2862 [Go], [_LT_LANG(GO)], 2863 [Java], [_LT_LANG(GCJ)], 2864 [Fortran 77], [_LT_LANG(F77)], 2865 [Fortran], [_LT_LANG(FC)], 2866 [Windows Resource], [_LT_LANG(RC)], 2867 [m4_ifdef([_LT_LANG_]$1[_CONFIG], 2868 [_LT_LANG($1)], 2869 [m4_fatal([$0: unsupported language: "$1"])])])dnl 2870])# LT_LANG 2871 2872 2873# _LT_LANG(LANGNAME) 2874# ------------------ 2875m4_defun([_LT_LANG], 2876[m4_ifdef([_LT_LANG_]$1[_enabled], [], 2877 [LT_SUPPORTED_TAG([$1])dnl 2878 m4_append([_LT_TAGS], [$1 ])dnl 2879 m4_define([_LT_LANG_]$1[_enabled], [])dnl 2880 _LT_LANG_$1_CONFIG($1)])dnl 2881])# _LT_LANG 2882 2883 2884m4_ifndef([AC_PROG_GO], [ 2885# NOTE: This macro has been submitted for inclusion into # 2886# GNU Autoconf as AC_PROG_GO. When it is available in # 2887# a released version of Autoconf we should remove this # 2888# macro and use it instead. # 2889m4_defun([AC_PROG_GO], 2890[AC_LANG_PUSH(Go)dnl 2891AC_ARG_VAR([GOC], [Go compiler command])dnl 2892AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl 2893_AC_ARG_VAR_LDFLAGS()dnl 2894AC_CHECK_TOOL(GOC, gccgo) 2895if test -z "$GOC"; then 2896 if test -n "$ac_tool_prefix"; then 2897 AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) 2898 fi 2899fi 2900if test -z "$GOC"; then 2901 AC_CHECK_PROG(GOC, gccgo, gccgo, false) 2902fi 2903])#m4_defun 2904])#m4_ifndef 2905 2906 2907# _LT_LANG_DEFAULT_CONFIG 2908# ----------------------- 2909m4_defun([_LT_LANG_DEFAULT_CONFIG], 2910[AC_PROVIDE_IFELSE([AC_PROG_CXX], 2911 [LT_LANG(CXX)], 2912 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 2913 2914AC_PROVIDE_IFELSE([AC_PROG_F77], 2915 [LT_LANG(F77)], 2916 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 2917 2918AC_PROVIDE_IFELSE([AC_PROG_FC], 2919 [LT_LANG(FC)], 2920 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 2921 2922dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 2923dnl pulling things in needlessly. 2924AC_PROVIDE_IFELSE([AC_PROG_GCJ], 2925 [LT_LANG(GCJ)], 2926 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 2927 [LT_LANG(GCJ)], 2928 [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 2929 [LT_LANG(GCJ)], 2930 [m4_ifdef([AC_PROG_GCJ], 2931 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 2932 m4_ifdef([A][M_PROG_GCJ], 2933 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 2934 m4_ifdef([LT_PROG_GCJ], 2935 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 2936 2937AC_PROVIDE_IFELSE([AC_PROG_GO], 2938 [LT_LANG(GO)], 2939 [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) 2940 2941AC_PROVIDE_IFELSE([LT_PROG_RC], 2942 [LT_LANG(RC)], 2943 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 2944])# _LT_LANG_DEFAULT_CONFIG 2945 2946# Obsolete macros: 2947AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 2948AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 2949AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 2950AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 2951AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 2952dnl aclocal-1.4 backwards compatibility: 2953dnl AC_DEFUN([AC_LIBTOOL_CXX], []) 2954dnl AC_DEFUN([AC_LIBTOOL_F77], []) 2955dnl AC_DEFUN([AC_LIBTOOL_FC], []) 2956dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 2957dnl AC_DEFUN([AC_LIBTOOL_RC], []) 2958 2959 2960# _LT_TAG_COMPILER 2961# ---------------- 2962m4_defun([_LT_TAG_COMPILER], 2963[AC_REQUIRE([AC_PROG_CC])dnl 2964 2965_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 2966_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 2967_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 2968_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 2969 2970# If no C compiler was specified, use CC. 2971LTCC=${LTCC-"$CC"} 2972 2973# If no C compiler flags were specified, use CFLAGS. 2974LTCFLAGS=${LTCFLAGS-"$CFLAGS"} 2975 2976# Allow CC to be a program name with arguments. 2977compiler=$CC 2978])# _LT_TAG_COMPILER 2979 2980 2981# _LT_COMPILER_BOILERPLATE 2982# ------------------------ 2983# Check for compiler boilerplate output or warnings with 2984# the simple compiler test code. 2985m4_defun([_LT_COMPILER_BOILERPLATE], 2986[m4_require([_LT_DECL_SED])dnl 2987ac_outfile=conftest.$ac_objext 2988echo "$lt_simple_compile_test_code" >conftest.$ac_ext 2989eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 2990_lt_compiler_boilerplate=`cat conftest.err` 2991$RM conftest* 2992])# _LT_COMPILER_BOILERPLATE 2993 2994 2995# _LT_LINKER_BOILERPLATE 2996# ---------------------- 2997# Check for linker boilerplate output or warnings with 2998# the simple link test code. 2999m4_defun([_LT_LINKER_BOILERPLATE], 3000[m4_require([_LT_DECL_SED])dnl 3001ac_outfile=conftest.$ac_objext 3002echo "$lt_simple_link_test_code" >conftest.$ac_ext 3003eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 3004_lt_linker_boilerplate=`cat conftest.err` 3005$RM -r conftest* 3006])# _LT_LINKER_BOILERPLATE 3007 3008# _LT_REQUIRED_DARWIN_CHECKS 3009# ------------------------- 3010m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 3011 case $host_os in 3012 rhapsody* | darwin*) 3013 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 3014 AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 3015 AC_CHECK_TOOL([LIPO], [lipo], [:]) 3016 AC_CHECK_TOOL([OTOOL], [otool], [:]) 3017 AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 3018 _LT_DECL([], [DSYMUTIL], [1], 3019 [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 3020 _LT_DECL([], [NMEDIT], [1], 3021 [Tool to change global to local symbols on Mac OS X]) 3022 _LT_DECL([], [LIPO], [1], 3023 [Tool to manipulate fat objects and archives on Mac OS X]) 3024 _LT_DECL([], [OTOOL], [1], 3025 [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 3026 _LT_DECL([], [OTOOL64], [1], 3027 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 3028 3029 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 3030 [lt_cv_apple_cc_single_mod=no 3031 if test -z "${LT_MULTI_MODULE}"; then 3032 # By default we will add the -single_module flag. You can override 3033 # by either setting the environment variable LT_MULTI_MODULE 3034 # non-empty at configure time, or by adding -multi_module to the 3035 # link flags. 3036 rm -rf libconftest.dylib* 3037 echo "int foo(void){return 1;}" > conftest.c 3038 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 3039-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 3040 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 3041 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 3042 _lt_result=$? 3043 # If there is a non-empty error log, and "single_module" 3044 # appears in it, assume the flag caused a linker warning 3045 if test -s conftest.err && $GREP single_module conftest.err; then 3046 cat conftest.err >&AS_MESSAGE_LOG_FD 3047 # Otherwise, if the output was created with a 0 exit code from 3048 # the compiler, it worked. 3049 elif test -f libconftest.dylib && test $_lt_result -eq 0; then 3050 lt_cv_apple_cc_single_mod=yes 3051 else 3052 cat conftest.err >&AS_MESSAGE_LOG_FD 3053 fi 3054 rm -rf libconftest.dylib* 3055 rm -f conftest.* 3056 fi]) 3057 3058 AC_CACHE_CHECK([for -exported_symbols_list linker flag], 3059 [lt_cv_ld_exported_symbols_list], 3060 [lt_cv_ld_exported_symbols_list=no 3061 save_LDFLAGS=$LDFLAGS 3062 echo "_main" > conftest.sym 3063 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 3064 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 3065 [lt_cv_ld_exported_symbols_list=yes], 3066 [lt_cv_ld_exported_symbols_list=no]) 3067 LDFLAGS="$save_LDFLAGS" 3068 ]) 3069 3070 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], 3071 [lt_cv_ld_force_load=no 3072 cat > conftest.c << _LT_EOF 3073int forced_loaded() { return 2;} 3074_LT_EOF 3075 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD 3076 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD 3077 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD 3078 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD 3079 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD 3080 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD 3081 cat > conftest.c << _LT_EOF 3082int main() { return 0;} 3083_LT_EOF 3084 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD 3085 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err 3086 _lt_result=$? 3087 if test -s conftest.err && $GREP force_load conftest.err; then 3088 cat conftest.err >&AS_MESSAGE_LOG_FD 3089 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then 3090 lt_cv_ld_force_load=yes 3091 else 3092 cat conftest.err >&AS_MESSAGE_LOG_FD 3093 fi 3094 rm -f conftest.err libconftest.a conftest conftest.c 3095 rm -rf conftest.dSYM 3096 ]) 3097 case $host_os in 3098 rhapsody* | darwin1.[[012]]) 3099 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 3100 darwin1.*) 3101 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 3102 darwin*) # darwin 5.x on 3103 # if running on 10.5 or later, the deployment target defaults 3104 # to the OS version, if on x86, and 10.4, the deployment 3105 # target defaults to 10.4. Don't you love it? 3106 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 3107 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 3108 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 3109 10.[[012]]*) 3110 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 3111 10.*) 3112 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 3113 esac 3114 ;; 3115 esac 3116 if test "$lt_cv_apple_cc_single_mod" = "yes"; then 3117 _lt_dar_single_mod='$single_module' 3118 fi 3119 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 3120 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 3121 else 3122 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' 3123 fi 3124 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then 3125 _lt_dsymutil='~$DSYMUTIL $lib || :' 3126 else 3127 _lt_dsymutil= 3128 fi 3129 ;; 3130 esac 3131]) 3132 3133 3134# _LT_DARWIN_LINKER_FEATURES([TAG]) 3135# --------------------------------- 3136# Checks for linker and compiler features on darwin 3137m4_defun([_LT_DARWIN_LINKER_FEATURES], 3138[ 3139 m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 3140 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 3141 _LT_TAGVAR(hardcode_direct, $1)=no 3142 _LT_TAGVAR(hardcode_automatic, $1)=yes 3143 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 3144 if test "$lt_cv_ld_force_load" = "yes"; then 3145 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' 3146 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], 3147 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) 3148 else 3149 _LT_TAGVAR(whole_archive_flag_spec, $1)='' 3150 fi 3151 _LT_TAGVAR(link_all_deplibs, $1)=yes 3152 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 3153 case $cc_basename in 3154 ifort*) _lt_dar_can_shared=yes ;; 3155 *) _lt_dar_can_shared=$GCC ;; 3156 esac 3157 if test "$_lt_dar_can_shared" = "yes"; then 3158 output_verbose_link_cmd=func_echo_all 3159 _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}" 3160 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 3161 _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}" 3162 _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}" 3163 m4_if([$1], [CXX], 3164[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then 3165 _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}" 3166 _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}" 3167 fi 3168],[]) 3169 else 3170 _LT_TAGVAR(ld_shlibs, $1)=no 3171 fi 3172]) 3173 3174# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) 3175# ---------------------------------- 3176# Links a minimal program and checks the executable 3177# for the system default hardcoded library path. In most cases, 3178# this is /usr/lib:/lib, but when the MPI compilers are used 3179# the location of the communication and MPI libs are included too. 3180# If we don't find anything, use the default library path according 3181# to the aix ld manual. 3182# Store the results from the different compilers for each TAGNAME. 3183# Allow to override them for all tags through lt_cv_aix_libpath. 3184m4_defun([_LT_SYS_MODULE_PATH_AIX], 3185[m4_require([_LT_DECL_SED])dnl 3186if test "${lt_cv_aix_libpath+set}" = set; then 3187 aix_libpath=$lt_cv_aix_libpath 3188else 3189 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], 3190 [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ 3191 lt_aix_libpath_sed='[ 3192 /Import File Strings/,/^$/ { 3193 /^0/ { 3194 s/^0 *\([^ ]*\) *$/\1/ 3195 p 3196 } 3197 }]' 3198 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3199 # Check for a 64-bit object if we didn't find anything. 3200 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 3201 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3202 fi],[]) 3203 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 3204 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" 3205 fi 3206 ]) 3207 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) 3208fi 3209])# _LT_SYS_MODULE_PATH_AIX 3210 3211 3212# _LT_SHELL_INIT(ARG) 3213# ------------------- 3214m4_define([_LT_SHELL_INIT], 3215[m4_divert_text([M4SH-INIT], [$1 3216])])# _LT_SHELL_INIT 3217 3218 3219 3220# _LT_PROG_ECHO_BACKSLASH 3221# ----------------------- 3222# Find how we can fake an echo command that does not interpret backslash. 3223# In particular, with Autoconf 2.60 or later we add some code to the start 3224# of the generated configure script which will find a shell with a builtin 3225# printf (which we can use as an echo command). 3226m4_defun([_LT_PROG_ECHO_BACKSLASH], 3227[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 3228ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 3229ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 3230 3231AC_MSG_CHECKING([how to print strings]) 3232# Test print first, because it will be a builtin if present. 3233if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ 3234 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then 3235 ECHO='print -r --' 3236elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then 3237 ECHO='printf %s\n' 3238else 3239 # Use this function as a fallback that always works. 3240 func_fallback_echo () 3241 { 3242 eval 'cat <<_LTECHO_EOF 3243$[]1 3244_LTECHO_EOF' 3245 } 3246 ECHO='func_fallback_echo' 3247fi 3248 3249# func_echo_all arg... 3250# Invoke $ECHO with all args, space-separated. 3251func_echo_all () 3252{ 3253 $ECHO "$*" 3254} 3255 3256case "$ECHO" in 3257 printf*) AC_MSG_RESULT([printf]) ;; 3258 print*) AC_MSG_RESULT([print -r]) ;; 3259 *) AC_MSG_RESULT([cat]) ;; 3260esac 3261 3262m4_ifdef([_AS_DETECT_SUGGESTED], 3263[_AS_DETECT_SUGGESTED([ 3264 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( 3265 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 3266 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 3267 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 3268 PATH=/empty FPATH=/empty; export PATH FPATH 3269 test "X`printf %s $ECHO`" = "X$ECHO" \ 3270 || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) 3271 3272_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 3273_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) 3274])# _LT_PROG_ECHO_BACKSLASH 3275 3276 3277# _LT_WITH_SYSROOT 3278# ---------------- 3279AC_DEFUN([_LT_WITH_SYSROOT], 3280[AC_MSG_CHECKING([for sysroot]) 3281AC_ARG_WITH([sysroot], 3282[ --with-sysroot[=DIR] Search for dependent libraries within DIR 3283 (or the compiler's sysroot if not specified).], 3284[], [with_sysroot=no]) 3285 3286dnl lt_sysroot will always be passed unquoted. We quote it here 3287dnl in case the user passed a directory name. 3288lt_sysroot= 3289case ${with_sysroot} in #( 3290 yes) 3291 if test "$GCC" = yes; then 3292 lt_sysroot=`$CC --print-sysroot 2>/dev/null` 3293 fi 3294 ;; #( 3295 /*) 3296 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` 3297 ;; #( 3298 no|'') 3299 ;; #( 3300 *) 3301 AC_MSG_RESULT([${with_sysroot}]) 3302 AC_MSG_ERROR([The sysroot must be an absolute path.]) 3303 ;; 3304esac 3305 3306 AC_MSG_RESULT([${lt_sysroot:-no}]) 3307_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl 3308[dependent libraries, and in which our libraries should be installed.])]) 3309 3310# _LT_ENABLE_LOCK 3311# --------------- 3312m4_defun([_LT_ENABLE_LOCK], 3313[AC_ARG_ENABLE([libtool-lock], 3314 [AS_HELP_STRING([--disable-libtool-lock], 3315 [avoid locking (might break parallel builds)])]) 3316test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 3317 3318# Some flags need to be propagated to the compiler or linker for good 3319# libtool support. 3320case $host in 3321ia64-*-hpux*) 3322 # Find out which ABI we are using. 3323 echo 'int i;' > conftest.$ac_ext 3324 if AC_TRY_EVAL(ac_compile); then 3325 case `/usr/bin/file conftest.$ac_objext` in 3326 *ELF-32*) 3327 HPUX_IA64_MODE="32" 3328 ;; 3329 *ELF-64*) 3330 HPUX_IA64_MODE="64" 3331 ;; 3332 esac 3333 fi 3334 rm -rf conftest* 3335 ;; 3336*-*-irix6*) 3337 # Find out which ABI we are using. 3338 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 3339 if AC_TRY_EVAL(ac_compile); then 3340 if test "$lt_cv_prog_gnu_ld" = yes; then 3341 case `/usr/bin/file conftest.$ac_objext` in 3342 *32-bit*) 3343 LD="${LD-ld} -melf32bsmip" 3344 ;; 3345 *N32*) 3346 LD="${LD-ld} -melf32bmipn32" 3347 ;; 3348 *64-bit*) 3349 LD="${LD-ld} -melf64bmip" 3350 ;; 3351 esac 3352 else 3353 case `/usr/bin/file conftest.$ac_objext` in 3354 *32-bit*) 3355 LD="${LD-ld} -32" 3356 ;; 3357 *N32*) 3358 LD="${LD-ld} -n32" 3359 ;; 3360 *64-bit*) 3361 LD="${LD-ld} -64" 3362 ;; 3363 esac 3364 fi 3365 fi 3366 rm -rf conftest* 3367 ;; 3368 3369x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ 3370s390*-*linux*|s390*-*tpf*|sparc*-*linux*) 3371 # Find out which ABI we are using. 3372 echo 'int i;' > conftest.$ac_ext 3373 if AC_TRY_EVAL(ac_compile); then 3374 case `/usr/bin/file conftest.o` in 3375 *32-bit*) 3376 case $host in 3377 x86_64-*kfreebsd*-gnu) 3378 LD="${LD-ld} -m elf_i386_fbsd" 3379 ;; 3380 x86_64-*linux*) 3381 LD="${LD-ld} -m elf_i386" 3382 ;; 3383 powerpc64le-*linux*) 3384 LD="${LD-ld} -m elf32lppclinux" 3385 ;; 3386 powerpc64-*linux*) 3387 LD="${LD-ld} -m elf32ppclinux" 3388 ;; 3389 s390x-*linux*) 3390 LD="${LD-ld} -m elf_s390" 3391 ;; 3392 sparc64-*linux*) 3393 LD="${LD-ld} -m elf32_sparc" 3394 ;; 3395 esac 3396 ;; 3397 *64-bit*) 3398 case $host in 3399 x86_64-*kfreebsd*-gnu) 3400 LD="${LD-ld} -m elf_x86_64_fbsd" 3401 ;; 3402 x86_64-*linux*) 3403 LD="${LD-ld} -m elf_x86_64" 3404 ;; 3405 powerpcle-*linux*) 3406 LD="${LD-ld} -m elf64lppc" 3407 ;; 3408 powerpc-*linux*) 3409 LD="${LD-ld} -m elf64ppc" 3410 ;; 3411 s390*-*linux*|s390*-*tpf*) 3412 LD="${LD-ld} -m elf64_s390" 3413 ;; 3414 sparc*-*linux*) 3415 LD="${LD-ld} -m elf64_sparc" 3416 ;; 3417 esac 3418 ;; 3419 esac 3420 fi 3421 rm -rf conftest* 3422 ;; 3423 3424*-*-sco3.2v5*) 3425 # On SCO OpenServer 5, we need -belf to get full-featured binaries. 3426 SAVE_CFLAGS="$CFLAGS" 3427 CFLAGS="$CFLAGS -belf" 3428 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 3429 [AC_LANG_PUSH(C) 3430 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 3431 AC_LANG_POP]) 3432 if test x"$lt_cv_cc_needs_belf" != x"yes"; then 3433 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 3434 CFLAGS="$SAVE_CFLAGS" 3435 fi 3436 ;; 3437*-*solaris*) 3438 # Find out which ABI we are using. 3439 echo 'int i;' > conftest.$ac_ext 3440 if AC_TRY_EVAL(ac_compile); then 3441 case `/usr/bin/file conftest.o` in 3442 *64-bit*) 3443 case $lt_cv_prog_gnu_ld in 3444 yes*) 3445 case $host in 3446 i?86-*-solaris*) 3447 LD="${LD-ld} -m elf_x86_64" 3448 ;; 3449 sparc*-*-solaris*) 3450 LD="${LD-ld} -m elf64_sparc" 3451 ;; 3452 esac 3453 # GNU ld 2.21 introduced _sol2 emulations. Use them if available. 3454 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then 3455 LD="${LD-ld}_sol2" 3456 fi 3457 ;; 3458 *) 3459 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 3460 LD="${LD-ld} -64" 3461 fi 3462 ;; 3463 esac 3464 ;; 3465 esac 3466 fi 3467 rm -rf conftest* 3468 ;; 3469esac 3470 3471need_locks="$enable_libtool_lock" 3472])# _LT_ENABLE_LOCK 3473 3474 3475# _LT_PROG_AR 3476# ----------- 3477m4_defun([_LT_PROG_AR], 3478[AC_CHECK_TOOLS(AR, [ar], false) 3479: ${AR=ar} 3480: ${AR_FLAGS=cru} 3481_LT_DECL([], [AR], [1], [The archiver]) 3482_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) 3483 3484AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], 3485 [lt_cv_ar_at_file=no 3486 AC_COMPILE_IFELSE([AC_LANG_PROGRAM], 3487 [echo conftest.$ac_objext > conftest.lst 3488 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' 3489 AC_TRY_EVAL([lt_ar_try]) 3490 if test "$ac_status" -eq 0; then 3491 # Ensure the archiver fails upon bogus file names. 3492 rm -f conftest.$ac_objext libconftest.a 3493 AC_TRY_EVAL([lt_ar_try]) 3494 if test "$ac_status" -ne 0; then 3495 lt_cv_ar_at_file=@ 3496 fi 3497 fi 3498 rm -f conftest.* libconftest.a 3499 ]) 3500 ]) 3501 3502if test "x$lt_cv_ar_at_file" = xno; then 3503 archiver_list_spec= 3504else 3505 archiver_list_spec=$lt_cv_ar_at_file 3506fi 3507_LT_DECL([], [archiver_list_spec], [1], 3508 [How to feed a file listing to the archiver]) 3509])# _LT_PROG_AR 3510 3511 3512# _LT_CMD_OLD_ARCHIVE 3513# ------------------- 3514m4_defun([_LT_CMD_OLD_ARCHIVE], 3515[_LT_PROG_AR 3516 3517AC_CHECK_TOOL(STRIP, strip, :) 3518test -z "$STRIP" && STRIP=: 3519_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 3520 3521AC_CHECK_TOOL(RANLIB, ranlib, :) 3522test -z "$RANLIB" && RANLIB=: 3523_LT_DECL([], [RANLIB], [1], 3524 [Commands used to install an old-style archive]) 3525 3526# Determine commands to create old-style static archives. 3527old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 3528old_postinstall_cmds='chmod 644 $oldlib' 3529old_postuninstall_cmds= 3530 3531if test -n "$RANLIB"; then 3532 case $host_os in 3533 openbsd*) 3534 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" 3535 ;; 3536 *) 3537 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" 3538 ;; 3539 esac 3540 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" 3541fi 3542 3543case $host_os in 3544 darwin*) 3545 lock_old_archive_extraction=yes ;; 3546 *) 3547 lock_old_archive_extraction=no ;; 3548esac 3549_LT_DECL([], [old_postinstall_cmds], [2]) 3550_LT_DECL([], [old_postuninstall_cmds], [2]) 3551_LT_TAGDECL([], [old_archive_cmds], [2], 3552 [Commands used to build an old-style archive]) 3553_LT_DECL([], [lock_old_archive_extraction], [0], 3554 [Whether to use a lock for old archive extraction]) 3555])# _LT_CMD_OLD_ARCHIVE 3556 3557 3558# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 3559# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 3560# ---------------------------------------------------------------- 3561# Check whether the given compiler option works 3562AC_DEFUN([_LT_COMPILER_OPTION], 3563[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3564m4_require([_LT_DECL_SED])dnl 3565AC_CACHE_CHECK([$1], [$2], 3566 [$2=no 3567 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 3568 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 3569 lt_compiler_flag="$3" 3570 # Insert the option either (1) after the last *FLAGS variable, or 3571 # (2) before a word containing "conftest.", or (3) at the end. 3572 # Note that $ac_compile itself does not contain backslashes and begins 3573 # with a dollar sign (not a hyphen), so the echo should work correctly. 3574 # The option is referenced via a variable to avoid confusing sed. 3575 lt_compile=`echo "$ac_compile" | $SED \ 3576 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 3577 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 3578 -e 's:$: $lt_compiler_flag:'` 3579 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 3580 (eval "$lt_compile" 2>conftest.err) 3581 ac_status=$? 3582 cat conftest.err >&AS_MESSAGE_LOG_FD 3583 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 3584 if (exit $ac_status) && test -s "$ac_outfile"; then 3585 # The compiler can only warn and ignore the option if not recognized 3586 # So say no if there are warnings other than the usual output. 3587 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp 3588 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 3589 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 3590 $2=yes 3591 fi 3592 fi 3593 $RM conftest* 3594]) 3595 3596if test x"[$]$2" = xyes; then 3597 m4_if([$5], , :, [$5]) 3598else 3599 m4_if([$6], , :, [$6]) 3600fi 3601])# _LT_COMPILER_OPTION 3602 3603# Old name: 3604AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 3605dnl aclocal-1.4 backwards compatibility: 3606dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 3607 3608 3609# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 3610# [ACTION-SUCCESS], [ACTION-FAILURE]) 3611# ---------------------------------------------------- 3612# Check whether the given linker option works 3613AC_DEFUN([_LT_LINKER_OPTION], 3614[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3615m4_require([_LT_DECL_SED])dnl 3616AC_CACHE_CHECK([$1], [$2], 3617 [$2=no 3618 save_LDFLAGS="$LDFLAGS" 3619 LDFLAGS="$LDFLAGS $3" 3620 echo "$lt_simple_link_test_code" > conftest.$ac_ext 3621 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 3622 # The linker can only warn and ignore the option if not recognized 3623 # So say no if there are warnings 3624 if test -s conftest.err; then 3625 # Append any errors to the config.log. 3626 cat conftest.err 1>&AS_MESSAGE_LOG_FD 3627 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp 3628 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 3629 if diff conftest.exp conftest.er2 >/dev/null; then 3630 $2=yes 3631 fi 3632 else 3633 $2=yes 3634 fi 3635 fi 3636 $RM -r conftest* 3637 LDFLAGS="$save_LDFLAGS" 3638]) 3639 3640if test x"[$]$2" = xyes; then 3641 m4_if([$4], , :, [$4]) 3642else 3643 m4_if([$5], , :, [$5]) 3644fi 3645])# _LT_LINKER_OPTION 3646 3647# Old name: 3648AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 3649dnl aclocal-1.4 backwards compatibility: 3650dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 3651 3652 3653# LT_CMD_MAX_LEN 3654#--------------- 3655AC_DEFUN([LT_CMD_MAX_LEN], 3656[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3657# find the maximum length of command line arguments 3658AC_MSG_CHECKING([the maximum length of command line arguments]) 3659AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 3660 i=0 3661 teststring="ABCD" 3662 3663 case $build_os in 3664 msdosdjgpp*) 3665 # On DJGPP, this test can blow up pretty badly due to problems in libc 3666 # (any single argument exceeding 2000 bytes causes a buffer overrun 3667 # during glob expansion). Even if it were fixed, the result of this 3668 # check would be larger than it should be. 3669 lt_cv_sys_max_cmd_len=12288; # 12K is about right 3670 ;; 3671 3672 gnu*) 3673 # Under GNU Hurd, this test is not required because there is 3674 # no limit to the length of command line arguments. 3675 # Libtool will interpret -1 as no limit whatsoever 3676 lt_cv_sys_max_cmd_len=-1; 3677 ;; 3678 3679 cygwin* | mingw* | cegcc*) 3680 # On Win9x/ME, this test blows up -- it succeeds, but takes 3681 # about 5 minutes as the teststring grows exponentially. 3682 # Worse, since 9x/ME are not pre-emptively multitasking, 3683 # you end up with a "frozen" computer, even though with patience 3684 # the test eventually succeeds (with a max line length of 256k). 3685 # Instead, let's just punt: use the minimum linelength reported by 3686 # all of the supported platforms: 8192 (on NT/2K/XP). 3687 lt_cv_sys_max_cmd_len=8192; 3688 ;; 3689 3690 mint*) 3691 # On MiNT this can take a long time and run out of memory. 3692 lt_cv_sys_max_cmd_len=8192; 3693 ;; 3694 3695 amigaos*) 3696 # On AmigaOS with pdksh, this test takes hours, literally. 3697 # So we just punt and use a minimum line length of 8192. 3698 lt_cv_sys_max_cmd_len=8192; 3699 ;; 3700 3701 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 3702 # This has been around since 386BSD, at least. Likely further. 3703 if test -x /sbin/sysctl; then 3704 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 3705 elif test -x /usr/sbin/sysctl; then 3706 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 3707 else 3708 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 3709 fi 3710 # And add a safety zone 3711 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 3712 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 3713 ;; 3714 3715 interix*) 3716 # We know the value 262144 and hardcode it with a safety zone (like BSD) 3717 lt_cv_sys_max_cmd_len=196608 3718 ;; 3719 3720 os2*) 3721 # The test takes a long time on OS/2. 3722 lt_cv_sys_max_cmd_len=8192 3723 ;; 3724 3725 osf*) 3726 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 3727 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 3728 # nice to cause kernel panics so lets avoid the loop below. 3729 # First set a reasonable default. 3730 lt_cv_sys_max_cmd_len=16384 3731 # 3732 if test -x /sbin/sysconfig; then 3733 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 3734 *1*) lt_cv_sys_max_cmd_len=-1 ;; 3735 esac 3736 fi 3737 ;; 3738 sco3.2v5*) 3739 lt_cv_sys_max_cmd_len=102400 3740 ;; 3741 sysv5* | sco5v6* | sysv4.2uw2*) 3742 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 3743 if test -n "$kargmax"; then 3744 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 3745 else 3746 lt_cv_sys_max_cmd_len=32768 3747 fi 3748 ;; 3749 *) 3750 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 3751 if test -n "$lt_cv_sys_max_cmd_len"; then 3752 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 3753 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 3754 else 3755 # Make teststring a little bigger before we do anything with it. 3756 # a 1K string should be a reasonable start. 3757 for i in 1 2 3 4 5 6 7 8 ; do 3758 teststring=$teststring$teststring 3759 done 3760 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 3761 # If test is not a shell built-in, we'll probably end up computing a 3762 # maximum length that is only half of the actual maximum length, but 3763 # we can't tell. 3764 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ 3765 = "X$teststring$teststring"; } >/dev/null 2>&1 && 3766 test $i != 17 # 1/2 MB should be enough 3767 do 3768 i=`expr $i + 1` 3769 teststring=$teststring$teststring 3770 done 3771 # Only check the string length outside the loop. 3772 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 3773 teststring= 3774 # Add a significant safety factor because C++ compilers can tack on 3775 # massive amounts of additional arguments before passing them to the 3776 # linker. It appears as though 1/2 is a usable value. 3777 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 3778 fi 3779 ;; 3780 esac 3781]) 3782if test -n $lt_cv_sys_max_cmd_len ; then 3783 AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 3784else 3785 AC_MSG_RESULT(none) 3786fi 3787max_cmd_len=$lt_cv_sys_max_cmd_len 3788_LT_DECL([], [max_cmd_len], [0], 3789 [What is the maximum length of a command?]) 3790])# LT_CMD_MAX_LEN 3791 3792# Old name: 3793AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 3794dnl aclocal-1.4 backwards compatibility: 3795dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 3796 3797 3798# _LT_HEADER_DLFCN 3799# ---------------- 3800m4_defun([_LT_HEADER_DLFCN], 3801[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 3802])# _LT_HEADER_DLFCN 3803 3804 3805# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 3806# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 3807# ---------------------------------------------------------------- 3808m4_defun([_LT_TRY_DLOPEN_SELF], 3809[m4_require([_LT_HEADER_DLFCN])dnl 3810if test "$cross_compiling" = yes; then : 3811 [$4] 3812else 3813 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 3814 lt_status=$lt_dlunknown 3815 cat > conftest.$ac_ext <<_LT_EOF 3816[#line $LINENO "configure" 3817#include "confdefs.h" 3818 3819#if HAVE_DLFCN_H 3820#include <dlfcn.h> 3821#endif 3822 3823#include <stdio.h> 3824 3825#ifdef RTLD_GLOBAL 3826# define LT_DLGLOBAL RTLD_GLOBAL 3827#else 3828# ifdef DL_GLOBAL 3829# define LT_DLGLOBAL DL_GLOBAL 3830# else 3831# define LT_DLGLOBAL 0 3832# endif 3833#endif 3834 3835/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 3836 find out it does not work in some platform. */ 3837#ifndef LT_DLLAZY_OR_NOW 3838# ifdef RTLD_LAZY 3839# define LT_DLLAZY_OR_NOW RTLD_LAZY 3840# else 3841# ifdef DL_LAZY 3842# define LT_DLLAZY_OR_NOW DL_LAZY 3843# else 3844# ifdef RTLD_NOW 3845# define LT_DLLAZY_OR_NOW RTLD_NOW 3846# else 3847# ifdef DL_NOW 3848# define LT_DLLAZY_OR_NOW DL_NOW 3849# else 3850# define LT_DLLAZY_OR_NOW 0 3851# endif 3852# endif 3853# endif 3854# endif 3855#endif 3856 3857/* When -fvisbility=hidden is used, assume the code has been annotated 3858 correspondingly for the symbols needed. */ 3859#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) 3860int fnord () __attribute__((visibility("default"))); 3861#endif 3862 3863int fnord () { return 42; } 3864int main () 3865{ 3866 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 3867 int status = $lt_dlunknown; 3868 3869 if (self) 3870 { 3871 if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 3872 else 3873 { 3874 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 3875 else puts (dlerror ()); 3876 } 3877 /* dlclose (self); */ 3878 } 3879 else 3880 puts (dlerror ()); 3881 3882 return status; 3883}] 3884_LT_EOF 3885 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 3886 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 3887 lt_status=$? 3888 case x$lt_status in 3889 x$lt_dlno_uscore) $1 ;; 3890 x$lt_dlneed_uscore) $2 ;; 3891 x$lt_dlunknown|x*) $3 ;; 3892 esac 3893 else : 3894 # compilation failed 3895 $3 3896 fi 3897fi 3898rm -fr conftest* 3899])# _LT_TRY_DLOPEN_SELF 3900 3901 3902# LT_SYS_DLOPEN_SELF 3903# ------------------ 3904AC_DEFUN([LT_SYS_DLOPEN_SELF], 3905[m4_require([_LT_HEADER_DLFCN])dnl 3906if test "x$enable_dlopen" != xyes; then 3907 enable_dlopen=unknown 3908 enable_dlopen_self=unknown 3909 enable_dlopen_self_static=unknown 3910else 3911 lt_cv_dlopen=no 3912 lt_cv_dlopen_libs= 3913 3914 case $host_os in 3915 beos*) 3916 lt_cv_dlopen="load_add_on" 3917 lt_cv_dlopen_libs= 3918 lt_cv_dlopen_self=yes 3919 ;; 3920 3921 mingw* | pw32* | cegcc*) 3922 lt_cv_dlopen="LoadLibrary" 3923 lt_cv_dlopen_libs= 3924 ;; 3925 3926 cygwin*) 3927 lt_cv_dlopen="dlopen" 3928 lt_cv_dlopen_libs= 3929 ;; 3930 3931 darwin*) 3932 # if libdl is installed we need to link against it 3933 AC_CHECK_LIB([dl], [dlopen], 3934 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 3935 lt_cv_dlopen="dyld" 3936 lt_cv_dlopen_libs= 3937 lt_cv_dlopen_self=yes 3938 ]) 3939 ;; 3940 3941 *) 3942 AC_CHECK_FUNC([shl_load], 3943 [lt_cv_dlopen="shl_load"], 3944 [AC_CHECK_LIB([dld], [shl_load], 3945 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 3946 [AC_CHECK_FUNC([dlopen], 3947 [lt_cv_dlopen="dlopen"], 3948 [AC_CHECK_LIB([dl], [dlopen], 3949 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 3950 [AC_CHECK_LIB([svld], [dlopen], 3951 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 3952 [AC_CHECK_LIB([dld], [dld_link], 3953 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 3954 ]) 3955 ]) 3956 ]) 3957 ]) 3958 ]) 3959 ;; 3960 esac 3961 3962 if test "x$lt_cv_dlopen" != xno; then 3963 enable_dlopen=yes 3964 else 3965 enable_dlopen=no 3966 fi 3967 3968 case $lt_cv_dlopen in 3969 dlopen) 3970 save_CPPFLAGS="$CPPFLAGS" 3971 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 3972 3973 save_LDFLAGS="$LDFLAGS" 3974 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 3975 3976 save_LIBS="$LIBS" 3977 LIBS="$lt_cv_dlopen_libs $LIBS" 3978 3979 AC_CACHE_CHECK([whether a program can dlopen itself], 3980 lt_cv_dlopen_self, [dnl 3981 _LT_TRY_DLOPEN_SELF( 3982 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 3983 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 3984 ]) 3985 3986 if test "x$lt_cv_dlopen_self" = xyes; then 3987 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 3988 AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 3989 lt_cv_dlopen_self_static, [dnl 3990 _LT_TRY_DLOPEN_SELF( 3991 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 3992 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 3993 ]) 3994 fi 3995 3996 CPPFLAGS="$save_CPPFLAGS" 3997 LDFLAGS="$save_LDFLAGS" 3998 LIBS="$save_LIBS" 3999 ;; 4000 esac 4001 4002 case $lt_cv_dlopen_self in 4003 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 4004 *) enable_dlopen_self=unknown ;; 4005 esac 4006 4007 case $lt_cv_dlopen_self_static in 4008 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 4009 *) enable_dlopen_self_static=unknown ;; 4010 esac 4011fi 4012_LT_DECL([dlopen_support], [enable_dlopen], [0], 4013 [Whether dlopen is supported]) 4014_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 4015 [Whether dlopen of programs is supported]) 4016_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 4017 [Whether dlopen of statically linked programs is supported]) 4018])# LT_SYS_DLOPEN_SELF 4019 4020# Old name: 4021AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 4022dnl aclocal-1.4 backwards compatibility: 4023dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 4024 4025 4026# _LT_COMPILER_C_O([TAGNAME]) 4027# --------------------------- 4028# Check to see if options -c and -o are simultaneously supported by compiler. 4029# This macro does not hard code the compiler like AC_PROG_CC_C_O. 4030m4_defun([_LT_COMPILER_C_O], 4031[m4_require([_LT_DECL_SED])dnl 4032m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4033m4_require([_LT_TAG_COMPILER])dnl 4034AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 4035 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 4036 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 4037 $RM -r conftest 2>/dev/null 4038 mkdir conftest 4039 cd conftest 4040 mkdir out 4041 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 4042 4043 lt_compiler_flag="-o out/conftest2.$ac_objext" 4044 # Insert the option either (1) after the last *FLAGS variable, or 4045 # (2) before a word containing "conftest.", or (3) at the end. 4046 # Note that $ac_compile itself does not contain backslashes and begins 4047 # with a dollar sign (not a hyphen), so the echo should work correctly. 4048 lt_compile=`echo "$ac_compile" | $SED \ 4049 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 4050 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 4051 -e 's:$: $lt_compiler_flag:'` 4052 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 4053 (eval "$lt_compile" 2>out/conftest.err) 4054 ac_status=$? 4055 cat out/conftest.err >&AS_MESSAGE_LOG_FD 4056 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 4057 if (exit $ac_status) && test -s out/conftest2.$ac_objext 4058 then 4059 # The compiler can only warn and ignore the option if not recognized 4060 # So say no if there are warnings 4061 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp 4062 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 4063 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 4064 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 4065 fi 4066 fi 4067 chmod u+w . 2>&AS_MESSAGE_LOG_FD 4068 $RM conftest* 4069 # SGI C++ compiler will create directory out/ii_files/ for 4070 # template instantiation 4071 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 4072 $RM out/* && rmdir out 4073 cd .. 4074 $RM -r conftest 4075 $RM conftest* 4076]) 4077_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 4078 [Does compiler simultaneously support -c and -o options?]) 4079])# _LT_COMPILER_C_O 4080 4081 4082# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 4083# ---------------------------------- 4084# Check to see if we can do hard links to lock some files if needed 4085m4_defun([_LT_COMPILER_FILE_LOCKS], 4086[m4_require([_LT_ENABLE_LOCK])dnl 4087m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4088_LT_COMPILER_C_O([$1]) 4089 4090hard_links="nottested" 4091if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 4092 # do not overwrite the value of need_locks provided by the user 4093 AC_MSG_CHECKING([if we can lock with hard links]) 4094 hard_links=yes 4095 $RM conftest* 4096 ln conftest.a conftest.b 2>/dev/null && hard_links=no 4097 touch conftest.a 4098 ln conftest.a conftest.b 2>&5 || hard_links=no 4099 ln conftest.a conftest.b 2>/dev/null && hard_links=no 4100 AC_MSG_RESULT([$hard_links]) 4101 if test "$hard_links" = no; then 4102 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 4103 need_locks=warn 4104 fi 4105else 4106 need_locks=no 4107fi 4108_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 4109])# _LT_COMPILER_FILE_LOCKS 4110 4111 4112# _LT_CHECK_OBJDIR 4113# ---------------- 4114m4_defun([_LT_CHECK_OBJDIR], 4115[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 4116[rm -f .libs 2>/dev/null 4117mkdir .libs 2>/dev/null 4118if test -d .libs; then 4119 lt_cv_objdir=.libs 4120else 4121 # MS-DOS does not allow filenames that begin with a dot. 4122 lt_cv_objdir=_libs 4123fi 4124rmdir .libs 2>/dev/null]) 4125objdir=$lt_cv_objdir 4126_LT_DECL([], [objdir], [0], 4127 [The name of the directory that contains temporary libtool files])dnl 4128m4_pattern_allow([LT_OBJDIR])dnl 4129AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", 4130 [Define to the sub-directory in which libtool stores uninstalled libraries.]) 4131])# _LT_CHECK_OBJDIR 4132 4133 4134# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 4135# -------------------------------------- 4136# Check hardcoding attributes. 4137m4_defun([_LT_LINKER_HARDCODE_LIBPATH], 4138[AC_MSG_CHECKING([how to hardcode library paths into programs]) 4139_LT_TAGVAR(hardcode_action, $1)= 4140if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 4141 test -n "$_LT_TAGVAR(runpath_var, $1)" || 4142 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 4143 4144 # We can hardcode non-existent directories. 4145 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && 4146 # If the only mechanism to avoid hardcoding is shlibpath_var, we 4147 # have to relink, otherwise we might link with an installed library 4148 # when we should be linking with a yet-to-be-installed one 4149 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && 4150 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then 4151 # Linking always hardcodes the temporary library directory. 4152 _LT_TAGVAR(hardcode_action, $1)=relink 4153 else 4154 # We can link without hardcoding, and we can hardcode nonexisting dirs. 4155 _LT_TAGVAR(hardcode_action, $1)=immediate 4156 fi 4157else 4158 # We cannot hardcode anything, or else we can only hardcode existing 4159 # directories. 4160 _LT_TAGVAR(hardcode_action, $1)=unsupported 4161fi 4162AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 4163 4164if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || 4165 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then 4166 # Fast installation is not supported 4167 enable_fast_install=no 4168elif test "$shlibpath_overrides_runpath" = yes || 4169 test "$enable_shared" = no; then 4170 # Fast installation is not necessary 4171 enable_fast_install=needless 4172fi 4173_LT_TAGDECL([], [hardcode_action], [0], 4174 [How to hardcode a shared library path into an executable]) 4175])# _LT_LINKER_HARDCODE_LIBPATH 4176 4177 4178# _LT_CMD_STRIPLIB 4179# ---------------- 4180m4_defun([_LT_CMD_STRIPLIB], 4181[m4_require([_LT_DECL_EGREP]) 4182striplib= 4183old_striplib= 4184AC_MSG_CHECKING([whether stripping libraries is possible]) 4185if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 4186 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 4187 test -z "$striplib" && striplib="$STRIP --strip-unneeded" 4188 AC_MSG_RESULT([yes]) 4189else 4190# FIXME - insert some real tests, host_os isn't really good enough 4191 case $host_os in 4192 darwin*) 4193 if test -n "$STRIP" ; then 4194 striplib="$STRIP -x" 4195 old_striplib="$STRIP -S" 4196 AC_MSG_RESULT([yes]) 4197 else 4198 AC_MSG_RESULT([no]) 4199 fi 4200 ;; 4201 *) 4202 AC_MSG_RESULT([no]) 4203 ;; 4204 esac 4205fi 4206_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 4207_LT_DECL([], [striplib], [1]) 4208])# _LT_CMD_STRIPLIB 4209 4210 4211# _LT_SYS_DYNAMIC_LINKER([TAG]) 4212# ----------------------------- 4213# PORTME Fill in your ld.so characteristics 4214m4_defun([_LT_SYS_DYNAMIC_LINKER], 4215[AC_REQUIRE([AC_CANONICAL_HOST])dnl 4216m4_require([_LT_DECL_EGREP])dnl 4217m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4218m4_require([_LT_DECL_OBJDUMP])dnl 4219m4_require([_LT_DECL_SED])dnl 4220m4_require([_LT_CHECK_SHELL_FEATURES])dnl 4221AC_MSG_CHECKING([dynamic linker characteristics]) 4222m4_if([$1], 4223 [], [ 4224if test "$GCC" = yes; then 4225 case $host_os in 4226 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 4227 *) lt_awk_arg="/^libraries:/" ;; 4228 esac 4229 case $host_os in 4230 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; 4231 *) lt_sed_strip_eq="s,=/,/,g" ;; 4232 esac 4233 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` 4234 case $lt_search_path_spec in 4235 *\;*) 4236 # if the path contains ";" then we assume it to be the separator 4237 # otherwise default to the standard path separator (i.e. ":") - it is 4238 # assumed that no part of a normal pathname contains ";" but that should 4239 # okay in the real world where ";" in dirpaths is itself problematic. 4240 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` 4241 ;; 4242 *) 4243 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` 4244 ;; 4245 esac 4246 # Ok, now we have the path, separated by spaces, we can step through it 4247 # and add multilib dir if necessary. 4248 lt_tmp_lt_search_path_spec= 4249 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 4250 for lt_sys_path in $lt_search_path_spec; do 4251 if test -d "$lt_sys_path/$lt_multi_os_dir"; then 4252 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 4253 else 4254 test -d "$lt_sys_path" && \ 4255 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 4256 fi 4257 done 4258 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' 4259BEGIN {RS=" "; FS="/|\n";} { 4260 lt_foo=""; 4261 lt_count=0; 4262 for (lt_i = NF; lt_i > 0; lt_i--) { 4263 if ($lt_i != "" && $lt_i != ".") { 4264 if ($lt_i == "..") { 4265 lt_count++; 4266 } else { 4267 if (lt_count == 0) { 4268 lt_foo="/" $lt_i lt_foo; 4269 } else { 4270 lt_count--; 4271 } 4272 } 4273 } 4274 } 4275 if (lt_foo != "") { lt_freq[[lt_foo]]++; } 4276 if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 4277}'` 4278 # AWK program above erroneously prepends '/' to C:/dos/paths 4279 # for these hosts. 4280 case $host_os in 4281 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ 4282 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; 4283 esac 4284 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` 4285else 4286 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 4287fi]) 4288library_names_spec= 4289libname_spec='lib$name' 4290soname_spec= 4291shrext_cmds=".so" 4292postinstall_cmds= 4293postuninstall_cmds= 4294finish_cmds= 4295finish_eval= 4296shlibpath_var= 4297shlibpath_overrides_runpath=unknown 4298version_type=none 4299dynamic_linker="$host_os ld.so" 4300sys_lib_dlsearch_path_spec="/lib /usr/lib" 4301need_lib_prefix=unknown 4302hardcode_into_libs=no 4303 4304# when you set need_version to no, make sure it does not cause -set_version 4305# flags to be left without arguments 4306need_version=unknown 4307 4308case $host_os in 4309aix3*) 4310 version_type=linux # correct to gnu/linux during the next big refactor 4311 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 4312 shlibpath_var=LIBPATH 4313 4314 # AIX 3 has no versioning support, so we append a major version to the name. 4315 soname_spec='${libname}${release}${shared_ext}$major' 4316 ;; 4317 4318aix[[4-9]]*) 4319 version_type=linux # correct to gnu/linux during the next big refactor 4320 need_lib_prefix=no 4321 need_version=no 4322 hardcode_into_libs=yes 4323 if test "$host_cpu" = ia64; then 4324 # AIX 5 supports IA64 4325 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 4326 shlibpath_var=LD_LIBRARY_PATH 4327 else 4328 # With GCC up to 2.95.x, collect2 would create an import file 4329 # for dependence libraries. The import file would start with 4330 # the line `#! .'. This would cause the generated library to 4331 # depend on `.', always an invalid library. This was fixed in 4332 # development snapshots of GCC prior to 3.0. 4333 case $host_os in 4334 aix4 | aix4.[[01]] | aix4.[[01]].*) 4335 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 4336 echo ' yes ' 4337 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then 4338 : 4339 else 4340 can_build_shared=no 4341 fi 4342 ;; 4343 esac 4344 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 4345 # soname into executable. Probably we can add versioning support to 4346 # collect2, so additional links can be useful in future. 4347 if test "$aix_use_runtimelinking" = yes; then 4348 # If using run time linking (on AIX 4.2 or later) use lib<name>.so 4349 # instead of lib<name>.a to let people know that these are not 4350 # typical AIX shared libraries. 4351 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4352 else 4353 # We preserve .a as extension for shared libraries through AIX4.2 4354 # and later when we are not doing run time linking. 4355 library_names_spec='${libname}${release}.a $libname.a' 4356 soname_spec='${libname}${release}${shared_ext}$major' 4357 fi 4358 shlibpath_var=LIBPATH 4359 fi 4360 ;; 4361 4362amigaos*) 4363 case $host_cpu in 4364 powerpc) 4365 # Since July 2007 AmigaOS4 officially supports .so libraries. 4366 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 4367 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4368 ;; 4369 m68k) 4370 library_names_spec='$libname.ixlibrary $libname.a' 4371 # Create ${libname}_ixlibrary.a entries in /sys/libs. 4372 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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' 4373 ;; 4374 esac 4375 ;; 4376 4377beos*) 4378 library_names_spec='${libname}${shared_ext}' 4379 dynamic_linker="$host_os ld.so" 4380 shlibpath_var=LIBRARY_PATH 4381 ;; 4382 4383bsdi[[45]]*) 4384 version_type=linux # correct to gnu/linux during the next big refactor 4385 need_version=no 4386 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4387 soname_spec='${libname}${release}${shared_ext}$major' 4388 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 4389 shlibpath_var=LD_LIBRARY_PATH 4390 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 4391 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 4392 # the default ld.so.conf also contains /usr/contrib/lib and 4393 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 4394 # libtool to hard-code these into programs 4395 ;; 4396 4397cygwin* | mingw* | pw32* | cegcc*) 4398 version_type=windows 4399 shrext_cmds=".dll" 4400 need_version=no 4401 need_lib_prefix=no 4402 4403 case $GCC,$cc_basename in 4404 yes,*) 4405 # gcc 4406 library_names_spec='$libname.dll.a' 4407 # DLL is installed to $(libdir)/../bin by postinstall_cmds 4408 postinstall_cmds='base_file=`basename \${file}`~ 4409 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 4410 dldir=$destdir/`dirname \$dlpath`~ 4411 test -d \$dldir || mkdir -p \$dldir~ 4412 $install_prog $dir/$dlname \$dldir/$dlname~ 4413 chmod a+x \$dldir/$dlname~ 4414 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 4415 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 4416 fi' 4417 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 4418 dlpath=$dir/\$dldll~ 4419 $RM \$dlpath' 4420 shlibpath_overrides_runpath=yes 4421 4422 case $host_os in 4423 cygwin*) 4424 # Cygwin DLLs use 'cyg' prefix rather than 'lib' 4425 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4426m4_if([$1], [],[ 4427 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) 4428 ;; 4429 mingw* | cegcc*) 4430 # MinGW DLLs use traditional 'lib' prefix 4431 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4432 ;; 4433 pw32*) 4434 # pw32 DLLs use 'pw' prefix rather than 'lib' 4435 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4436 ;; 4437 esac 4438 dynamic_linker='Win32 ld.exe' 4439 ;; 4440 4441 *,cl*) 4442 # Native MSVC 4443 libname_spec='$name' 4444 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4445 library_names_spec='${libname}.dll.lib' 4446 4447 case $build_os in 4448 mingw*) 4449 sys_lib_search_path_spec= 4450 lt_save_ifs=$IFS 4451 IFS=';' 4452 for lt_path in $LIB 4453 do 4454 IFS=$lt_save_ifs 4455 # Let DOS variable expansion print the short 8.3 style file name. 4456 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` 4457 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" 4458 done 4459 IFS=$lt_save_ifs 4460 # Convert to MSYS style. 4461 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` 4462 ;; 4463 cygwin*) 4464 # Convert to unix form, then to dos form, then back to unix form 4465 # but this time dos style (no spaces!) so that the unix form looks 4466 # like /cygdrive/c/PROGRA~1:/cygdr... 4467 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` 4468 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` 4469 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 4470 ;; 4471 *) 4472 sys_lib_search_path_spec="$LIB" 4473 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then 4474 # It is most probably a Windows format PATH. 4475 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 4476 else 4477 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 4478 fi 4479 # FIXME: find the short name or the path components, as spaces are 4480 # common. (e.g. "Program Files" -> "PROGRA~1") 4481 ;; 4482 esac 4483 4484 # DLL is installed to $(libdir)/../bin by postinstall_cmds 4485 postinstall_cmds='base_file=`basename \${file}`~ 4486 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 4487 dldir=$destdir/`dirname \$dlpath`~ 4488 test -d \$dldir || mkdir -p \$dldir~ 4489 $install_prog $dir/$dlname \$dldir/$dlname' 4490 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 4491 dlpath=$dir/\$dldll~ 4492 $RM \$dlpath' 4493 shlibpath_overrides_runpath=yes 4494 dynamic_linker='Win32 link.exe' 4495 ;; 4496 4497 *) 4498 # Assume MSVC wrapper 4499 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 4500 dynamic_linker='Win32 ld.exe' 4501 ;; 4502 esac 4503 # FIXME: first we should search . and the directory the executable is in 4504 shlibpath_var=PATH 4505 ;; 4506 4507darwin* | rhapsody*) 4508 dynamic_linker="$host_os dyld" 4509 version_type=darwin 4510 need_lib_prefix=no 4511 need_version=no 4512 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' 4513 soname_spec='${libname}${release}${major}$shared_ext' 4514 shlibpath_overrides_runpath=yes 4515 shlibpath_var=DYLD_LIBRARY_PATH 4516 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 4517m4_if([$1], [],[ 4518 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 4519 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 4520 ;; 4521 4522dgux*) 4523 version_type=linux # correct to gnu/linux during the next big refactor 4524 need_lib_prefix=no 4525 need_version=no 4526 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 4527 soname_spec='${libname}${release}${shared_ext}$major' 4528 shlibpath_var=LD_LIBRARY_PATH 4529 ;; 4530 4531freebsd* | dragonfly*) 4532 # DragonFly does not have aout. When/if they implement a new 4533 # versioning mechanism, adjust this. 4534 if test -x /usr/bin/objformat; then 4535 objformat=`/usr/bin/objformat` 4536 else 4537 case $host_os in 4538 freebsd[[23]].*) objformat=aout ;; 4539 *) objformat=elf ;; 4540 esac 4541 fi 4542 version_type=freebsd-$objformat 4543 case $version_type in 4544 freebsd-elf*) 4545 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 4546 need_version=no 4547 need_lib_prefix=no 4548 ;; 4549 freebsd-*) 4550 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 4551 need_version=yes 4552 ;; 4553 esac 4554 shlibpath_var=LD_LIBRARY_PATH 4555 case $host_os in 4556 freebsd2.*) 4557 shlibpath_overrides_runpath=yes 4558 ;; 4559 freebsd3.[[01]]* | freebsdelf3.[[01]]*) 4560 shlibpath_overrides_runpath=yes 4561 hardcode_into_libs=yes 4562 ;; 4563 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 4564 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 4565 shlibpath_overrides_runpath=no 4566 hardcode_into_libs=yes 4567 ;; 4568 *) # from 4.6 on, and DragonFly 4569 shlibpath_overrides_runpath=yes 4570 hardcode_into_libs=yes 4571 ;; 4572 esac 4573 ;; 4574 4575gnu*) 4576 version_type=linux # correct to gnu/linux during the next big refactor 4577 need_lib_prefix=no 4578 need_version=no 4579 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 4580 soname_spec='${libname}${release}${shared_ext}$major' 4581 shlibpath_var=LD_LIBRARY_PATH 4582 shlibpath_overrides_runpath=no 4583 hardcode_into_libs=yes 4584 ;; 4585 4586haiku*) 4587 version_type=linux # correct to gnu/linux during the next big refactor 4588 need_lib_prefix=no 4589 need_version=no 4590 dynamic_linker="$host_os runtime_loader" 4591 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 4592 soname_spec='${libname}${release}${shared_ext}$major' 4593 shlibpath_var=LIBRARY_PATH 4594 shlibpath_overrides_runpath=yes 4595 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' 4596 hardcode_into_libs=yes 4597 ;; 4598 4599hpux9* | hpux10* | hpux11*) 4600 # Give a soname corresponding to the major version so that dld.sl refuses to 4601 # link against other versions. 4602 version_type=sunos 4603 need_lib_prefix=no 4604 need_version=no 4605 case $host_cpu in 4606 ia64*) 4607 shrext_cmds='.so' 4608 hardcode_into_libs=yes 4609 dynamic_linker="$host_os dld.so" 4610 shlibpath_var=LD_LIBRARY_PATH 4611 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 4612 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4613 soname_spec='${libname}${release}${shared_ext}$major' 4614 if test "X$HPUX_IA64_MODE" = X32; then 4615 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 4616 else 4617 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 4618 fi 4619 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 4620 ;; 4621 hppa*64*) 4622 shrext_cmds='.sl' 4623 hardcode_into_libs=yes 4624 dynamic_linker="$host_os dld.sl" 4625 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 4626 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 4627 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4628 soname_spec='${libname}${release}${shared_ext}$major' 4629 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 4630 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 4631 ;; 4632 *) 4633 shrext_cmds='.sl' 4634 dynamic_linker="$host_os dld.sl" 4635 shlibpath_var=SHLIB_PATH 4636 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 4637 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4638 soname_spec='${libname}${release}${shared_ext}$major' 4639 ;; 4640 esac 4641 # HP-UX runs *really* slowly unless shared libraries are mode 555, ... 4642 postinstall_cmds='chmod 555 $lib' 4643 # or fails outright, so override atomically: 4644 install_override_mode=555 4645 ;; 4646 4647interix[[3-9]]*) 4648 version_type=linux # correct to gnu/linux during the next big refactor 4649 need_lib_prefix=no 4650 need_version=no 4651 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 4652 soname_spec='${libname}${release}${shared_ext}$major' 4653 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 4654 shlibpath_var=LD_LIBRARY_PATH 4655 shlibpath_overrides_runpath=no 4656 hardcode_into_libs=yes 4657 ;; 4658 4659irix5* | irix6* | nonstopux*) 4660 case $host_os in 4661 nonstopux*) version_type=nonstopux ;; 4662 *) 4663 if test "$lt_cv_prog_gnu_ld" = yes; then 4664 version_type=linux # correct to gnu/linux during the next big refactor 4665 else 4666 version_type=irix 4667 fi ;; 4668 esac 4669 need_lib_prefix=no 4670 need_version=no 4671 soname_spec='${libname}${release}${shared_ext}$major' 4672 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 4673 case $host_os in 4674 irix5* | nonstopux*) 4675 libsuff= shlibsuff= 4676 ;; 4677 *) 4678 case $LD in # libtool.m4 will add one of these switches to LD 4679 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 4680 libsuff= shlibsuff= libmagic=32-bit;; 4681 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 4682 libsuff=32 shlibsuff=N32 libmagic=N32;; 4683 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 4684 libsuff=64 shlibsuff=64 libmagic=64-bit;; 4685 *) libsuff= shlibsuff= libmagic=never-match;; 4686 esac 4687 ;; 4688 esac 4689 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 4690 shlibpath_overrides_runpath=no 4691 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 4692 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 4693 hardcode_into_libs=yes 4694 ;; 4695 4696# No shared lib support for Linux oldld, aout, or coff. 4697linux*oldld* | linux*aout* | linux*coff*) 4698 dynamic_linker=no 4699 ;; 4700 4701# This must be glibc/ELF. 4702linux* | k*bsd*-gnu | kopensolaris*-gnu) 4703 version_type=linux # correct to gnu/linux during the next big refactor 4704 need_lib_prefix=no 4705 need_version=no 4706 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4707 soname_spec='${libname}${release}${shared_ext}$major' 4708 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 4709 shlibpath_var=LD_LIBRARY_PATH 4710 shlibpath_overrides_runpath=no 4711 4712 # Some binutils ld are patched to set DT_RUNPATH 4713 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], 4714 [lt_cv_shlibpath_overrides_runpath=no 4715 save_LDFLAGS=$LDFLAGS 4716 save_libdir=$libdir 4717 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 4718 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 4719 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 4720 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 4721 [lt_cv_shlibpath_overrides_runpath=yes])]) 4722 LDFLAGS=$save_LDFLAGS 4723 libdir=$save_libdir 4724 ]) 4725 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath 4726 4727 # This implies no fast_install, which is unacceptable. 4728 # Some rework will be needed to allow for fast_install 4729 # before this can be enabled. 4730 hardcode_into_libs=yes 4731 4732 # Add ABI-specific directories to the system library path. 4733 sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" 4734 4735 # Append ld.so.conf contents to the search path 4736 if test -f /etc/ld.so.conf; then 4737 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` 4738 sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" 4739 4740 fi 4741 4742 # We used to test for /lib/ld.so.1 and disable shared libraries on 4743 # powerpc, because MkLinux only supported shared libraries with the 4744 # GNU dynamic linker. Since this was broken with cross compilers, 4745 # most powerpc-linux boxes support dynamic linking these days and 4746 # people can always --disable-shared, the test was removed, and we 4747 # assume the GNU/Linux dynamic linker is in use. 4748 dynamic_linker='GNU/Linux ld.so' 4749 ;; 4750 4751netbsd*) 4752 version_type=sunos 4753 need_lib_prefix=no 4754 need_version=no 4755 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 4756 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4757 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 4758 dynamic_linker='NetBSD (a.out) ld.so' 4759 else 4760 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 4761 soname_spec='${libname}${release}${shared_ext}$major' 4762 dynamic_linker='NetBSD ld.elf_so' 4763 fi 4764 shlibpath_var=LD_LIBRARY_PATH 4765 shlibpath_overrides_runpath=yes 4766 hardcode_into_libs=yes 4767 ;; 4768 4769newsos6) 4770 version_type=linux # correct to gnu/linux during the next big refactor 4771 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4772 shlibpath_var=LD_LIBRARY_PATH 4773 shlibpath_overrides_runpath=yes 4774 ;; 4775 4776*nto* | *qnx*) 4777 version_type=qnx 4778 need_lib_prefix=no 4779 need_version=no 4780 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4781 soname_spec='${libname}${release}${shared_ext}$major' 4782 shlibpath_var=LD_LIBRARY_PATH 4783 shlibpath_overrides_runpath=no 4784 hardcode_into_libs=yes 4785 dynamic_linker='ldqnx.so' 4786 ;; 4787 4788openbsd*) 4789 version_type=sunos 4790 sys_lib_dlsearch_path_spec="/usr/lib" 4791 need_lib_prefix=no 4792 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 4793 case $host_os in 4794 openbsd3.3 | openbsd3.3.*) need_version=yes ;; 4795 *) need_version=no ;; 4796 esac 4797 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4798 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 4799 shlibpath_var=LD_LIBRARY_PATH 4800 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 4801 case $host_os in 4802 openbsd2.[[89]] | openbsd2.[[89]].*) 4803 shlibpath_overrides_runpath=no 4804 ;; 4805 *) 4806 shlibpath_overrides_runpath=yes 4807 ;; 4808 esac 4809 else 4810 shlibpath_overrides_runpath=yes 4811 fi 4812 ;; 4813 4814os2*) 4815 libname_spec='$name' 4816 shrext_cmds=".dll" 4817 need_lib_prefix=no 4818 library_names_spec='$libname${shared_ext} $libname.a' 4819 dynamic_linker='OS/2 ld.exe' 4820 shlibpath_var=LIBPATH 4821 ;; 4822 4823osf3* | osf4* | osf5*) 4824 version_type=osf 4825 need_lib_prefix=no 4826 need_version=no 4827 soname_spec='${libname}${release}${shared_ext}$major' 4828 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4829 shlibpath_var=LD_LIBRARY_PATH 4830 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 4831 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 4832 ;; 4833 4834rdos*) 4835 dynamic_linker=no 4836 ;; 4837 4838solaris*) 4839 version_type=linux # correct to gnu/linux during the next big refactor 4840 need_lib_prefix=no 4841 need_version=no 4842 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4843 soname_spec='${libname}${release}${shared_ext}$major' 4844 shlibpath_var=LD_LIBRARY_PATH 4845 shlibpath_overrides_runpath=yes 4846 hardcode_into_libs=yes 4847 # ldd complains unless libraries are executable 4848 postinstall_cmds='chmod +x $lib' 4849 ;; 4850 4851sunos4*) 4852 version_type=sunos 4853 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4854 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 4855 shlibpath_var=LD_LIBRARY_PATH 4856 shlibpath_overrides_runpath=yes 4857 if test "$with_gnu_ld" = yes; then 4858 need_lib_prefix=no 4859 fi 4860 need_version=yes 4861 ;; 4862 4863sysv4 | sysv4.3*) 4864 version_type=linux # correct to gnu/linux during the next big refactor 4865 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4866 soname_spec='${libname}${release}${shared_ext}$major' 4867 shlibpath_var=LD_LIBRARY_PATH 4868 case $host_vendor in 4869 sni) 4870 shlibpath_overrides_runpath=no 4871 need_lib_prefix=no 4872 runpath_var=LD_RUN_PATH 4873 ;; 4874 siemens) 4875 need_lib_prefix=no 4876 ;; 4877 motorola) 4878 need_lib_prefix=no 4879 need_version=no 4880 shlibpath_overrides_runpath=no 4881 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 4882 ;; 4883 esac 4884 ;; 4885 4886sysv4*MP*) 4887 if test -d /usr/nec ;then 4888 version_type=linux # correct to gnu/linux during the next big refactor 4889 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 4890 soname_spec='$libname${shared_ext}.$major' 4891 shlibpath_var=LD_LIBRARY_PATH 4892 fi 4893 ;; 4894 4895sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 4896 version_type=freebsd-elf 4897 need_lib_prefix=no 4898 need_version=no 4899 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 4900 soname_spec='${libname}${release}${shared_ext}$major' 4901 shlibpath_var=LD_LIBRARY_PATH 4902 shlibpath_overrides_runpath=yes 4903 hardcode_into_libs=yes 4904 if test "$with_gnu_ld" = yes; then 4905 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 4906 else 4907 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 4908 case $host_os in 4909 sco3.2v5*) 4910 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 4911 ;; 4912 esac 4913 fi 4914 sys_lib_dlsearch_path_spec='/usr/lib' 4915 ;; 4916 4917tpf*) 4918 # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 4919 version_type=linux # correct to gnu/linux during the next big refactor 4920 need_lib_prefix=no 4921 need_version=no 4922 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4923 shlibpath_var=LD_LIBRARY_PATH 4924 shlibpath_overrides_runpath=no 4925 hardcode_into_libs=yes 4926 ;; 4927 4928uts4*) 4929 version_type=linux # correct to gnu/linux during the next big refactor 4930 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4931 soname_spec='${libname}${release}${shared_ext}$major' 4932 shlibpath_var=LD_LIBRARY_PATH 4933 ;; 4934 4935*) 4936 dynamic_linker=no 4937 ;; 4938esac 4939AC_MSG_RESULT([$dynamic_linker]) 4940test "$dynamic_linker" = no && can_build_shared=no 4941 4942variables_saved_for_relink="PATH $shlibpath_var $runpath_var" 4943if test "$GCC" = yes; then 4944 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 4945fi 4946 4947if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then 4948 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 4949fi 4950if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then 4951 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 4952fi 4953 4954_LT_DECL([], [variables_saved_for_relink], [1], 4955 [Variables whose values should be saved in libtool wrapper scripts and 4956 restored at link time]) 4957_LT_DECL([], [need_lib_prefix], [0], 4958 [Do we need the "lib" prefix for modules?]) 4959_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 4960_LT_DECL([], [version_type], [0], [Library versioning type]) 4961_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 4962_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 4963_LT_DECL([], [shlibpath_overrides_runpath], [0], 4964 [Is shlibpath searched before the hard-coded library search path?]) 4965_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 4966_LT_DECL([], [library_names_spec], [1], 4967 [[List of archive names. First name is the real one, the rest are links. 4968 The last name is the one that the linker finds with -lNAME]]) 4969_LT_DECL([], [soname_spec], [1], 4970 [[The coded name of the library, if different from the real name]]) 4971_LT_DECL([], [install_override_mode], [1], 4972 [Permission mode override for installation of shared libraries]) 4973_LT_DECL([], [postinstall_cmds], [2], 4974 [Command to use after installation of a shared archive]) 4975_LT_DECL([], [postuninstall_cmds], [2], 4976 [Command to use after uninstallation of a shared archive]) 4977_LT_DECL([], [finish_cmds], [2], 4978 [Commands used to finish a libtool library installation in a directory]) 4979_LT_DECL([], [finish_eval], [1], 4980 [[As "finish_cmds", except a single script fragment to be evaled but 4981 not shown]]) 4982_LT_DECL([], [hardcode_into_libs], [0], 4983 [Whether we should hardcode library paths into libraries]) 4984_LT_DECL([], [sys_lib_search_path_spec], [2], 4985 [Compile-time system search path for libraries]) 4986_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], 4987 [Run-time system search path for libraries]) 4988])# _LT_SYS_DYNAMIC_LINKER 4989 4990 4991# _LT_PATH_TOOL_PREFIX(TOOL) 4992# -------------------------- 4993# find a file program which can recognize shared library 4994AC_DEFUN([_LT_PATH_TOOL_PREFIX], 4995[m4_require([_LT_DECL_EGREP])dnl 4996AC_MSG_CHECKING([for $1]) 4997AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 4998[case $MAGIC_CMD in 4999[[\\/*] | ?:[\\/]*]) 5000 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 5001 ;; 5002*) 5003 lt_save_MAGIC_CMD="$MAGIC_CMD" 5004 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5005dnl $ac_dummy forces splitting on constant user-supplied paths. 5006dnl POSIX.2 word splitting is done only on the output of word expansions, 5007dnl not every word. This closes a longstanding sh security hole. 5008 ac_dummy="m4_if([$2], , $PATH, [$2])" 5009 for ac_dir in $ac_dummy; do 5010 IFS="$lt_save_ifs" 5011 test -z "$ac_dir" && ac_dir=. 5012 if test -f $ac_dir/$1; then 5013 lt_cv_path_MAGIC_CMD="$ac_dir/$1" 5014 if test -n "$file_magic_test_file"; then 5015 case $deplibs_check_method in 5016 "file_magic "*) 5017 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 5018 MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 5019 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 5020 $EGREP "$file_magic_regex" > /dev/null; then 5021 : 5022 else 5023 cat <<_LT_EOF 1>&2 5024 5025*** Warning: the command libtool uses to detect shared libraries, 5026*** $file_magic_cmd, produces output that libtool cannot recognize. 5027*** The result is that libtool may fail to recognize shared libraries 5028*** as such. This will affect the creation of libtool libraries that 5029*** depend on shared libraries, but programs linked with such libtool 5030*** libraries will work regardless of this problem. Nevertheless, you 5031*** may want to report the problem to your system manager and/or to 5032*** bug-libtool@gnu.org 5033 5034_LT_EOF 5035 fi ;; 5036 esac 5037 fi 5038 break 5039 fi 5040 done 5041 IFS="$lt_save_ifs" 5042 MAGIC_CMD="$lt_save_MAGIC_CMD" 5043 ;; 5044esac]) 5045MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 5046if test -n "$MAGIC_CMD"; then 5047 AC_MSG_RESULT($MAGIC_CMD) 5048else 5049 AC_MSG_RESULT(no) 5050fi 5051_LT_DECL([], [MAGIC_CMD], [0], 5052 [Used to examine libraries when file_magic_cmd begins with "file"])dnl 5053])# _LT_PATH_TOOL_PREFIX 5054 5055# Old name: 5056AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 5057dnl aclocal-1.4 backwards compatibility: 5058dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 5059 5060 5061# _LT_PATH_MAGIC 5062# -------------- 5063# find a file program which can recognize a shared library 5064m4_defun([_LT_PATH_MAGIC], 5065[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 5066if test -z "$lt_cv_path_MAGIC_CMD"; then 5067 if test -n "$ac_tool_prefix"; then 5068 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 5069 else 5070 MAGIC_CMD=: 5071 fi 5072fi 5073])# _LT_PATH_MAGIC 5074 5075 5076# LT_PATH_LD 5077# ---------- 5078# find the pathname to the GNU or non-GNU linker 5079AC_DEFUN([LT_PATH_LD], 5080[AC_REQUIRE([AC_PROG_CC])dnl 5081AC_REQUIRE([AC_CANONICAL_HOST])dnl 5082AC_REQUIRE([AC_CANONICAL_BUILD])dnl 5083m4_require([_LT_DECL_SED])dnl 5084m4_require([_LT_DECL_EGREP])dnl 5085m4_require([_LT_PROG_ECHO_BACKSLASH])dnl 5086 5087AC_ARG_WITH([gnu-ld], 5088 [AS_HELP_STRING([--with-gnu-ld], 5089 [assume the C compiler uses GNU ld @<:@default=no@:>@])], 5090 [test "$withval" = no || with_gnu_ld=yes], 5091 [with_gnu_ld=no])dnl 5092 5093ac_prog=ld 5094if test "$GCC" = yes; then 5095 # Check if gcc -print-prog-name=ld gives a path. 5096 AC_MSG_CHECKING([for ld used by $CC]) 5097 case $host in 5098 *-*-mingw*) 5099 # gcc leaves a trailing carriage return which upsets mingw 5100 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 5101 *) 5102 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 5103 esac 5104 case $ac_prog in 5105 # Accept absolute paths. 5106 [[\\/]]* | ?:[[\\/]]*) 5107 re_direlt='/[[^/]][[^/]]*/\.\./' 5108 # Canonicalize the pathname of ld 5109 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 5110 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 5111 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 5112 done 5113 test -z "$LD" && LD="$ac_prog" 5114 ;; 5115 "") 5116 # If it fails, then pretend we aren't using GCC. 5117 ac_prog=ld 5118 ;; 5119 *) 5120 # If it is relative, then search for the first ld in PATH. 5121 with_gnu_ld=unknown 5122 ;; 5123 esac 5124elif test "$with_gnu_ld" = yes; then 5125 AC_MSG_CHECKING([for GNU ld]) 5126else 5127 AC_MSG_CHECKING([for non-GNU ld]) 5128fi 5129AC_CACHE_VAL(lt_cv_path_LD, 5130[if test -z "$LD"; then 5131 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5132 for ac_dir in $PATH; do 5133 IFS="$lt_save_ifs" 5134 test -z "$ac_dir" && ac_dir=. 5135 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 5136 lt_cv_path_LD="$ac_dir/$ac_prog" 5137 # Check to see if the program is GNU ld. I'd rather use --version, 5138 # but apparently some variants of GNU ld only accept -v. 5139 # Break only if it was the GNU/non-GNU ld that we prefer. 5140 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 5141 *GNU* | *'with BFD'*) 5142 test "$with_gnu_ld" != no && break 5143 ;; 5144 *) 5145 test "$with_gnu_ld" != yes && break 5146 ;; 5147 esac 5148 fi 5149 done 5150 IFS="$lt_save_ifs" 5151else 5152 lt_cv_path_LD="$LD" # Let the user override the test with a path. 5153fi]) 5154LD="$lt_cv_path_LD" 5155if test -n "$LD"; then 5156 AC_MSG_RESULT($LD) 5157else 5158 AC_MSG_RESULT(no) 5159fi 5160test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 5161_LT_PATH_LD_GNU 5162AC_SUBST([LD]) 5163 5164_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 5165])# LT_PATH_LD 5166 5167# Old names: 5168AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 5169AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 5170dnl aclocal-1.4 backwards compatibility: 5171dnl AC_DEFUN([AM_PROG_LD], []) 5172dnl AC_DEFUN([AC_PROG_LD], []) 5173 5174 5175# _LT_PATH_LD_GNU 5176#- -------------- 5177m4_defun([_LT_PATH_LD_GNU], 5178[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 5179[# I'd rather use --version here, but apparently some GNU lds only accept -v. 5180case `$LD -v 2>&1 </dev/null` in 5181*GNU* | *'with BFD'*) 5182 lt_cv_prog_gnu_ld=yes 5183 ;; 5184*) 5185 lt_cv_prog_gnu_ld=no 5186 ;; 5187esac]) 5188with_gnu_ld=$lt_cv_prog_gnu_ld 5189])# _LT_PATH_LD_GNU 5190 5191 5192# _LT_CMD_RELOAD 5193# -------------- 5194# find reload flag for linker 5195# -- PORTME Some linkers may need a different reload flag. 5196m4_defun([_LT_CMD_RELOAD], 5197[AC_CACHE_CHECK([for $LD option to reload object files], 5198 lt_cv_ld_reload_flag, 5199 [lt_cv_ld_reload_flag='-r']) 5200reload_flag=$lt_cv_ld_reload_flag 5201case $reload_flag in 5202"" | " "*) ;; 5203*) reload_flag=" $reload_flag" ;; 5204esac 5205reload_cmds='$LD$reload_flag -o $output$reload_objs' 5206case $host_os in 5207 cygwin* | mingw* | pw32* | cegcc*) 5208 if test "$GCC" != yes; then 5209 reload_cmds=false 5210 fi 5211 ;; 5212 darwin*) 5213 if test "$GCC" = yes; then 5214 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 5215 else 5216 reload_cmds='$LD$reload_flag -o $output$reload_objs' 5217 fi 5218 ;; 5219esac 5220_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl 5221_LT_TAGDECL([], [reload_cmds], [2])dnl 5222])# _LT_CMD_RELOAD 5223 5224 5225# _LT_CHECK_MAGIC_METHOD 5226# ---------------------- 5227# how to check for library dependencies 5228# -- PORTME fill in with the dynamic library characteristics 5229m4_defun([_LT_CHECK_MAGIC_METHOD], 5230[m4_require([_LT_DECL_EGREP]) 5231m4_require([_LT_DECL_OBJDUMP]) 5232AC_CACHE_CHECK([how to recognize dependent libraries], 5233lt_cv_deplibs_check_method, 5234[lt_cv_file_magic_cmd='$MAGIC_CMD' 5235lt_cv_file_magic_test_file= 5236lt_cv_deplibs_check_method='unknown' 5237# Need to set the preceding variable on all platforms that support 5238# interlibrary dependencies. 5239# 'none' -- dependencies not supported. 5240# `unknown' -- same as none, but documents that we really don't know. 5241# 'pass_all' -- all dependencies passed with no checks. 5242# 'test_compile' -- check by making test program. 5243# 'file_magic [[regex]]' -- check by looking for files in library path 5244# which responds to the $file_magic_cmd with a given extended regex. 5245# If you have `file' or equivalent on your system and you're not sure 5246# whether `pass_all' will *always* work, you probably want this one. 5247 5248case $host_os in 5249aix[[4-9]]*) 5250 lt_cv_deplibs_check_method=pass_all 5251 ;; 5252 5253beos*) 5254 lt_cv_deplibs_check_method=pass_all 5255 ;; 5256 5257bsdi[[45]]*) 5258 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 5259 lt_cv_file_magic_cmd='/usr/bin/file -L' 5260 lt_cv_file_magic_test_file=/shlib/libc.so 5261 ;; 5262 5263cygwin*) 5264 # func_win32_libid is a shell function defined in ltmain.sh 5265 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 5266 lt_cv_file_magic_cmd='func_win32_libid' 5267 ;; 5268 5269mingw* | pw32*) 5270 # Base MSYS/MinGW do not provide the 'file' command needed by 5271 # func_win32_libid shell function, so use a weaker test based on 'objdump', 5272 # unless we find 'file', for example because we are cross-compiling. 5273 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. 5274 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then 5275 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 5276 lt_cv_file_magic_cmd='func_win32_libid' 5277 else 5278 # Keep this pattern in sync with the one in func_win32_libid. 5279 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' 5280 lt_cv_file_magic_cmd='$OBJDUMP -f' 5281 fi 5282 ;; 5283 5284cegcc*) 5285 # use the weaker test based on 'objdump'. See mingw*. 5286 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 5287 lt_cv_file_magic_cmd='$OBJDUMP -f' 5288 ;; 5289 5290darwin* | rhapsody*) 5291 lt_cv_deplibs_check_method=pass_all 5292 ;; 5293 5294freebsd* | dragonfly*) 5295 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 5296 case $host_cpu in 5297 i*86 ) 5298 # Not sure whether the presence of OpenBSD here was a mistake. 5299 # Let's accept both of them until this is cleared up. 5300 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 5301 lt_cv_file_magic_cmd=/usr/bin/file 5302 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 5303 ;; 5304 esac 5305 else 5306 lt_cv_deplibs_check_method=pass_all 5307 fi 5308 ;; 5309 5310gnu*) 5311 lt_cv_deplibs_check_method=pass_all 5312 ;; 5313 5314haiku*) 5315 lt_cv_deplibs_check_method=pass_all 5316 ;; 5317 5318hpux10.20* | hpux11*) 5319 lt_cv_file_magic_cmd=/usr/bin/file 5320 case $host_cpu in 5321 ia64*) 5322 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 5323 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 5324 ;; 5325 hppa*64*) 5326 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] 5327 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 5328 ;; 5329 *) 5330 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' 5331 lt_cv_file_magic_test_file=/usr/lib/libc.sl 5332 ;; 5333 esac 5334 ;; 5335 5336interix[[3-9]]*) 5337 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 5338 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 5339 ;; 5340 5341irix5* | irix6* | nonstopux*) 5342 case $LD in 5343 *-32|*"-32 ") libmagic=32-bit;; 5344 *-n32|*"-n32 ") libmagic=N32;; 5345 *-64|*"-64 ") libmagic=64-bit;; 5346 *) libmagic=never-match;; 5347 esac 5348 lt_cv_deplibs_check_method=pass_all 5349 ;; 5350 5351# This must be glibc/ELF. 5352linux* | k*bsd*-gnu | kopensolaris*-gnu) 5353 lt_cv_deplibs_check_method=pass_all 5354 ;; 5355 5356netbsd*) 5357 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 5358 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 5359 else 5360 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 5361 fi 5362 ;; 5363 5364newos6*) 5365 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 5366 lt_cv_file_magic_cmd=/usr/bin/file 5367 lt_cv_file_magic_test_file=/usr/lib/libnls.so 5368 ;; 5369 5370*nto* | *qnx*) 5371 lt_cv_deplibs_check_method=pass_all 5372 ;; 5373 5374openbsd*) 5375 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5376 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 5377 else 5378 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 5379 fi 5380 ;; 5381 5382osf3* | osf4* | osf5*) 5383 lt_cv_deplibs_check_method=pass_all 5384 ;; 5385 5386rdos*) 5387 lt_cv_deplibs_check_method=pass_all 5388 ;; 5389 5390solaris*) 5391 lt_cv_deplibs_check_method=pass_all 5392 ;; 5393 5394sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 5395 lt_cv_deplibs_check_method=pass_all 5396 ;; 5397 5398sysv4 | sysv4.3*) 5399 case $host_vendor in 5400 motorola) 5401 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]]' 5402 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 5403 ;; 5404 ncr) 5405 lt_cv_deplibs_check_method=pass_all 5406 ;; 5407 sequent) 5408 lt_cv_file_magic_cmd='/bin/file' 5409 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 5410 ;; 5411 sni) 5412 lt_cv_file_magic_cmd='/bin/file' 5413 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 5414 lt_cv_file_magic_test_file=/lib/libc.so 5415 ;; 5416 siemens) 5417 lt_cv_deplibs_check_method=pass_all 5418 ;; 5419 pc) 5420 lt_cv_deplibs_check_method=pass_all 5421 ;; 5422 esac 5423 ;; 5424 5425tpf*) 5426 lt_cv_deplibs_check_method=pass_all 5427 ;; 5428esac 5429]) 5430 5431file_magic_glob= 5432want_nocaseglob=no 5433if test "$build" = "$host"; then 5434 case $host_os in 5435 mingw* | pw32*) 5436 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then 5437 want_nocaseglob=yes 5438 else 5439 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` 5440 fi 5441 ;; 5442 esac 5443fi 5444 5445file_magic_cmd=$lt_cv_file_magic_cmd 5446deplibs_check_method=$lt_cv_deplibs_check_method 5447test -z "$deplibs_check_method" && deplibs_check_method=unknown 5448 5449_LT_DECL([], [deplibs_check_method], [1], 5450 [Method to check whether dependent libraries are shared objects]) 5451_LT_DECL([], [file_magic_cmd], [1], 5452 [Command to use when deplibs_check_method = "file_magic"]) 5453_LT_DECL([], [file_magic_glob], [1], 5454 [How to find potential files when deplibs_check_method = "file_magic"]) 5455_LT_DECL([], [want_nocaseglob], [1], 5456 [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) 5457])# _LT_CHECK_MAGIC_METHOD 5458 5459 5460# LT_PATH_NM 5461# ---------- 5462# find the pathname to a BSD- or MS-compatible name lister 5463AC_DEFUN([LT_PATH_NM], 5464[AC_REQUIRE([AC_PROG_CC])dnl 5465AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 5466[if test -n "$NM"; then 5467 # Let the user override the test. 5468 lt_cv_path_NM="$NM" 5469else 5470 lt_nm_to_check="${ac_tool_prefix}nm" 5471 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 5472 lt_nm_to_check="$lt_nm_to_check nm" 5473 fi 5474 for lt_tmp_nm in $lt_nm_to_check; do 5475 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5476 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 5477 IFS="$lt_save_ifs" 5478 test -z "$ac_dir" && ac_dir=. 5479 tmp_nm="$ac_dir/$lt_tmp_nm" 5480 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 5481 # Check to see if the nm accepts a BSD-compat flag. 5482 # Adding the `sed 1q' prevents false positives on HP-UX, which says: 5483 # nm: unknown option "B" ignored 5484 # Tru64's nm complains that /dev/null is an invalid object file 5485 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 5486 */dev/null* | *'Invalid file or object type'*) 5487 lt_cv_path_NM="$tmp_nm -B" 5488 break 5489 ;; 5490 *) 5491 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 5492 */dev/null*) 5493 lt_cv_path_NM="$tmp_nm -p" 5494 break 5495 ;; 5496 *) 5497 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 5498 continue # so that we can try to find one that supports BSD flags 5499 ;; 5500 esac 5501 ;; 5502 esac 5503 fi 5504 done 5505 IFS="$lt_save_ifs" 5506 done 5507 : ${lt_cv_path_NM=no} 5508fi]) 5509if test "$lt_cv_path_NM" != "no"; then 5510 NM="$lt_cv_path_NM" 5511else 5512 # Didn't find any BSD compatible name lister, look for dumpbin. 5513 if test -n "$DUMPBIN"; then : 5514 # Let the user override the test. 5515 else 5516 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) 5517 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in 5518 *COFF*) 5519 DUMPBIN="$DUMPBIN -symbols" 5520 ;; 5521 *) 5522 DUMPBIN=: 5523 ;; 5524 esac 5525 fi 5526 AC_SUBST([DUMPBIN]) 5527 if test "$DUMPBIN" != ":"; then 5528 NM="$DUMPBIN" 5529 fi 5530fi 5531test -z "$NM" && NM=nm 5532AC_SUBST([NM]) 5533_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 5534 5535AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 5536 [lt_cv_nm_interface="BSD nm" 5537 echo "int some_variable = 0;" > conftest.$ac_ext 5538 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 5539 (eval "$ac_compile" 2>conftest.err) 5540 cat conftest.err >&AS_MESSAGE_LOG_FD 5541 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 5542 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 5543 cat conftest.err >&AS_MESSAGE_LOG_FD 5544 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) 5545 cat conftest.out >&AS_MESSAGE_LOG_FD 5546 if $GREP 'External.*some_variable' conftest.out > /dev/null; then 5547 lt_cv_nm_interface="MS dumpbin" 5548 fi 5549 rm -f conftest*]) 5550])# LT_PATH_NM 5551 5552# Old names: 5553AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 5554AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 5555dnl aclocal-1.4 backwards compatibility: 5556dnl AC_DEFUN([AM_PROG_NM], []) 5557dnl AC_DEFUN([AC_PROG_NM], []) 5558 5559# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 5560# -------------------------------- 5561# how to determine the name of the shared library 5562# associated with a specific link library. 5563# -- PORTME fill in with the dynamic library characteristics 5564m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], 5565[m4_require([_LT_DECL_EGREP]) 5566m4_require([_LT_DECL_OBJDUMP]) 5567m4_require([_LT_DECL_DLLTOOL]) 5568AC_CACHE_CHECK([how to associate runtime and link libraries], 5569lt_cv_sharedlib_from_linklib_cmd, 5570[lt_cv_sharedlib_from_linklib_cmd='unknown' 5571 5572case $host_os in 5573cygwin* | mingw* | pw32* | cegcc*) 5574 # two different shell functions defined in ltmain.sh 5575 # decide which to use based on capabilities of $DLLTOOL 5576 case `$DLLTOOL --help 2>&1` in 5577 *--identify-strict*) 5578 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib 5579 ;; 5580 *) 5581 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback 5582 ;; 5583 esac 5584 ;; 5585*) 5586 # fallback: assume linklib IS sharedlib 5587 lt_cv_sharedlib_from_linklib_cmd="$ECHO" 5588 ;; 5589esac 5590]) 5591sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd 5592test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO 5593 5594_LT_DECL([], [sharedlib_from_linklib_cmd], [1], 5595 [Command to associate shared and link libraries]) 5596])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 5597 5598 5599# _LT_PATH_MANIFEST_TOOL 5600# ---------------------- 5601# locate the manifest tool 5602m4_defun([_LT_PATH_MANIFEST_TOOL], 5603[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) 5604test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt 5605AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], 5606 [lt_cv_path_mainfest_tool=no 5607 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD 5608 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out 5609 cat conftest.err >&AS_MESSAGE_LOG_FD 5610 if $GREP 'Manifest Tool' conftest.out > /dev/null; then 5611 lt_cv_path_mainfest_tool=yes 5612 fi 5613 rm -f conftest*]) 5614if test "x$lt_cv_path_mainfest_tool" != xyes; then 5615 MANIFEST_TOOL=: 5616fi 5617_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl 5618])# _LT_PATH_MANIFEST_TOOL 5619 5620 5621# LT_LIB_M 5622# -------- 5623# check for math library 5624AC_DEFUN([LT_LIB_M], 5625[AC_REQUIRE([AC_CANONICAL_HOST])dnl 5626LIBM= 5627case $host in 5628*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) 5629 # These system don't have libm, or don't need it 5630 ;; 5631*-ncr-sysv4.3*) 5632 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 5633 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 5634 ;; 5635*) 5636 AC_CHECK_LIB(m, cos, LIBM="-lm") 5637 ;; 5638esac 5639AC_SUBST([LIBM]) 5640])# LT_LIB_M 5641 5642# Old name: 5643AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 5644dnl aclocal-1.4 backwards compatibility: 5645dnl AC_DEFUN([AC_CHECK_LIBM], []) 5646 5647 5648# _LT_COMPILER_NO_RTTI([TAGNAME]) 5649# ------------------------------- 5650m4_defun([_LT_COMPILER_NO_RTTI], 5651[m4_require([_LT_TAG_COMPILER])dnl 5652 5653_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 5654 5655if test "$GCC" = yes; then 5656 case $cc_basename in 5657 nvcc*) 5658 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; 5659 *) 5660 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; 5661 esac 5662 5663 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 5664 lt_cv_prog_compiler_rtti_exceptions, 5665 [-fno-rtti -fno-exceptions], [], 5666 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 5667fi 5668_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 5669 [Compiler flag to turn off builtin functions]) 5670])# _LT_COMPILER_NO_RTTI 5671 5672 5673# _LT_CMD_GLOBAL_SYMBOLS 5674# ---------------------- 5675m4_defun([_LT_CMD_GLOBAL_SYMBOLS], 5676[AC_REQUIRE([AC_CANONICAL_HOST])dnl 5677AC_REQUIRE([AC_PROG_CC])dnl 5678AC_REQUIRE([AC_PROG_AWK])dnl 5679AC_REQUIRE([LT_PATH_NM])dnl 5680AC_REQUIRE([LT_PATH_LD])dnl 5681m4_require([_LT_DECL_SED])dnl 5682m4_require([_LT_DECL_EGREP])dnl 5683m4_require([_LT_TAG_COMPILER])dnl 5684 5685# Check for command to grab the raw symbol name followed by C symbol from nm. 5686AC_MSG_CHECKING([command to parse $NM output from $compiler object]) 5687AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 5688[ 5689# These are sane defaults that work on at least a few old systems. 5690# [They come from Ultrix. What could be older than Ultrix?!! ;)] 5691 5692# Character class describing NM global symbol codes. 5693symcode='[[BCDEGRST]]' 5694 5695# Regexp to match symbols that can be accessed directly from C. 5696sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 5697 5698# Define system-specific variables. 5699case $host_os in 5700aix*) 5701 symcode='[[BCDT]]' 5702 ;; 5703cygwin* | mingw* | pw32* | cegcc*) 5704 symcode='[[ABCDGISTW]]' 5705 ;; 5706hpux*) 5707 if test "$host_cpu" = ia64; then 5708 symcode='[[ABCDEGRST]]' 5709 fi 5710 ;; 5711irix* | nonstopux*) 5712 symcode='[[BCDEGRST]]' 5713 ;; 5714osf*) 5715 symcode='[[BCDEGQRST]]' 5716 ;; 5717solaris*) 5718 symcode='[[BDRT]]' 5719 ;; 5720sco3.2v5*) 5721 symcode='[[DT]]' 5722 ;; 5723sysv4.2uw2*) 5724 symcode='[[DT]]' 5725 ;; 5726sysv5* | sco5v6* | unixware* | OpenUNIX*) 5727 symcode='[[ABDT]]' 5728 ;; 5729sysv4) 5730 symcode='[[DFNSTU]]' 5731 ;; 5732esac 5733 5734# If we're using GNU nm, then use its standard symbol codes. 5735case `$NM -V 2>&1` in 5736*GNU* | *'with BFD'*) 5737 symcode='[[ABCDGIRSTW]]' ;; 5738esac 5739 5740# Transform an extracted symbol line into a proper C declaration. 5741# Some systems (esp. on ia64) link data and code symbols differently, 5742# so use this general approach. 5743lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 5744 5745# Transform an extracted symbol line into symbol name and symbol address 5746lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" 5747lt_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'" 5748 5749# Handle CRLF in mingw tool chain 5750opt_cr= 5751case $build_os in 5752mingw*) 5753 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 5754 ;; 5755esac 5756 5757# Try without a prefix underscore, then with it. 5758for ac_symprfx in "" "_"; do 5759 5760 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 5761 symxfrm="\\1 $ac_symprfx\\2 \\2" 5762 5763 # Write the raw and C identifiers. 5764 if test "$lt_cv_nm_interface" = "MS dumpbin"; then 5765 # Fake it for dumpbin and say T for any non-static function 5766 # and D for any global variable. 5767 # Also find C++ and __fastcall symbols from MSVC++, 5768 # which start with @ or ?. 5769 lt_cv_sys_global_symbol_pipe="$AWK ['"\ 5770" {last_section=section; section=\$ 3};"\ 5771" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ 5772" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 5773" \$ 0!~/External *\|/{next};"\ 5774" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 5775" {if(hide[section]) next};"\ 5776" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ 5777" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ 5778" s[1]~/^[@?]/{print s[1], s[1]; next};"\ 5779" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ 5780" ' prfx=^$ac_symprfx]" 5781 else 5782 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 5783 fi 5784 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" 5785 5786 # Check to see that the pipe works correctly. 5787 pipe_works=no 5788 5789 rm -f conftest* 5790 cat > conftest.$ac_ext <<_LT_EOF 5791#ifdef __cplusplus 5792extern "C" { 5793#endif 5794char nm_test_var; 5795void nm_test_func(void); 5796void nm_test_func(void){} 5797#ifdef __cplusplus 5798} 5799#endif 5800int main(){nm_test_var='a';nm_test_func();return(0);} 5801_LT_EOF 5802 5803 if AC_TRY_EVAL(ac_compile); then 5804 # Now try to grab the symbols. 5805 nlist=conftest.nm 5806 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then 5807 # Try sorting and uniquifying the output. 5808 if sort "$nlist" | uniq > "$nlist"T; then 5809 mv -f "$nlist"T "$nlist" 5810 else 5811 rm -f "$nlist"T 5812 fi 5813 5814 # Make sure that we snagged all the symbols we need. 5815 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 5816 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 5817 cat <<_LT_EOF > conftest.$ac_ext 5818/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ 5819#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) 5820/* DATA imports from DLLs on WIN32 con't be const, because runtime 5821 relocations are performed -- see ld's documentation on pseudo-relocs. */ 5822# define LT@&t@_DLSYM_CONST 5823#elif defined(__osf__) 5824/* This system does not cope well with relocations in const data. */ 5825# define LT@&t@_DLSYM_CONST 5826#else 5827# define LT@&t@_DLSYM_CONST const 5828#endif 5829 5830#ifdef __cplusplus 5831extern "C" { 5832#endif 5833 5834_LT_EOF 5835 # Now generate the symbol file. 5836 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 5837 5838 cat <<_LT_EOF >> conftest.$ac_ext 5839 5840/* The mapping between symbol names and symbols. */ 5841LT@&t@_DLSYM_CONST struct { 5842 const char *name; 5843 void *address; 5844} 5845lt__PROGRAM__LTX_preloaded_symbols[[]] = 5846{ 5847 { "@PROGRAM@", (void *) 0 }, 5848_LT_EOF 5849 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 5850 cat <<\_LT_EOF >> conftest.$ac_ext 5851 {0, (void *) 0} 5852}; 5853 5854/* This works around a problem in FreeBSD linker */ 5855#ifdef FREEBSD_WORKAROUND 5856static const void *lt_preloaded_setup() { 5857 return lt__PROGRAM__LTX_preloaded_symbols; 5858} 5859#endif 5860 5861#ifdef __cplusplus 5862} 5863#endif 5864_LT_EOF 5865 # Now try linking the two files. 5866 mv conftest.$ac_objext conftstm.$ac_objext 5867 lt_globsym_save_LIBS=$LIBS 5868 lt_globsym_save_CFLAGS=$CFLAGS 5869 LIBS="conftstm.$ac_objext" 5870 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 5871 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 5872 pipe_works=yes 5873 fi 5874 LIBS=$lt_globsym_save_LIBS 5875 CFLAGS=$lt_globsym_save_CFLAGS 5876 else 5877 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 5878 fi 5879 else 5880 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 5881 fi 5882 else 5883 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 5884 fi 5885 else 5886 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 5887 cat conftest.$ac_ext >&5 5888 fi 5889 rm -rf conftest* conftst* 5890 5891 # Do not use the global_symbol_pipe unless it works. 5892 if test "$pipe_works" = yes; then 5893 break 5894 else 5895 lt_cv_sys_global_symbol_pipe= 5896 fi 5897done 5898]) 5899if test -z "$lt_cv_sys_global_symbol_pipe"; then 5900 lt_cv_sys_global_symbol_to_cdecl= 5901fi 5902if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 5903 AC_MSG_RESULT(failed) 5904else 5905 AC_MSG_RESULT(ok) 5906fi 5907 5908# Response file support. 5909if test "$lt_cv_nm_interface" = "MS dumpbin"; then 5910 nm_file_list_spec='@' 5911elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then 5912 nm_file_list_spec='@' 5913fi 5914 5915_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 5916 [Take the output of nm and produce a listing of raw symbols and C names]) 5917_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 5918 [Transform the output of nm in a proper C declaration]) 5919_LT_DECL([global_symbol_to_c_name_address], 5920 [lt_cv_sys_global_symbol_to_c_name_address], [1], 5921 [Transform the output of nm in a C name address pair]) 5922_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 5923 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 5924 [Transform the output of nm in a C name address pair when lib prefix is needed]) 5925_LT_DECL([], [nm_file_list_spec], [1], 5926 [Specify filename containing input files for $NM]) 5927]) # _LT_CMD_GLOBAL_SYMBOLS 5928 5929 5930# _LT_COMPILER_PIC([TAGNAME]) 5931# --------------------------- 5932m4_defun([_LT_COMPILER_PIC], 5933[m4_require([_LT_TAG_COMPILER])dnl 5934_LT_TAGVAR(lt_prog_compiler_wl, $1)= 5935_LT_TAGVAR(lt_prog_compiler_pic, $1)= 5936_LT_TAGVAR(lt_prog_compiler_static, $1)= 5937 5938m4_if([$1], [CXX], [ 5939 # C++ specific cases for pic, static, wl, etc. 5940 if test "$GXX" = yes; then 5941 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 5942 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 5943 5944 case $host_os in 5945 aix*) 5946 # All AIX code is PIC. 5947 if test "$host_cpu" = ia64; then 5948 # AIX 5 now supports IA64 processor 5949 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 5950 fi 5951 ;; 5952 5953 amigaos*) 5954 case $host_cpu in 5955 powerpc) 5956 # see comment about AmigaOS4 .so support 5957 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 5958 ;; 5959 m68k) 5960 # FIXME: we need at least 68020 code to build shared libraries, but 5961 # adding the `-m68020' flag to GCC prevents building anything better, 5962 # like `-m68040'. 5963 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 5964 ;; 5965 esac 5966 ;; 5967 5968 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 5969 # PIC is the default for these OSes. 5970 ;; 5971 mingw* | cygwin* | os2* | pw32* | cegcc*) 5972 # This hack is so that the source file can tell whether it is being 5973 # built for inclusion in a dll (and should export symbols for example). 5974 # Although the cygwin gcc ignores -fPIC, still need this for old-style 5975 # (--disable-auto-import) libraries 5976 m4_if([$1], [GCJ], [], 5977 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 5978 ;; 5979 darwin* | rhapsody*) 5980 # PIC is the default on this platform 5981 # Common symbols not allowed in MH_DYLIB files 5982 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 5983 ;; 5984 *djgpp*) 5985 # DJGPP does not support shared libraries at all 5986 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 5987 ;; 5988 haiku*) 5989 # PIC is the default for Haiku. 5990 # The "-static" flag exists, but is broken. 5991 _LT_TAGVAR(lt_prog_compiler_static, $1)= 5992 ;; 5993 interix[[3-9]]*) 5994 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 5995 # Instead, we relocate shared libraries at runtime. 5996 ;; 5997 sysv4*MP*) 5998 if test -d /usr/nec; then 5999 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 6000 fi 6001 ;; 6002 hpux*) 6003 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 6004 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 6005 # sets the default TLS model and affects inlining. 6006 case $host_cpu in 6007 hppa*64*) 6008 ;; 6009 *) 6010 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6011 ;; 6012 esac 6013 ;; 6014 *qnx* | *nto*) 6015 # QNX uses GNU C++, but need to define -shared option too, otherwise 6016 # it will coredump. 6017 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6018 ;; 6019 *) 6020 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6021 ;; 6022 esac 6023 else 6024 case $host_os in 6025 aix[[4-9]]*) 6026 # All AIX code is PIC. 6027 if test "$host_cpu" = ia64; then 6028 # AIX 5 now supports IA64 processor 6029 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6030 else 6031 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6032 fi 6033 ;; 6034 chorus*) 6035 case $cc_basename in 6036 cxch68*) 6037 # Green Hills C++ Compiler 6038 # _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" 6039 ;; 6040 esac 6041 ;; 6042 mingw* | cygwin* | os2* | pw32* | cegcc*) 6043 # This hack is so that the source file can tell whether it is being 6044 # built for inclusion in a dll (and should export symbols for example). 6045 m4_if([$1], [GCJ], [], 6046 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6047 ;; 6048 dgux*) 6049 case $cc_basename in 6050 ec++*) 6051 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6052 ;; 6053 ghcx*) 6054 # Green Hills C++ Compiler 6055 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6056 ;; 6057 *) 6058 ;; 6059 esac 6060 ;; 6061 freebsd* | dragonfly*) 6062 # FreeBSD uses GNU C++ 6063 ;; 6064 hpux9* | hpux10* | hpux11*) 6065 case $cc_basename in 6066 CC*) 6067 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6068 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6069 if test "$host_cpu" != ia64; then 6070 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6071 fi 6072 ;; 6073 aCC*) 6074 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6075 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6076 case $host_cpu in 6077 hppa*64*|ia64*) 6078 # +Z the default 6079 ;; 6080 *) 6081 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6082 ;; 6083 esac 6084 ;; 6085 *) 6086 ;; 6087 esac 6088 ;; 6089 interix*) 6090 # This is c89, which is MS Visual C++ (no shared libs) 6091 # Anyone wants to do a port? 6092 ;; 6093 irix5* | irix6* | nonstopux*) 6094 case $cc_basename in 6095 CC*) 6096 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6097 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6098 # CC pic flag -KPIC is the default. 6099 ;; 6100 *) 6101 ;; 6102 esac 6103 ;; 6104 linux* | k*bsd*-gnu | kopensolaris*-gnu) 6105 case $cc_basename in 6106 KCC*) 6107 # KAI C++ Compiler 6108 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6109 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6110 ;; 6111 ecpc* ) 6112 # old Intel C++ for x86_64 which still supported -KPIC. 6113 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6114 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6115 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6116 ;; 6117 icpc* ) 6118 # Intel C++, used to be incompatible with GCC. 6119 # ICC 10 doesn't accept -KPIC any more. 6120 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6121 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6122 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6123 ;; 6124 pgCC* | pgcpp*) 6125 # Portland Group C++ compiler 6126 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6127 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6128 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6129 ;; 6130 cxx*) 6131 # Compaq C++ 6132 # Make sure the PIC flag is empty. It appears that all Alpha 6133 # Linux and Compaq Tru64 Unix objects are PIC. 6134 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6135 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6136 ;; 6137 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) 6138 # IBM XL 8.0, 9.0 on PPC and BlueGene 6139 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6140 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 6141 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 6142 ;; 6143 *) 6144 case `$CC -V 2>&1 | sed 5q` in 6145 *Sun\ C*) 6146 # Sun C++ 5.9 6147 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6148 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6149 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6150 ;; 6151 esac 6152 ;; 6153 esac 6154 ;; 6155 lynxos*) 6156 ;; 6157 m88k*) 6158 ;; 6159 mvs*) 6160 case $cc_basename in 6161 cxx*) 6162 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 6163 ;; 6164 *) 6165 ;; 6166 esac 6167 ;; 6168 netbsd*) 6169 ;; 6170 *qnx* | *nto*) 6171 # QNX uses GNU C++, but need to define -shared option too, otherwise 6172 # it will coredump. 6173 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6174 ;; 6175 osf3* | osf4* | osf5*) 6176 case $cc_basename in 6177 KCC*) 6178 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6179 ;; 6180 RCC*) 6181 # Rational C++ 2.4.1 6182 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6183 ;; 6184 cxx*) 6185 # Digital/Compaq C++ 6186 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6187 # Make sure the PIC flag is empty. It appears that all Alpha 6188 # Linux and Compaq Tru64 Unix objects are PIC. 6189 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6190 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6191 ;; 6192 *) 6193 ;; 6194 esac 6195 ;; 6196 psos*) 6197 ;; 6198 solaris*) 6199 case $cc_basename in 6200 CC* | sunCC*) 6201 # Sun C++ 4.2, 5.x and Centerline C++ 6202 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6203 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6204 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6205 ;; 6206 gcx*) 6207 # Green Hills C++ Compiler 6208 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6209 ;; 6210 *) 6211 ;; 6212 esac 6213 ;; 6214 sunos4*) 6215 case $cc_basename in 6216 CC*) 6217 # Sun C++ 4.x 6218 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6219 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6220 ;; 6221 lcc*) 6222 # Lucid 6223 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6224 ;; 6225 *) 6226 ;; 6227 esac 6228 ;; 6229 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 6230 case $cc_basename in 6231 CC*) 6232 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6233 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6234 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6235 ;; 6236 esac 6237 ;; 6238 tandem*) 6239 case $cc_basename in 6240 NCC*) 6241 # NonStop-UX NCC 3.20 6242 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6243 ;; 6244 *) 6245 ;; 6246 esac 6247 ;; 6248 vxworks*) 6249 ;; 6250 *) 6251 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6252 ;; 6253 esac 6254 fi 6255], 6256[ 6257 if test "$GCC" = yes; then 6258 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6259 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6260 6261 case $host_os in 6262 aix*) 6263 # All AIX code is PIC. 6264 if test "$host_cpu" = ia64; then 6265 # AIX 5 now supports IA64 processor 6266 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6267 fi 6268 ;; 6269 6270 amigaos*) 6271 case $host_cpu in 6272 powerpc) 6273 # see comment about AmigaOS4 .so support 6274 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6275 ;; 6276 m68k) 6277 # FIXME: we need at least 68020 code to build shared libraries, but 6278 # adding the `-m68020' flag to GCC prevents building anything better, 6279 # like `-m68040'. 6280 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 6281 ;; 6282 esac 6283 ;; 6284 6285 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 6286 # PIC is the default for these OSes. 6287 ;; 6288 6289 mingw* | cygwin* | pw32* | os2* | cegcc*) 6290 # This hack is so that the source file can tell whether it is being 6291 # built for inclusion in a dll (and should export symbols for example). 6292 # Although the cygwin gcc ignores -fPIC, still need this for old-style 6293 # (--disable-auto-import) libraries 6294 m4_if([$1], [GCJ], [], 6295 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6296 ;; 6297 6298 darwin* | rhapsody*) 6299 # PIC is the default on this platform 6300 # Common symbols not allowed in MH_DYLIB files 6301 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 6302 ;; 6303 6304 haiku*) 6305 # PIC is the default for Haiku. 6306 # The "-static" flag exists, but is broken. 6307 _LT_TAGVAR(lt_prog_compiler_static, $1)= 6308 ;; 6309 6310 hpux*) 6311 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 6312 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 6313 # sets the default TLS model and affects inlining. 6314 case $host_cpu in 6315 hppa*64*) 6316 # +Z the default 6317 ;; 6318 *) 6319 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6320 ;; 6321 esac 6322 ;; 6323 6324 interix[[3-9]]*) 6325 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 6326 # Instead, we relocate shared libraries at runtime. 6327 ;; 6328 6329 msdosdjgpp*) 6330 # Just because we use GCC doesn't mean we suddenly get shared libraries 6331 # on systems that don't support them. 6332 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6333 enable_shared=no 6334 ;; 6335 6336 *nto* | *qnx*) 6337 # QNX uses GNU C++, but need to define -shared option too, otherwise 6338 # it will coredump. 6339 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6340 ;; 6341 6342 sysv4*MP*) 6343 if test -d /usr/nec; then 6344 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 6345 fi 6346 ;; 6347 6348 *) 6349 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6350 ;; 6351 esac 6352 6353 case $cc_basename in 6354 nvcc*) # Cuda Compiler Driver 2.2 6355 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' 6356 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 6357 _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" 6358 fi 6359 ;; 6360 esac 6361 else 6362 # PORTME Check for flag to pass linker flags through the system compiler. 6363 case $host_os in 6364 aix*) 6365 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6366 if test "$host_cpu" = ia64; then 6367 # AIX 5 now supports IA64 processor 6368 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6369 else 6370 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6371 fi 6372 ;; 6373 6374 mingw* | cygwin* | pw32* | os2* | cegcc*) 6375 # This hack is so that the source file can tell whether it is being 6376 # built for inclusion in a dll (and should export symbols for example). 6377 m4_if([$1], [GCJ], [], 6378 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6379 ;; 6380 6381 hpux9* | hpux10* | hpux11*) 6382 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6383 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 6384 # not for PA HP-UX. 6385 case $host_cpu in 6386 hppa*64*|ia64*) 6387 # +Z the default 6388 ;; 6389 *) 6390 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6391 ;; 6392 esac 6393 # Is there a better lt_prog_compiler_static that works with the bundled CC? 6394 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6395 ;; 6396 6397 irix5* | irix6* | nonstopux*) 6398 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6399 # PIC (with -KPIC) is the default. 6400 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6401 ;; 6402 6403 linux* | k*bsd*-gnu | kopensolaris*-gnu) 6404 case $cc_basename in 6405 # old Intel for x86_64 which still supported -KPIC. 6406 ecc*) 6407 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6408 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6409 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6410 ;; 6411 # icc used to be incompatible with GCC. 6412 # ICC 10 doesn't accept -KPIC any more. 6413 icc* | ifort*) 6414 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6415 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6416 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6417 ;; 6418 # Lahey Fortran 8.1. 6419 lf95*) 6420 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6421 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 6422 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 6423 ;; 6424 nagfor*) 6425 # NAG Fortran compiler 6426 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' 6427 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6428 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6429 ;; 6430 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) 6431 # Portland Group compilers (*not* the Pentium gcc compiler, 6432 # which looks to be a dead project) 6433 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6434 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6435 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6436 ;; 6437 ccc*) 6438 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6439 # All Alpha code is PIC. 6440 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6441 ;; 6442 xl* | bgxl* | bgf* | mpixl*) 6443 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 6444 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6445 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 6446 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 6447 ;; 6448 *) 6449 case `$CC -V 2>&1 | sed 5q` in 6450 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) 6451 # Sun Fortran 8.3 passes all unrecognized flags to the linker 6452 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6453 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6454 _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 6455 ;; 6456 *Sun\ F* | *Sun*Fortran*) 6457 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6458 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6459 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6460 ;; 6461 *Sun\ C*) 6462 # Sun C 5.9 6463 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6464 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6465 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6466 ;; 6467 *Intel*\ [[CF]]*Compiler*) 6468 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6469 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6470 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6471 ;; 6472 *Portland\ Group*) 6473 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6474 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6475 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6476 ;; 6477 esac 6478 ;; 6479 esac 6480 ;; 6481 6482 newsos6) 6483 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6484 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6485 ;; 6486 6487 *nto* | *qnx*) 6488 # QNX uses GNU C++, but need to define -shared option too, otherwise 6489 # it will coredump. 6490 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6491 ;; 6492 6493 osf3* | osf4* | osf5*) 6494 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6495 # All OSF/1 code is PIC. 6496 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6497 ;; 6498 6499 rdos*) 6500 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6501 ;; 6502 6503 solaris*) 6504 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6505 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6506 case $cc_basename in 6507 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) 6508 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 6509 *) 6510 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 6511 esac 6512 ;; 6513 6514 sunos4*) 6515 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6516 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6517 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6518 ;; 6519 6520 sysv4 | sysv4.2uw2* | sysv4.3*) 6521 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6522 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6523 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6524 ;; 6525 6526 sysv4*MP*) 6527 if test -d /usr/nec ;then 6528 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 6529 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6530 fi 6531 ;; 6532 6533 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 6534 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6535 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6536 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6537 ;; 6538 6539 unicos*) 6540 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6541 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6542 ;; 6543 6544 uts4*) 6545 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6546 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6547 ;; 6548 6549 *) 6550 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6551 ;; 6552 esac 6553 fi 6554]) 6555case $host_os in 6556 # For platforms which do not support PIC, -DPIC is meaningless: 6557 *djgpp*) 6558 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6559 ;; 6560 *) 6561 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 6562 ;; 6563esac 6564 6565AC_CACHE_CHECK([for $compiler option to produce PIC], 6566 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], 6567 [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 6568_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) 6569 6570# 6571# Check to make sure the PIC flag actually works. 6572# 6573if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 6574 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 6575 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 6576 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 6577 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 6578 "" | " "*) ;; 6579 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 6580 esac], 6581 [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 6582 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 6583fi 6584_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 6585 [Additional compiler flags for building library objects]) 6586 6587_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 6588 [How to pass a linker flag through the compiler]) 6589# 6590# Check to make sure the static flag actually works. 6591# 6592wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 6593_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 6594 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 6595 $lt_tmp_static_flag, 6596 [], 6597 [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 6598_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 6599 [Compiler flag to prevent dynamic linking]) 6600])# _LT_COMPILER_PIC 6601 6602 6603# _LT_LINKER_SHLIBS([TAGNAME]) 6604# ---------------------------- 6605# See if the linker supports building shared libraries. 6606m4_defun([_LT_LINKER_SHLIBS], 6607[AC_REQUIRE([LT_PATH_LD])dnl 6608AC_REQUIRE([LT_PATH_NM])dnl 6609m4_require([_LT_PATH_MANIFEST_TOOL])dnl 6610m4_require([_LT_FILEUTILS_DEFAULTS])dnl 6611m4_require([_LT_DECL_EGREP])dnl 6612m4_require([_LT_DECL_SED])dnl 6613m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 6614m4_require([_LT_TAG_COMPILER])dnl 6615AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 6616m4_if([$1], [CXX], [ 6617 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6618 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 6619 case $host_os in 6620 aix[[4-9]]*) 6621 # If we're using GNU nm, then we don't want the "-C" option. 6622 # -C means demangle to AIX nm, but means don't demangle with GNU nm 6623 # Also, AIX nm treats weak defined symbols like other global defined 6624 # symbols, whereas GNU nm marks them as "W". 6625 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 6626 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 6627 else 6628 _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' 6629 fi 6630 ;; 6631 pw32*) 6632 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 6633 ;; 6634 cygwin* | mingw* | cegcc*) 6635 case $cc_basename in 6636 cl*) 6637 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' 6638 ;; 6639 *) 6640 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' 6641 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 6642 ;; 6643 esac 6644 ;; 6645 *) 6646 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6647 ;; 6648 esac 6649], [ 6650 runpath_var= 6651 _LT_TAGVAR(allow_undefined_flag, $1)= 6652 _LT_TAGVAR(always_export_symbols, $1)=no 6653 _LT_TAGVAR(archive_cmds, $1)= 6654 _LT_TAGVAR(archive_expsym_cmds, $1)= 6655 _LT_TAGVAR(compiler_needs_object, $1)=no 6656 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 6657 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 6658 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6659 _LT_TAGVAR(hardcode_automatic, $1)=no 6660 _LT_TAGVAR(hardcode_direct, $1)=no 6661 _LT_TAGVAR(hardcode_direct_absolute, $1)=no 6662 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6663 _LT_TAGVAR(hardcode_libdir_separator, $1)= 6664 _LT_TAGVAR(hardcode_minus_L, $1)=no 6665 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 6666 _LT_TAGVAR(inherit_rpath, $1)=no 6667 _LT_TAGVAR(link_all_deplibs, $1)=unknown 6668 _LT_TAGVAR(module_cmds, $1)= 6669 _LT_TAGVAR(module_expsym_cmds, $1)= 6670 _LT_TAGVAR(old_archive_from_new_cmds, $1)= 6671 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 6672 _LT_TAGVAR(thread_safe_flag_spec, $1)= 6673 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6674 # include_expsyms should be a list of space-separated symbols to be *always* 6675 # included in the symbol list 6676 _LT_TAGVAR(include_expsyms, $1)= 6677 # exclude_expsyms can be an extended regexp of symbols to exclude 6678 # it will be wrapped by ` (' and `)$', so one must not match beginning or 6679 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 6680 # as well as any symbol that contains `d'. 6681 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 6682 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 6683 # platforms (ab)use it in PIC code, but their linkers get confused if 6684 # the symbol is explicitly referenced. Since portable code cannot 6685 # rely on this symbol name, it's probably fine to never include it in 6686 # preloaded symbol tables. 6687 # Exclude shared library initialization/finalization symbols. 6688dnl Note also adjust exclude_expsyms for C++ above. 6689 extract_expsyms_cmds= 6690 6691 case $host_os in 6692 cygwin* | mingw* | pw32* | cegcc*) 6693 # FIXME: the MSVC++ port hasn't been tested in a loooong time 6694 # When not using gcc, we currently assume that we are using 6695 # Microsoft Visual C++. 6696 if test "$GCC" != yes; then 6697 with_gnu_ld=no 6698 fi 6699 ;; 6700 interix*) 6701 # we just hope/assume this is gcc and not c89 (= MSVC++) 6702 with_gnu_ld=yes 6703 ;; 6704 openbsd*) 6705 with_gnu_ld=no 6706 ;; 6707 esac 6708 6709 _LT_TAGVAR(ld_shlibs, $1)=yes 6710 6711 # On some targets, GNU ld is compatible enough with the native linker 6712 # that we're better off using the native interface for both. 6713 lt_use_gnu_ld_interface=no 6714 if test "$with_gnu_ld" = yes; then 6715 case $host_os in 6716 aix*) 6717 # The AIX port of GNU ld has always aspired to compatibility 6718 # with the native linker. However, as the warning in the GNU ld 6719 # block says, versions before 2.19.5* couldn't really create working 6720 # shared libraries, regardless of the interface used. 6721 case `$LD -v 2>&1` in 6722 *\ \(GNU\ Binutils\)\ 2.19.5*) ;; 6723 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; 6724 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; 6725 *) 6726 lt_use_gnu_ld_interface=yes 6727 ;; 6728 esac 6729 ;; 6730 *) 6731 lt_use_gnu_ld_interface=yes 6732 ;; 6733 esac 6734 fi 6735 6736 if test "$lt_use_gnu_ld_interface" = yes; then 6737 # If archive_cmds runs LD, not CC, wlarc should be empty 6738 wlarc='${wl}' 6739 6740 # Set some defaults for GNU ld with shared library support. These 6741 # are reset later if shared libraries are not supported. Putting them 6742 # here allows them to be overridden if necessary. 6743 runpath_var=LD_RUN_PATH 6744 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6745 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6746 # ancient GNU ld didn't support --whole-archive et. al. 6747 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 6748 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6749 else 6750 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6751 fi 6752 supports_anon_versioning=no 6753 case `$LD -v 2>&1` in 6754 *GNU\ gold*) supports_anon_versioning=yes ;; 6755 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 6756 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 6757 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 6758 *\ 2.11.*) ;; # other 2.11 versions 6759 *) supports_anon_versioning=yes ;; 6760 esac 6761 6762 # See if GNU ld supports shared libraries. 6763 case $host_os in 6764 aix[[3-9]]*) 6765 # On AIX/PPC, the GNU linker is very broken 6766 if test "$host_cpu" != ia64; then 6767 _LT_TAGVAR(ld_shlibs, $1)=no 6768 cat <<_LT_EOF 1>&2 6769 6770*** Warning: the GNU linker, at least up to release 2.19, is reported 6771*** to be unable to reliably create shared libraries on AIX. 6772*** Therefore, libtool is disabling shared libraries support. If you 6773*** really care for shared libraries, you may want to install binutils 6774*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. 6775*** You will then need to restart the configuration process. 6776 6777_LT_EOF 6778 fi 6779 ;; 6780 6781 amigaos*) 6782 case $host_cpu in 6783 powerpc) 6784 # see comment about AmigaOS4 .so support 6785 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6786 _LT_TAGVAR(archive_expsym_cmds, $1)='' 6787 ;; 6788 m68k) 6789 _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)' 6790 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6791 _LT_TAGVAR(hardcode_minus_L, $1)=yes 6792 ;; 6793 esac 6794 ;; 6795 6796 beos*) 6797 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6798 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6799 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 6800 # support --undefined. This deserves some investigation. FIXME 6801 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6802 else 6803 _LT_TAGVAR(ld_shlibs, $1)=no 6804 fi 6805 ;; 6806 6807 cygwin* | mingw* | pw32* | cegcc*) 6808 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 6809 # as there is no search path for DLLs. 6810 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6811 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 6812 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6813 _LT_TAGVAR(always_export_symbols, $1)=no 6814 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6815 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' 6816 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 6817 6818 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 6819 _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' 6820 # If the export-symbols file already is a .def file (1st line 6821 # is EXPORTS), use it as is; otherwise, prepend... 6822 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 6823 cp $export_symbols $output_objdir/$soname.def; 6824 else 6825 echo EXPORTS > $output_objdir/$soname.def; 6826 cat $export_symbols >> $output_objdir/$soname.def; 6827 fi~ 6828 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 6829 else 6830 _LT_TAGVAR(ld_shlibs, $1)=no 6831 fi 6832 ;; 6833 6834 haiku*) 6835 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6836 _LT_TAGVAR(link_all_deplibs, $1)=yes 6837 ;; 6838 6839 interix[[3-9]]*) 6840 _LT_TAGVAR(hardcode_direct, $1)=no 6841 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6842 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6843 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6844 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 6845 # Instead, shared libraries are loaded at an image base (0x10000000 by 6846 # default) and relocated if they conflict, which is a slow very memory 6847 # consuming and fragmenting process. To avoid this, we pick a random, 6848 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 6849 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 6850 _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' 6851 _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' 6852 ;; 6853 6854 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 6855 tmp_diet=no 6856 if test "$host_os" = linux-dietlibc; then 6857 case $cc_basename in 6858 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 6859 esac 6860 fi 6861 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 6862 && test "$tmp_diet" = no 6863 then 6864 tmp_addflag=' $pic_flag' 6865 tmp_sharedflag='-shared' 6866 case $cc_basename,$host_cpu in 6867 pgcc*) # Portland Group C compiler 6868 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6869 tmp_addflag=' $pic_flag' 6870 ;; 6871 pgf77* | pgf90* | pgf95* | pgfortran*) 6872 # Portland Group f77 and f90 compilers 6873 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6874 tmp_addflag=' $pic_flag -Mnomain' ;; 6875 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 6876 tmp_addflag=' -i_dynamic' ;; 6877 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 6878 tmp_addflag=' -i_dynamic -nofor_main' ;; 6879 ifc* | ifort*) # Intel Fortran compiler 6880 tmp_addflag=' -nofor_main' ;; 6881 lf95*) # Lahey Fortran 8.1 6882 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6883 tmp_sharedflag='--shared' ;; 6884 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 6885 tmp_sharedflag='-qmkshrobj' 6886 tmp_addflag= ;; 6887 nvcc*) # Cuda Compiler Driver 2.2 6888 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6889 _LT_TAGVAR(compiler_needs_object, $1)=yes 6890 ;; 6891 esac 6892 case `$CC -V 2>&1 | sed 5q` in 6893 *Sun\ C*) # Sun C 5.9 6894 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6895 _LT_TAGVAR(compiler_needs_object, $1)=yes 6896 tmp_sharedflag='-G' ;; 6897 *Sun\ F*) # Sun Fortran 8.3 6898 tmp_sharedflag='-G' ;; 6899 esac 6900 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6901 6902 if test "x$supports_anon_versioning" = xyes; then 6903 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6904 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6905 echo "local: *; };" >> $output_objdir/$libname.ver~ 6906 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 6907 fi 6908 6909 case $cc_basename in 6910 xlf* | bgf* | bgxlf* | mpixlf*) 6911 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 6912 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 6913 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6914 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' 6915 if test "x$supports_anon_versioning" = xyes; then 6916 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6917 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6918 echo "local: *; };" >> $output_objdir/$libname.ver~ 6919 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 6920 fi 6921 ;; 6922 esac 6923 else 6924 _LT_TAGVAR(ld_shlibs, $1)=no 6925 fi 6926 ;; 6927 6928 netbsd*) 6929 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 6930 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 6931 wlarc= 6932 else 6933 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6934 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6935 fi 6936 ;; 6937 6938 solaris*) 6939 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 6940 _LT_TAGVAR(ld_shlibs, $1)=no 6941 cat <<_LT_EOF 1>&2 6942 6943*** Warning: The releases 2.8.* of the GNU linker cannot reliably 6944*** create shared libraries on Solaris systems. Therefore, libtool 6945*** is disabling shared libraries support. We urge you to upgrade GNU 6946*** binutils to release 2.9.1 or newer. Another option is to modify 6947*** your PATH or compiler configuration so that the native linker is 6948*** used, and then restart. 6949 6950_LT_EOF 6951 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6952 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6953 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6954 else 6955 _LT_TAGVAR(ld_shlibs, $1)=no 6956 fi 6957 ;; 6958 6959 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 6960 case `$LD -v 2>&1` in 6961 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 6962 _LT_TAGVAR(ld_shlibs, $1)=no 6963 cat <<_LT_EOF 1>&2 6964 6965*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 6966*** reliably create shared libraries on SCO systems. Therefore, libtool 6967*** is disabling shared libraries support. We urge you to upgrade GNU 6968*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 6969*** your PATH or compiler configuration so that the native linker is 6970*** used, and then restart. 6971 6972_LT_EOF 6973 ;; 6974 *) 6975 # For security reasons, it is highly recommended that you always 6976 # use absolute paths for naming shared libraries, and exclude the 6977 # DT_RUNPATH tag from executables and libraries. But doing so 6978 # requires that you compile everything twice, which is a pain. 6979 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6980 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6981 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6982 _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' 6983 else 6984 _LT_TAGVAR(ld_shlibs, $1)=no 6985 fi 6986 ;; 6987 esac 6988 ;; 6989 6990 sunos4*) 6991 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 6992 wlarc= 6993 _LT_TAGVAR(hardcode_direct, $1)=yes 6994 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6995 ;; 6996 6997 *) 6998 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6999 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7000 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 7001 else 7002 _LT_TAGVAR(ld_shlibs, $1)=no 7003 fi 7004 ;; 7005 esac 7006 7007 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then 7008 runpath_var= 7009 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7010 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 7011 _LT_TAGVAR(whole_archive_flag_spec, $1)= 7012 fi 7013 else 7014 # PORTME fill in a description of your system's linker (not GNU ld) 7015 case $host_os in 7016 aix3*) 7017 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7018 _LT_TAGVAR(always_export_symbols, $1)=yes 7019 _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' 7020 # Note: this linker hardcodes the directories in LIBPATH if there 7021 # are no directories specified by -L. 7022 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7023 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 7024 # Neither direct hardcoding nor static linking is supported with a 7025 # broken collect2. 7026 _LT_TAGVAR(hardcode_direct, $1)=unsupported 7027 fi 7028 ;; 7029 7030 aix[[4-9]]*) 7031 if test "$host_cpu" = ia64; then 7032 # On IA64, the linker does run time linking by default, so we don't 7033 # have to do anything special. 7034 aix_use_runtimelinking=no 7035 exp_sym_flag='-Bexport' 7036 no_entry_flag="" 7037 else 7038 # If we're using GNU nm, then we don't want the "-C" option. 7039 # -C means demangle to AIX nm, but means don't demangle with GNU nm 7040 # Also, AIX nm treats weak defined symbols like other global 7041 # defined symbols, whereas GNU nm marks them as "W". 7042 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 7043 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 7044 else 7045 _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' 7046 fi 7047 aix_use_runtimelinking=no 7048 7049 # Test if we are trying to use run time linking or normal 7050 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 7051 # need to do runtime linking. 7052 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 7053 for ld_flag in $LDFLAGS; do 7054 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 7055 aix_use_runtimelinking=yes 7056 break 7057 fi 7058 done 7059 ;; 7060 esac 7061 7062 exp_sym_flag='-bexport' 7063 no_entry_flag='-bnoentry' 7064 fi 7065 7066 # When large executables or shared objects are built, AIX ld can 7067 # have problems creating the table of contents. If linking a library 7068 # or program results in "error TOC overflow" add -mminimal-toc to 7069 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 7070 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 7071 7072 _LT_TAGVAR(archive_cmds, $1)='' 7073 _LT_TAGVAR(hardcode_direct, $1)=yes 7074 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7075 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7076 _LT_TAGVAR(link_all_deplibs, $1)=yes 7077 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 7078 7079 if test "$GCC" = yes; then 7080 case $host_os in aix4.[[012]]|aix4.[[012]].*) 7081 # We only want to do this on AIX 4.2 and lower, the check 7082 # below for broken collect2 doesn't work under 4.3+ 7083 collect2name=`${CC} -print-prog-name=collect2` 7084 if test -f "$collect2name" && 7085 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 7086 then 7087 # We have reworked collect2 7088 : 7089 else 7090 # We have old collect2 7091 _LT_TAGVAR(hardcode_direct, $1)=unsupported 7092 # It fails to find uninstalled libraries when the uninstalled 7093 # path is not listed in the libpath. Setting hardcode_minus_L 7094 # to unsupported forces relinking 7095 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7096 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7097 _LT_TAGVAR(hardcode_libdir_separator, $1)= 7098 fi 7099 ;; 7100 esac 7101 shared_flag='-shared' 7102 if test "$aix_use_runtimelinking" = yes; then 7103 shared_flag="$shared_flag "'${wl}-G' 7104 fi 7105 else 7106 # not using gcc 7107 if test "$host_cpu" = ia64; then 7108 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 7109 # chokes on -Wl,-G. The following line is correct: 7110 shared_flag='-G' 7111 else 7112 if test "$aix_use_runtimelinking" = yes; then 7113 shared_flag='${wl}-G' 7114 else 7115 shared_flag='${wl}-bM:SRE' 7116 fi 7117 fi 7118 fi 7119 7120 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 7121 # It seems that -bexpall does not export symbols beginning with 7122 # underscore (_), so it is better to generate a list of symbols to export. 7123 _LT_TAGVAR(always_export_symbols, $1)=yes 7124 if test "$aix_use_runtimelinking" = yes; then 7125 # Warning - without using the other runtime loading flags (-brtl), 7126 # -berok will link without error, but may produce a broken library. 7127 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 7128 # Determine the default libpath from the value encoded in an 7129 # empty executable. 7130 _LT_SYS_MODULE_PATH_AIX([$1]) 7131 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7132 _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 func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 7133 else 7134 if test "$host_cpu" = ia64; then 7135 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 7136 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 7137 _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" 7138 else 7139 # Determine the default libpath from the value encoded in an 7140 # empty executable. 7141 _LT_SYS_MODULE_PATH_AIX([$1]) 7142 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7143 # Warning - without using the other run time loading flags, 7144 # -berok will link without error, but may produce a broken library. 7145 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 7146 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 7147 if test "$with_gnu_ld" = yes; then 7148 # We only use this code for GNU lds that support --whole-archive. 7149 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 7150 else 7151 # Exported symbols can be pulled into shared objects from archives 7152 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 7153 fi 7154 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7155 # This is similar to how AIX traditionally builds its shared libraries. 7156 _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' 7157 fi 7158 fi 7159 ;; 7160 7161 amigaos*) 7162 case $host_cpu in 7163 powerpc) 7164 # see comment about AmigaOS4 .so support 7165 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7166 _LT_TAGVAR(archive_expsym_cmds, $1)='' 7167 ;; 7168 m68k) 7169 _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)' 7170 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7171 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7172 ;; 7173 esac 7174 ;; 7175 7176 bsdi[[45]]*) 7177 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 7178 ;; 7179 7180 cygwin* | mingw* | pw32* | cegcc*) 7181 # When not using gcc, we currently assume that we are using 7182 # Microsoft Visual C++. 7183 # hardcode_libdir_flag_spec is actually meaningless, as there is 7184 # no search path for DLLs. 7185 case $cc_basename in 7186 cl*) 7187 # Native MSVC 7188 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 7189 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7190 _LT_TAGVAR(always_export_symbols, $1)=yes 7191 _LT_TAGVAR(file_list_spec, $1)='@' 7192 # Tell ltmain to make .lib files, not .a files. 7193 libext=lib 7194 # Tell ltmain to make .dll files, not .so files. 7195 shrext_cmds=".dll" 7196 # FIXME: Setting linknames here is a bad hack. 7197 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' 7198 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 7199 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; 7200 else 7201 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; 7202 fi~ 7203 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 7204 linknames=' 7205 # The linker will not automatically build a static lib if we build a DLL. 7206 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 7207 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 7208 _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' 7209 _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' 7210 # Don't use ranlib 7211 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 7212 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 7213 lt_tool_outputfile="@TOOL_OUTPUT@"~ 7214 case $lt_outputfile in 7215 *.exe|*.EXE) ;; 7216 *) 7217 lt_outputfile="$lt_outputfile.exe" 7218 lt_tool_outputfile="$lt_tool_outputfile.exe" 7219 ;; 7220 esac~ 7221 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then 7222 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 7223 $RM "$lt_outputfile.manifest"; 7224 fi' 7225 ;; 7226 *) 7227 # Assume MSVC wrapper 7228 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 7229 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7230 # Tell ltmain to make .lib files, not .a files. 7231 libext=lib 7232 # Tell ltmain to make .dll files, not .so files. 7233 shrext_cmds=".dll" 7234 # FIXME: Setting linknames here is a bad hack. 7235 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' 7236 # The linker will automatically build a .lib file if we build a DLL. 7237 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 7238 # FIXME: Should let the user specify the lib program. 7239 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 7240 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 7241 ;; 7242 esac 7243 ;; 7244 7245 darwin* | rhapsody*) 7246 _LT_DARWIN_LINKER_FEATURES($1) 7247 ;; 7248 7249 dgux*) 7250 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7251 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7252 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7253 ;; 7254 7255 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 7256 # support. Future versions do this automatically, but an explicit c++rt0.o 7257 # does not break anything, and helps significantly (at the cost of a little 7258 # extra space). 7259 freebsd2.2*) 7260 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 7261 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7262 _LT_TAGVAR(hardcode_direct, $1)=yes 7263 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7264 ;; 7265 7266 # Unfortunately, older versions of FreeBSD 2 do not have this feature. 7267 freebsd2.*) 7268 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7269 _LT_TAGVAR(hardcode_direct, $1)=yes 7270 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7271 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7272 ;; 7273 7274 # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 7275 freebsd* | dragonfly*) 7276 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7277 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7278 _LT_TAGVAR(hardcode_direct, $1)=yes 7279 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7280 ;; 7281 7282 hpux9*) 7283 if test "$GCC" = yes; then 7284 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 7285 else 7286 _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' 7287 fi 7288 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7289 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7290 _LT_TAGVAR(hardcode_direct, $1)=yes 7291 7292 # hardcode_minus_L: Not really in the search PATH, 7293 # but as the default location of the library. 7294 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7295 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7296 ;; 7297 7298 hpux10*) 7299 if test "$GCC" = yes && test "$with_gnu_ld" = no; then 7300 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7301 else 7302 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 7303 fi 7304 if test "$with_gnu_ld" = no; then 7305 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7306 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7307 _LT_TAGVAR(hardcode_direct, $1)=yes 7308 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7309 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7310 # hardcode_minus_L: Not really in the search PATH, 7311 # but as the default location of the library. 7312 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7313 fi 7314 ;; 7315 7316 hpux11*) 7317 if test "$GCC" = yes && test "$with_gnu_ld" = no; then 7318 case $host_cpu in 7319 hppa*64*) 7320 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7321 ;; 7322 ia64*) 7323 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7324 ;; 7325 *) 7326 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7327 ;; 7328 esac 7329 else 7330 case $host_cpu in 7331 hppa*64*) 7332 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7333 ;; 7334 ia64*) 7335 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7336 ;; 7337 *) 7338 m4_if($1, [], [ 7339 # Older versions of the 11.00 compiler do not understand -b yet 7340 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) 7341 _LT_LINKER_OPTION([if $CC understands -b], 7342 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], 7343 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], 7344 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], 7345 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) 7346 ;; 7347 esac 7348 fi 7349 if test "$with_gnu_ld" = no; then 7350 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7351 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7352 7353 case $host_cpu in 7354 hppa*64*|ia64*) 7355 _LT_TAGVAR(hardcode_direct, $1)=no 7356 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7357 ;; 7358 *) 7359 _LT_TAGVAR(hardcode_direct, $1)=yes 7360 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7361 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7362 7363 # hardcode_minus_L: Not really in the search PATH, 7364 # but as the default location of the library. 7365 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7366 ;; 7367 esac 7368 fi 7369 ;; 7370 7371 irix5* | irix6* | nonstopux*) 7372 if test "$GCC" = yes; then 7373 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7374 # Try to use the -exported_symbol ld option, if it does not 7375 # work, assume that -exports_file does not work either and 7376 # implicitly export all symbols. 7377 # This should be the same for all languages, so no per-tag cache variable. 7378 AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], 7379 [lt_cv_irix_exported_symbol], 7380 [save_LDFLAGS="$LDFLAGS" 7381 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" 7382 AC_LINK_IFELSE( 7383 [AC_LANG_SOURCE( 7384 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], 7385 [C++], [[int foo (void) { return 0; }]], 7386 [Fortran 77], [[ 7387 subroutine foo 7388 end]], 7389 [Fortran], [[ 7390 subroutine foo 7391 end]])])], 7392 [lt_cv_irix_exported_symbol=yes], 7393 [lt_cv_irix_exported_symbol=no]) 7394 LDFLAGS="$save_LDFLAGS"]) 7395 if test "$lt_cv_irix_exported_symbol" = yes; then 7396 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' 7397 fi 7398 else 7399 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 7400 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' 7401 fi 7402 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7403 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7404 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7405 _LT_TAGVAR(inherit_rpath, $1)=yes 7406 _LT_TAGVAR(link_all_deplibs, $1)=yes 7407 ;; 7408 7409 netbsd*) 7410 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 7411 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 7412 else 7413 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 7414 fi 7415 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7416 _LT_TAGVAR(hardcode_direct, $1)=yes 7417 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7418 ;; 7419 7420 newsos6) 7421 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7422 _LT_TAGVAR(hardcode_direct, $1)=yes 7423 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7424 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7425 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7426 ;; 7427 7428 *nto* | *qnx*) 7429 ;; 7430 7431 openbsd*) 7432 if test -f /usr/libexec/ld.so; then 7433 _LT_TAGVAR(hardcode_direct, $1)=yes 7434 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7435 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7436 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 7437 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7438 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 7439 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7440 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7441 else 7442 case $host_os in 7443 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 7444 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7445 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7446 ;; 7447 *) 7448 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7449 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7450 ;; 7451 esac 7452 fi 7453 else 7454 _LT_TAGVAR(ld_shlibs, $1)=no 7455 fi 7456 ;; 7457 7458 os2*) 7459 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7460 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7461 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7462 _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' 7463 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 7464 ;; 7465 7466 osf3*) 7467 if test "$GCC" = yes; then 7468 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7469 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7470 else 7471 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 7472 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 7473 fi 7474 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7475 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7476 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7477 ;; 7478 7479 osf4* | osf5*) # as osf3* with the addition of -msym flag 7480 if test "$GCC" = yes; then 7481 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7482 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7483 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7484 else 7485 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 7486 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 7487 _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~ 7488 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' 7489 7490 # Both c and cxx compiler support -rpath directly 7491 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 7492 fi 7493 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7494 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7495 ;; 7496 7497 solaris*) 7498 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 7499 if test "$GCC" = yes; then 7500 wlarc='${wl}' 7501 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7502 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7503 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 7504 else 7505 case `$CC -V 2>&1` in 7506 *"Compilers 5.0"*) 7507 wlarc='' 7508 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 7509 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7510 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 7511 ;; 7512 *) 7513 wlarc='${wl}' 7514 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' 7515 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7516 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 7517 ;; 7518 esac 7519 fi 7520 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7521 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7522 case $host_os in 7523 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 7524 *) 7525 # The compiler driver will combine and reorder linker options, 7526 # but understands `-z linker_flag'. GCC discards it without `$wl', 7527 # but is careful enough not to reorder. 7528 # Supported since Solaris 2.6 (maybe 2.5.1?) 7529 if test "$GCC" = yes; then 7530 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 7531 else 7532 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 7533 fi 7534 ;; 7535 esac 7536 _LT_TAGVAR(link_all_deplibs, $1)=yes 7537 ;; 7538 7539 sunos4*) 7540 if test "x$host_vendor" = xsequent; then 7541 # Use $CC to link under sequent, because it throws in some extra .o 7542 # files that make .init and .fini sections work. 7543 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 7544 else 7545 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 7546 fi 7547 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7548 _LT_TAGVAR(hardcode_direct, $1)=yes 7549 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7550 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7551 ;; 7552 7553 sysv4) 7554 case $host_vendor in 7555 sni) 7556 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7557 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 7558 ;; 7559 siemens) 7560 ## LD is ld it makes a PLAMLIB 7561 ## CC just makes a GrossModule. 7562 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 7563 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 7564 _LT_TAGVAR(hardcode_direct, $1)=no 7565 ;; 7566 motorola) 7567 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7568 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 7569 ;; 7570 esac 7571 runpath_var='LD_RUN_PATH' 7572 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7573 ;; 7574 7575 sysv4.3*) 7576 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7577 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7578 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 7579 ;; 7580 7581 sysv4*MP*) 7582 if test -d /usr/nec; then 7583 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7584 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7585 runpath_var=LD_RUN_PATH 7586 hardcode_runpath_var=yes 7587 _LT_TAGVAR(ld_shlibs, $1)=yes 7588 fi 7589 ;; 7590 7591 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 7592 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7593 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7594 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7595 runpath_var='LD_RUN_PATH' 7596 7597 if test "$GCC" = yes; then 7598 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7599 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7600 else 7601 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7602 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7603 fi 7604 ;; 7605 7606 sysv5* | sco3.2v5* | sco5v6*) 7607 # Note: We can NOT use -z defs as we might desire, because we do not 7608 # link with -lc, and that would cause any symbols used from libc to 7609 # always be unresolved, which means just about no library would 7610 # ever link correctly. If we're not using GNU ld we use -z text 7611 # though, which does catch some bad symbols but isn't as heavy-handed 7612 # as -z defs. 7613 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7614 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 7615 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7616 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7617 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 7618 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7619 _LT_TAGVAR(link_all_deplibs, $1)=yes 7620 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 7621 runpath_var='LD_RUN_PATH' 7622 7623 if test "$GCC" = yes; then 7624 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7625 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7626 else 7627 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7628 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7629 fi 7630 ;; 7631 7632 uts4*) 7633 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7634 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7635 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7636 ;; 7637 7638 *) 7639 _LT_TAGVAR(ld_shlibs, $1)=no 7640 ;; 7641 esac 7642 7643 if test x$host_vendor = xsni; then 7644 case $host in 7645 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 7646 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' 7647 ;; 7648 esac 7649 fi 7650 fi 7651]) 7652AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 7653test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 7654 7655_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 7656 7657_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 7658_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 7659_LT_DECL([], [extract_expsyms_cmds], [2], 7660 [The commands to extract the exported symbol list from a shared archive]) 7661 7662# 7663# Do we need to explicitly link libc? 7664# 7665case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 7666x|xyes) 7667 # Assume -lc should be added 7668 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7669 7670 if test "$enable_shared" = yes && test "$GCC" = yes; then 7671 case $_LT_TAGVAR(archive_cmds, $1) in 7672 *'~'*) 7673 # FIXME: we may have to deal with multi-command sequences. 7674 ;; 7675 '$CC '*) 7676 # Test whether the compiler implicitly links with -lc since on some 7677 # systems, -lgcc has to come before -lc. If gcc already passes -lc 7678 # to ld, don't add -lc before -lgcc. 7679 AC_CACHE_CHECK([whether -lc should be explicitly linked in], 7680 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), 7681 [$RM conftest* 7682 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 7683 7684 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 7685 soname=conftest 7686 lib=conftest 7687 libobjs=conftest.$ac_objext 7688 deplibs= 7689 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 7690 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 7691 compiler_flags=-v 7692 linker_flags=-v 7693 verstring= 7694 output_objdir=. 7695 libname=conftest 7696 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 7697 _LT_TAGVAR(allow_undefined_flag, $1)= 7698 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 7699 then 7700 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7701 else 7702 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7703 fi 7704 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 7705 else 7706 cat conftest.err 1>&5 7707 fi 7708 $RM conftest* 7709 ]) 7710 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) 7711 ;; 7712 esac 7713 fi 7714 ;; 7715esac 7716 7717_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 7718 [Whether or not to add -lc for building shared libraries]) 7719_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 7720 [enable_shared_with_static_runtimes], [0], 7721 [Whether or not to disallow shared libs when runtime libs are static]) 7722_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 7723 [Compiler flag to allow reflexive dlopens]) 7724_LT_TAGDECL([], [whole_archive_flag_spec], [1], 7725 [Compiler flag to generate shared objects directly from archives]) 7726_LT_TAGDECL([], [compiler_needs_object], [1], 7727 [Whether the compiler copes with passing no objects directly]) 7728_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 7729 [Create an old-style archive from a shared archive]) 7730_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 7731 [Create a temporary old-style archive to link instead of a shared archive]) 7732_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 7733_LT_TAGDECL([], [archive_expsym_cmds], [2]) 7734_LT_TAGDECL([], [module_cmds], [2], 7735 [Commands used to build a loadable module if different from building 7736 a shared archive.]) 7737_LT_TAGDECL([], [module_expsym_cmds], [2]) 7738_LT_TAGDECL([], [with_gnu_ld], [1], 7739 [Whether we are building with GNU ld or not]) 7740_LT_TAGDECL([], [allow_undefined_flag], [1], 7741 [Flag that allows shared libraries with undefined symbols to be built]) 7742_LT_TAGDECL([], [no_undefined_flag], [1], 7743 [Flag that enforces no undefined symbols]) 7744_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 7745 [Flag to hardcode $libdir into a binary during linking. 7746 This must work even if $libdir does not exist]) 7747_LT_TAGDECL([], [hardcode_libdir_separator], [1], 7748 [Whether we need a single "-rpath" flag with a separated argument]) 7749_LT_TAGDECL([], [hardcode_direct], [0], 7750 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 7751 DIR into the resulting binary]) 7752_LT_TAGDECL([], [hardcode_direct_absolute], [0], 7753 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 7754 DIR into the resulting binary and the resulting library dependency is 7755 "absolute", i.e impossible to change by setting ${shlibpath_var} if the 7756 library is relocated]) 7757_LT_TAGDECL([], [hardcode_minus_L], [0], 7758 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 7759 into the resulting binary]) 7760_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 7761 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 7762 into the resulting binary]) 7763_LT_TAGDECL([], [hardcode_automatic], [0], 7764 [Set to "yes" if building a shared library automatically hardcodes DIR 7765 into the library and all subsequent libraries and executables linked 7766 against it]) 7767_LT_TAGDECL([], [inherit_rpath], [0], 7768 [Set to yes if linker adds runtime paths of dependent libraries 7769 to runtime path list]) 7770_LT_TAGDECL([], [link_all_deplibs], [0], 7771 [Whether libtool must link a program against all its dependency libraries]) 7772_LT_TAGDECL([], [always_export_symbols], [0], 7773 [Set to "yes" if exported symbols are required]) 7774_LT_TAGDECL([], [export_symbols_cmds], [2], 7775 [The commands to list exported symbols]) 7776_LT_TAGDECL([], [exclude_expsyms], [1], 7777 [Symbols that should not be listed in the preloaded symbols]) 7778_LT_TAGDECL([], [include_expsyms], [1], 7779 [Symbols that must always be exported]) 7780_LT_TAGDECL([], [prelink_cmds], [2], 7781 [Commands necessary for linking programs (against libraries) with templates]) 7782_LT_TAGDECL([], [postlink_cmds], [2], 7783 [Commands necessary for finishing linking programs]) 7784_LT_TAGDECL([], [file_list_spec], [1], 7785 [Specify filename containing input files]) 7786dnl FIXME: Not yet implemented 7787dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 7788dnl [Compiler flag to generate thread safe objects]) 7789])# _LT_LINKER_SHLIBS 7790 7791 7792# _LT_LANG_C_CONFIG([TAG]) 7793# ------------------------ 7794# Ensure that the configuration variables for a C compiler are suitably 7795# defined. These variables are subsequently used by _LT_CONFIG to write 7796# the compiler configuration to `libtool'. 7797m4_defun([_LT_LANG_C_CONFIG], 7798[m4_require([_LT_DECL_EGREP])dnl 7799lt_save_CC="$CC" 7800AC_LANG_PUSH(C) 7801 7802# Source file extension for C test sources. 7803ac_ext=c 7804 7805# Object file extension for compiled C test sources. 7806objext=o 7807_LT_TAGVAR(objext, $1)=$objext 7808 7809# Code to be used in simple compile tests 7810lt_simple_compile_test_code="int some_variable = 0;" 7811 7812# Code to be used in simple link tests 7813lt_simple_link_test_code='int main(){return(0);}' 7814 7815_LT_TAG_COMPILER 7816# Save the default compiler, since it gets overwritten when the other 7817# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 7818compiler_DEFAULT=$CC 7819 7820# save warnings/boilerplate of simple test code 7821_LT_COMPILER_BOILERPLATE 7822_LT_LINKER_BOILERPLATE 7823 7824if test -n "$compiler"; then 7825 _LT_COMPILER_NO_RTTI($1) 7826 _LT_COMPILER_PIC($1) 7827 _LT_COMPILER_C_O($1) 7828 _LT_COMPILER_FILE_LOCKS($1) 7829 _LT_LINKER_SHLIBS($1) 7830 _LT_SYS_DYNAMIC_LINKER($1) 7831 _LT_LINKER_HARDCODE_LIBPATH($1) 7832 LT_SYS_DLOPEN_SELF 7833 _LT_CMD_STRIPLIB 7834 7835 # Report which library types will actually be built 7836 AC_MSG_CHECKING([if libtool supports shared libraries]) 7837 AC_MSG_RESULT([$can_build_shared]) 7838 7839 AC_MSG_CHECKING([whether to build shared libraries]) 7840 test "$can_build_shared" = "no" && enable_shared=no 7841 7842 # On AIX, shared libraries and static libraries use the same namespace, and 7843 # are all built from PIC. 7844 case $host_os in 7845 aix3*) 7846 test "$enable_shared" = yes && enable_static=no 7847 if test -n "$RANLIB"; then 7848 archive_cmds="$archive_cmds~\$RANLIB \$lib" 7849 postinstall_cmds='$RANLIB $lib' 7850 fi 7851 ;; 7852 7853 aix[[4-9]]*) 7854 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7855 test "$enable_shared" = yes && enable_static=no 7856 fi 7857 ;; 7858 esac 7859 AC_MSG_RESULT([$enable_shared]) 7860 7861 AC_MSG_CHECKING([whether to build static libraries]) 7862 # Make sure either enable_shared or enable_static is yes. 7863 test "$enable_shared" = yes || enable_static=yes 7864 AC_MSG_RESULT([$enable_static]) 7865 7866 _LT_CONFIG($1) 7867fi 7868AC_LANG_POP 7869CC="$lt_save_CC" 7870])# _LT_LANG_C_CONFIG 7871 7872 7873# _LT_LANG_CXX_CONFIG([TAG]) 7874# -------------------------- 7875# Ensure that the configuration variables for a C++ compiler are suitably 7876# defined. These variables are subsequently used by _LT_CONFIG to write 7877# the compiler configuration to `libtool'. 7878m4_defun([_LT_LANG_CXX_CONFIG], 7879[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 7880m4_require([_LT_DECL_EGREP])dnl 7881m4_require([_LT_PATH_MANIFEST_TOOL])dnl 7882if test -n "$CXX" && ( test "X$CXX" != "Xno" && 7883 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 7884 (test "X$CXX" != "Xg++"))) ; then 7885 AC_PROG_CXXCPP 7886else 7887 _lt_caught_CXX_error=yes 7888fi 7889 7890AC_LANG_PUSH(C++) 7891_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7892_LT_TAGVAR(allow_undefined_flag, $1)= 7893_LT_TAGVAR(always_export_symbols, $1)=no 7894_LT_TAGVAR(archive_expsym_cmds, $1)= 7895_LT_TAGVAR(compiler_needs_object, $1)=no 7896_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7897_LT_TAGVAR(hardcode_direct, $1)=no 7898_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7899_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7900_LT_TAGVAR(hardcode_libdir_separator, $1)= 7901_LT_TAGVAR(hardcode_minus_L, $1)=no 7902_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 7903_LT_TAGVAR(hardcode_automatic, $1)=no 7904_LT_TAGVAR(inherit_rpath, $1)=no 7905_LT_TAGVAR(module_cmds, $1)= 7906_LT_TAGVAR(module_expsym_cmds, $1)= 7907_LT_TAGVAR(link_all_deplibs, $1)=unknown 7908_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7909_LT_TAGVAR(reload_flag, $1)=$reload_flag 7910_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 7911_LT_TAGVAR(no_undefined_flag, $1)= 7912_LT_TAGVAR(whole_archive_flag_spec, $1)= 7913_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7914 7915# Source file extension for C++ test sources. 7916ac_ext=cpp 7917 7918# Object file extension for compiled C++ test sources. 7919objext=o 7920_LT_TAGVAR(objext, $1)=$objext 7921 7922# No sense in running all these tests if we already determined that 7923# the CXX compiler isn't working. Some variables (like enable_shared) 7924# are currently assumed to apply to all compilers on this platform, 7925# and will be corrupted by setting them based on a non-working compiler. 7926if test "$_lt_caught_CXX_error" != yes; then 7927 # Code to be used in simple compile tests 7928 lt_simple_compile_test_code="int some_variable = 0;" 7929 7930 # Code to be used in simple link tests 7931 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 7932 7933 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7934 _LT_TAG_COMPILER 7935 7936 # save warnings/boilerplate of simple test code 7937 _LT_COMPILER_BOILERPLATE 7938 _LT_LINKER_BOILERPLATE 7939 7940 # Allow CC to be a program name with arguments. 7941 lt_save_CC=$CC 7942 lt_save_CFLAGS=$CFLAGS 7943 lt_save_LD=$LD 7944 lt_save_GCC=$GCC 7945 GCC=$GXX 7946 lt_save_with_gnu_ld=$with_gnu_ld 7947 lt_save_path_LD=$lt_cv_path_LD 7948 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 7949 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 7950 else 7951 $as_unset lt_cv_prog_gnu_ld 7952 fi 7953 if test -n "${lt_cv_path_LDCXX+set}"; then 7954 lt_cv_path_LD=$lt_cv_path_LDCXX 7955 else 7956 $as_unset lt_cv_path_LD 7957 fi 7958 test -z "${LDCXX+set}" || LD=$LDCXX 7959 CC=${CXX-"c++"} 7960 CFLAGS=$CXXFLAGS 7961 compiler=$CC 7962 _LT_TAGVAR(compiler, $1)=$CC 7963 _LT_CC_BASENAME([$compiler]) 7964 7965 if test -n "$compiler"; then 7966 # We don't want -fno-exception when compiling C++ code, so set the 7967 # no_builtin_flag separately 7968 if test "$GXX" = yes; then 7969 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 7970 else 7971 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 7972 fi 7973 7974 if test "$GXX" = yes; then 7975 # Set up default GNU C++ configuration 7976 7977 LT_PATH_LD 7978 7979 # Check if GNU C++ uses GNU ld as the underlying linker, since the 7980 # archiving commands below assume that GNU ld is being used. 7981 if test "$with_gnu_ld" = yes; then 7982 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 7983 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 7984 7985 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7986 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 7987 7988 # If archive_cmds runs LD, not CC, wlarc should be empty 7989 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 7990 # investigate it a little bit more. (MM) 7991 wlarc='${wl}' 7992 7993 # ancient GNU ld didn't support --whole-archive et. al. 7994 if eval "`$CC -print-prog-name=ld` --help 2>&1" | 7995 $GREP 'no-whole-archive' > /dev/null; then 7996 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 7997 else 7998 _LT_TAGVAR(whole_archive_flag_spec, $1)= 7999 fi 8000 else 8001 with_gnu_ld=no 8002 wlarc= 8003 8004 # A generic and very simple default shared library creation 8005 # command for GNU C++ for the case where it uses the native 8006 # linker, instead of GNU ld. If possible, this setting should 8007 # overridden to take advantage of the native linker features on 8008 # the platform it is being used on. 8009 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 8010 fi 8011 8012 # Commands to make compiler produce verbose output that lists 8013 # what "hidden" libraries, object files and flags are used when 8014 # linking a shared library. 8015 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8016 8017 else 8018 GXX=no 8019 with_gnu_ld=no 8020 wlarc= 8021 fi 8022 8023 # PORTME: fill in a description of your system's C++ link characteristics 8024 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 8025 _LT_TAGVAR(ld_shlibs, $1)=yes 8026 case $host_os in 8027 aix3*) 8028 # FIXME: insert proper C++ library support 8029 _LT_TAGVAR(ld_shlibs, $1)=no 8030 ;; 8031 aix[[4-9]]*) 8032 if test "$host_cpu" = ia64; then 8033 # On IA64, the linker does run time linking by default, so we don't 8034 # have to do anything special. 8035 aix_use_runtimelinking=no 8036 exp_sym_flag='-Bexport' 8037 no_entry_flag="" 8038 else 8039 aix_use_runtimelinking=no 8040 8041 # Test if we are trying to use run time linking or normal 8042 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 8043 # need to do runtime linking. 8044 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 8045 for ld_flag in $LDFLAGS; do 8046 case $ld_flag in 8047 *-brtl*) 8048 aix_use_runtimelinking=yes 8049 break 8050 ;; 8051 esac 8052 done 8053 ;; 8054 esac 8055 8056 exp_sym_flag='-bexport' 8057 no_entry_flag='-bnoentry' 8058 fi 8059 8060 # When large executables or shared objects are built, AIX ld can 8061 # have problems creating the table of contents. If linking a library 8062 # or program results in "error TOC overflow" add -mminimal-toc to 8063 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 8064 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 8065 8066 _LT_TAGVAR(archive_cmds, $1)='' 8067 _LT_TAGVAR(hardcode_direct, $1)=yes 8068 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8069 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 8070 _LT_TAGVAR(link_all_deplibs, $1)=yes 8071 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 8072 8073 if test "$GXX" = yes; then 8074 case $host_os in aix4.[[012]]|aix4.[[012]].*) 8075 # We only want to do this on AIX 4.2 and lower, the check 8076 # below for broken collect2 doesn't work under 4.3+ 8077 collect2name=`${CC} -print-prog-name=collect2` 8078 if test -f "$collect2name" && 8079 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 8080 then 8081 # We have reworked collect2 8082 : 8083 else 8084 # We have old collect2 8085 _LT_TAGVAR(hardcode_direct, $1)=unsupported 8086 # It fails to find uninstalled libraries when the uninstalled 8087 # path is not listed in the libpath. Setting hardcode_minus_L 8088 # to unsupported forces relinking 8089 _LT_TAGVAR(hardcode_minus_L, $1)=yes 8090 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8091 _LT_TAGVAR(hardcode_libdir_separator, $1)= 8092 fi 8093 esac 8094 shared_flag='-shared' 8095 if test "$aix_use_runtimelinking" = yes; then 8096 shared_flag="$shared_flag "'${wl}-G' 8097 fi 8098 else 8099 # not using gcc 8100 if test "$host_cpu" = ia64; then 8101 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 8102 # chokes on -Wl,-G. The following line is correct: 8103 shared_flag='-G' 8104 else 8105 if test "$aix_use_runtimelinking" = yes; then 8106 shared_flag='${wl}-G' 8107 else 8108 shared_flag='${wl}-bM:SRE' 8109 fi 8110 fi 8111 fi 8112 8113 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 8114 # It seems that -bexpall does not export symbols beginning with 8115 # underscore (_), so it is better to generate a list of symbols to 8116 # export. 8117 _LT_TAGVAR(always_export_symbols, $1)=yes 8118 if test "$aix_use_runtimelinking" = yes; then 8119 # Warning - without using the other runtime loading flags (-brtl), 8120 # -berok will link without error, but may produce a broken library. 8121 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 8122 # Determine the default libpath from the value encoded in an empty 8123 # executable. 8124 _LT_SYS_MODULE_PATH_AIX([$1]) 8125 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 8126 8127 _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 func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 8128 else 8129 if test "$host_cpu" = ia64; then 8130 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 8131 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 8132 _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" 8133 else 8134 # Determine the default libpath from the value encoded in an 8135 # empty executable. 8136 _LT_SYS_MODULE_PATH_AIX([$1]) 8137 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 8138 # Warning - without using the other run time loading flags, 8139 # -berok will link without error, but may produce a broken library. 8140 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 8141 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 8142 if test "$with_gnu_ld" = yes; then 8143 # We only use this code for GNU lds that support --whole-archive. 8144 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 8145 else 8146 # Exported symbols can be pulled into shared objects from archives 8147 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 8148 fi 8149 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 8150 # This is similar to how AIX traditionally builds its shared 8151 # libraries. 8152 _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' 8153 fi 8154 fi 8155 ;; 8156 8157 beos*) 8158 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 8159 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8160 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 8161 # support --undefined. This deserves some investigation. FIXME 8162 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8163 else 8164 _LT_TAGVAR(ld_shlibs, $1)=no 8165 fi 8166 ;; 8167 8168 chorus*) 8169 case $cc_basename in 8170 *) 8171 # FIXME: insert proper C++ library support 8172 _LT_TAGVAR(ld_shlibs, $1)=no 8173 ;; 8174 esac 8175 ;; 8176 8177 cygwin* | mingw* | pw32* | cegcc*) 8178 case $GXX,$cc_basename in 8179 ,cl* | no,cl*) 8180 # Native MSVC 8181 # hardcode_libdir_flag_spec is actually meaningless, as there is 8182 # no search path for DLLs. 8183 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 8184 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8185 _LT_TAGVAR(always_export_symbols, $1)=yes 8186 _LT_TAGVAR(file_list_spec, $1)='@' 8187 # Tell ltmain to make .lib files, not .a files. 8188 libext=lib 8189 # Tell ltmain to make .dll files, not .so files. 8190 shrext_cmds=".dll" 8191 # FIXME: Setting linknames here is a bad hack. 8192 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' 8193 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 8194 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; 8195 else 8196 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; 8197 fi~ 8198 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 8199 linknames=' 8200 # The linker will not automatically build a static lib if we build a DLL. 8201 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 8202 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 8203 # Don't use ranlib 8204 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 8205 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 8206 lt_tool_outputfile="@TOOL_OUTPUT@"~ 8207 case $lt_outputfile in 8208 *.exe|*.EXE) ;; 8209 *) 8210 lt_outputfile="$lt_outputfile.exe" 8211 lt_tool_outputfile="$lt_tool_outputfile.exe" 8212 ;; 8213 esac~ 8214 func_to_tool_file "$lt_outputfile"~ 8215 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then 8216 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 8217 $RM "$lt_outputfile.manifest"; 8218 fi' 8219 ;; 8220 *) 8221 # g++ 8222 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 8223 # as there is no search path for DLLs. 8224 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8225 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 8226 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8227 _LT_TAGVAR(always_export_symbols, $1)=no 8228 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 8229 8230 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 8231 _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' 8232 # If the export-symbols file already is a .def file (1st line 8233 # is EXPORTS), use it as is; otherwise, prepend... 8234 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 8235 cp $export_symbols $output_objdir/$soname.def; 8236 else 8237 echo EXPORTS > $output_objdir/$soname.def; 8238 cat $export_symbols >> $output_objdir/$soname.def; 8239 fi~ 8240 $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' 8241 else 8242 _LT_TAGVAR(ld_shlibs, $1)=no 8243 fi 8244 ;; 8245 esac 8246 ;; 8247 darwin* | rhapsody*) 8248 _LT_DARWIN_LINKER_FEATURES($1) 8249 ;; 8250 8251 dgux*) 8252 case $cc_basename in 8253 ec++*) 8254 # FIXME: insert proper C++ library support 8255 _LT_TAGVAR(ld_shlibs, $1)=no 8256 ;; 8257 ghcx*) 8258 # Green Hills C++ Compiler 8259 # FIXME: insert proper C++ library support 8260 _LT_TAGVAR(ld_shlibs, $1)=no 8261 ;; 8262 *) 8263 # FIXME: insert proper C++ library support 8264 _LT_TAGVAR(ld_shlibs, $1)=no 8265 ;; 8266 esac 8267 ;; 8268 8269 freebsd2.*) 8270 # C++ shared libraries reported to be fairly broken before 8271 # switch to ELF 8272 _LT_TAGVAR(ld_shlibs, $1)=no 8273 ;; 8274 8275 freebsd-elf*) 8276 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8277 ;; 8278 8279 freebsd* | dragonfly*) 8280 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 8281 # conventions 8282 _LT_TAGVAR(ld_shlibs, $1)=yes 8283 ;; 8284 8285 gnu*) 8286 ;; 8287 8288 haiku*) 8289 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8290 _LT_TAGVAR(link_all_deplibs, $1)=yes 8291 ;; 8292 8293 hpux9*) 8294 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 8295 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8296 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8297 _LT_TAGVAR(hardcode_direct, $1)=yes 8298 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 8299 # but as the default 8300 # location of the library. 8301 8302 case $cc_basename in 8303 CC*) 8304 # FIXME: insert proper C++ library support 8305 _LT_TAGVAR(ld_shlibs, $1)=no 8306 ;; 8307 aCC*) 8308 _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' 8309 # Commands to make compiler produce verbose output that lists 8310 # what "hidden" libraries, object files and flags are used when 8311 # linking a shared library. 8312 # 8313 # There doesn't appear to be a way to prevent this compiler from 8314 # explicitly linking system object files so we need to strip them 8315 # from the output so that they don't get included in the library 8316 # dependencies. 8317 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 8318 ;; 8319 *) 8320 if test "$GXX" = yes; then 8321 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 8322 else 8323 # FIXME: insert proper C++ library support 8324 _LT_TAGVAR(ld_shlibs, $1)=no 8325 fi 8326 ;; 8327 esac 8328 ;; 8329 8330 hpux10*|hpux11*) 8331 if test $with_gnu_ld = no; then 8332 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 8333 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8334 8335 case $host_cpu in 8336 hppa*64*|ia64*) 8337 ;; 8338 *) 8339 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8340 ;; 8341 esac 8342 fi 8343 case $host_cpu in 8344 hppa*64*|ia64*) 8345 _LT_TAGVAR(hardcode_direct, $1)=no 8346 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8347 ;; 8348 *) 8349 _LT_TAGVAR(hardcode_direct, $1)=yes 8350 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8351 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 8352 # but as the default 8353 # location of the library. 8354 ;; 8355 esac 8356 8357 case $cc_basename in 8358 CC*) 8359 # FIXME: insert proper C++ library support 8360 _LT_TAGVAR(ld_shlibs, $1)=no 8361 ;; 8362 aCC*) 8363 case $host_cpu in 8364 hppa*64*) 8365 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8366 ;; 8367 ia64*) 8368 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8369 ;; 8370 *) 8371 _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' 8372 ;; 8373 esac 8374 # Commands to make compiler produce verbose output that lists 8375 # what "hidden" libraries, object files and flags are used when 8376 # linking a shared library. 8377 # 8378 # There doesn't appear to be a way to prevent this compiler from 8379 # explicitly linking system object files so we need to strip them 8380 # from the output so that they don't get included in the library 8381 # dependencies. 8382 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 8383 ;; 8384 *) 8385 if test "$GXX" = yes; then 8386 if test $with_gnu_ld = no; then 8387 case $host_cpu in 8388 hppa*64*) 8389 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8390 ;; 8391 ia64*) 8392 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8393 ;; 8394 *) 8395 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8396 ;; 8397 esac 8398 fi 8399 else 8400 # FIXME: insert proper C++ library support 8401 _LT_TAGVAR(ld_shlibs, $1)=no 8402 fi 8403 ;; 8404 esac 8405 ;; 8406 8407 interix[[3-9]]*) 8408 _LT_TAGVAR(hardcode_direct, $1)=no 8409 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8410 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8411 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8412 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 8413 # Instead, shared libraries are loaded at an image base (0x10000000 by 8414 # default) and relocated if they conflict, which is a slow very memory 8415 # consuming and fragmenting process. To avoid this, we pick a random, 8416 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 8417 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 8418 _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' 8419 _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' 8420 ;; 8421 irix5* | irix6*) 8422 case $cc_basename in 8423 CC*) 8424 # SGI C++ 8425 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 8426 8427 # Archives containing C++ object files must be created using 8428 # "CC -ar", where "CC" is the IRIX C++ compiler. This is 8429 # necessary to make sure instantiated templates are included 8430 # in the archive. 8431 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 8432 ;; 8433 *) 8434 if test "$GXX" = yes; then 8435 if test "$with_gnu_ld" = no; then 8436 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8437 else 8438 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' 8439 fi 8440 fi 8441 _LT_TAGVAR(link_all_deplibs, $1)=yes 8442 ;; 8443 esac 8444 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8445 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8446 _LT_TAGVAR(inherit_rpath, $1)=yes 8447 ;; 8448 8449 linux* | k*bsd*-gnu | kopensolaris*-gnu) 8450 case $cc_basename in 8451 KCC*) 8452 # Kuck and Associates, Inc. (KAI) C++ Compiler 8453 8454 # KCC will only create a shared library if the output file 8455 # ends with ".so" (or ".sl" for HP-UX), so rename the library 8456 # to its proper name (with version) after linking. 8457 _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' 8458 _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' 8459 # Commands to make compiler produce verbose output that lists 8460 # what "hidden" libraries, object files and flags are used when 8461 # linking a shared library. 8462 # 8463 # There doesn't appear to be a way to prevent this compiler from 8464 # explicitly linking system object files so we need to strip them 8465 # from the output so that they don't get included in the library 8466 # dependencies. 8467 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 8468 8469 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8470 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8471 8472 # Archives containing C++ object files must be created using 8473 # "CC -Bstatic", where "CC" is the KAI C++ compiler. 8474 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 8475 ;; 8476 icpc* | ecpc* ) 8477 # Intel C++ 8478 with_gnu_ld=yes 8479 # version 8.0 and above of icpc choke on multiply defined symbols 8480 # if we add $predep_objects and $postdep_objects, however 7.1 and 8481 # earlier do not add the objects themselves. 8482 case `$CC -V 2>&1` in 8483 *"Version 7."*) 8484 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 8485 _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' 8486 ;; 8487 *) # Version 8.0 or newer 8488 tmp_idyn= 8489 case $host_cpu in 8490 ia64*) tmp_idyn=' -i_dynamic';; 8491 esac 8492 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8493 _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' 8494 ;; 8495 esac 8496 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8497 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8498 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8499 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 8500 ;; 8501 pgCC* | pgcpp*) 8502 # Portland Group C++ compiler 8503 case `$CC -V` in 8504 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) 8505 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 8506 rm -rf $tpldir~ 8507 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 8508 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' 8509 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 8510 rm -rf $tpldir~ 8511 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 8512 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ 8513 $RANLIB $oldlib' 8514 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 8515 rm -rf $tpldir~ 8516 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 8517 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 8518 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 8519 rm -rf $tpldir~ 8520 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 8521 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' 8522 ;; 8523 *) # Version 6 and above use weak symbols 8524 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 8525 _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' 8526 ;; 8527 esac 8528 8529 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 8530 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8531 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 8532 ;; 8533 cxx*) 8534 # Compaq C++ 8535 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 8536 _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' 8537 8538 runpath_var=LD_RUN_PATH 8539 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8540 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8541 8542 # Commands to make compiler produce verbose output that lists 8543 # what "hidden" libraries, object files and flags are used when 8544 # linking a shared library. 8545 # 8546 # There doesn't appear to be a way to prevent this compiler from 8547 # explicitly linking system object files so we need to strip them 8548 # from the output so that they don't get included in the library 8549 # dependencies. 8550 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' 8551 ;; 8552 xl* | mpixl* | bgxl*) 8553 # IBM XL 8.0 on PPC, with GNU ld 8554 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8555 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8556 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8557 if test "x$supports_anon_versioning" = xyes; then 8558 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 8559 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 8560 echo "local: *; };" >> $output_objdir/$libname.ver~ 8561 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 8562 fi 8563 ;; 8564 *) 8565 case `$CC -V 2>&1 | sed 5q` in 8566 *Sun\ C*) 8567 # Sun C++ 5.9 8568 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 8569 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8570 _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' 8571 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8572 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 8573 _LT_TAGVAR(compiler_needs_object, $1)=yes 8574 8575 # Not sure whether something based on 8576 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 8577 # would be better. 8578 output_verbose_link_cmd='func_echo_all' 8579 8580 # Archives containing C++ object files must be created using 8581 # "CC -xar", where "CC" is the Sun C++ compiler. This is 8582 # necessary to make sure instantiated templates are included 8583 # in the archive. 8584 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 8585 ;; 8586 esac 8587 ;; 8588 esac 8589 ;; 8590 8591 lynxos*) 8592 # FIXME: insert proper C++ library support 8593 _LT_TAGVAR(ld_shlibs, $1)=no 8594 ;; 8595 8596 m88k*) 8597 # FIXME: insert proper C++ library support 8598 _LT_TAGVAR(ld_shlibs, $1)=no 8599 ;; 8600 8601 mvs*) 8602 case $cc_basename in 8603 cxx*) 8604 # FIXME: insert proper C++ library support 8605 _LT_TAGVAR(ld_shlibs, $1)=no 8606 ;; 8607 *) 8608 # FIXME: insert proper C++ library support 8609 _LT_TAGVAR(ld_shlibs, $1)=no 8610 ;; 8611 esac 8612 ;; 8613 8614 netbsd*) 8615 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 8616 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 8617 wlarc= 8618 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8619 _LT_TAGVAR(hardcode_direct, $1)=yes 8620 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8621 fi 8622 # Workaround some broken pre-1.5 toolchains 8623 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 8624 ;; 8625 8626 *nto* | *qnx*) 8627 _LT_TAGVAR(ld_shlibs, $1)=yes 8628 ;; 8629 8630 openbsd2*) 8631 # C++ shared libraries are fairly broken 8632 _LT_TAGVAR(ld_shlibs, $1)=no 8633 ;; 8634 8635 openbsd*) 8636 if test -f /usr/libexec/ld.so; then 8637 _LT_TAGVAR(hardcode_direct, $1)=yes 8638 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8639 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8640 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 8641 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8642 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 8643 _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' 8644 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8645 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 8646 fi 8647 output_verbose_link_cmd=func_echo_all 8648 else 8649 _LT_TAGVAR(ld_shlibs, $1)=no 8650 fi 8651 ;; 8652 8653 osf3* | osf4* | osf5*) 8654 case $cc_basename in 8655 KCC*) 8656 # Kuck and Associates, Inc. (KAI) C++ Compiler 8657 8658 # KCC will only create a shared library if the output file 8659 # ends with ".so" (or ".sl" for HP-UX), so rename the library 8660 # to its proper name (with version) after linking. 8661 _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' 8662 8663 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8664 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8665 8666 # Archives containing C++ object files must be created using 8667 # the KAI C++ compiler. 8668 case $host in 8669 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 8670 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 8671 esac 8672 ;; 8673 RCC*) 8674 # Rational C++ 2.4.1 8675 # FIXME: insert proper C++ library support 8676 _LT_TAGVAR(ld_shlibs, $1)=no 8677 ;; 8678 cxx*) 8679 case $host in 8680 osf3*) 8681 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8682 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 8683 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8684 ;; 8685 *) 8686 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 8687 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 8688 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 8689 echo "-hidden">> $lib.exp~ 8690 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ 8691 $RM $lib.exp' 8692 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8693 ;; 8694 esac 8695 8696 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8697 8698 # Commands to make compiler produce verbose output that lists 8699 # what "hidden" libraries, object files and flags are used when 8700 # linking a shared library. 8701 # 8702 # There doesn't appear to be a way to prevent this compiler from 8703 # explicitly linking system object files so we need to strip them 8704 # from the output so that they don't get included in the library 8705 # dependencies. 8706 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 8707 ;; 8708 *) 8709 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 8710 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8711 case $host in 8712 osf3*) 8713 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8714 ;; 8715 *) 8716 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8717 ;; 8718 esac 8719 8720 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8721 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8722 8723 # Commands to make compiler produce verbose output that lists 8724 # what "hidden" libraries, object files and flags are used when 8725 # linking a shared library. 8726 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8727 8728 else 8729 # FIXME: insert proper C++ library support 8730 _LT_TAGVAR(ld_shlibs, $1)=no 8731 fi 8732 ;; 8733 esac 8734 ;; 8735 8736 psos*) 8737 # FIXME: insert proper C++ library support 8738 _LT_TAGVAR(ld_shlibs, $1)=no 8739 ;; 8740 8741 sunos4*) 8742 case $cc_basename in 8743 CC*) 8744 # Sun C++ 4.x 8745 # FIXME: insert proper C++ library support 8746 _LT_TAGVAR(ld_shlibs, $1)=no 8747 ;; 8748 lcc*) 8749 # Lucid 8750 # FIXME: insert proper C++ library support 8751 _LT_TAGVAR(ld_shlibs, $1)=no 8752 ;; 8753 *) 8754 # FIXME: insert proper C++ library support 8755 _LT_TAGVAR(ld_shlibs, $1)=no 8756 ;; 8757 esac 8758 ;; 8759 8760 solaris*) 8761 case $cc_basename in 8762 CC* | sunCC*) 8763 # Sun C++ 4.2, 5.x and Centerline C++ 8764 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 8765 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 8766 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8767 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8768 $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' 8769 8770 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8771 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8772 case $host_os in 8773 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8774 *) 8775 # The compiler driver will combine and reorder linker options, 8776 # but understands `-z linker_flag'. 8777 # Supported since Solaris 2.6 (maybe 2.5.1?) 8778 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 8779 ;; 8780 esac 8781 _LT_TAGVAR(link_all_deplibs, $1)=yes 8782 8783 output_verbose_link_cmd='func_echo_all' 8784 8785 # Archives containing C++ object files must be created using 8786 # "CC -xar", where "CC" is the Sun C++ compiler. This is 8787 # necessary to make sure instantiated templates are included 8788 # in the archive. 8789 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 8790 ;; 8791 gcx*) 8792 # Green Hills C++ Compiler 8793 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8794 8795 # The C++ compiler must be used to create the archive. 8796 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 8797 ;; 8798 *) 8799 # GNU C++ compiler with Solaris linker 8800 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 8801 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 8802 if $CC --version | $GREP -v '^2\.7' > /dev/null; then 8803 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8804 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8805 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 8806 8807 # Commands to make compiler produce verbose output that lists 8808 # what "hidden" libraries, object files and flags are used when 8809 # linking a shared library. 8810 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8811 else 8812 # g++ 2.7 appears to require `-G' NOT `-shared' on this 8813 # platform. 8814 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8815 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8816 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 8817 8818 # Commands to make compiler produce verbose output that lists 8819 # what "hidden" libraries, object files and flags are used when 8820 # linking a shared library. 8821 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8822 fi 8823 8824 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 8825 case $host_os in 8826 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8827 *) 8828 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 8829 ;; 8830 esac 8831 fi 8832 ;; 8833 esac 8834 ;; 8835 8836 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 8837 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8838 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8839 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8840 runpath_var='LD_RUN_PATH' 8841 8842 case $cc_basename in 8843 CC*) 8844 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8845 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8846 ;; 8847 *) 8848 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8849 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8850 ;; 8851 esac 8852 ;; 8853 8854 sysv5* | sco3.2v5* | sco5v6*) 8855 # Note: We can NOT use -z defs as we might desire, because we do not 8856 # link with -lc, and that would cause any symbols used from libc to 8857 # always be unresolved, which means just about no library would 8858 # ever link correctly. If we're not using GNU ld we use -z text 8859 # though, which does catch some bad symbols but isn't as heavy-handed 8860 # as -z defs. 8861 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8862 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 8863 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8864 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8865 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 8866 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 8867 _LT_TAGVAR(link_all_deplibs, $1)=yes 8868 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 8869 runpath_var='LD_RUN_PATH' 8870 8871 case $cc_basename in 8872 CC*) 8873 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8874 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8875 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ 8876 '"$_LT_TAGVAR(old_archive_cmds, $1)" 8877 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ 8878 '"$_LT_TAGVAR(reload_cmds, $1)" 8879 ;; 8880 *) 8881 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8882 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8883 ;; 8884 esac 8885 ;; 8886 8887 tandem*) 8888 case $cc_basename in 8889 NCC*) 8890 # NonStop-UX NCC 3.20 8891 # FIXME: insert proper C++ library support 8892 _LT_TAGVAR(ld_shlibs, $1)=no 8893 ;; 8894 *) 8895 # FIXME: insert proper C++ library support 8896 _LT_TAGVAR(ld_shlibs, $1)=no 8897 ;; 8898 esac 8899 ;; 8900 8901 vxworks*) 8902 # FIXME: insert proper C++ library support 8903 _LT_TAGVAR(ld_shlibs, $1)=no 8904 ;; 8905 8906 *) 8907 # FIXME: insert proper C++ library support 8908 _LT_TAGVAR(ld_shlibs, $1)=no 8909 ;; 8910 esac 8911 8912 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 8913 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 8914 8915 _LT_TAGVAR(GCC, $1)="$GXX" 8916 _LT_TAGVAR(LD, $1)="$LD" 8917 8918 ## CAVEAT EMPTOR: 8919 ## There is no encapsulation within the following macros, do not change 8920 ## the running order or otherwise move them around unless you know exactly 8921 ## what you are doing... 8922 _LT_SYS_HIDDEN_LIBDEPS($1) 8923 _LT_COMPILER_PIC($1) 8924 _LT_COMPILER_C_O($1) 8925 _LT_COMPILER_FILE_LOCKS($1) 8926 _LT_LINKER_SHLIBS($1) 8927 _LT_SYS_DYNAMIC_LINKER($1) 8928 _LT_LINKER_HARDCODE_LIBPATH($1) 8929 8930 _LT_CONFIG($1) 8931 fi # test -n "$compiler" 8932 8933 CC=$lt_save_CC 8934 CFLAGS=$lt_save_CFLAGS 8935 LDCXX=$LD 8936 LD=$lt_save_LD 8937 GCC=$lt_save_GCC 8938 with_gnu_ld=$lt_save_with_gnu_ld 8939 lt_cv_path_LDCXX=$lt_cv_path_LD 8940 lt_cv_path_LD=$lt_save_path_LD 8941 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 8942 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 8943fi # test "$_lt_caught_CXX_error" != yes 8944 8945AC_LANG_POP 8946])# _LT_LANG_CXX_CONFIG 8947 8948 8949# _LT_FUNC_STRIPNAME_CNF 8950# ---------------------- 8951# func_stripname_cnf prefix suffix name 8952# strip PREFIX and SUFFIX off of NAME. 8953# PREFIX and SUFFIX must not contain globbing or regex special 8954# characters, hashes, percent signs, but SUFFIX may contain a leading 8955# dot (in which case that matches only a dot). 8956# 8957# This function is identical to the (non-XSI) version of func_stripname, 8958# except this one can be used by m4 code that may be executed by configure, 8959# rather than the libtool script. 8960m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl 8961AC_REQUIRE([_LT_DECL_SED]) 8962AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) 8963func_stripname_cnf () 8964{ 8965 case ${2} in 8966 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; 8967 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; 8968 esac 8969} # func_stripname_cnf 8970])# _LT_FUNC_STRIPNAME_CNF 8971 8972# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 8973# --------------------------------- 8974# Figure out "hidden" library dependencies from verbose 8975# compiler output when linking a shared library. 8976# Parse the compiler output and extract the necessary 8977# objects, libraries and library flags. 8978m4_defun([_LT_SYS_HIDDEN_LIBDEPS], 8979[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 8980AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl 8981# Dependencies to place before and after the object being linked: 8982_LT_TAGVAR(predep_objects, $1)= 8983_LT_TAGVAR(postdep_objects, $1)= 8984_LT_TAGVAR(predeps, $1)= 8985_LT_TAGVAR(postdeps, $1)= 8986_LT_TAGVAR(compiler_lib_search_path, $1)= 8987 8988dnl we can't use the lt_simple_compile_test_code here, 8989dnl because it contains code intended for an executable, 8990dnl not a library. It's possible we should let each 8991dnl tag define a new lt_????_link_test_code variable, 8992dnl but it's only used here... 8993m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 8994int a; 8995void foo (void) { a = 0; } 8996_LT_EOF 8997], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 8998class Foo 8999{ 9000public: 9001 Foo (void) { a = 0; } 9002private: 9003 int a; 9004}; 9005_LT_EOF 9006], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 9007 subroutine foo 9008 implicit none 9009 integer*4 a 9010 a=0 9011 return 9012 end 9013_LT_EOF 9014], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 9015 subroutine foo 9016 implicit none 9017 integer a 9018 a=0 9019 return 9020 end 9021_LT_EOF 9022], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 9023public class foo { 9024 private int a; 9025 public void bar (void) { 9026 a = 0; 9027 } 9028}; 9029_LT_EOF 9030], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF 9031package foo 9032func foo() { 9033} 9034_LT_EOF 9035]) 9036 9037_lt_libdeps_save_CFLAGS=$CFLAGS 9038case "$CC $CFLAGS " in #( 9039*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; 9040*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; 9041*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; 9042esac 9043 9044dnl Parse the compiler output and extract the necessary 9045dnl objects, libraries and library flags. 9046if AC_TRY_EVAL(ac_compile); then 9047 # Parse the compiler output and extract the necessary 9048 # objects, libraries and library flags. 9049 9050 # Sentinel used to keep track of whether or not we are before 9051 # the conftest object file. 9052 pre_test_object_deps_done=no 9053 9054 for p in `eval "$output_verbose_link_cmd"`; do 9055 case ${prev}${p} in 9056 9057 -L* | -R* | -l*) 9058 # Some compilers place space between "-{L,R}" and the path. 9059 # Remove the space. 9060 if test $p = "-L" || 9061 test $p = "-R"; then 9062 prev=$p 9063 continue 9064 fi 9065 9066 # Expand the sysroot to ease extracting the directories later. 9067 if test -z "$prev"; then 9068 case $p in 9069 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; 9070 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; 9071 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; 9072 esac 9073 fi 9074 case $p in 9075 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; 9076 esac 9077 if test "$pre_test_object_deps_done" = no; then 9078 case ${prev} in 9079 -L | -R) 9080 # Internal compiler library paths should come after those 9081 # provided the user. The postdeps already come after the 9082 # user supplied libs so there is no need to process them. 9083 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 9084 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 9085 else 9086 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 9087 fi 9088 ;; 9089 # The "-l" case would never come before the object being 9090 # linked, so don't bother handling this case. 9091 esac 9092 else 9093 if test -z "$_LT_TAGVAR(postdeps, $1)"; then 9094 _LT_TAGVAR(postdeps, $1)="${prev}${p}" 9095 else 9096 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" 9097 fi 9098 fi 9099 prev= 9100 ;; 9101 9102 *.lto.$objext) ;; # Ignore GCC LTO objects 9103 *.$objext) 9104 # This assumes that the test object file only shows up 9105 # once in the compiler output. 9106 if test "$p" = "conftest.$objext"; then 9107 pre_test_object_deps_done=yes 9108 continue 9109 fi 9110 9111 if test "$pre_test_object_deps_done" = no; then 9112 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 9113 _LT_TAGVAR(predep_objects, $1)="$p" 9114 else 9115 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 9116 fi 9117 else 9118 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 9119 _LT_TAGVAR(postdep_objects, $1)="$p" 9120 else 9121 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 9122 fi 9123 fi 9124 ;; 9125 9126 *) ;; # Ignore the rest. 9127 9128 esac 9129 done 9130 9131 # Clean up. 9132 rm -f a.out a.exe 9133else 9134 echo "libtool.m4: error: problem compiling $1 test program" 9135fi 9136 9137$RM -f confest.$objext 9138CFLAGS=$_lt_libdeps_save_CFLAGS 9139 9140# PORTME: override above test on systems where it is broken 9141m4_if([$1], [CXX], 9142[case $host_os in 9143interix[[3-9]]*) 9144 # Interix 3.5 installs completely hosed .la files for C++, so rather than 9145 # hack all around it, let's just trust "g++" to DTRT. 9146 _LT_TAGVAR(predep_objects,$1)= 9147 _LT_TAGVAR(postdep_objects,$1)= 9148 _LT_TAGVAR(postdeps,$1)= 9149 ;; 9150 9151linux*) 9152 case `$CC -V 2>&1 | sed 5q` in 9153 *Sun\ C*) 9154 # Sun C++ 5.9 9155 9156 # The more standards-conforming stlport4 library is 9157 # incompatible with the Cstd library. Avoid specifying 9158 # it if it's in CXXFLAGS. Ignore libCrun as 9159 # -library=stlport4 depends on it. 9160 case " $CXX $CXXFLAGS " in 9161 *" -library=stlport4 "*) 9162 solaris_use_stlport4=yes 9163 ;; 9164 esac 9165 9166 if test "$solaris_use_stlport4" != yes; then 9167 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 9168 fi 9169 ;; 9170 esac 9171 ;; 9172 9173solaris*) 9174 case $cc_basename in 9175 CC* | sunCC*) 9176 # The more standards-conforming stlport4 library is 9177 # incompatible with the Cstd library. Avoid specifying 9178 # it if it's in CXXFLAGS. Ignore libCrun as 9179 # -library=stlport4 depends on it. 9180 case " $CXX $CXXFLAGS " in 9181 *" -library=stlport4 "*) 9182 solaris_use_stlport4=yes 9183 ;; 9184 esac 9185 9186 # Adding this requires a known-good setup of shared libraries for 9187 # Sun compiler versions before 5.6, else PIC objects from an old 9188 # archive will be linked into the output, leading to subtle bugs. 9189 if test "$solaris_use_stlport4" != yes; then 9190 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 9191 fi 9192 ;; 9193 esac 9194 ;; 9195esac 9196]) 9197 9198case " $_LT_TAGVAR(postdeps, $1) " in 9199*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 9200esac 9201 _LT_TAGVAR(compiler_lib_search_dirs, $1)= 9202if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 9203 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 9204fi 9205_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 9206 [The directories searched by this compiler when creating a shared library]) 9207_LT_TAGDECL([], [predep_objects], [1], 9208 [Dependencies to place before and after the objects being linked to 9209 create a shared library]) 9210_LT_TAGDECL([], [postdep_objects], [1]) 9211_LT_TAGDECL([], [predeps], [1]) 9212_LT_TAGDECL([], [postdeps], [1]) 9213_LT_TAGDECL([], [compiler_lib_search_path], [1], 9214 [The library search path used internally by the compiler when linking 9215 a shared library]) 9216])# _LT_SYS_HIDDEN_LIBDEPS 9217 9218 9219# _LT_LANG_F77_CONFIG([TAG]) 9220# -------------------------- 9221# Ensure that the configuration variables for a Fortran 77 compiler are 9222# suitably defined. These variables are subsequently used by _LT_CONFIG 9223# to write the compiler configuration to `libtool'. 9224m4_defun([_LT_LANG_F77_CONFIG], 9225[AC_LANG_PUSH(Fortran 77) 9226if test -z "$F77" || test "X$F77" = "Xno"; then 9227 _lt_disable_F77=yes 9228fi 9229 9230_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9231_LT_TAGVAR(allow_undefined_flag, $1)= 9232_LT_TAGVAR(always_export_symbols, $1)=no 9233_LT_TAGVAR(archive_expsym_cmds, $1)= 9234_LT_TAGVAR(export_dynamic_flag_spec, $1)= 9235_LT_TAGVAR(hardcode_direct, $1)=no 9236_LT_TAGVAR(hardcode_direct_absolute, $1)=no 9237_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 9238_LT_TAGVAR(hardcode_libdir_separator, $1)= 9239_LT_TAGVAR(hardcode_minus_L, $1)=no 9240_LT_TAGVAR(hardcode_automatic, $1)=no 9241_LT_TAGVAR(inherit_rpath, $1)=no 9242_LT_TAGVAR(module_cmds, $1)= 9243_LT_TAGVAR(module_expsym_cmds, $1)= 9244_LT_TAGVAR(link_all_deplibs, $1)=unknown 9245_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9246_LT_TAGVAR(reload_flag, $1)=$reload_flag 9247_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9248_LT_TAGVAR(no_undefined_flag, $1)= 9249_LT_TAGVAR(whole_archive_flag_spec, $1)= 9250_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 9251 9252# Source file extension for f77 test sources. 9253ac_ext=f 9254 9255# Object file extension for compiled f77 test sources. 9256objext=o 9257_LT_TAGVAR(objext, $1)=$objext 9258 9259# No sense in running all these tests if we already determined that 9260# the F77 compiler isn't working. Some variables (like enable_shared) 9261# are currently assumed to apply to all compilers on this platform, 9262# and will be corrupted by setting them based on a non-working compiler. 9263if test "$_lt_disable_F77" != yes; then 9264 # Code to be used in simple compile tests 9265 lt_simple_compile_test_code="\ 9266 subroutine t 9267 return 9268 end 9269" 9270 9271 # Code to be used in simple link tests 9272 lt_simple_link_test_code="\ 9273 program t 9274 end 9275" 9276 9277 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 9278 _LT_TAG_COMPILER 9279 9280 # save warnings/boilerplate of simple test code 9281 _LT_COMPILER_BOILERPLATE 9282 _LT_LINKER_BOILERPLATE 9283 9284 # Allow CC to be a program name with arguments. 9285 lt_save_CC="$CC" 9286 lt_save_GCC=$GCC 9287 lt_save_CFLAGS=$CFLAGS 9288 CC=${F77-"f77"} 9289 CFLAGS=$FFLAGS 9290 compiler=$CC 9291 _LT_TAGVAR(compiler, $1)=$CC 9292 _LT_CC_BASENAME([$compiler]) 9293 GCC=$G77 9294 if test -n "$compiler"; then 9295 AC_MSG_CHECKING([if libtool supports shared libraries]) 9296 AC_MSG_RESULT([$can_build_shared]) 9297 9298 AC_MSG_CHECKING([whether to build shared libraries]) 9299 test "$can_build_shared" = "no" && enable_shared=no 9300 9301 # On AIX, shared libraries and static libraries use the same namespace, and 9302 # are all built from PIC. 9303 case $host_os in 9304 aix3*) 9305 test "$enable_shared" = yes && enable_static=no 9306 if test -n "$RANLIB"; then 9307 archive_cmds="$archive_cmds~\$RANLIB \$lib" 9308 postinstall_cmds='$RANLIB $lib' 9309 fi 9310 ;; 9311 aix[[4-9]]*) 9312 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 9313 test "$enable_shared" = yes && enable_static=no 9314 fi 9315 ;; 9316 esac 9317 AC_MSG_RESULT([$enable_shared]) 9318 9319 AC_MSG_CHECKING([whether to build static libraries]) 9320 # Make sure either enable_shared or enable_static is yes. 9321 test "$enable_shared" = yes || enable_static=yes 9322 AC_MSG_RESULT([$enable_static]) 9323 9324 _LT_TAGVAR(GCC, $1)="$G77" 9325 _LT_TAGVAR(LD, $1)="$LD" 9326 9327 ## CAVEAT EMPTOR: 9328 ## There is no encapsulation within the following macros, do not change 9329 ## the running order or otherwise move them around unless you know exactly 9330 ## what you are doing... 9331 _LT_COMPILER_PIC($1) 9332 _LT_COMPILER_C_O($1) 9333 _LT_COMPILER_FILE_LOCKS($1) 9334 _LT_LINKER_SHLIBS($1) 9335 _LT_SYS_DYNAMIC_LINKER($1) 9336 _LT_LINKER_HARDCODE_LIBPATH($1) 9337 9338 _LT_CONFIG($1) 9339 fi # test -n "$compiler" 9340 9341 GCC=$lt_save_GCC 9342 CC="$lt_save_CC" 9343 CFLAGS="$lt_save_CFLAGS" 9344fi # test "$_lt_disable_F77" != yes 9345 9346AC_LANG_POP 9347])# _LT_LANG_F77_CONFIG 9348 9349 9350# _LT_LANG_FC_CONFIG([TAG]) 9351# ------------------------- 9352# Ensure that the configuration variables for a Fortran compiler are 9353# suitably defined. These variables are subsequently used by _LT_CONFIG 9354# to write the compiler configuration to `libtool'. 9355m4_defun([_LT_LANG_FC_CONFIG], 9356[AC_LANG_PUSH(Fortran) 9357 9358if test -z "$FC" || test "X$FC" = "Xno"; then 9359 _lt_disable_FC=yes 9360fi 9361 9362_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9363_LT_TAGVAR(allow_undefined_flag, $1)= 9364_LT_TAGVAR(always_export_symbols, $1)=no 9365_LT_TAGVAR(archive_expsym_cmds, $1)= 9366_LT_TAGVAR(export_dynamic_flag_spec, $1)= 9367_LT_TAGVAR(hardcode_direct, $1)=no 9368_LT_TAGVAR(hardcode_direct_absolute, $1)=no 9369_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 9370_LT_TAGVAR(hardcode_libdir_separator, $1)= 9371_LT_TAGVAR(hardcode_minus_L, $1)=no 9372_LT_TAGVAR(hardcode_automatic, $1)=no 9373_LT_TAGVAR(inherit_rpath, $1)=no 9374_LT_TAGVAR(module_cmds, $1)= 9375_LT_TAGVAR(module_expsym_cmds, $1)= 9376_LT_TAGVAR(link_all_deplibs, $1)=unknown 9377_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9378_LT_TAGVAR(reload_flag, $1)=$reload_flag 9379_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9380_LT_TAGVAR(no_undefined_flag, $1)= 9381_LT_TAGVAR(whole_archive_flag_spec, $1)= 9382_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 9383 9384# Source file extension for fc test sources. 9385ac_ext=${ac_fc_srcext-f} 9386 9387# Object file extension for compiled fc test sources. 9388objext=o 9389_LT_TAGVAR(objext, $1)=$objext 9390 9391# No sense in running all these tests if we already determined that 9392# the FC compiler isn't working. Some variables (like enable_shared) 9393# are currently assumed to apply to all compilers on this platform, 9394# and will be corrupted by setting them based on a non-working compiler. 9395if test "$_lt_disable_FC" != yes; then 9396 # Code to be used in simple compile tests 9397 lt_simple_compile_test_code="\ 9398 subroutine t 9399 return 9400 end 9401" 9402 9403 # Code to be used in simple link tests 9404 lt_simple_link_test_code="\ 9405 program t 9406 end 9407" 9408 9409 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 9410 _LT_TAG_COMPILER 9411 9412 # save warnings/boilerplate of simple test code 9413 _LT_COMPILER_BOILERPLATE 9414 _LT_LINKER_BOILERPLATE 9415 9416 # Allow CC to be a program name with arguments. 9417 lt_save_CC="$CC" 9418 lt_save_GCC=$GCC 9419 lt_save_CFLAGS=$CFLAGS 9420 CC=${FC-"f95"} 9421 CFLAGS=$FCFLAGS 9422 compiler=$CC 9423 GCC=$ac_cv_fc_compiler_gnu 9424 9425 _LT_TAGVAR(compiler, $1)=$CC 9426 _LT_CC_BASENAME([$compiler]) 9427 9428 if test -n "$compiler"; then 9429 AC_MSG_CHECKING([if libtool supports shared libraries]) 9430 AC_MSG_RESULT([$can_build_shared]) 9431 9432 AC_MSG_CHECKING([whether to build shared libraries]) 9433 test "$can_build_shared" = "no" && enable_shared=no 9434 9435 # On AIX, shared libraries and static libraries use the same namespace, and 9436 # are all built from PIC. 9437 case $host_os in 9438 aix3*) 9439 test "$enable_shared" = yes && enable_static=no 9440 if test -n "$RANLIB"; then 9441 archive_cmds="$archive_cmds~\$RANLIB \$lib" 9442 postinstall_cmds='$RANLIB $lib' 9443 fi 9444 ;; 9445 aix[[4-9]]*) 9446 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 9447 test "$enable_shared" = yes && enable_static=no 9448 fi 9449 ;; 9450 esac 9451 AC_MSG_RESULT([$enable_shared]) 9452 9453 AC_MSG_CHECKING([whether to build static libraries]) 9454 # Make sure either enable_shared or enable_static is yes. 9455 test "$enable_shared" = yes || enable_static=yes 9456 AC_MSG_RESULT([$enable_static]) 9457 9458 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" 9459 _LT_TAGVAR(LD, $1)="$LD" 9460 9461 ## CAVEAT EMPTOR: 9462 ## There is no encapsulation within the following macros, do not change 9463 ## the running order or otherwise move them around unless you know exactly 9464 ## what you are doing... 9465 _LT_SYS_HIDDEN_LIBDEPS($1) 9466 _LT_COMPILER_PIC($1) 9467 _LT_COMPILER_C_O($1) 9468 _LT_COMPILER_FILE_LOCKS($1) 9469 _LT_LINKER_SHLIBS($1) 9470 _LT_SYS_DYNAMIC_LINKER($1) 9471 _LT_LINKER_HARDCODE_LIBPATH($1) 9472 9473 _LT_CONFIG($1) 9474 fi # test -n "$compiler" 9475 9476 GCC=$lt_save_GCC 9477 CC=$lt_save_CC 9478 CFLAGS=$lt_save_CFLAGS 9479fi # test "$_lt_disable_FC" != yes 9480 9481AC_LANG_POP 9482])# _LT_LANG_FC_CONFIG 9483 9484 9485# _LT_LANG_GCJ_CONFIG([TAG]) 9486# -------------------------- 9487# Ensure that the configuration variables for the GNU Java Compiler compiler 9488# are suitably defined. These variables are subsequently used by _LT_CONFIG 9489# to write the compiler configuration to `libtool'. 9490m4_defun([_LT_LANG_GCJ_CONFIG], 9491[AC_REQUIRE([LT_PROG_GCJ])dnl 9492AC_LANG_SAVE 9493 9494# Source file extension for Java test sources. 9495ac_ext=java 9496 9497# Object file extension for compiled Java test sources. 9498objext=o 9499_LT_TAGVAR(objext, $1)=$objext 9500 9501# Code to be used in simple compile tests 9502lt_simple_compile_test_code="class foo {}" 9503 9504# Code to be used in simple link tests 9505lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 9506 9507# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9508_LT_TAG_COMPILER 9509 9510# save warnings/boilerplate of simple test code 9511_LT_COMPILER_BOILERPLATE 9512_LT_LINKER_BOILERPLATE 9513 9514# Allow CC to be a program name with arguments. 9515lt_save_CC=$CC 9516lt_save_CFLAGS=$CFLAGS 9517lt_save_GCC=$GCC 9518GCC=yes 9519CC=${GCJ-"gcj"} 9520CFLAGS=$GCJFLAGS 9521compiler=$CC 9522_LT_TAGVAR(compiler, $1)=$CC 9523_LT_TAGVAR(LD, $1)="$LD" 9524_LT_CC_BASENAME([$compiler]) 9525 9526# GCJ did not exist at the time GCC didn't implicitly link libc in. 9527_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9528 9529_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9530_LT_TAGVAR(reload_flag, $1)=$reload_flag 9531_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9532 9533if test -n "$compiler"; then 9534 _LT_COMPILER_NO_RTTI($1) 9535 _LT_COMPILER_PIC($1) 9536 _LT_COMPILER_C_O($1) 9537 _LT_COMPILER_FILE_LOCKS($1) 9538 _LT_LINKER_SHLIBS($1) 9539 _LT_LINKER_HARDCODE_LIBPATH($1) 9540 9541 _LT_CONFIG($1) 9542fi 9543 9544AC_LANG_RESTORE 9545 9546GCC=$lt_save_GCC 9547CC=$lt_save_CC 9548CFLAGS=$lt_save_CFLAGS 9549])# _LT_LANG_GCJ_CONFIG 9550 9551 9552# _LT_LANG_GO_CONFIG([TAG]) 9553# -------------------------- 9554# Ensure that the configuration variables for the GNU Go compiler 9555# are suitably defined. These variables are subsequently used by _LT_CONFIG 9556# to write the compiler configuration to `libtool'. 9557m4_defun([_LT_LANG_GO_CONFIG], 9558[AC_REQUIRE([LT_PROG_GO])dnl 9559AC_LANG_SAVE 9560 9561# Source file extension for Go test sources. 9562ac_ext=go 9563 9564# Object file extension for compiled Go test sources. 9565objext=o 9566_LT_TAGVAR(objext, $1)=$objext 9567 9568# Code to be used in simple compile tests 9569lt_simple_compile_test_code="package main; func main() { }" 9570 9571# Code to be used in simple link tests 9572lt_simple_link_test_code='package main; func main() { }' 9573 9574# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9575_LT_TAG_COMPILER 9576 9577# save warnings/boilerplate of simple test code 9578_LT_COMPILER_BOILERPLATE 9579_LT_LINKER_BOILERPLATE 9580 9581# Allow CC to be a program name with arguments. 9582lt_save_CC=$CC 9583lt_save_CFLAGS=$CFLAGS 9584lt_save_GCC=$GCC 9585GCC=yes 9586CC=${GOC-"gccgo"} 9587CFLAGS=$GOFLAGS 9588compiler=$CC 9589_LT_TAGVAR(compiler, $1)=$CC 9590_LT_TAGVAR(LD, $1)="$LD" 9591_LT_CC_BASENAME([$compiler]) 9592 9593# Go did not exist at the time GCC didn't implicitly link libc in. 9594_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9595 9596_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9597_LT_TAGVAR(reload_flag, $1)=$reload_flag 9598_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9599 9600if test -n "$compiler"; then 9601 _LT_COMPILER_NO_RTTI($1) 9602 _LT_COMPILER_PIC($1) 9603 _LT_COMPILER_C_O($1) 9604 _LT_COMPILER_FILE_LOCKS($1) 9605 _LT_LINKER_SHLIBS($1) 9606 _LT_LINKER_HARDCODE_LIBPATH($1) 9607 9608 _LT_CONFIG($1) 9609fi 9610 9611AC_LANG_RESTORE 9612 9613GCC=$lt_save_GCC 9614CC=$lt_save_CC 9615CFLAGS=$lt_save_CFLAGS 9616])# _LT_LANG_GO_CONFIG 9617 9618 9619# _LT_LANG_RC_CONFIG([TAG]) 9620# ------------------------- 9621# Ensure that the configuration variables for the Windows resource compiler 9622# are suitably defined. These variables are subsequently used by _LT_CONFIG 9623# to write the compiler configuration to `libtool'. 9624m4_defun([_LT_LANG_RC_CONFIG], 9625[AC_REQUIRE([LT_PROG_RC])dnl 9626AC_LANG_SAVE 9627 9628# Source file extension for RC test sources. 9629ac_ext=rc 9630 9631# Object file extension for compiled RC test sources. 9632objext=o 9633_LT_TAGVAR(objext, $1)=$objext 9634 9635# Code to be used in simple compile tests 9636lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 9637 9638# Code to be used in simple link tests 9639lt_simple_link_test_code="$lt_simple_compile_test_code" 9640 9641# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9642_LT_TAG_COMPILER 9643 9644# save warnings/boilerplate of simple test code 9645_LT_COMPILER_BOILERPLATE 9646_LT_LINKER_BOILERPLATE 9647 9648# Allow CC to be a program name with arguments. 9649lt_save_CC="$CC" 9650lt_save_CFLAGS=$CFLAGS 9651lt_save_GCC=$GCC 9652GCC= 9653CC=${RC-"windres"} 9654CFLAGS= 9655compiler=$CC 9656_LT_TAGVAR(compiler, $1)=$CC 9657_LT_CC_BASENAME([$compiler]) 9658_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 9659 9660if test -n "$compiler"; then 9661 : 9662 _LT_CONFIG($1) 9663fi 9664 9665GCC=$lt_save_GCC 9666AC_LANG_RESTORE 9667CC=$lt_save_CC 9668CFLAGS=$lt_save_CFLAGS 9669])# _LT_LANG_RC_CONFIG 9670 9671 9672# LT_PROG_GCJ 9673# ----------- 9674AC_DEFUN([LT_PROG_GCJ], 9675[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 9676 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 9677 [AC_CHECK_TOOL(GCJ, gcj,) 9678 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 9679 AC_SUBST(GCJFLAGS)])])[]dnl 9680]) 9681 9682# Old name: 9683AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 9684dnl aclocal-1.4 backwards compatibility: 9685dnl AC_DEFUN([LT_AC_PROG_GCJ], []) 9686 9687 9688# LT_PROG_GO 9689# ---------- 9690AC_DEFUN([LT_PROG_GO], 9691[AC_CHECK_TOOL(GOC, gccgo,) 9692]) 9693 9694 9695# LT_PROG_RC 9696# ---------- 9697AC_DEFUN([LT_PROG_RC], 9698[AC_CHECK_TOOL(RC, windres,) 9699]) 9700 9701# Old name: 9702AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 9703dnl aclocal-1.4 backwards compatibility: 9704dnl AC_DEFUN([LT_AC_PROG_RC], []) 9705 9706 9707# _LT_DECL_EGREP 9708# -------------- 9709# If we don't have a new enough Autoconf to choose the best grep 9710# available, choose the one first in the user's PATH. 9711m4_defun([_LT_DECL_EGREP], 9712[AC_REQUIRE([AC_PROG_EGREP])dnl 9713AC_REQUIRE([AC_PROG_FGREP])dnl 9714test -z "$GREP" && GREP=grep 9715_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 9716_LT_DECL([], [EGREP], [1], [An ERE matcher]) 9717_LT_DECL([], [FGREP], [1], [A literal string matcher]) 9718dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 9719AC_SUBST([GREP]) 9720]) 9721 9722 9723# _LT_DECL_OBJDUMP 9724# -------------- 9725# If we don't have a new enough Autoconf to choose the best objdump 9726# available, choose the one first in the user's PATH. 9727m4_defun([_LT_DECL_OBJDUMP], 9728[AC_CHECK_TOOL(OBJDUMP, objdump, false) 9729test -z "$OBJDUMP" && OBJDUMP=objdump 9730_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 9731AC_SUBST([OBJDUMP]) 9732]) 9733 9734# _LT_DECL_DLLTOOL 9735# ---------------- 9736# Ensure DLLTOOL variable is set. 9737m4_defun([_LT_DECL_DLLTOOL], 9738[AC_CHECK_TOOL(DLLTOOL, dlltool, false) 9739test -z "$DLLTOOL" && DLLTOOL=dlltool 9740_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) 9741AC_SUBST([DLLTOOL]) 9742]) 9743 9744# _LT_DECL_SED 9745# ------------ 9746# Check for a fully-functional sed program, that truncates 9747# as few characters as possible. Prefer GNU sed if found. 9748m4_defun([_LT_DECL_SED], 9749[AC_PROG_SED 9750test -z "$SED" && SED=sed 9751Xsed="$SED -e 1s/^X//" 9752_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 9753_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 9754 [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 9755])# _LT_DECL_SED 9756 9757m4_ifndef([AC_PROG_SED], [ 9758# NOTE: This macro has been submitted for inclusion into # 9759# GNU Autoconf as AC_PROG_SED. When it is available in # 9760# a released version of Autoconf we should remove this # 9761# macro and use it instead. # 9762 9763m4_defun([AC_PROG_SED], 9764[AC_MSG_CHECKING([for a sed that does not truncate output]) 9765AC_CACHE_VAL(lt_cv_path_SED, 9766[# Loop through the user's path and test for sed and gsed. 9767# Then use that list of sed's as ones to test for truncation. 9768as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9769for as_dir in $PATH 9770do 9771 IFS=$as_save_IFS 9772 test -z "$as_dir" && as_dir=. 9773 for lt_ac_prog in sed gsed; do 9774 for ac_exec_ext in '' $ac_executable_extensions; do 9775 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 9776 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 9777 fi 9778 done 9779 done 9780done 9781IFS=$as_save_IFS 9782lt_ac_max=0 9783lt_ac_count=0 9784# Add /usr/xpg4/bin/sed as it is typically found on Solaris 9785# along with /bin/sed that truncates output. 9786for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 9787 test ! -f $lt_ac_sed && continue 9788 cat /dev/null > conftest.in 9789 lt_ac_count=0 9790 echo $ECHO_N "0123456789$ECHO_C" >conftest.in 9791 # Check for GNU sed and select it if it is found. 9792 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 9793 lt_cv_path_SED=$lt_ac_sed 9794 break 9795 fi 9796 while true; do 9797 cat conftest.in conftest.in >conftest.tmp 9798 mv conftest.tmp conftest.in 9799 cp conftest.in conftest.nl 9800 echo >>conftest.nl 9801 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 9802 cmp -s conftest.out conftest.nl || break 9803 # 10000 chars as input seems more than enough 9804 test $lt_ac_count -gt 10 && break 9805 lt_ac_count=`expr $lt_ac_count + 1` 9806 if test $lt_ac_count -gt $lt_ac_max; then 9807 lt_ac_max=$lt_ac_count 9808 lt_cv_path_SED=$lt_ac_sed 9809 fi 9810 done 9811done 9812]) 9813SED=$lt_cv_path_SED 9814AC_SUBST([SED]) 9815AC_MSG_RESULT([$SED]) 9816])#AC_PROG_SED 9817])#m4_ifndef 9818 9819# Old name: 9820AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 9821dnl aclocal-1.4 backwards compatibility: 9822dnl AC_DEFUN([LT_AC_PROG_SED], []) 9823 9824 9825# _LT_CHECK_SHELL_FEATURES 9826# ------------------------ 9827# Find out whether the shell is Bourne or XSI compatible, 9828# or has some other useful features. 9829m4_defun([_LT_CHECK_SHELL_FEATURES], 9830[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) 9831# Try some XSI features 9832xsi_shell=no 9833( _lt_dummy="a/b/c" 9834 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ 9835 = c,a/b,b/c, \ 9836 && eval 'test $(( 1 + 1 )) -eq 2 \ 9837 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ 9838 && xsi_shell=yes 9839AC_MSG_RESULT([$xsi_shell]) 9840_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) 9841 9842AC_MSG_CHECKING([whether the shell understands "+="]) 9843lt_shell_append=no 9844( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ 9845 >/dev/null 2>&1 \ 9846 && lt_shell_append=yes 9847AC_MSG_RESULT([$lt_shell_append]) 9848_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) 9849 9850if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 9851 lt_unset=unset 9852else 9853 lt_unset=false 9854fi 9855_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 9856 9857# test EBCDIC or ASCII 9858case `echo X|tr X '\101'` in 9859 A) # ASCII based system 9860 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 9861 lt_SP2NL='tr \040 \012' 9862 lt_NL2SP='tr \015\012 \040\040' 9863 ;; 9864 *) # EBCDIC based system 9865 lt_SP2NL='tr \100 \n' 9866 lt_NL2SP='tr \r\n \100\100' 9867 ;; 9868esac 9869_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 9870_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 9871])# _LT_CHECK_SHELL_FEATURES 9872 9873 9874# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) 9875# ------------------------------------------------------ 9876# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and 9877# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. 9878m4_defun([_LT_PROG_FUNCTION_REPLACE], 9879[dnl { 9880sed -e '/^$1 ()$/,/^} # $1 /c\ 9881$1 ()\ 9882{\ 9883m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) 9884} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ 9885 && mv -f "$cfgfile.tmp" "$cfgfile" \ 9886 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") 9887test 0 -eq $? || _lt_function_replace_fail=: 9888]) 9889 9890 9891# _LT_PROG_REPLACE_SHELLFNS 9892# ------------------------- 9893# Replace existing portable implementations of several shell functions with 9894# equivalent extended shell implementations where those features are available.. 9895m4_defun([_LT_PROG_REPLACE_SHELLFNS], 9896[if test x"$xsi_shell" = xyes; then 9897 _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl 9898 case ${1} in 9899 */*) func_dirname_result="${1%/*}${2}" ;; 9900 * ) func_dirname_result="${3}" ;; 9901 esac]) 9902 9903 _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl 9904 func_basename_result="${1##*/}"]) 9905 9906 _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl 9907 case ${1} in 9908 */*) func_dirname_result="${1%/*}${2}" ;; 9909 * ) func_dirname_result="${3}" ;; 9910 esac 9911 func_basename_result="${1##*/}"]) 9912 9913 _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl 9914 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are 9915 # positional parameters, so assign one to ordinary parameter first. 9916 func_stripname_result=${3} 9917 func_stripname_result=${func_stripname_result#"${1}"} 9918 func_stripname_result=${func_stripname_result%"${2}"}]) 9919 9920 _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl 9921 func_split_long_opt_name=${1%%=*} 9922 func_split_long_opt_arg=${1#*=}]) 9923 9924 _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl 9925 func_split_short_opt_arg=${1#??} 9926 func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) 9927 9928 _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl 9929 case ${1} in 9930 *.lo) func_lo2o_result=${1%.lo}.${objext} ;; 9931 *) func_lo2o_result=${1} ;; 9932 esac]) 9933 9934 _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) 9935 9936 _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) 9937 9938 _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) 9939fi 9940 9941if test x"$lt_shell_append" = xyes; then 9942 _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) 9943 9944 _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl 9945 func_quote_for_eval "${2}" 9946dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ 9947 eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) 9948 9949 # Save a `func_append' function call where possible by direct use of '+=' 9950 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ 9951 && mv -f "$cfgfile.tmp" "$cfgfile" \ 9952 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") 9953 test 0 -eq $? || _lt_function_replace_fail=: 9954else 9955 # Save a `func_append' function call even when '+=' is not available 9956 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ 9957 && mv -f "$cfgfile.tmp" "$cfgfile" \ 9958 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") 9959 test 0 -eq $? || _lt_function_replace_fail=: 9960fi 9961 9962if test x"$_lt_function_replace_fail" = x":"; then 9963 AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) 9964fi 9965]) 9966 9967# _LT_PATH_CONVERSION_FUNCTIONS 9968# ----------------------------- 9969# Determine which file name conversion functions should be used by 9970# func_to_host_file (and, implicitly, by func_to_host_path). These are needed 9971# for certain cross-compile configurations and native mingw. 9972m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], 9973[AC_REQUIRE([AC_CANONICAL_HOST])dnl 9974AC_REQUIRE([AC_CANONICAL_BUILD])dnl 9975AC_MSG_CHECKING([how to convert $build file names to $host format]) 9976AC_CACHE_VAL(lt_cv_to_host_file_cmd, 9977[case $host in 9978 *-*-mingw* ) 9979 case $build in 9980 *-*-mingw* ) # actually msys 9981 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 9982 ;; 9983 *-*-cygwin* ) 9984 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 9985 ;; 9986 * ) # otherwise, assume *nix 9987 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 9988 ;; 9989 esac 9990 ;; 9991 *-*-cygwin* ) 9992 case $build in 9993 *-*-mingw* ) # actually msys 9994 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin 9995 ;; 9996 *-*-cygwin* ) 9997 lt_cv_to_host_file_cmd=func_convert_file_noop 9998 ;; 9999 * ) # otherwise, assume *nix 10000 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin 10001 ;; 10002 esac 10003 ;; 10004 * ) # unhandled hosts (and "normal" native builds) 10005 lt_cv_to_host_file_cmd=func_convert_file_noop 10006 ;; 10007esac 10008]) 10009to_host_file_cmd=$lt_cv_to_host_file_cmd 10010AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) 10011_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], 10012 [0], [convert $build file names to $host format])dnl 10013 10014AC_MSG_CHECKING([how to convert $build file names to toolchain format]) 10015AC_CACHE_VAL(lt_cv_to_tool_file_cmd, 10016[#assume ordinary cross tools, or native build. 10017lt_cv_to_tool_file_cmd=func_convert_file_noop 10018case $host in 10019 *-*-mingw* ) 10020 case $build in 10021 *-*-mingw* ) # actually msys 10022 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 10023 ;; 10024 esac 10025 ;; 10026esac 10027]) 10028to_tool_file_cmd=$lt_cv_to_tool_file_cmd 10029AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) 10030_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], 10031 [0], [convert $build files to toolchain format])dnl 10032])# _LT_PATH_CONVERSION_FUNCTIONS 10033 10034# Helper functions for option handling. -*- Autoconf -*- 10035# 10036# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, 10037# Inc. 10038# Written by Gary V. Vaughan, 2004 10039# 10040# This file is free software; the Free Software Foundation gives 10041# unlimited permission to copy and/or distribute it, with or without 10042# modifications, as long as this notice is preserved. 10043 10044# serial 7 ltoptions.m4 10045 10046# This is to help aclocal find these macros, as it can't see m4_define. 10047AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 10048 10049 10050# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 10051# ------------------------------------------ 10052m4_define([_LT_MANGLE_OPTION], 10053[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 10054 10055 10056# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 10057# --------------------------------------- 10058# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 10059# matching handler defined, dispatch to it. Other OPTION-NAMEs are 10060# saved as a flag. 10061m4_define([_LT_SET_OPTION], 10062[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 10063m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 10064 _LT_MANGLE_DEFUN([$1], [$2]), 10065 [m4_warning([Unknown $1 option `$2'])])[]dnl 10066]) 10067 10068 10069# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 10070# ------------------------------------------------------------ 10071# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 10072m4_define([_LT_IF_OPTION], 10073[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 10074 10075 10076# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 10077# ------------------------------------------------------- 10078# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 10079# are set. 10080m4_define([_LT_UNLESS_OPTIONS], 10081[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 10082 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 10083 [m4_define([$0_found])])])[]dnl 10084m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 10085])[]dnl 10086]) 10087 10088 10089# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 10090# ---------------------------------------- 10091# OPTION-LIST is a space-separated list of Libtool options associated 10092# with MACRO-NAME. If any OPTION has a matching handler declared with 10093# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 10094# the unknown option and exit. 10095m4_defun([_LT_SET_OPTIONS], 10096[# Set options 10097m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 10098 [_LT_SET_OPTION([$1], _LT_Option)]) 10099 10100m4_if([$1],[LT_INIT],[ 10101 dnl 10102 dnl Simply set some default values (i.e off) if boolean options were not 10103 dnl specified: 10104 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 10105 ]) 10106 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 10107 ]) 10108 dnl 10109 dnl If no reference was made to various pairs of opposing options, then 10110 dnl we run the default mode handler for the pair. For example, if neither 10111 dnl `shared' nor `disable-shared' was passed, we enable building of shared 10112 dnl archives by default: 10113 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 10114 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 10115 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 10116 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 10117 [_LT_ENABLE_FAST_INSTALL]) 10118 ]) 10119])# _LT_SET_OPTIONS 10120 10121 10122 10123# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 10124# ----------------------------------------- 10125m4_define([_LT_MANGLE_DEFUN], 10126[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 10127 10128 10129# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 10130# ----------------------------------------------- 10131m4_define([LT_OPTION_DEFINE], 10132[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 10133])# LT_OPTION_DEFINE 10134 10135 10136# dlopen 10137# ------ 10138LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 10139]) 10140 10141AU_DEFUN([AC_LIBTOOL_DLOPEN], 10142[_LT_SET_OPTION([LT_INIT], [dlopen]) 10143AC_DIAGNOSE([obsolete], 10144[$0: Remove this warning and the call to _LT_SET_OPTION when you 10145put the `dlopen' option into LT_INIT's first parameter.]) 10146]) 10147 10148dnl aclocal-1.4 backwards compatibility: 10149dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 10150 10151 10152# win32-dll 10153# --------- 10154# Declare package support for building win32 dll's. 10155LT_OPTION_DEFINE([LT_INIT], [win32-dll], 10156[enable_win32_dll=yes 10157 10158case $host in 10159*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) 10160 AC_CHECK_TOOL(AS, as, false) 10161 AC_CHECK_TOOL(DLLTOOL, dlltool, false) 10162 AC_CHECK_TOOL(OBJDUMP, objdump, false) 10163 ;; 10164esac 10165 10166test -z "$AS" && AS=as 10167_LT_DECL([], [AS], [1], [Assembler program])dnl 10168 10169test -z "$DLLTOOL" && DLLTOOL=dlltool 10170_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl 10171 10172test -z "$OBJDUMP" && OBJDUMP=objdump 10173_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl 10174])# win32-dll 10175 10176AU_DEFUN([AC_LIBTOOL_WIN32_DLL], 10177[AC_REQUIRE([AC_CANONICAL_HOST])dnl 10178_LT_SET_OPTION([LT_INIT], [win32-dll]) 10179AC_DIAGNOSE([obsolete], 10180[$0: Remove this warning and the call to _LT_SET_OPTION when you 10181put the `win32-dll' option into LT_INIT's first parameter.]) 10182]) 10183 10184dnl aclocal-1.4 backwards compatibility: 10185dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 10186 10187 10188# _LT_ENABLE_SHARED([DEFAULT]) 10189# ---------------------------- 10190# implement the --enable-shared flag, and supports the `shared' and 10191# `disable-shared' LT_INIT options. 10192# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10193m4_define([_LT_ENABLE_SHARED], 10194[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 10195AC_ARG_ENABLE([shared], 10196 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 10197 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 10198 [p=${PACKAGE-default} 10199 case $enableval in 10200 yes) enable_shared=yes ;; 10201 no) enable_shared=no ;; 10202 *) 10203 enable_shared=no 10204 # Look at the argument we got. We use all the common list separators. 10205 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10206 for pkg in $enableval; do 10207 IFS="$lt_save_ifs" 10208 if test "X$pkg" = "X$p"; then 10209 enable_shared=yes 10210 fi 10211 done 10212 IFS="$lt_save_ifs" 10213 ;; 10214 esac], 10215 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 10216 10217 _LT_DECL([build_libtool_libs], [enable_shared], [0], 10218 [Whether or not to build shared libraries]) 10219])# _LT_ENABLE_SHARED 10220 10221LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 10222LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 10223 10224# Old names: 10225AC_DEFUN([AC_ENABLE_SHARED], 10226[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 10227]) 10228 10229AC_DEFUN([AC_DISABLE_SHARED], 10230[_LT_SET_OPTION([LT_INIT], [disable-shared]) 10231]) 10232 10233AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 10234AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 10235 10236dnl aclocal-1.4 backwards compatibility: 10237dnl AC_DEFUN([AM_ENABLE_SHARED], []) 10238dnl AC_DEFUN([AM_DISABLE_SHARED], []) 10239 10240 10241 10242# _LT_ENABLE_STATIC([DEFAULT]) 10243# ---------------------------- 10244# implement the --enable-static flag, and support the `static' and 10245# `disable-static' LT_INIT options. 10246# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10247m4_define([_LT_ENABLE_STATIC], 10248[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 10249AC_ARG_ENABLE([static], 10250 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 10251 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 10252 [p=${PACKAGE-default} 10253 case $enableval in 10254 yes) enable_static=yes ;; 10255 no) enable_static=no ;; 10256 *) 10257 enable_static=no 10258 # Look at the argument we got. We use all the common list separators. 10259 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10260 for pkg in $enableval; do 10261 IFS="$lt_save_ifs" 10262 if test "X$pkg" = "X$p"; then 10263 enable_static=yes 10264 fi 10265 done 10266 IFS="$lt_save_ifs" 10267 ;; 10268 esac], 10269 [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 10270 10271 _LT_DECL([build_old_libs], [enable_static], [0], 10272 [Whether or not to build static libraries]) 10273])# _LT_ENABLE_STATIC 10274 10275LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 10276LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 10277 10278# Old names: 10279AC_DEFUN([AC_ENABLE_STATIC], 10280[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 10281]) 10282 10283AC_DEFUN([AC_DISABLE_STATIC], 10284[_LT_SET_OPTION([LT_INIT], [disable-static]) 10285]) 10286 10287AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 10288AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 10289 10290dnl aclocal-1.4 backwards compatibility: 10291dnl AC_DEFUN([AM_ENABLE_STATIC], []) 10292dnl AC_DEFUN([AM_DISABLE_STATIC], []) 10293 10294 10295 10296# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 10297# ---------------------------------- 10298# implement the --enable-fast-install flag, and support the `fast-install' 10299# and `disable-fast-install' LT_INIT options. 10300# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10301m4_define([_LT_ENABLE_FAST_INSTALL], 10302[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 10303AC_ARG_ENABLE([fast-install], 10304 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 10305 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 10306 [p=${PACKAGE-default} 10307 case $enableval in 10308 yes) enable_fast_install=yes ;; 10309 no) enable_fast_install=no ;; 10310 *) 10311 enable_fast_install=no 10312 # Look at the argument we got. We use all the common list separators. 10313 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10314 for pkg in $enableval; do 10315 IFS="$lt_save_ifs" 10316 if test "X$pkg" = "X$p"; then 10317 enable_fast_install=yes 10318 fi 10319 done 10320 IFS="$lt_save_ifs" 10321 ;; 10322 esac], 10323 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 10324 10325_LT_DECL([fast_install], [enable_fast_install], [0], 10326 [Whether or not to optimize for fast installation])dnl 10327])# _LT_ENABLE_FAST_INSTALL 10328 10329LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 10330LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 10331 10332# Old names: 10333AU_DEFUN([AC_ENABLE_FAST_INSTALL], 10334[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 10335AC_DIAGNOSE([obsolete], 10336[$0: Remove this warning and the call to _LT_SET_OPTION when you put 10337the `fast-install' option into LT_INIT's first parameter.]) 10338]) 10339 10340AU_DEFUN([AC_DISABLE_FAST_INSTALL], 10341[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 10342AC_DIAGNOSE([obsolete], 10343[$0: Remove this warning and the call to _LT_SET_OPTION when you put 10344the `disable-fast-install' option into LT_INIT's first parameter.]) 10345]) 10346 10347dnl aclocal-1.4 backwards compatibility: 10348dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 10349dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 10350 10351 10352# _LT_WITH_PIC([MODE]) 10353# -------------------- 10354# implement the --with-pic flag, and support the `pic-only' and `no-pic' 10355# LT_INIT options. 10356# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 10357m4_define([_LT_WITH_PIC], 10358[AC_ARG_WITH([pic], 10359 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], 10360 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 10361 [lt_p=${PACKAGE-default} 10362 case $withval in 10363 yes|no) pic_mode=$withval ;; 10364 *) 10365 pic_mode=default 10366 # Look at the argument we got. We use all the common list separators. 10367 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10368 for lt_pkg in $withval; do 10369 IFS="$lt_save_ifs" 10370 if test "X$lt_pkg" = "X$lt_p"; then 10371 pic_mode=yes 10372 fi 10373 done 10374 IFS="$lt_save_ifs" 10375 ;; 10376 esac], 10377 [pic_mode=default]) 10378 10379test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) 10380 10381_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 10382])# _LT_WITH_PIC 10383 10384LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 10385LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 10386 10387# Old name: 10388AU_DEFUN([AC_LIBTOOL_PICMODE], 10389[_LT_SET_OPTION([LT_INIT], [pic-only]) 10390AC_DIAGNOSE([obsolete], 10391[$0: Remove this warning and the call to _LT_SET_OPTION when you 10392put the `pic-only' option into LT_INIT's first parameter.]) 10393]) 10394 10395dnl aclocal-1.4 backwards compatibility: 10396dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 10397 10398 10399m4_define([_LTDL_MODE], []) 10400LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 10401 [m4_define([_LTDL_MODE], [nonrecursive])]) 10402LT_OPTION_DEFINE([LTDL_INIT], [recursive], 10403 [m4_define([_LTDL_MODE], [recursive])]) 10404LT_OPTION_DEFINE([LTDL_INIT], [subproject], 10405 [m4_define([_LTDL_MODE], [subproject])]) 10406 10407m4_define([_LTDL_TYPE], []) 10408LT_OPTION_DEFINE([LTDL_INIT], [installable], 10409 [m4_define([_LTDL_TYPE], [installable])]) 10410LT_OPTION_DEFINE([LTDL_INIT], [convenience], 10411 [m4_define([_LTDL_TYPE], [convenience])]) 10412 10413# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 10414# 10415# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 10416# Written by Gary V. Vaughan, 2004 10417# 10418# This file is free software; the Free Software Foundation gives 10419# unlimited permission to copy and/or distribute it, with or without 10420# modifications, as long as this notice is preserved. 10421 10422# serial 6 ltsugar.m4 10423 10424# This is to help aclocal find these macros, as it can't see m4_define. 10425AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 10426 10427 10428# lt_join(SEP, ARG1, [ARG2...]) 10429# ----------------------------- 10430# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 10431# associated separator. 10432# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 10433# versions in m4sugar had bugs. 10434m4_define([lt_join], 10435[m4_if([$#], [1], [], 10436 [$#], [2], [[$2]], 10437 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 10438m4_define([_lt_join], 10439[m4_if([$#$2], [2], [], 10440 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 10441 10442 10443# lt_car(LIST) 10444# lt_cdr(LIST) 10445# ------------ 10446# Manipulate m4 lists. 10447# These macros are necessary as long as will still need to support 10448# Autoconf-2.59 which quotes differently. 10449m4_define([lt_car], [[$1]]) 10450m4_define([lt_cdr], 10451[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 10452 [$#], 1, [], 10453 [m4_dquote(m4_shift($@))])]) 10454m4_define([lt_unquote], $1) 10455 10456 10457# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 10458# ------------------------------------------ 10459# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. 10460# Note that neither SEPARATOR nor STRING are expanded; they are appended 10461# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 10462# No SEPARATOR is output if MACRO-NAME was previously undefined (different 10463# than defined and empty). 10464# 10465# This macro is needed until we can rely on Autoconf 2.62, since earlier 10466# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 10467m4_define([lt_append], 10468[m4_define([$1], 10469 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 10470 10471 10472 10473# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 10474# ---------------------------------------------------------- 10475# Produce a SEP delimited list of all paired combinations of elements of 10476# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 10477# has the form PREFIXmINFIXSUFFIXn. 10478# Needed until we can rely on m4_combine added in Autoconf 2.62. 10479m4_define([lt_combine], 10480[m4_if(m4_eval([$# > 3]), [1], 10481 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 10482[[m4_foreach([_Lt_prefix], [$2], 10483 [m4_foreach([_Lt_suffix], 10484 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 10485 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 10486 10487 10488# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 10489# ----------------------------------------------------------------------- 10490# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 10491# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 10492m4_define([lt_if_append_uniq], 10493[m4_ifdef([$1], 10494 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 10495 [lt_append([$1], [$2], [$3])$4], 10496 [$5])], 10497 [lt_append([$1], [$2], [$3])$4])]) 10498 10499 10500# lt_dict_add(DICT, KEY, VALUE) 10501# ----------------------------- 10502m4_define([lt_dict_add], 10503[m4_define([$1($2)], [$3])]) 10504 10505 10506# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 10507# -------------------------------------------- 10508m4_define([lt_dict_add_subkey], 10509[m4_define([$1($2:$3)], [$4])]) 10510 10511 10512# lt_dict_fetch(DICT, KEY, [SUBKEY]) 10513# ---------------------------------- 10514m4_define([lt_dict_fetch], 10515[m4_ifval([$3], 10516 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 10517 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 10518 10519 10520# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 10521# ----------------------------------------------------------------- 10522m4_define([lt_if_dict_fetch], 10523[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 10524 [$5], 10525 [$6])]) 10526 10527 10528# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 10529# -------------------------------------------------------------- 10530m4_define([lt_dict_filter], 10531[m4_if([$5], [], [], 10532 [lt_join(m4_quote(m4_default([$4], [[, ]])), 10533 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 10534 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 10535]) 10536 10537# ltversion.m4 -- version numbers -*- Autoconf -*- 10538# 10539# Copyright (C) 2004 Free Software Foundation, Inc. 10540# Written by Scott James Remnant, 2004 10541# 10542# This file is free software; the Free Software Foundation gives 10543# unlimited permission to copy and/or distribute it, with or without 10544# modifications, as long as this notice is preserved. 10545 10546# @configure_input@ 10547 10548# serial 3337 ltversion.m4 10549# This file is part of GNU Libtool 10550 10551m4_define([LT_PACKAGE_VERSION], [2.4.2]) 10552m4_define([LT_PACKAGE_REVISION], [1.3337]) 10553 10554AC_DEFUN([LTVERSION_VERSION], 10555[macro_version='2.4.2' 10556macro_revision='1.3337' 10557_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 10558_LT_DECL(, macro_revision, 0) 10559]) 10560 10561# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 10562# 10563# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. 10564# Written by Scott James Remnant, 2004. 10565# 10566# This file is free software; the Free Software Foundation gives 10567# unlimited permission to copy and/or distribute it, with or without 10568# modifications, as long as this notice is preserved. 10569 10570# serial 5 lt~obsolete.m4 10571 10572# These exist entirely to fool aclocal when bootstrapping libtool. 10573# 10574# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) 10575# which have later been changed to m4_define as they aren't part of the 10576# exported API, or moved to Autoconf or Automake where they belong. 10577# 10578# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 10579# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 10580# using a macro with the same name in our local m4/libtool.m4 it'll 10581# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 10582# and doesn't know about Autoconf macros at all.) 10583# 10584# So we provide this file, which has a silly filename so it's always 10585# included after everything else. This provides aclocal with the 10586# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 10587# because those macros already exist, or will be overwritten later. 10588# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 10589# 10590# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 10591# Yes, that means every name once taken will need to remain here until 10592# we give up compatibility with versions before 1.7, at which point 10593# we need to keep only those names which we still refer to. 10594 10595# This is to help aclocal find these macros, as it can't see m4_define. 10596AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 10597 10598m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 10599m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 10600m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 10601m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 10602m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 10603m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 10604m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 10605m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 10606m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 10607m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 10608m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 10609m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 10610m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 10611m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 10612m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 10613m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 10614m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 10615m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 10616m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 10617m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 10618m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 10619m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 10620m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 10621m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 10622m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 10623m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 10624m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 10625m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 10626m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 10627m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 10628m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 10629m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 10630m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 10631m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 10632m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 10633m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 10634m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 10635m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 10636m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 10637m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 10638m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 10639m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 10640m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 10641m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 10642m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 10643m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 10644m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 10645m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 10646m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 10647m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 10648m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 10649m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 10650m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 10651m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 10652m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) 10653m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) 10654m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) 10655m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) 10656m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) 10657m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) 10658m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) 10659 10660# nls.m4 serial 5 (gettext-0.18) 10661dnl Copyright (C) 1995-2003, 2005-2006, 2008-2014 Free Software Foundation, 10662dnl Inc. 10663dnl This file is free software; the Free Software Foundation 10664dnl gives unlimited permission to copy and/or distribute it, 10665dnl with or without modifications, as long as this notice is preserved. 10666dnl 10667dnl This file can can be used in projects which are not available under 10668dnl the GNU General Public License or the GNU Library General Public 10669dnl License but which still want to provide support for the GNU gettext 10670dnl functionality. 10671dnl Please note that the actual code of the GNU gettext library is covered 10672dnl by the GNU Library General Public License, and the rest of the GNU 10673dnl gettext package package is covered by the GNU General Public License. 10674dnl They are *not* in the public domain. 10675 10676dnl Authors: 10677dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000. 10678dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003. 10679 10680AC_PREREQ([2.50]) 10681 10682AC_DEFUN([AM_NLS], 10683[ 10684 AC_MSG_CHECKING([whether NLS is requested]) 10685 dnl Default is enabled NLS 10686 AC_ARG_ENABLE([nls], 10687 [ --disable-nls do not use Native Language Support], 10688 USE_NLS=$enableval, USE_NLS=yes) 10689 AC_MSG_RESULT([$USE_NLS]) 10690 AC_SUBST([USE_NLS]) 10691]) 10692 10693# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 10694# serial 1 (pkg-config-0.24) 10695# 10696# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 10697# 10698# This program is free software; you can redistribute it and/or modify 10699# it under the terms of the GNU General Public License as published by 10700# the Free Software Foundation; either version 2 of the License, or 10701# (at your option) any later version. 10702# 10703# This program is distributed in the hope that it will be useful, but 10704# WITHOUT ANY WARRANTY; without even the implied warranty of 10705# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 10706# General Public License for more details. 10707# 10708# You should have received a copy of the GNU General Public License 10709# along with this program; if not, write to the Free Software 10710# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 10711# 10712# As a special exception to the GNU General Public License, if you 10713# distribute this file as part of a program that contains a 10714# configuration script generated by Autoconf, you may include it under 10715# the same distribution terms that you use for the rest of that program. 10716 10717# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 10718# ---------------------------------- 10719AC_DEFUN([PKG_PROG_PKG_CONFIG], 10720[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 10721m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$]) 10722m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$]) 10723AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) 10724AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) 10725AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) 10726 10727if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 10728 AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 10729fi 10730if test -n "$PKG_CONFIG"; then 10731 _pkg_min_version=m4_default([$1], [0.9.0]) 10732 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 10733 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 10734 AC_MSG_RESULT([yes]) 10735 else 10736 AC_MSG_RESULT([no]) 10737 PKG_CONFIG="" 10738 fi 10739fi[]dnl 10740])# PKG_PROG_PKG_CONFIG 10741 10742# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 10743# 10744# Check to see whether a particular set of modules exists. Similar 10745# to PKG_CHECK_MODULES(), but does not set variables or print errors. 10746# 10747# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 10748# only at the first occurence in configure.ac, so if the first place 10749# it's called might be skipped (such as if it is within an "if", you 10750# have to call PKG_CHECK_EXISTS manually 10751# -------------------------------------------------------------- 10752AC_DEFUN([PKG_CHECK_EXISTS], 10753[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 10754if test -n "$PKG_CONFIG" && \ 10755 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 10756 m4_default([$2], [:]) 10757m4_ifvaln([$3], [else 10758 $3])dnl 10759fi]) 10760 10761# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 10762# --------------------------------------------- 10763m4_define([_PKG_CONFIG], 10764[if test -n "$$1"; then 10765 pkg_cv_[]$1="$$1" 10766 elif test -n "$PKG_CONFIG"; then 10767 PKG_CHECK_EXISTS([$3], 10768 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null` 10769 test "x$?" != "x0" && pkg_failed=yes ], 10770 [pkg_failed=yes]) 10771 else 10772 pkg_failed=untried 10773fi[]dnl 10774])# _PKG_CONFIG 10775 10776# _PKG_SHORT_ERRORS_SUPPORTED 10777# ----------------------------- 10778AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 10779[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 10780if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 10781 _pkg_short_errors_supported=yes 10782else 10783 _pkg_short_errors_supported=no 10784fi[]dnl 10785])# _PKG_SHORT_ERRORS_SUPPORTED 10786 10787 10788# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 10789# [ACTION-IF-NOT-FOUND]) 10790# 10791# 10792# Note that if there is a possibility the first call to 10793# PKG_CHECK_MODULES might not happen, you should be sure to include an 10794# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 10795# 10796# 10797# -------------------------------------------------------------- 10798AC_DEFUN([PKG_CHECK_MODULES], 10799[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 10800AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 10801AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 10802 10803pkg_failed=no 10804AC_MSG_CHECKING([for $1]) 10805 10806_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 10807_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 10808 10809m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 10810and $1[]_LIBS to avoid the need to call pkg-config. 10811See the pkg-config man page for more details.]) 10812 10813if test $pkg_failed = yes; then 10814 AC_MSG_RESULT([no]) 10815 _PKG_SHORT_ERRORS_SUPPORTED 10816 if test $_pkg_short_errors_supported = yes; then 10817 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` 10818 else 10819 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` 10820 fi 10821 # Put the nasty error message in config.log where it belongs 10822 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 10823 10824 m4_default([$4], [AC_MSG_ERROR( 10825[Package requirements ($2) were not met: 10826 10827$$1_PKG_ERRORS 10828 10829Consider adjusting the PKG_CONFIG_PATH environment variable if you 10830installed software in a non-standard prefix. 10831 10832_PKG_TEXT])[]dnl 10833 ]) 10834elif test $pkg_failed = untried; then 10835 AC_MSG_RESULT([no]) 10836 m4_default([$4], [AC_MSG_FAILURE( 10837[The pkg-config script could not be found or is too old. Make sure it 10838is in your PATH or set the PKG_CONFIG environment variable to the full 10839path to pkg-config. 10840 10841_PKG_TEXT 10842 10843To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl 10844 ]) 10845else 10846 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 10847 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 10848 AC_MSG_RESULT([yes]) 10849 $3 10850fi[]dnl 10851])# PKG_CHECK_MODULES 10852 10853 10854# PKG_INSTALLDIR(DIRECTORY) 10855# ------------------------- 10856# Substitutes the variable pkgconfigdir as the location where a module 10857# should install pkg-config .pc files. By default the directory is 10858# $libdir/pkgconfig, but the default can be changed by passing 10859# DIRECTORY. The user can override through the --with-pkgconfigdir 10860# parameter. 10861AC_DEFUN([PKG_INSTALLDIR], 10862[m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])]) 10863m4_pushdef([pkg_description], 10864 [pkg-config installation directory @<:@]pkg_default[@:>@]) 10865AC_ARG_WITH([pkgconfigdir], 10866 [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],, 10867 [with_pkgconfigdir=]pkg_default) 10868AC_SUBST([pkgconfigdir], [$with_pkgconfigdir]) 10869m4_popdef([pkg_default]) 10870m4_popdef([pkg_description]) 10871]) dnl PKG_INSTALLDIR 10872 10873 10874# PKG_NOARCH_INSTALLDIR(DIRECTORY) 10875# ------------------------- 10876# Substitutes the variable noarch_pkgconfigdir as the location where a 10877# module should install arch-independent pkg-config .pc files. By 10878# default the directory is $datadir/pkgconfig, but the default can be 10879# changed by passing DIRECTORY. The user can override through the 10880# --with-noarch-pkgconfigdir parameter. 10881AC_DEFUN([PKG_NOARCH_INSTALLDIR], 10882[m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])]) 10883m4_pushdef([pkg_description], 10884 [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@]) 10885AC_ARG_WITH([noarch-pkgconfigdir], 10886 [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],, 10887 [with_noarch_pkgconfigdir=]pkg_default) 10888AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir]) 10889m4_popdef([pkg_default]) 10890m4_popdef([pkg_description]) 10891]) dnl PKG_NOARCH_INSTALLDIR 10892 10893 10894# PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE, 10895# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 10896# ------------------------------------------- 10897# Retrieves the value of the pkg-config variable for the given module. 10898AC_DEFUN([PKG_CHECK_VAR], 10899[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 10900AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl 10901 10902_PKG_CONFIG([$1], [variable="][$3]["], [$2]) 10903AS_VAR_COPY([$1], [pkg_cv_][$1]) 10904 10905AS_VAR_IF([$1], [""], [$5], [$4])dnl 10906])# PKG_CHECK_VAR 10907 10908# po.m4 serial 24 (gettext-0.19) 10909dnl Copyright (C) 1995-2014 Free Software Foundation, Inc. 10910dnl This file is free software; the Free Software Foundation 10911dnl gives unlimited permission to copy and/or distribute it, 10912dnl with or without modifications, as long as this notice is preserved. 10913dnl 10914dnl This file can can be used in projects which are not available under 10915dnl the GNU General Public License or the GNU Library General Public 10916dnl License but which still want to provide support for the GNU gettext 10917dnl functionality. 10918dnl Please note that the actual code of the GNU gettext library is covered 10919dnl by the GNU Library General Public License, and the rest of the GNU 10920dnl gettext package package is covered by the GNU General Public License. 10921dnl They are *not* in the public domain. 10922 10923dnl Authors: 10924dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000. 10925dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003. 10926 10927AC_PREREQ([2.60]) 10928 10929dnl Checks for all prerequisites of the po subdirectory. 10930AC_DEFUN([AM_PO_SUBDIRS], 10931[ 10932 AC_REQUIRE([AC_PROG_MAKE_SET])dnl 10933 AC_REQUIRE([AC_PROG_INSTALL])dnl 10934 AC_REQUIRE([AC_PROG_MKDIR_P])dnl 10935 AC_REQUIRE([AC_PROG_SED])dnl 10936 AC_REQUIRE([AM_NLS])dnl 10937 10938 dnl Release version of the gettext macros. This is used to ensure that 10939 dnl the gettext macros and po/Makefile.in.in are in sync. 10940 AC_SUBST([GETTEXT_MACRO_VERSION], [0.19]) 10941 10942 dnl Perform the following tests also if --disable-nls has been given, 10943 dnl because they are needed for "make dist" to work. 10944 10945 dnl Search for GNU msgfmt in the PATH. 10946 dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions. 10947 dnl The second test excludes FreeBSD msgfmt. 10948 AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, 10949 [$ac_dir/$ac_word --statistics /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 && 10950 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], 10951 :) 10952 AC_PATH_PROG([GMSGFMT], [gmsgfmt], [$MSGFMT]) 10953 10954 dnl Test whether it is GNU msgfmt >= 0.15. 10955changequote(,)dnl 10956 case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in 10957 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;; 10958 *) MSGFMT_015=$MSGFMT ;; 10959 esac 10960changequote([,])dnl 10961 AC_SUBST([MSGFMT_015]) 10962changequote(,)dnl 10963 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in 10964 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;; 10965 *) GMSGFMT_015=$GMSGFMT ;; 10966 esac 10967changequote([,])dnl 10968 AC_SUBST([GMSGFMT_015]) 10969 10970 dnl Search for GNU xgettext 0.12 or newer in the PATH. 10971 dnl The first test excludes Solaris xgettext and early GNU xgettext versions. 10972 dnl The second test excludes FreeBSD xgettext. 10973 AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, 10974 [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 && 10975 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], 10976 :) 10977 dnl Remove leftover from FreeBSD xgettext call. 10978 rm -f messages.po 10979 10980 dnl Test whether it is GNU xgettext >= 0.15. 10981changequote(,)dnl 10982 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in 10983 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;; 10984 *) XGETTEXT_015=$XGETTEXT ;; 10985 esac 10986changequote([,])dnl 10987 AC_SUBST([XGETTEXT_015]) 10988 10989 dnl Search for GNU msgmerge 0.11 or newer in the PATH. 10990 AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge, 10991 [$ac_dir/$ac_word --update -q /dev/null /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1], :) 10992 10993 dnl Installation directories. 10994 dnl Autoconf >= 2.60 defines localedir. For older versions of autoconf, we 10995 dnl have to define it here, so that it can be used in po/Makefile. 10996 test -n "$localedir" || localedir='${datadir}/locale' 10997 AC_SUBST([localedir]) 10998 10999 dnl Support for AM_XGETTEXT_OPTION. 11000 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS= 11001 AC_SUBST([XGETTEXT_EXTRA_OPTIONS]) 11002 11003 AC_CONFIG_COMMANDS([po-directories], [[ 11004 for ac_file in $CONFIG_FILES; do 11005 # Support "outfile[:infile[:infile...]]" 11006 case "$ac_file" in 11007 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; 11008 esac 11009 # PO directories have a Makefile.in generated from Makefile.in.in. 11010 case "$ac_file" in */Makefile.in) 11011 # Adjust a relative srcdir. 11012 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` 11013 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'` 11014 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` 11015 # In autoconf-2.13 it is called $ac_given_srcdir. 11016 # In autoconf-2.50 it is called $srcdir. 11017 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" 11018 case "$ac_given_srcdir" in 11019 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; 11020 /*) top_srcdir="$ac_given_srcdir" ;; 11021 *) top_srcdir="$ac_dots$ac_given_srcdir" ;; 11022 esac 11023 # Treat a directory as a PO directory if and only if it has a 11024 # POTFILES.in file. This allows packages to have multiple PO 11025 # directories under different names or in different locations. 11026 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then 11027 rm -f "$ac_dir/POTFILES" 11028 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" 11029 gt_tab=`printf '\t'` 11030 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" 11031 POMAKEFILEDEPS="POTFILES.in" 11032 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend 11033 # on $ac_dir but don't depend on user-specified configuration 11034 # parameters. 11035 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then 11036 # The LINGUAS file contains the set of available languages. 11037 if test -n "$OBSOLETE_ALL_LINGUAS"; then 11038 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" 11039 fi 11040 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"` 11041 # Hide the ALL_LINGUAS assignment from automake < 1.5. 11042 eval 'ALL_LINGUAS''=$ALL_LINGUAS_' 11043 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" 11044 else 11045 # The set of available languages was given in configure.in. 11046 # Hide the ALL_LINGUAS assignment from automake < 1.5. 11047 eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' 11048 fi 11049 # Compute POFILES 11050 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po) 11051 # Compute UPDATEPOFILES 11052 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update) 11053 # Compute DUMMYPOFILES 11054 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop) 11055 # Compute GMOFILES 11056 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo) 11057 case "$ac_given_srcdir" in 11058 .) srcdirpre= ;; 11059 *) srcdirpre='$(srcdir)/' ;; 11060 esac 11061 POFILES= 11062 UPDATEPOFILES= 11063 DUMMYPOFILES= 11064 GMOFILES= 11065 for lang in $ALL_LINGUAS; do 11066 POFILES="$POFILES $srcdirpre$lang.po" 11067 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" 11068 DUMMYPOFILES="$DUMMYPOFILES $lang.nop" 11069 GMOFILES="$GMOFILES $srcdirpre$lang.gmo" 11070 done 11071 # CATALOGS depends on both $ac_dir and the user's LINGUAS 11072 # environment variable. 11073 INST_LINGUAS= 11074 if test -n "$ALL_LINGUAS"; then 11075 for presentlang in $ALL_LINGUAS; do 11076 useit=no 11077 if test "%UNSET%" != "$LINGUAS"; then 11078 desiredlanguages="$LINGUAS" 11079 else 11080 desiredlanguages="$ALL_LINGUAS" 11081 fi 11082 for desiredlang in $desiredlanguages; do 11083 # Use the presentlang catalog if desiredlang is 11084 # a. equal to presentlang, or 11085 # b. a variant of presentlang (because in this case, 11086 # presentlang can be used as a fallback for messages 11087 # which are not translated in the desiredlang catalog). 11088 case "$desiredlang" in 11089 "$presentlang"*) useit=yes;; 11090 esac 11091 done 11092 if test $useit = yes; then 11093 INST_LINGUAS="$INST_LINGUAS $presentlang" 11094 fi 11095 done 11096 fi 11097 CATALOGS= 11098 if test -n "$INST_LINGUAS"; then 11099 for lang in $INST_LINGUAS; do 11100 CATALOGS="$CATALOGS $lang.gmo" 11101 done 11102 fi 11103 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" 11104 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" 11105 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do 11106 if test -f "$f"; then 11107 case "$f" in 11108 *.orig | *.bak | *~) ;; 11109 *) cat "$f" >> "$ac_dir/Makefile" ;; 11110 esac 11111 fi 11112 done 11113 fi 11114 ;; 11115 esac 11116 done]], 11117 [# Capture the value of obsolete ALL_LINGUAS because we need it to compute 11118 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it 11119 # from automake < 1.5. 11120 eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' 11121 # Capture the value of LINGUAS because we need it to compute CATALOGS. 11122 LINGUAS="${LINGUAS-%UNSET%}" 11123 ]) 11124]) 11125 11126dnl Postprocesses a Makefile in a directory containing PO files. 11127AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE], 11128[ 11129 # When this code is run, in config.status, two variables have already been 11130 # set: 11131 # - OBSOLETE_ALL_LINGUAS is the value of LINGUAS set in configure.in, 11132 # - LINGUAS is the value of the environment variable LINGUAS at configure 11133 # time. 11134 11135changequote(,)dnl 11136 # Adjust a relative srcdir. 11137 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` 11138 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'` 11139 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` 11140 # In autoconf-2.13 it is called $ac_given_srcdir. 11141 # In autoconf-2.50 it is called $srcdir. 11142 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" 11143 case "$ac_given_srcdir" in 11144 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; 11145 /*) top_srcdir="$ac_given_srcdir" ;; 11146 *) top_srcdir="$ac_dots$ac_given_srcdir" ;; 11147 esac 11148 11149 # Find a way to echo strings without interpreting backslash. 11150 if test "X`(echo '\t') 2>/dev/null`" = 'X\t'; then 11151 gt_echo='echo' 11152 else 11153 if test "X`(printf '%s\n' '\t') 2>/dev/null`" = 'X\t'; then 11154 gt_echo='printf %s\n' 11155 else 11156 echo_func () { 11157 cat <<EOT 11158$* 11159EOT 11160 } 11161 gt_echo='echo_func' 11162 fi 11163 fi 11164 11165 # A sed script that extracts the value of VARIABLE from a Makefile. 11166 tab=`printf '\t'` 11167 sed_x_variable=' 11168# Test if the hold space is empty. 11169x 11170s/P/P/ 11171x 11172ta 11173# Yes it was empty. Look if we have the expected variable definition. 11174/^['"${tab}"' ]*VARIABLE['"${tab}"' ]*=/{ 11175 # Seen the first line of the variable definition. 11176 s/^['"${tab}"' ]*VARIABLE['"${tab}"' ]*=// 11177 ba 11178} 11179bd 11180:a 11181# Here we are processing a line from the variable definition. 11182# Remove comment, more precisely replace it with a space. 11183s/#.*$/ / 11184# See if the line ends in a backslash. 11185tb 11186:b 11187s/\\$// 11188# Print the line, without the trailing backslash. 11189p 11190tc 11191# There was no trailing backslash. The end of the variable definition is 11192# reached. Clear the hold space. 11193s/^.*$// 11194x 11195bd 11196:c 11197# A trailing backslash means that the variable definition continues in the 11198# next line. Put a nonempty string into the hold space to indicate this. 11199s/^.*$/P/ 11200x 11201:d 11202' 11203changequote([,])dnl 11204 11205 # Set POTFILES to the value of the Makefile variable POTFILES. 11206 sed_x_POTFILES=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/POTFILES/g'` 11207 POTFILES=`sed -n -e "$sed_x_POTFILES" < "$ac_file"` 11208 # Compute POTFILES_DEPS as 11209 # $(foreach file, $(POTFILES), $(top_srcdir)/$(file)) 11210 POTFILES_DEPS= 11211 for file in $POTFILES; do 11212 POTFILES_DEPS="$POTFILES_DEPS "'$(top_srcdir)/'"$file" 11213 done 11214 POMAKEFILEDEPS="" 11215 11216 if test -n "$OBSOLETE_ALL_LINGUAS"; then 11217 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" 11218 fi 11219 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then 11220 # The LINGUAS file contains the set of available languages. 11221 ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"` 11222 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" 11223 else 11224 # Set ALL_LINGUAS to the value of the Makefile variable LINGUAS. 11225 sed_x_LINGUAS=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/LINGUAS/g'` 11226 ALL_LINGUAS_=`sed -n -e "$sed_x_LINGUAS" < "$ac_file"` 11227 fi 11228 # Hide the ALL_LINGUAS assignment from automake < 1.5. 11229 eval 'ALL_LINGUAS''=$ALL_LINGUAS_' 11230 # Compute POFILES 11231 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po) 11232 # Compute UPDATEPOFILES 11233 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update) 11234 # Compute DUMMYPOFILES 11235 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop) 11236 # Compute GMOFILES 11237 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo) 11238 # Compute PROPERTIESFILES 11239 # as $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).properties) 11240 # Compute CLASSFILES 11241 # as $(foreach lang, $(ALL_LINGUAS), $(top_srcdir)/$(DOMAIN)_$(lang).class) 11242 # Compute QMFILES 11243 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).qm) 11244 # Compute MSGFILES 11245 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang)).msg) 11246 # Compute RESOURCESDLLFILES 11247 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang))/$(DOMAIN).resources.dll) 11248 case "$ac_given_srcdir" in 11249 .) srcdirpre= ;; 11250 *) srcdirpre='$(srcdir)/' ;; 11251 esac 11252 POFILES= 11253 UPDATEPOFILES= 11254 DUMMYPOFILES= 11255 GMOFILES= 11256 PROPERTIESFILES= 11257 CLASSFILES= 11258 QMFILES= 11259 MSGFILES= 11260 RESOURCESDLLFILES= 11261 for lang in $ALL_LINGUAS; do 11262 POFILES="$POFILES $srcdirpre$lang.po" 11263 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" 11264 DUMMYPOFILES="$DUMMYPOFILES $lang.nop" 11265 GMOFILES="$GMOFILES $srcdirpre$lang.gmo" 11266 PROPERTIESFILES="$PROPERTIESFILES \$(top_srcdir)/\$(DOMAIN)_$lang.properties" 11267 CLASSFILES="$CLASSFILES \$(top_srcdir)/\$(DOMAIN)_$lang.class" 11268 QMFILES="$QMFILES $srcdirpre$lang.qm" 11269 frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'` 11270 MSGFILES="$MSGFILES $srcdirpre$frobbedlang.msg" 11271 frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'` 11272 RESOURCESDLLFILES="$RESOURCESDLLFILES $srcdirpre$frobbedlang/\$(DOMAIN).resources.dll" 11273 done 11274 # CATALOGS depends on both $ac_dir and the user's LINGUAS 11275 # environment variable. 11276 INST_LINGUAS= 11277 if test -n "$ALL_LINGUAS"; then 11278 for presentlang in $ALL_LINGUAS; do 11279 useit=no 11280 if test "%UNSET%" != "$LINGUAS"; then 11281 desiredlanguages="$LINGUAS" 11282 else 11283 desiredlanguages="$ALL_LINGUAS" 11284 fi 11285 for desiredlang in $desiredlanguages; do 11286 # Use the presentlang catalog if desiredlang is 11287 # a. equal to presentlang, or 11288 # b. a variant of presentlang (because in this case, 11289 # presentlang can be used as a fallback for messages 11290 # which are not translated in the desiredlang catalog). 11291 case "$desiredlang" in 11292 "$presentlang"*) useit=yes;; 11293 esac 11294 done 11295 if test $useit = yes; then 11296 INST_LINGUAS="$INST_LINGUAS $presentlang" 11297 fi 11298 done 11299 fi 11300 CATALOGS= 11301 JAVACATALOGS= 11302 QTCATALOGS= 11303 TCLCATALOGS= 11304 CSHARPCATALOGS= 11305 if test -n "$INST_LINGUAS"; then 11306 for lang in $INST_LINGUAS; do 11307 CATALOGS="$CATALOGS $lang.gmo" 11308 JAVACATALOGS="$JAVACATALOGS \$(DOMAIN)_$lang.properties" 11309 QTCATALOGS="$QTCATALOGS $lang.qm" 11310 frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'` 11311 TCLCATALOGS="$TCLCATALOGS $frobbedlang.msg" 11312 frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'` 11313 CSHARPCATALOGS="$CSHARPCATALOGS $frobbedlang/\$(DOMAIN).resources.dll" 11314 done 11315 fi 11316 11317 sed -e "s|@POTFILES_DEPS@|$POTFILES_DEPS|g" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@PROPERTIESFILES@|$PROPERTIESFILES|g" -e "s|@CLASSFILES@|$CLASSFILES|g" -e "s|@QMFILES@|$QMFILES|g" -e "s|@MSGFILES@|$MSGFILES|g" -e "s|@RESOURCESDLLFILES@|$RESOURCESDLLFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@JAVACATALOGS@|$JAVACATALOGS|g" -e "s|@QTCATALOGS@|$QTCATALOGS|g" -e "s|@TCLCATALOGS@|$TCLCATALOGS|g" -e "s|@CSHARPCATALOGS@|$CSHARPCATALOGS|g" -e 's,^#distdir:,distdir:,' < "$ac_file" > "$ac_file.tmp" 11318 tab=`printf '\t'` 11319 if grep -l '@TCLCATALOGS@' "$ac_file" > /dev/null; then 11320 # Add dependencies that cannot be formulated as a simple suffix rule. 11321 for lang in $ALL_LINGUAS; do 11322 frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'` 11323 cat >> "$ac_file.tmp" <<EOF 11324$frobbedlang.msg: $lang.po 11325${tab}@echo "\$(MSGFMT) -c --tcl -d \$(srcdir) -l $lang $srcdirpre$lang.po"; \ 11326${tab}\$(MSGFMT) -c --tcl -d "\$(srcdir)" -l $lang $srcdirpre$lang.po || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; } 11327EOF 11328 done 11329 fi 11330 if grep -l '@CSHARPCATALOGS@' "$ac_file" > /dev/null; then 11331 # Add dependencies that cannot be formulated as a simple suffix rule. 11332 for lang in $ALL_LINGUAS; do 11333 frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'` 11334 cat >> "$ac_file.tmp" <<EOF 11335$frobbedlang/\$(DOMAIN).resources.dll: $lang.po 11336${tab}@echo "\$(MSGFMT) -c --csharp -d \$(srcdir) -l $lang $srcdirpre$lang.po -r \$(DOMAIN)"; \ 11337${tab}\$(MSGFMT) -c --csharp -d "\$(srcdir)" -l $lang $srcdirpre$lang.po -r "\$(DOMAIN)" || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; } 11338EOF 11339 done 11340 fi 11341 if test -n "$POMAKEFILEDEPS"; then 11342 cat >> "$ac_file.tmp" <<EOF 11343Makefile: $POMAKEFILEDEPS 11344EOF 11345 fi 11346 mv "$ac_file.tmp" "$ac_file" 11347]) 11348 11349dnl Initializes the accumulator used by AM_XGETTEXT_OPTION. 11350AC_DEFUN([AM_XGETTEXT_OPTION_INIT], 11351[ 11352 XGETTEXT_EXTRA_OPTIONS= 11353]) 11354 11355dnl Registers an option to be passed to xgettext in the po subdirectory. 11356AC_DEFUN([AM_XGETTEXT_OPTION], 11357[ 11358 AC_REQUIRE([AM_XGETTEXT_OPTION_INIT]) 11359 XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS $1" 11360]) 11361 11362# progtest.m4 serial 7 (gettext-0.18.2) 11363dnl Copyright (C) 1996-2003, 2005, 2008-2014 Free Software Foundation, Inc. 11364dnl This file is free software; the Free Software Foundation 11365dnl gives unlimited permission to copy and/or distribute it, 11366dnl with or without modifications, as long as this notice is preserved. 11367dnl 11368dnl This file can can be used in projects which are not available under 11369dnl the GNU General Public License or the GNU Library General Public 11370dnl License but which still want to provide support for the GNU gettext 11371dnl functionality. 11372dnl Please note that the actual code of the GNU gettext library is covered 11373dnl by the GNU Library General Public License, and the rest of the GNU 11374dnl gettext package package is covered by the GNU General Public License. 11375dnl They are *not* in the public domain. 11376 11377dnl Authors: 11378dnl Ulrich Drepper <drepper@cygnus.com>, 1996. 11379 11380AC_PREREQ([2.50]) 11381 11382# Search path for a program which passes the given test. 11383 11384dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, 11385dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) 11386AC_DEFUN([AM_PATH_PROG_WITH_TEST], 11387[ 11388# Prepare PATH_SEPARATOR. 11389# The user is always right. 11390if test "${PATH_SEPARATOR+set}" != set; then 11391 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which 11392 # contains only /bin. Note that ksh looks also at the FPATH variable, 11393 # so we have to set that as well for the test. 11394 PATH_SEPARATOR=: 11395 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \ 11396 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \ 11397 || PATH_SEPARATOR=';' 11398 } 11399fi 11400 11401# Find out how to test for executable files. Don't use a zero-byte file, 11402# as systems may use methods other than mode bits to determine executability. 11403cat >conf$$.file <<_ASEOF 11404#! /bin/sh 11405exit 0 11406_ASEOF 11407chmod +x conf$$.file 11408if test -x conf$$.file >/dev/null 2>&1; then 11409 ac_executable_p="test -x" 11410else 11411 ac_executable_p="test -f" 11412fi 11413rm -f conf$$.file 11414 11415# Extract the first word of "$2", so it can be a program name with args. 11416set dummy $2; ac_word=[$]2 11417AC_MSG_CHECKING([for $ac_word]) 11418AC_CACHE_VAL([ac_cv_path_$1], 11419[case "[$]$1" in 11420 [[\\/]]* | ?:[[\\/]]*) 11421 ac_cv_path_$1="[$]$1" # Let the user override the test with a path. 11422 ;; 11423 *) 11424 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR 11425 for ac_dir in ifelse([$5], , $PATH, [$5]); do 11426 IFS="$ac_save_IFS" 11427 test -z "$ac_dir" && ac_dir=. 11428 for ac_exec_ext in '' $ac_executable_extensions; do 11429 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then 11430 echo "$as_me: trying $ac_dir/$ac_word..." >&AS_MESSAGE_LOG_FD 11431 if [$3]; then 11432 ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext" 11433 break 2 11434 fi 11435 fi 11436 done 11437 done 11438 IFS="$ac_save_IFS" 11439dnl If no 4th arg is given, leave the cache variable unset, 11440dnl so AC_PATH_PROGS will keep looking. 11441ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" 11442])dnl 11443 ;; 11444esac])dnl 11445$1="$ac_cv_path_$1" 11446if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then 11447 AC_MSG_RESULT([$][$1]) 11448else 11449 AC_MSG_RESULT([no]) 11450fi 11451AC_SUBST([$1])dnl 11452]) 11453 11454# Copyright (C) 2002-2013 Free Software Foundation, Inc. 11455# 11456# This file is free software; the Free Software Foundation 11457# gives unlimited permission to copy and/or distribute it, 11458# with or without modifications, as long as this notice is preserved. 11459 11460# AM_AUTOMAKE_VERSION(VERSION) 11461# ---------------------------- 11462# Automake X.Y traces this macro to ensure aclocal.m4 has been 11463# generated from the m4 files accompanying Automake X.Y. 11464# (This private macro should not be called outside this file.) 11465AC_DEFUN([AM_AUTOMAKE_VERSION], 11466[am__api_version='1.14' 11467dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 11468dnl require some minimum version. Point them to the right macro. 11469m4_if([$1], [1.14.1], [], 11470 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 11471]) 11472 11473# _AM_AUTOCONF_VERSION(VERSION) 11474# ----------------------------- 11475# aclocal traces this macro to find the Autoconf version. 11476# This is a private macro too. Using m4_define simplifies 11477# the logic in aclocal, which can simply ignore this definition. 11478m4_define([_AM_AUTOCONF_VERSION], []) 11479 11480# AM_SET_CURRENT_AUTOMAKE_VERSION 11481# ------------------------------- 11482# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 11483# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 11484AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 11485[AM_AUTOMAKE_VERSION([1.14.1])dnl 11486m4_ifndef([AC_AUTOCONF_VERSION], 11487 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 11488_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 11489 11490# AM_AUX_DIR_EXPAND -*- Autoconf -*- 11491 11492# Copyright (C) 2001-2013 Free Software Foundation, Inc. 11493# 11494# This file is free software; the Free Software Foundation 11495# gives unlimited permission to copy and/or distribute it, 11496# with or without modifications, as long as this notice is preserved. 11497 11498# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 11499# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to 11500# '$srcdir', '$srcdir/..', or '$srcdir/../..'. 11501# 11502# Of course, Automake must honor this variable whenever it calls a 11503# tool from the auxiliary directory. The problem is that $srcdir (and 11504# therefore $ac_aux_dir as well) can be either absolute or relative, 11505# depending on how configure is run. This is pretty annoying, since 11506# it makes $ac_aux_dir quite unusable in subdirectories: in the top 11507# source directory, any form will work fine, but in subdirectories a 11508# relative path needs to be adjusted first. 11509# 11510# $ac_aux_dir/missing 11511# fails when called from a subdirectory if $ac_aux_dir is relative 11512# $top_srcdir/$ac_aux_dir/missing 11513# fails if $ac_aux_dir is absolute, 11514# fails when called from a subdirectory in a VPATH build with 11515# a relative $ac_aux_dir 11516# 11517# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 11518# are both prefixed by $srcdir. In an in-source build this is usually 11519# harmless because $srcdir is '.', but things will broke when you 11520# start a VPATH build or use an absolute $srcdir. 11521# 11522# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 11523# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 11524# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 11525# and then we would define $MISSING as 11526# MISSING="\${SHELL} $am_aux_dir/missing" 11527# This will work as long as MISSING is not called from configure, because 11528# unfortunately $(top_srcdir) has no meaning in configure. 11529# However there are other variables, like CC, which are often used in 11530# configure, and could therefore not use this "fixed" $ac_aux_dir. 11531# 11532# Another solution, used here, is to always expand $ac_aux_dir to an 11533# absolute PATH. The drawback is that using absolute paths prevent a 11534# configured tree to be moved without reconfiguration. 11535 11536AC_DEFUN([AM_AUX_DIR_EXPAND], 11537[dnl Rely on autoconf to set up CDPATH properly. 11538AC_PREREQ([2.50])dnl 11539# expand $ac_aux_dir to an absolute path 11540am_aux_dir=`cd $ac_aux_dir && pwd` 11541]) 11542 11543# AM_CONDITIONAL -*- Autoconf -*- 11544 11545# Copyright (C) 1997-2013 Free Software Foundation, Inc. 11546# 11547# This file is free software; the Free Software Foundation 11548# gives unlimited permission to copy and/or distribute it, 11549# with or without modifications, as long as this notice is preserved. 11550 11551# AM_CONDITIONAL(NAME, SHELL-CONDITION) 11552# ------------------------------------- 11553# Define a conditional. 11554AC_DEFUN([AM_CONDITIONAL], 11555[AC_PREREQ([2.52])dnl 11556 m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 11557 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 11558AC_SUBST([$1_TRUE])dnl 11559AC_SUBST([$1_FALSE])dnl 11560_AM_SUBST_NOTMAKE([$1_TRUE])dnl 11561_AM_SUBST_NOTMAKE([$1_FALSE])dnl 11562m4_define([_AM_COND_VALUE_$1], [$2])dnl 11563if $2; then 11564 $1_TRUE= 11565 $1_FALSE='#' 11566else 11567 $1_TRUE='#' 11568 $1_FALSE= 11569fi 11570AC_CONFIG_COMMANDS_PRE( 11571[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 11572 AC_MSG_ERROR([[conditional "$1" was never defined. 11573Usually this means the macro was only invoked conditionally.]]) 11574fi])]) 11575 11576# Copyright (C) 1999-2013 Free Software Foundation, Inc. 11577# 11578# This file is free software; the Free Software Foundation 11579# gives unlimited permission to copy and/or distribute it, 11580# with or without modifications, as long as this notice is preserved. 11581 11582 11583# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be 11584# written in clear, in which case automake, when reading aclocal.m4, 11585# will think it sees a *use*, and therefore will trigger all it's 11586# C support machinery. Also note that it means that autoscan, seeing 11587# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 11588 11589 11590# _AM_DEPENDENCIES(NAME) 11591# ---------------------- 11592# See how the compiler implements dependency checking. 11593# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". 11594# We try a few techniques and use that to set a single cache variable. 11595# 11596# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 11597# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 11598# dependency, and given that the user is not expected to run this macro, 11599# just rely on AC_PROG_CC. 11600AC_DEFUN([_AM_DEPENDENCIES], 11601[AC_REQUIRE([AM_SET_DEPDIR])dnl 11602AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 11603AC_REQUIRE([AM_MAKE_INCLUDE])dnl 11604AC_REQUIRE([AM_DEP_TRACK])dnl 11605 11606m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], 11607 [$1], [CXX], [depcc="$CXX" am_compiler_list=], 11608 [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 11609 [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], 11610 [$1], [UPC], [depcc="$UPC" am_compiler_list=], 11611 [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 11612 [depcc="$$1" am_compiler_list=]) 11613 11614AC_CACHE_CHECK([dependency style of $depcc], 11615 [am_cv_$1_dependencies_compiler_type], 11616[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 11617 # We make a subdir and do the tests there. Otherwise we can end up 11618 # making bogus files that we don't know about and never remove. For 11619 # instance it was reported that on HP-UX the gcc test will end up 11620 # making a dummy file named 'D' -- because '-MD' means "put the output 11621 # in D". 11622 rm -rf conftest.dir 11623 mkdir conftest.dir 11624 # Copy depcomp to subdir because otherwise we won't find it if we're 11625 # using a relative directory. 11626 cp "$am_depcomp" conftest.dir 11627 cd conftest.dir 11628 # We will build objects and dependencies in a subdirectory because 11629 # it helps to detect inapplicable dependency modes. For instance 11630 # both Tru64's cc and ICC support -MD to output dependencies as a 11631 # side effect of compilation, but ICC will put the dependencies in 11632 # the current directory while Tru64 will put them in the object 11633 # directory. 11634 mkdir sub 11635 11636 am_cv_$1_dependencies_compiler_type=none 11637 if test "$am_compiler_list" = ""; then 11638 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 11639 fi 11640 am__universal=false 11641 m4_case([$1], [CC], 11642 [case " $depcc " in #( 11643 *\ -arch\ *\ -arch\ *) am__universal=true ;; 11644 esac], 11645 [CXX], 11646 [case " $depcc " in #( 11647 *\ -arch\ *\ -arch\ *) am__universal=true ;; 11648 esac]) 11649 11650 for depmode in $am_compiler_list; do 11651 # Setup a source with many dependencies, because some compilers 11652 # like to wrap large dependency lists on column 80 (with \), and 11653 # we should not choose a depcomp mode which is confused by this. 11654 # 11655 # We need to recreate these files for each test, as the compiler may 11656 # overwrite some of them when testing with obscure command lines. 11657 # This happens at least with the AIX C compiler. 11658 : > sub/conftest.c 11659 for i in 1 2 3 4 5 6; do 11660 echo '#include "conftst'$i'.h"' >> sub/conftest.c 11661 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with 11662 # Solaris 10 /bin/sh. 11663 echo '/* dummy */' > sub/conftst$i.h 11664 done 11665 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 11666 11667 # We check with '-c' and '-o' for the sake of the "dashmstdout" 11668 # mode. It turns out that the SunPro C++ compiler does not properly 11669 # handle '-M -o', and we need to detect this. Also, some Intel 11670 # versions had trouble with output in subdirs. 11671 am__obj=sub/conftest.${OBJEXT-o} 11672 am__minus_obj="-o $am__obj" 11673 case $depmode in 11674 gcc) 11675 # This depmode causes a compiler race in universal mode. 11676 test "$am__universal" = false || continue 11677 ;; 11678 nosideeffect) 11679 # After this tag, mechanisms are not by side-effect, so they'll 11680 # only be used when explicitly requested. 11681 if test "x$enable_dependency_tracking" = xyes; then 11682 continue 11683 else 11684 break 11685 fi 11686 ;; 11687 msvc7 | msvc7msys | msvisualcpp | msvcmsys) 11688 # This compiler won't grok '-c -o', but also, the minuso test has 11689 # not run yet. These depmodes are late enough in the game, and 11690 # so weak that their functioning should not be impacted. 11691 am__obj=conftest.${OBJEXT-o} 11692 am__minus_obj= 11693 ;; 11694 none) break ;; 11695 esac 11696 if depmode=$depmode \ 11697 source=sub/conftest.c object=$am__obj \ 11698 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 11699 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ 11700 >/dev/null 2>conftest.err && 11701 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 11702 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 11703 grep $am__obj sub/conftest.Po > /dev/null 2>&1 && 11704 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 11705 # icc doesn't choke on unknown options, it will just issue warnings 11706 # or remarks (even with -Werror). So we grep stderr for any message 11707 # that says an option was ignored or not supported. 11708 # When given -MP, icc 7.0 and 7.1 complain thusly: 11709 # icc: Command line warning: ignoring option '-M'; no argument required 11710 # The diagnosis changed in icc 8.0: 11711 # icc: Command line remark: option '-MP' not supported 11712 if (grep 'ignoring option' conftest.err || 11713 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 11714 am_cv_$1_dependencies_compiler_type=$depmode 11715 break 11716 fi 11717 fi 11718 done 11719 11720 cd .. 11721 rm -rf conftest.dir 11722else 11723 am_cv_$1_dependencies_compiler_type=none 11724fi 11725]) 11726AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 11727AM_CONDITIONAL([am__fastdep$1], [ 11728 test "x$enable_dependency_tracking" != xno \ 11729 && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 11730]) 11731 11732 11733# AM_SET_DEPDIR 11734# ------------- 11735# Choose a directory name for dependency files. 11736# This macro is AC_REQUIREd in _AM_DEPENDENCIES. 11737AC_DEFUN([AM_SET_DEPDIR], 11738[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 11739AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 11740]) 11741 11742 11743# AM_DEP_TRACK 11744# ------------ 11745AC_DEFUN([AM_DEP_TRACK], 11746[AC_ARG_ENABLE([dependency-tracking], [dnl 11747AS_HELP_STRING( 11748 [--enable-dependency-tracking], 11749 [do not reject slow dependency extractors]) 11750AS_HELP_STRING( 11751 [--disable-dependency-tracking], 11752 [speeds up one-time build])]) 11753if test "x$enable_dependency_tracking" != xno; then 11754 am_depcomp="$ac_aux_dir/depcomp" 11755 AMDEPBACKSLASH='\' 11756 am__nodep='_no' 11757fi 11758AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 11759AC_SUBST([AMDEPBACKSLASH])dnl 11760_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 11761AC_SUBST([am__nodep])dnl 11762_AM_SUBST_NOTMAKE([am__nodep])dnl 11763]) 11764 11765# Generate code to set up dependency tracking. -*- Autoconf -*- 11766 11767# Copyright (C) 1999-2013 Free Software Foundation, Inc. 11768# 11769# This file is free software; the Free Software Foundation 11770# gives unlimited permission to copy and/or distribute it, 11771# with or without modifications, as long as this notice is preserved. 11772 11773 11774# _AM_OUTPUT_DEPENDENCY_COMMANDS 11775# ------------------------------ 11776AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 11777[{ 11778 # Older Autoconf quotes --file arguments for eval, but not when files 11779 # are listed without --file. Let's play safe and only enable the eval 11780 # if we detect the quoting. 11781 case $CONFIG_FILES in 11782 *\'*) eval set x "$CONFIG_FILES" ;; 11783 *) set x $CONFIG_FILES ;; 11784 esac 11785 shift 11786 for mf 11787 do 11788 # Strip MF so we end up with the name of the file. 11789 mf=`echo "$mf" | sed -e 's/:.*$//'` 11790 # Check whether this is an Automake generated Makefile or not. 11791 # We used to match only the files named 'Makefile.in', but 11792 # some people rename them; so instead we look at the file content. 11793 # Grep'ing the first line is not enough: some people post-process 11794 # each Makefile.in and add a new line on top of each file to say so. 11795 # Grep'ing the whole file is not good either: AIX grep has a line 11796 # limit of 2048, but all sed's we know have understand at least 4000. 11797 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then 11798 dirpart=`AS_DIRNAME("$mf")` 11799 else 11800 continue 11801 fi 11802 # Extract the definition of DEPDIR, am__include, and am__quote 11803 # from the Makefile without running 'make'. 11804 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 11805 test -z "$DEPDIR" && continue 11806 am__include=`sed -n 's/^am__include = //p' < "$mf"` 11807 test -z "$am__include" && continue 11808 am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 11809 # Find all dependency output files, they are included files with 11810 # $(DEPDIR) in their names. We invoke sed twice because it is the 11811 # simplest approach to changing $(DEPDIR) to its actual value in the 11812 # expansion. 11813 for file in `sed -n " 11814 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 11815 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do 11816 # Make sure the directory exists. 11817 test -f "$dirpart/$file" && continue 11818 fdir=`AS_DIRNAME(["$file"])` 11819 AS_MKDIR_P([$dirpart/$fdir]) 11820 # echo "creating $dirpart/$file" 11821 echo '# dummy' > "$dirpart/$file" 11822 done 11823 done 11824} 11825])# _AM_OUTPUT_DEPENDENCY_COMMANDS 11826 11827 11828# AM_OUTPUT_DEPENDENCY_COMMANDS 11829# ----------------------------- 11830# This macro should only be invoked once -- use via AC_REQUIRE. 11831# 11832# This code is only required when automatic dependency tracking 11833# is enabled. FIXME. This creates each '.P' file that we will 11834# need in order to bootstrap the dependency handling code. 11835AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 11836[AC_CONFIG_COMMANDS([depfiles], 11837 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 11838 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 11839]) 11840 11841# Do all the work for Automake. -*- Autoconf -*- 11842 11843# Copyright (C) 1996-2013 Free Software Foundation, Inc. 11844# 11845# This file is free software; the Free Software Foundation 11846# gives unlimited permission to copy and/or distribute it, 11847# with or without modifications, as long as this notice is preserved. 11848 11849# This macro actually does too much. Some checks are only needed if 11850# your package does certain things. But this isn't really a big deal. 11851 11852dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. 11853m4_define([AC_PROG_CC], 11854m4_defn([AC_PROG_CC]) 11855[_AM_PROG_CC_C_O 11856]) 11857 11858# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 11859# AM_INIT_AUTOMAKE([OPTIONS]) 11860# ----------------------------------------------- 11861# The call with PACKAGE and VERSION arguments is the old style 11862# call (pre autoconf-2.50), which is being phased out. PACKAGE 11863# and VERSION should now be passed to AC_INIT and removed from 11864# the call to AM_INIT_AUTOMAKE. 11865# We support both call styles for the transition. After 11866# the next Automake release, Autoconf can make the AC_INIT 11867# arguments mandatory, and then we can depend on a new Autoconf 11868# release and drop the old call support. 11869AC_DEFUN([AM_INIT_AUTOMAKE], 11870[AC_PREREQ([2.65])dnl 11871dnl Autoconf wants to disallow AM_ names. We explicitly allow 11872dnl the ones we care about. 11873m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 11874AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 11875AC_REQUIRE([AC_PROG_INSTALL])dnl 11876if test "`cd $srcdir && pwd`" != "`pwd`"; then 11877 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 11878 # is not polluted with repeated "-I." 11879 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 11880 # test to see if srcdir already configured 11881 if test -f $srcdir/config.status; then 11882 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 11883 fi 11884fi 11885 11886# test whether we have cygpath 11887if test -z "$CYGPATH_W"; then 11888 if (cygpath --version) >/dev/null 2>/dev/null; then 11889 CYGPATH_W='cygpath -w' 11890 else 11891 CYGPATH_W=echo 11892 fi 11893fi 11894AC_SUBST([CYGPATH_W]) 11895 11896# Define the identity of the package. 11897dnl Distinguish between old-style and new-style calls. 11898m4_ifval([$2], 11899[AC_DIAGNOSE([obsolete], 11900 [$0: two- and three-arguments forms are deprecated.]) 11901m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 11902 AC_SUBST([PACKAGE], [$1])dnl 11903 AC_SUBST([VERSION], [$2])], 11904[_AM_SET_OPTIONS([$1])dnl 11905dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 11906m4_if( 11907 m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), 11908 [ok:ok],, 11909 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 11910 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 11911 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 11912 11913_AM_IF_OPTION([no-define],, 11914[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) 11915 AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl 11916 11917# Some tools Automake needs. 11918AC_REQUIRE([AM_SANITY_CHECK])dnl 11919AC_REQUIRE([AC_ARG_PROGRAM])dnl 11920AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) 11921AM_MISSING_PROG([AUTOCONF], [autoconf]) 11922AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) 11923AM_MISSING_PROG([AUTOHEADER], [autoheader]) 11924AM_MISSING_PROG([MAKEINFO], [makeinfo]) 11925AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 11926AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 11927AC_REQUIRE([AC_PROG_MKDIR_P])dnl 11928# For better backward compatibility. To be removed once Automake 1.9.x 11929# dies out for good. For more background, see: 11930# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> 11931# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> 11932AC_SUBST([mkdir_p], ['$(MKDIR_P)']) 11933# We need awk for the "check" target. The system "awk" is bad on 11934# some platforms. 11935AC_REQUIRE([AC_PROG_AWK])dnl 11936AC_REQUIRE([AC_PROG_MAKE_SET])dnl 11937AC_REQUIRE([AM_SET_LEADING_DOT])dnl 11938_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 11939 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 11940 [_AM_PROG_TAR([v7])])]) 11941_AM_IF_OPTION([no-dependencies],, 11942[AC_PROVIDE_IFELSE([AC_PROG_CC], 11943 [_AM_DEPENDENCIES([CC])], 11944 [m4_define([AC_PROG_CC], 11945 m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl 11946AC_PROVIDE_IFELSE([AC_PROG_CXX], 11947 [_AM_DEPENDENCIES([CXX])], 11948 [m4_define([AC_PROG_CXX], 11949 m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl 11950AC_PROVIDE_IFELSE([AC_PROG_OBJC], 11951 [_AM_DEPENDENCIES([OBJC])], 11952 [m4_define([AC_PROG_OBJC], 11953 m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl 11954AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], 11955 [_AM_DEPENDENCIES([OBJCXX])], 11956 [m4_define([AC_PROG_OBJCXX], 11957 m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl 11958]) 11959AC_REQUIRE([AM_SILENT_RULES])dnl 11960dnl The testsuite driver may need to know about EXEEXT, so add the 11961dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This 11962dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. 11963AC_CONFIG_COMMANDS_PRE(dnl 11964[m4_provide_if([_AM_COMPILER_EXEEXT], 11965 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 11966 11967# POSIX will say in a future version that running "rm -f" with no argument 11968# is OK; and we want to be able to make that assumption in our Makefile 11969# recipes. So use an aggressive probe to check that the usage we want is 11970# actually supported "in the wild" to an acceptable degree. 11971# See automake bug#10828. 11972# To make any issue more visible, cause the running configure to be aborted 11973# by default if the 'rm' program in use doesn't match our expectations; the 11974# user can still override this though. 11975if rm -f && rm -fr && rm -rf; then : OK; else 11976 cat >&2 <<'END' 11977Oops! 11978 11979Your 'rm' program seems unable to run without file operands specified 11980on the command line, even when the '-f' option is present. This is contrary 11981to the behaviour of most rm programs out there, and not conforming with 11982the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> 11983 11984Please tell bug-automake@gnu.org about your system, including the value 11985of your $PATH and any error possibly output before this message. This 11986can help us improve future automake versions. 11987 11988END 11989 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then 11990 echo 'Configuration will proceed anyway, since you have set the' >&2 11991 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 11992 echo >&2 11993 else 11994 cat >&2 <<'END' 11995Aborting the configuration process, to ensure you take notice of the issue. 11996 11997You can download and install GNU coreutils to get an 'rm' implementation 11998that behaves properly: <http://www.gnu.org/software/coreutils/>. 11999 12000If you want to complete the configuration process using your problematic 12001'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM 12002to "yes", and re-run configure. 12003 12004END 12005 AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) 12006 fi 12007fi]) 12008 12009dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 12010dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 12011dnl mangled by Autoconf and run in a shell conditional statement. 12012m4_define([_AC_COMPILER_EXEEXT], 12013m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 12014 12015# When config.status generates a header, we must update the stamp-h file. 12016# This file resides in the same directory as the config header 12017# that is generated. The stamp files are numbered to have different names. 12018 12019# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 12020# loop where config.status creates the headers, so we can generate 12021# our stamp files there. 12022AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 12023[# Compute $1's index in $config_headers. 12024_am_arg=$1 12025_am_stamp_count=1 12026for _am_header in $config_headers :; do 12027 case $_am_header in 12028 $_am_arg | $_am_arg:* ) 12029 break ;; 12030 * ) 12031 _am_stamp_count=`expr $_am_stamp_count + 1` ;; 12032 esac 12033done 12034echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 12035 12036# Copyright (C) 2001-2013 Free Software Foundation, Inc. 12037# 12038# This file is free software; the Free Software Foundation 12039# gives unlimited permission to copy and/or distribute it, 12040# with or without modifications, as long as this notice is preserved. 12041 12042# AM_PROG_INSTALL_SH 12043# ------------------ 12044# Define $install_sh. 12045AC_DEFUN([AM_PROG_INSTALL_SH], 12046[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 12047if test x"${install_sh}" != xset; then 12048 case $am_aux_dir in 12049 *\ * | *\ *) 12050 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 12051 *) 12052 install_sh="\${SHELL} $am_aux_dir/install-sh" 12053 esac 12054fi 12055AC_SUBST([install_sh])]) 12056 12057# Copyright (C) 2003-2013 Free Software Foundation, Inc. 12058# 12059# This file is free software; the Free Software Foundation 12060# gives unlimited permission to copy and/or distribute it, 12061# with or without modifications, as long as this notice is preserved. 12062 12063# Check whether the underlying file-system supports filenames 12064# with a leading dot. For instance MS-DOS doesn't. 12065AC_DEFUN([AM_SET_LEADING_DOT], 12066[rm -rf .tst 2>/dev/null 12067mkdir .tst 2>/dev/null 12068if test -d .tst; then 12069 am__leading_dot=. 12070else 12071 am__leading_dot=_ 12072fi 12073rmdir .tst 2>/dev/null 12074AC_SUBST([am__leading_dot])]) 12075 12076# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- 12077# From Jim Meyering 12078 12079# Copyright (C) 1996-2013 Free Software Foundation, Inc. 12080# 12081# This file is free software; the Free Software Foundation 12082# gives unlimited permission to copy and/or distribute it, 12083# with or without modifications, as long as this notice is preserved. 12084 12085# AM_MAINTAINER_MODE([DEFAULT-MODE]) 12086# ---------------------------------- 12087# Control maintainer-specific portions of Makefiles. 12088# Default is to disable them, unless 'enable' is passed literally. 12089# For symmetry, 'disable' may be passed as well. Anyway, the user 12090# can override the default with the --enable/--disable switch. 12091AC_DEFUN([AM_MAINTAINER_MODE], 12092[m4_case(m4_default([$1], [disable]), 12093 [enable], [m4_define([am_maintainer_other], [disable])], 12094 [disable], [m4_define([am_maintainer_other], [enable])], 12095 [m4_define([am_maintainer_other], [enable]) 12096 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) 12097AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) 12098 dnl maintainer-mode's default is 'disable' unless 'enable' is passed 12099 AC_ARG_ENABLE([maintainer-mode], 12100 [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode], 12101 am_maintainer_other[ make rules and dependencies not useful 12102 (and sometimes confusing) to the casual installer])], 12103 [USE_MAINTAINER_MODE=$enableval], 12104 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) 12105 AC_MSG_RESULT([$USE_MAINTAINER_MODE]) 12106 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) 12107 MAINT=$MAINTAINER_MODE_TRUE 12108 AC_SUBST([MAINT])dnl 12109] 12110) 12111 12112# Check to see how 'make' treats includes. -*- Autoconf -*- 12113 12114# Copyright (C) 2001-2013 Free Software Foundation, Inc. 12115# 12116# This file is free software; the Free Software Foundation 12117# gives unlimited permission to copy and/or distribute it, 12118# with or without modifications, as long as this notice is preserved. 12119 12120# AM_MAKE_INCLUDE() 12121# ----------------- 12122# Check to see how make treats includes. 12123AC_DEFUN([AM_MAKE_INCLUDE], 12124[am_make=${MAKE-make} 12125cat > confinc << 'END' 12126am__doit: 12127 @echo this is the am__doit target 12128.PHONY: am__doit 12129END 12130# If we don't find an include directive, just comment out the code. 12131AC_MSG_CHECKING([for style of include used by $am_make]) 12132am__include="#" 12133am__quote= 12134_am_result=none 12135# First try GNU make style include. 12136echo "include confinc" > confmf 12137# Ignore all kinds of additional output from 'make'. 12138case `$am_make -s -f confmf 2> /dev/null` in #( 12139*the\ am__doit\ target*) 12140 am__include=include 12141 am__quote= 12142 _am_result=GNU 12143 ;; 12144esac 12145# Now try BSD make style include. 12146if test "$am__include" = "#"; then 12147 echo '.include "confinc"' > confmf 12148 case `$am_make -s -f confmf 2> /dev/null` in #( 12149 *the\ am__doit\ target*) 12150 am__include=.include 12151 am__quote="\"" 12152 _am_result=BSD 12153 ;; 12154 esac 12155fi 12156AC_SUBST([am__include]) 12157AC_SUBST([am__quote]) 12158AC_MSG_RESULT([$_am_result]) 12159rm -f confinc confmf 12160]) 12161 12162# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 12163 12164# Copyright (C) 1997-2013 Free Software Foundation, Inc. 12165# 12166# This file is free software; the Free Software Foundation 12167# gives unlimited permission to copy and/or distribute it, 12168# with or without modifications, as long as this notice is preserved. 12169 12170# AM_MISSING_PROG(NAME, PROGRAM) 12171# ------------------------------ 12172AC_DEFUN([AM_MISSING_PROG], 12173[AC_REQUIRE([AM_MISSING_HAS_RUN]) 12174$1=${$1-"${am_missing_run}$2"} 12175AC_SUBST($1)]) 12176 12177# AM_MISSING_HAS_RUN 12178# ------------------ 12179# Define MISSING if not defined so far and test if it is modern enough. 12180# If it is, set am_missing_run to use it, otherwise, to nothing. 12181AC_DEFUN([AM_MISSING_HAS_RUN], 12182[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 12183AC_REQUIRE_AUX_FILE([missing])dnl 12184if test x"${MISSING+set}" != xset; then 12185 case $am_aux_dir in 12186 *\ * | *\ *) 12187 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; 12188 *) 12189 MISSING="\${SHELL} $am_aux_dir/missing" ;; 12190 esac 12191fi 12192# Use eval to expand $SHELL 12193if eval "$MISSING --is-lightweight"; then 12194 am_missing_run="$MISSING " 12195else 12196 am_missing_run= 12197 AC_MSG_WARN(['missing' script is too old or missing]) 12198fi 12199]) 12200 12201# Helper functions for option handling. -*- Autoconf -*- 12202 12203# Copyright (C) 2001-2013 Free Software Foundation, Inc. 12204# 12205# This file is free software; the Free Software Foundation 12206# gives unlimited permission to copy and/or distribute it, 12207# with or without modifications, as long as this notice is preserved. 12208 12209# _AM_MANGLE_OPTION(NAME) 12210# ----------------------- 12211AC_DEFUN([_AM_MANGLE_OPTION], 12212[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 12213 12214# _AM_SET_OPTION(NAME) 12215# -------------------- 12216# Set option NAME. Presently that only means defining a flag for this option. 12217AC_DEFUN([_AM_SET_OPTION], 12218[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) 12219 12220# _AM_SET_OPTIONS(OPTIONS) 12221# ------------------------ 12222# OPTIONS is a space-separated list of Automake options. 12223AC_DEFUN([_AM_SET_OPTIONS], 12224[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 12225 12226# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 12227# ------------------------------------------- 12228# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 12229AC_DEFUN([_AM_IF_OPTION], 12230[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 12231 12232# Copyright (C) 1999-2013 Free Software Foundation, Inc. 12233# 12234# This file is free software; the Free Software Foundation 12235# gives unlimited permission to copy and/or distribute it, 12236# with or without modifications, as long as this notice is preserved. 12237 12238# _AM_PROG_CC_C_O 12239# --------------- 12240# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC 12241# to automatically call this. 12242AC_DEFUN([_AM_PROG_CC_C_O], 12243[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 12244AC_REQUIRE_AUX_FILE([compile])dnl 12245AC_LANG_PUSH([C])dnl 12246AC_CACHE_CHECK( 12247 [whether $CC understands -c and -o together], 12248 [am_cv_prog_cc_c_o], 12249 [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) 12250 # Make sure it works both with $CC and with simple cc. 12251 # Following AC_PROG_CC_C_O, we do the test twice because some 12252 # compilers refuse to overwrite an existing .o file with -o, 12253 # though they will create one. 12254 am_cv_prog_cc_c_o=yes 12255 for am_i in 1 2; do 12256 if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ 12257 && test -f conftest2.$ac_objext; then 12258 : OK 12259 else 12260 am_cv_prog_cc_c_o=no 12261 break 12262 fi 12263 done 12264 rm -f core conftest* 12265 unset am_i]) 12266if test "$am_cv_prog_cc_c_o" != yes; then 12267 # Losing compiler, so override with the script. 12268 # FIXME: It is wrong to rewrite CC. 12269 # But if we don't then we get into trouble of one sort or another. 12270 # A longer-term fix would be to have automake use am__CC in this case, 12271 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" 12272 CC="$am_aux_dir/compile $CC" 12273fi 12274AC_LANG_POP([C])]) 12275 12276# For backward compatibility. 12277AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) 12278 12279# Copyright (C) 1999-2013 Free Software Foundation, Inc. 12280# 12281# This file is free software; the Free Software Foundation 12282# gives unlimited permission to copy and/or distribute it, 12283# with or without modifications, as long as this notice is preserved. 12284 12285 12286# AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 12287# --------------------------------------------------------------------------- 12288# Adds support for distributing Python modules and packages. To 12289# install modules, copy them to $(pythondir), using the python_PYTHON 12290# automake variable. To install a package with the same name as the 12291# automake package, install to $(pkgpythondir), or use the 12292# pkgpython_PYTHON automake variable. 12293# 12294# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as 12295# locations to install python extension modules (shared libraries). 12296# Another macro is required to find the appropriate flags to compile 12297# extension modules. 12298# 12299# If your package is configured with a different prefix to python, 12300# users will have to add the install directory to the PYTHONPATH 12301# environment variable, or create a .pth file (see the python 12302# documentation for details). 12303# 12304# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will 12305# cause an error if the version of python installed on the system 12306# doesn't meet the requirement. MINIMUM-VERSION should consist of 12307# numbers and dots only. 12308AC_DEFUN([AM_PATH_PYTHON], 12309 [ 12310 dnl Find a Python interpreter. Python versions prior to 2.0 are not 12311 dnl supported. (2.0 was released on October 16, 2000). 12312 m4_define_default([_AM_PYTHON_INTERPRETER_LIST], 12313[python python2 python3 python3.3 python3.2 python3.1 python3.0 python2.7 dnl 12314 python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0]) 12315 12316 AC_ARG_VAR([PYTHON], [the Python interpreter]) 12317 12318 m4_if([$1],[],[ 12319 dnl No version check is needed. 12320 # Find any Python interpreter. 12321 if test -z "$PYTHON"; then 12322 AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :) 12323 fi 12324 am_display_PYTHON=python 12325 ], [ 12326 dnl A version check is needed. 12327 if test -n "$PYTHON"; then 12328 # If the user set $PYTHON, use it and don't search something else. 12329 AC_MSG_CHECKING([whether $PYTHON version is >= $1]) 12330 AM_PYTHON_CHECK_VERSION([$PYTHON], [$1], 12331 [AC_MSG_RESULT([yes])], 12332 [AC_MSG_RESULT([no]) 12333 AC_MSG_ERROR([Python interpreter is too old])]) 12334 am_display_PYTHON=$PYTHON 12335 else 12336 # Otherwise, try each interpreter until we find one that satisfies 12337 # VERSION. 12338 AC_CACHE_CHECK([for a Python interpreter with version >= $1], 12339 [am_cv_pathless_PYTHON],[ 12340 for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do 12341 test "$am_cv_pathless_PYTHON" = none && break 12342 AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break]) 12343 done]) 12344 # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON. 12345 if test "$am_cv_pathless_PYTHON" = none; then 12346 PYTHON=: 12347 else 12348 AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON]) 12349 fi 12350 am_display_PYTHON=$am_cv_pathless_PYTHON 12351 fi 12352 ]) 12353 12354 if test "$PYTHON" = :; then 12355 dnl Run any user-specified action, or abort. 12356 m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])]) 12357 else 12358 12359 dnl Query Python for its version number. Getting [:3] seems to be 12360 dnl the best way to do this; it's what "site.py" does in the standard 12361 dnl library. 12362 12363 AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version], 12364 [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`]) 12365 AC_SUBST([PYTHON_VERSION], [$am_cv_python_version]) 12366 12367 dnl Use the values of $prefix and $exec_prefix for the corresponding 12368 dnl values of PYTHON_PREFIX and PYTHON_EXEC_PREFIX. These are made 12369 dnl distinct variables so they can be overridden if need be. However, 12370 dnl general consensus is that you shouldn't need this ability. 12371 12372 AC_SUBST([PYTHON_PREFIX], ['${prefix}']) 12373 AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}']) 12374 12375 dnl At times (like when building shared libraries) you may want 12376 dnl to know which OS platform Python thinks this is. 12377 12378 AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform], 12379 [am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`]) 12380 AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform]) 12381 12382 # Just factor out some code duplication. 12383 am_python_setup_sysconfig="\ 12384import sys 12385# Prefer sysconfig over distutils.sysconfig, for better compatibility 12386# with python 3.x. See automake bug#10227. 12387try: 12388 import sysconfig 12389except ImportError: 12390 can_use_sysconfig = 0 12391else: 12392 can_use_sysconfig = 1 12393# Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs: 12394# <https://github.com/pypa/virtualenv/issues/118> 12395try: 12396 from platform import python_implementation 12397 if python_implementation() == 'CPython' and sys.version[[:3]] == '2.7': 12398 can_use_sysconfig = 0 12399except ImportError: 12400 pass" 12401 12402 dnl Set up 4 directories: 12403 12404 dnl pythondir -- where to install python scripts. This is the 12405 dnl site-packages directory, not the python standard library 12406 dnl directory like in previous automake betas. This behavior 12407 dnl is more consistent with lispdir.m4 for example. 12408 dnl Query distutils for this directory. 12409 AC_CACHE_CHECK([for $am_display_PYTHON script directory], 12410 [am_cv_python_pythondir], 12411 [if test "x$prefix" = xNONE 12412 then 12413 am_py_prefix=$ac_default_prefix 12414 else 12415 am_py_prefix=$prefix 12416 fi 12417 am_cv_python_pythondir=`$PYTHON -c " 12418$am_python_setup_sysconfig 12419if can_use_sysconfig: 12420 sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'}) 12421else: 12422 from distutils import sysconfig 12423 sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix') 12424sys.stdout.write(sitedir)"` 12425 case $am_cv_python_pythondir in 12426 $am_py_prefix*) 12427 am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'` 12428 am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"` 12429 ;; 12430 *) 12431 case $am_py_prefix in 12432 /usr|/System*) ;; 12433 *) 12434 am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages 12435 ;; 12436 esac 12437 ;; 12438 esac 12439 ]) 12440 AC_SUBST([pythondir], [$am_cv_python_pythondir]) 12441 12442 dnl pkgpythondir -- $PACKAGE directory under pythondir. Was 12443 dnl PYTHON_SITE_PACKAGE in previous betas, but this naming is 12444 dnl more consistent with the rest of automake. 12445 12446 AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE]) 12447 12448 dnl pyexecdir -- directory for installing python extension modules 12449 dnl (shared libraries) 12450 dnl Query distutils for this directory. 12451 AC_CACHE_CHECK([for $am_display_PYTHON extension module directory], 12452 [am_cv_python_pyexecdir], 12453 [if test "x$exec_prefix" = xNONE 12454 then 12455 am_py_exec_prefix=$am_py_prefix 12456 else 12457 am_py_exec_prefix=$exec_prefix 12458 fi 12459 am_cv_python_pyexecdir=`$PYTHON -c " 12460$am_python_setup_sysconfig 12461if can_use_sysconfig: 12462 sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_prefix'}) 12463else: 12464 from distutils import sysconfig 12465 sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_prefix') 12466sys.stdout.write(sitedir)"` 12467 case $am_cv_python_pyexecdir in 12468 $am_py_exec_prefix*) 12469 am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'` 12470 am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"` 12471 ;; 12472 *) 12473 case $am_py_exec_prefix in 12474 /usr|/System*) ;; 12475 *) 12476 am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages 12477 ;; 12478 esac 12479 ;; 12480 esac 12481 ]) 12482 AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir]) 12483 12484 dnl pkgpyexecdir -- $(pyexecdir)/$(PACKAGE) 12485 12486 AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE]) 12487 12488 dnl Run any user-specified action. 12489 $2 12490 fi 12491 12492]) 12493 12494 12495# AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE]) 12496# --------------------------------------------------------------------------- 12497# Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION. 12498# Run ACTION-IF-FALSE otherwise. 12499# This test uses sys.hexversion instead of the string equivalent (first 12500# word of sys.version), in order to cope with versions such as 2.2c1. 12501# This supports Python 2.0 or higher. (2.0 was released on October 16, 2000). 12502AC_DEFUN([AM_PYTHON_CHECK_VERSION], 12503 [prog="import sys 12504# split strings by '.' and convert to numeric. Append some zeros 12505# because we need at least 4 digits for the hex conversion. 12506# map returns an iterator in Python 3.0 and a list in 2.x 12507minver = list(map(int, '$2'.split('.'))) + [[0, 0, 0]] 12508minverhex = 0 12509# xrange is not present in Python 3.0 and range returns an iterator 12510for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[[i]] 12511sys.exit(sys.hexversion < minverhex)" 12512 AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])]) 12513 12514# Copyright (C) 2001-2013 Free Software Foundation, Inc. 12515# 12516# This file is free software; the Free Software Foundation 12517# gives unlimited permission to copy and/or distribute it, 12518# with or without modifications, as long as this notice is preserved. 12519 12520# AM_RUN_LOG(COMMAND) 12521# ------------------- 12522# Run COMMAND, save the exit status in ac_status, and log it. 12523# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) 12524AC_DEFUN([AM_RUN_LOG], 12525[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD 12526 ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD 12527 ac_status=$? 12528 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 12529 (exit $ac_status); }]) 12530 12531# Check to make sure that the build environment is sane. -*- Autoconf -*- 12532 12533# Copyright (C) 1996-2013 Free Software Foundation, Inc. 12534# 12535# This file is free software; the Free Software Foundation 12536# gives unlimited permission to copy and/or distribute it, 12537# with or without modifications, as long as this notice is preserved. 12538 12539# AM_SANITY_CHECK 12540# --------------- 12541AC_DEFUN([AM_SANITY_CHECK], 12542[AC_MSG_CHECKING([whether build environment is sane]) 12543# Reject unsafe characters in $srcdir or the absolute working directory 12544# name. Accept space and tab only in the latter. 12545am_lf=' 12546' 12547case `pwd` in 12548 *[[\\\"\#\$\&\'\`$am_lf]]*) 12549 AC_MSG_ERROR([unsafe absolute working directory name]);; 12550esac 12551case $srcdir in 12552 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 12553 AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; 12554esac 12555 12556# Do 'set' in a subshell so we don't clobber the current shell's 12557# arguments. Must try -L first in case configure is actually a 12558# symlink; some systems play weird games with the mod time of symlinks 12559# (eg FreeBSD returns the mod time of the symlink's containing 12560# directory). 12561if ( 12562 am_has_slept=no 12563 for am_try in 1 2; do 12564 echo "timestamp, slept: $am_has_slept" > conftest.file 12565 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 12566 if test "$[*]" = "X"; then 12567 # -L didn't work. 12568 set X `ls -t "$srcdir/configure" conftest.file` 12569 fi 12570 if test "$[*]" != "X $srcdir/configure conftest.file" \ 12571 && test "$[*]" != "X conftest.file $srcdir/configure"; then 12572 12573 # If neither matched, then we have a broken ls. This can happen 12574 # if, for instance, CONFIG_SHELL is bash and it inherits a 12575 # broken ls alias from the environment. This has actually 12576 # happened. Such a system could not be considered "sane". 12577 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 12578 alias in your environment]) 12579 fi 12580 if test "$[2]" = conftest.file || test $am_try -eq 2; then 12581 break 12582 fi 12583 # Just in case. 12584 sleep 1 12585 am_has_slept=yes 12586 done 12587 test "$[2]" = conftest.file 12588 ) 12589then 12590 # Ok. 12591 : 12592else 12593 AC_MSG_ERROR([newly created file is older than distributed files! 12594Check your system clock]) 12595fi 12596AC_MSG_RESULT([yes]) 12597# If we didn't sleep, we still need to ensure time stamps of config.status and 12598# generated files are strictly newer. 12599am_sleep_pid= 12600if grep 'slept: no' conftest.file >/dev/null 2>&1; then 12601 ( sleep 1 ) & 12602 am_sleep_pid=$! 12603fi 12604AC_CONFIG_COMMANDS_PRE( 12605 [AC_MSG_CHECKING([that generated files are newer than configure]) 12606 if test -n "$am_sleep_pid"; then 12607 # Hide warnings about reused PIDs. 12608 wait $am_sleep_pid 2>/dev/null 12609 fi 12610 AC_MSG_RESULT([done])]) 12611rm -f conftest.file 12612]) 12613 12614# Copyright (C) 2009-2013 Free Software Foundation, Inc. 12615# 12616# This file is free software; the Free Software Foundation 12617# gives unlimited permission to copy and/or distribute it, 12618# with or without modifications, as long as this notice is preserved. 12619 12620# AM_SILENT_RULES([DEFAULT]) 12621# -------------------------- 12622# Enable less verbose build rules; with the default set to DEFAULT 12623# ("yes" being less verbose, "no" or empty being verbose). 12624AC_DEFUN([AM_SILENT_RULES], 12625[AC_ARG_ENABLE([silent-rules], [dnl 12626AS_HELP_STRING( 12627 [--enable-silent-rules], 12628 [less verbose build output (undo: "make V=1")]) 12629AS_HELP_STRING( 12630 [--disable-silent-rules], 12631 [verbose build output (undo: "make V=0")])dnl 12632]) 12633case $enable_silent_rules in @%:@ ((( 12634 yes) AM_DEFAULT_VERBOSITY=0;; 12635 no) AM_DEFAULT_VERBOSITY=1;; 12636 *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; 12637esac 12638dnl 12639dnl A few 'make' implementations (e.g., NonStop OS and NextStep) 12640dnl do not support nested variable expansions. 12641dnl See automake bug#9928 and bug#10237. 12642am_make=${MAKE-make} 12643AC_CACHE_CHECK([whether $am_make supports nested variables], 12644 [am_cv_make_support_nested_variables], 12645 [if AS_ECHO([['TRUE=$(BAR$(V)) 12646BAR0=false 12647BAR1=true 12648V=1 12649am__doit: 12650 @$(TRUE) 12651.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then 12652 am_cv_make_support_nested_variables=yes 12653else 12654 am_cv_make_support_nested_variables=no 12655fi]) 12656if test $am_cv_make_support_nested_variables = yes; then 12657 dnl Using '$V' instead of '$(V)' breaks IRIX make. 12658 AM_V='$(V)' 12659 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' 12660else 12661 AM_V=$AM_DEFAULT_VERBOSITY 12662 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY 12663fi 12664AC_SUBST([AM_V])dnl 12665AM_SUBST_NOTMAKE([AM_V])dnl 12666AC_SUBST([AM_DEFAULT_V])dnl 12667AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl 12668AC_SUBST([AM_DEFAULT_VERBOSITY])dnl 12669AM_BACKSLASH='\' 12670AC_SUBST([AM_BACKSLASH])dnl 12671_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl 12672]) 12673 12674# Copyright (C) 2001-2013 Free Software Foundation, Inc. 12675# 12676# This file is free software; the Free Software Foundation 12677# gives unlimited permission to copy and/or distribute it, 12678# with or without modifications, as long as this notice is preserved. 12679 12680# AM_PROG_INSTALL_STRIP 12681# --------------------- 12682# One issue with vendor 'install' (even GNU) is that you can't 12683# specify the program used to strip binaries. This is especially 12684# annoying in cross-compiling environments, where the build's strip 12685# is unlikely to handle the host's binaries. 12686# Fortunately install-sh will honor a STRIPPROG variable, so we 12687# always use install-sh in "make install-strip", and initialize 12688# STRIPPROG with the value of the STRIP variable (set by the user). 12689AC_DEFUN([AM_PROG_INSTALL_STRIP], 12690[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 12691# Installed binaries are usually stripped using 'strip' when the user 12692# run "make install-strip". However 'strip' might not be the right 12693# tool to use in cross-compilation environments, therefore Automake 12694# will honor the 'STRIP' environment variable to overrule this program. 12695dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. 12696if test "$cross_compiling" != no; then 12697 AC_CHECK_TOOL([STRIP], [strip], :) 12698fi 12699INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 12700AC_SUBST([INSTALL_STRIP_PROGRAM])]) 12701 12702# Copyright (C) 2006-2013 Free Software Foundation, Inc. 12703# 12704# This file is free software; the Free Software Foundation 12705# gives unlimited permission to copy and/or distribute it, 12706# with or without modifications, as long as this notice is preserved. 12707 12708# _AM_SUBST_NOTMAKE(VARIABLE) 12709# --------------------------- 12710# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 12711# This macro is traced by Automake. 12712AC_DEFUN([_AM_SUBST_NOTMAKE]) 12713 12714# AM_SUBST_NOTMAKE(VARIABLE) 12715# -------------------------- 12716# Public sister of _AM_SUBST_NOTMAKE. 12717AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 12718 12719# Check how to create a tarball. -*- Autoconf -*- 12720 12721# Copyright (C) 2004-2013 Free Software Foundation, Inc. 12722# 12723# This file is free software; the Free Software Foundation 12724# gives unlimited permission to copy and/or distribute it, 12725# with or without modifications, as long as this notice is preserved. 12726 12727# _AM_PROG_TAR(FORMAT) 12728# -------------------- 12729# Check how to create a tarball in format FORMAT. 12730# FORMAT should be one of 'v7', 'ustar', or 'pax'. 12731# 12732# Substitute a variable $(am__tar) that is a command 12733# writing to stdout a FORMAT-tarball containing the directory 12734# $tardir. 12735# tardir=directory && $(am__tar) > result.tar 12736# 12737# Substitute a variable $(am__untar) that extract such 12738# a tarball read from stdin. 12739# $(am__untar) < result.tar 12740# 12741AC_DEFUN([_AM_PROG_TAR], 12742[# Always define AMTAR for backward compatibility. Yes, it's still used 12743# in the wild :-( We should find a proper way to deprecate it ... 12744AC_SUBST([AMTAR], ['$${TAR-tar}']) 12745 12746# We'll loop over all known methods to create a tar archive until one works. 12747_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 12748 12749m4_if([$1], [v7], 12750 [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], 12751 12752 [m4_case([$1], 12753 [ustar], 12754 [# The POSIX 1988 'ustar' format is defined with fixed-size fields. 12755 # There is notably a 21 bits limit for the UID and the GID. In fact, 12756 # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 12757 # and bug#13588). 12758 am_max_uid=2097151 # 2^21 - 1 12759 am_max_gid=$am_max_uid 12760 # The $UID and $GID variables are not portable, so we need to resort 12761 # to the POSIX-mandated id(1) utility. Errors in the 'id' calls 12762 # below are definitely unexpected, so allow the users to see them 12763 # (that is, avoid stderr redirection). 12764 am_uid=`id -u || echo unknown` 12765 am_gid=`id -g || echo unknown` 12766 AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) 12767 if test $am_uid -le $am_max_uid; then 12768 AC_MSG_RESULT([yes]) 12769 else 12770 AC_MSG_RESULT([no]) 12771 _am_tools=none 12772 fi 12773 AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) 12774 if test $am_gid -le $am_max_gid; then 12775 AC_MSG_RESULT([yes]) 12776 else 12777 AC_MSG_RESULT([no]) 12778 _am_tools=none 12779 fi], 12780 12781 [pax], 12782 [], 12783 12784 [m4_fatal([Unknown tar format])]) 12785 12786 AC_MSG_CHECKING([how to create a $1 tar archive]) 12787 12788 # Go ahead even if we have the value already cached. We do so because we 12789 # need to set the values for the 'am__tar' and 'am__untar' variables. 12790 _am_tools=${am_cv_prog_tar_$1-$_am_tools} 12791 12792 for _am_tool in $_am_tools; do 12793 case $_am_tool in 12794 gnutar) 12795 for _am_tar in tar gnutar gtar; do 12796 AM_RUN_LOG([$_am_tar --version]) && break 12797 done 12798 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 12799 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 12800 am__untar="$_am_tar -xf -" 12801 ;; 12802 plaintar) 12803 # Must skip GNU tar: if it does not support --format= it doesn't create 12804 # ustar tarball either. 12805 (tar --version) >/dev/null 2>&1 && continue 12806 am__tar='tar chf - "$$tardir"' 12807 am__tar_='tar chf - "$tardir"' 12808 am__untar='tar xf -' 12809 ;; 12810 pax) 12811 am__tar='pax -L -x $1 -w "$$tardir"' 12812 am__tar_='pax -L -x $1 -w "$tardir"' 12813 am__untar='pax -r' 12814 ;; 12815 cpio) 12816 am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 12817 am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 12818 am__untar='cpio -i -H $1 -d' 12819 ;; 12820 none) 12821 am__tar=false 12822 am__tar_=false 12823 am__untar=false 12824 ;; 12825 esac 12826 12827 # If the value was cached, stop now. We just wanted to have am__tar 12828 # and am__untar set. 12829 test -n "${am_cv_prog_tar_$1}" && break 12830 12831 # tar/untar a dummy directory, and stop if the command works. 12832 rm -rf conftest.dir 12833 mkdir conftest.dir 12834 echo GrepMe > conftest.dir/file 12835 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 12836 rm -rf conftest.dir 12837 if test -s conftest.tar; then 12838 AM_RUN_LOG([$am__untar <conftest.tar]) 12839 AM_RUN_LOG([cat conftest.dir/file]) 12840 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 12841 fi 12842 done 12843 rm -rf conftest.dir 12844 12845 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 12846 AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 12847 12848AC_SUBST([am__tar]) 12849AC_SUBST([am__untar]) 12850]) # _AM_PROG_TAR 12851 12852