Add dbus support. (Closes: #720604)
[debian/lxappearance.git] / aclocal.m4
CommitLineData
ae1f8f29
AG
1# generated automatically by aclocal 1.14 -*- Autoconf -*-
2
3# Copyright (C) 1996-2013 Free Software Foundation, Inc.
08024023 4
08024023
DB
5# This file is free software; the Free Software Foundation
6# gives unlimited permission to copy and/or distribute it,
7# with or without modifications, as long as this notice is preserved.
8
9# This program is distributed in the hope that it will be useful,
10# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12# PARTICULAR PURPOSE.
13
ae1f8f29 14m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
eddc0c49
DB
15m4_ifndef([AC_AUTOCONF_VERSION],
16 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
ae1f8f29
AG
17m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
18[m4_warning([this file was generated for autoconf 2.69.
eddc0c49
DB
19You have another version of autoconf. It may work, but is not guaranteed to.
20If you have problems, you may need to regenerate the build system entirely.
ae1f8f29 21To do so, use the procedure documented by the package, typically 'autoreconf'.])])
08024023
DB
22
23# Copyright (C) 1995-2002 Free Software Foundation, Inc.
24# Copyright (C) 2001-2003,2004 Red Hat, Inc.
25#
26# This file is free software, distributed under the terms of the GNU
27# General Public License. As a special exception to the GNU General
28# Public License, this file may be distributed as part of a program
29# that contains a configuration script generated by Autoconf, under
30# the same distribution terms as the rest of that program.
31#
32# This file can be copied and used freely without restrictions. It can
33# be used in projects which are not available under the GNU Public License
34# but which still want to provide support for the GNU gettext functionality.
35#
36# Macro to add for using GNU gettext.
37# Ulrich Drepper <drepper@cygnus.com>, 1995, 1996
38#
39# Modified to never use included libintl.
40# Owen Taylor <otaylor@redhat.com>, 12/15/1998
41#
42# Major rework to remove unused code
43# Owen Taylor <otaylor@redhat.com>, 12/11/2002
44#
45# Added better handling of ALL_LINGUAS from GNU gettext version
46# written by Bruno Haible, Owen Taylor <otaylor.redhat.com> 5/30/3002
47#
48# Modified to require ngettext
49# Matthias Clasen <mclasen@redhat.com> 08/06/2004
50#
51# We need this here as well, since someone might use autoconf-2.5x
52# to configure GLib then an older version to configure a package
53# using AM_GLIB_GNU_GETTEXT
54AC_PREREQ(2.53)
55
56dnl
57dnl We go to great lengths to make sure that aclocal won't
58dnl try to pull in the installed version of these macros
59dnl when running aclocal in the glib directory.
60dnl
61m4_copy([AC_DEFUN],[glib_DEFUN])
62m4_copy([AC_REQUIRE],[glib_REQUIRE])
63dnl
64dnl At the end, if we're not within glib, we'll define the public
65dnl definitions in terms of our private definitions.
66dnl
67
68# GLIB_LC_MESSAGES
69#--------------------
70glib_DEFUN([GLIB_LC_MESSAGES],
71 [AC_CHECK_HEADERS([locale.h])
72 if test $ac_cv_header_locale_h = yes; then
73 AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
74 [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
75 am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
76 if test $am_cv_val_LC_MESSAGES = yes; then
77 AC_DEFINE(HAVE_LC_MESSAGES, 1,
78 [Define if your <locale.h> file defines LC_MESSAGES.])
79 fi
80 fi])
81
82# GLIB_PATH_PROG_WITH_TEST
83#----------------------------
84dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
85dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
86glib_DEFUN([GLIB_PATH_PROG_WITH_TEST],
87[# Extract the first word of "$2", so it can be a program name with args.
88set dummy $2; ac_word=[$]2
89AC_MSG_CHECKING([for $ac_word])
90AC_CACHE_VAL(ac_cv_path_$1,
91[case "[$]$1" in
92 /*)
93 ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
94 ;;
95 *)
96 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
97 for ac_dir in ifelse([$5], , $PATH, [$5]); do
98 test -z "$ac_dir" && ac_dir=.
99 if test -f $ac_dir/$ac_word; then
100 if [$3]; then
101 ac_cv_path_$1="$ac_dir/$ac_word"
102 break
103 fi
104 fi
105 done
106 IFS="$ac_save_ifs"
107dnl If no 4th arg is given, leave the cache variable unset,
108dnl so AC_PATH_PROGS will keep looking.
109ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
110])dnl
111 ;;
112esac])dnl
113$1="$ac_cv_path_$1"
114if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
115 AC_MSG_RESULT([$]$1)
116else
117 AC_MSG_RESULT(no)
118fi
119AC_SUBST($1)dnl
120])
121
122# GLIB_WITH_NLS
123#-----------------
124glib_DEFUN([GLIB_WITH_NLS],
125 dnl NLS is obligatory
eddc0c49 126 [USE_NLS=yes
08024023
DB
127 AC_SUBST(USE_NLS)
128
129 gt_cv_have_gettext=no
130
131 CATOBJEXT=NONE
132 XGETTEXT=:
133 INTLLIBS=
134
135 AC_CHECK_HEADER(libintl.h,
136 [gt_cv_func_dgettext_libintl="no"
137 libintl_extra_libs=""
138
139 #
140 # First check in libc
141 #
142 AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc,
143 [AC_TRY_LINK([
144#include <libintl.h>
145],
146 [return !ngettext ("","", 1)],
147 gt_cv_func_ngettext_libc=yes,
148 gt_cv_func_ngettext_libc=no)
149 ])
150
151 if test "$gt_cv_func_ngettext_libc" = "yes" ; then
152 AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc,
153 [AC_TRY_LINK([
154#include <libintl.h>
155],
156 [return !dgettext ("","")],
157 gt_cv_func_dgettext_libc=yes,
158 gt_cv_func_dgettext_libc=no)
159 ])
160 fi
161
162 if test "$gt_cv_func_ngettext_libc" = "yes" ; then
163 AC_CHECK_FUNCS(bind_textdomain_codeset)
164 fi
165
166 #
167 # If we don't have everything we want, check in libintl
168 #
169 if test "$gt_cv_func_dgettext_libc" != "yes" \
170 || test "$gt_cv_func_ngettext_libc" != "yes" \
171 || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then
172
173 AC_CHECK_LIB(intl, bindtextdomain,
174 [AC_CHECK_LIB(intl, ngettext,
175 [AC_CHECK_LIB(intl, dgettext,
176 gt_cv_func_dgettext_libintl=yes)])])
177
178 if test "$gt_cv_func_dgettext_libintl" != "yes" ; then
179 AC_MSG_CHECKING([if -liconv is needed to use gettext])
180 AC_MSG_RESULT([])
181 AC_CHECK_LIB(intl, ngettext,
182 [AC_CHECK_LIB(intl, dcgettext,
183 [gt_cv_func_dgettext_libintl=yes
184 libintl_extra_libs=-liconv],
185 :,-liconv)],
186 :,-liconv)
187 fi
188
189 #
190 # If we found libintl, then check in it for bind_textdomain_codeset();
191 # we'll prefer libc if neither have bind_textdomain_codeset(),
192 # and both have dgettext and ngettext
193 #
194 if test "$gt_cv_func_dgettext_libintl" = "yes" ; then
195 glib_save_LIBS="$LIBS"
196 LIBS="$LIBS -lintl $libintl_extra_libs"
197 unset ac_cv_func_bind_textdomain_codeset
198 AC_CHECK_FUNCS(bind_textdomain_codeset)
199 LIBS="$glib_save_LIBS"
200
201 if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then
202 gt_cv_func_dgettext_libc=no
203 else
204 if test "$gt_cv_func_dgettext_libc" = "yes" \
205 && test "$gt_cv_func_ngettext_libc" = "yes"; then
206 gt_cv_func_dgettext_libintl=no
207 fi
208 fi
209 fi
210 fi
211
212 if test "$gt_cv_func_dgettext_libc" = "yes" \
213 || test "$gt_cv_func_dgettext_libintl" = "yes"; then
214 gt_cv_have_gettext=yes
215 fi
216
217 if test "$gt_cv_func_dgettext_libintl" = "yes"; then
218 INTLLIBS="-lintl $libintl_extra_libs"
219 fi
220
221 if test "$gt_cv_have_gettext" = "yes"; then
222 AC_DEFINE(HAVE_GETTEXT,1,
223 [Define if the GNU gettext() function is already present or preinstalled.])
224 GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
225 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
226 if test "$MSGFMT" != "no"; then
227 glib_save_LIBS="$LIBS"
228 LIBS="$LIBS $INTLLIBS"
229 AC_CHECK_FUNCS(dcgettext)
230 MSGFMT_OPTS=
231 AC_MSG_CHECKING([if msgfmt accepts -c])
232 GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[
233msgid ""
234msgstr ""
235"Content-Type: text/plain; charset=UTF-8\n"
236"Project-Id-Version: test 1.0\n"
237"PO-Revision-Date: 2007-02-15 12:01+0100\n"
238"Last-Translator: test <foo@bar.xx>\n"
239"Language-Team: C <LL@li.org>\n"
240"MIME-Version: 1.0\n"
241"Content-Transfer-Encoding: 8bit\n"
242], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])])
243 AC_SUBST(MSGFMT_OPTS)
244 AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
245 GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
246 [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
247 AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
248 return _nl_msg_cat_cntr],
249 [CATOBJEXT=.gmo
250 DATADIRNAME=share],
251 [case $host in
252 *-*-solaris*)
253 dnl On Solaris, if bind_textdomain_codeset is in libc,
254 dnl GNU format message catalog is always supported,
255 dnl since both are added to the libc all together.
256 dnl Hence, we'd like to go with DATADIRNAME=share and
257 dnl and CATOBJEXT=.gmo in this case.
258 AC_CHECK_FUNC(bind_textdomain_codeset,
259 [CATOBJEXT=.gmo
260 DATADIRNAME=share],
261 [CATOBJEXT=.mo
262 DATADIRNAME=lib])
263 ;;
7f605299
DB
264 *-*-openbsd*)
265 CATOBJEXT=.mo
266 DATADIRNAME=share
267 ;;
08024023
DB
268 *)
269 CATOBJEXT=.mo
270 DATADIRNAME=lib
271 ;;
272 esac])
273 LIBS="$glib_save_LIBS"
274 INSTOBJEXT=.mo
275 else
276 gt_cv_have_gettext=no
277 fi
278 fi
279 ])
280
281 if test "$gt_cv_have_gettext" = "yes" ; then
282 AC_DEFINE(ENABLE_NLS, 1,
283 [always defined to indicate that i18n is enabled])
284 fi
285
286 dnl Test whether we really found GNU xgettext.
287 if test "$XGETTEXT" != ":"; then
288 dnl If it is not GNU xgettext we define it as : so that the
289 dnl Makefiles still can work.
290 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
291 : ;
292 else
293 AC_MSG_RESULT(
294 [found xgettext program is not GNU xgettext; ignore it])
295 XGETTEXT=":"
296 fi
297 fi
298
299 # We need to process the po/ directory.
300 POSUB=po
301
302 AC_OUTPUT_COMMANDS(
303 [case "$CONFIG_FILES" in *po/Makefile.in*)
304 sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
305 esac])
306
307 dnl These rules are solely for the distribution goal. While doing this
308 dnl we only have to keep exactly one list of the available catalogs
e7f9874d 309 dnl in configure.ac.
08024023
DB
310 for lang in $ALL_LINGUAS; do
311 GMOFILES="$GMOFILES $lang.gmo"
312 POFILES="$POFILES $lang.po"
313 done
314
315 dnl Make all variables we use known to autoconf.
316 AC_SUBST(CATALOGS)
317 AC_SUBST(CATOBJEXT)
318 AC_SUBST(DATADIRNAME)
319 AC_SUBST(GMOFILES)
320 AC_SUBST(INSTOBJEXT)
321 AC_SUBST(INTLLIBS)
322 AC_SUBST(PO_IN_DATADIR_TRUE)
323 AC_SUBST(PO_IN_DATADIR_FALSE)
324 AC_SUBST(POFILES)
325 AC_SUBST(POSUB)
326 ])
327
328# AM_GLIB_GNU_GETTEXT
329# -------------------
330# Do checks necessary for use of gettext. If a suitable implementation
331# of gettext is found in either in libintl or in the C library,
332# it will set INTLLIBS to the libraries needed for use of gettext
333# and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable
334# gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST()
335# on various variables needed by the Makefile.in.in installed by
336# glib-gettextize.
337dnl
338glib_DEFUN([GLIB_GNU_GETTEXT],
339 [AC_REQUIRE([AC_PROG_CC])dnl
340 AC_REQUIRE([AC_HEADER_STDC])dnl
341
342 GLIB_LC_MESSAGES
343 GLIB_WITH_NLS
344
345 if test "$gt_cv_have_gettext" = "yes"; then
346 if test "x$ALL_LINGUAS" = "x"; then
347 LINGUAS=
348 else
349 AC_MSG_CHECKING(for catalogs to be installed)
350 NEW_LINGUAS=
351 for presentlang in $ALL_LINGUAS; do
352 useit=no
353 if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then
354 desiredlanguages="$LINGUAS"
355 else
356 desiredlanguages="$ALL_LINGUAS"
357 fi
358 for desiredlang in $desiredlanguages; do
359 # Use the presentlang catalog if desiredlang is
360 # a. equal to presentlang, or
361 # b. a variant of presentlang (because in this case,
362 # presentlang can be used as a fallback for messages
363 # which are not translated in the desiredlang catalog).
364 case "$desiredlang" in
365 "$presentlang"*) useit=yes;;
366 esac
367 done
368 if test $useit = yes; then
369 NEW_LINGUAS="$NEW_LINGUAS $presentlang"
370 fi
371 done
372 LINGUAS=$NEW_LINGUAS
373 AC_MSG_RESULT($LINGUAS)
374 fi
375
376 dnl Construct list of names of catalog files to be constructed.
377 if test -n "$LINGUAS"; then
378 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
379 fi
380 fi
381
382 dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
383 dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
384 dnl Try to locate is.
385 MKINSTALLDIRS=
386 if test -n "$ac_aux_dir"; then
387 MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
388 fi
389 if test -z "$MKINSTALLDIRS"; then
390 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
391 fi
392 AC_SUBST(MKINSTALLDIRS)
393
394 dnl Generate list of files to be processed by xgettext which will
395 dnl be included in po/Makefile.
396 test -d po || mkdir po
397 if test "x$srcdir" != "x."; then
398 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
399 posrcprefix="$srcdir/"
400 else
401 posrcprefix="../$srcdir/"
402 fi
403 else
404 posrcprefix="../"
405 fi
406 rm -f po/POTFILES
407 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
408 < $srcdir/po/POTFILES.in > po/POTFILES
409 ])
410
411# AM_GLIB_DEFINE_LOCALEDIR(VARIABLE)
412# -------------------------------
413# Define VARIABLE to the location where catalog files will
414# be installed by po/Makefile.
415glib_DEFUN([GLIB_DEFINE_LOCALEDIR],
416[glib_REQUIRE([GLIB_GNU_GETTEXT])dnl
417glib_save_prefix="$prefix"
418glib_save_exec_prefix="$exec_prefix"
419glib_save_datarootdir="$datarootdir"
420test "x$prefix" = xNONE && prefix=$ac_default_prefix
421test "x$exec_prefix" = xNONE && exec_prefix=$prefix
422datarootdir=`eval echo "${datarootdir}"`
423if test "x$CATOBJEXT" = "x.mo" ; then
424 localedir=`eval echo "${libdir}/locale"`
425else
426 localedir=`eval echo "${datadir}/locale"`
427fi
428prefix="$glib_save_prefix"
429exec_prefix="$glib_save_exec_prefix"
430datarootdir="$glib_save_datarootdir"
431AC_DEFINE_UNQUOTED($1, "$localedir",
432 [Define the location where the catalogs will be installed])
433])
434
435dnl
436dnl Now the definitions that aclocal will find
437dnl
e7f9874d 438ifdef(glib_configure_ac,[],[
08024023
DB
439AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)])
440AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)])
441])dnl
442
443# GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL])
444#
445# Create a temporary file with TEST-FILE as its contents and pass the
446# file name to PROGRAM. Perform ACTION-IF-PASS if PROGRAM exits with
447# 0 and perform ACTION-IF-FAIL for any other exit status.
448AC_DEFUN([GLIB_RUN_PROG],
449[cat >conftest.foo <<_ACEOF
450$2
451_ACEOF
452if AC_RUN_LOG([$1 conftest.foo]); then
453 m4_ifval([$3], [$3], [:])
454m4_ifvaln([$4], [else $4])dnl
455echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD
456sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
457fi])
458
459
8df2f63a
DB
460
461dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
7f605299 462# serial 42 IT_PROG_INTLTOOL
8df2f63a
DB
463AC_DEFUN([IT_PROG_INTLTOOL], [
464AC_PREREQ([2.50])dnl
465AC_REQUIRE([AM_NLS])dnl
466
467case "$am__api_version" in
468 1.[01234])
469 AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
470 ;;
471 *)
472 ;;
473esac
474
7f605299
DB
475INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
476INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
477INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
8df2f63a
DB
478if test -n "$1"; then
479 AC_MSG_CHECKING([for intltool >= $1])
8df2f63a
DB
480 AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
481 test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
482 AC_MSG_ERROR([Your intltool is too old. You need intltool $1 or later.])
483fi
484
485AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
486AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
487AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
488if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
489 AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
490fi
491
7f605299
DB
492if test -z "$AM_DEFAULT_VERBOSITY"; then
493 AM_DEFAULT_VERBOSITY=1
494fi
495AC_SUBST([AM_DEFAULT_VERBOSITY])
496
497INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
498INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
499INTLTOOL__v_MERGE_0='@echo " ITMRG " [$]@;'
500AC_SUBST(INTLTOOL_V_MERGE)
501AC_SUBST(INTLTOOL__v_MERGE_)
502AC_SUBST(INTLTOOL__v_MERGE_0)
503
504INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
505intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
506intltool__v_merge_options_0='-q'
507AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
508AC_SUBST(intltool__v_merge_options_)
509AC_SUBST(intltool__v_merge_options_0)
510
511 INTLTOOL_DESKTOP_RULE='%.desktop: %.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
512INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
513 INTLTOOL_KEYS_RULE='%.keys: %.keys.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
514 INTLTOOL_PROP_RULE='%.prop: %.prop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
515 INTLTOOL_OAF_RULE='%.oaf: %.oaf.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -p $(top_srcdir)/po $< [$]@'
516 INTLTOOL_PONG_RULE='%.pong: %.pong.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
517 INTLTOOL_SERVER_RULE='%.server: %.server.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
518 INTLTOOL_SHEET_RULE='%.sheet: %.sheet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
519INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
520 INTLTOOL_UI_RULE='%.ui: %.ui.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
521 INTLTOOL_XML_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
522if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
523 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u --no-translations $< [$]@'
524else
525 INTLTOOL_XML_NOMERGE_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)_it_tmp_dir=tmp.intltool.[$][$]RANDOM && mkdir [$][$]_it_tmp_dir && LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u [$][$]_it_tmp_dir $< [$]@ && rmdir [$][$]_it_tmp_dir'
526fi
527 INTLTOOL_XAM_RULE='%.xam: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
528 INTLTOOL_KBD_RULE='%.kbd: %.kbd.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
529 INTLTOOL_CAVES_RULE='%.caves: %.caves.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
530 INTLTOOL_SCHEMAS_RULE='%.schemas: %.schemas.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
531 INTLTOOL_THEME_RULE='%.theme: %.theme.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
532 INTLTOOL_SERVICE_RULE='%.service: %.service.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
533 INTLTOOL_POLICY_RULE='%.policy: %.policy.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
8df2f63a
DB
534
535_IT_SUBST(INTLTOOL_DESKTOP_RULE)
536_IT_SUBST(INTLTOOL_DIRECTORY_RULE)
537_IT_SUBST(INTLTOOL_KEYS_RULE)
538_IT_SUBST(INTLTOOL_PROP_RULE)
539_IT_SUBST(INTLTOOL_OAF_RULE)
540_IT_SUBST(INTLTOOL_PONG_RULE)
541_IT_SUBST(INTLTOOL_SERVER_RULE)
542_IT_SUBST(INTLTOOL_SHEET_RULE)
543_IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
544_IT_SUBST(INTLTOOL_UI_RULE)
545_IT_SUBST(INTLTOOL_XAM_RULE)
546_IT_SUBST(INTLTOOL_KBD_RULE)
547_IT_SUBST(INTLTOOL_XML_RULE)
548_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
549_IT_SUBST(INTLTOOL_CAVES_RULE)
550_IT_SUBST(INTLTOOL_SCHEMAS_RULE)
551_IT_SUBST(INTLTOOL_THEME_RULE)
552_IT_SUBST(INTLTOOL_SERVICE_RULE)
553_IT_SUBST(INTLTOOL_POLICY_RULE)
554
ae1f8f29
AG
555# Check the gettext tools to make sure they are GNU
556AC_PATH_PROG(XGETTEXT, xgettext)
557AC_PATH_PROG(MSGMERGE, msgmerge)
558AC_PATH_PROG(MSGFMT, msgfmt)
559AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
560if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
561 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
562fi
563xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
564mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
565mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
566if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
567 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
568fi
569
570AC_PATH_PROG(INTLTOOL_PERL, perl)
571if test -z "$INTLTOOL_PERL"; then
572 AC_MSG_ERROR([perl not found])
573fi
574AC_MSG_CHECKING([for perl >= 5.8.1])
575$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
576if test $? -ne 0; then
577 AC_MSG_ERROR([perl 5.8.1 is required for intltool])
578else
579 IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
580 AC_MSG_RESULT([$IT_PERL_VERSION])
581fi
582if test "x$2" != "xno-xml"; then
583 AC_MSG_CHECKING([for XML::Parser])
584 if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
585 AC_MSG_RESULT([ok])
586 else
587 AC_MSG_ERROR([XML::Parser perl module is required for intltool])
588 fi
589fi
590
591# Substitute ALL_LINGUAS so we can use it in po/Makefile
592AC_SUBST(ALL_LINGUAS)
593
594# Set DATADIRNAME correctly if it is not set yet
595# (copied from glib-gettext.m4)
596if test -z "$DATADIRNAME"; then
597 AC_LINK_IFELSE(
598 [AC_LANG_PROGRAM([[]],
599 [[extern int _nl_msg_cat_cntr;
600 return _nl_msg_cat_cntr]])],
601 [DATADIRNAME=share],
602 [case $host in
603 *-*-solaris*)
604 dnl On Solaris, if bind_textdomain_codeset is in libc,
605 dnl GNU format message catalog is always supported,
606 dnl since both are added to the libc all together.
607 dnl Hence, we'd like to go with DATADIRNAME=share
608 dnl in this case.
609 AC_CHECK_FUNC(bind_textdomain_codeset,
610 [DATADIRNAME=share], [DATADIRNAME=lib])
611 ;;
612 *)
613 [DATADIRNAME=lib]
614 ;;
615 esac])
616fi
617AC_SUBST(DATADIRNAME)
618
619IT_PO_SUBDIR([po])
620
621])
622
623
624# IT_PO_SUBDIR(DIRNAME)
625# ---------------------
626# All po subdirs have to be declared with this macro; the subdir "po" is
627# declared by IT_PROG_INTLTOOL.
628#
629AC_DEFUN([IT_PO_SUBDIR],
630[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
631dnl
632dnl The following CONFIG_COMMANDS should be executed at the very end
633dnl of config.status.
634AC_CONFIG_COMMANDS_PRE([
635 AC_CONFIG_COMMANDS([$1/stamp-it], [
636 if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
637 AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
638 fi
639 rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
640 >"$1/stamp-it.tmp"
641 [sed '/^#/d
642 s/^[[].*] *//
643 /^[ ]*$/d
644 '"s|^| $ac_top_srcdir/|" \
645 "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
646 ]
647 [sed '/^POTFILES =/,/[^\\]$/ {
648 /^POTFILES =/!d
649 r $1/POTFILES
650 }
651 ' "$1/Makefile.in" >"$1/Makefile"]
652 rm -f "$1/Makefile.tmp"
653 mv "$1/stamp-it.tmp" "$1/stamp-it"
654 ])
655])dnl
656])
657
658# _IT_SUBST(VARIABLE)
659# -------------------
660# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
661#
662AC_DEFUN([_IT_SUBST],
663[
664AC_SUBST([$1])
665m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
666]
667)
668
669# deprecated macros
670AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
671# A hint is needed for aclocal from Automake <= 1.9.4:
672# AC_DEFUN([AC_PROG_INTLTOOL], ...)
673
674
675# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
676#
677# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
678# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
679# Foundation, Inc.
680# Written by Gordon Matzigkeit, 1996
681#
682# This file is free software; the Free Software Foundation gives
683# unlimited permission to copy and/or distribute it, with or without
684# modifications, as long as this notice is preserved.
685
686m4_define([_LT_COPYING], [dnl
687# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
688# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
689# Foundation, Inc.
690# Written by Gordon Matzigkeit, 1996
691#
692# This file is part of GNU Libtool.
693#
694# GNU Libtool is free software; you can redistribute it and/or
695# modify it under the terms of the GNU General Public License as
696# published by the Free Software Foundation; either version 2 of
697# the License, or (at your option) any later version.
698#
699# As a special exception to the GNU General Public License,
700# if you distribute this file as part of a program or library that
701# is built using GNU Libtool, you may include this file under the
702# same distribution terms that you use for the rest of that program.
703#
704# GNU Libtool is distributed in the hope that it will be useful,
705# but WITHOUT ANY WARRANTY; without even the implied warranty of
706# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
707# GNU General Public License for more details.
708#
709# You should have received a copy of the GNU General Public License
710# along with GNU Libtool; see the file COPYING. If not, a copy
711# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
712# obtained by writing to the Free Software Foundation, Inc.,
713# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
714])
715
716# serial 57 LT_INIT
717
718
719# LT_PREREQ(VERSION)
720# ------------------
721# Complain and exit if this libtool version is less that VERSION.
722m4_defun([LT_PREREQ],
723[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
724 [m4_default([$3],
725 [m4_fatal([Libtool version $1 or higher is required],
726 63)])],
727 [$2])])
728
729
730# _LT_CHECK_BUILDDIR
731# ------------------
732# Complain if the absolute build directory name contains unusual characters
733m4_defun([_LT_CHECK_BUILDDIR],
734[case `pwd` in
735 *\ * | *\ *)
736 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
737esac
738])
739
740
741# LT_INIT([OPTIONS])
742# ------------------
743AC_DEFUN([LT_INIT],
744[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
745AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
746AC_BEFORE([$0], [LT_LANG])dnl
747AC_BEFORE([$0], [LT_OUTPUT])dnl
748AC_BEFORE([$0], [LTDL_INIT])dnl
749m4_require([_LT_CHECK_BUILDDIR])dnl
750
751dnl Autoconf doesn't catch unexpanded LT_ macros by default:
752m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
753m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
754dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
755dnl unless we require an AC_DEFUNed macro:
756AC_REQUIRE([LTOPTIONS_VERSION])dnl
757AC_REQUIRE([LTSUGAR_VERSION])dnl
758AC_REQUIRE([LTVERSION_VERSION])dnl
759AC_REQUIRE([LTOBSOLETE_VERSION])dnl
760m4_require([_LT_PROG_LTMAIN])dnl
761
762_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
763
764dnl Parse OPTIONS
765_LT_SET_OPTIONS([$0], [$1])
766
767# This can be used to rebuild libtool when needed
768LIBTOOL_DEPS="$ltmain"
769
770# Always use our own libtool.
771LIBTOOL='$(SHELL) $(top_builddir)/libtool'
772AC_SUBST(LIBTOOL)dnl
773
774_LT_SETUP
775
776# Only expand once:
777m4_define([LT_INIT])
778])# LT_INIT
779
780# Old names:
781AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
782AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
783dnl aclocal-1.4 backwards compatibility:
784dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
785dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
786
787
788# _LT_CC_BASENAME(CC)
789# -------------------
790# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
791m4_defun([_LT_CC_BASENAME],
792[for cc_temp in $1""; do
793 case $cc_temp in
794 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
795 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
796 \-*) ;;
797 *) break;;
798 esac
799done
800cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
801])
802
803
804# _LT_FILEUTILS_DEFAULTS
805# ----------------------
806# It is okay to use these file commands and assume they have been set
807# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
808m4_defun([_LT_FILEUTILS_DEFAULTS],
809[: ${CP="cp -f"}
810: ${MV="mv -f"}
811: ${RM="rm -f"}
812])# _LT_FILEUTILS_DEFAULTS
813
814
815# _LT_SETUP
816# ---------
817m4_defun([_LT_SETUP],
818[AC_REQUIRE([AC_CANONICAL_HOST])dnl
819AC_REQUIRE([AC_CANONICAL_BUILD])dnl
820AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
821AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
822
823_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
824dnl
825_LT_DECL([], [host_alias], [0], [The host system])dnl
826_LT_DECL([], [host], [0])dnl
827_LT_DECL([], [host_os], [0])dnl
828dnl
829_LT_DECL([], [build_alias], [0], [The build system])dnl
830_LT_DECL([], [build], [0])dnl
831_LT_DECL([], [build_os], [0])dnl
832dnl
833AC_REQUIRE([AC_PROG_CC])dnl
834AC_REQUIRE([LT_PATH_LD])dnl
835AC_REQUIRE([LT_PATH_NM])dnl
836dnl
837AC_REQUIRE([AC_PROG_LN_S])dnl
838test -z "$LN_S" && LN_S="ln -s"
839_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
840dnl
841AC_REQUIRE([LT_CMD_MAX_LEN])dnl
842_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
843_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
844dnl
845m4_require([_LT_FILEUTILS_DEFAULTS])dnl
846m4_require([_LT_CHECK_SHELL_FEATURES])dnl
847m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
848m4_require([_LT_CMD_RELOAD])dnl
849m4_require([_LT_CHECK_MAGIC_METHOD])dnl
850m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
851m4_require([_LT_CMD_OLD_ARCHIVE])dnl
852m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
853m4_require([_LT_WITH_SYSROOT])dnl
854
855_LT_CONFIG_LIBTOOL_INIT([
856# See if we are running on zsh, and set the options which allow our
857# commands through without removal of \ escapes INIT.
858if test -n "\${ZSH_VERSION+set}" ; then
859 setopt NO_GLOB_SUBST
860fi
861])
862if test -n "${ZSH_VERSION+set}" ; then
863 setopt NO_GLOB_SUBST
864fi
865
866_LT_CHECK_OBJDIR
867
868m4_require([_LT_TAG_COMPILER])dnl
869
870case $host_os in
871aix3*)
872 # AIX sometimes has problems with the GCC collect2 program. For some
873 # reason, if we set the COLLECT_NAMES environment variable, the problems
874 # vanish in a puff of smoke.
875 if test "X${COLLECT_NAMES+set}" != Xset; then
876 COLLECT_NAMES=
877 export COLLECT_NAMES
878 fi
879 ;;
880esac
881
882# Global variables:
883ofile=libtool
884can_build_shared=yes
885
886# All known linkers require a `.a' archive for static linking (except MSVC,
887# which needs '.lib').
888libext=a
889
890with_gnu_ld="$lt_cv_prog_gnu_ld"
891
892old_CC="$CC"
893old_CFLAGS="$CFLAGS"
894
895# Set sane defaults for various variables
896test -z "$CC" && CC=cc
897test -z "$LTCC" && LTCC=$CC
898test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
899test -z "$LD" && LD=ld
900test -z "$ac_objext" && ac_objext=o
901
902_LT_CC_BASENAME([$compiler])
903
904# Only perform the check for file, if the check method requires it
905test -z "$MAGIC_CMD" && MAGIC_CMD=file
906case $deplibs_check_method in
907file_magic*)
908 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
909 _LT_PATH_MAGIC
910 fi
911 ;;
912esac
913
914# Use C for the default configuration in the libtool script
915LT_SUPPORTED_TAG([CC])
916_LT_LANG_C_CONFIG
917_LT_LANG_DEFAULT_CONFIG
918_LT_CONFIG_COMMANDS
919])# _LT_SETUP
920
921
922# _LT_PREPARE_SED_QUOTE_VARS
923# --------------------------
924# Define a few sed substitution that help us do robust quoting.
925m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
926[# Backslashify metacharacters that are still active within
927# double-quoted strings.
928sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
929
930# Same as above, but do not quote variable references.
931double_quote_subst='s/\([["`\\]]\)/\\\1/g'
932
933# Sed substitution to delay expansion of an escaped shell variable in a
934# double_quote_subst'ed string.
935delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
936
937# Sed substitution to delay expansion of an escaped single quote.
938delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
939
940# Sed substitution to avoid accidental globbing in evaled expressions
941no_glob_subst='s/\*/\\\*/g'
942])
943
944# _LT_PROG_LTMAIN
945# ---------------
946# Note that this code is called both from `configure', and `config.status'
947# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
948# `config.status' has no value for ac_aux_dir unless we are using Automake,
949# so we pass a copy along to make sure it has a sensible value anyway.
950m4_defun([_LT_PROG_LTMAIN],
951[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
952_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
953ltmain="$ac_aux_dir/ltmain.sh"
954])# _LT_PROG_LTMAIN
955
956
957
958# So that we can recreate a full libtool script including additional
959# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
960# in macros and then make a single call at the end using the `libtool'
961# label.
962
963
964# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
965# ----------------------------------------
966# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
967m4_define([_LT_CONFIG_LIBTOOL_INIT],
968[m4_ifval([$1],
969 [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
970 [$1
971])])])
972
973# Initialize.
974m4_define([_LT_OUTPUT_LIBTOOL_INIT])
975
976
977# _LT_CONFIG_LIBTOOL([COMMANDS])
978# ------------------------------
979# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
980m4_define([_LT_CONFIG_LIBTOOL],
981[m4_ifval([$1],
982 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
983 [$1
984])])])
985
986# Initialize.
987m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
988
989
990# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
991# -----------------------------------------------------
992m4_defun([_LT_CONFIG_SAVE_COMMANDS],
993[_LT_CONFIG_LIBTOOL([$1])
994_LT_CONFIG_LIBTOOL_INIT([$2])
995])
996
997
998# _LT_FORMAT_COMMENT([COMMENT])
999# -----------------------------
1000# Add leading comment marks to the start of each line, and a trailing
1001# full-stop to the whole comment if one is not present already.
1002m4_define([_LT_FORMAT_COMMENT],
1003[m4_ifval([$1], [
1004m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
1005 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
1006)])
1007
1008
1009
1010
1011
1012# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
1013# -------------------------------------------------------------------
1014# CONFIGNAME is the name given to the value in the libtool script.
1015# VARNAME is the (base) name used in the configure script.
1016# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
1017# VARNAME. Any other value will be used directly.
1018m4_define([_LT_DECL],
1019[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
1020 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
1021 [m4_ifval([$1], [$1], [$2])])
1022 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
1023 m4_ifval([$4],
1024 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
1025 lt_dict_add_subkey([lt_decl_dict], [$2],
1026 [tagged?], [m4_ifval([$5], [yes], [no])])])
1027])
1028
1029
1030# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
1031# --------------------------------------------------------
1032m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
1033
1034
1035# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
1036# ------------------------------------------------
1037m4_define([lt_decl_tag_varnames],
1038[_lt_decl_filter([tagged?], [yes], $@)])
1039
1040
1041# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
1042# ---------------------------------------------------------
1043m4_define([_lt_decl_filter],
1044[m4_case([$#],
1045 [0], [m4_fatal([$0: too few arguments: $#])],
1046 [1], [m4_fatal([$0: too few arguments: $#: $1])],
1047 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
1048 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
1049 [lt_dict_filter([lt_decl_dict], $@)])[]dnl
1050])
1051
1052
1053# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
1054# --------------------------------------------------
1055m4_define([lt_decl_quote_varnames],
1056[_lt_decl_filter([value], [1], $@)])
1057
1058
1059# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
1060# ---------------------------------------------------
1061m4_define([lt_decl_dquote_varnames],
1062[_lt_decl_filter([value], [2], $@)])
1063
1064
1065# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
1066# ---------------------------------------------------
1067m4_define([lt_decl_varnames_tagged],
1068[m4_assert([$# <= 2])dnl
1069_$0(m4_quote(m4_default([$1], [[, ]])),
1070 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
1071 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
1072m4_define([_lt_decl_varnames_tagged],
1073[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
1074
1075
1076# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
1077# ------------------------------------------------
1078m4_define([lt_decl_all_varnames],
1079[_$0(m4_quote(m4_default([$1], [[, ]])),
1080 m4_if([$2], [],
1081 m4_quote(lt_decl_varnames),
1082 m4_quote(m4_shift($@))))[]dnl
1083])
1084m4_define([_lt_decl_all_varnames],
1085[lt_join($@, lt_decl_varnames_tagged([$1],
1086 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
1087])
1088
1089
1090# _LT_CONFIG_STATUS_DECLARE([VARNAME])
1091# ------------------------------------
1092# Quote a variable value, and forward it to `config.status' so that its
1093# declaration there will have the same value as in `configure'. VARNAME
1094# must have a single quote delimited value for this to work.
1095m4_define([_LT_CONFIG_STATUS_DECLARE],
1096[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
1097
1098
1099# _LT_CONFIG_STATUS_DECLARATIONS
1100# ------------------------------
1101# We delimit libtool config variables with single quotes, so when
1102# we write them to config.status, we have to be sure to quote all
1103# embedded single quotes properly. In configure, this macro expands
1104# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
1105#
1106# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
1107m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
1108[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
1109 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
1110
1111
1112# _LT_LIBTOOL_TAGS
1113# ----------------
1114# Output comment and list of tags supported by the script
1115m4_defun([_LT_LIBTOOL_TAGS],
1116[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
1117available_tags="_LT_TAGS"dnl
1118])
1119
1120
1121# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
1122# -----------------------------------
1123# Extract the dictionary values for VARNAME (optionally with TAG) and
1124# expand to a commented shell variable setting:
1125#
1126# # Some comment about what VAR is for.
1127# visible_name=$lt_internal_name
1128m4_define([_LT_LIBTOOL_DECLARE],
1129[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
1130 [description])))[]dnl
1131m4_pushdef([_libtool_name],
1132 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
1133m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
1134 [0], [_libtool_name=[$]$1],
1135 [1], [_libtool_name=$lt_[]$1],
1136 [2], [_libtool_name=$lt_[]$1],
1137 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
1138m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
1139])
1140
1141
1142# _LT_LIBTOOL_CONFIG_VARS
1143# -----------------------
1144# Produce commented declarations of non-tagged libtool config variables
1145# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
1146# script. Tagged libtool config variables (even for the LIBTOOL CONFIG
1147# section) are produced by _LT_LIBTOOL_TAG_VARS.
1148m4_defun([_LT_LIBTOOL_CONFIG_VARS],
1149[m4_foreach([_lt_var],
1150 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
1151 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
1152
1153
1154# _LT_LIBTOOL_TAG_VARS(TAG)
1155# -------------------------
1156m4_define([_LT_LIBTOOL_TAG_VARS],
1157[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
1158 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
1159
1160
1161# _LT_TAGVAR(VARNAME, [TAGNAME])
1162# ------------------------------
1163m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
1164
1165
1166# _LT_CONFIG_COMMANDS
1167# -------------------
1168# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
1169# variables for single and double quote escaping we saved from calls
1170# to _LT_DECL, we can put quote escaped variables declarations
1171# into `config.status', and then the shell code to quote escape them in
1172# for loops in `config.status'. Finally, any additional code accumulated
1173# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
1174m4_defun([_LT_CONFIG_COMMANDS],
1175[AC_PROVIDE_IFELSE([LT_OUTPUT],
1176 dnl If the libtool generation code has been placed in $CONFIG_LT,
1177 dnl instead of duplicating it all over again into config.status,
1178 dnl then we will have config.status run $CONFIG_LT later, so it
1179 dnl needs to know what name is stored there:
1180 [AC_CONFIG_COMMANDS([libtool],
1181 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
1182 dnl If the libtool generation code is destined for config.status,
1183 dnl expand the accumulated commands and init code now:
1184 [AC_CONFIG_COMMANDS([libtool],
1185 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
1186])#_LT_CONFIG_COMMANDS
1187
1188
1189# Initialize.
1190m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
1191[
1192
1193# The HP-UX ksh and POSIX shell print the target directory to stdout
1194# if CDPATH is set.
1195(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1196
1197sed_quote_subst='$sed_quote_subst'
1198double_quote_subst='$double_quote_subst'
1199delay_variable_subst='$delay_variable_subst'
1200_LT_CONFIG_STATUS_DECLARATIONS
1201LTCC='$LTCC'
1202LTCFLAGS='$LTCFLAGS'
1203compiler='$compiler_DEFAULT'
1204
1205# A function that is used when there is no print builtin or printf.
1206func_fallback_echo ()
1207{
1208 eval 'cat <<_LTECHO_EOF
1209\$[]1
1210_LTECHO_EOF'
1211}
1212
1213# Quote evaled strings.
1214for var in lt_decl_all_varnames([[ \
1215]], lt_decl_quote_varnames); do
1216 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1217 *[[\\\\\\\`\\"\\\$]]*)
1218 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
1219 ;;
1220 *)
1221 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1222 ;;
1223 esac
1224done
1225
1226# Double-quote double-evaled strings.
1227for var in lt_decl_all_varnames([[ \
1228]], lt_decl_dquote_varnames); do
1229 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
1230 *[[\\\\\\\`\\"\\\$]]*)
1231 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
1232 ;;
1233 *)
1234 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
1235 ;;
1236 esac
1237done
1238
1239_LT_OUTPUT_LIBTOOL_INIT
1240])
1241
1242# _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
1243# ------------------------------------
1244# Generate a child script FILE with all initialization necessary to
1245# reuse the environment learned by the parent script, and make the
1246# file executable. If COMMENT is supplied, it is inserted after the
1247# `#!' sequence but before initialization text begins. After this
1248# macro, additional text can be appended to FILE to form the body of
1249# the child script. The macro ends with non-zero status if the
1250# file could not be fully written (such as if the disk is full).
1251m4_ifdef([AS_INIT_GENERATED],
1252[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
1253[m4_defun([_LT_GENERATED_FILE_INIT],
1254[m4_require([AS_PREPARE])]dnl
1255[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
1256[lt_write_fail=0
1257cat >$1 <<_ASEOF || lt_write_fail=1
1258#! $SHELL
1259# Generated by $as_me.
1260$2
1261SHELL=\${CONFIG_SHELL-$SHELL}
1262export SHELL
1263_ASEOF
1264cat >>$1 <<\_ASEOF || lt_write_fail=1
1265AS_SHELL_SANITIZE
1266_AS_PREPARE
1267exec AS_MESSAGE_FD>&1
1268_ASEOF
1269test $lt_write_fail = 0 && chmod +x $1[]dnl
1270m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
1271
1272# LT_OUTPUT
1273# ---------
1274# This macro allows early generation of the libtool script (before
1275# AC_OUTPUT is called), incase it is used in configure for compilation
1276# tests.
1277AC_DEFUN([LT_OUTPUT],
1278[: ${CONFIG_LT=./config.lt}
1279AC_MSG_NOTICE([creating $CONFIG_LT])
1280_LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
1281[# Run this file to recreate a libtool stub with the current configuration.])
1282
1283cat >>"$CONFIG_LT" <<\_LTEOF
1284lt_cl_silent=false
1285exec AS_MESSAGE_LOG_FD>>config.log
1286{
1287 echo
1288 AS_BOX([Running $as_me.])
1289} >&AS_MESSAGE_LOG_FD
1290
1291lt_cl_help="\
1292\`$as_me' creates a local libtool stub from the current configuration,
1293for use in further configure time tests before the real libtool is
1294generated.
1295
1296Usage: $[0] [[OPTIONS]]
1297
1298 -h, --help print this help, then exit
1299 -V, --version print version number, then exit
1300 -q, --quiet do not print progress messages
1301 -d, --debug don't remove temporary files
1302
1303Report bugs to <bug-libtool@gnu.org>."
1304
1305lt_cl_version="\
1306m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
1307m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
1308configured by $[0], generated by m4_PACKAGE_STRING.
1309
1310Copyright (C) 2011 Free Software Foundation, Inc.
1311This config.lt script is free software; the Free Software Foundation
1312gives unlimited permision to copy, distribute and modify it."
1313
1314while test $[#] != 0
1315do
1316 case $[1] in
1317 --version | --v* | -V )
1318 echo "$lt_cl_version"; exit 0 ;;
1319 --help | --h* | -h )
1320 echo "$lt_cl_help"; exit 0 ;;
1321 --debug | --d* | -d )
1322 debug=: ;;
1323 --quiet | --q* | --silent | --s* | -q )
1324 lt_cl_silent=: ;;
1325
1326 -*) AC_MSG_ERROR([unrecognized option: $[1]
1327Try \`$[0] --help' for more information.]) ;;
1328
1329 *) AC_MSG_ERROR([unrecognized argument: $[1]
1330Try \`$[0] --help' for more information.]) ;;
1331 esac
1332 shift
1333done
1334
1335if $lt_cl_silent; then
1336 exec AS_MESSAGE_FD>/dev/null
1337fi
1338_LTEOF
1339
1340cat >>"$CONFIG_LT" <<_LTEOF
1341_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
1342_LTEOF
1343
1344cat >>"$CONFIG_LT" <<\_LTEOF
1345AC_MSG_NOTICE([creating $ofile])
1346_LT_OUTPUT_LIBTOOL_COMMANDS
1347AS_EXIT(0)
1348_LTEOF
1349chmod +x "$CONFIG_LT"
1350
1351# configure is writing to config.log, but config.lt does its own redirection,
1352# appending to config.log, which fails on DOS, as config.log is still kept
1353# open by configure. Here we exec the FD to /dev/null, effectively closing
1354# config.log, so it can be properly (re)opened and appended to by config.lt.
1355lt_cl_success=:
1356test "$silent" = yes &&
1357 lt_config_lt_args="$lt_config_lt_args --quiet"
1358exec AS_MESSAGE_LOG_FD>/dev/null
1359$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
1360exec AS_MESSAGE_LOG_FD>>config.log
1361$lt_cl_success || AS_EXIT(1)
1362])# LT_OUTPUT
1363
1364
1365# _LT_CONFIG(TAG)
1366# ---------------
1367# If TAG is the built-in tag, create an initial libtool script with a
1368# default configuration from the untagged config vars. Otherwise add code
1369# to config.status for appending the configuration named by TAG from the
1370# matching tagged config vars.
1371m4_defun([_LT_CONFIG],
1372[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
1373_LT_CONFIG_SAVE_COMMANDS([
1374 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
1375 m4_if(_LT_TAG, [C], [
1376 # See if we are running on zsh, and set the options which allow our
1377 # commands through without removal of \ escapes.
1378 if test -n "${ZSH_VERSION+set}" ; then
1379 setopt NO_GLOB_SUBST
1380 fi
1381
1382 cfgfile="${ofile}T"
1383 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
1384 $RM "$cfgfile"
1385
1386 cat <<_LT_EOF >> "$cfgfile"
1387#! $SHELL
1388
1389# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
1390# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
1391# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1392# NOTE: Changes made to this file will be lost: look at ltmain.sh.
1393#
1394_LT_COPYING
1395_LT_LIBTOOL_TAGS
1396
1397# ### BEGIN LIBTOOL CONFIG
1398_LT_LIBTOOL_CONFIG_VARS
1399_LT_LIBTOOL_TAG_VARS
1400# ### END LIBTOOL CONFIG
1401
1402_LT_EOF
1403
1404 case $host_os in
1405 aix3*)
1406 cat <<\_LT_EOF >> "$cfgfile"
1407# AIX sometimes has problems with the GCC collect2 program. For some
1408# reason, if we set the COLLECT_NAMES environment variable, the problems
1409# vanish in a puff of smoke.
1410if test "X${COLLECT_NAMES+set}" != Xset; then
1411 COLLECT_NAMES=
1412 export COLLECT_NAMES
1413fi
1414_LT_EOF
1415 ;;
1416 esac
1417
1418 _LT_PROG_LTMAIN
1419
1420 # We use sed instead of cat because bash on DJGPP gets confused if
1421 # if finds mixed CR/LF and LF-only lines. Since sed operates in
1422 # text mode, it properly converts lines to CR/LF. This bash problem
1423 # is reportedly fixed, but why not run on old versions too?
1424 sed '$q' "$ltmain" >> "$cfgfile" \
1425 || (rm -f "$cfgfile"; exit 1)
1426
1427 _LT_PROG_REPLACE_SHELLFNS
1428
1429 mv -f "$cfgfile" "$ofile" ||
1430 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
1431 chmod +x "$ofile"
1432],
1433[cat <<_LT_EOF >> "$ofile"
1434
1435dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
1436dnl in a comment (ie after a #).
1437# ### BEGIN LIBTOOL TAG CONFIG: $1
1438_LT_LIBTOOL_TAG_VARS(_LT_TAG)
1439# ### END LIBTOOL TAG CONFIG: $1
1440_LT_EOF
1441])dnl /m4_if
1442],
1443[m4_if([$1], [], [
1444 PACKAGE='$PACKAGE'
1445 VERSION='$VERSION'
1446 TIMESTAMP='$TIMESTAMP'
1447 RM='$RM'
1448 ofile='$ofile'], [])
1449])dnl /_LT_CONFIG_SAVE_COMMANDS
1450])# _LT_CONFIG
1451
1452
1453# LT_SUPPORTED_TAG(TAG)
1454# ---------------------
1455# Trace this macro to discover what tags are supported by the libtool
1456# --tag option, using:
1457# autoconf --trace 'LT_SUPPORTED_TAG:$1'
1458AC_DEFUN([LT_SUPPORTED_TAG], [])
1459
1460
1461# C support is built-in for now
1462m4_define([_LT_LANG_C_enabled], [])
1463m4_define([_LT_TAGS], [])
1464
1465
1466# LT_LANG(LANG)
1467# -------------
1468# Enable libtool support for the given language if not already enabled.
1469AC_DEFUN([LT_LANG],
1470[AC_BEFORE([$0], [LT_OUTPUT])dnl
1471m4_case([$1],
1472 [C], [_LT_LANG(C)],
1473 [C++], [_LT_LANG(CXX)],
1474 [Go], [_LT_LANG(GO)],
1475 [Java], [_LT_LANG(GCJ)],
1476 [Fortran 77], [_LT_LANG(F77)],
1477 [Fortran], [_LT_LANG(FC)],
1478 [Windows Resource], [_LT_LANG(RC)],
1479 [m4_ifdef([_LT_LANG_]$1[_CONFIG],
1480 [_LT_LANG($1)],
1481 [m4_fatal([$0: unsupported language: "$1"])])])dnl
1482])# LT_LANG
1483
1484
1485# _LT_LANG(LANGNAME)
1486# ------------------
1487m4_defun([_LT_LANG],
1488[m4_ifdef([_LT_LANG_]$1[_enabled], [],
1489 [LT_SUPPORTED_TAG([$1])dnl
1490 m4_append([_LT_TAGS], [$1 ])dnl
1491 m4_define([_LT_LANG_]$1[_enabled], [])dnl
1492 _LT_LANG_$1_CONFIG($1)])dnl
1493])# _LT_LANG
1494
1495
1496m4_ifndef([AC_PROG_GO], [
1497# NOTE: This macro has been submitted for inclusion into #
1498# GNU Autoconf as AC_PROG_GO. When it is available in #
1499# a released version of Autoconf we should remove this #
1500# macro and use it instead. #
1501m4_defun([AC_PROG_GO],
1502[AC_LANG_PUSH(Go)dnl
1503AC_ARG_VAR([GOC], [Go compiler command])dnl
1504AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
1505_AC_ARG_VAR_LDFLAGS()dnl
1506AC_CHECK_TOOL(GOC, gccgo)
1507if test -z "$GOC"; then
1508 if test -n "$ac_tool_prefix"; then
1509 AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
1510 fi
1511fi
1512if test -z "$GOC"; then
1513 AC_CHECK_PROG(GOC, gccgo, gccgo, false)
1514fi
1515])#m4_defun
1516])#m4_ifndef
1517
1518
1519# _LT_LANG_DEFAULT_CONFIG
1520# -----------------------
1521m4_defun([_LT_LANG_DEFAULT_CONFIG],
1522[AC_PROVIDE_IFELSE([AC_PROG_CXX],
1523 [LT_LANG(CXX)],
1524 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
1525
1526AC_PROVIDE_IFELSE([AC_PROG_F77],
1527 [LT_LANG(F77)],
1528 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
1529
1530AC_PROVIDE_IFELSE([AC_PROG_FC],
1531 [LT_LANG(FC)],
1532 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
1533
1534dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
1535dnl pulling things in needlessly.
1536AC_PROVIDE_IFELSE([AC_PROG_GCJ],
1537 [LT_LANG(GCJ)],
1538 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
1539 [LT_LANG(GCJ)],
1540 [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
1541 [LT_LANG(GCJ)],
1542 [m4_ifdef([AC_PROG_GCJ],
1543 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
1544 m4_ifdef([A][M_PROG_GCJ],
1545 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
1546 m4_ifdef([LT_PROG_GCJ],
1547 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
1548
1549AC_PROVIDE_IFELSE([AC_PROG_GO],
1550 [LT_LANG(GO)],
1551 [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
1552
1553AC_PROVIDE_IFELSE([LT_PROG_RC],
1554 [LT_LANG(RC)],
1555 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
1556])# _LT_LANG_DEFAULT_CONFIG
1557
1558# Obsolete macros:
1559AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
1560AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
1561AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
1562AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
1563AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
1564dnl aclocal-1.4 backwards compatibility:
1565dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
1566dnl AC_DEFUN([AC_LIBTOOL_F77], [])
1567dnl AC_DEFUN([AC_LIBTOOL_FC], [])
1568dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
1569dnl AC_DEFUN([AC_LIBTOOL_RC], [])
1570
1571
1572# _LT_TAG_COMPILER
1573# ----------------
1574m4_defun([_LT_TAG_COMPILER],
1575[AC_REQUIRE([AC_PROG_CC])dnl
1576
1577_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
1578_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
1579_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
1580_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
1581
1582# If no C compiler was specified, use CC.
1583LTCC=${LTCC-"$CC"}
1584
1585# If no C compiler flags were specified, use CFLAGS.
1586LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1587
1588# Allow CC to be a program name with arguments.
1589compiler=$CC
1590])# _LT_TAG_COMPILER
1591
1592
1593# _LT_COMPILER_BOILERPLATE
1594# ------------------------
1595# Check for compiler boilerplate output or warnings with
1596# the simple compiler test code.
1597m4_defun([_LT_COMPILER_BOILERPLATE],
1598[m4_require([_LT_DECL_SED])dnl
1599ac_outfile=conftest.$ac_objext
1600echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1601eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1602_lt_compiler_boilerplate=`cat conftest.err`
1603$RM conftest*
1604])# _LT_COMPILER_BOILERPLATE
1605
1606
1607# _LT_LINKER_BOILERPLATE
1608# ----------------------
1609# Check for linker boilerplate output or warnings with
1610# the simple link test code.
1611m4_defun([_LT_LINKER_BOILERPLATE],
1612[m4_require([_LT_DECL_SED])dnl
1613ac_outfile=conftest.$ac_objext
1614echo "$lt_simple_link_test_code" >conftest.$ac_ext
1615eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1616_lt_linker_boilerplate=`cat conftest.err`
1617$RM -r conftest*
1618])# _LT_LINKER_BOILERPLATE
1619
1620# _LT_REQUIRED_DARWIN_CHECKS
1621# -------------------------
1622m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
1623 case $host_os in
1624 rhapsody* | darwin*)
1625 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1626 AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1627 AC_CHECK_TOOL([LIPO], [lipo], [:])
1628 AC_CHECK_TOOL([OTOOL], [otool], [:])
1629 AC_CHECK_TOOL([OTOOL64], [otool64], [:])
1630 _LT_DECL([], [DSYMUTIL], [1],
1631 [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
1632 _LT_DECL([], [NMEDIT], [1],
1633 [Tool to change global to local symbols on Mac OS X])
1634 _LT_DECL([], [LIPO], [1],
1635 [Tool to manipulate fat objects and archives on Mac OS X])
1636 _LT_DECL([], [OTOOL], [1],
1637 [ldd/readelf like tool for Mach-O binaries on Mac OS X])
1638 _LT_DECL([], [OTOOL64], [1],
1639 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
1640
1641 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1642 [lt_cv_apple_cc_single_mod=no
1643 if test -z "${LT_MULTI_MODULE}"; then
1644 # By default we will add the -single_module flag. You can override
1645 # by either setting the environment variable LT_MULTI_MODULE
1646 # non-empty at configure time, or by adding -multi_module to the
1647 # link flags.
1648 rm -rf libconftest.dylib*
1649 echo "int foo(void){return 1;}" > conftest.c
1650 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1651-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
1652 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1653 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
1654 _lt_result=$?
1655 # If there is a non-empty error log, and "single_module"
1656 # appears in it, assume the flag caused a linker warning
1657 if test -s conftest.err && $GREP single_module conftest.err; then
1658 cat conftest.err >&AS_MESSAGE_LOG_FD
1659 # Otherwise, if the output was created with a 0 exit code from
1660 # the compiler, it worked.
1661 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
1662 lt_cv_apple_cc_single_mod=yes
1663 else
1664 cat conftest.err >&AS_MESSAGE_LOG_FD
1665 fi
1666 rm -rf libconftest.dylib*
1667 rm -f conftest.*
1668 fi])
1669
1670 AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1671 [lt_cv_ld_exported_symbols_list],
1672 [lt_cv_ld_exported_symbols_list=no
1673 save_LDFLAGS=$LDFLAGS
1674 echo "_main" > conftest.sym
1675 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1676 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1677 [lt_cv_ld_exported_symbols_list=yes],
1678 [lt_cv_ld_exported_symbols_list=no])
1679 LDFLAGS="$save_LDFLAGS"
1680 ])
1681
1682 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
1683 [lt_cv_ld_force_load=no
1684 cat > conftest.c << _LT_EOF
1685int forced_loaded() { return 2;}
1686_LT_EOF
1687 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1688 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1689 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1690 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1691 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1692 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1693 cat > conftest.c << _LT_EOF
1694int main() { return 0;}
1695_LT_EOF
1696 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
1697 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
1698 _lt_result=$?
1699 if test -s conftest.err && $GREP force_load conftest.err; then
1700 cat conftest.err >&AS_MESSAGE_LOG_FD
1701 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
1702 lt_cv_ld_force_load=yes
1703 else
1704 cat conftest.err >&AS_MESSAGE_LOG_FD
1705 fi
1706 rm -f conftest.err libconftest.a conftest conftest.c
1707 rm -rf conftest.dSYM
1708 ])
1709 case $host_os in
1710 rhapsody* | darwin1.[[012]])
1711 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1712 darwin1.*)
1713 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1714 darwin*) # darwin 5.x on
1715 # if running on 10.5 or later, the deployment target defaults
1716 # to the OS version, if on x86, and 10.4, the deployment
1717 # target defaults to 10.4. Don't you love it?
1718 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1719 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1720 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1721 10.[[012]]*)
1722 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1723 10.*)
1724 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1725 esac
1726 ;;
1727 esac
1728 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1729 _lt_dar_single_mod='$single_module'
1730 fi
1731 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1732 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1733 else
1734 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1735 fi
1736 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
1737 _lt_dsymutil='~$DSYMUTIL $lib || :'
1738 else
1739 _lt_dsymutil=
1740 fi
1741 ;;
1742 esac
1743])
1744
1745
1746# _LT_DARWIN_LINKER_FEATURES([TAG])
1747# ---------------------------------
1748# Checks for linker and compiler features on darwin
1749m4_defun([_LT_DARWIN_LINKER_FEATURES],
1750[
1751 m4_require([_LT_REQUIRED_DARWIN_CHECKS])
1752 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
1753 _LT_TAGVAR(hardcode_direct, $1)=no
1754 _LT_TAGVAR(hardcode_automatic, $1)=yes
1755 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1756 if test "$lt_cv_ld_force_load" = "yes"; then
1757 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1758 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
1759 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
1760 else
1761 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
1762 fi
1763 _LT_TAGVAR(link_all_deplibs, $1)=yes
1764 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1765 case $cc_basename in
1766 ifort*) _lt_dar_can_shared=yes ;;
1767 *) _lt_dar_can_shared=$GCC ;;
1768 esac
1769 if test "$_lt_dar_can_shared" = "yes"; then
1770 output_verbose_link_cmd=func_echo_all
1771 _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}"
1772 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1773 _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}"
1774 _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}"
1775 m4_if([$1], [CXX],
1776[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1777 _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}"
1778 _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}"
1779 fi
1780],[])
1781 else
1782 _LT_TAGVAR(ld_shlibs, $1)=no
1783 fi
1784])
1785
1786# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
1787# ----------------------------------
1788# Links a minimal program and checks the executable
1789# for the system default hardcoded library path. In most cases,
1790# this is /usr/lib:/lib, but when the MPI compilers are used
1791# the location of the communication and MPI libs are included too.
1792# If we don't find anything, use the default library path according
1793# to the aix ld manual.
1794# Store the results from the different compilers for each TAGNAME.
1795# Allow to override them for all tags through lt_cv_aix_libpath.
1796m4_defun([_LT_SYS_MODULE_PATH_AIX],
1797[m4_require([_LT_DECL_SED])dnl
1798if test "${lt_cv_aix_libpath+set}" = set; then
1799 aix_libpath=$lt_cv_aix_libpath
1800else
1801 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
1802 [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
1803 lt_aix_libpath_sed='[
1804 /Import File Strings/,/^$/ {
1805 /^0/ {
1806 s/^0 *\([^ ]*\) *$/\1/
1807 p
1808 }
1809 }]'
1810 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1811 # Check for a 64-bit object if we didn't find anything.
1812 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1813 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1814 fi],[])
1815 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1816 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
1817 fi
1818 ])
1819 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
1820fi
1821])# _LT_SYS_MODULE_PATH_AIX
1822
1823
1824# _LT_SHELL_INIT(ARG)
1825# -------------------
1826m4_define([_LT_SHELL_INIT],
1827[m4_divert_text([M4SH-INIT], [$1
1828])])# _LT_SHELL_INIT
1829
1830
1831
1832# _LT_PROG_ECHO_BACKSLASH
1833# -----------------------
1834# Find how we can fake an echo command that does not interpret backslash.
1835# In particular, with Autoconf 2.60 or later we add some code to the start
1836# of the generated configure script which will find a shell with a builtin
1837# printf (which we can use as an echo command).
1838m4_defun([_LT_PROG_ECHO_BACKSLASH],
1839[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1840ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1841ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1842
1843AC_MSG_CHECKING([how to print strings])
1844# Test print first, because it will be a builtin if present.
1845if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
1846 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
1847 ECHO='print -r --'
1848elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
1849 ECHO='printf %s\n'
1850else
1851 # Use this function as a fallback that always works.
1852 func_fallback_echo ()
1853 {
1854 eval 'cat <<_LTECHO_EOF
1855$[]1
1856_LTECHO_EOF'
1857 }
1858 ECHO='func_fallback_echo'
1859fi
1860
1861# func_echo_all arg...
1862# Invoke $ECHO with all args, space-separated.
1863func_echo_all ()
1864{
1865 $ECHO "$*"
1866}
1867
1868case "$ECHO" in
1869 printf*) AC_MSG_RESULT([printf]) ;;
1870 print*) AC_MSG_RESULT([print -r]) ;;
1871 *) AC_MSG_RESULT([cat]) ;;
1872esac
1873
1874m4_ifdef([_AS_DETECT_SUGGESTED],
1875[_AS_DETECT_SUGGESTED([
1876 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
1877 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
1878 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
1879 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
1880 PATH=/empty FPATH=/empty; export PATH FPATH
1881 test "X`printf %s $ECHO`" = "X$ECHO" \
1882 || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
1883
1884_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
1885_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
1886])# _LT_PROG_ECHO_BACKSLASH
1887
1888
1889# _LT_WITH_SYSROOT
1890# ----------------
1891AC_DEFUN([_LT_WITH_SYSROOT],
1892[AC_MSG_CHECKING([for sysroot])
1893AC_ARG_WITH([sysroot],
1894[ --with-sysroot[=DIR] Search for dependent libraries within DIR
1895 (or the compiler's sysroot if not specified).],
1896[], [with_sysroot=no])
1897
1898dnl lt_sysroot will always be passed unquoted. We quote it here
1899dnl in case the user passed a directory name.
1900lt_sysroot=
1901case ${with_sysroot} in #(
1902 yes)
1903 if test "$GCC" = yes; then
1904 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
1905 fi
1906 ;; #(
1907 /*)
1908 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
1909 ;; #(
1910 no|'')
1911 ;; #(
1912 *)
1913 AC_MSG_RESULT([${with_sysroot}])
1914 AC_MSG_ERROR([The sysroot must be an absolute path.])
1915 ;;
1916esac
1917
1918 AC_MSG_RESULT([${lt_sysroot:-no}])
1919_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
1920[dependent libraries, and in which our libraries should be installed.])])
1921
1922# _LT_ENABLE_LOCK
1923# ---------------
1924m4_defun([_LT_ENABLE_LOCK],
1925[AC_ARG_ENABLE([libtool-lock],
1926 [AS_HELP_STRING([--disable-libtool-lock],
1927 [avoid locking (might break parallel builds)])])
1928test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1929
1930# Some flags need to be propagated to the compiler or linker for good
1931# libtool support.
1932case $host in
1933ia64-*-hpux*)
1934 # Find out which ABI we are using.
1935 echo 'int i;' > conftest.$ac_ext
1936 if AC_TRY_EVAL(ac_compile); then
1937 case `/usr/bin/file conftest.$ac_objext` in
1938 *ELF-32*)
1939 HPUX_IA64_MODE="32"
1940 ;;
1941 *ELF-64*)
1942 HPUX_IA64_MODE="64"
1943 ;;
1944 esac
1945 fi
1946 rm -rf conftest*
1947 ;;
1948*-*-irix6*)
1949 # Find out which ABI we are using.
1950 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1951 if AC_TRY_EVAL(ac_compile); then
1952 if test "$lt_cv_prog_gnu_ld" = yes; then
1953 case `/usr/bin/file conftest.$ac_objext` in
1954 *32-bit*)
1955 LD="${LD-ld} -melf32bsmip"
1956 ;;
1957 *N32*)
1958 LD="${LD-ld} -melf32bmipn32"
1959 ;;
1960 *64-bit*)
1961 LD="${LD-ld} -melf64bmip"
1962 ;;
1963 esac
1964 else
1965 case `/usr/bin/file conftest.$ac_objext` in
1966 *32-bit*)
1967 LD="${LD-ld} -32"
1968 ;;
1969 *N32*)
1970 LD="${LD-ld} -n32"
1971 ;;
1972 *64-bit*)
1973 LD="${LD-ld} -64"
1974 ;;
1975 esac
1976 fi
1977 fi
1978 rm -rf conftest*
1979 ;;
1980
1981x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1982s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1983 # Find out which ABI we are using.
1984 echo 'int i;' > conftest.$ac_ext
1985 if AC_TRY_EVAL(ac_compile); then
1986 case `/usr/bin/file conftest.o` in
1987 *32-bit*)
1988 case $host in
1989 x86_64-*kfreebsd*-gnu)
1990 LD="${LD-ld} -m elf_i386_fbsd"
1991 ;;
1992 x86_64-*linux*)
1993 case `/usr/bin/file conftest.o` in
1994 *x86-64*)
1995 LD="${LD-ld} -m elf32_x86_64"
1996 ;;
1997 *)
1998 LD="${LD-ld} -m elf_i386"
1999 ;;
2000 esac
2001 ;;
2002 ppc64-*linux*|powerpc64-*linux*)
2003 LD="${LD-ld} -m elf32ppclinux"
2004 ;;
2005 s390x-*linux*)
2006 LD="${LD-ld} -m elf_s390"
2007 ;;
2008 sparc64-*linux*)
2009 LD="${LD-ld} -m elf32_sparc"
2010 ;;
2011 esac
2012 ;;
2013 *64-bit*)
2014 case $host in
2015 x86_64-*kfreebsd*-gnu)
2016 LD="${LD-ld} -m elf_x86_64_fbsd"
2017 ;;
2018 x86_64-*linux*)
2019 LD="${LD-ld} -m elf_x86_64"
2020 ;;
2021 ppc*-*linux*|powerpc*-*linux*)
2022 LD="${LD-ld} -m elf64ppc"
2023 ;;
2024 s390*-*linux*|s390*-*tpf*)
2025 LD="${LD-ld} -m elf64_s390"
2026 ;;
2027 sparc*-*linux*)
2028 LD="${LD-ld} -m elf64_sparc"
2029 ;;
2030 esac
2031 ;;
2032 esac
2033 fi
2034 rm -rf conftest*
2035 ;;
2036
2037*-*-sco3.2v5*)
2038 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2039 SAVE_CFLAGS="$CFLAGS"
2040 CFLAGS="$CFLAGS -belf"
2041 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
2042 [AC_LANG_PUSH(C)
2043 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
2044 AC_LANG_POP])
2045 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2046 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2047 CFLAGS="$SAVE_CFLAGS"
2048 fi
2049 ;;
2050*-*solaris*)
2051 # Find out which ABI we are using.
2052 echo 'int i;' > conftest.$ac_ext
2053 if AC_TRY_EVAL(ac_compile); then
2054 case `/usr/bin/file conftest.o` in
2055 *64-bit*)
2056 case $lt_cv_prog_gnu_ld in
2057 yes*)
2058 case $host in
2059 i?86-*-solaris*)
2060 LD="${LD-ld} -m elf_x86_64"
2061 ;;
2062 sparc*-*-solaris*)
2063 LD="${LD-ld} -m elf64_sparc"
2064 ;;
2065 esac
2066 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
2067 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
2068 LD="${LD-ld}_sol2"
2069 fi
2070 ;;
2071 *)
2072 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
2073 LD="${LD-ld} -64"
2074 fi
2075 ;;
2076 esac
2077 ;;
2078 esac
2079 fi
2080 rm -rf conftest*
2081 ;;
2082esac
2083
2084need_locks="$enable_libtool_lock"
2085])# _LT_ENABLE_LOCK
2086
2087
2088# _LT_PROG_AR
2089# -----------
2090m4_defun([_LT_PROG_AR],
2091[AC_CHECK_TOOLS(AR, [ar], false)
2092: ${AR=ar}
2093: ${AR_FLAGS=cru}
2094_LT_DECL([], [AR], [1], [The archiver])
2095_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
2096
2097AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
2098 [lt_cv_ar_at_file=no
2099 AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
2100 [echo conftest.$ac_objext > conftest.lst
2101 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
2102 AC_TRY_EVAL([lt_ar_try])
2103 if test "$ac_status" -eq 0; then
2104 # Ensure the archiver fails upon bogus file names.
2105 rm -f conftest.$ac_objext libconftest.a
2106 AC_TRY_EVAL([lt_ar_try])
2107 if test "$ac_status" -ne 0; then
2108 lt_cv_ar_at_file=@
2109 fi
2110 fi
2111 rm -f conftest.* libconftest.a
2112 ])
2113 ])
2114
2115if test "x$lt_cv_ar_at_file" = xno; then
2116 archiver_list_spec=
2117else
2118 archiver_list_spec=$lt_cv_ar_at_file
2119fi
2120_LT_DECL([], [archiver_list_spec], [1],
2121 [How to feed a file listing to the archiver])
2122])# _LT_PROG_AR
2123
2124
2125# _LT_CMD_OLD_ARCHIVE
2126# -------------------
2127m4_defun([_LT_CMD_OLD_ARCHIVE],
2128[_LT_PROG_AR
2129
2130AC_CHECK_TOOL(STRIP, strip, :)
2131test -z "$STRIP" && STRIP=:
2132_LT_DECL([], [STRIP], [1], [A symbol stripping program])
2133
2134AC_CHECK_TOOL(RANLIB, ranlib, :)
2135test -z "$RANLIB" && RANLIB=:
2136_LT_DECL([], [RANLIB], [1],
2137 [Commands used to install an old-style archive])
2138
2139# Determine commands to create old-style static archives.
2140old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
2141old_postinstall_cmds='chmod 644 $oldlib'
2142old_postuninstall_cmds=
2143
2144if test -n "$RANLIB"; then
2145 case $host_os in
2146 openbsd*)
2147 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
2148 ;;
2149 *)
2150 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
2151 ;;
2152 esac
2153 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
2154fi
2155
2156case $host_os in
2157 darwin*)
2158 lock_old_archive_extraction=yes ;;
2159 *)
2160 lock_old_archive_extraction=no ;;
2161esac
2162_LT_DECL([], [old_postinstall_cmds], [2])
2163_LT_DECL([], [old_postuninstall_cmds], [2])
2164_LT_TAGDECL([], [old_archive_cmds], [2],
2165 [Commands used to build an old-style archive])
2166_LT_DECL([], [lock_old_archive_extraction], [0],
2167 [Whether to use a lock for old archive extraction])
2168])# _LT_CMD_OLD_ARCHIVE
2169
2170
2171# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2172# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
2173# ----------------------------------------------------------------
2174# Check whether the given compiler option works
2175AC_DEFUN([_LT_COMPILER_OPTION],
2176[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2177m4_require([_LT_DECL_SED])dnl
2178AC_CACHE_CHECK([$1], [$2],
2179 [$2=no
2180 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
2181 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2182 lt_compiler_flag="$3"
2183 # Insert the option either (1) after the last *FLAGS variable, or
2184 # (2) before a word containing "conftest.", or (3) at the end.
2185 # Note that $ac_compile itself does not contain backslashes and begins
2186 # with a dollar sign (not a hyphen), so the echo should work correctly.
2187 # The option is referenced via a variable to avoid confusing sed.
2188 lt_compile=`echo "$ac_compile" | $SED \
2189 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2190 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2191 -e 's:$: $lt_compiler_flag:'`
2192 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2193 (eval "$lt_compile" 2>conftest.err)
2194 ac_status=$?
2195 cat conftest.err >&AS_MESSAGE_LOG_FD
2196 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2197 if (exit $ac_status) && test -s "$ac_outfile"; then
2198 # The compiler can only warn and ignore the option if not recognized
2199 # So say no if there are warnings other than the usual output.
2200 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
2201 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2202 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
2203 $2=yes
2204 fi
2205 fi
2206 $RM conftest*
2207])
2208
2209if test x"[$]$2" = xyes; then
2210 m4_if([$5], , :, [$5])
2211else
2212 m4_if([$6], , :, [$6])
2213fi
2214])# _LT_COMPILER_OPTION
2215
2216# Old name:
2217AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
2218dnl aclocal-1.4 backwards compatibility:
2219dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
2220
2221
2222# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
2223# [ACTION-SUCCESS], [ACTION-FAILURE])
2224# ----------------------------------------------------
2225# Check whether the given linker option works
2226AC_DEFUN([_LT_LINKER_OPTION],
2227[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2228m4_require([_LT_DECL_SED])dnl
2229AC_CACHE_CHECK([$1], [$2],
2230 [$2=no
2231 save_LDFLAGS="$LDFLAGS"
2232 LDFLAGS="$LDFLAGS $3"
2233 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2234 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2235 # The linker can only warn and ignore the option if not recognized
2236 # So say no if there are warnings
2237 if test -s conftest.err; then
2238 # Append any errors to the config.log.
2239 cat conftest.err 1>&AS_MESSAGE_LOG_FD
2240 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
2241 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
2242 if diff conftest.exp conftest.er2 >/dev/null; then
2243 $2=yes
2244 fi
2245 else
2246 $2=yes
2247 fi
2248 fi
2249 $RM -r conftest*
2250 LDFLAGS="$save_LDFLAGS"
2251])
2252
2253if test x"[$]$2" = xyes; then
2254 m4_if([$4], , :, [$4])
2255else
2256 m4_if([$5], , :, [$5])
2257fi
2258])# _LT_LINKER_OPTION
2259
2260# Old name:
2261AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
2262dnl aclocal-1.4 backwards compatibility:
2263dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
2264
2265
2266# LT_CMD_MAX_LEN
2267#---------------
2268AC_DEFUN([LT_CMD_MAX_LEN],
2269[AC_REQUIRE([AC_CANONICAL_HOST])dnl
2270# find the maximum length of command line arguments
2271AC_MSG_CHECKING([the maximum length of command line arguments])
2272AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
2273 i=0
2274 teststring="ABCD"
2275
2276 case $build_os in
2277 msdosdjgpp*)
2278 # On DJGPP, this test can blow up pretty badly due to problems in libc
2279 # (any single argument exceeding 2000 bytes causes a buffer overrun
2280 # during glob expansion). Even if it were fixed, the result of this
2281 # check would be larger than it should be.
2282 lt_cv_sys_max_cmd_len=12288; # 12K is about right
2283 ;;
2284
2285 gnu*)
2286 # Under GNU Hurd, this test is not required because there is
2287 # no limit to the length of command line arguments.
2288 # Libtool will interpret -1 as no limit whatsoever
2289 lt_cv_sys_max_cmd_len=-1;
2290 ;;
2291
2292 cygwin* | mingw* | cegcc*)
2293 # On Win9x/ME, this test blows up -- it succeeds, but takes
2294 # about 5 minutes as the teststring grows exponentially.
2295 # Worse, since 9x/ME are not pre-emptively multitasking,
2296 # you end up with a "frozen" computer, even though with patience
2297 # the test eventually succeeds (with a max line length of 256k).
2298 # Instead, let's just punt: use the minimum linelength reported by
2299 # all of the supported platforms: 8192 (on NT/2K/XP).
2300 lt_cv_sys_max_cmd_len=8192;
2301 ;;
2302
2303 mint*)
2304 # On MiNT this can take a long time and run out of memory.
2305 lt_cv_sys_max_cmd_len=8192;
2306 ;;
2307
2308 amigaos*)
2309 # On AmigaOS with pdksh, this test takes hours, literally.
2310 # So we just punt and use a minimum line length of 8192.
2311 lt_cv_sys_max_cmd_len=8192;
2312 ;;
2313
2314 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
2315 # This has been around since 386BSD, at least. Likely further.
2316 if test -x /sbin/sysctl; then
2317 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
2318 elif test -x /usr/sbin/sysctl; then
2319 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
2320 else
2321 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
2322 fi
2323 # And add a safety zone
2324 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2325 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2326 ;;
2327
2328 interix*)
2329 # We know the value 262144 and hardcode it with a safety zone (like BSD)
2330 lt_cv_sys_max_cmd_len=196608
2331 ;;
2332
2333 os2*)
2334 # The test takes a long time on OS/2.
2335 lt_cv_sys_max_cmd_len=8192
2336 ;;
2337
2338 osf*)
2339 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
2340 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
2341 # nice to cause kernel panics so lets avoid the loop below.
2342 # First set a reasonable default.
2343 lt_cv_sys_max_cmd_len=16384
2344 #
2345 if test -x /sbin/sysconfig; then
2346 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
2347 *1*) lt_cv_sys_max_cmd_len=-1 ;;
2348 esac
2349 fi
2350 ;;
2351 sco3.2v5*)
2352 lt_cv_sys_max_cmd_len=102400
2353 ;;
2354 sysv5* | sco5v6* | sysv4.2uw2*)
2355 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
2356 if test -n "$kargmax"; then
2357 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
2358 else
2359 lt_cv_sys_max_cmd_len=32768
2360 fi
2361 ;;
2362 *)
2363 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
2364 if test -n "$lt_cv_sys_max_cmd_len" && \
2365 test undefined != "$lt_cv_sys_max_cmd_len"; then
2366 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
2367 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
2368 else
2369 # Make teststring a little bigger before we do anything with it.
2370 # a 1K string should be a reasonable start.
2371 for i in 1 2 3 4 5 6 7 8 ; do
2372 teststring=$teststring$teststring
2373 done
2374 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
2375 # If test is not a shell built-in, we'll probably end up computing a
2376 # maximum length that is only half of the actual maximum length, but
2377 # we can't tell.
2378 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
2379 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
2380 test $i != 17 # 1/2 MB should be enough
2381 do
2382 i=`expr $i + 1`
2383 teststring=$teststring$teststring
2384 done
2385 # Only check the string length outside the loop.
2386 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
2387 teststring=
2388 # Add a significant safety factor because C++ compilers can tack on
2389 # massive amounts of additional arguments before passing them to the
2390 # linker. It appears as though 1/2 is a usable value.
2391 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
2392 fi
2393 ;;
2394 esac
2395])
2396if test -n $lt_cv_sys_max_cmd_len ; then
2397 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
2398else
2399 AC_MSG_RESULT(none)
2400fi
2401max_cmd_len=$lt_cv_sys_max_cmd_len
2402_LT_DECL([], [max_cmd_len], [0],
2403 [What is the maximum length of a command?])
2404])# LT_CMD_MAX_LEN
2405
2406# Old name:
2407AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
2408dnl aclocal-1.4 backwards compatibility:
2409dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
2410
2411
2412# _LT_HEADER_DLFCN
2413# ----------------
2414m4_defun([_LT_HEADER_DLFCN],
2415[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
2416])# _LT_HEADER_DLFCN
2417
2418
2419# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
2420# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
2421# ----------------------------------------------------------------
2422m4_defun([_LT_TRY_DLOPEN_SELF],
2423[m4_require([_LT_HEADER_DLFCN])dnl
2424if test "$cross_compiling" = yes; then :
2425 [$4]
2426else
2427 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
2428 lt_status=$lt_dlunknown
2429 cat > conftest.$ac_ext <<_LT_EOF
2430[#line $LINENO "configure"
2431#include "confdefs.h"
2432
2433#if HAVE_DLFCN_H
2434#include <dlfcn.h>
2435#endif
2436
2437#include <stdio.h>
2438
2439#ifdef RTLD_GLOBAL
2440# define LT_DLGLOBAL RTLD_GLOBAL
2441#else
2442# ifdef DL_GLOBAL
2443# define LT_DLGLOBAL DL_GLOBAL
2444# else
2445# define LT_DLGLOBAL 0
2446# endif
2447#endif
2448
2449/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
2450 find out it does not work in some platform. */
2451#ifndef LT_DLLAZY_OR_NOW
2452# ifdef RTLD_LAZY
2453# define LT_DLLAZY_OR_NOW RTLD_LAZY
2454# else
2455# ifdef DL_LAZY
2456# define LT_DLLAZY_OR_NOW DL_LAZY
2457# else
2458# ifdef RTLD_NOW
2459# define LT_DLLAZY_OR_NOW RTLD_NOW
2460# else
2461# ifdef DL_NOW
2462# define LT_DLLAZY_OR_NOW DL_NOW
2463# else
2464# define LT_DLLAZY_OR_NOW 0
2465# endif
2466# endif
2467# endif
2468# endif
2469#endif
2470
2471/* When -fvisbility=hidden is used, assume the code has been annotated
2472 correspondingly for the symbols needed. */
2473#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
2474int fnord () __attribute__((visibility("default")));
2475#endif
2476
2477int fnord () { return 42; }
2478int main ()
2479{
2480 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
2481 int status = $lt_dlunknown;
2482
2483 if (self)
2484 {
2485 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
2486 else
2487 {
2488 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
2489 else puts (dlerror ());
2490 }
2491 /* dlclose (self); */
2492 }
2493 else
2494 puts (dlerror ());
2495
2496 return status;
2497}]
2498_LT_EOF
2499 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
2500 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
2501 lt_status=$?
2502 case x$lt_status in
2503 x$lt_dlno_uscore) $1 ;;
2504 x$lt_dlneed_uscore) $2 ;;
2505 x$lt_dlunknown|x*) $3 ;;
2506 esac
2507 else :
2508 # compilation failed
2509 $3
2510 fi
2511fi
2512rm -fr conftest*
2513])# _LT_TRY_DLOPEN_SELF
2514
2515
2516# LT_SYS_DLOPEN_SELF
2517# ------------------
2518AC_DEFUN([LT_SYS_DLOPEN_SELF],
2519[m4_require([_LT_HEADER_DLFCN])dnl
2520if test "x$enable_dlopen" != xyes; then
2521 enable_dlopen=unknown
2522 enable_dlopen_self=unknown
2523 enable_dlopen_self_static=unknown
2524else
2525 lt_cv_dlopen=no
2526 lt_cv_dlopen_libs=
2527
2528 case $host_os in
2529 beos*)
2530 lt_cv_dlopen="load_add_on"
2531 lt_cv_dlopen_libs=
2532 lt_cv_dlopen_self=yes
2533 ;;
2534
2535 mingw* | pw32* | cegcc*)
2536 lt_cv_dlopen="LoadLibrary"
2537 lt_cv_dlopen_libs=
2538 ;;
2539
2540 cygwin*)
2541 lt_cv_dlopen="dlopen"
2542 lt_cv_dlopen_libs=
2543 ;;
2544
2545 darwin*)
2546 # if libdl is installed we need to link against it
2547 AC_CHECK_LIB([dl], [dlopen],
2548 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
2549 lt_cv_dlopen="dyld"
2550 lt_cv_dlopen_libs=
2551 lt_cv_dlopen_self=yes
2552 ])
2553 ;;
2554
2555 *)
2556 AC_CHECK_FUNC([shl_load],
2557 [lt_cv_dlopen="shl_load"],
2558 [AC_CHECK_LIB([dld], [shl_load],
2559 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
2560 [AC_CHECK_FUNC([dlopen],
2561 [lt_cv_dlopen="dlopen"],
2562 [AC_CHECK_LIB([dl], [dlopen],
2563 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
2564 [AC_CHECK_LIB([svld], [dlopen],
2565 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
2566 [AC_CHECK_LIB([dld], [dld_link],
2567 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
2568 ])
2569 ])
2570 ])
2571 ])
2572 ])
2573 ;;
2574 esac
2575
2576 if test "x$lt_cv_dlopen" != xno; then
2577 enable_dlopen=yes
2578 else
2579 enable_dlopen=no
2580 fi
2581
2582 case $lt_cv_dlopen in
2583 dlopen)
2584 save_CPPFLAGS="$CPPFLAGS"
2585 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
2586
2587 save_LDFLAGS="$LDFLAGS"
2588 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2589
2590 save_LIBS="$LIBS"
2591 LIBS="$lt_cv_dlopen_libs $LIBS"
2592
2593 AC_CACHE_CHECK([whether a program can dlopen itself],
2594 lt_cv_dlopen_self, [dnl
2595 _LT_TRY_DLOPEN_SELF(
2596 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2597 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2598 ])
2599
2600 if test "x$lt_cv_dlopen_self" = xyes; then
2601 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2602 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2603 lt_cv_dlopen_self_static, [dnl
2604 _LT_TRY_DLOPEN_SELF(
2605 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2606 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2607 ])
2608 fi
2609
2610 CPPFLAGS="$save_CPPFLAGS"
2611 LDFLAGS="$save_LDFLAGS"
2612 LIBS="$save_LIBS"
2613 ;;
2614 esac
2615
2616 case $lt_cv_dlopen_self in
2617 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2618 *) enable_dlopen_self=unknown ;;
2619 esac
2620
2621 case $lt_cv_dlopen_self_static in
2622 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2623 *) enable_dlopen_self_static=unknown ;;
2624 esac
2625fi
2626_LT_DECL([dlopen_support], [enable_dlopen], [0],
2627 [Whether dlopen is supported])
2628_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
2629 [Whether dlopen of programs is supported])
2630_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
2631 [Whether dlopen of statically linked programs is supported])
2632])# LT_SYS_DLOPEN_SELF
2633
2634# Old name:
2635AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
2636dnl aclocal-1.4 backwards compatibility:
2637dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
2638
2639
2640# _LT_COMPILER_C_O([TAGNAME])
2641# ---------------------------
2642# Check to see if options -c and -o are simultaneously supported by compiler.
2643# This macro does not hard code the compiler like AC_PROG_CC_C_O.
2644m4_defun([_LT_COMPILER_C_O],
2645[m4_require([_LT_DECL_SED])dnl
2646m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2647m4_require([_LT_TAG_COMPILER])dnl
2648AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2649 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2650 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2651 $RM -r conftest 2>/dev/null
2652 mkdir conftest
2653 cd conftest
2654 mkdir out
2655 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2656
2657 lt_compiler_flag="-o out/conftest2.$ac_objext"
2658 # Insert the option either (1) after the last *FLAGS variable, or
2659 # (2) before a word containing "conftest.", or (3) at the end.
2660 # Note that $ac_compile itself does not contain backslashes and begins
2661 # with a dollar sign (not a hyphen), so the echo should work correctly.
2662 lt_compile=`echo "$ac_compile" | $SED \
2663 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2664 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2665 -e 's:$: $lt_compiler_flag:'`
2666 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2667 (eval "$lt_compile" 2>out/conftest.err)
2668 ac_status=$?
2669 cat out/conftest.err >&AS_MESSAGE_LOG_FD
2670 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2671 if (exit $ac_status) && test -s out/conftest2.$ac_objext
2672 then
2673 # The compiler can only warn and ignore the option if not recognized
2674 # So say no if there are warnings
2675 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
2676 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2677 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2678 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2679 fi
2680 fi
2681 chmod u+w . 2>&AS_MESSAGE_LOG_FD
2682 $RM conftest*
2683 # SGI C++ compiler will create directory out/ii_files/ for
2684 # template instantiation
2685 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
2686 $RM out/* && rmdir out
2687 cd ..
2688 $RM -r conftest
2689 $RM conftest*
2690])
2691_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
2692 [Does compiler simultaneously support -c and -o options?])
2693])# _LT_COMPILER_C_O
2694
2695
2696# _LT_COMPILER_FILE_LOCKS([TAGNAME])
2697# ----------------------------------
2698# Check to see if we can do hard links to lock some files if needed
2699m4_defun([_LT_COMPILER_FILE_LOCKS],
2700[m4_require([_LT_ENABLE_LOCK])dnl
2701m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2702_LT_COMPILER_C_O([$1])
2703
2704hard_links="nottested"
2705if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2706 # do not overwrite the value of need_locks provided by the user
2707 AC_MSG_CHECKING([if we can lock with hard links])
2708 hard_links=yes
2709 $RM conftest*
2710 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2711 touch conftest.a
2712 ln conftest.a conftest.b 2>&5 || hard_links=no
2713 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2714 AC_MSG_RESULT([$hard_links])
2715 if test "$hard_links" = no; then
2716 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2717 need_locks=warn
2718 fi
2719else
2720 need_locks=no
2721fi
2722_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
2723])# _LT_COMPILER_FILE_LOCKS
2724
2725
2726# _LT_CHECK_OBJDIR
2727# ----------------
2728m4_defun([_LT_CHECK_OBJDIR],
2729[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2730[rm -f .libs 2>/dev/null
2731mkdir .libs 2>/dev/null
2732if test -d .libs; then
2733 lt_cv_objdir=.libs
2734else
2735 # MS-DOS does not allow filenames that begin with a dot.
2736 lt_cv_objdir=_libs
2737fi
2738rmdir .libs 2>/dev/null])
2739objdir=$lt_cv_objdir
2740_LT_DECL([], [objdir], [0],
2741 [The name of the directory that contains temporary libtool files])dnl
2742m4_pattern_allow([LT_OBJDIR])dnl
2743AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2744 [Define to the sub-directory in which libtool stores uninstalled libraries.])
2745])# _LT_CHECK_OBJDIR
2746
2747
2748# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
2749# --------------------------------------
2750# Check hardcoding attributes.
2751m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
2752[AC_MSG_CHECKING([how to hardcode library paths into programs])
2753_LT_TAGVAR(hardcode_action, $1)=
2754if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
2755 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2756 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2757
2758 # We can hardcode non-existent directories.
2759 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2760 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2761 # have to relink, otherwise we might link with an installed library
2762 # when we should be linking with a yet-to-be-installed one
2763 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2764 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2765 # Linking always hardcodes the temporary library directory.
2766 _LT_TAGVAR(hardcode_action, $1)=relink
2767 else
2768 # We can link without hardcoding, and we can hardcode nonexisting dirs.
2769 _LT_TAGVAR(hardcode_action, $1)=immediate
2770 fi
2771else
2772 # We cannot hardcode anything, or else we can only hardcode existing
2773 # directories.
2774 _LT_TAGVAR(hardcode_action, $1)=unsupported
2775fi
2776AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
2777
2778if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2779 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2780 # Fast installation is not supported
2781 enable_fast_install=no
2782elif test "$shlibpath_overrides_runpath" = yes ||
2783 test "$enable_shared" = no; then
2784 # Fast installation is not necessary
2785 enable_fast_install=needless
2786fi
2787_LT_TAGDECL([], [hardcode_action], [0],
2788 [How to hardcode a shared library path into an executable])
2789])# _LT_LINKER_HARDCODE_LIBPATH
2790
2791
2792# _LT_CMD_STRIPLIB
2793# ----------------
2794m4_defun([_LT_CMD_STRIPLIB],
2795[m4_require([_LT_DECL_EGREP])
2796striplib=
2797old_striplib=
2798AC_MSG_CHECKING([whether stripping libraries is possible])
2799if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
2800 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2801 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2802 AC_MSG_RESULT([yes])
2803else
2804# FIXME - insert some real tests, host_os isn't really good enough
2805 case $host_os in
2806 darwin*)
2807 if test -n "$STRIP" ; then
2808 striplib="$STRIP -x"
2809 old_striplib="$STRIP -S"
2810 AC_MSG_RESULT([yes])
2811 else
2812 AC_MSG_RESULT([no])
2813 fi
2814 ;;
2815 *)
2816 AC_MSG_RESULT([no])
2817 ;;
2818 esac
2819fi
2820_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
2821_LT_DECL([], [striplib], [1])
2822])# _LT_CMD_STRIPLIB
2823
2824
2825# _LT_SYS_DYNAMIC_LINKER([TAG])
2826# -----------------------------
2827# PORTME Fill in your ld.so characteristics
2828m4_defun([_LT_SYS_DYNAMIC_LINKER],
2829[AC_REQUIRE([AC_CANONICAL_HOST])dnl
2830m4_require([_LT_DECL_EGREP])dnl
2831m4_require([_LT_FILEUTILS_DEFAULTS])dnl
2832m4_require([_LT_DECL_OBJDUMP])dnl
2833m4_require([_LT_DECL_SED])dnl
2834m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2835AC_MSG_CHECKING([dynamic linker characteristics])
2836m4_if([$1],
2837 [], [
2838if test "$GCC" = yes; then
2839 case $host_os in
2840 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2841 *) lt_awk_arg="/^libraries:/" ;;
2842 esac
2843 case $host_os in
2844 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
2845 *) lt_sed_strip_eq="s,=/,/,g" ;;
2846 esac
2847 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
2848 case $lt_search_path_spec in
2849 *\;*)
2850 # if the path contains ";" then we assume it to be the separator
2851 # otherwise default to the standard path separator (i.e. ":") - it is
2852 # assumed that no part of a normal pathname contains ";" but that should
2853 # okay in the real world where ";" in dirpaths is itself problematic.
2854 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
2855 ;;
2856 *)
2857 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
2858 ;;
2859 esac
2860 # Ok, now we have the path, separated by spaces, we can step through it
2861 # and add multilib dir if necessary.
2862 lt_tmp_lt_search_path_spec=
2863 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2864 for lt_sys_path in $lt_search_path_spec; do
2865 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2866 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2867 else
2868 test -d "$lt_sys_path" && \
2869 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2870 fi
2871 done
2872 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2873BEGIN {RS=" "; FS="/|\n";} {
2874 lt_foo="";
2875 lt_count=0;
2876 for (lt_i = NF; lt_i > 0; lt_i--) {
2877 if ($lt_i != "" && $lt_i != ".") {
2878 if ($lt_i == "..") {
2879 lt_count++;
2880 } else {
2881 if (lt_count == 0) {
2882 lt_foo="/" $lt_i lt_foo;
2883 } else {
2884 lt_count--;
2885 }
2886 }
2887 }
2888 }
2889 if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2890 if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2891}'`
2892 # AWK program above erroneously prepends '/' to C:/dos/paths
2893 # for these hosts.
2894 case $host_os in
2895 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
2896 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
2897 esac
2898 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
2899else
2900 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2901fi])
2902library_names_spec=
2903libname_spec='lib$name'
2904soname_spec=
2905shrext_cmds=".so"
2906postinstall_cmds=
2907postuninstall_cmds=
2908finish_cmds=
2909finish_eval=
2910shlibpath_var=
2911shlibpath_overrides_runpath=unknown
2912version_type=none
2913dynamic_linker="$host_os ld.so"
2914sys_lib_dlsearch_path_spec="/lib /usr/lib"
2915need_lib_prefix=unknown
2916hardcode_into_libs=no
2917
2918# when you set need_version to no, make sure it does not cause -set_version
2919# flags to be left without arguments
2920need_version=unknown
2921
2922case $host_os in
2923aix3*)
2924 version_type=linux # correct to gnu/linux during the next big refactor
2925 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2926 shlibpath_var=LIBPATH
2927
2928 # AIX 3 has no versioning support, so we append a major version to the name.
2929 soname_spec='${libname}${release}${shared_ext}$major'
2930 ;;
2931
2932aix[[4-9]]*)
2933 version_type=linux # correct to gnu/linux during the next big refactor
2934 need_lib_prefix=no
2935 need_version=no
2936 hardcode_into_libs=yes
2937 if test "$host_cpu" = ia64; then
2938 # AIX 5 supports IA64
2939 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2940 shlibpath_var=LD_LIBRARY_PATH
2941 else
2942 # With GCC up to 2.95.x, collect2 would create an import file
2943 # for dependence libraries. The import file would start with
2944 # the line `#! .'. This would cause the generated library to
2945 # depend on `.', always an invalid library. This was fixed in
2946 # development snapshots of GCC prior to 3.0.
2947 case $host_os in
2948 aix4 | aix4.[[01]] | aix4.[[01]].*)
2949 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2950 echo ' yes '
2951 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2952 :
2953 else
2954 can_build_shared=no
2955 fi
2956 ;;
2957 esac
2958 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2959 # soname into executable. Probably we can add versioning support to
2960 # collect2, so additional links can be useful in future.
2961 if test "$aix_use_runtimelinking" = yes; then
2962 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2963 # instead of lib<name>.a to let people know that these are not
2964 # typical AIX shared libraries.
2965 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2966 else
2967 # We preserve .a as extension for shared libraries through AIX4.2
2968 # and later when we are not doing run time linking.
2969 library_names_spec='${libname}${release}.a $libname.a'
2970 soname_spec='${libname}${release}${shared_ext}$major'
2971 fi
2972 shlibpath_var=LIBPATH
2973 fi
2974 ;;
2975
2976amigaos*)
2977 case $host_cpu in
2978 powerpc)
2979 # Since July 2007 AmigaOS4 officially supports .so libraries.
2980 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2981 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2982 ;;
2983 m68k)
2984 library_names_spec='$libname.ixlibrary $libname.a'
2985 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2986 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2987 ;;
2988 esac
2989 ;;
2990
2991beos*)
2992 library_names_spec='${libname}${shared_ext}'
2993 dynamic_linker="$host_os ld.so"
2994 shlibpath_var=LIBRARY_PATH
2995 ;;
2996
2997bsdi[[45]]*)
2998 version_type=linux # correct to gnu/linux during the next big refactor
2999 need_version=no
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 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
3003 shlibpath_var=LD_LIBRARY_PATH
3004 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
3005 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
3006 # the default ld.so.conf also contains /usr/contrib/lib and
3007 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
3008 # libtool to hard-code these into programs
3009 ;;
3010
3011cygwin* | mingw* | pw32* | cegcc*)
3012 version_type=windows
3013 shrext_cmds=".dll"
3014 need_version=no
3015 need_lib_prefix=no
3016
3017 case $GCC,$cc_basename in
3018 yes,*)
3019 # gcc
3020 library_names_spec='$libname.dll.a'
3021 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3022 postinstall_cmds='base_file=`basename \${file}`~
3023 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3024 dldir=$destdir/`dirname \$dlpath`~
3025 test -d \$dldir || mkdir -p \$dldir~
3026 $install_prog $dir/$dlname \$dldir/$dlname~
3027 chmod a+x \$dldir/$dlname~
3028 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
3029 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
3030 fi'
3031 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3032 dlpath=$dir/\$dldll~
3033 $RM \$dlpath'
3034 shlibpath_overrides_runpath=yes
3035
3036 case $host_os in
3037 cygwin*)
3038 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
3039 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3040m4_if([$1], [],[
3041 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
3042 ;;
3043 mingw* | cegcc*)
3044 # MinGW DLLs use traditional 'lib' prefix
3045 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3046 ;;
3047 pw32*)
3048 # pw32 DLLs use 'pw' prefix rather than 'lib'
3049 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3050 ;;
3051 esac
3052 dynamic_linker='Win32 ld.exe'
3053 ;;
3054
3055 *,cl*)
3056 # Native MSVC
3057 libname_spec='$name'
3058 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
3059 library_names_spec='${libname}.dll.lib'
3060
3061 case $build_os in
3062 mingw*)
3063 sys_lib_search_path_spec=
3064 lt_save_ifs=$IFS
3065 IFS=';'
3066 for lt_path in $LIB
3067 do
3068 IFS=$lt_save_ifs
3069 # Let DOS variable expansion print the short 8.3 style file name.
3070 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
3071 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
3072 done
3073 IFS=$lt_save_ifs
3074 # Convert to MSYS style.
3075 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
3076 ;;
3077 cygwin*)
3078 # Convert to unix form, then to dos form, then back to unix form
3079 # but this time dos style (no spaces!) so that the unix form looks
3080 # like /cygdrive/c/PROGRA~1:/cygdr...
3081 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
3082 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
3083 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3084 ;;
3085 *)
3086 sys_lib_search_path_spec="$LIB"
3087 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
3088 # It is most probably a Windows format PATH.
3089 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
3090 else
3091 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
3092 fi
3093 # FIXME: find the short name or the path components, as spaces are
3094 # common. (e.g. "Program Files" -> "PROGRA~1")
3095 ;;
3096 esac
3097
3098 # DLL is installed to $(libdir)/../bin by postinstall_cmds
3099 postinstall_cmds='base_file=`basename \${file}`~
3100 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
3101 dldir=$destdir/`dirname \$dlpath`~
3102 test -d \$dldir || mkdir -p \$dldir~
3103 $install_prog $dir/$dlname \$dldir/$dlname'
3104 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
3105 dlpath=$dir/\$dldll~
3106 $RM \$dlpath'
3107 shlibpath_overrides_runpath=yes
3108 dynamic_linker='Win32 link.exe'
3109 ;;
3110
3111 *)
3112 # Assume MSVC wrapper
3113 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
3114 dynamic_linker='Win32 ld.exe'
3115 ;;
3116 esac
3117 # FIXME: first we should search . and the directory the executable is in
3118 shlibpath_var=PATH
3119 ;;
3120
3121darwin* | rhapsody*)
3122 dynamic_linker="$host_os dyld"
3123 version_type=darwin
3124 need_lib_prefix=no
3125 need_version=no
3126 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
3127 soname_spec='${libname}${release}${major}$shared_ext'
3128 shlibpath_overrides_runpath=yes
3129 shlibpath_var=DYLD_LIBRARY_PATH
3130 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
3131m4_if([$1], [],[
3132 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
3133 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
3134 ;;
3135
3136dgux*)
3137 version_type=linux # correct to gnu/linux during the next big refactor
3138 need_lib_prefix=no
3139 need_version=no
3140 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
3141 soname_spec='${libname}${release}${shared_ext}$major'
3142 shlibpath_var=LD_LIBRARY_PATH
3143 ;;
3144
3145freebsd* | dragonfly*)
3146 # DragonFly does not have aout. When/if they implement a new
3147 # versioning mechanism, adjust this.
3148 if test -x /usr/bin/objformat; then
3149 objformat=`/usr/bin/objformat`
3150 else
3151 case $host_os in
3152 freebsd[[23]].*) objformat=aout ;;
3153 *) objformat=elf ;;
3154 esac
3155 fi
3156 version_type=freebsd-$objformat
3157 case $version_type in
3158 freebsd-elf*)
3159 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3160 need_version=no
3161 need_lib_prefix=no
3162 ;;
3163 freebsd-*)
3164 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
3165 need_version=yes
3166 ;;
3167 esac
3168 shlibpath_var=LD_LIBRARY_PATH
3169 case $host_os in
3170 freebsd2.*)
3171 shlibpath_overrides_runpath=yes
3172 ;;
3173 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
3174 shlibpath_overrides_runpath=yes
3175 hardcode_into_libs=yes
3176 ;;
3177 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
3178 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
3179 shlibpath_overrides_runpath=no
3180 hardcode_into_libs=yes
3181 ;;
3182 *) # from 4.6 on, and DragonFly
3183 shlibpath_overrides_runpath=yes
3184 hardcode_into_libs=yes
3185 ;;
3186 esac
3187 ;;
3188
3189haiku*)
3190 version_type=linux # correct to gnu/linux during the next big refactor
3191 need_lib_prefix=no
3192 need_version=no
3193 dynamic_linker="$host_os runtime_loader"
3194 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
3195 soname_spec='${libname}${release}${shared_ext}$major'
3196 shlibpath_var=LIBRARY_PATH
3197 shlibpath_overrides_runpath=yes
3198 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
3199 hardcode_into_libs=yes
3200 ;;
3201
3202hpux9* | hpux10* | hpux11*)
3203 # Give a soname corresponding to the major version so that dld.sl refuses to
3204 # link against other versions.
3205 version_type=sunos
3206 need_lib_prefix=no
3207 need_version=no
3208 case $host_cpu in
3209 ia64*)
3210 shrext_cmds='.so'
3211 hardcode_into_libs=yes
3212 dynamic_linker="$host_os dld.so"
3213 shlibpath_var=LD_LIBRARY_PATH
3214 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3215 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3216 soname_spec='${libname}${release}${shared_ext}$major'
3217 if test "X$HPUX_IA64_MODE" = X32; then
3218 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
3219 else
3220 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
3221 fi
3222 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3223 ;;
3224 hppa*64*)
3225 shrext_cmds='.sl'
3226 hardcode_into_libs=yes
3227 dynamic_linker="$host_os dld.sl"
3228 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
3229 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
3230 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3231 soname_spec='${libname}${release}${shared_ext}$major'
3232 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
3233 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
3234 ;;
3235 *)
3236 shrext_cmds='.sl'
3237 dynamic_linker="$host_os dld.sl"
3238 shlibpath_var=SHLIB_PATH
3239 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
3240 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3241 soname_spec='${libname}${release}${shared_ext}$major'
3242 ;;
3243 esac
3244 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
3245 postinstall_cmds='chmod 555 $lib'
3246 # or fails outright, so override atomically:
3247 install_override_mode=555
3248 ;;
3249
3250interix[[3-9]]*)
3251 version_type=linux # correct to gnu/linux during the next big refactor
3252 need_lib_prefix=no
3253 need_version=no
3254 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3255 soname_spec='${libname}${release}${shared_ext}$major'
3256 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
3257 shlibpath_var=LD_LIBRARY_PATH
3258 shlibpath_overrides_runpath=no
3259 hardcode_into_libs=yes
3260 ;;
3261
3262irix5* | irix6* | nonstopux*)
3263 case $host_os in
3264 nonstopux*) version_type=nonstopux ;;
3265 *)
3266 if test "$lt_cv_prog_gnu_ld" = yes; then
3267 version_type=linux # correct to gnu/linux during the next big refactor
3268 else
3269 version_type=irix
3270 fi ;;
3271 esac
3272 need_lib_prefix=no
3273 need_version=no
3274 soname_spec='${libname}${release}${shared_ext}$major'
3275 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
3276 case $host_os in
3277 irix5* | nonstopux*)
3278 libsuff= shlibsuff=
3279 ;;
3280 *)
3281 case $LD in # libtool.m4 will add one of these switches to LD
3282 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
3283 libsuff= shlibsuff= libmagic=32-bit;;
3284 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
3285 libsuff=32 shlibsuff=N32 libmagic=N32;;
3286 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
3287 libsuff=64 shlibsuff=64 libmagic=64-bit;;
3288 *) libsuff= shlibsuff= libmagic=never-match;;
3289 esac
3290 ;;
3291 esac
3292 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
3293 shlibpath_overrides_runpath=no
3294 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
3295 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
3296 hardcode_into_libs=yes
3297 ;;
3298
3299# No shared lib support for Linux oldld, aout, or coff.
3300linux*oldld* | linux*aout* | linux*coff*)
3301 dynamic_linker=no
3302 ;;
3303
3304# This must be glibc/ELF.
3305linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3306 version_type=linux # correct to gnu/linux during the next big refactor
3307 need_lib_prefix=no
3308 need_version=no
3309 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3310 soname_spec='${libname}${release}${shared_ext}$major'
3311 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
3312 shlibpath_var=LD_LIBRARY_PATH
3313 shlibpath_overrides_runpath=no
3314
3315 # Some binutils ld are patched to set DT_RUNPATH
3316 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
3317 [lt_cv_shlibpath_overrides_runpath=no
3318 save_LDFLAGS=$LDFLAGS
3319 save_libdir=$libdir
3320 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
3321 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
3322 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
3323 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
3324 [lt_cv_shlibpath_overrides_runpath=yes])])
3325 LDFLAGS=$save_LDFLAGS
3326 libdir=$save_libdir
3327 ])
3328 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
3329
3330 # This implies no fast_install, which is unacceptable.
3331 # Some rework will be needed to allow for fast_install
3332 # before this can be enabled.
3333 hardcode_into_libs=yes
3334
3335 # Append ld.so.conf contents to the search path
3336 if test -f /etc/ld.so.conf; then
3337 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
3338 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3339 fi
3340
3341 # We used to test for /lib/ld.so.1 and disable shared libraries on
3342 # powerpc, because MkLinux only supported shared libraries with the
3343 # GNU dynamic linker. Since this was broken with cross compilers,
3344 # most powerpc-linux boxes support dynamic linking these days and
3345 # people can always --disable-shared, the test was removed, and we
3346 # assume the GNU/Linux dynamic linker is in use.
3347 dynamic_linker='GNU/Linux ld.so'
3348 ;;
3349
3350netbsdelf*-gnu)
3351 version_type=linux
3352 need_lib_prefix=no
3353 need_version=no
3354 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3355 soname_spec='${libname}${release}${shared_ext}$major'
3356 shlibpath_var=LD_LIBRARY_PATH
3357 shlibpath_overrides_runpath=no
3358 hardcode_into_libs=yes
3359 dynamic_linker='NetBSD ld.elf_so'
3360 ;;
3361
3362netbsd*)
3363 version_type=sunos
3364 need_lib_prefix=no
3365 need_version=no
3366 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
3367 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3368 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3369 dynamic_linker='NetBSD (a.out) ld.so'
3370 else
3371 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3372 soname_spec='${libname}${release}${shared_ext}$major'
3373 dynamic_linker='NetBSD ld.elf_so'
3374 fi
3375 shlibpath_var=LD_LIBRARY_PATH
3376 shlibpath_overrides_runpath=yes
3377 hardcode_into_libs=yes
3378 ;;
3379
3380newsos6)
3381 version_type=linux # correct to gnu/linux during the next big refactor
3382 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3383 shlibpath_var=LD_LIBRARY_PATH
3384 shlibpath_overrides_runpath=yes
3385 ;;
3386
3387*nto* | *qnx*)
3388 version_type=qnx
3389 need_lib_prefix=no
3390 need_version=no
3391 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3392 soname_spec='${libname}${release}${shared_ext}$major'
3393 shlibpath_var=LD_LIBRARY_PATH
3394 shlibpath_overrides_runpath=no
3395 hardcode_into_libs=yes
3396 dynamic_linker='ldqnx.so'
3397 ;;
3398
3399openbsd*)
3400 version_type=sunos
3401 sys_lib_dlsearch_path_spec="/usr/lib"
3402 need_lib_prefix=no
3403 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
3404 case $host_os in
3405 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
3406 *) need_version=no ;;
3407 esac
3408 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3409 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
3410 shlibpath_var=LD_LIBRARY_PATH
3411 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3412 case $host_os in
3413 openbsd2.[[89]] | openbsd2.[[89]].*)
3414 shlibpath_overrides_runpath=no
3415 ;;
3416 *)
3417 shlibpath_overrides_runpath=yes
3418 ;;
3419 esac
3420 else
3421 shlibpath_overrides_runpath=yes
3422 fi
3423 ;;
3424
3425os2*)
3426 libname_spec='$name'
3427 shrext_cmds=".dll"
3428 need_lib_prefix=no
3429 library_names_spec='$libname${shared_ext} $libname.a'
3430 dynamic_linker='OS/2 ld.exe'
3431 shlibpath_var=LIBPATH
3432 ;;
3433
3434osf3* | osf4* | osf5*)
3435 version_type=osf
3436 need_lib_prefix=no
3437 need_version=no
3438 soname_spec='${libname}${release}${shared_ext}$major'
3439 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3440 shlibpath_var=LD_LIBRARY_PATH
3441 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
3442 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
3443 ;;
3444
3445rdos*)
3446 dynamic_linker=no
3447 ;;
3448
3449solaris*)
3450 version_type=linux # correct to gnu/linux during the next big refactor
3451 need_lib_prefix=no
3452 need_version=no
3453 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3454 soname_spec='${libname}${release}${shared_ext}$major'
3455 shlibpath_var=LD_LIBRARY_PATH
3456 shlibpath_overrides_runpath=yes
3457 hardcode_into_libs=yes
3458 # ldd complains unless libraries are executable
3459 postinstall_cmds='chmod +x $lib'
3460 ;;
3461
3462sunos4*)
3463 version_type=sunos
3464 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3465 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
3466 shlibpath_var=LD_LIBRARY_PATH
3467 shlibpath_overrides_runpath=yes
3468 if test "$with_gnu_ld" = yes; then
3469 need_lib_prefix=no
3470 fi
3471 need_version=yes
3472 ;;
3473
3474sysv4 | sysv4.3*)
3475 version_type=linux # correct to gnu/linux during the next big refactor
3476 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3477 soname_spec='${libname}${release}${shared_ext}$major'
3478 shlibpath_var=LD_LIBRARY_PATH
3479 case $host_vendor in
3480 sni)
3481 shlibpath_overrides_runpath=no
3482 need_lib_prefix=no
3483 runpath_var=LD_RUN_PATH
3484 ;;
3485 siemens)
3486 need_lib_prefix=no
3487 ;;
3488 motorola)
3489 need_lib_prefix=no
3490 need_version=no
3491 shlibpath_overrides_runpath=no
3492 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
3493 ;;
3494 esac
3495 ;;
3496
3497sysv4*MP*)
3498 if test -d /usr/nec ;then
3499 version_type=linux # correct to gnu/linux during the next big refactor
3500 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
3501 soname_spec='$libname${shared_ext}.$major'
3502 shlibpath_var=LD_LIBRARY_PATH
3503 fi
3504 ;;
3505
3506sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3507 version_type=freebsd-elf
3508 need_lib_prefix=no
3509 need_version=no
3510 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
3511 soname_spec='${libname}${release}${shared_ext}$major'
3512 shlibpath_var=LD_LIBRARY_PATH
3513 shlibpath_overrides_runpath=yes
3514 hardcode_into_libs=yes
3515 if test "$with_gnu_ld" = yes; then
3516 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
3517 else
3518 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
3519 case $host_os in
3520 sco3.2v5*)
3521 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
3522 ;;
3523 esac
3524 fi
3525 sys_lib_dlsearch_path_spec='/usr/lib'
3526 ;;
3527
3528tpf*)
3529 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
3530 version_type=linux # correct to gnu/linux during the next big refactor
3531 need_lib_prefix=no
3532 need_version=no
3533 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3534 shlibpath_var=LD_LIBRARY_PATH
3535 shlibpath_overrides_runpath=no
3536 hardcode_into_libs=yes
3537 ;;
3538
3539uts4*)
3540 version_type=linux # correct to gnu/linux during the next big refactor
3541 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3542 soname_spec='${libname}${release}${shared_ext}$major'
3543 shlibpath_var=LD_LIBRARY_PATH
3544 ;;
3545
3546*)
3547 dynamic_linker=no
3548 ;;
3549esac
3550AC_MSG_RESULT([$dynamic_linker])
3551test "$dynamic_linker" = no && can_build_shared=no
3552
3553variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
3554if test "$GCC" = yes; then
3555 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
3556fi
3557
3558if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
3559 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
3560fi
3561if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
3562 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
3563fi
3564
3565_LT_DECL([], [variables_saved_for_relink], [1],
3566 [Variables whose values should be saved in libtool wrapper scripts and
3567 restored at link time])
3568_LT_DECL([], [need_lib_prefix], [0],
3569 [Do we need the "lib" prefix for modules?])
3570_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
3571_LT_DECL([], [version_type], [0], [Library versioning type])
3572_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
3573_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
3574_LT_DECL([], [shlibpath_overrides_runpath], [0],
3575 [Is shlibpath searched before the hard-coded library search path?])
3576_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
3577_LT_DECL([], [library_names_spec], [1],
3578 [[List of archive names. First name is the real one, the rest are links.
3579 The last name is the one that the linker finds with -lNAME]])
3580_LT_DECL([], [soname_spec], [1],
3581 [[The coded name of the library, if different from the real name]])
3582_LT_DECL([], [install_override_mode], [1],
3583 [Permission mode override for installation of shared libraries])
3584_LT_DECL([], [postinstall_cmds], [2],
3585 [Command to use after installation of a shared archive])
3586_LT_DECL([], [postuninstall_cmds], [2],
3587 [Command to use after uninstallation of a shared archive])
3588_LT_DECL([], [finish_cmds], [2],
3589 [Commands used to finish a libtool library installation in a directory])
3590_LT_DECL([], [finish_eval], [1],
3591 [[As "finish_cmds", except a single script fragment to be evaled but
3592 not shown]])
3593_LT_DECL([], [hardcode_into_libs], [0],
3594 [Whether we should hardcode library paths into libraries])
3595_LT_DECL([], [sys_lib_search_path_spec], [2],
3596 [Compile-time system search path for libraries])
3597_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
3598 [Run-time system search path for libraries])
3599])# _LT_SYS_DYNAMIC_LINKER
3600
3601
3602# _LT_PATH_TOOL_PREFIX(TOOL)
3603# --------------------------
3604# find a file program which can recognize shared library
3605AC_DEFUN([_LT_PATH_TOOL_PREFIX],
3606[m4_require([_LT_DECL_EGREP])dnl
3607AC_MSG_CHECKING([for $1])
3608AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3609[case $MAGIC_CMD in
3610[[\\/*] | ?:[\\/]*])
3611 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3612 ;;
3613*)
3614 lt_save_MAGIC_CMD="$MAGIC_CMD"
3615 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3616dnl $ac_dummy forces splitting on constant user-supplied paths.
3617dnl POSIX.2 word splitting is done only on the output of word expansions,
3618dnl not every word. This closes a longstanding sh security hole.
3619 ac_dummy="m4_if([$2], , $PATH, [$2])"
3620 for ac_dir in $ac_dummy; do
3621 IFS="$lt_save_ifs"
3622 test -z "$ac_dir" && ac_dir=.
3623 if test -f $ac_dir/$1; then
3624 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3625 if test -n "$file_magic_test_file"; then
3626 case $deplibs_check_method in
3627 "file_magic "*)
3628 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3629 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3630 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3631 $EGREP "$file_magic_regex" > /dev/null; then
3632 :
3633 else
3634 cat <<_LT_EOF 1>&2
3635
3636*** Warning: the command libtool uses to detect shared libraries,
3637*** $file_magic_cmd, produces output that libtool cannot recognize.
3638*** The result is that libtool may fail to recognize shared libraries
3639*** as such. This will affect the creation of libtool libraries that
3640*** depend on shared libraries, but programs linked with such libtool
3641*** libraries will work regardless of this problem. Nevertheless, you
3642*** may want to report the problem to your system manager and/or to
3643*** bug-libtool@gnu.org
3644
3645_LT_EOF
3646 fi ;;
3647 esac
3648 fi
3649 break
3650 fi
3651 done
3652 IFS="$lt_save_ifs"
3653 MAGIC_CMD="$lt_save_MAGIC_CMD"
3654 ;;
3655esac])
3656MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3657if test -n "$MAGIC_CMD"; then
3658 AC_MSG_RESULT($MAGIC_CMD)
3659else
3660 AC_MSG_RESULT(no)
3661fi
3662_LT_DECL([], [MAGIC_CMD], [0],
3663 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
3664])# _LT_PATH_TOOL_PREFIX
3665
3666# Old name:
3667AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
3668dnl aclocal-1.4 backwards compatibility:
3669dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
3670
3671
3672# _LT_PATH_MAGIC
3673# --------------
3674# find a file program which can recognize a shared library
3675m4_defun([_LT_PATH_MAGIC],
3676[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3677if test -z "$lt_cv_path_MAGIC_CMD"; then
3678 if test -n "$ac_tool_prefix"; then
3679 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3680 else
3681 MAGIC_CMD=:
3682 fi
3683fi
3684])# _LT_PATH_MAGIC
3685
3686
3687# LT_PATH_LD
3688# ----------
3689# find the pathname to the GNU or non-GNU linker
3690AC_DEFUN([LT_PATH_LD],
3691[AC_REQUIRE([AC_PROG_CC])dnl
3692AC_REQUIRE([AC_CANONICAL_HOST])dnl
3693AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3694m4_require([_LT_DECL_SED])dnl
3695m4_require([_LT_DECL_EGREP])dnl
3696m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
3697
3698AC_ARG_WITH([gnu-ld],
3699 [AS_HELP_STRING([--with-gnu-ld],
3700 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3701 [test "$withval" = no || with_gnu_ld=yes],
3702 [with_gnu_ld=no])dnl
3703
3704ac_prog=ld
3705if test "$GCC" = yes; then
3706 # Check if gcc -print-prog-name=ld gives a path.
3707 AC_MSG_CHECKING([for ld used by $CC])
3708 case $host in
3709 *-*-mingw*)
3710 # gcc leaves a trailing carriage return which upsets mingw
3711 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3712 *)
3713 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3714 esac
3715 case $ac_prog in
3716 # Accept absolute paths.
3717 [[\\/]]* | ?:[[\\/]]*)
3718 re_direlt='/[[^/]][[^/]]*/\.\./'
3719 # Canonicalize the pathname of ld
3720 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
3721 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
3722 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
3723 done
3724 test -z "$LD" && LD="$ac_prog"
3725 ;;
3726 "")
3727 # If it fails, then pretend we aren't using GCC.
3728 ac_prog=ld
3729 ;;
3730 *)
3731 # If it is relative, then search for the first ld in PATH.
3732 with_gnu_ld=unknown
3733 ;;
3734 esac
3735elif test "$with_gnu_ld" = yes; then
3736 AC_MSG_CHECKING([for GNU ld])
3737else
3738 AC_MSG_CHECKING([for non-GNU ld])
3739fi
3740AC_CACHE_VAL(lt_cv_path_LD,
3741[if test -z "$LD"; then
3742 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3743 for ac_dir in $PATH; do
3744 IFS="$lt_save_ifs"
3745 test -z "$ac_dir" && ac_dir=.
3746 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3747 lt_cv_path_LD="$ac_dir/$ac_prog"
3748 # Check to see if the program is GNU ld. I'd rather use --version,
3749 # but apparently some variants of GNU ld only accept -v.
3750 # Break only if it was the GNU/non-GNU ld that we prefer.
3751 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3752 *GNU* | *'with BFD'*)
3753 test "$with_gnu_ld" != no && break
3754 ;;
3755 *)
3756 test "$with_gnu_ld" != yes && break
3757 ;;
3758 esac
3759 fi
3760 done
3761 IFS="$lt_save_ifs"
3762else
3763 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3764fi])
3765LD="$lt_cv_path_LD"
3766if test -n "$LD"; then
3767 AC_MSG_RESULT($LD)
3768else
3769 AC_MSG_RESULT(no)
3770fi
3771test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3772_LT_PATH_LD_GNU
3773AC_SUBST([LD])
3774
3775_LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
3776])# LT_PATH_LD
3777
3778# Old names:
3779AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
3780AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
3781dnl aclocal-1.4 backwards compatibility:
3782dnl AC_DEFUN([AM_PROG_LD], [])
3783dnl AC_DEFUN([AC_PROG_LD], [])
3784
3785
3786# _LT_PATH_LD_GNU
3787#- --------------
3788m4_defun([_LT_PATH_LD_GNU],
3789[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3790[# I'd rather use --version here, but apparently some GNU lds only accept -v.
3791case `$LD -v 2>&1 </dev/null` in
3792*GNU* | *'with BFD'*)
3793 lt_cv_prog_gnu_ld=yes
3794 ;;
3795*)
3796 lt_cv_prog_gnu_ld=no
3797 ;;
3798esac])
3799with_gnu_ld=$lt_cv_prog_gnu_ld
3800])# _LT_PATH_LD_GNU
3801
3802
3803# _LT_CMD_RELOAD
3804# --------------
3805# find reload flag for linker
3806# -- PORTME Some linkers may need a different reload flag.
3807m4_defun([_LT_CMD_RELOAD],
3808[AC_CACHE_CHECK([for $LD option to reload object files],
3809 lt_cv_ld_reload_flag,
3810 [lt_cv_ld_reload_flag='-r'])
3811reload_flag=$lt_cv_ld_reload_flag
3812case $reload_flag in
3813"" | " "*) ;;
3814*) reload_flag=" $reload_flag" ;;
3815esac
3816reload_cmds='$LD$reload_flag -o $output$reload_objs'
3817case $host_os in
3818 cygwin* | mingw* | pw32* | cegcc*)
3819 if test "$GCC" != yes; then
3820 reload_cmds=false
3821 fi
3822 ;;
3823 darwin*)
3824 if test "$GCC" = yes; then
3825 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3826 else
3827 reload_cmds='$LD$reload_flag -o $output$reload_objs'
3828 fi
3829 ;;
3830esac
3831_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
3832_LT_TAGDECL([], [reload_cmds], [2])dnl
3833])# _LT_CMD_RELOAD
3834
3835
3836# _LT_CHECK_MAGIC_METHOD
3837# ----------------------
3838# how to check for library dependencies
3839# -- PORTME fill in with the dynamic library characteristics
3840m4_defun([_LT_CHECK_MAGIC_METHOD],
3841[m4_require([_LT_DECL_EGREP])
3842m4_require([_LT_DECL_OBJDUMP])
3843AC_CACHE_CHECK([how to recognize dependent libraries],
3844lt_cv_deplibs_check_method,
3845[lt_cv_file_magic_cmd='$MAGIC_CMD'
3846lt_cv_file_magic_test_file=
3847lt_cv_deplibs_check_method='unknown'
3848# Need to set the preceding variable on all platforms that support
3849# interlibrary dependencies.
3850# 'none' -- dependencies not supported.
3851# `unknown' -- same as none, but documents that we really don't know.
3852# 'pass_all' -- all dependencies passed with no checks.
3853# 'test_compile' -- check by making test program.
3854# 'file_magic [[regex]]' -- check by looking for files in library path
3855# which responds to the $file_magic_cmd with a given extended regex.
3856# If you have `file' or equivalent on your system and you're not sure
3857# whether `pass_all' will *always* work, you probably want this one.
3858
3859case $host_os in
3860aix[[4-9]]*)
3861 lt_cv_deplibs_check_method=pass_all
3862 ;;
3863
3864beos*)
3865 lt_cv_deplibs_check_method=pass_all
3866 ;;
3867
3868bsdi[[45]]*)
3869 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3870 lt_cv_file_magic_cmd='/usr/bin/file -L'
3871 lt_cv_file_magic_test_file=/shlib/libc.so
3872 ;;
3873
3874cygwin*)
3875 # func_win32_libid is a shell function defined in ltmain.sh
3876 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3877 lt_cv_file_magic_cmd='func_win32_libid'
3878 ;;
3879
3880mingw* | pw32*)
3881 # Base MSYS/MinGW do not provide the 'file' command needed by
3882 # func_win32_libid shell function, so use a weaker test based on 'objdump',
3883 # unless we find 'file', for example because we are cross-compiling.
3884 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
3885 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
3886 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3887 lt_cv_file_magic_cmd='func_win32_libid'
3888 else
3889 # Keep this pattern in sync with the one in func_win32_libid.
3890 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
3891 lt_cv_file_magic_cmd='$OBJDUMP -f'
3892 fi
3893 ;;
3894
3895cegcc*)
3896 # use the weaker test based on 'objdump'. See mingw*.
3897 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
3898 lt_cv_file_magic_cmd='$OBJDUMP -f'
3899 ;;
3900
3901darwin* | rhapsody*)
3902 lt_cv_deplibs_check_method=pass_all
3903 ;;
3904
3905freebsd* | dragonfly*)
3906 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3907 case $host_cpu in
3908 i*86 )
3909 # Not sure whether the presence of OpenBSD here was a mistake.
3910 # Let's accept both of them until this is cleared up.
3911 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3912 lt_cv_file_magic_cmd=/usr/bin/file
3913 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3914 ;;
3915 esac
3916 else
3917 lt_cv_deplibs_check_method=pass_all
3918 fi
3919 ;;
3920
3921haiku*)
3922 lt_cv_deplibs_check_method=pass_all
3923 ;;
3924
3925hpux10.20* | hpux11*)
3926 lt_cv_file_magic_cmd=/usr/bin/file
3927 case $host_cpu in
3928 ia64*)
3929 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3930 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3931 ;;
3932 hppa*64*)
3933 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
3934 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3935 ;;
3936 *)
3937 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
3938 lt_cv_file_magic_test_file=/usr/lib/libc.sl
3939 ;;
3940 esac
3941 ;;
3942
3943interix[[3-9]]*)
3944 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3945 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3946 ;;
3947
3948irix5* | irix6* | nonstopux*)
3949 case $LD in
3950 *-32|*"-32 ") libmagic=32-bit;;
3951 *-n32|*"-n32 ") libmagic=N32;;
3952 *-64|*"-64 ") libmagic=64-bit;;
3953 *) libmagic=never-match;;
3954 esac
3955 lt_cv_deplibs_check_method=pass_all
3956 ;;
3957
3958# This must be glibc/ELF.
3959linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
3960 lt_cv_deplibs_check_method=pass_all
3961 ;;
3962
3963netbsd* | netbsdelf*-gnu)
3964 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
3965 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3966 else
3967 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3968 fi
3969 ;;
3970
3971newos6*)
3972 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3973 lt_cv_file_magic_cmd=/usr/bin/file
3974 lt_cv_file_magic_test_file=/usr/lib/libnls.so
3975 ;;
3976
3977*nto* | *qnx*)
3978 lt_cv_deplibs_check_method=pass_all
3979 ;;
3980
3981openbsd*)
3982 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3983 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3984 else
3985 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3986 fi
3987 ;;
3988
3989osf3* | osf4* | osf5*)
3990 lt_cv_deplibs_check_method=pass_all
3991 ;;
3992
3993rdos*)
3994 lt_cv_deplibs_check_method=pass_all
3995 ;;
3996
3997solaris*)
3998 lt_cv_deplibs_check_method=pass_all
3999 ;;
4000
4001sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
4002 lt_cv_deplibs_check_method=pass_all
4003 ;;
4004
4005sysv4 | sysv4.3*)
4006 case $host_vendor in
4007 motorola)
4008 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]]'
4009 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
4010 ;;
4011 ncr)
4012 lt_cv_deplibs_check_method=pass_all
4013 ;;
4014 sequent)
4015 lt_cv_file_magic_cmd='/bin/file'
4016 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
4017 ;;
4018 sni)
4019 lt_cv_file_magic_cmd='/bin/file'
4020 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
4021 lt_cv_file_magic_test_file=/lib/libc.so
4022 ;;
4023 siemens)
4024 lt_cv_deplibs_check_method=pass_all
4025 ;;
4026 pc)
4027 lt_cv_deplibs_check_method=pass_all
4028 ;;
4029 esac
4030 ;;
4031
4032tpf*)
4033 lt_cv_deplibs_check_method=pass_all
4034 ;;
4035esac
4036])
4037
4038file_magic_glob=
4039want_nocaseglob=no
4040if test "$build" = "$host"; then
4041 case $host_os in