1 # generated automatically by aclocal 1.10.1 -*- Autoconf -*-
3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
4 # 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
5 # This file is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
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
14 m4_ifndef([AC_AUTOCONF_VERSION],
15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16 m4_if(AC_AUTOCONF_VERSION, [2.61],,
17 [m4_warning([this file was generated for autoconf 2.61.
18 You have another version of autoconf. It may work, but is not guaranteed to.
19 If you have problems, you may need to regenerate the build system entirely.
20 To do so, use the procedure documented by the package, typically `autoreconf'.])])
22 # Copyright (C) 1995-2002 Free Software Foundation, Inc.
23 # Copyright (C) 2001-2003,2004 Red Hat, Inc.
25 # This file is free software, distributed under the terms of the GNU
26 # General Public License. As a special exception to the GNU General
27 # Public License, this file may be distributed as part of a program
28 # that contains a configuration script generated by Autoconf, under
29 # the same distribution terms as the rest of that program.
31 # This file can be copied and used freely without restrictions. It can
32 # be used in projects which are not available under the GNU Public License
33 # but which still want to provide support for the GNU gettext functionality.
35 # Macro to add for using GNU gettext.
36 # Ulrich Drepper <drepper@cygnus.com>, 1995, 1996
38 # Modified to never use included libintl.
39 # Owen Taylor <otaylor@redhat.com>, 12/15/1998
41 # Major rework to remove unused code
42 # Owen Taylor <otaylor@redhat.com>, 12/11/2002
44 # Added better handling of ALL_LINGUAS from GNU gettext version
45 # written by Bruno Haible, Owen Taylor <otaylor.redhat.com> 5/30/3002
47 # Modified to require ngettext
48 # Matthias Clasen <mclasen@redhat.com> 08/06/2004
50 # We need this here as well, since someone might use autoconf-2.5x
51 # to configure GLib then an older version to configure a package
52 # using AM_GLIB_GNU_GETTEXT
56 dnl We go to great lengths to make sure that aclocal won't
57 dnl try to pull in the installed version of these macros
58 dnl when running aclocal in the glib directory.
60 m4_copy([AC_DEFUN],[glib_DEFUN])
61 m4_copy([AC_REQUIRE],[glib_REQUIRE])
63 dnl At the end, if we're not within glib, we'll define the public
64 dnl definitions in terms of our private definitions.
69 glib_DEFUN([GLIB_LC_MESSAGES],
70 [AC_CHECK_HEADERS([locale.h])
71 if test $ac_cv_header_locale_h = yes; then
72 AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
73 [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
74 am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
75 if test $am_cv_val_LC_MESSAGES = yes; then
76 AC_DEFINE(HAVE_LC_MESSAGES, 1,
77 [Define if your <locale.h> file defines LC_MESSAGES.])
81 # GLIB_PATH_PROG_WITH_TEST
82 #----------------------------
83 dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
84 dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
85 glib_DEFUN([GLIB_PATH_PROG_WITH_TEST],
86 [# Extract the first word of "$2", so it can be a program name with args.
87 set dummy $2; ac_word=[$]2
88 AC_MSG_CHECKING([for $ac_word])
89 AC_CACHE_VAL(ac_cv_path_$1,
92 ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
95 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
96 for ac_dir in ifelse([$5], , $PATH, [$5]); do
97 test -z "$ac_dir" && ac_dir=.
98 if test -f $ac_dir/$ac_word; then
100 ac_cv_path_$1="$ac_dir/$ac_word"
106 dnl If no 4th arg is given, leave the cache variable unset,
107 dnl so AC_PATH_PROGS will keep looking.
108 ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
113 if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
123 glib_DEFUN([GLIB_WITH_NLS],
124 dnl NLS is obligatory
128 gt_cv_have_gettext=no
134 AC_CHECK_HEADER(libintl.h,
135 [gt_cv_func_dgettext_libintl="no"
136 libintl_extra_libs=""
139 # First check in libc
141 AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc,
145 [return !ngettext ("","", 1)],
146 gt_cv_func_ngettext_libc=yes,
147 gt_cv_func_ngettext_libc=no)
150 if test "$gt_cv_func_ngettext_libc" = "yes" ; then
151 AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc,
155 [return !dgettext ("","")],
156 gt_cv_func_dgettext_libc=yes,
157 gt_cv_func_dgettext_libc=no)
161 if test "$gt_cv_func_ngettext_libc" = "yes" ; then
162 AC_CHECK_FUNCS(bind_textdomain_codeset)
166 # If we don't have everything we want, check in libintl
168 if test "$gt_cv_func_dgettext_libc" != "yes" \
169 || test "$gt_cv_func_ngettext_libc" != "yes" \
170 || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then
172 AC_CHECK_LIB(intl, bindtextdomain,
173 [AC_CHECK_LIB(intl, ngettext,
174 [AC_CHECK_LIB(intl, dgettext,
175 gt_cv_func_dgettext_libintl=yes)])])
177 if test "$gt_cv_func_dgettext_libintl" != "yes" ; then
178 AC_MSG_CHECKING([if -liconv is needed to use gettext])
180 AC_CHECK_LIB(intl, ngettext,
181 [AC_CHECK_LIB(intl, dcgettext,
182 [gt_cv_func_dgettext_libintl=yes
183 libintl_extra_libs=-liconv],
189 # If we found libintl, then check in it for bind_textdomain_codeset();
190 # we'll prefer libc if neither have bind_textdomain_codeset(),
191 # and both have dgettext and ngettext
193 if test "$gt_cv_func_dgettext_libintl" = "yes" ; then
194 glib_save_LIBS="$LIBS"
195 LIBS="$LIBS -lintl $libintl_extra_libs"
196 unset ac_cv_func_bind_textdomain_codeset
197 AC_CHECK_FUNCS(bind_textdomain_codeset)
198 LIBS="$glib_save_LIBS"
200 if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then
201 gt_cv_func_dgettext_libc=no
203 if test "$gt_cv_func_dgettext_libc" = "yes" \
204 && test "$gt_cv_func_ngettext_libc" = "yes"; then
205 gt_cv_func_dgettext_libintl=no
211 if test "$gt_cv_func_dgettext_libc" = "yes" \
212 || test "$gt_cv_func_dgettext_libintl" = "yes"; then
213 gt_cv_have_gettext=yes
216 if test "$gt_cv_func_dgettext_libintl" = "yes"; then
217 INTLLIBS="-lintl $libintl_extra_libs"
220 if test "$gt_cv_have_gettext" = "yes"; then
221 AC_DEFINE(HAVE_GETTEXT,1,
222 [Define if the GNU gettext() function is already present or preinstalled.])
223 GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
224 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
225 if test "$MSGFMT" != "no"; then
226 glib_save_LIBS="$LIBS"
227 LIBS="$LIBS $INTLLIBS"
228 AC_CHECK_FUNCS(dcgettext)
230 AC_MSG_CHECKING([if msgfmt accepts -c])
231 GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[
234 "Content-Type: text/plain; charset=UTF-8\n"
235 "Project-Id-Version: test 1.0\n"
236 "PO-Revision-Date: 2007-02-15 12:01+0100\n"
237 "Last-Translator: test <foo@bar.xx>\n"
238 "Language-Team: C <LL@li.org>\n"
239 "MIME-Version: 1.0\n"
240 "Content-Transfer-Encoding: 8bit\n"
241 ], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])])
242 AC_SUBST(MSGFMT_OPTS)
243 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
244 GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
245 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
246 AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
247 return _nl_msg_cat_cntr],
252 dnl On Solaris, if bind_textdomain_codeset is in libc,
253 dnl GNU format message catalog is always supported,
254 dnl since both are added to the libc all together.
255 dnl Hence, we'd like to go with DATADIRNAME=share and
256 dnl and CATOBJEXT=.gmo in this case.
257 AC_CHECK_FUNC(bind_textdomain_codeset,
268 LIBS="$glib_save_LIBS"
271 gt_cv_have_gettext=no
276 if test "$gt_cv_have_gettext" = "yes" ; then
277 AC_DEFINE(ENABLE_NLS, 1,
278 [always defined to indicate that i18n is enabled])
281 dnl Test whether we really found GNU xgettext.
282 if test "$XGETTEXT" != ":"; then
283 dnl If it is not GNU xgettext we define it as : so that the
284 dnl Makefiles still can work.
285 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
289 [found xgettext program is not GNU xgettext; ignore it])
294 # We need to process the po/ directory.
298 [case "$CONFIG_FILES" in *po/Makefile.in*)
299 sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
302 dnl These rules are solely for the distribution goal. While doing this
303 dnl we only have to keep exactly one list of the available catalogs
305 for lang in $ALL_LINGUAS; do
306 GMOFILES="$GMOFILES $lang.gmo"
307 POFILES="$POFILES $lang.po"
310 dnl Make all variables we use known to autoconf.
313 AC_SUBST(DATADIRNAME)
317 AC_SUBST(PO_IN_DATADIR_TRUE)
318 AC_SUBST(PO_IN_DATADIR_FALSE)
323 # AM_GLIB_GNU_GETTEXT
324 # -------------------
325 # Do checks necessary for use of gettext. If a suitable implementation
326 # of gettext is found in either in libintl or in the C library,
327 # it will set INTLLIBS to the libraries needed for use of gettext
328 # and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable
329 # gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST()
330 # on various variables needed by the Makefile.in.in installed by
333 glib_DEFUN([GLIB_GNU_GETTEXT],
334 [AC_REQUIRE([AC_PROG_CC])dnl
335 AC_REQUIRE([AC_HEADER_STDC])dnl
340 if test "$gt_cv_have_gettext" = "yes"; then
341 if test "x$ALL_LINGUAS" = "x"; then
344 AC_MSG_CHECKING(for catalogs to be installed)
346 for presentlang in $ALL_LINGUAS; do
348 if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then
349 desiredlanguages="$LINGUAS"
351 desiredlanguages="$ALL_LINGUAS"
353 for desiredlang in $desiredlanguages; do
354 # Use the presentlang catalog if desiredlang is
355 # a. equal to presentlang, or
356 # b. a variant of presentlang (because in this case,
357 # presentlang can be used as a fallback for messages
358 # which are not translated in the desiredlang catalog).
359 case "$desiredlang" in
360 "$presentlang"*) useit=yes;;
363 if test $useit = yes; then
364 NEW_LINGUAS="$NEW_LINGUAS $presentlang"
368 AC_MSG_RESULT($LINGUAS)
371 dnl Construct list of names of catalog files to be constructed.
372 if test -n "$LINGUAS"; then
373 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
377 dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
378 dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
379 dnl Try to locate is.
381 if test -n "$ac_aux_dir"; then
382 MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
384 if test -z "$MKINSTALLDIRS"; then
385 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
387 AC_SUBST(MKINSTALLDIRS)
389 dnl Generate list of files to be processed by xgettext which will
390 dnl be included in po/Makefile.
391 test -d po || mkdir po
392 if test "x$srcdir" != "x."; then
393 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
394 posrcprefix="$srcdir/"
396 posrcprefix="../$srcdir/"
402 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
403 < $srcdir/po/POTFILES.in > po/POTFILES
406 # AM_GLIB_DEFINE_LOCALEDIR(VARIABLE)
407 # -------------------------------
408 # Define VARIABLE to the location where catalog files will
409 # be installed by po/Makefile.
410 glib_DEFUN([GLIB_DEFINE_LOCALEDIR],
411 [glib_REQUIRE([GLIB_GNU_GETTEXT])dnl
412 glib_save_prefix="$prefix"
413 glib_save_exec_prefix="$exec_prefix"
414 glib_save_datarootdir="$datarootdir"
415 test "x$prefix" = xNONE && prefix=$ac_default_prefix
416 test "x$exec_prefix" = xNONE && exec_prefix=$prefix
417 datarootdir=`eval echo "${datarootdir}"`
418 if test "x$CATOBJEXT" = "x.mo" ; then
419 localedir=`eval echo "${libdir}/locale"`
421 localedir=`eval echo "${datadir}/locale"`
423 prefix="$glib_save_prefix"
424 exec_prefix="$glib_save_exec_prefix"
425 datarootdir="$glib_save_datarootdir"
426 AC_DEFINE_UNQUOTED($1, "$localedir",
427 [Define the location where the catalogs will be installed])
431 dnl Now the definitions that aclocal will find
433 ifdef(glib_configure_in,[],[
434 AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)])
435 AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)])
438 # GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL])
440 # Create a temporary file with TEST-FILE as its contents and pass the
441 # file name to PROGRAM. Perform ACTION-IF-PASS if PROGRAM exits with
442 # 0 and perform ACTION-IF-FAIL for any other exit status.
443 AC_DEFUN([GLIB_RUN_PROG],
444 [cat >conftest.foo <<_ACEOF
447 if AC_RUN_LOG([$1 conftest.foo]); then
448 m4_ifval([$3], [$3], [:])
449 m4_ifvaln([$4], [else $4])dnl
450 echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD
451 sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
456 dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
457 # serial 40 IT_PROG_INTLTOOL
458 AC_DEFUN([IT_PROG_INTLTOOL], [
460 AC_REQUIRE([AM_NLS])dnl
462 case "$am__api_version" in
464 AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
470 if test -n "$1"; then
471 AC_MSG_CHECKING([for intltool >= $1])
473 INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
474 INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
475 [INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
477 AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
478 test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
479 AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.])
482 AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
483 AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
484 AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
485 if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
486 AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
489 INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
490 INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
491 INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
492 INTLTOOL_PROP_RULE='%.prop: %.prop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
493 INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -p $(top_srcdir)/po $< [$]@'
494 INTLTOOL_PONG_RULE='%.pong: %.pong.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
495 INTLTOOL_SERVER_RULE='%.server: %.server.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
496 INTLTOOL_SHEET_RULE='%.sheet: %.sheet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
497 INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
498 INTLTOOL_UI_RULE='%.ui: %.ui.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
499 INTLTOOL_XML_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
500 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< [$]@'
501 INTLTOOL_XAM_RULE='%.xam: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
502 INTLTOOL_KBD_RULE='%.kbd: %.kbd.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
503 INTLTOOL_CAVES_RULE='%.caves: %.caves.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
504 INTLTOOL_SCHEMAS_RULE='%.schemas: %.schemas.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
505 INTLTOOL_THEME_RULE='%.theme: %.theme.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
506 INTLTOOL_SERVICE_RULE='%.service: %.service.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
507 INTLTOOL_POLICY_RULE='%.policy: %.policy.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
509 AC_SUBST(INTLTOOL_DESKTOP_RULE)
510 AC_SUBST(INTLTOOL_DIRECTORY_RULE)
511 AC_SUBST(INTLTOOL_KEYS_RULE)
512 AC_SUBST(INTLTOOL_PROP_RULE)
513 AC_SUBST(INTLTOOL_OAF_RULE)
514 AC_SUBST(INTLTOOL_PONG_RULE)
515 AC_SUBST(INTLTOOL_SERVER_RULE)
516 AC_SUBST(INTLTOOL_SHEET_RULE)
517 AC_SUBST(INTLTOOL_SOUNDLIST_RULE)
518 AC_SUBST(INTLTOOL_UI_RULE)
519 AC_SUBST(INTLTOOL_XAM_RULE)
520 AC_SUBST(INTLTOOL_KBD_RULE)
521 AC_SUBST(INTLTOOL_XML_RULE)
522 AC_SUBST(INTLTOOL_XML_NOMERGE_RULE)
523 AC_SUBST(INTLTOOL_CAVES_RULE)
524 AC_SUBST(INTLTOOL_SCHEMAS_RULE)
525 AC_SUBST(INTLTOOL_THEME_RULE)
526 AC_SUBST(INTLTOOL_SERVICE_RULE)
527 AC_SUBST(INTLTOOL_POLICY_RULE)
529 # Check the gettext tools to make sure they are GNU
530 AC_PATH_PROG(XGETTEXT, xgettext)
531 AC_PATH_PROG(MSGMERGE, msgmerge)
532 AC_PATH_PROG(MSGFMT, msgfmt)
533 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
534 if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
535 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
537 xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
538 mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
539 mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
540 if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
541 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
544 AC_PATH_PROG(INTLTOOL_PERL, [perl])
545 if test -z "$INTLTOOL_PERL"; then
546 AC_MSG_ERROR([perl not found; required for intltool])
548 if test -z "`$INTLTOOL_PERL -v | fgrep '5.' 2> /dev/null`"; then
549 AC_MSG_ERROR([perl 5.x required for intltool])
551 if test "x$2" != "xno-xml"; then
552 AC_MSG_CHECKING([for XML::Parser])
553 if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
556 AC_MSG_ERROR([XML::Parser perl module is required for intltool])
560 # Substitute ALL_LINGUAS so we can use it in po/Makefile
561 AC_SUBST(ALL_LINGUAS)
563 # Set DATADIRNAME correctly if it is not set yet
564 # (copied from glib-gettext.m4)
565 if test -z "$DATADIRNAME"; then
567 [AC_LANG_PROGRAM([[]],
568 [[extern int _nl_msg_cat_cntr;
569 return _nl_msg_cat_cntr]])],
573 dnl On Solaris, if bind_textdomain_codeset is in libc,
574 dnl GNU format message catalog is always supported,
575 dnl since both are added to the libc all together.
576 dnl Hence, we'd like to go with DATADIRNAME=share
578 AC_CHECK_FUNC(bind_textdomain_codeset,
579 [DATADIRNAME=share], [DATADIRNAME=lib])
586 AC_SUBST(DATADIRNAME)
593 # IT_PO_SUBDIR(DIRNAME)
594 # ---------------------
595 # All po subdirs have to be declared with this macro; the subdir "po" is
596 # declared by IT_PROG_INTLTOOL.
598 AC_DEFUN([IT_PO_SUBDIR],
599 [AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
601 dnl The following CONFIG_COMMANDS should be exetuted at the very end
602 dnl of config.status.
603 AC_CONFIG_COMMANDS_PRE([
604 AC_CONFIG_COMMANDS([$1/stamp-it], [
605 if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" ]; then
606 AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
608 rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
613 '"s|^| $ac_top_srcdir/|" \
614 "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
616 [sed '/^POTFILES =/,/[^\\]$/ {
620 ' "$1/Makefile.in" >"$1/Makefile"]
621 rm -f "$1/Makefile.tmp"
622 mv "$1/stamp-it.tmp" "$1/stamp-it"
628 AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
629 # A hint is needed for aclocal from Automake <= 1.9.4:
630 # AC_DEFUN([AC_PROG_INTLTOOL], ...)
633 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
635 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
636 # 2006, 2007, 2008 Free Software Foundation, Inc.
637 # Written by Gordon Matzigkeit, 1996
639 # This file is free software; the Free Software Foundation gives
640 # unlimited permission to copy and/or distribute it, with or without
641 # modifications, as long as this notice is preserved.
643 m4_define([_LT_COPYING], [dnl
644 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
645 # 2006, 2007, 2008 Free Software Foundation, Inc.
646 # Written by Gordon Matzigkeit, 1996
648 # This file is part of GNU Libtool.
650 # GNU Libtool is free software; you can redistribute it and/or
651 # modify it under the terms of the GNU General Public License as
652 # published by the Free Software Foundation; either version 2 of
653 # the License, or (at your option) any later version.
655 # As a special exception to the GNU General Public License,
656 # if you distribute this file as part of a program or library that
657 # is built using GNU Libtool, you may include this file under the
658 # same distribution terms that you use for the rest of that program.
660 # GNU Libtool is distributed in the hope that it will be useful,
661 # but WITHOUT ANY WARRANTY; without even the implied warranty of
662 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
663 # GNU General Public License for more details.
665 # You should have received a copy of the GNU General Public License
666 # along with GNU Libtool; see the file COPYING. If not, a copy
667 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
668 # obtained by writing to the Free Software Foundation, Inc.,
669 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
677 # Complain and exit if this libtool version is less that VERSION.
678 m4_defun([LT_PREREQ],
679 [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
681 [m4_fatal([Libtool version $1 or higher is required],
688 # Complain if the absolute build directory name contains unusual characters
689 m4_defun([_LT_CHECK_BUILDDIR],
692 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
700 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
701 AC_BEFORE([$0], [LT_LANG])dnl
702 AC_BEFORE([$0], [LT_OUTPUT])dnl
703 AC_BEFORE([$0], [LTDL_INIT])dnl
704 m4_require([_LT_CHECK_BUILDDIR])dnl
706 dnl Autoconf doesn't catch unexpanded LT_ macros by default:
707 m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
708 m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
709 dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
710 dnl unless we require an AC_DEFUNed macro:
711 AC_REQUIRE([LTOPTIONS_VERSION])dnl
712 AC_REQUIRE([LTSUGAR_VERSION])dnl
713 AC_REQUIRE([LTVERSION_VERSION])dnl
714 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
715 m4_require([_LT_PROG_LTMAIN])dnl
718 _LT_SET_OPTIONS([$0], [$1])
720 # This can be used to rebuild libtool when needed
721 LIBTOOL_DEPS="$ltmain"
723 # Always use our own libtool.
724 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
734 AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
735 AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
736 dnl aclocal-1.4 backwards compatibility:
737 dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
738 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
741 # _LT_CC_BASENAME(CC)
742 # -------------------
743 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
744 m4_defun([_LT_CC_BASENAME],
745 [for cc_temp in $1""; do
747 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
748 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
753 cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
757 # _LT_FILEUTILS_DEFAULTS
758 # ----------------------
759 # It is okay to use these file commands and assume they have been set
760 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
761 m4_defun([_LT_FILEUTILS_DEFAULTS],
765 ])# _LT_FILEUTILS_DEFAULTS
770 m4_defun([_LT_SETUP],
771 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
772 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
773 _LT_DECL([], [host_alias], [0], [The host system])dnl
774 _LT_DECL([], [host], [0])dnl
775 _LT_DECL([], [host_os], [0])dnl
777 _LT_DECL([], [build_alias], [0], [The build system])dnl
778 _LT_DECL([], [build], [0])dnl
779 _LT_DECL([], [build_os], [0])dnl
781 AC_REQUIRE([AC_PROG_CC])dnl
782 AC_REQUIRE([LT_PATH_LD])dnl
783 AC_REQUIRE([LT_PATH_NM])dnl
785 AC_REQUIRE([AC_PROG_LN_S])dnl
786 test -z "$LN_S" && LN_S="ln -s"
787 _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
789 AC_REQUIRE([LT_CMD_MAX_LEN])dnl
790 _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
791 _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
793 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
794 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
795 m4_require([_LT_CMD_RELOAD])dnl
796 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
797 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
798 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
800 _LT_CONFIG_LIBTOOL_INIT([
801 # See if we are running on zsh, and set the options which allow our
802 # commands through without removal of \ escapes INIT.
803 if test -n "\${ZSH_VERSION+set}" ; then
807 if test -n "${ZSH_VERSION+set}" ; then
813 m4_require([_LT_TAG_COMPILER])dnl
814 _LT_PROG_ECHO_BACKSLASH
818 # AIX sometimes has problems with the GCC collect2 program. For some
819 # reason, if we set the COLLECT_NAMES environment variable, the problems
820 # vanish in a puff of smoke.
821 if test "X${COLLECT_NAMES+set}" != Xset; then
828 # Sed substitution that helps us do robust quoting. It backslashifies
829 # metacharacters that are still active within double-quoted strings.
830 sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
832 # Same as above, but do not quote variable references.
833 double_quote_subst='s/\([["`\\]]\)/\\\1/g'
835 # Sed substitution to delay expansion of an escaped shell variable in a
836 # double_quote_subst'ed string.
837 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
839 # Sed substitution to delay expansion of an escaped single quote.
840 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
842 # Sed substitution to avoid accidental globbing in evaled expressions
843 no_glob_subst='s/\*/\\\*/g'
849 # All known linkers require a `.a' archive for static linking (except MSVC,
850 # which needs '.lib').
853 with_gnu_ld="$lt_cv_prog_gnu_ld"
858 # Set sane defaults for various variables
859 test -z "$CC" && CC=cc
860 test -z "$LTCC" && LTCC=$CC
861 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
862 test -z "$LD" && LD=ld
863 test -z "$ac_objext" && ac_objext=o
865 _LT_CC_BASENAME([$compiler])
867 # Only perform the check for file, if the check method requires it
868 test -z "$MAGIC_CMD" && MAGIC_CMD=file
869 case $deplibs_check_method in
871 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
877 # Use C for the default configuration in the libtool script
878 LT_SUPPORTED_TAG([CC])
880 _LT_LANG_DEFAULT_CONFIG
887 # Note that this code is called both from `configure', and `config.status'
888 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
889 # `config.status' has no value for ac_aux_dir unless we are using Automake,
890 # so we pass a copy along to make sure it has a sensible value anyway.
891 m4_defun([_LT_PROG_LTMAIN],
892 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
893 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
894 ltmain="$ac_aux_dir/ltmain.sh"
899 # So that we can recreate a full libtool script including additional
900 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
901 # in macros and then make a single call at the end using the `libtool'
905 # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
906 # ----------------------------------------
907 # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
908 m4_define([_LT_CONFIG_LIBTOOL_INIT],
910 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
915 m4_define([_LT_OUTPUT_LIBTOOL_INIT])
918 # _LT_CONFIG_LIBTOOL([COMMANDS])
919 # ------------------------------
920 # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
921 m4_define([_LT_CONFIG_LIBTOOL],
923 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
928 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
931 # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
932 # -----------------------------------------------------
933 m4_defun([_LT_CONFIG_SAVE_COMMANDS],
934 [_LT_CONFIG_LIBTOOL([$1])
935 _LT_CONFIG_LIBTOOL_INIT([$2])
939 # _LT_FORMAT_COMMENT([COMMENT])
940 # -----------------------------
941 # Add leading comment marks to the start of each line, and a trailing
942 # full-stop to the whole comment if one is not present already.
943 m4_define([_LT_FORMAT_COMMENT],
945 m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
946 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
953 # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
954 # -------------------------------------------------------------------
955 # CONFIGNAME is the name given to the value in the libtool script.
956 # VARNAME is the (base) name used in the configure script.
957 # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
958 # VARNAME. Any other value will be used directly.
959 m4_define([_LT_DECL],
960 [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
961 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
962 [m4_ifval([$1], [$1], [$2])])
963 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
965 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
966 lt_dict_add_subkey([lt_decl_dict], [$2],
967 [tagged?], [m4_ifval([$5], [yes], [no])])])
971 # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
972 # --------------------------------------------------------
973 m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
976 # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
977 # ------------------------------------------------
978 m4_define([lt_decl_tag_varnames],
979 [_lt_decl_filter([tagged?], [yes], $@)])
982 # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
983 # ---------------------------------------------------------
984 m4_define([_lt_decl_filter],
986 [0], [m4_fatal([$0: too few arguments: $#])],
987 [1], [m4_fatal([$0: too few arguments: $#: $1])],
988 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
989 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
990 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
994 # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
995 # --------------------------------------------------
996 m4_define([lt_decl_quote_varnames],
997 [_lt_decl_filter([value], [1], $@)])
1000 # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
1001 # ---------------------------------------------------
1002 m4_define([lt_decl_dquote_varnames],
1003 [_lt_decl_filter([value], [2], $@)])
1006 # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
1007 # ---------------------------------------------------
1008 m4_define([lt_decl_varnames_tagged],
1009 [_$0(m4_quote(m4_default([$1], [[, ]])),
1010 m4_quote(m4_if([$2], [],
1011 m4_quote(lt_decl_tag_varnames),
1012 m4_quote(m4_shift($@)))),
1013 m4_split(m4_normalize(m4_quote(_LT_TAGS))))])
1014 m4_define([_lt_decl_varnames_tagged], [lt_combine([$1], [$2], [_], $3)])
1017 # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
1018 # ------------------------------------------------
1019 m4_define([lt_decl_all_varnames],
1020 [_$0(m4_quote(m4_default([$1], [[, ]])),
1022 m4_quote(lt_decl_varnames),
1023 m4_quote(m4_shift($@))))[]dnl
1025 m4_define([_lt_decl_all_varnames],
1026 [lt_join($@, lt_decl_varnames_tagged([$1],
1027 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
1031 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
1032 # ------------------------------------
1033 # Quote a variable value, and forward it to `config.status' so that its
1034 # declaration there will have the same value as in `configure'. VARNAME
1035 # must have a single quote delimited value for this to work.
1036 m4_define([_LT_CONFIG_STATUS_DECLARE],
1037 [$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
1040 # _LT_CONFIG_STATUS_DECLARATIONS
1041 # ------------------------------
1042 # We delimit libtool config variables with single quotes, so when
1043 # we write them to config.status, we have to be sure to quote all
1044 # embedded single quotes properly. In configure, this macro expands
1045 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
1047 # <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
1048 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
1049 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
1050 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
1055 # Output comment and list of tags supported by the script
1056 m4_defun([_LT_LIBTOOL_TAGS],
1057 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
1058 available_tags="_LT_TAGS"dnl
1062 # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
1063 # -----------------------------------
1064 # Extract the dictionary values for VARNAME (optionally with TAG) and
1065 # expand to a commented shell variable setting:
1067 # # Some comment about what VAR is for.
1068 # visible_name=$lt_internal_name
1069 m4_define([_LT_LIBTOOL_DECLARE],
1070 [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
1071 [description])))[]dnl
1072 m4_pushdef([_libtool_name],
1073 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
1074 m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
1075 [0], [_libtool_name=[$]$1],
1076 [1], [_libtool_name=$lt_[]$1],
1077 [2], [_libtool_name=$lt_[]$1],
1078 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
1079 m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
1083 # _LT_LIBTOOL_CONFIG_VARS
1084 # -----------------------
1085 # Produce commented declarations of non-tagged libtool config variables
1086 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
1087 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
1088 # section) are produced by _LT_LIBTOOL_TAG_VARS.
1089 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
1090 [m4_foreach([_lt_var],
1091 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
1092 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
1095 # _LT_LIBTOOL_TAG_VARS(TAG)
1096 # -------------------------
1097 m4_define([_LT_LIBTOOL_TAG_VARS],
1098 [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
1099 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
1102 # _LT_TAGVAR(VARNAME, [TAGNAME])
1103 # ------------------------------
1104 m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
1107 # _LT_CONFIG_COMMANDS
1108 # -------------------
1109 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
1110 # variables for single and double quote escaping we saved from calls
1111 # to _LT_DECL, we can put quote escaped variables declarations
1112 # into `config.status', and then the shell code to quote escape them in
1113 # for loops in `config.status'. Finally, any additional code accumulated
1114 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
1115 m4_defun([_LT_CONFIG_COMMANDS],
1116 [AC_PROVIDE_IFELSE([LT_OUTPUT],
1117 dnl If the libtool generation code has been placed in $CONFIG_LT,
1118 dnl instead of duplicating it all over again into config.status,
1119 dnl then we will have config.status run $CONFIG_LT later, so it
1120 dnl needs to know what name is stored there:
1121 [AC_CONFIG_COMMANDS([libtool],
1122 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
1123 dnl If the libtool generation code is destined for config.status,
1124 dnl expand the accumulated commands and init code now:
1125 [AC_CONFIG_COMMANDS([libtool],
1126 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
1127 ])#_LT_CONFIG_COMMANDS
1131 m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
1134 # The HP-UX ksh and POSIX shell print the target directory to stdout
1136 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1138 sed_quote_subst='$sed_quote_subst'
1139 double_quote_subst='$double_quote_subst'
1140 delay_variable_subst='$delay_variable_subst'
1141 _LT_CONFIG_STATUS_DECLARATIONS
1143 LTCFLAGS='$LTCFLAGS'
1144 compiler='$compiler_DEFAULT'
1146 # Quote evaled strings.
1147 for var in lt_decl_all_varnames([[ \
1148 ]], lt_decl_quote_varnames); do
1149 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
1150 *[[\\\\\\\`\\"\\\$]]*)
1151 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1154 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1159 # Double-quote double-evaled strings.
1160 for var in lt_decl_all_varnames([[ \
1161 ]], lt_decl_dquote_varnames); do
1162 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
1163 *[[\\\\\\\`\\"\\\$]]*)
1164 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1167 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1172 # Fix-up fallback echo if it was mangled by the above quoting rules.
1174 *'\\\[$]0 --fallback-echo"')dnl "
1175 lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
1179 _LT_OUTPUT_LIBTOOL_INIT
1185 # This macro allows early generation of the libtool script (before
1186 # AC_OUTPUT is called), incase it is used in configure for compilation
1188 AC_DEFUN([LT_OUTPUT],
1189 [: ${CONFIG_LT=./config.lt}
1190 AC_MSG_NOTICE([creating $CONFIG_LT])
1191 cat >"$CONFIG_LT" <<_LTEOF
1193 # Generated by $as_me.
1194 # Run this file to recreate a libtool stub with the current configuration.
1197 SHELL=\${CONFIG_SHELL-$SHELL}
1200 cat >>"$CONFIG_LT" <<\_LTEOF
1204 exec AS_MESSAGE_FD>&1
1205 exec AS_MESSAGE_LOG_FD>>config.log
1208 AS_BOX([Running $as_me.])
1209 } >&AS_MESSAGE_LOG_FD
1212 \`$as_me' creates a local libtool stub from the current configuration,
1213 for use in further configure time tests before the real libtool is
1216 Usage: $[0] [[OPTIONS]]
1218 -h, --help print this help, then exit
1219 -V, --version print version number, then exit
1220 -q, --quiet do not print progress messages
1221 -d, --debug don't remove temporary files
1223 Report bugs to <bug-libtool@gnu.org>."
1226 m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1227 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1228 configured by $[0], generated by m4_PACKAGE_STRING.
1230 Copyright (C) 2008 Free Software Foundation, Inc.
1231 This config.lt script is free software; the Free Software Foundation
1232 gives unlimited permision to copy, distribute and modify it."
1234 while test $[#] != 0
1237 --version | --v* | -V )
1238 echo "$lt_cl_version"; exit 0 ;;
1239 --help | --h* | -h )
1240 echo "$lt_cl_help"; exit 0 ;;
1241 --debug | --d* | -d )
1243 --quiet | --q* | --silent | --s* | -q )
1246 -*) AC_MSG_ERROR([unrecognized option: $[1]
1247 Try \`$[0] --help' for more information.]) ;;
1249 *) AC_MSG_ERROR([unrecognized argument: $[1]
1250 Try \`$[0] --help' for more information.]) ;;
1255 if $lt_cl_silent; then
1256 exec AS_MESSAGE_FD>/dev/null
1260 cat >>"$CONFIG_LT" <<_LTEOF
1261 _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1264 cat >>"$CONFIG_LT" <<\_LTEOF
1265 AC_MSG_NOTICE([creating $ofile])
1266 _LT_OUTPUT_LIBTOOL_COMMANDS
1269 chmod +x "$CONFIG_LT"
1271 # configure is writing to config.log, but config.lt does its own redirection,
1272 # appending to config.log, which fails on DOS, as config.log is still kept
1273 # open by configure. Here we exec the FD to /dev/null, effectively closing
1274 # config.log, so it can be properly (re)opened and appended to by config.lt.
1275 if test "$no_create" != yes; then
1277 test "$silent" = yes &&
1278 lt_config_lt_args="$lt_config_lt_args --quiet"
1279 exec AS_MESSAGE_LOG_FD>/dev/null
1280 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
1281 exec AS_MESSAGE_LOG_FD>>config.log
1282 $lt_cl_success || AS_EXIT(1)
1289 # If TAG is the built-in tag, create an initial libtool script with a
1290 # default configuration from the untagged config vars. Otherwise add code
1291 # to config.status for appending the configuration named by TAG from the
1292 # matching tagged config vars.
1293 m4_defun([_LT_CONFIG],
1294 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1295 _LT_CONFIG_SAVE_COMMANDS([
1296 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
1297 m4_if(_LT_TAG, [C], [
1298 # See if we are running on zsh, and set the options which allow our
1299 # commands through without removal of \ escapes.
1300 if test -n "${ZSH_VERSION+set}" ; then
1301 setopt NO_GLOB_SUBST
1305 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
1308 cat <<_LT_EOF >> "$cfgfile"
1311 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
1312 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
1313 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1314 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
1319 # ### BEGIN LIBTOOL CONFIG
1320 _LT_LIBTOOL_CONFIG_VARS
1321 _LT_LIBTOOL_TAG_VARS
1322 # ### END LIBTOOL CONFIG
1328 cat <<\_LT_EOF >> "$cfgfile"
1329 # AIX sometimes has problems with the GCC collect2 program. For some
1330 # reason, if we set the COLLECT_NAMES environment variable, the problems
1331 # vanish in a puff of smoke.
1332 if test "X${COLLECT_NAMES+set}" != Xset; then
1334 export COLLECT_NAMES
1342 # We use sed instead of cat because bash on DJGPP gets confused if
1343 # if finds mixed CR/LF and LF-only lines. Since sed operates in
1344 # text mode, it properly converts lines to CR/LF. This bash problem
1345 # is reportedly fixed, but why not run on old versions too?
1346 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
1347 || (rm -f "$cfgfile"; exit 1)
1349 _LT_PROG_XSI_SHELLFNS
1351 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
1352 || (rm -f "$cfgfile"; exit 1)
1354 mv -f "$cfgfile" "$ofile" ||
1355 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
1358 [cat <<_LT_EOF >> "$ofile"
1360 dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
1361 dnl in a comment (ie after a #).
1362 # ### BEGIN LIBTOOL TAG CONFIG: $1
1363 _LT_LIBTOOL_TAG_VARS(_LT_TAG)
1364 # ### END LIBTOOL TAG CONFIG: $1
1371 TIMESTAMP='$TIMESTAMP'
1373 ofile='$ofile'], [])
1374 ])dnl /_LT_CONFIG_SAVE_COMMANDS
1378 # LT_SUPPORTED_TAG(TAG)
1379 # ---------------------
1380 # Trace this macro to discover what tags are supported by the libtool
1381 # --tag option, using:
1382 # autoconf --trace 'LT_SUPPORTED_TAG:$1'
1383 AC_DEFUN([LT_SUPPORTED_TAG], [])
1386 # C support is built-in for now
1387 m4_define([_LT_LANG_C_enabled], [])
1388 m4_define([_LT_TAGS], [])
1393 # Enable libtool support for the given language if not already enabled.
1395 [AC_BEFORE([$0], [LT_OUTPUT])dnl
1398 [C++], [_LT_LANG(CXX)],
1399 [Java], [_LT_LANG(GCJ)],
1400 [Fortran 77], [_LT_LANG(F77)],
1401 [Fortran], [_LT_LANG(FC)],
1402 [Windows Resource], [_LT_LANG(RC)],
1403 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
1405 [m4_fatal([$0: unsupported language: "$1"])])])dnl
1409 # _LT_LANG(LANGNAME)
1410 # ------------------
1411 m4_defun([_LT_LANG],
1412 [m4_ifdef([_LT_LANG_]$1[_enabled], [],
1413 [LT_SUPPORTED_TAG([$1])dnl
1414 m4_append([_LT_TAGS], [$1 ])dnl
1415 m4_define([_LT_LANG_]$1[_enabled], [])dnl
1416 _LT_LANG_$1_CONFIG($1)])dnl
1420 # _LT_LANG_DEFAULT_CONFIG
1421 # -----------------------
1422 m4_defun([_LT_LANG_DEFAULT_CONFIG],
1423 [AC_PROVIDE_IFELSE([AC_PROG_CXX],
1425 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
1427 AC_PROVIDE_IFELSE([AC_PROG_F77],
1429 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
1431 AC_PROVIDE_IFELSE([AC_PROG_FC],
1433 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
1435 dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
1436 dnl pulling things in needlessly.
1437 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1439 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1441 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
1443 [m4_ifdef([AC_PROG_GCJ],
1444 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
1445 m4_ifdef([A][M_PROG_GCJ],
1446 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
1447 m4_ifdef([LT_PROG_GCJ],
1448 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
1450 AC_PROVIDE_IFELSE([LT_PROG_RC],
1452 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
1453 ])# _LT_LANG_DEFAULT_CONFIG
1456 AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1457 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1458 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1459 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1460 dnl aclocal-1.4 backwards compatibility:
1461 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1462 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1463 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1464 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1469 m4_defun([_LT_TAG_COMPILER],
1470 [AC_REQUIRE([AC_PROG_CC])dnl
1472 _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1473 _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1474 _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1475 _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1477 # If no C compiler was specified, use CC.
1480 # If no C compiler flags were specified, use CFLAGS.
1481 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1483 # Allow CC to be a program name with arguments.
1485 ])# _LT_TAG_COMPILER
1488 # _LT_COMPILER_BOILERPLATE
1489 # ------------------------
1490 # Check for compiler boilerplate output or warnings with
1491 # the simple compiler test code.
1492 m4_defun([_LT_COMPILER_BOILERPLATE],
1493 [m4_require([_LT_DECL_SED])dnl
1494 ac_outfile=conftest.$ac_objext
1495 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1496 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1497 _lt_compiler_boilerplate=`cat conftest.err`
1499 ])# _LT_COMPILER_BOILERPLATE
1502 # _LT_LINKER_BOILERPLATE
1503 # ----------------------
1504 # Check for linker boilerplate output or warnings with
1505 # the simple link test code.
1506 m4_defun([_LT_LINKER_BOILERPLATE],
1507 [m4_require([_LT_DECL_SED])dnl
1508 ac_outfile=conftest.$ac_objext
1509 echo "$lt_simple_link_test_code" >conftest.$ac_ext
1510 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1511 _lt_linker_boilerplate=`cat conftest.err`
1513 ])# _LT_LINKER_BOILERPLATE
1515 # _LT_REQUIRED_DARWIN_CHECKS
1516 # -------------------------
1517 m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1519 rhapsody* | darwin*)
1520 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1521 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1522 AC_CHECK_TOOL([LIPO], [lipo], [:])
1523 AC_CHECK_TOOL([OTOOL], [otool], [:])
1524 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1525 _LT_DECL([], [DSYMUTIL], [1],
1526 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1527 _LT_DECL([], [NMEDIT], [1],
1528 [Tool to change global to local symbols on Mac OS X])
1529 _LT_DECL([], [LIPO], [1],
1530 [Tool to manipulate fat objects and archives on Mac OS X])
1531 _LT_DECL([], [OTOOL], [1],
1532 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1533 _LT_DECL([], [OTOOL64], [1],
1534 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1536 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1537 [lt_cv_apple_cc_single_mod=no
1538 if test -z "${LT_MULTI_MODULE}"; then
1539 # By default we will add the -single_module flag. You can override
1540 # by either setting the environment variable LT_MULTI_MODULE
1541 # non-empty at configure time, or by adding -multi_module to the
1543 rm -rf libconftest.dylib*
1544 echo "int foo(void){return 1;}" > conftest.c
1545 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1546 -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1547 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1548 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1550 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
1551 lt_cv_apple_cc_single_mod=yes
1553 cat conftest.err >&AS_MESSAGE_LOG_FD
1555 rm -rf libconftest.dylib*
1558 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1559 [lt_cv_ld_exported_symbols_list],
1560 [lt_cv_ld_exported_symbols_list=no
1561 save_LDFLAGS=$LDFLAGS
1562 echo "_main" > conftest.sym
1563 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1564 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1565 [lt_cv_ld_exported_symbols_list=yes],
1566 [lt_cv_ld_exported_symbols_list=no])
1567 LDFLAGS="$save_LDFLAGS"
1570 rhapsody* | darwin1.[[012]])
1571 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1573 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1574 darwin*) # darwin 5.x on
1575 # if running on 10.5 or later, the deployment target defaults
1576 # to the OS version, if on x86, and 10.4, the deployment
1577 # target defaults to 10.4. Don't you love it?
1578 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1579 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1580 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1582 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1584 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1588 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1589 _lt_dar_single_mod='$single_module'
1591 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1592 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1594 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1596 if test "$DSYMUTIL" != ":"; then
1597 _lt_dsymutil='~$DSYMUTIL $lib || :'
1606 # _LT_DARWIN_LINKER_FEATURES
1607 # --------------------------
1608 # Checks for linker and compiler features on darwin
1609 m4_defun([_LT_DARWIN_LINKER_FEATURES],
1611 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1612 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1613 _LT_TAGVAR(hardcode_direct, $1)=no
1614 _LT_TAGVAR(hardcode_automatic, $1)=yes
1615 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1616 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1617 _LT_TAGVAR(link_all_deplibs, $1)=yes
1618 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1619 if test "$GCC" = "yes"; then
1620 output_verbose_link_cmd=echo
1621 _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}"
1622 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1623 _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}"
1624 _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}"
1626 [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1627 _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}"
1628 _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}"
1632 _LT_TAGVAR(ld_shlibs, $1)=no
1636 # _LT_SYS_MODULE_PATH_AIX
1637 # -----------------------
1638 # Links a minimal program and checks the executable
1639 # for the system default hardcoded library path. In most cases,
1640 # this is /usr/lib:/lib, but when the MPI compilers are used
1641 # the location of the communication and MPI libs are included too.
1642 # If we don't find anything, use the default library path according
1643 # to the aix ld manual.
1644 m4_defun([_LT_SYS_MODULE_PATH_AIX],
1645 [m4_require([_LT_DECL_SED])dnl
1646 AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1647 lt_aix_libpath_sed='
1648 /Import File Strings/,/^$/ {
1654 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1655 # Check for a 64-bit object if we didn't find anything.
1656 if test -z "$aix_libpath"; then
1657 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1659 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1660 ])# _LT_SYS_MODULE_PATH_AIX
1663 # _LT_SHELL_INIT(ARG)
1664 # -------------------
1665 m4_define([_LT_SHELL_INIT],
1666 [ifdef([AC_DIVERSION_NOTICE],
1667 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1668 [AC_DIVERT_PUSH(NOTICE)])
1674 # _LT_PROG_ECHO_BACKSLASH
1675 # -----------------------
1676 # Add some code to the start of the generated configure script which
1677 # will find an echo command which doesn't interpret backslashes.
1678 m4_defun([_LT_PROG_ECHO_BACKSLASH],
1680 # Check that we are running under the correct shell.
1681 SHELL=${CONFIG_SHELL-/bin/sh}
1685 # Remove one level of quotation (which was required for Make).
1686 ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1690 ECHO=${lt_ECHO-echo}
1691 if test "X[$]1" = X--no-reexec; then
1692 # Discard the --no-reexec flag, and continue.
1694 elif test "X[$]1" = X--fallback-echo; then
1695 # Avoid inline document here, it may be left over
1697 elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
1698 # Yippee, $ECHO works!
1701 # Restart under the correct shell.
1702 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1705 if test "X[$]1" = X--fallback-echo; then
1706 # used as fallback echo
1714 # The HP-UX ksh and POSIX shell print the target directory to stdout
1716 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1718 if test -z "$lt_ECHO"; then
1719 if test "X${echo_test_string+set}" != Xset; then
1720 # find a string as large as possible, as long as the shell can cope with it
1721 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1722 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1723 if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
1724 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
1731 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1732 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1733 test "X$echo_testing_string" = "X$echo_test_string"; then
1736 # The Solaris, AIX, and Digital Unix default echo programs unquote
1737 # backslashes. This makes it impossible to quote backslashes using
1738 # echo "$something" | sed 's/\\/\\\\/g'
1740 # So, first we look for a working echo in the user's PATH.
1742 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1743 for dir in $PATH /usr/ucb; do
1745 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1746 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1747 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1748 test "X$echo_testing_string" = "X$echo_test_string"; then
1755 if test "X$ECHO" = Xecho; then
1756 # We didn't find a better echo, so look for alternatives.
1757 if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
1758 echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
1759 test "X$echo_testing_string" = "X$echo_test_string"; then
1760 # This shell has a builtin print -r that does the trick.
1762 elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
1763 test "X$CONFIG_SHELL" != X/bin/ksh; then
1764 # If we have ksh, try running configure again with it.
1765 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1766 export ORIGINAL_CONFIG_SHELL
1767 CONFIG_SHELL=/bin/ksh
1769 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1773 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
1774 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
1775 test "X$echo_testing_string" = "X$echo_test_string"; then
1776 # Cool, printf works
1778 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1779 test "X$echo_testing_string" = 'X\t' &&
1780 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1781 test "X$echo_testing_string" = "X$echo_test_string"; then
1782 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1784 SHELL="$CONFIG_SHELL"
1786 ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1787 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1788 test "X$echo_testing_string" = 'X\t' &&
1789 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1790 test "X$echo_testing_string" = "X$echo_test_string"; then
1791 ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
1793 # maybe with a smaller string...
1796 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1797 if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
1804 if test "$prev" != 'sed 50q "[$]0"'; then
1805 echo_test_string=`eval $prev`
1806 export echo_test_string
1807 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1809 # Oops. We lost completely, so just stick with echo.
1818 # Copy echo and quote the copy suitably for passing to libtool from
1819 # the Makefile, instead of quoting the original, which is used later.
1821 if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1822 lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1827 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1828 _LT_DECL([], [ECHO], [1],
1829 [An echo program that does not interpret backslashes])
1830 ])# _LT_PROG_ECHO_BACKSLASH
1835 m4_defun([_LT_ENABLE_LOCK],
1836 [AC_ARG_ENABLE([libtool-lock],
1837 [AS_HELP_STRING([--disable-libtool-lock],
1838 [avoid locking (might break parallel builds)])])
1839 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1841 # Some flags need to be propagated to the compiler or linker for good
1845 # Find out which ABI we are using.
1846 echo 'int i;' > conftest.$ac_ext
1847 if AC_TRY_EVAL(ac_compile); then
1848 case `/usr/bin/file conftest.$ac_objext` in
1860 # Find out which ABI we are using.
1861 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1862 if AC_TRY_EVAL(ac_compile); then
1863 if test "$lt_cv_prog_gnu_ld" = yes; then
1864 case `/usr/bin/file conftest.$ac_objext` in
1866 LD="${LD-ld} -melf32bsmip"
1869 LD="${LD-ld} -melf32bmipn32"
1872 LD="${LD-ld} -melf64bmip"
1876 case `/usr/bin/file conftest.$ac_objext` in
1892 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1893 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1894 # Find out which ABI we are using.
1895 echo 'int i;' > conftest.$ac_ext
1896 if AC_TRY_EVAL(ac_compile); then
1897 case `/usr/bin/file conftest.o` in
1900 x86_64-*kfreebsd*-gnu)
1901 LD="${LD-ld} -m elf_i386_fbsd"
1904 LD="${LD-ld} -m elf_i386"
1906 ppc64-*linux*|powerpc64-*linux*)
1907 LD="${LD-ld} -m elf32ppclinux"
1910 LD="${LD-ld} -m elf_s390"
1913 LD="${LD-ld} -m elf32_sparc"
1919 x86_64-*kfreebsd*-gnu)
1920 LD="${LD-ld} -m elf_x86_64_fbsd"
1923 LD="${LD-ld} -m elf_x86_64"
1925 ppc*-*linux*|powerpc*-*linux*)
1926 LD="${LD-ld} -m elf64ppc"
1928 s390*-*linux*|s390*-*tpf*)
1929 LD="${LD-ld} -m elf64_s390"
1932 LD="${LD-ld} -m elf64_sparc"
1942 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1943 SAVE_CFLAGS="$CFLAGS"
1944 CFLAGS="$CFLAGS -belf"
1945 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1947 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1949 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1950 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1951 CFLAGS="$SAVE_CFLAGS"
1955 # Find out which ABI we are using.
1956 echo 'int i;' > conftest.$ac_ext
1957 if AC_TRY_EVAL(ac_compile); then
1958 case `/usr/bin/file conftest.o` in
1960 case $lt_cv_prog_gnu_ld in
1961 yes*) LD="${LD-ld} -m elf64_sparc" ;;
1963 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1975 need_locks="$enable_libtool_lock"
1979 # _LT_CMD_OLD_ARCHIVE
1980 # -------------------
1981 m4_defun([_LT_CMD_OLD_ARCHIVE],
1982 [AC_CHECK_TOOL(AR, ar, false)
1983 test -z "$AR" && AR=ar
1984 test -z "$AR_FLAGS" && AR_FLAGS=cru
1985 _LT_DECL([], [AR], [1], [The archiver])
1986 _LT_DECL([], [AR_FLAGS], [1])
1988 AC_CHECK_TOOL(STRIP, strip, :)
1989 test -z "$STRIP" && STRIP=:
1990 _LT_DECL([], [STRIP], [1], [A symbol stripping program])
1992 AC_CHECK_TOOL(RANLIB, ranlib, :)
1993 test -z "$RANLIB" && RANLIB=:
1994 _LT_DECL([], [RANLIB], [1],
1995 [Commands used to install an old-style archive])
1997 # Determine commands to create old-style static archives.
1998 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1999 old_postinstall_cmds='chmod 644 $oldlib'
2000 old_postuninstall_cmds=
2002 if test -n "$RANLIB"; then
2005 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
2008 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
2011 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
2013 _LT_DECL([], [old_postinstall_cmds], [2])
2014 _LT_DECL([], [old_postuninstall_cmds], [2])
2015 _LT_TAGDECL([], [old_archive_cmds], [2],
2016 [Commands used to build an old-style archive])
2017 ])# _LT_CMD_OLD_ARCHIVE
2020 # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2021 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
2022 # ----------------------------------------------------------------
2023 # Check whether the given compiler option works
2024 AC_DEFUN([_LT_COMPILER_OPTION],
2025 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2026 m4_require([_LT_DECL_SED])dnl
2027 AC_CACHE_CHECK([$1], [$2],
2029 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
2030 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2031 lt_compiler_flag="$3"
2032 # Insert the option either (1) after the last *FLAGS variable, or
2033 # (2) before a word containing "conftest.", or (3) at the end.
2034 # Note that $ac_compile itself does not contain backslashes and begins
2035 # with a dollar sign (not a hyphen), so the echo should work correctly.
2036 # The option is referenced via a variable to avoid confusing sed.
2037 lt_compile=`echo "$ac_compile" | $SED \
2038 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2039 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2040 -e 's:$: $lt_compiler_flag:'`
2041 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2042 (eval "$lt_compile" 2>conftest.err)
2044 cat conftest.err >&AS_MESSAGE_LOG_FD
2045 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2046 if (exit $ac_status) && test -s "$ac_outfile"; then
2047 # The compiler can only warn and ignore the option if not recognized
2048 # So say no if there are warnings other than the usual output.
2049 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
2050 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2051 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2058 if test x"[$]$2" = xyes; then
2059 m4_if([$5], , :, [$5])
2061 m4_if([$6], , :, [$6])
2063 ])# _LT_COMPILER_OPTION
2066 AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2067 dnl aclocal-1.4 backwards compatibility:
2068 dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2071 # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2072 # [ACTION-SUCCESS], [ACTION-FAILURE])
2073 # ----------------------------------------------------
2074 # Check whether the given linker option works
2075 AC_DEFUN([_LT_LINKER_OPTION],
2076 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2077 m4_require([_LT_DECL_SED])dnl
2078 AC_CACHE_CHECK([$1], [$2],
2080 save_LDFLAGS="$LDFLAGS"
2081 LDFLAGS="$LDFLAGS $3"
2082 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2083 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2084 # The linker can only warn and ignore the option if not recognized
2085 # So say no if there are warnings
2086 if test -s conftest.err; then
2087 # Append any errors to the config.log.
2088 cat conftest.err 1>&AS_MESSAGE_LOG_FD
2089 $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
2090 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2091 if diff conftest.exp conftest.er2 >/dev/null; then
2099 LDFLAGS="$save_LDFLAGS"
2102 if test x"[$]$2" = xyes; then
2103 m4_if([$4], , :, [$4])
2105 m4_if([$5], , :, [$5])
2107 ])# _LT_LINKER_OPTION
2110 AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2111 dnl aclocal-1.4 backwards compatibility:
2112 dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2117 AC_DEFUN([LT_CMD_MAX_LEN],
2118 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2119 # find the maximum length of command line arguments
2120 AC_MSG_CHECKING([the maximum length of command line arguments])
2121 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2127 # On DJGPP, this test can blow up pretty badly due to problems in libc
2128 # (any single argument exceeding 2000 bytes causes a buffer overrun
2129 # during glob expansion). Even if it were fixed, the result of this
2130 # check would be larger than it should be.
2131 lt_cv_sys_max_cmd_len=12288; # 12K is about right
2135 # Under GNU Hurd, this test is not required because there is
2136 # no limit to the length of command line arguments.
2137 # Libtool will interpret -1 as no limit whatsoever
2138 lt_cv_sys_max_cmd_len=-1;
2142 # On Win9x/ME, this test blows up -- it succeeds, but takes
2143 # about 5 minutes as the teststring grows exponentially.
2144 # Worse, since 9x/ME are not pre-emptively multitasking,
2145 # you end up with a "frozen" computer, even though with patience
2146 # the test eventually succeeds (with a max line length of 256k).
2147 # Instead, let's just punt: use the minimum linelength reported by
2148 # all of the supported platforms: 8192 (on NT/2K/XP).
2149 lt_cv_sys_max_cmd_len=8192;
2153 # On AmigaOS with pdksh, this test takes hours, literally.
2154 # So we just punt and use a minimum line length of 8192.
2155 lt_cv_sys_max_cmd_len=8192;
2158 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
2159 # This has been around since 386BSD, at least. Likely further.
2160 if test -x /sbin/sysctl; then
2161 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2162 elif test -x /usr/sbin/sysctl; then
2163 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2165 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
2167 # And add a safety zone
2168 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2169 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2173 # We know the value 262144 and hardcode it with a safety zone (like BSD)
2174 lt_cv_sys_max_cmd_len=196608
2178 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2179 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2180 # nice to cause kernel panics so lets avoid the loop below.
2181 # First set a reasonable default.
2182 lt_cv_sys_max_cmd_len=16384
2184 if test -x /sbin/sysconfig; then
2185 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2186 *1*) lt_cv_sys_max_cmd_len=-1 ;;
2191 lt_cv_sys_max_cmd_len=102400
2193 sysv5* | sco5v6* | sysv4.2uw2*)
2194 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2195 if test -n "$kargmax"; then
2196 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
2198 lt_cv_sys_max_cmd_len=32768
2202 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
2203 if test -n "$lt_cv_sys_max_cmd_len"; then
2204 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2205 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2207 # Make teststring a little bigger before we do anything with it.
2208 # a 1K string should be a reasonable start.
2209 for i in 1 2 3 4 5 6 7 8 ; do
2210 teststring=$teststring$teststring
2212 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
2213 # If test is not a shell built-in, we'll probably end up computing a
2214 # maximum length that is only half of the actual maximum length, but
2216 while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
2217 = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
2218 test $i != 17 # 1/2 MB should be enough
2221 teststring=$teststring$teststring
2223 # Only check the string length outside the loop.
2224 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
2226 # Add a significant safety factor because C++ compilers can tack on
2227 # massive amounts of additional arguments before passing them to the
2228 # linker. It appears as though 1/2 is a usable value.
2229 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
2234 if test -n $lt_cv_sys_max_cmd_len ; then
2235 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
2239 max_cmd_len=$lt_cv_sys_max_cmd_len
2240 _LT_DECL([], [max_cmd_len], [0],
2241 [What is the maximum length of a command?])
2245 AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
2246 dnl aclocal-1.4 backwards compatibility:
2247 dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
2252 m4_defun([_LT_HEADER_DLFCN],
2253 [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
2254 ])# _LT_HEADER_DLFCN
2257 # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
2258 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
2259 # ----------------------------------------------------------------
2260 m4_defun([_LT_TRY_DLOPEN_SELF],
2261 [m4_require([_LT_HEADER_DLFCN])dnl
2262 if test "$cross_compiling" = yes; then :
2265 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
2266 lt_status=$lt_dlunknown
2267 cat > conftest.$ac_ext <<_LT_EOF
2268 [#line __oline__ "configure"
2269 #include "confdefs.h"
2278 # define LT_DLGLOBAL RTLD_GLOBAL
2281 # define LT_DLGLOBAL DL_GLOBAL
2283 # define LT_DLGLOBAL 0
2287 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
2288 find out it does not work in some platform. */
2289 #ifndef LT_DLLAZY_OR_NOW
2291 # define LT_DLLAZY_OR_NOW RTLD_LAZY
2294 # define LT_DLLAZY_OR_NOW DL_LAZY
2297 # define LT_DLLAZY_OR_NOW RTLD_NOW
2300 # define LT_DLLAZY_OR_NOW DL_NOW
2302 # define LT_DLLAZY_OR_NOW 0
2310 extern "C" void exit (int);
2313 void fnord() { int i=42;}
2316 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
2317 int status = $lt_dlunknown;
2321 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
2322 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
2323 /* dlclose (self); */
2331 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
2332 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
2335 x$lt_dlno_uscore) $1 ;;
2336 x$lt_dlneed_uscore) $2 ;;
2337 x$lt_dlunknown|x*) $3 ;;
2340 # compilation failed
2345 ])# _LT_TRY_DLOPEN_SELF
2348 # LT_SYS_DLOPEN_SELF
2349 # ------------------
2350 AC_DEFUN([LT_SYS_DLOPEN_SELF],
2351 [m4_require([_LT_HEADER_DLFCN])dnl
2352 if test "x$enable_dlopen" != xyes; then
2353 enable_dlopen=unknown
2354 enable_dlopen_self=unknown
2355 enable_dlopen_self_static=unknown
2362 lt_cv_dlopen="load_add_on"
2364 lt_cv_dlopen_self=yes
2368 lt_cv_dlopen="LoadLibrary"
2373 lt_cv_dlopen="dlopen"
2378 # if libdl is installed we need to link against it
2379 AC_CHECK_LIB([dl], [dlopen],
2380 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
2383 lt_cv_dlopen_self=yes
2388 AC_CHECK_FUNC([shl_load],
2389 [lt_cv_dlopen="shl_load"],
2390 [AC_CHECK_LIB([dld], [shl_load],
2391 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
2392 [AC_CHECK_FUNC([dlopen],
2393 [lt_cv_dlopen="dlopen"],
2394 [AC_CHECK_LIB([dl], [dlopen],
2395 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
2396 [AC_CHECK_LIB([svld], [dlopen],
2397 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
2398 [AC_CHECK_LIB([dld], [dld_link],
2399 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
2408 if test "x$lt_cv_dlopen" != xno; then
2414 case $lt_cv_dlopen in
2416 save_CPPFLAGS="$CPPFLAGS"
2417 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2419 save_LDFLAGS="$LDFLAGS"
2420 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2423 LIBS="$lt_cv_dlopen_libs $LIBS"
2425 AC_CACHE_CHECK([whether a program can dlopen itself],
2426 lt_cv_dlopen_self, [dnl
2427 _LT_TRY_DLOPEN_SELF(
2428 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2429 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2432 if test "x$lt_cv_dlopen_self" = xyes; then
2433 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2434 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2435 lt_cv_dlopen_self_static, [dnl
2436 _LT_TRY_DLOPEN_SELF(
2437 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2438 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2442 CPPFLAGS="$save_CPPFLAGS"
2443 LDFLAGS="$save_LDFLAGS"
2448 case $lt_cv_dlopen_self in
2449 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2450 *) enable_dlopen_self=unknown ;;
2453 case $lt_cv_dlopen_self_static in
2454 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2455 *) enable_dlopen_self_static=unknown ;;
2458 _LT_DECL([dlopen_support], [enable_dlopen], [0],
2459 [Whether dlopen is supported])
2460 _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2461 [Whether dlopen of programs is supported])
2462 _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2463 [Whether dlopen of statically linked programs is supported])
2464 ])# LT_SYS_DLOPEN_SELF
2467 AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2468 dnl aclocal-1.4 backwards compatibility:
2469 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2472 # _LT_COMPILER_C_O([TAGNAME])
2473 # ---------------------------
2474 # Check to see if options -c and -o are simultaneously supported by compiler.
2475 # This macro does not hard code the compiler like AC_PROG_CC_C_O.
2476 m4_defun([_LT_COMPILER_C_O],
2477 [m4_require([_LT_DECL_SED])dnl
2478 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2479 m4_require([_LT_TAG_COMPILER])dnl
2480 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2481 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2482 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2483 $RM -r conftest 2>/dev/null
2487 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2489 lt_compiler_flag="-o out/conftest2.$ac_objext"
2490 # Insert the option either (1) after the last *FLAGS variable, or
2491 # (2) before a word containing "conftest.", or (3) at the end.
2492 # Note that $ac_compile itself does not contain backslashes and begins
2493 # with a dollar sign (not a hyphen), so the echo should work correctly.
2494 lt_compile=`echo "$ac_compile" | $SED \
2495 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2496 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2497 -e 's:$: $lt_compiler_flag:'`
2498 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2499 (eval "$lt_compile" 2>out/conftest.err)
2501 cat out/conftest.err >&AS_MESSAGE_LOG_FD
2502 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2503 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2505 # The compiler can only warn and ignore the option if not recognized
2506 # So say no if there are warnings
2507 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
2508 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2509 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2510 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2513 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2515 # SGI C++ compiler will create directory out/ii_files/ for
2516 # template instantiation
2517 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2518 $RM out/* && rmdir out
2523 _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2524 [Does compiler simultaneously support -c and -o options?])
2525 ])# _LT_COMPILER_C_O
2528 # _LT_COMPILER_FILE_LOCKS([TAGNAME])
2529 # ----------------------------------
2530 # Check to see if we can do hard links to lock some files if needed
2531 m4_defun([_LT_COMPILER_FILE_LOCKS],
2532 [m4_require([_LT_ENABLE_LOCK])dnl
2533 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2534 _LT_COMPILER_C_O([$1])
2536 hard_links="nottested"
2537 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2538 # do not overwrite the value of need_locks provided by the user
2539 AC_MSG_CHECKING([if we can lock with hard links])
2542 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2544 ln conftest.a conftest.b 2>&5 || hard_links=no
2545 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2546 AC_MSG_RESULT([$hard_links])
2547 if test "$hard_links" = no; then
2548 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2554 _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2555 ])# _LT_COMPILER_FILE_LOCKS
2560 m4_defun([_LT_CHECK_OBJDIR],
2561 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2562 [rm -f .libs 2>/dev/null
2563 mkdir .libs 2>/dev/null
2564 if test -d .libs; then
2567 # MS-DOS does not allow filenames that begin with a dot.
2570 rmdir .libs 2>/dev/null])
2571 objdir=$lt_cv_objdir
2572 _LT_DECL([], [objdir], [0],
2573 [The name of the directory that contains temporary libtool files])dnl
2574 m4_pattern_allow([LT_OBJDIR])dnl
2575 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2576 [Define to the sub-directory in which libtool stores uninstalled libraries.])
2577 ])# _LT_CHECK_OBJDIR
2580 # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2581 # --------------------------------------
2582 # Check hardcoding attributes.
2583 m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2584 [AC_MSG_CHECKING([how to hardcode library paths into programs])
2585 _LT_TAGVAR(hardcode_action, $1)=
2586 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2587 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2588 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2590 # We can hardcode non-existent directories.
2591 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2592 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2593 # have to relink, otherwise we might link with an installed library
2594 # when we should be linking with a yet-to-be-installed one
2595 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2596 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2597 # Linking always hardcodes the temporary library directory.
2598 _LT_TAGVAR(hardcode_action, $1)=relink
2600 # We can link without hardcoding, and we can hardcode nonexisting dirs.
2601 _LT_TAGVAR(hardcode_action, $1)=immediate
2604 # We cannot hardcode anything, or else we can only hardcode existing
2606 _LT_TAGVAR(hardcode_action, $1)=unsupported
2608 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2610 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2611 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2612 # Fast installation is not supported
2613 enable_fast_install=no
2614 elif test "$shlibpath_overrides_runpath" = yes ||
2615 test "$enable_shared" = no; then
2616 # Fast installation is not necessary
2617 enable_fast_install=needless
2619 _LT_TAGDECL([], [hardcode_action], [0],
2620 [How to hardcode a shared library path into an executable])
2621 ])# _LT_LINKER_HARDCODE_LIBPATH
2626 m4_defun([_LT_CMD_STRIPLIB],
2627 [m4_require([_LT_DECL_EGREP])
2630 AC_MSG_CHECKING([whether stripping libraries is possible])
2631 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2632 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2633 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2634 AC_MSG_RESULT([yes])
2636 # FIXME - insert some real tests, host_os isn't really good enough
2639 if test -n "$STRIP" ; then
2640 striplib="$STRIP -x"
2641 old_striplib="$STRIP -S"
2642 AC_MSG_RESULT([yes])
2652 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2653 _LT_DECL([], [striplib], [1])
2654 ])# _LT_CMD_STRIPLIB
2657 # _LT_SYS_DYNAMIC_LINKER([TAG])
2658 # -----------------------------
2659 # PORTME Fill in your ld.so characteristics
2660 m4_defun([_LT_SYS_DYNAMIC_LINKER],
2661 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2662 m4_require([_LT_DECL_EGREP])dnl
2663 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2664 m4_require([_LT_DECL_SED])dnl
2665 AC_MSG_CHECKING([dynamic linker characteristics])
2668 if test "$GCC" = yes; then
2670 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2671 *) lt_awk_arg="/^libraries:/" ;;
2673 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2674 if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
2675 # if the path contains ";" then we assume it to be the separator
2676 # otherwise default to the standard path separator (i.e. ":") - it is
2677 # assumed that no part of a normal pathname contains ";" but that should
2678 # okay in the real world where ";" in dirpaths is itself problematic.
2679 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
2681 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2683 # Ok, now we have the path, separated by spaces, we can step through it
2684 # and add multilib dir if necessary.
2685 lt_tmp_lt_search_path_spec=
2686 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2687 for lt_sys_path in $lt_search_path_spec; do
2688 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2689 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2691 test -d "$lt_sys_path" && \
2692 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2695 lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
2696 BEGIN {RS=" "; FS="/|\n";} {
2699 for (lt_i = NF; lt_i > 0; lt_i--) {
2700 if ($lt_i != "" && $lt_i != ".") {
2701 if ($lt_i == "..") {
2704 if (lt_count == 0) {
2705 lt_foo="/" $lt_i lt_foo;
2712 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2713 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2715 sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
2717 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2720 libname_spec='lib$name'
2728 shlibpath_overrides_runpath=unknown
2730 dynamic_linker="$host_os ld.so"
2731 sys_lib_dlsearch_path_spec="/lib /usr/lib"
2732 need_lib_prefix=unknown
2733 hardcode_into_libs=no
2735 # when you set need_version to no, make sure it does not cause -set_version
2736 # flags to be left without arguments
2737 need_version=unknown
2742 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2743 shlibpath_var=LIBPATH
2745 # AIX 3 has no versioning support, so we append a major version to the name.
2746 soname_spec='${libname}${release}${shared_ext}$major'
2753 hardcode_into_libs=yes
2754 if test "$host_cpu" = ia64; then
2755 # AIX 5 supports IA64
2756 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2757 shlibpath_var=LD_LIBRARY_PATH
2759 # With GCC up to 2.95.x, collect2 would create an import file
2760 # for dependence libraries. The import file would start with
2761 # the line `#! .'. This would cause the generated library to
2762 # depend on `.', always an invalid library. This was fixed in
2763 # development snapshots of GCC prior to 3.0.
2765 aix4 | aix4.[[01]] | aix4.[[01]].*)
2766 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2768 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2775 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2776 # soname into executable. Probably we can add versioning support to
2777 # collect2, so additional links can be useful in future.
2778 if test "$aix_use_runtimelinking" = yes; then
2779 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2780 # instead of lib<name>.a to let people know that these are not
2781 # typical AIX shared libraries.
2782 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2784 # We preserve .a as extension for shared libraries through AIX4.2
2785 # and later when we are not doing run time linking.
2786 library_names_spec='${libname}${release}.a $libname.a'
2787 soname_spec='${libname}${release}${shared_ext}$major'
2789 shlibpath_var=LIBPATH
2796 # Since July 2007 AmigaOS4 officially supports .so libraries.
2797 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2798 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2801 library_names_spec='$libname.ixlibrary $libname.a'
2802 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2803 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2809 library_names_spec='${libname}${shared_ext}'
2810 dynamic_linker="$host_os ld.so"
2811 shlibpath_var=LIBRARY_PATH
2817 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2818 soname_spec='${libname}${release}${shared_ext}$major'
2819 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2820 shlibpath_var=LD_LIBRARY_PATH
2821 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2822 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2823 # the default ld.so.conf also contains /usr/contrib/lib and
2824 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2825 # libtool to hard-code these into programs
2828 cygwin* | mingw* | pw32*)
2829 version_type=windows
2834 case $GCC,$host_os in
2835 yes,cygwin* | yes,mingw* | yes,pw32*)
2836 library_names_spec='$libname.dll.a'
2837 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2838 postinstall_cmds='base_file=`basename \${file}`~
2839 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2840 dldir=$destdir/`dirname \$dlpath`~
2841 test -d \$dldir || mkdir -p \$dldir~
2842 $install_prog $dir/$dlname \$dldir/$dlname~
2843 chmod a+x \$dldir/$dlname~
2844 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2845 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2847 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2848 dlpath=$dir/\$dldll~
2850 shlibpath_overrides_runpath=yes
2854 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2855 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2856 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2859 # MinGW DLLs use traditional 'lib' prefix
2860 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2861 sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2862 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
2863 # It is most probably a Windows format PATH printed by
2864 # mingw gcc, but we are running on Cygwin. Gcc prints its search
2865 # path with ; separators, and with drive letters. We can handle the
2866 # drive letters (cygwin fileutils understands them), so leave them,
2867 # especially as we might pass files found there to a mingw objdump,
2868 # which wouldn't understand a cygwinified path. Ahh.
2869 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2871 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2875 # pw32 DLLs use 'pw' prefix rather than 'lib'
2876 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2882 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2885 dynamic_linker='Win32 ld.exe'
2886 # FIXME: first we should search . and the directory the executable is in
2890 darwin* | rhapsody*)
2891 dynamic_linker="$host_os dyld"
2895 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2896 soname_spec='${libname}${release}${major}$shared_ext'
2897 shlibpath_overrides_runpath=yes
2898 shlibpath_var=DYLD_LIBRARY_PATH
2899 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2901 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2902 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2909 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2910 soname_spec='${libname}${release}${shared_ext}$major'
2911 shlibpath_var=LD_LIBRARY_PATH
2918 freebsd* | dragonfly*)
2919 # DragonFly does not have aout. When/if they implement a new
2920 # versioning mechanism, adjust this.
2921 if test -x /usr/bin/objformat; then
2922 objformat=`/usr/bin/objformat`
2925 freebsd[[123]]*) objformat=aout ;;
2929 version_type=freebsd-$objformat
2930 case $version_type in
2932 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2937 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2941 shlibpath_var=LD_LIBRARY_PATH
2944 shlibpath_overrides_runpath=yes
2946 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2947 shlibpath_overrides_runpath=yes
2948 hardcode_into_libs=yes
2950 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2951 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2952 shlibpath_overrides_runpath=no
2953 hardcode_into_libs=yes
2955 *) # from 4.6 on, and DragonFly
2956 shlibpath_overrides_runpath=yes
2957 hardcode_into_libs=yes
2966 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2967 soname_spec='${libname}${release}${shared_ext}$major'
2968 shlibpath_var=LD_LIBRARY_PATH
2969 hardcode_into_libs=yes
2972 hpux9* | hpux10* | hpux11*)
2973 # Give a soname corresponding to the major version so that dld.sl refuses to
2974 # link against other versions.
2981 hardcode_into_libs=yes
2982 dynamic_linker="$host_os dld.so"
2983 shlibpath_var=LD_LIBRARY_PATH
2984 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2985 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2986 soname_spec='${libname}${release}${shared_ext}$major'
2987 if test "X$HPUX_IA64_MODE" = X32; then
2988 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2990 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2992 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2996 hardcode_into_libs=yes
2997 dynamic_linker="$host_os dld.sl"
2998 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2999 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3000 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3001 soname_spec='${libname}${release}${shared_ext}$major'
3002 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3003 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3007 dynamic_linker="$host_os dld.sl"
3008 shlibpath_var=SHLIB_PATH
3009 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3010 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3011 soname_spec='${libname}${release}${shared_ext}$major'
3014 # HP-UX runs *really* slowly unless shared libraries are mode 555.
3015 postinstall_cmds='chmod 555 $lib'
3022 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3023 soname_spec='${libname}${release}${shared_ext}$major'
3024 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3025 shlibpath_var=LD_LIBRARY_PATH
3026 shlibpath_overrides_runpath=no
3027 hardcode_into_libs=yes
3030 irix5* | irix6* | nonstopux*)
3032 nonstopux*) version_type=nonstopux ;;
3034 if test "$lt_cv_prog_gnu_ld" = yes; then
3042 soname_spec='${libname}${release}${shared_ext}$major'
3043 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
3045 irix5* | nonstopux*)
3049 case $LD in # libtool.m4 will add one of these switches to LD
3050 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3051 libsuff= shlibsuff= libmagic=32-bit;;
3052 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3053 libsuff=32 shlibsuff=N32 libmagic=N32;;
3054 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3055 libsuff=64 shlibsuff=64 libmagic=64-bit;;
3056 *) libsuff= shlibsuff= libmagic=never-match;;
3060 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3061 shlibpath_overrides_runpath=no
3062 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
3063 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
3064 hardcode_into_libs=yes
3067 # No shared lib support for Linux oldld, aout, or coff.
3068 linux*oldld* | linux*aout* | linux*coff*)
3072 # This must be Linux ELF.
3073 linux* | k*bsd*-gnu)
3077 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3078 soname_spec='${libname}${release}${shared_ext}$major'
3079 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3080 shlibpath_var=LD_LIBRARY_PATH
3081 shlibpath_overrides_runpath=no
3082 # Some binutils ld are patched to set DT_RUNPATH
3083 save_LDFLAGS=$LDFLAGS
3085 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3086 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3087 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3088 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3089 [shlibpath_overrides_runpath=yes])])
3090 LDFLAGS=$save_LDFLAGS
3093 # This implies no fast_install, which is unacceptable.
3094 # Some rework will be needed to allow for fast_install
3095 # before this can be enabled.
3096 hardcode_into_libs=yes
3098 # Append ld.so.conf contents to the search path
3099 if test -f /etc/ld.so.conf; then
3100 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
3101 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3104 # We used to test for /lib/ld.so.1 and disable shared libraries on
3105 # powerpc, because MkLinux only supported shared libraries with the
3106 # GNU dynamic linker. Since this was broken with cross compilers,
3107 # most powerpc-linux boxes support dynamic linking these days and
3108 # people can always --disable-shared, the test was removed, and we
3109 # assume the GNU/Linux dynamic linker is in use.
3110 dynamic_linker='GNU/Linux ld.so'
3117 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3118 soname_spec='${libname}${release}${shared_ext}$major'
3119 shlibpath_var=LD_LIBRARY_PATH
3120 shlibpath_overrides_runpath=no
3121 hardcode_into_libs=yes
3122 dynamic_linker='NetBSD ld.elf_so'
3129 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
3130 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3131 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3132 dynamic_linker='NetBSD (a.out) ld.so'
3134 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3135 soname_spec='${libname}${release}${shared_ext}$major'
3136 dynamic_linker='NetBSD ld.elf_so'
3138 shlibpath_var=LD_LIBRARY_PATH
3139 shlibpath_overrides_runpath=yes
3140 hardcode_into_libs=yes
3145 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3146 shlibpath_var=LD_LIBRARY_PATH
3147 shlibpath_overrides_runpath=yes
3154 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3155 soname_spec='${libname}${release}${shared_ext}$major'
3156 shlibpath_var=LD_LIBRARY_PATH
3157 shlibpath_overrides_runpath=no
3158 hardcode_into_libs=yes
3159 dynamic_linker='ldqnx.so'
3164 sys_lib_dlsearch_path_spec="/usr/lib"
3166 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
3168 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
3169 *) need_version=no ;;
3171 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3172 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3173 shlibpath_var=LD_LIBRARY_PATH
3174 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3176 openbsd2.[[89]] | openbsd2.[[89]].*)
3177 shlibpath_overrides_runpath=no
3180 shlibpath_overrides_runpath=yes
3184 shlibpath_overrides_runpath=yes
3189 libname_spec='$name'
3192 library_names_spec='$libname${shared_ext} $libname.a'
3193 dynamic_linker='OS/2 ld.exe'
3194 shlibpath_var=LIBPATH
3197 osf3* | osf4* | osf5*)
3201 soname_spec='${libname}${release}${shared_ext}$major'
3202 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3203 shlibpath_var=LD_LIBRARY_PATH
3204 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
3205 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
3216 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3217 soname_spec='${libname}${release}${shared_ext}$major'
3218 shlibpath_var=LD_LIBRARY_PATH
3219 shlibpath_overrides_runpath=yes
3220 hardcode_into_libs=yes
3221 # ldd complains unless libraries are executable
3222 postinstall_cmds='chmod +x $lib'
3227 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3228 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
3229 shlibpath_var=LD_LIBRARY_PATH
3230 shlibpath_overrides_runpath=yes
3231 if test "$with_gnu_ld" = yes; then
3239 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3240 soname_spec='${libname}${release}${shared_ext}$major'
3241 shlibpath_var=LD_LIBRARY_PATH
3242 case $host_vendor in
3244 shlibpath_overrides_runpath=no
3246 runpath_var=LD_RUN_PATH
3254 shlibpath_overrides_runpath=no
3255 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
3261 if test -d /usr/nec ;then
3263 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
3264 soname_spec='$libname${shared_ext}.$major'
3265 shlibpath_var=LD_LIBRARY_PATH
3269 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3270 version_type=freebsd-elf
3273 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3274 soname_spec='${libname}${release}${shared_ext}$major'
3275 shlibpath_var=LD_LIBRARY_PATH
3276 shlibpath_overrides_runpath=yes
3277 hardcode_into_libs=yes
3278 if test "$with_gnu_ld" = yes; then
3279 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
3281 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
3284 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
3288 sys_lib_dlsearch_path_spec='/usr/lib'
3292 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
3296 library_name_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3297 shlibpath_var=LD_LIBRARY_PATH
3298 shlibpath_overrides_runpath=no
3299 hardcode_into_libs=yes
3304 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3305 soname_spec='${libname}${release}${shared_ext}$major'
3306 shlibpath_var=LD_LIBRARY_PATH
3313 AC_MSG_RESULT([$dynamic_linker])
3314 test "$dynamic_linker" = no && can_build_shared=no
3316 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3317 if test "$GCC" = yes; then
3318 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3321 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
3322 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
3324 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
3325 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
3328 _LT_DECL([], [variables_saved_for_relink], [1],
3329 [Variables whose values should be saved in libtool wrapper scripts and
3330 restored at link time])
3331 _LT_DECL([], [need_lib_prefix], [0],
3332 [Do we need the "lib" prefix for modules?])
3333 _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3334 _LT_DECL([], [version_type], [0], [Library versioning type])
3335 _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3336 _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3337 _LT_DECL([], [shlibpath_overrides_runpath], [0],
3338 [Is shlibpath searched before the hard-coded library search path?])
3339 _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3340 _LT_DECL([], [library_names_spec], [1],
3341 [[List of archive names. First name is the real one, the rest are links.
3342 The last name is the one that the linker finds with -lNAME]])
3343 _LT_DECL([], [soname_spec], [1],
3344 [[The coded name of the library, if different from the real name]])
3345 _LT_DECL([], [postinstall_cmds], [2],
3346 [Command to use after installation of a shared archive])
3347 _LT_DECL([], [postuninstall_cmds], [2],
3348 [Command to use after uninstallation of a shared archive])
3349 _LT_DECL([], [finish_cmds], [2],
3350 [Commands used to finish a libtool library installation in a directory])
3351 _LT_DECL([], [finish_eval], [1],
3352 [[As "finish_cmds", except a single script fragment to be evaled but
3354 _LT_DECL([], [hardcode_into_libs], [0],
3355 [Whether we should hardcode library paths into libraries])
3356 _LT_DECL([], [sys_lib_search_path_spec], [2],
3357 [Compile-time system search path for libraries])
3358 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3359 [Run-time system search path for libraries])
3360 ])# _LT_SYS_DYNAMIC_LINKER
3363 # _LT_PATH_TOOL_PREFIX(TOOL)
3364 # --------------------------
3365 # find a file program which can recognize shared library
3366 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3367 [m4_require([_LT_DECL_EGREP])dnl
3368 AC_MSG_CHECKING([for $1])
3369 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3371 [[\\/*] | ?:[\\/]*])
3372 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3375 lt_save_MAGIC_CMD="$MAGIC_CMD"
3376 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3377 dnl $ac_dummy forces splitting on constant user-supplied paths.
3378 dnl POSIX.2 word splitting is done only on the output of word expansions,
3379 dnl not every word. This closes a longstanding sh security hole.
3380 ac_dummy="m4_if([$2], , $PATH, [$2])"
3381 for ac_dir in $ac_dummy; do
3383 test -z "$ac_dir" && ac_dir=.
3384 if test -f $ac_dir/$1; then
3385 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3386 if test -n "$file_magic_test_file"; then
3387 case $deplibs_check_method in
3389 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3390 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3391 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3392 $EGREP "$file_magic_regex" > /dev/null; then
3397 *** Warning: the command libtool uses to detect shared libraries,
3398 *** $file_magic_cmd, produces output that libtool cannot recognize.
3399 *** The result is that libtool may fail to recognize shared libraries
3400 *** as such. This will affect the creation of libtool libraries that
3401 *** depend on shared libraries, but programs linked with such libtool
3402 *** libraries will work regardless of this problem. Nevertheless, you
3403 *** may want to report the problem to your system manager and/or to
3404 *** bug-libtool@gnu.org
3414 MAGIC_CMD="$lt_save_MAGIC_CMD"
3417 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3418 if test -n "$MAGIC_CMD"; then
3419 AC_MSG_RESULT($MAGIC_CMD)
3423 _LT_DECL([], [MAGIC_CMD], [0],
3424 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3425 ])# _LT_PATH_TOOL_PREFIX
3428 AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3429 dnl aclocal-1.4 backwards compatibility:
3430 dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3435 # find a file program which can recognize a shared library
3436 m4_defun([_LT_PATH_MAGIC],
3437 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3438 if test -z "$lt_cv_path_MAGIC_CMD"; then
3439 if test -n "$ac_tool_prefix"; then
3440 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3450 # find the pathname to the GNU or non-GNU linker
3451 AC_DEFUN([LT_PATH_LD],
3452 [AC_REQUIRE([AC_PROG_CC])dnl
3453 AC_REQUIRE([AC_CANONICAL_HOST])dnl
3454 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3455 m4_require([_LT_DECL_SED])dnl
3456 m4_require([_LT_DECL_EGREP])dnl
3458 AC_ARG_WITH([gnu-ld],
3459 [AS_HELP_STRING([--with-gnu-ld],
3460 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3461 [test "$withval" = no || with_gnu_ld=yes],
3462 [with_gnu_ld=no])dnl
3465 if test "$GCC" = yes; then
3466 # Check if gcc -print-prog-name=ld gives a path.
3467 AC_MSG_CHECKING([for ld used by $CC])
3470 # gcc leaves a trailing carriage return which upsets mingw
3471 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3473 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3476 # Accept absolute paths.
3477 [[\\/]]* | ?:[[\\/]]*)
3478 re_direlt='/[[^/]][[^/]]*/\.\./'
3479 # Canonicalize the pathname of ld
3480 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3481 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3482 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3484 test -z "$LD" && LD="$ac_prog"
3487 # If it fails, then pretend we aren't using GCC.
3491 # If it is relative, then search for the first ld in PATH.
3495 elif test "$with_gnu_ld" = yes; then
3496 AC_MSG_CHECKING([for GNU ld])
3498 AC_MSG_CHECKING([for non-GNU ld])
3500 AC_CACHE_VAL(lt_cv_path_LD,
3501 [if test -z "$LD"; then
3502 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3503 for ac_dir in $PATH; do
3505 test -z "$ac_dir" && ac_dir=.
3506 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3507 lt_cv_path_LD="$ac_dir/$ac_prog"
3508 # Check to see if the program is GNU ld. I'd rather use --version,
3509 # but apparently some variants of GNU ld only accept -v.
3510 # Break only if it was the GNU/non-GNU ld that we prefer.
3511 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3512 *GNU* | *'with BFD'*)
3513 test "$with_gnu_ld" != no && break
3516 test "$with_gnu_ld" != yes && break
3523 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3526 if test -n "$LD"; then
3531 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3535 _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3539 AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3540 AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3541 dnl aclocal-1.4 backwards compatibility:
3542 dnl AC_DEFUN([AM_PROG_LD], [])
3543 dnl AC_DEFUN([AC_PROG_LD], [])
3548 m4_defun([_LT_PATH_LD_GNU],
3549 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3550 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
3551 case `$LD -v 2>&1 </dev/null` in
3552 *GNU* | *'with BFD'*)
3553 lt_cv_prog_gnu_ld=yes
3556 lt_cv_prog_gnu_ld=no
3559 with_gnu_ld=$lt_cv_prog_gnu_ld
3565 # find reload flag for linker
3566 # -- PORTME Some linkers may need a different reload flag.
3567 m4_defun([_LT_CMD_RELOAD],
3568 [AC_CACHE_CHECK([for $LD option to reload object files],
3569 lt_cv_ld_reload_flag,
3570 [lt_cv_ld_reload_flag='-r'])
3571 reload_flag=$lt_cv_ld_reload_flag
3572 case $reload_flag in
3574 *) reload_flag=" $reload_flag" ;;
3576 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3579 if test "$GCC" = yes; then
3580 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3582 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3586 _LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3587 _LT_DECL([], [reload_cmds], [2])dnl
3591 # _LT_CHECK_MAGIC_METHOD
3592 # ----------------------
3593 # how to check for library dependencies
3594 # -- PORTME fill in with the dynamic library characteristics
3595 m4_defun([_LT_CHECK_MAGIC_METHOD],
3596 [m4_require([_LT_DECL_EGREP])
3597 AC_CACHE_CHECK([how to recognize dependent libraries],
3598 lt_cv_deplibs_check_method,
3599 [lt_cv_file_magic_cmd='$MAGIC_CMD'
3600 lt_cv_file_magic_test_file=
3601 lt_cv_deplibs_check_method='unknown'
3602 # Need to set the preceding variable on all platforms that support
3603 # interlibrary dependencies.
3604 # 'none' -- dependencies not supported.
3605 # `unknown' -- same as none, but documents that we really don't know.
3606 # 'pass_all' -- all dependencies passed with no checks.
3607 # 'test_compile' -- check by making test program.
3608 # 'file_magic [[regex]]' -- check by looking for files in library path
3609 # which responds to the $file_magic_cmd with a given extended regex.
3610 # If you have `file' or equivalent on your system and you're not sure
3611 # whether `pass_all' will *always* work, you probably want this one.
3615 lt_cv_deplibs_check_method=pass_all
3619 lt_cv_deplibs_check_method=pass_all
3623 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3624 lt_cv_file_magic_cmd='/usr/bin/file -L'
3625 lt_cv_file_magic_test_file=/shlib/libc.so
3629 # func_win32_libid is a shell function defined in ltmain.sh
3630 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3631 lt_cv_file_magic_cmd='func_win32_libid'
3635 # Base MSYS/MinGW do not provide the 'file' command needed by
3636 # func_win32_libid shell function, so use a weaker test based on 'objdump',
3637 # unless we find 'file', for example because we are cross-compiling.
3638 if ( file / ) >/dev/null 2>&1; then
3639 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3640 lt_cv_file_magic_cmd='func_win32_libid'
3642 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3643 lt_cv_file_magic_cmd='$OBJDUMP -f'
3647 darwin* | rhapsody*)
3648 lt_cv_deplibs_check_method=pass_all
3651 freebsd* | dragonfly*)
3652 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3655 # Not sure whether the presence of OpenBSD here was a mistake.
3656 # Let's accept both of them until this is cleared up.
3657 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3658 lt_cv_file_magic_cmd=/usr/bin/file
3659 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3663 lt_cv_deplibs_check_method=pass_all
3668 lt_cv_deplibs_check_method=pass_all
3671 hpux10.20* | hpux11*)
3672 lt_cv_file_magic_cmd=/usr/bin/file
3675 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3676 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3679 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
3680 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3683 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3684 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3690 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3691 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3694 irix5* | irix6* | nonstopux*)
3696 *-32|*"-32 ") libmagic=32-bit;;
3697 *-n32|*"-n32 ") libmagic=N32;;
3698 *-64|*"-64 ") libmagic=64-bit;;
3699 *) libmagic=never-match;;
3701 lt_cv_deplibs_check_method=pass_all
3704 # This must be Linux ELF.
3705 linux* | k*bsd*-gnu)
3706 lt_cv_deplibs_check_method=pass_all
3709 netbsd* | netbsdelf*-gnu)
3710 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3711 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3713 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3718 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3719 lt_cv_file_magic_cmd=/usr/bin/file
3720 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3724 lt_cv_deplibs_check_method=pass_all
3728 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3729 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3731 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3735 osf3* | osf4* | osf5*)
3736 lt_cv_deplibs_check_method=pass_all
3740 lt_cv_deplibs_check_method=pass_all
3744 lt_cv_deplibs_check_method=pass_all
3747 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3748 lt_cv_deplibs_check_method=pass_all
3752 case $host_vendor in
3754 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]]'
3755 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3758 lt_cv_deplibs_check_method=pass_all
3761 lt_cv_file_magic_cmd='/bin/file'
3762 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3765 lt_cv_file_magic_cmd='/bin/file'
3766 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3767 lt_cv_file_magic_test_file=/lib/libc.so
3770 lt_cv_deplibs_check_method=pass_all
3773 lt_cv_deplibs_check_method=pass_all
3779 lt_cv_deplibs_check_method=pass_all
3783 file_magic_cmd=$lt_cv_file_magic_cmd
3784 deplibs_check_method=$lt_cv_deplibs_check_method
3785 test -z "$deplibs_check_method" && deplibs_check_method=unknown
3787 _LT_DECL([], [deplibs_check_method], [1],
3788 [Method to check whether dependent libraries are shared objects])
3789 _LT_DECL([], [file_magic_cmd], [1],
3790 [Command to use when deplibs_check_method == "file_magic"])
3791 ])# _LT_CHECK_MAGIC_METHOD
3796 # find the pathname to a BSD- or MS-compatible name lister
3797 AC_DEFUN([LT_PATH_NM],
3798 [AC_REQUIRE([AC_PROG_CC])dnl
3799 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
3800 [if test -n "$NM"; then
3801 # Let the user override the test.
3804 lt_nm_to_check="${ac_tool_prefix}nm"
3805 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3806 lt_nm_to_check="$lt_nm_to_check nm"
3808 for lt_tmp_nm in $lt_nm_to_check; do
3809 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3810 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3812 test -z "$ac_dir" && ac_dir=.
3813 tmp_nm="$ac_dir/$lt_tmp_nm"
3814 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3815 # Check to see if the nm accepts a BSD-compat flag.
3816 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3817 # nm: unknown option "B" ignored
3818 # Tru64's nm complains that /dev/null is an invalid object file
3819 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3820 */dev/null* | *'Invalid file or object type'*)
3821 lt_cv_path_NM="$tmp_nm -B"
3825 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3827 lt_cv_path_NM="$tmp_nm -p"
3831 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3832 continue # so that we can try to find one that supports BSD flags
3841 : ${lt_cv_path_NM=no}
3843 if test "$lt_cv_path_NM" != "no"; then
3846 # Didn't find any BSD compatible name lister, look for dumpbin.
3847 AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
3849 if test "$DUMPBIN" != ":"; then
3853 test -z "$NM" && NM=nm
3855 _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
3857 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
3858 [lt_cv_nm_interface="BSD nm"
3859 echo "int some_variable = 0;" > conftest.$ac_ext
3860 (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
3861 (eval "$ac_compile" 2>conftest.err)
3862 cat conftest.err >&AS_MESSAGE_LOG_FD
3863 (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
3864 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
3865 cat conftest.err >&AS_MESSAGE_LOG_FD
3866 (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
3867 cat conftest.out >&AS_MESSAGE_LOG_FD
3868 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
3869 lt_cv_nm_interface="MS dumpbin"
3875 AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
3876 AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
3877 dnl aclocal-1.4 backwards compatibility:
3878 dnl AC_DEFUN([AM_PROG_NM], [])
3879 dnl AC_DEFUN([AC_PROG_NM], [])
3884 # check for math library
3885 AC_DEFUN([LT_LIB_M],
3886 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3889 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3890 # These system don't have libm, or don't need it
3893 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3894 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3897 AC_CHECK_LIB(m, cos, LIBM="-lm")
3904 AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
3905 dnl aclocal-1.4 backwards compatibility:
3906 dnl AC_DEFUN([AC_CHECK_LIBM], [])
3909 # _LT_COMPILER_NO_RTTI([TAGNAME])
3910 # -------------------------------
3911 m4_defun([_LT_COMPILER_NO_RTTI],
3912 [m4_require([_LT_TAG_COMPILER])dnl
3914 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3916 if test "$GCC" = yes; then
3917 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3919 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
3920 lt_cv_prog_compiler_rtti_exceptions,
3921 [-fno-rtti -fno-exceptions], [],
3922 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
3924 _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
3925 [Compiler flag to turn off builtin functions])
3926 ])# _LT_COMPILER_NO_RTTI
3929 # _LT_CMD_GLOBAL_SYMBOLS
3930 # ----------------------
3931 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
3932 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
3933 AC_REQUIRE([AC_PROG_CC])dnl
3934 AC_REQUIRE([LT_PATH_NM])dnl
3935 AC_REQUIRE([LT_PATH_LD])dnl
3936 m4_require([_LT_DECL_SED])dnl
3937 m4_require([_LT_DECL_EGREP])dnl
3938 m4_require([_LT_TAG_COMPILER])dnl
3940 # Check for command to grab the raw symbol name followed by C symbol from nm.
3941 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
3942 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
3944 # These are sane defaults that work on at least a few old systems.
3945 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
3947 # Character class describing NM global symbol codes.
3948 symcode='[[BCDEGRST]]'
3950 # Regexp to match symbols that can be accessed directly from C.
3951 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
3953 # Define system-specific variables.
3958 cygwin* | mingw* | pw32*)
3959 symcode='[[ABCDGISTW]]'
3962 if test "$host_cpu" = ia64; then
3963 symcode='[[ABCDEGRST]]'
3967 symcode='[[BCDEGRST]]'
3970 symcode='[[BCDEGQRST]]'
3981 sysv5* | sco5v6* | unixware* | OpenUNIX*)
3985 symcode='[[DFNSTU]]'
3989 # If we're using GNU nm, then use its standard symbol codes.
3990 case `$NM -V 2>&1` in
3991 *GNU* | *'with BFD'*)
3992 symcode='[[ABCDGIRSTW]]' ;;
3995 # Transform an extracted symbol line into a proper C declaration.
3996 # Some systems (esp. on ia64) link data and code symbols differently,
3997 # so use this general approach.
3998 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4000 # Transform an extracted symbol line into symbol name and symbol address
4001 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
4002 lt_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'"
4004 # Handle CRLF in mingw tool chain
4008 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4012 # Try without a prefix underscore, then with it.
4013 for ac_symprfx in "" "_"; do
4015 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4016 symxfrm="\\1 $ac_symprfx\\2 \\2"
4018 # Write the raw and C identifiers.
4019 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
4020 # Fake it for dumpbin and say T for any non-static function
4021 # and D for any global variable.
4022 # Also find C++ and __fastcall symbols from MSVC++,
4023 # which start with @ or ?.
4024 lt_cv_sys_global_symbol_pipe="$AWK ['"\
4025 " {last_section=section; section=\$ 3};"\
4026 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
4027 " \$ 0!~/External *\|/{next};"\
4028 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
4029 " {if(hide[section]) next};"\
4030 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
4031 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
4032 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
4033 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
4034 " ' prfx=^$ac_symprfx]"
4036 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4039 # Check to see that the pipe works correctly.
4043 cat > conftest.$ac_ext <<_LT_EOF
4048 void nm_test_func(void);
4049 void nm_test_func(void){}
4053 int main(){nm_test_var='a';nm_test_func();return(0);}
4056 if AC_TRY_EVAL(ac_compile); then
4057 # Now try to grab the symbols.
4059 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
4060 # Try sorting and uniquifying the output.
4061 if sort "$nlist" | uniq > "$nlist"T; then
4062 mv -f "$nlist"T "$nlist"
4067 # Make sure that we snagged all the symbols we need.
4068 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
4069 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
4070 cat <<_LT_EOF > conftest.$ac_ext
4076 # Now generate the symbol file.
4077 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
4079 cat <<_LT_EOF >> conftest.$ac_ext
4081 /* The mapping between symbol names and symbols. */
4086 lt__PROGRAM__LTX_preloaded_symbols[[]] =
4088 { "@PROGRAM@", (void *) 0 },
4090 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4091 cat <<\_LT_EOF >> conftest.$ac_ext
4095 /* This works around a problem in FreeBSD linker */
4096 #ifdef FREEBSD_WORKAROUND
4097 static const void *lt_preloaded_setup() {
4098 return lt__PROGRAM__LTX_preloaded_symbols;
4106 # Now try linking the two files.
4107 mv conftest.$ac_objext conftstm.$ac_objext
4108 lt_save_LIBS="$LIBS"
4109 lt_save_CFLAGS="$CFLAGS"
4110 LIBS="conftstm.$ac_objext"
4111 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4112 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4115 LIBS="$lt_save_LIBS"
4116 CFLAGS="$lt_save_CFLAGS"
4118 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4121 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4124 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4127 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4128 cat conftest.$ac_ext >&5
4130 rm -rf conftest* conftst*
4132 # Do not use the global_symbol_pipe unless it works.
4133 if test "$pipe_works" = yes; then
4136 lt_cv_sys_global_symbol_pipe=
4140 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4141 lt_cv_sys_global_symbol_to_cdecl=
4143 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4144 AC_MSG_RESULT(failed)
4149 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
4150 [Take the output of nm and produce a listing of raw symbols and C names])
4151 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
4152 [Transform the output of nm in a proper C declaration])
4153 _LT_DECL([global_symbol_to_c_name_address],
4154 [lt_cv_sys_global_symbol_to_c_name_address], [1],
4155 [Transform the output of nm in a C name address pair])
4156 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
4157 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
4158 [Transform the output of nm in a C name address pair when lib prefix is needed])
4159 ]) # _LT_CMD_GLOBAL_SYMBOLS
4162 # _LT_COMPILER_PIC([TAGNAME])
4163 # ---------------------------
4164 m4_defun([_LT_COMPILER_PIC],
4165 [m4_require([_LT_TAG_COMPILER])dnl
4166 _LT_TAGVAR(lt_prog_compiler_wl, $1)=
4167 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4168 _LT_TAGVAR(lt_prog_compiler_static, $1)=
4170 AC_MSG_CHECKING([for $compiler option to produce PIC])
4171 m4_if([$1], [CXX], [
4172 # C++ specific cases for pic, static, wl, etc.
4173 if test "$GXX" = yes; then
4174 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4175 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4179 # All AIX code is PIC.
4180 if test "$host_cpu" = ia64; then
4181 # AIX 5 now supports IA64 processor
4182 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4189 # see comment about AmigaOS4 .so support
4190 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4193 # FIXME: we need at least 68020 code to build shared libraries, but
4194 # adding the `-m68020' flag to GCC prevents building anything better,
4196 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4201 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4202 # PIC is the default for these OSes.
4204 mingw* | cygwin* | os2* | pw32*)
4205 # This hack is so that the source file can tell whether it is being
4206 # built for inclusion in a dll (and should export symbols for example).
4207 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4208 # (--disable-auto-import) libraries
4209 m4_if([$1], [GCJ], [],
4210 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4212 darwin* | rhapsody*)
4213 # PIC is the default on this platform
4214 # Common symbols not allowed in MH_DYLIB files
4215 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4218 # DJGPP does not support shared libraries at all
4219 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4222 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4223 # Instead, we relocate shared libraries at runtime.
4226 if test -d /usr/nec; then
4227 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4231 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4237 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4242 # QNX uses GNU C++, but need to define -shared option too, otherwise
4244 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4247 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4253 # All AIX code is PIC.
4254 if test "$host_cpu" = ia64; then
4255 # AIX 5 now supports IA64 processor
4256 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4258 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4262 case $cc_basename in
4264 # Green Hills C++ Compiler
4265 # _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"
4270 case $cc_basename in
4272 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4275 # Green Hills C++ Compiler
4276 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4282 freebsd* | dragonfly*)
4283 # FreeBSD uses GNU C++
4285 hpux9* | hpux10* | hpux11*)
4286 case $cc_basename in
4288 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4289 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4290 if test "$host_cpu" != ia64; then
4291 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4295 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4296 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4302 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4311 # This is c89, which is MS Visual C++ (no shared libs)
4312 # Anyone wants to do a port?
4314 irix5* | irix6* | nonstopux*)
4315 case $cc_basename in
4317 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4318 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4319 # CC pic flag -KPIC is the default.
4325 linux* | k*bsd*-gnu)
4326 case $cc_basename in
4329 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4330 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4334 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4335 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4336 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4339 # Portland Group C++ compiler
4340 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4341 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4342 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4346 # Make sure the PIC flag is empty. It appears that all Alpha
4347 # Linux and Compaq Tru64 Unix objects are PIC.
4348 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4349 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4353 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4354 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4355 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4358 case `$CC -V 2>&1 | sed 5q` in
4361 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4362 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4363 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4374 case $cc_basename in
4376 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4382 netbsd* | netbsdelf*-gnu)
4385 # QNX uses GNU C++, but need to define -shared option too, otherwise
4387 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4389 osf3* | osf4* | osf5*)
4390 case $cc_basename in
4392 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4395 # Rational C++ 2.4.1
4396 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4399 # Digital/Compaq C++
4400 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4401 # Make sure the PIC flag is empty. It appears that all Alpha
4402 # Linux and Compaq Tru64 Unix objects are PIC.
4403 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4404 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4413 case $cc_basename in
4415 # Sun C++ 4.2, 5.x and Centerline C++
4416 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4417 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4418 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4421 # Green Hills C++ Compiler
4422 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4429 case $cc_basename in
4432 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4433 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4437 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4443 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4444 case $cc_basename in
4446 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4447 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4448 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4453 case $cc_basename in
4455 # NonStop-UX NCC 3.20
4456 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4465 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4471 if test "$GCC" = yes; then
4472 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4473 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4477 # All AIX code is PIC.
4478 if test "$host_cpu" = ia64; then
4479 # AIX 5 now supports IA64 processor
4480 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4487 # see comment about AmigaOS4 .so support
4488 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4491 # FIXME: we need at least 68020 code to build shared libraries, but
4492 # adding the `-m68020' flag to GCC prevents building anything better,
4494 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4499 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4500 # PIC is the default for these OSes.
4503 mingw* | cygwin* | pw32* | os2*)
4504 # This hack is so that the source file can tell whether it is being
4505 # built for inclusion in a dll (and should export symbols for example).
4506 # Although the cygwin gcc ignores -fPIC, still need this for old-style
4507 # (--disable-auto-import) libraries
4508 m4_if([$1], [GCJ], [],
4509 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4512 darwin* | rhapsody*)
4513 # PIC is the default on this platform
4514 # Common symbols not allowed in MH_DYLIB files
4515 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4519 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4526 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4532 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
4533 # Instead, we relocate shared libraries at runtime.
4537 # Just because we use GCC doesn't mean we suddenly get shared libraries
4538 # on systems that don't support them.
4539 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4544 # QNX uses GNU C++, but need to define -shared option too, otherwise
4546 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4550 if test -d /usr/nec; then
4551 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4556 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4560 # PORTME Check for flag to pass linker flags through the system compiler.
4563 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4564 if test "$host_cpu" = ia64; then
4565 # AIX 5 now supports IA64 processor
4566 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4568 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4572 mingw* | cygwin* | pw32* | os2*)
4573 # This hack is so that the source file can tell whether it is being
4574 # built for inclusion in a dll (and should export symbols for example).
4575 m4_if([$1], [GCJ], [],
4576 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4579 hpux9* | hpux10* | hpux11*)
4580 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4581 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4588 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4591 # Is there a better lt_prog_compiler_static that works with the bundled CC?
4592 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4595 irix5* | irix6* | nonstopux*)
4596 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4597 # PIC (with -KPIC) is the default.
4598 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4601 linux* | k*bsd*-gnu)
4602 case $cc_basename in
4603 icc* | ecc* | ifort*)
4604 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4605 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4606 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4608 pgcc* | pgf77* | pgf90* | pgf95*)
4609 # Portland Group compilers (*not* the Pentium gcc compiler,
4610 # which looks to be a dead project)
4611 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4612 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4613 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4616 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4617 # All Alpha code is PIC.
4618 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4621 # IBM XL C 8.0/Fortran 10.1 on PPC
4622 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4623 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
4624 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
4627 case `$CC -V 2>&1 | sed 5q` in
4630 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4631 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4632 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4635 # Sun Fortran 8.3 passes all unrecognized flags to the linker
4636 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4637 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4638 _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
4646 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4647 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4651 # QNX uses GNU C++, but need to define -shared option too, otherwise
4653 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
4656 osf3* | osf4* | osf5*)
4657 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4658 # All OSF/1 code is PIC.
4659 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4663 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4667 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4668 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4669 case $cc_basename in
4671 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
4673 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
4678 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
4679 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4680 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4683 sysv4 | sysv4.2uw2* | sysv4.3*)
4684 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4685 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4686 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4690 if test -d /usr/nec ;then
4691 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
4692 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4696 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
4697 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4698 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4699 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4703 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4704 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4708 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4709 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4713 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
4719 # For platforms which do not support PIC, -DPIC is meaningless:
4721 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
4724 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
4727 AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
4728 _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
4729 [How to pass a linker flag through the compiler])
4732 # Check to make sure the PIC flag actually works.
4734 if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
4735 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
4736 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
4737 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
4738 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
4740 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
4742 [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
4743 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
4745 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
4746 [Additional compiler flags for building library objects])
4749 # Check to make sure the static flag actually works.
4751 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
4752 _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
4753 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
4754 $lt_tmp_static_flag,
4756 [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
4757 _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
4758 [Compiler flag to prevent dynamic linking])
4759 ])# _LT_COMPILER_PIC
4762 # _LT_LINKER_SHLIBS([TAGNAME])
4763 # ----------------------------
4764 # See if the linker supports building shared libraries.
4765 m4_defun([_LT_LINKER_SHLIBS],
4766 [AC_REQUIRE([LT_PATH_LD])dnl
4767 AC_REQUIRE([LT_PATH_NM])dnl
4768 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
4769 m4_require([_LT_DECL_EGREP])dnl
4770 m4_require([_LT_DECL_SED])dnl
4771 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
4772 m4_require([_LT_TAG_COMPILER])dnl
4773 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
4774 m4_if([$1], [CXX], [
4775 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4778 # If we're using GNU nm, then we don't want the "-C" option.
4779 # -C means demangle to AIX nm, but means don't demangle with GNU nm
4780 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4781 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4783 _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'
4787 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4790 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
4792 linux* | k*bsd*-gnu)
4793 _LT_TAGVAR(link_all_deplibs, $1)=no
4796 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4799 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4802 _LT_TAGVAR(allow_undefined_flag, $1)=
4803 _LT_TAGVAR(always_export_symbols, $1)=no
4804 _LT_TAGVAR(archive_cmds, $1)=
4805 _LT_TAGVAR(archive_expsym_cmds, $1)=
4806 _LT_TAGVAR(compiler_needs_object, $1)=no
4807 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
4808 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
4809 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4810 _LT_TAGVAR(hardcode_automatic, $1)=no
4811 _LT_TAGVAR(hardcode_direct, $1)=no
4812 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
4813 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
4814 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
4815 _LT_TAGVAR(hardcode_libdir_separator, $1)=
4816 _LT_TAGVAR(hardcode_minus_L, $1)=no
4817 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4818 _LT_TAGVAR(inherit_rpath, $1)=no
4819 _LT_TAGVAR(link_all_deplibs, $1)=unknown
4820 _LT_TAGVAR(module_cmds, $1)=
4821 _LT_TAGVAR(module_expsym_cmds, $1)=
4822 _LT_TAGVAR(old_archive_from_new_cmds, $1)=
4823 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
4824 _LT_TAGVAR(thread_safe_flag_spec, $1)=
4825 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4826 # include_expsyms should be a list of space-separated symbols to be *always*
4827 # included in the symbol list
4828 _LT_TAGVAR(include_expsyms, $1)=
4829 # exclude_expsyms can be an extended regexp of symbols to exclude
4830 # it will be wrapped by ` (' and `)$', so one must not match beginning or
4831 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4832 # as well as any symbol that contains `d'.
4833 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
4834 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4835 # platforms (ab)use it in PIC code, but their linkers get confused if
4836 # the symbol is explicitly referenced. Since portable code cannot
4837 # rely on this symbol name, it's probably fine to never include it in
4838 # preloaded symbol tables.
4839 # Exclude shared library initialization/finalization symbols.
4840 dnl Note also adjust exclude_expsyms for C++ above.
4841 extract_expsyms_cmds=
4844 cygwin* | mingw* | pw32*)
4845 # FIXME: the MSVC++ port hasn't been tested in a loooong time
4846 # When not using gcc, we currently assume that we are using
4847 # Microsoft Visual C++.
4848 if test "$GCC" != yes; then
4853 # we just hope/assume this is gcc and not c89 (= MSVC++)
4861 _LT_TAGVAR(ld_shlibs, $1)=yes
4862 if test "$with_gnu_ld" = yes; then
4863 # If archive_cmds runs LD, not CC, wlarc should be empty
4866 # Set some defaults for GNU ld with shared library support. These
4867 # are reset later if shared libraries are not supported. Putting them
4868 # here allows them to be overridden if necessary.
4869 runpath_var=LD_RUN_PATH
4870 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4871 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4872 # ancient GNU ld didn't support --whole-archive et. al.
4873 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
4874 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4876 _LT_TAGVAR(whole_archive_flag_spec, $1)=
4878 supports_anon_versioning=no
4879 case `$LD -v 2>&1` in
4880 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
4881 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
4882 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
4883 *\ 2.11.*) ;; # other 2.11 versions
4884 *) supports_anon_versioning=yes ;;
4887 # See if GNU ld supports shared libraries.
4890 # On AIX/PPC, the GNU linker is very broken
4891 if test "$host_cpu" != ia64; then
4892 _LT_TAGVAR(ld_shlibs, $1)=no
4895 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
4896 *** to be unable to reliably create shared libraries on AIX.
4897 *** Therefore, libtool is disabling shared libraries support. If you
4898 *** really care for shared libraries, you may want to modify your PATH
4899 *** so that a non-GNU linker is found, and then restart.
4908 # see comment about AmigaOS4 .so support
4909 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4910 _LT_TAGVAR(archive_expsym_cmds, $1)=''
4913 _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)'
4914 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4915 _LT_TAGVAR(hardcode_minus_L, $1)=yes
4921 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4922 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4923 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
4924 # support --undefined. This deserves some investigation. FIXME
4925 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4927 _LT_TAGVAR(ld_shlibs, $1)=no
4931 cygwin* | mingw* | pw32*)
4932 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4933 # as there is no search path for DLLs.
4934 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4935 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
4936 _LT_TAGVAR(always_export_symbols, $1)=no
4937 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4938 _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'
4940 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
4941 _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'
4942 # If the export-symbols file already is a .def file (1st line
4943 # is EXPORTS), use it as is; otherwise, prepend...
4944 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
4945 cp $export_symbols $output_objdir/$soname.def;
4947 echo EXPORTS > $output_objdir/$soname.def;
4948 cat $export_symbols >> $output_objdir/$soname.def;
4950 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4952 _LT_TAGVAR(ld_shlibs, $1)=no
4957 _LT_TAGVAR(hardcode_direct, $1)=no
4958 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4959 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4960 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4961 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4962 # Instead, shared libraries are loaded at an image base (0x10000000 by
4963 # default) and relocated if they conflict, which is a slow very memory
4964 # consuming and fragmenting process. To avoid this, we pick a random,
4965 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4966 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
4967 _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'
4968 _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'
4971 gnu* | linux* | tpf* | k*bsd*-gnu)
4973 if test "$host_os" = linux-dietlibc; then
4974 case $cc_basename in
4975 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
4978 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
4979 && test "$tmp_diet" = no
4982 tmp_sharedflag='-shared'
4983 case $cc_basename,$host_cpu in
4984 pgcc*) # Portland Group C compiler
4985 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
4986 tmp_addflag=' $pic_flag'
4988 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
4989 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
4990 tmp_addflag=' $pic_flag -Mnomain' ;;
4991 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
4992 tmp_addflag=' -i_dynamic' ;;
4993 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
4994 tmp_addflag=' -i_dynamic -nofor_main' ;;
4995 ifc* | ifort*) # Intel Fortran compiler
4996 tmp_addflag=' -nofor_main' ;;
4997 xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
4998 tmp_sharedflag='-qmkshrobj'
5001 case `$CC -V 2>&1 | sed 5q` in
5002 *Sun\ C*) # Sun C 5.9
5003 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
5004 _LT_TAGVAR(compiler_needs_object, $1)=yes
5005 tmp_sharedflag='-G' ;;
5006 *Sun\ F*) # Sun Fortran 8.3
5007 tmp_sharedflag='-G' ;;
5009 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5011 if test "x$supports_anon_versioning" = xyes; then
5012 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5013 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5014 echo "local: *; };" >> $output_objdir/$libname.ver~
5015 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5018 case $cc_basename in
5020 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
5021 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
5022 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5023 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
5024 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
5025 if test "x$supports_anon_versioning" = xyes; then
5026 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
5027 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5028 echo "local: *; };" >> $output_objdir/$libname.ver~
5029 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5034 _LT_TAGVAR(ld_shlibs, $1)=no
5038 netbsd* | netbsdelf*-gnu)
5039 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5040 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5043 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5044 _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'
5049 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
5050 _LT_TAGVAR(ld_shlibs, $1)=no
5053 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5054 *** create shared libraries on Solaris systems. Therefore, libtool
5055 *** is disabling shared libraries support. We urge you to upgrade GNU
5056 *** binutils to release 2.9.1 or newer. Another option is to modify
5057 *** your PATH or compiler configuration so that the native linker is
5058 *** used, and then restart.
5061 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5062 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5063 _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'
5065 _LT_TAGVAR(ld_shlibs, $1)=no
5069 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
5070 case `$LD -v 2>&1` in
5071 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
5072 _LT_TAGVAR(ld_shlibs, $1)=no
5075 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
5076 *** reliably create shared libraries on SCO systems. Therefore, libtool
5077 *** is disabling shared libraries support. We urge you to upgrade GNU
5078 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
5079 *** your PATH or compiler configuration so that the native linker is
5080 *** used, and then restart.
5085 # For security reasons, it is highly recommended that you always
5086 # use absolute paths for naming shared libraries, and exclude the
5087 # DT_RUNPATH tag from executables and libraries. But doing so
5088 # requires that you compile everything twice, which is a pain.
5089 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5090 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5091 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5092 _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'
5094 _LT_TAGVAR(ld_shlibs, $1)=no
5101 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5103 _LT_TAGVAR(hardcode_direct, $1)=yes
5104 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5108 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
5109 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5110 _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'
5112 _LT_TAGVAR(ld_shlibs, $1)=no
5117 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
5119 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5120 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5121 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5124 # PORTME fill in a description of your system's linker (not GNU ld)
5127 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5128 _LT_TAGVAR(always_export_symbols, $1)=yes
5129 _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'
5130 # Note: this linker hardcodes the directories in LIBPATH if there
5131 # are no directories specified by -L.
5132 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5133 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5134 # Neither direct hardcoding nor static linking is supported with a
5136 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5141 if test "$host_cpu" = ia64; then
5142 # On IA64, the linker does run time linking by default, so we don't
5143 # have to do anything special.
5144 aix_use_runtimelinking=no
5145 exp_sym_flag='-Bexport'
5148 # If we're using GNU nm, then we don't want the "-C" option.
5149 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5150 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
5151 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5153 _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'
5155 aix_use_runtimelinking=no
5157 # Test if we are trying to use run time linking or normal
5158 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5159 # need to do runtime linking.
5160 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
5161 for ld_flag in $LDFLAGS; do
5162 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5163 aix_use_runtimelinking=yes
5170 exp_sym_flag='-bexport'
5171 no_entry_flag='-bnoentry'
5174 # When large executables or shared objects are built, AIX ld can
5175 # have problems creating the table of contents. If linking a library
5176 # or program results in "error TOC overflow" add -mminimal-toc to
5177 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5178 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5180 _LT_TAGVAR(archive_cmds, $1)=''
5181 _LT_TAGVAR(hardcode_direct, $1)=yes
5182 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5183 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5184 _LT_TAGVAR(link_all_deplibs, $1)=yes
5185 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5187 if test "$GCC" = yes; then
5188 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5189 # We only want to do this on AIX 4.2 and lower, the check
5190 # below for broken collect2 doesn't work under 4.3+
5191 collect2name=`${CC} -print-prog-name=collect2`
5192 if test -f "$collect2name" &&
5193 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
5195 # We have reworked collect2
5198 # We have old collect2
5199 _LT_TAGVAR(hardcode_direct, $1)=unsupported
5200 # It fails to find uninstalled libraries when the uninstalled
5201 # path is not listed in the libpath. Setting hardcode_minus_L
5202 # to unsupported forces relinking
5203 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5204 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5205 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5209 shared_flag='-shared'
5210 if test "$aix_use_runtimelinking" = yes; then
5211 shared_flag="$shared_flag "'${wl}-G'
5213 _LT_TAGVAR(link_all_deplibs, $1)=no
5216 if test "$host_cpu" = ia64; then
5217 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5218 # chokes on -Wl,-G. The following line is correct:
5221 if test "$aix_use_runtimelinking" = yes; then
5222 shared_flag='${wl}-G'
5224 shared_flag='${wl}-bM:SRE'
5229 # It seems that -bexpall does not export symbols beginning with
5230 # underscore (_), so it is better to generate a list of symbols to export.
5231 _LT_TAGVAR(always_export_symbols, $1)=yes
5232 if test "$aix_use_runtimelinking" = yes; then
5233 # Warning - without using the other runtime loading flags (-brtl),
5234 # -berok will link without error, but may produce a broken library.
5235 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
5236 # Determine the default libpath from the value encoded in an
5238 _LT_SYS_MODULE_PATH_AIX
5239 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5240 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5242 if test "$host_cpu" = ia64; then
5243 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5244 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5245 _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"
5247 # Determine the default libpath from the value encoded in an
5249 _LT_SYS_MODULE_PATH_AIX
5250 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5251 # Warning - without using the other run time loading flags,
5252 # -berok will link without error, but may produce a broken library.
5253 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5254 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5255 # Exported symbols can be pulled into shared objects from archives
5256 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
5257 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5258 # This is similar to how AIX traditionally builds its shared libraries.
5259 _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'
5267 # see comment about AmigaOS4 .so support
5268 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5269 _LT_TAGVAR(archive_expsym_cmds, $1)=''
5272 _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)'
5273 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5274 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5280 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5283 cygwin* | mingw* | pw32*)
5284 # When not using gcc, we currently assume that we are using
5285 # Microsoft Visual C++.
5286 # hardcode_libdir_flag_spec is actually meaningless, as there is
5287 # no search path for DLLs.
5288 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5289 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5290 # Tell ltmain to make .lib files, not .a files.
5292 # Tell ltmain to make .dll files, not .so files.
5294 # FIXME: Setting linknames here is a bad hack.
5295 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
5296 # The linker will automatically build a .lib file if we build a DLL.
5297 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
5298 # FIXME: Should let the user specify the lib program.
5299 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
5300 _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
5301 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5304 darwin* | rhapsody*)
5305 _LT_DARWIN_LINKER_FEATURES($1)
5309 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5310 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5311 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5315 _LT_TAGVAR(ld_shlibs, $1)=no
5318 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
5319 # support. Future versions do this automatically, but an explicit c++rt0.o
5320 # does not break anything, and helps significantly (at the cost of a little
5323 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
5324 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5325 _LT_TAGVAR(hardcode_direct, $1)=yes
5326 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5329 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
5331 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5332 _LT_TAGVAR(hardcode_direct, $1)=yes
5333 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5334 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5337 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
5338 freebsd* | dragonfly*)
5339 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
5340 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5341 _LT_TAGVAR(hardcode_direct, $1)=yes
5342 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5346 if test "$GCC" = yes; then
5347 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5349 _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'
5351 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5352 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5353 _LT_TAGVAR(hardcode_direct, $1)=yes
5355 # hardcode_minus_L: Not really in the search PATH,
5356 # but as the default location of the library.
5357 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5358 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5362 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
5363 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5365 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
5367 if test "$with_gnu_ld" = no; then
5368 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5369 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
5370 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5371 _LT_TAGVAR(hardcode_direct, $1)=yes
5372 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5373 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5374 # hardcode_minus_L: Not really in the search PATH,
5375 # but as the default location of the library.
5376 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5381 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
5384 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5387 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5390 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5396 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5399 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5402 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5406 if test "$with_gnu_ld" = no; then
5407 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5408 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5412 _LT_TAGVAR(hardcode_direct, $1)=no
5413 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5416 _LT_TAGVAR(hardcode_direct, $1)=yes
5417 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5418 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5420 # hardcode_minus_L: Not really in the search PATH,
5421 # but as the default location of the library.
5422 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5428 irix5* | irix6* | nonstopux*)
5429 if test "$GCC" = yes; then
5430 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5431 # Try to use the -exported_symbol ld option, if it does not
5432 # work, assume that -exports_file does not work either and
5433 # implicitly export all symbols.
5434 save_LDFLAGS="$LDFLAGS"
5435 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
5436 AC_LINK_IFELSE(int foo(void) {},
5437 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
5439 LDFLAGS="$save_LDFLAGS"
5441 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
5442 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
5444 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5445 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5446 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5447 _LT_TAGVAR(inherit_rpath, $1)=yes
5448 _LT_TAGVAR(link_all_deplibs, $1)=yes
5451 netbsd* | netbsdelf*-gnu)
5452 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
5453 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
5455 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
5457 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5458 _LT_TAGVAR(hardcode_direct, $1)=yes
5459 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5463 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5464 _LT_TAGVAR(hardcode_direct, $1)=yes
5465 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5466 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5467 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5474 if test -f /usr/libexec/ld.so; then
5475 _LT_TAGVAR(hardcode_direct, $1)=yes
5476 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5477 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5478 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5479 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5480 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
5481 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5482 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5485 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5486 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5487 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5490 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5491 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5496 _LT_TAGVAR(ld_shlibs, $1)=no
5501 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5502 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5503 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5504 _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'
5505 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
5509 if test "$GCC" = yes; then
5510 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5511 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5513 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5514 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
5516 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5517 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5518 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5521 osf4* | osf5*) # as osf3* with the addition of -msym flag
5522 if test "$GCC" = yes; then
5523 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5524 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5525 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5527 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5528 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
5529 _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~
5530 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
5532 # Both c and cxx compiler support -rpath directly
5533 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
5535 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5536 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
5540 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5541 if test "$GCC" = yes; then
5543 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5544 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5545 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5547 case `$CC -V 2>&1` in
5550 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
5551 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5552 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
5556 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
5557 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5558 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5562 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5563 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5565 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
5567 # The compiler driver will combine and reorder linker options,
5568 # but understands `-z linker_flag'. GCC discards it without `$wl',
5569 # but is careful enough not to reorder.
5570 # Supported since Solaris 2.6 (maybe 2.5.1?)
5571 if test "$GCC" = yes; then
5572 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
5574 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
5578 _LT_TAGVAR(link_all_deplibs, $1)=yes
5582 if test "x$host_vendor" = xsequent; then
5583 # Use $CC to link under sequent, because it throws in some extra .o
5584 # files that make .init and .fini sections work.
5585 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
5587 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
5589 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5590 _LT_TAGVAR(hardcode_direct, $1)=yes
5591 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5592 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5596 case $host_vendor in
5598 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5599 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
5602 ## LD is ld it makes a PLAMLIB
5603 ## CC just makes a GrossModule.
5604 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
5605 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
5606 _LT_TAGVAR(hardcode_direct, $1)=no
5609 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5610 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
5613 runpath_var='LD_RUN_PATH'
5614 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5618 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5619 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5620 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
5624 if test -d /usr/nec; then
5625 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5626 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5627 runpath_var=LD_RUN_PATH
5628 hardcode_runpath_var=yes
5629 _LT_TAGVAR(ld_shlibs, $1)=yes
5633 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
5634 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5635 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5636 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5637 runpath_var='LD_RUN_PATH'
5639 if test "$GCC" = yes; then
5640 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5641 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5643 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5644 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5648 sysv5* | sco3.2v5* | sco5v6*)
5649 # Note: We can NOT use -z defs as we might desire, because we do not
5650 # link with -lc, and that would cause any symbols used from libc to
5651 # always be unresolved, which means just about no library would
5652 # ever link correctly. If we're not using GNU ld we use -z text
5653 # though, which does catch some bad symbols but isn't as heavy-handed
5655 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5656 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
5657 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5658 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5659 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
5660 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
5661 _LT_TAGVAR(link_all_deplibs, $1)=yes
5662 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
5663 runpath_var='LD_RUN_PATH'
5665 if test "$GCC" = yes; then
5666 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5667 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5669 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5670 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5675 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
5676 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5677 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5681 _LT_TAGVAR(ld_shlibs, $1)=no
5685 if test x$host_vendor = xsni; then
5687 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5688 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
5694 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
5695 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
5697 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
5699 _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
5700 _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
5701 _LT_DECL([], [extract_expsyms_cmds], [2],
5702 [The commands to extract the exported symbol list from a shared archive])
5705 # Do we need to explicitly link libc?
5707 case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
5709 # Assume -lc should be added
5710 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5712 if test "$enable_shared" = yes && test "$GCC" = yes; then
5713 case $_LT_TAGVAR(archive_cmds, $1) in
5715 # FIXME: we may have to deal with multi-command sequences.
5718 # Test whether the compiler implicitly links with -lc since on some
5719 # systems, -lgcc has to come before -lc. If gcc already passes -lc
5720 # to ld, don't add -lc before -lgcc.
5721 AC_MSG_CHECKING([whether -lc should be explicitly linked in])
5723 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
5725 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
5728 libobjs=conftest.$ac_objext
5730 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
5731 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
5737 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
5738 _LT_TAGVAR(allow_undefined_flag, $1)=
5739 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
5741 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5743 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5745 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
5747 cat conftest.err 1>&5
5750 AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
5757 _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
5758 [Whether or not to add -lc for building shared libraries])
5759 _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
5760 [enable_shared_with_static_runtimes], [0],
5761 [Whether or not to disallow shared libs when runtime libs are static])
5762 _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
5763 [Compiler flag to allow reflexive dlopens])
5764 _LT_TAGDECL([], [whole_archive_flag_spec], [1],
5765 [Compiler flag to generate shared objects directly from archives])
5766 _LT_TAGDECL([], [compiler_needs_object], [1],
5767 [Whether the compiler copes with passing no objects directly])
5768 _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
5769 [Create an old-style archive from a shared archive])
5770 _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
5771 [Create a temporary old-style archive to link instead of a shared archive])
5772 _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
5773 _LT_TAGDECL([], [archive_expsym_cmds], [2])
5774 _LT_TAGDECL([], [module_cmds], [2],
5775 [Commands used to build a loadable module if different from building
5777 _LT_TAGDECL([], [module_expsym_cmds], [2])
5778 _LT_TAGDECL([], [with_gnu_ld], [1],
5779 [Whether we are building with GNU ld or not])
5780 _LT_TAGDECL([], [allow_undefined_flag], [1],
5781 [Flag that allows shared libraries with undefined symbols to be built])
5782 _LT_TAGDECL([], [no_undefined_flag], [1],
5783 [Flag that enforces no undefined symbols])
5784 _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
5785 [Flag to hardcode $libdir into a binary during linking.
5786 This must work even if $libdir does not exist])
5787 _LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
5788 [[If ld is used when linking, flag to hardcode $libdir into a binary
5789 during linking. This must work even if $libdir does not exist]])
5790 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
5791 [Whether we need a single "-rpath" flag with a separated argument])
5792 _LT_TAGDECL([], [hardcode_direct], [0],
5793 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5794 DIR into the resulting binary])
5795 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
5796 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
5797 DIR into the resulting binary and the resulting library dependency is
5798 "absolute", i.e impossible to change by setting ${shlibpath_var} if the
5799 library is relocated])
5800 _LT_TAGDECL([], [hardcode_minus_L], [0],
5801 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
5802 into the resulting binary])
5803 _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
5804 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
5805 into the resulting binary])
5806 _LT_TAGDECL([], [hardcode_automatic], [0],
5807 [Set to "yes" if building a shared library automatically hardcodes DIR
5808 into the library and all subsequent libraries and executables linked
5810 _LT_TAGDECL([], [inherit_rpath], [0],
5811 [Set to yes if linker adds runtime paths of dependent libraries
5812 to runtime path list])
5813 _LT_TAGDECL([], [link_all_deplibs], [0],
5814 [Whether libtool must link a program against all its dependency libraries])
5815 _LT_TAGDECL([], [fix_srcfile_path], [1],
5816 [Fix the shell variable $srcfile for the compiler])
5817 _LT_TAGDECL([], [always_export_symbols], [0],
5818 [Set to "yes" if exported symbols are required])
5819 _LT_TAGDECL([], [export_symbols_cmds], [2],
5820 [The commands to list exported symbols])
5821 _LT_TAGDECL([], [exclude_expsyms], [1],
5822 [Symbols that should not be listed in the preloaded symbols])
5823 _LT_TAGDECL([], [include_expsyms], [1],
5824 [Symbols that must always be exported])
5825 _LT_TAGDECL([], [prelink_cmds], [2],
5826 [Commands necessary for linking programs (against libraries) with templates])
5827 _LT_TAGDECL([], [file_list_spec], [1],
5828 [Specify filename containing input files])
5829 dnl FIXME: Not yet implemented
5830 dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
5831 dnl [Compiler flag to generate thread safe objects])
5832 ])# _LT_LINKER_SHLIBS
5835 # _LT_LANG_C_CONFIG([TAG])
5836 # ------------------------
5837 # Ensure that the configuration variables for a C compiler are suitably
5838 # defined. These variables are subsequently used by _LT_CONFIG to write
5839 # the compiler configuration to `libtool'.
5840 m4_defun([_LT_LANG_C_CONFIG],
5841 [m4_require([_LT_DECL_EGREP])dnl
5845 # Source file extension for C test sources.
5848 # Object file extension for compiled C test sources.
5850 _LT_TAGVAR(objext, $1)=$objext
5852 # Code to be used in simple compile tests
5853 lt_simple_compile_test_code="int some_variable = 0;"
5855 # Code to be used in simple link tests
5856 lt_simple_link_test_code='int main(){return(0);}'
5859 # Save the default compiler, since it gets overwritten when the other
5860 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
5861 compiler_DEFAULT=$CC
5863 # save warnings/boilerplate of simple test code
5864 _LT_COMPILER_BOILERPLATE
5865 _LT_LINKER_BOILERPLATE
5867 if test -n "$compiler"; then
5868 _LT_COMPILER_NO_RTTI($1)
5869 _LT_COMPILER_PIC($1)
5870 _LT_COMPILER_C_O($1)
5871 _LT_COMPILER_FILE_LOCKS($1)
5872 _LT_LINKER_SHLIBS($1)
5873 _LT_SYS_DYNAMIC_LINKER($1)
5874 _LT_LINKER_HARDCODE_LIBPATH($1)
5878 # Report which library types will actually be built
5879 AC_MSG_CHECKING([if libtool supports shared libraries])
5880 AC_MSG_RESULT([$can_build_shared])
5882 AC_MSG_CHECKING([whether to build shared libraries])
5883 test "$can_build_shared" = "no" && enable_shared=no
5885 # On AIX, shared libraries and static libraries use the same namespace, and
5886 # are all built from PIC.
5889 test "$enable_shared" = yes && enable_static=no
5890 if test -n "$RANLIB"; then
5891 archive_cmds="$archive_cmds~\$RANLIB \$lib"
5892 postinstall_cmds='$RANLIB $lib'
5897 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
5898 test "$enable_shared" = yes && enable_static=no
5902 AC_MSG_RESULT([$enable_shared])
5904 AC_MSG_CHECKING([whether to build static libraries])
5905 # Make sure either enable_shared or enable_static is yes.
5906 test "$enable_shared" = yes || enable_static=yes
5907 AC_MSG_RESULT([$enable_static])
5913 ])# _LT_LANG_C_CONFIG
5918 # Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
5919 # compiler, we have our own version here.
5920 m4_defun([_LT_PROG_CXX],
5922 pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
5924 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
5925 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
5926 (test "X$CXX" != "Xg++"))) ; then
5929 _lt_caught_CXX_error=yes
5931 popdef([AC_MSG_ERROR])
5934 dnl aclocal-1.4 backwards compatibility:
5935 dnl AC_DEFUN([_LT_PROG_CXX], [])
5938 # _LT_LANG_CXX_CONFIG([TAG])
5939 # --------------------------
5940 # Ensure that the configuration variables for a C++ compiler are suitably
5941 # defined. These variables are subsequently used by _LT_CONFIG to write
5942 # the compiler configuration to `libtool'.
5943 m4_defun([_LT_LANG_CXX_CONFIG],
5944 [AC_REQUIRE([_LT_PROG_CXX])dnl
5945 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
5946 m4_require([_LT_DECL_EGREP])dnl
5949 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
5950 _LT_TAGVAR(allow_undefined_flag, $1)=
5951 _LT_TAGVAR(always_export_symbols, $1)=no
5952 _LT_TAGVAR(archive_expsym_cmds, $1)=
5953 _LT_TAGVAR(compiler_needs_object, $1)=no
5954 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
5955 _LT_TAGVAR(hardcode_direct, $1)=no
5956 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5957 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
5958 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5959 _LT_TAGVAR(hardcode_libdir_separator, $1)=
5960 _LT_TAGVAR(hardcode_minus_L, $1)=no
5961 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5962 _LT_TAGVAR(hardcode_automatic, $1)=no
5963 _LT_TAGVAR(inherit_rpath, $1)=no
5964 _LT_TAGVAR(module_cmds, $1)=
5965 _LT_TAGVAR(module_expsym_cmds, $1)=
5966 _LT_TAGVAR(link_all_deplibs, $1)=unknown
5967 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5968 _LT_TAGVAR(no_undefined_flag, $1)=
5969 _LT_TAGVAR(whole_archive_flag_spec, $1)=
5970 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5972 # Source file extension for C++ test sources.
5975 # Object file extension for compiled C++ test sources.
5977 _LT_TAGVAR(objext, $1)=$objext
5979 # No sense in running all these tests if we already determined that
5980 # the CXX compiler isn't working. Some variables (like enable_shared)
5981 # are currently assumed to apply to all compilers on this platform,
5982 # and will be corrupted by setting them based on a non-working compiler.
5983 if test "$_lt_caught_CXX_error" != yes; then
5984 # Code to be used in simple compile tests
5985 lt_simple_compile_test_code="int some_variable = 0;"
5987 # Code to be used in simple link tests
5988 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
5990 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
5993 # save warnings/boilerplate of simple test code
5994 _LT_COMPILER_BOILERPLATE
5995 _LT_LINKER_BOILERPLATE
5997 # Allow CC to be a program name with arguments.
6002 lt_save_with_gnu_ld=$with_gnu_ld
6003 lt_save_path_LD=$lt_cv_path_LD
6004 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
6005 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
6007 $as_unset lt_cv_prog_gnu_ld
6009 if test -n "${lt_cv_path_LDCXX+set}"; then
6010 lt_cv_path_LD=$lt_cv_path_LDCXX
6012 $as_unset lt_cv_path_LD
6014 test -z "${LDCXX+set}" || LD=$LDCXX
6017 _LT_TAGVAR(compiler, $1)=$CC
6018 _LT_CC_BASENAME([$compiler])
6020 if test -n "$compiler"; then
6021 # We don't want -fno-exception when compiling C++ code, so set the
6022 # no_builtin_flag separately
6023 if test "$GXX" = yes; then
6024 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
6026 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
6029 if test "$GXX" = yes; then
6030 # Set up default GNU C++ configuration
6034 # Check if GNU C++ uses GNU ld as the underlying linker, since the
6035 # archiving commands below assume that GNU ld is being used.
6036 if test "$with_gnu_ld" = yes; then
6037 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6038 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6040 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6041 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6043 # If archive_cmds runs LD, not CC, wlarc should be empty
6044 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
6045 # investigate it a little bit more. (MM)
6048 # ancient GNU ld didn't support --whole-archive et. al.
6049 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
6050 $GREP 'no-whole-archive' > /dev/null; then
6051 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6053 _LT_TAGVAR(whole_archive_flag_spec, $1)=
6059 # A generic and very simple default shared library creation
6060 # command for GNU C++ for the case where it uses the native
6061 # linker, instead of GNU ld. If possible, this setting should
6062 # overridden to take advantage of the native linker features on
6063 # the platform it is being used on.
6064 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6067 # Commands to make compiler produce verbose output that lists
6068 # what "hidden" libraries, object files and flags are used when
6069 # linking a shared library.
6070 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6078 # PORTME: fill in a description of your system's C++ link characteristics
6079 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6080 _LT_TAGVAR(ld_shlibs, $1)=yes
6083 # FIXME: insert proper C++ library support
6084 _LT_TAGVAR(ld_shlibs, $1)=no
6087 if test "$host_cpu" = ia64; then
6088 # On IA64, the linker does run time linking by default, so we don't
6089 # have to do anything special.
6090 aix_use_runtimelinking=no
6091 exp_sym_flag='-Bexport'
6094 aix_use_runtimelinking=no
6096 # Test if we are trying to use run time linking or normal
6097 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6098 # need to do runtime linking.
6099 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6100 for ld_flag in $LDFLAGS; do
6103 aix_use_runtimelinking=yes
6111 exp_sym_flag='-bexport'
6112 no_entry_flag='-bnoentry'
6115 # When large executables or shared objects are built, AIX ld can
6116 # have problems creating the table of contents. If linking a library
6117 # or program results in "error TOC overflow" add -mminimal-toc to
6118 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6119 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6121 _LT_TAGVAR(archive_cmds, $1)=''
6122 _LT_TAGVAR(hardcode_direct, $1)=yes
6123 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6124 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6125 _LT_TAGVAR(link_all_deplibs, $1)=yes
6126 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6128 if test "$GXX" = yes; then
6129 case $host_os in aix4.[[012]]|aix4.[[012]].*)
6130 # We only want to do this on AIX 4.2 and lower, the check
6131 # below for broken collect2 doesn't work under 4.3+
6132 collect2name=`${CC} -print-prog-name=collect2`
6133 if test -f "$collect2name" &&
6134 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
6136 # We have reworked collect2
6139 # We have old collect2
6140 _LT_TAGVAR(hardcode_direct, $1)=unsupported
6141 # It fails to find uninstalled libraries when the uninstalled
6142 # path is not listed in the libpath. Setting hardcode_minus_L
6143 # to unsupported forces relinking
6144 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6145 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6146 _LT_TAGVAR(hardcode_libdir_separator, $1)=
6149 shared_flag='-shared'
6150 if test "$aix_use_runtimelinking" = yes; then
6151 shared_flag="$shared_flag "'${wl}-G'
6155 if test "$host_cpu" = ia64; then
6156 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6157 # chokes on -Wl,-G. The following line is correct:
6160 if test "$aix_use_runtimelinking" = yes; then
6161 shared_flag='${wl}-G'
6163 shared_flag='${wl}-bM:SRE'
6168 # It seems that -bexpall does not export symbols beginning with
6169 # underscore (_), so it is better to generate a list of symbols to
6171 _LT_TAGVAR(always_export_symbols, $1)=yes
6172 if test "$aix_use_runtimelinking" = yes; then
6173 # Warning - without using the other runtime loading flags (-brtl),
6174 # -berok will link without error, but may produce a broken library.
6175 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6176 # Determine the default libpath from the value encoded in an empty
6178 _LT_SYS_MODULE_PATH_AIX
6179 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6181 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6183 if test "$host_cpu" = ia64; then
6184 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6185 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6186 _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"
6188 # Determine the default libpath from the value encoded in an
6190 _LT_SYS_MODULE_PATH_AIX
6191 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6192 # Warning - without using the other run time loading flags,
6193 # -berok will link without error, but may produce a broken library.
6194 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6195 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6196 # Exported symbols can be pulled into shared objects from archives
6197 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6198 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6199 # This is similar to how AIX traditionally builds its shared
6201 _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'
6207 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
6208 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6209 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6210 # support --undefined. This deserves some investigation. FIXME
6211 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6213 _LT_TAGVAR(ld_shlibs, $1)=no
6218 case $cc_basename in
6220 # FIXME: insert proper C++ library support
6221 _LT_TAGVAR(ld_shlibs, $1)=no
6226 cygwin* | mingw* | pw32*)
6227 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6228 # as there is no search path for DLLs.
6229 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6230 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6231 _LT_TAGVAR(always_export_symbols, $1)=no
6232 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6234 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
6235 _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'
6236 # If the export-symbols file already is a .def file (1st line
6237 # is EXPORTS), use it as is; otherwise, prepend...
6238 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6239 cp $export_symbols $output_objdir/$soname.def;
6241 echo EXPORTS > $output_objdir/$soname.def;
6242 cat $export_symbols >> $output_objdir/$soname.def;
6244 $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'
6246 _LT_TAGVAR(ld_shlibs, $1)=no
6249 darwin* | rhapsody*)
6250 _LT_DARWIN_LINKER_FEATURES($1)
6254 case $cc_basename in
6256 # FIXME: insert proper C++ library support
6257 _LT_TAGVAR(ld_shlibs, $1)=no
6260 # Green Hills C++ Compiler
6261 # FIXME: insert proper C++ library support
6262 _LT_TAGVAR(ld_shlibs, $1)=no
6265 # FIXME: insert proper C++ library support
6266 _LT_TAGVAR(ld_shlibs, $1)=no
6272 # C++ shared libraries reported to be fairly broken before
6274 _LT_TAGVAR(ld_shlibs, $1)=no
6278 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6281 freebsd* | dragonfly*)
6282 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
6284 _LT_TAGVAR(ld_shlibs, $1)=yes
6291 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6292 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6293 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6294 _LT_TAGVAR(hardcode_direct, $1)=yes
6295 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6296 # but as the default
6297 # location of the library.
6299 case $cc_basename in
6301 # FIXME: insert proper C++ library support
6302 _LT_TAGVAR(ld_shlibs, $1)=no
6305 _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'
6306 # Commands to make compiler produce verbose output that lists
6307 # what "hidden" libraries, object files and flags are used when
6308 # linking a shared library.
6310 # There doesn't appear to be a way to prevent this compiler from
6311 # explicitly linking system object files so we need to strip them
6312 # from the output so that they don't get included in the library
6314 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6317 if test "$GXX" = yes; then
6318 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6320 # FIXME: insert proper C++ library support
6321 _LT_TAGVAR(ld_shlibs, $1)=no
6328 if test $with_gnu_ld = no; then
6329 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6330 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6336 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6342 _LT_TAGVAR(hardcode_direct, $1)=no
6343 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6346 _LT_TAGVAR(hardcode_direct, $1)=yes
6347 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6348 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
6349 # but as the default
6350 # location of the library.
6354 case $cc_basename in
6356 # FIXME: insert proper C++ library support
6357 _LT_TAGVAR(ld_shlibs, $1)=no
6362 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6365 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6368 _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'
6371 # Commands to make compiler produce verbose output that lists
6372 # what "hidden" libraries, object files and flags are used when
6373 # linking a shared library.
6375 # There doesn't appear to be a way to prevent this compiler from
6376 # explicitly linking system object files so we need to strip them
6377 # from the output so that they don't get included in the library
6379 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6382 if test "$GXX" = yes; then
6383 if test $with_gnu_ld = no; then
6386 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6389 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6392 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6397 # FIXME: insert proper C++ library support
6398 _LT_TAGVAR(ld_shlibs, $1)=no
6405 _LT_TAGVAR(hardcode_direct, $1)=no
6406 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6407 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6408 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6409 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6410 # Instead, shared libraries are loaded at an image base (0x10000000 by
6411 # default) and relocated if they conflict, which is a slow very memory
6412 # consuming and fragmenting process. To avoid this, we pick a random,
6413 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6414 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6415 _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'
6416 _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'
6419 case $cc_basename in
6422 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6424 # Archives containing C++ object files must be created using
6425 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
6426 # necessary to make sure instantiated templates are included
6428 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
6431 if test "$GXX" = yes; then
6432 if test "$with_gnu_ld" = no; then
6433 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6435 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
6438 _LT_TAGVAR(link_all_deplibs, $1)=yes
6441 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6442 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6443 _LT_TAGVAR(inherit_rpath, $1)=yes
6446 linux* | k*bsd*-gnu)
6447 case $cc_basename in
6449 # Kuck and Associates, Inc. (KAI) C++ Compiler
6451 # KCC will only create a shared library if the output file
6452 # ends with ".so" (or ".sl" for HP-UX), so rename the library
6453 # to its proper name (with version) after linking.
6454 _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'
6455 _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'
6456 # Commands to make compiler produce verbose output that lists
6457 # what "hidden" libraries, object files and flags are used when
6458 # linking a shared library.
6460 # There doesn't appear to be a way to prevent this compiler from
6461 # explicitly linking system object files so we need to strip them
6462 # from the output so that they don't get included in the library
6464 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6466 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6467 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6469 # Archives containing C++ object files must be created using
6470 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
6471 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
6476 # version 8.0 and above of icpc choke on multiply defined symbols
6477 # if we add $predep_objects and $postdep_objects, however 7.1 and
6478 # earlier do not add the objects themselves.
6479 case `$CC -V 2>&1` in
6481 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6482 _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'
6484 *) # Version 8.0 or newer
6487 ia64*) tmp_idyn=' -i_dynamic';;
6489 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6490 _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'
6493 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6494 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6495 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6496 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6499 # Portland Group C++ compiler
6501 *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*)
6502 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
6504 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6505 compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
6506 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
6508 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6509 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
6511 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6513 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6514 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6515 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6517 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6518 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6520 *) # Version 6 will use weak symbols
6521 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6522 _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'
6526 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6527 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6528 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6532 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6533 _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'
6535 runpath_var=LD_RUN_PATH
6536 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6537 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6539 # Commands to make compiler produce verbose output that lists
6540 # what "hidden" libraries, object files and flags are used when
6541 # linking a shared library.
6543 # There doesn't appear to be a way to prevent this compiler from
6544 # explicitly linking system object files so we need to strip them
6545 # from the output so that they don't get included in the library
6547 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6550 # IBM XL 8.0 on PPC, with GNU ld
6551 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6552 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6553 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6554 if test "x$supports_anon_versioning" = xyes; then
6555 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6556 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6557 echo "local: *; };" >> $output_objdir/$libname.ver~
6558 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6562 case `$CC -V 2>&1 | sed 5q` in
6565 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6566 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6567 _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'
6568 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6569 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
6570 _LT_TAGVAR(compiler_needs_object, $1)=yes
6572 # Not sure whether something based on
6573 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
6575 output_verbose_link_cmd='echo'
6577 # Archives containing C++ object files must be created using
6578 # "CC -xar", where "CC" is the Sun C++ compiler. This is
6579 # necessary to make sure instantiated templates are included
6581 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6589 # FIXME: insert proper C++ library support
6590 _LT_TAGVAR(ld_shlibs, $1)=no
6594 # FIXME: insert proper C++ library support
6595 _LT_TAGVAR(ld_shlibs, $1)=no
6599 case $cc_basename in
6601 # FIXME: insert proper C++ library support
6602 _LT_TAGVAR(ld_shlibs, $1)=no
6605 # FIXME: insert proper C++ library support
6606 _LT_TAGVAR(ld_shlibs, $1)=no
6612 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
6613 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
6615 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6616 _LT_TAGVAR(hardcode_direct, $1)=yes
6617 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6619 # Workaround some broken pre-1.5 toolchains
6620 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
6624 _LT_TAGVAR(ld_shlibs, $1)=yes
6628 # C++ shared libraries are fairly broken
6629 _LT_TAGVAR(ld_shlibs, $1)=no
6633 if test -f /usr/libexec/ld.so; then
6634 _LT_TAGVAR(hardcode_direct, $1)=yes
6635 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6636 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
6637 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6638 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6639 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6640 _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'
6641 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6642 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6644 output_verbose_link_cmd=echo
6646 _LT_TAGVAR(ld_shlibs, $1)=no
6650 osf3* | osf4* | osf5*)
6651 case $cc_basename in
6653 # Kuck and Associates, Inc. (KAI) C++ Compiler
6655 # KCC will only create a shared library if the output file
6656 # ends with ".so" (or ".sl" for HP-UX), so rename the library
6657 # to its proper name (with version) after linking.
6658 _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'
6660 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6661 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6663 # Archives containing C++ object files must be created using
6664 # the KAI C++ compiler.
6666 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
6667 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
6671 # Rational C++ 2.4.1
6672 # FIXME: insert proper C++ library support
6673 _LT_TAGVAR(ld_shlibs, $1)=no
6678 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6679 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6680 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6683 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6684 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
6685 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
6686 echo "-hidden">> $lib.exp~
6687 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
6689 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
6693 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6695 # Commands to make compiler produce verbose output that lists
6696 # what "hidden" libraries, object files and flags are used when
6697 # linking a shared library.
6699 # There doesn't appear to be a way to prevent this compiler from
6700 # explicitly linking system object files so we need to strip them
6701 # from the output so that they don't get included in the library
6703 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
6706 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6707 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6710 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6713 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6717 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6718 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6720 # Commands to make compiler produce verbose output that lists
6721 # what "hidden" libraries, object files and flags are used when
6722 # linking a shared library.
6723 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6726 # FIXME: insert proper C++ library support
6727 _LT_TAGVAR(ld_shlibs, $1)=no
6734 # FIXME: insert proper C++ library support
6735 _LT_TAGVAR(ld_shlibs, $1)=no
6739 case $cc_basename in
6742 # FIXME: insert proper C++ library support
6743 _LT_TAGVAR(ld_shlibs, $1)=no
6747 # FIXME: insert proper C++ library support
6748 _LT_TAGVAR(ld_shlibs, $1)=no
6751 # FIXME: insert proper C++ library support
6752 _LT_TAGVAR(ld_shlibs, $1)=no
6758 case $cc_basename in
6760 # Sun C++ 4.2, 5.x and Centerline C++
6761 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
6762 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6763 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6764 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6765 $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'
6767 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6768 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6770 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6772 # The compiler driver will combine and reorder linker options,
6773 # but understands `-z linker_flag'.
6774 # Supported since Solaris 2.6 (maybe 2.5.1?)
6775 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
6778 _LT_TAGVAR(link_all_deplibs, $1)=yes
6780 output_verbose_link_cmd='echo'
6782 # Archives containing C++ object files must be created using
6783 # "CC -xar", where "CC" is the Sun C++ compiler. This is
6784 # necessary to make sure instantiated templates are included
6786 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
6789 # Green Hills C++ Compiler
6790 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6792 # The C++ compiler must be used to create the archive.
6793 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
6796 # GNU C++ compiler with Solaris linker
6797 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6798 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
6799 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
6800 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6801 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6802 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6804 # Commands to make compiler produce verbose output that lists
6805 # what "hidden" libraries, object files and flags are used when
6806 # linking a shared library.
6807 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6809 # g++ 2.7 appears to require `-G' NOT `-shared' on this
6811 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
6812 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6813 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
6815 # Commands to make compiler produce verbose output that lists
6816 # what "hidden" libraries, object files and flags are used when
6817 # linking a shared library.
6818 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
6821 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
6823 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
6825 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
6833 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6834 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6835 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6836 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6837 runpath_var='LD_RUN_PATH'
6839 case $cc_basename in
6841 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6842 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6845 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6846 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6851 sysv5* | sco3.2v5* | sco5v6*)
6852 # Note: We can NOT use -z defs as we might desire, because we do not
6853 # link with -lc, and that would cause any symbols used from libc to
6854 # always be unresolved, which means just about no library would
6855 # ever link correctly. If we're not using GNU ld we use -z text
6856 # though, which does catch some bad symbols but isn't as heavy-handed
6858 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6859 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6860 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6861 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6862 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6863 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
6864 _LT_TAGVAR(link_all_deplibs, $1)=yes
6865 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6866 runpath_var='LD_RUN_PATH'
6868 case $cc_basename in
6870 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6871 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6874 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6875 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6881 case $cc_basename in
6883 # NonStop-UX NCC 3.20
6884 # FIXME: insert proper C++ library support
6885 _LT_TAGVAR(ld_shlibs, $1)=no
6888 # FIXME: insert proper C++ library support
6889 _LT_TAGVAR(ld_shlibs, $1)=no
6895 # FIXME: insert proper C++ library support
6896 _LT_TAGVAR(ld_shlibs, $1)=no
6900 # FIXME: insert proper C++ library support
6901 _LT_TAGVAR(ld_shlibs, $1)=no
6905 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6906 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6908 _LT_TAGVAR(GCC, $1)="$GXX"
6909 _LT_TAGVAR(LD, $1)="$LD"
6912 ## There is no encapsulation within the following macros, do not change
6913 ## the running order or otherwise move them around unless you know exactly
6914 ## what you are doing...
6915 _LT_SYS_HIDDEN_LIBDEPS($1)
6916 _LT_COMPILER_PIC($1)
6917 _LT_COMPILER_C_O($1)
6918 _LT_COMPILER_FILE_LOCKS($1)
6919 _LT_LINKER_SHLIBS($1)
6920 _LT_SYS_DYNAMIC_LINKER($1)
6921 _LT_LINKER_HARDCODE_LIBPATH($1)
6924 fi # test -n "$compiler"
6930 with_gnu_ld=$lt_save_with_gnu_ld
6931 lt_cv_path_LDCXX=$lt_cv_path_LD
6932 lt_cv_path_LD=$lt_save_path_LD
6933 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
6934 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
6935 fi # test "$_lt_caught_CXX_error" != yes
6938 ])# _LT_LANG_CXX_CONFIG
6941 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
6942 # ---------------------------------
6943 # Figure out "hidden" library dependencies from verbose
6944 # compiler output when linking a shared library.
6945 # Parse the compiler output and extract the necessary
6946 # objects, libraries and library flags.
6947 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
6948 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
6949 # Dependencies to place before and after the object being linked:
6950 _LT_TAGVAR(predep_objects, $1)=
6951 _LT_TAGVAR(postdep_objects, $1)=
6952 _LT_TAGVAR(predeps, $1)=
6953 _LT_TAGVAR(postdeps, $1)=
6954 _LT_TAGVAR(compiler_lib_search_path, $1)=
6956 dnl we can't use the lt_simple_compile_test_code here,
6957 dnl because it contains code intended for an executable,
6958 dnl not a library. It's possible we should let each
6959 dnl tag define a new lt_????_link_test_code variable,
6960 dnl but it's only used here...
6961 m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
6963 void foo (void) { a = 0; }
6965 ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
6969 Foo (void) { a = 0; }
6974 ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
6982 ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
6990 ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
6993 public void bar (void) {
6999 dnl Parse the compiler output and extract the necessary
7000 dnl objects, libraries and library flags.
7001 if AC_TRY_EVAL(ac_compile); then
7002 # Parse the compiler output and extract the necessary
7003 # objects, libraries and library flags.
7005 # Sentinel used to keep track of whether or not we are before
7006 # the conftest object file.
7007 pre_test_object_deps_done=no
7009 for p in `eval "$output_verbose_link_cmd"`; do
7013 # Some compilers place space between "-{L,R}" and the path.
7015 if test $p = "-L" ||
7016 test $p = "-R"; then
7023 if test "$pre_test_object_deps_done" = no; then
7026 # Internal compiler library paths should come after those
7027 # provided the user. The postdeps already come after the
7028 # user supplied libs so there is no need to process them.
7029 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7030 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
7032 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
7035 # The "-l" case would never come before the object being
7036 # linked, so don't bother handling this case.
7039 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7040 _LT_TAGVAR(postdeps, $1)="${prev}${p}"
7042 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
7048 # This assumes that the test object file only shows up
7049 # once in the compiler output.
7050 if test "$p" = "conftest.$objext"; then
7051 pre_test_object_deps_done=yes
7055 if test "$pre_test_object_deps_done" = no; then
7056 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
7057 _LT_TAGVAR(predep_objects, $1)="$p"
7059 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
7062 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
7063 _LT_TAGVAR(postdep_objects, $1)="$p"
7065 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
7070 *) ;; # Ignore the rest.
7078 echo "libtool.m4: error: problem compiling $1 test program"
7081 $RM -f confest.$objext
7083 # PORTME: override above test on systems where it is broken
7087 # Interix 3.5 installs completely hosed .la files for C++, so rather than
7088 # hack all around it, let's just trust "g++" to DTRT.
7089 _LT_TAGVAR(predep_objects,$1)=
7090 _LT_TAGVAR(postdep_objects,$1)=
7091 _LT_TAGVAR(postdeps,$1)=
7095 case `$CC -V 2>&1 | sed 5q` in
7099 # The more standards-conforming stlport4 library is
7100 # incompatible with the Cstd library. Avoid specifying
7101 # it if it's in CXXFLAGS. Ignore libCrun as
7102 # -library=stlport4 depends on it.
7103 case " $CXX $CXXFLAGS " in
7104 *" -library=stlport4 "*)
7105 solaris_use_stlport4=yes
7109 if test "$solaris_use_stlport4" != yes; then
7110 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7117 case $cc_basename in
7119 # The more standards-conforming stlport4 library is
7120 # incompatible with the Cstd library. Avoid specifying
7121 # it if it's in CXXFLAGS. Ignore libCrun as
7122 # -library=stlport4 depends on it.
7123 case " $CXX $CXXFLAGS " in
7124 *" -library=stlport4 "*)
7125 solaris_use_stlport4=yes
7129 # Adding this requires a known-good setup of shared libraries for
7130 # Sun compiler versions before 5.6, else PIC objects from an old
7131 # archive will be linked into the output, leading to subtle bugs.
7132 if test "$solaris_use_stlport4" != yes; then
7133 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7141 case " $_LT_TAGVAR(postdeps, $1) " in
7142 *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
7144 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
7145 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
7146 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
7148 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
7149 [The directories searched by this compiler when creating a shared library])
7150 _LT_TAGDECL([], [predep_objects], [1],
7151 [Dependencies to place before and after the objects being linked to
7152 create a shared library])
7153 _LT_TAGDECL([], [postdep_objects], [1])
7154 _LT_TAGDECL([], [predeps], [1])
7155 _LT_TAGDECL([], [postdeps], [1])
7156 _LT_TAGDECL([], [compiler_lib_search_path], [1],
7157 [The library search path used internally by the compiler when linking
7159 ])# _LT_SYS_HIDDEN_LIBDEPS
7164 # Since AC_PROG_F77 is broken, in that it returns the empty string
7165 # if there is no fortran compiler, we have our own version here.
7166 m4_defun([_LT_PROG_F77],
7168 pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
7170 if test -z "$F77" || test "X$F77" = "Xno"; then
7173 popdef([AC_MSG_ERROR])
7176 dnl aclocal-1.4 backwards compatibility:
7177 dnl AC_DEFUN([_LT_PROG_F77], [])
7180 # _LT_LANG_F77_CONFIG([TAG])
7181 # --------------------------
7182 # Ensure that the configuration variables for a Fortran 77 compiler are
7183 # suitably defined. These variables are subsequently used by _LT_CONFIG
7184 # to write the compiler configuration to `libtool'.
7185 m4_defun([_LT_LANG_F77_CONFIG],
7186 [AC_REQUIRE([_LT_PROG_F77])dnl
7187 AC_LANG_PUSH(Fortran 77)
7189 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7190 _LT_TAGVAR(allow_undefined_flag, $1)=
7191 _LT_TAGVAR(always_export_symbols, $1)=no
7192 _LT_TAGVAR(archive_expsym_cmds, $1)=
7193 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7194 _LT_TAGVAR(hardcode_direct, $1)=no
7195 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7196 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7197 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
7198 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7199 _LT_TAGVAR(hardcode_minus_L, $1)=no
7200 _LT_TAGVAR(hardcode_automatic, $1)=no
7201 _LT_TAGVAR(inherit_rpath, $1)=no
7202 _LT_TAGVAR(module_cmds, $1)=
7203 _LT_TAGVAR(module_expsym_cmds, $1)=
7204 _LT_TAGVAR(link_all_deplibs, $1)=unknown
7205 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7206 _LT_TAGVAR(no_undefined_flag, $1)=
7207 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7208 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7210 # Source file extension for f77 test sources.
7213 # Object file extension for compiled f77 test sources.
7215 _LT_TAGVAR(objext, $1)=$objext
7217 # No sense in running all these tests if we already determined that
7218 # the F77 compiler isn't working. Some variables (like enable_shared)
7219 # are currently assumed to apply to all compilers on this platform,
7220 # and will be corrupted by setting them based on a non-working compiler.
7221 if test "$_lt_disable_F77" != yes; then
7222 # Code to be used in simple compile tests
7223 lt_simple_compile_test_code="\
7229 # Code to be used in simple link tests
7230 lt_simple_link_test_code="\
7235 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7238 # save warnings/boilerplate of simple test code
7239 _LT_COMPILER_BOILERPLATE
7240 _LT_LINKER_BOILERPLATE
7242 # Allow CC to be a program name with arguments.
7247 _LT_TAGVAR(compiler, $1)=$CC
7248 _LT_CC_BASENAME([$compiler])
7250 if test -n "$compiler"; then
7251 AC_MSG_CHECKING([if libtool supports shared libraries])
7252 AC_MSG_RESULT([$can_build_shared])
7254 AC_MSG_CHECKING([whether to build shared libraries])
7255 test "$can_build_shared" = "no" && enable_shared=no
7257 # On AIX, shared libraries and static libraries use the same namespace, and
7258 # are all built from PIC.
7261 test "$enable_shared" = yes && enable_static=no
7262 if test -n "$RANLIB"; then
7263 archive_cmds="$archive_cmds~\$RANLIB \$lib"
7264 postinstall_cmds='$RANLIB $lib'
7268 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7269 test "$enable_shared" = yes && enable_static=no
7273 AC_MSG_RESULT([$enable_shared])
7275 AC_MSG_CHECKING([whether to build static libraries])
7276 # Make sure either enable_shared or enable_static is yes.
7277 test "$enable_shared" = yes || enable_static=yes
7278 AC_MSG_RESULT([$enable_static])
7280 _LT_TAGVAR(GCC, $1)="$G77"
7281 _LT_TAGVAR(LD, $1)="$LD"
7284 ## There is no encapsulation within the following macros, do not change
7285 ## the running order or otherwise move them around unless you know exactly
7286 ## what you are doing...
7287 _LT_COMPILER_PIC($1)
7288 _LT_COMPILER_C_O($1)
7289 _LT_COMPILER_FILE_LOCKS($1)
7290 _LT_LINKER_SHLIBS($1)
7291 _LT_SYS_DYNAMIC_LINKER($1)
7292 _LT_LINKER_HARDCODE_LIBPATH($1)
7295 fi # test -n "$compiler"
7299 fi # test "$_lt_disable_F77" != yes
7302 ])# _LT_LANG_F77_CONFIG
7307 # Since AC_PROG_FC is broken, in that it returns the empty string
7308 # if there is no fortran compiler, we have our own version here.
7309 m4_defun([_LT_PROG_FC],
7311 pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
7313 if test -z "$FC" || test "X$FC" = "Xno"; then
7316 popdef([AC_MSG_ERROR])
7319 dnl aclocal-1.4 backwards compatibility:
7320 dnl AC_DEFUN([_LT_PROG_FC], [])
7323 # _LT_LANG_FC_CONFIG([TAG])
7324 # -------------------------
7325 # Ensure that the configuration variables for a Fortran compiler are
7326 # suitably defined. These variables are subsequently used by _LT_CONFIG
7327 # to write the compiler configuration to `libtool'.
7328 m4_defun([_LT_LANG_FC_CONFIG],
7329 [AC_REQUIRE([_LT_PROG_FC])dnl
7330 AC_LANG_PUSH(Fortran)
7332 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7333 _LT_TAGVAR(allow_undefined_flag, $1)=
7334 _LT_TAGVAR(always_export_symbols, $1)=no
7335 _LT_TAGVAR(archive_expsym_cmds, $1)=
7336 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
7337 _LT_TAGVAR(hardcode_direct, $1)=no
7338 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
7339 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
7340 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
7341 _LT_TAGVAR(hardcode_libdir_separator, $1)=
7342 _LT_TAGVAR(hardcode_minus_L, $1)=no
7343 _LT_TAGVAR(hardcode_automatic, $1)=no
7344 _LT_TAGVAR(inherit_rpath, $1)=no
7345 _LT_TAGVAR(module_cmds, $1)=
7346 _LT_TAGVAR(module_expsym_cmds, $1)=
7347 _LT_TAGVAR(link_all_deplibs, $1)=unknown
7348 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7349 _LT_TAGVAR(no_undefined_flag, $1)=
7350 _LT_TAGVAR(whole_archive_flag_spec, $1)=
7351 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
7353 # Source file extension for fc test sources.
7354 ac_ext=${ac_fc_srcext-f}
7356 # Object file extension for compiled fc test sources.
7358 _LT_TAGVAR(objext, $1)=$objext
7360 # No sense in running all these tests if we already determined that
7361 # the FC compiler isn't working. Some variables (like enable_shared)
7362 # are currently assumed to apply to all compilers on this platform,
7363 # and will be corrupted by setting them based on a non-working compiler.
7364 if test "$_lt_disable_FC" != yes; then
7365 # Code to be used in simple compile tests
7366 lt_simple_compile_test_code="\
7372 # Code to be used in simple link tests
7373 lt_simple_link_test_code="\
7378 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7381 # save warnings/boilerplate of simple test code
7382 _LT_COMPILER_BOILERPLATE
7383 _LT_LINKER_BOILERPLATE
7385 # Allow CC to be a program name with arguments.
7390 GCC=$ac_cv_fc_compiler_gnu
7392 _LT_TAGVAR(compiler, $1)=$CC
7393 _LT_CC_BASENAME([$compiler])
7395 if test -n "$compiler"; then
7396 AC_MSG_CHECKING([if libtool supports shared libraries])
7397 AC_MSG_RESULT([$can_build_shared])
7399 AC_MSG_CHECKING([whether to build shared libraries])
7400 test "$can_build_shared" = "no" && enable_shared=no
7402 # On AIX, shared libraries and static libraries use the same namespace, and
7403 # are all built from PIC.
7406 test "$enable_shared" = yes && enable_static=no
7407 if test -n "$RANLIB"; then
7408 archive_cmds="$archive_cmds~\$RANLIB \$lib"
7409 postinstall_cmds='$RANLIB $lib'
7413 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7414 test "$enable_shared" = yes && enable_static=no
7418 AC_MSG_RESULT([$enable_shared])
7420 AC_MSG_CHECKING([whether to build static libraries])
7421 # Make sure either enable_shared or enable_static is yes.
7422 test "$enable_shared" = yes || enable_static=yes
7423 AC_MSG_RESULT([$enable_static])
7425 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
7426 _LT_TAGVAR(LD, $1)="$LD"
7429 ## There is no encapsulation within the following macros, do not change
7430 ## the running order or otherwise move them around unless you know exactly
7431 ## what you are doing...
7432 _LT_SYS_HIDDEN_LIBDEPS($1)
7433 _LT_COMPILER_PIC($1)
7434 _LT_COMPILER_C_O($1)
7435 _LT_COMPILER_FILE_LOCKS($1)
7436 _LT_LINKER_SHLIBS($1)
7437 _LT_SYS_DYNAMIC_LINKER($1)
7438 _LT_LINKER_HARDCODE_LIBPATH($1)
7441 fi # test -n "$compiler"
7445 fi # test "$_lt_disable_FC" != yes
7448 ])# _LT_LANG_FC_CONFIG
7451 # _LT_LANG_GCJ_CONFIG([TAG])
7452 # --------------------------
7453 # Ensure that the configuration variables for the GNU Java Compiler compiler
7454 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7455 # to write the compiler configuration to `libtool'.
7456 m4_defun([_LT_LANG_GCJ_CONFIG],
7457 [AC_REQUIRE([LT_PROG_GCJ])dnl
7460 # Source file extension for Java test sources.
7463 # Object file extension for compiled Java test sources.
7465 _LT_TAGVAR(objext, $1)=$objext
7467 # Code to be used in simple compile tests
7468 lt_simple_compile_test_code="class foo {}"
7470 # Code to be used in simple link tests
7471 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
7473 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7476 # save warnings/boilerplate of simple test code
7477 _LT_COMPILER_BOILERPLATE
7478 _LT_LINKER_BOILERPLATE
7480 # Allow CC to be a program name with arguments.
7486 _LT_TAGVAR(compiler, $1)=$CC
7487 _LT_TAGVAR(LD, $1)="$LD"
7488 _LT_CC_BASENAME([$compiler])
7490 # GCJ did not exist at the time GCC didn't implicitly link libc in.
7491 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
7493 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7495 if test -n "$compiler"; then
7496 _LT_COMPILER_NO_RTTI($1)
7497 _LT_COMPILER_PIC($1)
7498 _LT_COMPILER_C_O($1)
7499 _LT_COMPILER_FILE_LOCKS($1)
7500 _LT_LINKER_SHLIBS($1)
7501 _LT_LINKER_HARDCODE_LIBPATH($1)
7510 ])# _LT_LANG_GCJ_CONFIG
7513 # _LT_LANG_RC_CONFIG([TAG])
7514 # -------------------------
7515 # Ensure that the configuration variables for the Windows resource compiler
7516 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7517 # to write the compiler configuration to `libtool'.
7518 m4_defun([_LT_LANG_RC_CONFIG],
7519 [AC_REQUIRE([LT_PROG_RC])dnl
7522 # Source file extension for RC test sources.
7525 # Object file extension for compiled RC test sources.
7527 _LT_TAGVAR(objext, $1)=$objext
7529 # Code to be used in simple compile tests
7530 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
7532 # Code to be used in simple link tests
7533 lt_simple_link_test_code="$lt_simple_compile_test_code"
7535 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
7538 # save warnings/boilerplate of simple test code
7539 _LT_COMPILER_BOILERPLATE
7540 _LT_LINKER_BOILERPLATE
7542 # Allow CC to be a program name with arguments.
7548 _LT_TAGVAR(compiler, $1)=$CC
7549 _LT_CC_BASENAME([$compiler])
7550 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
7552 if test -n "$compiler"; then
7560 ])# _LT_LANG_RC_CONFIG
7565 AC_DEFUN([LT_PROG_GCJ],
7566 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
7567 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
7568 [AC_CHECK_TOOL(GCJ, gcj,)
7569 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7570 AC_SUBST(GCJFLAGS)])])[]dnl
7574 AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
7575 dnl aclocal-1.4 backwards compatibility:
7576 dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
7581 AC_DEFUN([LT_PROG_RC],
7582 [AC_CHECK_TOOL(RC, windres,)
7586 AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
7587 dnl aclocal-1.4 backwards compatibility:
7588 dnl AC_DEFUN([LT_AC_PROG_RC], [])
7593 # If we don't have a new enough Autoconf to choose the best grep
7594 # available, choose the one first in the user's PATH.
7595 m4_defun([_LT_DECL_EGREP],
7596 [AC_REQUIRE([AC_PROG_EGREP])dnl
7597 AC_REQUIRE([AC_PROG_FGREP])dnl
7598 test -z "$GREP" && GREP=grep
7599 _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
7600 _LT_DECL([], [EGREP], [1], [An ERE matcher])
7601 _LT_DECL([], [FGREP], [1], [A literal string matcher])
7602 dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
7609 # Check for a fully-functional sed program, that truncates
7610 # as few characters as possible. Prefer GNU sed if found.
7611 m4_defun([_LT_DECL_SED],
7613 test -z "$SED" && SED=sed
7614 Xsed="$SED -e 1s/^X//"
7615 _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
7616 _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
7617 [Sed that helps us avoid accidentally triggering echo(1) options like -n])
7620 m4_ifndef([AC_PROG_SED], [
7621 # NOTE: This macro has been submitted for inclusion into #
7622 # GNU Autoconf as AC_PROG_SED. When it is available in #
7623 # a released version of Autoconf we should remove this #
7624 # macro and use it instead. #
7626 m4_defun([AC_PROG_SED],
7627 [AC_MSG_CHECKING([for a sed that does not truncate output])
7628 AC_CACHE_VAL(lt_cv_path_SED,
7629 [# Loop through the user's path and test for sed and gsed.
7630 # Then use that list of sed's as ones to test for truncation.
7631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7635 test -z "$as_dir" && as_dir=.
7636 for lt_ac_prog in sed gsed; do
7637 for ac_exec_ext in '' $ac_executable_extensions; do
7638 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
7639 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7647 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
7648 # along with /bin/sed that truncates output.
7649 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7650 test ! -f $lt_ac_sed && continue
7651 cat /dev/null > conftest.in
7653 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7654 # Check for GNU sed and select it if it is found.
7655 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7656 lt_cv_path_SED=$lt_ac_sed
7660 cat conftest.in conftest.in >conftest.tmp
7661 mv conftest.tmp conftest.in
7662 cp conftest.in conftest.nl
7664 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7665 cmp -s conftest.out conftest.nl || break
7666 # 10000 chars as input seems more than enough
7667 test $lt_ac_count -gt 10 && break
7668 lt_ac_count=`expr $lt_ac_count + 1`
7669 if test $lt_ac_count -gt $lt_ac_max; then
7670 lt_ac_max=$lt_ac_count
7671 lt_cv_path_SED=$lt_ac_sed
7678 AC_MSG_RESULT([$SED])
7683 AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
7684 dnl aclocal-1.4 backwards compatibility:
7685 dnl AC_DEFUN([LT_AC_PROG_SED], [])
7688 # _LT_CHECK_SHELL_FEATURES
7689 # ------------------------
7690 # Find out whether the shell is Bourne or XSI compatible,
7691 # or has some other useful features.
7692 m4_defun([_LT_CHECK_SHELL_FEATURES],
7693 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
7694 # Try some XSI features
7697 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
7699 && eval 'test $(( 1 + 1 )) -eq 2 \
7700 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7702 AC_MSG_RESULT([$xsi_shell])
7703 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
7705 AC_MSG_CHECKING([whether the shell understands "+="])
7707 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
7709 && lt_shell_append=yes
7710 AC_MSG_RESULT([$lt_shell_append])
7711 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
7713 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7718 _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
7720 # test EBCDIC or ASCII
7721 case `echo X|tr X '\101'` in
7722 A) # ASCII based system
7723 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7724 lt_SP2NL='tr \040 \012'
7725 lt_NL2SP='tr \015\012 \040\040'
7727 *) # EBCDIC based system
7728 lt_SP2NL='tr \100 \n'
7729 lt_NL2SP='tr \r\n \100\100'
7732 _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
7733 _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
7734 ])# _LT_CHECK_SHELL_FEATURES
7737 # _LT_PROG_XSI_SHELLFNS
7738 # ---------------------
7739 # Bourne and XSI compatible variants of some useful shell functions.
7740 m4_defun([_LT_PROG_XSI_SHELLFNS],
7743 cat << \_LT_EOF >> "$cfgfile"
7745 # func_dirname file append nondir_replacement
7746 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
7747 # otherwise set result to NONDIR_REPLACEMENT.
7751 */*) func_dirname_result="${1%/*}${2}" ;;
7752 * ) func_dirname_result="${3}" ;;
7756 # func_basename file
7759 func_basename_result="${1##*/}"
7762 # func_dirname_and_basename file append nondir_replacement
7763 # perform func_basename and func_dirname in a single function
7765 # dirname: Compute the dirname of FILE. If nonempty,
7766 # add APPEND to the result, otherwise set result
7767 # to NONDIR_REPLACEMENT.
7768 # value returned in "$func_dirname_result"
7769 # basename: Compute filename of FILE.
7770 # value retuned in "$func_basename_result"
7771 # Implementation must be kept synchronized with func_dirname
7772 # and func_basename. For efficiency, we do not delegate to
7773 # those functions but instead duplicate the functionality here.
7774 func_dirname_and_basename ()
7777 */*) func_dirname_result="${1%/*}${2}" ;;
7778 * ) func_dirname_result="${3}" ;;
7780 func_basename_result="${1##*/}"
7783 # func_stripname prefix suffix name
7784 # strip PREFIX and SUFFIX off of NAME.
7785 # PREFIX and SUFFIX must not contain globbing or regex special
7786 # characters, hashes, percent signs, but SUFFIX may contain a leading
7787 # dot (in which case that matches only a dot).
7790 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
7791 # positional parameters, so assign one to ordinary parameter first.
7792 func_stripname_result=${3}
7793 func_stripname_result=${func_stripname_result#"${1}"}
7794 func_stripname_result=${func_stripname_result%"${2}"}
7800 func_opt_split_opt=${1%%=*}
7801 func_opt_split_arg=${1#*=}
7808 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
7809 *) func_lo2o_result=${1} ;;
7813 # func_xform libobj-or-source
7816 func_xform_result=${1%.*}.lo
7819 # func_arith arithmetic-term...
7822 func_arith_result=$(( $[*] ))
7826 # STRING may not start with a hyphen.
7829 func_len_result=${#1}
7834 *) # Bourne compatible functions.
7835 cat << \_LT_EOF >> "$cfgfile"
7837 # func_dirname file append nondir_replacement
7838 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
7839 # otherwise set result to NONDIR_REPLACEMENT.
7842 # Extract subdirectory from the argument.
7843 func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
7844 if test "X$func_dirname_result" = "X${1}"; then
7845 func_dirname_result="${3}"
7847 func_dirname_result="$func_dirname_result${2}"
7851 # func_basename file
7854 func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
7857 dnl func_dirname_and_basename
7858 dnl A portable version of this function is already defined in general.m4sh
7859 dnl so there is no need for it here.
7861 # func_stripname prefix suffix name
7862 # strip PREFIX and SUFFIX off of NAME.
7863 # PREFIX and SUFFIX must not contain globbing or regex special
7864 # characters, hashes, percent signs, but SUFFIX may contain a leading
7865 # dot (in which case that matches only a dot).
7866 # func_strip_suffix prefix name
7870 .*) func_stripname_result=`$ECHO "X${3}" \
7871 | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
7872 *) func_stripname_result=`$ECHO "X${3}" \
7873 | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
7878 my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
7879 my_sed_long_arg='1s/^-[[^=]]*=//'
7884 func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
7885 func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
7891 func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
7894 # func_xform libobj-or-source
7897 func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'`
7900 # func_arith arithmetic-term...
7903 func_arith_result=`expr "$[@]"`
7907 # STRING may not start with a hyphen.
7910 func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
7916 case $lt_shell_append in
7918 cat << \_LT_EOF >> "$cfgfile"
7920 # func_append var value
7921 # Append VALUE to the end of shell variable VAR.
7929 cat << \_LT_EOF >> "$cfgfile"
7931 # func_append var value
7932 # Append VALUE to the end of shell variable VAR.
7935 eval "$[1]=\$$[1]\$[2]"
7943 # Helper functions for option handling. -*- Autoconf -*-
7945 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
7946 # Written by Gary V. Vaughan, 2004
7948 # This file is free software; the Free Software Foundation gives
7949 # unlimited permission to copy and/or distribute it, with or without
7950 # modifications, as long as this notice is preserved.
7952 # serial 6 ltoptions.m4
7954 # This is to help aclocal find these macros, as it can't see m4_define.
7955 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
7958 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
7959 # ------------------------------------------
7960 m4_define([_LT_MANGLE_OPTION],
7961 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
7964 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
7965 # ---------------------------------------
7966 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
7967 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
7969 m4_define([_LT_SET_OPTION],
7970 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
7971 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
7972 _LT_MANGLE_DEFUN([$1], [$2]),
7973 [m4_warning([Unknown $1 option `$2'])])[]dnl
7977 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
7978 # ------------------------------------------------------------
7979 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
7980 m4_define([_LT_IF_OPTION],
7981 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
7984 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
7985 # -------------------------------------------------------
7986 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
7988 m4_define([_LT_UNLESS_OPTIONS],
7989 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
7990 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
7991 [m4_define([$0_found])])])[]dnl
7992 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
7997 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
7998 # ----------------------------------------
7999 # OPTION-LIST is a space-separated list of Libtool options associated
8000 # with MACRO-NAME. If any OPTION has a matching handler declared with
8001 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
8002 # the unknown option and exit.
8003 m4_defun([_LT_SET_OPTIONS],
8005 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
8006 [_LT_SET_OPTION([$1], _LT_Option)])
8008 m4_if([$1],[LT_INIT],[
8010 dnl Simply set some default values (i.e off) if boolean options were not
8012 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
8014 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
8017 dnl If no reference was made to various pairs of opposing options, then
8018 dnl we run the default mode handler for the pair. For example, if neither
8019 dnl `shared' nor `disable-shared' was passed, we enable building of shared
8020 dnl archives by default:
8021 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
8022 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
8023 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
8024 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
8025 [_LT_ENABLE_FAST_INSTALL])
8031 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
8032 # -----------------------------------------
8033 m4_define([_LT_MANGLE_DEFUN],
8034 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
8037 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
8038 # -----------------------------------------------
8039 m4_define([LT_OPTION_DEFINE],
8040 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
8041 ])# LT_OPTION_DEFINE
8046 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
8049 AU_DEFUN([AC_LIBTOOL_DLOPEN],
8050 [_LT_SET_OPTION([LT_INIT], [dlopen])
8051 AC_DIAGNOSE([obsolete],
8052 [$0: Remove this warning and the call to _LT_SET_OPTION when you
8053 put the `dlopen' option into LT_INIT's first parameter.])
8056 dnl aclocal-1.4 backwards compatibility:
8057 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
8062 # Declare package support for building win32 dll's.
8063 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
8064 [enable_win32_dll=yes
8067 *-*-cygwin* | *-*-mingw* | *-*-pw32*)
8068 AC_CHECK_TOOL(AS, as, false)
8069 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
8070 AC_CHECK_TOOL(OBJDUMP, objdump, false)
8074 test -z "$AS" && AS=as
8075 _LT_DECL([], [AS], [0], [Assembler program])dnl
8077 test -z "$DLLTOOL" && DLLTOOL=dlltool
8078 _LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl
8080 test -z "$OBJDUMP" && OBJDUMP=objdump
8081 _LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl
8084 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
8085 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
8086 _LT_SET_OPTION([LT_INIT], [win32-dll])
8087 AC_DIAGNOSE([obsolete],
8088 [$0: Remove this warning and the call to _LT_SET_OPTION when you
8089 put the `win32-dll' option into LT_INIT's first parameter.])
8092 dnl aclocal-1.4 backwards compatibility:
8093 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
8096 # _LT_ENABLE_SHARED([DEFAULT])
8097 # ----------------------------
8098 # implement the --enable-shared flag, and supports the `shared' and
8099 # `disable-shared' LT_INIT options.
8100 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
8101 m4_define([_LT_ENABLE_SHARED],
8102 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
8103 AC_ARG_ENABLE([shared],
8104 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
8105 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
8106 [p=${PACKAGE-default}
8108 yes) enable_shared=yes ;;
8109 no) enable_shared=no ;;
8112 # Look at the argument we got. We use all the common list separators.
8113 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8114 for pkg in $enableval; do
8116 if test "X$pkg" = "X$p"; then
8123 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
8125 _LT_DECL([build_libtool_libs], [enable_shared], [0],
8126 [Whether or not to build shared libraries])
8127 ])# _LT_ENABLE_SHARED
8129 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
8130 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
8133 AC_DEFUN([AC_ENABLE_SHARED],
8134 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
8137 AC_DEFUN([AC_DISABLE_SHARED],
8138 [_LT_SET_OPTION([LT_INIT], [disable-shared])
8141 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
8142 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
8144 dnl aclocal-1.4 backwards compatibility:
8145 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
8146 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
8150 # _LT_ENABLE_STATIC([DEFAULT])
8151 # ----------------------------
8152 # implement the --enable-static flag, and support the `static' and
8153 # `disable-static' LT_INIT options.
8154 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
8155 m4_define([_LT_ENABLE_STATIC],
8156 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
8157 AC_ARG_ENABLE([static],
8158 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
8159 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
8160 [p=${PACKAGE-default}
8162 yes) enable_static=yes ;;
8163 no) enable_static=no ;;
8166 # Look at the argument we got. We use all the common list separators.
8167 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8168 for pkg in $enableval; do
8170 if test "X$pkg" = "X$p"; then
8177 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
8179 _LT_DECL([build_old_libs], [enable_static], [0],
8180 [Whether or not to build static libraries])
8181 ])# _LT_ENABLE_STATIC
8183 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
8184 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
8187 AC_DEFUN([AC_ENABLE_STATIC],
8188 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
8191 AC_DEFUN([AC_DISABLE_STATIC],
8192 [_LT_SET_OPTION([LT_INIT], [disable-static])
8195 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
8196 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
8198 dnl aclocal-1.4 backwards compatibility:
8199 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
8200 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
8204 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
8205 # ----------------------------------
8206 # implement the --enable-fast-install flag, and support the `fast-install'
8207 # and `disable-fast-install' LT_INIT options.
8208 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
8209 m4_define([_LT_ENABLE_FAST_INSTALL],
8210 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
8211 AC_ARG_ENABLE([fast-install],
8212 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
8213 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
8214 [p=${PACKAGE-default}
8216 yes) enable_fast_install=yes ;;
8217 no) enable_fast_install=no ;;
8219 enable_fast_install=no
8220 # Look at the argument we got. We use all the common list separators.
8221 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8222 for pkg in $enableval; do
8224 if test "X$pkg" = "X$p"; then
8225 enable_fast_install=yes
8231 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
8233 _LT_DECL([fast_install], [enable_fast_install], [0],
8234 [Whether or not to optimize for fast installation])dnl
8235 ])# _LT_ENABLE_FAST_INSTALL
8237 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
8238 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
8241 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
8242 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
8243 AC_DIAGNOSE([obsolete],
8244 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
8245 the `fast-install' option into LT_INIT's first parameter.])
8248 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
8249 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
8250 AC_DIAGNOSE([obsolete],
8251 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
8252 the `disable-fast-install' option into LT_INIT's first parameter.])
8255 dnl aclocal-1.4 backwards compatibility:
8256 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
8257 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
8260 # _LT_WITH_PIC([MODE])
8261 # --------------------
8262 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
8264 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
8265 m4_define([_LT_WITH_PIC],
8267 [AS_HELP_STRING([--with-pic],
8268 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
8269 [pic_mode="$withval"],
8272 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
8274 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
8277 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
8278 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
8281 AU_DEFUN([AC_LIBTOOL_PICMODE],
8282 [_LT_SET_OPTION([LT_INIT], [pic-only])
8283 AC_DIAGNOSE([obsolete],
8284 [$0: Remove this warning and the call to _LT_SET_OPTION when you
8285 put the `pic-only' option into LT_INIT's first parameter.])
8288 dnl aclocal-1.4 backwards compatibility:
8289 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
8292 m4_define([_LTDL_MODE], [])
8293 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
8294 [m4_define([_LTDL_MODE], [nonrecursive])])
8295 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
8296 [m4_define([_LTDL_MODE], [recursive])])
8297 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
8298 [m4_define([_LTDL_MODE], [subproject])])
8300 m4_define([_LTDL_TYPE], [])
8301 LT_OPTION_DEFINE([LTDL_INIT], [installable],
8302 [m4_define([_LTDL_TYPE], [installable])])
8303 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
8304 [m4_define([_LTDL_TYPE], [convenience])])
8306 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
8308 # Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
8309 # Written by Gary V. Vaughan, 2004
8311 # This file is free software; the Free Software Foundation gives
8312 # unlimited permission to copy and/or distribute it, with or without
8313 # modifications, as long as this notice is preserved.
8315 # serial 5 ltsugar.m4
8317 # This is to help aclocal find these macros, as it can't see m4_define.
8318 AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
8321 # lt_join(SEP, ARG1, [ARG2...])
8322 # -----------------------------
8323 # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
8324 # associated separator.
8325 # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
8326 # versions in m4sugar had bugs.
8327 m4_define([lt_join],
8328 [m4_if([$#], [1], [],
8330 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
8331 m4_define([_lt_join],
8332 [m4_if([$#$2], [2], [],
8333 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
8339 # Manipulate m4 lists.
8340 # These macros are necessary as long as will still need to support
8341 # Autoconf-2.59 which quotes differently.
8342 m4_define([lt_car], [[$1]])
8344 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
8346 [m4_dquote(m4_shift($@))])])
8347 m4_define([lt_unquote], $1)
8350 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
8351 # ------------------------------------------
8352 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
8353 # Note that neither SEPARATOR nor STRING are expanded; they are appended
8354 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
8355 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
8356 # than defined and empty).
8358 # This macro is needed until we can rely on Autoconf 2.62, since earlier
8359 # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
8360 m4_define([lt_append],
8362 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
8366 # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
8367 # ----------------------------------------------------------
8368 # Produce a SEP delimited list of all paired combinations of elements of
8369 # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
8370 # has the form PREFIXmINFIXSUFFIXn.
8371 m4_define([lt_combine],
8372 [m4_if([$2], [], [],
8373 [m4_if([$4], [], [],
8374 [lt_join(m4_quote(m4_default([$1], [[, ]])),
8375 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_prefix, [$2],
8376 [m4_foreach(_Lt_suffix, lt_car([m4_shiftn(3, $@)]),
8377 [_Lt_prefix[]$3[]_Lt_suffix ])])))))])])dnl
8381 # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
8382 # -----------------------------------------------------------------------
8383 # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
8384 # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
8385 m4_define([lt_if_append_uniq],
8387 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
8388 [lt_append([$1], [$2], [$3])$4],
8390 [lt_append([$1], [$2], [$3])$4])])
8393 # lt_dict_add(DICT, KEY, VALUE)
8394 # -----------------------------
8395 m4_define([lt_dict_add],
8396 [m4_define([$1($2)], [$3])])
8399 # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
8400 # --------------------------------------------
8401 m4_define([lt_dict_add_subkey],
8402 [m4_define([$1($2:$3)], [$4])])
8405 # lt_dict_fetch(DICT, KEY, [SUBKEY])
8406 # ----------------------------------
8407 m4_define([lt_dict_fetch],
8409 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
8410 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
8413 # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
8414 # -----------------------------------------------------------------
8415 m4_define([lt_if_dict_fetch],
8416 [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
8421 # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
8422 # --------------------------------------------------------------
8423 m4_define([lt_dict_filter],
8424 [m4_if([$5], [], [],
8425 [lt_join(m4_quote(m4_default([$4], [[, ]])),
8426 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
8427 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
8430 # ltversion.m4 -- version numbers -*- Autoconf -*-
8432 # Copyright (C) 2004 Free Software Foundation, Inc.
8433 # Written by Scott James Remnant, 2004
8435 # This file is free software; the Free Software Foundation gives
8436 # unlimited permission to copy and/or distribute it, with or without
8437 # modifications, as long as this notice is preserved.
8439 # Generated from ltversion.in.
8441 # serial 2976 ltversion.m4
8442 # This file is part of GNU Libtool
8444 m4_define([LT_PACKAGE_VERSION], [2.2.4])
8445 m4_define([LT_PACKAGE_REVISION], [1.2976])
8447 AC_DEFUN([LTVERSION_VERSION],
8448 [macro_version='2.2.4'
8449 macro_revision='1.2976'
8450 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
8451 _LT_DECL(, macro_revision, 0)
8454 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
8456 # Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
8457 # Written by Scott James Remnant, 2004.
8459 # This file is free software; the Free Software Foundation gives
8460 # unlimited permission to copy and/or distribute it, with or without
8461 # modifications, as long as this notice is preserved.
8463 # serial 4 lt~obsolete.m4
8465 # These exist entirely to fool aclocal when bootstrapping libtool.
8467 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
8468 # which have later been changed to m4_define as they aren't part of the
8469 # exported API, or moved to Autoconf or Automake where they belong.
8471 # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
8472 # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
8473 # using a macro with the same name in our local m4/libtool.m4 it'll
8474 # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
8475 # and doesn't know about Autoconf macros at all.)
8477 # So we provide this file, which has a silly filename so it's always
8478 # included after everything else. This provides aclocal with the
8479 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
8480 # because those macros already exist, or will be overwritten later.
8481 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
8483 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
8484 # Yes, that means every name once taken will need to remain here until
8485 # we give up compatibility with versions before 1.7, at which point
8486 # we need to keep only those names which we still refer to.
8488 # This is to help aclocal find these macros, as it can't see m4_define.
8489 AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
8491 m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
8492 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
8493 m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
8494 m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
8495 m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
8496 m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
8497 m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
8498 m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
8499 m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
8500 m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
8501 m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
8502 m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
8503 m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
8504 m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
8505 m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
8506 m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
8507 m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
8508 m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
8509 m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
8510 m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
8511 m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
8512 m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
8513 m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
8514 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
8515 m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
8516 m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
8517 m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
8518 m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
8519 m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
8520 m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
8521 m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
8522 m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
8523 m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
8524 m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
8525 m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
8526 m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
8527 m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
8528 m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
8529 m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
8530 m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
8531 m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
8532 m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
8533 m4_ifndef([AC_LIBTOOL_RC], [AC_DEFUN([AC_LIBTOOL_RC])])
8534 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
8535 m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
8536 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
8537 m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
8538 m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
8539 m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
8540 m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
8541 m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
8542 m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
8543 m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
8544 m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
8545 m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
8547 # nls.m4 serial 3 (gettext-0.15)
8548 dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc.
8549 dnl This file is free software; the Free Software Foundation
8550 dnl gives unlimited permission to copy and/or distribute it,
8551 dnl with or without modifications, as long as this notice is preserved.
8553 dnl This file can can be used in projects which are not available under
8554 dnl the GNU General Public License or the GNU Library General Public
8555 dnl License but which still want to provide support for the GNU gettext
8557 dnl Please note that the actual code of the GNU gettext library is covered
8558 dnl by the GNU Library General Public License, and the rest of the GNU
8559 dnl gettext package package is covered by the GNU General Public License.
8560 dnl They are *not* in the public domain.
8563 dnl Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
8564 dnl Bruno Haible <haible@clisp.cons.org>, 2000-2003.
8570 AC_MSG_CHECKING([whether NLS is requested])
8571 dnl Default is enabled NLS
8573 [ --disable-nls do not use Native Language Support],
8574 USE_NLS=$enableval, USE_NLS=yes)
8575 AC_MSG_RESULT($USE_NLS)
8579 # Copyright (C) 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
8581 # This file is free software; the Free Software Foundation
8582 # gives unlimited permission to copy and/or distribute it,
8583 # with or without modifications, as long as this notice is preserved.
8585 # AM_AUTOMAKE_VERSION(VERSION)
8586 # ----------------------------
8587 # Automake X.Y traces this macro to ensure aclocal.m4 has been
8588 # generated from the m4 files accompanying Automake X.Y.
8589 # (This private macro should not be called outside this file.)
8590 AC_DEFUN([AM_AUTOMAKE_VERSION],
8591 [am__api_version='1.10'
8592 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
8593 dnl require some minimum version. Point them to the right macro.
8594 m4_if([$1], [1.10.1], [],
8595 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
8598 # _AM_AUTOCONF_VERSION(VERSION)
8599 # -----------------------------
8600 # aclocal traces this macro to find the Autoconf version.
8601 # This is a private macro too. Using m4_define simplifies
8602 # the logic in aclocal, which can simply ignore this definition.
8603 m4_define([_AM_AUTOCONF_VERSION], [])
8605 # AM_SET_CURRENT_AUTOMAKE_VERSION
8606 # -------------------------------
8607 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
8608 # This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
8609 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
8610 [AM_AUTOMAKE_VERSION([1.10.1])dnl
8611 m4_ifndef([AC_AUTOCONF_VERSION],
8612 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
8613 _AM_AUTOCONF_VERSION(AC_AUTOCONF_VERSION)])
8615 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
8617 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
8619 # This file is free software; the Free Software Foundation
8620 # gives unlimited permission to copy and/or distribute it,
8621 # with or without modifications, as long as this notice is preserved.
8623 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
8624 # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
8625 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
8627 # Of course, Automake must honor this variable whenever it calls a
8628 # tool from the auxiliary directory. The problem is that $srcdir (and
8629 # therefore $ac_aux_dir as well) can be either absolute or relative,
8630 # depending on how configure is run. This is pretty annoying, since
8631 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
8632 # source directory, any form will work fine, but in subdirectories a
8633 # relative path needs to be adjusted first.
8635 # $ac_aux_dir/missing
8636 # fails when called from a subdirectory if $ac_aux_dir is relative
8637 # $top_srcdir/$ac_aux_dir/missing
8638 # fails if $ac_aux_dir is absolute,
8639 # fails when called from a subdirectory in a VPATH build with
8640 # a relative $ac_aux_dir
8642 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
8643 # are both prefixed by $srcdir. In an in-source build this is usually
8644 # harmless because $srcdir is `.', but things will broke when you
8645 # start a VPATH build or use an absolute $srcdir.
8647 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
8648 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
8649 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
8650 # and then we would define $MISSING as
8651 # MISSING="\${SHELL} $am_aux_dir/missing"
8652 # This will work as long as MISSING is not called from configure, because
8653 # unfortunately $(top_srcdir) has no meaning in configure.
8654 # However there are other variables, like CC, which are often used in
8655 # configure, and could therefore not use this "fixed" $ac_aux_dir.
8657 # Another solution, used here, is to always expand $ac_aux_dir to an
8658 # absolute PATH. The drawback is that using absolute paths prevent a
8659 # configured tree to be moved without reconfiguration.
8661 AC_DEFUN([AM_AUX_DIR_EXPAND],
8662 [dnl Rely on autoconf to set up CDPATH properly.
8663 AC_PREREQ([2.50])dnl
8664 # expand $ac_aux_dir to an absolute path
8665 am_aux_dir=`cd $ac_aux_dir && pwd`
8669 # Copyright (C) 1996, 1997, 1999, 2000, 2001, 2002, 2003, 2005
8670 # Free Software Foundation, Inc.
8672 # This file is free software; the Free Software Foundation
8673 # gives unlimited permission to copy and/or distribute it,
8674 # with or without modifications, as long as this notice is preserved.
8678 # This was merged into AC_PROG_CC in Autoconf.
8680 AU_DEFUN([AM_PROG_CC_STDC],
8682 AC_DIAGNOSE([obsolete], [$0:
8683 your code should no longer depend upon `am_cv_prog_cc_stdc', but upon
8684 `ac_cv_prog_cc_stdc'. Remove this warning and the assignment when
8685 you adjust the code. You can also remove the above call to
8686 AC_PROG_CC if you already called it elsewhere.])
8687 am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
8689 AU_DEFUN([fp_PROG_CC_STDC])
8691 # AM_CONDITIONAL -*- Autoconf -*-
8693 # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
8694 # Free Software Foundation, Inc.
8696 # This file is free software; the Free Software Foundation
8697 # gives unlimited permission to copy and/or distribute it,
8698 # with or without modifications, as long as this notice is preserved.
8702 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
8703 # -------------------------------------
8704 # Define a conditional.
8705 AC_DEFUN([AM_CONDITIONAL],
8707 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
8708 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
8709 AC_SUBST([$1_TRUE])dnl
8710 AC_SUBST([$1_FALSE])dnl
8711 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
8712 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
8720 AC_CONFIG_COMMANDS_PRE(
8721 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
8722 AC_MSG_ERROR([[conditional "$1" was never defined.
8723 Usually this means the macro was only invoked conditionally.]])
8726 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
8727 # Free Software Foundation, Inc.
8729 # This file is free software; the Free Software Foundation
8730 # gives unlimited permission to copy and/or distribute it,
8731 # with or without modifications, as long as this notice is preserved.
8735 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
8736 # written in clear, in which case automake, when reading aclocal.m4,
8737 # will think it sees a *use*, and therefore will trigger all it's
8738 # C support machinery. Also note that it means that autoscan, seeing
8739 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
8742 # _AM_DEPENDENCIES(NAME)
8743 # ----------------------
8744 # See how the compiler implements dependency checking.
8745 # NAME is "CC", "CXX", "GCJ", or "OBJC".
8746 # We try a few techniques and use that to set a single cache variable.
8748 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
8749 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
8750 # dependency, and given that the user is not expected to run this macro,
8751 # just rely on AC_PROG_CC.
8752 AC_DEFUN([_AM_DEPENDENCIES],
8753 [AC_REQUIRE([AM_SET_DEPDIR])dnl
8754 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
8755 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
8756 AC_REQUIRE([AM_DEP_TRACK])dnl
8758 ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
8759 [$1], CXX, [depcc="$CXX" am_compiler_list=],
8760 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
8761 [$1], UPC, [depcc="$UPC" am_compiler_list=],
8762 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
8763 [depcc="$$1" am_compiler_list=])
8765 AC_CACHE_CHECK([dependency style of $depcc],
8766 [am_cv_$1_dependencies_compiler_type],
8767 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
8768 # We make a subdir and do the tests there. Otherwise we can end up
8769 # making bogus files that we don't know about and never remove. For
8770 # instance it was reported that on HP-UX the gcc test will end up
8771 # making a dummy file named `D' -- because `-MD' means `put the output
8774 # Copy depcomp to subdir because otherwise we won't find it if we're
8775 # using a relative directory.
8776 cp "$am_depcomp" conftest.dir
8778 # We will build objects and dependencies in a subdirectory because
8779 # it helps to detect inapplicable dependency modes. For instance
8780 # both Tru64's cc and ICC support -MD to output dependencies as a
8781 # side effect of compilation, but ICC will put the dependencies in
8782 # the current directory while Tru64 will put them in the object
8786 am_cv_$1_dependencies_compiler_type=none
8787 if test "$am_compiler_list" = ""; then
8788 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
8790 for depmode in $am_compiler_list; do
8791 # Setup a source with many dependencies, because some compilers
8792 # like to wrap large dependency lists on column 80 (with \), and
8793 # we should not choose a depcomp mode which is confused by this.
8795 # We need to recreate these files for each test, as the compiler may
8796 # overwrite some of them when testing with obscure command lines.
8797 # This happens at least with the AIX C compiler.
8799 for i in 1 2 3 4 5 6; do
8800 echo '#include "conftst'$i'.h"' >> sub/conftest.c
8801 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
8802 # Solaris 8's {/usr,}/bin/sh.
8803 touch sub/conftst$i.h
8805 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
8809 # after this tag, mechanisms are not by side-effect, so they'll
8810 # only be used when explicitly requested
8811 if test "x$enable_dependency_tracking" = xyes; then
8819 # We check with `-c' and `-o' for the sake of the "dashmstdout"
8820 # mode. It turns out that the SunPro C++ compiler does not properly
8821 # handle `-M -o', and we need to detect this.
8822 if depmode=$depmode \
8823 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
8824 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
8825 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
8826 >/dev/null 2>conftest.err &&
8827 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
8828 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
8829 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
8830 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
8831 # icc doesn't choke on unknown options, it will just issue warnings
8832 # or remarks (even with -Werror). So we grep stderr for any message
8833 # that says an option was ignored or not supported.
8834 # When given -MP, icc 7.0 and 7.1 complain thusly:
8835 # icc: Command line warning: ignoring option '-M'; no argument required
8836 # The diagnosis changed in icc 8.0:
8837 # icc: Command line remark: option '-MP' not supported
8838 if (grep 'ignoring option' conftest.err ||
8839 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
8840 am_cv_$1_dependencies_compiler_type=$depmode
8849 am_cv_$1_dependencies_compiler_type=none
8852 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
8853 AM_CONDITIONAL([am__fastdep$1], [
8854 test "x$enable_dependency_tracking" != xno \
8855 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
8861 # Choose a directory name for dependency files.
8862 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
8863 AC_DEFUN([AM_SET_DEPDIR],
8864 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
8865 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
8871 AC_DEFUN([AM_DEP_TRACK],
8872 [AC_ARG_ENABLE(dependency-tracking,
8873 [ --disable-dependency-tracking speeds up one-time build
8874 --enable-dependency-tracking do not reject slow dependency extractors])
8875 if test "x$enable_dependency_tracking" != xno; then
8876 am_depcomp="$ac_aux_dir/depcomp"
8879 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
8880 AC_SUBST([AMDEPBACKSLASH])dnl
8881 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
8884 # Generate code to set up dependency tracking. -*- Autoconf -*-
8886 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
8887 # Free Software Foundation, Inc.
8889 # This file is free software; the Free Software Foundation
8890 # gives unlimited permission to copy and/or distribute it,
8891 # with or without modifications, as long as this notice is preserved.
8895 # _AM_OUTPUT_DEPENDENCY_COMMANDS
8896 # ------------------------------
8897 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
8898 [for mf in $CONFIG_FILES; do
8899 # Strip MF so we end up with the name of the file.
8900 mf=`echo "$mf" | sed -e 's/:.*$//'`
8901 # Check whether this is an Automake generated Makefile or not.
8902 # We used to match only the files named `Makefile.in', but
8903 # some people rename them; so instead we look at the file content.
8904 # Grep'ing the first line is not enough: some people post-process
8905 # each Makefile.in and add a new line on top of each file to say so.
8906 # Grep'ing the whole file is not good either: AIX grep has a line
8907 # limit of 2048, but all sed's we know have understand at least 4000.
8908 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
8909 dirpart=`AS_DIRNAME("$mf")`
8913 # Extract the definition of DEPDIR, am__include, and am__quote
8914 # from the Makefile without running `make'.
8915 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
8916 test -z "$DEPDIR" && continue
8917 am__include=`sed -n 's/^am__include = //p' < "$mf"`
8918 test -z "am__include" && continue
8919 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
8920 # When using ansi2knr, U may be empty or an underscore; expand it
8921 U=`sed -n 's/^U = //p' < "$mf"`
8922 # Find all dependency output files, they are included files with
8923 # $(DEPDIR) in their names. We invoke sed twice because it is the
8924 # simplest approach to changing $(DEPDIR) to its actual value in the
8926 for file in `sed -n "
8927 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
8928 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
8929 # Make sure the directory exists.
8930 test -f "$dirpart/$file" && continue
8931 fdir=`AS_DIRNAME(["$file"])`
8932 AS_MKDIR_P([$dirpart/$fdir])
8933 # echo "creating $dirpart/$file"
8934 echo '# dummy' > "$dirpart/$file"
8937 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
8940 # AM_OUTPUT_DEPENDENCY_COMMANDS
8941 # -----------------------------
8942 # This macro should only be invoked once -- use via AC_REQUIRE.
8944 # This code is only required when automatic dependency tracking
8945 # is enabled. FIXME. This creates each `.P' file that we will
8946 # need in order to bootstrap the dependency handling code.
8947 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
8948 [AC_CONFIG_COMMANDS([depfiles],
8949 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
8950 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
8953 # Do all the work for Automake. -*- Autoconf -*-
8955 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
8956 # 2005, 2006, 2008 Free Software Foundation, Inc.
8958 # This file is free software; the Free Software Foundation
8959 # gives unlimited permission to copy and/or distribute it,
8960 # with or without modifications, as long as this notice is preserved.
8964 # This macro actually does too much. Some checks are only needed if
8965 # your package does certain things. But this isn't really a big deal.
8967 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
8968 # AM_INIT_AUTOMAKE([OPTIONS])
8969 # -----------------------------------------------
8970 # The call with PACKAGE and VERSION arguments is the old style
8971 # call (pre autoconf-2.50), which is being phased out. PACKAGE
8972 # and VERSION should now be passed to AC_INIT and removed from
8973 # the call to AM_INIT_AUTOMAKE.
8974 # We support both call styles for the transition. After
8975 # the next Automake release, Autoconf can make the AC_INIT
8976 # arguments mandatory, and then we can depend on a new Autoconf
8977 # release and drop the old call support.
8978 AC_DEFUN([AM_INIT_AUTOMAKE],
8979 [AC_PREREQ([2.60])dnl
8980 dnl Autoconf wants to disallow AM_ names. We explicitly allow
8981 dnl the ones we care about.
8982 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
8983 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
8984 AC_REQUIRE([AC_PROG_INSTALL])dnl
8985 if test "`cd $srcdir && pwd`" != "`pwd`"; then
8986 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
8987 # is not polluted with repeated "-I."
8988 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
8989 # test to see if srcdir already configured
8990 if test -f $srcdir/config.status; then
8991 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
8995 # test whether we have cygpath
8996 if test -z "$CYGPATH_W"; then
8997 if (cygpath --version) >/dev/null 2>/dev/null; then
8998 CYGPATH_W='cygpath -w'
9003 AC_SUBST([CYGPATH_W])
9005 # Define the identity of the package.
9006 dnl Distinguish between old-style and new-style calls.
9008 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
9009 AC_SUBST([PACKAGE], [$1])dnl
9010 AC_SUBST([VERSION], [$2])],
9011 [_AM_SET_OPTIONS([$1])dnl
9012 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
9013 m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
9014 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
9015 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
9016 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
9018 _AM_IF_OPTION([no-define],,
9019 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
9020 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
9022 # Some tools Automake needs.
9023 AC_REQUIRE([AM_SANITY_CHECK])dnl
9024 AC_REQUIRE([AC_ARG_PROGRAM])dnl
9025 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
9026 AM_MISSING_PROG(AUTOCONF, autoconf)
9027 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
9028 AM_MISSING_PROG(AUTOHEADER, autoheader)
9029 AM_MISSING_PROG(MAKEINFO, makeinfo)
9031 AM_PROG_INSTALL_STRIP
9032 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
9033 # We need awk for the "check" target. The system "awk" is bad on
9035 AC_REQUIRE([AC_PROG_AWK])dnl
9036 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
9037 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
9038 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
9039 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
9040 [_AM_PROG_TAR([v7])])])
9041 _AM_IF_OPTION([no-dependencies],,
9042 [AC_PROVIDE_IFELSE([AC_PROG_CC],
9043 [_AM_DEPENDENCIES(CC)],
9044 [define([AC_PROG_CC],
9045 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
9046 AC_PROVIDE_IFELSE([AC_PROG_CXX],
9047 [_AM_DEPENDENCIES(CXX)],
9048 [define([AC_PROG_CXX],
9049 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
9050 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
9051 [_AM_DEPENDENCIES(OBJC)],
9052 [define([AC_PROG_OBJC],
9053 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
9058 # When config.status generates a header, we must update the stamp-h file.
9059 # This file resides in the same directory as the config header
9060 # that is generated. The stamp files are numbered to have different names.
9062 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
9063 # loop where config.status creates the headers, so we can generate
9064 # our stamp files there.
9065 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
9066 [# Compute $1's index in $config_headers.
9069 for _am_header in $config_headers :; do
9071 $_am_arg | $_am_arg:* )
9074 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
9077 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
9079 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
9081 # This file is free software; the Free Software Foundation
9082 # gives unlimited permission to copy and/or distribute it,
9083 # with or without modifications, as long as this notice is preserved.
9085 # AM_PROG_INSTALL_SH
9086 # ------------------
9087 # Define $install_sh.
9088 AC_DEFUN([AM_PROG_INSTALL_SH],
9089 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9090 install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
9091 AC_SUBST(install_sh)])
9093 # Copyright (C) 2003, 2005 Free Software Foundation, Inc.
9095 # This file is free software; the Free Software Foundation
9096 # gives unlimited permission to copy and/or distribute it,
9097 # with or without modifications, as long as this notice is preserved.
9101 # Check whether the underlying file-system supports filenames
9102 # with a leading dot. For instance MS-DOS doesn't.
9103 AC_DEFUN([AM_SET_LEADING_DOT],
9104 [rm -rf .tst 2>/dev/null
9105 mkdir .tst 2>/dev/null
9106 if test -d .tst; then
9111 rmdir .tst 2>/dev/null
9112 AC_SUBST([am__leading_dot])])
9114 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
9117 # Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005
9118 # Free Software Foundation, Inc.
9120 # This file is free software; the Free Software Foundation
9121 # gives unlimited permission to copy and/or distribute it,
9122 # with or without modifications, as long as this notice is preserved.
9126 AC_DEFUN([AM_MAINTAINER_MODE],
9127 [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
9128 dnl maintainer-mode is disabled by default
9129 AC_ARG_ENABLE(maintainer-mode,
9130 [ --enable-maintainer-mode enable make rules and dependencies not useful
9131 (and sometimes confusing) to the casual installer],
9132 USE_MAINTAINER_MODE=$enableval,
9133 USE_MAINTAINER_MODE=no)
9134 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
9135 AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
9136 MAINT=$MAINTAINER_MODE_TRUE
9141 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
9143 # Check to see how 'make' treats includes. -*- Autoconf -*-
9145 # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
9147 # This file is free software; the Free Software Foundation
9148 # gives unlimited permission to copy and/or distribute it,
9149 # with or without modifications, as long as this notice is preserved.
9155 # Check to see how make treats includes.
9156 AC_DEFUN([AM_MAKE_INCLUDE],
9157 [am_make=${MAKE-make}
9158 cat > confinc << 'END'
9163 # If we don't find an include directive, just comment out the code.
9164 AC_MSG_CHECKING([for style of include used by $am_make])
9168 # First try GNU make style include.
9169 echo "include confinc" > confmf
9170 # We grep out `Entering directory' and `Leaving directory'
9171 # messages which can occur if `w' ends up in MAKEFLAGS.
9172 # In particular we don't look at `^make:' because GNU make might
9173 # be invoked under some other name (usually "gmake"), in which
9174 # case it prints its new name instead of `make'.
9175 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
9180 # Now try BSD make style include.
9181 if test "$am__include" = "#"; then
9182 echo '.include "confinc"' > confmf
9183 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
9184 am__include=.include
9189 AC_SUBST([am__include])
9190 AC_SUBST([am__quote])
9191 AC_MSG_RESULT([$_am_result])
9192 rm -f confinc confmf
9195 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
9197 # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
9198 # Free Software Foundation, Inc.
9200 # This file is free software; the Free Software Foundation
9201 # gives unlimited permission to copy and/or distribute it,
9202 # with or without modifications, as long as this notice is preserved.
9206 # AM_MISSING_PROG(NAME, PROGRAM)
9207 # ------------------------------
9208 AC_DEFUN([AM_MISSING_PROG],
9209 [AC_REQUIRE([AM_MISSING_HAS_RUN])
9210 $1=${$1-"${am_missing_run}$2"}
9214 # AM_MISSING_HAS_RUN
9215 # ------------------
9216 # Define MISSING if not defined so far and test if it supports --run.
9217 # If it does, set am_missing_run to use it, otherwise, to nothing.
9218 AC_DEFUN([AM_MISSING_HAS_RUN],
9219 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9220 AC_REQUIRE_AUX_FILE([missing])dnl
9221 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
9222 # Use eval to expand $SHELL
9223 if eval "$MISSING --run true"; then
9224 am_missing_run="$MISSING --run "
9227 AC_MSG_WARN([`missing' script is too old or missing])
9231 # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
9233 # This file is free software; the Free Software Foundation
9234 # gives unlimited permission to copy and/or distribute it,
9235 # with or without modifications, as long as this notice is preserved.
9239 # Check for `mkdir -p'.
9240 AC_DEFUN([AM_PROG_MKDIR_P],
9241 [AC_PREREQ([2.60])dnl
9242 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
9243 dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
9244 dnl while keeping a definition of mkdir_p for backward compatibility.
9245 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
9246 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
9247 dnl Makefile.ins that do not define MKDIR_P, so we do our own
9248 dnl adjustment using top_builddir (which is defined more often than
9250 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
9252 [[\\/$]]* | ?:[[\\/]]*) ;;
9253 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
9257 # Helper functions for option handling. -*- Autoconf -*-
9259 # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
9261 # This file is free software; the Free Software Foundation
9262 # gives unlimited permission to copy and/or distribute it,
9263 # with or without modifications, as long as this notice is preserved.
9267 # _AM_MANGLE_OPTION(NAME)
9268 # -----------------------
9269 AC_DEFUN([_AM_MANGLE_OPTION],
9270 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
9272 # _AM_SET_OPTION(NAME)
9273 # ------------------------------
9274 # Set option NAME. Presently that only means defining a flag for this option.
9275 AC_DEFUN([_AM_SET_OPTION],
9276 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
9278 # _AM_SET_OPTIONS(OPTIONS)
9279 # ----------------------------------
9280 # OPTIONS is a space-separated list of Automake options.
9281 AC_DEFUN([_AM_SET_OPTIONS],
9282 [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
9284 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
9285 # -------------------------------------------
9286 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
9287 AC_DEFUN([_AM_IF_OPTION],
9288 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
9290 # Check to make sure that the build environment is sane. -*- Autoconf -*-
9292 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
9293 # Free Software Foundation, Inc.
9295 # This file is free software; the Free Software Foundation
9296 # gives unlimited permission to copy and/or distribute it,
9297 # with or without modifications, as long as this notice is preserved.
9303 AC_DEFUN([AM_SANITY_CHECK],
9304 [AC_MSG_CHECKING([whether build environment is sane])
9307 echo timestamp > conftest.file
9308 # Do `set' in a subshell so we don't clobber the current shell's
9309 # arguments. Must try -L first in case configure is actually a
9310 # symlink; some systems play weird games with the mod time of symlinks
9311 # (eg FreeBSD returns the mod time of the symlink's containing
9314 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
9315 if test "$[*]" = "X"; then
9317 set X `ls -t $srcdir/configure conftest.file`
9320 if test "$[*]" != "X $srcdir/configure conftest.file" \
9321 && test "$[*]" != "X conftest.file $srcdir/configure"; then
9323 # If neither matched, then we have a broken ls. This can happen
9324 # if, for instance, CONFIG_SHELL is bash and it inherits a
9325 # broken ls alias from the environment. This has actually
9326 # happened. Such a system could not be considered "sane".
9327 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
9328 alias in your environment])
9331 test "$[2]" = conftest.file
9337 AC_MSG_ERROR([newly created file is older than distributed files!
9338 Check your system clock])
9340 AC_MSG_RESULT(yes)])
9342 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
9344 # This file is free software; the Free Software Foundation
9345 # gives unlimited permission to copy and/or distribute it,
9346 # with or without modifications, as long as this notice is preserved.
9348 # AM_PROG_INSTALL_STRIP
9349 # ---------------------
9350 # One issue with vendor `install' (even GNU) is that you can't
9351 # specify the program used to strip binaries. This is especially
9352 # annoying in cross-compiling environments, where the build's strip
9353 # is unlikely to handle the host's binaries.
9354 # Fortunately install-sh will honor a STRIPPROG variable, so we
9355 # always use install-sh in `make install-strip', and initialize
9356 # STRIPPROG with the value of the STRIP variable (set by the user).
9357 AC_DEFUN([AM_PROG_INSTALL_STRIP],
9358 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
9359 # Installed binaries are usually stripped using `strip' when the user
9360 # run `make install-strip'. However `strip' might not be the right
9361 # tool to use in cross-compilation environments, therefore Automake
9362 # will honor the `STRIP' environment variable to overrule this program.
9363 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
9364 if test "$cross_compiling" != no; then
9365 AC_CHECK_TOOL([STRIP], [strip], :)
9367 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
9368 AC_SUBST([INSTALL_STRIP_PROGRAM])])
9370 # Copyright (C) 2006 Free Software Foundation, Inc.
9372 # This file is free software; the Free Software Foundation
9373 # gives unlimited permission to copy and/or distribute it,
9374 # with or without modifications, as long as this notice is preserved.
9376 # _AM_SUBST_NOTMAKE(VARIABLE)
9377 # ---------------------------
9378 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
9379 # This macro is traced by Automake.
9380 AC_DEFUN([_AM_SUBST_NOTMAKE])
9382 # Check how to create a tarball. -*- Autoconf -*-
9384 # Copyright (C) 2004, 2005 Free Software Foundation, Inc.
9386 # This file is free software; the Free Software Foundation
9387 # gives unlimited permission to copy and/or distribute it,
9388 # with or without modifications, as long as this notice is preserved.
9392 # _AM_PROG_TAR(FORMAT)
9393 # --------------------
9394 # Check how to create a tarball in format FORMAT.
9395 # FORMAT should be one of `v7', `ustar', or `pax'.
9397 # Substitute a variable $(am__tar) that is a command
9398 # writing to stdout a FORMAT-tarball containing the directory
9400 # tardir=directory && $(am__tar) > result.tar
9402 # Substitute a variable $(am__untar) that extract such
9403 # a tarball read from stdin.
9404 # $(am__untar) < result.tar
9405 AC_DEFUN([_AM_PROG_TAR],
9406 [# Always define AMTAR for backward compatibility.
9407 AM_MISSING_PROG([AMTAR], [tar])
9409 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
9410 [m4_case([$1], [ustar],, [pax],,
9411 [m4_fatal([Unknown tar format])])
9412 AC_MSG_CHECKING([how to create a $1 tar archive])
9413 # Loop over all known methods to create a tar archive until one works.
9414 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
9415 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
9416 # Do not fold the above two line into one, because Tru64 sh and
9417 # Solaris sh will not grok spaces in the rhs of `-'.
9418 for _am_tool in $_am_tools
9422 for _am_tar in tar gnutar gtar;
9424 AM_RUN_LOG([$_am_tar --version]) && break
9426 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
9427 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
9428 am__untar="$_am_tar -xf -"
9431 # Must skip GNU tar: if it does not support --format= it doesn't create
9432 # ustar tarball either.
9433 (tar --version) >/dev/null 2>&1 && continue
9434 am__tar='tar chf - "$$tardir"'
9435 am__tar_='tar chf - "$tardir"'
9436 am__untar='tar xf -'
9439 am__tar='pax -L -x $1 -w "$$tardir"'
9440 am__tar_='pax -L -x $1 -w "$tardir"'
9444 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
9445 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
9446 am__untar='cpio -i -H $1 -d'
9455 # If the value was cached, stop now. We just wanted to have am__tar
9456 # and am__untar set.
9457 test -n "${am_cv_prog_tar_$1}" && break
9459 # tar/untar a dummy directory, and stop if the command works
9462 echo GrepMe > conftest.dir/file
9463 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
9465 if test -s conftest.tar; then
9466 AM_RUN_LOG([$am__untar <conftest.tar])
9467 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
9472 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
9473 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
9475 AC_SUBST([am__untar])