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