Develop and Download Open Source Software

Browse CVS Repository

Contents of /gticker/gticker/aclocal.m4

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1.1.1 - (show annotations) (download) (vendor branch)
Mon Aug 15 06:50:46 2005 UTC (18 years, 7 months ago) by bluedwarf
Branch: MAIN, bluedwarf
CVS Tags: start, HEAD
Changes since 1.1: +0 -0 lines
Initial import of gticker

1 # generated automatically by aclocal 1.9.5 -*- Autoconf -*-
2
3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
4 # 2005 Free Software Foundation, Inc.
5 # This file is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 dnl AM_GCONF_SOURCE_2
15 dnl Defines GCONF_SCHEMA_CONFIG_SOURCE which is where you should install schemas
16 dnl (i.e. pass to gconftool-2
17 dnl Defines GCONF_SCHEMA_FILE_DIR which is a filesystem directory where
18 dnl you should install foo.schemas files
19 dnl
20
21 AC_DEFUN([AM_GCONF_SOURCE_2],
22 [
23 if test "x$GCONF_SCHEMA_INSTALL_SOURCE" = "x"; then
24 GCONF_SCHEMA_CONFIG_SOURCE=`gconftool-2 --get-default-source`
25 else
26 GCONF_SCHEMA_CONFIG_SOURCE=$GCONF_SCHEMA_INSTALL_SOURCE
27 fi
28
29 AC_ARG_WITH(gconf-source,
30 [ --with-gconf-source=sourceaddress Config database for installing schema files.],GCONF_SCHEMA_CONFIG_SOURCE="$withval",)
31
32 AC_SUBST(GCONF_SCHEMA_CONFIG_SOURCE)
33 AC_MSG_RESULT([Using config source $GCONF_SCHEMA_CONFIG_SOURCE for schema installation])
34
35 if test "x$GCONF_SCHEMA_FILE_DIR" = "x"; then
36 GCONF_SCHEMA_FILE_DIR='$(sysconfdir)/gconf/schemas'
37 fi
38
39 AC_ARG_WITH(gconf-schema-file-dir,
40 [ --with-gconf-schema-file-dir=dir Directory for installing schema files.],GCONF_SCHEMA_FILE_DIR="$withval",)
41
42 AC_SUBST(GCONF_SCHEMA_FILE_DIR)
43 AC_MSG_RESULT([Using $GCONF_SCHEMA_FILE_DIR as install directory for schema files])
44
45 AC_ARG_ENABLE(schemas-install,
46 [ --disable-schemas-install Disable the schemas installation],
47 [case "${enableval}" in
48 yes) schemas_install=true ;;
49 no) schemas_install=false ;;
50 *) AC_MSG_ERROR(bad value ${enableval} for --disable-schemas-install) ;;
51 esac],[schemas_install=true])
52 AM_CONDITIONAL(GCONF_SCHEMAS_INSTALL, test x$schemas_install = xtrue)
53 ])
54
55 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
56
57 # serial 47 AC_PROG_LIBTOOL
58
59
60 # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
61 # -----------------------------------------------------------
62 # If this macro is not defined by Autoconf, define it here.
63 m4_ifdef([AC_PROVIDE_IFELSE],
64 [],
65 [m4_define([AC_PROVIDE_IFELSE],
66 [m4_ifdef([AC_PROVIDE_$1],
67 [$2], [$3])])])
68
69
70 # AC_PROG_LIBTOOL
71 # ---------------
72 AC_DEFUN([AC_PROG_LIBTOOL],
73 [AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
74 dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
75 dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
76 AC_PROVIDE_IFELSE([AC_PROG_CXX],
77 [AC_LIBTOOL_CXX],
78 [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
79 ])])
80 dnl And a similar setup for Fortran 77 support
81 AC_PROVIDE_IFELSE([AC_PROG_F77],
82 [AC_LIBTOOL_F77],
83 [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
84 ])])
85
86 dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
87 dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
88 dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
89 AC_PROVIDE_IFELSE([AC_PROG_GCJ],
90 [AC_LIBTOOL_GCJ],
91 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
92 [AC_LIBTOOL_GCJ],
93 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
94 [AC_LIBTOOL_GCJ],
95 [ifdef([AC_PROG_GCJ],
96 [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
97 ifdef([A][M_PROG_GCJ],
98 [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
99 ifdef([LT_AC_PROG_GCJ],
100 [define([LT_AC_PROG_GCJ],
101 defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
102 ])])# AC_PROG_LIBTOOL
103
104
105 # _AC_PROG_LIBTOOL
106 # ----------------
107 AC_DEFUN([_AC_PROG_LIBTOOL],
108 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
109 AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
110 AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
111 AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
112
113 # This can be used to rebuild libtool when needed
114 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
115
116 # Always use our own libtool.
117 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
118 AC_SUBST(LIBTOOL)dnl
119
120 # Prevent multiple expansion
121 define([AC_PROG_LIBTOOL], [])
122 ])# _AC_PROG_LIBTOOL
123
124
125 # AC_LIBTOOL_SETUP
126 # ----------------
127 AC_DEFUN([AC_LIBTOOL_SETUP],
128 [AC_PREREQ(2.50)dnl
129 AC_REQUIRE([AC_ENABLE_SHARED])dnl
130 AC_REQUIRE([AC_ENABLE_STATIC])dnl
131 AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
132 AC_REQUIRE([AC_CANONICAL_HOST])dnl
133 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
134 AC_REQUIRE([AC_PROG_CC])dnl
135 AC_REQUIRE([AC_PROG_LD])dnl
136 AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
137 AC_REQUIRE([AC_PROG_NM])dnl
138
139 AC_REQUIRE([AC_PROG_LN_S])dnl
140 AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
141 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
142 AC_REQUIRE([AC_OBJEXT])dnl
143 AC_REQUIRE([AC_EXEEXT])dnl
144 dnl
145
146 AC_LIBTOOL_SYS_MAX_CMD_LEN
147 AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
148 AC_LIBTOOL_OBJDIR
149
150 AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
151 _LT_AC_PROG_ECHO_BACKSLASH
152
153 case $host_os in
154 aix3*)
155 # AIX sometimes has problems with the GCC collect2 program. For some
156 # reason, if we set the COLLECT_NAMES environment variable, the problems
157 # vanish in a puff of smoke.
158 if test "X${COLLECT_NAMES+set}" != Xset; then
159 COLLECT_NAMES=
160 export COLLECT_NAMES
161 fi
162 ;;
163 esac
164
165 # Sed substitution that helps us do robust quoting. It backslashifies
166 # metacharacters that are still active within double-quoted strings.
167 Xsed='sed -e 1s/^X//'
168 [sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
169
170 # Same as above, but do not quote variable references.
171 [double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
172
173 # Sed substitution to delay expansion of an escaped shell variable in a
174 # double_quote_subst'ed string.
175 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
176
177 # Sed substitution to avoid accidental globbing in evaled expressions
178 no_glob_subst='s/\*/\\\*/g'
179
180 # Constants:
181 rm="rm -f"
182
183 # Global variables:
184 default_ofile=libtool
185 can_build_shared=yes
186
187 # All known linkers require a `.a' archive for static linking (except M$VC,
188 # which needs '.lib').
189 libext=a
190 ltmain="$ac_aux_dir/ltmain.sh"
191 ofile="$default_ofile"
192 with_gnu_ld="$lt_cv_prog_gnu_ld"
193
194 AC_CHECK_TOOL(AR, ar, false)
195 AC_CHECK_TOOL(RANLIB, ranlib, :)
196 AC_CHECK_TOOL(STRIP, strip, :)
197
198 old_CC="$CC"
199 old_CFLAGS="$CFLAGS"
200
201 # Set sane defaults for various variables
202 test -z "$AR" && AR=ar
203 test -z "$AR_FLAGS" && AR_FLAGS=cru
204 test -z "$AS" && AS=as
205 test -z "$CC" && CC=cc
206 test -z "$LTCC" && LTCC=$CC
207 test -z "$DLLTOOL" && DLLTOOL=dlltool
208 test -z "$LD" && LD=ld
209 test -z "$LN_S" && LN_S="ln -s"
210 test -z "$MAGIC_CMD" && MAGIC_CMD=file
211 test -z "$NM" && NM=nm
212 test -z "$SED" && SED=sed
213 test -z "$OBJDUMP" && OBJDUMP=objdump
214 test -z "$RANLIB" && RANLIB=:
215 test -z "$STRIP" && STRIP=:
216 test -z "$ac_objext" && ac_objext=o
217
218 # Determine commands to create old-style static archives.
219 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
220 old_postinstall_cmds='chmod 644 $oldlib'
221 old_postuninstall_cmds=
222
223 if test -n "$RANLIB"; then
224 case $host_os in
225 openbsd*)
226 old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
227 ;;
228 *)
229 old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
230 ;;
231 esac
232 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
233 fi
234
235 _LT_CC_BASENAME([$compiler])
236
237 # Only perform the check for file, if the check method requires it
238 case $deplibs_check_method in
239 file_magic*)
240 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
241 AC_PATH_MAGIC
242 fi
243 ;;
244 esac
245
246 AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
247 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
248 enable_win32_dll=yes, enable_win32_dll=no)
249
250 AC_ARG_ENABLE([libtool-lock],
251 [AC_HELP_STRING([--disable-libtool-lock],
252 [avoid locking (might break parallel builds)])])
253 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
254
255 AC_ARG_WITH([pic],
256 [AC_HELP_STRING([--with-pic],
257 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
258 [pic_mode="$withval"],
259 [pic_mode=default])
260 test -z "$pic_mode" && pic_mode=default
261
262 # Check if we have a version mismatch between libtool.m4 and ltmain.sh.
263 #
264 # Note: This should be in AC_LIBTOOL_SETUP, _after_ $ltmain have been defined.
265 # We also should do it _before_ AC_LIBTOOL_LANG_C_CONFIG that actually
266 # calls AC_LIBTOOL_CONFIG and creates libtool.
267 #
268 _LT_VERSION_CHECK
269
270 # Use C for the default configuration in the libtool script
271 tagname=
272 AC_LIBTOOL_LANG_C_CONFIG
273 _LT_AC_TAGCONFIG
274 ])# AC_LIBTOOL_SETUP
275
276
277 # _LT_VERSION_CHECK
278 # -----------------
279 AC_DEFUN([_LT_VERSION_CHECK],
280 [AC_MSG_CHECKING([for correct ltmain.sh version])
281 if test -z "$ltmain"; then
282 AC_MSG_RESULT(no)
283 echo
284 echo "*** [Gentoo] sanity check failed! ***"
285 echo "*** \$ltmain is not defined, please check the patch for consistency! ***"
286 echo
287 exit 1
288 fi
289 gentoo_lt_version="1.5.18"
290 gentoo_ltmain_version=`grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||'`
291 if test "$gentoo_lt_version" != "$gentoo_ltmain_version"; then
292 AC_MSG_RESULT(no)
293 echo
294 echo "*** [Gentoo] sanity check failed! ***"
295 echo "*** libtool.m4 and ltmain.sh have a version mismatch! ***"
296 echo "*** (libtool.m4 = $gentoo_lt_version, ltmain.sh = $gentoo_ltmain_version) ***"
297 echo
298 echo "Please run:"
299 echo
300 echo " libtoolize --copy --force"
301 echo
302 echo "if appropriate, please contact the maintainer of this"
303 echo "package (or your distribution) for help."
304 echo
305 exit 1
306 else
307 AC_MSG_RESULT(yes)
308 fi
309 ])# _LT_VERSION_CHECK
310
311
312 # _LT_AC_SYS_COMPILER
313 # -------------------
314 AC_DEFUN([_LT_AC_SYS_COMPILER],
315 [AC_REQUIRE([AC_PROG_CC])dnl
316
317 # If no C compiler was specified, use CC.
318 LTCC=${LTCC-"$CC"}
319
320 # Allow CC to be a program name with arguments.
321 compiler=$CC
322 ])# _LT_AC_SYS_COMPILER
323
324
325 # _LT_CC_BASENAME(CC)
326 # -------------------
327 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
328 AC_DEFUN([_LT_CC_BASENAME],
329 [for cc_temp in $1""; do
330 case $cc_temp in
331 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
332 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
333 \-*) ;;
334 *) break;;
335 esac
336 done
337 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
338 ])
339
340
341 # _LT_COMPILER_BOILERPLATE
342 # ------------------------
343 # Check for compiler boilerplate output or warnings with
344 # the simple compiler test code.
345 AC_DEFUN([_LT_COMPILER_BOILERPLATE],
346 [ac_outfile=conftest.$ac_objext
347 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
348 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
349 _lt_compiler_boilerplate=`cat conftest.err`
350 $rm conftest*
351 ])# _LT_COMPILER_BOILERPLATE
352
353
354 # _LT_LINKER_BOILERPLATE
355 # ----------------------
356 # Check for linker boilerplate output or warnings with
357 # the simple link test code.
358 AC_DEFUN([_LT_LINKER_BOILERPLATE],
359 [ac_outfile=conftest.$ac_objext
360 printf "$lt_simple_link_test_code" >conftest.$ac_ext
361 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
362 _lt_linker_boilerplate=`cat conftest.err`
363 $rm conftest*
364 ])# _LT_LINKER_BOILERPLATE
365
366
367 # _LT_AC_SYS_LIBPATH_AIX
368 # ----------------------
369 # Links a minimal program and checks the executable
370 # for the system default hardcoded library path. In most cases,
371 # this is /usr/lib:/lib, but when the MPI compilers are used
372 # the location of the communication and MPI libs are included too.
373 # If we don't find anything, use the default library path according
374 # to the aix ld manual.
375 AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
376 [AC_LINK_IFELSE(AC_LANG_PROGRAM,[
377 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
378 }'`
379 # Check for a 64-bit object if we didn't find anything.
380 if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
381 }'`; fi],[])
382 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
383 ])# _LT_AC_SYS_LIBPATH_AIX
384
385
386 # _LT_AC_SHELL_INIT(ARG)
387 # ----------------------
388 AC_DEFUN([_LT_AC_SHELL_INIT],
389 [ifdef([AC_DIVERSION_NOTICE],
390 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
391 [AC_DIVERT_PUSH(NOTICE)])
392 $1
393 AC_DIVERT_POP
394 ])# _LT_AC_SHELL_INIT
395
396
397 # _LT_AC_PROG_ECHO_BACKSLASH
398 # --------------------------
399 # Add some code to the start of the generated configure script which
400 # will find an echo command which doesn't interpret backslashes.
401 AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
402 [_LT_AC_SHELL_INIT([
403 # Check that we are running under the correct shell.
404 SHELL=${CONFIG_SHELL-/bin/sh}
405
406 case X$ECHO in
407 X*--fallback-echo)
408 # Remove one level of quotation (which was required for Make).
409 ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
410 ;;
411 esac
412
413 echo=${ECHO-echo}
414 if test "X[$]1" = X--no-reexec; then
415 # Discard the --no-reexec flag, and continue.
416 shift
417 elif test "X[$]1" = X--fallback-echo; then
418 # Avoid inline document here, it may be left over
419 :
420 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
421 # Yippee, $echo works!
422 :
423 else
424 # Restart under the correct shell.
425 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
426 fi
427
428 if test "X[$]1" = X--fallback-echo; then
429 # used as fallback echo
430 shift
431 cat <<EOF
432 [$]*
433 EOF
434 exit 0
435 fi
436
437 # The HP-UX ksh and POSIX shell print the target directory to stdout
438 # if CDPATH is set.
439 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
440
441 if test -z "$ECHO"; then
442 if test "X${echo_test_string+set}" != Xset; then
443 # find a string as large as possible, as long as the shell can cope with it
444 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
445 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
446 if (echo_test_string="`eval $cmd`") 2>/dev/null &&
447 echo_test_string="`eval $cmd`" &&
448 (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
449 then
450 break
451 fi
452 done
453 fi
454
455 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
456 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
457 test "X$echo_testing_string" = "X$echo_test_string"; then
458 :
459 else
460 # The Solaris, AIX, and Digital Unix default echo programs unquote
461 # backslashes. This makes it impossible to quote backslashes using
462 # echo "$something" | sed 's/\\/\\\\/g'
463 #
464 # So, first we look for a working echo in the user's PATH.
465
466 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
467 for dir in $PATH /usr/ucb; do
468 IFS="$lt_save_ifs"
469 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
470 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
471 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
472 test "X$echo_testing_string" = "X$echo_test_string"; then
473 echo="$dir/echo"
474 break
475 fi
476 done
477 IFS="$lt_save_ifs"
478
479 if test "X$echo" = Xecho; then
480 # We didn't find a better echo, so look for alternatives.
481 if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
482 echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
483 test "X$echo_testing_string" = "X$echo_test_string"; then
484 # This shell has a builtin print -r that does the trick.
485 echo='print -r'
486 elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
487 test "X$CONFIG_SHELL" != X/bin/ksh; then
488 # If we have ksh, try running configure again with it.
489 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
490 export ORIGINAL_CONFIG_SHELL
491 CONFIG_SHELL=/bin/ksh
492 export CONFIG_SHELL
493 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
494 else
495 # Try using printf.
496 echo='printf %s\n'
497 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
498 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
499 test "X$echo_testing_string" = "X$echo_test_string"; then
500 # Cool, printf works
501 :
502 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
503 test "X$echo_testing_string" = 'X\t' &&
504 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
505 test "X$echo_testing_string" = "X$echo_test_string"; then
506 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
507 export CONFIG_SHELL
508 SHELL="$CONFIG_SHELL"
509 export SHELL
510 echo="$CONFIG_SHELL [$]0 --fallback-echo"
511 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
512 test "X$echo_testing_string" = 'X\t' &&
513 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
514 test "X$echo_testing_string" = "X$echo_test_string"; then
515 echo="$CONFIG_SHELL [$]0 --fallback-echo"
516 else
517 # maybe with a smaller string...
518 prev=:
519
520 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
521 if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
522 then
523 break
524 fi
525 prev="$cmd"
526 done
527
528 if test "$prev" != 'sed 50q "[$]0"'; then
529 echo_test_string=`eval $prev`
530 export echo_test_string
531 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
532 else
533 # Oops. We lost completely, so just stick with echo.
534 echo=echo
535 fi
536 fi
537 fi
538 fi
539 fi
540 fi
541
542 # Copy echo and quote the copy suitably for passing to libtool from
543 # the Makefile, instead of quoting the original, which is used later.
544 ECHO=$echo
545 if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
546 ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
547 fi
548
549 AC_SUBST(ECHO)
550 ])])# _LT_AC_PROG_ECHO_BACKSLASH
551
552
553 # _LT_AC_LOCK
554 # -----------
555 AC_DEFUN([_LT_AC_LOCK],
556 [AC_ARG_ENABLE([libtool-lock],
557 [AC_HELP_STRING([--disable-libtool-lock],
558 [avoid locking (might break parallel builds)])])
559 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
560
561 # Some flags need to be propagated to the compiler or linker for good
562 # libtool support.
563 case $host in
564 ia64-*-hpux*)
565 # Find out which ABI we are using.
566 echo 'int i;' > conftest.$ac_ext
567 if AC_TRY_EVAL(ac_compile); then
568 case `/usr/bin/file conftest.$ac_objext` in
569 *ELF-32*)
570 HPUX_IA64_MODE="32"
571 ;;
572 *ELF-64*)
573 HPUX_IA64_MODE="64"
574 ;;
575 esac
576 fi
577 rm -rf conftest*
578 ;;
579 *-*-irix6*)
580 # Find out which ABI we are using.
581 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
582 if AC_TRY_EVAL(ac_compile); then
583 if test "$lt_cv_prog_gnu_ld" = yes; then
584 case `/usr/bin/file conftest.$ac_objext` in
585 *32-bit*)
586 LD="${LD-ld} -melf32bsmip"
587 ;;
588 *N32*)
589 LD="${LD-ld} -melf32bmipn32"
590 ;;
591 *64-bit*)
592 LD="${LD-ld} -melf64bmip"
593 ;;
594 esac
595 else
596 case `/usr/bin/file conftest.$ac_objext` in
597 *32-bit*)
598 LD="${LD-ld} -32"
599 ;;
600 *N32*)
601 LD="${LD-ld} -n32"
602 ;;
603 *64-bit*)
604 LD="${LD-ld} -64"
605 ;;
606 esac
607 fi
608 fi
609 rm -rf conftest*
610 ;;
611
612 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
613 # Find out which ABI we are using.
614 echo 'int i;' > conftest.$ac_ext
615 if AC_TRY_EVAL(ac_compile); then
616 case "`/usr/bin/file conftest.o`" in
617 *32-bit*)
618 case $host in
619 x86_64-*linux*)
620 LD="${LD-ld} -m elf_i386"
621 ;;
622 ppc64-*linux*|powerpc64-*linux*)
623 LD="${LD-ld} -m elf32ppclinux"
624 ;;
625 s390x-*linux*)
626 LD="${LD-ld} -m elf_s390"
627 ;;
628 sparc64-*linux*)
629 LD="${LD-ld} -m elf32_sparc"
630 ;;
631 esac
632 ;;
633 *64-bit*)
634 case $host in
635 x86_64-*linux*)
636 LD="${LD-ld} -m elf_x86_64"
637 ;;
638 ppc*-*linux*|powerpc*-*linux*)
639 LD="${LD-ld} -m elf64ppc"
640 ;;
641 s390*-*linux*)
642 LD="${LD-ld} -m elf64_s390"
643 ;;
644 sparc*-*linux*)
645 LD="${LD-ld} -m elf64_sparc"
646 ;;
647 esac
648 ;;
649 esac
650 fi
651 rm -rf conftest*
652 ;;
653
654 *-*-linux*)
655 # Test if the compiler is 64bit
656 echo 'int i;' > conftest.$ac_ext
657 lt_cv_cc_64bit_output=no
658 if AC_TRY_EVAL(ac_compile); then
659 case `/usr/bin/file conftest.$ac_objext` in
660 *"ELF 64"*)
661 lt_cv_cc_64bit_output=yes
662 ;;
663 esac
664 fi
665 rm -rf conftest*
666 ;;
667
668 *-*-sco3.2v5*)
669 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
670 SAVE_CFLAGS="$CFLAGS"
671 CFLAGS="$CFLAGS -belf"
672 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
673 [AC_LANG_PUSH(C)
674 AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
675 AC_LANG_POP])
676 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
677 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
678 CFLAGS="$SAVE_CFLAGS"
679 fi
680 ;;
681 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
682 [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
683 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
684 AC_CHECK_TOOL(AS, as, false)
685 AC_CHECK_TOOL(OBJDUMP, objdump, false)
686 ;;
687 ])
688 esac
689
690 need_locks="$enable_libtool_lock"
691
692 ])# _LT_AC_LOCK
693
694
695 # AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
696 # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
697 # ----------------------------------------------------------------
698 # Check whether the given compiler option works
699 AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
700 [AC_REQUIRE([LT_AC_PROG_SED])
701 AC_CACHE_CHECK([$1], [$2],
702 [$2=no
703 ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
704 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
705 lt_compiler_flag="$3"
706 # Insert the option either (1) after the last *FLAGS variable, or
707 # (2) before a word containing "conftest.", or (3) at the end.
708 # Note that $ac_compile itself does not contain backslashes and begins
709 # with a dollar sign (not a hyphen), so the echo should work correctly.
710 # The option is referenced via a variable to avoid confusing sed.
711 lt_compile=`echo "$ac_compile" | $SED \
712 -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
713 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
714 -e 's:$: $lt_compiler_flag:'`
715 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
716 (eval "$lt_compile" 2>conftest.err)
717 ac_status=$?
718 cat conftest.err >&AS_MESSAGE_LOG_FD
719 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
720 if (exit $ac_status) && test -s "$ac_outfile"; then
721 # The compiler can only warn and ignore the option if not recognized
722 # So say no if there are warnings other than the usual output.
723 $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
724 $SED '/^$/d' conftest.err >conftest.er2
725 if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
726 $2=yes
727 fi
728 fi
729 $rm conftest*
730 ])
731
732 if test x"[$]$2" = xyes; then
733 ifelse([$5], , :, [$5])
734 else
735 ifelse([$6], , :, [$6])
736 fi
737 ])# AC_LIBTOOL_COMPILER_OPTION
738
739
740 # AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
741 # [ACTION-SUCCESS], [ACTION-FAILURE])
742 # ------------------------------------------------------------
743 # Check whether the given compiler option works
744 AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
745 [AC_CACHE_CHECK([$1], [$2],
746 [$2=no
747 save_LDFLAGS="$LDFLAGS"
748 LDFLAGS="$LDFLAGS $3"
749 printf "$lt_simple_link_test_code" > conftest.$ac_ext
750 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
751 # The compiler can only warn and ignore the option if not recognized
752 # So say no if there are warnings
753 if test -s conftest.err; then
754 # Append any errors to the config.log.
755 cat conftest.err 1>&AS_MESSAGE_LOG_FD
756 $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
757 $SED '/^$/d' conftest.err >conftest.er2
758 if diff conftest.exp conftest.er2 >/dev/null; then
759 $2=yes
760 fi
761 else
762 $2=yes
763 fi
764 fi
765 $rm conftest*
766 LDFLAGS="$save_LDFLAGS"
767 ])
768
769 if test x"[$]$2" = xyes; then
770 ifelse([$4], , :, [$4])
771 else
772 ifelse([$5], , :, [$5])
773 fi
774 ])# AC_LIBTOOL_LINKER_OPTION
775
776
777 # AC_LIBTOOL_SYS_MAX_CMD_LEN
778 # --------------------------
779 AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
780 [# find the maximum length of command line arguments
781 AC_MSG_CHECKING([the maximum length of command line arguments])
782 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
783 i=0
784 teststring="ABCD"
785
786 case $build_os in
787 msdosdjgpp*)
788 # On DJGPP, this test can blow up pretty badly due to problems in libc
789 # (any single argument exceeding 2000 bytes causes a buffer overrun
790 # during glob expansion). Even if it were fixed, the result of this
791 # check would be larger than it should be.
792 lt_cv_sys_max_cmd_len=12288; # 12K is about right
793 ;;
794
795 gnu*)
796 # Under GNU Hurd, this test is not required because there is
797 # no limit to the length of command line arguments.
798 # Libtool will interpret -1 as no limit whatsoever
799 lt_cv_sys_max_cmd_len=-1;
800 ;;
801
802 cygwin* | mingw*)
803 # On Win9x/ME, this test blows up -- it succeeds, but takes
804 # about 5 minutes as the teststring grows exponentially.
805 # Worse, since 9x/ME are not pre-emptively multitasking,
806 # you end up with a "frozen" computer, even though with patience
807 # the test eventually succeeds (with a max line length of 256k).
808 # Instead, let's just punt: use the minimum linelength reported by
809 # all of the supported platforms: 8192 (on NT/2K/XP).
810 lt_cv_sys_max_cmd_len=8192;
811 ;;
812
813 amigaos*)
814 # On AmigaOS with pdksh, this test takes hours, literally.
815 # So we just punt and use a minimum line length of 8192.
816 lt_cv_sys_max_cmd_len=8192;
817 ;;
818
819 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
820 # This has been around since 386BSD, at least. Likely further.
821 if test -x /sbin/sysctl; then
822 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
823 elif test -x /usr/sbin/sysctl; then
824 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
825 else
826 lt_cv_sys_max_cmd_len=65536 # usable default for *BSD
827 fi
828 # And add a safety zone
829 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
830 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
831 ;;
832 osf*)
833 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
834 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
835 # nice to cause kernel panics so lets avoid the loop below.
836 # First set a reasonable default.
837 lt_cv_sys_max_cmd_len=16384
838 #
839 if test -x /sbin/sysconfig; then
840 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
841 *1*) lt_cv_sys_max_cmd_len=-1 ;;
842 esac
843 fi
844 ;;
845 *)
846 # If test is not a shell built-in, we'll probably end up computing a
847 # maximum length that is only half of the actual maximum length, but
848 # we can't tell.
849 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
850 while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
851 = "XX$teststring") >/dev/null 2>&1 &&
852 new_result=`expr "X$teststring" : ".*" 2>&1` &&
853 lt_cv_sys_max_cmd_len=$new_result &&
854 test $i != 17 # 1/2 MB should be enough
855 do
856 i=`expr $i + 1`
857 teststring=$teststring$teststring
858 done
859 teststring=
860 # Add a significant safety factor because C++ compilers can tack on massive
861 # amounts of additional arguments before passing them to the linker.
862 # It appears as though 1/2 is a usable value.
863 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
864 ;;
865 esac
866 ])
867 if test -n $lt_cv_sys_max_cmd_len ; then
868 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
869 else
870 AC_MSG_RESULT(none)
871 fi
872 ])# AC_LIBTOOL_SYS_MAX_CMD_LEN
873
874
875 # _LT_AC_CHECK_DLFCN
876 # --------------------
877 AC_DEFUN([_LT_AC_CHECK_DLFCN],
878 [AC_CHECK_HEADERS(dlfcn.h)dnl
879 ])# _LT_AC_CHECK_DLFCN
880
881
882 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
883 # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
884 # ------------------------------------------------------------------
885 AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
886 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
887 if test "$cross_compiling" = yes; then :
888 [$4]
889 else
890 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
891 lt_status=$lt_dlunknown
892 cat > conftest.$ac_ext <<EOF
893 [#line __oline__ "configure"
894 #include "confdefs.h"
895
896 #if HAVE_DLFCN_H
897 #include <dlfcn.h>
898 #endif
899
900 #include <stdio.h>
901
902 #ifdef RTLD_GLOBAL
903 # define LT_DLGLOBAL RTLD_GLOBAL
904 #else
905 # ifdef DL_GLOBAL
906 # define LT_DLGLOBAL DL_GLOBAL
907 # else
908 # define LT_DLGLOBAL 0
909 # endif
910 #endif
911
912 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
913 find out it does not work in some platform. */
914 #ifndef LT_DLLAZY_OR_NOW
915 # ifdef RTLD_LAZY
916 # define LT_DLLAZY_OR_NOW RTLD_LAZY
917 # else
918 # ifdef DL_LAZY
919 # define LT_DLLAZY_OR_NOW DL_LAZY
920 # else
921 # ifdef RTLD_NOW
922 # define LT_DLLAZY_OR_NOW RTLD_NOW
923 # else
924 # ifdef DL_NOW
925 # define LT_DLLAZY_OR_NOW DL_NOW
926 # else
927 # define LT_DLLAZY_OR_NOW 0
928 # endif
929 # endif
930 # endif
931 # endif
932 #endif
933
934 #ifdef __cplusplus
935 extern "C" void exit (int);
936 #endif
937
938 void fnord() { int i=42;}
939 int main ()
940 {
941 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
942 int status = $lt_dlunknown;
943
944 if (self)
945 {
946 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
947 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
948 /* dlclose (self); */
949 }
950
951 exit (status);
952 }]
953 EOF
954 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
955 (./conftest; exit; ) 2>/dev/null
956 lt_status=$?
957 case x$lt_status in
958 x$lt_dlno_uscore) $1 ;;
959 x$lt_dlneed_uscore) $2 ;;
960 x$lt_unknown|x*) $3 ;;
961 esac
962 else :
963 # compilation failed
964 $3
965 fi
966 fi
967 rm -fr conftest*
968 ])# _LT_AC_TRY_DLOPEN_SELF
969
970
971 # AC_LIBTOOL_DLOPEN_SELF
972 # -------------------
973 AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
974 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
975 if test "x$enable_dlopen" != xyes; then
976 enable_dlopen=unknown
977 enable_dlopen_self=unknown
978 enable_dlopen_self_static=unknown
979 else
980 lt_cv_dlopen=no
981 lt_cv_dlopen_libs=
982
983 case $host_os in
984 beos*)
985 lt_cv_dlopen="load_add_on"
986 lt_cv_dlopen_libs=
987 lt_cv_dlopen_self=yes
988 ;;
989
990 mingw* | pw32*)
991 lt_cv_dlopen="LoadLibrary"
992 lt_cv_dlopen_libs=
993 ;;
994
995 cygwin*)
996 lt_cv_dlopen="dlopen"
997 lt_cv_dlopen_libs=
998 ;;
999
1000 darwin*)
1001 # if libdl is installed we need to link against it
1002 AC_CHECK_LIB([dl], [dlopen],
1003 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1004 lt_cv_dlopen="dyld"
1005 lt_cv_dlopen_libs=
1006 lt_cv_dlopen_self=yes
1007 ])
1008 ;;
1009
1010 *)
1011 AC_CHECK_FUNC([shl_load],
1012 [lt_cv_dlopen="shl_load"],
1013 [AC_CHECK_LIB([dld], [shl_load],
1014 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
1015 [AC_CHECK_FUNC([dlopen],
1016 [lt_cv_dlopen="dlopen"],
1017 [AC_CHECK_LIB([dl], [dlopen],
1018 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1019 [AC_CHECK_LIB([svld], [dlopen],
1020 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1021 [AC_CHECK_LIB([dld], [dld_link],
1022 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
1023 ])
1024 ])
1025 ])
1026 ])
1027 ])
1028 ;;
1029 esac
1030
1031 if test "x$lt_cv_dlopen" != xno; then
1032 enable_dlopen=yes
1033 else
1034 enable_dlopen=no
1035 fi
1036
1037 case $lt_cv_dlopen in
1038 dlopen)
1039 save_CPPFLAGS="$CPPFLAGS"
1040 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1041
1042 save_LDFLAGS="$LDFLAGS"
1043 eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1044
1045 save_LIBS="$LIBS"
1046 LIBS="$lt_cv_dlopen_libs $LIBS"
1047
1048 AC_CACHE_CHECK([whether a program can dlopen itself],
1049 lt_cv_dlopen_self, [dnl
1050 _LT_AC_TRY_DLOPEN_SELF(
1051 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
1052 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
1053 ])
1054
1055 if test "x$lt_cv_dlopen_self" = xyes; then
1056 LDFLAGS="$LDFLAGS $link_static_flag"
1057 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
1058 lt_cv_dlopen_self_static, [dnl
1059 _LT_AC_TRY_DLOPEN_SELF(
1060 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
1061 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
1062 ])
1063 fi
1064
1065 CPPFLAGS="$save_CPPFLAGS"
1066 LDFLAGS="$save_LDFLAGS"
1067 LIBS="$save_LIBS"
1068 ;;
1069 esac
1070
1071 case $lt_cv_dlopen_self in
1072 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
1073 *) enable_dlopen_self=unknown ;;
1074 esac
1075
1076 case $lt_cv_dlopen_self_static in
1077 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
1078 *) enable_dlopen_self_static=unknown ;;
1079 esac
1080 fi
1081 ])# AC_LIBTOOL_DLOPEN_SELF
1082
1083
1084 # AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
1085 # ---------------------------------
1086 # Check to see if options -c and -o are simultaneously supported by compiler
1087 AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
1088 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1089 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
1090 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
1091 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
1092 $rm -r conftest 2>/dev/null
1093 mkdir conftest
1094 cd conftest
1095 mkdir out
1096 printf "$lt_simple_compile_test_code" > conftest.$ac_ext
1097
1098 lt_compiler_flag="-o out/conftest2.$ac_objext"
1099 # Insert the option either (1) after the last *FLAGS variable, or
1100 # (2) before a word containing "conftest.", or (3) at the end.
1101 # Note that $ac_compile itself does not contain backslashes and begins
1102 # with a dollar sign (not a hyphen), so the echo should work correctly.
1103 lt_compile=`echo "$ac_compile" | $SED \
1104 -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
1105 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1106 -e 's:$: $lt_compiler_flag:'`
1107 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1108 (eval "$lt_compile" 2>out/conftest.err)
1109 ac_status=$?
1110 cat out/conftest.err >&AS_MESSAGE_LOG_FD
1111 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1112 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1113 then
1114 # The compiler can only warn and ignore the option if not recognized
1115 # So say no if there are warnings
1116 $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
1117 $SED '/^$/d' out/conftest.err >out/conftest.er2
1118 if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
1119 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
1120 fi
1121 fi
1122 chmod u+w .
1123 $rm conftest*
1124 # SGI C++ compiler will create directory out/ii_files/ for
1125 # template instantiation
1126 test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
1127 $rm out/* && rmdir out
1128 cd ..
1129 rmdir conftest
1130 $rm conftest*
1131 ])
1132 ])# AC_LIBTOOL_PROG_CC_C_O
1133
1134
1135 # AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
1136 # -----------------------------------------
1137 # Check to see if we can do hard links to lock some files if needed
1138 AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
1139 [AC_REQUIRE([_LT_AC_LOCK])dnl
1140
1141 hard_links="nottested"
1142 if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
1143 # do not overwrite the value of need_locks provided by the user
1144 AC_MSG_CHECKING([if we can lock with hard links])
1145 hard_links=yes
1146 $rm conftest*
1147 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1148 touch conftest.a
1149 ln conftest.a conftest.b 2>&5 || hard_links=no
1150 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1151 AC_MSG_RESULT([$hard_links])
1152 if test "$hard_links" = no; then
1153 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
1154 need_locks=warn
1155 fi
1156 else
1157 need_locks=no
1158 fi
1159 ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
1160
1161
1162 # AC_LIBTOOL_OBJDIR
1163 # -----------------
1164 AC_DEFUN([AC_LIBTOOL_OBJDIR],
1165 [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
1166 [rm -f .libs 2>/dev/null
1167 mkdir .libs 2>/dev/null
1168 if test -d .libs; then
1169 lt_cv_objdir=.libs
1170 else
1171 # MS-DOS does not allow filenames that begin with a dot.
1172 lt_cv_objdir=_libs
1173 fi
1174 rmdir .libs 2>/dev/null])
1175 objdir=$lt_cv_objdir
1176 ])# AC_LIBTOOL_OBJDIR
1177
1178
1179 # AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
1180 # ----------------------------------------------
1181 # Check hardcoding attributes.
1182 AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
1183 [AC_MSG_CHECKING([how to hardcode library paths into programs])
1184 _LT_AC_TAGVAR(hardcode_action, $1)=
1185 if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
1186 test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
1187 test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
1188
1189 # We can hardcode non-existant directories.
1190 if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
1191 # If the only mechanism to avoid hardcoding is shlibpath_var, we
1192 # have to relink, otherwise we might link with an installed library
1193 # when we should be linking with a yet-to-be-installed one
1194 ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
1195 test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
1196 # Linking always hardcodes the temporary library directory.
1197 _LT_AC_TAGVAR(hardcode_action, $1)=relink
1198 else
1199 # We can link without hardcoding, and we can hardcode nonexisting dirs.
1200 _LT_AC_TAGVAR(hardcode_action, $1)=immediate
1201 fi
1202 else
1203 # We cannot hardcode anything, or else we can only hardcode existing
1204 # directories.
1205 _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
1206 fi
1207 AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
1208
1209 if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
1210 # Fast installation is not supported
1211 enable_fast_install=no
1212 elif test "$shlibpath_overrides_runpath" = yes ||
1213 test "$enable_shared" = no; then
1214 # Fast installation is not necessary
1215 enable_fast_install=needless
1216 fi
1217 ])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
1218
1219
1220 # AC_LIBTOOL_SYS_LIB_STRIP
1221 # ------------------------
1222 AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
1223 [striplib=
1224 old_striplib=
1225 AC_MSG_CHECKING([whether stripping libraries is possible])
1226 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
1227 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
1228 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
1229 AC_MSG_RESULT([yes])
1230 else
1231 # FIXME - insert some real tests, host_os isn't really good enough
1232 case $host_os in
1233 darwin*)
1234 if test -n "$STRIP" ; then
1235 striplib="$STRIP -x"
1236 AC_MSG_RESULT([yes])
1237 else
1238 AC_MSG_RESULT([no])
1239 fi
1240 ;;
1241 *)
1242 AC_MSG_RESULT([no])
1243 ;;
1244 esac
1245 fi
1246 ])# AC_LIBTOOL_SYS_LIB_STRIP
1247
1248
1249 # AC_LIBTOOL_SYS_DYNAMIC_LINKER
1250 # -----------------------------
1251 # PORTME Fill in your ld.so characteristics
1252 AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
1253 [AC_MSG_CHECKING([dynamic linker characteristics])
1254 library_names_spec=
1255 libname_spec='lib$name'
1256 soname_spec=
1257 shrext_cmds=".so"
1258 postinstall_cmds=
1259 postuninstall_cmds=
1260 finish_cmds=
1261 finish_eval=
1262 shlibpath_var=
1263 shlibpath_overrides_runpath=unknown
1264 version_type=none
1265 dynamic_linker="$host_os ld.so"
1266 sys_lib_dlsearch_path_spec="/lib /usr/lib"
1267 if test "$GCC" = yes; then
1268 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1269 if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
1270 # if the path contains ";" then we assume it to be the separator
1271 # otherwise default to the standard path separator (i.e. ":") - it is
1272 # assumed that no part of a normal pathname contains ";" but that should
1273 # okay in the real world where ";" in dirpaths is itself problematic.
1274 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1275 else
1276 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1277 fi
1278 else
1279 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
1280 fi
1281 need_lib_prefix=unknown
1282 hardcode_into_libs=no
1283
1284 # when you set need_version to no, make sure it does not cause -set_version
1285 # flags to be left without arguments
1286 need_version=unknown
1287
1288 case $host_os in
1289 aix3*)
1290 version_type=linux
1291 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
1292 shlibpath_var=LIBPATH
1293
1294 # AIX 3 has no versioning support, so we append a major version to the name.
1295 soname_spec='${libname}${release}${shared_ext}$major'
1296 ;;
1297
1298 aix4* | aix5*)
1299 version_type=linux
1300 need_lib_prefix=no
1301 need_version=no
1302 hardcode_into_libs=yes
1303 if test "$host_cpu" = ia64; then
1304 # AIX 5 supports IA64
1305 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
1306 shlibpath_var=LD_LIBRARY_PATH
1307 else
1308 # With GCC up to 2.95.x, collect2 would create an import file
1309 # for dependence libraries. The import file would start with
1310 # the line `#! .'. This would cause the generated library to
1311 # depend on `.', always an invalid library. This was fixed in
1312 # development snapshots of GCC prior to 3.0.
1313 case $host_os in
1314 aix4 | aix4.[[01]] | aix4.[[01]].*)
1315 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
1316 echo ' yes '
1317 echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
1318 :
1319 else
1320 can_build_shared=no
1321 fi
1322 ;;
1323 esac
1324 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
1325 # soname into executable. Probably we can add versioning support to
1326 # collect2, so additional links can be useful in future.
1327 if test "$aix_use_runtimelinking" = yes; then
1328 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
1329 # instead of lib<name>.a to let people know that these are not
1330 # typical AIX shared libraries.
1331 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1332 else
1333 # We preserve .a as extension for shared libraries through AIX4.2
1334 # and later when we are not doing run time linking.
1335 library_names_spec='${libname}${release}.a $libname.a'
1336 soname_spec='${libname}${release}${shared_ext}$major'
1337 fi
1338 shlibpath_var=LIBPATH
1339 fi
1340 ;;
1341
1342 amigaos*)
1343 library_names_spec='$libname.ixlibrary $libname.a'
1344 # Create ${libname}_ixlibrary.a entries in /sys/libs.
1345 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
1346 ;;
1347
1348 beos*)
1349 library_names_spec='${libname}${shared_ext}'
1350 dynamic_linker="$host_os ld.so"
1351 shlibpath_var=LIBRARY_PATH
1352 ;;
1353
1354 bsdi[[45]]*)
1355 version_type=linux
1356 need_version=no
1357 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1358 soname_spec='${libname}${release}${shared_ext}$major'
1359 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
1360 shlibpath_var=LD_LIBRARY_PATH
1361 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
1362 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
1363 # the default ld.so.conf also contains /usr/contrib/lib and
1364 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
1365 # libtool to hard-code these into programs
1366 ;;
1367
1368 cygwin* | mingw* | pw32*)
1369 version_type=windows
1370 shrext_cmds=".dll"
1371 need_version=no
1372 need_lib_prefix=no
1373
1374 case $GCC,$host_os in
1375 yes,cygwin* | yes,mingw* | yes,pw32*)
1376 library_names_spec='$libname.dll.a'
1377 # DLL is installed to $(libdir)/../bin by postinstall_cmds
1378 postinstall_cmds='base_file=`basename \${file}`~
1379 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
1380 dldir=$destdir/`dirname \$dlpath`~
1381 test -d \$dldir || mkdir -p \$dldir~
1382 $install_prog $dir/$dlname \$dldir/$dlname'
1383 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
1384 dlpath=$dir/\$dldll~
1385 $rm \$dlpath'
1386 shlibpath_overrides_runpath=yes
1387
1388 case $host_os in
1389 cygwin*)
1390 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
1391 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1392 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
1393 ;;
1394 mingw*)
1395 # MinGW DLLs use traditional 'lib' prefix
1396 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1397 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
1398 if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
1399 # It is most probably a Windows format PATH printed by
1400 # mingw gcc, but we are running on Cygwin. Gcc prints its search
1401 # path with ; separators, and with drive letters. We can handle the
1402 # drive letters (cygwin fileutils understands them), so leave them,
1403 # especially as we might pass files found there to a mingw objdump,
1404 # which wouldn't understand a cygwinified path. Ahh.
1405 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1406 else
1407 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1408 fi
1409 ;;
1410 pw32*)
1411 # pw32 DLLs use 'pw' prefix rather than 'lib'
1412 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
1413 ;;
1414 esac
1415 ;;
1416
1417 linux*)
1418 if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
1419 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
1420 supports_anon_versioning=no
1421 case `$LD -v 2>/dev/null` in
1422 *\ [01].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
1423 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
1424 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
1425 *\ 2.11.*) ;; # other 2.11 versions
1426 *) supports_anon_versioning=yes ;;
1427 esac
1428 if test $supports_anon_versioning = yes; then
1429 archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
1430 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
1431 $echo "local: *; };" >> $output_objdir/$libname.ver~
1432 $CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
1433 else
1434 $archive_expsym_cmds="$archive_cmds"
1435 fi
1436 else
1437 ld_shlibs=no
1438 fi
1439 ;;
1440
1441 *)
1442 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
1443 ;;
1444 esac
1445 dynamic_linker='Win32 ld.exe'
1446 # FIXME: first we should search . and the directory the executable is in
1447 shlibpath_var=PATH
1448 ;;
1449
1450 darwin* | rhapsody*)
1451 dynamic_linker="$host_os dyld"
1452 version_type=darwin
1453 need_lib_prefix=no
1454 need_version=no
1455 library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
1456 soname_spec='${libname}${release}${major}$shared_ext'
1457 shlibpath_overrides_runpath=yes
1458 shlibpath_var=DYLD_LIBRARY_PATH
1459 shrext_cmds='$(test .$module = .yes && echo .so || echo .dylib)'
1460 # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
1461 if test "$GCC" = yes; then
1462 sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
1463 else
1464 sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
1465 fi
1466 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
1467 ;;
1468
1469 dgux*)
1470 version_type=linux
1471 need_lib_prefix=no
1472 need_version=no
1473 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
1474 soname_spec='${libname}${release}${shared_ext}$major'
1475 shlibpath_var=LD_LIBRARY_PATH
1476 ;;
1477
1478 freebsd1*)
1479 dynamic_linker=no
1480 ;;
1481
1482 kfreebsd*-gnu)
1483 version_type=linux
1484 need_lib_prefix=no
1485 need_version=no
1486 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1487 soname_spec='${libname}${release}${shared_ext}$major'
1488 shlibpath_var=LD_LIBRARY_PATH
1489 shlibpath_overrides_runpath=no
1490 hardcode_into_libs=yes
1491 dynamic_linker='GNU ld.so'
1492 ;;
1493
1494 freebsd* | dragonfly*)
1495 # DragonFly does not have aout. When/if they implement a new
1496 # versioning mechanism, adjust this.
1497 objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
1498 version_type=freebsd-$objformat
1499 case $version_type in
1500 freebsd-elf*)
1501 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
1502 need_version=no
1503 need_lib_prefix=no
1504 ;;
1505 freebsd-*)
1506 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
1507 need_version=yes
1508 ;;
1509 esac
1510 shlibpath_var=LD_LIBRARY_PATH
1511 case $host_os in
1512 freebsd2*)
1513 shlibpath_overrides_runpath=yes
1514 ;;
1515 freebsd3.[[01]]* | freebsdelf3.[[01]]*)
1516 shlibpath_overrides_runpath=yes
1517 hardcode_into_libs=yes
1518 ;;
1519 *) # from 3.2 on
1520 shlibpath_overrides_runpath=no
1521 hardcode_into_libs=yes
1522 ;;
1523 esac
1524 ;;
1525
1526 gnu*)
1527 version_type=linux
1528 need_lib_prefix=no
1529 need_version=no
1530 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
1531 soname_spec='${libname}${release}${shared_ext}$major'
1532 shlibpath_var=LD_LIBRARY_PATH
1533 hardcode_into_libs=yes
1534 ;;
1535
1536 hpux9* | hpux10* | hpux11*)
1537 # Give a soname corresponding to the major version so that dld.sl refuses to
1538 # link against other versions.
1539 version_type=sunos
1540 need_lib_prefix=no
1541 need_version=no
1542 case "$host_cpu" in
1543 ia64*)
1544 shrext_cmds='.so'
1545 hardcode_into_libs=yes
1546 dynamic_linker="$host_os dld.so"
1547 shlibpath_var=LD_LIBRARY_PATH
1548 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
1549 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1550 soname_spec='${libname}${release}${shared_ext}$major'
1551 if test "X$HPUX_IA64_MODE" = X32; then
1552 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
1553 else
1554 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
1555 fi
1556 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1557 ;;
1558 hppa*64*)
1559 shrext_cmds='.sl'
1560 hardcode_into_libs=yes
1561 dynamic_linker="$host_os dld.sl"
1562 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
1563 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
1564 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1565 soname_spec='${libname}${release}${shared_ext}$major'
1566 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
1567 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1568 ;;
1569 *)
1570 shrext_cmds='.sl'
1571 dynamic_linker="$host_os dld.sl"
1572 shlibpath_var=SHLIB_PATH
1573 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
1574 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1575 soname_spec='${libname}${release}${shared_ext}$major'
1576 ;;
1577 esac
1578 # HP-UX runs *really* slowly unless shared libraries are mode 555.
1579 postinstall_cmds='chmod 555 $lib'
1580 ;;
1581
1582 irix5* | irix6* | nonstopux*)
1583 case $host_os in
1584 nonstopux*) version_type=nonstopux ;;
1585 *)
1586 if test "$lt_cv_prog_gnu_ld" = yes; then
1587 version_type=linux
1588 else
1589 version_type=irix
1590 fi ;;
1591 esac
1592 need_lib_prefix=no
1593 need_version=no
1594 soname_spec='${libname}${release}${shared_ext}$major'
1595 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
1596 case $host_os in
1597 irix5* | nonstopux*)
1598 libsuff= shlibsuff=
1599 ;;
1600 *)
1601 case $LD in # libtool.m4 will add one of these switches to LD
1602 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
1603 libsuff= shlibsuff= libmagic=32-bit;;
1604 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
1605 libsuff=32 shlibsuff=N32 libmagic=N32;;
1606 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
1607 libsuff=64 shlibsuff=64 libmagic=64-bit;;
1608 *) libsuff= shlibsuff= libmagic=never-match;;
1609 esac
1610 ;;
1611 esac
1612 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
1613 shlibpath_overrides_runpath=no
1614 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
1615 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
1616 hardcode_into_libs=yes
1617 ;;
1618
1619 # No shared lib support for Linux oldld, aout, or coff.
1620 linux*oldld* | linux*aout* | linux*coff*)
1621 dynamic_linker=no
1622 ;;
1623
1624 # This must be Linux ELF.
1625 linux*)
1626 version_type=linux
1627 need_lib_prefix=no
1628 need_version=no
1629 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1630 soname_spec='${libname}${release}${shared_ext}$major'
1631 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
1632 shlibpath_var=LD_LIBRARY_PATH
1633 shlibpath_overrides_runpath=no
1634 # This implies no fast_install, which is unacceptable.
1635 # Some rework will be needed to allow for fast_install
1636 # before this can be enabled.
1637 hardcode_into_libs=yes
1638
1639 # Append ld.so.conf contents to the search path
1640 if test -f /etc/ld.so.conf; then
1641 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
1642 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
1643 fi
1644
1645 case $host_cpu:$lt_cv_cc_64bit_output in
1646 powerpc64:yes | s390x:yes | sparc64:yes | x86_64:yes)
1647 sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /usr/X11R6/lib64"
1648 sys_lib_search_path_spec="/lib64 /usr/lib64 /usr/local/lib64 /usr/X11R6/lib64"
1649 ;;
1650 esac
1651
1652 # We used to test for /lib/ld.so.1 and disable shared libraries on
1653 # powerpc, because MkLinux only supported shared libraries with the
1654 # GNU dynamic linker. Since this was broken with cross compilers,
1655 # most powerpc-linux boxes support dynamic linking these days and
1656 # people can always --disable-shared, the test was removed, and we
1657 # assume the GNU/Linux dynamic linker is in use.
1658 dynamic_linker='GNU/Linux ld.so'
1659
1660 # Find out which ABI we are using (multilib Linux x86_64 hack).
1661 libsuff=
1662 case "$host_cpu" in
1663 x86_64*)
1664 echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1665 if AC_TRY_EVAL(ac_compile); then
1666 case `/usr/bin/file conftest.$ac_objext` in
1667 *64-bit*)
1668 libsuff=64
1669 ;;
1670 esac
1671 fi
1672 rm -rf conftest*
1673 ;;
1674 *)
1675 ;;
1676 esac
1677 sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
1678 sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
1679 ;;
1680
1681 knetbsd*-gnu)
1682 version_type=linux
1683 need_lib_prefix=no
1684 need_version=no
1685 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1686 soname_spec='${libname}${release}${shared_ext}$major'
1687 shlibpath_var=LD_LIBRARY_PATH
1688 shlibpath_overrides_runpath=no
1689 hardcode_into_libs=yes
1690 dynamic_linker='GNU ld.so'
1691 ;;
1692
1693 netbsd*)
1694 version_type=sunos
1695 need_lib_prefix=no
1696 need_version=no
1697 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
1698 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1699 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1700 dynamic_linker='NetBSD (a.out) ld.so'
1701 else
1702 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
1703 soname_spec='${libname}${release}${shared_ext}$major'
1704 dynamic_linker='NetBSD ld.elf_so'
1705 fi
1706 shlibpath_var=LD_LIBRARY_PATH
1707 shlibpath_overrides_runpath=yes
1708 hardcode_into_libs=yes
1709 ;;
1710
1711 newsos6)
1712 version_type=linux
1713 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1714 shlibpath_var=LD_LIBRARY_PATH
1715 shlibpath_overrides_runpath=yes
1716 ;;
1717
1718 nto-qnx*)
1719 version_type=linux
1720 need_lib_prefix=no
1721 need_version=no
1722 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1723 soname_spec='${libname}${release}${shared_ext}$major'
1724 shlibpath_var=LD_LIBRARY_PATH
1725 shlibpath_overrides_runpath=yes
1726 ;;
1727
1728 openbsd*)
1729 version_type=sunos
1730 need_lib_prefix=no
1731 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
1732 case $host_os in
1733 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
1734 *) need_version=no ;;
1735 esac
1736 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1737 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1738 shlibpath_var=LD_LIBRARY_PATH
1739 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
1740 case $host_os in
1741 openbsd2.[[89]] | openbsd2.[[89]].*)
1742 shlibpath_overrides_runpath=no
1743 ;;
1744 *)
1745 shlibpath_overrides_runpath=yes
1746 ;;
1747 esac
1748 else
1749 shlibpath_overrides_runpath=yes
1750 fi
1751 ;;
1752
1753 os2*)
1754 libname_spec='$name'
1755 shrext_cmds=".dll"
1756 need_lib_prefix=no
1757 library_names_spec='$libname${shared_ext} $libname.a'
1758 dynamic_linker='OS/2 ld.exe'
1759 shlibpath_var=LIBPATH
1760 ;;
1761
1762 osf3* | osf4* | osf5*)
1763 version_type=osf
1764 need_lib_prefix=no
1765 need_version=no
1766 soname_spec='${libname}${release}${shared_ext}$major'
1767 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1768 shlibpath_var=LD_LIBRARY_PATH
1769 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
1770 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
1771 ;;
1772
1773 sco3.2v5*)
1774 version_type=osf
1775 soname_spec='${libname}${release}${shared_ext}$major'
1776 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1777 shlibpath_var=LD_LIBRARY_PATH
1778 ;;
1779
1780 solaris*)
1781 version_type=linux
1782 need_lib_prefix=no
1783 need_version=no
1784 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1785 soname_spec='${libname}${release}${shared_ext}$major'
1786 shlibpath_var=LD_LIBRARY_PATH
1787 shlibpath_overrides_runpath=yes
1788 hardcode_into_libs=yes
1789 # ldd complains unless libraries are executable
1790 postinstall_cmds='chmod +x $lib'
1791 ;;
1792
1793 sunos4*)
1794 version_type=sunos
1795 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
1796 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
1797 shlibpath_var=LD_LIBRARY_PATH
1798 shlibpath_overrides_runpath=yes
1799 if test "$with_gnu_ld" = yes; then
1800 need_lib_prefix=no
1801 fi
1802 need_version=yes
1803 ;;
1804
1805 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
1806 version_type=linux
1807 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1808 soname_spec='${libname}${release}${shared_ext}$major'
1809 shlibpath_var=LD_LIBRARY_PATH
1810 case $host_vendor in
1811 sni)
1812 shlibpath_overrides_runpath=no
1813 need_lib_prefix=no
1814 export_dynamic_flag_spec='${wl}-Blargedynsym'
1815 runpath_var=LD_RUN_PATH
1816 ;;
1817 siemens)
1818 need_lib_prefix=no
1819 ;;
1820 motorola)
1821 need_lib_prefix=no
1822 need_version=no
1823 shlibpath_overrides_runpath=no
1824 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
1825 ;;
1826 esac
1827 ;;
1828
1829 sysv4*MP*)
1830 if test -d /usr/nec ;then
1831 version_type=linux
1832 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
1833 soname_spec='$libname${shared_ext}.$major'
1834 shlibpath_var=LD_LIBRARY_PATH
1835 fi
1836 ;;
1837
1838 uts4*)
1839 version_type=linux
1840 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
1841 soname_spec='${libname}${release}${shared_ext}$major'
1842 shlibpath_var=LD_LIBRARY_PATH
1843 ;;
1844
1845 *)
1846 dynamic_linker=no
1847 ;;
1848 esac
1849 AC_MSG_RESULT([$dynamic_linker])
1850 test "$dynamic_linker" = no && can_build_shared=no
1851 ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
1852
1853
1854 # _LT_AC_TAGCONFIG
1855 # ----------------
1856 AC_DEFUN([_LT_AC_TAGCONFIG],
1857 [AC_ARG_WITH([tags],
1858 [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
1859 [include additional configurations @<:@automatic@:>@])],
1860 [tagnames="$withval"])
1861
1862 if test -f "$ltmain" && test -n "$tagnames"; then
1863 if test ! -f "${ofile}"; then
1864 AC_MSG_WARN([output file `$ofile' does not exist])
1865 fi
1866
1867 if test -z "$LTCC"; then
1868 eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
1869 if test -z "$LTCC"; then
1870 AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
1871 else
1872 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
1873 fi
1874 fi
1875
1876 # Extract list of available tagged configurations in $ofile.
1877 # Note that this assumes the entire list is on one line.
1878 available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
1879
1880 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
1881 for tagname in $tagnames; do
1882 IFS="$lt_save_ifs"
1883 # Check whether tagname contains only valid characters
1884 case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
1885 "") ;;
1886 *) AC_MSG_ERROR([invalid tag name: $tagname])
1887 ;;
1888 esac
1889
1890 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
1891 then
1892 AC_MSG_ERROR([tag name \"$tagname\" already exists])
1893 fi
1894
1895 # Update the list of available tags.
1896 if test -n "$tagname"; then
1897 echo appending configuration tag \"$tagname\" to $ofile
1898
1899 case $tagname in
1900 CXX)
1901 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
1902 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
1903 (test "X$CXX" != "Xg++"))) ; then
1904 AC_LIBTOOL_LANG_CXX_CONFIG
1905 else
1906 tagname=""
1907 fi
1908 ;;
1909
1910 F77)
1911 if test -n "$F77" && test "X$F77" != "Xno"; then
1912 AC_LIBTOOL_LANG_F77_CONFIG
1913 else
1914 tagname=""
1915 fi
1916 ;;
1917
1918 GCJ)
1919 if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
1920 AC_LIBTOOL_LANG_GCJ_CONFIG
1921 else
1922 tagname=""
1923 fi
1924 ;;
1925
1926 RC)
1927 AC_LIBTOOL_LANG_RC_CONFIG
1928 ;;
1929
1930 *)
1931 AC_MSG_ERROR([Unsupported tag name: $tagname])
1932 ;;
1933 esac
1934
1935 # Append the new tag name to the list of available tags.
1936 if test -n "$tagname" ; then
1937 available_tags="$available_tags $tagname"
1938 fi
1939 fi
1940 done
1941 IFS="$lt_save_ifs"
1942
1943 # Now substitute the updated list of available tags.
1944 if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
1945 mv "${ofile}T" "$ofile"
1946 chmod +x "$ofile"
1947 else
1948 rm -f "${ofile}T"
1949 AC_MSG_ERROR([unable to update list of available tagged configurations.])
1950 fi
1951 fi
1952 ])# _LT_AC_TAGCONFIG
1953
1954
1955 # AC_LIBTOOL_DLOPEN
1956 # -----------------
1957 # enable checks for dlopen support
1958 AC_DEFUN([AC_LIBTOOL_DLOPEN],
1959 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
1960 ])# AC_LIBTOOL_DLOPEN
1961
1962
1963 # AC_LIBTOOL_WIN32_DLL
1964 # --------------------
1965 # declare package support for building win32 dll's
1966 AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
1967 [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
1968 ])# AC_LIBTOOL_WIN32_DLL
1969
1970
1971 # AC_ENABLE_SHARED([DEFAULT])
1972 # ---------------------------
1973 # implement the --enable-shared flag
1974 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
1975 AC_DEFUN([AC_ENABLE_SHARED],
1976 [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
1977 AC_ARG_ENABLE([shared],
1978 [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
1979 [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
1980 [p=${PACKAGE-default}
1981 case $enableval in
1982 yes) enable_shared=yes ;;
1983 no) enable_shared=no ;;
1984 *)
1985 enable_shared=no
1986 # Look at the argument we got. We use all the common list separators.
1987 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
1988 for pkg in $enableval; do
1989 IFS="$lt_save_ifs"
1990 if test "X$pkg" = "X$p"; then
1991 enable_shared=yes
1992 fi
1993 done
1994 IFS="$lt_save_ifs"
1995 ;;
1996 esac],
1997 [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
1998 ])# AC_ENABLE_SHARED
1999
2000
2001 # AC_DISABLE_SHARED
2002 # -----------------
2003 #- set the default shared flag to --disable-shared
2004 AC_DEFUN([AC_DISABLE_SHARED],
2005 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2006 AC_ENABLE_SHARED(no)
2007 ])# AC_DISABLE_SHARED
2008
2009
2010 # AC_ENABLE_STATIC([DEFAULT])
2011 # ---------------------------
2012 # implement the --enable-static flag
2013 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2014 AC_DEFUN([AC_ENABLE_STATIC],
2015 [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
2016 AC_ARG_ENABLE([static],
2017 [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
2018 [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
2019 [p=${PACKAGE-default}
2020 case $enableval in
2021 yes) enable_static=yes ;;
2022 no) enable_static=no ;;
2023 *)
2024 enable_static=no
2025 # Look at the argument we got. We use all the common list separators.
2026 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2027 for pkg in $enableval; do
2028 IFS="$lt_save_ifs"
2029 if test "X$pkg" = "X$p"; then
2030 enable_static=yes
2031 fi
2032 done
2033 IFS="$lt_save_ifs"
2034 ;;
2035 esac],
2036 [enable_static=]AC_ENABLE_STATIC_DEFAULT)
2037 ])# AC_ENABLE_STATIC
2038
2039
2040 # AC_DISABLE_STATIC
2041 # -----------------
2042 # set the default static flag to --disable-static
2043 AC_DEFUN([AC_DISABLE_STATIC],
2044 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2045 AC_ENABLE_STATIC(no)
2046 ])# AC_DISABLE_STATIC
2047
2048
2049 # AC_ENABLE_FAST_INSTALL([DEFAULT])
2050 # ---------------------------------
2051 # implement the --enable-fast-install flag
2052 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2053 AC_DEFUN([AC_ENABLE_FAST_INSTALL],
2054 [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
2055 AC_ARG_ENABLE([fast-install],
2056 [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
2057 [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
2058 [p=${PACKAGE-default}
2059 case $enableval in
2060 yes) enable_fast_install=yes ;;
2061 no) enable_fast_install=no ;;
2062 *)
2063 enable_fast_install=no
2064 # Look at the argument we got. We use all the common list separators.
2065 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2066 for pkg in $enableval; do
2067 IFS="$lt_save_ifs"
2068 if test "X$pkg" = "X$p"; then
2069 enable_fast_install=yes
2070 fi
2071 done
2072 IFS="$lt_save_ifs"
2073 ;;
2074 esac],
2075 [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
2076 ])# AC_ENABLE_FAST_INSTALL
2077
2078
2079 # AC_DISABLE_FAST_INSTALL
2080 # -----------------------
2081 # set the default to --disable-fast-install
2082 AC_DEFUN([AC_DISABLE_FAST_INSTALL],
2083 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2084 AC_ENABLE_FAST_INSTALL(no)
2085 ])# AC_DISABLE_FAST_INSTALL
2086
2087
2088 # AC_LIBTOOL_PICMODE([MODE])
2089 # --------------------------
2090 # implement the --with-pic flag
2091 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
2092 AC_DEFUN([AC_LIBTOOL_PICMODE],
2093 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2094 pic_mode=ifelse($#,1,$1,default)
2095 ])# AC_LIBTOOL_PICMODE
2096
2097
2098 # AC_PROG_EGREP
2099 # -------------
2100 # This is predefined starting with Autoconf 2.54, so this conditional
2101 # definition can be removed once we require Autoconf 2.54 or later.
2102 m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
2103 [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
2104 [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2105 then ac_cv_prog_egrep='grep -E'
2106 else ac_cv_prog_egrep='egrep'
2107 fi])
2108 EGREP=$ac_cv_prog_egrep
2109 AC_SUBST([EGREP])
2110 ])])
2111
2112
2113 # AC_PATH_TOOL_PREFIX
2114 # -------------------
2115 # find a file program which can recognise shared library
2116 AC_DEFUN([AC_PATH_TOOL_PREFIX],
2117 [AC_REQUIRE([AC_PROG_EGREP])dnl
2118 AC_MSG_CHECKING([for $1])
2119 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
2120 [case $MAGIC_CMD in
2121 [[\\/*] | ?:[\\/]*])
2122 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
2123 ;;
2124 *)
2125 lt_save_MAGIC_CMD="$MAGIC_CMD"
2126 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2127 dnl $ac_dummy forces splitting on constant user-supplied paths.
2128 dnl POSIX.2 word splitting is done only on the output of word expansions,
2129 dnl not every word. This closes a longstanding sh security hole.
2130 ac_dummy="ifelse([$2], , $PATH, [$2])"
2131 for ac_dir in $ac_dummy; do
2132 IFS="$lt_save_ifs"
2133 test -z "$ac_dir" && ac_dir=.
2134 if test -f $ac_dir/$1; then
2135 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
2136 if test -n "$file_magic_test_file"; then
2137 case $deplibs_check_method in
2138 "file_magic "*)
2139 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
2140 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2141 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
2142 $EGREP "$file_magic_regex" > /dev/null; then
2143 :
2144 else
2145 cat <<EOF 1>&2
2146
2147 *** Warning: the command libtool uses to detect shared libraries,
2148 *** $file_magic_cmd, produces output that libtool cannot recognize.
2149 *** The result is that libtool may fail to recognize shared libraries
2150 *** as such. This will affect the creation of libtool libraries that
2151 *** depend on shared libraries, but programs linked with such libtool
2152 *** libraries will work regardless of this problem. Nevertheless, you
2153 *** may want to report the problem to your system manager and/or to
2154 *** bug-libtool@gnu.org
2155
2156 EOF
2157 fi ;;
2158 esac
2159 fi
2160 break
2161 fi
2162 done
2163 IFS="$lt_save_ifs"
2164 MAGIC_CMD="$lt_save_MAGIC_CMD"
2165 ;;
2166 esac])
2167 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
2168 if test -n "$MAGIC_CMD"; then
2169 AC_MSG_RESULT($MAGIC_CMD)
2170 else
2171 AC_MSG_RESULT(no)
2172 fi
2173 ])# AC_PATH_TOOL_PREFIX
2174
2175
2176 # AC_PATH_MAGIC
2177 # -------------
2178 # find a file program which can recognise a shared library
2179 AC_DEFUN([AC_PATH_MAGIC],
2180 [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
2181 if test -z "$lt_cv_path_MAGIC_CMD"; then
2182 if test -n "$ac_tool_prefix"; then
2183 AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
2184 else
2185 MAGIC_CMD=:
2186 fi
2187 fi
2188 ])# AC_PATH_MAGIC
2189
2190
2191 # AC_PROG_LD
2192 # ----------
2193 # find the pathname to the GNU or non-GNU linker
2194 AC_DEFUN([AC_PROG_LD],
2195 [AC_ARG_WITH([gnu-ld],
2196 [AC_HELP_STRING([--with-gnu-ld],
2197 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
2198 [test "$withval" = no || with_gnu_ld=yes],
2199 [with_gnu_ld=no])
2200 AC_REQUIRE([LT_AC_PROG_SED])dnl
2201 AC_REQUIRE([AC_PROG_CC])dnl
2202 AC_REQUIRE([AC_CANONICAL_HOST])dnl
2203 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
2204 ac_prog=ld
2205 if test "$GCC" = yes; then
2206 # Check if gcc -print-prog-name=ld gives a path.
2207 AC_MSG_CHECKING([for ld used by $CC])
2208 case $host in
2209 *-*-mingw*)
2210 # gcc leaves a trailing carriage return which upsets mingw
2211 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2212 *)
2213 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2214 esac
2215 case $ac_prog in
2216 # Accept absolute paths.
2217 [[\\/]]* | ?:[[\\/]]*)
2218 re_direlt='/[[^/]][[^/]]*/\.\./'
2219 # Canonicalize the pathname of ld
2220 ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
2221 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2222 ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
2223 done
2224 test -z "$LD" && LD="$ac_prog"
2225 ;;
2226 "")
2227 # If it fails, then pretend we aren't using GCC.
2228 ac_prog=ld
2229 ;;
2230 *)
2231 # If it is relative, then search for the first ld in PATH.
2232 with_gnu_ld=unknown
2233 ;;
2234 esac
2235 elif test "$with_gnu_ld" = yes; then
2236 AC_MSG_CHECKING([for GNU ld])
2237 else
2238 AC_MSG_CHECKING([for non-GNU ld])
2239 fi
2240 AC_CACHE_VAL(lt_cv_path_LD,
2241 [if test -z "$LD"; then
2242 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2243 for ac_dir in $PATH; do
2244 IFS="$lt_save_ifs"
2245 test -z "$ac_dir" && ac_dir=.
2246 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2247 lt_cv_path_LD="$ac_dir/$ac_prog"
2248 # Check to see if the program is GNU ld. I'd rather use --version,
2249 # but apparently some GNU ld's only accept -v.
2250 # Break only if it was the GNU/non-GNU ld that we prefer.
2251 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
2252 *GNU* | *'with BFD'*)
2253 test "$with_gnu_ld" != no && break
2254 ;;
2255 *)
2256 test "$with_gnu_ld" != yes && break
2257 ;;
2258 esac
2259 fi
2260 done
2261 IFS="$lt_save_ifs"
2262 else
2263 lt_cv_path_LD="$LD" # Let the user override the test with a path.
2264 fi])
2265 LD="$lt_cv_path_LD"
2266 if test -n "$LD"; then
2267 AC_MSG_RESULT($LD)
2268 else
2269 AC_MSG_RESULT(no)
2270 fi
2271 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
2272 AC_PROG_LD_GNU
2273 ])# AC_PROG_LD
2274
2275
2276 # AC_PROG_LD_GNU
2277 # --------------
2278 AC_DEFUN([AC_PROG_LD_GNU],
2279 [AC_REQUIRE([AC_PROG_EGREP])dnl
2280 AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
2281 [# I'd rather use --version here, but apparently some GNU ld's only accept -v.
2282 case `$LD -v 2>&1 </dev/null` in
2283 *GNU* | *'with BFD'*)
2284 lt_cv_prog_gnu_ld=yes
2285 ;;
2286 *)
2287 lt_cv_prog_gnu_ld=no
2288 ;;
2289 esac])
2290 with_gnu_ld=$lt_cv_prog_gnu_ld
2291 ])# AC_PROG_LD_GNU
2292
2293
2294 # AC_PROG_LD_RELOAD_FLAG
2295 # ----------------------
2296 # find reload flag for linker
2297 # -- PORTME Some linkers may need a different reload flag.
2298 AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
2299 [AC_CACHE_CHECK([for $LD option to reload object files],
2300 lt_cv_ld_reload_flag,
2301 [lt_cv_ld_reload_flag='-r'])
2302 reload_flag=$lt_cv_ld_reload_flag
2303 case $reload_flag in
2304 "" | " "*) ;;
2305 *) reload_flag=" $reload_flag" ;;
2306 esac
2307 reload_cmds='$LD$reload_flag -o $output$reload_objs'
2308 case $host_os in
2309 darwin*)
2310 if test "$GCC" = yes; then
2311 reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
2312 else
2313 reload_cmds='$LD$reload_flag -o $output$reload_objs'
2314 fi
2315 ;;
2316 esac
2317 ])# AC_PROG_LD_RELOAD_FLAG
2318
2319
2320 # AC_DEPLIBS_CHECK_METHOD
2321 # -----------------------
2322 # how to check for library dependencies
2323 # -- PORTME fill in with the dynamic library characteristics
2324 AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
2325 [AC_CACHE_CHECK([how to recognise dependent libraries],
2326 lt_cv_deplibs_check_method,
2327 [lt_cv_file_magic_cmd='$MAGIC_CMD'
2328 lt_cv_file_magic_test_file=
2329 lt_cv_deplibs_check_method='unknown'
2330 # Need to set the preceding variable on all platforms that support
2331 # interlibrary dependencies.
2332 # 'none' -- dependencies not supported.
2333 # `unknown' -- same as none, but documents that we really don't know.
2334 # 'pass_all' -- all dependencies passed with no checks.
2335 # 'test_compile' -- check by making test program.
2336 # 'file_magic [[regex]]' -- check by looking for files in library path
2337 # which responds to the $file_magic_cmd with a given extended regex.
2338 # If you have `file' or equivalent on your system and you're not sure
2339 # whether `pass_all' will *always* work, you probably want this one.
2340
2341 case $host_os in
2342 aix4* | aix5*)
2343 lt_cv_deplibs_check_method=pass_all
2344 ;;
2345
2346 beos*)
2347 lt_cv_deplibs_check_method=pass_all
2348 ;;
2349
2350 bsdi[[45]]*)
2351 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
2352 lt_cv_file_magic_cmd='/usr/bin/file -L'
2353 lt_cv_file_magic_test_file=/shlib/libc.so
2354 ;;
2355
2356 cygwin*)
2357 # func_win32_libid is a shell function defined in ltmain.sh
2358 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
2359 lt_cv_file_magic_cmd='func_win32_libid'
2360 ;;
2361
2362 mingw* | pw32*)
2363 # Base MSYS/MinGW do not provide the 'file' command needed by
2364 # func_win32_libid shell function, so use a weaker test based on 'objdump'.
2365 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
2366 lt_cv_file_magic_cmd='$OBJDUMP -f'
2367 ;;
2368
2369 darwin* | rhapsody*)
2370 lt_cv_deplibs_check_method=pass_all
2371 ;;
2372
2373 freebsd* | kfreebsd*-gnu | dragonfly*)
2374 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2375 case $host_cpu in
2376 i*86 )
2377 # Not sure whether the presence of OpenBSD here was a mistake.
2378 # Let's accept both of them until this is cleared up.
2379 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
2380 lt_cv_file_magic_cmd=/usr/bin/file
2381 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
2382 ;;
2383 esac
2384 else
2385 lt_cv_deplibs_check_method=pass_all
2386 fi
2387 ;;
2388
2389 gnu*)
2390 lt_cv_deplibs_check_method=pass_all
2391 ;;
2392
2393 hpux10.20* | hpux11*)
2394 lt_cv_file_magic_cmd=/usr/bin/file
2395 case "$host_cpu" in
2396 ia64*)
2397 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
2398 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
2399 ;;
2400 hppa*64*)
2401 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
2402 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
2403 ;;
2404 *)
2405 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
2406 lt_cv_file_magic_test_file=/usr/lib/libc.sl
2407 ;;
2408 esac
2409 ;;
2410
2411 irix5* | irix6* | nonstopux*)
2412 case $LD in
2413 *-32|*"-32 ") libmagic=32-bit;;
2414 *-n32|*"-n32 ") libmagic=N32;;
2415 *-64|*"-64 ") libmagic=64-bit;;
2416 *) libmagic=never-match;;
2417 esac
2418 lt_cv_deplibs_check_method=pass_all
2419 ;;
2420
2421 # This must be Linux ELF.
2422 linux*)
2423 lt_cv_deplibs_check_method=pass_all
2424 ;;
2425
2426 netbsd*)
2427 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2428 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
2429 else
2430 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
2431 fi
2432 ;;
2433
2434 newos6*)
2435 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
2436 lt_cv_file_magic_cmd=/usr/bin/file
2437 lt_cv_file_magic_test_file=/usr/lib/libnls.so
2438 ;;
2439
2440 nto-qnx*)
2441 lt_cv_deplibs_check_method=unknown
2442 ;;
2443
2444 openbsd*)
2445 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2446 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
2447 else
2448 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
2449 fi
2450 ;;
2451
2452 osf3* | osf4* | osf5*)
2453 lt_cv_deplibs_check_method=pass_all
2454 ;;
2455
2456 sco3.2v5*)
2457 lt_cv_deplibs_check_method=pass_all
2458 ;;
2459
2460 solaris*)
2461 lt_cv_deplibs_check_method=pass_all
2462 ;;
2463
2464 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
2465 case $host_vendor in
2466 motorola)
2467 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]]'
2468 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
2469 ;;
2470 ncr)
2471 lt_cv_deplibs_check_method=pass_all
2472 ;;
2473 sequent)
2474 lt_cv_file_magic_cmd='/bin/file'
2475 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
2476 ;;
2477 sni)
2478 lt_cv_file_magic_cmd='/bin/file'
2479 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
2480 lt_cv_file_magic_test_file=/lib/libc.so
2481 ;;
2482 siemens)
2483 lt_cv_deplibs_check_method=pass_all
2484 ;;
2485 esac
2486 ;;
2487
2488 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
2489 lt_cv_deplibs_check_method=pass_all
2490 ;;
2491 esac
2492 ])
2493 file_magic_cmd=$lt_cv_file_magic_cmd
2494 deplibs_check_method=$lt_cv_deplibs_check_method
2495 test -z "$deplibs_check_method" && deplibs_check_method=unknown
2496 ])# AC_DEPLIBS_CHECK_METHOD
2497
2498
2499 # AC_PROG_NM
2500 # ----------
2501 # find the pathname to a BSD-compatible name lister
2502 AC_DEFUN([AC_PROG_NM],
2503 [AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
2504 [if test -n "$NM"; then
2505 # Let the user override the test.
2506 lt_cv_path_NM="$NM"
2507 else
2508 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
2509 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2510 IFS="$lt_save_ifs"
2511 test -z "$ac_dir" && ac_dir=.
2512 tmp_nm="$ac_dir/${ac_tool_prefix}nm"
2513 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
2514 # Check to see if the nm accepts a BSD-compat flag.
2515 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2516 # nm: unknown option "B" ignored
2517 # Tru64's nm complains that /dev/null is an invalid object file
2518 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
2519 */dev/null* | *'Invalid file or object type'*)
2520 lt_cv_path_NM="$tmp_nm -B"
2521 break
2522 ;;
2523 *)
2524 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
2525 */dev/null*)
2526 lt_cv_path_NM="$tmp_nm -p"
2527 break
2528 ;;
2529 *)
2530 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
2531 continue # so that we can try to find one that supports BSD flags
2532 ;;
2533 esac
2534 esac
2535 fi
2536 done
2537 IFS="$lt_save_ifs"
2538 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
2539 fi])
2540 NM="$lt_cv_path_NM"
2541 ])# AC_PROG_NM
2542
2543
2544 # AC_CHECK_LIBM
2545 # -------------
2546 # check for math library
2547 AC_DEFUN([AC_CHECK_LIBM],
2548 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
2549 LIBM=
2550 case $host in
2551 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
2552 # These system don't have libm, or don't need it
2553 ;;
2554 *-ncr-sysv4.3*)
2555 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
2556 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
2557 ;;
2558 *)
2559 AC_CHECK_LIB(m, cos, LIBM="-lm")
2560 ;;
2561 esac
2562 ])# AC_CHECK_LIBM
2563
2564
2565 # AC_LIBLTDL_CONVENIENCE([DIRECTORY])
2566 # -----------------------------------
2567 # sets LIBLTDL to the link flags for the libltdl convenience library and
2568 # LTDLINCL to the include flags for the libltdl header and adds
2569 # --enable-ltdl-convenience to the configure arguments. Note that LIBLTDL
2570 # and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If
2571 # DIRECTORY is not provided, it is assumed to be `libltdl'. LIBLTDL will
2572 # be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed with
2573 # '${top_srcdir}/' (note the single quotes!). If your package is not
2574 # flat and you're not using automake, define top_builddir and
2575 # top_srcdir appropriately in the Makefiles.
2576 AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
2577 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2578 case $enable_ltdl_convenience in
2579 no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
2580 "") enable_ltdl_convenience=yes
2581 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
2582 esac
2583 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
2584 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
2585 # For backwards non-gettext consistent compatibility...
2586 INCLTDL="$LTDLINCL"
2587 ])# AC_LIBLTDL_CONVENIENCE
2588
2589
2590 # AC_LIBLTDL_INSTALLABLE([DIRECTORY])
2591 # -----------------------------------
2592 # sets LIBLTDL to the link flags for the libltdl installable library and
2593 # LTDLINCL to the include flags for the libltdl header and adds
2594 # --enable-ltdl-install to the configure arguments. Note that LIBLTDL
2595 # and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If
2596 # DIRECTORY is not provided and an installed libltdl is not found, it is
2597 # assumed to be `libltdl'. LIBLTDL will be prefixed with '${top_builddir}/'
2598 # and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single
2599 # quotes!). If your package is not flat and you're not using automake,
2600 # define top_builddir and top_srcdir appropriately in the Makefiles.
2601 # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
2602 AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
2603 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2604 AC_CHECK_LIB(ltdl, lt_dlinit,
2605 [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
2606 [if test x"$enable_ltdl_install" = xno; then
2607 AC_MSG_WARN([libltdl not installed, but installation disabled])
2608 else
2609 enable_ltdl_install=yes
2610 fi
2611 ])
2612 if test x"$enable_ltdl_install" = x"yes"; then
2613 ac_configure_args="$ac_configure_args --enable-ltdl-install"
2614 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
2615 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
2616 else
2617 ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
2618 LIBLTDL="-lltdl"
2619 LTDLINCL=
2620 fi
2621 # For backwards non-gettext consistent compatibility...
2622 INCLTDL="$LTDLINCL"
2623 ])# AC_LIBLTDL_INSTALLABLE
2624
2625
2626 # AC_LIBTOOL_CXX
2627 # --------------
2628 # enable support for C++ libraries
2629 AC_DEFUN([AC_LIBTOOL_CXX],
2630 [AC_REQUIRE([_LT_AC_LANG_CXX])
2631 ])# AC_LIBTOOL_CXX
2632
2633
2634 # _LT_AC_LANG_CXX
2635 # ---------------
2636 AC_DEFUN([_LT_AC_LANG_CXX],
2637 [AC_REQUIRE([AC_PROG_CXX])
2638 AC_REQUIRE([_LT_AC_PROG_CXXCPP])
2639 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
2640 ])# _LT_AC_LANG_CXX
2641
2642 # _LT_AC_PROG_CXXCPP
2643 # ---------------
2644 AC_DEFUN([_LT_AC_PROG_CXXCPP],
2645 [
2646 AC_REQUIRE([AC_PROG_CXX])
2647 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2648 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2649 (test "X$CXX" != "Xg++"))) ; then
2650 AC_PROG_CXXCPP
2651 fi
2652 ])# _LT_AC_PROG_CXXCPP
2653
2654 # AC_LIBTOOL_F77
2655 # --------------
2656 # enable support for Fortran 77 libraries
2657 AC_DEFUN([AC_LIBTOOL_F77],
2658 [AC_REQUIRE([_LT_AC_LANG_F77])
2659 ])# AC_LIBTOOL_F77
2660
2661
2662 # _LT_AC_LANG_F77
2663 # ---------------
2664 AC_DEFUN([_LT_AC_LANG_F77],
2665 [AC_REQUIRE([AC_PROG_F77])
2666 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
2667 ])# _LT_AC_LANG_F77
2668
2669
2670 # AC_LIBTOOL_GCJ
2671 # --------------
2672 # enable support for GCJ libraries
2673 AC_DEFUN([AC_LIBTOOL_GCJ],
2674 [AC_REQUIRE([_LT_AC_LANG_GCJ])
2675 ])# AC_LIBTOOL_GCJ
2676
2677
2678 # _LT_AC_LANG_GCJ
2679 # ---------------
2680 AC_DEFUN([_LT_AC_LANG_GCJ],
2681 [AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
2682 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
2683 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
2684 [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
2685 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
2686 [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
2687 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
2688 ])# _LT_AC_LANG_GCJ
2689
2690
2691 # AC_LIBTOOL_RC
2692 # --------------
2693 # enable support for Windows resource files
2694 AC_DEFUN([AC_LIBTOOL_RC],
2695 [AC_REQUIRE([LT_AC_PROG_RC])
2696 _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
2697 ])# AC_LIBTOOL_RC
2698
2699
2700 # AC_LIBTOOL_LANG_C_CONFIG
2701 # ------------------------
2702 # Ensure that the configuration vars for the C compiler are
2703 # suitably defined. Those variables are subsequently used by
2704 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
2705 AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
2706 AC_DEFUN([_LT_AC_LANG_C_CONFIG],
2707 [lt_save_CC="$CC"
2708 AC_LANG_PUSH(C)
2709
2710 # Source file extension for C test sources.
2711 ac_ext=c
2712
2713 # Object file extension for compiled C test sources.
2714 objext=o
2715 _LT_AC_TAGVAR(objext, $1)=$objext
2716
2717 # Code to be used in simple compile tests
2718 lt_simple_compile_test_code="int some_variable = 0;\n"
2719
2720 # Code to be used in simple link tests
2721 lt_simple_link_test_code='int main(){return(0);}\n'
2722
2723 _LT_AC_SYS_COMPILER
2724
2725 # save warnings/boilerplate of simple test code
2726 _LT_COMPILER_BOILERPLATE
2727 _LT_LINKER_BOILERPLATE
2728
2729 #
2730 # Check for any special shared library compilation flags.
2731 #
2732 _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
2733 if test "$GCC" = no; then
2734 case $host_os in
2735 sco3.2v5*)
2736 _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
2737 ;;
2738 esac
2739 fi
2740 if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
2741 AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
2742 if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then :
2743 else
2744 AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
2745 _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
2746 fi
2747 fi
2748
2749
2750 #
2751 # Check to make sure the static flag actually works.
2752 #
2753 AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
2754 _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
2755 $_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
2756 [],
2757 [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
2758
2759
2760 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
2761 AC_LIBTOOL_PROG_COMPILER_PIC($1)
2762 AC_LIBTOOL_PROG_CC_C_O($1)
2763 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
2764 AC_LIBTOOL_PROG_LD_SHLIBS($1)
2765 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
2766 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
2767 AC_LIBTOOL_SYS_LIB_STRIP
2768 AC_LIBTOOL_DLOPEN_SELF($1)
2769
2770 # Report which librarie types wil actually be built
2771 AC_MSG_CHECKING([if libtool supports shared libraries])
2772 AC_MSG_RESULT([$can_build_shared])
2773
2774 AC_MSG_CHECKING([whether to build shared libraries])
2775 test "$can_build_shared" = "no" && enable_shared=no
2776
2777 # On AIX, shared libraries and static libraries use the same namespace, and
2778 # are all built from PIC.
2779 case "$host_os" in
2780 aix3*)
2781 test "$enable_shared" = yes && enable_static=no
2782 if test -n "$RANLIB"; then
2783 archive_cmds="$archive_cmds~\$RANLIB \$lib"
2784 postinstall_cmds='$RANLIB $lib'
2785 fi
2786 ;;
2787
2788 aix4* | aix5*)
2789 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
2790 test "$enable_shared" = yes && enable_static=no
2791 fi
2792 ;;
2793 esac
2794 AC_MSG_RESULT([$enable_shared])
2795
2796 AC_MSG_CHECKING([whether to build static libraries])
2797 # Make sure either enable_shared or enable_static is yes.
2798 test "$enable_shared" = yes || enable_static=yes
2799 AC_MSG_RESULT([$enable_static])
2800
2801 AC_LIBTOOL_CONFIG($1)
2802
2803 AC_LANG_POP
2804 CC="$lt_save_CC"
2805 ])# AC_LIBTOOL_LANG_C_CONFIG
2806
2807
2808 # AC_LIBTOOL_LANG_CXX_CONFIG
2809 # --------------------------
2810 # Ensure that the configuration vars for the C compiler are
2811 # suitably defined. Those variables are subsequently used by
2812 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
2813 AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
2814 AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
2815 [AC_LANG_PUSH(C++)
2816 AC_REQUIRE([AC_PROG_CXX])
2817 AC_REQUIRE([_LT_AC_PROG_CXXCPP])
2818
2819 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
2820 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
2821 _LT_AC_TAGVAR(always_export_symbols, $1)=no
2822 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
2823 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
2824 _LT_AC_TAGVAR(hardcode_direct, $1)=no
2825 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
2826 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
2827 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
2828 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
2829 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
2830 _LT_AC_TAGVAR(module_cmds, $1)=
2831 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
2832 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
2833 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
2834 _LT_AC_TAGVAR(no_undefined_flag, $1)=
2835 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
2836 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
2837
2838 # Dependencies to place before and after the object being linked:
2839 _LT_AC_TAGVAR(predep_objects, $1)=
2840 _LT_AC_TAGVAR(postdep_objects, $1)=
2841 _LT_AC_TAGVAR(predeps, $1)=
2842 _LT_AC_TAGVAR(postdeps, $1)=
2843 _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
2844
2845 # Source file extension for C++ test sources.
2846 ac_ext=cc
2847
2848 # Object file extension for compiled C++ test sources.
2849 objext=o
2850 _LT_AC_TAGVAR(objext, $1)=$objext
2851
2852 # Code to be used in simple compile tests
2853 lt_simple_compile_test_code="int some_variable = 0;\n"
2854
2855 # Code to be used in simple link tests
2856 lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
2857
2858 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
2859 _LT_AC_SYS_COMPILER
2860
2861 # save warnings/boilerplate of simple test code
2862 _LT_COMPILER_BOILERPLATE
2863 _LT_LINKER_BOILERPLATE
2864
2865 # Allow CC to be a program name with arguments.
2866 lt_save_CC=$CC
2867 lt_save_LD=$LD
2868 lt_save_GCC=$GCC
2869 GCC=$GXX
2870 lt_save_with_gnu_ld=$with_gnu_ld
2871 lt_save_path_LD=$lt_cv_path_LD
2872 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
2873 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
2874 else
2875 unset lt_cv_prog_gnu_ld
2876 fi
2877 if test -n "${lt_cv_path_LDCXX+set}"; then
2878 lt_cv_path_LD=$lt_cv_path_LDCXX
2879 else
2880 unset lt_cv_path_LD
2881 fi
2882 test -z "${LDCXX+set}" || LD=$LDCXX
2883 CC=${CXX-"c++"}
2884 compiler=$CC
2885 _LT_AC_TAGVAR(compiler, $1)=$CC
2886 _LT_CC_BASENAME([$compiler])
2887
2888 # We don't want -fno-exception wen compiling C++ code, so set the
2889 # no_builtin_flag separately
2890 if test "$GXX" = yes; then
2891 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
2892 else
2893 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
2894 fi
2895
2896 if test "$GXX" = yes; then
2897 # Set up default GNU C++ configuration
2898
2899 AC_PROG_LD
2900
2901 # Check if GNU C++ uses GNU ld as the underlying linker, since the
2902 # archiving commands below assume that GNU ld is being used.
2903 if test "$with_gnu_ld" = yes; then
2904 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
2905 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
2906
2907 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
2908 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
2909
2910 # If archive_cmds runs LD, not CC, wlarc should be empty
2911 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
2912 # investigate it a little bit more. (MM)
2913 wlarc='${wl}'
2914
2915 # ancient GNU ld didn't support --whole-archive et. al.
2916 if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
2917 grep 'no-whole-archive' > /dev/null; then
2918 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
2919 else
2920 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
2921 fi
2922 else
2923 with_gnu_ld=no
2924 wlarc=
2925
2926 # A generic and very simple default shared library creation
2927 # command for GNU C++ for the case where it uses the native
2928 # linker, instead of GNU ld. If possible, this setting should
2929 # overridden to take advantage of the native linker features on
2930 # the platform it is being used on.
2931 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
2932 fi
2933
2934 # Commands to make compiler produce verbose output that lists
2935 # what "hidden" libraries, object files and flags are used when
2936 # linking a shared library.
2937 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
2938
2939 else
2940 GXX=no
2941 with_gnu_ld=no
2942 wlarc=
2943 fi
2944
2945 # PORTME: fill in a description of your system's C++ link characteristics
2946 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
2947 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
2948 case $host_os in
2949 aix3*)
2950 # FIXME: insert proper C++ library support
2951 _LT_AC_TAGVAR(ld_shlibs, $1)=no
2952 ;;
2953 aix4* | aix5*)
2954 if test "$host_cpu" = ia64; then
2955 # On IA64, the linker does run time linking by default, so we don't
2956 # have to do anything special.
2957 aix_use_runtimelinking=no
2958 exp_sym_flag='-Bexport'
2959 no_entry_flag=""
2960 else
2961 aix_use_runtimelinking=no
2962
2963 # Test if we are trying to use run time linking or normal
2964 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
2965 # need to do runtime linking.
2966 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
2967 for ld_flag in $LDFLAGS; do
2968 case $ld_flag in
2969 *-brtl*)
2970 aix_use_runtimelinking=yes
2971 break
2972 ;;
2973 esac
2974 done
2975 esac
2976
2977 exp_sym_flag='-bexport'
2978 no_entry_flag='-bnoentry'
2979 fi
2980
2981 # When large executables or shared objects are built, AIX ld can
2982 # have problems creating the table of contents. If linking a library
2983 # or program results in "error TOC overflow" add -mminimal-toc to
2984 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
2985 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
2986
2987 _LT_AC_TAGVAR(archive_cmds, $1)=''
2988 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
2989 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
2990 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
2991
2992 if test "$GXX" = yes; then
2993 case $host_os in aix4.[[012]]|aix4.[[012]].*)
2994 # We only want to do this on AIX 4.2 and lower, the check
2995 # below for broken collect2 doesn't work under 4.3+
2996 collect2name=`${CC} -print-prog-name=collect2`
2997 if test -f "$collect2name" && \
2998 strings "$collect2name" | grep resolve_lib_name >/dev/null
2999 then
3000 # We have reworked collect2
3001 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3002 else
3003 # We have old collect2
3004 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3005 # It fails to find uninstalled libraries when the uninstalled
3006 # path is not listed in the libpath. Setting hardcode_minus_L
3007 # to unsupported forces relinking
3008 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3009 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3010 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3011 fi
3012 esac
3013 shared_flag='-shared'
3014 if test "$aix_use_runtimelinking" = yes; then
3015 shared_flag="$shared_flag "'${wl}-G'
3016 fi
3017 else
3018 # not using gcc
3019 if test "$host_cpu" = ia64; then
3020 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
3021 # chokes on -Wl,-G. The following line is correct:
3022 shared_flag='-G'
3023 else
3024 if test "$aix_use_runtimelinking" = yes; then
3025 shared_flag='${wl}-G'
3026 else
3027 shared_flag='${wl}-bM:SRE'
3028 fi
3029 fi
3030 fi
3031
3032 # It seems that -bexpall does not export symbols beginning with
3033 # underscore (_), so it is better to generate a list of symbols to export.
3034 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3035 if test "$aix_use_runtimelinking" = yes; then
3036 # Warning - without using the other runtime loading flags (-brtl),
3037 # -berok will link without error, but may produce a broken library.
3038 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
3039 # Determine the default libpath from the value encoded in an empty executable.
3040 _LT_AC_SYS_LIBPATH_AIX
3041 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3042
3043 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
3044 else
3045 if test "$host_cpu" = ia64; then
3046 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
3047 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
3048 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
3049 else
3050 # Determine the default libpath from the value encoded in an empty executable.
3051 _LT_AC_SYS_LIBPATH_AIX
3052 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
3053 # Warning - without using the other run time loading flags,
3054 # -berok will link without error, but may produce a broken library.
3055 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
3056 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
3057 # -bexpall does not export symbols beginning with underscore (_)
3058 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
3059 # Exported symbols can be pulled into shared objects from archives
3060 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
3061 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
3062 # This is similar to how AIX traditionally builds it's shared libraries.
3063 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
3064 fi
3065 fi
3066 ;;
3067 chorus*)
3068 case $cc_basename in
3069 *)
3070 # FIXME: insert proper C++ library support
3071 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3072 ;;
3073 esac
3074 ;;
3075
3076
3077 cygwin* | mingw* | pw32*)
3078 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
3079 # as there is no search path for DLLs.
3080 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3081 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
3082 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3083 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
3084
3085 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
3086 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
3087 # If the export-symbols file already is a .def file (1st line
3088 # is EXPORTS), use it as is; otherwise, prepend...
3089 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
3090 cp $export_symbols $output_objdir/$soname.def;
3091 else
3092 echo EXPORTS > $output_objdir/$soname.def;
3093 cat $export_symbols >> $output_objdir/$soname.def;
3094 fi~
3095 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
3096 else
3097 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3098 fi
3099 ;;
3100 darwin* | rhapsody*)
3101 case "$host_os" in
3102 rhapsody* | darwin1.[[012]])
3103 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
3104 ;;
3105 *) # Darwin 1.3 on
3106 if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
3107 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
3108 else
3109 case ${MACOSX_DEPLOYMENT_TARGET} in
3110 10.[[012]])
3111 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
3112 ;;
3113 10.*)
3114 _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
3115 ;;
3116 esac
3117 fi
3118 ;;
3119 esac
3120 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3121 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3122 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
3123 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3124 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
3125 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3126
3127 if test "$GXX" = yes ; then
3128 lt_int_apple_cc_single_mod=no
3129 output_verbose_link_cmd='echo'
3130 if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
3131 lt_int_apple_cc_single_mod=yes
3132 fi
3133 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3134 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
3135 else
3136 _LT_AC_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'
3137 fi
3138 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3139 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
3140 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
3141 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3142 else
3143 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3144 fi
3145 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3146 else
3147 case $cc_basename in
3148 xlc*)
3149 output_verbose_link_cmd='echo'
3150 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
3151 _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
3152 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
3153 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3154 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
3155 ;;
3156 *)
3157 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3158 ;;
3159 esac
3160 fi
3161 ;;
3162
3163 dgux*)
3164 case $cc_basename in
3165 ec++*)
3166 # FIXME: insert proper C++ library support
3167 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3168 ;;
3169 ghcx*)
3170 # Green Hills C++ Compiler
3171 # FIXME: insert proper C++ library support
3172 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3173 ;;
3174 *)
3175 # FIXME: insert proper C++ library support
3176 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3177 ;;
3178 esac
3179 ;;
3180 freebsd[[12]]*)
3181 # C++ shared libraries reported to be fairly broken before switch to ELF
3182 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3183 ;;
3184 freebsd-elf*)
3185 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3186 ;;
3187 freebsd* | kfreebsd*-gnu | dragonfly*)
3188 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
3189 # conventions
3190 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
3191 ;;
3192 gnu*)
3193 ;;
3194 hpux9*)
3195 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3196 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3197 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3198 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3199 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3200 # but as the default
3201 # location of the library.
3202
3203 case $cc_basename in
3204 CC*)
3205 # FIXME: insert proper C++ library support
3206 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3207 ;;
3208 aCC*)
3209 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3210 # Commands to make compiler produce verbose output that lists
3211 # what "hidden" libraries, object files and flags are used when
3212 # linking a shared library.
3213 #
3214 # There doesn't appear to be a way to prevent this compiler from
3215 # explicitly linking system object files so we need to strip them
3216 # from the output so that they don't get included in the library
3217 # dependencies.
3218 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3219 ;;
3220 *)
3221 if test "$GXX" = yes; then
3222 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
3223 else
3224 # FIXME: insert proper C++ library support
3225 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3226 fi
3227 ;;
3228 esac
3229 ;;
3230 hpux10*|hpux11*)
3231 if test $with_gnu_ld = no; then
3232 case "$host_cpu" in
3233 hppa*64*)
3234 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3235 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
3236 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3237 ;;
3238 ia64*)
3239 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3240 ;;
3241 *)
3242 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
3243 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3244 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3245 ;;
3246 esac
3247 fi
3248 case "$host_cpu" in
3249 hppa*64*)
3250 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3251 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3252 ;;
3253 ia64*)
3254 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3255 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3256 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3257 # but as the default
3258 # location of the library.
3259 ;;
3260 *)
3261 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3262 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
3263 # but as the default
3264 # location of the library.
3265 ;;
3266 esac
3267
3268 case $cc_basename in
3269 CC*)
3270 # FIXME: insert proper C++ library support
3271 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3272 ;;
3273 aCC*)
3274 case "$host_cpu" in
3275 hppa*64*|ia64*)
3276 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
3277 ;;
3278 *)
3279 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3280 ;;
3281 esac
3282 # Commands to make compiler produce verbose output that lists
3283 # what "hidden" libraries, object files and flags are used when
3284 # linking a shared library.
3285 #
3286 # There doesn't appear to be a way to prevent this compiler from
3287 # explicitly linking system object files so we need to strip them
3288 # from the output so that they don't get included in the library
3289 # dependencies.
3290 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3291 ;;
3292 *)
3293 if test "$GXX" = yes; then
3294 if test $with_gnu_ld = no; then
3295 case "$host_cpu" in
3296 ia64*|hppa*64*)
3297 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
3298 ;;
3299 *)
3300 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3301 ;;
3302 esac
3303 fi
3304 else
3305 # FIXME: insert proper C++ library support
3306 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3307 fi
3308 ;;
3309 esac
3310 ;;
3311 irix5* | irix6*)
3312 case $cc_basename in
3313 CC*)
3314 # SGI C++
3315 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
3316
3317 # Archives containing C++ object files must be created using
3318 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
3319 # necessary to make sure instantiated templates are included
3320 # in the archive.
3321 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
3322 ;;
3323 *)
3324 if test "$GXX" = yes; then
3325 if test "$with_gnu_ld" = no; then
3326 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
3327 else
3328 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
3329 fi
3330 fi
3331 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3332 ;;
3333 esac
3334 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3335 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3336 ;;
3337 linux*)
3338 case $cc_basename in
3339 KCC*)
3340 # Kuck and Associates, Inc. (KAI) C++ Compiler
3341
3342 # KCC will only create a shared library if the output file
3343 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3344 # to its proper name (with version) after linking.
3345 _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
3346 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
3347 # Commands to make compiler produce verbose output that lists
3348 # what "hidden" libraries, object files and flags are used when
3349 # linking a shared library.
3350 #
3351 # There doesn't appear to be a way to prevent this compiler from
3352 # explicitly linking system object files so we need to strip them
3353 # from the output so that they don't get included in the library
3354 # dependencies.
3355 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3356
3357 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
3358 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3359
3360 # Archives containing C++ object files must be created using
3361 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
3362 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
3363 ;;
3364 icpc*)
3365 # Intel C++
3366 with_gnu_ld=yes
3367 # version 8.0 and above of icpc choke on multiply defined symbols
3368 # if we add $predep_objects and $postdep_objects, however 7.1 and
3369 # earlier do not add the objects themselves.
3370 case `$CC -V 2>&1` in
3371 *"Version 7."*)
3372 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3373 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3374 ;;
3375 *) # Version 8.0 or newer
3376 tmp_idyn=
3377 case $host_cpu in
3378 ia64*) tmp_idyn=' -i_dynamic';;
3379 esac
3380 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
3381 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3382 ;;
3383 esac
3384 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3385 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3386 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3387 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
3388 ;;
3389 pgCC*)
3390 # Portland Group C++ compiler
3391 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
3392 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
3393
3394 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3395 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3396 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive,`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
3397 ;;
3398 cxx*)
3399 # Compaq C++
3400 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3401 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
3402
3403 runpath_var=LD_RUN_PATH
3404 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
3405 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3406
3407 # Commands to make compiler produce verbose output that lists
3408 # what "hidden" libraries, object files and flags are used when
3409 # linking a shared library.
3410 #
3411 # There doesn't appear to be a way to prevent this compiler from
3412 # explicitly linking system object files so we need to strip them
3413 # from the output so that they don't get included in the library
3414 # dependencies.
3415 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3416 ;;
3417 esac
3418 ;;
3419 lynxos*)
3420 # FIXME: insert proper C++ library support
3421 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3422 ;;
3423 m88k*)
3424 # FIXME: insert proper C++ library support
3425 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3426 ;;
3427 mvs*)
3428 case $cc_basename in
3429 cxx*)
3430 # FIXME: insert proper C++ library support
3431 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3432 ;;
3433 *)
3434 # FIXME: insert proper C++ library support
3435 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3436 ;;
3437 esac
3438 ;;
3439 netbsd*)
3440 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
3441 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
3442 wlarc=
3443 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
3444 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3445 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3446 fi
3447 # Workaround some broken pre-1.5 toolchains
3448 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
3449 ;;
3450 openbsd2*)
3451 # C++ shared libraries are fairly broken
3452 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3453 ;;
3454 openbsd*)
3455 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
3456 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3457 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3458 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3459 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3460 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
3461 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
3462 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3463 fi
3464 output_verbose_link_cmd='echo'
3465 ;;
3466 osf3*)
3467 case $cc_basename in
3468 KCC*)
3469 # Kuck and Associates, Inc. (KAI) C++ Compiler
3470
3471 # KCC will only create a shared library if the output file
3472 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3473 # to its proper name (with version) after linking.
3474 _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
3475
3476 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3477 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3478
3479 # Archives containing C++ object files must be created using
3480 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
3481 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
3482
3483 ;;
3484 RCC*)
3485 # Rational C++ 2.4.1
3486 # FIXME: insert proper C++ library support
3487 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3488 ;;
3489 cxx*)
3490 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3491 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
3492
3493 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3494 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3495
3496 # Commands to make compiler produce verbose output that lists
3497 # what "hidden" libraries, object files and flags are used when
3498 # linking a shared library.
3499 #
3500 # There doesn't appear to be a way to prevent this compiler from
3501 # explicitly linking system object files so we need to strip them
3502 # from the output so that they don't get included in the library
3503 # dependencies.
3504 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3505 ;;
3506 *)
3507 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3508 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3509 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
3510
3511 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3512 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3513
3514 # Commands to make compiler produce verbose output that lists
3515 # what "hidden" libraries, object files and flags are used when
3516 # linking a shared library.
3517 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3518
3519 else
3520 # FIXME: insert proper C++ library support
3521 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3522 fi
3523 ;;
3524 esac
3525 ;;
3526 osf4* | osf5*)
3527 case $cc_basename in
3528 KCC*)
3529 # Kuck and Associates, Inc. (KAI) C++ Compiler
3530
3531 # KCC will only create a shared library if the output file
3532 # ends with ".so" (or ".sl" for HP-UX), so rename the library
3533 # to its proper name (with version) after linking.
3534 _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
3535
3536 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
3537 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3538
3539 # Archives containing C++ object files must be created using
3540 # the KAI C++ compiler.
3541 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
3542 ;;
3543 RCC*)
3544 # Rational C++ 2.4.1
3545 # FIXME: insert proper C++ library support
3546 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3547 ;;
3548 cxx*)
3549 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
3550 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
3551 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
3552 echo "-hidden">> $lib.exp~
3553 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~
3554 $rm $lib.exp'
3555
3556 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
3557 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3558
3559 # Commands to make compiler produce verbose output that lists
3560 # what "hidden" libraries, object files and flags are used when
3561 # linking a shared library.
3562 #
3563 # There doesn't appear to be a way to prevent this compiler from
3564 # explicitly linking system object files so we need to strip them
3565 # from the output so that they don't get included in the library
3566 # dependencies.
3567 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3568 ;;
3569 *)
3570 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3571 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
3572 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
3573
3574 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
3575 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
3576
3577 # Commands to make compiler produce verbose output that lists
3578 # what "hidden" libraries, object files and flags are used when
3579 # linking a shared library.
3580 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3581
3582 else
3583 # FIXME: insert proper C++ library support
3584 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3585 fi
3586 ;;
3587 esac
3588 ;;
3589 psos*)
3590 # FIXME: insert proper C++ library support
3591 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3592 ;;
3593 sco*)
3594 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3595 case $cc_basename in
3596 CC*)
3597 # FIXME: insert proper C++ library support
3598 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3599 ;;
3600 *)
3601 # FIXME: insert proper C++ library support
3602 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3603 ;;
3604 esac
3605 ;;
3606 sunos4*)
3607 case $cc_basename in
3608 CC*)
3609 # Sun C++ 4.x
3610 # FIXME: insert proper C++ library support
3611 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3612 ;;
3613 lcc*)
3614 # Lucid
3615 # FIXME: insert proper C++ library support
3616 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3617 ;;
3618 *)
3619 # FIXME: insert proper C++ library support
3620 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3621 ;;
3622 esac
3623 ;;
3624 solaris*)
3625 case $cc_basename in
3626 CC*)
3627 # Sun C++ 4.2, 5.x and Centerline C++
3628 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
3629 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
3630 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3631 $CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3632
3633 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
3634 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
3635 case $host_os in
3636 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
3637 *)
3638 # The C++ compiler is used as linker so we must use $wl
3639 # flag to pass the commands to the underlying system
3640 # linker. We must also pass each convience library through
3641 # to the system linker between allextract/defaultextract.
3642 # The C++ compiler will combine linker options so we
3643 # cannot just pass the convience library names through
3644 # without $wl.
3645 # Supported since Solaris 2.6 (maybe 2.5.1?)
3646 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
3647 ;;
3648 esac
3649 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3650
3651 # Commands to make compiler produce verbose output that lists
3652 # what "hidden" libraries, object files and flags are used when
3653 # linking a shared library.
3654 #
3655 # There doesn't appear to be a way to prevent this compiler from
3656 # explicitly linking system object files so we need to strip them
3657 # from the output so that they don't get included in the library
3658 # dependencies.
3659 output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
3660
3661 # Archives containing C++ object files must be created using
3662 # "CC -xar", where "CC" is the Sun C++ compiler. This is
3663 # necessary to make sure instantiated templates are included
3664 # in the archive.
3665 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
3666 ;;
3667 gcx*)
3668 # Green Hills C++ Compiler
3669 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3670
3671 # The C++ compiler must be used to create the archive.
3672 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
3673 ;;
3674 *)
3675 # GNU C++ compiler with Solaris linker
3676 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
3677 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
3678 if $CC --version | grep -v '^2\.7' > /dev/null; then
3679 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3680 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3681 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3682
3683 # Commands to make compiler produce verbose output that lists
3684 # what "hidden" libraries, object files and flags are used when
3685 # linking a shared library.
3686 output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
3687 else
3688 # g++ 2.7 appears to require `-G' NOT `-shared' on this
3689 # platform.
3690 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
3691 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
3692 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
3693
3694 # Commands to make compiler produce verbose output that lists
3695 # what "hidden" libraries, object files and flags are used when
3696 # linking a shared library.
3697 output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
3698 fi
3699
3700 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
3701 fi
3702 ;;
3703 esac
3704 ;;
3705 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
3706 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3707 ;;
3708 tandem*)
3709 case $cc_basename in
3710 NCC*)
3711 # NonStop-UX NCC 3.20
3712 # FIXME: insert proper C++ library support
3713 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3714 ;;
3715 *)
3716 # FIXME: insert proper C++ library support
3717 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3718 ;;
3719 esac
3720 ;;
3721 vxworks*)
3722 # FIXME: insert proper C++ library support
3723 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3724 ;;
3725 *)
3726 # FIXME: insert proper C++ library support
3727 _LT_AC_TAGVAR(ld_shlibs, $1)=no
3728 ;;
3729 esac
3730 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
3731 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
3732
3733 _LT_AC_TAGVAR(GCC, $1)="$GXX"
3734 _LT_AC_TAGVAR(LD, $1)="$LD"
3735
3736 AC_LIBTOOL_POSTDEP_PREDEP($1)
3737 AC_LIBTOOL_PROG_COMPILER_PIC($1)
3738 AC_LIBTOOL_PROG_CC_C_O($1)
3739 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3740 AC_LIBTOOL_PROG_LD_SHLIBS($1)
3741 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3742 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3743 AC_LIBTOOL_SYS_LIB_STRIP
3744 AC_LIBTOOL_DLOPEN_SELF($1)
3745
3746 AC_LIBTOOL_CONFIG($1)
3747
3748 AC_LANG_POP
3749 CC=$lt_save_CC
3750 LDCXX=$LD
3751 LD=$lt_save_LD
3752 GCC=$lt_save_GCC
3753 with_gnu_ldcxx=$with_gnu_ld
3754 with_gnu_ld=$lt_save_with_gnu_ld
3755 lt_cv_path_LDCXX=$lt_cv_path_LD
3756 lt_cv_path_LD=$lt_save_path_LD
3757 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
3758 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
3759 ])# AC_LIBTOOL_LANG_CXX_CONFIG
3760
3761 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
3762 # ------------------------
3763 # Figure out "hidden" library dependencies from verbose
3764 # compiler output when linking a shared library.
3765 # Parse the compiler output and extract the necessary
3766 # objects, libraries and library flags.
3767 AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
3768 dnl we can't use the lt_simple_compile_test_code here,
3769 dnl because it contains code intended for an executable,
3770 dnl not a library. It's possible we should let each
3771 dnl tag define a new lt_????_link_test_code variable,
3772 dnl but it's only used here...
3773 ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
3774 int a;
3775 void foo (void) { a = 0; }
3776 EOF
3777 ],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
3778 class Foo
3779 {
3780 public:
3781 Foo (void) { a = 0; }
3782 private:
3783 int a;
3784 };
3785 EOF
3786 ],[$1],[F77],[cat > conftest.$ac_ext <<EOF
3787 subroutine foo
3788 implicit none
3789 integer*4 a
3790 a=0
3791 return
3792 end
3793 EOF
3794 ],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
3795 public class foo {
3796 private int a;
3797 public void bar (void) {
3798 a = 0;
3799 }
3800 };
3801 EOF
3802 ])
3803 dnl Parse the compiler output and extract the necessary
3804 dnl objects, libraries and library flags.
3805 if AC_TRY_EVAL(ac_compile); then
3806 # Parse the compiler output and extract the necessary
3807 # objects, libraries and library flags.
3808
3809 # Sentinel used to keep track of whether or not we are before
3810 # the conftest object file.
3811 pre_test_object_deps_done=no
3812
3813 # The `*' in the case matches for architectures that use `case' in
3814 # $output_verbose_cmd can trigger glob expansion during the loop
3815 # eval without this substitution.
3816 output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`"
3817
3818 for p in `eval $output_verbose_link_cmd`; do
3819 case $p in
3820
3821 -L* | -R* | -l*)
3822 # Some compilers place space between "-{L,R}" and the path.
3823 # Remove the space.
3824 if test $p = "-L" \
3825 || test $p = "-R"; then
3826 prev=$p
3827 continue
3828 else
3829 prev=
3830 fi
3831
3832 if test "$pre_test_object_deps_done" = no; then
3833 case $p in
3834 -L* | -R*)
3835 # Internal compiler library paths should come after those
3836 # provided the user. The postdeps already come after the
3837 # user supplied libs so there is no need to process them.
3838 if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
3839 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
3840 else
3841 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
3842 fi
3843 ;;
3844 # The "-l" case would never come before the object being
3845 # linked, so don't bother handling this case.
3846 esac
3847 else
3848 if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
3849 _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
3850 else
3851 _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
3852 fi
3853 fi
3854 ;;
3855
3856 *.$objext)
3857 # This assumes that the test object file only shows up
3858 # once in the compiler output.
3859 if test "$p" = "conftest.$objext"; then
3860 pre_test_object_deps_done=yes
3861 continue
3862 fi
3863
3864 if test "$pre_test_object_deps_done" = no; then
3865 if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
3866 _LT_AC_TAGVAR(predep_objects, $1)="$p"
3867 else
3868 _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
3869 fi
3870 else
3871 if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
3872 _LT_AC_TAGVAR(postdep_objects, $1)="$p"
3873 else
3874 _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
3875 fi
3876 fi
3877 ;;
3878
3879 *) ;; # Ignore the rest.
3880
3881 esac
3882 done
3883
3884 # Clean up.
3885 rm -f a.out a.exe
3886 else
3887 echo "libtool.m4: error: problem compiling $1 test program"
3888 fi
3889
3890 $rm -f confest.$objext
3891
3892 case " $_LT_AC_TAGVAR(postdeps, $1) " in
3893 *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
3894 esac
3895 ])# AC_LIBTOOL_POSTDEP_PREDEP
3896
3897 # AC_LIBTOOL_LANG_F77_CONFIG
3898 # ------------------------
3899 # Ensure that the configuration vars for the C compiler are
3900 # suitably defined. Those variables are subsequently used by
3901 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3902 AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
3903 AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
3904 [AC_REQUIRE([AC_PROG_F77])
3905 AC_LANG_PUSH(Fortran 77)
3906
3907 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3908 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
3909 _LT_AC_TAGVAR(always_export_symbols, $1)=no
3910 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3911 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3912 _LT_AC_TAGVAR(hardcode_direct, $1)=no
3913 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3914 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3915 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3916 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3917 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
3918 _LT_AC_TAGVAR(module_cmds, $1)=
3919 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
3920 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3921 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3922 _LT_AC_TAGVAR(no_undefined_flag, $1)=
3923 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3924 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3925
3926 # Source file extension for f77 test sources.
3927 ac_ext=f
3928
3929 # Object file extension for compiled f77 test sources.
3930 objext=o
3931 _LT_AC_TAGVAR(objext, $1)=$objext
3932
3933 # Code to be used in simple compile tests
3934 lt_simple_compile_test_code=" subroutine t\n return\n end\n"
3935
3936 # Code to be used in simple link tests
3937 lt_simple_link_test_code=" program t\n end\n"
3938
3939 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
3940 _LT_AC_SYS_COMPILER
3941
3942 # save warnings/boilerplate of simple test code
3943 _LT_COMPILER_BOILERPLATE
3944 _LT_LINKER_BOILERPLATE
3945
3946 # Allow CC to be a program name with arguments.
3947 lt_save_CC="$CC"
3948 CC=${F77-"f77"}
3949 compiler=$CC
3950 _LT_AC_TAGVAR(compiler, $1)=$CC
3951 _LT_CC_BASENAME([$compiler])
3952
3953 AC_MSG_CHECKING([if libtool supports shared libraries])
3954 AC_MSG_RESULT([$can_build_shared])
3955
3956 AC_MSG_CHECKING([whether to build shared libraries])
3957 test "$can_build_shared" = "no" && enable_shared=no
3958
3959 # On AIX, shared libraries and static libraries use the same namespace, and
3960 # are all built from PIC.
3961 case "$host_os" in
3962 aix3*)
3963 test "$enable_shared" = yes && enable_static=no
3964 if test -n "$RANLIB"; then
3965 archive_cmds="$archive_cmds~\$RANLIB \$lib"
3966 postinstall_cmds='$RANLIB $lib'
3967 fi
3968 ;;
3969 aix4* | aix5*)
3970 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3971 test "$enable_shared" = yes && enable_static=no
3972 fi
3973 ;;
3974 esac
3975 AC_MSG_RESULT([$enable_shared])
3976
3977 AC_MSG_CHECKING([whether to build static libraries])
3978 # Make sure either enable_shared or enable_static is yes.
3979 test "$enable_shared" = yes || enable_static=yes
3980 AC_MSG_RESULT([$enable_static])
3981
3982 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
3983
3984 _LT_AC_TAGVAR(GCC, $1)="$G77"
3985 _LT_AC_TAGVAR(LD, $1)="$LD"
3986
3987 AC_LIBTOOL_PROG_COMPILER_PIC($1)
3988 AC_LIBTOOL_PROG_CC_C_O($1)
3989 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3990 AC_LIBTOOL_PROG_LD_SHLIBS($1)
3991 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3992 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3993 AC_LIBTOOL_SYS_LIB_STRIP
3994
3995
3996 AC_LIBTOOL_CONFIG($1)
3997
3998 AC_LANG_POP
3999 CC="$lt_save_CC"
4000 ])# AC_LIBTOOL_LANG_F77_CONFIG
4001
4002
4003 # AC_LIBTOOL_LANG_GCJ_CONFIG
4004 # --------------------------
4005 # Ensure that the configuration vars for the C compiler are
4006 # suitably defined. Those variables are subsequently used by
4007 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4008 AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
4009 AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
4010 [AC_LANG_SAVE
4011
4012 # Source file extension for Java test sources.
4013 ac_ext=java
4014
4015 # Object file extension for compiled Java test sources.
4016 objext=o
4017 _LT_AC_TAGVAR(objext, $1)=$objext
4018
4019 # Code to be used in simple compile tests
4020 lt_simple_compile_test_code="class foo {}\n"
4021
4022 # Code to be used in simple link tests
4023 lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
4024
4025 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4026 _LT_AC_SYS_COMPILER
4027
4028 # save warnings/boilerplate of simple test code
4029 _LT_COMPILER_BOILERPLATE
4030 _LT_LINKER_BOILERPLATE
4031
4032 # Allow CC to be a program name with arguments.
4033 lt_save_CC="$CC"
4034 CC=${GCJ-"gcj"}
4035 compiler=$CC
4036 _LT_AC_TAGVAR(compiler, $1)=$CC
4037 _LT_CC_BASENAME([$compiler])
4038
4039 # GCJ did not exist at the time GCC didn't implicitly link libc in.
4040 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4041
4042 _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
4043
4044 AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
4045 AC_LIBTOOL_PROG_COMPILER_PIC($1)
4046 AC_LIBTOOL_PROG_CC_C_O($1)
4047 AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4048 AC_LIBTOOL_PROG_LD_SHLIBS($1)
4049 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4050 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4051 AC_LIBTOOL_SYS_LIB_STRIP
4052 AC_LIBTOOL_DLOPEN_SELF($1)
4053
4054 AC_LIBTOOL_CONFIG($1)
4055
4056 AC_LANG_RESTORE
4057 CC="$lt_save_CC"
4058 ])# AC_LIBTOOL_LANG_GCJ_CONFIG
4059
4060
4061 # AC_LIBTOOL_LANG_RC_CONFIG
4062 # --------------------------
4063 # Ensure that the configuration vars for the Windows resource compiler are
4064 # suitably defined. Those variables are subsequently used by
4065 # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4066 AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
4067 AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
4068 [AC_LANG_SAVE
4069
4070 # Source file extension for RC test sources.
4071 ac_ext=rc
4072
4073 # Object file extension for compiled RC test sources.
4074 objext=o
4075 _LT_AC_TAGVAR(objext, $1)=$objext
4076
4077 # Code to be used in simple compile tests
4078 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
4079
4080 # Code to be used in simple link tests
4081 lt_simple_link_test_code="$lt_simple_compile_test_code"
4082
4083 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
4084 _LT_AC_SYS_COMPILER
4085
4086 # save warnings/boilerplate of simple test code
4087 _LT_COMPILER_BOILERPLATE
4088 _LT_LINKER_BOILERPLATE
4089
4090 # Allow CC to be a program name with arguments.
4091 lt_save_CC="$CC"
4092 CC=${RC-"windres"}
4093 compiler=$CC
4094 _LT_AC_TAGVAR(compiler, $1)=$CC
4095 _LT_CC_BASENAME([$compiler])
4096 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
4097
4098 AC_LIBTOOL_CONFIG($1)
4099
4100 AC_LANG_RESTORE
4101 CC="$lt_save_CC"
4102 ])# AC_LIBTOOL_LANG_RC_CONFIG
4103
4104
4105 # AC_LIBTOOL_CONFIG([TAGNAME])
4106 # ----------------------------
4107 # If TAGNAME is not passed, then create an initial libtool script
4108 # with a default configuration from the untagged config vars. Otherwise
4109 # add code to config.status for appending the configuration named by
4110 # TAGNAME from the matching tagged config vars.
4111 AC_DEFUN([AC_LIBTOOL_CONFIG],
4112 [# The else clause should only fire when bootstrapping the
4113 # libtool distribution, otherwise you forgot to ship ltmain.sh
4114 # with your package, and you will get complaints that there are
4115 # no rules to generate ltmain.sh.
4116 if test -f "$ltmain"; then
4117 # See if we are running on zsh, and set the options which allow our commands through
4118 # without removal of \ escapes.
4119 if test -n "${ZSH_VERSION+set}" ; then
4120 setopt NO_GLOB_SUBST
4121 fi
4122 # Now quote all the things that may contain metacharacters while being
4123 # careful not to overquote the AC_SUBSTed values. We take copies of the
4124 # variables and quote the copies for generation of the libtool script.
4125 for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
4126 SED SHELL STRIP \
4127 libname_spec library_names_spec soname_spec extract_expsyms_cmds \
4128 old_striplib striplib file_magic_cmd finish_cmds finish_eval \
4129 deplibs_check_method reload_flag reload_cmds need_locks \
4130 lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
4131 lt_cv_sys_global_symbol_to_c_name_address \
4132 sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
4133 old_postinstall_cmds old_postuninstall_cmds \
4134 _LT_AC_TAGVAR(compiler, $1) \
4135 _LT_AC_TAGVAR(CC, $1) \
4136 _LT_AC_TAGVAR(LD, $1) \
4137 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
4138 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
4139 _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
4140 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
4141 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
4142 _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
4143 _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
4144 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
4145 _LT_AC_TAGVAR(old_archive_cmds, $1) \
4146 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
4147 _LT_AC_TAGVAR(predep_objects, $1) \
4148 _LT_AC_TAGVAR(postdep_objects, $1) \
4149 _LT_AC_TAGVAR(predeps, $1) \
4150 _LT_AC_TAGVAR(postdeps, $1) \
4151 _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
4152 _LT_AC_TAGVAR(archive_cmds, $1) \
4153 _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
4154 _LT_AC_TAGVAR(postinstall_cmds, $1) \
4155 _LT_AC_TAGVAR(postuninstall_cmds, $1) \
4156 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
4157 _LT_AC_TAGVAR(allow_undefined_flag, $1) \
4158 _LT_AC_TAGVAR(no_undefined_flag, $1) \
4159 _LT_AC_TAGVAR(export_symbols_cmds, $1) \
4160 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
4161 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
4162 _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
4163 _LT_AC_TAGVAR(hardcode_automatic, $1) \
4164 _LT_AC_TAGVAR(module_cmds, $1) \
4165 _LT_AC_TAGVAR(module_expsym_cmds, $1) \
4166 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
4167 _LT_AC_TAGVAR(exclude_expsyms, $1) \
4168 _LT_AC_TAGVAR(include_expsyms, $1); do
4169
4170 case $var in
4171 _LT_AC_TAGVAR(old_archive_cmds, $1) | \
4172 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
4173 _LT_AC_TAGVAR(archive_cmds, $1) | \
4174 _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
4175 _LT_AC_TAGVAR(module_cmds, $1) | \
4176 _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
4177 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
4178 _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
4179 extract_expsyms_cmds | reload_cmds | finish_cmds | \
4180 postinstall_cmds | postuninstall_cmds | \
4181 old_postinstall_cmds | old_postuninstall_cmds | \
4182 sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
4183 # Double-quote double-evaled strings.
4184 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
4185 ;;
4186 *)
4187 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
4188 ;;
4189 esac
4190 done
4191
4192 case $lt_echo in
4193 *'\[$]0 --fallback-echo"')
4194 lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
4195 ;;
4196 esac
4197
4198 ifelse([$1], [],
4199 [cfgfile="${ofile}T"
4200 trap "$rm \"$cfgfile\"; exit 1" 1 2 15
4201 $rm -f "$cfgfile"
4202 AC_MSG_NOTICE([creating $ofile])],
4203 [cfgfile="$ofile"])
4204
4205 cat <<__EOF__ >> "$cfgfile"
4206 ifelse([$1], [],
4207 [#! $SHELL
4208
4209 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
4210 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
4211 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
4212 #
4213 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
4214 # Free Software Foundation, Inc.
4215 #
4216 # This file is part of GNU Libtool:
4217 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
4218 #
4219 # This program is free software; you can redistribute it and/or modify
4220 # it under the terms of the GNU General Public License as published by
4221 # the Free Software Foundation; either version 2 of the License, or
4222 # (at your option) any later version.
4223 #
4224 # This program is distributed in the hope that it will be useful, but
4225 # WITHOUT ANY WARRANTY; without even the implied warranty of
4226 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4227 # General Public License for more details.
4228 #
4229 # You should have received a copy of the GNU General Public License
4230 # along with this program; if not, write to the Free Software
4231 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
4232 #
4233 # As a special exception to the GNU General Public License, if you
4234 # distribute this file as part of a program that contains a
4235 # configuration script generated by Autoconf, you may include it under
4236 # the same distribution terms that you use for the rest of that program.
4237
4238 # A sed program that does not truncate output.
4239 SED=$lt_SED
4240
4241 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
4242 Xsed="$SED -e 1s/^X//"
4243
4244 # The HP-UX ksh and POSIX shell print the target directory to stdout
4245 # if CDPATH is set.
4246 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
4247
4248 # The names of the tagged configurations supported by this script.
4249 available_tags=
4250
4251 # ### BEGIN LIBTOOL CONFIG],
4252 [# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
4253
4254 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4255
4256 # Shell to use when invoking shell scripts.
4257 SHELL=$lt_SHELL
4258
4259 # Whether or not to build shared libraries.
4260 build_libtool_libs=$enable_shared
4261
4262 # Whether or not to build static libraries.
4263 build_old_libs=$enable_static
4264
4265 # Whether or not to add -lc for building shared libraries.
4266 build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
4267
4268 # Whether or not to disallow shared libs when runtime libs are static
4269 allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
4270
4271 # Whether or not to optimize for fast installation.
4272 fast_install=$enable_fast_install
4273
4274 # The host system.
4275 host_alias=$host_alias
4276 host=$host
4277 host_os=$host_os
4278
4279 # The build system.
4280 build_alias=$build_alias
4281 build=$build
4282 build_os=$build_os
4283
4284 # An echo program that does not interpret backslashes.
4285 echo=$lt_echo
4286
4287 # The archiver.
4288 AR=$lt_AR
4289 AR_FLAGS=$lt_AR_FLAGS
4290
4291 # A C compiler.
4292 LTCC=$lt_LTCC
4293
4294 # A language-specific compiler.
4295 CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
4296
4297 # Is the compiler the GNU C compiler?
4298 with_gcc=$_LT_AC_TAGVAR(GCC, $1)
4299
4300 # An ERE matcher.
4301 EGREP=$lt_EGREP
4302
4303 # The linker used to build libraries.
4304 LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
4305
4306 # Whether we need hard or soft links.
4307 LN_S=$lt_LN_S
4308
4309 # A BSD-compatible nm program.
4310 NM=$lt_NM
4311
4312 # A symbol stripping program
4313 STRIP=$lt_STRIP
4314
4315 # Used to examine libraries when file_magic_cmd begins "file"
4316 MAGIC_CMD=$MAGIC_CMD
4317
4318 # Used on cygwin: DLL creation program.
4319 DLLTOOL="$DLLTOOL"
4320
4321 # Used on cygwin: object dumper.
4322 OBJDUMP="$OBJDUMP"
4323
4324 # Used on cygwin: assembler.
4325 AS="$AS"
4326
4327 # The name of the directory that contains temporary libtool files.
4328 objdir=$objdir
4329
4330 # How to create reloadable object files.
4331 reload_flag=$lt_reload_flag
4332 reload_cmds=$lt_reload_cmds
4333
4334 # How to pass a linker flag through the compiler.
4335 wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
4336
4337 # Object file suffix (normally "o").
4338 objext="$ac_objext"
4339
4340 # Old archive suffix (normally "a").
4341 libext="$libext"
4342
4343 # Shared library suffix (normally ".so").
4344 shrext_cmds='$shrext_cmds'
4345
4346 # Executable file suffix (normally "").
4347 exeext="$exeext"
4348
4349 # Additional compiler flags for building library objects.
4350 pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
4351 pic_mode=$pic_mode
4352
4353 # What is the maximum length of a command?
4354 max_cmd_len=$lt_cv_sys_max_cmd_len
4355
4356 # Does compiler simultaneously support -c and -o options?
4357 compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
4358
4359 # Must we lock files when doing compilation?
4360 need_locks=$lt_need_locks
4361
4362 # Do we need the lib prefix for modules?
4363 need_lib_prefix=$need_lib_prefix
4364
4365 # Do we need a version for libraries?
4366 need_version=$need_version
4367
4368 # Whether dlopen is supported.
4369 dlopen_support=$enable_dlopen
4370
4371 # Whether dlopen of programs is supported.
4372 dlopen_self=$enable_dlopen_self
4373
4374 # Whether dlopen of statically linked programs is supported.
4375 dlopen_self_static=$enable_dlopen_self_static
4376
4377 # Compiler flag to prevent dynamic linking.
4378 link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
4379
4380 # Compiler flag to turn off builtin functions.
4381 no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
4382
4383 # Compiler flag to allow reflexive dlopens.
4384 export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
4385
4386 # Compiler flag to generate shared objects directly from archives.
4387 whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
4388
4389 # Compiler flag to generate thread-safe objects.
4390 thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
4391
4392 # Library versioning type.
4393 version_type=$version_type
4394
4395 # Format of library name prefix.
4396 libname_spec=$lt_libname_spec
4397
4398 # List of archive names. First name is the real one, the rest are links.
4399 # The last name is the one that the linker finds with -lNAME.
4400 library_names_spec=$lt_library_names_spec
4401
4402 # The coded name of the library, if different from the real name.
4403 soname_spec=$lt_soname_spec
4404
4405 # Commands used to build and install an old-style archive.
4406 RANLIB=$lt_RANLIB
4407 old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
4408 old_postinstall_cmds=$lt_old_postinstall_cmds
4409 old_postuninstall_cmds=$lt_old_postuninstall_cmds
4410
4411 # Create an old-style archive from a shared archive.
4412 old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
4413
4414 # Create a temporary old-style archive to link instead of a shared archive.
4415 old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
4416
4417 # Commands used to build and install a shared archive.
4418 archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
4419 archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
4420 postinstall_cmds=$lt_postinstall_cmds
4421 postuninstall_cmds=$lt_postuninstall_cmds
4422
4423 # Commands used to build a loadable module (assumed same as above if empty)
4424 module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
4425 module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
4426
4427 # Commands to strip libraries.
4428 old_striplib=$lt_old_striplib
4429 striplib=$lt_striplib
4430
4431 # Dependencies to place before the objects being linked to create a
4432 # shared library.
4433 predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
4434
4435 # Dependencies to place after the objects being linked to create a
4436 # shared library.
4437 postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
4438
4439 # Dependencies to place before the objects being linked to create a
4440 # shared library.
4441 predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
4442
4443 # Dependencies to place after the objects being linked to create a
4444 # shared library.
4445 postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
4446
4447 # The library search path used internally by the compiler when linking
4448 # a shared library.
4449 compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
4450
4451 # Method to check whether dependent libraries are shared objects.
4452 deplibs_check_method=$lt_deplibs_check_method
4453
4454 # Command to use when deplibs_check_method == file_magic.
4455 file_magic_cmd=$lt_file_magic_cmd
4456
4457 # Flag that allows shared libraries with undefined symbols to be built.
4458 allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
4459
4460 # Flag that forces no undefined symbols.
4461 no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
4462
4463 # Commands used to finish a libtool library installation in a directory.
4464 finish_cmds=$lt_finish_cmds
4465
4466 # Same as above, but a single script fragment to be evaled but not shown.
4467 finish_eval=$lt_finish_eval
4468
4469 # Take the output of nm and produce a listing of raw symbols and C names.
4470 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
4471
4472 # Transform the output of nm in a proper C declaration
4473 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
4474
4475 # Transform the output of nm in a C name address pair
4476 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
4477
4478 # This is the shared library runtime path variable.
4479 runpath_var=$runpath_var
4480
4481 # This is the shared library path variable.
4482 shlibpath_var=$shlibpath_var
4483
4484 # Is shlibpath searched before the hard-coded library search path?
4485 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
4486
4487 # How to hardcode a shared library path into an executable.
4488 hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
4489
4490 # Whether we should hardcode library paths into libraries.
4491 hardcode_into_libs=$hardcode_into_libs
4492
4493 # Flag to hardcode \$libdir into a binary during linking.
4494 # This must work even if \$libdir does not exist.
4495 hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
4496
4497 # If ld is used when linking, flag to hardcode \$libdir into
4498 # a binary during linking. This must work even if \$libdir does
4499 # not exist.
4500 hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
4501
4502 # Whether we need a single -rpath flag with a separated argument.
4503 hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
4504
4505 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
4506 # resulting binary.
4507 hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
4508
4509 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
4510 # resulting binary.
4511 hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
4512
4513 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
4514 # the resulting binary.
4515 hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
4516
4517 # Set to yes if building a shared library automatically hardcodes DIR into the library
4518 # and all subsequent libraries and executables linked against it.
4519 hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
4520
4521 # Variables whose values should be saved in libtool wrapper scripts and
4522 # restored at relink time.
4523 variables_saved_for_relink="$variables_saved_for_relink"
4524
4525 # Whether libtool must link a program against all its dependency libraries.
4526 link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
4527
4528 # Compile-time system search path for libraries
4529 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
4530
4531 # Run-time system search path for libraries
4532 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
4533
4534 # Fix the shell variable \$srcfile for the compiler.
4535 fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
4536
4537 # Set to yes if exported symbols are required.
4538 always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
4539
4540 # The commands to list exported symbols.
4541 export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
4542
4543 # The commands to extract the exported symbol list from a shared archive.
4544 extract_expsyms_cmds=$lt_extract_expsyms_cmds
4545
4546 # Symbols that should not be listed in the preloaded symbols.
4547 exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
4548
4549 # Symbols that must always be exported.
4550 include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
4551
4552 ifelse([$1],[],
4553 [# ### END LIBTOOL CONFIG],
4554 [# ### END LIBTOOL TAG CONFIG: $tagname])
4555
4556 __EOF__
4557
4558 ifelse([$1],[], [
4559 case $host_os in
4560 aix3*)
4561 cat <<\EOF >> "$cfgfile"
4562
4563 # AIX sometimes has problems with the GCC collect2 program. For some
4564 # reason, if we set the COLLECT_NAMES environment variable, the problems
4565 # vanish in a puff of smoke.
4566 if test "X${COLLECT_NAMES+set}" != Xset; then
4567 COLLECT_NAMES=
4568 export COLLECT_NAMES
4569 fi
4570 EOF
4571 ;;
4572 esac
4573
4574 # We use sed instead of cat because bash on DJGPP gets confused if
4575 # if finds mixed CR/LF and LF-only lines. Since sed operates in
4576 # text mode, it properly converts lines to CR/LF. This bash problem
4577 # is reportedly fixed, but why not run on old versions too?
4578 sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
4579
4580 mv -f "$cfgfile" "$ofile" || \
4581 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
4582 chmod +x "$ofile"
4583 ])
4584 else
4585 # If there is no Makefile yet, we rely on a make rule to execute
4586 # `config.status --recheck' to rerun these tests and create the
4587 # libtool script then.
4588 ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
4589 if test -f "$ltmain_in"; then
4590 test -f Makefile && make "$ltmain"
4591 fi
4592 fi
4593 ])# AC_LIBTOOL_CONFIG
4594
4595
4596 # AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
4597 # -------------------------------------------
4598 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
4599 [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
4600
4601 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
4602
4603 if test "$GCC" = yes; then
4604 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
4605
4606 AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
4607 lt_cv_prog_compiler_rtti_exceptions,
4608 [-fno-rtti -fno-exceptions], [],
4609 [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
4610 fi
4611 ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
4612
4613
4614 # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
4615 # ---------------------------------
4616 AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
4617 [AC_REQUIRE([AC_CANONICAL_HOST])
4618 AC_REQUIRE([AC_PROG_NM])
4619 AC_REQUIRE([AC_OBJEXT])
4620 # Check for command to grab the raw symbol name followed by C symbol from nm.
4621 AC_MSG_CHECKING([command to parse $NM output from $compiler object])
4622 AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
4623 [
4624 # These are sane defaults that work on at least a few old systems.
4625 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
4626
4627 # Character class describing NM global symbol codes.
4628 symcode='[[BCDEGRST]]'
4629
4630 # Regexp to match symbols that can be accessed directly from C.
4631 sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
4632
4633 # Transform an extracted symbol line into a proper C declaration
4634 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
4635
4636 # Transform an extracted symbol line into symbol name and symbol address
4637 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
4638
4639 # Define system-specific variables.
4640 case $host_os in
4641 aix*)
4642 symcode='[[BCDT]]'
4643 ;;
4644 cygwin* | mingw* | pw32*)
4645 symcode='[[ABCDGISTW]]'
4646 ;;
4647 hpux*) # Its linker distinguishes data from code symbols
4648 if test "$host_cpu" = ia64; then
4649 symcode='[[ABCDEGRST]]'
4650 fi
4651 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4652 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
4653 ;;
4654 linux*)
4655 if test "$host_cpu" = ia64; then
4656 symcode='[[ABCDGIRSTW]]'
4657 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
4658 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
4659 fi
4660 ;;
4661 irix* | nonstopux*)
4662 symcode='[[BCDEGRST]]'
4663 ;;
4664 osf*)
4665 symcode='[[BCDEGQRST]]'
4666 ;;
4667 solaris* | sysv5*)
4668 symcode='[[BDRT]]'
4669 ;;
4670 sysv4)
4671 symcode='[[DFNSTU]]'
4672 ;;
4673 esac
4674
4675 # Handle CRLF in mingw tool chain
4676 opt_cr=
4677 case $build_os in
4678 mingw*)
4679 opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
4680 ;;
4681 esac
4682
4683 # If we're using GNU nm, then use its standard symbol codes.
4684 case `$NM -V 2>&1` in
4685 *GNU* | *'with BFD'*)
4686 symcode='[[ABCDGIRSTW]]' ;;
4687 esac
4688
4689 # Try without a prefix undercore, then with it.
4690 for ac_symprfx in "" "_"; do
4691
4692 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
4693 symxfrm="\\1 $ac_symprfx\\2 \\2"
4694
4695 # Write the raw and C identifiers.
4696 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
4697
4698 # Check to see that the pipe works correctly.
4699 pipe_works=no
4700
4701 rm -f conftest*
4702 cat > conftest.$ac_ext <<EOF
4703 #ifdef __cplusplus
4704 extern "C" {
4705 #endif
4706 char nm_test_var;
4707 void nm_test_func(){}
4708 #ifdef __cplusplus
4709 }
4710 #endif
4711 int main(){nm_test_var='a';nm_test_func();return(0);}
4712 EOF
4713
4714 if AC_TRY_EVAL(ac_compile); then
4715 # Now try to grab the symbols.
4716 nlist=conftest.nm
4717 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
4718 # Try sorting and uniquifying the output.
4719 if sort "$nlist" | uniq > "$nlist"T; then
4720 mv -f "$nlist"T "$nlist"
4721 else
4722 rm -f "$nlist"T
4723 fi
4724
4725 # Make sure that we snagged all the symbols we need.
4726 if grep ' nm_test_var$' "$nlist" >/dev/null; then
4727 if grep ' nm_test_func$' "$nlist" >/dev/null; then
4728 cat <<EOF > conftest.$ac_ext
4729 #ifdef __cplusplus
4730 extern "C" {
4731 #endif
4732
4733 EOF
4734 # Now generate the symbol file.
4735 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
4736
4737 cat <<EOF >> conftest.$ac_ext
4738 #if defined (__STDC__) && __STDC__
4739 # define lt_ptr_t void *
4740 #else
4741 # define lt_ptr_t char *
4742 # define const
4743 #endif
4744
4745 /* The mapping between symbol names and symbols. */
4746 const struct {
4747 const char *name;
4748 lt_ptr_t address;
4749 }
4750 lt_preloaded_symbols[[]] =
4751 {
4752 EOF
4753 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
4754 cat <<\EOF >> conftest.$ac_ext
4755 {0, (lt_ptr_t) 0}
4756 };
4757
4758 #ifdef __cplusplus
4759 }
4760 #endif
4761 EOF
4762 # Now try linking the two files.
4763 mv conftest.$ac_objext conftstm.$ac_objext
4764 lt_save_LIBS="$LIBS"
4765 lt_save_CFLAGS="$CFLAGS"
4766 LIBS="conftstm.$ac_objext"
4767 CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
4768 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4769 pipe_works=yes
4770 fi
4771 LIBS="$lt_save_LIBS"
4772 CFLAGS="$lt_save_CFLAGS"
4773 else
4774 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
4775 fi
4776 else
4777 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
4778 fi
4779 else
4780 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
4781 fi
4782 else
4783 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
4784 cat conftest.$ac_ext >&5
4785 fi
4786 rm -f conftest* conftst*
4787
4788 # Do not use the global_symbol_pipe unless it works.
4789 if test "$pipe_works" = yes; then
4790 break
4791 else
4792 lt_cv_sys_global_symbol_pipe=
4793 fi
4794 done
4795 ])
4796 if test -z "$lt_cv_sys_global_symbol_pipe"; then
4797 lt_cv_sys_global_symbol_to_cdecl=
4798 fi
4799 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
4800 AC_MSG_RESULT(failed)
4801 else
4802 AC_MSG_RESULT(ok)
4803 fi
4804 ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
4805
4806
4807 # AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
4808 # ---------------------------------------
4809 AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
4810 [_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
4811 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4812 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
4813
4814 AC_MSG_CHECKING([for $compiler option to produce PIC])
4815 ifelse([$1],[CXX],[
4816 # C++ specific cases for pic, static, wl, etc.
4817 if test "$GXX" = yes; then
4818 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4819 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
4820
4821 case $host_os in
4822 aix*)
4823 # All AIX code is PIC.
4824 if test "$host_cpu" = ia64; then
4825 # AIX 5 now supports IA64 processor
4826 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4827 fi
4828 ;;
4829 amigaos*)
4830 # FIXME: we need at least 68020 code to build shared libraries, but
4831 # adding the `-m68020' flag to GCC prevents building anything better,
4832 # like `-m68040'.
4833 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
4834 ;;
4835 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
4836 # PIC is the default for these OSes.
4837 ;;
4838 mingw* | os2* | pw32*)
4839 # This hack is so that the source file can tell whether it is being
4840 # built for inclusion in a dll (and should export symbols for example).
4841 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
4842 ;;
4843 darwin* | rhapsody*)
4844 # PIC is the default on this platform
4845 # Common symbols not allowed in MH_DYLIB files
4846 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4847 ;;
4848 *djgpp*)
4849 # DJGPP does not support shared libraries at all
4850 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4851 ;;
4852 sysv4*MP*)
4853 if test -d /usr/nec; then
4854 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
4855 fi
4856 ;;
4857 hpux*)
4858 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
4859 # not for PA HP-UX.
4860 case "$host_cpu" in
4861 hppa*64*|ia64*)
4862 ;;
4863 *)
4864 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4865 ;;
4866 esac
4867 ;;
4868 *)
4869 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4870 ;;
4871 esac
4872 else
4873 case $host_os in
4874 aix4* | aix5*)
4875 # All AIX code is PIC.
4876 if test "$host_cpu" = ia64; then
4877 # AIX 5 now supports IA64 processor
4878 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4879 else
4880 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
4881 fi
4882 ;;
4883 chorus*)
4884 case $cc_basename in
4885 cxch68*)
4886 # Green Hills C++ Compiler
4887 # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
4888 ;;
4889 esac
4890 ;;
4891 darwin*)
4892 # PIC is the default on this platform
4893 # Common symbols not allowed in MH_DYLIB files
4894 case $cc_basename in
4895 xlc*)
4896 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
4897 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4898 ;;
4899 esac
4900 ;;
4901 dgux*)
4902 case $cc_basename in
4903 ec++*)
4904 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4905 ;;
4906 ghcx*)
4907 # Green Hills C++ Compiler
4908 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
4909 ;;
4910 *)
4911 ;;
4912 esac
4913 ;;
4914 freebsd* | kfreebsd*-gnu | dragonfly*)
4915 # FreeBSD uses GNU C++
4916 ;;
4917 hpux9* | hpux10* | hpux11*)
4918 case $cc_basename in
4919 CC*)
4920 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4921 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
4922 if test "$host_cpu" != ia64; then
4923 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4924 fi
4925 ;;
4926 aCC*)
4927 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4928 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
4929 case "$host_cpu" in
4930 hppa*64*|ia64*)
4931 # +Z the default
4932 ;;
4933 *)
4934 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
4935 ;;
4936 esac
4937 ;;
4938 *)
4939 ;;
4940 esac
4941 ;;
4942 irix5* | irix6* | nonstopux*)
4943 case $cc_basename in
4944 CC*)
4945 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4946 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4947 # CC pic flag -KPIC is the default.
4948 ;;
4949 *)
4950 ;;
4951 esac
4952 ;;
4953 linux*)
4954 case $cc_basename in
4955 KCC*)
4956 # KAI C++ Compiler
4957 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
4958 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4959 ;;
4960 icpc* | ecpc*)
4961 # Intel C++
4962 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4963 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4964 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
4965 ;;
4966 pgCC*)
4967 # Portland Group C++ compiler.
4968 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4969 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
4970 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
4971 ;;
4972 cxx*)
4973 # Compaq C++
4974 # Make sure the PIC flag is empty. It appears that all Alpha
4975 # Linux and Compaq Tru64 Unix objects are PIC.
4976 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
4977 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
4978 ;;
4979 *)
4980 ;;
4981 esac
4982 ;;
4983 lynxos*)
4984 ;;
4985 m88k*)
4986 ;;
4987 mvs*)
4988 case $cc_basename in
4989 cxx*)
4990 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
4991 ;;
4992 *)
4993 ;;
4994 esac
4995 ;;
4996 netbsd*)
4997 ;;
4998 osf3* | osf4* | osf5*)
4999 case $cc_basename in
5000 KCC*)
5001 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
5002 ;;
5003 RCC*)
5004 # Rational C++ 2.4.1
5005 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5006 ;;
5007 cxx*)
5008 # Digital/Compaq C++
5009 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5010 # Make sure the PIC flag is empty. It appears that all Alpha
5011 # Linux and Compaq Tru64 Unix objects are PIC.
5012 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5013 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5014 ;;
5015 *)
5016 ;;
5017 esac
5018 ;;
5019 psos*)
5020 ;;
5021 sco*)
5022 case $cc_basename in
5023 CC*)
5024 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5025 ;;
5026 *)
5027 ;;
5028 esac
5029 ;;
5030 solaris*)
5031 case $cc_basename in
5032 CC*)
5033 # Sun C++ 4.2, 5.x and Centerline C++
5034 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5035 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5036 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5037 ;;
5038 gcx*)
5039 # Green Hills C++ Compiler
5040 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5041 ;;
5042 *)
5043 ;;
5044 esac
5045 ;;
5046 sunos4*)
5047 case $cc_basename in
5048 CC*)
5049 # Sun C++ 4.x
5050 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5051 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5052 ;;
5053 lcc*)
5054 # Lucid
5055 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5056 ;;
5057 *)
5058 ;;
5059 esac
5060 ;;
5061 tandem*)
5062 case $cc_basename in
5063 NCC*)
5064 # NonStop-UX NCC 3.20
5065 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5066 ;;
5067 *)
5068 ;;
5069 esac
5070 ;;
5071 unixware*)
5072 ;;
5073 vxworks*)
5074 ;;
5075 *)
5076 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5077 ;;
5078 esac
5079 fi
5080 ],
5081 [
5082 if test "$GCC" = yes; then
5083 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5084 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5085
5086 case $host_os in
5087 aix*)
5088 # All AIX code is PIC.
5089 if test "$host_cpu" = ia64; then
5090 # AIX 5 now supports IA64 processor
5091 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5092 fi
5093 ;;
5094
5095 amigaos*)
5096 # FIXME: we need at least 68020 code to build shared libraries, but
5097 # adding the `-m68020' flag to GCC prevents building anything better,
5098 # like `-m68040'.
5099 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5100 ;;
5101
5102 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5103 # PIC is the default for these OSes.
5104 ;;
5105
5106 mingw* | pw32* | os2*)
5107 # This hack is so that the source file can tell whether it is being
5108 # built for inclusion in a dll (and should export symbols for example).
5109 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5110 ;;
5111
5112 darwin* | rhapsody*)
5113 # PIC is the default on this platform
5114 # Common symbols not allowed in MH_DYLIB files
5115 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5116 ;;
5117
5118 msdosdjgpp*)
5119 # Just because we use GCC doesn't mean we suddenly get shared libraries
5120 # on systems that don't support them.
5121 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5122 enable_shared=no
5123 ;;
5124
5125 sysv4*MP*)
5126 if test -d /usr/nec; then
5127 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5128 fi
5129 ;;
5130
5131 hpux*)
5132 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5133 # not for PA HP-UX.
5134 case "$host_cpu" in
5135 hppa*64*|ia64*)
5136 # +Z the default
5137 ;;
5138 *)
5139 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5140 ;;
5141 esac
5142 ;;
5143
5144 *)
5145 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5146 ;;
5147 esac
5148 else
5149 # PORTME Check for flag to pass linker flags through the system compiler.
5150 case $host_os in
5151 aix*)
5152 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5153 if test "$host_cpu" = ia64; then
5154 # AIX 5 now supports IA64 processor
5155 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5156 else
5157 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
5158 fi
5159 ;;
5160 darwin*)
5161 # PIC is the default on this platform
5162 # Common symbols not allowed in MH_DYLIB files
5163 case $cc_basename in
5164 xlc*)
5165 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
5166 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5167 ;;
5168 esac
5169 ;;
5170
5171 mingw* | pw32* | os2*)
5172 # This hack is so that the source file can tell whether it is being
5173 # built for inclusion in a dll (and should export symbols for example).
5174 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
5175 ;;
5176
5177 hpux9* | hpux10* | hpux11*)
5178 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5179 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5180 # not for PA HP-UX.
5181 case "$host_cpu" in
5182 hppa*64*|ia64*)
5183 # +Z the default
5184 ;;
5185 *)
5186 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
5187 ;;
5188 esac
5189 # Is there a better lt_prog_compiler_static that works with the bundled CC?
5190 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
5191 ;;
5192
5193 irix5* | irix6* | nonstopux*)
5194 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5195 # PIC (with -KPIC) is the default.
5196 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5197 ;;
5198
5199 newsos6)
5200 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5201 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5202 ;;
5203
5204 linux*)
5205 case $cc_basename in
5206 icc* | ecc*)
5207 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5208 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5209 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5210 ;;
5211 pgcc* | pgf77* | pgf90*)
5212 # Portland Group compilers (*not* the Pentium gcc compiler,
5213 # which looks to be a dead project)
5214 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5215 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
5216 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5217 ;;
5218 ccc*)
5219 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5220 # All Alpha code is PIC.
5221 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5222 ;;
5223 esac
5224 ;;
5225
5226 osf3* | osf4* | osf5*)
5227 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5228 # All OSF/1 code is PIC.
5229 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
5230 ;;
5231
5232 sco3.2v5*)
5233 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
5234 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
5235 ;;
5236
5237 solaris*)
5238 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5239 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5240 case $cc_basename in
5241 f77* | f90* | f95*)
5242 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
5243 *)
5244 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
5245 esac
5246 ;;
5247
5248 sunos4*)
5249 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
5250 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
5251 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5252 ;;
5253
5254 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5255 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5256 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
5257 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5258 ;;
5259
5260 sysv4*MP*)
5261 if test -d /usr/nec ;then
5262 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
5263 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5264 fi
5265 ;;
5266
5267 unicos*)
5268 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5269 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5270 ;;
5271
5272 uts4*)
5273 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
5274 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5275 ;;
5276
5277 *)
5278 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
5279 ;;
5280 esac
5281 fi
5282 ])
5283 AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
5284
5285 #
5286 # Check to make sure the PIC flag actually works.
5287 #
5288 if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
5289 AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
5290 _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
5291 [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
5292 [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
5293 "" | " "*) ;;
5294 *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
5295 esac],
5296 [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5297 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
5298 fi
5299 case "$host_os" in
5300 # For platforms which do not support PIC, -DPIC is meaningless:
5301 *djgpp*)
5302 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5303 ;;
5304 *)
5305 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
5306 ;;
5307 esac
5308 ])
5309
5310
5311 # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
5312 # ------------------------------------
5313 # See if the linker supports building shared libraries.
5314 AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
5315 [AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
5316 ifelse([$1],[CXX],[
5317 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5318 case $host_os in
5319 aix4* | aix5*)
5320 # If we're using GNU nm, then we don't want the "-C" option.
5321 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5322 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5323 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
5324 else
5325 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
5326 fi
5327 ;;
5328 pw32*)
5329 _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
5330 ;;
5331 cygwin* | mingw*)
5332 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
5333 ;;
5334 *)
5335 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5336 ;;
5337 esac
5338 ],[
5339 runpath_var=
5340 _LT_AC_TAGVAR(allow_undefined_flag, $1)=
5341 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5342 _LT_AC_TAGVAR(archive_cmds, $1)=
5343 _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
5344 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
5345 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
5346 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5347 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5348 _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
5349 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5350 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5351 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5352 _LT_AC_TAGVAR(hardcode_direct, $1)=no
5353 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
5354 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
5355 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
5356 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
5357 _LT_AC_TAGVAR(module_cmds, $1)=
5358 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
5359 _LT_AC_TAGVAR(always_export_symbols, $1)=no
5360 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
5361 # include_expsyms should be a list of space-separated symbols to be *always*
5362 # included in the symbol list
5363 _LT_AC_TAGVAR(include_expsyms, $1)=
5364 # exclude_expsyms can be an extended regexp of symbols to exclude
5365 # it will be wrapped by ` (' and `)$', so one must not match beginning or
5366 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
5367 # as well as any symbol that contains `d'.
5368 _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
5369 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
5370 # platforms (ab)use it in PIC code, but their linkers get confused if
5371 # the symbol is explicitly referenced. Since portable code cannot
5372 # rely on this symbol name, it's probably fine to never include it in
5373 # preloaded symbol tables.
5374 extract_expsyms_cmds=
5375 # Just being paranoid about ensuring that cc_basename is set.
5376 _LT_CC_BASENAME([$compiler])
5377 case $host_os in
5378 cygwin* | mingw* | pw32*)
5379 # FIXME: the MSVC++ port hasn't been tested in a loooong time
5380 # When not using gcc, we currently assume that we are using
5381 # Microsoft Visual C++.
5382 if test "$GCC" != yes; then
5383 with_gnu_ld=no
5384 fi
5385 ;;
5386 openbsd*)
5387 with_gnu_ld=no
5388 ;;
5389 esac
5390
5391 _LT_AC_TAGVAR(ld_shlibs, $1)=yes
5392 if test "$with_gnu_ld" = yes; then
5393 # If archive_cmds runs LD, not CC, wlarc should be empty
5394 wlarc='${wl}'
5395
5396 # Set some defaults for GNU ld with shared library support. These
5397 # are reset later if shared libraries are not supported. Putting them
5398 # here allows them to be overridden if necessary.
5399 runpath_var=LD_RUN_PATH
5400 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
5401 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5402 # ancient GNU ld didn't support --whole-archive et. al.
5403 if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
5404 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5405 else
5406 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5407 fi
5408 supports_anon_versioning=no
5409 case `$LD -v 2>/dev/null` in
5410 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
5411 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
5412 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
5413 *\ 2.11.*) ;; # other 2.11 versions
5414 *) supports_anon_versioning=yes ;;
5415 esac
5416
5417 # See if GNU ld supports shared libraries.
5418 case $host_os in
5419 aix3* | aix4* | aix5*)
5420 # On AIX/PPC, the GNU linker is very broken
5421 if test "$host_cpu" != ia64; then
5422 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5423 cat <<EOF 1>&2
5424
5425 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
5426 *** to be unable to reliably create shared libraries on AIX.
5427 *** Therefore, libtool is disabling shared libraries support. If you
5428 *** really care for shared libraries, you may want to modify your PATH
5429 *** so that a non-GNU linker is found, and then restart.
5430
5431 EOF
5432 fi
5433 ;;
5434
5435 amigaos*)
5436 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
5437 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5438 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5439
5440 # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
5441 # that the semantics of dynamic libraries on AmigaOS, at least up
5442 # to version 4, is to share data among multiple programs linked
5443 # with the same dynamic library. Since this doesn't match the
5444 # behavior of shared libraries on other platforms, we can't use
5445 # them.
5446 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5447 ;;
5448
5449 beos*)
5450 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5451 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5452 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
5453 # support --undefined. This deserves some investigation. FIXME
5454 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5455 else
5456 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5457 fi
5458 ;;
5459
5460 cygwin* | mingw* | pw32*)
5461 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
5462 # as there is no search path for DLLs.
5463 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5464 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5465 _LT_AC_TAGVAR(always_export_symbols, $1)=no
5466 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
5467 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
5468
5469 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
5470 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
5471 # If the export-symbols file already is a .def file (1st line
5472 # is EXPORTS), use it as is; otherwise, prepend...
5473 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5474 cp $export_symbols $output_objdir/$soname.def;
5475 else
5476 echo EXPORTS > $output_objdir/$soname.def;
5477 cat $export_symbols >> $output_objdir/$soname.def;
5478 fi~
5479 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
5480 else
5481 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5482 fi
5483 ;;
5484
5485 linux*)
5486 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5487 tmp_addflag=
5488 case $cc_basename,$host_cpu in
5489 pgcc*) # Portland Group C compiler
5490 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive,`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
5491 tmp_addflag=' $pic_flag'
5492 ;;
5493 pgf77* | pgf90* ) # Portland Group f77 and f90 compilers
5494 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive,`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
5495 tmp_addflag=' $pic_flag -Mnomain' ;;
5496 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
5497 tmp_addflag=' -i_dynamic' ;;
5498 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
5499 tmp_addflag=' -i_dynamic -nofor_main' ;;
5500 ifc* | ifort*) # Intel Fortran compiler
5501 tmp_addflag=' -nofor_main' ;;
5502 esac
5503 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5504
5505 if test $supports_anon_versioning = yes; then
5506 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
5507 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5508 $echo "local: *; };" >> $output_objdir/$libname.ver~
5509 $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5510 fi
5511 else
5512 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5513 fi
5514 ;;
5515
5516 netbsd*)
5517 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5518 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
5519 wlarc=
5520 else
5521 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5522 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5523 fi
5524 ;;
5525
5526 solaris* | sysv5*)
5527 if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
5528 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5529 cat <<EOF 1>&2
5530
5531 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
5532 *** create shared libraries on Solaris systems. Therefore, libtool
5533 *** is disabling shared libraries support. We urge you to upgrade GNU
5534 *** binutils to release 2.9.1 or newer. Another option is to modify
5535 *** your PATH or compiler configuration so that the native linker is
5536 *** used, and then restart.
5537
5538 EOF
5539 elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5540 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5541 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5542 else
5543 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5544 fi
5545 ;;
5546
5547 sunos4*)
5548 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5549 wlarc=
5550 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5551 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
5552 ;;
5553
5554 *)
5555 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
5556 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5557 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5558 else
5559 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5560 fi
5561 ;;
5562 esac
5563
5564 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
5565 runpath_var=
5566 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5567 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5568 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5569 fi
5570 else
5571 # PORTME fill in a description of your system's linker (not GNU ld)
5572 case $host_os in
5573 aix3*)
5574 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5575 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5576 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
5577 # Note: this linker hardcodes the directories in LIBPATH if there
5578 # are no directories specified by -L.
5579 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5580 if test "$GCC" = yes && test -z "$link_static_flag"; then
5581 # Neither direct hardcoding nor static linking is supported with a
5582 # broken collect2.
5583 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5584 fi
5585 ;;
5586
5587 aix4* | aix5*)
5588 if test "$host_cpu" = ia64; then
5589 # On IA64, the linker does run time linking by default, so we don't
5590 # have to do anything special.
5591 aix_use_runtimelinking=no
5592 exp_sym_flag='-Bexport'
5593 no_entry_flag=""
5594 else
5595 # If we're using GNU nm, then we don't want the "-C" option.
5596 # -C means demangle to AIX nm, but means don't demangle with GNU nm
5597 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
5598 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
5599 else
5600 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
5601 fi
5602 aix_use_runtimelinking=no
5603
5604 # Test if we are trying to use run time linking or normal
5605 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5606 # need to do runtime linking.
5607 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
5608 for ld_flag in $LDFLAGS; do
5609 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5610 aix_use_runtimelinking=yes
5611 break
5612 fi
5613 done
5614 esac
5615
5616 exp_sym_flag='-bexport'
5617 no_entry_flag='-bnoentry'
5618 fi
5619
5620 # When large executables or shared objects are built, AIX ld can
5621 # have problems creating the table of contents. If linking a library
5622 # or program results in "error TOC overflow" add -mminimal-toc to
5623 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
5624 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
5625
5626 _LT_AC_TAGVAR(archive_cmds, $1)=''
5627 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5628 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
5629 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
5630
5631 if test "$GCC" = yes; then
5632 case $host_os in aix4.[[012]]|aix4.[[012]].*)
5633 # We only want to do this on AIX 4.2 and lower, the check
5634 # below for broken collect2 doesn't work under 4.3+
5635 collect2name=`${CC} -print-prog-name=collect2`
5636 if test -f "$collect2name" && \
5637 strings "$collect2name" | grep resolve_lib_name >/dev/null
5638 then
5639 # We have reworked collect2
5640 _LT_AC_TAGVAR(hardcode_direct, $1)=yes
5641 else
5642 # We have old collect2
5643 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
5644 # It fails to find uninstalled libraries when the uninstalled
5645 # path is not listed in the libpath. Setting hardcode_minus_L
5646 # to unsupported forces relinking
5647 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5648 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5649 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5650 fi
5651 esac
5652 shared_flag='-shared'
5653 if test "$aix_use_runtimelinking" = yes; then
5654 shared_flag="$shared_flag "'${wl}-G'
5655 fi
5656 else
5657 # not using gcc
5658 if test "$host_cpu" = ia64; then
5659 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
5660 # chokes on -Wl,-G. The following line is correct:
5661 shared_flag='-G'
5662 else
5663 if test "$aix_use_runtimelinking" = yes; then
5664 shared_flag='${wl}-G'
5665 else
5666 shared_flag='${wl}-bM:SRE'
5667 fi
5668 fi
5669 fi
5670
5671 # It seems that -bexpall does not export symbols beginning with
5672 # underscore (_), so it is better to generate a list of symbols to export.
5673 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5674 if test "$aix_use_runtimelinking" = yes; then
5675 # Warning - without using the other runtime loading flags (-brtl),
5676 # -berok will link without error, but may produce a broken library.
5677 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
5678 # Determine the default libpath from the value encoded in an empty executable.
5679 _LT_AC_SYS_LIBPATH_AIX
5680 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5681 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5682 else
5683 if test "$host_cpu" = ia64; then
5684 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5685 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5686 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
5687 else
5688 # Determine the default libpath from the value encoded in an empty executable.
5689 _LT_AC_SYS_LIBPATH_AIX
5690 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5691 # Warning - without using the other run time loading flags,
5692 # -berok will link without error, but may produce a broken library.
5693 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5694 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5695 # -bexpall does not export symbols beginning with underscore (_)
5696 _LT_AC_TAGVAR(always_export_symbols, $1)=yes
5697 # Exported symbols can be pulled into shared objects from archives
5698 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
5699 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
5700 # This is similar to how AIX traditionally builds it's shared libraries.
5701 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
5702 fi
5703 fi
5704 ;;
5705
5706 amigaos*)
5707 _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
5708 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5709 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
5710 # see comment about different semantics on the GNU ld section
5711 _LT_AC_TAGVAR(ld_shlibs, $1)=no
5712 ;;
5713
5714 bsdi[[45]]*)
5715 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
5716 ;;
5717
5718 cygwin* | mingw* | pw32*)
5719 # When not using gcc, we currently assume that we are using
5720 # Microsoft Visual C++.
5721 # hardcode_libdir_flag_spec is actually meaningless, as there is
5722 # no search path for DLLs.
5723 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
5724 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
5725 # Tell ltmain to make .lib files, not .a files.
5726 libext=lib
5727 # Tell ltmain to make .dll files, not .so files.
5728 shrext_cmds=".dll"
5729 # FIXME: Setting linknames here is a bad hack.
5730 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
5731 # The linker will automatically build a .lib file if we build a DLL.
5732 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
5733 # FIXME: Should let the user specify the lib program.